@kosdev-code/kos-ui-sdk 2.0.45 → 2.0.46
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/common/events/eventBus.d.ts +0 -30
- package/common/events/eventBus.d.ts.map +1 -1
- package/common/events/eventBus.functional.d.ts +0 -48
- package/common/events/eventBus.functional.d.ts.map +1 -1
- package/common/events/eventBus.state.d.ts +0 -33
- package/common/events/eventBus.state.d.ts.map +1 -1
- package/core/core/decorators/index.d.ts +0 -11
- package/core/core/decorators/index.d.ts.map +1 -1
- package/core/core/decorators/kos-child.d.ts +0 -2
- package/core/core/decorators/kos-child.d.ts.map +1 -1
- package/core/core/decorators/kos-companion.d.ts +8 -158
- package/core/core/decorators/kos-companion.d.ts.map +1 -1
- package/core/core/decorators/kos-context.d.ts +0 -6
- package/core/core/decorators/kos-context.d.ts.map +1 -1
- package/core/core/decorators/kos-http-decorators.d.ts +0 -15
- package/core/core/decorators/kos-http-decorators.d.ts.map +1 -1
- package/core/core/decorators/kos-log.d.ts +0 -4
- package/core/core/decorators/kos-log.d.ts.map +1 -1
- package/core/core/decorators/kos-model-effect.d.ts +0 -9
- package/core/core/decorators/kos-model-effect.d.ts.map +1 -1
- package/core/core/decorators/kos-parent.d.ts +0 -4
- package/core/core/decorators/kos-parent.d.ts.map +1 -1
- package/core/core/decorators/kos-reference.d.ts +0 -9
- package/core/core/decorators/kos-reference.d.ts.map +1 -1
- package/core/core/decorators/kos-topic-handler-flow-control.d.ts +1 -17
- package/core/core/decorators/kos-topic-handler-flow-control.d.ts.map +1 -1
- package/core/core/decorators/kosDependency.d.ts +1 -4
- package/core/core/decorators/kosDependency.d.ts.map +1 -1
- package/core/core/decorators/kosModel.d.ts +2 -17
- package/core/core/decorators/kosModel.d.ts.map +1 -1
- package/core/core/decorators/kosSubscribe.d.ts +0 -9
- package/core/core/decorators/kosSubscribe.d.ts.map +1 -1
- package/core/core/decorators/kosTopicHandler.d.ts +5 -87
- package/core/core/decorators/kosTopicHandler.d.ts.map +1 -1
- package/core/core/decorators/propKeys.d.ts +0 -14
- package/core/core/decorators/propKeys.d.ts.map +1 -1
- package/core/core/decorators/resolve-parameters.d.ts.map +1 -1
- package/core/core/extension/extension-manager.d.ts +4 -64
- package/core/core/extension/extension-manager.d.ts.map +1 -1
- package/core/core/extension/initialize-extension.d.ts +0 -24
- package/core/core/extension/initialize-extension.d.ts.map +1 -1
- package/core/core/extension/plugin-extension-manager.d.ts +0 -11
- package/core/core/extension/plugin-extension-manager.d.ts.map +1 -1
- package/core/core/kos-container-model.d.ts +0 -188
- package/core/core/kos-container-model.d.ts.map +1 -1
- package/core/core/kos-data-container.d.ts +1 -93
- package/core/core/kos-data-container.d.ts.map +1 -1
- package/core/core/kos-registration.d.ts.map +1 -1
- package/core/core/kos-singleton-registration.d.ts.map +1 -1
- package/core/core/kosCore.d.ts.map +1 -1
- package/core/core/kosModel.d.ts +2 -55
- package/core/core/kosModel.d.ts.map +1 -1
- package/core/core/kosModelManager.d.ts +1 -11
- package/core/core/kosModelManager.d.ts.map +1 -1
- package/core/core/log/log.d.ts.map +1 -1
- package/core/core/model/apply-kos-dev-tool-support.d.ts.map +1 -1
- package/core/core/model/kos-fsm-manager.d.ts +4 -1
- package/core/core/model/kos-fsm-manager.d.ts.map +1 -1
- package/core/core/model/kos-model-component-factory.d.ts +0 -4
- package/core/core/model/kos-model-component-factory.d.ts.map +1 -1
- package/core/core/model/kos-offline-queue.d.ts +1 -78
- package/core/core/model/kos-offline-queue.d.ts.map +1 -1
- package/core/core/model/kos-online-lifecycle-manager.d.ts.map +1 -1
- package/core/core/model/kos-subscription-manager.d.ts +0 -20
- package/core/core/model/kos-subscription-manager.d.ts.map +1 -1
- package/core/core/model/model-introspection-utils.d.ts +0 -1
- package/core/core/model/model-introspection-utils.d.ts.map +1 -1
- package/core/core/model-instantiator.d.ts +0 -19
- package/core/core/model-instantiator.d.ts.map +1 -1
- package/core/core/registration/index.d.ts +0 -1
- package/core/core/registration/index.d.ts.map +1 -1
- package/core/core/services/browser-router.d.ts.map +1 -1
- package/core/core/transport/webSocketTransport.d.ts +1 -2
- package/core/core/transport/webSocketTransport.d.ts.map +1 -1
- package/core/core/types/registration.d.ts +0 -7
- package/core/core/types/registration.d.ts.map +1 -1
- package/core/index.d.ts +1 -2
- package/core/index.d.ts.map +1 -1
- package/core/types/index.d.ts +0 -1
- package/core/types/index.d.ts.map +1 -1
- package/core/types/kos-dependency.d.ts +1 -48
- package/core/types/kos-dependency.d.ts.map +1 -1
- package/core/types/utils/kos-fetch.d.ts +0 -121
- package/core/types/utils/kos-fetch.d.ts.map +1 -1
- package/core/util/api-request-id.d.ts +0 -4
- package/core/util/api-request-id.d.ts.map +1 -1
- package/core/util/apply-mixins.d.ts +0 -4
- package/core/util/apply-mixins.d.ts.map +1 -1
- package/core/util/array-utils.d.ts +0 -4
- package/core/util/array-utils.d.ts.map +1 -1
- package/core/util/container-utils.d.ts +11 -264
- package/core/util/container-utils.d.ts.map +1 -1
- package/core/util/date-utils.d.ts +0 -29
- package/core/util/date-utils.d.ts.map +1 -1
- package/core/util/debounce.d.ts +0 -3
- package/core/util/debounce.d.ts.map +1 -1
- package/core/util/feature-flags.d.ts +0 -19
- package/core/util/feature-flags.d.ts.map +1 -1
- package/core/util/get-query-params.d.ts +0 -4
- package/core/util/get-query-params.d.ts.map +1 -1
- package/core/util/hsl-to-hex.d.ts +0 -16
- package/core/util/hsl-to-hex.d.ts.map +1 -1
- package/core/util/index.d.ts +0 -3
- package/core/util/index.d.ts.map +1 -1
- package/core/util/kos-config-init.d.ts +0 -37
- package/core/util/kos-config-init.d.ts.map +1 -1
- package/core/util/kos-data-mapper-utils.d.ts +0 -9
- package/core/util/kos-data-mapper-utils.d.ts.map +1 -1
- package/core/util/kos-fetch.d.ts +0 -12
- package/core/util/kos-fetch.d.ts.map +1 -1
- package/core/util/kos-message-utils.d.ts +0 -88
- package/core/util/kos-message-utils.d.ts.map +1 -1
- package/core/util/kos-model-utils.d.ts +0 -46
- package/core/util/kos-model-utils.d.ts.map +1 -1
- package/core/util/kos-model-visitor.d.ts +0 -2
- package/core/util/kos-model-visitor.d.ts.map +1 -1
- package/core/util/kos-service-request.d.ts +3 -43
- package/core/util/kos-service-request.d.ts.map +1 -1
- package/core/util/log-utils.d.ts +0 -12
- package/core/util/log-utils.d.ts.map +1 -1
- package/core/util/middleware.d.ts +0 -15
- package/core/util/middleware.d.ts.map +1 -1
- package/core/util/model-attribute-utils.d.ts +0 -7
- package/core/util/model-attribute-utils.d.ts.map +1 -1
- package/core/util/model-factory.d.ts +0 -4
- package/core/util/model-factory.d.ts.map +1 -1
- package/core/util/model-registration-utils.d.ts +0 -8
- package/core/util/model-registration-utils.d.ts.map +1 -1
- package/core/util/model-utils.d.ts +29 -40
- package/core/util/model-utils.d.ts.map +1 -1
- package/core/util/observable-proxy-map.d.ts +0 -11
- package/core/util/observable-proxy-map.d.ts.map +1 -1
- package/core/util/paired-client-heartbeat.d.ts +0 -2
- package/core/util/paired-client-heartbeat.d.ts.map +1 -1
- package/core/util/pipe.d.ts +0 -4
- package/core/util/pipe.d.ts.map +1 -1
- package/core/util/retry-with-exponential-backoff.d.ts +0 -3
- package/core/util/retry-with-exponential-backoff.d.ts.map +1 -1
- package/core/util/service-factory.d.ts +0 -10
- package/core/util/service-factory.d.ts.map +1 -1
- package/core/util/session-utils.d.ts +0 -8
- package/core/util/session-utils.d.ts.map +1 -1
- package/core/util/wait-for-request.d.ts +0 -16
- package/core/util/wait-for-request.d.ts.map +1 -1
- package/core/util/when-ready.d.ts +0 -3
- package/core/util/when-ready.d.ts.map +1 -1
- package/index.cjs +123 -26909
- package/index.cjs.map +1 -1
- package/index.d.cts +3 -6
- package/index.d.ts +3 -6
- package/index.d.ts.map +1 -1
- package/index.js +13460 -25275
- package/index.js.map +1 -1
- package/models/constants/index.d.ts +1 -3
- package/models/constants/index.d.ts.map +1 -1
- package/models/decorators/future-service.d.ts +2 -27
- package/models/decorators/future-service.d.ts.map +1 -1
- package/models/models/browser-router/browser-router-model.d.ts +1 -80
- package/models/models/browser-router/browser-router-model.d.ts.map +1 -1
- package/models/models/browser-router/types/index.d.ts +1 -26
- package/models/models/canvas-dispatcher/types/index.d.ts +0 -5
- package/models/models/canvas-renderer/types/index.d.ts +0 -5
- package/models/models/config-bean/config-bean-model-builder.d.ts +2 -4
- package/models/models/config-bean/config-bean-model-builder.d.ts.map +1 -1
- package/models/models/config-bean/config-bean-model.d.ts +13 -117
- package/models/models/config-bean/config-bean-model.d.ts.map +1 -1
- package/models/models/config-bean/config-bean-types.d.ts +3 -6
- package/models/models/config-bean/config-bean-types.d.ts.map +1 -1
- package/models/models/config-bean-prop/config-bean-prop-model.d.ts +1 -112
- package/models/models/config-bean-prop/config-bean-prop-model.d.ts.map +1 -1
- package/models/models/config-bean-prop/types/index.d.ts +19 -301
- package/models/models/device/device-model.d.ts +9 -219
- package/models/models/device/device-model.d.ts.map +1 -1
- package/models/models/device/device-registration.d.ts +48 -61
- package/models/models/device/device-registration.d.ts.map +1 -1
- package/models/models/device/types/index.d.ts +0 -42
- package/models/models/future/future-aware.d.ts +0 -82
- package/models/models/future/future-aware.d.ts.map +1 -1
- package/models/models/future/future-model.d.ts +5 -34
- package/models/models/future/future-model.d.ts.map +1 -1
- package/models/models/future/future-types.d.ts +9 -202
- package/models/models/future/future-types.d.ts.map +1 -1
- package/models/models/future-container/future-container-model.d.ts +2 -2
- package/models/models/index.d.ts +0 -1
- package/models/models/index.d.ts.map +1 -1
- package/models/models/key-value/index.d.ts +0 -4
- package/models/models/key-value/index.d.ts.map +1 -1
- package/models/models/key-value/key-value-model.d.ts +0 -111
- package/models/models/key-value/key-value-model.d.ts.map +1 -1
- package/models/models/key-value/services/key-value-services.d.ts +2 -124
- package/models/models/key-value/services/key-value-services.d.ts.map +1 -1
- package/models/models/key-value/types/index.d.ts +0 -57
- package/models/models/kos-log-manager/kos-log-manager-model.d.ts +14 -61
- package/models/models/kos-log-manager/kos-log-manager-model.d.ts.map +1 -1
- package/models/models/kos-log-manager/types/index.d.ts +0 -191
- package/models/models/kos-time/kos-time-model.d.ts +0 -64
- package/models/models/kos-time/kos-time-model.d.ts.map +1 -1
- package/models/models/kos-time/types/index.d.ts +0 -83
- package/models/models/log-block/log-block-container-model.d.ts +0 -132
- package/models/models/log-block/log-block-container-model.d.ts.map +1 -1
- package/models/models/log-block/log-block-model.d.ts +0 -185
- package/models/models/log-block/log-block-model.d.ts.map +1 -1
- package/models/models/log-block/types/index.d.ts +0 -133
- package/models/models/log-stream/index.d.ts +2 -6
- package/models/models/log-stream/index.d.ts.map +1 -1
- package/models/models/log-stream/log-stream-container-model.d.ts +0 -62
- package/models/models/log-stream/log-stream-container-model.d.ts.map +1 -1
- package/models/models/log-stream/log-stream-model.d.ts +0 -55
- package/models/models/log-stream/log-stream-model.d.ts.map +1 -1
- package/models/models/log-stream/services/log-stream-services.d.ts +1 -2
- package/models/models/log-stream/services/log-stream-services.d.ts.map +1 -1
- package/models/models/log-stream/types/index.d.ts +0 -79
- package/models/models/network-interface/index.d.ts +2 -6
- package/models/models/network-interface/index.d.ts.map +1 -1
- package/models/models/network-interface/network-interface-container-model.d.ts +0 -62
- package/models/models/network-interface/network-interface-container-model.d.ts.map +1 -1
- package/models/models/network-interface/network-interface-container-registration.d.ts +1 -2
- package/models/models/network-interface/network-interface-container-registration.d.ts.map +1 -1
- package/models/models/network-interface/network-interface-model.d.ts +0 -77
- package/models/models/network-interface/network-interface-model.d.ts.map +1 -1
- package/models/models/network-interface/network-interface-registration.d.ts +1 -2
- package/models/models/network-interface/network-interface-registration.d.ts.map +1 -1
- package/models/models/network-interface/services/network-interface-services.d.ts +0 -54
- package/models/models/network-interface/services/network-interface-services.d.ts.map +1 -1
- package/models/models/network-interface/types/index.d.ts +0 -22
- package/models/models/ota/ota-model.d.ts +0 -79
- package/models/models/ota/ota-model.d.ts.map +1 -1
- package/models/models/ota/types/index.d.ts +0 -177
- package/models/models/region-info/region-info-model.d.ts +3 -8
- package/models/models/region-info/region-info-model.d.ts.map +1 -1
- package/models/models/region-info/services/region-info-services.d.ts +2 -2
- package/models/models/region-info/services/region-info-services.d.ts.map +1 -1
- package/models/models/region-info/types/index.d.ts +13 -191
- package/models/models/region-info/types/index.d.ts.map +1 -1
- package/models/models/region-info/utils/unit-system-utils.d.ts.map +1 -1
- package/models/models/software-info/services/software-info-services.d.ts.map +1 -1
- package/models/models/software-info/software-info-model.d.ts +2 -74
- package/models/models/software-info/software-info-model.d.ts.map +1 -1
- package/models/models/software-info/types/index.d.ts +17 -52
- package/models/models/state-bean/state-bean-model.d.ts +9 -86
- package/models/models/state-bean/state-bean-model.d.ts.map +1 -1
- package/models/models/state-bean/types/index.d.ts +6 -117
- package/models/models/state-prop/state-prop-model.d.ts +1 -78
- package/models/models/state-prop/state-prop-model.d.ts.map +1 -1
- package/models/models/state-prop/types/index.d.ts +7 -57
- package/models/models/storage-device/services/storage-device-services.d.ts +0 -1
- package/models/models/storage-device/services/storage-device-services.d.ts.map +1 -1
- package/models/models/storage-device/storage-device-container-model.d.ts +2 -289
- package/models/models/storage-device/storage-device-container-model.d.ts.map +1 -1
- package/models/models/storage-device/storage-device-model.d.ts +2 -84
- package/models/models/storage-device/storage-device-model.d.ts.map +1 -1
- package/models/models/storage-device/types/index.d.ts +0 -114
- package/models/models/studio-properties/studio-properties-model.d.ts +0 -75
- package/models/models/studio-properties/studio-properties-model.d.ts.map +1 -1
- package/models/models/studio-properties/types/index.d.ts +0 -29
- package/models/models/translation/services/translation-services.d.ts +2 -128
- package/models/models/translation/services/translation-services.d.ts.map +1 -1
- package/models/models/translation/translation-container-model.d.ts +10 -100
- package/models/models/translation/translation-container-model.d.ts.map +1 -1
- package/models/models/translation/translation-container-registration.d.ts +1 -2
- package/models/models/translation/translation-container-registration.d.ts.map +1 -1
- package/models/models/translation/translation-context.d.ts +16 -1
- package/models/models/translation/translation-context.d.ts.map +1 -1
- package/models/models/translation/translation-model.d.ts +1 -113
- package/models/models/translation/translation-model.d.ts.map +1 -1
- package/models/models/translation/types/index.d.ts +0 -343
- package/models/models/trouble/index.d.ts +1 -2
- package/models/models/trouble/index.d.ts.map +1 -1
- package/models/models/trouble/services/trouble-services.d.ts +4 -6
- package/models/models/trouble/services/trouble-services.d.ts.map +1 -1
- package/models/models/trouble/trouble-model.d.ts +1 -4
- package/models/models/trouble/trouble-model.d.ts.map +1 -1
- package/models/models/trouble/types/index.d.ts +93 -34
- package/models/models/trouble/utils/is-trouble-aware.d.ts +2 -2
- package/models/models/trouble/utils/is-trouble-aware.d.ts.map +1 -1
- package/models/models/trouble-container/index.d.ts +3 -4
- package/models/models/trouble-container/index.d.ts.map +1 -1
- package/models/models/trouble-container/trouble-container-model.d.ts +6 -10
- package/models/models/trouble-container/trouble-container-model.d.ts.map +1 -1
- package/models/models/trouble-container/trouble-container-registration.d.ts +5 -0
- package/models/models/trouble-container/trouble-container-registration.d.ts.map +1 -0
- package/models/models/trouble-container/types/index.d.ts +15 -6
- package/models/models/usb-update/types/index.d.ts +0 -10
- package/models/services/config-bean/index.d.ts +2 -2
- package/models/services/config-bean/index.d.ts.map +1 -1
- package/models/utils/client.d.ts +12 -16
- package/models/utils/client.d.ts.map +1 -1
- package/models/utils/core-registration-manager.d.ts +1 -1
- package/models/utils/core-registration-manager.d.ts.map +1 -1
- package/models/utils/extension-manager.d.ts +13 -54
- package/models/utils/extension-manager.d.ts.map +1 -1
- package/models/utils/index.d.ts +2 -3
- package/models/utils/index.d.ts.map +1 -1
- package/models/utils/kosmodel-compatible-future-mixin.d.ts +142 -0
- package/models/utils/kosmodel-compatible-future-mixin.d.ts.map +1 -0
- package/models/utils/kosmodel-interface-companion-mixin.d.ts +83 -0
- package/models/utils/kosmodel-interface-companion-mixin.d.ts.map +1 -0
- package/models/utils/service.d.ts +13 -91
- package/models/utils/service.d.ts.map +1 -1
- package/package.json +2 -16
- package/ui/contexts/kos-core-context.d.ts.map +1 -1
- package/ui/contexts/state-bean/state-bean-provider.d.ts.map +1 -1
- package/ui/hooks/device/use-device.d.ts +0 -6
- package/ui/hooks/device/use-device.d.ts.map +1 -1
- package/ui/hooks/index.d.ts +0 -1
- package/ui/hooks/index.d.ts.map +1 -1
- package/ui/hooks/kos-time/use-kos-time.d.ts +0 -6
- package/ui/hooks/kos-time/use-kos-time.d.ts.map +1 -1
- package/ui/hooks/network-interface-container/use-network-interface-container.d.ts +0 -6
- package/ui/hooks/network-interface-container/use-network-interface-container.d.ts.map +1 -1
- package/ui/hooks/ota/use-ota.d.ts +0 -6
- package/ui/hooks/ota/use-ota.d.ts.map +1 -1
- package/ui/hooks/software-info/use-software-info.d.ts +0 -6
- package/ui/hooks/software-info/use-software-info.d.ts.map +1 -1
- package/ui/hooks/state-bean/use-state-bean.d.ts +2 -2
- package/ui/hooks/state-bean/use-state-bean.d.ts.map +1 -1
- package/ui/hooks/state-bean/with-state-bean.d.ts.map +1 -1
- package/ui/hooks/storage-device-container/use-storage-device-container.d.ts +0 -6
- package/ui/hooks/storage-device-container/use-storage-device-container.d.ts.map +1 -1
- package/ui/hooks/translation-container/trans.d.ts +0 -6
- package/ui/hooks/translation-container/trans.d.ts.map +1 -1
- package/ui/hooks/translation-container/use-translation-container.d.ts +33 -10
- package/ui/hooks/translation-container/use-translation-container.d.ts.map +1 -1
- package/ui/hooks/translation-container/use-translation.d.ts +0 -7
- package/ui/hooks/translation-container/use-translation.d.ts.map +1 -1
- package/ui/hooks/translation-container/with-translation-container.d.ts +0 -6
- package/ui/hooks/translation-container/with-translation-container.d.ts.map +1 -1
- package/ui/hooks/usb-update-container/use-usb-update-container.d.ts +0 -6
- package/ui/hooks/usb-update-container/use-usb-update-container.d.ts.map +1 -1
- package/ui/hooks/use-config-bean.d.ts +0 -6
- package/ui/hooks/use-config-bean.d.ts.map +1 -1
- package/ui/hooks/use-config-property.d.ts +0 -6
- package/ui/hooks/use-config-property.d.ts.map +1 -1
- package/ui/hooks/use-kos-model.d.ts +0 -7
- package/ui/hooks/use-kos-model.d.ts.map +1 -1
- package/ui/hooks/use-kos-regions.d.ts.map +1 -1
- package/core/constants/model-constants.d.ts +0 -9
- package/core/constants/model-constants.d.ts.map +0 -1
- package/core/core/companion-instantiator.d.ts +0 -71
- package/core/core/companion-instantiator.d.ts.map +0 -1
- package/core/core/decorators/fsm-injection-utils.d.ts +0 -16
- package/core/core/decorators/fsm-injection-utils.d.ts.map +0 -1
- package/core/core/decorators/kos-container-aware.d.ts +0 -619
- package/core/core/decorators/kos-container-aware.d.ts.map +0 -1
- package/core/core/decorators/kos-execution-context.d.ts +0 -63
- package/core/core/decorators/kos-execution-context.d.ts.map +0 -1
- package/core/core/decorators/kos-future-aware.d.ts +0 -162
- package/core/core/decorators/kos-future-aware.d.ts.map +0 -1
- package/core/core/decorators/kos-logger-aware.d.ts +0 -105
- package/core/core/decorators/kos-logger-aware.d.ts.map +0 -1
- package/core/core/decorators/kos-multiple-future-aware.d.ts +0 -217
- package/core/core/decorators/kos-multiple-future-aware.d.ts.map +0 -1
- package/core/core/decorators/kos-service-request-helpers.d.ts +0 -60
- package/core/core/decorators/kos-service-request-helpers.d.ts.map +0 -1
- package/core/core/decorators/kos-service-request.d.ts +0 -498
- package/core/core/decorators/kos-service-request.d.ts.map +0 -1
- package/core/core/decorators/kos-state-machine.d.ts +0 -534
- package/core/core/decorators/kos-state-machine.d.ts.map +0 -1
- package/core/core/decorators/kos-trouble-aware.d.ts +0 -77
- package/core/core/decorators/kos-trouble-aware.d.ts.map +0 -1
- package/core/core/decorators/kos-view-model.d.ts +0 -176
- package/core/core/decorators/kos-view-model.d.ts.map +0 -1
- package/core/core/model/kos-service-request-manager.d.ts +0 -102
- package/core/core/model/kos-service-request-manager.d.ts.map +0 -1
- package/core/core/model/service-response-store.d.ts +0 -164
- package/core/core/model/service-response-store.d.ts.map +0 -1
- package/core/types/service-response-store.d.ts +0 -162
- package/core/types/service-response-store.d.ts.map +0 -1
- package/core/util/ancestor-path-visitor.d.ts +0 -60
- package/core/util/ancestor-path-visitor.d.ts.map +0 -1
- package/core/util/error-logger.d.ts +0 -16
- package/core/util/error-logger.d.ts.map +0 -1
- package/core/util/model-error-utils.d.ts +0 -61
- package/core/util/model-error-utils.d.ts.map +0 -1
- package/core/util/model-transition-utils.d.ts +0 -41
- package/core/util/model-transition-utils.d.ts.map +0 -1
- package/core/util/model-type-guards.d.ts +0 -26
- package/core/util/model-type-guards.d.ts.map +0 -1
- package/core/util/promise-utils.d.ts +0 -58
- package/core/util/promise-utils.d.ts.map +0 -1
- package/core/util/service-request-error.d.ts +0 -60
- package/core/util/service-request-error.d.ts.map +0 -1
- package/core/util/service-response.d.ts +0 -125
- package/core/util/service-response.d.ts.map +0 -1
- package/kos-models.json +0 -426
- package/models/models/config-bean/types/index.d.ts +0 -34
- package/models/models/gpio-chip/gpio-chip-container-model.d.ts +0 -25
- package/models/models/gpio-chip/gpio-chip-container-model.d.ts.map +0 -1
- package/models/models/gpio-chip/gpio-chip-model.d.ts +0 -30
- package/models/models/gpio-chip/gpio-chip-model.d.ts.map +0 -1
- package/models/models/gpio-chip/index.d.ts +0 -7
- package/models/models/gpio-chip/index.d.ts.map +0 -1
- package/models/models/gpio-chip/services/gpio-chip-services.d.ts +0 -86
- package/models/models/gpio-chip/services/gpio-chip-services.d.ts.map +0 -1
- package/models/models/gpio-chip/services/index.d.ts +0 -2
- package/models/models/gpio-chip/services/index.d.ts.map +0 -1
- package/models/models/gpio-chip/types/index.d.ts +0 -24
- package/models/models/gpio-pin/gpio-pin-container-model.d.ts +0 -23
- package/models/models/gpio-pin/gpio-pin-container-model.d.ts.map +0 -1
- package/models/models/gpio-pin/gpio-pin-model.d.ts +0 -26
- package/models/models/gpio-pin/gpio-pin-model.d.ts.map +0 -1
- package/models/models/gpio-pin/index.d.ts +0 -6
- package/models/models/gpio-pin/index.d.ts.map +0 -1
- package/models/models/gpio-pin/types/index.d.ts +0 -23
- package/models/models/kos-expression-evaluator/index.d.ts +0 -4
- package/models/models/kos-expression-evaluator/index.d.ts.map +0 -1
- package/models/models/kos-expression-evaluator/kos-expression-evaluator-model.d.ts +0 -209
- package/models/models/kos-expression-evaluator/kos-expression-evaluator-model.d.ts.map +0 -1
- package/models/models/kos-expression-evaluator/services/index.d.ts +0 -6
- package/models/models/kos-expression-evaluator/services/index.d.ts.map +0 -1
- package/models/models/kos-expression-evaluator/services/kos-expression-evaluator-services.d.ts +0 -15
- package/models/models/kos-expression-evaluator/services/kos-expression-evaluator-services.d.ts.map +0 -1
- package/models/models/kos-expression-evaluator/types/index.d.ts +0 -6
- package/models/utils/get-kos-connection-id.d.ts +0 -2
- package/models/utils/get-kos-connection-id.d.ts.map +0 -1
- package/models/utils/openapi-index.d.ts +0 -3
- package/models/utils/openapi-index.d.ts.map +0 -1
- package/models/utils/service-accessor.d.ts +0 -86
- package/models/utils/service-accessor.d.ts.map +0 -1
- package/models/utils/services/kos/1.6.5/openapi.d.ts +0 -3809
- package/models/utils/services/kos/1.6.5/service.d.ts +0 -124
- package/models/utils/services/kos/1.6.5/service.d.ts.map +0 -1
- package/models/utils/services/kos/1.8.1/openapi.d.ts +0 -4344
- package/models/utils/services/kos/1.8.1/service.d.ts +0 -124
- package/models/utils/services/kos/1.8.1/service.d.ts.map +0 -1
- package/models/utils/services/kos/1.9.x/openapi.d.ts +0 -4597
- package/models/utils/services/kos/1.9.x/service.d.ts +0 -124
- package/models/utils/services/kos/1.9.x/service.d.ts.map +0 -1
- package/models/utils/services/kos/daily/openapi.d.ts +0 -4349
- package/models/utils/services/kos/daily/service.d.ts +0 -124
- package/models/utils/services/kos/daily/service.d.ts.map +0 -1
- package/models/utils/services/vfs/1.6.5/openapi.d.ts +0 -51
- package/models/utils/services/vfs/1.6.5/service.d.ts +0 -124
- package/models/utils/services/vfs/1.6.5/service.d.ts.map +0 -1
- package/models/utils/services/vfs/1.8.1/openapi.d.ts +0 -51
- package/models/utils/services/vfs/1.8.1/service.d.ts +0 -124
- package/models/utils/services/vfs/1.8.1/service.d.ts.map +0 -1
- package/models/utils/services/vfs/1.9.x/openapi.d.ts +0 -51
- package/models/utils/services/vfs/1.9.x/service.d.ts +0 -124
- package/models/utils/services/vfs/1.9.x/service.d.ts.map +0 -1
- package/models/utils/services/vfs/daily/openapi.d.ts +0 -51
- package/models/utils/services/vfs/daily/service.d.ts +0 -124
- package/models/utils/services/vfs/daily/service.d.ts.map +0 -1
- package/models/utils/services-index.d.ts +0 -9
- package/models/utils/services-index.d.ts.map +0 -1
- package/ui/hooks/view-model/index.d.ts +0 -2
- package/ui/hooks/view-model/index.d.ts.map +0 -1
- package/ui/hooks/view-model/use-view-model.d.ts +0 -80
- package/ui/hooks/view-model/use-view-model.d.ts.map +0 -1
|
@@ -1,70 +1,35 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { PublicModelInterface } from '../../../../core';
|
|
1
|
+
import { IKosDataModel } from '../../../../core';
|
|
3
2
|
|
|
4
3
|
|
|
5
4
|
/**
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* This interface defines the configuration options for the SoftwareInfo model.
|
|
9
|
-
* Currently, no specific configuration options are required as the model
|
|
10
|
-
* automatically loads software information from the system manifest API.
|
|
11
|
-
*
|
|
12
|
-
* @example Basic Usage
|
|
13
|
-
* ```typescript
|
|
14
|
-
* const softwareInfo = SoftwareInfo.instance('system-info').build();
|
|
15
|
-
* ```
|
|
16
|
-
*
|
|
17
|
-
* @kosService core.software-info
|
|
18
|
-
* @category Model Configuration
|
|
19
|
-
* @category System Integration
|
|
5
|
+
* @internal
|
|
20
6
|
*/
|
|
21
|
-
export interface SoftwareInfoOptions {
|
|
22
|
-
/** Reserved for future extensibility - currently no options required */
|
|
23
|
-
[key: string]: never;
|
|
24
|
-
}
|
|
7
|
+
export interface SoftwareInfoOptions {}
|
|
25
8
|
|
|
26
9
|
/**
|
|
27
|
-
*
|
|
28
|
-
* @
|
|
29
|
-
* @
|
|
10
|
+
* Maintains the state of the current software information.
|
|
11
|
+
* @category Model
|
|
12
|
+
* @link withSoftwareInfo
|
|
30
13
|
*/
|
|
31
|
-
export
|
|
14
|
+
export interface SoftwareInfoModel extends IKosDataModel {
|
|
15
|
+
nodes: Nodes;
|
|
16
|
+
}
|
|
32
17
|
|
|
33
|
-
/**
|
|
34
|
-
* Software artifact information representing an individual component or package.
|
|
35
|
-
*
|
|
36
|
-
* This interface describes a software artifact (component, package, or module)
|
|
37
|
-
* installed on a KOS device node, including its identification, grouping, and version.
|
|
38
|
-
*
|
|
39
|
-
* @kosService core.software-info
|
|
40
|
-
* @group KOS Model
|
|
41
|
-
* @category Types
|
|
42
|
-
*/
|
|
43
18
|
export interface ArtifactsType {
|
|
44
|
-
/** Unique identifier/name of the software artifact */
|
|
45
19
|
name: string;
|
|
46
|
-
/** Functional group classification (core, ui, services, etc.) */
|
|
47
20
|
group: string;
|
|
48
|
-
/** Semantic version string of the artifact */
|
|
49
21
|
version: string;
|
|
50
22
|
}
|
|
51
23
|
|
|
52
|
-
/**
|
|
53
|
-
* Node software information representing all software components on a device node.
|
|
54
|
-
*
|
|
55
|
-
* This interface describes the complete software configuration of a single KOS device node,
|
|
56
|
-
* including the node identification, KOS framework version, and all installed artifacts
|
|
57
|
-
* organized by functional groups.
|
|
58
|
-
*
|
|
59
|
-
* @kosService core.software-info
|
|
60
|
-
* @group KOS Model
|
|
61
|
-
* @category Types
|
|
62
|
-
*/
|
|
63
24
|
export interface NodeInfoType {
|
|
64
|
-
/** Node identifier (primary, secondary, etc.) */
|
|
65
25
|
nodeName: string;
|
|
66
|
-
/** KOS framework version running on this node */
|
|
67
|
-
kosVersion?: string;
|
|
68
|
-
/** Artifacts organized by functional groups */
|
|
69
26
|
group: Record<string, ArtifactsType[]>;
|
|
70
27
|
}
|
|
28
|
+
|
|
29
|
+
export interface NodeHead {
|
|
30
|
+
NodeType: string;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export interface object {
|
|
34
|
+
[key: string]: string;
|
|
35
|
+
}
|
|
@@ -1,106 +1,29 @@
|
|
|
1
1
|
import { StateBeanModel, StateBeanOptions, StatePropsMap } from './types';
|
|
2
2
|
import { StateBeanResponse } from './services';
|
|
3
3
|
import { StatePropertyTypes } from '../types';
|
|
4
|
-
import { PublicModelInterface } from '../../../core/types';
|
|
5
4
|
import { IKosModelLogger, KosContextLogger, KosCreationContext } from '../../../core';
|
|
6
5
|
|
|
7
6
|
export declare const MODEL_TYPE = "state-bean-model";
|
|
8
|
-
|
|
9
|
-
* StateBean - Reactive state management for KOS device state properties.
|
|
10
|
-
*
|
|
11
|
-
* The StateBean model provides real-time access to KOS device state information through
|
|
12
|
-
* reactive properties that automatically synchronize with device state changes via WebSocket
|
|
13
|
-
* topics. This model is essential for applications that need to monitor device state,
|
|
14
|
-
* track property changes, or build reactive UIs that respond to device status updates.
|
|
15
|
-
*
|
|
16
|
-
* ## Key Features
|
|
17
|
-
* - **Real-time Synchronization** - Automatic updates via `/kos/state/{path}` WebSocket topics
|
|
18
|
-
* - **Type-safe Properties** - Strongly typed state properties with automatic type conversion
|
|
19
|
-
* - **Observable State Map** - Reactive Map-based property storage for efficient updates
|
|
20
|
-
* - **Automatic Type Conversion** - Smart conversion of string values to boolean/number types
|
|
21
|
-
* - **Path-based Organization** - Hierarchical state organization using dot-notation paths
|
|
22
|
-
* - **Lifecycle Management** - Proper initialization and loading of state data
|
|
23
|
-
*
|
|
24
|
-
* ## Topic-Based Reactivity
|
|
25
|
-
* The model listens to KOS topics for real-time synchronization:
|
|
26
|
-
* - **`/kos/state/{path}`** - Receives state updates for the specified path, triggering automatic property updates across all connected clients
|
|
27
|
-
*
|
|
28
|
-
* ## State Property Types
|
|
29
|
-
* Supports all common KOS state property types:
|
|
30
|
-
* - **string** - Text values, configuration strings, identifiers
|
|
31
|
-
* - **number** - Numeric values, counters, measurements, percentages
|
|
32
|
-
* - **boolean** - Status flags, enabled/disabled states, operational flags
|
|
33
|
-
* - **object** - Complex state objects, nested configurations
|
|
34
|
-
*
|
|
35
|
-
* ## Common Use Cases
|
|
36
|
-
* - **Device Status Monitoring** - Track operational states, error conditions, health metrics
|
|
37
|
-
* - **Configuration State** - Monitor dynamic configuration changes and feature flags
|
|
38
|
-
* - **System Status Dashboards** - Build real-time status displays and monitoring interfaces
|
|
39
|
-
* - **Conditional UI Logic** - Show/hide UI elements based on device state
|
|
40
|
-
* - **State-dependent Operations** - Enable/disable functionality based on device state
|
|
41
|
-
* - **Multi-client Synchronization** - Keep multiple clients in sync with device state
|
|
42
|
-
*
|
|
43
|
-
* @interface
|
|
44
|
-
* @example Basic Usage
|
|
45
|
-
* ```typescript
|
|
46
|
-
* const deviceState = StateBean.instance('device-status')
|
|
47
|
-
* .options({ path: 'device.operational.status' })
|
|
48
|
-
* .build();
|
|
49
|
-
*
|
|
50
|
-
* // Access reactive state properties
|
|
51
|
-
* const isOnline = deviceState.props.get('online') as boolean;
|
|
52
|
-
* const temperature = deviceState.props.get('temperature') as number;
|
|
53
|
-
* ```
|
|
54
|
-
*
|
|
55
|
-
* @group KOS Model
|
|
56
|
-
* @category State Management
|
|
57
|
-
* @useDeclaredType
|
|
58
|
-
*
|
|
59
|
-
* @see {@link StateBeanOptions} - Configuration options for StateBean model
|
|
60
|
-
* @see {@link StatePropertyTypes} - Supported state property value types
|
|
61
|
-
* @see {@link StateProp} - Individual property access model
|
|
62
|
-
* @see {@link getStateBeanData} - Service function for loading state data
|
|
63
|
-
*/
|
|
64
|
-
export type StateBean<T extends Record<string, StatePropertyTypes> = Record<string, StatePropertyTypes>> = PublicModelInterface<StateBeanModelImpl<T>>;
|
|
65
|
-
/**
|
|
66
|
-
* @ignore
|
|
67
|
-
* @internal
|
|
68
|
-
*/
|
|
69
|
-
export declare class StateBeanModelImpl<T extends Record<string, StatePropertyTypes> = Record<string, StatePropertyTypes>> implements StateBeanModel<T>, IKosModelLogger {
|
|
70
|
-
/** Unique identifier for the model instance */
|
|
7
|
+
export declare class StateBeanModelImpl<T extends Record<string, StatePropertyTypes> = any> implements StateBeanModel<T>, IKosModelLogger {
|
|
71
8
|
id: string;
|
|
72
|
-
/** State path being monitored for updates */
|
|
73
9
|
path: string;
|
|
74
|
-
/** Reactive Map of state properties with automatic type conversion */
|
|
75
10
|
props: StatePropsMap<T>;
|
|
76
|
-
/** Context logger for debugging and diagnostics */
|
|
77
11
|
logger: KosContextLogger;
|
|
78
12
|
constructor(modelId: string, options: StateBeanOptions, context: KosCreationContext);
|
|
79
|
-
/**
|
|
80
|
-
* Updates the model configuration with new options.
|
|
81
|
-
* @param options New configuration options to apply
|
|
82
|
-
*/
|
|
83
13
|
updateModel(options: StateBeanOptions): void;
|
|
84
14
|
/**
|
|
85
|
-
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
*
|
|
15
|
+
* @category Subscription
|
|
16
|
+
* Updates the Config Bean model when a `/kos/config//update` event
|
|
17
|
+
* is recieved from the server.
|
|
18
|
+
*
|
|
19
|
+
*
|
|
20
|
+
* @param data - the raw callback
|
|
21
|
+
* @param data.body - the Config Bean that was updated.
|
|
22
|
+
* @see ConfigBeanResponse
|
|
89
23
|
*/
|
|
90
24
|
handleConfigBeanUpdated(stateBean: StateBeanResponse): void;
|
|
91
|
-
/**
|
|
92
|
-
* @internal
|
|
93
|
-
*/
|
|
94
25
|
init(): Promise<void>;
|
|
95
|
-
/**
|
|
96
|
-
* Updates multiple properties at once with type conversion.
|
|
97
|
-
* @param props Properties to update
|
|
98
|
-
* @private
|
|
99
|
-
*/
|
|
100
26
|
updateProps(props: Record<string, StatePropertyTypes>): void;
|
|
101
|
-
/**
|
|
102
|
-
* @internal
|
|
103
|
-
*/
|
|
104
27
|
load(): Promise<void>;
|
|
105
28
|
}
|
|
106
29
|
//# sourceMappingURL=state-bean-model.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"state-bean-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-ui-sdk/src/models/models/state-bean/state-bean-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EACnB,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"state-bean-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-ui-sdk/src/models/models/state-bean/state-bean-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EACnB,MAAM,eAAe,CAAC;AASvB,OAAO,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAC9C,OAAO,EAAoB,KAAK,iBAAiB,EAAE,MAAM,YAAY,CAAC;AACtE,OAAO,KAAK,EAAE,cAAc,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAE/E,eAAO,MAAM,UAAU,qBAAqB,CAAC;AAE7C,qBACa,kBAAkB,CAC7B,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,GAAG,GAAG,CAClD,YAAW,cAAc,CAAC,CAAC,CAAC,EAAE,eAAe;IAE7C,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAG,MAAM,CAAC;IACd,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;IACxB,MAAM,EAAE,gBAAgB,CAAC;gBAEvB,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,gBAAgB,EACzB,OAAO,EAAE,kBAAkB;IAQ7B,WAAW,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI;IAI5C;;;;;;;;;OASG;IAKH,uBAAuB,CAAC,SAAS,EAAE,iBAAiB;IAkB9C,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAI3B,WAAW,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC;IAM/C,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAO5B"}
|
|
@@ -1,135 +1,24 @@
|
|
|
1
1
|
import { StatePropertyTypes } from '../../types';
|
|
2
|
+
import { IKosDataModel } from '../../../core';
|
|
2
3
|
|
|
3
4
|
|
|
4
|
-
/**
|
|
5
|
-
* Configuration options for StateBean model instances.
|
|
6
|
-
*
|
|
7
|
-
* This interface defines the configuration options for the StateBean model,
|
|
8
|
-
* specifying which state path the model should monitor for real-time updates.
|
|
9
|
-
*
|
|
10
|
-
* @example Basic StateBean Model Creation
|
|
11
|
-
* ```typescript
|
|
12
|
-
* // Monitor device operational status
|
|
13
|
-
* const deviceState = StateBean.instance('device-status')
|
|
14
|
-
* .options({ path: 'device.operational.status' })
|
|
15
|
-
* .build();
|
|
16
|
-
*
|
|
17
|
-
* // Monitor system health metrics
|
|
18
|
-
* const healthState = StateBean.instance('system-health')
|
|
19
|
-
* .options({ path: 'system.health.metrics' })
|
|
20
|
-
* .build();
|
|
21
|
-
* ```
|
|
22
|
-
*
|
|
23
|
-
* @example Path Patterns
|
|
24
|
-
* ```typescript
|
|
25
|
-
* // Different path patterns for different use cases
|
|
26
|
-
* const networkOptions: StateBeanOptions = {
|
|
27
|
-
* path: 'network.interfaces.primary' // Network interface state
|
|
28
|
-
* };
|
|
29
|
-
*
|
|
30
|
-
* const pumpOptions: StateBeanOptions = {
|
|
31
|
-
* path: 'assembly.pumps.status' // Pump system state
|
|
32
|
-
* };
|
|
33
|
-
*
|
|
34
|
-
* const brewingOptions: StateBeanOptions = {
|
|
35
|
-
* path: 'beverage.brewing.process' // Brewing process state
|
|
36
|
-
* };
|
|
37
|
-
* ```
|
|
38
|
-
*
|
|
39
|
-
* @example Hierarchical State Organization
|
|
40
|
-
* ```typescript
|
|
41
|
-
* // Use dot notation for hierarchical state paths
|
|
42
|
-
* const parentState = StateBean.instance('parent')
|
|
43
|
-
* .options({ path: 'system' })
|
|
44
|
-
* .build();
|
|
45
|
-
*
|
|
46
|
-
* const childState = StateBean.instance('child')
|
|
47
|
-
* .options({ path: 'system.subsystem.component' })
|
|
48
|
-
* .build();
|
|
49
|
-
* ```
|
|
50
|
-
*
|
|
51
|
-
* @kosService core.state-bean
|
|
52
|
-
* @category Model Configuration
|
|
53
|
-
* @category State Management
|
|
54
|
-
*/
|
|
55
5
|
export interface StateBeanOptions {
|
|
56
|
-
/**
|
|
57
|
-
* State path to monitor for updates using dot notation hierarchy.
|
|
58
|
-
* This path corresponds to the WebSocket topic `/kos/state/{path}` for real-time updates.
|
|
59
|
-
*
|
|
60
|
-
* @example "device.operational.status"
|
|
61
|
-
* @example "network.interfaces.primary"
|
|
62
|
-
* @example "assembly.pumps.status"
|
|
63
|
-
*/
|
|
64
6
|
path: string;
|
|
65
7
|
}
|
|
66
8
|
|
|
67
|
-
/**
|
|
68
|
-
* Type-safe keys for state properties within a StateBean.
|
|
69
|
-
*
|
|
70
|
-
* @template T - The state property type mapping
|
|
71
|
-
*/
|
|
72
9
|
type StateKeys<T extends Record<string, StatePropertyTypes>> = keyof T;
|
|
73
|
-
|
|
74
|
-
/**
|
|
75
|
-
* Reactive Map-based storage for state properties with type safety.
|
|
76
|
-
*
|
|
77
|
-
* This Map provides efficient storage and retrieval of state properties with automatic
|
|
78
|
-
* reactivity through MobX observables. The Map structure allows for dynamic property
|
|
79
|
-
* addition/removal while maintaining type safety for known properties.
|
|
80
|
-
*
|
|
81
|
-
* @example Accessing State Properties
|
|
82
|
-
* ```typescript
|
|
83
|
-
* // Define typed state interface
|
|
84
|
-
* interface PumpState {
|
|
85
|
-
* active: boolean;
|
|
86
|
-
* flowRate: number;
|
|
87
|
-
* temperature: number;
|
|
88
|
-
* lastMaintenance: string;
|
|
89
|
-
* }
|
|
90
|
-
*
|
|
91
|
-
* const pumpState = StateBean.instance('pump-monitor')
|
|
92
|
-
* .options({ path: 'assembly.pumps.pump1' })
|
|
93
|
-
* .build() as StateBean<PumpState>;
|
|
94
|
-
*
|
|
95
|
-
* // Type-safe property access
|
|
96
|
-
* const isActive = pumpState.props.get('active') as boolean;
|
|
97
|
-
* const currentFlow = pumpState.props.get('flowRate') as number;
|
|
98
|
-
* const temp = pumpState.props.get('temperature') as number;
|
|
99
|
-
* const maintenance = pumpState.props.get('lastMaintenance') as string;
|
|
100
|
-
* ```
|
|
101
|
-
*
|
|
102
|
-
* @template T - The state property type mapping
|
|
103
|
-
*
|
|
104
|
-
* @kosService core.state-bean
|
|
105
|
-
* @group KOS Model
|
|
106
|
-
* @category Types
|
|
107
|
-
*/
|
|
108
10
|
export type StatePropsMap<T> = Map<StateKeys<T>, T[keyof T]>;
|
|
109
11
|
|
|
110
12
|
/**
|
|
111
|
-
* State Bean Model
|
|
112
|
-
*
|
|
113
|
-
* This interface represents the public API for StateBean models, providing reactive
|
|
114
|
-
* access to device state properties through an observable Map structure. The interface
|
|
115
|
-
* supports real-time synchronization with device state via WebSocket topics.
|
|
116
|
-
*
|
|
117
|
-
* @kosService core.state-bean
|
|
118
|
-
* @group KOS Model
|
|
119
|
-
* @category Model Interface
|
|
13
|
+
* State Bean Model
|
|
14
|
+
* @category Model
|
|
120
15
|
*/
|
|
121
16
|
export interface StateBeanModel<
|
|
122
|
-
T extends Record<string, StatePropertyTypes> =
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
>
|
|
126
|
-
> {
|
|
127
|
-
/** Unique model identifier */
|
|
17
|
+
T extends Record<string, StatePropertyTypes> = any
|
|
18
|
+
> extends StateBeanOptions,
|
|
19
|
+
IKosDataModel {
|
|
128
20
|
id: string;
|
|
129
|
-
/** State path being monitored */
|
|
130
21
|
path: string;
|
|
131
|
-
/** Reactive Map of state properties */
|
|
132
22
|
props: StatePropsMap<T>;
|
|
133
|
-
/** Update model configuration */
|
|
134
23
|
updateModel(options: StateBeanOptions): void;
|
|
135
24
|
}
|
|
@@ -1,96 +1,19 @@
|
|
|
1
1
|
import { KosStateProp, StatePropOptions } from './types';
|
|
2
2
|
import { StatePropertyTypes } from '../types';
|
|
3
3
|
import { StateBeanModel } from '../state-bean/types';
|
|
4
|
-
import { PublicModelInterface } from '../../../core/types';
|
|
5
4
|
import { IKosModelLogger, KosContextLogger, KosCreationContext } from '../../../core';
|
|
6
5
|
|
|
7
6
|
export declare const MODEL_TYPE = "state-prop-model";
|
|
8
|
-
|
|
9
|
-
* StateProp - Focused access to individual state properties with dependency on StateBean.
|
|
10
|
-
*
|
|
11
|
-
* The StateProp model provides targeted access to a single property within a StateBean,
|
|
12
|
-
* offering a focused interface for components or services that only need to monitor
|
|
13
|
-
* specific state values. This model automatically manages its dependency on the underlying
|
|
14
|
-
* StateBean and provides reactive access to individual property values.
|
|
15
|
-
*
|
|
16
|
-
* ## Key Features
|
|
17
|
-
* - **Single Property Focus** - Access one specific property from a StateBean path
|
|
18
|
-
* - **Automatic StateBean Dependency** - Manages StateBean dependency transparently
|
|
19
|
-
* - **Type-safe Value Access** - Strongly typed property value with generic support
|
|
20
|
-
* - **Reactive Updates** - Automatically updates when underlying StateBean changes
|
|
21
|
-
* - **Simplified Interface** - Clean `.value` accessor for property values
|
|
22
|
-
* - **String Conversion** - Built-in `toString()` method for display purposes
|
|
23
|
-
*
|
|
24
|
-
* ## StateBean Integration
|
|
25
|
-
* StateProp models automatically create and manage dependencies on StateBean models:
|
|
26
|
-
* - **Automatic Dependency** - Creates StateBean with matching path automatically
|
|
27
|
-
* - **Shared StateBean** - Multiple StateProp models can share the same StateBean
|
|
28
|
-
* - **Lifecycle Management** - Proper initialization and cleanup of dependencies
|
|
29
|
-
* - **Real-time Synchronization** - Inherits WebSocket updates from StateBean
|
|
30
|
-
*
|
|
31
|
-
* ## Common Use Cases
|
|
32
|
-
* - **Single Value Components** - React components that only need one state property
|
|
33
|
-
* - **Conditional Logic** - Enable/disable functionality based on specific state
|
|
34
|
-
* - **Status Indicators** - Display individual status flags or measurements
|
|
35
|
-
* - **Property Validation** - Monitor specific properties for validation rules
|
|
36
|
-
* - **Focused Updates** - Reduce re-renders by tracking only needed properties
|
|
37
|
-
* - **Service Dependencies** - Services that depend on specific state values
|
|
38
|
-
*
|
|
39
|
-
* @interface
|
|
40
|
-
* @example Basic Usage
|
|
41
|
-
* ```typescript
|
|
42
|
-
* const deviceOnline = StateProp.instance('device-online')
|
|
43
|
-
* .options({
|
|
44
|
-
* path: 'device.operational.status',
|
|
45
|
-
* attribute: 'online'
|
|
46
|
-
* })
|
|
47
|
-
* .build();
|
|
48
|
-
*
|
|
49
|
-
* // Access focused property value with type safety
|
|
50
|
-
* const isOnline = deviceOnline.value as boolean;
|
|
51
|
-
* console.log(`Status: ${deviceOnline.toString()}`);
|
|
52
|
-
* ```
|
|
53
|
-
*
|
|
54
|
-
* @group KOS Model
|
|
55
|
-
* @category State Management
|
|
56
|
-
* @useDeclaredType
|
|
57
|
-
*
|
|
58
|
-
* @see {@link StatePropOptions} - Configuration options for StateProp model
|
|
59
|
-
* @see {@link StatePropertyTypes} - Supported property value types
|
|
60
|
-
* @see {@link StateBean} - Underlying state collection model
|
|
61
|
-
* @see {@link StateBeanOptions} - StateBean configuration options
|
|
62
|
-
*/
|
|
63
|
-
export type StateProp<T extends StatePropertyTypes = StatePropertyTypes> = PublicModelInterface<StatePropModelImpl<T>>;
|
|
64
|
-
/**
|
|
65
|
-
* @ignore
|
|
66
|
-
* @internal
|
|
67
|
-
*/
|
|
68
|
-
export declare class StatePropModelImpl<T extends StatePropertyTypes = StatePropertyTypes> implements KosStateProp<T>, IKosModelLogger {
|
|
69
|
-
/** Unique identifier for the model instance */
|
|
7
|
+
export declare class StatePropModelImpl<T extends StatePropertyTypes = any> implements KosStateProp<T>, IKosModelLogger {
|
|
70
8
|
id: string;
|
|
71
|
-
/** State path being monitored (same as dependent StateBean) */
|
|
72
9
|
path: string;
|
|
73
|
-
/** Specific attribute name to access within the state path */
|
|
74
10
|
attribute: string;
|
|
75
|
-
/** Context logger for debugging and diagnostics */
|
|
76
11
|
logger: KosContextLogger;
|
|
77
|
-
/** Automatic dependency on StateBean for the specified path */
|
|
78
12
|
stateBean: StateBeanModel;
|
|
79
13
|
constructor(modelId: string, options: StatePropOptions, context: KosCreationContext);
|
|
80
|
-
/** The current value of the specific attribute, with type safety */
|
|
81
14
|
get value(): T | undefined;
|
|
82
|
-
/**
|
|
83
|
-
* @internal
|
|
84
|
-
*/
|
|
85
15
|
init(): Promise<void>;
|
|
86
|
-
/**
|
|
87
|
-
* @internal
|
|
88
|
-
*/
|
|
89
16
|
load(): Promise<void>;
|
|
90
|
-
/**
|
|
91
|
-
* Converts the current property value to string for display purposes.
|
|
92
|
-
* @returns String representation of the property value, or empty string if undefined
|
|
93
|
-
*/
|
|
94
17
|
toString(): string;
|
|
95
18
|
}
|
|
96
19
|
//# sourceMappingURL=state-prop-model.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"state-prop-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-ui-sdk/src/models/models/state-prop/state-prop-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EACnB,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"state-prop-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-ui-sdk/src/models/models/state-prop/state-prop-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EACnB,MAAM,eAAe,CAAC;AAGvB,OAAO,KAAK,EAAE,cAAc,EAAoB,MAAM,qBAAqB,CAAC;AAC5E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AACnD,OAAO,KAAK,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAE9D,eAAO,MAAM,UAAU,qBAAqB,CAAC;AAG7C,qBACa,kBAAkB,CAAC,CAAC,SAAS,kBAAkB,GAAG,GAAG,CAChE,YAAW,YAAY,CAAC,CAAC,CAAC,EAAE,eAAe;IAE3C,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,gBAAgB,CAAC;IAOzB,SAAS,EAAG,cAAc,CAAC;gBAGzB,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,gBAAgB,EACzB,OAAO,EAAE,kBAAkB;IAW7B,IAAI,KAAK,IAAI,CAAC,GAAG,SAAS,CAEzB;IAIK,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAIrB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAI3B,QAAQ,IAAI,MAAM;CAGnB"}
|
|
@@ -1,70 +1,20 @@
|
|
|
1
1
|
import { StatePropertyTypes } from '../../types';
|
|
2
|
+
import { IKosDataModel } from '../../../core';
|
|
2
3
|
|
|
3
4
|
|
|
4
|
-
/**
|
|
5
|
-
* Configuration options for StateProp model instances.
|
|
6
|
-
*
|
|
7
|
-
* This interface defines the configuration options for the StateProp model,
|
|
8
|
-
* specifying which state path and attribute the model should monitor for
|
|
9
|
-
* focused property access.
|
|
10
|
-
*
|
|
11
|
-
* @example Basic Usage
|
|
12
|
-
* ```typescript
|
|
13
|
-
* const deviceOnline = StateProp.instance('device-online')
|
|
14
|
-
* .options({
|
|
15
|
-
* path: 'device.operational.status',
|
|
16
|
-
* attribute: 'online'
|
|
17
|
-
* })
|
|
18
|
-
* .build();
|
|
19
|
-
* ```
|
|
20
|
-
*
|
|
21
|
-
* @kosService core.state-prop
|
|
22
|
-
* @category Model Configuration
|
|
23
|
-
* @category State Management
|
|
24
|
-
*/
|
|
25
5
|
export interface StatePropOptions {
|
|
26
|
-
/**
|
|
27
|
-
* State path to monitor, matching the StateBean path structure.
|
|
28
|
-
* Uses dot notation hierarchy corresponding to `/kos/state/{path}` WebSocket topic.
|
|
29
|
-
*
|
|
30
|
-
* @example "device.operational.status"
|
|
31
|
-
* @example "assembly.pumps.pump1"
|
|
32
|
-
* @example "system.health.metrics"
|
|
33
|
-
*/
|
|
34
6
|
path: string;
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* Specific attribute name within the state path to access.
|
|
38
|
-
* This corresponds to a property key within the StateBean's properties Map.
|
|
39
|
-
*
|
|
40
|
-
* @example "online"
|
|
41
|
-
* @example "temperature"
|
|
42
|
-
* @example "flowRate"
|
|
43
|
-
* @example "active"
|
|
44
|
-
*/
|
|
45
7
|
attribute: string;
|
|
46
8
|
}
|
|
47
9
|
|
|
48
10
|
/**
|
|
49
|
-
* State Property Model
|
|
50
|
-
*
|
|
51
|
-
* This interface represents the public API for StateProp models, providing focused
|
|
52
|
-
* access to individual properties within a StateBean through automatic dependency
|
|
53
|
-
* management and reactive value updates.
|
|
54
|
-
*
|
|
55
|
-
* @kosService core.state-prop
|
|
56
|
-
* @group KOS Model
|
|
57
|
-
* @category Model Interface
|
|
11
|
+
* State Property Model manages the state of a single state bean property
|
|
12
|
+
* @category Model
|
|
58
13
|
*/
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
14
|
+
|
|
15
|
+
export interface KosStateProp<T extends StatePropertyTypes = any>
|
|
16
|
+
extends StatePropOptions,
|
|
17
|
+
IKosDataModel {
|
|
63
18
|
id: string;
|
|
64
|
-
/** State path being monitored */
|
|
65
|
-
path: string;
|
|
66
|
-
/** Specific attribute name within the state path */
|
|
67
|
-
attribute: string;
|
|
68
|
-
/** Current property value (reactive) */
|
|
69
19
|
value: T | undefined;
|
|
70
20
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"storage-device-services.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/sdk/kos-ui-sdk/src/models/models/storage-device/services/storage-device-services.ts"],"names":[],"mappings":"AAAA;;GAEG;AAcH,MAAM,WAAW,qBAAqB;IACpC,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"storage-device-services.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/sdk/kos-ui-sdk/src/models/models/storage-device/services/storage-device-services.ts"],"names":[],"mappings":"AAAA;;GAEG;AAcH,MAAM,WAAW,qBAAqB;IACpC,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;CACjB;AACD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,wCAQ7B,CAAC"}
|