@furo/open-models 1.19.0 → 1.20.1

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.
@@ -2618,290 +2618,6 @@
2618
2618
  }
2619
2619
  ]
2620
2620
  },
2621
- {
2622
- "kind": "javascript-module",
2623
- "path": "dist/decorators/DefaultServiceEventHandlers.js",
2624
- "declarations": [
2625
- {
2626
- "kind": "function",
2627
- "name": "DefaultServiceEventHandlers",
2628
- "parameters": [
2629
- {
2630
- "name": "dispatch",
2631
- "type": {
2632
- "text": "DispatchFn"
2633
- },
2634
- "description": "Function to dispatch events (typically bound to the service's dispatchEvent)"
2635
- },
2636
- {
2637
- "name": "options",
2638
- "default": "{}",
2639
- "type": {
2640
- "text": "DefaultServiceEventHandlersOptions"
2641
- },
2642
- "description": "Optional configuration"
2643
- }
2644
- ],
2645
- "description": "### DefaultServiceEventHandlers\n\nCreates default service handlers that dispatch standard events.\nUse this to reduce boilerplate when setting up service handlers.\n\nThe `onResponse` handler is intentionally NOT included - you must provide your own\nimplementation since response handling is typically service-specific.\n\nUsage:\n```typescript\nclass MyEntityService extends EventTarget {\n private dispatch = createDispatch(this);\n\n setupHandlers() {\n this.service.Get.setHandlers({\n ...DefaultServiceEventHandlers(this.dispatch),\n onResponse: (response, serverResponse) => {\n // Your custom response handling\n this.entity.fromLiteral(response.entity);\n this.dispatch(\"response-received\", { response, serverResponse });\n },\n });\n }\n}\n```\n\nWith loading check:\n```typescript\nthis.service.Get.setHandlers({\n ...DefaultServiceEventHandlers(this.dispatch, {\n isLoading: () => this.service.Get.isLoading || this.service.Update.isLoading,\n }),\n onResponse: (response, serverResponse) => { ... },\n});\n```",
2646
- "return": {
2647
- "type": {
2648
- "text": ""
2649
- }
2650
- }
2651
- },
2652
- {
2653
- "kind": "function",
2654
- "name": "CreateDispatch",
2655
- "return": {
2656
- "type": {
2657
- "text": ""
2658
- }
2659
- },
2660
- "parameters": [
2661
- {
2662
- "name": "target",
2663
- "type": {
2664
- "text": "EventTarget"
2665
- },
2666
- "description": "The EventTarget to dispatch events on"
2667
- }
2668
- ],
2669
- "description": "### createDispatch\n\nHelper to create a typed dispatch function for an EventTarget.\n\nUsage:\n```typescript\nclass MyService extends EventTarget {\n private dispatch = createDispatch(this);\n\n doSomething() {\n this.dispatch(\"busy-changed\", { busy: true });\n }\n}\n```"
2670
- }
2671
- ],
2672
- "exports": [
2673
- {
2674
- "kind": "js",
2675
- "name": "DefaultServiceEventHandlers",
2676
- "declaration": {
2677
- "name": "DefaultServiceEventHandlers",
2678
- "module": "src/decorators/DefaultServiceEventHandlers.ts"
2679
- }
2680
- },
2681
- {
2682
- "kind": "js",
2683
- "name": "CreateDispatch",
2684
- "declaration": {
2685
- "name": "CreateDispatch",
2686
- "module": "src/decorators/DefaultServiceEventHandlers.ts"
2687
- }
2688
- }
2689
- ]
2690
- },
2691
- {
2692
- "kind": "javascript-module",
2693
- "path": "dist/decorators/EntityServiceTypes.js",
2694
- "declarations": [],
2695
- "exports": []
2696
- },
2697
- {
2698
- "kind": "javascript-module",
2699
- "path": "dist/decorators/FieldBindings.js",
2700
- "declarations": [
2701
- {
2702
- "kind": "variable",
2703
- "name": "fieldBindings",
2704
- "type": {
2705
- "text": "object"
2706
- },
2707
- "default": "{ /** * Decorator for the `model` property. * * Handles: * - Binding/unbinding when model changes * - Resolving reader/writer functions based on model type * - Calling reader on model value changes * - Providing `writeToModel()` method */ model() { return function modelDecorator(target: object, propertyKey: string) { const ctor = target.constructor as typeof ReactiveElement; // Patch lifecycle patchLifecycle(ctor); // Add writeToModel helper method if (!Object.prototype.hasOwnProperty.call(target, \"writeToModel\")) { Object.defineProperty(target, \"writeToModel\", { value: function writeToModel(this: LitElement & Record<symbol, (() => void) | undefined>) { const writeFn = this[MODEL_WRITE_FN]; if (writeFn) { try { writeFn(); } catch (e) { console.error(\"Failed to write to model:\", e); } } }, writable: false, enumerable: false, configurable: true, }); } // Create getter/setter for the model property Object.defineProperty(target, propertyKey, { get(this: LitElement & Record<symbol, FieldNodeLike | undefined>): FieldNodeLike | undefined { return this[CURRENT_MODEL]; }, set(this: LitElement & BindableComponent & Record<symbol, FieldNodeLike | (() => void) | undefined>, value: FieldNodeLike | undefined) { const oldModel = this[CURRENT_MODEL] as FieldNodeLike | undefined; if (value === oldModel) return; // Unbind from old model if (oldModel) { unbindFromModel(this, oldModel); } // Store new model this[CURRENT_MODEL] = value; // Resolve reader/writer functions based on type if (value) { const typeName = value.__meta?.typeName ?? \"primitives.STRING\"; // Resolve reader // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) const reader = this.modelReaders?.get(typeName); if (reader) { this[MODEL_READ_FN] = reader.bind(this); } else { // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) console.warn(`No modelReader for type \"${typeName}\". Available: ${[...(this.modelReaders?.keys() ?? [])].join(\", \")}`); this[MODEL_READ_FN] = undefined; } // Resolve writer // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) const writer = this.modelWriters?.get(typeName); if (writer) { this[MODEL_WRITE_FN] = writer.bind(this); } else { // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) console.warn(`No modelWriter for type \"${typeName}\". Available: ${[...(this.modelWriters?.keys() ?? [])].join(\", \")}`); this[MODEL_WRITE_FN] = undefined; } } else { this[MODEL_READ_FN] = undefined; this[MODEL_WRITE_FN] = undefined; } // Bind to new model (if connected) if (value && this.isConnected) { bindToModel(this, value); } // Trigger Lit update this.requestUpdate(); }, enumerable: true, configurable: true, }); }; }, /** * Binds a method to an event on the model. * When the event fires, the method is called with the event detail. * * @param eventType - The event type to listen for */ onEvent(eventType: ModelEventType) { return function onEventDecorator(target: object, propertyKey: string, descriptor: PropertyDescriptor) { // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment const originalMethod = descriptor.value; const ctor = target.constructor as typeof ReactiveElement; let events = (ctor as unknown as Record<symbol, FieldEventMeta[]>)[FIELD_EVENTS]; // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) if (!events) { events = []; (ctor as unknown as Record<symbol, FieldEventMeta[]>)[FIELD_EVENTS] = events; } // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment events.push({ propertyKey, eventType, method: originalMethod }); patchLifecycle(ctor); }; }, /** * Decorator that marks a method to be called once after a new model is assigned and bound. * * Useful for one-time setup like setting a11y attributes, placeholders, or constraints * based on the model's type. * * @example * ```typescript * @fieldBindings.onInit() * protected init() { * this.accessibleName = this.model?.__label ?? \"Toggle\"; * } * ``` */ onInit() { return function onInitDecorator(target: object, propertyKey: string, descriptor: PropertyDescriptor) { // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment const originalMethod = descriptor.value; const ctor = target.constructor as typeof ReactiveElement; // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type let inits = (ctor as unknown as Record<symbol, { propertyKey: string; method: Function }[]>)[FIELD_INIT_METHODS]; // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) if (!inits) { inits = []; // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type (ctor as unknown as Record<symbol, { propertyKey: string; method: Function }[]>)[FIELD_INIT_METHODS] = inits; } // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment inits.push({ propertyKey, method: originalMethod }); patchLifecycle(ctor); }; }, }",
2708
- "description": "### fieldBindings\n\nDecorators for creating reusable components that bind to FieldNode models.\n\nThe component provides `modelReaders` and `modelWriters` maps keyed by\n`__meta.typeName`. The decorator handles:\n- Binding/unbinding on model change\n- Calling the correct reader when model value changes\n- Providing `writeToModel()` method that calls the correct writer"
2709
- }
2710
- ],
2711
- "exports": [
2712
- {
2713
- "kind": "js",
2714
- "name": "fieldBindings",
2715
- "declaration": {
2716
- "name": "fieldBindings",
2717
- "module": "src/decorators/FieldBindings.ts"
2718
- }
2719
- }
2720
- ]
2721
- },
2722
- {
2723
- "kind": "javascript-module",
2724
- "path": "dist/decorators/ModelDecorators.js",
2725
- "declarations": [
2726
- {
2727
- "kind": "function",
2728
- "name": "ModelBindings",
2729
- "parameters": [
2730
- {
2731
- "name": "model",
2732
- "type": {
2733
- "text": "FieldNodeLike"
2734
- },
2735
- "description": "The FieldNode model to bind to"
2736
- }
2737
- ],
2738
- "description": "### ModelBindings Factory\n\nCreates type-safe decorators bound to a specific FieldNode model.\nUse this to bind component properties and methods to model events.\n\nUsage:\n```typescript\nimport { ModelBindings } from \"@x/furo/open-models/ModelDecorators\";\nimport { CubeEntityModel } from \"./CubeEntityModel\";\n\nconst cubeModel = ModelBindings(CubeEntityModel.model);\n\nclass MyComponent extends LitElement {\n // Triggers re-render on any model update",
2739
- "return": {
2740
- "type": {
2741
- "text": ""
2742
- }
2743
- }
2744
- }
2745
- ],
2746
- "exports": [
2747
- {
2748
- "kind": "js",
2749
- "name": "ModelBindings",
2750
- "declaration": {
2751
- "name": "ModelBindings",
2752
- "module": "src/decorators/ModelDecorators.ts"
2753
- }
2754
- }
2755
- ]
2756
- },
2757
- {
2758
- "kind": "javascript-module",
2759
- "path": "dist/decorators/SchemaBuilder.js",
2760
- "declarations": [
2761
- {
2762
- "kind": "class",
2763
- "description": "",
2764
- "name": "SchemaBuilder",
2765
- "members": [
2766
- {
2767
- "kind": "method",
2768
- "name": "generate",
2769
- "privacy": "public",
2770
- "static": true,
2771
- "return": {
2772
- "type": {
2773
- "text": "JSONSchema7"
2774
- }
2775
- },
2776
- "parameters": [
2777
- {
2778
- "name": "model",
2779
- "type": {
2780
- "text": "FieldNode"
2781
- }
2782
- }
2783
- ]
2784
- },
2785
- {
2786
- "kind": "method",
2787
- "name": "getProps",
2788
- "privacy": "private",
2789
- "static": true,
2790
- "return": {
2791
- "type": {
2792
- "text": "Record<string, JSONSchema7Definition>"
2793
- }
2794
- },
2795
- "parameters": [
2796
- {
2797
- "name": "model",
2798
- "type": {
2799
- "text": "FieldNode"
2800
- }
2801
- }
2802
- ]
2803
- },
2804
- {
2805
- "kind": "method",
2806
- "name": "getRequiredFields",
2807
- "privacy": "private",
2808
- "static": true,
2809
- "return": {
2810
- "type": {
2811
- "text": "string[]"
2812
- }
2813
- },
2814
- "parameters": [
2815
- {
2816
- "name": "descriptors",
2817
- "type": {
2818
- "text": "FieldDescriptor[]"
2819
- }
2820
- }
2821
- ]
2822
- },
2823
- {
2824
- "kind": "method",
2825
- "name": "getConstraints",
2826
- "privacy": "private",
2827
- "static": true,
2828
- "parameters": [
2829
- {
2830
- "name": "constraints",
2831
- "type": {
2832
- "text": "FieldConstraints | undefined"
2833
- }
2834
- }
2835
- ]
2836
- },
2837
- {
2838
- "kind": "method",
2839
- "name": "createFieldNodeFromSchema",
2840
- "privacy": "public",
2841
- "static": true,
2842
- "return": {
2843
- "type": {
2844
- "text": "FieldNode"
2845
- }
2846
- },
2847
- "parameters": [
2848
- {
2849
- "name": "schema",
2850
- "type": {
2851
- "text": "FieldNodeSchema"
2852
- }
2853
- }
2854
- ]
2855
- }
2856
- ]
2857
- }
2858
- ],
2859
- "exports": [
2860
- {
2861
- "kind": "js",
2862
- "name": "SchemaBuilder",
2863
- "declaration": {
2864
- "name": "SchemaBuilder",
2865
- "module": "src/decorators/SchemaBuilder.ts"
2866
- }
2867
- }
2868
- ]
2869
- },
2870
- {
2871
- "kind": "javascript-module",
2872
- "path": "dist/decorators/ServiceDecorators.js",
2873
- "declarations": [
2874
- {
2875
- "kind": "function",
2876
- "name": "ServiceBindings",
2877
- "parameters": [
2878
- {
2879
- "name": "service",
2880
- "type": {
2881
- "text": "EventTarget"
2882
- },
2883
- "description": "The EventTarget service to bind to"
2884
- }
2885
- ],
2886
- "description": "### ServiceBindings Factory\n\nCreates type-safe decorators bound to a specific service instance.\nUse this to bind component properties and methods to service events.\n\nThe factory is generic and works with any `EventTarget`.\nEvent types and their detail payloads are type-checked at compile time\nvia the `TEventMap` type parameter.\n\nUsage:\n```typescript\nimport { cubeEntityService } from \"./CubeEntityService\";\nimport { ServiceBindings } from \"./ServiceDecorators\";\n\nconst cube = ServiceBindings(cubeEntityService);\n\nclass MyComponent extends LitElement {\n // Property binding - type-safe event name, auto-extracts from detail",
2887
- "return": {
2888
- "type": {
2889
- "text": ""
2890
- }
2891
- }
2892
- }
2893
- ],
2894
- "exports": [
2895
- {
2896
- "kind": "js",
2897
- "name": "ServiceBindings",
2898
- "declaration": {
2899
- "name": "ServiceBindings",
2900
- "module": "src/decorators/ServiceDecorators.ts"
2901
- }
2902
- }
2903
- ]
2904
- },
2905
2621
  {
2906
2622
  "kind": "javascript-module",
2907
2623
  "path": "dist/proxies/ARRAY.js",
@@ -7590,6 +7306,290 @@
7590
7306
  }
