gomtm 0.0.226 → 0.0.227
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -35,7 +35,7 @@ import { useMutation, useSuspenseInfiniteQuery } from "../connectquery";
|
|
|
35
35
|
import CurdCreatePanel, { CurdCreatePanelTriggerButton, openCurdCreatePanelAtom } from "./create/CurdCreatePanel";
|
|
36
36
|
import { activateItemAtom, createMethodSigAtom, openCreatePanelAtom, openRemovePanelAtom, removeMethodSigAtom } from "./curd.atoms";
|
|
37
37
|
import { DlgCurdDebugInfo, DlgCurdDebugInfoTriggerButton, openDlgCurdDebugInfoAtom } from "./dlg/DlgCurdDebugInfo";
|
|
38
|
-
import { CurdEditPanelTriggerButton, openCurdEditPanelAtom } from "./edit/CurdEditPanel";
|
|
38
|
+
import CurdEditPanel, { CurdEditPanelTriggerButton, openCurdEditPanelAtom } from "./edit/CurdEditPanel";
|
|
39
39
|
import { ListItemView } from "./list-item/ListItem";
|
|
40
40
|
import { ListLayout } from "./list-item/ListLayout";
|
|
41
41
|
const listQueryAtom = atom(null);
|
|
@@ -158,6 +158,7 @@ const ListViewActions = () => {
|
|
|
158
158
|
/* @__PURE__ */ jsx(PanelCreate, {}),
|
|
159
159
|
/* @__PURE__ */ jsx(DlgCurdDebugInfo, {}),
|
|
160
160
|
/* @__PURE__ */ jsx(CurdCreatePanel, {}),
|
|
161
|
+
/* @__PURE__ */ jsx(CurdEditPanel, {}),
|
|
161
162
|
/* @__PURE__ */ jsxs("div", { className: "bg-yellow-100 p-2", children: [
|
|
162
163
|
/* @__PURE__ */ jsx(DlgCurdDebugInfoTriggerButton, {}),
|
|
163
164
|
/* @__PURE__ */ jsx(CurdEditPanelTriggerButton, {}),
|
|
@@ -1,20 +1,25 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { atom, useAtom } from "jotai";
|
|
4
|
-
import { useMtRouter } from "mtxuilib/hooks/use-router";
|
|
5
4
|
import { Dialog, DialogContent, DialogTitle } from "mtxuilib/ui/dialog";
|
|
6
5
|
import { MtButton } from "mtxuilib/ui/ui-mt/Button";
|
|
7
6
|
const openCurdEditPanelAtom = atom(false);
|
|
8
7
|
function CurdEditPanel() {
|
|
9
|
-
const router = useMtRouter();
|
|
10
8
|
const [openCurdEditPanel, setOpenCurdEditPanel] = useAtom(openCurdEditPanelAtom);
|
|
11
9
|
return /* @__PURE__ */ jsx(Dialog, { open: openCurdEditPanel, onOpenChange: setOpenCurdEditPanel, children: /* @__PURE__ */ jsx(DialogContent, { children: /* @__PURE__ */ jsx(DialogTitle, { children: " Edit " }) }) });
|
|
12
10
|
}
|
|
13
11
|
const CurdEditPanelTriggerButton = () => {
|
|
14
|
-
const [
|
|
15
|
-
return /* @__PURE__ */
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
const [openCurdEditPanel, setOpenCurdEditPanel] = useAtom(openCurdEditPanelAtom);
|
|
13
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
14
|
+
/* @__PURE__ */ jsx("pre", { children: openCurdEditPanel }),
|
|
15
|
+
/* @__PURE__ */ jsxs(MtButton, { onClick: () => {
|
|
16
|
+
setOpenCurdEditPanel(true);
|
|
17
|
+
}, children: [
|
|
18
|
+
"Edit(",
|
|
19
|
+
JSON.stringify(openCurdEditPanel, null, 2),
|
|
20
|
+
")"
|
|
21
|
+
] })
|
|
22
|
+
] });
|
|
18
23
|
};
|
|
19
24
|
export {
|
|
20
25
|
CurdEditPanelTriggerButton,
|