@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.
Files changed (134) hide show
  1. package/dist/api/general-api.cjs +1 -1
  2. package/dist/api/general-api.js +1 -1
  3. package/dist/appSlice/index.js +1 -1
  4. package/dist/appSlice/selectors.d.cts +1 -1
  5. package/dist/appSlice/selectors.d.ts +1 -1
  6. package/dist/appSlice/thunks.d.cts +1 -1
  7. package/dist/appSlice/thunks.d.ts +1 -1
  8. package/dist/auth.cjs +1 -1
  9. package/dist/auth.js +1 -1
  10. package/dist/commonConstants.cjs +1 -1
  11. package/dist/commonConstants.js +1 -1
  12. package/dist/commonSelectors.cjs +1 -1
  13. package/dist/commonSelectors.d.cts +1 -1
  14. package/dist/commonSelectors.d.ts +1 -1
  15. package/dist/commonSelectors.js +1 -1
  16. package/dist/constants-CNZ5L0A0.cjs +957 -0
  17. package/dist/constants-CNZ5L0A0.cjs.map +1 -0
  18. package/dist/constants-Cj2kp3Iy.js +676 -0
  19. package/dist/constants-Cj2kp3Iy.js.map +1 -0
  20. package/dist/{constants-BwKiHHaB.d.ts → constants-D9o0Cnk_.d.cts} +2 -1
  21. package/dist/{constants-BwKiHHaB.d.cts → constants-D9o0Cnk_.d.ts} +2 -1
  22. package/dist/constants.cjs +48 -718
  23. package/dist/constants.d.cts +1 -1
  24. package/dist/constants.d.ts +1 -1
  25. package/dist/constants.js +1 -672
  26. package/dist/deploymentsSlice/constants.cjs +1 -1
  27. package/dist/deploymentsSlice/constants.d.cts +1 -1
  28. package/dist/deploymentsSlice/constants.d.ts +1 -1
  29. package/dist/deploymentsSlice/constants.js +1 -1
  30. package/dist/deploymentsSlice/index.cjs +1 -1
  31. package/dist/deploymentsSlice/index.js +1 -1
  32. package/dist/deploymentsSlice/mocks.cjs +1 -1
  33. package/dist/deploymentsSlice/mocks.cjs.map +1 -1
  34. package/dist/deploymentsSlice/mocks.d.cts +1 -1
  35. package/dist/deploymentsSlice/mocks.d.ts +1 -1
  36. package/dist/deploymentsSlice/mocks.js +1 -1
  37. package/dist/deploymentsSlice/mocks.js.map +1 -1
  38. package/dist/deploymentsSlice/selectors.cjs +1 -1
  39. package/dist/deploymentsSlice/selectors.d.cts +1 -1
  40. package/dist/deploymentsSlice/selectors.d.ts +1 -1
  41. package/dist/deploymentsSlice/selectors.js +1 -1
  42. package/dist/deploymentsSlice/thunks.d.cts +1 -1
  43. package/dist/deploymentsSlice/thunks.d.ts +1 -1
  44. package/dist/devicesSlice/constants.cjs +1 -1
  45. package/dist/devicesSlice/constants.js +1 -1
  46. package/dist/devicesSlice/index.js +1 -1
  47. package/dist/devicesSlice/mocks.js +1 -1
  48. package/dist/devicesSlice/selectors.cjs +1 -1
  49. package/dist/devicesSlice/selectors.d.cts +1 -1
  50. package/dist/devicesSlice/selectors.d.ts +1 -1
  51. package/dist/devicesSlice/selectors.js +1 -1
  52. package/dist/devicesSlice/thunks.d.cts +3 -3
  53. package/dist/devicesSlice/thunks.d.ts +3 -3
  54. package/dist/liststatehook.cjs +2 -1
  55. package/dist/liststatehook.cjs.map +1 -1
  56. package/dist/liststatehook.js +2 -1
  57. package/dist/liststatehook.js.map +1 -1
  58. package/dist/locationutils.cjs +1 -1
  59. package/dist/locationutils.js +1 -1
  60. package/dist/monitorSlice/index.js +1 -1
  61. package/dist/monitorSlice/mocks.js +1 -1
  62. package/dist/monitorSlice/selectors.d.cts +1 -1
  63. package/dist/monitorSlice/selectors.d.ts +1 -1
  64. package/dist/monitorSlice/thunks.cjs +1 -1
  65. package/dist/monitorSlice/thunks.cjs.map +1 -1
  66. package/dist/monitorSlice/thunks.d.cts +1 -1
  67. package/dist/monitorSlice/thunks.d.ts +1 -1
  68. package/dist/monitorSlice/thunks.js +1 -1
  69. package/dist/monitorSlice/thunks.js.map +1 -1
  70. package/dist/onboardingSlice/selectors.d.cts +1 -1
  71. package/dist/onboardingSlice/selectors.d.ts +1 -1
  72. package/dist/onboardingSlice/thunks.d.cts +1 -1
  73. package/dist/onboardingSlice/thunks.d.ts +1 -1
  74. package/dist/organizationSlice/constants.cjs +1 -1
  75. package/dist/organizationSlice/constants.js +1 -1
  76. package/dist/organizationSlice/index.cjs +1 -1
  77. package/dist/organizationSlice/index.js +1 -1
  78. package/dist/organizationSlice/mocks.js +1 -1
  79. package/dist/organizationSlice/selectors.cjs +1 -1
  80. package/dist/organizationSlice/selectors.d.cts +1 -1
  81. package/dist/organizationSlice/selectors.d.ts +1 -1
  82. package/dist/organizationSlice/selectors.js +1 -1
  83. package/dist/organizationSlice/thunks.d.cts +1 -1
  84. package/dist/organizationSlice/thunks.d.ts +1 -1
  85. package/dist/releasesSlice/index.js +1 -1
  86. package/dist/releasesSlice/mocks.js +1 -1
  87. package/dist/releasesSlice/selectors.d.cts +1 -1
  88. package/dist/releasesSlice/selectors.d.ts +1 -1
  89. package/dist/releasesSlice/thunks.cjs +6 -4
  90. package/dist/releasesSlice/thunks.cjs.map +1 -1
  91. package/dist/releasesSlice/thunks.d.cts +1 -1
  92. package/dist/releasesSlice/thunks.d.ts +1 -1
  93. package/dist/releasesSlice/thunks.js +6 -4
  94. package/dist/releasesSlice/thunks.js.map +1 -1
  95. package/dist/sockethook.cjs +1 -1
  96. package/dist/sockethook.js +1 -1
  97. package/dist/{store-xV2zaXAc.d.cts → store-B5-0USDz.d.cts} +3 -3
  98. package/dist/{store-BzrMxxAO.d.ts → store-CmiiLjxd.d.ts} +3 -3
  99. package/dist/store.cjs +1 -1
  100. package/dist/store.d.cts +1 -1
  101. package/dist/store.d.ts +1 -1
  102. package/dist/store.js +1 -1
  103. package/dist/storehooks.cjs +1 -1
  104. package/dist/storehooks.d.cts +1 -1
  105. package/dist/storehooks.d.ts +1 -1
  106. package/dist/storehooks.js +1 -1
  107. package/dist/thunks.cjs +57 -40
  108. package/dist/thunks.cjs.map +1 -1
  109. package/dist/thunks.d.cts +2 -2
  110. package/dist/thunks.d.ts +2 -2
  111. package/dist/thunks.js +54 -41
  112. package/dist/thunks.js.map +1 -1
  113. package/dist/usersSlice/constants.cjs +1 -1
  114. package/dist/usersSlice/constants.js +1 -1
  115. package/dist/usersSlice/index.cjs +1 -1
  116. package/dist/usersSlice/index.js +1 -1
  117. package/dist/usersSlice/mocks.js +1 -1
  118. package/dist/usersSlice/selectors.cjs +1 -1
  119. package/dist/usersSlice/selectors.d.cts +1 -1
  120. package/dist/usersSlice/selectors.d.ts +1 -1
  121. package/dist/usersSlice/selectors.js +1 -1
  122. package/dist/usersSlice/thunks.cjs +4 -0
  123. package/dist/usersSlice/thunks.d.cts +43 -3
  124. package/dist/usersSlice/thunks.d.ts +43 -3
  125. package/dist/usersSlice/thunks.js +2 -2
  126. package/dist/utils.cjs +11 -21
  127. package/dist/utils.cjs.map +1 -1
  128. package/dist/utils.d.cts +1 -1
  129. package/dist/utils.d.ts +1 -1
  130. package/dist/utils.js +11 -21
  131. package/dist/utils.js.map +1 -1
  132. package/package.json +3 -3
  133. package/dist/constants.cjs.map +0 -1
  134. package/dist/constants.js.map +0 -1
