@northern.tech/store 0.30.2 → 0.31.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/actions.d.cts +12 -6
- package/dist/actions.d.ts +12 -6
- package/dist/appSlice/constants.cjs +5 -0
- package/dist/appSlice/constants.cjs.map +1 -1
- package/dist/appSlice/constants.d.cts +1 -1
- package/dist/appSlice/constants.d.ts +1 -1
- package/dist/appSlice/constants.js +5 -0
- package/dist/appSlice/constants.js.map +1 -1
- package/dist/appSlice/index.d.cts +1 -1
- package/dist/appSlice/index.d.ts +1 -1
- package/dist/appSlice/mocks.d.cts +1 -1
- package/dist/appSlice/mocks.d.ts +1 -1
- package/dist/appSlice/selectors.d.cts +7 -7
- package/dist/appSlice/selectors.d.ts +7 -7
- package/dist/appSlice/thunks.d.cts +2 -2
- package/dist/appSlice/thunks.d.ts +2 -2
- package/dist/auth.d.cts +1 -1
- package/dist/auth.d.ts +1 -1
- package/dist/commonConstants.d.cts +1 -1
- package/dist/commonConstants.d.ts +1 -1
- package/dist/commonSelectors.d.cts +10 -10
- package/dist/commonSelectors.d.ts +10 -10
- package/dist/{constants-DPLHhjVN.d.cts → constants-BFTS6mge.d.cts} +6 -1
- package/dist/{constants-C5AU0mCY.d.ts → constants-BIIEMVoG.d.ts} +6 -1
- package/dist/{constants-MPLfugsi.d.cts → constants-BrGIx40B.d.cts} +3 -3
- package/dist/{constants-DrwXHsJ1.d.ts → constants-CjO3_FOH.d.ts} +3 -3
- package/dist/constants.cjs +1 -0
- package/dist/constants.d.cts +3 -3
- package/dist/constants.d.ts +3 -3
- package/dist/constants.js +2 -2
- package/dist/deploymentsSlice/selectors.d.cts +7 -7
- package/dist/deploymentsSlice/selectors.d.ts +7 -7
- package/dist/deploymentsSlice/thunks.d.cts +4 -4
- package/dist/deploymentsSlice/thunks.d.ts +4 -4
- package/dist/devicesSlice/constants.d.cts +1 -1
- package/dist/devicesSlice/constants.d.ts +1 -1
- package/dist/devicesSlice/index.d.cts +1 -1
- package/dist/devicesSlice/index.d.ts +1 -1
- package/dist/devicesSlice/selectors.d.cts +7 -7
- package/dist/devicesSlice/selectors.d.ts +7 -7
- package/dist/devicesSlice/thunks.d.cts +4 -4
- package/dist/devicesSlice/thunks.d.ts +4 -4
- package/dist/{index-Lz5JsJ6O.d.cts → index-B64X5ozM.d.cts} +2 -2
- package/dist/{index-4eaLEXy_.d.cts → index-BFlHWzjv.d.cts} +2 -2
- package/dist/{index-DqyY6oZ3.d.ts → index-BI9O8JWe.d.ts} +2 -2
- package/dist/{index-Bwx9jEiL.d.cts → index-BbaS7MzW.d.cts} +2 -2
- package/dist/{index-Dv3Hfxk_.d.ts → index-Bp1WpATs.d.ts} +2 -2
- package/dist/{index-DJSlDPRX.d.ts → index-C6wNUfiV.d.ts} +2 -2
- package/dist/{index-Cvkvcz4r.d.ts → index-CQo3yTUa.d.ts} +31 -5
- package/dist/{index-BEVkIiNa.d.cts → index-CT5hgXm9.d.cts} +2 -2
- package/dist/{index-CO-py5d4.d.ts → index-DUvrw_Ed.d.ts} +2 -2
- package/dist/{index-CTt-eIY8.d.cts → index-DwACbyUg.d.cts} +2 -2
- package/dist/{index-FyYBBeN-.d.cts → index-WXwgRjLt.d.cts} +31 -5
- package/dist/{index-DtePEQPT.d.ts → index-ez3oxfRo.d.ts} +2 -2
- package/dist/locationutils.cjs +3 -0
- package/dist/locationutils.cjs.map +1 -1
- package/dist/locationutils.d.cts +3 -2
- package/dist/locationutils.d.ts +3 -2
- package/dist/locationutils.js +3 -0
- package/dist/locationutils.js.map +1 -1
- package/dist/monitorSlice/constants.d.cts +1 -1
- package/dist/monitorSlice/constants.d.ts +1 -1
- package/dist/monitorSlice/index.d.cts +1 -1
- package/dist/monitorSlice/index.d.ts +1 -1
- package/dist/monitorSlice/mocks.d.cts +1 -1
- package/dist/monitorSlice/mocks.d.ts +1 -1
- package/dist/monitorSlice/selectors.d.cts +1 -1
- package/dist/monitorSlice/selectors.d.ts +1 -1
- package/dist/monitorSlice/thunks.d.cts +4 -4
- package/dist/monitorSlice/thunks.d.ts +4 -4
- package/dist/onboardingSlice/selectors.d.cts +1 -1
- package/dist/onboardingSlice/selectors.d.ts +1 -1
- package/dist/onboardingSlice/thunks.d.cts +2 -2
- package/dist/onboardingSlice/thunks.d.ts +2 -2
- package/dist/organizationSlice/index.d.cts +1 -1
- package/dist/organizationSlice/index.d.ts +1 -1
- package/dist/organizationSlice/mocks.d.cts +2 -2
- package/dist/organizationSlice/mocks.d.ts +2 -2
- package/dist/organizationSlice/selectors.d.cts +8 -8
- package/dist/organizationSlice/selectors.d.ts +8 -8
- package/dist/organizationSlice/thunks.d.cts +5 -5
- package/dist/organizationSlice/thunks.d.ts +5 -5
- package/dist/organizationSlice/types.d.cts +1 -1
- package/dist/organizationSlice/types.d.ts +1 -1
- package/dist/releasesSlice/index.cjs +37 -0
- package/dist/releasesSlice/index.cjs.map +1 -1
- package/dist/releasesSlice/index.d.cts +2 -2
- package/dist/releasesSlice/index.d.ts +2 -2
- package/dist/releasesSlice/index.js +37 -0
- package/dist/releasesSlice/index.js.map +1 -1
- package/dist/releasesSlice/mocks.cjs +34 -0
- package/dist/releasesSlice/mocks.cjs.map +1 -1
- package/dist/releasesSlice/mocks.d.cts +43 -0
- package/dist/releasesSlice/mocks.d.ts +43 -0
- package/dist/releasesSlice/mocks.js +34 -0
- package/dist/releasesSlice/mocks.js.map +1 -1
- package/dist/releasesSlice/selectors.cjs +22 -0
- package/dist/releasesSlice/selectors.cjs.map +1 -1
- package/dist/releasesSlice/selectors.d.cts +161 -9
- package/dist/releasesSlice/selectors.d.ts +161 -9
- package/dist/releasesSlice/selectors.js +16 -1
- package/dist/releasesSlice/selectors.js.map +1 -1
- package/dist/releasesSlice/thunks.cjs +89 -0
- package/dist/releasesSlice/thunks.cjs.map +1 -1
- package/dist/releasesSlice/thunks.d.cts +56 -6
- package/dist/releasesSlice/thunks.d.ts +56 -6
- package/dist/releasesSlice/thunks.js +88 -3
- package/dist/releasesSlice/thunks.js.map +1 -1
- package/dist/selectors.cjs +7 -0
- package/dist/selectors.d.cts +2 -2
- package/dist/selectors.d.ts +2 -2
- package/dist/selectors.js +2 -2
- package/dist/{store-BQxOSRC1.d.ts → store-Boqp1x2t.d.ts} +7 -7
- package/dist/{store-BiIA0r0A.d.cts → store-NOBz-rVZ.d.cts} +7 -7
- package/dist/store.d.cts +2 -2
- package/dist/store.d.ts +2 -2
- package/dist/storehooks.d.cts +2 -2
- package/dist/storehooks.d.ts +2 -2
- package/dist/thunks.cjs +4 -0
- package/dist/thunks.d.cts +2 -2
- package/dist/thunks.d.ts +2 -2
- package/dist/thunks.js +2 -2
- package/dist/{types-B2NRQLFw.d.ts → types-BPyM8Inu.d.ts} +3 -3
- package/dist/{types-ClEfo0dK.d.cts → types-COdPU2QQ.d.cts} +3 -3
- package/dist/usersSlice/index.d.cts +1 -1
- package/dist/usersSlice/index.d.ts +1 -1
- package/dist/usersSlice/mocks.d.cts +1 -1
- package/dist/usersSlice/mocks.d.ts +1 -1
- package/dist/usersSlice/selectors.d.cts +7 -7
- package/dist/usersSlice/selectors.d.ts +7 -7
- package/dist/usersSlice/thunks.d.cts +4 -4
- package/dist/usersSlice/thunks.d.ts +4 -4
- package/dist/{utils-CO_CpGFP.d.ts → utils-CHBWS_tH.d.ts} +4 -4
- package/dist/{utils-CpPfqW0Q.d.cts → utils-Do9z5TL1.d.cts} +4 -4
- package/dist/utils.d.cts +1 -1
- package/dist/utils.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,18 +1,19 @@
|
|
|
1
|
-
import { o as UserSliceType } from "../index-
|
|
2
|
-
import {
|
|
1
|
+
import { o as UserSliceType } from "../index-BFlHWzjv.cjs";
|
|
2
|
+
import { a as ReleasesList, i as ReleaseSliceType, n as ManifestsList, r as Release } from "../index-WXwgRjLt.cjs";
|
|
3
3
|
import { n as OnboardingSliceType } from "../index-UPc3wvVd.cjs";
|
|
4
4
|
import { o as DeploymentsSliceType } from "../index-BP0uAq36.cjs";
|
|
5
|
-
import { s as DeviceSliceType } from "../index-
|
|
6
|
-
import { t as AppSliceType } from "../index-
|
|
7
|
-
import { t as MonitorSliceType } from "../index-
|
|
8
|
-
import { t as OrganizationSliceType } from "../index-
|
|
9
|
-
import { r as RootState } from "../store-
|
|
10
|
-
import { ReleaseV2 } from "@northern.tech/types/MenderTypes";
|
|
5
|
+
import { s as DeviceSliceType } from "../index-B64X5ozM.cjs";
|
|
6
|
+
import { t as AppSliceType } from "../index-DwACbyUg.cjs";
|
|
7
|
+
import { t as MonitorSliceType } from "../index-CT5hgXm9.cjs";
|
|
8
|
+
import { t as OrganizationSliceType } from "../index-BbaS7MzW.cjs";
|
|
9
|
+
import { r as RootState } from "../store-NOBz-rVZ.cjs";
|
|
10
|
+
import { Manifest, ReleaseV2 } from "@northern.tech/types/MenderTypes";
|
|
11
11
|
import * as _$_northern_tech_utils_constants0 from "@northern.tech/utils/constants";
|
|
12
12
|
import * as _$_northern_tech_types_types_gen0 from "@northern.tech/types/types.gen";
|
|
13
13
|
import * as _$reselect from "reselect";
|
|
14
14
|
|
|
15
15
|
//#region src/releasesSlice/selectors.d.ts
|
|
16
|
+
declare const getActiveTab: (state: RootState) => "releases" | "delta" | "manifests" | undefined;
|
|
16
17
|
declare const getReleasesById: (state: RootState) => Record<string, Release>;
|
|
17
18
|
declare const getReleaseTags: (state: RootState) => string[];
|
|
18
19
|
declare const getReleaseListState: (state: RootState) => ReleasesList;
|
|
@@ -345,6 +346,157 @@ declare const getSelectedJob: ((state: {
|
|
|
345
346
|
memoize: typeof _$reselect.weakMapMemoize;
|
|
346
347
|
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
347
348
|
};
|
|
349
|
+
declare const getManifestsById: (state: RootState) => Record<string, Manifest>;
|
|
350
|
+
declare const getManifestsListState: (state: RootState) => ManifestsList;
|
|
351
|
+
declare const getManifestsList: ((state: {
|
|
352
|
+
app: AppSliceType;
|
|
353
|
+
devices: DeviceSliceType;
|
|
354
|
+
deployments: DeploymentsSliceType;
|
|
355
|
+
monitor: MonitorSliceType;
|
|
356
|
+
onboarding: OnboardingSliceType;
|
|
357
|
+
organization: OrganizationSliceType;
|
|
358
|
+
releases: ReleaseSliceType;
|
|
359
|
+
users: UserSliceType;
|
|
360
|
+
}) => Manifest[]) & {
|
|
361
|
+
clearCache: () => void;
|
|
362
|
+
resultsCount: () => number;
|
|
363
|
+
resetResultsCount: () => void;
|
|
364
|
+
} & {
|
|
365
|
+
resultFunc: (resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[];
|
|
366
|
+
memoizedResultFunc: ((resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[]) & {
|
|
367
|
+
clearCache: () => void;
|
|
368
|
+
resultsCount: () => number;
|
|
369
|
+
resetResultsCount: () => void;
|
|
370
|
+
};
|
|
371
|
+
lastResult: () => Manifest[];
|
|
372
|
+
dependencies: [(state: RootState) => Record<string, Manifest>, (state: RootState) => string[], () => {}];
|
|
373
|
+
recomputations: () => number;
|
|
374
|
+
resetRecomputations: () => void;
|
|
375
|
+
dependencyRecomputations: () => number;
|
|
376
|
+
resetDependencyRecomputations: () => void;
|
|
377
|
+
} & {
|
|
378
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
379
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
380
|
+
};
|
|
381
|
+
declare const getHasManifests: ((state: {
|
|
382
|
+
app: AppSliceType;
|
|
383
|
+
devices: DeviceSliceType;
|
|
384
|
+
deployments: DeploymentsSliceType;
|
|
385
|
+
monitor: MonitorSliceType;
|
|
386
|
+
onboarding: OnboardingSliceType;
|
|
387
|
+
organization: OrganizationSliceType;
|
|
388
|
+
releases: ReleaseSliceType;
|
|
389
|
+
users: UserSliceType;
|
|
390
|
+
}) => boolean) & {
|
|
391
|
+
clearCache: () => void;
|
|
392
|
+
resultsCount: () => number;
|
|
393
|
+
resetResultsCount: () => void;
|
|
394
|
+
} & {
|
|
395
|
+
resultFunc: (resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Record<string, Manifest>) => boolean;
|
|
396
|
+
memoizedResultFunc: ((resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Record<string, Manifest>) => boolean) & {
|
|
397
|
+
clearCache: () => void;
|
|
398
|
+
resultsCount: () => number;
|
|
399
|
+
resetResultsCount: () => void;
|
|
400
|
+
};
|
|
401
|
+
lastResult: () => boolean;
|
|
402
|
+
dependencies: [(state: RootState) => ManifestsList, (state: RootState) => Record<string, Manifest>];
|
|
403
|
+
recomputations: () => number;
|
|
404
|
+
resetRecomputations: () => void;
|
|
405
|
+
dependencyRecomputations: () => number;
|
|
406
|
+
resetDependencyRecomputations: () => void;
|
|
407
|
+
} & {
|
|
408
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
409
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
410
|
+
};
|
|
411
|
+
declare const getSelectedManifest: ((state: {
|
|
412
|
+
app: AppSliceType;
|
|
413
|
+
devices: DeviceSliceType;
|
|
414
|
+
deployments: DeploymentsSliceType;
|
|
415
|
+
monitor: MonitorSliceType;
|
|
416
|
+
onboarding: OnboardingSliceType;
|
|
417
|
+
organization: OrganizationSliceType;
|
|
418
|
+
releases: ReleaseSliceType;
|
|
419
|
+
users: UserSliceType;
|
|
420
|
+
}) => Manifest) & {
|
|
421
|
+
clearCache: () => void;
|
|
422
|
+
resultsCount: () => number;
|
|
423
|
+
resetResultsCount: () => void;
|
|
424
|
+
} & {
|
|
425
|
+
resultFunc: (resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string | null) => Manifest;
|
|
426
|
+
memoizedResultFunc: ((resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string | null) => Manifest) & {
|
|
427
|
+
clearCache: () => void;
|
|
428
|
+
resultsCount: () => number;
|
|
429
|
+
resetResultsCount: () => void;
|
|
430
|
+
};
|
|
431
|
+
lastResult: () => Manifest;
|
|
432
|
+
dependencies: [(state: RootState) => Record<string, Manifest>, (state: RootState) => string | null];
|
|
433
|
+
recomputations: () => number;
|
|
434
|
+
resetRecomputations: () => void;
|
|
435
|
+
dependencyRecomputations: () => number;
|
|
436
|
+
resetDependencyRecomputations: () => void;
|
|
437
|
+
} & {
|
|
438
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
439
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
440
|
+
};
|
|
441
|
+
declare const getSelectedManifests: ((state: {
|
|
442
|
+
app: AppSliceType;
|
|
443
|
+
devices: DeviceSliceType;
|
|
444
|
+
deployments: DeploymentsSliceType;
|
|
445
|
+
monitor: MonitorSliceType;
|
|
446
|
+
onboarding: OnboardingSliceType;
|
|
447
|
+
organization: OrganizationSliceType;
|
|
448
|
+
releases: ReleaseSliceType;
|
|
449
|
+
users: UserSliceType;
|
|
450
|
+
}) => Manifest[]) & {
|
|
451
|
+
clearCache: () => void;
|
|
452
|
+
resultsCount: () => number;
|
|
453
|
+
resetResultsCount: () => void;
|
|
454
|
+
} & {
|
|
455
|
+
resultFunc: (resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Manifest[]) => Manifest[];
|
|
456
|
+
memoizedResultFunc: ((resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Manifest[]) => Manifest[]) & {
|
|
457
|
+
clearCache: () => void;
|
|
458
|
+
resultsCount: () => number;
|
|
459
|
+
resetResultsCount: () => void;
|
|
460
|
+
};
|
|
461
|
+
lastResult: () => Manifest[];
|
|
462
|
+
dependencies: [(state: RootState) => ManifestsList, ((state: {
|
|
463
|
+
app: AppSliceType;
|
|
464
|
+
devices: DeviceSliceType;
|
|
465
|
+
deployments: DeploymentsSliceType;
|
|
466
|
+
monitor: MonitorSliceType;
|
|
467
|
+
onboarding: OnboardingSliceType;
|
|
468
|
+
organization: OrganizationSliceType;
|
|
469
|
+
releases: ReleaseSliceType;
|
|
470
|
+
users: UserSliceType;
|
|
471
|
+
}) => Manifest[]) & {
|
|
472
|
+
clearCache: () => void;
|
|
473
|
+
resultsCount: () => number;
|
|
474
|
+
resetResultsCount: () => void;
|
|
475
|
+
} & {
|
|
476
|
+
resultFunc: (resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[];
|
|
477
|
+
memoizedResultFunc: ((resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[]) & {
|
|
478
|
+
clearCache: () => void;
|
|
479
|
+
resultsCount: () => number;
|
|
480
|
+
resetResultsCount: () => void;
|
|
481
|
+
};
|
|
482
|
+
lastResult: () => Manifest[];
|
|
483
|
+
dependencies: [(state: RootState) => Record<string, Manifest>, (state: RootState) => string[], () => {}];
|
|
484
|
+
recomputations: () => number;
|
|
485
|
+
resetRecomputations: () => void;
|
|
486
|
+
dependencyRecomputations: () => number;
|
|
487
|
+
resetDependencyRecomputations: () => void;
|
|
488
|
+
} & {
|
|
489
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
490
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
491
|
+
}];
|
|
492
|
+
recomputations: () => number;
|
|
493
|
+
resetRecomputations: () => void;
|
|
494
|
+
dependencyRecomputations: () => number;
|
|
495
|
+
resetDependencyRecomputations: () => void;
|
|
496
|
+
} & {
|
|
497
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
498
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
499
|
+
};
|
|
348
500
|
//#endregion
|
|
349
|
-
export { getDeltaJobById, getDeltaJobsById, getDeltaJobsListState, getHasReleases, getReleaseListState, getReleaseTags, getReleaseTagsById, getReleasesById, getReleasesList, getSelectedJob, getSelectedRelease, getSelectedReleases, getUpdateTypes };
|
|
501
|
+
export { getActiveTab, getDeltaJobById, getDeltaJobsById, getDeltaJobsListState, getHasManifests, getHasReleases, getManifestsById, getManifestsList, getManifestsListState, getReleaseListState, getReleaseTags, getReleaseTagsById, getReleasesById, getReleasesList, getSelectedJob, getSelectedManifest, getSelectedManifests, getSelectedRelease, getSelectedReleases, getUpdateTypes };
|
|
350
502
|
//# sourceMappingURL=selectors.d.cts.map
|
|
@@ -1,18 +1,19 @@
|
|
|
1
|
-
import { o as UserSliceType } from "../index-
|
|
2
|
-
import {
|
|
1
|
+
import { o as UserSliceType } from "../index-ez3oxfRo.js";
|
|
2
|
+
import { a as ReleasesList, i as ReleaseSliceType, n as ManifestsList, r as Release } from "../index-CQo3yTUa.js";
|
|
3
3
|
import { n as OnboardingSliceType } from "../index-CJkrL0oA.js";
|
|
4
4
|
import { o as DeploymentsSliceType } from "../index-CkwVnIqd.js";
|
|
5
|
-
import { s as DeviceSliceType } from "../index-
|
|
6
|
-
import { t as AppSliceType } from "../index-
|
|
7
|
-
import { t as MonitorSliceType } from "../index-
|
|
8
|
-
import { t as OrganizationSliceType } from "../index-
|
|
9
|
-
import { r as RootState } from "../store-
|
|
5
|
+
import { s as DeviceSliceType } from "../index-BI9O8JWe.js";
|
|
6
|
+
import { t as AppSliceType } from "../index-Bp1WpATs.js";
|
|
7
|
+
import { t as MonitorSliceType } from "../index-DUvrw_Ed.js";
|
|
8
|
+
import { t as OrganizationSliceType } from "../index-C6wNUfiV.js";
|
|
9
|
+
import { r as RootState } from "../store-Boqp1x2t.js";
|
|
10
10
|
import * as _$_northern_tech_utils_constants0 from "@northern.tech/utils/constants";
|
|
11
|
-
import { ReleaseV2 } from "@northern.tech/types/MenderTypes";
|
|
11
|
+
import { Manifest, ReleaseV2 } from "@northern.tech/types/MenderTypes";
|
|
12
12
|
import * as _$_northern_tech_types_types_gen0 from "@northern.tech/types/types.gen";
|
|
13
13
|
import * as _$reselect from "reselect";
|
|
14
14
|
|
|
15
15
|
//#region src/releasesSlice/selectors.d.ts
|
|
16
|
+
declare const getActiveTab: (state: RootState) => "releases" | "delta" | "manifests" | undefined;
|
|
16
17
|
declare const getReleasesById: (state: RootState) => Record<string, Release>;
|
|
17
18
|
declare const getReleaseTags: (state: RootState) => string[];
|
|
18
19
|
declare const getReleaseListState: (state: RootState) => ReleasesList;
|
|
@@ -345,6 +346,157 @@ declare const getSelectedJob: ((state: {
|
|
|
345
346
|
memoize: typeof _$reselect.weakMapMemoize;
|
|
346
347
|
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
347
348
|
};
|
|
349
|
+
declare const getManifestsById: (state: RootState) => Record<string, Manifest>;
|
|
350
|
+
declare const getManifestsListState: (state: RootState) => ManifestsList;
|
|
351
|
+
declare const getManifestsList: ((state: {
|
|
352
|
+
app: AppSliceType;
|
|
353
|
+
devices: DeviceSliceType;
|
|
354
|
+
deployments: DeploymentsSliceType;
|
|
355
|
+
monitor: MonitorSliceType;
|
|
356
|
+
onboarding: OnboardingSliceType;
|
|
357
|
+
organization: OrganizationSliceType;
|
|
358
|
+
releases: ReleaseSliceType;
|
|
359
|
+
users: UserSliceType;
|
|
360
|
+
}) => Manifest[]) & {
|
|
361
|
+
clearCache: () => void;
|
|
362
|
+
resultsCount: () => number;
|
|
363
|
+
resetResultsCount: () => void;
|
|
364
|
+
} & {
|
|
365
|
+
resultFunc: (resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[];
|
|
366
|
+
memoizedResultFunc: ((resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[]) & {
|
|
367
|
+
clearCache: () => void;
|
|
368
|
+
resultsCount: () => number;
|
|
369
|
+
resetResultsCount: () => void;
|
|
370
|
+
};
|
|
371
|
+
lastResult: () => Manifest[];
|
|
372
|
+
dependencies: [(state: RootState) => Record<string, Manifest>, (state: RootState) => string[], () => {}];
|
|
373
|
+
recomputations: () => number;
|
|
374
|
+
resetRecomputations: () => void;
|
|
375
|
+
dependencyRecomputations: () => number;
|
|
376
|
+
resetDependencyRecomputations: () => void;
|
|
377
|
+
} & {
|
|
378
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
379
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
380
|
+
};
|
|
381
|
+
declare const getHasManifests: ((state: {
|
|
382
|
+
app: AppSliceType;
|
|
383
|
+
devices: DeviceSliceType;
|
|
384
|
+
deployments: DeploymentsSliceType;
|
|
385
|
+
monitor: MonitorSliceType;
|
|
386
|
+
onboarding: OnboardingSliceType;
|
|
387
|
+
organization: OrganizationSliceType;
|
|
388
|
+
releases: ReleaseSliceType;
|
|
389
|
+
users: UserSliceType;
|
|
390
|
+
}) => boolean) & {
|
|
391
|
+
clearCache: () => void;
|
|
392
|
+
resultsCount: () => number;
|
|
393
|
+
resetResultsCount: () => void;
|
|
394
|
+
} & {
|
|
395
|
+
resultFunc: (resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Record<string, Manifest>) => boolean;
|
|
396
|
+
memoizedResultFunc: ((resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Record<string, Manifest>) => boolean) & {
|
|
397
|
+
clearCache: () => void;
|
|
398
|
+
resultsCount: () => number;
|
|
399
|
+
resetResultsCount: () => void;
|
|
400
|
+
};
|
|
401
|
+
lastResult: () => boolean;
|
|
402
|
+
dependencies: [(state: RootState) => ManifestsList, (state: RootState) => Record<string, Manifest>];
|
|
403
|
+
recomputations: () => number;
|
|
404
|
+
resetRecomputations: () => void;
|
|
405
|
+
dependencyRecomputations: () => number;
|
|
406
|
+
resetDependencyRecomputations: () => void;
|
|
407
|
+
} & {
|
|
408
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
409
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
410
|
+
};
|
|
411
|
+
declare const getSelectedManifest: ((state: {
|
|
412
|
+
app: AppSliceType;
|
|
413
|
+
devices: DeviceSliceType;
|
|
414
|
+
deployments: DeploymentsSliceType;
|
|
415
|
+
monitor: MonitorSliceType;
|
|
416
|
+
onboarding: OnboardingSliceType;
|
|
417
|
+
organization: OrganizationSliceType;
|
|
418
|
+
releases: ReleaseSliceType;
|
|
419
|
+
users: UserSliceType;
|
|
420
|
+
}) => Manifest) & {
|
|
421
|
+
clearCache: () => void;
|
|
422
|
+
resultsCount: () => number;
|
|
423
|
+
resetResultsCount: () => void;
|
|
424
|
+
} & {
|
|
425
|
+
resultFunc: (resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string | null) => Manifest;
|
|
426
|
+
memoizedResultFunc: ((resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string | null) => Manifest) & {
|
|
427
|
+
clearCache: () => void;
|
|
428
|
+
resultsCount: () => number;
|
|
429
|
+
resetResultsCount: () => void;
|
|
430
|
+
};
|
|
431
|
+
lastResult: () => Manifest;
|
|
432
|
+
dependencies: [(state: RootState) => Record<string, Manifest>, (state: RootState) => string | null];
|
|
433
|
+
recomputations: () => number;
|
|
434
|
+
resetRecomputations: () => void;
|
|
435
|
+
dependencyRecomputations: () => number;
|
|
436
|
+
resetDependencyRecomputations: () => void;
|
|
437
|
+
} & {
|
|
438
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
439
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
440
|
+
};
|
|
441
|
+
declare const getSelectedManifests: ((state: {
|
|
442
|
+
app: AppSliceType;
|
|
443
|
+
devices: DeviceSliceType;
|
|
444
|
+
deployments: DeploymentsSliceType;
|
|
445
|
+
monitor: MonitorSliceType;
|
|
446
|
+
onboarding: OnboardingSliceType;
|
|
447
|
+
organization: OrganizationSliceType;
|
|
448
|
+
releases: ReleaseSliceType;
|
|
449
|
+
users: UserSliceType;
|
|
450
|
+
}) => Manifest[]) & {
|
|
451
|
+
clearCache: () => void;
|
|
452
|
+
resultsCount: () => number;
|
|
453
|
+
resetResultsCount: () => void;
|
|
454
|
+
} & {
|
|
455
|
+
resultFunc: (resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Manifest[]) => Manifest[];
|
|
456
|
+
memoizedResultFunc: ((resultFuncArgs_0: ManifestsList, resultFuncArgs_1: Manifest[]) => Manifest[]) & {
|
|
457
|
+
clearCache: () => void;
|
|
458
|
+
resultsCount: () => number;
|
|
459
|
+
resetResultsCount: () => void;
|
|
460
|
+
};
|
|
461
|
+
lastResult: () => Manifest[];
|
|
462
|
+
dependencies: [(state: RootState) => ManifestsList, ((state: {
|
|
463
|
+
app: AppSliceType;
|
|
464
|
+
devices: DeviceSliceType;
|
|
465
|
+
deployments: DeploymentsSliceType;
|
|
466
|
+
monitor: MonitorSliceType;
|
|
467
|
+
onboarding: OnboardingSliceType;
|
|
468
|
+
organization: OrganizationSliceType;
|
|
469
|
+
releases: ReleaseSliceType;
|
|
470
|
+
users: UserSliceType;
|
|
471
|
+
}) => Manifest[]) & {
|
|
472
|
+
clearCache: () => void;
|
|
473
|
+
resultsCount: () => number;
|
|
474
|
+
resetResultsCount: () => void;
|
|
475
|
+
} & {
|
|
476
|
+
resultFunc: (resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[];
|
|
477
|
+
memoizedResultFunc: ((resultFuncArgs_0: Record<string, Manifest>, resultFuncArgs_1: string[], resultFuncArgs_2: {}) => Manifest[]) & {
|
|
478
|
+
clearCache: () => void;
|
|
479
|
+
resultsCount: () => number;
|
|
480
|
+
resetResultsCount: () => void;
|
|
481
|
+
};
|
|
482
|
+
lastResult: () => Manifest[];
|
|
483
|
+
dependencies: [(state: RootState) => Record<string, Manifest>, (state: RootState) => string[], () => {}];
|
|
484
|
+
recomputations: () => number;
|
|
485
|
+
resetRecomputations: () => void;
|
|
486
|
+
dependencyRecomputations: () => number;
|
|
487
|
+
resetDependencyRecomputations: () => void;
|
|
488
|
+
} & {
|
|
489
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
490
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
491
|
+
}];
|
|
492
|
+
recomputations: () => number;
|
|
493
|
+
resetRecomputations: () => void;
|
|
494
|
+
dependencyRecomputations: () => number;
|
|
495
|
+
resetDependencyRecomputations: () => void;
|
|
496
|
+
} & {
|
|
497
|
+
memoize: typeof _$reselect.weakMapMemoize;
|
|
498
|
+
argsMemoize: typeof _$reselect.weakMapMemoize;
|
|
499
|
+
};
|
|
348
500
|
//#endregion
|
|
349
|
-
export { getDeltaJobById, getDeltaJobsById, getDeltaJobsListState, getHasReleases, getReleaseListState, getReleaseTags, getReleaseTagsById, getReleasesById, getReleasesList, getSelectedJob, getSelectedRelease, getSelectedReleases, getUpdateTypes };
|
|
501
|
+
export { getActiveTab, getDeltaJobById, getDeltaJobsById, getDeltaJobsListState, getHasManifests, getHasReleases, getManifestsById, getManifestsList, getManifestsListState, getReleaseListState, getReleaseTags, getReleaseTagsById, getReleasesById, getReleasesList, getSelectedJob, getSelectedManifest, getSelectedManifests, getSelectedRelease, getSelectedReleases, getUpdateTypes };
|
|
350
502
|
//# sourceMappingURL=selectors.d.ts.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { listItemMapper } from "../utils.js";
|
|
2
2
|
import { createSelector } from "@reduxjs/toolkit";
|
|
3
3
|
//#region src/releasesSlice/selectors.ts
|
|
4
|
+
const getActiveTab = (state) => state.releases.tab;
|
|
4
5
|
const getSelectedReleaseId = (state) => state.releases.selectedRelease;
|
|
5
6
|
const getReleasesById = (state) => state.releases.byId;
|
|
6
7
|
const getReleaseTags = (state) => state.releases.tags;
|
|
@@ -26,7 +27,21 @@ const getDeltaJobsById = (state) => state.releases.deltaJobs;
|
|
|
26
27
|
const getDeltaJobById = createSelector([getDeltaJobsById, (_, jobId) => jobId], (byId, jobId) => byId[jobId]);
|
|
27
28
|
const getSelectedJobId = (state) => state.releases.selectedJob;
|
|
28
29
|
const getSelectedJob = createSelector([getDeltaJobsById, getSelectedJobId], (byId, jobId) => byId[jobId || ""]);
|
|
30
|
+
const getSelectedManifestId = (state) => state.releases.selectedManifest;
|
|
31
|
+
const getManifestsById = (state) => state.releases.manifestsById;
|
|
32
|
+
const getManifestsListState = (state) => state.releases.manifestsList;
|
|
33
|
+
const getListedManifests = (state) => state.releases.manifestsList.manifestIds;
|
|
34
|
+
const manifestDefaults = {};
|
|
35
|
+
const getManifestMappingDefaults = () => manifestDefaults;
|
|
36
|
+
const getManifestsList = createSelector([
|
|
37
|
+
getManifestsById,
|
|
38
|
+
getListedManifests,
|
|
39
|
+
getManifestMappingDefaults
|
|
40
|
+
], listItemMapper);
|
|
41
|
+
const getHasManifests = createSelector([getManifestsListState, getManifestsById], ({ searchTotal, total }, byId) => !!(Object.keys(byId).length || total || searchTotal));
|
|
42
|
+
const getSelectedManifest = createSelector([getManifestsById, getSelectedManifestId], (byId, id) => byId[id || ""] ?? {});
|
|
43
|
+
const getSelectedManifests = createSelector([getManifestsListState, getManifestsList], ({ selection }, manifests) => selection.map((index) => manifests[index]));
|
|
29
44
|
//#endregion
|
|
30
|
-
export { getDeltaJobById, getDeltaJobsById, getDeltaJobsListState, getHasReleases, getReleaseListState, getReleaseTags, getReleaseTagsById, getReleasesById, getReleasesList, getSelectedJob, getSelectedRelease, getSelectedReleases, getUpdateTypes };
|
|
45
|
+
export { getActiveTab, getDeltaJobById, getDeltaJobsById, getDeltaJobsListState, getHasManifests, getHasReleases, getManifestsById, getManifestsList, getManifestsListState, getReleaseListState, getReleaseTags, getReleaseTagsById, getReleasesById, getReleasesList, getSelectedJob, getSelectedManifest, getSelectedManifests, getSelectedRelease, getSelectedReleases, getUpdateTypes };
|
|
31
46
|
|
|
32
47
|
//# sourceMappingURL=selectors.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"selectors.js","names":[],"sources":["../../src/releasesSlice/selectors.ts"],"sourcesContent":["// Copyright 2023 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 { ReleaseV2 } from '@northern.tech/types/MenderTypes';\nimport { createSelector } from '@reduxjs/toolkit';\n\nimport type { RootState } from '../store';\nimport { listItemMapper } from '../utils';\n\nconst getSelectedReleaseId = (state: RootState) => state.releases.selectedRelease;\nexport const getReleasesById = (state: RootState) => state.releases.byId;\nexport const getReleaseTags = (state: RootState) => state.releases.tags;\nexport const getReleaseListState = (state: RootState) => state.releases.releasesList;\nconst getListedReleases = (state: RootState) => state.releases.releasesList.releaseIds;\nexport const getUpdateTypes = (state: RootState) => state.releases.updateTypes;\nconst releaseDefaults = {};\nconst getReleaseMappingDefaults = () => releaseDefaults;\nexport const getReleasesList = createSelector([getReleasesById, getListedReleases, getReleaseMappingDefaults], listItemMapper<ReleaseV2>);\n\nexport const getReleaseTagsById = createSelector([getReleaseTags], releaseTags => releaseTags.reduce((accu, key) => ({ ...accu, [key]: key }), {}));\nexport const getHasReleases = createSelector(\n [getReleaseListState, getReleasesById],\n ({ searchTotal, total }, byId) => !!(Object.keys(byId).length || total || searchTotal)\n);\n\nexport const getSelectedRelease = createSelector([getReleasesById, getSelectedReleaseId], (byId, id) => byId[id || ''] ?? {});\n\nexport const getSelectedReleases = createSelector([getReleaseListState, getReleasesList], ({ selection }, releases) => selection.map(index => releases[index]));\n\nexport const getDeltaJobsListState = (state: RootState) => state.releases.deltaJobsList;\nexport const getDeltaJobsById = (state: RootState) => state.releases.deltaJobs;\nexport const getDeltaJobById = createSelector([getDeltaJobsById, (_, jobId) => jobId], (byId, jobId: string) => byId[jobId]);\nconst getSelectedJobId = (state: RootState) => state.releases.selectedJob;\nexport const getSelectedJob = createSelector([getDeltaJobsById, getSelectedJobId], (byId, jobId) => byId[jobId || '']);\n"],"mappings":";;;AAmBA,MAAM,wBAAwB,UAAqB,MAAM,SAAS;AAClE,MAAa,mBAAmB,UAAqB,MAAM,SAAS;AACpE,MAAa,kBAAkB,UAAqB,MAAM,SAAS;AACnE,MAAa,uBAAuB,UAAqB,MAAM,SAAS;AACxE,MAAM,qBAAqB,UAAqB,MAAM,SAAS,aAAa;AAC5E,MAAa,kBAAkB,UAAqB,MAAM,SAAS;AACnE,MAAM,kBAAkB,EAAE;AAC1B,MAAM,kCAAkC;AACxC,MAAa,kBAAkB,eAAe;CAAC;CAAiB;CAAmB;CAA0B,EAAE,eAA0B;AAEzI,MAAa,qBAAqB,eAAe,CAAC,eAAe,GAAE,gBAAe,YAAY,QAAQ,MAAM,SAAS;CAAE,GAAG;EAAO,MAAM;CAAK,GAAG,EAAE,CAAC,CAAC;AACnJ,MAAa,iBAAiB,eAC5B,CAAC,qBAAqB,gBAAgB,GACrC,EAAE,aAAa,SAAS,SAAS,CAAC,EAAE,OAAO,KAAK,KAAK,CAAC,UAAU,SAAS,aAC3E;AAED,MAAa,qBAAqB,eAAe,CAAC,iBAAiB,qBAAqB,GAAG,MAAM,OAAO,KAAK,MAAM,OAAO,EAAE,CAAC;AAE7H,MAAa,sBAAsB,eAAe,CAAC,qBAAqB,gBAAgB,GAAG,EAAE,aAAa,aAAa,UAAU,KAAI,UAAS,SAAS,OAAO,CAAC;AAE/J,MAAa,yBAAyB,UAAqB,MAAM,SAAS;AAC1E,MAAa,oBAAoB,UAAqB,MAAM,SAAS;AACrE,MAAa,kBAAkB,eAAe,CAAC,mBAAmB,GAAG,UAAU,MAAM,GAAG,MAAM,UAAkB,KAAK,OAAO;AAC5H,MAAM,oBAAoB,UAAqB,MAAM,SAAS;AAC9D,MAAa,iBAAiB,eAAe,CAAC,kBAAkB,iBAAiB,GAAG,MAAM,UAAU,KAAK,SAAS,IAAI"}
|
|
1
|
+
{"version":3,"file":"selectors.js","names":[],"sources":["../../src/releasesSlice/selectors.ts"],"sourcesContent":["// Copyright 2023 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 { Manifest, ReleaseV2 } from '@northern.tech/types/MenderTypes';\nimport { createSelector } from '@reduxjs/toolkit';\n\nimport type { RootState } from '../store';\nimport { listItemMapper } from '../utils';\n\nexport const getActiveTab = (state: RootState) => state.releases.tab;\nconst getSelectedReleaseId = (state: RootState) => state.releases.selectedRelease;\nexport const getReleasesById = (state: RootState) => state.releases.byId;\nexport const getReleaseTags = (state: RootState) => state.releases.tags;\nexport const getReleaseListState = (state: RootState) => state.releases.releasesList;\nconst getListedReleases = (state: RootState) => state.releases.releasesList.releaseIds;\nexport const getUpdateTypes = (state: RootState) => state.releases.updateTypes;\nconst releaseDefaults = {};\nconst getReleaseMappingDefaults = () => releaseDefaults;\nexport const getReleasesList = createSelector([getReleasesById, getListedReleases, getReleaseMappingDefaults], listItemMapper<ReleaseV2>);\n\nexport const getReleaseTagsById = createSelector([getReleaseTags], releaseTags => releaseTags.reduce((accu, key) => ({ ...accu, [key]: key }), {}));\nexport const getHasReleases = createSelector(\n [getReleaseListState, getReleasesById],\n ({ searchTotal, total }, byId) => !!(Object.keys(byId).length || total || searchTotal)\n);\n\nexport const getSelectedRelease = createSelector([getReleasesById, getSelectedReleaseId], (byId, id) => byId[id || ''] ?? {});\n\nexport const getSelectedReleases = createSelector([getReleaseListState, getReleasesList], ({ selection }, releases) => selection.map(index => releases[index]));\n\nexport const getDeltaJobsListState = (state: RootState) => state.releases.deltaJobsList;\nexport const getDeltaJobsById = (state: RootState) => state.releases.deltaJobs;\nexport const getDeltaJobById = createSelector([getDeltaJobsById, (_, jobId) => jobId], (byId, jobId: string) => byId[jobId]);\nconst getSelectedJobId = (state: RootState) => state.releases.selectedJob;\nexport const getSelectedJob = createSelector([getDeltaJobsById, getSelectedJobId], (byId, jobId) => byId[jobId || '']);\n\nconst getSelectedManifestId = (state: RootState) => state.releases.selectedManifest;\nexport const getManifestsById = (state: RootState) => state.releases.manifestsById;\nexport const getManifestsListState = (state: RootState) => state.releases.manifestsList;\nconst getListedManifests = (state: RootState) => state.releases.manifestsList.manifestIds;\nconst manifestDefaults = {};\nconst getManifestMappingDefaults = () => manifestDefaults;\nexport const getManifestsList = createSelector([getManifestsById, getListedManifests, getManifestMappingDefaults], listItemMapper<Manifest>);\n\nexport const getHasManifests = createSelector(\n [getManifestsListState, getManifestsById],\n ({ searchTotal, total }, byId) => !!(Object.keys(byId).length || total || searchTotal)\n);\n\nexport const getSelectedManifest = createSelector([getManifestsById, getSelectedManifestId], (byId, id) => byId[id || ''] ?? {});\n\nexport const getSelectedManifests = createSelector([getManifestsListState, getManifestsList], ({ selection }, manifests) =>\n selection.map(index => manifests[index])\n);\n"],"mappings":";;;AAmBA,MAAa,gBAAgB,UAAqB,MAAM,SAAS;AACjE,MAAM,wBAAwB,UAAqB,MAAM,SAAS;AAClE,MAAa,mBAAmB,UAAqB,MAAM,SAAS;AACpE,MAAa,kBAAkB,UAAqB,MAAM,SAAS;AACnE,MAAa,uBAAuB,UAAqB,MAAM,SAAS;AACxE,MAAM,qBAAqB,UAAqB,MAAM,SAAS,aAAa;AAC5E,MAAa,kBAAkB,UAAqB,MAAM,SAAS;AACnE,MAAM,kBAAkB,EAAE;AAC1B,MAAM,kCAAkC;AACxC,MAAa,kBAAkB,eAAe;CAAC;CAAiB;CAAmB;CAA0B,EAAE,eAA0B;AAEzI,MAAa,qBAAqB,eAAe,CAAC,eAAe,GAAE,gBAAe,YAAY,QAAQ,MAAM,SAAS;CAAE,GAAG;EAAO,MAAM;CAAK,GAAG,EAAE,CAAC,CAAC;AACnJ,MAAa,iBAAiB,eAC5B,CAAC,qBAAqB,gBAAgB,GACrC,EAAE,aAAa,SAAS,SAAS,CAAC,EAAE,OAAO,KAAK,KAAK,CAAC,UAAU,SAAS,aAC3E;AAED,MAAa,qBAAqB,eAAe,CAAC,iBAAiB,qBAAqB,GAAG,MAAM,OAAO,KAAK,MAAM,OAAO,EAAE,CAAC;AAE7H,MAAa,sBAAsB,eAAe,CAAC,qBAAqB,gBAAgB,GAAG,EAAE,aAAa,aAAa,UAAU,KAAI,UAAS,SAAS,OAAO,CAAC;AAE/J,MAAa,yBAAyB,UAAqB,MAAM,SAAS;AAC1E,MAAa,oBAAoB,UAAqB,MAAM,SAAS;AACrE,MAAa,kBAAkB,eAAe,CAAC,mBAAmB,GAAG,UAAU,MAAM,GAAG,MAAM,UAAkB,KAAK,OAAO;AAC5H,MAAM,oBAAoB,UAAqB,MAAM,SAAS;AAC9D,MAAa,iBAAiB,eAAe,CAAC,kBAAkB,iBAAiB,GAAG,MAAM,UAAU,KAAK,SAAS,IAAI;AAEtH,MAAM,yBAAyB,UAAqB,MAAM,SAAS;AACnE,MAAa,oBAAoB,UAAqB,MAAM,SAAS;AACrE,MAAa,yBAAyB,UAAqB,MAAM,SAAS;AAC1E,MAAM,sBAAsB,UAAqB,MAAM,SAAS,cAAc;AAC9E,MAAM,mBAAmB,EAAE;AAC3B,MAAM,mCAAmC;AACzC,MAAa,mBAAmB,eAAe;CAAC;CAAkB;CAAoB;CAA2B,EAAE,eAAyB;AAE5I,MAAa,kBAAkB,eAC7B,CAAC,uBAAuB,iBAAiB,GACxC,EAAE,aAAa,SAAS,SAAS,CAAC,EAAE,OAAO,KAAK,KAAK,CAAC,UAAU,SAAS,aAC3E;AAED,MAAa,sBAAsB,eAAe,CAAC,kBAAkB,sBAAsB,GAAG,MAAM,OAAO,KAAK,MAAM,OAAO,EAAE,CAAC;AAEhI,MAAa,uBAAuB,eAAe,CAAC,uBAAuB,iBAAiB,GAAG,EAAE,aAAa,cAC5G,UAAU,KAAI,UAAS,UAAU,OAAO,CACzC"}
|
|
@@ -412,6 +412,91 @@ const getDeltaGenerationJobDetails = require_store.createAppAsyncThunk(`${requir
|
|
|
412
412
|
...data,
|
|
413
413
|
id: jobId
|
|
414
414
|
}))).catch((err) => require_store.commonErrorHandler(err, "There was an error retrieving delta generation job details:", dispatch)));
|
|
415
|
+
const manifestSortingDefaults = {
|
|
416
|
+
direction: _northern_tech_utils_constants.SORTING_OPTIONS.desc,
|
|
417
|
+
key: "modified"
|
|
418
|
+
};
|
|
419
|
+
const reduceReceivedManifests = (manifests) => manifests.reduce((accu, manifest) => {
|
|
420
|
+
accu[manifest.name] = manifest;
|
|
421
|
+
return accu;
|
|
422
|
+
}, {});
|
|
423
|
+
const manifestListRetrieval = (config) => {
|
|
424
|
+
const { searchTerm = "", page = defaultPage, perPage = defaultPerPage, sort = manifestSortingDefaults } = config;
|
|
425
|
+
const { key: attribute, direction } = sort;
|
|
426
|
+
const nameFilter = searchTerm ? `name=${encodeURIComponent(searchTerm)}` : "";
|
|
427
|
+
const sorting = attribute ? `sort=${attribute}:${direction}`.toLowerCase() : "";
|
|
428
|
+
return require_api_general_api.default.get(`${_northern_tech_utils_constants.deploymentsApiUrlV1alpha1}/manifests?${[
|
|
429
|
+
`page=${page}`,
|
|
430
|
+
`per_page=${perPage}`,
|
|
431
|
+
nameFilter,
|
|
432
|
+
sorting
|
|
433
|
+
].filter((i) => i).join("&")}`);
|
|
434
|
+
};
|
|
435
|
+
const deductManifestSearchState = (receivedManifests, config, total, state) => {
|
|
436
|
+
let manifestsListState = { ...state.manifestsList };
|
|
437
|
+
const { searchTerm, sort = {} } = config;
|
|
438
|
+
const manifestIds = Object.values(receivedManifests).sort((0, _northern_tech_utils_helpers.customSort)(sort.direction === _northern_tech_utils_constants.SORTING_OPTIONS.desc, sort.key)).map((item) => item.name);
|
|
439
|
+
const isFiltering = !!searchTerm;
|
|
440
|
+
manifestsListState = {
|
|
441
|
+
...manifestsListState,
|
|
442
|
+
manifestIds,
|
|
443
|
+
searchTotal: isFiltering ? total : state.manifestsList.searchTotal,
|
|
444
|
+
total: !isFiltering ? total : state.manifestsList.total
|
|
445
|
+
};
|
|
446
|
+
return manifestsListState;
|
|
447
|
+
};
|
|
448
|
+
const getManifests = require_store.createAppAsyncThunk(`${require_releasesSlice_index.sliceName}/getManifests`, async (passedConfig = {}, { dispatch, getState }) => {
|
|
449
|
+
const config = {
|
|
450
|
+
...getState().releases.manifestsList,
|
|
451
|
+
...passedConfig
|
|
452
|
+
};
|
|
453
|
+
const { data: receivedManifests = [], headers = {} } = await manifestListRetrieval(config).catch((err) => require_store.commonErrorHandler(err, `Please check your connection`, dispatch));
|
|
454
|
+
const total = headers[_northern_tech_utils_constants.headerNames.total] ? Number(headers[_northern_tech_utils_constants.headerNames.total]) : 0;
|
|
455
|
+
const state = getState().releases;
|
|
456
|
+
const flatManifests = reduceReceivedManifests(receivedManifests);
|
|
457
|
+
const combinedManifests = {
|
|
458
|
+
...state.manifestsById,
|
|
459
|
+
...flatManifests
|
|
460
|
+
};
|
|
461
|
+
dispatch(require_releasesSlice_index.actions.receiveManifests(combinedManifests));
|
|
462
|
+
const manifestsListState = deductManifestSearchState(receivedManifests, config, total, state);
|
|
463
|
+
dispatch(require_releasesSlice_index.actions.setManifestsListState(manifestsListState));
|
|
464
|
+
return combinedManifests;
|
|
465
|
+
});
|
|
466
|
+
const getManifest = require_store.createAppAsyncThunk(`${require_releasesSlice_index.sliceName}/getManifest`, async (name, { dispatch, getState }) => {
|
|
467
|
+
const { data } = await require_api_general_api.default.get(`${_northern_tech_utils_constants.deploymentsApiUrlV1alpha1}/manifests/${name}`);
|
|
468
|
+
if (!data) return null;
|
|
469
|
+
const manifest = {
|
|
470
|
+
...require_releasesSlice_selectors.getManifestsById(getState())[data.name] || {},
|
|
471
|
+
...data
|
|
472
|
+
};
|
|
473
|
+
dispatch(require_releasesSlice_index.actions.receiveManifest(manifest));
|
|
474
|
+
return manifest;
|
|
475
|
+
});
|
|
476
|
+
const selectManifest = require_store.createAppAsyncThunk(`${require_releasesSlice_index.sliceName}/selectManifest`, async (manifest, { dispatch }) => {
|
|
477
|
+
const name = (manifest && typeof manifest === "object" ? manifest.name : manifest) || null;
|
|
478
|
+
dispatch(require_releasesSlice_index.actions.selectedManifest(name));
|
|
479
|
+
if (name) await dispatch(getManifest(name)).unwrap();
|
|
480
|
+
});
|
|
481
|
+
const setManifestsListState = require_store.createAppAsyncThunk(`${require_releasesSlice_index.sliceName}/setManifestsListState`, async (selectionState, { dispatch, getState }) => {
|
|
482
|
+
const currentState = getState().releases.manifestsList;
|
|
483
|
+
const nextState = {
|
|
484
|
+
...currentState,
|
|
485
|
+
...selectionState,
|
|
486
|
+
sort: {
|
|
487
|
+
...currentState.sort,
|
|
488
|
+
...selectionState.sort
|
|
489
|
+
}
|
|
490
|
+
};
|
|
491
|
+
const { isLoading: currentLoading, ...currentRequestState } = currentState;
|
|
492
|
+
const { isLoading: selectionLoading, ...selectionRequestState } = nextState;
|
|
493
|
+
if (!(0, _northern_tech_utils_helpers.deepCompare)(currentRequestState, selectionRequestState)) {
|
|
494
|
+
nextState.isLoading = true;
|
|
495
|
+
dispatch(getManifests(nextState)).unwrap().finally(() => dispatch(setManifestsListState({ isLoading: false })).unwrap());
|
|
496
|
+
}
|
|
497
|
+
if (currentState.page !== nextState.page || currentState.perPage > nextState.perPage || !(0, _northern_tech_utils_helpers.deepCompare)(currentState.sort, nextState.sort)) nextState.selection = [];
|
|
498
|
+
dispatch(require_releasesSlice_index.actions.setManifestsListState(nextState));
|
|
499
|
+
});
|
|
415
500
|
//#endregion
|
|
416
501
|
exports.cancelFileUpload = cancelFileUpload;
|
|
417
502
|
exports.createArtifact = createArtifact;
|
|
@@ -421,13 +506,17 @@ exports.getArtifactUrl = getArtifactUrl;
|
|
|
421
506
|
exports.getDeltaGenerationJobDetails = getDeltaGenerationJobDetails;
|
|
422
507
|
exports.getDeltaGenerationJobs = getDeltaGenerationJobs;
|
|
423
508
|
exports.getExistingReleaseTags = getExistingReleaseTags;
|
|
509
|
+
exports.getManifest = getManifest;
|
|
510
|
+
exports.getManifests = getManifests;
|
|
424
511
|
exports.getRelease = getRelease;
|
|
425
512
|
exports.getReleases = getReleases;
|
|
426
513
|
exports.getUpdateTypes = getUpdateTypes;
|
|
427
514
|
exports.removeArtifact = removeArtifact;
|
|
428
515
|
exports.removeRelease = removeRelease;
|
|
429
516
|
exports.removeReleases = removeReleases;
|
|
517
|
+
exports.selectManifest = selectManifest;
|
|
430
518
|
exports.selectRelease = selectRelease;
|
|
519
|
+
exports.setManifestsListState = setManifestsListState;
|
|
431
520
|
exports.setReleaseTags = setReleaseTags;
|
|
432
521
|
exports.setReleasesListState = setReleasesListState;
|
|
433
522
|
exports.setReleasesTags = setReleasesTags;
|