@xylabs/sdk-react 2.9.33 → 2.9.36

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.
Files changed (57) hide show
  1. package/dist/cjs5/components/EthAccount/EthAccount.stories.d.ts +3 -1
  2. package/dist/cjs5/components/EthAccount/EthAccountProps.d.ts +1 -0
  3. package/dist/cjs5/components/LinkEx/LinkToEx.d.ts +4 -2
  4. package/dist/cjs5/components/LinkEx/index.d.ts +1 -2
  5. package/dist/cjs5/index.js +12 -4
  6. package/dist/cjs5/index.js.map +1 -1
  7. package/dist/components/BasePage/BasePage.stories.js +2 -1
  8. package/dist/components/BasePage/BasePage.stories.js.map +1 -1
  9. package/dist/components/EthAccount/EthAccount.js +2 -2
  10. package/dist/components/EthAccount/EthAccount.js.map +1 -1
  11. package/dist/components/EthAccount/EthAccount.stories.d.ts +3 -1
  12. package/dist/components/EthAccount/EthAccount.stories.js +18 -1
  13. package/dist/components/EthAccount/EthAccount.stories.js.map +1 -1
  14. package/dist/components/EthAccount/EthAccountProps.d.ts +1 -0
  15. package/dist/components/LinkEx/LinkToEx.d.ts +4 -2
  16. package/dist/components/LinkEx/LinkToEx.js +10 -3
  17. package/dist/components/LinkEx/LinkToEx.js.map +1 -1
  18. package/dist/components/LinkEx/index.d.ts +1 -2
  19. package/dist/components/LinkEx/index.js +1 -2
  20. package/dist/components/LinkEx/index.js.map +1 -1
  21. package/dist/esm2015/components/EthAccount/EthAccount.stories.d.ts +3 -1
  22. package/dist/esm2015/components/EthAccount/EthAccountProps.d.ts +1 -0
  23. package/dist/esm2015/components/LinkEx/LinkToEx.d.ts +4 -2
  24. package/dist/esm2015/components/LinkEx/index.d.ts +1 -2
  25. package/dist/esm2015/index.js +12 -5
  26. package/dist/esm2015/index.js.map +1 -1
  27. package/dist/esm2017/components/EthAccount/EthAccount.stories.d.ts +3 -1
  28. package/dist/esm2017/components/EthAccount/EthAccountProps.d.ts +1 -0
  29. package/dist/esm2017/components/LinkEx/LinkToEx.d.ts +4 -2
  30. package/dist/esm2017/components/LinkEx/index.d.ts +1 -2
  31. package/dist/esm2017/index.js +12 -5
  32. package/dist/esm2017/index.js.map +1 -1
  33. package/dist/esm5/components/EthAccount/EthAccount.stories.d.ts +3 -1
  34. package/dist/esm5/components/EthAccount/EthAccountProps.d.ts +1 -0
  35. package/dist/esm5/components/LinkEx/LinkToEx.d.ts +4 -2
  36. package/dist/esm5/components/LinkEx/index.d.ts +1 -2
  37. package/dist/esm5/index.js +12 -5
  38. package/dist/esm5/index.js.map +1 -1
  39. package/dist/node/components/EthAccount/EthAccount.stories.d.ts +3 -1
  40. package/dist/node/components/EthAccount/EthAccountProps.d.ts +1 -0
  41. package/dist/node/components/LinkEx/LinkToEx.d.ts +4 -2
  42. package/dist/node/components/LinkEx/index.d.ts +1 -2
  43. package/dist/node/index.js +12 -4
  44. package/dist/node/index.js.map +1 -1
  45. package/dist/node-esm/components/EthAccount/EthAccount.stories.d.ts +3 -1
  46. package/dist/node-esm/components/EthAccount/EthAccountProps.d.ts +1 -0
  47. package/dist/node-esm/components/LinkEx/LinkToEx.d.ts +4 -2
  48. package/dist/node-esm/components/LinkEx/index.d.ts +1 -2
  49. package/dist/node-esm/index.js +12 -5
  50. package/dist/node-esm/index.js.map +1 -1
  51. package/package.json +15 -12
  52. package/src/components/BasePage/BasePage.stories.tsx +6 -1
  53. package/src/components/EthAccount/EthAccount.stories.tsx +20 -1
  54. package/src/components/EthAccount/EthAccount.tsx +2 -1
  55. package/src/components/EthAccount/EthAccountProps.tsx +1 -0
  56. package/src/components/LinkEx/LinkToEx.tsx +11 -4
  57. package/src/components/LinkEx/index.ts +1 -3
