@orchestrator-ui/orchestrator-ui-components 1.26.0 → 1.27.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/.turbo/turbo-build.log +4 -4
- package/.turbo/turbo-lint.log +1 -1
- package/.turbo/turbo-test.log +34 -33
- package/CHANGELOG.md +9 -0
- package/dist/index.d.ts +75 -66
- package/dist/index.js +596 -536
- package/jest.config.cjs +13 -2
- package/package.json +1 -1
- package/src/components/WfoForms/UserInputForm.tsx +18 -13
- package/src/components/WfoForms/UserInputFormWizard.tsx +3 -3
- package/src/components/WfoPageTemplate/WfoBreadcrumbs/WfoBreadcrumbs.tsx +52 -10
- package/src/components/WfoPageTemplate/WfoPageHeader/WfoPageHeader.tsx +1 -11
- package/src/components/WfoPageTemplate/WfoPageTemplate/WfoPageTemplate.tsx +5 -4
- package/src/components/WfoSubscription/WfoInSyncField.tsx +1 -1
- package/src/components/WfoSubscription/WfoSubscriptionDetailTree.tsx +4 -1
- package/src/components/WfoTree/WfoTree.tsx +4 -3
- package/src/components/WfoTree/WfoTreeBranch.tsx +10 -3
- package/src/components/WfoTree/treeUtils.ts +13 -0
- package/src/components/confirmationDialog/WfoConfirmationDialog.tsx +61 -68
- package/src/contexts/ConfirmationDialogProvider.tsx +57 -60
- package/src/messages/en-GB.json +3 -1
- package/src/messages/nl-NL.json +3 -1
- package/src/pages/processes/WfoProcessDetail.tsx +3 -3
- package/src/pages/tasks/WfoTasksListPage.tsx +1 -1
- package/src/rtk/api.ts +5 -21
- package/src/rtk/endpoints/processDetail.ts +11 -11
- package/src/rtk/endpoints/processList.ts +8 -2
- package/src/rtk/endpoints/processListSummary.ts +7 -3
- package/src/rtk/endpoints/processStatusCounts.ts +4 -3
- package/src/rtk/endpoints/settings.ts +5 -5
- package/src/rtk/endpoints/streamMessages.ts +13 -45
- package/src/rtk/endpoints/subscriptionActions.ts +1 -2
- package/src/rtk/endpoints/subscriptionDetail.ts +12 -7
- package/src/rtk/endpoints/subscriptionInUseByRelationsList.ts +4 -2
- package/src/rtk/endpoints/subscriptionList.ts +4 -2
- package/src/rtk/endpoints/subscriptionListSummary.ts +4 -2
- package/src/rtk/endpoints/translations.ts +1 -2
- package/src/types/types.ts +11 -0
- package/src/utils/cacheTag.spec.ts +14 -0
- package/src/utils/cacheTag.ts +11 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { orchestratorApi } from '@/rtk';
|
|
2
|
+
import { CacheTagType } from '@/types';
|
|
2
3
|
import {
|
|
3
4
|
BaseGraphQlResult,
|
|
4
5
|
GraphqlQueryVariables,
|
|
@@ -6,6 +7,7 @@ import {
|
|
|
6
7
|
SubscriptionSummary,
|
|
7
8
|
SubscriptionsResult,
|
|
8
9
|
} from '@/types';
|
|
10
|
+
import { getCacheTag } from '@/utils/cacheTag';
|
|
9
11
|
|
|
10
12
|
export const subscriptionListSummaryQuery = `
|
|
11
13
|
query SubscriptionsList(
|
|
@@ -61,7 +63,7 @@ const subscriptionListSummaryApi = orchestratorApi.injectEndpoints({
|
|
|
61
63
|
pageInfo,
|
|
62
64
|
};
|
|
63
65
|
},
|
|
64
|
-
providesTags:
|
|
66
|
+
providesTags: getCacheTag(CacheTagType.subscriptions),
|
|
65
67
|
}),
|
|
66
68
|
}),
|
|
67
69
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BaseQueryTypes,
|
|
1
|
+
import { BaseQueryTypes, orchestratorApi } from '@/rtk';
|
|
2
2
|
|
|
3
3
|
const TRANSLATIONS_URL = 'translations';
|
|
4
4
|
|
|
@@ -24,7 +24,6 @@ const translationsApi = orchestratorApi.injectEndpoints({
|
|
|
24
24
|
extraOptions: {
|
|
25
25
|
baseQueryType: BaseQueryTypes.fetch,
|
|
26
26
|
},
|
|
27
|
-
providesTags: [CacheTags.backendTranslations],
|
|
28
27
|
}),
|
|
29
28
|
}),
|
|
30
29
|
});
|
package/src/types/types.ts
CHANGED
|
@@ -562,3 +562,14 @@ export type SubscriptionActions = {
|
|
|
562
562
|
terminate: SubscriptionAction[];
|
|
563
563
|
system: SubscriptionAction[];
|
|
564
564
|
};
|
|
565
|
+
|
|
566
|
+
export type CacheTag = { type: CacheTagType; id?: string };
|
|
567
|
+
|
|
568
|
+
export enum CacheTagType {
|
|
569
|
+
engineStatus = 'engineStatus',
|
|
570
|
+
processes = 'processes',
|
|
571
|
+
processStatusCounts = 'processStatusCounts',
|
|
572
|
+
subscriptions = 'subscriptions',
|
|
573
|
+
}
|
|
574
|
+
|
|
575
|
+
export const CACHETAG_TYPE_LIST = 'LIST';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CacheTagType } from '@/types';
|
|
2
|
+
|
|
3
|
+
import { getCacheTag } from './cacheTag';
|
|
4
|
+
|
|
5
|
+
describe('getCacheTag', () => {
|
|
6
|
+
it('returns cacheTag with type only when no id is passed', () => {
|
|
7
|
+
const result = getCacheTag(CacheTagType.processes);
|
|
8
|
+
expect(result).toEqual([{ type: CacheTagType.processes }]);
|
|
9
|
+
});
|
|
10
|
+
it('returns cacheTag with type and id if id is passed', () => {
|
|
11
|
+
const result = getCacheTag(CacheTagType.processes, '123');
|
|
12
|
+
expect(result).toEqual([{ type: CacheTagType.processes, id: '123' }]);
|
|
13
|
+
});
|
|
14
|
+
});
|