@ledgerhq/native-ui 0.61.0 → 0.61.1-nightly.20260428030635

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.
@@ -31,7 +31,6 @@ export type AccountItemProps = {
31
31
  rightElement?: RightElement;
32
32
  showIcon?: boolean;
33
33
  backgroundColor?: string;
34
- cryptoIconBackgroundColor: string;
35
34
  };
36
- export declare const AccountItem: ({ onClick, account, rightElement, showIcon, backgroundColor, cryptoIconBackgroundColor, }: AccountItemProps) => import("react/jsx-runtime").JSX.Element;
35
+ export declare const AccountItem: ({ onClick, account, rightElement, showIcon, backgroundColor, }: AccountItemProps) => import("react/jsx-runtime").JSX.Element;
37
36
  //# sourceMappingURL=AccountItem.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AccountItem.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/AccountItem/AccountItem.tsx"],"names":[],"mappings":"AAUA,MAAM,MAAM,SAAS,GAAG;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,IAAI,EAAE,OAAO,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,UAAU,CAAC;IACjB,QAAQ,EAAE;QACR,OAAO,EAAE,OAAO,CAAC;QACjB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;QACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;KACpB,CAAC;CACH,CAAC;AAEF,MA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H,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,YAAY,GAAG,iBAAiB,GAAG,oBAAoB,GAAG,gBAAgB,CAAC;AAEvF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,OAAO,EAAE,SAAS,CAAC;IACnB,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAkGF,eAAO,MAAM,WAAW,GAAI,gEAMzB,gBAAgB,4CA8FlB,CAAC"}
