@elaraai/east-ui 1.0.39 → 1.0.41
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/src/collections/calendar/index.d.ts +275 -62
- package/dist/src/collections/calendar/index.d.ts.map +1 -1
- package/dist/src/collections/calendar/index.js +168 -51
- package/dist/src/collections/calendar/index.js.map +1 -1
- package/dist/src/collections/calendar/types.d.ts +228 -22
- package/dist/src/collections/calendar/types.d.ts.map +1 -1
- package/dist/src/collections/calendar/types.js +132 -18
- package/dist/src/collections/calendar/types.js.map +1 -1
- package/dist/src/collections/deck/index.d.ts +2229 -0
- package/dist/src/collections/deck/index.d.ts.map +1 -0
- package/dist/src/collections/deck/index.js +461 -0
- package/dist/src/collections/deck/index.js.map +1 -0
- package/dist/src/collections/deck/types.d.ts +327 -0
- package/dist/src/collections/deck/types.d.ts.map +1 -0
- package/dist/src/collections/deck/types.js +206 -0
- package/dist/src/collections/deck/types.js.map +1 -0
- package/dist/src/collections/index.d.ts +2 -0
- package/dist/src/collections/index.d.ts.map +1 -1
- package/dist/src/collections/index.js +2 -0
- package/dist/src/collections/index.js.map +1 -1
- package/dist/src/collections/value-tree/index.d.ts +380 -0
- package/dist/src/collections/value-tree/index.d.ts.map +1 -0
- package/dist/src/collections/value-tree/index.js +688 -0
- package/dist/src/collections/value-tree/index.js.map +1 -0
- package/dist/src/collections/value-tree/materialize.d.ts +65 -0
- package/dist/src/collections/value-tree/materialize.d.ts.map +1 -0
- package/dist/src/collections/value-tree/materialize.js +238 -0
- package/dist/src/collections/value-tree/materialize.js.map +1 -0
- package/dist/src/collections/value-tree/types.d.ts +324 -0
- package/dist/src/collections/value-tree/types.d.ts.map +1 -0
- package/dist/src/collections/value-tree/types.js +168 -0
- package/dist/src/collections/value-tree/types.js.map +1 -0
- package/dist/src/component.d.ts +1047 -61
- package/dist/src/component.d.ts.map +1 -1
- package/dist/src/component.js +97 -3
- package/dist/src/component.js.map +1 -1
- package/dist/src/index.d.ts +3 -3
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +2 -2
- package/dist/src/index.js.map +1 -1
- package/dist/src/internal.d.ts +4 -3
- package/dist/src/internal.d.ts.map +1 -1
- package/dist/src/internal.js +3 -3
- package/dist/src/internal.js.map +1 -1
- package/dist/src/layout/splitter/index.d.ts +1 -0
- package/dist/src/layout/splitter/index.d.ts.map +1 -1
- package/dist/src/layout/splitter/index.js +2 -1
- package/dist/src/layout/splitter/index.js.map +1 -1
- package/dist/src/layout/splitter/types.d.ts +9 -0
- package/dist/src/layout/splitter/types.d.ts.map +1 -1
- package/dist/src/layout/splitter/types.js +4 -0
- package/dist/src/layout/splitter/types.js.map +1 -1
- package/dist/src/navigation/app/index.d.ts +135 -0
- package/dist/src/navigation/app/index.d.ts.map +1 -0
- package/dist/src/navigation/app/index.js +191 -0
- package/dist/src/navigation/app/index.js.map +1 -0
- package/dist/src/navigation/index.d.ts +1 -0
- package/dist/src/navigation/index.d.ts.map +1 -1
- package/dist/src/navigation/index.js +1 -0
- package/dist/src/navigation/index.js.map +1 -1
- package/dist/src/navigation/pages/types.d.ts +15 -1
- package/dist/src/navigation/pages/types.d.ts.map +1 -1
- package/dist/src/navigation/pages/types.js.map +1 -1
- package/dist/src/platform/slice/impl.js +2 -2
- package/dist/src/platform/slice/impl.js.map +1 -1
- package/dist/src/runtime/collections/calendar.d.ts +10 -5
- package/dist/src/runtime/collections/calendar.d.ts.map +1 -1
- package/dist/src/runtime/collections/calendar.js +10 -5
- package/dist/src/runtime/collections/calendar.js.map +1 -1
- package/dist/src/runtime/collections/deck.d.ts +1066 -0
- package/dist/src/runtime/collections/deck.d.ts.map +1 -0
- package/dist/src/runtime/collections/deck.js +54 -0
- package/dist/src/runtime/collections/deck.js.map +1 -0
- package/dist/src/runtime/collections/index.d.ts +2 -0
- package/dist/src/runtime/collections/index.d.ts.map +1 -1
- package/dist/src/runtime/collections/index.js +2 -0
- package/dist/src/runtime/collections/index.js.map +1 -1
- package/dist/src/runtime/collections/value-tree.d.ts +202 -0
- package/dist/src/runtime/collections/value-tree.d.ts.map +1 -0
- package/dist/src/runtime/collections/value-tree.js +49 -0
- package/dist/src/runtime/collections/value-tree.js.map +1 -0
- package/dist/src/runtime/navigation/app.d.ts +50 -0
- package/dist/src/runtime/navigation/app.d.ts.map +1 -0
- package/dist/src/runtime/navigation/app.js +51 -0
- package/dist/src/runtime/navigation/app.js.map +1 -0
- package/dist/src/runtime/navigation/index.d.ts +1 -0
- package/dist/src/runtime/navigation/index.d.ts.map +1 -1
- package/dist/src/runtime/navigation/index.js +1 -0
- package/dist/src/runtime/navigation/index.js.map +1 -1
- package/dist/test/collections/calendar.examples.d.ts +2 -0
- package/dist/test/collections/calendar.examples.d.ts.map +1 -1
- package/dist/test/collections/calendar.examples.js +74 -42
- package/dist/test/collections/calendar.examples.js.map +1 -1
- package/dist/test/collections/deck.examples.d.ts +8 -0
- package/dist/test/collections/deck.examples.d.ts.map +1 -0
- package/dist/test/collections/deck.examples.js +169 -0
- package/dist/test/collections/deck.examples.js.map +1 -0
- package/dist/test/collections/planner.examples.js +2 -2
- package/dist/test/collections/value-tree.examples.d.ts +10 -0
- package/dist/test/collections/value-tree.examples.d.ts.map +1 -0
- package/dist/test/collections/value-tree.examples.js +263 -0
- package/dist/test/collections/value-tree.examples.js.map +1 -0
- package/dist/test/display/image.examples.js +1 -1
- package/dist/test/display/image.examples.js.map +1 -1
- package/dist/test/layout/aligned-stack.examples.js +4 -4
- package/dist/test/layout/aligned-stack.examples.js.map +1 -1
- package/dist/test/layout/dock.examples.js +6 -6
- package/dist/test/layout/dock.examples.js.map +1 -1
- package/dist/test/layout/splitter.examples.d.ts +1 -0
- package/dist/test/layout/splitter.examples.d.ts.map +1 -1
- package/dist/test/layout/splitter.examples.js +11 -0
- package/dist/test/layout/splitter.examples.js.map +1 -1
- package/dist/test/navigation/app.examples.d.ts +22 -0
- package/dist/test/navigation/app.examples.d.ts.map +1 -0
- package/dist/test/navigation/app.examples.js +116 -0
- package/dist/test/navigation/app.examples.js.map +1 -0
- package/dist/test/navigation/nav-list.examples.js +2 -2
- package/dist/test/navigation/nav-list.examples.js.map +1 -1
- package/dist/test/overlays/drawer.examples.js +2 -2
- package/dist/test/overlays/drawer.examples.js.map +1 -1
- package/package.json +3 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deck.d.ts","sourceRoot":"","sources":["../../../../src/runtime/collections/deck.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,6CAA6C;AAE7C,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,kBAAkB,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC9F,OAAO,EAEH,KAAK,UAAU,EAClB,MAAM,iCAAiC,CAAC;AACzC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AACrE,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,iBAAS,OAAO,CAAC,CAAC,SAAS,kBAAkB,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,EAChE,KAAK,EAAE;IAAE,IAAI,EAAE,CAAC,CAAA;CAAE,GAAG,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,GAC/C,QAAQ,CAAC,eAAe,CAAC,CAG3B;AAED,wEAAwE;AACxE,eAAO,MAAM,IAAI;;;;cAC2zV,CAAC;;;;;;;;;;;;YAAmF,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAD12V,CAAC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/** `<Deck>` tag — see the export's JSDoc. */
|
|
6
|
+
import { ArrayType, StructType } from "@elaraai/east";
|
|
7
|
+
import { Deck as DeckFactory, } from "../../collections/deck/index.js";
|
|
8
|
+
import { UIComponentType } from "../../component.js";
|
|
9
|
+
/**
|
|
10
|
+
* `<Deck>` — a declarative grouped card collection: `data` rows rendered
|
|
11
|
+
* as presentation cards (structured face via the `card` accessor, or a
|
|
12
|
+
* fully custom face via `render`), grouped by named GROUP BY toolbar
|
|
13
|
+
* options, filtered by slice chrome, laid out as a wrapping card grid
|
|
14
|
+
* (desktop rows → one phone column) or a single-column list. Cards are
|
|
15
|
+
* tap targets (`onCardClick`) — for a drag-and-drop palette use
|
|
16
|
+
* `<Library>` instead.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* ```tsx
|
|
20
|
+
* // .tsx file with the `@jsxImportSource @elaraai/east-ui` pragma
|
|
21
|
+
* import { East } from "@elaraai/east";
|
|
22
|
+
* import { Deck, UIComponentType } from "@elaraai/east-ui";
|
|
23
|
+
*
|
|
24
|
+
* const surface = East.function([], UIComponentType, _$ => (
|
|
25
|
+
* <Deck
|
|
26
|
+
* data={[
|
|
27
|
+
* { id: "a-201", name: "Line A", state: "RUNNING", team: "Alpha", load: 0.62 },
|
|
28
|
+
* { id: "b-114", name: "Line B", state: "DOWN", team: "Beta", load: 0.0 },
|
|
29
|
+
* ]}
|
|
30
|
+
* card={r => ({
|
|
31
|
+
* key: r.id, title: r.name, sublabel: r.team,
|
|
32
|
+
* status: Deck.status(r.state, "info"),
|
|
33
|
+
* facts: [Deck.meter("Load", r.load.multiply(100.0), 100.0, East.print(r.load))],
|
|
34
|
+
* })}
|
|
35
|
+
* groupBy={[
|
|
36
|
+
* { key: "state", label: "Status", value: r => r.state },
|
|
37
|
+
* { key: "team", label: "Team", value: r => r.team },
|
|
38
|
+
* ]}
|
|
39
|
+
* search={r => r.name}
|
|
40
|
+
* />
|
|
41
|
+
* ));
|
|
42
|
+
* ```
|
|
43
|
+
*
|
|
44
|
+
* @remarks
|
|
45
|
+
* Carries `Deck.status` / `Deck.meter` / `Deck.chips` / `Deck.text` value
|
|
46
|
+
* constructors and `Deck.Types`. Desugars to `Deck.Root(data, config)`.
|
|
47
|
+
*/
|
|
48
|
+
function DeckTag(props) {
|
|
49
|
+
const { data, ...config } = props;
|
|
50
|
+
return DeckFactory.Root(data, config);
|
|
51
|
+
}
|
|
52
|
+
/** The callable `<Deck>` tag carrying the factory namespace statics. */
|
|
53
|
+
export const Deck = Object.assign(DeckTag, DeckFactory);
|
|
54
|
+
//# sourceMappingURL=deck.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deck.js","sourceRoot":"","sources":["../../../../src/runtime/collections/deck.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,6CAA6C;AAE7C,OAAO,EAA0C,SAAS,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC9F,OAAO,EACH,IAAI,IAAI,WAAW,GAEtB,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,SAAS,OAAO,CACZ,KAA8C;IAE9C,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,EAAE,GAAG,KAAK,CAAC;IAClC,OAAO,WAAW,CAAC,IAAI,CAAC,IAAI,EAAE,MAAmC,CAAC,CAAC;AACvE,CAAC;AAED,wEAAwE;AACxE,MAAM,CAAC,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC"}
|
|
@@ -10,6 +10,8 @@ export { Table } from "./table.js";
|
|
|
10
10
|
export { Matrix } from "./matrix.js";
|
|
11
11
|
export { Gantt } from "./gantt.js";
|
|
12
12
|
export { Planner } from "./planner.js";
|
|
13
|
+
export { Deck } from "./deck.js";
|
|
14
|
+
export { ValueTree } from "./value-tree.js";
|
|
13
15
|
export { Library } from "./library.js";
|
|
14
16
|
export { Roster } from "./roster.js";
|
|
15
17
|
export { Board } from "./board.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/runtime/collections/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,uDAAuD;AAEvD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/runtime/collections/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,uDAAuD;AAEvD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -10,6 +10,8 @@ export { Table } from "./table.js";
|
|
|
10
10
|
export { Matrix } from "./matrix.js";
|
|
11
11
|
export { Gantt } from "./gantt.js";
|
|
12
12
|
export { Planner } from "./planner.js";
|
|
13
|
+
export { Deck } from "./deck.js";
|
|
14
|
+
export { ValueTree } from "./value-tree.js";
|
|
13
15
|
export { Library } from "./library.js";
|
|
14
16
|
export { Roster } from "./roster.js";
|
|
15
17
|
export { Board } from "./board.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/runtime/collections/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,uDAAuD;AAEvD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/runtime/collections/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,uDAAuD;AAEvD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/** `<ValueTree>` tag — see the export's JSDoc. */
|
|
6
|
+
import { type EastType, type Expr, type ExprType, type SubtypeExprOrValue } from "@elaraai/east";
|
|
7
|
+
import { type ValueTreeOptions } from "../../collections/value-tree/index.js";
|
|
8
|
+
import { UIComponentType } from "../../component.js";
|
|
9
|
+
/**
|
|
10
|
+
* `<ValueTree>` — the editable tree of any East value: the `value` prop's
|
|
11
|
+
* STATIC East type is walked at authoring time and materialized into a
|
|
12
|
+
* fixed recursive node IR (structs, arrays, string-keyed dicts, options
|
|
13
|
+
* and variants become branches; primitives become typed editable leaves;
|
|
14
|
+
* everything else summarizes read-only). Pass `onUpdate` (and optionally
|
|
15
|
+
* `at` scopes built with `ValueTree.at`) to receive the whole rebuilt
|
|
16
|
+
* value — or subtree — after every edit; the raw path callbacks
|
|
17
|
+
* (`onEdit` / `onInsert` / `onRemove` / `onTag`) remain for hosts with a
|
|
18
|
+
* finer-grained store. Omit all callbacks for a read-only inspector.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```tsx
|
|
22
|
+
* // .tsx file with the `@jsxImportSource @elaraai/east-ui` pragma
|
|
23
|
+
* import { East } from "@elaraai/east";
|
|
24
|
+
* import { ValueTree, UIComponentType } from "@elaraai/east-ui";
|
|
25
|
+
*
|
|
26
|
+
* // Read-only inspector — any value materializes automatically.
|
|
27
|
+
* const surface = East.function([], UIComponentType, _$ => (
|
|
28
|
+
* <ValueTree
|
|
29
|
+
* value={{
|
|
30
|
+
* rate: 0.15,
|
|
31
|
+
* label: "Base",
|
|
32
|
+
* tags: ["a", "b"],
|
|
33
|
+
* }}
|
|
34
|
+
* />
|
|
35
|
+
* ));
|
|
36
|
+
* ```
|
|
37
|
+
*
|
|
38
|
+
* @remarks
|
|
39
|
+
* Carries `ValueTree.at` (scoped subtree handlers), `ValueTree.zero`
|
|
40
|
+
* (host-side default element for raw `onInsert` handlers) and
|
|
41
|
+
* `ValueTree.Types`. Desugars to `ValueTree.Root(value, options)`.
|
|
42
|
+
*/
|
|
43
|
+
declare function ValueTreeTag<T extends EastType>(props: {
|
|
44
|
+
value: SubtypeExprOrValue<T> | Expr;
|
|
45
|
+
} & ValueTreeOptions<T>): ExprType<UIComponentType>;
|
|
46
|
+
/** The callable `<ValueTree>` tag carrying the factory namespace statics. */
|
|
47
|
+
export declare const ValueTree: typeof ValueTreeTag & {
|
|
48
|
+
readonly Root: <T extends EastType>(value: SubtypeExprOrValue<T> | Expr, options?: ValueTreeOptions<T>) => ExprType<UIComponentType>;
|
|
49
|
+
readonly at: <T extends EastType, S extends EastType>(root: T, path: (probe: import("../../collections/value-tree/index.js").ValueTreeProbe<T>) => {
|
|
50
|
+
readonly __vt?: S;
|
|
51
|
+
}, onUpdate: SubtypeExprOrValue<import("@elaraai/east").FunctionType<[S], import("@elaraai/east").NullType>> | SubtypeExprOrValue<import("@elaraai/east").AsyncFunctionType<[S], import("@elaraai/east").NullType>>) => import("../../collections/value-tree/index.js").ValueTreeScope;
|
|
52
|
+
readonly zero: <T extends EastType>(t: T) => import("@elaraai/east").ValueTypeOf<T>;
|
|
53
|
+
readonly materialize: typeof import("../../collections/value-tree/materialize.js").materialize;
|
|
54
|
+
readonly applyEdit: typeof import("../../collections/value-tree/materialize.js").applyEdit;
|
|
55
|
+
readonly Types: {
|
|
56
|
+
readonly Root: import("@elaraai/east").StructType<{
|
|
57
|
+
readonly root: import("@elaraai/east").RecursiveType<import("@elaraai/east").VariantType<{
|
|
58
|
+
readonly struct: import("@elaraai/east").StructType<{
|
|
59
|
+
readonly fields: import("@elaraai/east").ArrayType<import("@elaraai/east").StructType<{
|
|
60
|
+
readonly name: import("@elaraai/east").StringType;
|
|
61
|
+
readonly node: import("@elaraai/east").RecursiveTypeMarker;
|
|
62
|
+
}>>;
|
|
63
|
+
}>;
|
|
64
|
+
readonly array: import("@elaraai/east").StructType<{
|
|
65
|
+
readonly items: import("@elaraai/east").ArrayType<import("@elaraai/east").RecursiveTypeMarker>;
|
|
66
|
+
}>;
|
|
67
|
+
readonly dict: import("@elaraai/east").StructType<{
|
|
68
|
+
readonly entries: import("@elaraai/east").ArrayType<import("@elaraai/east").StructType<{
|
|
69
|
+
readonly key: import("@elaraai/east").StringType;
|
|
70
|
+
readonly node: import("@elaraai/east").RecursiveTypeMarker;
|
|
71
|
+
}>>;
|
|
72
|
+
readonly editable: import("@elaraai/east").BooleanType;
|
|
73
|
+
}>;
|
|
74
|
+
readonly option: import("@elaraai/east").StructType<{
|
|
75
|
+
readonly value: import("@elaraai/east").OptionType<import("@elaraai/east").RecursiveTypeMarker>;
|
|
76
|
+
}>;
|
|
77
|
+
readonly variant: import("@elaraai/east").StructType<{
|
|
78
|
+
readonly tag: import("@elaraai/east").StringType;
|
|
79
|
+
readonly tags: import("@elaraai/east").ArrayType<import("@elaraai/east").StringType>;
|
|
80
|
+
readonly value: import("@elaraai/east").RecursiveTypeMarker;
|
|
81
|
+
}>;
|
|
82
|
+
readonly leaf: import("@elaraai/east").VariantType<{
|
|
83
|
+
readonly string: import("@elaraai/east").StringType;
|
|
84
|
+
readonly integer: import("@elaraai/east").IntegerType;
|
|
85
|
+
readonly float: import("@elaraai/east").FloatType;
|
|
86
|
+
readonly boolean: import("@elaraai/east").BooleanType;
|
|
87
|
+
readonly datetime: import("@elaraai/east").DateTimeType;
|
|
88
|
+
readonly null: import("@elaraai/east").NullType;
|
|
89
|
+
}>;
|
|
90
|
+
readonly opaque: import("@elaraai/east").StringType;
|
|
91
|
+
}>>;
|
|
92
|
+
readonly onEdit: import("@elaraai/east").OptionType<import("@elaraai/east").AsyncFunctionType<[import("@elaraai/east").ArrayType<import("@elaraai/east").VariantType<{
|
|
93
|
+
readonly append: import("@elaraai/east").NullType;
|
|
94
|
+
readonly field: import("@elaraai/east").StringType;
|
|
95
|
+
readonly index: import("@elaraai/east").IntegerType;
|
|
96
|
+
readonly key: import("@elaraai/east").StringType;
|
|
97
|
+
readonly some: import("@elaraai/east").NullType;
|
|
98
|
+
readonly tag: import("@elaraai/east").NullType;
|
|
99
|
+
}>>, import("@elaraai/east").VariantType<{
|
|
100
|
+
readonly string: import("@elaraai/east").StringType;
|
|
101
|
+
readonly integer: import("@elaraai/east").IntegerType;
|
|
102
|
+
readonly float: import("@elaraai/east").FloatType;
|
|
103
|
+
readonly boolean: import("@elaraai/east").BooleanType;
|
|
104
|
+
readonly datetime: import("@elaraai/east").DateTimeType;
|
|
105
|
+
readonly null: import("@elaraai/east").NullType;
|
|
106
|
+
}>], import("@elaraai/east").NullType>>;
|
|
107
|
+
readonly onInsert: import("@elaraai/east").OptionType<import("@elaraai/east").AsyncFunctionType<[import("@elaraai/east").ArrayType<import("@elaraai/east").VariantType<{
|
|
108
|
+
readonly append: import("@elaraai/east").NullType;
|
|
109
|
+
readonly field: import("@elaraai/east").StringType;
|
|
110
|
+
readonly index: import("@elaraai/east").IntegerType;
|
|
111
|
+
readonly key: import("@elaraai/east").StringType;
|
|
112
|
+
readonly some: import("@elaraai/east").NullType;
|
|
113
|
+
readonly tag: import("@elaraai/east").NullType;
|
|
114
|
+
}>>], import("@elaraai/east").NullType>>;
|
|
115
|
+
readonly onRemove: import("@elaraai/east").OptionType<import("@elaraai/east").AsyncFunctionType<[import("@elaraai/east").ArrayType<import("@elaraai/east").VariantType<{
|
|
116
|
+
readonly append: import("@elaraai/east").NullType;
|
|
117
|
+
readonly field: import("@elaraai/east").StringType;
|
|
118
|
+
readonly index: import("@elaraai/east").IntegerType;
|
|
119
|
+
readonly key: import("@elaraai/east").StringType;
|
|
120
|
+
readonly some: import("@elaraai/east").NullType;
|
|
121
|
+
readonly tag: import("@elaraai/east").NullType;
|
|
122
|
+
}>>], import("@elaraai/east").NullType>>;
|
|
123
|
+
readonly onTag: import("@elaraai/east").OptionType<import("@elaraai/east").AsyncFunctionType<[import("@elaraai/east").ArrayType<import("@elaraai/east").VariantType<{
|
|
124
|
+
readonly append: import("@elaraai/east").NullType;
|
|
125
|
+
readonly field: import("@elaraai/east").StringType;
|
|
126
|
+
readonly index: import("@elaraai/east").IntegerType;
|
|
127
|
+
readonly key: import("@elaraai/east").StringType;
|
|
128
|
+
readonly some: import("@elaraai/east").NullType;
|
|
129
|
+
readonly tag: import("@elaraai/east").NullType;
|
|
130
|
+
}>>, import("@elaraai/east").StringType], import("@elaraai/east").NullType>>;
|
|
131
|
+
readonly style: import("@elaraai/east").OptionType<import("@elaraai/east").StructType<{
|
|
132
|
+
readonly height: import("@elaraai/east").OptionType<import("@elaraai/east").StringType>;
|
|
133
|
+
readonly maxHeight: import("@elaraai/east").OptionType<import("@elaraai/east").StringType>;
|
|
134
|
+
}>>;
|
|
135
|
+
}>;
|
|
136
|
+
readonly Node: import("@elaraai/east").RecursiveType<import("@elaraai/east").VariantType<{
|
|
137
|
+
readonly struct: import("@elaraai/east").StructType<{
|
|
138
|
+
readonly fields: import("@elaraai/east").ArrayType<import("@elaraai/east").StructType<{
|
|
139
|
+
readonly name: import("@elaraai/east").StringType;
|
|
140
|
+
readonly node: import("@elaraai/east").RecursiveTypeMarker;
|
|
141
|
+
}>>;
|
|
142
|
+
}>;
|
|
143
|
+
readonly array: import("@elaraai/east").StructType<{
|
|
144
|
+
readonly items: import("@elaraai/east").ArrayType<import("@elaraai/east").RecursiveTypeMarker>;
|
|
145
|
+
}>;
|
|
146
|
+
readonly dict: import("@elaraai/east").StructType<{
|
|
147
|
+
readonly entries: import("@elaraai/east").ArrayType<import("@elaraai/east").StructType<{
|
|
148
|
+
readonly key: import("@elaraai/east").StringType;
|
|
149
|
+
readonly node: import("@elaraai/east").RecursiveTypeMarker;
|
|
150
|
+
}>>;
|
|
151
|
+
readonly editable: import("@elaraai/east").BooleanType;
|
|
152
|
+
}>;
|
|
153
|
+
readonly option: import("@elaraai/east").StructType<{
|
|
154
|
+
readonly value: import("@elaraai/east").OptionType<import("@elaraai/east").RecursiveTypeMarker>;
|
|
155
|
+
}>;
|
|
156
|
+
readonly variant: import("@elaraai/east").StructType<{
|
|
157
|
+
readonly tag: import("@elaraai/east").StringType;
|
|
158
|
+
readonly tags: import("@elaraai/east").ArrayType<import("@elaraai/east").StringType>;
|
|
159
|
+
readonly value: import("@elaraai/east").RecursiveTypeMarker;
|
|
160
|
+
}>;
|
|
161
|
+
readonly leaf: import("@elaraai/east").VariantType<{
|
|
162
|
+
readonly string: import("@elaraai/east").StringType;
|
|
163
|
+
readonly integer: import("@elaraai/east").IntegerType;
|
|
164
|
+
readonly float: import("@elaraai/east").FloatType;
|
|
165
|
+
readonly boolean: import("@elaraai/east").BooleanType;
|
|
166
|
+
readonly datetime: import("@elaraai/east").DateTimeType;
|
|
167
|
+
readonly null: import("@elaraai/east").NullType;
|
|
168
|
+
}>;
|
|
169
|
+
readonly opaque: import("@elaraai/east").StringType;
|
|
170
|
+
}>>;
|
|
171
|
+
readonly Path: import("@elaraai/east").ArrayType<import("@elaraai/east").VariantType<{
|
|
172
|
+
readonly append: import("@elaraai/east").NullType;
|
|
173
|
+
readonly field: import("@elaraai/east").StringType;
|
|
174
|
+
readonly index: import("@elaraai/east").IntegerType;
|
|
175
|
+
readonly key: import("@elaraai/east").StringType;
|
|
176
|
+
readonly some: import("@elaraai/east").NullType;
|
|
177
|
+
readonly tag: import("@elaraai/east").NullType;
|
|
178
|
+
}>>;
|
|
179
|
+
readonly Step: import("@elaraai/east").VariantType<{
|
|
180
|
+
readonly append: import("@elaraai/east").NullType;
|
|
181
|
+
readonly field: import("@elaraai/east").StringType;
|
|
182
|
+
readonly index: import("@elaraai/east").IntegerType;
|
|
183
|
+
readonly key: import("@elaraai/east").StringType;
|
|
184
|
+
readonly some: import("@elaraai/east").NullType;
|
|
185
|
+
readonly tag: import("@elaraai/east").NullType;
|
|
186
|
+
}>;
|
|
187
|
+
readonly Leaf: import("@elaraai/east").VariantType<{
|
|
188
|
+
readonly string: import("@elaraai/east").StringType;
|
|
189
|
+
readonly integer: import("@elaraai/east").IntegerType;
|
|
190
|
+
readonly float: import("@elaraai/east").FloatType;
|
|
191
|
+
readonly boolean: import("@elaraai/east").BooleanType;
|
|
192
|
+
readonly datetime: import("@elaraai/east").DateTimeType;
|
|
193
|
+
readonly null: import("@elaraai/east").NullType;
|
|
194
|
+
}>;
|
|
195
|
+
readonly Style: import("@elaraai/east").StructType<{
|
|
196
|
+
readonly height: import("@elaraai/east").OptionType<import("@elaraai/east").StringType>;
|
|
197
|
+
readonly maxHeight: import("@elaraai/east").OptionType<import("@elaraai/east").StringType>;
|
|
198
|
+
}>;
|
|
199
|
+
};
|
|
200
|
+
};
|
|
201
|
+
export {};
|
|
202
|
+
//# sourceMappingURL=value-tree.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"value-tree.d.ts","sourceRoot":"","sources":["../../../../src/runtime/collections/value-tree.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,kDAAkD;AAElD,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,IAAI,EAAE,KAAK,QAAQ,EAAE,KAAK,kBAAkB,EAAE,MAAM,eAAe,CAAC;AACjG,OAAO,EAEH,KAAK,gBAAgB,EACxB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,iBAAS,YAAY,CAAC,CAAC,SAAS,QAAQ,EACpC,KAAK,EAAE;IAAE,KAAK,EAAE,kBAAkB,CAAC,CAAC,CAAC,GAAG,IAAI,CAAA;CAAE,GAAG,gBAAgB,CAAC,CAAC,CAAC,GACrE,QAAQ,CAAC,eAAe,CAAC,CAG3B;AAED,6EAA6E;AAC7E,eAAO,MAAM,SAAS;;;qBAC02uB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAD3zuB,CAAC"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/** `<ValueTree>` tag — see the export's JSDoc. */
|
|
6
|
+
import {} from "@elaraai/east";
|
|
7
|
+
import { ValueTree as ValueTreeFactory, } from "../../collections/value-tree/index.js";
|
|
8
|
+
import { UIComponentType } from "../../component.js";
|
|
9
|
+
/**
|
|
10
|
+
* `<ValueTree>` — the editable tree of any East value: the `value` prop's
|
|
11
|
+
* STATIC East type is walked at authoring time and materialized into a
|
|
12
|
+
* fixed recursive node IR (structs, arrays, string-keyed dicts, options
|
|
13
|
+
* and variants become branches; primitives become typed editable leaves;
|
|
14
|
+
* everything else summarizes read-only). Pass `onUpdate` (and optionally
|
|
15
|
+
* `at` scopes built with `ValueTree.at`) to receive the whole rebuilt
|
|
16
|
+
* value — or subtree — after every edit; the raw path callbacks
|
|
17
|
+
* (`onEdit` / `onInsert` / `onRemove` / `onTag`) remain for hosts with a
|
|
18
|
+
* finer-grained store. Omit all callbacks for a read-only inspector.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```tsx
|
|
22
|
+
* // .tsx file with the `@jsxImportSource @elaraai/east-ui` pragma
|
|
23
|
+
* import { East } from "@elaraai/east";
|
|
24
|
+
* import { ValueTree, UIComponentType } from "@elaraai/east-ui";
|
|
25
|
+
*
|
|
26
|
+
* // Read-only inspector — any value materializes automatically.
|
|
27
|
+
* const surface = East.function([], UIComponentType, _$ => (
|
|
28
|
+
* <ValueTree
|
|
29
|
+
* value={{
|
|
30
|
+
* rate: 0.15,
|
|
31
|
+
* label: "Base",
|
|
32
|
+
* tags: ["a", "b"],
|
|
33
|
+
* }}
|
|
34
|
+
* />
|
|
35
|
+
* ));
|
|
36
|
+
* ```
|
|
37
|
+
*
|
|
38
|
+
* @remarks
|
|
39
|
+
* Carries `ValueTree.at` (scoped subtree handlers), `ValueTree.zero`
|
|
40
|
+
* (host-side default element for raw `onInsert` handlers) and
|
|
41
|
+
* `ValueTree.Types`. Desugars to `ValueTree.Root(value, options)`.
|
|
42
|
+
*/
|
|
43
|
+
function ValueTreeTag(props) {
|
|
44
|
+
const { value, ...options } = props;
|
|
45
|
+
return ValueTreeFactory.Root(value, options);
|
|
46
|
+
}
|
|
47
|
+
/** The callable `<ValueTree>` tag carrying the factory namespace statics. */
|
|
48
|
+
export const ValueTree = Object.assign(ValueTreeTag, ValueTreeFactory);
|
|
49
|
+
//# sourceMappingURL=value-tree.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"value-tree.js","sourceRoot":"","sources":["../../../../src/runtime/collections/value-tree.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,kDAAkD;AAElD,OAAO,EAAoE,MAAM,eAAe,CAAC;AACjG,OAAO,EACH,SAAS,IAAI,gBAAgB,GAEhC,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,SAAS,YAAY,CACjB,KAAoE;IAEpE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,GAAG,KAAK,CAAC;IACpC,OAAO,gBAAgB,CAAC,IAAI,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;AACjD,CAAC;AAED,6EAA6E;AAC7E,MAAM,CAAC,MAAM,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,YAAY,EAAE,gBAAgB,CAAC,CAAC"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/** Navigation `<App>` tag — the application shell (#367). */
|
|
6
|
+
import { type AppInput } from "../../navigation/app/index.js";
|
|
7
|
+
import type { NavRoutes } from "../../navigation/pages/types.js";
|
|
8
|
+
import type { UIElement } from "../runtime.js";
|
|
9
|
+
/**
|
|
10
|
+
* The application shell — a collapsible nav rail, a breadcrumb app bar, an
|
|
11
|
+
* optional brand logo, app-bar slots and the routed page body, all driven by one
|
|
12
|
+
* `Navigation.bind` handle. Author it **inside** the enclosing `<Reactive>` that
|
|
13
|
+
* binds `nav`, and pass the same `Navigation.config` as `config` (the handle
|
|
14
|
+
* carries no labels/icons — the config is the single source of truth for the
|
|
15
|
+
* rail and breadcrumb).
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```tsx
|
|
19
|
+
* // .tsx file with the `@jsxImportSource @elaraai/east-ui` pragma
|
|
20
|
+
* import { East, NullType, UIComponentType } from "@elaraai/east";
|
|
21
|
+
* import { App, Navigation, Reactive, Image, Text } from "@elaraai/east-ui";
|
|
22
|
+
*
|
|
23
|
+
* const app = East.function([], UIComponentType, _$ => {
|
|
24
|
+
* const routes = Navigation.config({
|
|
25
|
+
* overview: { value: NullType, label: "Overview", section: "Analyse", icon: { prefix: "fas", name: "gauge-high" } },
|
|
26
|
+
* audit: { value: NullType, label: "Audit", section: "Manage", icon: { prefix: "fas", name: "list-check" } },
|
|
27
|
+
* });
|
|
28
|
+
* return (
|
|
29
|
+
* <Reactive>{$ => {
|
|
30
|
+
* const nav = $.let(Navigation.bind(routes, "app.route", [routes.Page.overview()]));
|
|
31
|
+
* return (
|
|
32
|
+
* <App nav={nav} config={routes} title="Acme Ops" logo={Image.dataUri("data:image/svg+xml,<svg/>")}
|
|
33
|
+
* pages={{ overview: () => <Text>Overview</Text>, audit: () => <Text>Audit</Text> }} />
|
|
34
|
+
* );
|
|
35
|
+
* }}</Reactive>
|
|
36
|
+
* );
|
|
37
|
+
* });
|
|
38
|
+
* ```
|
|
39
|
+
*
|
|
40
|
+
* @remarks
|
|
41
|
+
* Desugars to `App.Root({ nav, config, pages, … })`. A generic function
|
|
42
|
+
* declaration (merged with the `App` namespace) so it is a valid generic JSX
|
|
43
|
+
* component.
|
|
44
|
+
*/
|
|
45
|
+
export declare function App<R extends NavRoutes>(props: AppInput<R>): UIElement;
|
|
46
|
+
export declare namespace App {
|
|
47
|
+
/** The underlying factory: `App.Root({ nav, config, pages, … })`. */
|
|
48
|
+
const Root: <R extends NavRoutes>(input: AppInput<R>) => import("@elaraai/east").ExprType<import("../../component.js").UIComponentType>;
|
|
49
|
+
}
|
|
50
|
+
//# sourceMappingURL=app.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../../src/runtime/navigation/app.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,6DAA6D;AAE7D,OAAO,EAAqB,KAAK,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AACjF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE/C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,wBAAgB,GAAG,CAAC,CAAC,SAAS,SAAS,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,SAAS,CAEtE;AAGD,yBAAiB,GAAG,CAAC;IACjB,qEAAqE;IAC9D,MAAM,IAAI,6HAAkB,CAAC;CACvC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/** Navigation `<App>` tag — the application shell (#367). */
|
|
6
|
+
import { App as AppFactory } from "../../navigation/app/index.js";
|
|
7
|
+
/**
|
|
8
|
+
* The application shell — a collapsible nav rail, a breadcrumb app bar, an
|
|
9
|
+
* optional brand logo, app-bar slots and the routed page body, all driven by one
|
|
10
|
+
* `Navigation.bind` handle. Author it **inside** the enclosing `<Reactive>` that
|
|
11
|
+
* binds `nav`, and pass the same `Navigation.config` as `config` (the handle
|
|
12
|
+
* carries no labels/icons — the config is the single source of truth for the
|
|
13
|
+
* rail and breadcrumb).
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```tsx
|
|
17
|
+
* // .tsx file with the `@jsxImportSource @elaraai/east-ui` pragma
|
|
18
|
+
* import { East, NullType, UIComponentType } from "@elaraai/east";
|
|
19
|
+
* import { App, Navigation, Reactive, Image, Text } from "@elaraai/east-ui";
|
|
20
|
+
*
|
|
21
|
+
* const app = East.function([], UIComponentType, _$ => {
|
|
22
|
+
* const routes = Navigation.config({
|
|
23
|
+
* overview: { value: NullType, label: "Overview", section: "Analyse", icon: { prefix: "fas", name: "gauge-high" } },
|
|
24
|
+
* audit: { value: NullType, label: "Audit", section: "Manage", icon: { prefix: "fas", name: "list-check" } },
|
|
25
|
+
* });
|
|
26
|
+
* return (
|
|
27
|
+
* <Reactive>{$ => {
|
|
28
|
+
* const nav = $.let(Navigation.bind(routes, "app.route", [routes.Page.overview()]));
|
|
29
|
+
* return (
|
|
30
|
+
* <App nav={nav} config={routes} title="Acme Ops" logo={Image.dataUri("data:image/svg+xml,<svg/>")}
|
|
31
|
+
* pages={{ overview: () => <Text>Overview</Text>, audit: () => <Text>Audit</Text> }} />
|
|
32
|
+
* );
|
|
33
|
+
* }}</Reactive>
|
|
34
|
+
* );
|
|
35
|
+
* });
|
|
36
|
+
* ```
|
|
37
|
+
*
|
|
38
|
+
* @remarks
|
|
39
|
+
* Desugars to `App.Root({ nav, config, pages, … })`. A generic function
|
|
40
|
+
* declaration (merged with the `App` namespace) so it is a valid generic JSX
|
|
41
|
+
* component.
|
|
42
|
+
*/
|
|
43
|
+
export function App(props) {
|
|
44
|
+
return AppFactory.Root(props);
|
|
45
|
+
}
|
|
46
|
+
// eslint-disable-next-line @typescript-eslint/no-namespace
|
|
47
|
+
(function (App) {
|
|
48
|
+
/** The underlying factory: `App.Root({ nav, config, pages, … })`. */
|
|
49
|
+
App.Root = AppFactory.Root;
|
|
50
|
+
})(App || (App = {}));
|
|
51
|
+
//# sourceMappingURL=app.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app.js","sourceRoot":"","sources":["../../../../src/runtime/navigation/app.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,6DAA6D;AAE7D,OAAO,EAAE,GAAG,IAAI,UAAU,EAAiB,MAAM,+BAA+B,CAAC;AAIjF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,MAAM,UAAU,GAAG,CAAsB,KAAkB;IACvD,OAAO,UAAU,CAAC,IAAI,CAAC,KAAK,CAAc,CAAC;AAC/C,CAAC;AAED,2DAA2D;AAC3D,WAAiB,GAAG;IAChB,qEAAqE;IACxD,QAAI,GAAG,UAAU,CAAC,IAAI,CAAC;AACxC,CAAC,EAHgB,GAAG,KAAH,GAAG,QAGnB"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
4
|
*/
|
|
5
5
|
/** Navigation JSX tags. Mirrors `src/navigation/`. */
|
|
6
|
+
export { App } from "./app.js";
|
|
6
7
|
export { Breadcrumb } from "./breadcrumb.js";
|
|
7
8
|
export { NavList } from "./nav-list.js";
|
|
8
9
|
export { Pages } from "./pages.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/runtime/navigation/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,sDAAsD;AAEtD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/runtime/navigation/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,sDAAsD;AAEtD,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAC/B,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
4
|
*/
|
|
5
5
|
/** Navigation JSX tags. Mirrors `src/navigation/`. */
|
|
6
|
+
export { App } from "./app.js";
|
|
6
7
|
export { Breadcrumb } from "./breadcrumb.js";
|
|
7
8
|
export { NavList } from "./nav-list.js";
|
|
8
9
|
export { Pages } from "./pages.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/runtime/navigation/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,sDAAsD;AAEtD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/runtime/navigation/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,sDAAsD;AAEtD,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAC/B,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
export declare const calendarDemand: import("@elaraai/east").ExampleDef<[], any>;
|
|
2
2
|
export declare const calendarMinimal: import("@elaraai/east").ExampleDef<[], any>;
|
|
3
|
+
export declare const calendarValuesOff: import("@elaraai/east").ExampleDef<[], any>;
|
|
4
|
+
export declare const calendarTotals: import("@elaraai/east").ExampleDef<[], any>;
|
|
3
5
|
export declare const calendarDensity: import("@elaraai/east").ExampleDef<[], any>;
|
|
4
6
|
export declare const calendarInteractive: import("@elaraai/east").ExampleDef<[], any>;
|
|
5
7
|
export declare const calendarScroll: import("@elaraai/east").ExampleDef<[], any>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"calendar.examples.d.ts","sourceRoot":"","sources":["../../../test/collections/calendar.examples.tsx"],"names":[],"mappings":"AASA,eAAO,MAAM,cAAc,
|
|
1
|
+
{"version":3,"file":"calendar.examples.d.ts","sourceRoot":"","sources":["../../../test/collections/calendar.examples.tsx"],"names":[],"mappings":"AASA,eAAO,MAAM,cAAc,6CAyCzB,CAAC;AAEH,eAAO,MAAM,eAAe,6CAmB1B,CAAC;AAEH,eAAO,MAAM,iBAAiB,6CAuB5B,CAAC;AAEH,eAAO,MAAM,cAAc,6CAsBzB,CAAC;AAEH,eAAO,MAAM,eAAe,6CAsB1B,CAAC;AAEH,eAAO,MAAM,mBAAmB,6CAoC9B,CAAC;AAGH,eAAO,MAAM,cAAc,6CAuCzB,CAAC;AAEH,eAAO,MAAM,YAAY,6CAoBvB,CAAC"}
|