@northern.tech/store 0.39.0 → 0.41.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/general-api.cjs +1 -1
- package/dist/api/general-api.js +1 -1
- package/dist/appSlice/index.js +1 -1
- package/dist/appSlice/selectors.d.cts +1 -1
- package/dist/appSlice/selectors.d.ts +1 -1
- package/dist/appSlice/thunks.d.cts +1 -1
- package/dist/appSlice/thunks.d.ts +1 -1
- package/dist/auth.cjs +1 -1
- package/dist/auth.js +1 -1
- package/dist/commonConstants.cjs +1 -1
- package/dist/commonConstants.js +1 -1
- package/dist/commonSelectors.cjs +1 -1
- package/dist/commonSelectors.d.cts +1 -1
- package/dist/commonSelectors.d.ts +1 -1
- package/dist/commonSelectors.js +1 -1
- package/dist/constants-CNZ5L0A0.cjs +957 -0
- package/dist/constants-CNZ5L0A0.cjs.map +1 -0
- package/dist/constants-Cj2kp3Iy.js +676 -0
- package/dist/constants-Cj2kp3Iy.js.map +1 -0
- package/dist/{constants-BwKiHHaB.d.ts → constants-D9o0Cnk_.d.cts} +2 -1
- package/dist/{constants-BwKiHHaB.d.cts → constants-D9o0Cnk_.d.ts} +2 -1
- package/dist/constants.cjs +48 -718
- package/dist/constants.d.cts +1 -1
- package/dist/constants.d.ts +1 -1
- package/dist/constants.js +1 -672
- package/dist/deploymentsSlice/constants.cjs +1 -1
- package/dist/deploymentsSlice/constants.d.cts +1 -1
- package/dist/deploymentsSlice/constants.d.ts +1 -1
- package/dist/deploymentsSlice/constants.js +1 -1
- package/dist/deploymentsSlice/index.cjs +1 -1
- package/dist/deploymentsSlice/index.js +1 -1
- package/dist/deploymentsSlice/mocks.cjs +1 -1
- package/dist/deploymentsSlice/mocks.cjs.map +1 -1
- package/dist/deploymentsSlice/mocks.d.cts +1 -1
- package/dist/deploymentsSlice/mocks.d.ts +1 -1
- package/dist/deploymentsSlice/mocks.js +1 -1
- package/dist/deploymentsSlice/mocks.js.map +1 -1
- package/dist/deploymentsSlice/selectors.cjs +1 -1
- package/dist/deploymentsSlice/selectors.d.cts +1 -1
- package/dist/deploymentsSlice/selectors.d.ts +1 -1
- package/dist/deploymentsSlice/selectors.js +1 -1
- package/dist/deploymentsSlice/thunks.d.cts +1 -1
- package/dist/deploymentsSlice/thunks.d.ts +1 -1
- package/dist/devicesSlice/constants.cjs +1 -1
- package/dist/devicesSlice/constants.js +1 -1
- package/dist/devicesSlice/index.js +1 -1
- package/dist/devicesSlice/mocks.js +1 -1
- package/dist/devicesSlice/selectors.cjs +1 -1
- package/dist/devicesSlice/selectors.d.cts +1 -1
- package/dist/devicesSlice/selectors.d.ts +1 -1
- package/dist/devicesSlice/selectors.js +1 -1
- package/dist/devicesSlice/thunks.d.cts +3 -3
- package/dist/devicesSlice/thunks.d.ts +3 -3
- package/dist/liststatehook.cjs +2 -1
- package/dist/liststatehook.cjs.map +1 -1
- package/dist/liststatehook.js +2 -1
- package/dist/liststatehook.js.map +1 -1
- package/dist/locationutils.cjs +1 -1
- package/dist/locationutils.js +1 -1
- package/dist/monitorSlice/index.js +1 -1
- package/dist/monitorSlice/mocks.js +1 -1
- package/dist/monitorSlice/selectors.d.cts +1 -1
- package/dist/monitorSlice/selectors.d.ts +1 -1
- package/dist/monitorSlice/thunks.cjs +1 -1
- package/dist/monitorSlice/thunks.cjs.map +1 -1
- package/dist/monitorSlice/thunks.d.cts +1 -1
- package/dist/monitorSlice/thunks.d.ts +1 -1
- package/dist/monitorSlice/thunks.js +1 -1
- package/dist/monitorSlice/thunks.js.map +1 -1
- package/dist/onboardingSlice/selectors.d.cts +1 -1
- package/dist/onboardingSlice/selectors.d.ts +1 -1
- package/dist/onboardingSlice/thunks.d.cts +1 -1
- package/dist/onboardingSlice/thunks.d.ts +1 -1
- package/dist/organizationSlice/constants.cjs +1 -1
- package/dist/organizationSlice/constants.js +1 -1
- package/dist/organizationSlice/index.cjs +1 -1
- package/dist/organizationSlice/index.js +1 -1
- package/dist/organizationSlice/mocks.js +1 -1
- package/dist/organizationSlice/selectors.cjs +1 -1
- package/dist/organizationSlice/selectors.d.cts +1 -1
- package/dist/organizationSlice/selectors.d.ts +1 -1
- package/dist/organizationSlice/selectors.js +1 -1
- package/dist/organizationSlice/thunks.d.cts +1 -1
- package/dist/organizationSlice/thunks.d.ts +1 -1
- package/dist/releasesSlice/index.js +1 -1
- package/dist/releasesSlice/mocks.js +1 -1
- package/dist/releasesSlice/selectors.d.cts +1 -1
- package/dist/releasesSlice/selectors.d.ts +1 -1
- package/dist/releasesSlice/thunks.cjs +6 -4
- package/dist/releasesSlice/thunks.cjs.map +1 -1
- package/dist/releasesSlice/thunks.d.cts +1 -1
- package/dist/releasesSlice/thunks.d.ts +1 -1
- package/dist/releasesSlice/thunks.js +6 -4
- package/dist/releasesSlice/thunks.js.map +1 -1
- package/dist/sockethook.cjs +1 -1
- package/dist/sockethook.js +1 -1
- package/dist/{store-xV2zaXAc.d.cts → store-B5-0USDz.d.cts} +3 -3
- package/dist/{store-BzrMxxAO.d.ts → store-CmiiLjxd.d.ts} +3 -3
- package/dist/store.cjs +1 -1
- package/dist/store.d.cts +1 -1
- package/dist/store.d.ts +1 -1
- package/dist/store.js +1 -1
- package/dist/storehooks.cjs +1 -1
- package/dist/storehooks.d.cts +1 -1
- package/dist/storehooks.d.ts +1 -1
- package/dist/storehooks.js +1 -1
- package/dist/thunks.cjs +57 -40
- package/dist/thunks.cjs.map +1 -1
- package/dist/thunks.d.cts +2 -2
- package/dist/thunks.d.ts +2 -2
- package/dist/thunks.js +54 -41
- package/dist/thunks.js.map +1 -1
- package/dist/usersSlice/constants.cjs +1 -1
- package/dist/usersSlice/constants.js +1 -1
- package/dist/usersSlice/index.cjs +1 -1
- package/dist/usersSlice/index.js +1 -1
- package/dist/usersSlice/mocks.js +1 -1
- package/dist/usersSlice/selectors.cjs +1 -1
- package/dist/usersSlice/selectors.d.cts +1 -1
- package/dist/usersSlice/selectors.d.ts +1 -1
- package/dist/usersSlice/selectors.js +1 -1
- package/dist/usersSlice/thunks.cjs +4 -0
- package/dist/usersSlice/thunks.d.cts +43 -3
- package/dist/usersSlice/thunks.d.ts +43 -3
- package/dist/usersSlice/thunks.js +2 -2
- package/dist/utils.cjs +11 -21
- package/dist/utils.cjs.map +1 -1
- package/dist/utils.d.cts +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +11 -21
- package/dist/utils.js.map +1 -1
- package/package.json +3 -3
- package/dist/constants.cjs.map +0 -1
- package/dist/constants.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_constants = require("../constants.cjs");
|
|
2
|
+
const require_constants = require("../constants-CNZ5L0A0.cjs");
|
|
3
3
|
exports.DEFAULT_PENDING_INPROGRESS_COUNT = require_constants.DEFAULT_PENDING_INPROGRESS_COUNT;
|
|
4
4
|
exports.DEPLOYMENT_ROUTES = require_constants.DEPLOYMENT_ROUTES;
|
|
5
5
|
exports.DEPLOYMENT_STATES = require_constants.DEPLOYMENT_STATES;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as DeploymentSubstateMapping, c as deploymentPrototype, d as deploymentSubstates, f as installationSubstatesMap, i as DEPLOYMENT_TYPES, l as deploymentStatesToSubstates, m as pauseMap, n as DEPLOYMENT_ROUTES, o as defaultStats, p as listDefaultsByState, r as DEPLOYMENT_STATES, s as deploymentDisplayStates, t as DEFAULT_PENDING_INPROGRESS_COUNT, u as deploymentStatesToSubstatesWithSkipped } from "../constants-
|
|
1
|
+
import { a as DeploymentSubstateMapping, c as deploymentPrototype, d as deploymentSubstates, f as installationSubstatesMap, i as DEPLOYMENT_TYPES, l as deploymentStatesToSubstates, m as pauseMap, n as DEPLOYMENT_ROUTES, o as defaultStats, p as listDefaultsByState, r as DEPLOYMENT_STATES, s as deploymentDisplayStates, t as DEFAULT_PENDING_INPROGRESS_COUNT, u as deploymentStatesToSubstatesWithSkipped } from "../constants-D9o0Cnk_.cjs";
|
|
2
2
|
export { DEFAULT_PENDING_INPROGRESS_COUNT, DEPLOYMENT_ROUTES, DEPLOYMENT_STATES, DEPLOYMENT_TYPES, DeploymentSubstateMapping, defaultStats, deploymentDisplayStates, deploymentPrototype, deploymentStatesToSubstates, deploymentStatesToSubstatesWithSkipped, deploymentSubstates, installationSubstatesMap, listDefaultsByState, pauseMap };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as DeploymentSubstateMapping, c as deploymentPrototype, d as deploymentSubstates, f as installationSubstatesMap, i as DEPLOYMENT_TYPES, l as deploymentStatesToSubstates, m as pauseMap, n as DEPLOYMENT_ROUTES, o as defaultStats, p as listDefaultsByState, r as DEPLOYMENT_STATES, s as deploymentDisplayStates, t as DEFAULT_PENDING_INPROGRESS_COUNT, u as deploymentStatesToSubstatesWithSkipped } from "../constants-
|
|
1
|
+
import { a as DeploymentSubstateMapping, c as deploymentPrototype, d as deploymentSubstates, f as installationSubstatesMap, i as DEPLOYMENT_TYPES, l as deploymentStatesToSubstates, m as pauseMap, n as DEPLOYMENT_ROUTES, o as defaultStats, p as listDefaultsByState, r as DEPLOYMENT_STATES, s as deploymentDisplayStates, t as DEFAULT_PENDING_INPROGRESS_COUNT, u as deploymentStatesToSubstatesWithSkipped } from "../constants-D9o0Cnk_.js";
|
|
2
2
|
export { DEFAULT_PENDING_INPROGRESS_COUNT, DEPLOYMENT_ROUTES, DEPLOYMENT_STATES, DEPLOYMENT_TYPES, DeploymentSubstateMapping, defaultStats, deploymentDisplayStates, deploymentPrototype, deploymentStatesToSubstates, deploymentStatesToSubstatesWithSkipped, deploymentSubstates, installationSubstatesMap, listDefaultsByState, pauseMap };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ct as deploymentSubstates, Et as pauseMap, St as deploymentStatesToSubstatesWithSkipped, Tt as listDefaultsByState, _t as DEPLOYMENT_TYPES, bt as deploymentPrototype, gt as DEPLOYMENT_STATES, ht as DEPLOYMENT_ROUTES, mt as DEFAULT_PENDING_INPROGRESS_COUNT, vt as defaultStats, wt as installationSubstatesMap, xt as deploymentStatesToSubstates, yt as deploymentDisplayStates } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
export { DEFAULT_PENDING_INPROGRESS_COUNT, DEPLOYMENT_ROUTES, DEPLOYMENT_STATES, DEPLOYMENT_TYPES, defaultStats, deploymentDisplayStates, deploymentPrototype, deploymentStatesToSubstates, deploymentStatesToSubstatesWithSkipped, deploymentSubstates, installationSubstatesMap, listDefaultsByState, pauseMap };
|
|
@@ -2,7 +2,7 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_constants = require("../constants.cjs");
|
|
5
|
+
const require_constants = require("../constants-CNZ5L0A0.cjs");
|
|
6
6
|
let _reduxjs_toolkit = require("@reduxjs/toolkit");
|
|
7
7
|
let _northern_tech_utils_constants = require("@northern.tech/utils/constants");
|
|
8
8
|
//#region src/deploymentsSlice/index.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { A as limitDefault, bt as deploymentPrototype, gt as DEPLOYMENT_STATES, ht as DEPLOYMENT_ROUTES, l as DEVICE_LIST_DEFAULTS } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { createSlice } from "@reduxjs/toolkit";
|
|
3
3
|
//#region src/deploymentsSlice/index.ts
|
|
4
4
|
const sliceName = "deployments";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mocks.cjs","names":["initialState"],"sources":["../../src/deploymentsSlice/mocks.ts"],"sourcesContent":["// Copyright 2025 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { initialState } from './index';\n\nexport const mockState = {\n ...initialState,\n byId: {\n d1: {\n id: 'd1',\n name: 'test deployment',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:30:00.000Z',\n device_count: 1,\n devices: {\n a1: {\n attributes: {},\n id: 'a1',\n image: { size: 123 },\n status: 'installing'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 1,\n noartifact: 0,\n pending: 0,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n },\n total_size: 1234\n }\n },\n d2: {\n id: 'd2',\n name: 'test deployment 2',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:25:00.000Z',\n device_count: 1,\n devices: {\n b1: {\n attributes: {},\n id: 'b1',\n status: 'pending'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 0,\n noartifact: 0,\n pending: 1,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n }\n }\n },\n d3: {\n id: 'd3',\n name: 'Test',\n phases: [\n { id: '0', batch_size: 2, device_count: 2 },\n { id: '1', start_ts: '2019-02-04T11:45:10.002Z', batch_size: 3, device_count: 3 },\n { id: '2', start_ts: '2019-02-05T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '3', start_ts: '2019-02-06T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '4', start_ts: '2019-02-21T11:45:10.002Z', batch_size: 5, device_count: 0 }\n ],\n max_devices: 0,\n created: '2019-01-31T12:59:30.020Z',\n devices: {},\n filter: undefined,\n group: undefined,\n stats: {\n pending: 3,\n decommissioned: 0,\n failure: 23,\n pause_before_committing: 0,\n pause_before_rebooting: 0,\n installing: 0,\n rebooting: 0,\n 'already-installed': 0,\n pause_before_installing: 0,\n downloading: 0,\n success: 6,\n aborted: 0,\n noartifact: 0\n },\n statistics: { total_size: '1234' },\n status: 'inprogress',\n active: true,\n device_count: 100,\n retries:
|
|
1
|
+
{"version":3,"file":"mocks.cjs","names":["initialState"],"sources":["../../src/deploymentsSlice/mocks.ts"],"sourcesContent":["// Copyright 2025 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { initialState } from './index';\n\nexport const mockState = {\n ...initialState,\n byId: {\n d1: {\n id: 'd1',\n name: 'test deployment',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:30:00.000Z',\n device_count: 1,\n devices: {\n a1: {\n attributes: {},\n id: 'a1',\n image: { size: 123 },\n status: 'installing'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 1,\n noartifact: 0,\n pending: 0,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n },\n total_size: 1234\n }\n },\n d2: {\n id: 'd2',\n name: 'test deployment 2',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:25:00.000Z',\n device_count: 1,\n devices: {\n b1: {\n attributes: {},\n id: 'b1',\n status: 'pending'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 0,\n noartifact: 0,\n pending: 1,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n }\n }\n },\n d3: {\n id: 'd3',\n name: 'Test',\n phases: [\n { id: '0', batch_size: 2, device_count: 2 },\n { id: '1', start_ts: '2019-02-04T11:45:10.002Z', batch_size: 3, device_count: 3 },\n { id: '2', start_ts: '2019-02-05T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '3', start_ts: '2019-02-06T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '4', start_ts: '2019-02-21T11:45:10.002Z', batch_size: 5, device_count: 0 }\n ],\n max_devices: 0,\n created: '2019-01-31T12:59:30.020Z',\n devices: {},\n filter: undefined,\n group: undefined,\n stats: {\n pending: 3,\n decommissioned: 0,\n failure: 23,\n pause_before_committing: 0,\n pause_before_rebooting: 0,\n installing: 0,\n rebooting: 0,\n 'already-installed': 0,\n pause_before_installing: 0,\n downloading: 0,\n success: 6,\n aborted: 0,\n noartifact: 0\n },\n statistics: { total_size: '1234' },\n status: 'inprogress',\n active: true,\n device_count: 100,\n retries: 0,\n type: 'software'\n }\n },\n byStatus: {\n finished: { deploymentIds: ['d1'], total: 1 },\n inprogress: { deploymentIds: ['d3'], total: 1 },\n pending: { deploymentIds: ['d2'], total: 1 },\n scheduled: { deploymentIds: ['d2'], total: 1 }\n },\n deploymentDeviceLimit: 500,\n selectedDeviceIds: [],\n selectionState: {\n finished: {\n ...initialState.selectionState.finished,\n selection: ['d1'],\n endDate: undefined,\n search: '',\n total: 1,\n type: ''\n },\n inprogress: { ...initialState.selectionState.inprogress, selection: ['d1'], total: 1 },\n pending: { ...initialState.selectionState.pending, selection: ['d2'], total: 1 },\n scheduled: { ...initialState.selectionState.scheduled, selection: ['d2'], total: 1 },\n general: {\n state: 'active',\n showCreationDialog: false,\n showReportDialog: false,\n reportType: null\n },\n selectedId: 'd1'\n }\n};\n"],"mappings":";;;AAeA,MAAa,YAAY;CACvB,GAAGA,+BAAAA;CACH,MAAM;EACJ,IAAI;GACF,IAAI;GACJ,MAAM;GACN,eAAe;GACf,WAAW,CAAC,KAAK;GACjB,SAAS;GACT,cAAc;GACd,SAAS,EACP,IAAI;IACF,YAAY,CAAC;IACb,IAAI;IACJ,OAAO,EAAE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SAAS;GACT,MAAM;EACR;CACF;CACA,UAAU;EACR,UAAU;GAAE,eAAe,CAAC,IAAI;GAAG,OAAO;EAAE;EAC5C,YAAY;GAAE,eAAe,CAAC,IAAI;GAAG,OAAO;EAAE;EAC9C,SAAS;GAAE,eAAe,CAAC,IAAI;GAAG,OAAO;EAAE;EAC3C,WAAW;GAAE,eAAe,CAAC,IAAI;GAAG,OAAO;EAAE;CAC/C;CACA,uBAAuB;CACvB,mBAAmB,CAAC;CACpB,gBAAgB;EACd,UAAU;GACR,GAAGA,+BAAAA,aAAa,eAAe;GAC/B,WAAW,CAAC,IAAI;GAChB,SAAS,KAAA;GACT,QAAQ;GACR,OAAO;GACP,MAAM;EACR;EACA,YAAY;GAAE,GAAGA,+BAAAA,aAAa,eAAe;GAAY,WAAW,CAAC,IAAI;GAAG,OAAO;EAAE;EACrF,SAAS;GAAE,GAAGA,+BAAAA,aAAa,eAAe;GAAS,WAAW,CAAC,IAAI;GAAG,OAAO;EAAE;EAC/E,WAAW;GAAE,GAAGA,+BAAAA,aAAa,eAAe;GAAW,WAAW,CAAC,IAAI;GAAG,OAAO;EAAE;EACnF,SAAS;GACP,OAAO;GACP,oBAAoB;GACpB,kBAAkB;GAClB,YAAY;EACd;EACA,YAAY;CACd;AACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mocks.js","names":[],"sources":["../../src/deploymentsSlice/mocks.ts"],"sourcesContent":["// Copyright 2025 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { initialState } from './index';\n\nexport const mockState = {\n ...initialState,\n byId: {\n d1: {\n id: 'd1',\n name: 'test deployment',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:30:00.000Z',\n device_count: 1,\n devices: {\n a1: {\n attributes: {},\n id: 'a1',\n image: { size: 123 },\n status: 'installing'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 1,\n noartifact: 0,\n pending: 0,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n },\n total_size: 1234\n }\n },\n d2: {\n id: 'd2',\n name: 'test deployment 2',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:25:00.000Z',\n device_count: 1,\n devices: {\n b1: {\n attributes: {},\n id: 'b1',\n status: 'pending'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 0,\n noartifact: 0,\n pending: 1,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n }\n }\n },\n d3: {\n id: 'd3',\n name: 'Test',\n phases: [\n { id: '0', batch_size: 2, device_count: 2 },\n { id: '1', start_ts: '2019-02-04T11:45:10.002Z', batch_size: 3, device_count: 3 },\n { id: '2', start_ts: '2019-02-05T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '3', start_ts: '2019-02-06T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '4', start_ts: '2019-02-21T11:45:10.002Z', batch_size: 5, device_count: 0 }\n ],\n max_devices: 0,\n created: '2019-01-31T12:59:30.020Z',\n devices: {},\n filter: undefined,\n group: undefined,\n stats: {\n pending: 3,\n decommissioned: 0,\n failure: 23,\n pause_before_committing: 0,\n pause_before_rebooting: 0,\n installing: 0,\n rebooting: 0,\n 'already-installed': 0,\n pause_before_installing: 0,\n downloading: 0,\n success: 6,\n aborted: 0,\n noartifact: 0\n },\n statistics: { total_size: '1234' },\n status: 'inprogress',\n active: true,\n device_count: 100,\n retries:
|
|
1
|
+
{"version":3,"file":"mocks.js","names":[],"sources":["../../src/deploymentsSlice/mocks.ts"],"sourcesContent":["// Copyright 2025 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { initialState } from './index';\n\nexport const mockState = {\n ...initialState,\n byId: {\n d1: {\n id: 'd1',\n name: 'test deployment',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:30:00.000Z',\n device_count: 1,\n devices: {\n a1: {\n attributes: {},\n id: 'a1',\n image: { size: 123 },\n status: 'installing'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 1,\n noartifact: 0,\n pending: 0,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n },\n total_size: 1234\n }\n },\n d2: {\n id: 'd2',\n name: 'test deployment 2',\n artifact_name: 'r1',\n artifacts: ['123'],\n created: '2019-01-01T12:25:00.000Z',\n device_count: 1,\n devices: {\n b1: {\n attributes: {},\n id: 'b1',\n status: 'pending'\n }\n },\n filter: undefined,\n group: undefined,\n statistics: {\n status: {\n downloading: 0,\n decommissioned: 0,\n failure: 0,\n installing: 0,\n noartifact: 0,\n pending: 1,\n rebooting: 0,\n success: 0,\n 'already-installed': 0\n }\n }\n },\n d3: {\n id: 'd3',\n name: 'Test',\n phases: [\n { id: '0', batch_size: 2, device_count: 2 },\n { id: '1', start_ts: '2019-02-04T11:45:10.002Z', batch_size: 3, device_count: 3 },\n { id: '2', start_ts: '2019-02-05T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '3', start_ts: '2019-02-06T11:45:10.002Z', batch_size: 5, device_count: 5 },\n { id: '4', start_ts: '2019-02-21T11:45:10.002Z', batch_size: 5, device_count: 0 }\n ],\n max_devices: 0,\n created: '2019-01-31T12:59:30.020Z',\n devices: {},\n filter: undefined,\n group: undefined,\n stats: {\n pending: 3,\n decommissioned: 0,\n failure: 23,\n pause_before_committing: 0,\n pause_before_rebooting: 0,\n installing: 0,\n rebooting: 0,\n 'already-installed': 0,\n pause_before_installing: 0,\n downloading: 0,\n success: 6,\n aborted: 0,\n noartifact: 0\n },\n statistics: { total_size: '1234' },\n status: 'inprogress',\n active: true,\n device_count: 100,\n retries: 0,\n type: 'software'\n }\n },\n byStatus: {\n finished: { deploymentIds: ['d1'], total: 1 },\n inprogress: { deploymentIds: ['d3'], total: 1 },\n pending: { deploymentIds: ['d2'], total: 1 },\n scheduled: { deploymentIds: ['d2'], total: 1 }\n },\n deploymentDeviceLimit: 500,\n selectedDeviceIds: [],\n selectionState: {\n finished: {\n ...initialState.selectionState.finished,\n selection: ['d1'],\n endDate: undefined,\n search: '',\n total: 1,\n type: ''\n },\n inprogress: { ...initialState.selectionState.inprogress, selection: ['d1'], total: 1 },\n pending: { ...initialState.selectionState.pending, selection: ['d2'], total: 1 },\n scheduled: { ...initialState.selectionState.scheduled, selection: ['d2'], total: 1 },\n general: {\n state: 'active',\n showCreationDialog: false,\n showReportDialog: false,\n reportType: null\n },\n selectedId: 'd1'\n }\n};\n"],"mappings":";;AAeA,MAAa,YAAY;CACvB,GAAG;CACH,MAAM;EACJ,IAAI;GACF,IAAI;GACJ,MAAM;GACN,eAAe;GACf,WAAW,CAAC,KAAK;GACjB,SAAS;GACT,cAAc;GACd,SAAS,EACP,IAAI;IACF,YAAY,CAAC;IACb,IAAI;IACJ,OAAO,EAAE,MAAM,IAAI;IACnB,QAAQ;GACV,EACF;GACA,QAAQ,KAAA;GACR,OAAO,KAAA;GACP,YAAY;IACV,QAAQ;KACN,aAAa;KACb,gBAAgB;KAChB,SAAS;KACT,YAAY;KACZ,YAAY;KACZ,SAAS;KACT,WAAW;KACX,SAAS;KAC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OAAO;EAAE;EAC3C,WAAW;GAAE,eAAe,CAAC,IAAI;GAAG,OAAO;EAAE;CAC/C;CACA,uBAAuB;CACvB,mBAAmB,CAAC;CACpB,gBAAgB;EACd,UAAU;GACR,GAAG,aAAa,eAAe;GAC/B,WAAW,CAAC,IAAI;GAChB,SAAS,KAAA;GACT,QAAQ;GACR,OAAO;GACP,MAAM;EACR;EACA,YAAY;GAAE,GAAG,aAAa,eAAe;GAAY,WAAW,CAAC,IAAI;GAAG,OAAO;EAAE;EACrF,SAAS;GAAE,GAAG,aAAa,eAAe;GAAS,WAAW,CAAC,IAAI;GAAG,OAAO;EAAE;EAC/E,WAAW;GAAE,GAAG,aAAa,eAAe;GAAW,WAAW,CAAC,IAAI;GAAG,OAAO;EAAE;EACnF,SAAS;GACP,OAAO;GACP,oBAAoB;GACpB,kBAAkB;GAClB,YAAY;EACd;EACA,YAAY;CACd;AACF"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_constants = require("../constants.cjs");
|
|
2
|
+
const require_constants = require("../constants-CNZ5L0A0.cjs");
|
|
3
3
|
let _reduxjs_toolkit = require("@reduxjs/toolkit");
|
|
4
4
|
//#region src/deploymentsSlice/selectors.ts
|
|
5
5
|
const getDeploymentsById = (state) => state.deployments.byId;
|
|
@@ -6,7 +6,7 @@ import { s as DeviceSliceType } from "../index-Doc_1P_Y.cjs";
|
|
|
6
6
|
import { t as AppSliceType } from "../index-C8QadAm7.cjs";
|
|
7
7
|
import { t as MonitorSliceType } from "../index-5Q-iI4EB.cjs";
|
|
8
8
|
import { t as OrganizationSliceType } from "../index-Bj3OArhr.cjs";
|
|
9
|
-
import { r as RootState } from "../store-
|
|
9
|
+
import { r as RootState } from "../store-B5-0USDz.cjs";
|
|
10
10
|
|
|
11
11
|
//#region src/deploymentsSlice/selectors.d.ts
|
|
12
12
|
declare const getDeploymentsById: (state: RootState) => Record<string, Deployment>;
|
|
@@ -6,7 +6,7 @@ import { s as DeviceSliceType } from "../index-BqJuhvO_.js";
|
|
|
6
6
|
import { t as AppSliceType } from "../index-BLvjQfGj.js";
|
|
7
7
|
import { t as MonitorSliceType } from "../index-ByfjrTdH.js";
|
|
8
8
|
import { t as OrganizationSliceType } from "../index-BBsUj1a8.js";
|
|
9
|
-
import { r as RootState } from "../store-
|
|
9
|
+
import { r as RootState } from "../store-CmiiLjxd.js";
|
|
10
10
|
|
|
11
11
|
//#region src/deploymentsSlice/selectors.d.ts
|
|
12
12
|
declare const getDeploymentsById: (state: RootState) => Record<string, Deployment>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DEPLOYMENT_STATES } from "../constants.js";
|
|
1
|
+
import { gt as DEPLOYMENT_STATES } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { createSelector } from "@reduxjs/toolkit";
|
|
3
3
|
//#region src/deploymentsSlice/selectors.ts
|
|
4
4
|
const getDeploymentsById = (state) => state.deployments.byId;
|
|
@@ -2,7 +2,7 @@ import { T as SortOptions } from "../constants-_p6w8uEp.cjs";
|
|
|
2
2
|
import { c as SelectionListState, i as DeploymentConfig, l as SelectionState, r as DeploymentByStatusKey, t as Deployment } from "../index-EPmsL6Lb.cjs";
|
|
3
3
|
import { t as Device$1 } from "../index-Doc_1P_Y.cjs";
|
|
4
4
|
import { i as SnackbarContent } from "../index-C8QadAm7.cjs";
|
|
5
|
-
import { r as RootState, t as AppDispatch } from "../store-
|
|
5
|
+
import { r as RootState, t as AppDispatch } from "../store-B5-0USDz.cjs";
|
|
6
6
|
import { DeploymentV1, DeploymentV2, NewDeploymentForGroup, NewDeploymentTypeManagement, NewDeploymentV2TypeManagement } from "@northern.tech/types/MenderTypes";
|
|
7
7
|
|
|
8
8
|
//#region src/deploymentsSlice/thunks.d.ts
|
|
@@ -2,7 +2,7 @@ import { T as SortOptions } from "../constants-OcdoVk6f.js";
|
|
|
2
2
|
import { c as SelectionListState, i as DeploymentConfig, l as SelectionState, r as DeploymentByStatusKey, t as Deployment } from "../index-Bb4yvvgG.js";
|
|
3
3
|
import { t as Device$1 } from "../index-BqJuhvO_.js";
|
|
4
4
|
import { i as SnackbarContent } from "../index-BLvjQfGj.js";
|
|
5
|
-
import { r as RootState, t as AppDispatch } from "../store-
|
|
5
|
+
import { r as RootState, t as AppDispatch } from "../store-CmiiLjxd.js";
|
|
6
6
|
import { DeploymentV1, DeploymentV2, NewDeploymentForGroup, NewDeploymentTypeManagement, NewDeploymentV2TypeManagement } from "@northern.tech/types/MenderTypes";
|
|
7
7
|
|
|
8
8
|
//#region src/deploymentsSlice/thunks.d.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_constants = require("../constants.cjs");
|
|
2
|
+
const require_constants = require("../constants-CNZ5L0A0.cjs");
|
|
3
3
|
exports.DEVICE_CONNECT_STATES = require_constants.DEVICE_CONNECT_STATES;
|
|
4
4
|
exports.DEVICE_DISMISSAL_STATE = require_constants.DEVICE_DISMISSAL_STATE;
|
|
5
5
|
exports.DEVICE_MESSAGE_PROTOCOLS = require_constants.DEVICE_MESSAGE_PROTOCOLS;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ct as DEVICE_DISMISSAL_STATE, dt as REPORT_CHART_SIZE_LIMIT, ft as emptyFilter, lt as DEVICE_MESSAGE_PROTOCOLS, pt as geoAttributes, st as DEVICE_CONNECT_STATES, ut as DEVICE_MESSAGE_TYPES } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
export { DEVICE_CONNECT_STATES, DEVICE_DISMISSAL_STATE, DEVICE_MESSAGE_PROTOCOLS, DEVICE_MESSAGE_TYPES, REPORT_CHART_SIZE_LIMIT, emptyFilter, geoAttributes };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DEVICE_LIST_DEFAULTS, DEVICE_STATES
|
|
1
|
+
import { f as SORTING_OPTIONS, l as DEVICE_LIST_DEFAULTS, u as DEVICE_STATES } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { createSlice } from "@reduxjs/toolkit";
|
|
3
3
|
import { deepCompare, duplicateFilter } from "@northern.tech/utils/helpers";
|
|
4
4
|
//#region src/devicesSlice/index.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { f as SORTING_OPTIONS, u as DEVICE_STATES } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { initialState } from "./index.js";
|
|
3
3
|
//#region src/devicesSlice/mocks.ts
|
|
4
4
|
const deviceTypes = { qemu: "qemux86-64" };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_constants = require("../constants.cjs");
|
|
2
|
+
const require_constants = require("../constants-CNZ5L0A0.cjs");
|
|
3
3
|
let _reduxjs_toolkit = require("@reduxjs/toolkit");
|
|
4
4
|
let _northern_tech_utils_helpers = require("@northern.tech/utils/helpers");
|
|
5
5
|
let _northern_tech_utils_constants = require("@northern.tech/utils/constants");
|
|
@@ -6,7 +6,7 @@ import { a as DeviceListState, n as DeviceFilter, r as DeviceGroup, s as DeviceS
|
|
|
6
6
|
import { t as AppSliceType } from "../index-C8QadAm7.cjs";
|
|
7
7
|
import { t as MonitorSliceType } from "../index-5Q-iI4EB.cjs";
|
|
8
8
|
import { t as OrganizationSliceType } from "../index-Bj3OArhr.cjs";
|
|
9
|
-
import { r as RootState } from "../store-
|
|
9
|
+
import { r as RootState } from "../store-B5-0USDz.cjs";
|
|
10
10
|
|
|
11
11
|
//#region src/devicesSlice/selectors.d.ts
|
|
12
12
|
declare const getAcceptedDevices: (state: RootState) => {
|
|
@@ -6,7 +6,7 @@ import { a as DeviceListState, n as DeviceFilter, r as DeviceGroup, s as DeviceS
|
|
|
6
6
|
import { t as AppSliceType } from "../index-BLvjQfGj.js";
|
|
7
7
|
import { t as MonitorSliceType } from "../index-ByfjrTdH.js";
|
|
8
8
|
import { t as OrganizationSliceType } from "../index-BBsUj1a8.js";
|
|
9
|
-
import { r as RootState } from "../store-
|
|
9
|
+
import { r as RootState } from "../store-CmiiLjxd.js";
|
|
10
10
|
|
|
11
11
|
//#region src/devicesSlice/selectors.d.ts
|
|
12
12
|
declare const getAcceptedDevices: (state: RootState) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Mt as UNGROUPED_GROUP, u as DEVICE_STATES } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { createSelector } from "@reduxjs/toolkit";
|
|
3
3
|
import { duplicateFilter } from "@northern.tech/utils/helpers";
|
|
4
4
|
//#region src/devicesSlice/selectors.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { m as DeviceIssueOptionKey, mt as DeviceAuthState } from "../constants-_p6w8uEp.cjs";
|
|
2
2
|
import { a as DeviceListState, n as DeviceFilter, o as DeviceSelectedAttribute, r as DeviceGroup, t as Device$1 } from "../index-Doc_1P_Y.cjs";
|
|
3
3
|
import { i as SnackbarContent, n as SearchState } from "../index-C8QadAm7.cjs";
|
|
4
|
-
import { r as RootState, t as AppDispatch } from "../store-
|
|
5
|
-
import { ConnectionState, Device, DeviceConfiguration,
|
|
4
|
+
import { r as RootState, t as AppDispatch } from "../store-B5-0USDz.cjs";
|
|
5
|
+
import { ConnectionState, Device, DeviceConfiguration, DeviceInventoryResponse, DeviceTierLimits, DeviceWithImage, Filter, Integration, ManagementApiConfiguration, NewConfigurationDeployment, PreAuthSet, SortCriteria, Status } from "@northern.tech/types/MenderTypes";
|
|
6
6
|
|
|
7
7
|
//#region src/devicesSlice/thunks.d.ts
|
|
8
8
|
declare const getGroups: import("@reduxjs/toolkit").AsyncThunk<{
|
|
@@ -228,7 +228,7 @@ declare const selectGroup: import("@reduxjs/toolkit").AsyncThunk<unknown, {
|
|
|
228
228
|
fulfilledMeta?: unknown;
|
|
229
229
|
rejectedMeta?: unknown;
|
|
230
230
|
}>;
|
|
231
|
-
type ReceivedDevice = Device &
|
|
231
|
+
type ReceivedDevice = Device & DeviceInventoryResponse & Omit<DeviceWithImage, 'status'>;
|
|
232
232
|
type getGroupDevicesPayload = {
|
|
233
233
|
group: string;
|
|
234
234
|
page?: number;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { m as DeviceIssueOptionKey, mt as DeviceAuthState } from "../constants-OcdoVk6f.js";
|
|
2
2
|
import { a as DeviceListState, n as DeviceFilter, o as DeviceSelectedAttribute, r as DeviceGroup, t as Device$1 } from "../index-BqJuhvO_.js";
|
|
3
3
|
import { i as SnackbarContent, n as SearchState } from "../index-BLvjQfGj.js";
|
|
4
|
-
import { r as RootState, t as AppDispatch } from "../store-
|
|
5
|
-
import { ConnectionState, Device, DeviceConfiguration,
|
|
4
|
+
import { r as RootState, t as AppDispatch } from "../store-CmiiLjxd.js";
|
|
5
|
+
import { ConnectionState, Device, DeviceConfiguration, DeviceInventoryResponse, DeviceTierLimits, DeviceWithImage, Filter, Integration, ManagementApiConfiguration, NewConfigurationDeployment, PreAuthSet, SortCriteria, Status } from "@northern.tech/types/MenderTypes";
|
|
6
6
|
|
|
7
7
|
//#region src/devicesSlice/thunks.d.ts
|
|
8
8
|
declare const getGroups: import("@reduxjs/toolkit").AsyncThunk<{
|
|
@@ -228,7 +228,7 @@ declare const selectGroup: import("@reduxjs/toolkit").AsyncThunk<unknown, {
|
|
|
228
228
|
fulfilledMeta?: unknown;
|
|
229
229
|
rejectedMeta?: unknown;
|
|
230
230
|
}>;
|
|
231
|
-
type ReceivedDevice = Device &
|
|
231
|
+
type ReceivedDevice = Device & DeviceInventoryResponse & Omit<DeviceWithImage, 'status'>;
|
|
232
232
|
type getGroupDevicesPayload = {
|
|
233
233
|
group: string;
|
|
234
234
|
page?: number;
|
package/dist/liststatehook.cjs
CHANGED
|
@@ -69,10 +69,11 @@ const useLocationParams = (key, extras, processors = defaultProcessors) => {
|
|
|
69
69
|
location
|
|
70
70
|
});
|
|
71
71
|
const formatFn = processors[key].format;
|
|
72
|
+
const searchQuery = [processors.common.format(newValue.pageState, extras), formatFn(newValue, extras)].filter((i) => i).join("&");
|
|
72
73
|
navigate({
|
|
73
74
|
pathname,
|
|
74
75
|
replace: true,
|
|
75
|
-
search: `?${
|
|
76
|
+
search: `?${searchQuery}`,
|
|
76
77
|
...options
|
|
77
78
|
});
|
|
78
79
|
}, [extrasString, key]),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"liststatehook.cjs","names":["formatAuditlogs","parseAuditlogsQuery","formatPageState","commonProcessor","formatDeployments","generateDeploymentsPath","parseDeploymentsQuery","formatDeviceSearch","generateDevicePath","parseDeviceQuery","formatReleases","generateReleasesPath","parseReleasesQuery","formatTenants","generateTenantPath","parseTenantsQuery"],"sources":["../src/liststatehook.ts"],"sourcesContent":["// Copyright 2022 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { useCallback, useMemo } from 'react';\nimport type { Location, NavigateOptions } from 'react-router';\nimport { useLocation, useNavigate, useNavigationType, useSearchParams } from 'react-router';\n\nimport type { CommonProcessorResult, FormatPageStateDefaults, PageState } from './locationutils';\nimport {\n commonProcessor,\n formatAuditlogs,\n formatDeployments,\n formatDeviceSearch,\n formatPageState,\n formatReleases,\n formatTenants,\n generateDeploymentsPath,\n generateDevicePath,\n generateReleasesPath,\n generateTenantPath,\n parseAuditlogsQuery,\n parseDeploymentsQuery,\n parseDeviceQuery,\n parseReleasesQuery,\n parseTenantsQuery\n} from './locationutils';\n\ntype ProcessorConfig<TFormat, TLocate, TParse> = {\n format: TFormat;\n locate: TLocate;\n parse: TParse;\n};\n\ntype Processors = {\n auditlogs: ProcessorConfig<typeof formatAuditlogs, () => undefined, typeof parseAuditlogsQuery>;\n common: ProcessorConfig<typeof formatPageState, () => undefined, typeof commonProcessor>;\n deployments: ProcessorConfig<typeof formatDeployments, typeof generateDeploymentsPath, typeof parseDeploymentsQuery>;\n devices: ProcessorConfig<typeof formatDeviceSearch, typeof generateDevicePath, typeof parseDeviceQuery>;\n releases: ProcessorConfig<typeof formatReleases, typeof generateReleasesPath, typeof parseReleasesQuery>;\n tenants: ProcessorConfig<typeof formatTenants, typeof generateTenantPath, typeof parseTenantsQuery>;\n};\n\nexport const defaultProcessors: Processors = {\n auditlogs: {\n format: formatAuditlogs,\n locate: () => undefined,\n parse: parseAuditlogsQuery\n },\n common: {\n format: formatPageState,\n locate: () => undefined,\n parse: commonProcessor\n },\n deployments: {\n format: formatDeployments,\n locate: generateDeploymentsPath,\n parse: parseDeploymentsQuery\n },\n devices: {\n format: formatDeviceSearch,\n locate: generateDevicePath,\n parse: parseDeviceQuery\n },\n releases: {\n format: formatReleases,\n locate: generateReleasesPath,\n parse: parseReleasesQuery\n },\n tenants: {\n format: formatTenants,\n locate: generateTenantPath,\n parse: parseTenantsQuery\n }\n};\n\ntype ProcessorKey = keyof Omit<Processors, 'common'>;\n\ntype LocationExtras = Record<string, unknown>;\n\ntype LocationParamsValue = PageState & CommonProcessorResult['sort'] & Record<string, unknown>;\n\ntype SetValueParams = {\n [key: string]: unknown;\n pageState: PageState;\n};\n\ntype UseLocationParamsReturn = [\n value: LocationParamsValue,\n setValue: (newValue: SetValueParams, options?: NavigateOptions) => void,\n options: { shouldInitializeFromUrl: boolean }\n];\n\nexport const useLocationParams = (key: ProcessorKey, extras: LocationExtras, processors: Processors = defaultProcessors): UseLocationParamsReturn => {\n const [searchParams] = useSearchParams();\n const navigate = useNavigate();\n const location = useLocation();\n const navigationType = useNavigationType();\n\n // POP (back/ forward/ initial load) -> rely on url state - otherwise on stored redux state\n const shouldInitializeFromUrl = navigationType === 'POP';\n\n const extrasString = JSON.stringify(extras);\n const searchParamsString = searchParams.toString();\n\n const value = useMemo(() => {\n const { pageState, params, sort } = processors.common.parse(searchParams);\n const extendedExtras = { ...extras, pageState, location };\n return {\n ...pageState,\n sort,\n ...(processors[key].parse as (params: URLSearchParams, extras: typeof extendedExtras) => Record<string, unknown>)(params, extendedExtras)\n } as LocationParamsValue;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [extrasString, key, location.search, location.pathname, searchParamsString]);\n\n const setValue = useCallback(\n (newValue: SetValueParams, options: NavigateOptions = {}): void => {\n const locateFn = processors[key].locate as (params: { location: Location; pageState: PageState }) => string | undefined;\n const pathname = locateFn({ pageState: newValue.pageState, location });\n const formatFn = processors[key].format as (value: SetValueParams, extras: LocationExtras) => string;\n const searchQuery = [processors.common.format(newValue.pageState, extras as FormatPageStateDefaults), formatFn(newValue, extras)]\n .filter(i => i)\n .join('&');\n navigate({ pathname, replace: true, search: `?${searchQuery}`, ...options });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [extrasString, key]\n );\n\n return [value, setValue, { shouldInitializeFromUrl }];\n};\n"],"mappings":";;;;;AAoDA,MAAa,oBAAgC;CAC3C,WAAW;EACT,QAAQA,sBAAAA;EACR,cAAc,KAAA;EACd,OAAOC,sBAAAA;CACT;CACA,QAAQ;EACN,QAAQC,sBAAAA;EACR,cAAc,KAAA;EACd,OAAOC,sBAAAA;CACT;CACA,aAAa;EACX,QAAQC,sBAAAA;EACR,QAAQC,sBAAAA;EACR,OAAOC,sBAAAA;CACT;CACA,SAAS;EACP,QAAQC,sBAAAA;EACR,QAAQC,sBAAAA;EACR,OAAOC,sBAAAA;CACT;CACA,UAAU;EACR,QAAQC,sBAAAA;EACR,QAAQC,sBAAAA;EACR,OAAOC,sBAAAA;CACT;CACA,SAAS;EACP,QAAQC,sBAAAA;EACR,QAAQC,sBAAAA;EACR,OAAOC,sBAAAA;CACT;AACF;AAmBA,MAAa,qBAAqB,KAAmB,QAAwB,aAAyB,sBAA+C;CACnJ,MAAM,CAAC,iBAAA,GAAA,aAAA,gBAAA,CAAgC;CACvC,MAAM,YAAA,GAAA,aAAA,YAAA,CAAuB;CAC7B,MAAM,YAAA,GAAA,aAAA,YAAA,CAAuB;CAI7B,MAAM,2BAAA,GAAA,aAAA,kBAAA,CAAuC,MAAM;CAEnD,MAAM,eAAe,KAAK,UAAU,MAAM;CAC1C,MAAM,qBAAqB,aAAa,SAAS;CA2BjD,OAAO;2BAzBqB;GAC1B,MAAM,EAAE,WAAW,QAAQ,SAAS,WAAW,OAAO,MAAM,YAAY;GACxE,MAAM,iBAAiB;IAAE,GAAG;IAAQ;IAAW;GAAS;GACxD,OAAO;IACL,GAAG;IACH;IACA,GAAI,WAAW,IAAI,CAAC,MAA8F,QAAQ,cAAc;GAC1I;EAEF,GAAG;GAAC;GAAc;GAAK,SAAS;GAAQ,SAAS;GAAU;EAAkB,CAgBjE;0BAbT,UAA0B,UAA2B,CAAC,MAAY;GACjE,MAAM,WAAW,WAAW,IAAI,CAAC;GACjC,MAAM,WAAW,SAAS;IAAE,WAAW,SAAS;IAAW;GAAS,CAAC;GACrE,MAAM,WAAW,WAAW,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"liststatehook.cjs","names":["formatAuditlogs","parseAuditlogsQuery","formatPageState","commonProcessor","formatDeployments","generateDeploymentsPath","parseDeploymentsQuery","formatDeviceSearch","generateDevicePath","parseDeviceQuery","formatReleases","generateReleasesPath","parseReleasesQuery","formatTenants","generateTenantPath","parseTenantsQuery"],"sources":["../src/liststatehook.ts"],"sourcesContent":["// Copyright 2022 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { useCallback, useMemo } from 'react';\nimport type { Location, NavigateOptions } from 'react-router';\nimport { useLocation, useNavigate, useNavigationType, useSearchParams } from 'react-router';\n\nimport type { CommonProcessorResult, FormatPageStateDefaults, PageState } from './locationutils';\nimport {\n commonProcessor,\n formatAuditlogs,\n formatDeployments,\n formatDeviceSearch,\n formatPageState,\n formatReleases,\n formatTenants,\n generateDeploymentsPath,\n generateDevicePath,\n generateReleasesPath,\n generateTenantPath,\n parseAuditlogsQuery,\n parseDeploymentsQuery,\n parseDeviceQuery,\n parseReleasesQuery,\n parseTenantsQuery\n} from './locationutils';\n\ntype ProcessorConfig<TFormat, TLocate, TParse> = {\n format: TFormat;\n locate: TLocate;\n parse: TParse;\n};\n\ntype Processors = {\n auditlogs: ProcessorConfig<typeof formatAuditlogs, () => undefined, typeof parseAuditlogsQuery>;\n common: ProcessorConfig<typeof formatPageState, () => undefined, typeof commonProcessor>;\n deployments: ProcessorConfig<typeof formatDeployments, typeof generateDeploymentsPath, typeof parseDeploymentsQuery>;\n devices: ProcessorConfig<typeof formatDeviceSearch, typeof generateDevicePath, typeof parseDeviceQuery>;\n releases: ProcessorConfig<typeof formatReleases, typeof generateReleasesPath, typeof parseReleasesQuery>;\n tenants: ProcessorConfig<typeof formatTenants, typeof generateTenantPath, typeof parseTenantsQuery>;\n};\n\nexport const defaultProcessors: Processors = {\n auditlogs: {\n format: formatAuditlogs,\n locate: () => undefined,\n parse: parseAuditlogsQuery\n },\n common: {\n format: formatPageState,\n locate: () => undefined,\n parse: commonProcessor\n },\n deployments: {\n format: formatDeployments,\n locate: generateDeploymentsPath,\n parse: parseDeploymentsQuery\n },\n devices: {\n format: formatDeviceSearch,\n locate: generateDevicePath,\n parse: parseDeviceQuery\n },\n releases: {\n format: formatReleases,\n locate: generateReleasesPath,\n parse: parseReleasesQuery\n },\n tenants: {\n format: formatTenants,\n locate: generateTenantPath,\n parse: parseTenantsQuery\n }\n};\n\ntype ProcessorKey = keyof Omit<Processors, 'common'>;\n\ntype LocationExtras = Record<string, unknown>;\n\ntype LocationParamsValue = PageState & CommonProcessorResult['sort'] & Record<string, unknown>;\n\ntype SetValueParams = {\n [key: string]: unknown;\n pageState: PageState;\n};\n\ntype UseLocationParamsReturn = [\n value: LocationParamsValue,\n setValue: (newValue: SetValueParams, options?: NavigateOptions) => void,\n options: { shouldInitializeFromUrl: boolean }\n];\n\nexport const useLocationParams = (key: ProcessorKey, extras: LocationExtras, processors: Processors = defaultProcessors): UseLocationParamsReturn => {\n const [searchParams] = useSearchParams();\n const navigate = useNavigate();\n const location = useLocation();\n const navigationType = useNavigationType();\n\n // POP (back/ forward/ initial load) -> rely on url state - otherwise on stored redux state\n const shouldInitializeFromUrl = navigationType === 'POP';\n\n const extrasString = JSON.stringify(extras);\n const searchParamsString = searchParams.toString();\n\n const value = useMemo(() => {\n const { pageState, params, sort } = processors.common.parse(searchParams);\n const extendedExtras = { ...extras, pageState, location };\n return {\n ...pageState,\n sort,\n ...(processors[key].parse as (params: URLSearchParams, extras: typeof extendedExtras) => Record<string, unknown>)(params, extendedExtras)\n } as LocationParamsValue;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [extrasString, key, location.search, location.pathname, searchParamsString]);\n\n const setValue = useCallback(\n (newValue: SetValueParams, options: NavigateOptions = {}): void => {\n const locateFn = processors[key].locate as (params: { location: Location; pageState: PageState }) => string | undefined;\n const pathname = locateFn({ pageState: newValue.pageState, location });\n const formatFn = processors[key].format as (value: SetValueParams, extras: LocationExtras) => string;\n const searchQuery = [processors.common.format(newValue.pageState, extras as FormatPageStateDefaults), formatFn(newValue, extras)]\n .filter(i => i)\n .join('&');\n navigate({ pathname, replace: true, search: `?${searchQuery}`, ...options });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [extrasString, key]\n );\n\n return [value, setValue, { shouldInitializeFromUrl }];\n};\n"],"mappings":";;;;;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AAM,WAAW,WAAW,IAAI,CAAC;GACjC,MAAM,cAAc,CAAC,WAAW,OAAO,OAAO,SAAS,WAAW,MAAiC,GAAG,SAAS,UAAU,MAAM,CAAC,CAAC,CAC9H,QAAO,MAAK,CAAC,CAAC,CACd,KAAK,GAAG;GACX,SAAS;IAAE;IAAU,SAAS;IAAM,QAAQ,IAAI;IAAe,GAAG;GAAQ,CAAC;EAC7E,GAEA,CAAC,cAAc,GAAG,CAGE;EAAG,EAAE,wBAAwB;CAAC;AACtD"}
|
package/dist/liststatehook.js
CHANGED
|
@@ -68,10 +68,11 @@ const useLocationParams = (key, extras, processors = defaultProcessors) => {
|
|
|
68
68
|
location
|
|
69
69
|
});
|
|
70
70
|
const formatFn = processors[key].format;
|
|
71
|
+
const searchQuery = [processors.common.format(newValue.pageState, extras), formatFn(newValue, extras)].filter((i) => i).join("&");
|
|
71
72
|
navigate({
|
|
72
73
|
pathname,
|
|
73
74
|
replace: true,
|
|
74
|
-
search: `?${
|
|
75
|
+
search: `?${searchQuery}`,
|
|
75
76
|
...options
|
|
76
77
|
});
|
|
77
78
|
}, [extrasString, key]),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"liststatehook.js","names":[],"sources":["../src/liststatehook.ts"],"sourcesContent":["// Copyright 2022 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { useCallback, useMemo } from 'react';\nimport type { Location, NavigateOptions } from 'react-router';\nimport { useLocation, useNavigate, useNavigationType, useSearchParams } from 'react-router';\n\nimport type { CommonProcessorResult, FormatPageStateDefaults, PageState } from './locationutils';\nimport {\n commonProcessor,\n formatAuditlogs,\n formatDeployments,\n formatDeviceSearch,\n formatPageState,\n formatReleases,\n formatTenants,\n generateDeploymentsPath,\n generateDevicePath,\n generateReleasesPath,\n generateTenantPath,\n parseAuditlogsQuery,\n parseDeploymentsQuery,\n parseDeviceQuery,\n parseReleasesQuery,\n parseTenantsQuery\n} from './locationutils';\n\ntype ProcessorConfig<TFormat, TLocate, TParse> = {\n format: TFormat;\n locate: TLocate;\n parse: TParse;\n};\n\ntype Processors = {\n auditlogs: ProcessorConfig<typeof formatAuditlogs, () => undefined, typeof parseAuditlogsQuery>;\n common: ProcessorConfig<typeof formatPageState, () => undefined, typeof commonProcessor>;\n deployments: ProcessorConfig<typeof formatDeployments, typeof generateDeploymentsPath, typeof parseDeploymentsQuery>;\n devices: ProcessorConfig<typeof formatDeviceSearch, typeof generateDevicePath, typeof parseDeviceQuery>;\n releases: ProcessorConfig<typeof formatReleases, typeof generateReleasesPath, typeof parseReleasesQuery>;\n tenants: ProcessorConfig<typeof formatTenants, typeof generateTenantPath, typeof parseTenantsQuery>;\n};\n\nexport const defaultProcessors: Processors = {\n auditlogs: {\n format: formatAuditlogs,\n locate: () => undefined,\n parse: parseAuditlogsQuery\n },\n common: {\n format: formatPageState,\n locate: () => undefined,\n parse: commonProcessor\n },\n deployments: {\n format: formatDeployments,\n locate: generateDeploymentsPath,\n parse: parseDeploymentsQuery\n },\n devices: {\n format: formatDeviceSearch,\n locate: generateDevicePath,\n parse: parseDeviceQuery\n },\n releases: {\n format: formatReleases,\n locate: generateReleasesPath,\n parse: parseReleasesQuery\n },\n tenants: {\n format: formatTenants,\n locate: generateTenantPath,\n parse: parseTenantsQuery\n }\n};\n\ntype ProcessorKey = keyof Omit<Processors, 'common'>;\n\ntype LocationExtras = Record<string, unknown>;\n\ntype LocationParamsValue = PageState & CommonProcessorResult['sort'] & Record<string, unknown>;\n\ntype SetValueParams = {\n [key: string]: unknown;\n pageState: PageState;\n};\n\ntype UseLocationParamsReturn = [\n value: LocationParamsValue,\n setValue: (newValue: SetValueParams, options?: NavigateOptions) => void,\n options: { shouldInitializeFromUrl: boolean }\n];\n\nexport const useLocationParams = (key: ProcessorKey, extras: LocationExtras, processors: Processors = defaultProcessors): UseLocationParamsReturn => {\n const [searchParams] = useSearchParams();\n const navigate = useNavigate();\n const location = useLocation();\n const navigationType = useNavigationType();\n\n // POP (back/ forward/ initial load) -> rely on url state - otherwise on stored redux state\n const shouldInitializeFromUrl = navigationType === 'POP';\n\n const extrasString = JSON.stringify(extras);\n const searchParamsString = searchParams.toString();\n\n const value = useMemo(() => {\n const { pageState, params, sort } = processors.common.parse(searchParams);\n const extendedExtras = { ...extras, pageState, location };\n return {\n ...pageState,\n sort,\n ...(processors[key].parse as (params: URLSearchParams, extras: typeof extendedExtras) => Record<string, unknown>)(params, extendedExtras)\n } as LocationParamsValue;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [extrasString, key, location.search, location.pathname, searchParamsString]);\n\n const setValue = useCallback(\n (newValue: SetValueParams, options: NavigateOptions = {}): void => {\n const locateFn = processors[key].locate as (params: { location: Location; pageState: PageState }) => string | undefined;\n const pathname = locateFn({ pageState: newValue.pageState, location });\n const formatFn = processors[key].format as (value: SetValueParams, extras: LocationExtras) => string;\n const searchQuery = [processors.common.format(newValue.pageState, extras as FormatPageStateDefaults), formatFn(newValue, extras)]\n .filter(i => i)\n .join('&');\n navigate({ pathname, replace: true, search: `?${searchQuery}`, ...options });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [extrasString, key]\n );\n\n return [value, setValue, { shouldInitializeFromUrl }];\n};\n"],"mappings":";;;;AAoDA,MAAa,oBAAgC;CAC3C,WAAW;EACT,QAAQ;EACR,cAAc,KAAA;EACd,OAAO;CACT;CACA,QAAQ;EACN,QAAQ;EACR,cAAc,KAAA;EACd,OAAO;CACT;CACA,aAAa;EACX,QAAQ;EACR,QAAQ;EACR,OAAO;CACT;CACA,SAAS;EACP,QAAQ;EACR,QAAQ;EACR,OAAO;CACT;CACA,UAAU;EACR,QAAQ;EACR,QAAQ;EACR,OAAO;CACT;CACA,SAAS;EACP,QAAQ;EACR,QAAQ;EACR,OAAO;CACT;AACF;AAmBA,MAAa,qBAAqB,KAAmB,QAAwB,aAAyB,sBAA+C;CACnJ,MAAM,CAAC,gBAAgB,gBAAgB;CACvC,MAAM,WAAW,YAAY;CAC7B,MAAM,WAAW,YAAY;CAI7B,MAAM,0BAHiB,kBAGsB,MAAM;CAEnD,MAAM,eAAe,KAAK,UAAU,MAAM;CAC1C,MAAM,qBAAqB,aAAa,SAAS;CA2BjD,OAAO;EAzBO,cAAc;GAC1B,MAAM,EAAE,WAAW,QAAQ,SAAS,WAAW,OAAO,MAAM,YAAY;GACxE,MAAM,iBAAiB;IAAE,GAAG;IAAQ;IAAW;GAAS;GACxD,OAAO;IACL,GAAG;IACH;IACA,GAAI,WAAW,IAAI,CAAC,MAA8F,QAAQ,cAAc;GAC1I;EAEF,GAAG;GAAC;GAAc;GAAK,SAAS;GAAQ,SAAS;GAAU;EAAkB,CAgBjE;EAdK,aACd,UAA0B,UAA2B,CAAC,MAAY;GACjE,MAAM,WAAW,WAAW,IAAI,CAAC;GACjC,MAAM,WAAW,SAAS;IAAE,WAAW,SAAS;IAAW;GAAS,CAAC;GACrE,MAAM,WAAW,WAAW,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"liststatehook.js","names":[],"sources":["../src/liststatehook.ts"],"sourcesContent":["// Copyright 2022 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport { useCallback, useMemo } from 'react';\nimport type { Location, NavigateOptions } from 'react-router';\nimport { useLocation, useNavigate, useNavigationType, useSearchParams } from 'react-router';\n\nimport type { CommonProcessorResult, FormatPageStateDefaults, PageState } from './locationutils';\nimport {\n commonProcessor,\n formatAuditlogs,\n formatDeployments,\n formatDeviceSearch,\n formatPageState,\n formatReleases,\n formatTenants,\n generateDeploymentsPath,\n generateDevicePath,\n generateReleasesPath,\n generateTenantPath,\n parseAuditlogsQuery,\n parseDeploymentsQuery,\n parseDeviceQuery,\n parseReleasesQuery,\n parseTenantsQuery\n} from './locationutils';\n\ntype ProcessorConfig<TFormat, TLocate, TParse> = {\n format: TFormat;\n locate: TLocate;\n parse: TParse;\n};\n\ntype Processors = {\n auditlogs: ProcessorConfig<typeof formatAuditlogs, () => undefined, typeof parseAuditlogsQuery>;\n common: ProcessorConfig<typeof formatPageState, () => undefined, typeof commonProcessor>;\n deployments: ProcessorConfig<typeof formatDeployments, typeof generateDeploymentsPath, typeof parseDeploymentsQuery>;\n devices: ProcessorConfig<typeof formatDeviceSearch, typeof generateDevicePath, typeof parseDeviceQuery>;\n releases: ProcessorConfig<typeof formatReleases, typeof generateReleasesPath, typeof parseReleasesQuery>;\n tenants: ProcessorConfig<typeof formatTenants, typeof generateTenantPath, typeof parseTenantsQuery>;\n};\n\nexport const defaultProcessors: Processors = {\n auditlogs: {\n format: formatAuditlogs,\n locate: () => undefined,\n parse: parseAuditlogsQuery\n },\n common: {\n format: formatPageState,\n locate: () => undefined,\n parse: commonProcessor\n },\n deployments: {\n format: formatDeployments,\n locate: generateDeploymentsPath,\n parse: parseDeploymentsQuery\n },\n devices: {\n format: formatDeviceSearch,\n locate: generateDevicePath,\n parse: parseDeviceQuery\n },\n releases: {\n format: formatReleases,\n locate: generateReleasesPath,\n parse: parseReleasesQuery\n },\n tenants: {\n format: formatTenants,\n locate: generateTenantPath,\n parse: parseTenantsQuery\n }\n};\n\ntype ProcessorKey = keyof Omit<Processors, 'common'>;\n\ntype LocationExtras = Record<string, unknown>;\n\ntype LocationParamsValue = PageState & CommonProcessorResult['sort'] & Record<string, unknown>;\n\ntype SetValueParams = {\n [key: string]: unknown;\n pageState: PageState;\n};\n\ntype UseLocationParamsReturn = [\n value: LocationParamsValue,\n setValue: (newValue: SetValueParams, options?: NavigateOptions) => void,\n options: { shouldInitializeFromUrl: boolean }\n];\n\nexport const useLocationParams = (key: ProcessorKey, extras: LocationExtras, processors: Processors = defaultProcessors): UseLocationParamsReturn => {\n const [searchParams] = useSearchParams();\n const navigate = useNavigate();\n const location = useLocation();\n const navigationType = useNavigationType();\n\n // POP (back/ forward/ initial load) -> rely on url state - otherwise on stored redux state\n const shouldInitializeFromUrl = navigationType === 'POP';\n\n const extrasString = JSON.stringify(extras);\n const searchParamsString = searchParams.toString();\n\n const value = useMemo(() => {\n const { pageState, params, sort } = processors.common.parse(searchParams);\n const extendedExtras = { ...extras, pageState, location };\n return {\n ...pageState,\n sort,\n ...(processors[key].parse as (params: URLSearchParams, extras: typeof extendedExtras) => Record<string, unknown>)(params, extendedExtras)\n } as LocationParamsValue;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [extrasString, key, location.search, location.pathname, searchParamsString]);\n\n const setValue = useCallback(\n (newValue: SetValueParams, options: NavigateOptions = {}): void => {\n const locateFn = processors[key].locate as (params: { location: Location; pageState: PageState }) => string | undefined;\n const pathname = locateFn({ pageState: newValue.pageState, location });\n const formatFn = processors[key].format as (value: SetValueParams, extras: LocationExtras) => string;\n const searchQuery = [processors.common.format(newValue.pageState, extras as FormatPageStateDefaults), formatFn(newValue, extras)]\n .filter(i => i)\n .join('&');\n navigate({ pathname, replace: true, search: `?${searchQuery}`, ...options });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [extrasString, key]\n );\n\n return [value, setValue, { shouldInitializeFromUrl }];\n};\n"],"mappings":";;;;AAoDA,MAAa,oBAAgC;CAC3C,WAAW;EACT,QAAQ;EACR,cAAc,KAAA;EACd,OAAO;CACT;CACA,QAAQ;EACN,QAAQ;EACR,cAAc,KAAA;EACd,OAAO;CACT;CACA,aAAa;E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,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_constants = require("./constants.cjs");
|
|
2
|
+
const require_constants = require("./constants-CNZ5L0A0.cjs");
|
|
3
3
|
let _northern_tech_utils_helpers = require("@northern.tech/utils/helpers");
|
|
4
4
|
let _northern_tech_utils_constants = require("@northern.tech/utils/constants");
|
|
5
5
|
//#region src/locationutils.ts
|
package/dist/locationutils.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Mt as UNGROUPED_GROUP, Q as AUDIT_LOGS_TYPES, _t as DEPLOYMENT_TYPES, ft as emptyFilter, gt as DEPLOYMENT_STATES, ht as DEPLOYMENT_ROUTES, l as DEVICE_LIST_DEFAULTS, o as ATTRIBUTE_SCOPES, s as DEVICE_FILTERING_OPTIONS, t as ALL_DEVICES } from "./constants-Cj2kp3Iy.js";
|
|
2
2
|
import { deepCompare, getISOStringBoundaries } from "@northern.tech/utils/helpers";
|
|
3
3
|
//#region src/locationutils.ts
|
|
4
4
|
const SEPARATOR = ":";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DEVICE_ISSUE_OPTIONS, DEVICE_LIST_DEFAULTS, alertChannels } from "../constants.js";
|
|
1
|
+
import { c as DEVICE_ISSUE_OPTIONS, l as DEVICE_LIST_DEFAULTS, p as alertChannels } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { createSlice } from "@reduxjs/toolkit";
|
|
3
3
|
//#region src/monitorSlice/index.ts
|
|
4
4
|
const sliceName = "monitor";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DEVICE_ISSUE_OPTIONS, DEVICE_LIST_DEFAULTS } from "../constants.js";
|
|
1
|
+
import { c as DEVICE_ISSUE_OPTIONS, l as DEVICE_LIST_DEFAULTS } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { initialState } from "./index.js";
|
|
3
3
|
//#region src/monitorSlice/mocks.ts
|
|
4
4
|
const mockState = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_constants = require("../constants.cjs");
|
|
2
|
+
const require_constants = require("../constants-CNZ5L0A0.cjs");
|
|
3
3
|
const require_monitorSlice_index = require("./index.cjs");
|
|
4
4
|
const require_actions = require("../actions.cjs");
|
|
5
5
|
const require_devicesSlice_selectors = require("../devicesSlice/selectors.cjs");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"thunks.cjs","names":["DEVICE_LIST_DEFAULTS","createAppAsyncThunk","sliceName","Api","monitorApiUrlv1","commonErrorHandler","actions","headerNames","getDeviceFilters","convertDeviceListStateToFilters","inventoryApiUrlV2","commonErrorFallback","storeActions","alertChannels","TIMEOUTS"],"sources":["../../src/monitorSlice/thunks.ts"],"sourcesContent":["// Copyright 2021 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport type { DeviceFilter } from '@/src/devicesSlice';\nimport type { Alert,
|
|
1
|
+
{"version":3,"file":"thunks.cjs","names":["DEVICE_LIST_DEFAULTS","createAppAsyncThunk","sliceName","Api","monitorApiUrlv1","commonErrorHandler","actions","headerNames","getDeviceFilters","convertDeviceListStateToFilters","inventoryApiUrlV2","commonErrorFallback","storeActions","alertChannels","TIMEOUTS"],"sources":["../../src/monitorSlice/thunks.ts"],"sourcesContent":["// Copyright 2021 Northern.tech AS\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\nimport type { DeviceFilter } from '@/src/devicesSlice';\nimport type { Alert, DeviceInventoryResponse, MonitorConfiguration } from '@northern.tech/types/MenderTypes';\n\nimport { actions, sliceName } from '.';\nimport storeActions from '../actions';\nimport Api from '../api/general-api';\nimport type { AlertChannelKey, DeviceIssueOptionKey } from '../constants';\nimport { DEVICE_LIST_DEFAULTS, TIMEOUTS, alertChannels, headerNames, inventoryApiUrlV2, monitorApiUrlv1 } from '../constants';\nimport { getDeviceFilters } from '../selectors';\nimport { commonErrorFallback, commonErrorHandler, createAppAsyncThunk } from '../store';\nimport { convertDeviceListStateToFilters } from '../utils';\n\nconst { page: defaultPage, perPage: defaultPerPage } = DEVICE_LIST_DEFAULTS;\n\nconst cutoffLength = 75;\nconst ellipsis = '...';\nconst longTextTrimmer = (text: string): string =>\n text.length >= cutoffLength + ellipsis.length ? `${text.substring(0, cutoffLength + ellipsis.length)}${ellipsis}` : text;\n\nconst sanitizeDeviceAlerts = (alerts: Alert[]) => alerts.map(alert => ({ ...alert, fullName: alert.name, name: longTextTrimmer(alert.name || '') }));\n\ninterface GetDeviceAlertsPayload {\n config?: { issuedAfter?: string; issuedBefore?: string; page?: number; perPage?: number; sortAscending?: boolean };\n id: string;\n}\nexport const getDeviceAlerts = createAppAsyncThunk(`${sliceName}/getDeviceAlerts`, ({ id, config = {} }: GetDeviceAlertsPayload, { dispatch }) => {\n const { page = defaultPage, perPage = defaultPerPage, issuedBefore, issuedAfter, sortAscending = false } = config;\n const issued_after = issuedAfter ? `&issued_after=${issuedAfter}` : '';\n const issued_before = issuedBefore ? `&issued_before=${issuedBefore}` : '';\n return Api.get<Alert[]>(\n `${monitorApiUrlv1}/devices/${id}/alerts?page=${page}&per_page=${perPage}${issued_after}${issued_before}&sort_ascending=${sortAscending}`\n )\n .catch(err => commonErrorHandler(err, `Retrieving device alerts for device ${id} failed:`, dispatch))\n .then(res =>\n Promise.all([\n dispatch(actions.receiveDeviceAlerts({ deviceId: id, alerts: sanitizeDeviceAlerts(res.data) })),\n dispatch(actions.setAlertListState({ total: Number(res.headers[headerNames.total]) }))\n ])\n );\n});\n\ninterface GetLatestDeviceAlertsPayload {\n config?: { page?: number; perPage?: number };\n id: string;\n}\nexport const getLatestDeviceAlerts = createAppAsyncThunk(\n `${sliceName}/getLatestDeviceAlerts`,\n ({ id, config = {} }: GetLatestDeviceAlertsPayload, { dispatch }) => {\n const { page = defaultPage, perPage = 10 } = config;\n return Api.get<Alert[]>(`${monitorApiUrlv1}/devices/${id}/alerts/latest?page=${page}&per_page=${perPage}`)\n .catch(err => commonErrorHandler(err, `Retrieving device alerts for device ${id} failed:`, dispatch))\n .then(res => Promise.resolve(dispatch(actions.receiveLatestDeviceAlerts({ deviceId: id, alerts: sanitizeDeviceAlerts(res.data) }))));\n }\n);\n\ninterface GetIssueCountsByTypePayload {\n options?: Partial<{ filters: DeviceFilter[]; group: string; status: string; type: string }>;\n type: DeviceIssueOptionKey;\n}\nexport const getIssueCountsByType = createAppAsyncThunk(\n `${sliceName}/getIssueCountsByType`,\n async ({ type, options = {} }: GetIssueCountsByTypePayload, { dispatch, getState }) => {\n const state = getState();\n const { filters = getDeviceFilters(state), group, status, ...remainder } = options;\n const { applicableFilters: nonMonitorFilters, filterTerms } = convertDeviceListStateToFilters({\n ...remainder,\n filters,\n group,\n offlineThreshold: state.app.offlineThreshold,\n selectedIssues: [type],\n status\n });\n const res = await Api.post<DeviceInventoryResponse[]>(`${inventoryApiUrlV2}/filters/search`, {\n page: 1,\n per_page: 1,\n filters: filterTerms,\n attributes: [{ scope: 'identity', attribute: 'status' }]\n }).catch(err => commonErrorHandler(err, `Retrieving issue counts failed:`, dispatch, commonErrorFallback));\n const total = nonMonitorFilters.length ? state.monitor.issueCounts.byType[type].total : Number(res.headers[headerNames.total]);\n const filtered = nonMonitorFilters.length ? Number(res.headers[headerNames.total]) : total;\n if (total === state.monitor.issueCounts.byType[type].total && filtered === state.monitor.issueCounts.byType[type].filtered) {\n return;\n }\n return dispatch(actions.receiveDeviceIssueCounts({ counts: { filtered, total }, issueType: type }));\n }\n);\n\nexport const getDeviceMonitorConfig = createAppAsyncThunk(`${sliceName}/getDeviceMonitorConfig`, (id: string, { dispatch }) =>\n Api.get<MonitorConfiguration[]>(`${monitorApiUrlv1}/devices/${id}/config`)\n .catch(err => commonErrorHandler(err, `Retrieving device monitor config for device ${id} failed:`, dispatch))\n .then(({ data }) => Promise.all([dispatch(storeActions.receivedDevice({ id, monitors: data }), Promise.resolve(data))]))\n);\n\ninterface ChangeNotificationSettingPayload {\n channel?: AlertChannelKey;\n enabled: boolean;\n}\nexport const changeNotificationSetting = createAppAsyncThunk(\n `${sliceName}/changeNotificationSetting`,\n ({ enabled, channel = alertChannels.email as AlertChannelKey }: ChangeNotificationSettingPayload, { dispatch }) =>\n Api.put(`${monitorApiUrlv1}/settings/global/channel/alerts/${channel}/status`, { enabled })\n .catch(err => commonErrorHandler(err, `${enabled ? 'En' : 'Dis'}abling ${channel} alerts failed:`, dispatch))\n .then(() =>\n Promise.all([\n dispatch(actions.changeAlertChannel({ channel, enabled })),\n dispatch(\n storeActions.setSnackbar({ message: `Successfully ${enabled ? 'en' : 'dis'}abled ${channel} alerts`, autoHideDuration: TIMEOUTS.fiveSeconds })\n )\n ])\n )\n);\n"],"mappings":";;;;;;;;;;AAyBA,MAAM,EAAE,MAAM,aAAa,SAAS,mBAAmBA,+BAAAA;AAGvD,MAAM,WAAW;AACjB,MAAM,mBAAmB,SACvB,KAAK,UAAU,KAAiC,GAAG,KAAK,UAAU,GAAG,EAA8B,IAAI,aAAa;AAEtH,MAAM,wBAAwB,WAAoB,OAAO,KAAI,WAAU;CAAE,GAAG;CAAO,UAAU,MAAM;CAAM,MAAM,gBAAgB,MAAM,QAAQ,EAA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ACvE,OAAM,QAAOC,cAAAA,mBAAmB,KAAK,+CAA+C,GAAG,WAAW,QAAQ,CAAC,CAAC,CAC5G,MAAM,EAAE,WAAW,QAAQ,IAAI,CAAC,SAASO,gBAAa,eAAe;CAAE;CAAI,UAAU;AAAK,CAAC,GAAG,QAAQ,QAAQ,IAAI,CAAC,CAAC,CAAC,CAAC,CAC3H;AAMA,MAAa,4BAA4BX,cAAAA,oBACvC,GAAGC,2BAAAA,UAAU,8BACZ,EAAE,SAAS,UAAUW,+BAAAA,cAAc,SAA8D,EAAE,eAClGV,wBAAAA,QAAI,IAAI,GAAGC,+BAAAA,gBAAgB,kCAAkC,QAAQ,UAAU,EAAE,QAAQ,CAAC,CAAC,CACxF,OAAM,QAAOC,cAAAA,mBAAmB,KAAK,GAAG,UAAU,OAAO,MAAM,UAAU,QAAQ,kBAAkB,QAAQ,CAAC,CAAC,CAC7G,WACC,QAAQ,IAAI,CACV,SAASC,2BAAAA,QAAQ,mBAAmB;CAAE;CAAS;AAAQ,CAAC,CAAC,GACzD,SACEM,gBAAa,YAAY;CAAE,SAAS,gBAAgB,UAAU,OAAO,MAAM,QAAQ,QAAQ;CAAU,kBAAkBE,kBAAAA,SAAS;AAAY,CAAC,CAC/I,CACF,CAAC,CACH,CACN"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { lt as AlertChannelKey, m as DeviceIssueOptionKey } from "../constants-_p6w8uEp.cjs";
|
|
2
2
|
import { n as DeviceFilter, t as Device } from "../index-Doc_1P_Y.cjs";
|
|
3
3
|
import { i as SnackbarContent } from "../index-C8QadAm7.cjs";
|
|
4
|
-
import { r as RootState, t as AppDispatch } from "../store-
|
|
4
|
+
import { r as RootState, t as AppDispatch } from "../store-B5-0USDz.cjs";
|
|
5
5
|
|
|
6
6
|
//#region src/monitorSlice/thunks.d.ts
|
|
7
7
|
interface GetDeviceAlertsPayload {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { lt as AlertChannelKey, m as DeviceIssueOptionKey } from "../constants-OcdoVk6f.js";
|
|
2
2
|
import { n as DeviceFilter, t as Device } from "../index-BqJuhvO_.js";
|
|
3
3
|
import { i as SnackbarContent } from "../index-BLvjQfGj.js";
|
|
4
|
-
import { r as RootState, t as AppDispatch } from "../store-
|
|
4
|
+
import { r as RootState, t as AppDispatch } from "../store-CmiiLjxd.js";
|
|
5
5
|
|
|
6
6
|
//#region src/monitorSlice/thunks.d.ts
|
|
7
7
|
interface GetDeviceAlertsPayload {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { E as headerNames, M as monitorApiUrlv1, O as inventoryApiUrlV2, jt as TIMEOUTS, l as DEVICE_LIST_DEFAULTS, p as alertChannels } from "../constants-Cj2kp3Iy.js";
|
|
2
2
|
import { actions, sliceName } from "./index.js";
|
|
3
3
|
import actions_default from "../actions.js";
|
|
4
4
|
import { getDeviceFilters } from "../devicesSlice/selectors.js";
|