@@ -64,7 +64,7 @@ const RightElementContainer = styled(View) `
64
64
  const RightElementRenderer = ({ rightElement, tokens, onEditPress }) => {
65
65
  return (_jsxs(RightElementContainer, { style: { marginLeft: Number(tokens["spacing-xs"]) }, children: [rightElement.type === "checkbox" && (_jsx(View, { testID: "right-element-checkbox", children: _jsx(Checkbox, { checked: rightElement.checkbox.checked, onChange: rightElement.checkbox.onChange, disabled: rightElement.checkbox.disabled }) })), rightElement.type === "arrow" && (_jsx(View, { testID: "right-element-arrow-icon", children: _jsx(ChevronRightMedium, { size: 24, color: String(tokens["colors-content-default-default"]) }) })), rightElement.type === "edit" && (_jsx(IconButton, { onPress: onEditPress, testID: "right-element-edit-icon", children: _jsx(PenMedium, { size: 16, color: String(tokens["colors-content-default-default"]) }) }))] }));
66
66
  };
67
- export const AccountItem = ({ onClick, account, rightElement, showIcon = true, backgroundColor, cryptoIconBackgroundColor, }) => {
67
+ export const AccountItem = ({ onClick, account, rightElement, showIcon = true, backgroundColor, }) => {
68
68
  const theme = useTheme();
69
69
  const colorType = theme.colors.type === "dark" ? "dark" : "light";
70
70
  const tokens = useTokens(colorType, [
@@ -92,5 +92,5 @@ export const AccountItem = ({ onClick, account, rightElement, showIcon = true, b
92
92
  paddingTop: onClick ? Number(tokens["margin-s"]) : 0,
93
93
  borderRadius: onClick ? Number(tokens["radius-s"]) : 0,
94
94
  opacity: pressed && onClick ? 0.7 : 1,
95
- }), testID: "account-item", children: _jsxs(ContentContainer, { children: [_jsxs(AccountInfoContainer, { children: [_jsxs(NameRow, { style: { marginBottom: Number(tokens["spacing-xxxs"]) }, children: [_jsx(NameWrapper, { children: _jsx(Text, { variant: "largeLineHeight", fontWeight: "semiBold", color: String(tokens["colors-content-default-default"]), fontSize: "18px", numberOfLines: 1, ellipsizeMode: "tail", testID: `account-item-name-${name}`, children: name }) }), protocol && (_jsx(TagWrapper, { style: { marginLeft: Number(tokens["spacing-xs"]) }, children: _jsx(Tag, { textTransform: "uppercase", children: protocol }) }))] }), _jsx(Address, { address: address, cryptoId: cryptoId, ticker: ticker, parentId: parentId, showIcon: showIcon, backgroundColor: cryptoIconBackgroundColor })] }), _jsxs(BalanceContainer, { style: { gap: Number(tokens["spacing-xxxs"]) }, children: [fiatValue && (_jsx(Text, { fontSize: "18px", color: String(tokens["colors-content-default-default"]), children: fiatValue })), balance && (_jsx(Text, { fontSize: "14px", color: String(tokens["colors-content-subdued-default-default"]), children: balance }))] }), rightElement && (_jsx(RightElementRenderer, { rightElement: rightElement, tokens: tokens, onEditPress: handleEditPress }))] }) }));
95
+ }), testID: "account-item", children: _jsxs(ContentContainer, { children: [_jsxs(AccountInfoContainer, { children: [_jsxs(NameRow, { style: { marginBottom: Number(tokens["spacing-xxxs"]) }, children: [_jsx(NameWrapper, { children: _jsx(Text, { variant: "largeLineHeight", fontWeight: "semiBold", color: String(tokens["colors-content-default-default"]), fontSize: "18px", numberOfLines: 1, ellipsizeMode: "tail", testID: `account-item-name-${name}`, children: name }) }), protocol && (_jsx(TagWrapper, { style: { marginLeft: Number(tokens["spacing-xs"]) }, children: _jsx(Tag, { textTransform: "uppercase", children: protocol }) }))] }), _jsx(Address, { address: address, cryptoId: cryptoId, ticker: ticker, parentId: parentId, showIcon: showIcon })] }), _jsxs(BalanceContainer, { style: { gap: Number(tokens["spacing-xxxs"]) }, children: [fiatValue && (_jsx(Text, { fontSize: "18px", color: String(tokens["colors-content-default-default"]), children: fiatValue })), balance && (_jsx(Text, { fontSize: "14px", color: String(tokens["colors-content-subdued-default-default"]), children: balance }))] }), rightElement && (_jsx(RightElementRenderer, { rightElement: rightElement, tokens: tokens, onEditPress: handleEditPress }))] }) }));
96
96
  };
@@ -1,9 +1,8 @@
1
- export declare const Address: ({ address, showIcon, cryptoId, ticker, parentId, backgroundColor, }: {
1
+ export declare const Address: ({ address, showIcon, cryptoId, ticker, parentId, }: {
2
2
  address: string;
3
3
  showIcon: boolean;
4
4
  cryptoId?: string;
5
5
  ticker?: string;
6
6
  parentId?: string;
7
- backgroundColor: string;
8
7
  }) => import("react/jsx-runtime").JSX.Element;
9
8
  //# sourceMappingURL=Address.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Address.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/Address/Address.tsx"],"names":[],"mappings":"AAYA,eAAO,MAAM,OAAO,GAAI,qEAOrB;IACD,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;CACzB,4CA0BA,CAAC"}
1
+ {"version":3,"file":"Address.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/Address/Address.tsx"],"names":[],"mappings":"AAYA,eAAO,MAAM,OAAO,GAAI,oDAMrB;IACD,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,4CAmBA,CAAC"}
@@ -8,9 +8,9 @@ const Wrapper = styled(View) `
8
8
  flex-direction: row;
9
9
  align-items: center;
