@stokr/components-library 4.0.1 → 4.1.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.
Files changed (76) hide show
  1. package/README.md +1 -1
  2. package/dist/components/AdminDashboard/Table/Table.styles.js +6 -2
  3. package/dist/components/BackButton/BackButton.js +10 -14
  4. package/dist/components/BackButton/BackButton.styles.js +7 -4
  5. package/dist/components/ChartLegend/ChartLegend.styles.js +4 -2
  6. package/dist/components/Checkbox/Checkbox.js +5 -1
  7. package/dist/components/Checkbox/Checkbox.styles.js +12 -27
  8. package/dist/components/Checklist/ChecklistCard.js +6 -6
  9. package/dist/components/Checklist/ChecklistCard.styles.js +0 -39
  10. package/dist/components/Chips/Chip.js +14 -1
  11. package/dist/components/Chips/Chip.styles.js +4 -3
  12. package/dist/components/CryptoAddress/CryptoAddress.styles.js +15 -94
  13. package/dist/components/CryptoAddressWrapper/CryptoAddressWrapper.styles.js +7 -10
  14. package/dist/components/FAQ/FAQ.styles.js +6 -2
  15. package/dist/components/IdentityInfo/IdentityInfo.styles.js +1 -1
  16. package/dist/components/InfoBox/InfoBox.js +4 -2
  17. package/dist/components/InfoIcon/InfoIcon.js +24 -28
  18. package/dist/components/InfoIcon/InfoIcon.styles.d.ts +1 -1
  19. package/dist/components/InfoIcon/InfoIcon.styles.js +4 -3
  20. package/dist/components/Input/InputPassword.js +2 -1
  21. package/dist/components/Input/Select.js +0 -2
  22. package/dist/components/Input/Select.styles.js +5 -2
  23. package/dist/components/MaterialIcon/MaterialIcon.d.ts +5 -3
  24. package/dist/components/MaterialIcon/MaterialIcon.js +9 -5
  25. package/dist/components/MaterialIcon/MaterialIcon.styles.d.ts +5 -5
  26. package/dist/components/MaterialIcon/MaterialIcon.styles.js +2 -2
  27. package/dist/components/MaterialIcon/glyph.d.ts +5 -0
  28. package/dist/components/MaterialIcon/glyph.js +8 -0
  29. package/dist/components/MaterialIcon/iconConfig.d.ts +1 -1
  30. package/dist/components/MaterialIcon/requiredIcons.d.ts +5 -0
  31. package/dist/components/MaterialIcon/requiredIcons.js +21 -0
  32. package/dist/components/Modal/Modal.js +27 -31
  33. package/dist/components/Modal/Modal.styles.d.ts +3 -3
  34. package/dist/components/Modal/Modal.styles.js +31 -51
  35. package/dist/components/Modal/PaymentModal.js +10 -3
  36. package/dist/components/Modal/SideModal.js +45 -49
  37. package/dist/components/Pagination/Pagination.js +3 -3
  38. package/dist/components/Payment/TimerComponent.js +2 -3
  39. package/dist/components/Process/Process.styles.js +13 -18
  40. package/dist/components/ProfileBox/ProfileBox.styles.js +8 -8
  41. package/dist/components/RequestDataBox/RequestDataBox.styles.js +2 -3
  42. package/dist/components/StatusTag/StatusTag.js +2 -2
  43. package/dist/components/TaxResidenceCard/TaxResidenceCard.js +0 -2
  44. package/dist/components/TaxResidenceCard/TaxResidenceCard.styles.js +4 -2
  45. package/dist/components/TextLink/TextLink.styles.js +11 -20
  46. package/dist/components/Timeline/Timeline.styles.js +1 -1
  47. package/dist/components/Timeline/TimelineStep.js +2 -2
  48. package/dist/index.d.ts +1 -4
  49. package/dist/index.js +32 -38
  50. package/dist/styles/global.js +0 -5
  51. package/dist/styles/rwd.d.ts +7 -2
  52. package/dist/styles/rwd.js +7 -2
  53. package/package.json +3 -4
  54. package/dist/components/Icon/Icon.style.js +0 -92
  55. package/dist/static/fonts/Ionicons/Ionicons.ttf +0 -0
  56. package/dist/static/fonts/Ionicons/Ionicons.ttf.js +0 -4
  57. package/dist/static/fonts/Ionicons/Ionicons.woff +0 -0
  58. package/dist/static/fonts/Ionicons/Ionicons.woff.js +0 -4
  59. package/dist/static/fonts/Ionicons/Ionicons.woff2 +0 -0
  60. package/dist/static/fonts/Ionicons/Ionicons.woff2.js +0 -4
  61. package/dist/static/fonts/Ionicons/ionicons.min.css +0 -2810
  62. package/dist/static/fonts/Ionicons/ionicons.min.css.js +0 -4
  63. package/dist/static/fonts/icomoon/icomoon.eot +0 -0
  64. package/dist/static/fonts/icomoon/icomoon.eot.js +0 -4
  65. package/dist/static/fonts/icomoon/icomoon.svg +0 -53
  66. package/dist/static/fonts/icomoon/icomoon.svg.js +0 -4
  67. package/dist/static/fonts/icomoon/icomoon.ttf +0 -0
  68. package/dist/static/fonts/icomoon/icomoon.ttf.js +0 -4
  69. package/dist/static/fonts/icomoon/icomoon.woff +0 -0
  70. package/dist/static/fonts/icomoon/icomoon.woff.js +0 -4
  71. package/dist/static/fonts/icomoon/selection.json +0 -910
  72. package/dist/static/fonts/icomoon/style.css +0 -139
  73. package/dist/static/images/copy_icon.svg +0 -4
  74. package/dist/static/images/copy_icon.svg.js +0 -5
  75. package/dist/styles/fonts.js +0 -35
  76. package/dist/styles/ioniconsStyles.js +0 -34
