@kosdev-code/kos-ui-sdk 0.1.0-next.1035 → 0.1.0-next.1036
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/index.cjs +2 -2
- package/index.js +3 -3
- package/models/models/storage-device/storage-device-container-model.d.ts +4 -3
- package/models/models/storage-device/storage-device-container-model.d.ts.map +1 -1
- package/package.json +3 -3
- package/{software-info-registration-Co9Wq_-n.js → software-info-registration-CPH7UyL6.js} +5 -3
- package/{software-info-registration-Co9Wq_-n.js.map → software-info-registration-CPH7UyL6.js.map} +1 -1
- package/{software-info-registration-C-fplY8u.cjs → software-info-registration-CWlRW0sN.cjs} +5 -3
- package/{software-info-registration-C-fplY8u.cjs.map → software-info-registration-CWlRW0sN.cjs.map} +1 -1
- package/testing.cjs +1 -1
- package/testing.js +1 -1
package/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const service$8 = require("./software-info-registration-
|
|
3
|
+
const service$8 = require("./software-info-registration-CWlRW0sN.cjs");
|
|
4
4
|
const mobx = require("mobx");
|
|
5
5
|
const jsxRuntime = require("@emotion/react/jsx-runtime");
|
|
6
6
|
const styled = require("@emotion/styled");
|
|
@@ -1541,7 +1541,7 @@ const updateRegion = async (region) => {
|
|
|
1541
1541
|
regionInfo.updateProperty(region);
|
|
1542
1542
|
};
|
|
1543
1543
|
async function getKosServiceApi() {
|
|
1544
|
-
const { default: API } = await Promise.resolve().then(() => require("./software-info-registration-
|
|
1544
|
+
const { default: API } = await Promise.resolve().then(() => require("./software-info-registration-CWlRW0sN.cjs")).then((n) => n.service);
|
|
1545
1545
|
return API;
|
|
1546
1546
|
}
|
|
1547
1547
|
function kosServiceRequest$7(params) {
|
package/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as subscribe, p as publish, k as kosParentAware, C as CompanionParentModel, K as KosContextManager, M as MultipleFutureContainerSetup, a as MixinModels, R as ReferenceConfig, T as TroubleAwareSetup, D as DependencyModels, E as ExtensionManager, S as SubscriptionHandlers, b as KosViewModelSymbol, V as ViewModelConfig, c as StateMachineSetup, d as DependencyLifecycle, i as injectStateMachineSupport, e as initializeStateMachine, f as ModelEffects, g as KosModelVisitor, h as KosCore, j as sendKosMessageResponse, I as INDEX_RECORD_SYMBOL, l as INDEX_COLLECTION_KEY, m as KosContainerIndexEvents, n as isIndexableItem, o as Kos, q as isKosModel, r as ConfigBean, t as configBeanModelId, u as getRegionInfo, v as getRegions, w as Registration, x as getStateBeanData, y as StateBean, z as getStateProps, A as StateProp, B as deleteKeyValue, F as deleteKeyValueNamespace, G as getKeyValue, H as updateKeyValue, J as addLogOverride, L as getLogGroups, N as getLogOverrides, O as removeLogOverride, P as getTimezone, Q as setDate, U as setTime, W as setTimezone, X as createOverride, Y as getLogStreamBlock, Z as getLogStreamBlocks, _ as getLogStreams, $ as subscribeToLogStream, a0 as unsubscribeFromLogStream, a1 as bulkResolveTroubles, a2 as getTroubles, a3 as resolveTrouble, a4 as sendCanvasData, a5 as getDeviceDetails, a6 as getSerialNumber, a7 as getNetworkInterfaces, a8 as getStorageDevices, a9 as getAvailableUpdates, aa as installUpdate, ab as TranslationContainer, ac as whenReady, ad as KosCoreModelPropertyMapper, ae as CanvasDispatcher, af as KeyValue, ag as destroyKosModel, ah as createClient, ai as kosServiceRequest$8, aj as getSoftwareInfos, ak as getSoftwareInfosWithCancel, al as KosLog, am as LogGroup, an as BASE_URL, ao as kosFetch, ap as kosModel, aq as kosLoggerAware, ar as kosContainerAware, as as kosChild, at as api$8, au as ObservableData, av as WebSocketTransport, aw as kosComputed, ax as KosModelRegistrationFactory, ay as getKosModelSync, az as kosAutoEffect, aA as WebSocketEvents, aB as modelHookCache, aC as isUpdateable, aD as KosModelState, aE as KosModelEvents, aF as clearModelHookCacheEntry, aG as KosTime, aH as SoftwareInfo, aI as getQueryParams, aJ as getKosLocalizationDescriptor, aK as Device, aL as NetworkInterfaceContainer, aM as Ota, aN as StorageDeviceContainer, aO as TimerManager, aP as TIMER_END, aQ as TIMER_EVENT, aR as TOPIC_TIMER_TICK_EVENT, aS as getKosModel, aT as Trouble, aU as TroubleContainer, aV as UsbUpdateContainer, aW as Registration$1 } from "./software-info-registration-
|
|
2
|
-
import { aX, aY, aZ, a_, a$, b0, b1, b2, b3, b4, b5, b6, b7, b8, b9, ba, bb, bc, bd, be, bf, bg, bh, bi, bj, bk, bl, bm, bn, bo, bp, bq, br, bs, bt, bu, bv, bw, bx, by, bz, bA, bB, bC, bD, bE, bF, bG, bH, bI, bJ, bK, bL, bM, bN, bO, bP, bQ, bR, bS, bT, bU, bV, bW, bX, bY, bZ, b_, b$, c0, c1, c2, c3, c4, c5, c6, c7, c8, c9, ca, cb, cc, cd, ce, cf, cg, ch, ci, cj, ck, cl, cm, cn, co, cp, cq, cr, cs, ct, cu, cv, cw, cx, cy, cz, cA, cB, cC, cD, cE, cF, cG, cH, cI, cJ, cK, cL, cM, cN, cO, cP, cQ, cR, cS, cT, cU, cV, cW, cX, cY, cZ, c_, c$, d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, da, db, dc, dd, de, df, dg, dh, di, dj, dk, dl, dm, dn, dp, dq, dr, ds, dt, du, dv, dw, dx, dy, dz, dA, dB, dC, dD, dE, dF, dG, dH, dI, dJ, dK, dL, dM, dN, dO, dP, dQ, dR, dS, dT, dU, dV, dW, dX, dY, dZ, d_, d$, e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, ea, eb, ec, ed, ee, ef, eg, eh, ei, ej, ek, el, em, en, eo, ep, eq, er, es, et, eu, ev, ew, ex, ey, ez, eA, eB, eC, eD, eE, eF, eG, eH, eI, eJ, eK, eL, eM, eN, eO, eP, eQ, eR, eS, eT, eU, eV, eW, eX, eY, eZ, e_, e$, f0, f1, f2 } from "./software-info-registration-
|
|
1
|
+
import { s as subscribe, p as publish, k as kosParentAware, C as CompanionParentModel, K as KosContextManager, M as MultipleFutureContainerSetup, a as MixinModels, R as ReferenceConfig, T as TroubleAwareSetup, D as DependencyModels, E as ExtensionManager, S as SubscriptionHandlers, b as KosViewModelSymbol, V as ViewModelConfig, c as StateMachineSetup, d as DependencyLifecycle, i as injectStateMachineSupport, e as initializeStateMachine, f as ModelEffects, g as KosModelVisitor, h as KosCore, j as sendKosMessageResponse, I as INDEX_RECORD_SYMBOL, l as INDEX_COLLECTION_KEY, m as KosContainerIndexEvents, n as isIndexableItem, o as Kos, q as isKosModel, r as ConfigBean, t as configBeanModelId, u as getRegionInfo, v as getRegions, w as Registration, x as getStateBeanData, y as StateBean, z as getStateProps, A as StateProp, B as deleteKeyValue, F as deleteKeyValueNamespace, G as getKeyValue, H as updateKeyValue, J as addLogOverride, L as getLogGroups, N as getLogOverrides, O as removeLogOverride, P as getTimezone, Q as setDate, U as setTime, W as setTimezone, X as createOverride, Y as getLogStreamBlock, Z as getLogStreamBlocks, _ as getLogStreams, $ as subscribeToLogStream, a0 as unsubscribeFromLogStream, a1 as bulkResolveTroubles, a2 as getTroubles, a3 as resolveTrouble, a4 as sendCanvasData, a5 as getDeviceDetails, a6 as getSerialNumber, a7 as getNetworkInterfaces, a8 as getStorageDevices, a9 as getAvailableUpdates, aa as installUpdate, ab as TranslationContainer, ac as whenReady, ad as KosCoreModelPropertyMapper, ae as CanvasDispatcher, af as KeyValue, ag as destroyKosModel, ah as createClient, ai as kosServiceRequest$8, aj as getSoftwareInfos, ak as getSoftwareInfosWithCancel, al as KosLog, am as LogGroup, an as BASE_URL, ao as kosFetch, ap as kosModel, aq as kosLoggerAware, ar as kosContainerAware, as as kosChild, at as api$8, au as ObservableData, av as WebSocketTransport, aw as kosComputed, ax as KosModelRegistrationFactory, ay as getKosModelSync, az as kosAutoEffect, aA as WebSocketEvents, aB as modelHookCache, aC as isUpdateable, aD as KosModelState, aE as KosModelEvents, aF as clearModelHookCacheEntry, aG as KosTime, aH as SoftwareInfo, aI as getQueryParams, aJ as getKosLocalizationDescriptor, aK as Device, aL as NetworkInterfaceContainer, aM as Ota, aN as StorageDeviceContainer, aO as TimerManager, aP as TIMER_END, aQ as TIMER_EVENT, aR as TOPIC_TIMER_TICK_EVENT, aS as getKosModel, aT as Trouble, aU as TroubleContainer, aV as UsbUpdateContainer, aW as Registration$1 } from "./software-info-registration-CPH7UyL6.js";
|
|
2
|
+
import { aX, aY, aZ, a_, a$, b0, b1, b2, b3, b4, b5, b6, b7, b8, b9, ba, bb, bc, bd, be, bf, bg, bh, bi, bj, bk, bl, bm, bn, bo, bp, bq, br, bs, bt, bu, bv, bw, bx, by, bz, bA, bB, bC, bD, bE, bF, bG, bH, bI, bJ, bK, bL, bM, bN, bO, bP, bQ, bR, bS, bT, bU, bV, bW, bX, bY, bZ, b_, b$, c0, c1, c2, c3, c4, c5, c6, c7, c8, c9, ca, cb, cc, cd, ce, cf, cg, ch, ci, cj, ck, cl, cm, cn, co, cp, cq, cr, cs, ct, cu, cv, cw, cx, cy, cz, cA, cB, cC, cD, cE, cF, cG, cH, cI, cJ, cK, cL, cM, cN, cO, cP, cQ, cR, cS, cT, cU, cV, cW, cX, cY, cZ, c_, c$, d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, da, db, dc, dd, de, df, dg, dh, di, dj, dk, dl, dm, dn, dp, dq, dr, ds, dt, du, dv, dw, dx, dy, dz, dA, dB, dC, dD, dE, dF, dG, dH, dI, dJ, dK, dL, dM, dN, dO, dP, dQ, dR, dS, dT, dU, dV, dW, dX, dY, dZ, d_, d$, e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, ea, eb, ec, ed, ee, ef, eg, eh, ei, ej, ek, el, em, en, eo, ep, eq, er, es, et, eu, ev, ew, ex, ey, ez, eA, eB, eC, eD, eE, eF, eG, eH, eI, eJ, eK, eL, eM, eN, eO, eP, eQ, eR, eS, eT, eU, eV, eW, eX, eY, eZ, e_, e$, f0, f1, f2 } from "./software-info-registration-CPH7UyL6.js";
|
|
3
3
|
import { action, reaction, autorun, makeAutoObservable, runInAction } from "mobx";
|
|
4
4
|
import { makeAutoObservable as makeAutoObservable2, makeObservable } from "mobx";
|
|
5
5
|
import { jsx, jsxs, Fragment } from "@emotion/react/jsx-runtime";
|
|
@@ -1542,7 +1542,7 @@ const updateRegion = async (region) => {
|
|
|
1542
1542
|
regionInfo.updateProperty(region);
|
|
1543
1543
|
};
|
|
1544
1544
|
async function getKosServiceApi() {
|
|
1545
|
-
const { default: API } = await import("./software-info-registration-
|
|
1545
|
+
const { default: API } = await import("./software-info-registration-CPH7UyL6.js").then((n) => n.f3);
|
|
1546
1546
|
return API;
|
|
1547
1547
|
}
|
|
1548
1548
|
function kosServiceRequest$7(params) {
|
|
@@ -7,8 +7,9 @@ import { StorageDeviceContainerOptions } from './types';
|
|
|
7
7
|
export declare const MODEL_TYPE = "storage-device-container-model";
|
|
8
8
|
export declare const TOPIC_STORAGE_AVAILABILITY = "/kos/storage";
|
|
9
9
|
/**
|
|
10
|
-
* Holds a {@link StorageDeviceModel} for each storage device (partition)
|
|
11
|
-
* device reports
|
|
10
|
+
* Holds a {@link StorageDeviceModel} for each inserted storage device (partition)
|
|
11
|
+
* the device reports; the node's own `local` devices are left out. The
|
|
12
|
+
* container loads the devices on load and reconciles them
|
|
12
13
|
* on each `/kos/storage` topic: models for devices missing from the payload are
|
|
13
14
|
* removed, existing ones are updated in place and new ones are added.
|
|
14
15
|
*
|
|
@@ -45,7 +46,7 @@ export declare class StorageDeviceContainerModelImpl implements IKosIdentifiable
|
|
|
45
46
|
init(): Promise<void>;
|
|
46
47
|
get isStorageInserted(): boolean;
|
|
47
48
|
get volumes(): StorageDeviceModel[];
|
|
48
|
-
handleStorageAvailability(
|
|
49
|
+
handleStorageAvailability(payload: StorageDeviceResponse[]): void;
|
|
49
50
|
load(): Promise<void>;
|
|
50
51
|
}
|
|
51
52
|
//# sourceMappingURL=storage-device-container-model.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"storage-device-container-model.d.ts","sourceRoot":"","sources":["../../../../../../packages/kos-ui-sdk/src/models/models/storage-device/storage-device-container-model.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,eAAe,EAIpB,KAAK,oBAAoB,EAC1B,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,KAAK,kBAAkB,EAExB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACL,KAAK,aAAa,EAElB,KAAK,kBAAkB,EACxB,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAqB,KAAK,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAC3E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE,OAAO,KAAK,EACV,6BAA6B,EAE9B,MAAM,SAAS,CAAC;AAEjB,eAAO,MAAM,UAAU,mCAAmC,CAAC;AAE3D,eAAO,MAAM,0BAA0B,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"storage-device-container-model.d.ts","sourceRoot":"","sources":["../../../../../../packages/kos-ui-sdk/src/models/models/storage-device/storage-device-container-model.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,eAAe,EAIpB,KAAK,oBAAoB,EAC1B,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,KAAK,kBAAkB,EAExB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACL,KAAK,aAAa,EAElB,KAAK,kBAAkB,EACxB,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAqB,KAAK,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAC3E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE,OAAO,KAAK,EACV,6BAA6B,EAE9B,MAAM,SAAS,CAAC;AAEjB,eAAO,MAAM,UAAU,mCAAmC,CAAC;AAE3D,eAAO,MAAM,0BAA0B,iBAAiB,CAAC;AAKzD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,MAAM,sBAAsB,GAChC,oBAAoB,CAAC,+BAA+B,CAAC,CAAC;AAExD,MAAM,MAAM,2BAA2B,GACrC,oBAAoB,CAAC,+BAA+B,CAAC,CAAC;AAExD;;;GAGG;AACH,qBACa,+BACX,YACE,gBAAgB,EAChB,eAAe,CAAC,kBAAkB,CAAC,EACnC,aAAa;IAEf,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,CAAC,MAAM,CAAmB;IACvB,OAAO,CAAC,OAAO,CAAyC;gBAEhE,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,kBAAkB;IAY7B,QAAQ,CAAC,EAAE,EAAE,MAAM;IAGnB,IAAI,MAAM,2CAET;IACD,IAAI,IAAI,yBAEP;IAED,QAAQ,CAAC,KAAK,EAAE,kBAAkB;IAIlC,WAAW,CAAC,EAAE,EAAE,MAAM;IAKhB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAK3B,IAAI,iBAAiB,YAEpB;IAED,IAAI,OAAO,yBAEV;IAMD,yBAAyB,CAAC,OAAO,EAAE,qBAAqB,EAAE;IA8BpD,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAiB5B"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kosdev-code/kos-ui-sdk",
|
|
3
|
-
"version": "0.1.0-next.
|
|
3
|
+
"version": "0.1.0-next.1036",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./index.cjs",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"react-router-dom": "^6.11.2"
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
|
-
"@kosdev-code/kos-api-levels": "0.1.0-next.
|
|
53
|
+
"@kosdev-code/kos-api-levels": "0.1.0-next.1036",
|
|
54
54
|
"mobx": "^6.9.0",
|
|
55
55
|
"mobx-react-lite": "^3.4.3",
|
|
56
56
|
"date-fns": "^2.30.0",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
},
|
|
60
60
|
"kos": {
|
|
61
61
|
"build": {
|
|
62
|
-
"gitHash": "
|
|
62
|
+
"gitHash": "17a2fd2a927dd5cf797317251f841ced6d20721c"
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
65
|
}
|
|
@@ -23651,6 +23651,7 @@ var __decorateClass$6 = (decorators, target, key, kind) => {
|
|
|
23651
23651
|
};
|
|
23652
23652
|
const MODEL_TYPE$5 = "storage-device-container-model";
|
|
23653
23653
|
const TOPIC_STORAGE_AVAILABILITY = "/kos/storage";
|
|
23654
|
+
const isInsertedStorage = (device) => !device.local;
|
|
23654
23655
|
let StorageDeviceContainerModelImpl = class {
|
|
23655
23656
|
id;
|
|
23656
23657
|
logger;
|
|
@@ -23689,7 +23690,8 @@ let StorageDeviceContainerModelImpl = class {
|
|
|
23689
23690
|
get volumes() {
|
|
23690
23691
|
return this.data;
|
|
23691
23692
|
}
|
|
23692
|
-
handleStorageAvailability(
|
|
23693
|
+
handleStorageAvailability(payload) {
|
|
23694
|
+
const devices = payload.filter(isInsertedStorage);
|
|
23693
23695
|
const toRemove = this._models.data.filter(
|
|
23694
23696
|
(model) => !devices.find((device) => device.id === model.id)
|
|
23695
23697
|
);
|
|
@@ -23717,7 +23719,7 @@ let StorageDeviceContainerModelImpl = class {
|
|
|
23717
23719
|
async load() {
|
|
23718
23720
|
this.logger.debug(`loading storage-device-container container ${this.id}`);
|
|
23719
23721
|
const storageDevices = await getStorageDevices();
|
|
23720
|
-
storageDevices.forEach((storageDevice) => {
|
|
23722
|
+
storageDevices.filter(isInsertedStorage).forEach((storageDevice) => {
|
|
23721
23723
|
if (storageDevice.deviceType !== "disk") {
|
|
23722
23724
|
const options = {
|
|
23723
23725
|
...storageDevice,
|
|
@@ -25413,4 +25415,4 @@ export {
|
|
|
25413
25415
|
StateBean as y,
|
|
25414
25416
|
getStateProps as z
|
|
25415
25417
|
};
|
|
25416
|
-
//# sourceMappingURL=software-info-registration-
|
|
25418
|
+
//# sourceMappingURL=software-info-registration-CPH7UyL6.js.map
|