10
10
  `;
11
- export const Address = ({ address, showIcon, cryptoId, ticker, parentId, backgroundColor, }) => {
11
+ export const Address = ({ address, showIcon, cryptoId, ticker, parentId, }) => {
12
12
  const { theme } = useTheme();
13
13
  const colorType = theme;
14
14
  const tokens = useTokens(colorType, ["spacing-xxxs", "colors-content-subdued-default-default"]);
15
- return (_jsxs(Wrapper, { children: [_jsx(Text, { fontSize: "14px", color: String(tokens["colors-content-subdued-default-default"]), marginRight: showIcon ? Number(tokens["spacing-xxxs"]) : 0, children: address }), showIcon && (_jsx(CryptoIcon, { ledgerId: cryptoId, network: parentId, ticker: ticker, size: 20, theme: theme, backgroundColor: backgroundColor }))] }));
15
+ return (_jsxs(Wrapper, { children: [_jsx(Text, { fontSize: "14px", color: String(tokens["colors-content-subdued-default-default"]), marginRight: showIcon ? Number(tokens["spacing-xxxs"]) : 0, children: address }), showIcon && cryptoId && ticker && (_jsx(CryptoIcon, { ledgerId: cryptoId, network: parentId, ticker: ticker, size: 20 }))] }));
16
16
  };
@@ -1 +1 @@
1
- {"version":3,"file":"CryptoIcon.stories.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/CryptoIcon/CryptoIcon.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,EAAE,KAAK,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CAoBjC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAC;AAEzC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC"}
1
+ {"version":3,"file":"CryptoIcon.stories.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/CryptoIcon/CryptoIcon.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,EAAE,KAAK,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CAmBjC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAC;AAEzC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC"}
@@ -7,7 +7,6 @@ const meta = {
7
7
  ledgerId: "bitcoin",
8
8
  ticker: "BTC",
9
9
  size: 56,
10
- backgroundColor: "red",
11
10
  network: "",
12
11
  },
13
12
  argTypes: {
@@ -37,5 +37,5 @@ export const NetworkItem = ({ name, onClick, id, ticker, leftElement, rightEleme
37
37
  const tokens = useTokens(colorType, [...TOKEN_KEYS]);
38
38
  return (_jsxs(Wrapper, { tokens: tokens, onPress: onClick, style: ({ pressed }) => ({
39
39
  opacity: pressed ? 0.7 : 1,
40
- }), testID: `network-item-${name}`, children: [_jsx(CryptoIcon, { size: 48, overridesRadius: 12, ledgerId: id, ticker: ticker }), _jsxs(InfoWrapper, { tokens: tokens, children: [_jsx(Text, { variant: "largeLineHeight", fontWeight: "semiBold", color: String(tokens["colors-content-default-default"]), children: name }), _jsx(LeftElementWrapper, { children: leftElement })] }), rightElement] }));
40
+ }), testID: `network-item-${name}`, children: [_jsx(CryptoIcon, { size: 48, shape: "square", ledgerId: id, ticker: ticker }), _jsxs(InfoWrapper, { tokens: tokens, children: [_jsx(Text, { variant: "largeLineHeight", fontWeight: "semiBold", color: String(tokens["colors-content-default-default"]), children: name }), _jsx(LeftElementWrapper, { children: leftElement })] }), rightElement] }));
41
41
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ledgerhq/native-ui",
3
- "version": "0.61.0",
3
+ "version": "0.61.1-nightly.20260428030635",
4
4
  "description": "Ledger Live - Mobile UI",
5
5
  "repository": {
6
6
  "type": "git",
@@ -54,7 +54,7 @@
54
54
  "lib/**/*"
55
55
  ],
56
56
  "dependencies": {
57
- "@ledgerhq/crypto-icons": "1.4.0",
57
+ "@ledgerhq/crypto-icons": "2.0.1",
58
58
  "color": "^4.0.0",
59
59
  "styled-system": "5.1.5",
60
60
  "stylis": "4.0.0",
@@ -62,6 +62,8 @@
62
62
  "@ledgerhq/ui-shared": "^0.5.0"
63
63
  },
64
64
  "peerDependencies": {
65
+ "@ledgerhq/lumen-design-core": ">=0.1.11",
66
+ "@ledgerhq/lumen-ui-rnative": ">=0.1.25",
65
67
  "react": ">=17",
66
68
  "react-native": ">=0.64.0",
67
69
  "react-native-reanimated": ">=4.1",
@@ -86,6 +88,8 @@
86
88
  "@emotion/native": "^11.0.0",
87
89
  "@expo/cli": "0.24.14",
88
90
  "@expo/metro-config": "^0.19.11",
91
+ "@ledgerhq/lumen-design-core": "0.1.11",
92
+ "@ledgerhq/lumen-ui-rnative": "0.1.25",
89
93
  "@rsbuild/core": "1.7.2",
90
94
  "@rsbuild/plugin-react": "1.4.3",
91
95
  "@react-native-async-storage/async-storage": "2.1.2",
@@ -175,7 +179,7 @@
175
179
  "scripts": {
176
180
  "android": "expo start --android",
177
181
  "build": "tsc -p tsconfig.prod.json && node scripts/postBuild",
178
- "prebuild:storybook": "pnpm -F ui-shared -F icons-ui -F crypto-icons-ui build",
182
+ "prebuild:storybook": "nx run-many -t build -p @ledgerhq/ui-shared,@ledgerhq/icons-ui,@ledgerhq/crypto-icons-ui",
179
183
  "build:storybook": "NODE_PATH=./node_modules storybook build -c .storybook-web",
180
184
  "watch": "tsc -p tsconfig.prod.json --watch",
181
185
  "clean": "rimraf lib",