@@ -1,677 +1,9 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_appSlice_constants = require("./appSlice/constants.cjs");
3
+ const require_constants = require("./constants-CNZ5L0A0.cjs");
3
4
  const require_onboardingSlice_constants = require("./onboardingSlice/constants.cjs");
4
5
  const require_releasesSlice_constants = require("./releasesSlice/constants.cjs");
5
6
  let _northern_tech_utils_constants = require("@northern.tech/utils/constants");
6
- let _mdi_js = require("@mdi/js");
7
- let react_jsx_runtime = require("react/jsx-runtime");
8
- //#region src/commonConstants.tsx
9
- const timeUnits = {
10
- days: "days",
11
- minutes: "minutes",
12
- hours: "hours"
13
- };
14
- const UNGROUPED_GROUP = {
15
- id: "*|=ungrouped=|*",
16
- name: "Unassigned"
17
- };
18
- const DEVICE_LIST_MAXIMUM_LENGTH = 50;
19
- const oneSecond = 1e3;
20
- const TIMEOUTS = {
21
- debounceDefault: 700,
22
- debounceShort: 300,
23
- halfASecond: .5 * oneSecond,
24
- oneSecond,
25
- twoSeconds: 2 * oneSecond,
26
- threeSeconds: 3 * oneSecond,
27
- fiveSeconds: 5 * oneSecond,
28
- refreshDefault: 10 * oneSecond,
29
- refreshLong: 60 * oneSecond
30
- };
31
- const DEVICE_ONLINE_CUTOFF = {
32
- interval: 1,
33
- intervalName: timeUnits.days
34
- };
35
- const defaultIdAttribute = Object.freeze({
36
- attribute: "id",
37
- scope: _northern_tech_utils_constants.ATTRIBUTE_SCOPES.identity
38
- });
39
- const productOrder = [
40
- "micro",
41
- "standard",
42
- "system"
43
- ];
44
- const credentialTypes = {
45
- aws: "aws",
46
- http: "http",
47
- sas: "sas",
48
- x509: "x509"
49
- };
50
- const EXTERNAL_PROVIDER = {
51
- "iot-core": {
52
- credentialsType: credentialTypes.aws,
53
- icon: _mdi_js.mdiAws,
54
- title: "AWS IoT Core",
55
- twinTitle: "Device Shadow",
56
- provider: "iot-core",
57
- enabled: true,
58
- deviceTwin: true,
59
- configHint: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: "For help finding your AWS IoT Core connection string, check the AWS IoT documentation." })
60
- },
61
- "iot-hub": {
62
- credentialsType: credentialTypes.sas,
63
- icon: _mdi_js.mdiMicrosoftAzure,
64
- title: "Azure IoT Hub",
65
- twinTitle: "Device Twin",
66
- provider: "iot-hub",
67
- enabled: true,
68
- deviceTwin: true,
69
- configHint: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", { children: [
70
- "For help finding your Azure IoT Hub connection string, look under 'Shared access policies' in the Microsoft Azure UI as described",
71
- " ",
72
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
73
- href: "https://devblogs.microsoft.com/iotdev/understand-different-connection-strings-in-azure-iot-hub/#iothubconn",
74
- target: "_blank",
75
- rel: "noopener noreferrer",
76
- children: "here"
77
- }),
78
- "."
79
- ] })
80
- },
81
- webhook: {
82
- credentialsType: credentialTypes.http,
83
- deviceTwin: false,
84
- twinTitle: "",
85
- enabled: false,
86
- provider: "webhook"
87
- }
88
- };
89
- const emptyWebhook = {
90
- description: "",
91
- provider: "webhook",
92
- credentials: {
93
- type: EXTERNAL_PROVIDER.webhook.credentialsType,
94
- [EXTERNAL_PROVIDER.webhook.credentialsType]: {
95
- secret: "",
96
- url: ""
97
- }
98
- }
99
- };
100
- const MAX_PAGE_SIZE = 500;
101
- const regionNames = new Intl.DisplayNames(["en"], { type: "region" });
102
- const countries = [
103
- "AD",
104
- "AE",
105
- "AF",
106
- "AG",
107
- "AI",
108
- "AL",
109
- "AM",
110
- "AO",
111
- "AQ",
112
- "AR",
113
- "AS",
114
- "AT",
115
- "AU",
116
- "AW",
117
- "AX",
118
- "AZ",
119
- "BA",
120
- "BB",
121
- "BD",
122
- "BE",
123
- "BF",
124
- "BG",
125
- "BH",
126
- "BI",
127
- "BJ",
128
- "BL",
129
- "BM",
130
- "BN",
131
- "BO",
132
- "BR",
133
- "BS",
134
- "BT",
135
- "BV",
136
- "BW",
137
- "BY",
138
- "BZ",
139
- "CA",
140
- "CC",
141
- "CD",
142
- "CF",
143
- "CG",
144
- "CH",
145
- "CI",
146
- "CK",
147
- "CL",
148
- "CM",
149
- "CN",
150
- "CO",
151
- "CR",
152
- "CU",
153
- "CV",
154
- "CW",
155
- "CX",
156
- "CY",
157
- "CZ",
158
- "DE",
159
- "DJ",
160
- "DK",
161
- "DM",
162
- "DO",
163
- "DZ",
164
- "EC",
165
- "EE",
166
- "EG",
167
- "EH",
168
- "ER",
169
- "ES",
170
- "ET",
171
- "FI",
172
- "FJ",
173
- "FK",
174
- "FM",
175
- "FO",
176
- "FR",
177
- "GA",
178
- "GB",
179
- "GD",
180
- "GE",
181
- "GF",
182
- "GG",
183
- "GH",
184
- "GI",
185
- "GL",
186
- "GM",
187
- "GN",
188
- "GP",
189
- "GQ",
190
- "GR",
191
- "GS",
192
- "GT",
193
- "GU",
194
- "GW",
195
- "GY",
196
- "HK",
197
- "HM",
198
- "HN",
199
- "HR",
200
- "HT",
201
- "HU",
202
- "ID",
203
- "IE",
204
- "IL",
205
- "IM",
206
- "IN",
207
- "IO",
208
- "IQ",
209
- "IR",
210
- "IS",
211
- "IT",
212
- "JE",
213
- "JM",
214
- "JO",
215
- "JP",
216
- "KE",
217
- "KG",
218
- "KH",
219
- "KI",
220
- "KM",
221
- "KN",
222
- "KP",
223
- "KR",
224
- "KW",
225
- "KY",
226
- "KZ",
227
- "LA",
228
- "LB",
229
- "LC",
230
- "LI",
231
- "LK",
232
- "LR",
233
- "LS",
234
- "LT",
235
- "LU",
236
- "LV",
237
- "LY",
238
- "MA",
239
- "MC",
240
- "MD",
241
- "ME",
242
- "MF",
243
- "MG",
244
- "MH",
245
- "MK",
246
- "ML",
247
- "MM",
248
- "MN",
249
- "MO",
250
- "MP",
251
- "MQ",
252
- "MR",
253
- "MS",
254
- "MT",
255
- "MU",
256
- "MV",
257
- "MW",
258
- "MX",
259
- "MY",
260
- "MZ",
261
- "NA",
262
- "NC",
263
- "NE",
264
- "NF",
265
- "NG",
266
- "NI",
267
- "NL",
268
- "NO",
269
- "NP",
270
- "NR",
271
- "NU",
272
- "NZ",
273
- "OM",
274
- "PA",
275
- "PE",
276
- "PF",
277
- "PG",
278
- "PH",
279
- "PK",
280
- "PL",
281
- "PM",
282
- "PN",
283
- "PR",
284
- "PS",
285
- "PT",
286
- "PW",
287
- "PY",
288
- "QA",
289
- "RE",
290
- "RO",
291
- "RS",
292
- "RU",
293
- "RW",
294
- "SA",
295
- "SB",
296
- "SC",
297
- "SD",
298
- "SE",
299
- "SG",
300
- "SH",
301
- "SI",
302
- "SJ",
303
- "SK",
304
- "SL",
305
- "SM",
306
- "SN",
307
- "SO",
308
- "SR",
309
- "SS",
310
- "ST",
311
- "SV",
312
- "SX",
313
- "SY",
314
- "SZ",
315
- "TC",
316
- "TD",
317
- "TF",
318
- "TG",
319
- "TH",
320
- "TJ",
321
- "TK",
322
- "TL",
323
- "TM",
324
- "TN",
325
- "TO",
326
- "TR",
327
- "TT",
328
- "TV",
329
- "TW",
330
- "TZ",
331
- "UA",
332
- "UG",
333
- "US",
334
- "UY",
335
- "UZ",
336
- "VA",
337
- "VC",
338
- "VE",
339
- "VG",
340
- "VI",
341
- "VN",
342
- "VU",
343
- "WF",
344
- "WS",
345
- "XK",
346
- "YE",
347
- "YT",
348
- "ZA",
349
- "ZM",
350
- "ZW"
351
- ].map((code) => ({
352
- code,
353
- label: regionNames.of(code)
354
- })).sort((a, b) => a.label.localeCompare(b.label));
355
- const deploymentSubstates = {
356
- aborted: "aborted",
357
- alreadyInstalled: "already-installed",
358
- decommissioned: "decommissioned",
359
- downloading: "downloading",
360
- failure: "failure",
361
- installing: "installing",
362
- noartifact: "noartifact",
363
- artifact_too_big: "artifact_too_big",
364
- pause_before_committing: "pause_before_committing",
365
- pause_before_installing: "pause_before_installing",
366
- pause_before_rebooting: "pause_before_rebooting",
367
- pending: "pending",
368
- rebooting: "rebooting",
369
- success: "success"
370
- };
371
- const deploymentStatesToSubstates = {
372
- failures: [
373
- deploymentSubstates.failure,
374
- deploymentSubstates.aborted,
375
- deploymentSubstates.decommissioned
376
- ],
377
- inprogress: [
378
- deploymentSubstates.downloading,
379
- deploymentSubstates.installing,
380
- deploymentSubstates.rebooting
381
- ],
382
- paused: [
383
- deploymentSubstates.pause_before_installing,
384
- deploymentSubstates.pause_before_rebooting,
385
- deploymentSubstates.pause_before_committing
386
- ],
387
- pending: [deploymentSubstates.pending],
388
- successes: [
389
- deploymentSubstates.success,
390
- deploymentSubstates.alreadyInstalled,
391
- deploymentSubstates.noartifact,
392
- deploymentSubstates.artifact_too_big
393
- ]
394
- };
395
- const deploymentStatesToSubstatesWithSkipped = {
396
- ...deploymentStatesToSubstates,
397
- failures: [deploymentSubstates.failure],
398
- skipped: [
399
- deploymentSubstates.aborted,
400
- deploymentSubstates.noartifact,
401
- deploymentSubstates.artifact_too_big,
402
- deploymentSubstates.alreadyInstalled,
403
- deploymentSubstates.decommissioned
404
- ],
405
- successes: [deploymentSubstates.success]
406
- };
407
- const installationSubstatesMap = {
408
- download: {
409
- title: "download",
410
- done: "downloaded",
411
- successIndicators: [
412
- deploymentSubstates.installing,
413
- deploymentSubstates.rebooting,
414
- ...deploymentStatesToSubstates.paused,
415
- deploymentSubstates.success
416
- ],
417
- failureIndicators: deploymentStatesToSubstates.failures,
418
- pauseConfigurationIndicator: "ArtifactInstall_Enter"
419
- },
420
- install: {
421
- title: "install",
422
- done: "installed",
423
- successIndicators: [
424
- deploymentSubstates.rebooting,
425
- deploymentSubstates.pause_before_rebooting,
426
- deploymentSubstates.pause_before_committing,
427
- deploymentSubstates.success
428
- ],
429
- failureIndicators: deploymentStatesToSubstates.failures,
430
- pauseConfigurationIndicator: "ArtifactReboot_Enter"
431
- },
432
- reboot: {
433
- title: "reboot",
434
- done: "rebooted",
435
- successIndicators: [deploymentSubstates.pause_before_committing, deploymentSubstates.success],
436
- failureIndicators: deploymentStatesToSubstates.failures,
437
- pauseConfigurationIndicator: "ArtifactCommit_Enter"
438
- },
439
- commit: {
440
- title: "commit",
441
- done: "committed",
442
- successIndicators: deploymentStatesToSubstates.successes,
443
- failureIndicators: deploymentStatesToSubstates.failures,
444
- pauseConfigurationIndicator: void 0
445
- }
446
- };
447
- const DEPLOYMENT_STATES = {
448
- finished: "finished",
449
- inprogress: "inprogress",
450
- pending: "pending",
451
- scheduled: "scheduled"
452
- };
453
- const listDefaultsByState = {
454
- [DEPLOYMENT_STATES.inprogress]: {
455
- page: 1,
456
- perPage: 10
457
- },
458
- [DEPLOYMENT_STATES.pending]: {
459
- page: 1,
460
- perPage: 10
461
- },
462
- [DEPLOYMENT_STATES.scheduled]: { ..._northern_tech_utils_constants.DEVICE_LIST_DEFAULTS },
463
- [DEPLOYMENT_STATES.finished]: { ..._northern_tech_utils_constants.DEVICE_LIST_DEFAULTS },
464
- sort: { direction: _northern_tech_utils_constants.SORTING_OPTIONS.desc }
465
- };
466
- const DEFAULT_PENDING_INPROGRESS_COUNT = 10;
467
- const DEPLOYMENT_ROUTES = {
468
- active: {
469
- key: "active",
470
- route: "/deployments/active",
471
- states: [DEPLOYMENT_STATES.pending, DEPLOYMENT_STATES.inprogress],
472
- title: "Active"
473
- },
474
- finished: {
475
- key: "finished",
476
- route: "/deployments/finished",
477
- states: [DEPLOYMENT_STATES.finished],
478
- title: "Finished"
479
- },
480
- scheduled: {
481
- key: "scheduled",
482
- route: "/deployments/scheduled",
483
- states: [DEPLOYMENT_STATES.scheduled],
484
- title: "Scheduled"
485
- }
486
- };
487
- const DEPLOYMENT_TYPES = {
488
- software: "software",
489
- configuration: "configuration"
490
- };
491
- const defaultStats = {
492
- [deploymentSubstates.aborted]: 0,
493
- [deploymentSubstates.alreadyInstalled]: 0,
494
- [deploymentSubstates.decommissioned]: 0,
495
- [deploymentSubstates.downloading]: 0,
496
- [deploymentSubstates.failure]: 0,
497
- [deploymentSubstates.installing]: 0,
498
- [deploymentSubstates.noartifact]: 0,
499
- [deploymentSubstates.pause_before_committing]: 0,
500
- [deploymentSubstates.pause_before_installing]: 0,
501
- [deploymentSubstates.pause_before_rebooting]: 0,
502
- [deploymentSubstates.pending]: 0,
503
- [deploymentSubstates.rebooting]: 0,
504
- [deploymentSubstates.success]: 0
505
- };
506
- const deploymentDisplayStates = {
507
- finished: "Finished",
508
- scheduled: "Scheduled",
509
- skipped: "Skipped",
510
- paused: "Paused",
511
- pending: "Pending",
512
- inprogress: "In Progress",
513
- success: "Success",
514
- successes: "Success",
515
- failure: "Fail",
516
- failures: "Fail"
517
- };
518
- const deploymentPrototype = {
519
- devices: {},
520
- name: void 0,
521
- statistics: { status: {} }
522
- };
523
- const pauseMap = {
524
- [deploymentSubstates.pause_before_installing]: {
525
- title: installationSubstatesMap.download.done,
526
- followUp: installationSubstatesMap.download.pauseConfigurationIndicator
527
- },
528
- [deploymentSubstates.pause_before_rebooting]: {
529
- title: installationSubstatesMap.install.done,
530
- followUp: installationSubstatesMap.install.pauseConfigurationIndicator
531
- },
532
- [deploymentSubstates.pause_before_committing]: {
533
- title: installationSubstatesMap.reboot.done,
534
- followUp: installationSubstatesMap.reboot.pauseConfigurationIndicator
535
- }
536
- };
537
- //#endregion
538
- //#region src/devicesSlice/constants.ts
539
- const emptyFilter = {
540
- key: null,
541
- value: "",
542
- operator: _northern_tech_utils_constants.DEVICE_FILTERING_OPTIONS.$eq.key,
543
- scope: "inventory"
544
- };
545
- const DEVICE_MESSAGE_PROTOCOLS = { Shell: 1 };
546
- const DEVICE_MESSAGE_TYPES = {
547
- Delay: "delay",
548
- New: "new",
549
- Ping: "ping",
550
- Pong: "pong",
551
- Resize: "resize",
552
- Shell: "shell",
553
- Stop: "stop"
554
- };
555
- const DEVICE_DISMISSAL_STATE = "dismiss";
556
- const DEVICE_CONNECT_STATES = {
557
- connected: "connected",
558
- disconnected: "disconnected",
559
- unknown: "unknown"
560
- };
561
- const geoAttributes = ["geo-lat", "geo-lon"].map((attribute) => ({
562
- attribute,
563
- scope: "inventory"
564
- }));
565
- const REPORT_CHART_SIZE_LIMIT = 6;
566
- //#endregion
567
- //#region src/organizationSlice/constants.ts
568
- const XML_METADATA_FORMAT = "xml";
569
- const JSON_METADATA_FORMAT = "json";
570
- const getSamlStartUrl = (id) => `${window.location.origin}${_northern_tech_utils_constants.useradmApiUrl}/auth/sso/${id}/login`;
571
- const getOidcStartUrl = (id) => `${window.location.origin}${_northern_tech_utils_constants.useradmApiUrl}/oidc/${id}/start`;
572
- const SSO_TYPES = {
573
- saml: {
574
- id: "saml",
575
- type: "saml",
576
- title: "SAML",
577
- metadataFormat: "xml",
578
- editorLanguage: "xml",
579
- contentType: "application/samlmetadata+xml",
580
- getStartUrl: getSamlStartUrl,
581
- configDetails: [
582
- {
583
- key: "entityID",
584
- label: "Entity ID",
585
- getValue: (id) => `${window.location.origin}${_northern_tech_utils_constants.useradmApiUrl}/sso/sp/metadata/${id}`
586
- },
587
- {
588
- key: "acs",
589
- label: "ACS URL",
590
- getValue: (id) => `${window.location.origin}${_northern_tech_utils_constants.useradmApiUrl}/auth/sso/${id}/acs`
591
- },
592
- {
593
- key: "startURL",
594
- label: "Start URL",
595
- getValue: getSamlStartUrl
596
- }
597
- ]
598
- },
599
- oidc: {
600
- id: "oidc",
601
- type: "oidc",
602
- title: "OpenID Connect",
603
- metadataFormat: JSON_METADATA_FORMAT,
604
- editorLanguage: JSON_METADATA_FORMAT,
605
- contentType: "application/json",
606
- getStartUrl: getOidcStartUrl,
607
- configDetails: [{
608
- key: "startURL",
609
- label: "Start Url",
610
- getValue: getOidcStartUrl
611
- }]
612
- }
613
- };
614
- const auditlogTypes = {
615
- artifact: {
616
- title: "Artifact",
617
- queryParameter: "object_type",
618
- value: "artifact"
619
- },
620
- deployment: {
621
- title: "Deployment",
622
- queryParameter: "object_deployment_name",
623
- value: "deployment"
624
- },
625
- device: {
626
- title: "Device",
627
- queryParameter: "object_id",
628
- value: "device"
629
- },
630
- user_access_token: {
631
- title: "Personal Access Token",
632
- queryParameter: "user_access_token",
633
- value: "user_access_token"
634
- },
635
- user: {
636
- title: "User",
637
- queryParameter: "object_id",
638
- value: "user"
639
- },
640
- tenant: {
641
- title: "Tenant",
642
- queryParameter: "object_id",
643
- value: "tenant"
644
- }
645
- };
646
- const AUDIT_LOGS_TYPES = [
647
- auditlogTypes.artifact,
648
- auditlogTypes.deployment,
649
- auditlogTypes.device,
650
- auditlogTypes.user_access_token,
651
- auditlogTypes.user
652
- ];
653
- const SP_AUDIT_LOGS_TYPES = [auditlogTypes.user, auditlogTypes.tenant];
654
- const TENANT_LIST_DEFAULT = {
655
- page: 1,
656
- perPage: 20
657
- };
658
- //#endregion
659
- //#region src/usersSlice/constants.ts
660
- const itemUiPermissionsReducer = (accu, { item, uiPermissions }) => item ? {
661
- ...accu,
662
- [item]: uiPermissions
663
- } : accu;
664
- const checkSinglePermission = (permission, requiredPermission) => requiredPermission === permission || _northern_tech_utils_constants.uiPermissionsById[permission].permissionLevel > _northern_tech_utils_constants.uiPermissionsById[requiredPermission].permissionLevel;
665
- const checkPermissionsObject = (permissions, requiredPermission, scopedAccess, superAccess) => permissions[superAccess]?.some((permission) => checkSinglePermission(permission, requiredPermission)) || permissions[scopedAccess]?.some((permission) => checkSinglePermission(permission, requiredPermission));
666
- const USER_LOGOUT = "USER_LOGOUT";
667
- const OWN_USER_ID = "me";
668
- const settingsKeys = { initialized: "settings-initialized" };
669
- const READ_STATES = {
670
- read: "read",
671
- seen: "seen",
672
- unread: "unread"
673
- };
674
- //#endregion
675
7
  exports.ADDONS = require_appSlice_constants.ADDONS;
