diff --git a/app/web/src/nova/ed/ed-base.tsx b/app/web/src/nova/ed/ed-base.tsx index 25c92435..38874ea6 100644 --- a/app/web/src/nova/ed/ed-base.tsx +++ b/app/web/src/nova/ed/ed-base.tsx @@ -14,6 +14,7 @@ import { EdPagePop } from "./panel/popup/page/page-popup"; import { EdPopScript } from "./panel/popup/script/pop-script"; import { EdPopSite } from "./panel/popup/site/site-popup"; import { EdScriptInit } from "./panel/script/monaco/init"; +import { EdPopApi } from "./panel/popup/api/api-server"; export const EdBase = () => { const p = useGlobal(EDGlobal, "EDITOR"); @@ -51,6 +52,7 @@ export const EdBase = () => { + diff --git a/app/web/src/nova/ed/logic/ed-global.ts b/app/web/src/nova/ed/logic/ed-global.ts index 96621d19..39e41e91 100644 --- a/app/web/src/nova/ed/logic/ed-global.ts +++ b/app/web/src/nova/ed/logic/ed-global.ts @@ -244,6 +244,7 @@ export const EDGlobal = { on_pick?: (group_id: string) => void | Promise; on_close?: () => void | Promise; }, + api: { open: false }, }, }, }; diff --git a/app/web/src/nova/ed/panel/header/left/api.tsx b/app/web/src/nova/ed/panel/header/left/api.tsx index 053f7b20..74f6137a 100644 --- a/app/web/src/nova/ed/panel/header/left/api.tsx +++ b/app/web/src/nova/ed/panel/header/left/api.tsx @@ -1,12 +1,18 @@ -import { EdApiServer } from "../../popup/api/api-server"; +import { useGlobal } from "web-utils"; import { TopBtn } from "../top-btn"; +import { EDGlobal } from "../../../logic/ed-global"; export const EdApi = () => { + const p = useGlobal(EDGlobal, "EDITOR"); + return ( } + onClick={() => { + p.ui.popup.api.open = true; + p.render(); + }} placement="right" >
{ + const p = useGlobal(EDGlobal, "EDITOR"); + + return ( + { + p.ui.popup.api.open = open; + p.render(); + }} + > + + + ); +}; export const EdApiServer = forwardRef< HTMLDivElement, diff --git a/app/web/src/nova/ed/panel/tree/node/item/name.tsx b/app/web/src/nova/ed/panel/tree/node/item/name.tsx index 7b3c0a4b..35e7e431 100644 --- a/app/web/src/nova/ed/panel/tree/node/item/name.tsx +++ b/app/web/src/nova/ed/panel/tree/node/item/name.tsx @@ -2,6 +2,7 @@ import { NodeModel, RenderParams } from "@minoru/react-dnd-treeview"; import { EDGlobal, EdMeta } from "../../../../logic/ed-global"; import { useGlobal, useLocal } from "web-utils"; import { FC, useEffect } from "react"; +import { Tooltip } from "../../../../../../utils/ui/tooltip"; export const EdTreeName = ({ node, @@ -74,7 +75,7 @@ export const EdTreeName = ({ ) : (
-
{item.id}
+ {/*
{item.id}
*/}
)}
@@ -88,8 +89,8 @@ const Name: FC<{ name: string; is_jsx_prop: boolean }> = ({ if (is_jsx_prop) { return (
-
- PROP +
+ P
{name}