7591
7307
  ]
7592
7308
  },
7309
+ {
7310
+ "kind": "javascript-module",
7311
+ "path": "dist/decorators/DefaultServiceEventHandlers.js",
7312
+ "declarations": [
7313
+ {
7314
+ "kind": "function",
7315
+ "name": "DefaultServiceEventHandlers",
7316
+ "parameters": [
7317
+ {
7318
+ "name": "dispatch",
7319
+ "type": {
7320
+ "text": "DispatchFn"
7321
+ },
7322
+ "description": "Function to dispatch events (typically bound to the service's dispatchEvent)"
7323
+ },
7324
+ {
7325
+ "name": "options",
7326
+ "default": "{}",
7327
+ "type": {
7328
+ "text": "DefaultServiceEventHandlersOptions"
7329
+ },
7330
+ "description": "Optional configuration"
7331
+ }
7332
+ ],
7333
+ "description": "### DefaultServiceEventHandlers\n\nCreates default service handlers that dispatch standard events.\nUse this to reduce boilerplate when setting up service handlers.\n\nThe `onResponse` handler is intentionally NOT included - you must provide your own\nimplementation since response handling is typically service-specific.\n\nUsage:\n```typescript\nclass MyEntityService extends EventTarget {\n private dispatch = createDispatch(this);\n\n setupHandlers() {\n this.service.Get.setHandlers({\n ...DefaultServiceEventHandlers(this.dispatch),\n onResponse: (response, serverResponse) => {\n // Your custom response handling\n this.entity.fromLiteral(response.entity);\n this.dispatch(\"response-received\", { response, serverResponse });\n },\n });\n }\n}\n```\n\nWith loading check:\n```typescript\nthis.service.Get.setHandlers({\n ...DefaultServiceEventHandlers(this.dispatch, {\n isLoading: () => this.service.Get.isLoading || this.service.Update.isLoading,\n }),\n onResponse: (response, serverResponse) => { ... },\n});\n```",
7334
+ "return": {
7335
+ "type": {
7336
+ "text": ""
7337
+ }
7338
+ }
7339
+ },
7340
+ {
7341
+ "kind": "function",
7342
+ "name": "CreateDispatch",
7343
+ "return": {
7344
+ "type": {
7345
+ "text": ""
7346
+ }
7347
+ },
7348
+ "parameters": [
7349
+ {
7350
+ "name": "target",
7351
+ "type": {
7352
+ "text": "EventTarget"
7353
+ },
7354
+ "description": "The EventTarget to dispatch events on"
7355
+ }
7356
+ ],
7357
+ "description": "### createDispatch\n\nHelper to create a typed dispatch function for an EventTarget.\n\nUsage:\n```typescript\nclass MyService extends EventTarget {\n private dispatch = createDispatch(this);\n\n doSomething() {\n this.dispatch(\"busy-changed\", { busy: true });\n }\n}\n```"
7358
+ }
7359
+ ],
7360
+ "exports": [
7361
+ {
7362
+ "kind": "js",
7363
+ "name": "DefaultServiceEventHandlers",
7364
+ "declaration": {
7365
+ "name": "DefaultServiceEventHandlers",
7366
+ "module": "src/decorators/DefaultServiceEventHandlers.ts"
7367
+ }
7368
+ },
7369
+ {
7370
+ "kind": "js",
7371
+ "name": "CreateDispatch",
7372
+ "declaration": {
7373
+ "name": "CreateDispatch",
7374
+ "module": "src/decorators/DefaultServiceEventHandlers.ts"
7375
+ }
7376
+ }
7377
+ ]
7378
+ },
7379
+ {
7380
+ "kind": "javascript-module",
7381
+ "path": "dist/decorators/EntityServiceTypes.js",
7382
+ "declarations": [],
7383
+ "exports": []
7384
+ },
7385
+ {
7386
+ "kind": "javascript-module",
7387
+ "path": "dist/decorators/FieldBindings.js",
7388
+ "declarations": [
7389
+ {
7390
+ "kind": "variable",
7391
+ "name": "fieldBindings",
7392
+ "type": {
7393
+ "text": "object"
7394
+ },
7395
+ "default": "{ /** * Decorator for the `model` property. * * Handles: * - Binding/unbinding when model changes * - Resolving reader/writer functions based on model type * - Calling reader on model value changes * - Providing `writeToModel()` method */ model() { return function modelDecorator(target: object, propertyKey: string) { const ctor = target.constructor as typeof ReactiveElement; // Patch lifecycle patchLifecycle(ctor); // Add writeToModel helper method if (!Object.prototype.hasOwnProperty.call(target, \"writeToModel\")) { Object.defineProperty(target, \"writeToModel\", { value: function writeToModel(this: LitElement & Record<symbol, (() => void) | undefined>) { const writeFn = this[MODEL_WRITE_FN]; if (writeFn) { try { writeFn(); } catch (e) { console.error(\"Failed to write to model:\", e); } } }, writable: false, enumerable: false, configurable: true, }); } // Create getter/setter for the model property Object.defineProperty(target, propertyKey, { get(this: LitElement & Record<symbol, FieldNodeLike | undefined>): FieldNodeLike | undefined { return this[CURRENT_MODEL]; }, set(this: LitElement & BindableComponent & Record<symbol, FieldNodeLike | (() => void) | undefined>, value: FieldNodeLike | undefined) { const oldModel = this[CURRENT_MODEL] as FieldNodeLike | undefined; if (value === oldModel) return; // Unbind from old model if (oldModel) { unbindFromModel(this, oldModel); } // Store new model this[CURRENT_MODEL] = value; // Resolve reader/writer functions based on type if (value) { const typeName = value.__meta?.typeName ?? \"primitives.STRING\"; // Resolve reader // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) const reader = this.modelReaders?.get(typeName); if (reader) { this[MODEL_READ_FN] = reader.bind(this); } else { // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) console.warn(`No modelReader for type \"${typeName}\". Available: ${[...(this.modelReaders?.keys() ?? [])].join(\", \")}`); this[MODEL_READ_FN] = undefined; } // Resolve writer // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) const writer = this.modelWriters?.get(typeName); if (writer) { this[MODEL_WRITE_FN] = writer.bind(this); } else { // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) console.warn(`No modelWriter for type \"${typeName}\". Available: ${[...(this.modelWriters?.keys() ?? [])].join(\", \")}`); this[MODEL_WRITE_FN] = undefined; } } else { this[MODEL_READ_FN] = undefined; this[MODEL_WRITE_FN] = undefined; } // Bind to new model (if connected) if (value && this.isConnected) { bindToModel(this, value); } // Trigger Lit update this.requestUpdate(); }, enumerable: true, configurable: true, }); }; }, /** * Binds a method to an event on the model. * When the event fires, the method is called with the event detail. * * @param eventType - The event type to listen for */ onEvent(eventType: ModelEventType) { return function onEventDecorator(target: object, propertyKey: string, descriptor: PropertyDescriptor) { // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment const originalMethod = descriptor.value; const ctor = target.constructor as typeof ReactiveElement; let events = (ctor as unknown as Record<symbol, FieldEventMeta[]>)[FIELD_EVENTS]; // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) if (!events) { events = []; (ctor as unknown as Record<symbol, FieldEventMeta[]>)[FIELD_EVENTS] = events; } // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment events.push({ propertyKey, eventType, method: originalMethod }); patchLifecycle(ctor); }; }, /** * Decorator that marks a method to be called once after a new model is assigned and bound. * * Useful for one-time setup like setting a11y attributes, placeholders, or constraints * based on the model's type. * * @example * ```typescript * @fieldBindings.onInit() * protected init() { * this.accessibleName = this.model?.__label ?? \"Toggle\"; * } * ``` */ onInit() { return function onInitDecorator(target: object, propertyKey: string, descriptor: PropertyDescriptor) { // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment const originalMethod = descriptor.value; const ctor = target.constructor as typeof ReactiveElement; // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type let inits = (ctor as unknown as Record<symbol, { propertyKey: string; method: Function }[]>)[FIELD_INIT_METHODS]; // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- runtime data may not match types (REST API input) if (!inits) { inits = []; // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type (ctor as unknown as Record<symbol, { propertyKey: string; method: Function }[]>)[FIELD_INIT_METHODS] = inits; } // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment inits.push({ propertyKey, method: originalMethod }); patchLifecycle(ctor); }; }, }",
7396
+ "description": "### fieldBindings\n\nDecorators for creating reusable components that bind to FieldNode models.\n\nThe component provides `modelReaders` and `modelWriters` maps keyed by\n`__meta.typeName`. The decorator handles:\n- Binding/unbinding on model change\n- Calling the correct reader when model value changes\n- Providing `writeToModel()` method that calls the correct writer"
7397
+ }
7398
+ ],
7399
+ "exports": [
7400
+ {
7401
+ "kind": "js",
7402
+ "name": "fieldBindings",
7403
+ "declaration": {
7404
+ "name": "fieldBindings",
7405
+ "module": "src/decorators/FieldBindings.ts"
7406
+ }
7407
+ }
7408
+ ]
7409
+ },
7410
+ {
7411
+ "kind": "javascript-module",
7412
+ "path": "dist/decorators/ModelDecorators.js",
7413
+ "declarations": [
7414
+ {
7415
+ "kind": "function",
7416
+ "name": "ModelBindings",
7417
+ "parameters": [
7418
+ {
7419
+ "name": "model",
7420
+ "type": {
7421
+ "text": "FieldNodeLike"
7422
+ },
7423
+ "description": "The FieldNode model to bind to"
7424
+ }
7425
+ ],
7426
+ "description": "### ModelBindings Factory\n\nCreates type-safe decorators bound to a specific FieldNode model.\nUse this to bind component properties and methods to model events.\n\nUsage:\n```typescript\nimport { ModelBindings } from \"@x/furo/open-models/ModelDecorators\";\nimport { CubeEntityModel } from \"./CubeEntityModel\";\n\nconst cubeModel = ModelBindings(CubeEntityModel.model);\n\nclass MyComponent extends LitElement {\n // Triggers re-render on any model update",
7427
+ "return": {
7428
+ "type": {
7429
+ "text": ""
7430
+ }
7431
+ }
7432
+ }
7433
+ ],
7434
+ "exports": [
7435
+ {
7436
+ "kind": "js",
7437
+ "name": "ModelBindings",
7438
+ "declaration": {
7439
+ "name": "ModelBindings",
7440
+ "module": "src/decorators/ModelDecorators.ts"
7441
+ }
7442
+ }
7443
+ ]
7444
+ },
7445
+ {
7446
+ "kind": "javascript-module",
7447
+ "path": "dist/decorators/SchemaBuilder.js",
7448
+ "declarations": [
7449
+ {
7450
+ "kind": "class",
7451
+ "description": "",
7452
+ "name": "SchemaBuilder",
7453
+ "members": [
7454
+ {
7455
+ "kind": "method",
7456
+ "name": "generate",
7457
+ "privacy": "public",
7458
+ "static": true,
7459
+ "return": {
7460
+ "type": {
7461
+ "text": "JSONSchema7"
7462
+ }
7463
+ },
7464
+ "parameters": [
7465
+ {
7466
+ "name": "model",
7467
+ "type": {
7468
+ "text": "FieldNode"
7469
+ }
7470
+ }
7471
+ ]
7472
+ },
7473
+ {
7474
+ "kind": "method",
7475
+ "name": "getProps",
7476
+ "privacy": "private",
7477
+ "static": true,
7478
+ "return": {
7479
+ "type": {
7480
+ "text": "Record<string, JSONSchema7Definition>"
7481
+ }
7482
+ },
7483
+ "parameters": [
7484
+ {
7485
+ "name": "model",
7486
+ "type": {
7487
+ "text": "FieldNode"
7488
+ }
7489
+ }
7490
+ ]
7491
+ },
7492
+ {
7493
+ "kind": "method",
7494
+ "name": "getRequiredFields",
7495
+ "privacy": "private",
7496
+ "static": true,
7497
+ "return": {
7498
+ "type": {
7499
+ "text": "string[]"
7500
+ }
7501
+ },
7502
+ "parameters": [
7503
+ {
7504
+ "name": "descriptors",
7505
+ "type": {
7506
+ "text": "FieldDescriptor[]"
7507
+ }
7508
+ }
7509
+ ]
7510
+ },
7511
+ {
7512
+ "kind": "method",
7513
+ "name": "getConstraints",
7514
+ "privacy": "private",
7515
+ "static": true,
7516
+ "parameters": [
7517
+ {
7518
+ "name": "constraints",
7519
+ "type": {
7520
+ "text": "FieldConstraints | undefined"
7521
+ }
7522
+ }
7523
+ ]
7524
+ },
7525
+ {
7526
+ "kind": "method",
7527
+ "name": "createFieldNodeFromSchema",
7528
+ "privacy": "public",
7529
+ "static": true,
7530
+ "return": {
7531
+ "type": {
7532
+ "text": "FieldNode"
7533
+ }
7534
+ },
7535
+ "parameters": [
7536
+ {
7537
+ "name": "schema",
7538
+ "type": {
7539
+ "text": "FieldNodeSchema"
7540
+ }
7541
+ }
7542
+ ]
7543
+ }
7544
+ ]
7545
+ }
7546
+ ],
7547
+ "exports": [
7548
+ {
7549
+ "kind": "js",
7550
+ "name": "SchemaBuilder",
7551
+ "declaration": {
7552
+ "name": "SchemaBuilder",
7553
+ "module": "src/decorators/SchemaBuilder.ts"
7554
+ }
7555
+ }
7556
+ ]
7557
+ },
7558
+ {
7559
+ "kind": "javascript-module",
7560
+ "path": "dist/decorators/ServiceDecorators.js",
7561
+ "declarations": [
7562
+ {
7563
+ "kind": "function",
7564
+ "name": "ServiceBindings",
7565
+ "parameters": [
7566
+ {
7567
+ "name": "service",
7568
+ "type": {
7569
+ "text": "EventTarget"
7570
+ },
7571
+ "description": "The EventTarget service to bind to"
7572
+ }
7573
+ ],
7574
+ "description": "### ServiceBindings Factory\n\nCreates type-safe decorators bound to a specific service instance.\nUse this to bind component properties and methods to service events.\n\nThe factory is generic and works with any `EventTarget`.\nEvent types and their detail payloads are type-checked at compile time\nvia the `TEventMap` type parameter.\n\nUsage:\n```typescript\nimport { cubeEntityService } from \"./CubeEntityService\";\nimport { ServiceBindings } from \"./ServiceDecorators\";\n\nconst cube = ServiceBindings(cubeEntityService);\n\nclass MyComponent extends LitElement {\n // Property binding - type-safe event name, auto-extracts from detail",
7575
+ "return": {
7576
+ "type": {
7577
+ "text": ""
7578
+ }
7579
+ }
7580
+ }
7581
+ ],
7582
+ "exports": [
7583
+ {
7584
+ "kind": "js",
7585
+ "name": "ServiceBindings",
7586
+ "declaration": {
7587
+ "name": "ServiceBindings",
7588
+ "module": "src/decorators/ServiceDecorators.ts"
7589
+ }
7590
+ }
7591
+ ]
7592
+ },
7593
7593
  {
7594
7594
  "kind": "javascript-module",
7595
7595
  "path": "dist/primitives/BOOLEAN.js",
@@ -26622,7 +26622,7 @@
26622
26622
  "kind": "field",
26623
26623
  "name": "value",
26624
26624
  "type": {
26625
- "text": "number"
26625
+ "text": "number | null"
26626
26626
  }
26627
26627
  },
