@akanjs/ui 0.0.149 → 0.0.151
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.
- package/BottomSheet.d.ts +13 -0
- package/Button.d.ts +9 -0
- package/ClientSide.d.ts +6 -0
- package/Copy.d.ts +6 -0
- package/CsrImage.d.ts +11 -0
- package/Data/CardList.d.ts +36 -0
- package/Data/Dashboard.d.ts +15 -0
- package/Data/Insight.d.ts +8 -0
- package/Data/Item.d.ts +74 -0
- package/Data/ListContainer.d.ts +38 -0
- package/Data/Pagination.d.ts +6 -0
- package/Data/QueryMaker.d.ts +9 -0
- package/Data/TableList.d.ts +26 -0
- package/Data/index.d.ts +10 -0
- package/Data/index_.d.ts +8 -0
- package/DatePicker.d.ts +38 -0
- package/Dialog/Action.d.ts +5 -0
- package/Dialog/Close.d.ts +5 -0
- package/Dialog/Content.d.ts +6 -0
- package/Dialog/Modal.d.ts +8 -0
- package/Dialog/Provider.d.ts +7 -0
- package/Dialog/Title.d.ts +5 -0
- package/Dialog/Trigger.d.ts +5 -0
- package/Dialog/context.d.ts +10 -0
- package/Dialog/index.d.ts +9 -0
- package/DragAction.d.ts +24 -0
- package/DraggableList.d.ts +25 -0
- package/Dropdown.d.ts +10 -0
- package/Empty.d.ts +9 -0
- package/Field.d.ts +404 -0
- package/FontFace.d.ts +6 -0
- package/Image.d.ts +17 -0
- package/InfiniteScroll.d.ts +10 -0
- package/Input.d.ts +85 -0
- package/KeyboardAvoiding.d.ts +7 -0
- package/Layout/BottomAction.d.ts +5 -0
- package/Layout/BottomInset.d.ts +6 -0
- package/Layout/BottomTab.d.ts +14 -0
- package/Layout/Header.d.ts +7 -0
- package/Layout/LeftSider.d.ts +8 -0
- package/Layout/Navbar.d.ts +11 -0
- package/Layout/RightSider.d.ts +9 -0
- package/Layout/Sider.d.ts +6 -0
- package/Layout/Template.d.ts +5 -0
- package/Layout/TopLeftAction.d.ts +5 -0
- package/Layout/Unit.d.ts +6 -0
- package/Layout/View.d.ts +5 -0
- package/Layout/Zone.d.ts +5 -0
- package/Layout/index.d.ts +14 -0
- package/Link/Back.d.ts +6 -0
- package/Link/Close.d.ts +6 -0
- package/Link/CsrLink.d.ts +2 -0
- package/Link/NextLink.d.ts +2 -0
- package/Link/index.d.ts +8 -0
- package/Link/types.d.ts +22 -0
- package/Load/Edit.d.ts +4 -0
- package/Load/Edit_Client.d.ts +25 -0
- package/Load/Page.d.ts +10 -0
- package/Load/PageCSR.d.ts +11 -0
- package/Load/Pagination.d.ts +8 -0
- package/Load/Units.d.ts +34 -0
- package/Load/View.d.ts +17 -0
- package/Load/index.d.ts +8 -0
- package/Load/index_.d.ts +3 -0
- package/Loading/Area.d.ts +1 -0
- package/Loading/Button.d.ts +7 -0
- package/Loading/Input.d.ts +7 -0
- package/Loading/ProgressBar.d.ts +6 -0
- package/Loading/Skeleton.d.ts +7 -0
- package/Loading/Spin.d.ts +7 -0
- package/Loading/index.d.ts +8 -0
- package/Menu.d.ts +26 -0
- package/Modal.d.ts +23 -0
- package/Model/Edit.d.ts +15 -0
- package/Model/EditModal.d.ts +33 -0
- package/Model/EditWrapper.d.ts +11 -0
- package/Model/LoadInit.d.ts +10 -0
- package/Model/New.d.ts +15 -0
- package/Model/NewWrapper.d.ts +12 -0
- package/Model/NewWrapper_Client.d.ts +12 -0
- package/Model/Remove.d.ts +10 -0
- package/Model/RemoveWrapper.d.ts +11 -0
- package/Model/SureToRemove.d.ts +10 -0
- package/Model/View.d.ts +19 -0
- package/Model/ViewEditModal.d.ts +11 -0
- package/Model/ViewModal.d.ts +13 -0
- package/Model/ViewWrapper.d.ts +11 -0
- package/Model/index.d.ts +15 -0
- package/Model/index_.d.ts +13 -0
- package/More.d.ts +12 -0
- package/ObjectId.d.ts +5 -0
- package/Pagination.d.ts +14 -0
- package/Popconfirm.d.ts +18 -0
- package/Portal.d.ts +6 -0
- package/Radio.d.ts +19 -0
- package/RecentTime.d.ts +7 -0
- package/Refresh.d.ts +7 -0
- package/ScreenNavigator.d.ts +18 -0
- package/Select.d.ts +29 -0
- package/Signal/Arg.d.ts +75 -0
- package/Signal/Doc.d.ts +19 -0
- package/Signal/GraphQL.d.ts +32 -0
- package/Signal/Listener.d.ts +9 -0
- package/Signal/Message.d.ts +27 -0
- package/Signal/Object.d.ts +19 -0
- package/Signal/PubSub.d.ts +26 -0
- package/Signal/Request.d.ts +8 -0
- package/Signal/Response.d.ts +16 -0
- package/Signal/RestApi.d.ts +40 -0
- package/Signal/WebSocket.d.ts +9 -0
- package/Signal/index.d.ts +20 -0
- package/System/CSR.d.ts +31 -0
- package/System/Client.d.ts +48 -0
- package/System/Common.d.ts +66 -0
- package/System/DevModeToggle.d.ts +1 -0
- package/System/Gtag.d.ts +3 -0
- package/System/HealthCheck.d.ts +5 -0
- package/System/Messages.d.ts +1 -0
- package/System/Reconnect.d.ts +6 -0
- package/System/Root.d.ts +5 -0
- package/System/SSR.d.ts +26 -0
- package/System/SelectLanguage.d.ts +5 -0
- package/System/ThemeToggle.d.ts +1 -0
- package/System/index.d.ts +11 -0
- package/Tab/Menu.d.ts +11 -0
- package/Tab/Menus.d.ts +5 -0
- package/Tab/Panel.d.ts +7 -0
- package/Tab/Provider.d.ts +6 -0
- package/Tab/context.d.ts +9 -0
- package/Tab/index.d.ts +7 -0
- package/Table.d.ts +26 -0
- package/ToggleSelect.d.ts +31 -0
- package/Unauthorized.d.ts +9 -0
- package/cjs/BottomSheet.js +113 -0
- package/cjs/Button.js +69 -0
- package/cjs/ClientSide.js +26 -0
- package/cjs/Copy.js +37 -0
- package/cjs/CsrImage.js +50 -0
- package/cjs/Data/CardList.js +119 -0
- package/cjs/Data/Dashboard.js +54 -0
- package/cjs/Data/Insight.js +38 -0
- package/cjs/Data/Item.js +204 -0
- package/cjs/Data/ListContainer.js +251 -0
- package/cjs/Data/Pagination.js +64 -0
- package/cjs/Data/QueryMaker.js +304 -0
- package/cjs/Data/TableList.js +139 -0
- package/cjs/Data/index.js +33 -0
- package/cjs/Data/index_.js +49 -0
- package/cjs/DatePicker.js +173 -0
- package/cjs/Dialog/Action.js +32 -0
- package/cjs/Dialog/Close.js +38 -0
- package/cjs/Dialog/Content.js +27 -0
- package/cjs/Dialog/Modal.js +155 -0
- package/cjs/Dialog/Provider.js +46 -0
- package/cjs/Dialog/Title.js +32 -0
- package/cjs/Dialog/Trigger.js +38 -0
- package/cjs/Dialog/context.js +32 -0
- package/cjs/Dialog/index.js +36 -0
- package/cjs/DragAction.js +111 -0
- package/cjs/DraggableList.js +141 -0
- package/cjs/Dropdown.js +64 -0
- package/cjs/Empty.js +50 -0
- package/cjs/Field.js +1109 -0
- package/cjs/FontFace.js +77 -0
- package/cjs/Image.js +61 -0
- package/cjs/InfiniteScroll.js +65 -0
- package/cjs/Input.js +440 -0
- package/cjs/KeyboardAvoiding.js +65 -0
- package/cjs/Layout/BottomAction.js +26 -0
- package/cjs/Layout/BottomInset.js +53 -0
- package/cjs/Layout/BottomTab.js +56 -0
- package/cjs/Layout/Header.js +52 -0
- package/cjs/Layout/LeftSider.js +49 -0
- package/cjs/Layout/Navbar.js +51 -0
- package/cjs/Layout/RightSider.js +52 -0
- package/cjs/Layout/Sider.js +39 -0
- package/cjs/Layout/Template.js +26 -0
- package/cjs/Layout/TopLeftAction.js +39 -0
- package/cjs/Layout/Unit.js +27 -0
- package/cjs/Layout/View.js +26 -0
- package/cjs/Layout/Zone.js +26 -0
- package/cjs/Layout/index.js +48 -0
- package/cjs/Link/Back.js +27 -0
- package/cjs/Link/Close.js +36 -0
- package/cjs/Link/CsrLink.js +49 -0
- package/cjs/Link/NextLink.js +71 -0
- package/cjs/Link/index.js +47 -0
- package/cjs/Link/types.js +15 -0
- package/cjs/Load/Edit.js +42 -0
- package/cjs/Load/Edit_Client.js +93 -0
- package/cjs/Load/Page.js +35 -0
- package/cjs/Load/PageCSR.js +67 -0
- package/cjs/Load/Pagination.js +89 -0
- package/cjs/Load/Units.js +232 -0
- package/cjs/Load/View.js +88 -0
- package/cjs/Load/index.js +42 -0
- package/cjs/Load/index_.js +39 -0
- package/cjs/Loading/Area.js +25 -0
- package/cjs/Loading/Button.js +33 -0
- package/cjs/Loading/Input.js +33 -0
- package/cjs/Loading/ProgressBar.js +29 -0
- package/cjs/Loading/Skeleton.js +27 -0
- package/cjs/Loading/Spin.js +27 -0
- package/cjs/Loading/index.js +29 -0
- package/cjs/Menu.js +215 -0
- package/cjs/Modal.js +75 -0
- package/cjs/Model/Edit.js +61 -0
- package/cjs/Model/EditModal.js +255 -0
- package/cjs/Model/EditWrapper.js +48 -0
- package/cjs/Model/LoadInit.js +27 -0
- package/cjs/Model/New.js +61 -0
- package/cjs/Model/NewWrapper.js +28 -0
- package/cjs/Model/NewWrapper_Client.js +66 -0
- package/cjs/Model/Remove.js +86 -0
- package/cjs/Model/RemoveWrapper.js +48 -0
- package/cjs/Model/SureToRemove.js +109 -0
- package/cjs/Model/View.js +44 -0
- package/cjs/Model/ViewEditModal.js +118 -0
- package/cjs/Model/ViewModal.js +92 -0
- package/cjs/Model/ViewWrapper.js +48 -0
- package/cjs/Model/index.js +38 -0
- package/cjs/Model/index_.js +58 -0
- package/cjs/More.js +67 -0
- package/cjs/ObjectId.js +37 -0
- package/cjs/Pagination.js +110 -0
- package/cjs/Popconfirm.js +116 -0
- package/cjs/Portal.js +27 -0
- package/cjs/Radio.js +53 -0
- package/cjs/RecentTime.js +86 -0
- package/cjs/Refresh.js +45 -0
- package/cjs/ScreenNavigator.js +121 -0
- package/cjs/Select.js +262 -0
- package/cjs/Signal/Arg.js +237 -0
- package/cjs/Signal/Doc.js +181 -0
- package/cjs/Signal/GraphQL.js +177 -0
- package/cjs/Signal/Listener.js +59 -0
- package/cjs/Signal/Message.js +190 -0
- package/cjs/Signal/Object.js +95 -0
- package/cjs/Signal/PubSub.js +191 -0
- package/cjs/Signal/Request.js +38 -0
- package/cjs/Signal/Response.js +53 -0
- package/cjs/Signal/RestApi.js +255 -0
- package/cjs/Signal/WebSocket.js +68 -0
- package/cjs/Signal/index.js +42 -0
- package/cjs/System/CSR.js +376 -0
- package/cjs/System/Client.js +200 -0
- package/cjs/System/Common.js +64 -0
- package/cjs/System/DevModeToggle.js +38 -0
- package/cjs/System/Gtag.js +67 -0
- package/cjs/System/HealthCheck.js +60 -0
- package/cjs/System/Messages.js +170 -0
- package/cjs/System/Reconnect.js +64 -0
- package/cjs/System/Root.js +30 -0
- package/cjs/System/SSR.js +144 -0
- package/cjs/System/SelectLanguage.js +58 -0
- package/cjs/System/ThemeToggle.js +40 -0
- package/cjs/System/index.js +55 -0
- package/cjs/Tab/Menu.js +70 -0
- package/cjs/{src/index.js → Tab/Menus.js} +8 -5
- package/cjs/Tab/Panel.js +42 -0
- package/cjs/Tab/Provider.js +31 -0
- package/cjs/Tab/context.js +30 -0
- package/cjs/Tab/index.js +32 -0
- package/cjs/Table.js +85 -0
- package/cjs/ToggleSelect.js +118 -0
- package/cjs/Unauthorized.js +50 -0
- package/cjs/index.js +88 -2
- package/esm/BottomSheet.js +84 -0
- package/esm/Button.js +40 -0
- package/esm/ClientSide.js +7 -0
- package/esm/Copy.js +18 -0
- package/esm/CsrImage.js +31 -0
- package/esm/Data/CardList.js +90 -0
- package/esm/Data/Dashboard.js +35 -0
- package/esm/Data/Insight.js +19 -0
- package/esm/Data/Item.js +175 -0
- package/esm/Data/ListContainer.js +228 -0
- package/esm/Data/Pagination.js +45 -0
- package/esm/Data/QueryMaker.js +293 -0
- package/esm/Data/TableList.js +110 -0
- package/esm/Data/index.js +14 -0
- package/esm/Data/index_.js +20 -0
- package/esm/DatePicker.js +144 -0
- package/esm/Dialog/Action.js +13 -0
- package/esm/Dialog/Close.js +19 -0
- package/esm/Dialog/Content.js +8 -0
- package/esm/Dialog/Modal.js +126 -0
- package/esm/Dialog/Provider.js +17 -0
- package/esm/Dialog/Title.js +13 -0
- package/esm/Dialog/Trigger.js +19 -0
- package/esm/Dialog/context.js +13 -0
- package/esm/Dialog/index.js +17 -0
- package/esm/DragAction.js +92 -0
- package/esm/DraggableList.js +112 -0
- package/esm/Dropdown.js +45 -0
- package/esm/Empty.js +21 -0
- package/esm/Field.js +1090 -0
- package/esm/FontFace.js +58 -0
- package/esm/Image.js +32 -0
- package/esm/InfiniteScroll.js +46 -0
- package/esm/Input.js +415 -0
- package/esm/KeyboardAvoiding.js +46 -0
- package/esm/Layout/BottomAction.js +7 -0
- package/esm/Layout/BottomInset.js +34 -0
- package/esm/Layout/BottomTab.js +37 -0
- package/esm/Layout/Header.js +33 -0
- package/esm/Layout/LeftSider.js +30 -0
- package/esm/Layout/Navbar.js +22 -0
- package/esm/Layout/RightSider.js +33 -0
- package/esm/Layout/Sider.js +20 -0
- package/esm/Layout/Template.js +7 -0
- package/esm/Layout/TopLeftAction.js +20 -0
- package/esm/Layout/Unit.js +8 -0
- package/esm/Layout/View.js +7 -0
- package/esm/Layout/Zone.js +7 -0
- package/esm/Layout/index.js +29 -0
- package/esm/Link/Back.js +8 -0
- package/esm/Link/Close.js +17 -0
- package/esm/Link/CsrLink.js +30 -0
- package/esm/Link/NextLink.js +42 -0
- package/esm/Link/index.js +18 -0
- package/esm/Link/types.js +0 -0
- package/esm/Load/Edit.js +13 -0
- package/esm/Load/Edit_Client.js +74 -0
- package/esm/Load/Page.js +16 -0
- package/esm/Load/PageCSR.js +48 -0
- package/esm/Load/Pagination.js +70 -0
- package/esm/Load/Units.js +213 -0
- package/esm/Load/View.js +69 -0
- package/esm/Load/index.js +13 -0
- package/esm/Load/index_.js +10 -0
- package/esm/Loading/Area.js +6 -0
- package/esm/Loading/Button.js +14 -0
- package/esm/Loading/Input.js +14 -0
- package/esm/Loading/ProgressBar.js +10 -0
- package/esm/Loading/Skeleton.js +8 -0
- package/esm/Loading/Spin.js +8 -0
- package/esm/Loading/index.js +10 -0
- package/esm/Menu.js +196 -0
- package/esm/Modal.js +46 -0
- package/esm/Model/Edit.js +32 -0
- package/esm/Model/EditModal.js +226 -0
- package/esm/Model/EditWrapper.js +29 -0
- package/esm/Model/LoadInit.js +8 -0
- package/esm/Model/New.js +32 -0
- package/esm/Model/NewWrapper.js +9 -0
- package/esm/Model/NewWrapper_Client.js +47 -0
- package/esm/Model/Remove.js +67 -0
- package/esm/Model/RemoveWrapper.js +29 -0
- package/esm/Model/SureToRemove.js +90 -0
- package/esm/Model/View.js +25 -0
- package/esm/Model/ViewEditModal.js +89 -0
- package/esm/Model/ViewModal.js +63 -0
- package/esm/Model/ViewWrapper.js +29 -0
- package/esm/Model/index.js +33 -0
- package/esm/Model/index_.js +29 -0
- package/esm/More.js +38 -0
- package/esm/ObjectId.js +18 -0
- package/esm/Pagination.js +91 -0
- package/esm/Popconfirm.js +87 -0
- package/esm/Portal.js +8 -0
- package/esm/Radio.js +34 -0
- package/esm/RecentTime.js +57 -0
- package/esm/Refresh.js +16 -0
- package/esm/ScreenNavigator.js +102 -0
- package/esm/Select.js +243 -0
- package/esm/Signal/Arg.js +208 -0
- package/esm/Signal/Doc.js +152 -0
- package/esm/Signal/GraphQL.js +156 -0
- package/esm/Signal/Listener.js +40 -0
- package/esm/Signal/Message.js +161 -0
- package/esm/Signal/Object.js +76 -0
- package/esm/Signal/PubSub.js +162 -0
- package/esm/Signal/Request.js +19 -0
- package/esm/Signal/Response.js +34 -0
- package/esm/Signal/RestApi.js +234 -0
- package/esm/Signal/WebSocket.js +39 -0
- package/esm/Signal/index.js +13 -0
- package/esm/System/CSR.js +357 -0
- package/esm/System/Client.js +191 -0
- package/esm/System/Common.js +45 -0
- package/esm/System/DevModeToggle.js +19 -0
- package/esm/System/Gtag.js +48 -0
- package/esm/System/HealthCheck.js +41 -0
- package/esm/System/Messages.js +156 -0
- package/esm/System/Reconnect.js +45 -0
- package/esm/System/Root.js +11 -0
- package/esm/System/SSR.js +125 -0
- package/esm/System/SelectLanguage.js +39 -0
- package/esm/System/ThemeToggle.js +21 -0
- package/esm/System/index.js +26 -0
- package/esm/Tab/Menu.js +51 -0
- package/esm/Tab/Menus.js +7 -0
- package/esm/Tab/Panel.js +23 -0
- package/esm/Tab/Provider.js +12 -0
- package/esm/Tab/context.js +11 -0
- package/esm/Tab/index.js +13 -0
- package/esm/Table.js +56 -0
- package/esm/ToggleSelect.js +99 -0
- package/esm/Unauthorized.js +21 -0
- package/esm/index.js +84 -1
- package/index.d.ts +41 -1
- package/package.json +23 -2
- package/esm/src/index.js +0 -4
- package/src/index.d.ts +0 -1
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var QueryMaker_exports = {};
|
|
20
|
+
__export(QueryMaker_exports, {
|
|
21
|
+
default: () => QueryMaker
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(QueryMaker_exports);
|
|
24
|
+
var import_base = require("@akanjs/base");
|
|
25
|
+
var import_client = require("@akanjs/client");
|
|
26
|
+
var import_common = require("@akanjs/common");
|
|
27
|
+
var import_constant = require("@akanjs/constant");
|
|
28
|
+
var import_next = require("@akanjs/next");
|
|
29
|
+
var import_store = require("@akanjs/store");
|
|
30
|
+
var import_react = require("react");
|
|
31
|
+
var import_bi = require("react-icons/bi");
|
|
32
|
+
var import_DatePicker = require("../DatePicker");
|
|
33
|
+
var import_Input = require("../Input");
|
|
34
|
+
var import_Modal = require("../Modal");
|
|
35
|
+
var import_Select = require("../Select");
|
|
36
|
+
const searchQuerySetting = { queryKey: "search", arg: { $search: void 0 } };
|
|
37
|
+
const byStatusQuerySetting = { queryKey: "byStatuses", arg: { statuses: null } };
|
|
38
|
+
function QueryMaker({ className, sliceName, query }) {
|
|
39
|
+
const { l } = (0, import_next.usePage)();
|
|
40
|
+
const storeDo = import_store.st.do;
|
|
41
|
+
const cnst = (0, import_constant.getCnstMeta)(sliceName);
|
|
42
|
+
const isModelSearchable = (0, import_constant.hasTextField)(cnst.Full);
|
|
43
|
+
const summaryRef = cnst.Summary;
|
|
44
|
+
const { subMenu, filter } = import_store.st.use.searchParams();
|
|
45
|
+
const summaryQueryMap = (0, import_constant.getQueryMap)(summaryRef);
|
|
46
|
+
const filterRef = cnst.Filter;
|
|
47
|
+
const filterQueryMap = (0, import_constant.getFilterQueryMap)(filterRef);
|
|
48
|
+
const defaultQuerySetting = { ...isModelSearchable ? searchQuerySetting : byStatusQuerySetting, ...query ?? {} };
|
|
49
|
+
const isInitialized = (0, import_react.useRef)(false);
|
|
50
|
+
const [querySetting, setQuerySetting] = (0, import_react.useState)(defaultQuerySetting);
|
|
51
|
+
const getQuery = (0, import_react.useCallback)(
|
|
52
|
+
(querySetting2) => {
|
|
53
|
+
if (summaryQueryMap[querySetting2.queryKey]) {
|
|
54
|
+
const query2 = typeof summaryQueryMap[querySetting2.queryKey] === "function" ? summaryQueryMap[querySetting2.queryKey]() : summaryQueryMap[querySetting2.queryKey] ?? null;
|
|
55
|
+
if (!query2)
|
|
56
|
+
throw new Error(`Query not found`);
|
|
57
|
+
return query2;
|
|
58
|
+
} else if (querySetting2.queryKey === "search") {
|
|
59
|
+
const query2 = querySetting2.arg;
|
|
60
|
+
return query2;
|
|
61
|
+
} else {
|
|
62
|
+
const queryFn = (0, import_constant.getFilterQuery)(filterRef, querySetting2.queryKey);
|
|
63
|
+
const filterQueryArgMetas = (0, import_constant.getFilterArgMetas)(filterRef, querySetting2.queryKey);
|
|
64
|
+
const queryArgs = filterQueryArgMetas.map((queryArgMeta) => querySetting2.arg[queryArgMeta.name]);
|
|
65
|
+
const query2 = queryFn(...queryArgs);
|
|
66
|
+
return query2;
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
[filter]
|
|
70
|
+
);
|
|
71
|
+
const setQueryOfModel = (0, import_next.useDebounce)((querySetting2) => {
|
|
72
|
+
const query2 = getQuery(querySetting2);
|
|
73
|
+
if (!isInitialized.current) {
|
|
74
|
+
void storeDo[`init${(0, import_common.capitalize)(sliceName)}`](query2);
|
|
75
|
+
isInitialized.current = true;
|
|
76
|
+
} else
|
|
77
|
+
void storeDo[`setQueryArgsOf${(0, import_common.capitalize)(sliceName)}`](query2);
|
|
78
|
+
});
|
|
79
|
+
(0, import_react.useEffect)(() => {
|
|
80
|
+
if (filter && subMenu === sliceName)
|
|
81
|
+
setQuerySetting({ queryKey: filter, arg: {} });
|
|
82
|
+
}, [filter, subMenu]);
|
|
83
|
+
(0, import_react.useEffect)(() => {
|
|
84
|
+
setQueryOfModel(querySetting);
|
|
85
|
+
}, [querySetting]);
|
|
86
|
+
return /* @__PURE__ */ React.createElement("div", { className: (0, import_client.clsx)("flex w-full items-center gap-4", className) }, /* @__PURE__ */ React.createElement("div", { className: "flex flex-col gap-2" }, "Query", /* @__PURE__ */ React.createElement(
|
|
87
|
+
import_Select.Select,
|
|
88
|
+
{
|
|
89
|
+
value: querySetting.queryKey,
|
|
90
|
+
options: Object.keys(summaryQueryMap).map((queryKey) => ({
|
|
91
|
+
label: l.qry(sliceName, queryKey),
|
|
92
|
+
value: queryKey
|
|
93
|
+
})),
|
|
94
|
+
onChange: (queryKey) => {
|
|
95
|
+
const filterQueryArgMetas = (0, import_constant.getFilterArgMetas)(filterRef, queryKey);
|
|
96
|
+
const defaultArg = Object.fromEntries(
|
|
97
|
+
filterQueryArgMetas.map((queryArgMeta) => [
|
|
98
|
+
queryArgMeta.name,
|
|
99
|
+
queryArgMeta.nullable ? null : queryArgMeta.arrDepth ? { $in: [] } : queryArgMeta.default ? typeof queryArgMeta.default === "function" ? queryArgMeta.default() : queryArgMeta.default : import_base.scalarDefaultMap.get(queryArgMeta.modelRef) ?? null
|
|
100
|
+
])
|
|
101
|
+
);
|
|
102
|
+
setQuerySetting({ queryKey, arg: defaultArg });
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
)), querySetting.queryKey === "search" ? /* @__PURE__ */ React.createElement("div", { className: "flex w-full flex-col gap-2" }, "Search", /* @__PURE__ */ React.createElement("label", { className: "input flex w-full items-center gap-2" }, /* @__PURE__ */ React.createElement(
|
|
106
|
+
"input",
|
|
107
|
+
{
|
|
108
|
+
type: "text",
|
|
109
|
+
className: "grow",
|
|
110
|
+
placeholder: "Type to search...",
|
|
111
|
+
value: querySetting.arg.$search ?? "",
|
|
112
|
+
onChange: (e) => {
|
|
113
|
+
setQuerySetting({ ...querySetting, arg: e.target.value ? { $search: e.target.value } : {} });
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
), /* @__PURE__ */ React.createElement(import_bi.BiSearch, { className: "size-4 opacity-70" }))) : summaryQueryMap[querySetting.queryKey] ? null : (0, import_constant.getFilterArgMetas)(filterRef, querySetting.queryKey).map((queryArgMeta, idx) => /* @__PURE__ */ React.createElement("div", { className: "flex flex-col gap-2", key: idx }, /* @__PURE__ */ React.createElement("div", { className: "text-sm text-gray-500" }, l.qarg(sliceName, querySetting.queryKey, queryArgMeta.name)), /* @__PURE__ */ React.createElement(
|
|
117
|
+
QueryArg,
|
|
118
|
+
{
|
|
119
|
+
queryArgMeta,
|
|
120
|
+
value: querySetting.arg[queryArgMeta.name],
|
|
121
|
+
onChange: (value) => {
|
|
122
|
+
setQuerySetting({
|
|
123
|
+
...querySetting,
|
|
124
|
+
arg: { ...querySetting.arg, [queryArgMeta.name]: value }
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
))));
|
|
129
|
+
}
|
|
130
|
+
function QueryArg({ queryArgMeta, value, onChange }) {
|
|
131
|
+
const argType = (0, import_constant.getGqlTypeStr)(queryArgMeta.modelRef);
|
|
132
|
+
if (queryArgMeta.enum && queryArgMeta.arrDepth && queryArgMeta.arrDepth < 2)
|
|
133
|
+
return /* @__PURE__ */ React.createElement(
|
|
134
|
+
QueryArg.Enum,
|
|
135
|
+
{
|
|
136
|
+
options: queryArgMeta.enum.values,
|
|
137
|
+
value,
|
|
138
|
+
onChange,
|
|
139
|
+
nullable: queryArgMeta.nullable,
|
|
140
|
+
multiple: queryArgMeta.arrDepth ? queryArgMeta.arrDepth >= 1 : false
|
|
141
|
+
}
|
|
142
|
+
);
|
|
143
|
+
return argType === "ID" ? /* @__PURE__ */ React.createElement(QueryArg.ID, { queryArgMeta, value, onChange }) : argType === "Int" ? /* @__PURE__ */ React.createElement(QueryArg.Int, { value, onChange }) : argType === "Float" ? /* @__PURE__ */ React.createElement(QueryArg.Float, { value, onChange }) : argType === "String" ? /* @__PURE__ */ React.createElement(QueryArg.String, { value, onChange }) : argType === "Boolean" ? /* @__PURE__ */ React.createElement(QueryArg.Boolean, { value, onChange }) : argType === "Date" ? /* @__PURE__ */ React.createElement(QueryArg.Date, { value, onChange }) : argType === "JSON" ? /* @__PURE__ */ React.createElement(QueryArg.Json, { value, onChange }) : /* @__PURE__ */ React.createElement(React.Fragment, null);
|
|
144
|
+
}
|
|
145
|
+
const ArgEnum = ({ options, value, onChange, nullable, multiple }) => {
|
|
146
|
+
return /* @__PURE__ */ React.createElement(
|
|
147
|
+
import_Select.Select,
|
|
148
|
+
{
|
|
149
|
+
options: options.map((option) => ({
|
|
150
|
+
label: option.toString(),
|
|
151
|
+
value: option
|
|
152
|
+
})),
|
|
153
|
+
value: value ?? [],
|
|
154
|
+
onChange: (val) => {
|
|
155
|
+
onChange(val);
|
|
156
|
+
},
|
|
157
|
+
multiple
|
|
158
|
+
}
|
|
159
|
+
);
|
|
160
|
+
};
|
|
161
|
+
QueryArg.Enum = ArgEnum;
|
|
162
|
+
const ArgID = ({ queryArgMeta, value, onChange }) => {
|
|
163
|
+
if (!queryArgMeta.ref)
|
|
164
|
+
return /* @__PURE__ */ React.createElement(
|
|
165
|
+
import_Input.Input,
|
|
166
|
+
{
|
|
167
|
+
inputClassName: "w-full",
|
|
168
|
+
value: value ?? "",
|
|
169
|
+
onChange: (value2) => {
|
|
170
|
+
onChange(value2 ? value2 : null);
|
|
171
|
+
},
|
|
172
|
+
validate: (e) => true
|
|
173
|
+
}
|
|
174
|
+
);
|
|
175
|
+
else
|
|
176
|
+
return /* @__PURE__ */ React.createElement(SelectIDWithRef, { queryArgMeta, value, onChange });
|
|
177
|
+
};
|
|
178
|
+
QueryArg.ID = ArgID;
|
|
179
|
+
const SelectIDWithRef = ({ queryArgMeta, value, onChange }) => {
|
|
180
|
+
if (!queryArgMeta.ref)
|
|
181
|
+
throw new Error("No ref in queryArgMeta");
|
|
182
|
+
const [modalOpen, setModalOpen] = (0, import_react.useState)(false);
|
|
183
|
+
const storeUse = import_store.st.use;
|
|
184
|
+
const modelList = storeUse[`${queryArgMeta.ref}List`]();
|
|
185
|
+
const renderOption = queryArgMeta.renderOption ?? ((value2) => value2.id);
|
|
186
|
+
const selectedModel = value ? modelList.get(value) : null;
|
|
187
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
188
|
+
"button",
|
|
189
|
+
{
|
|
190
|
+
className: "btn",
|
|
191
|
+
onClick: () => {
|
|
192
|
+
setModalOpen(true);
|
|
193
|
+
}
|
|
194
|
+
},
|
|
195
|
+
selectedModel ? renderOption(selectedModel) : `Select ${queryArgMeta.ref}`
|
|
196
|
+
), /* @__PURE__ */ React.createElement(
|
|
197
|
+
import_Modal.Modal,
|
|
198
|
+
{
|
|
199
|
+
open: modalOpen,
|
|
200
|
+
onCancel: () => {
|
|
201
|
+
setModalOpen(false);
|
|
202
|
+
}
|
|
203
|
+
},
|
|
204
|
+
/* @__PURE__ */ React.createElement("div", { className: "flex w-full flex-col gap-4 pb-[256px]" }, /* @__PURE__ */ React.createElement(QueryMaker, { sliceName: queryArgMeta.ref }), /* @__PURE__ */ React.createElement(
|
|
205
|
+
import_Select.Select,
|
|
206
|
+
{
|
|
207
|
+
options: modelList.map((model) => ({
|
|
208
|
+
label: renderOption(model),
|
|
209
|
+
value: model.id
|
|
210
|
+
})),
|
|
211
|
+
value,
|
|
212
|
+
onChange: (value2) => {
|
|
213
|
+
onChange(value2);
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
))
|
|
217
|
+
));
|
|
218
|
+
};
|
|
219
|
+
const ArgInt = ({ value, onChange }) => {
|
|
220
|
+
return /* @__PURE__ */ React.createElement(
|
|
221
|
+
import_Input.Input.Number,
|
|
222
|
+
{
|
|
223
|
+
inputClassName: "w-full",
|
|
224
|
+
value,
|
|
225
|
+
onChange: (value2) => {
|
|
226
|
+
onChange(value2 ?? 0);
|
|
227
|
+
},
|
|
228
|
+
validate: (e) => true
|
|
229
|
+
}
|
|
230
|
+
);
|
|
231
|
+
};
|
|
232
|
+
QueryArg.Int = ArgInt;
|
|
233
|
+
const ArgFloat = ({ value, onChange }) => {
|
|
234
|
+
return /* @__PURE__ */ React.createElement(
|
|
235
|
+
import_Input.Input.Number,
|
|
236
|
+
{
|
|
237
|
+
inputClassName: "w-full",
|
|
238
|
+
value,
|
|
239
|
+
onChange: (value2) => {
|
|
240
|
+
onChange(value2 ?? 0);
|
|
241
|
+
},
|
|
242
|
+
validate: (e) => true
|
|
243
|
+
}
|
|
244
|
+
);
|
|
245
|
+
};
|
|
246
|
+
QueryArg.Float = ArgFloat;
|
|
247
|
+
const ArgString = ({ value, onChange }) => {
|
|
248
|
+
return /* @__PURE__ */ React.createElement(
|
|
249
|
+
import_Input.Input,
|
|
250
|
+
{
|
|
251
|
+
inputClassName: "w-full",
|
|
252
|
+
value: value ?? "",
|
|
253
|
+
onChange: (value2) => {
|
|
254
|
+
onChange(value2 ? value2 : null);
|
|
255
|
+
},
|
|
256
|
+
validate: (e) => true
|
|
257
|
+
}
|
|
258
|
+
);
|
|
259
|
+
};
|
|
260
|
+
QueryArg.String = ArgString;
|
|
261
|
+
const ArgBoolean = ({ value, onChange }) => {
|
|
262
|
+
return /* @__PURE__ */ React.createElement(
|
|
263
|
+
import_Input.Input.Checkbox,
|
|
264
|
+
{
|
|
265
|
+
className: "w-full",
|
|
266
|
+
checked: value,
|
|
267
|
+
onChange: (value2) => {
|
|
268
|
+
onChange(value2);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
);
|
|
272
|
+
};
|
|
273
|
+
QueryArg.Boolean = ArgBoolean;
|
|
274
|
+
const ArgDate = ({ value, onChange }) => {
|
|
275
|
+
return /* @__PURE__ */ React.createElement(
|
|
276
|
+
import_DatePicker.DatePicker,
|
|
277
|
+
{
|
|
278
|
+
className: "w-full",
|
|
279
|
+
value,
|
|
280
|
+
onChange: (value2) => {
|
|
281
|
+
onChange(value2);
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
);
|
|
285
|
+
};
|
|
286
|
+
QueryArg.Date = ArgDate;
|
|
287
|
+
const ArgJson = ({ value, onChange }) => {
|
|
288
|
+
return /* @__PURE__ */ React.createElement(
|
|
289
|
+
import_Input.Input.TextArea,
|
|
290
|
+
{
|
|
291
|
+
validate: (e) => true,
|
|
292
|
+
className: "w-full",
|
|
293
|
+
inputClassName: "w-full min-h-[300px]",
|
|
294
|
+
value,
|
|
295
|
+
onPressEnter: (value2) => {
|
|
296
|
+
onChange(value2);
|
|
297
|
+
},
|
|
298
|
+
onChange: (value2) => {
|
|
299
|
+
onChange(value2);
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
);
|
|
303
|
+
};
|
|
304
|
+
QueryArg.Json = ArgJson;
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var TableList_exports = {};
|
|
30
|
+
__export(TableList_exports, {
|
|
31
|
+
default: () => TableList
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(TableList_exports);
|
|
34
|
+
var import_common = require("@akanjs/common");
|
|
35
|
+
var import_next = require("@akanjs/next");
|
|
36
|
+
var import_store = require("@akanjs/store");
|
|
37
|
+
var import_react = __toESM(require("react"));
|
|
38
|
+
var import_Model = require("../Model");
|
|
39
|
+
var import_Table = require("../Table");
|
|
40
|
+
var import_Item = require("./Item");
|
|
41
|
+
var import_Pagination = __toESM(require("./Pagination"));
|
|
42
|
+
function TableList({
|
|
43
|
+
className,
|
|
44
|
+
init,
|
|
45
|
+
queryArgs = [],
|
|
46
|
+
sliceName,
|
|
47
|
+
columns,
|
|
48
|
+
actions,
|
|
49
|
+
renderTemplate,
|
|
50
|
+
renderTitle,
|
|
51
|
+
renderView,
|
|
52
|
+
onItemClick
|
|
53
|
+
}) {
|
|
54
|
+
const { l } = (0, import_next.usePage)();
|
|
55
|
+
const storeUse = import_store.st.use;
|
|
56
|
+
const storeDo = import_store.st.do;
|
|
57
|
+
const storeGet = import_store.st.get;
|
|
58
|
+
const refName = import_store.st.slice[sliceName].refName;
|
|
59
|
+
const [modelName, modelClassName] = [refName, (0, import_common.capitalize)(refName)];
|
|
60
|
+
const names = {
|
|
61
|
+
model: modelName,
|
|
62
|
+
modelId: `${modelName}Id`,
|
|
63
|
+
modelList: `${modelName}List`,
|
|
64
|
+
modelListLoading: `${modelName}ListLoading`,
|
|
65
|
+
initModel: `init${modelClassName}`
|
|
66
|
+
};
|
|
67
|
+
const namesOfSlice = {
|
|
68
|
+
modelList: sliceName.replace(names.model, names.modelList),
|
|
69
|
+
modelListLoading: sliceName.replace(names.model, names.modelListLoading),
|
|
70
|
+
initModel: sliceName.replace(names.model, names.initModel)
|
|
71
|
+
};
|
|
72
|
+
const modelList = storeUse[namesOfSlice.modelList]();
|
|
73
|
+
const modelListLoading = storeUse[namesOfSlice.modelListLoading]();
|
|
74
|
+
const RenderTemplate = ({ id }) => {
|
|
75
|
+
const Edit = renderTemplate;
|
|
76
|
+
return Edit ? /* @__PURE__ */ import_react.default.createElement(Edit, { ...{ [names.modelId]: id } }) : null;
|
|
77
|
+
};
|
|
78
|
+
(0, import_react.useEffect)(() => {
|
|
79
|
+
if (queryArgs.length)
|
|
80
|
+
void storeDo[namesOfSlice.initModel](...queryArgs, init);
|
|
81
|
+
}, []);
|
|
82
|
+
const cols = (0, import_react.useMemo)(() => {
|
|
83
|
+
const firstCol = {
|
|
84
|
+
...(0, import_Item.convToAntdColumn)(columns[0]),
|
|
85
|
+
title: typeof columns[0] !== "string" && columns[0].title ? columns[0].title : l.field(
|
|
86
|
+
sliceName,
|
|
87
|
+
typeof columns[0] === "string" ? columns[0] : columns[0].key
|
|
88
|
+
)
|
|
89
|
+
};
|
|
90
|
+
return [
|
|
91
|
+
{
|
|
92
|
+
...firstCol,
|
|
93
|
+
render: (value, model, idx) => /* @__PURE__ */ import_react.default.createElement("div", { key: `${model.id}-${idx}`, className: "flex items-center" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "mr-2" }, firstCol.render ? firstCol.render(value, model) : value), actions && (typeof actions === "function" ? actions(model, idx) : actions).filter((action) => typeof action === "string").map((action, idx2) => /* @__PURE__ */ import_react.default.createElement(
|
|
94
|
+
import_Item.Action,
|
|
95
|
+
{
|
|
96
|
+
key: `${model.id}-${action}`,
|
|
97
|
+
model,
|
|
98
|
+
action,
|
|
99
|
+
sliceName
|
|
100
|
+
}
|
|
101
|
+
)))
|
|
102
|
+
},
|
|
103
|
+
...columns.slice(1).map((col) => ({
|
|
104
|
+
...(0, import_Item.convToAntdColumn)(col),
|
|
105
|
+
title: typeof col !== "string" && col.title ? col.title : l.field(sliceName, typeof col === "string" ? col : col.key)
|
|
106
|
+
})),
|
|
107
|
+
...actions ? [
|
|
108
|
+
{
|
|
109
|
+
key: "actions",
|
|
110
|
+
dataIndex: "id",
|
|
111
|
+
title: l("shared.actions"),
|
|
112
|
+
render: (_, model, idx) => /* @__PURE__ */ import_react.default.createElement("div", { className: "flex gap-1" }, (typeof actions === "function" ? actions(model, idx) : actions).filter((action) => typeof action !== "string").map((action, idx2) => /* @__PURE__ */ import_react.default.createElement(import_Item.Action, { key: `${model.id}-${idx2}`, model, action, sliceName })))
|
|
113
|
+
}
|
|
114
|
+
] : []
|
|
115
|
+
];
|
|
116
|
+
}, []);
|
|
117
|
+
return /* @__PURE__ */ import_react.default.createElement("div", { className }, /* @__PURE__ */ import_react.default.createElement(
|
|
118
|
+
import_Table.Table,
|
|
119
|
+
{
|
|
120
|
+
dataSource: modelListLoading ? [] : [...modelList],
|
|
121
|
+
columns: cols,
|
|
122
|
+
loading: !!modelListLoading,
|
|
123
|
+
size: "small",
|
|
124
|
+
rowKey: (model) => model.id,
|
|
125
|
+
pagination: false,
|
|
126
|
+
onRow: (model, idx) => ({
|
|
127
|
+
onClick: () => onItemClick?.(model, idx)
|
|
128
|
+
})
|
|
129
|
+
}
|
|
130
|
+
), /* @__PURE__ */ import_react.default.createElement(import_Pagination.default, { sliceName }), !modelListLoading ? modelList.map((model) => /* @__PURE__ */ import_react.default.createElement("div", { key: model.id }, /* @__PURE__ */ import_react.default.createElement(import_Model.Model.EditModal, { id: model.id, sliceName, renderTitle }, /* @__PURE__ */ import_react.default.createElement(RenderTemplate, { id: model.id })), renderView ? /* @__PURE__ */ import_react.default.createElement(
|
|
131
|
+
import_Model.Model.ViewModal,
|
|
132
|
+
{
|
|
133
|
+
id: model.id,
|
|
134
|
+
sliceName,
|
|
135
|
+
renderTitle,
|
|
136
|
+
renderView
|
|
137
|
+
}
|
|
138
|
+
) : null)) : null);
|
|
139
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var Data_exports = {};
|
|
19
|
+
__export(Data_exports, {
|
|
20
|
+
Data: () => Data
|
|
21
|
+
});
|
|
22
|
+
module.exports = __toCommonJS(Data_exports);
|
|
23
|
+
var import_index = require("./index_");
|
|
24
|
+
const Data = {
|
|
25
|
+
CardList: import_index.CardList,
|
|
26
|
+
Dashboard: import_index.Dashboard,
|
|
27
|
+
Insight: import_index.Insight,
|
|
28
|
+
Item: import_index.Item,
|
|
29
|
+
ListContainer: import_index.ListContainer,
|
|
30
|
+
Pagination: import_index.Pagination,
|
|
31
|
+
TableList: import_index.TableList,
|
|
32
|
+
QueryMaker: import_index.QueryMaker
|
|
33
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var index_exports = {};
|
|
30
|
+
__export(index_exports, {
|
|
31
|
+
CardList: () => CardList,
|
|
32
|
+
Dashboard: () => Dashboard,
|
|
33
|
+
Insight: () => Insight,
|
|
34
|
+
Item: () => Item,
|
|
35
|
+
ListContainer: () => ListContainer,
|
|
36
|
+
Pagination: () => Pagination,
|
|
37
|
+
QueryMaker: () => QueryMaker,
|
|
38
|
+
TableList: () => TableList
|
|
39
|
+
});
|
|
40
|
+
module.exports = __toCommonJS(index_exports);
|
|
41
|
+
var import_next = require("@akanjs/next");
|
|
42
|
+
const CardList = (0, import_next.lazy)(() => import("./CardList"));
|
|
43
|
+
const Dashboard = (0, import_next.lazy)(() => import("./Dashboard"));
|
|
44
|
+
const Insight = (0, import_next.lazy)(() => import("./Insight"));
|
|
45
|
+
const Item = (0, import_next.lazy)(() => import("./Item"));
|
|
46
|
+
const ListContainer = (0, import_next.lazy)(() => import("./ListContainer"));
|
|
47
|
+
const Pagination = (0, import_next.lazy)(() => import("./Pagination"));
|
|
48
|
+
const TableList = (0, import_next.lazy)(() => import("./TableList"));
|
|
49
|
+
const QueryMaker = (0, import_next.lazy)(() => import("./QueryMaker"));
|