@@ -1,5 +1,6 @@
1
1
  import styled from "styled-components";
2
2
  import theme from "../../styles/theme.js";
3
+ import { glyph } from "../MaterialIcon/glyph.js";
3
4
  const CONTAINER_OWN_PROPS = ["noMargin", "noMarginLeft", "noMarginRight", "fullWidth"];
4
5
  const Container = styled.div.withConfig({
5
6
  shouldForwardProp: (prop) => !CONTAINER_OWN_PROPS.includes(prop)
@@ -22,15 +23,15 @@ const Container = styled.div.withConfig({
22
23
  justify-content: center;
23
24
  `}
24
25
  `;
25
- const Icon = styled.i.withConfig({
26
+ const Icon = styled.span.withConfig({
26
27
  shouldForwardProp: (prop) => prop !== "outline"
27
28
  }).attrs((props) => ({
28
- className: props.outline ? "ion ion-md-information-circle-outline" : "ion ion-md-information-circle"
29
+ children: glyph("info", !props.outline)
29
30
  }))`
30
31
  position: relative;
31
32
  left: -0.4px;
32
33
 
33
- display: inline-block;
34
+ display: inline-flex;
34
35
  vertical-align: middle;
35
36
  font-size: 16px;
36
37
  line-height: 16px;
@@ -6,6 +6,7 @@ import { InfoIcon } from "../InfoIcon/InfoIcon.js";
6
6
  import { Wrapper, Label, InputWrap } from "./Input.styles.js";
7
7
  import { getPasswordEntropy, ENTROPY_WEAK, ENTROPY_MEDIUM } from "../../utils/password-validation.js";
8
8
  import { InfoIconWrapper, ShowPassword, BottomWrap, PasswordStrengthWrap, PasswordStrengthIndicators, PasswordStrengthIndicator, PasswordStrengthText, CapslockIndicator } from "./InputPassword.styles.js";
9
+ import { MaterialIcon } from "../MaterialIcon/MaterialIcon.js";
9
10
  const PasswordStrength = {
10
11
  NONE: "none",
11
12
  WEAK: "Weak",
@@ -87,7 +88,7 @@ const InputPassword = (props) => {
87
88
  onClick: togglePasswordVisibility,
88
89
  "aria-label": isPasswordVisible ? "Hide password" : "Show password",
89
90
  "data-cy": toggleDataCy ?? `${id}-password-visibility-toggle`,
90
- children: isPasswordVisible ? /* @__PURE__ */ jsx("i", { className: "ion ion-md-eye-off" }) : /* @__PURE__ */ jsx("i", { className: "ion ion-md-eye" })
91
+ children: /* @__PURE__ */ jsx(MaterialIcon, { name: isPasswordVisible ? "visibility_off" : "visibility", size: "1em" })
91
92
  }
92
93
  ),
93
94
  /* @__PURE__ */ jsxs(BottomWrap, { children: [
@@ -4,7 +4,6 @@ import { Wrapper, Label } from "./Input.styles.js";
4
4
  import { useState, useMemo } from "react";
5
5
  import CreatableSelect from "react-select/creatable";
6
6
  import ReactSelect, { components } from "react-select";
7
- import { IoniconsStyles } from "../../styles/ioniconsStyles.js";
8
7
  import { SelectContainer, SelectMenu, SelectControl, SelectedChipsWrapper, SelectedChipsTitle, SelectedChipsList, SelectedChip, SelectedChipLabel, SelectedChipRemove, SelectOption, OptionRow, OptionLabel, OptionCheckbox, SelectMenuList, SelectIcon, OptionIcon } from "./Select.styles.js";
9
8
  import { SelectValueContainer, SelectWrapper } from "./Select.styles.js";
10
9
  const renderIcon = (icon) => {
@@ -170,7 +169,6 @@ const Select = (props) => {
170
169
  const isLabelUp = floatingLabel ? hasFocus || hasValue : Boolean(label);
171
170
  const effectivePlaceholder = label ? hasFocus && placeholder ? placeholder : "" : placeholder;
172
171
  return /* @__PURE__ */ jsxs(Wrapper, { children: [
173
- /* @__PURE__ */ jsx(IoniconsStyles, {}),
174
172
  label && /* @__PURE__ */ jsx(Label, { isUp: isLabelUp, active: hasFocus, error: error && touched, htmlFor: id, children: label }),
175
173
  /* @__PURE__ */ jsx(
176
174
  SelectComponent,
@@ -1,6 +1,7 @@
1
1
  import styled, { css } from "styled-components";
2
2
  import { TrackV } from "../ComponentScroll/ComponentScroll.styles.js";
3
3
  import stdin_default from "../ComponentScroll/ComponentScroll.js";
4
+ import { glyph } from "../MaterialIcon/glyph.js";
4
5
  const SelectControl = css`
5
6
  &&& {
6
7
  z-index: 10 !important;
@@ -81,12 +82,14 @@ const SelectValueContainer = css`
81
82
  margin-left: -2px;
82
83
  }
83
84
  `;
84
- const SelectIcon = styled.i.withConfig({
85
+ const SelectIcon = styled.span.withConfig({
85
86
  shouldForwardProp: (props) => !["isMenuOpen"].includes(props)
86
87
  }).attrs({
87
- className: "ion ion-ios-arrow-down"
88
+ children: glyph("keyboard_arrow_down")
88
89
  })`
89
90
  &&& {
91
+ display: inline-flex;
92
+ font-size: 18px;
90
93
  transition: 0.3s transform;
91
94
  transform: rotate(0);
92
95
  color: #202020;
@@ -7,9 +7,9 @@ export declare const ICON_SIZES: {
7
7
  readonly lg: 24;
8
8
  readonly xl: 32;
9
9
  };
10
- export type IconSize = keyof typeof ICON_SIZES | number;
10
+ export type IconSize = keyof typeof ICON_SIZES | number | (string & {});
11
11
  interface IconBaseProps {
12
- /** Token or px. Default `lg` (24px). */
12
+ /** Token, px number, or a CSS length such as `1em` to follow the font size. Default `lg` (24px). */
13
13
  size?: IconSize;
14
14
  /** Any CSS colour. Default: the surrounding text colour. */
15
15
  color?: string;
@@ -23,12 +23,14 @@ export interface MaterialIconProps extends IconBaseProps {
23
23
  name: MaterialIconName;
24
24
  variant?: 'outlined' | 'rounded' | 'sharp';
25
25
  filled?: boolean;
26
+ /** Stroke weight of the registered file: 400 (default) or another the app registered, e.g. `600`. */
27
+ weight?: number;
26
28
  }
27
29
  /**
28
30
  * A Material Symbol the app registered with `registerMaterialIcons`, drawn inline (in the server render too, no
29
31
  * request) in the text colour or `color`. An unregistered icon renders nothing.
30
32
  */
31
- export declare const MaterialIcon: ({ name, variant, filled, size, color, label, className, dataCy, }: MaterialIconProps) => import("react/jsx-runtime").JSX.Element;
33
+ export declare const MaterialIcon: ({ name, variant, filled, weight, size, color, label, className, dataCy, }: MaterialIconProps) => import("react/jsx-runtime").JSX.Element;
32
34
  export interface SvgIconProps extends IconBaseProps {
33
35
  /** An SVG React component (`import Logo from './logo.svg?react'`), or the URL of a single-colour SVG. */
34
36
  svg: ComponentType<SVGProps<SVGSVGElement>> | string;
@@ -3,20 +3,24 @@ import { createElement } from "react";
3
3
  import { InlineIcon, MaskedIcon, IconBox } from "./MaterialIcon.styles.js";
4
4
  import { getRegisteredMaterialIcon } from "./iconConfig.js";
5
5
  const ICON_SIZES = { xs: 12, sm: 16, md: 20, lg: 24, xl: 32 };
6
- const toPx = (size) => typeof size === "number" ? size : ICON_SIZES[size];
6
+ const toLength = (size) => {
7
+ if (typeof size === "number") return `${size}px`;
8
+ return Object.prototype.hasOwnProperty.call(ICON_SIZES, size) ? `${ICON_SIZES[size]}px` : size;
9
+ };
7
10
  const a11y = (label) => label ? { role: "img", "aria-label": label } : { "aria-hidden": true };
8
- const cssUrl = (url) => `url("${encodeURI(url).replace(/["'()]/g, (c) => `%${c.charCodeAt(0).toString(16)}`)}")`;
11
+ const cssUrl = (url) => `url("${(url.startsWith("data:") ? url : encodeURI(url)).replace(/["'()]/g, (c) => `%${c.charCodeAt(0).toString(16)}`)}")`;
9
12
  const MaterialIcon = ({
10
13
  name,
11
14
  variant = "outlined",
12
15
  filled = false,
16
+ weight = 400,
13
17
  size = "lg",
14
18
  color,
15
19
  label,
16
20
  className,
17
21
  dataCy
18
22
  }) => {
19
- const path = `${variant}/${name}${filled ? "-fill" : ""}`;
23
+ const path = `${variant}/${name}${filled ? "-fill" : ""}${weight === 400 ? "" : `@${weight}`}`;
20
24
  const svg = getRegisteredMaterialIcon(path);
21
25
  if (!svg) {
22
26
  return null;
@@ -28,7 +32,7 @@ const MaterialIcon = ({
28
32
  className,
29
33
  "data-cy": dataCy,
30
34
  "data-icon": name,
31
- $size: toPx(size),
35
+ $size: toLength(size),
32
36
  $color: color,
33
37
  children: createElement(svg, { "aria-hidden": true, focusable: false })
34
38
  }
@@ -40,7 +44,7 @@ const SvgIcon = ({ svg: Svg, size = "lg", color, label, className, dataCy }) =>
40
44
  className,
41
45
  "data-cy": dataCy,
42
46
  "data-icon": "custom",
43
- $size: toPx(size),
47
+ $size: toLength(size),
44
48
  $color: color
45
49
  };
46
50
  if (typeof Svg === "string") {
@@ -1,14 +1,14 @@
1
1
  export declare const IconBox: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {
2
- $size: number;
2
+ $size: string;
3
3
  $color?: string;
4
4
  }>> & string;
5
5
  /** A registered Material Symbol drawn inline; the files have no fill, so it takes the text colour. */
6
- export declare const InlineIcon: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "$color" | "$size"> & {
7
- $size: number;
6
+ export declare const InlineIcon: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "$size" | "$color"> & {
7
+ $size: string;
8
8
  $color?: string;
9
9
  }, never>> & string;
10
10
  /** Paints the SVG at `--icon-url` in the text colour, so any colour works without touching the file. */
11
- export declare const MaskedIcon: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "$color" | "$size"> & {
12
- $size: number;
11
+ export declare const MaskedIcon: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "$size" | "$color"> & {
12
+ $size: string;
13
13
  $color?: string;
14
14
  }, never>> & string;
@@ -4,8 +4,8 @@ const IconBox = styled.span`
4
4
  flex: 0 0 auto;
5
5
  align-items: center;
6
6
  justify-content: center;
7
- width: ${({ $size }) => $size}px;
8
- height: ${({ $size }) => $size}px;
7
+ width: ${({ $size }) => $size};
8
+ height: ${({ $size }) => $size};
9
9
  color: ${({ $color }) => $color ?? "inherit"};
10
10
  vertical-align: middle;
11
11
 
@@ -0,0 +1,5 @@
1
+ import { ReactNode } from 'react';
2
+ /** A Material icon that follows the font size, for `styled.span.attrs({ children: glyph('close') })`. */
3
+ export declare const glyph: (name: string, filled?: boolean, size?: string | number) => import('react').FunctionComponentElement<import('./MaterialIcon').MaterialIconProps>;
4
+ /** An icon placed before the element's own children, for `.attrs((props) => ({ children: withGlyph(...) }))`. */
5
+ export declare const withGlyph: (icon: ReactNode, children: ReactNode) => import('react').FunctionComponentElement<import('react').FragmentProps>;
@@ -0,0 +1,8 @@
1
+ import { createElement, Fragment } from "react";
2
+ import { MaterialIcon } from "./MaterialIcon.js";
3
+ const glyph = (name, filled = false, size = "1em") => createElement(MaterialIcon, { name, filled, size });
4
+ const withGlyph = (icon, children) => createElement(Fragment, null, icon, children);
5
+ export {
6
+ glyph,
7
+ withGlyph
8
+ };
@@ -11,7 +11,7 @@ export type MaterialIconName = MaterialIconRegistry extends {
11
11
  } ? K : string;
12
12
  type SvgComponent = ComponentType<SVGProps<SVGSVGElement>>;
13
13
  /**
14
- * Registers the Material Symbols an app uses, as SVG components keyed `<variant>/<name>` (`-fill` for filled): the
14
+ * Registers the Material Symbols an app uses, as SVG components keyed `<variant>/<name>` (`-fill` for filled, `@<weight>` for a weight other than 400): the
15
15
  * paths in the `@material-symbols/svg-<weight>` packages. Only these are bundled; `MaterialIcon` draws them inline.
16
16
  * Call once at module scope in an entry shared by server and client; with Module Federation the host's call covers
17
17
  * the remotes (the library is a shared singleton).
@@ -0,0 +1,5 @@
1
+ /**
2
+ * The Material Symbols (`<variant>/<name>[-fill]`) the library's own components draw. The host registers them with
3
+ * `registerMaterialIcons`; a component whose icon is not registered renders it empty.
4
+ */
5
+ export declare const requiredMaterialIcons: readonly ["outlined/add_circle", "outlined/cancel-fill", "outlined/check", "outlined/check_circle-fill", "outlined/chevron_left", "outlined/chevron_right", "outlined/close", "outlined/content_copy", "outlined/edit", "outlined/info", "outlined/info-fill", "outlined/keyboard_arrow_down", "outlined/search_activity", "outlined/visibility", "outlined/visibility_off", "outlined/warning"];
@@ -0,0 +1,21 @@
1
+ const requiredMaterialIcons = [
2
+ "outlined/add_circle",
3
+ "outlined/cancel-fill",
4
+ "outlined/check",
5
+ "outlined/check_circle-fill",
6
+ "outlined/chevron_left",
7
+ "outlined/chevron_right",
8
+ "outlined/close",
9
+ "outlined/content_copy",
10
+ "outlined/edit",
11
+ "outlined/info",
12
+ "outlined/info-fill",
13
+ "outlined/keyboard_arrow_down",
14
+ "outlined/search_activity",
15
+ "outlined/visibility",
16
+ "outlined/visibility_off",
17
+ "outlined/warning"
18
+ ];
19
+ export {
20
+ requiredMaterialIcons
21
+ };
@@ -1,9 +1,8 @@
1
- import { jsxs, jsx } from "react/jsx-runtime";
1
+ import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { Portal } from "react-portal";
3
3
  import { useState, useEffect } from "react";
4
4
  import { ModalRoot, Dimmer, Box, ModalClose } from "./Modal.styles.js";
5
5
  import { ModalBack, ModalInner, ModalInnerSmartContractAddress, ModalInnerWithBorder, ModalLink, ModalLinkWrap, ModalScroll } from "./Modal.styles.js";
6
- import { IoniconsStyles } from "../../styles/ioniconsStyles.js";
7
6
  const timeout = 300;
8
7
  const Modal = ({
9
8
  children,
@@ -59,35 +58,32 @@ const Modal = ({
59
58
  };
60
59
  }, [isOpen]);
61
60
  if (!shouldRender) return null;
62
- return /* @__PURE__ */ jsxs(Portal, { isOpened: isOpen, children: [
63
- /* @__PURE__ */ jsx(IoniconsStyles, {}),
64
- /* @__PURE__ */ jsx(
65
- ModalRoot,
66
- {
67
- className,
68
- style: {
69
- opacity: isVisible ? 1 : 0,
70
- transition: `opacity ${timeout}ms ease-in-out`
71
- },
72
- children: /* @__PURE__ */ jsx(Dimmer, { background, kyc, children: /* @__PURE__ */ jsxs(
73
- Box,
74
- {
75
- kyc,
76
- fullscreen,
77
- thin,
78
- isRegisterEntity,
79
- style: boxStyles,
80
- maxHeight,
81
- maxWidth,
82
- children: [
83
- !hideCloseButton && /* @__PURE__ */ jsx(ModalClose, { onClick: onClose }),
84
- children
85
- ]
86
- }
87
- ) })
88
- }
89
- )
90
- ] });
61
+ return /* @__PURE__ */ jsx(Portal, { isOpened: isOpen, children: /* @__PURE__ */ jsx(
62
+ ModalRoot,
63
+ {
64
+ className,
65
+ style: {
66
+ opacity: isVisible ? 1 : 0,
67
+ transition: `opacity ${timeout}ms ease-in-out`
68
+ },
69
+ children: /* @__PURE__ */ jsx(Dimmer, { background, kyc, children: /* @__PURE__ */ jsxs(
70
+ Box,
71
+ {
72
+ kyc,
73
+ fullscreen,
74
+ thin,
75
+ isRegisterEntity,
76
+ style: boxStyles,
77
+ maxHeight,
78
+ maxWidth,
79
+ children: [
80
+ !hideCloseButton && /* @__PURE__ */ jsx(ModalClose, { onClick: onClose }),
81
+ children
82
+ ]
83
+ }
84
+ ) })
85
+ }
86
+ ) });
91
87
  };
92
88
  export {
93
89
  Modal,
@@ -42,11 +42,11 @@ export interface ModalInnerProps {
42
42
  noPaddingHorizontal?: boolean;
43
43
  }
44
44
  export declare const ModalInner: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ModalInnerProps>> & string;
45
- export declare const ModalClose: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>>, never>, never>> & string;
46
- export declare const ModalBack: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('styled-components').FastOmit<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>>, never>, {
45
+ export declare const ModalClose: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>>, never>, never>> & string;
46
+ export declare const ModalBack: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('styled-components').FastOmit<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>>, never>, {
47
47
  hide?: boolean;
48
48
  }>> & string;
49
- export declare const ModalLinkWrap: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
49
+ export declare const ModalLinkWrap: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>>, never>, never>> & string;
50
50
  /** Props of `ModalLink`: a router link (`to`), or any element via `as` (e.g. `as="button"`, then `to` isn't needed). */
51
51
  export type ModalLinkProps = Partial<LinkProps> & AnchorHTMLAttributes<HTMLAnchorElement> & ButtonHTMLAttributes<HTMLButtonElement> & {
52
52
  as?: ElementType;
@@ -3,6 +3,7 @@ import { Link } from "react-router-dom";
3
3
  import grid from "../../styles/grid.js";
4
4
  import rwd, { rwdMax } from "../../styles/rwd.js";
5
5
  import { colors } from "../../styles/colors.js";
6
+ import { glyph, withGlyph } from "../MaterialIcon/glyph.js";
6
7
  const ModalRoot = styled.div`
7
8
  z-index: 1000;
8
9
  position: fixed;
@@ -238,8 +239,8 @@ const ModalInner = styled.div.withConfig({
238
239
  padding-right: 0!important;
239
240
  `}
240
241
  `;
241
- const ModalClose = styled.i.attrs({
242
- className: "ion ion-md-close",
242
+ const ModalClose = styled.span.attrs({
243
+ children: glyph("close"),
243
244
  role: "button",
244
245
  tabIndex: 0,
245
246
  "aria-label": "Close dialog",
@@ -249,6 +250,9 @@ const ModalClose = styled.i.attrs({
249
250
  position: absolute;
250
251
  top: 0;
251
252
  right: 0;
253
+ display: flex;
254
+ align-items: center;
255
+ justify-content: center;
252
256
  width: 40px;
253
257
  height: 40px;
254
258
  text-align: center;
@@ -259,24 +263,18 @@ const ModalClose = styled.i.attrs({
259
263
  background-color 0.2s,
260
264
  color 0.2s;
261
265
 
262
- &:before {
266
+ font-size: 24px;
267
+ line-height: 24px;
268
+
269
+ > [data-icon] {
263
270
  transition: transform 0.2s;
264
- font-size: 24px;
265
- line-height: 24px !important;
266
- width: 24px;
267
- height: 24px;
268
- position: absolute;
269
- top: 50%;
270
- left: 50%;
271
- margin-top: -12px;
272
- margin-left: -12px;
273
271
  }
274
272
 
275
273
  &:hover {
276
274
  color: ${colors.black};
277
275
  background-color: ${colors.white};
278
276
 
279
- &:before {
277
+ > [data-icon] {
280
278
  transform: rotate(-180deg);
281
279
  }
282
280
  }
@@ -285,15 +283,13 @@ const ModalClose = styled.i.attrs({
285
283
  width: 56px;
286
284
  height: 56px;
287
285
 
288
- &:before {
289
- font-size: 27px;
290
- }
286
+ font-size: 27px;
291
287
  `}
292
288
  `;
293
- const ModalBack = styled.i.withConfig({
289
+ const ModalBack = styled.span.withConfig({
294
290
  shouldForwardProp: (props) => !["hide"].includes(props)
295
291
  }).attrs({
296
- className: "ion ion-ios-arrow-back",
292
+ children: glyph("chevron_left"),
297
293
  role: "button",
298
294
  tabIndex: 0,
299
295
  "aria-label": "Back",
@@ -303,6 +299,9 @@ const ModalBack = styled.i.withConfig({
303
299
  position: absolute;
304
300
  top: 0;
305
301
  left: 0;
302
+ display: flex;
303
+ align-items: center;
304
+ justify-content: center;
306
305
  width: 40px;
307
306
  height: 40px;
308
307
  text-align: center;
@@ -319,23 +318,17 @@ const ModalBack = styled.i.withConfig({
319
318
  visibility: hidden;
320
319
  `}
321
320
 
322
- &:before {
321
+ font-size: 24px;
322
+ line-height: 24px;
323
+
324
+ > [data-icon] {
323
325
  transition: transform 0.2s;
324
- font-size: 24px;
325
- line-height: 24px !important;
326
- width: 24px;
327
- height: 24px;
328
- position: absolute;
329
- top: 50%;
330
- left: 50%;
331
- margin-top: -12px;
332
- margin-left: -12px;
333
326
  }
334
327
 
335
328
  &:hover {
336
329
  color: ${colors.blue};
337
330
 
338
- &:before {
331
+ > [data-icon] {
339
332
  transform: translateX(-20%);
340
333
  }
341
334
  }
@@ -344,12 +337,12 @@ const ModalBack = styled.i.withConfig({
344
337
  width: 56px;
345
338
  height: 56px;
346
339
 
347
- &:before {
348
- font-size: 27px;
349
- }
340
+ font-size: 27px;
350
341
  `}
351
342
  `;
352
- const ModalLinkWrap = styled.div`
343
+ const ModalLinkWrap = styled.div.attrs((props) => ({
344
+ children: withGlyph(glyph("chevron_right", false, 16), props.children)
345
+ }))`
353
346
  position: relative;
354
347
  font-family: 'Open Sans';
355
348
  font-weight: 300;
@@ -358,26 +351,13 @@ const ModalLinkWrap = styled.div`
358
351
  text-transform: uppercase;
359
352
  padding-left: 18px;
360
353
 
361
- &:before {
362
- content: '\\f3d1';
363
- font-family: 'Ionicons';
364
- speak: none;
365
- font-style: normal;
366
- font-weight: normal;
367
- font-variant: normal;
368
- text-transform: none;
369
- text-rendering: auto;
370
- -webkit-font-smoothing: antialiased;
371
- -moz-osx-font-smoothing: grayscale;
372
- font-size: 12px;
373
- line-height: 8px;
374
- display: block;
375
- width: 8px;
376
- height: 8px;
354
+ > [data-icon] {
377
355
  position: absolute;
378
356
  top: 50%;
379
- left: 0;
380
- margin-top: -4px;
357
+ left: -4px;
358
+ width: 16px;
359
+ height: 16px;
360
+ margin-top: -8px;
381
361
  color: ${colors.lighterGreen};
382
362
  }
383
363
  `;
@@ -10,7 +10,7 @@ import stdin_default from "../CryptoAddress/CryptoAddress.js";
10
10
  import { Button } from "../Button/Button.styles.js";
11
11
  import { getCurrencySymbol } from "../../utils/formatCurrencyValue.js";
12
12
  import theme from "../../styles/theme.js";
13
- import { Icon, iconsMap } from "../Icon/Icon.style.js";
13
+ import { MaterialIcon } from "../MaterialIcon/MaterialIcon.js";
14
14
  import styled from "styled-components";
15
15
  import { ModalInner } from "./Modal.styles.js";
16
16
  const WarningBox = styled.div`
@@ -86,7 +86,14 @@ const PaymentModal = ({
86
86
  ] })
87
87
  ] }),
88
88
  /* @__PURE__ */ jsx("p", { children: investorWalletLabel }),
89
- /* @__PURE__ */ jsx(stdin_default, { noHead: true, data: { value: investorWallet, tooltip: true, shortAddress: true }, fontSize: 16 }),
89
+ /* @__PURE__ */ jsx(
90
+ stdin_default,
91
+ {
92
+ noHead: true,
93
+ data: { value: investorWallet, tooltip: true, shortAddress: true },
94
+ fontSize: 16
95
+ }
96
+ ),
90
97
  /* @__PURE__ */ jsxs("p", { children: [
91
98
  numberOfSecuritiesText,
92
99
  " ",
@@ -126,7 +133,7 @@ const PaymentModal = ({
126
133
  qrValue && /* @__PURE__ */ jsx(ComponentWrapper, { noPaddingHorizontal: true, noPaddingBottom: true, children: /* @__PURE__ */ jsx(QRCodeSVG, { value: qrValue, size: 150 }) })
127
134
  ] }) : /* @__PURE__ */ jsxs("div", { style: { position: "relative" }, children: [
128
135
  /* @__PURE__ */ jsxs(WarningBox, { children: [
129
- /* @__PURE__ */ jsx(Icon, { icon: iconsMap.warning, size: 32, color: "white" }),
136
+ /* @__PURE__ */ jsx(MaterialIcon, { name: "warning", size: 32, color: "white" }),
130
137
  /* @__PURE__ */ jsxs("p", { style: { color: theme.cWhite }, children: [
131
138
  "Your KYC needs an update, please contact",
132
139
  " ",