676
8
  exports.ALL_DEVICES = _northern_tech_utils_constants.ALL_DEVICES;
677
9
  exports.ALL_DEVICE_STATES = _northern_tech_utils_constants.ALL_DEVICE_STATES;
@@ -680,62 +12,62 @@ exports.APPLICATION_JSON_CONTENT_TYPE = _northern_tech_utils_constants.APPLICATI
680
12
  exports.APPLICATION_JWT_CONTENT_TYPE = _northern_tech_utils_constants.APPLICATION_JWT_CONTENT_TYPE;
681
13
  exports.ARTIFACT_GENERATION_TYPE = require_releasesSlice_constants.ARTIFACT_GENERATION_TYPE;
682
14
  exports.ATTRIBUTE_SCOPES = _northern_tech_utils_constants.ATTRIBUTE_SCOPES;
683
- exports.AUDIT_LOGS_TYPES = AUDIT_LOGS_TYPES;
15
+ exports.AUDIT_LOGS_TYPES = require_constants.AUDIT_LOGS_TYPES;
684
16
  exports.BEGINNING_OF_TIME = require_appSlice_constants.BEGINNING_OF_TIME;
685
17
  exports.BENEFITS = require_appSlice_constants.BENEFITS;
686
18
  exports.DARK_MODE = require_appSlice_constants.DARK_MODE;