@@ -9,7 +9,7 @@ import { ButtonEx } from '../ButtonEx';
9
9
  import { FlexGrowRow, FlexRow } from '../FlexBox';
10
10
  import { Identicon } from '../Identicon';
11
11
  const EthAccount = (_a) => {
12
- var { address, icon = false, iconSize = 16, iconOnly = false, addressLength = 'auto', fontFamily = '"Source Code Pro",monospace', toEtherScan, onButtonClick } = _a, props = __rest(_a, ["address", "icon", "iconSize", "iconOnly", "addressLength", "fontFamily", "toEtherScan", "onButtonClick"]);
12
+ var { address, icon = false, iconSize = 16, iconOnly = false, shortenedLength, addressLength = 'auto', fontFamily = '"Source Code Pro",monospace', toEtherScan, onButtonClick } = _a, props = __rest(_a, ["address", "icon", "iconSize", "iconOnly", "shortenedLength", "addressLength", "fontFamily", "toEtherScan", "onButtonClick"]);
13
13
  const { localAddress } = useContext(EthersContext);
14
14
  const theme = useTheme();
15
15
  const large = useMediaQuery(theme.breakpoints.up('md'));
@@ -24,7 +24,7 @@ const EthAccount = (_a) => {
24
24
  const testToDisplay = addressLength === 'long'
25
25
  ? addressToDisplay.toString()
26
26
  : addressLength === 'short'
27
- ? addressToDisplay.toShortString()
27
+ ? addressToDisplay.toShortString(shortenedLength)
28
28
  : large
29
29
  ? addressToDisplay.toString()
30
30
  : addressToDisplay.toShortString();
@@ -1 +1 @@
1
- {"version":3,"file":"EthAccount.js","sourceRoot":"","sources":["../../../src/components/EthAccount/EthAccount.tsx"],"names":[],"mappings":";;AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACpD,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AACrD,OAAO,EAAc,UAAU,EAAE,MAAM,OAAO,CAAA;AAE9C,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAA;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AACtC,OAAO,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAGxC,MAAM,UAAU,GAA8B,CAAC,EAU9C,EAAE,EAAE;QAV0C,EAC7C,OAAO,EACP,IAAI,GAAG,KAAK,EACZ,QAAQ,GAA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Aa,YACH,EACZ,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAChB,KAAC,UAAU,kBAAC,QAAQ,EAAC,UAAU,EAAC,UAAU,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,EAAC,OAAO,EAAC,UAAU,EAAE,UAAU,mCAEnF,CACd,YACO,CACX,EACA,cAAc,CAAC,CAAC,CAAC,KAAC,OAAO,kBAAC,UAAU,EAAE,GAAG,mCAAiB,CAAC,CAAC,CAAC,IAAI,aACtD,YACL,CACZ,CAAA;AACH,CAAC,CAAA;AAED,OAAO,EAAE,UAAU,EAAE,CAAA"}
@@ -3,9 +3,11 @@ import { ComponentMeta, ComponentStory } from '@storybook/react';
3
3
  declare const StorybookEntry: ComponentMeta<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
4
4
  declare const Long: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
5
5
  declare const LongEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
6
+ declare const Medium: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
7
+ declare const MediumEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
6
8
  declare const Short: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
7
9
  declare const ShortEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
8
10
  declare const Auto: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
9
11
  declare const AutoEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
10
- export { Auto, AutoEmpty, Long, LongEmpty, Short, ShortEmpty };
12
+ export { Auto, AutoEmpty, Long, LongEmpty, Medium, MediumEmpty, Short, ShortEmpty };
11
13
  export default StorybookEntry;
@@ -28,6 +28,23 @@ LongEmpty.args = {
28
28
  title: 'Sample EthAccount',
29
29
  toEtherScan: true,
30
30
  };
31
+ const Medium = Template.bind({});
32
+ Medium.args = {
33
+ address: EthAddress.fromString('0x6792b02f88b32c4fe8e31cfa41ae5af44865f930'),
34
+ addressLength: 'short',
35
+ icon: true,
36
+ shortenedLength: 8,
37
+ title: 'Sample EthAccount',
38
+ toEtherScan: true,
39
+ };
40
+ const MediumEmpty = Template.bind({});
41
+ MediumEmpty.args = {
42
+ addressLength: 'short',
43
+ icon: true,
44
+ shortenedLength: 8,
45
+ title: 'Sample EthAccount',
46
+ toEtherScan: true,
47
+ };
31
48
  const Short = Template.bind({});
32
49
  Short.args = {
33
50
  address: EthAddress.fromString('0x6792b02f88b32c4fe8e31cfa41ae5af44865f930'),
@@ -58,7 +75,7 @@ AutoEmpty.args = {
58
75
  title: 'Sample EthAccount',
59
76
  toEtherScan: true,
60
77
  };
61
- export { Auto, AutoEmpty, Long, LongEmpty, Short, ShortEmpty };
78
+ export { Auto, AutoEmpty, Long, LongEmpty, Medium, MediumEmpty, Short, ShortEmpty };
62
79
  // eslint-disable-next-line import/no-default-export
63
80
  export default StorybookEntry;
64
81
  //# sourceMappingURL=EthAccount.stories.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"EthAccount.stories.js","sourceRoot":"","sources":["../../../src/components/EthAccount/EthAccount.stories.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAE3C,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAEzC,MAAM,cAAc,GAAG;IACrB,QAAQ,EAAE,EAAE;IACZ,SAAS,EAAE,UAAU;IACrB,UAAU,EAAE;QACV,IAAI,EAAE;YACJ,IAAI,EAAE,IAAI;SACX;KACF;IACD,KAAK,EAAE,uBAAuB;CACK,CAAA;AAErC,MAAM,QAAQ,GAAsC,CAAC,IAAI,EAAE,EAAE,CAAC,CAC5D,KAAC,OAAO,cACN,KAAC,UAAU,kBAAC,OAAO,EAAC,UA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I;CAClB,CAAA;AAED,MAAM,SAAS,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AACnC,SAAS,CAAC,IAAI,GAAG;IACf,aAAa,EAAE,MAAM;IACrB,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,mBAAmB;IAC1B,WAAW,EAAE,IAAI;CAClB,CAAA;AAED,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,UAAU,EAAE,CAAA;AAE9D,oDAAoD;AACpD,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"EthAccount.stories.js","sourceRoot":"","sources":["../../../src/components/EthAccount/EthAccount.stories.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAE3C,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAEzC,MAAM,cAAc,GAAG;IACrB,QAAQ,EAAE,EAAE;IACZ,SAAS,EAAE,UAAU;IACrB,UAAU,EAAE;QACV,IAAI,EAAE;YACJ,IAAI,EAAE,IAAI;SACX;KACF;IACD,KAAK,EAAE,uBAAuB;CACK,CAAA;AAErC,MAAM,QAAQ,GAAsC,CAAC,IAAI,EAAE,EAAE,CAAC,CAC5D,KAAC,OAAO,cACN,KAAC,UAAU,kBAAC,OAAO,EAAC,UAAU,IAAK,IAAI,UAAe,WAC9C,CACX,CAAA;AAED,MAAM,IAAI,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAC9B,IAAI,CAAC,IAAI,GAAG;IACV,OAAO,EAAE,UAAU,CAAC,UAAU,CAAC,4CAA4C,CAAC;IAC5E,aAAa,EAAE,MAAM;IACrB,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,mBAAmB;IAC1B,WAAW,EAAE,IAAI;CAClB,CAAA;AAED,MAAM,SAAS,GAAG,QAAQ,CAAC,IA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IAAI,CAAC,IAAI,GAAG;IACV,OAAO,EAAE,UAAU,CAAC,UAAU,CAAC,4CAA4C,CAAC;IAC5E,aAAa,EAAE,MAAM;IACrB,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,mBAAmB;IAC1B,WAAW,EAAE,IAAI;CAClB,CAAA;AAED,MAAM,SAAS,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AACnC,SAAS,CAAC,IAAI,GAAG;IACf,aAAa,EAAE,MAAM;IACrB,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,mBAAmB;IAC1B,WAAW,EAAE,IAAI;CAClB,CAAA;AAED,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,KAAK,EAAE,UAAU,EAAE,CAAA;AAEnF,oDAAoD;AACpD,eAAe,cAAc,CAAA"}
@@ -4,6 +4,7 @@ import { ButtonExProps } from '../ButtonEx';
4
4
  interface EthAccountProps extends ButtonExProps {
5
5
  address?: EthAddress | null;
6
6
  addressLength?: 'auto' | 'short' | 'long';
7
+ shortenedLength?: number;
7
8
  full?: boolean;
8
9
  icon?: boolean;
9
10
  iconSize?: number;
@@ -2,7 +2,9 @@ import { LinkProps } from '@mui/material';
2
2
  import React from 'react';
3
3
  import { To } from 'react-router-dom';
4
4
  interface Props extends LinkProps {
5
- to: To;
5
+ to?: To;
6
6
  }
7
+ declare const LinkEx: React.FC<Props>;
8
+ /** @deprecated use LinkEx instead */
7
9
  declare const LinkToEx: React.FC<Props>;
8
- export { LinkToEx };
10
+ export { LinkEx, LinkToEx };
@@ -2,9 +2,16 @@ import { __rest } from "tslib";
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import { Link } from '@mui/material';
4
4
  import { Link as RouterLink } from 'react-router-dom';
5
- const LinkToEx = (_a) => {
5
+ const LinkEx = (_a) => {
6
6
  var { to } = _a, props = __rest(_a, ["to"]);
7
- return _jsx(Link, Object.assign({ component: RouterLink, to: to }, props), void 0);
7
+ if (to) {
8
+ return _jsx(Link, Object.assign({ component: RouterLink, to: to }, props), void 0);
9
+ }
10
+ else {
11
+ return _jsx(Link, Object.assign({}, props), void 0);
12
+ }
8
13
  };
9
- export { LinkToEx };
14
+ /** @deprecated use LinkEx instead */
15
+ const LinkToEx = LinkEx;
16
+ export { LinkEx, LinkToEx };
10
17
  //# sourceMappingURL=LinkToEx.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LinkToEx.js","sourceRoot":"","sources":["../../../src/components/LinkEx/LinkToEx.tsx"],"names":[],"mappings":";;AAAA,OAAO,EAAE,IAAI,EAAa,MAAM,eAAe,CAAA;AAE/C,OAAO,EAAE,IAAI,IAAI,UAAU,EAAM,MAAM,kBAAkB,CAAA;AAMzD,MAAM,QAAQ,GAAoB,CAAC,EAAgB,EAAE,EAAE;QAApB,EAAE,EAAE,OAAY,EAAP,KAAK,cAAd,MAAgB,CAAF;IAC/C,OAAO,KAAC,IAAI,kBAAC,SAAS,EAAE,UAAU,EAAE,EAAE,EAAE,EAAE,IAAM,KAAK,UAAI,CAAA;AAC3D,CAAC,CAAA;AAED,OAAO,EAAE,QAAQ,EAAE,CAAA"}
1
+ {"version":3,"file":"LinkToEx.js","sourceRoot":"","sources":["../../../src/components/LinkEx/LinkToEx.tsx"],"names":[],"mappings":";;AAAA,OAAO,EAAE,IAAI,EAAa,MAAM,eAAe,CAAA;AAE/C,OAAO,EAAE,IAAI,IAAI,UAAU,EAAM,MAAM,kBAAkB,CAAA;AAMzD,MAAM,MAAM,GAAoB,CAAC,EAAgB,EAAE,EAAE;QAApB,EAAE,EAAE,OAAY,EAAP,KAAK,cAAd,MAAgB,CAAF;IAC7C,IAAI,EAAE,EAAE;QACN,OAAO,KAAC,IAAI,kBAAC,SAAS,EAAE,UAAU,EAAE,EAAE,EAAE,EAAE,IAAM,KAAK,UAAI,CAAA;KAC1D;SAAM;QACL,OAAO,KAAC,IAAI,oBAAK,KAAK,UAAI,CAAA;KAC3B;AACH,CAAC,CAAA;AAED,qCAAqC;AACrC,MAAM,QAAQ,GAAG,MAAM,CAAA;AAEvB,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAA"}
@@ -1,2 +1 @@
1
- import { LinkToEx } from './LinkToEx';
2
- export { LinkToEx };
1
+ export * from './LinkToEx';
@@ -1,3 +1,2 @@
1
- import { LinkToEx } from './LinkToEx';
2
- export { LinkToEx };
1
+ export * from './LinkToEx';
3
2
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/LinkEx/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAA;AAErC,OAAO,EAAE,QAAQ,EAAE,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/LinkEx/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA"}
@@ -3,9 +3,11 @@ import { ComponentMeta, ComponentStory } from '@storybook/react';
3
3
  declare const StorybookEntry: ComponentMeta<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
4
4
  declare const Long: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
5
5
  declare const LongEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
6
+ declare const Medium: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
7
+ declare const MediumEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
6
8
  declare const Short: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
7
9
  declare const ShortEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
8
10
  declare const Auto: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
9
11
  declare const AutoEmpty: ComponentStory<import("react").FC<import("./EthAccountProps").EthAccountProps>>;
10
- export { Auto, AutoEmpty, Long, LongEmpty, Short, ShortEmpty };
12
+ export { Auto, AutoEmpty, Long, LongEmpty, Medium, MediumEmpty, Short, ShortEmpty };
11
13
  export default StorybookEntry;
@@ -4,6 +4,7 @@ import { ButtonExProps } from '../ButtonEx';
4
4
  interface EthAccountProps extends ButtonExProps {
5
5
  address?: EthAddress | null;
6
6
  addressLength?: 'auto' | 'short' | 'long';
7
+ shortenedLength?: number;
7
8
  full?: boolean;
8
9
  icon?: boolean;
9
10
  iconSize?: number;
@@ -2,7 +2,9 @@ import { LinkProps } from '@mui/material';
2
2
  import React from 'react';
3
3
  import { To } from 'react-router-dom';
4
4
  interface Props extends LinkProps {
5
- to: To;
5
+ to?: To;
6
6
  }
7
+ declare const LinkEx: React.FC<Props>;
8
+ /** @deprecated use LinkEx instead */
7
9
  declare const LinkToEx: React.FC<Props>;
8
- export { LinkToEx };
10
+ export { LinkEx, LinkToEx };
@@ -1,2 +1 @@
1
- import { LinkToEx } from './LinkToEx';
2
- export { LinkToEx };
1
+ export * from './LinkToEx';
@@ -1947,7 +1947,7 @@ function useWindowSize() {
1947
1947
  }
1948
1948
 
1949
1949
  const EthAccount = (_a) => {
1950
- var { address, icon = false, iconSize = 16, iconOnly = false, addressLength = 'auto', fontFamily = '"Source Code Pro",monospace', toEtherScan, onButtonClick } = _a, props = __rest(_a, ["address", "icon", "iconSize", "iconOnly", "addressLength", "fontFamily", "toEtherScan", "onButtonClick"]);
1950
+ var { address, icon = false, iconSize = 16, iconOnly = false, shortenedLength, addressLength = 'auto', fontFamily = '"Source Code Pro",monospace', toEtherScan, onButtonClick } = _a, props = __rest(_a, ["address", "icon", "iconSize", "iconOnly", "shortenedLength", "addressLength", "fontFamily", "toEtherScan", "onButtonClick"]);
1951
1951
  const { localAddress } = useContext(EthersContext);
1952
1952
  const theme = useTheme();
1953
1953
  const large = useMediaQuery(theme.breakpoints.up('md'));
@@ -1962,7 +1962,7 @@ const EthAccount = (_a) => {
1962
1962
  const testToDisplay = addressLength === 'long'
1963
1963
  ? addressToDisplay.toString()
1964
1964
  : addressLength === 'short'
1965
- ? addressToDisplay.toShortString()
1965
+ ? addressToDisplay.toShortString(shortenedLength)
1966
1966
  : large
1967
1967
  ? addressToDisplay.toString()
1968
1968
  : addressToDisplay.toShortString();
@@ -2094,10 +2094,17 @@ const ExperimentsDebugger = (_a) => {
2094
2094
  }) }), void 0));
2095
2095
  };
2096
2096
 
2097
- const LinkToEx = (_a) => {
2097
+ const LinkEx = (_a) => {
2098
2098
  var { to } = _a, props = __rest(_a, ["to"]);
2099
- return jsx(Link, Object.assign({ component: Link$1, to: to }, props), void 0);
2099
+ if (to) {
2100
+ return jsx(Link, Object.assign({ component: Link$1, to: to }, props), void 0);
2101
+ }
2102
+ else {
2103
+ return jsx(Link, Object.assign({}, props), void 0);
2104
+ }
2100
2105
  };
2106
+ /** @deprecated use LinkEx instead */
2107
+ const LinkToEx = LinkEx;
2101
2108
 
2102
2109
  const MenuEx = (_a) => {
2103
2110
  var { MenuListProps = {}, mode = 'light', colorize } = _a, props = __rest(_a, ["MenuListProps", "mode", "colorize"]);
@@ -2277,5 +2284,5 @@ const TokenAmount = (_a) => {
2277
2284
  return (jsx(ButtonEx, Object.assign({ style: Object.assign({ backgroundColor: statusColor }, style), variant: "outlined", onClick: onButtonClick }, props, { children: jsxs(FlexRow, Object.assign({ justifyContent: "space-between", width: "100%", busy: amount === undefined, busySize: 16 }, { children: [jsxs(FlexRow, { children: [logo ? jsx("img", { src: img, height: 24 }, void 0) : null, label ? (jsx(Typography, Object.assign({ marginRight: 1, marginLeft: logo ? 1 : 0, noWrap: true, fontFamily: textFontFamily, variant: "caption" }, { children: label }), void 0)) : null] }, void 0), jsx(Typography, Object.assign({ color: textColor, noWrap: true, fontFamily: textFontFamily, variant: "body1", style: { textTransform: 'none' } }, { children: amountString }), void 0)] }), void 0) }), void 0));
2278
2285
  };
2279
2286
 
2280
- export { ActionStatusType, AppBarEx, Background, BasePage, BreadcrumbsEx, BusyBox, ButtonEx, ContactPointOption, CookieConsent, CookieConsentBody, CookieConsentContext, CookieConsentLoader, CoverProgress, DebugUserEventsContext, DripCustomEvent, DripStandardEvents, ErrorDialog, EthAccount, EthersContext, EthersLoader, Experiment, Experiments, ExperimentsDebugger, FacebookCustomEvent, FacebookStandardEvents, Fbq, FlexCol, FlexGrowCol, FlexGrowRow, FlexRow, GoogleBaseEvent, GoogleCustomEvent, GoogleStandardEvents, GoogleUserEventHandler, Gtag, Gtm, HoverScale, Identicon, InvertableThemeProvider, ItemAvailability, LinkToEx, MapCategoryType, MenuEx, MessageDialog, NetworkSettingsContext, NetworkSettingsLoader, NumberStatus, PixelDebugger, PixelDebuggerProvider, PixelDebuggerToggle, Portal, QuickTipButton, Rdt, RedditCustomEvent, RedditStandardEvents, RedirectWithQuery, Referrer, RichResult, ScrollToTop, ScrollToTopButton, SelectEx, SnapTr, SnapchatStandardEvents, TiktokCustomEvent, TiktokStandardEvents, TokenAmount, Ttq, UserEventsContext, UserEventsLoader, XyBaseEvent, XyCustomEvent, XyUserEventHandler, XyoUserEventHandler, enableProfileLogging, getApiStage, getLocalStorageObject, getSessionStorageObject, isLocalhost, profileBlock, profileResults, resolveThemeColors, setLocalStorageObject, setSessionStorageObject, useAsyncEffect, useBreakpoint, useCookieConsent, useInterval, useLocalStorage, useMounted, useNavigateToEthAddress, useSpacing, useTimeout, useUserEvents, useWebP, useWindowSize };
2287
+ export { ActionStatusType, AppBarEx, Background, BasePage, BreadcrumbsEx, BusyBox, ButtonEx, ContactPointOption, CookieConsent, CookieConsentBody, CookieConsentContext, CookieConsentLoader, CoverProgress, DebugUserEventsContext, DripCustomEvent, DripStandardEvents, ErrorDialog, EthAccount, EthersContext, EthersLoader, Experiment, Experiments, ExperimentsDebugger, FacebookCustomEvent, FacebookStandardEvents, Fbq, FlexCol, FlexGrowCol, FlexGrowRow, FlexRow, GoogleBaseEvent, GoogleCustomEvent, GoogleStandardEvents, GoogleUserEventHandler, Gtag, Gtm, HoverScale, Identicon, InvertableThemeProvider, ItemAvailability, LinkEx, LinkToEx, MapCategoryType, MenuEx, MessageDialog, NetworkSettingsContext, NetworkSettingsLoader, NumberStatus, PixelDebugger, PixelDebuggerProvider, PixelDebuggerToggle, Portal, QuickTipButton, Rdt, RedditCustomEvent, RedditStandardEvents, RedirectWithQuery, Referrer, RichResult, ScrollToTop, ScrollToTopButton, SelectEx, SnapTr, SnapchatStandardEvents, TiktokCustomEvent, TiktokStandardEvents, TokenAmount, Ttq, UserEventsContext, UserEventsLoader, XyBaseEvent, XyCustomEvent, XyUserEventHandler, XyoUserEventHandler, enableProfileLogging, getApiStage, getLocalStorageObject, getSessionStorageObject, isLocalhost, profileBlock, profileResults, resolveThemeColors, setLocalStorageObject, setSessionStorageObject, useAsyncEffect, useBreakpoint, useCookieConsent, useInterval, useLocalStorage, useMounted, useNavigateToEthAddress, useSpacing, useTimeout, useUserEvents, useWebP, useWindowSize };
2281
2288
  //# sourceMappingURL=index.js.map