26628
26628
  {
@@ -26632,7 +26632,7 @@
26632
26632
  "text": "number | null"
26633
26633
  },
26634
26634
  "privacy": "public",
26635
- "default": "0"
26635
+ "default": "null"
26636
26636
  },
26637
26637
  {
26638
26638
  "kind": "method",
@@ -31690,7 +31690,7 @@
31690
31690
  "kind": "field",
31691
31691
  "name": "value",
31692
31692
  "type": {
31693
- "text": "number"
31693
+ "text": "number | null"
31694
31694
  }
31695
31695
  },
31696
31696
  {
@@ -31700,7 +31700,7 @@
31700
31700
  "text": "number | null"
31701
31701
  },
31702
31702
  "privacy": "public",
31703
- "default": "0"
31703
+ "default": "null"
31704
31704
  },
31705
31705
  {
31706
31706
  "kind": "method",
@@ -32957,7 +32957,7 @@
32957
32957
  "kind": "field",
32958
32958
  "name": "value",
32959
32959
  "type": {
32960
- "text": "number"
32960
+ "text": "number | null"
32961
32961
  }
32962
32962
  },
32963
32963
  {
@@ -32967,7 +32967,7 @@
32967
32967
  "text": "number | null"
32968
32968
  },
32969
32969
  "privacy": "public",