687
- exports.DEFAULT_PENDING_INPROGRESS_COUNT = DEFAULT_PENDING_INPROGRESS_COUNT;
688
- exports.DEPLOYMENT_ROUTES = DEPLOYMENT_ROUTES;
689
- exports.DEPLOYMENT_STATES = DEPLOYMENT_STATES;
690
- exports.DEPLOYMENT_TYPES = DEPLOYMENT_TYPES;
691
- exports.DEVICE_CONNECT_STATES = DEVICE_CONNECT_STATES;
692
- exports.DEVICE_DISMISSAL_STATE = DEVICE_DISMISSAL_STATE;
19
+ exports.DEFAULT_PENDING_INPROGRESS_COUNT = require_constants.DEFAULT_PENDING_INPROGRESS_COUNT;
20
+ exports.DEPLOYMENT_ROUTES = require_constants.DEPLOYMENT_ROUTES;
21
+ exports.DEPLOYMENT_STATES = require_constants.DEPLOYMENT_STATES;
22
+ exports.DEPLOYMENT_TYPES = require_constants.DEPLOYMENT_TYPES;
23
+ exports.DEVICE_CONNECT_STATES = require_constants.DEVICE_CONNECT_STATES;
24
+ exports.DEVICE_DISMISSAL_STATE = require_constants.DEVICE_DISMISSAL_STATE;
693
25
  exports.DEVICE_FILTERING_OPTIONS = _northern_tech_utils_constants.DEVICE_FILTERING_OPTIONS;
