@camunda/camunda-composite-components 0.22.5 → 0.22.6
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/lib/esm/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camunda/camunda-composite-components",
|
|
3
|
-
"version": "0.22.
|
|
3
|
+
"version": "0.22.6",
|
|
4
4
|
"description": "Camunda Composite Components",
|
|
5
5
|
"bugs": {
|
|
6
6
|
"url": "https://github.com/camunda/camunda-cloud-management-apps/issues"
|
|
@@ -58,34 +58,34 @@
|
|
|
58
58
|
"@auth0/auth0-spa-js": "2.18.0",
|
|
59
59
|
"@camunda/ccma-shared-types": "workspace:*",
|
|
60
60
|
"@carbon/react": "1.103.0",
|
|
61
|
-
"@chromatic-com/storybook": "5.
|
|
61
|
+
"@chromatic-com/storybook": "5.1.1",
|
|
62
62
|
"@mdx-js/react": "3.1.1",
|
|
63
63
|
"@playwright/test": "1.58.2",
|
|
64
|
-
"@storybook/addon-a11y": "10.3.
|
|
65
|
-
"@storybook/addon-docs": "10.3.
|
|
66
|
-
"@storybook/addon-links": "10.3.
|
|
67
|
-
"@storybook/addon-vitest": "10.3.
|
|
68
|
-
"@storybook/react": "10.3.
|
|
69
|
-
"@storybook/react-vite": "10.3.
|
|
70
|
-
"@vitest/browser": "4.1.
|
|
71
|
-
"@vitest/browser-playwright": "4.1.
|
|
72
|
-
"vitest": "4.1.
|
|
64
|
+
"@storybook/addon-a11y": "10.3.3",
|
|
65
|
+
"@storybook/addon-docs": "10.3.3",
|
|
66
|
+
"@storybook/addon-links": "10.3.3",
|
|
67
|
+
"@storybook/addon-vitest": "10.3.3",
|
|
68
|
+
"@storybook/react": "10.3.3",
|
|
69
|
+
"@storybook/react-vite": "10.3.3",
|
|
70
|
+
"@vitest/browser": "4.1.1",
|
|
71
|
+
"@vitest/browser-playwright": "4.1.1",
|
|
72
|
+
"vitest": "4.1.1",
|
|
73
73
|
"conventional-changelog-conventionalcommits": "9.3.0",
|
|
74
74
|
"eslint-import-resolver-typescript": "4.4.4",
|
|
75
75
|
"eslint-plugin-react": "7.37.5",
|
|
76
76
|
"eslint-plugin-react-hooks": "7.0.1",
|
|
77
|
-
"eslint-plugin-storybook": "10.3.
|
|
77
|
+
"eslint-plugin-storybook": "10.3.3",
|
|
78
78
|
"event-source-polyfill": "1.0.31",
|
|
79
|
-
"mixpanel-browser": "2.
|
|
79
|
+
"mixpanel-browser": "2.77.0",
|
|
80
80
|
"playwright": "1.58.2",
|
|
81
81
|
"react": "19.2.4",
|
|
82
82
|
"react-dom": "19.2.4",
|
|
83
83
|
"react-is": "19.2.4",
|
|
84
84
|
"rimraf": "6.1.3",
|
|
85
85
|
"serve": "14.2.6",
|
|
86
|
-
"storybook": "10.3.
|
|
86
|
+
"storybook": "10.3.3",
|
|
87
87
|
"styled-components": "6.3.12",
|
|
88
|
-
"typescript-eslint": "8.57.
|
|
88
|
+
"typescript-eslint": "8.57.2",
|
|
89
89
|
"wait-on": "9.0.4"
|
|
90
90
|
},
|
|
91
91
|
"peerDependencies": {
|
|
@@ -6,7 +6,7 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
6
6
|
*/
|
|
7
7
|
import { FormLabel, HeaderGlobalAction, HeaderMenuItem, HeaderSideNavItems, Modal, SideNavItems, SideNavLink, SideNavMenu, SideNavMenuItem, } from '@carbon/react';
|
|
8
8
|
import { Close } from '@carbon/react/icons/index.esm.js';
|
|
9
|
-
import { useCallback, useEffect, useState } from 'react';
|
|
9
|
+
import { Fragment, useCallback, useEffect, useState } from 'react';
|
|
10
10
|
import { styled } from 'styled-components';
|
|
11
11
|
import { C3AppMenuIcon } from '../../../assets/c3-icons.js';
|
|
12
12
|
import { useClusterUpdate } from '../../../contexts/c3-cluster-update-manager.js';
|
|
@@ -107,6 +107,14 @@ const SubElementWrapper = styled.ul `
|
|
|
107
107
|
visibility: inherit;
|
|
108
108
|
}
|
|
109
109
|
`;
|
|
110
|
+
const AppBarDivider = styled.li.attrs({
|
|
111
|
+
role: 'separator',
|
|
112
|
+
'aria-hidden': 'true',
|
|
113
|
+
}) `
|
|
114
|
+
border-top: 1px solid var(--cds-border-subtle);
|
|
115
|
+
margin: 0.5rem 1rem;
|
|
116
|
+
list-style: none;
|
|
117
|
+
`;
|
|
110
118
|
export const C3NavigationAppBar = ({ app: appProps, appBar, forwardRef, navbar, toggleAppbar, }) => {
|
|
111
119
|
const { currentApp, domain, analyticsTrack, currentClusterUuid } = useC3UserConfiguration();
|
|
112
120
|
const { orgs, clusters, setClusters, activeOrg, isEnabled, loadClustersById, } = useC3Profile();
|
|
@@ -342,39 +350,38 @@ export const C3NavigationAppBar = ({ app: appProps, appBar, forwardRef, navbar,
|
|
|
342
350
|
if (appBar.closeOnClick !== false) {
|
|
343
351
|
toggleAppbar(false);
|
|
344
352
|
}
|
|
345
|
-
}, children: element.label }, element.key))) })) }), _jsx("li", { children: _jsx(SubElementWrapper, { "$expanded": appBar.isOpen, children: appBarElements
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
353
|
+
}, children: element.label }, element.key))) })) }), _jsx("li", { children: _jsx(SubElementWrapper, { "$expanded": appBar.isOpen, children: appBarElements?.map((element) => {
|
|
354
|
+
if (element.subElements && element.subElements.length > 0) {
|
|
355
|
+
return (_jsxs(Fragment, { children: [element.preceedingDivider && _jsx(AppBarDivider, {}), _jsx(SideNavMenu, { large: true, title: element.label, children: element.subElements.map((subElement) => (_jsx(SideNavMenuItem, { as: subElement.routeProps && forwardRef, href: subElement.href, target: subElement.href ? subElement.target : undefined, isActive: subElement.isActive || subElement.active, ...subElement.routeProps, onClick: () => {
|
|
356
|
+
if (subElement.onClick) {
|
|
357
|
+
subElement.onClick();
|
|
358
|
+
}
|
|
359
|
+
if (subElement.routeProps?.onClick) {
|
|
360
|
+
subElement.routeProps.onClick();
|
|
361
|
+
}
|
|
362
|
+
if (appBar.closeOnClick !== false) {
|
|
363
|
+
toggleAppbar(false);
|
|
364
|
+
}
|
|
365
|
+
if (appBar.elementClicked) {
|
|
366
|
+
appBar.elementClicked(subElement.key);
|
|
367
|
+
}
|
|
368
|
+
}, children: subElement.label }, subElement.key))) })] }, element.key));
|
|
369
|
+
}
|
|
370
|
+
else {
|
|
371
|
+
return (_jsxs(Fragment, { children: [element.preceedingDivider && _jsx(AppBarDivider, {}), _jsx(SideNavLink, { as: element.routeProps && forwardRef, large: true, isActive: element.active, ...element.routeProps, onClick: () => {
|
|
372
|
+
if (element.onClick) {
|
|
373
|
+
element.onClick();
|
|
351
374
|
}
|
|
352
|
-
if (
|
|
353
|
-
|
|
375
|
+
if (element.routeProps?.onClick) {
|
|
376
|
+
element.routeProps.onClick();
|
|
354
377
|
}
|
|
355
378
|
if (appBar.closeOnClick !== false) {
|
|
356
379
|
toggleAppbar(false);
|
|
357
380
|
}
|
|
358
381
|
if (appBar.elementClicked) {
|
|
359
|
-
appBar.elementClicked(
|
|
382
|
+
appBar.elementClicked(element.key);
|
|
360
383
|
}
|
|
361
|
-
}, children:
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
return (_jsx(SideNavLink, { as: element.routeProps && forwardRef, large: true, isActive: element.active, ...element.routeProps, onClick: () => {
|
|
365
|
-
if (element.onClick) {
|
|
366
|
-
element.onClick();
|
|
367
|
-
}
|
|
368
|
-
if (element.routeProps?.onClick) {
|
|
369
|
-
element.routeProps.onClick();
|
|
370
|
-
}
|
|
371
|
-
if (appBar.closeOnClick !== false) {
|
|
372
|
-
toggleAppbar(false);
|
|
373
|
-
}
|
|
374
|
-
if (appBar.elementClicked) {
|
|
375
|
-
appBar.elementClicked(element.key);
|
|
376
|
-
}
|
|
377
|
-
}, href: element.href, target: element.href ? element.target : undefined, children: element.label }, element.key));
|
|
378
|
-
}
|
|
379
|
-
}) }) })] }) }) })] }));
|
|
384
|
+
}, href: element.href, target: element.href ? element.target : undefined, children: element.label })] }, element.key));
|
|
385
|
+
}
|
|
386
|
+
}) }) })] }) }) })] }));
|
|
380
387
|
};
|
|
@@ -15,7 +15,27 @@ export var VersionCheckOperator;
|
|
|
15
15
|
VersionCheckOperator[VersionCheckOperator["SameMinor"] = 5] = "SameMinor";
|
|
16
16
|
})(VersionCheckOperator || (VersionCheckOperator = {}));
|
|
17
17
|
export const checkVersion = (params) => {
|
|
18
|
-
if
|
|
18
|
+
// quick exit: if the versionToCompareTo is
|
|
19
|
+
// - `SNAPSHOT` there is not a lot we can compare here to, so we return false directly
|
|
20
|
+
// - ends with `-SNAPSHOT` we ignore the `-SNAPSHOT` part for the comparison, guess a good matching semver compliant version and try to move on with the generated one in the code
|
|
21
|
+
if (params.versionToCompareTo === 'SNAPSHOT') {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
let versionToCompareTo = params.versionToCompareTo;
|
|
25
|
+
if (versionToCompareTo.endsWith('-SNAPSHOT')) {
|
|
26
|
+
versionToCompareTo = versionToCompareTo.replace('-SNAPSHOT', '');
|
|
27
|
+
const parts = versionToCompareTo.split('.');
|
|
28
|
+
if (parts.length === 1) {
|
|
29
|
+
versionToCompareTo = `${parts[0]}.0.0`;
|
|
30
|
+
}
|
|
31
|
+
else if (parts.length === 2) {
|
|
32
|
+
versionToCompareTo = `${parts[0]}.${parts[1]}.0`;
|
|
33
|
+
}
|
|
34
|
+
else if (parts.length === 3) {
|
|
35
|
+
versionToCompareTo = `${parts[0]}.${parts[1]}.${parts[2]}`;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
if (!semver.valid(versionToCompareTo)) {
|
|
19
39
|
throw new Error('Invalid version to compare to');
|
|
20
40
|
}
|
|
21
41
|
let version = '';
|
|
@@ -44,11 +64,11 @@ export const checkVersion = (params) => {
|
|
|
44
64
|
}
|
|
45
65
|
}
|
|
46
66
|
let parsedVersionToCompareTo = '';
|
|
47
|
-
if (semver.valid(
|
|
48
|
-
parsedVersionToCompareTo =
|
|
67
|
+
if (semver.valid(versionToCompareTo ?? '')) {
|
|
68
|
+
parsedVersionToCompareTo = versionToCompareTo ?? '';
|
|
49
69
|
}
|
|
50
70
|
else {
|
|
51
|
-
const versionSplit =
|
|
71
|
+
const versionSplit = versionToCompareTo?.split(':') ?? [];
|
|
52
72
|
if (versionSplit.length > 1) {
|
|
53
73
|
parsedVersionToCompareTo = versionSplit[1];
|
|
54
74
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camunda/camunda-composite-components",
|
|
3
|
-
"version": "0.22.
|
|
3
|
+
"version": "0.22.6",
|
|
4
4
|
"description": "Camunda Composite Components",
|
|
5
5
|
"bugs": {
|
|
6
6
|
"url": "https://github.com/camunda/camunda-cloud-management-apps/issues"
|
|
@@ -31,36 +31,36 @@
|
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@auth0/auth0-spa-js": "2.18.0",
|
|
33
33
|
"@carbon/react": "1.103.0",
|
|
34
|
-
"@chromatic-com/storybook": "5.
|
|
34
|
+
"@chromatic-com/storybook": "5.1.1",
|
|
35
35
|
"@mdx-js/react": "3.1.1",
|
|
36
36
|
"@playwright/test": "1.58.2",
|
|
37
|
-
"@storybook/addon-a11y": "10.3.
|
|
38
|
-
"@storybook/addon-docs": "10.3.
|
|
39
|
-
"@storybook/addon-links": "10.3.
|
|
40
|
-
"@storybook/addon-vitest": "10.3.
|
|
41
|
-
"@storybook/react": "10.3.
|
|
42
|
-
"@storybook/react-vite": "10.3.
|
|
43
|
-
"@vitest/browser": "4.1.
|
|
44
|
-
"@vitest/browser-playwright": "4.1.
|
|
45
|
-
"vitest": "4.1.
|
|
37
|
+
"@storybook/addon-a11y": "10.3.3",
|
|
38
|
+
"@storybook/addon-docs": "10.3.3",
|
|
39
|
+
"@storybook/addon-links": "10.3.3",
|
|
40
|
+
"@storybook/addon-vitest": "10.3.3",
|
|
41
|
+
"@storybook/react": "10.3.3",
|
|
42
|
+
"@storybook/react-vite": "10.3.3",
|
|
43
|
+
"@vitest/browser": "4.1.1",
|
|
44
|
+
"@vitest/browser-playwright": "4.1.1",
|
|
45
|
+
"vitest": "4.1.1",
|
|
46
46
|
"conventional-changelog-conventionalcommits": "9.3.0",
|
|
47
47
|
"eslint-import-resolver-typescript": "4.4.4",
|
|
48
48
|
"eslint-plugin-react": "7.37.5",
|
|
49
49
|
"eslint-plugin-react-hooks": "7.0.1",
|
|
50
|
-
"eslint-plugin-storybook": "10.3.
|
|
50
|
+
"eslint-plugin-storybook": "10.3.3",
|
|
51
51
|
"event-source-polyfill": "1.0.31",
|
|
52
|
-
"mixpanel-browser": "2.
|
|
52
|
+
"mixpanel-browser": "2.77.0",
|
|
53
53
|
"playwright": "1.58.2",
|
|
54
54
|
"react": "19.2.4",
|
|
55
55
|
"react-dom": "19.2.4",
|
|
56
56
|
"react-is": "19.2.4",
|
|
57
57
|
"rimraf": "6.1.3",
|
|
58
58
|
"serve": "14.2.6",
|
|
59
|
-
"storybook": "10.3.
|
|
59
|
+
"storybook": "10.3.3",
|
|
60
60
|
"styled-components": "6.3.12",
|
|
61
|
-
"typescript-eslint": "8.57.
|
|
61
|
+
"typescript-eslint": "8.57.2",
|
|
62
62
|
"wait-on": "9.0.4",
|
|
63
|
-
"@camunda/ccma-shared-types": "0.0.
|
|
63
|
+
"@camunda/ccma-shared-types": "0.0.4"
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
66
|
"@carbon/react": "1.x",
|