32970
- "default": "0"
32970
+ "default": "null"
32971
32971
  },
32972
32972
  {
32973
32973
  "kind": "method",
@@ -34224,7 +34224,7 @@
34224
34224
  "kind": "field",
34225
34225
  "name": "value",
34226
34226
  "type": {
34227
- "text": "bigint"
34227
+ "text": "bigint | null"
34228
34228
  }
34229
34229
  },
34230
34230
  {
@@ -34234,7 +34234,7 @@
34234
34234
  "text": "bigint | null"
34235
34235
  },
34236
34236
  "privacy": "public",
34237
- "default": "0n"
34237
+ "default": "null"
34238
34238
  },
34239
34239
  {
34240
34240
  "kind": "method",
@@ -40559,7 +40559,7 @@
40559
40559
  "kind": "field",
40560
40560
  "name": "value",
40561
40561
  "type": {
40562
- "text": "number"
40562
+ "text": "number | null"
40563
40563
  }
40564
40564
  },
40565
40565
  {
@@ -40569,7 +40569,7 @@
40569
40569
  "text": "number | null"
40570
40570
  },
40571
40571
  "privacy": "public",
40572
- "default": "0"
40572
+ "default": "null"
40573
40573
  },
40574
40574
  {
40575
40575
  "kind": "method",
@@ -41826,7 +41826,7 @@
41826
41826
  "kind": "field",
41827
41827
  "name": "value",
41828
41828
  "type": {
41829
- "text": "number"
41829
+ "text": "number | null"
41830
41830
  }
41831
41831
  },
41832
41832
  {
@@ -41836,7 +41836,7 @@
41836
41836
  "text": "number | null"
41837
41837
  },
41838
41838
  "privacy": "public",
41839
- "default": "0"
41839
+ "default": "null"
41840
41840
  },
41841
41841
  {
41842
41842
  "kind": "method",