694
26
  exports.DEVICE_ISSUE_OPTIONS = _northern_tech_utils_constants.DEVICE_ISSUE_OPTIONS;
695
27
  exports.DEVICE_LIST_DEFAULTS = _northern_tech_utils_constants.DEVICE_LIST_DEFAULTS;
696
- exports.DEVICE_LIST_MAXIMUM_LENGTH = DEVICE_LIST_MAXIMUM_LENGTH;
697
- exports.DEVICE_MESSAGE_PROTOCOLS = DEVICE_MESSAGE_PROTOCOLS;
698
- exports.DEVICE_MESSAGE_TYPES = DEVICE_MESSAGE_TYPES;
699
- exports.DEVICE_ONLINE_CUTOFF = DEVICE_ONLINE_CUTOFF;
28
+ exports.DEVICE_LIST_MAXIMUM_LENGTH = require_constants.DEVICE_LIST_MAXIMUM_LENGTH;
29
+ exports.DEVICE_MESSAGE_PROTOCOLS = require_constants.DEVICE_MESSAGE_PROTOCOLS;
30
+ exports.DEVICE_MESSAGE_TYPES = require_constants.DEVICE_MESSAGE_TYPES;
31
+ exports.DEVICE_ONLINE_CUTOFF = require_constants.DEVICE_ONLINE_CUTOFF;
700
32
  exports.DEVICE_STATES = _northern_tech_utils_constants.DEVICE_STATES;
