@lattice-php/lattice 0.60.0 → 0.62.0
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/dist/create-app.js +3 -2
- package/dist/create-app.js.map +1 -1
- package/dist/event-bridge.js +1 -1
- package/dist/fragments/fragment.js +1 -1
- package/dist/index.d.ts +1 -3
- package/dist/index.js +3 -7
- package/dist/inertia-navigation.d.ts +6 -0
- package/dist/inertia-navigation.js +28 -4
- package/dist/inertia-navigation.js.map +1 -1
- package/dist/lattice.css +16 -0
- package/dist/layout/components/outlet.js.map +1 -1
- package/dist/layout/components/schema-layout.js +1 -1
- package/dist/layout/components/schema-layout.js.map +1 -1
- package/dist/layout/index.d.ts +0 -1
- package/dist/layout/index.js +1 -2
- package/dist/layout/plugin.js +1 -19
- package/dist/layout/plugin.js.map +1 -1
- package/dist/notifications/components/empty-state.js +1 -1
- package/dist/notifications/components/notification-item.js +3 -3
- package/dist/notifications/components/notification-item.js.map +1 -1
- package/dist/notifications/components/notification-list.js +1 -1
- package/dist/notifications/components/notification-list.js.map +1 -1
- package/dist/notifications/components/notifications-echo.js.map +1 -1
- package/dist/notifications/components/notifications-sheet.js +2 -2
- package/dist/notifications/components/notifications-sheet.js.map +1 -1
- package/dist/notifications/components/notifications.js +4 -4
- package/dist/notifications/components/notifications.js.map +1 -1
- package/dist/page.js +2 -1
- package/dist/page.js.map +1 -1
- package/dist/provider-base.d.ts +3 -1
- package/dist/provider-base.js +6 -5
- package/dist/provider-base.js.map +1 -1
- package/dist/realtime/subscriptions.js +3 -3
- package/dist/realtime/subscriptions.js.map +1 -1
- package/dist/remote/components/data-list.js +1 -1
- package/dist/runtime.d.ts +4 -4
- package/dist/runtime.js +6 -9
- package/dist/types/generated.d.ts +5 -39
- package/dist-standalone/chunks/chart-view-CJZkJAHB.js +59 -0
- package/dist-standalone/chunks/{date-picker-field-D_73rR_m.js → date-picker-view-p9mSMvwV.js} +1 -1
- package/dist-standalone/chunks/dist-Dd8dg4q5.js +106 -0
- package/dist-standalone/chunks/{field-CGZayHGR.js → pattern-input-view-CCPpYThT.js} +1 -1
- package/dist-standalone/chunks/rich-editor-view-CBCDtSzk.js +53 -0
- package/dist-standalone/chunks/runtime-DI3n1MuN.js +162 -0
- package/dist-standalone/chunks/{subscriptions-CJ3H8KiC.js → subscriptions-C1LRT5gZ.js} +1 -1
- package/dist-standalone/lattice.css +1 -1
- package/dist-standalone/lattice.js +1 -1
- package/dist-standalone/manifest.json +1 -1
- package/dist-standalone/runtime.js +1 -1
- package/dist-standalone/sprite.svg +1 -1
- package/package.json +7 -12
- package/dist/layout/components/breadcrumbs.d.ts +0 -3
- package/dist/layout/components/breadcrumbs.js +0 -41
- package/dist/layout/components/breadcrumbs.js.map +0 -1
- package/dist/layout/components/callouts.d.ts +0 -15
- package/dist/layout/components/callouts.js +0 -89
- package/dist/layout/components/callouts.js.map +0 -1
- package/dist/layout/components/dropdown.d.ts +0 -3
- package/dist/layout/components/dropdown.js +0 -24
- package/dist/layout/components/dropdown.js.map +0 -1
- package/dist/layout/components/menu-item.d.ts +0 -3
- package/dist/layout/components/menu-item.js +0 -137
- package/dist/layout/components/menu-item.js.map +0 -1
- package/dist/layout/components/menu.d.ts +0 -3
- package/dist/layout/components/menu.js +0 -14
- package/dist/layout/components/menu.js.map +0 -1
- package/dist/layout/components/popover.d.ts +0 -17
- package/dist/layout/components/popover.js +0 -46
- package/dist/layout/components/popover.js.map +0 -1
- package/dist/layout/components/sidebar-footer.d.ts +0 -3
- package/dist/layout/components/sidebar-footer.js +0 -12
- package/dist/layout/components/sidebar-footer.js.map +0 -1
- package/dist/layout/components/sidebar.d.ts +0 -3
- package/dist/layout/components/sidebar.js +0 -55
- package/dist/layout/components/sidebar.js.map +0 -1
- package/dist/layout/components/topbar.d.ts +0 -3
- package/dist/layout/components/topbar.js +0 -16
- package/dist/layout/components/topbar.js.map +0 -1
- package/dist/toast/callout.d.ts +0 -5
- package/dist/toast/callout.js +0 -31
- package/dist/toast/callout.js.map +0 -1
- package/dist/toast/index.d.ts +0 -6
- package/dist/toast/index.js +0 -5
- package/dist/toast/toast.d.ts +0 -7
- package/dist/toast/toast.js +0 -47
- package/dist/toast/toast.js.map +0 -1
- package/dist/toast/toaster.d.ts +0 -3
- package/dist/toast/toaster.js +0 -63
- package/dist/toast/toaster.js.map +0 -1
- package/dist/toast/variant-styles.d.ts +0 -6
- package/dist/toast/variant-styles.js +0 -51
- package/dist/toast/variant-styles.js.map +0 -1
- package/dist-standalone/chunks/chart-view-BxNPMybJ.js +0 -59
- package/dist-standalone/chunks/dist-DAHNiLp2.js +0 -106
- package/dist-standalone/chunks/rich-editor-field-Cp8zPFKl.js +0 -53
- package/dist-standalone/chunks/runtime-DGQM7tBp.js +0 -162
package/dist/provider-base.js
CHANGED
|
@@ -1,23 +1,24 @@
|
|
|
1
1
|
import { updateAppearance } from "./appearance/index.js";
|
|
2
|
-
import { Toaster } from "./toast/toaster.js";
|
|
3
2
|
import { useFlashEffects } from "./effects/use-flash-effects.js";
|
|
4
3
|
import { EventBridge } from "./event-bridge.js";
|
|
5
|
-
import {
|
|
4
|
+
import { useCloseModalsOnNavigate, useInertiaNavigation } from "./inertia-navigation.js";
|
|
6
5
|
import { RegistryProvider } from "@lattice-php/core/registry-context";
|
|
7
6
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
7
|
import { ActionInteractionProvider } from "@lattice-php/action/components/action-trigger-provider";
|
|
9
8
|
import { NavigationProvider } from "@lattice-php/ui/navigation";
|
|
10
|
-
import { ModalProvider } from "@lattice-php/ui/modal";
|
|
9
|
+
import { ModalProvider } from "@lattice-php/ui/components/modal/modal-host";
|
|
11
10
|
import { SpriteProvider } from "@lattice-php/ui/icons/sprite";
|
|
11
|
+
import { Toaster } from "@lattice-php/ui/toast";
|
|
12
12
|
//#region resources/js/provider-base.tsx
|
|
13
13
|
var defaultSprite = { href: "" };
|
|
14
|
-
function ProviderBase({ children, registry, sprite = defaultSprite, toaster = true }) {
|
|
14
|
+
function ProviderBase({ children, initialUrl, registry, sprite = defaultSprite, toaster = true }) {
|
|
15
15
|
useFlashEffects();
|
|
16
16
|
useCloseModalsOnNavigate();
|
|
17
|
+
const navigation = useInertiaNavigation(initialUrl);
|
|
17
18
|
return /* @__PURE__ */ jsx(RegistryProvider, {
|
|
18
19
|
registry,
|
|
19
20
|
children: /* @__PURE__ */ jsx(NavigationProvider, {
|
|
20
|
-
adapter:
|
|
21
|
+
adapter: navigation,
|
|
21
22
|
children: /* @__PURE__ */ jsx(ActionInteractionProvider, { children: /* @__PURE__ */ jsx(SpriteProvider, {
|
|
22
23
|
sprite,
|
|
23
24
|
children: /* @__PURE__ */ jsxs(ModalProvider, { children: [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"provider-base.js","names":[],"sources":["../resources/js/provider-base.tsx"],"sourcesContent":["import type { ReactNode } from \"react\";\nimport { ActionInteractionProvider } from \"@lattice-php/action/components/action-trigger-provider\";\nimport type { Registry } from \"@lattice-php/core/registry\";\nimport { RegistryProvider } from \"@lattice-php/core/registry-context\";\nimport { useFlashEffects } from \"./effects/use-flash-effects\";\nimport { NavigationProvider } from \"@lattice-php/ui/navigation\";\nimport { ModalProvider } from \"@lattice-php/ui/modal\";\nimport { EventBridge } from \"./event-bridge\";\nimport {
|
|
1
|
+
{"version":3,"file":"provider-base.js","names":[],"sources":["../resources/js/provider-base.tsx"],"sourcesContent":["import type { ReactNode } from \"react\";\nimport { ActionInteractionProvider } from \"@lattice-php/action/components/action-trigger-provider\";\nimport type { Registry } from \"@lattice-php/core/registry\";\nimport { RegistryProvider } from \"@lattice-php/core/registry-context\";\nimport { useFlashEffects } from \"./effects/use-flash-effects\";\nimport { NavigationProvider } from \"@lattice-php/ui/navigation\";\nimport { ModalProvider } from \"@lattice-php/ui/components/modal/modal-host\";\nimport { EventBridge } from \"./event-bridge\";\nimport { useCloseModalsOnNavigate, useInertiaNavigation } from \"./inertia-navigation\";\nimport type { SpriteValue } from \"@lattice-php/ui/icons/sprite\";\nimport { SpriteProvider } from \"@lattice-php/ui/icons/sprite\";\nimport { Toaster } from \"@lattice-php/ui/toast\";\nimport { updateAppearance } from \"./appearance\";\n\nconst defaultSprite: SpriteValue = { href: \"\" };\n\nexport type ProviderBaseProps = {\n children: ReactNode;\n /** The url of the page being rendered, so the first render already knows it (SSR included). */\n initialUrl?: string;\n registry: Registry;\n sprite?: SpriteValue;\n toaster?: boolean;\n};\n\nexport function ProviderBase({\n children,\n initialUrl,\n registry,\n sprite = defaultSprite,\n toaster = true,\n}: ProviderBaseProps) {\n useFlashEffects();\n useCloseModalsOnNavigate();\n const navigation = useInertiaNavigation(initialUrl);\n\n return (\n <RegistryProvider registry={registry}>\n <NavigationProvider adapter={navigation}>\n <ActionInteractionProvider>\n <SpriteProvider sprite={sprite}>\n <ModalProvider>\n {children}\n <EventBridge onAppearanceChange={updateAppearance} />\n {toaster ? <Toaster /> : null}\n </ModalProvider>\n </SpriteProvider>\n </ActionInteractionProvider>\n </NavigationProvider>\n </RegistryProvider>\n );\n}\n"],"mappings":";;;;;;;;;;;;AAcA,IAAM,gBAA6B,EAAE,MAAM,GAAG;AAW9C,SAAgB,aAAa,EAC3B,UACA,YACA,UACA,SAAS,eACT,UAAU,QACU;CACpB,gBAAgB;CAChB,yBAAyB;CACzB,MAAM,aAAa,qBAAqB,UAAU;CAElD,OACE,oBAAC,kBAAD;EAA4B;EAC1B,UAAA,oBAAC,oBAAD;GAAoB,SAAS;GAC3B,UAAA,oBAAC,2BAAD,EAAA,UACE,oBAAC,gBAAD;IAAwB;IACtB,UAAA,qBAAC,eAAD,EAAA,UAAA;KACG;KACD,oBAAC,aAAD,EAAa,oBAAoB,iBAAmB,CAAA;KACnD,UAAU,oBAAC,SAAD,CAAU,CAAA,IAAI;IACZ,EAAA,CAAA;GACD,CAAA,EACS,CAAA;EACT,CAAA;CACJ,CAAA;AAEtB"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { buildEffects } from "./build-effects.js";
|
|
2
2
|
import { useCallback } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import { Fragment as Fragment$1, jsx } from "react/jsx-runtime";
|
|
3
|
+
import { Fragment, jsx } from "react/jsx-runtime";
|
|
5
4
|
import { useEffectDispatcher } from "@lattice-php/ui/effects/use-effect-dispatcher";
|
|
5
|
+
import { useT } from "@lattice-php/ui/i18n";
|
|
6
6
|
import { useEcho, useEchoPresence, useEchoPublic } from "@laravel/echo-react";
|
|
7
7
|
//#region resources/js/realtime/subscriptions.tsx
|
|
8
8
|
function useListenerHandler(listener) {
|
|
@@ -37,7 +37,7 @@ function Listener({ listener }) {
|
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
39
|
function Subscriptions({ listeners }) {
|
|
40
|
-
return /* @__PURE__ */ jsx(Fragment
|
|
40
|
+
return /* @__PURE__ */ jsx(Fragment, { children: listeners.map((listener, index) => /* @__PURE__ */ jsx(Listener, { listener }, `${listener.visibility}:${listener.channel}:${index}`)) });
|
|
41
41
|
}
|
|
42
42
|
//#endregion
|
|
43
43
|
export { Subscriptions as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"subscriptions.js","names":[],"sources":["../../resources/js/realtime/subscriptions.tsx"],"sourcesContent":["import { useEcho, useEchoPresence, useEchoPublic } from \"@laravel/echo-react\";\nimport { useCallback } from \"react\";\nimport { useEffectDispatcher } from \"@lattice-php/ui/effects/use-effect-dispatcher\";\nimport { useT } from \"@lattice-php/ui/i18n\";\nimport { buildEffects } from \"./build-effects\";\nimport type { Listen } from \"@lattice-php/lattice/types/generated\";\n\nfunction useListenerHandler(listener: Listen): (payload: unknown) => void {\n const { t } = useT(\"lattice\");\n const dispatch = useEffectDispatcher();\n\n return useCallback(\n (payload: unknown) => {\n const data = (typeof payload === \"object\" && payload !== null ? payload : {}) as Record<\n string,\n unknown\n >;\n dispatch(buildEffects(listener.effects, data, t));\n },\n [dispatch, listener, t],\n );\n}\n\nfunction PublicListener({ listener }: { listener: Listen }) {\n useEchoPublic(listener.channel, listener.events, useListenerHandler(listener));\n return null;\n}\n\nfunction PrivateListener({ listener }: { listener: Listen }) {\n useEcho(listener.channel, listener.events, useListenerHandler(listener));\n return null;\n}\n\nfunction PresenceListener({ listener }: { listener: Listen }) {\n useEchoPresence(listener.channel, listener.events, useListenerHandler(listener));\n return null;\n}\n\nfunction Listener({ listener }: { listener: Listen }) {\n switch (listener.visibility) {\n case \"private\":\n return <PrivateListener listener={listener} />;\n case \"presence\":\n return <PresenceListener listener={listener} />;\n default:\n return <PublicListener listener={listener} />;\n }\n}\n\nexport default function Subscriptions({ listeners }: { listeners: Listen[] }) {\n return (\n <>\n {listeners.map((listener, index) => (\n <Listener key={`${listener.visibility}:${listener.channel}:${index}`} listener={listener} />\n ))}\n </>\n );\n}\n"],"mappings":";;;;;;;AAOA,SAAS,mBAAmB,UAA8C;CACxE,MAAM,EAAE,MAAM,KAAK,SAAS;CAC5B,MAAM,WAAW,oBAAoB;CAErC,OAAO,aACJ,YAAqB;EACpB,MAAM,OAAQ,OAAO,YAAY,YAAY,YAAY,OAAO,UAAU,CAAC;EAI3E,SAAS,aAAa,SAAS,SAAS,MAAM,CAAC,CAAC;CAClD,GACA;EAAC;EAAU;EAAU;CAAC,CACxB;AACF;AAEA,SAAS,eAAe,EAAE,YAAkC;CAC1D,cAAc,SAAS,SAAS,SAAS,QAAQ,mBAAmB,QAAQ,CAAC;CAC7E,OAAO;AACT;AAEA,SAAS,gBAAgB,EAAE,YAAkC;CAC3D,QAAQ,SAAS,SAAS,SAAS,QAAQ,mBAAmB,QAAQ,CAAC;CACvE,OAAO;AACT;AAEA,SAAS,iBAAiB,EAAE,YAAkC;CAC5D,gBAAgB,SAAS,SAAS,SAAS,QAAQ,mBAAmB,QAAQ,CAAC;CAC/E,OAAO;AACT;AAEA,SAAS,SAAS,EAAE,YAAkC;CACpD,QAAQ,SAAS,YAAjB;EACE,KAAK,WACH,OAAO,oBAAC,iBAAD,EAA2B,SAAW,CAAA;EAC/C,KAAK,YACH,OAAO,oBAAC,kBAAD,EAA4B,SAAW,CAAA;EAChD,SACE,OAAO,oBAAC,gBAAD,EAA0B,SAAW,CAAA;CAChD;AACF;AAEA,SAAwB,cAAc,EAAE,aAAsC;CAC5E,OACE,oBAAA,
|
|
1
|
+
{"version":3,"file":"subscriptions.js","names":[],"sources":["../../resources/js/realtime/subscriptions.tsx"],"sourcesContent":["import { useEcho, useEchoPresence, useEchoPublic } from \"@laravel/echo-react\";\nimport { useCallback } from \"react\";\nimport { useEffectDispatcher } from \"@lattice-php/ui/effects/use-effect-dispatcher\";\nimport { useT } from \"@lattice-php/ui/i18n\";\nimport { buildEffects } from \"./build-effects\";\nimport type { Listen } from \"@lattice-php/lattice/types/generated\";\n\nfunction useListenerHandler(listener: Listen): (payload: unknown) => void {\n const { t } = useT(\"lattice\");\n const dispatch = useEffectDispatcher();\n\n return useCallback(\n (payload: unknown) => {\n const data = (typeof payload === \"object\" && payload !== null ? payload : {}) as Record<\n string,\n unknown\n >;\n dispatch(buildEffects(listener.effects, data, t));\n },\n [dispatch, listener, t],\n );\n}\n\nfunction PublicListener({ listener }: { listener: Listen }) {\n useEchoPublic(listener.channel, listener.events, useListenerHandler(listener));\n return null;\n}\n\nfunction PrivateListener({ listener }: { listener: Listen }) {\n useEcho(listener.channel, listener.events, useListenerHandler(listener));\n return null;\n}\n\nfunction PresenceListener({ listener }: { listener: Listen }) {\n useEchoPresence(listener.channel, listener.events, useListenerHandler(listener));\n return null;\n}\n\nfunction Listener({ listener }: { listener: Listen }) {\n switch (listener.visibility) {\n case \"private\":\n return <PrivateListener listener={listener} />;\n case \"presence\":\n return <PresenceListener listener={listener} />;\n default:\n return <PublicListener listener={listener} />;\n }\n}\n\nexport default function Subscriptions({ listeners }: { listeners: Listen[] }) {\n return (\n <>\n {listeners.map((listener, index) => (\n <Listener key={`${listener.visibility}:${listener.channel}:${index}`} listener={listener} />\n ))}\n </>\n );\n}\n"],"mappings":";;;;;;;AAOA,SAAS,mBAAmB,UAA8C;CACxE,MAAM,EAAE,MAAM,KAAK,SAAS;CAC5B,MAAM,WAAW,oBAAoB;CAErC,OAAO,aACJ,YAAqB;EACpB,MAAM,OAAQ,OAAO,YAAY,YAAY,YAAY,OAAO,UAAU,CAAC;EAI3E,SAAS,aAAa,SAAS,SAAS,MAAM,CAAC,CAAC;CAClD,GACA;EAAC;EAAU;EAAU;CAAC,CACxB;AACF;AAEA,SAAS,eAAe,EAAE,YAAkC;CAC1D,cAAc,SAAS,SAAS,SAAS,QAAQ,mBAAmB,QAAQ,CAAC;CAC7E,OAAO;AACT;AAEA,SAAS,gBAAgB,EAAE,YAAkC;CAC3D,QAAQ,SAAS,SAAS,SAAS,QAAQ,mBAAmB,QAAQ,CAAC;CACvE,OAAO;AACT;AAEA,SAAS,iBAAiB,EAAE,YAAkC;CAC5D,gBAAgB,SAAS,SAAS,SAAS,QAAQ,mBAAmB,QAAQ,CAAC;CAC/E,OAAO;AACT;AAEA,SAAS,SAAS,EAAE,YAAkC;CACpD,QAAQ,SAAS,YAAjB;EACE,KAAK,WACH,OAAO,oBAAC,iBAAD,EAA2B,SAAW,CAAA;EAC/C,KAAK,YACH,OAAO,oBAAC,kBAAD,EAA4B,SAAW,CAAA;EAChD,SACE,OAAO,oBAAC,gBAAD,EAA0B,SAAW,CAAA;CAChD;AACF;AAEA,SAAwB,cAAc,EAAE,aAAsC;CAC5E,OACE,oBAAA,UAAA,EAAA,UACG,UAAU,KAAK,UAAU,UACxB,oBAAC,UAAD,EAAgF,SAAW,GAA5E,GAAG,SAAS,WAAW,GAAG,SAAS,QAAQ,GAAG,OAA8B,CAC5F,EACD,CAAA;AAEN"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { useEffect, useState } from "react";
|
|
2
2
|
import { remoteJson } from "@lattice-php/core/api";
|
|
3
3
|
import { materializeSchema } from "@lattice-php/core/materialize";
|
|
4
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
5
|
import { Renderer } from "@lattice-php/core/renderer";
|
|
5
6
|
import { useT } from "@lattice-php/ui/i18n";
|
|
6
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
7
|
//#region resources/js/remote/components/data-list.tsx
|
|
8
8
|
function label(value) {
|
|
9
9
|
if (value === null || value === void 0) return "";
|
package/dist/runtime.d.ts
CHANGED
|
@@ -11,15 +11,15 @@ export { RenderNode } from '@lattice-php/core/renderer';
|
|
|
11
11
|
export { coerceColor, toneProps } from '@lattice-php/ui/lib/color';
|
|
12
12
|
export { nodeIdentity } from '@lattice-php/core/test-id';
|
|
13
13
|
export { requestSignedUpload, xhrTransfer } from '@lattice-php/core/upload';
|
|
14
|
-
export { SimpleField } from '@lattice-php/form/components/
|
|
14
|
+
export { SimpleField } from '@lattice-php/form/components/base/simple-field';
|
|
15
15
|
export { RICH_EDITOR_EXTENSION, ToolbarIconButton } from '@lattice-php/form/rich-editor';
|
|
16
16
|
export * from '@lattice-php/form/toolkit';
|
|
17
17
|
export { useTable } from '@lattice-php/table/hooks/use-table';
|
|
18
18
|
export { useTableSelection } from '@lattice-php/table/hooks/use-table-selection';
|
|
19
19
|
export { getBulkActionNodes } from '@lattice-php/table/lib/bulk';
|
|
20
20
|
export { useAction } from '@lattice-php/action/hooks/use-action';
|
|
21
|
-
export { MODAL_MISSING_ERROR, useEmbeddedModal, useModal } from '@lattice-php/ui/modal';
|
|
22
|
-
export { Badge, Button,
|
|
21
|
+
export { MODAL_MISSING_ERROR, useEmbeddedModal, useModal, } from '@lattice-php/ui/components/modal/modal-host';
|
|
22
|
+
export { Badge, Button, cn, CodeBlock, ConfirmDialog, CopyButton, Dialog, DialogContent, DialogHeader, DialogTitle, formatDateValue, IconButton, InfoTooltip, NativeSelect, PreviewableImage, SegmentedControl, Spinner, useDebouncedCallback, useFormatContext, usePersistentState, } from '@lattice-php/ui';
|
|
23
|
+
export { Checkbox, Combobox, Input, Label, Textarea } from '@lattice-php/form';
|
|
23
24
|
export * from '@lattice-php/ui/i18n';
|
|
24
25
|
export { announce, attachTreeItemInstruction, combine, draggable, dropTargetForElements, extractTreeItemInstruction, } from './dnd/index.js';
|
|
25
|
-
export type { Variant } from './toast/index.js';
|
package/dist/runtime.js
CHANGED
|
@@ -1,8 +1,4 @@
|
|
|
1
1
|
import { initializeAppearance, updateAppearance, useAppearance } from "./appearance/index.js";
|
|
2
|
-
import { onToast } from "./toast/toast.js";
|
|
3
|
-
import { onCallout } from "./toast/callout.js";
|
|
4
|
-
import { Toaster } from "./toast/toaster.js";
|
|
5
|
-
import Callouts from "./layout/components/callouts.js";
|
|
6
2
|
import { OutletProvider, useOutlet } from "./layout/hooks/context.js";
|
|
7
3
|
import { layoutComponents } from "./layout/plugin.js";
|
|
8
4
|
import SchemaLayout from "./layout/components/schema-layout.js";
|
|
@@ -19,15 +15,16 @@ import { router } from "@inertiajs/react";
|
|
|
19
15
|
import { apiFetch, apiJson, setRefRefreshEndpoint, xsrfToken } from "@lattice-php/core/api";
|
|
20
16
|
import { useExtensionRegistry } from "@lattice-php/core/registry-context";
|
|
21
17
|
import { RenderNode } from "@lattice-php/core/renderer";
|
|
22
|
-
import { nodeIdentity } from "@lattice-php/core/test-id";
|
|
23
18
|
import { NavigationProvider, defaultNavigation, useNavigation } from "@lattice-php/ui/navigation";
|
|
24
|
-
import { MODAL_MISSING_ERROR, useEmbeddedModal, useModal } from "@lattice-php/ui/modal";
|
|
25
|
-
import {
|
|
19
|
+
import { MODAL_MISSING_ERROR, useEmbeddedModal, useModal } from "@lattice-php/ui/components/modal/modal-host";
|
|
20
|
+
import { Checkbox, Combobox, Input, Label, Textarea } from "@lattice-php/form";
|
|
21
|
+
import { Badge, Button, CodeBlock, ConfirmDialog, CopyButton, Dialog, DialogContent, DialogHeader, DialogTitle, IconButton, InfoTooltip, NativeSelect, PreviewableImage, SegmentedControl, Spinner, cn, formatDateValue, useDebouncedCallback, useFormatContext, usePersistentState } from "@lattice-php/ui";
|
|
26
22
|
import { callAction, runAction, useCallAction } from "@lattice-php/action";
|
|
27
23
|
import { ActionConfirmOverlay } from "@lattice-php/action/components/action-confirm-overlay";
|
|
28
24
|
import { coerceColor, toneProps } from "@lattice-php/ui/lib/color";
|
|
25
|
+
import { nodeIdentity } from "@lattice-php/core/test-id";
|
|
29
26
|
import { requestSignedUpload, xhrTransfer } from "@lattice-php/core/upload";
|
|
30
|
-
import { SimpleField } from "@lattice-php/form/components/
|
|
27
|
+
import { SimpleField } from "@lattice-php/form/components/base/simple-field";
|
|
31
28
|
import { RICH_EDITOR_EXTENSION, ToolbarIconButton } from "@lattice-php/form/rich-editor";
|
|
32
29
|
import { useTable } from "@lattice-php/table/hooks/use-table";
|
|
33
30
|
import { useTableSelection } from "@lattice-php/table/hooks/use-table-selection";
|
|
@@ -35,4 +32,4 @@ import { getBulkActionNodes } from "@lattice-php/table/lib/bulk";
|
|
|
35
32
|
import { useAction } from "@lattice-php/action/hooks/use-action";
|
|
36
33
|
export * from "@lattice-php/ui/i18n";
|
|
37
34
|
export * from "@lattice-php/form/toolkit";
|
|
38
|
-
export { ActionConfirmOverlay, Badge, Button,
|
|
35
|
+
export { ActionConfirmOverlay, Badge, Button, Checkbox, CodeBlock, Combobox, ConfirmDialog, CopyButton, Dialog, DialogContent, DialogHeader, DialogTitle, EventBridge, Icon, IconButton, IconRenderer, IconRendererProvider, InfoTooltip, Input, LATTICE_EVENT, LATTICE_REF_HEADER, Label, MODAL_MISSING_ERROR, NativeSelect, NavigationProvider, OutletProvider, PreviewableImage, Provider, RICH_EDITOR_EXTENSION, RealtimeListeners, RenderNode, Renderer, SchemaLayout, SegmentedControl, SimpleField, Spinner, SpriteProvider, Textarea, ToolbarIconButton, announce, apiFetch, apiJson, attachTreeItemInstruction, builtinEffectHandlers, callAction, cn, coerceColor, columnCell, combine, copyToClipboard, createLatticeApp, createLayoutResolver, createPageResolver, createRegistry, defaultNavigation, dispatchActionError, dispatchEffects, draggable, dropTargetForElements, eagerComponent, effectHandler, extendRegistry, extractTreeItemInstruction, formatDateValue, getActionEffects, getBulkActionNodes, inertiaNavigation, initializeAppearance, isActionEffect, layoutComponents, lazyComponent, loadPluginModules, mergeEffectHandlers, navigationPlugin, nodeIdentity, pageComponentName, registry, requestSignedUpload, router, runAction, setRefRefreshEndpoint, toneProps, updateAppearance, useAction, useAppearance, useCallAction, useColumnRegistry, useComponentRegistry, useDebouncedCallback, useEffectDispatcher, useEmbeddedModal, useExtensionRegistry, useFormatContext, useModal, useNavigation, useOutlet, usePersistentState, useTable, useTableSelection, withHeaders, withRefHeader, withVisitHeaders, xhrTransfer, xsrfToken };
|
|
@@ -1,36 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Breadcrumb, Node, RemoteAccess } from '@lattice-php/core';
|
|
2
|
+
import { Size, Translatable, Variant } from '@lattice-php/ui';
|
|
3
3
|
import { Effect } from '@lattice-php/ui/effects/types';
|
|
4
4
|
export type ActionNodeType = "action" | "action.bulk" | "action.group";
|
|
5
|
-
export type Breadcrumbs = Record<string, never>;
|
|
6
5
|
export type CalendarNodeType = "calendar";
|
|
7
|
-
export type Callouts = Record<string, never>;
|
|
8
6
|
export type ChannelVisibility = "public" | "private" | "presence";
|
|
9
7
|
export type ChatNodeType = "chat.box" | "chat.part.text" | "chat.part.tool-call";
|
|
10
8
|
export type ColumnNodeType = "column.badge" | "column.boolean" | "column.icon" | "column.image" | "column.money" | "column.number" | "column.stack" | "column.text";
|
|
11
9
|
export type ComponentPropsMap = {
|
|
12
|
-
breadcrumbs: Breadcrumbs;
|
|
13
|
-
callouts: Callouts;
|
|
14
|
-
dropdown: Dropdown;
|
|
15
10
|
fragment: Fragment;
|
|
16
|
-
menu: Menu;
|
|
17
|
-
"menu-item": MenuItem;
|
|
18
11
|
notifications: Notifications;
|
|
19
12
|
outlet: Outlet;
|
|
20
13
|
"remote.data-list": DataList;
|
|
21
|
-
sidebar: Sidebar;
|
|
22
|
-
"sidebar.footer": SidebarFooter;
|
|
23
|
-
topbar: Topbar;
|
|
24
14
|
};
|
|
25
15
|
export type DataList = {
|
|
26
16
|
dataEndpoint: string | null;
|
|
27
17
|
emptyLabel: string | null;
|
|
28
18
|
remote: RemoteAccess | null;
|
|
29
19
|
};
|
|
30
|
-
export type Dropdown = {
|
|
31
|
-
placement: Placement;
|
|
32
|
-
trigger: Node[];
|
|
33
|
-
};
|
|
34
20
|
export type FilterNodeType = "filter.date-range" | "filter.media-type" | "filter.select" | "filter.ternary" | "filter.toggle";
|
|
35
21
|
export type FormFieldNodeType = "field.builder" | "field.checkbox" | "field.choice" | "field.color-picker" | "field.date-input" | "field.date-time-input" | "field.file-upload" | "field.hidden-input" | "field.media-picker" | "field.number-input" | "field.otp" | "field.password-input" | "field.pattern-input" | "field.repeater" | "field.rich-editor" | "field.select" | "field.text-input" | "field.textarea" | "field.time-input" | "field.toggle" | "field.tree" | "wizard" | "wizard-step";
|
|
36
22
|
export type FormNodeType = "field.builder" | "field.checkbox" | "field.choice" | "field.color-picker" | "field.date-input" | "field.date-time-input" | "field.file-upload" | "field.hidden-input" | "field.media-picker" | "field.number-input" | "field.otp" | "field.password-input" | "field.pattern-input" | "field.repeater" | "field.rich-editor" | "field.select" | "field.text-input" | "field.textarea" | "field.time-input" | "field.toggle" | "field.tree" | "form" | "wizard" | "wizard-step";
|
|
@@ -51,7 +37,7 @@ export type I18nConfig = {
|
|
|
51
37
|
readonly saveMissing: boolean;
|
|
52
38
|
readonly timezone: string | null;
|
|
53
39
|
};
|
|
54
|
-
export type LayoutNodeType = "
|
|
40
|
+
export type LayoutNodeType = "outlet";
|
|
55
41
|
export type Listen = {
|
|
56
42
|
readonly channel: string;
|
|
57
43
|
effects: Effect[];
|
|
@@ -60,19 +46,7 @@ export type Listen = {
|
|
|
60
46
|
};
|
|
61
47
|
export type MapNodeType = "map";
|
|
62
48
|
export type MediumNodeType = "media.library";
|
|
63
|
-
export type
|
|
64
|
-
export type MenuItem = {
|
|
65
|
-
action: Node | null;
|
|
66
|
-
effects: Effect[];
|
|
67
|
-
href: string | null;
|
|
68
|
-
icon: string | null;
|
|
69
|
-
label: string | null;
|
|
70
|
-
method: HttpMethod | null;
|
|
71
|
-
modal: Node<"modal"> | null;
|
|
72
|
-
prefix: Affix | null;
|
|
73
|
-
suffix: Affix | null;
|
|
74
|
-
};
|
|
75
|
-
export type NodeType = "action" | "action.bulk" | "action.group" | "api-reference" | "avatar" | "badge" | "breadcrumbs" | "button" | "calendar" | "callouts" | "card" | "chart" | "chat.box" | "chat.part.text" | "chat.part.tool-call" | "code-block" | "collapsible" | "description-list" | "dropdown" | "entry.badge" | "entry.boolean" | "entry.component" | "entry.date" | "entry.text" | "field.builder" | "field.checkbox" | "field.choice" | "field.color-picker" | "field.date-input" | "field.date-time-input" | "field.file-upload" | "field.hidden-input" | "field.media-picker" | "field.number-input" | "field.otp" | "field.password-input" | "field.pattern-input" | "field.repeater" | "field.rich-editor" | "field.select" | "field.text-input" | "field.textarea" | "field.time-input" | "field.toggle" | "field.tree" | "floating-panel" | "form" | "fragment" | "grid" | "heading" | "icon" | "image" | "link" | "map" | "media.library" | "menu" | "menu-item" | "modal" | "notifications" | "outlet" | "pdf" | "progress" | "raw-block" | "remote.data-list" | "search.box" | "search.categories" | "search.input" | "search.preview" | "search.recent" | "search.results" | "section" | "segmented-control" | "separator" | "sidebar" | "sidebar.footer" | "signature" | "stack" | "tab" | "table" | "tabs" | "text" | "tooltip" | "topbar" | "tree" | "wizard" | "wizard-step";
|
|
49
|
+
export type NodeType = "action" | "action.bulk" | "action.group" | "api-reference" | "avatar" | "badge" | "breadcrumbs" | "button" | "calendar" | "callouts" | "card" | "chart" | "chat.box" | "chat.part.text" | "chat.part.tool-call" | "code-block" | "collapsible" | "description-list" | "dropdown" | "entry.badge" | "entry.boolean" | "entry.component" | "entry.date" | "entry.text" | "field.builder" | "field.checkbox" | "field.choice" | "field.color-picker" | "field.date-input" | "field.date-time-input" | "field.file-upload" | "field.hidden-input" | "field.media-picker" | "field.number-input" | "field.otp" | "field.password-input" | "field.pattern-input" | "field.repeater" | "field.rich-editor" | "field.select" | "field.text-input" | "field.textarea" | "field.time-input" | "field.toggle" | "field.tree" | "floating-panel" | "form" | "fragment" | "grid" | "heading" | "icon" | "image" | "link" | "map" | "media.library" | "menu" | "menu-item" | "modal" | "notifications" | "outlet" | "pdf" | "popover" | "progress" | "raw-block" | "remote.data-list" | "search.box" | "search.categories" | "search.input" | "search.preview" | "search.recent" | "search.results" | "section" | "segmented-control" | "separator" | "sidebar" | "sidebar.footer" | "signature" | "stack" | "tab" | "table" | "tabs" | "text" | "tooltip" | "topbar" | "tree" | "wizard" | "wizard-step";
|
|
76
50
|
export type NotificationItem = {
|
|
77
51
|
readonly actions: Node[];
|
|
78
52
|
readonly body: Translatable | string | null;
|
|
@@ -112,17 +86,9 @@ export type PagePayload = {
|
|
|
112
86
|
export type PdfNodeType = "pdf";
|
|
113
87
|
export type RemoteNodeType = "remote.data-list";
|
|
114
88
|
export type SearchNodeType = "search.box" | "search.categories" | "search.input" | "search.preview" | "search.recent" | "search.results";
|
|
115
|
-
export type Sidebar = {
|
|
116
|
-
collapsible: boolean;
|
|
117
|
-
rememberState: boolean;
|
|
118
|
-
};
|
|
119
|
-
export type SidebarFooter = Record<string, never>;
|
|
120
89
|
export type SignatureExampleNodeType = "signature";
|
|
121
90
|
export type TableNodeType = "table";
|
|
122
|
-
export type
|
|
123
|
-
sticky: boolean;
|
|
124
|
-
};
|
|
125
|
-
export type UiNodeType = "avatar" | "badge" | "button" | "card" | "chart" | "code-block" | "collapsible" | "description-list" | "entry.badge" | "entry.boolean" | "entry.component" | "entry.date" | "entry.text" | "floating-panel" | "grid" | "heading" | "icon" | "image" | "link" | "modal" | "progress" | "raw-block" | "section" | "segmented-control" | "separator" | "stack" | "tab" | "tabs" | "text" | "tooltip";
|
|
91
|
+
export type UiNodeType = "avatar" | "badge" | "breadcrumbs" | "button" | "callouts" | "card" | "chart" | "code-block" | "collapsible" | "description-list" | "dropdown" | "entry.badge" | "entry.boolean" | "entry.component" | "entry.date" | "entry.text" | "floating-panel" | "grid" | "heading" | "icon" | "image" | "link" | "menu" | "menu-item" | "modal" | "popover" | "progress" | "raw-block" | "section" | "segmented-control" | "separator" | "sidebar" | "sidebar.footer" | "stack" | "tab" | "tabs" | "text" | "tooltip" | "topbar";
|
|
126
92
|
export type UnreadCount = {
|
|
127
93
|
readonly unreadCount: number;
|
|
128
94
|
};
|