@balena/ui-shared-components 12.0.1-build-renovate-major-7-react-router-dom-5a89a0ddf13f62416fb0ce2cc4b2148c4edb2ed7-1 → 12.0.1-build-upgrade-storybook-to-8-6-fd98f9f481f55338bfe6701eee1846a17a50114c-1

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.
@@ -3,13 +3,11 @@ import type { IconDefinition } from '@fortawesome/free-solid-svg-icons';
3
3
  type JsonToken = {
4
4
  type: string;
5
5
  value: string;
6
- blendMode: string;
7
6
  filePath: string;
8
7
  isSource: boolean;
9
8
  original: {
10
9
  type: string;
11
10
  value: string;
12
- blendMode: string;
13
11
  };
14
12
  name: string;
15
13
  attributes: {
@@ -18,17 +16,18 @@ type JsonToken = {
18
16
  [key: string]: string;
19
17
  };
20
18
  path: string[];
19
+ key: string;
21
20
  };
22
21
  export declare const ColorTable: ({ children }: {
23
22
  children: React.ReactNode;
24
23
  }) => import("react/jsx-runtime").JSX.Element;
25
- export declare const ColorRow: ({ token, description, }: {
26
- token: {
24
+ export declare const ColorRow: ({ designToken, description, }: {
25
+ designToken: {
27
26
  value: string;
28
27
  name: string;
29
28
  };
30
29
  description: string;
31
- }) => import("react/jsx-runtime").JSX.Element;
30
+ }) => import("react/jsx-runtime").JSX.Element | undefined;
32
31
  /**
33
32
  * split pascalcase into lowercase words separated with dots or dashes, and remove first separator
34
33
  */
@@ -4,8 +4,13 @@ import { useState } from 'react';
4
4
  import { Box, ToggleButton, ToggleButtonGroup, Typography, } from '@mui/material';
5
5
  import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
6
6
  import { token as getToken } from '../utils/token';
7
+ import jsonTokens from '@balena/design-tokens/build/json/tokens.json';
7
8
  export const ColorTable = ({ children }) => (_jsxs("table", { style: { width: '100%', borderCollapse: 'collapse' }, children: [_jsx("thead", { children: _jsxs("tr", { children: [_jsx("th", { style: { textAlign: 'left', width: '75px' }, children: "Color" }), _jsx("th", { style: { textAlign: 'left' }, children: "Token" }), _jsx("th", { style: { textAlign: 'left' }, children: "Description" }), _jsx("th", { style: { textAlign: 'left' }, children: "Variables" }), _jsx("th", { style: { textAlign: 'left' }, children: "Value" })] }) }), _jsx("tbody", { children: children })] }));
8
- export const ColorRow = ({ token, description, }) => {
9
+ export const ColorRow = ({ designToken, description, }) => {
10
+ const token = jsonTokens.find((jsonToken) => jsonToken.key === `{${designToken}}`);
11
+ if (!token) {
12
+ return;
13
+ }
9
14
  return (_jsxs("tr", { children: [_jsx("td", { children: _jsx("div", { style: {
10
15
  width: '100%',
11
16
  height: '20px',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@balena/ui-shared-components",
3
- "version": "12.0.1-build-renovate-major-7-react-router-dom-5a89a0ddf13f62416fb0ce2cc4b2148c4edb2ed7-1",
3
+ "version": "12.0.1-build-upgrade-storybook-to-8-6-fd98f9f481f55338bfe6701eee1846a17a50114c-1",
4
4
  "main": "./dist/index.js",
5
5
  "sideEffects": false,
6
6
  "files": [
@@ -44,7 +44,7 @@
44
44
  "react-dropzone": "^14.2.3",
45
45
  "react-helmet": "^6.1.0",
46
46
  "react-markdown": "^10.0.0",
47
- "react-router-dom": "^7.0.0",
47
+ "react-router-dom": "^6.28.0",
48
48
  "remark-breaks": "^4.0.0",
49
49
  "remark-gfm": "^4.0.0",
50
50
  "rimraf": "^6.0.0",
@@ -55,18 +55,17 @@
55
55
  },
56
56
  "devDependencies": {
57
57
  "@balena/lint": "^9.1.0",
58
- "@storybook/addon-essentials": "^8.5.0",
59
- "@storybook/addon-interactions": "^8.5.0",
60
- "@storybook/addon-links": "^8.5.0",
61
- "@storybook/addon-mdx-gfm": "^8.5.0",
62
- "@storybook/addon-onboarding": "^8.5.0",
63
- "@storybook/addon-webpack5-compiler-swc": "^2.0.0",
64
- "@storybook/blocks": "^8.5.0",
65
- "@storybook/manager-api": "^8.5.0",
66
- "@storybook/react": "^8.5.0",
67
- "@storybook/react-webpack5": "^8.5.0",
68
- "@storybook/test": "^8.5.0",
69
- "@storybook/theming": "^8.5.0",
58
+ "@storybook/addon-essentials": "^8.6.12",
59
+ "@storybook/addon-interactions": "^8.6.12",
60
+ "@storybook/addon-links": "^8.6.12",
61
+ "@storybook/addon-onboarding": "^8.6.12",
62
+ "@storybook/addon-webpack5-compiler-swc": "^3.0.0",
63
+ "@storybook/blocks": "^8.6.12",
64
+ "@storybook/manager-api": "^8.6.12",
65
+ "@storybook/react": "^8.6.12",
66
+ "@storybook/react-webpack5": "^8.6.12",
67
+ "@storybook/test": "^8.6.12",
68
+ "@storybook/theming": "^8.6.12",
70
69
  "@types/color": "^4.2.0",
71
70
  "@types/color-hash": "^2.0.0",
72
71
  "@types/lodash": "^4.17.14",
@@ -76,11 +75,11 @@
76
75
  "@types/react-dom": "^18.0.11",
77
76
  "@types/react-helmet": "^6.1.6",
78
77
  "@types/zxcvbn": "^4.4.4",
79
- "eslint-plugin-storybook": "^0.11.2",
78
+ "eslint-plugin-storybook": "^0.12.0",
80
79
  "husky": "^9.0.0",
81
80
  "lint-staged": "^15.0.0",
82
81
  "prop-types": "^15.8.1",
83
- "storybook": "^8.5.0",
82
+ "storybook": "^8.6.12",
84
83
  "ts-loader": "^9.5.1",
85
84
  "webpack": "^5.88.2"
86
85
  },
@@ -139,6 +138,6 @@
139
138
  },
140
139
  "homepage": "https://github.com/balena-io/ui-shared-components#readme",
141
140
  "versionist": {
142
- "publishedAt": "2025-04-04T13:08:03.342Z"
141
+ "publishedAt": "2025-04-04T14:51:19.041Z"
143
142
  }
144
143
  }