701
- exports.EXTERNAL_PROVIDER = EXTERNAL_PROVIDER;
702
- exports.JSON_METADATA_FORMAT = JSON_METADATA_FORMAT;
33
+ exports.EXTERNAL_PROVIDER = require_constants.EXTERNAL_PROVIDER;
34
+ exports.JSON_METADATA_FORMAT = require_constants.JSON_METADATA_FORMAT;
703
35
  exports.LIGHT_MODE = require_appSlice_constants.LIGHT_MODE;
704
- exports.MAX_PAGE_SIZE = MAX_PAGE_SIZE;
705
- exports.OWN_USER_ID = OWN_USER_ID;
36
+ exports.MAX_PAGE_SIZE = require_constants.MAX_PAGE_SIZE;
37
+ exports.OWN_USER_ID = require_constants.OWN_USER_ID;
706
38
  exports.PLANS = require_appSlice_constants.PLANS;
707
39
  exports.PermissionTypes = _northern_tech_utils_constants.PermissionTypes;
708
- exports.READ_STATES = READ_STATES;
709
- exports.REPORT_CHART_SIZE_LIMIT = REPORT_CHART_SIZE_LIMIT;
40
+ exports.READ_STATES = require_constants.READ_STATES;
41
+ exports.REPORT_CHART_SIZE_LIMIT = require_constants.REPORT_CHART_SIZE_LIMIT;
710
42
  exports.SORTING_OPTIONS = _northern_tech_utils_constants.SORTING_OPTIONS;
711
- exports.SP_AUDIT_LOGS_TYPES = SP_AUDIT_LOGS_TYPES;
712
- exports.SSO_TYPES = SSO_TYPES;
713
- exports.TENANT_LIST_DEFAULT = TENANT_LIST_DEFAULT;
714
- exports.TIMEOUTS = TIMEOUTS;
715
- exports.UNGROUPED_GROUP = UNGROUPED_GROUP;
716
- exports.USER_LOGOUT = USER_LOGOUT;
717
- exports.XML_METADATA_FORMAT = XML_METADATA_FORMAT;
43
+ exports.SP_AUDIT_LOGS_TYPES = require_constants.SP_AUDIT_LOGS_TYPES;
44
+ exports.SSO_TYPES = require_constants.SSO_TYPES;
45
+ exports.TENANT_LIST_DEFAULT = require_constants.TENANT_LIST_DEFAULT;
46
+ exports.TIMEOUTS = require_constants.TIMEOUTS;
47
+ exports.UNGROUPED_GROUP = require_constants.UNGROUPED_GROUP;
48
+ exports.USER_LOGOUT = require_constants.USER_LOGOUT;
49
+ exports.XML_METADATA_FORMAT = require_constants.XML_METADATA_FORMAT;
718
50
  exports.alertChannels = _northern_tech_utils_constants.alertChannels;
719
51
  exports.apiRoot = _northern_tech_utils_constants.apiRoot;
720
52
  exports.apiUrl = _northern_tech_utils_constants.apiUrl;
721
53
  exports.auditLogsApiUrl = _northern_tech_utils_constants.auditLogsApiUrl;
722
- exports.auditlogTypes = auditlogTypes;
54
+ exports.auditlogTypes = require_constants.auditlogTypes;
723
55
  exports.canAccess = require_appSlice_constants.canAccess;
724
56
  exports.chartTypes = require_appSlice_constants.chartTypes;
725
- exports.checkPermissionsObject = checkPermissionsObject;
726
- exports.countries = countries;
727
- exports.credentialTypes = credentialTypes;
57
+ exports.checkPermissionsObject = require_constants.checkPermissionsObject;
58
+ exports.countries = require_constants.countries;
59
+ exports.credentialTypes = require_constants.credentialTypes;
728
60
  exports.currentArtifact = require_releasesSlice_constants.currentArtifact;
729
- exports.defaultIdAttribute = defaultIdAttribute;
61
+ exports.defaultIdAttribute = require_constants.defaultIdAttribute;
730
62
  exports.defaultPermissionSets = _northern_tech_utils_constants.defaultPermissionSets;
731
63
  exports.defaultReportType = require_appSlice_constants.defaultReportType;
732
64
  exports.defaultReports = require_appSlice_constants.defaultReports;
733
- exports.defaultStats = defaultStats;
734
- exports.deploymentDisplayStates = deploymentDisplayStates;
735
- exports.deploymentPrototype = deploymentPrototype;
736
- exports.deploymentStatesToSubstates = deploymentStatesToSubstates;
737
- exports.deploymentStatesToSubstatesWithSkipped = deploymentStatesToSubstatesWithSkipped;
738
- exports.deploymentSubstates = deploymentSubstates;
65
+ exports.defaultStats = require_constants.defaultStats;
66
+ exports.deploymentDisplayStates = require_constants.deploymentDisplayStates;
67
+ exports.deploymentPrototype = require_constants.deploymentPrototype;
68
+ exports.deploymentStatesToSubstates = require_constants.deploymentStatesToSubstates;
69
+ exports.deploymentStatesToSubstatesWithSkipped = require_constants.deploymentStatesToSubstatesWithSkipped;
70
+ exports.deploymentSubstates = require_constants.deploymentSubstates;
739
71
  exports.deploymentsApiUrl = _northern_tech_utils_constants.deploymentsApiUrl;
740
72
  exports.deploymentsApiUrlV1alpha1 = _northern_tech_utils_constants.deploymentsApiUrlV1alpha1;
741
73
  exports.deploymentsApiUrlV2 = _northern_tech_utils_constants.deploymentsApiUrlV2;
@@ -743,40 +75,40 @@ exports.deviceAuthV2 = _northern_tech_utils_constants.deviceAuthV2;
743
75
  exports.deviceConfig = _northern_tech_utils_constants.deviceConfig;
744
76
  exports.deviceConnect = _northern_tech_utils_constants.deviceConnect;
745
77
  exports.emptyChartSelection = require_appSlice_constants.emptyChartSelection;
746
- exports.emptyFilter = emptyFilter;
78
+ exports.emptyFilter = require_constants.emptyFilter;
747
79
  exports.emptyRole = _northern_tech_utils_constants.emptyRole;
748
80
  exports.emptyUiPermissions = _northern_tech_utils_constants.emptyUiPermissions;
749
- exports.emptyWebhook = emptyWebhook;
750
- exports.geoAttributes = geoAttributes;
751
- exports.getOidcStartUrl = getOidcStartUrl;
752
- exports.getSamlStartUrl = getSamlStartUrl;
81
+ exports.emptyWebhook = require_constants.emptyWebhook;
82
+ exports.geoAttributes = require_constants.geoAttributes;
83
+ exports.getOidcStartUrl = require_constants.getOidcStartUrl;
84
+ exports.getSamlStartUrl = require_constants.getSamlStartUrl;
753
85
  exports.headerNames = _northern_tech_utils_constants.headerNames;
754
- exports.installationSubstatesMap = installationSubstatesMap;
86
+ exports.installationSubstatesMap = require_constants.installationSubstatesMap;
755
87
  exports.inventoryApiUrl = _northern_tech_utils_constants.inventoryApiUrl;
756
88
  exports.inventoryApiUrlV2 = _northern_tech_utils_constants.inventoryApiUrlV2;
757
89
  exports.iotManagerBaseURL = _northern_tech_utils_constants.iotManagerBaseURL;
758
- exports.itemUiPermissionsReducer = itemUiPermissionsReducer;
90
+ exports.itemUiPermissionsReducer = require_constants.itemUiPermissionsReducer;
759
91
  exports.limitDefault = _northern_tech_utils_constants.limitDefault;
760
- exports.listDefaultsByState = listDefaultsByState;
92
+ exports.listDefaultsByState = require_constants.listDefaultsByState;
761
93
  exports.locations = require_appSlice_constants.locations;
762
94
  exports.maxSessionAge = _northern_tech_utils_constants.maxSessionAge;
763
95
  exports.monitorApiUrlv1 = _northern_tech_utils_constants.monitorApiUrlv1;
764
96
  exports.onboardingSteps = require_onboardingSlice_constants.onboardingSteps;
765
97
  exports.orderedOnboardingSteps = require_onboardingSlice_constants.orderedOnboardingSteps;
766
- exports.pauseMap = pauseMap;
767
- exports.productOrder = productOrder;
98
+ exports.pauseMap = require_constants.pauseMap;
99
+ exports.productOrder = require_constants.productOrder;
768
100
  exports.rolesById = _northern_tech_utils_constants.rolesById;
769
101
  exports.rolesByName = _northern_tech_utils_constants.rolesByName;
770
102
  exports.rootfsImageVersion = require_releasesSlice_constants.rootfsImageVersion;
771
103
  exports.scopedPermissionAreas = _northern_tech_utils_constants.scopedPermissionAreas;
772
104
  exports.serviceProviderRolesById = _northern_tech_utils_constants.serviceProviderRolesById;
773
- exports.settingsKeys = settingsKeys;
105
+ exports.settingsKeys = require_constants.settingsKeys;
774
106
  exports.softwareIndicator = require_releasesSlice_constants.softwareIndicator;
775
107
  exports.softwareTitleMap = require_releasesSlice_constants.softwareTitleMap;
776
108
  exports.ssoIdpApiUrlv1 = _northern_tech_utils_constants.ssoIdpApiUrlv1;
777
109
  exports.tenantadmApiUrlv1 = _northern_tech_utils_constants.tenantadmApiUrlv1;
778
110
  exports.tenantadmApiUrlv2 = _northern_tech_utils_constants.tenantadmApiUrlv2;
779
- exports.timeUnits = timeUnits;
111
+ exports.timeUnits = require_constants.timeUnits;
780
112
  exports.twoFAStates = _northern_tech_utils_constants.twoFAStates;
781
113
  exports.uiPermissionsByArea = _northern_tech_utils_constants.uiPermissionsByArea;
782
114
  exports.uiPermissionsById = _northern_tech_utils_constants.uiPermissionsById;
@@ -784,5 +116,3 @@ exports.useradmApiUrl = _northern_tech_utils_constants.useradmApiUrl;
784
116
  exports.useradmApiUrlv1 = _northern_tech_utils_constants.useradmApiUrlv1;
785
117
  exports.useradmApiUrlv2 = _northern_tech_utils_constants.useradmApiUrlv2;
786
118
  exports.yes = require_appSlice_constants.yes;
787
-
788
- //# sourceMappingURL=constants.cjs.map