@redotech/redo-hydrogen 1.3.0 → 1.4.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.
- package/CHANGELOG.md +8 -0
- package/dist/cjs/index.js +2 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/types.d.ts +11 -2
- package/package.json +1 -1
- package/rollup.config.js +1 -1
- package/src/components/icons/featured-laptop-2.svg +57 -0
- package/src/components/icons/featured-package-check.svg +57 -0
- package/src/components/icons/featured-refresh-cw-3.svg +57 -0
- package/src/components/icons/info.svg +20 -0
- package/src/components/icons/logo.svg +13 -0
- package/src/components/icons/modal-close-button.svg +37 -0
- package/src/components/icons/shield-tick.svg +13 -0
- package/src/components/redo-checkout-buttons.tsx +0 -1
- package/src/components/redo-info-modal.tsx +432 -0
- package/src/index.ts +3 -1
- package/src/svg.d.ts +4 -3
package/dist/types.d.ts
CHANGED
|
@@ -52,7 +52,6 @@ declare const RedoProvider: ({ cart, storeId, children }: {
|
|
|
52
52
|
declare const useRedoCoverageClient: () => RedoCoverageClient;
|
|
53
53
|
|
|
54
54
|
declare const RedoCheckoutButtons: (props: {
|
|
55
|
-
cart: CartReturn | CartWithActionsDocs | OptimisticCart;
|
|
56
55
|
children?: ReactNode;
|
|
57
56
|
onClick?: (enabled: boolean) => void;
|
|
58
57
|
}) => react_jsx_runtime.JSX.Element;
|
|
@@ -69,4 +68,14 @@ interface LoadState<T> {
|
|
|
69
68
|
}
|
|
70
69
|
declare function useLoad<T>(fn: Loader<T>, deps: DependencyList): LoadState<T>;
|
|
71
70
|
|
|
72
|
-
|
|
71
|
+
interface RedoInfoModalProps {
|
|
72
|
+
showInfoIcon?: boolean;
|
|
73
|
+
onInfoClick?: () => void;
|
|
74
|
+
infoCardImageUrl?: string;
|
|
75
|
+
infoModalLogoUrl?: string;
|
|
76
|
+
infoModalImageUrl?: string;
|
|
77
|
+
infoModalContent?: ReactNode;
|
|
78
|
+
}
|
|
79
|
+
declare const RedoInfoCard: ({ showInfoIcon, onInfoClick, infoCardImageUrl, infoModalLogoUrl, infoModalImageUrl, infoModalContent, }: RedoInfoModalProps) => react_jsx_runtime.JSX.Element;
|
|
80
|
+
|
|
81
|
+
export { type CartAttributeKey, type CartInfoToEnable, type CartProductVariantFragment, type LoadState, type Loader, REDO_REQUIRED_HOSTNAMES, RedoCheckoutButtons, type RedoContextValue, type RedoCoverageClient, type RedoError, RedoErrorType, RedoInfoCard, RedoProvider, useLoad, useRedoCoverageClient };
|
package/package.json
CHANGED
package/rollup.config.js
CHANGED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
<svg
|
|
2
|
+
viewBox="0 0 36 36"
|
|
3
|
+
fill="none"
|
|
4
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
5
|
+
>
|
|
6
|
+
<g filter="url(#filter0_d_635_1424)">
|
|
7
|
+
<path
|
|
8
|
+
d="M2.5 7C2.5 3.96243 4.96243 1.5 8 1.5H28C31.0376 1.5 33.5 3.96243 33.5 7V27C33.5 30.0376 31.0376 32.5 28 32.5H8C4.96243 32.5 2.5 30.0376 2.5 27V7Z"
|
|
9
|
+
stroke="#D6D6D6"
|
|
10
|
+
shape-rendering="crispEdges"
|
|
11
|
+
/>
|
|
12
|
+
<path
|
|
13
|
+
d="M23.9999 19.6667V13.8C23.9999 13.0533 23.9999 12.6799 23.8546 12.3947C23.7268 12.1438 23.5228 11.9398 23.2719 11.812C22.9867 11.6667 22.6133 11.6667 21.8666 11.6667H14.1333C13.3865 11.6667 13.0131 11.6667 12.7279 11.812C12.477 11.9398 12.2731 12.1438 12.1452 12.3947C11.9999 12.6799 11.9999 13.0533 11.9999 13.8V19.6667M13.111 22.3333H22.8888C23.3021 22.3333 23.5088 22.3333 23.6783 22.2879C24.1385 22.1646 24.4979 21.8052 24.6212 21.3451C24.6666 21.1755 24.6666 20.9689 24.6666 20.5556C24.6666 20.3489 24.6666 20.2456 24.6439 20.1608C24.5822 19.9307 24.4025 19.751 24.1725 19.6894C24.0877 19.6667 23.9844 19.6667 23.7777 19.6667H12.2221C12.0155 19.6667 11.9122 19.6667 11.8274 19.6894C11.5973 19.751 11.4176 19.9307 11.356 20.1608C11.3333 20.2456 11.3333 20.3489 11.3333 20.5556C11.3333 20.9689 11.3333 21.1755 11.3787 21.3451C11.502 21.8052 11.8614 22.1646 12.3215 22.2879C12.491 22.3333 12.6977 22.3333 13.111 22.3333Z"
|
|
14
|
+
stroke="#424242"
|
|
15
|
+
stroke-width="1.33333"
|
|
16
|
+
stroke-linecap="round"
|
|
17
|
+
stroke-linejoin="round"
|
|
18
|
+
/>
|
|
19
|
+
</g>
|
|
20
|
+
<defs>
|
|
21
|
+
<filter
|
|
22
|
+
id="filter0_d_635_1424"
|
|
23
|
+
x="0"
|
|
24
|
+
y="0"
|
|
25
|
+
width="36"
|
|
26
|
+
height="36"
|
|
27
|
+
filterUnits="userSpaceOnUse"
|
|
28
|
+
color-interpolation-filters="sRGB"
|
|
29
|
+
>
|
|
30
|
+
<feFlood flood-opacity="0" result="BackgroundImageFix" />
|
|
31
|
+
<feColorMatrix
|
|
32
|
+
in="SourceAlpha"
|
|
33
|
+
type="matrix"
|
|
34
|
+
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
|
|
35
|
+
result="hardAlpha"
|
|
36
|
+
/>
|
|
37
|
+
<feOffset dy="1" />
|
|
38
|
+
<feGaussianBlur stdDeviation="1" />
|
|
39
|
+
<feComposite in2="hardAlpha" operator="out" />
|
|
40
|
+
<feColorMatrix
|
|
41
|
+
type="matrix"
|
|
42
|
+
values="0 0 0 0 0.0627451 0 0 0 0 0.0941176 0 0 0 0 0.156863 0 0 0 0.05 0"
|
|
43
|
+
/>
|
|
44
|
+
<feBlend
|
|
45
|
+
mode="normal"
|
|
46
|
+
in2="BackgroundImageFix"
|
|
47
|
+
result="effect1_dropShadow_635_1424"
|
|
48
|
+
/>
|
|
49
|
+
<feBlend
|
|
50
|
+
mode="normal"
|
|
51
|
+
in="SourceGraphic"
|
|
52
|
+
in2="effect1_dropShadow_635_1424"
|
|
53
|
+
result="shape"
|
|
54
|
+
/>
|
|
55
|
+
</filter>
|
|
56
|
+
</defs>
|
|
57
|
+
</svg>
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
<svg
|
|
2
|
+
viewBox="0 0 36 36"
|
|
3
|
+
fill="none"
|
|
4
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
5
|
+
>
|
|
6
|
+
<g filter="url(#filter0_d_632_1403)">
|
|
7
|
+
<path
|
|
8
|
+
d="M2.5 7C2.5 3.96243 4.96243 1.5 8 1.5H28C31.0376 1.5 33.5 3.96243 33.5 7V27C33.5 30.0376 31.0376 32.5 28 32.5H8C4.96243 32.5 2.5 30.0376 2.5 27V7Z"
|
|
9
|
+
stroke="#D6D6D6"
|
|
10
|
+
shape-rendering="crispEdges"
|
|
11
|
+
/>
|
|
12
|
+
<path
|
|
13
|
+
d="M23.6666 13.8518L18 17M18 17L12.3333 13.8518M18 17L18 23.3333M19.3333 22.9259L18.518 23.3789C18.329 23.4839 18.2344 23.5364 18.1343 23.557C18.0457 23.5753 17.9543 23.5753 17.8657 23.557C17.7656 23.5364 17.6711 23.4839 17.482 23.3789L12.5486 20.6381C12.349 20.5272 12.2491 20.4717 12.1764 20.3928C12.1121 20.3231 12.0634 20.2403 12.0337 20.1502C12 20.0483 12 19.9341 12 19.7057V14.2943C12 14.0659 12 13.9517 12.0337 13.8498C12.0634 13.7597 12.1121 13.677 12.1764 13.6072C12.2491 13.5283 12.349 13.4728 12.5486 13.3619L17.482 10.6211C17.671 10.5161 17.7656 10.4636 17.8657 10.443C17.9543 10.4248 18.0457 10.4248 18.1343 10.443C18.2344 10.4636 18.329 10.5161 18.518 10.6211L23.4514 13.3619C23.651 13.4728 23.7509 13.5283 23.8236 13.6072C23.8879 13.6769 23.9366 13.7597 23.9663 13.8498C24 13.9517 24 14.0659 24 14.2943L24 17.3333M15 12L21 15.3333M20.6667 21L22 22.3333L24.6667 19.6667"
|
|
14
|
+
stroke="#424242"
|
|
15
|
+
stroke-width="1.33333"
|
|
16
|
+
stroke-linecap="round"
|
|
17
|
+
stroke-linejoin="round"
|
|
18
|
+
/>
|
|
19
|
+
</g>
|
|
20
|
+
<defs>
|
|
21
|
+
<filter
|
|
22
|
+
id="filter0_d_632_1403"
|
|
23
|
+
x="0"
|
|
24
|
+
y="0"
|
|
25
|
+
width="36"
|
|
26
|
+
height="36"
|
|
27
|
+
filterUnits="userSpaceOnUse"
|
|
28
|
+
color-interpolation-filters="sRGB"
|
|
29
|
+
>
|
|
30
|
+
<feFlood flood-opacity="0" result="BackgroundImageFix" />
|
|
31
|
+
<feColorMatrix
|
|
32
|
+
in="SourceAlpha"
|
|
33
|
+
type="matrix"
|
|
34
|
+
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
|
|
35
|
+
result="hardAlpha"
|
|
36
|
+
/>
|
|
37
|
+
<feOffset dy="1" />
|
|
38
|
+
<feGaussianBlur stdDeviation="1" />
|
|
39
|
+
<feComposite in2="hardAlpha" operator="out" />
|
|
40
|
+
<feColorMatrix
|
|
41
|
+
type="matrix"
|
|
42
|
+
values="0 0 0 0 0.0627451 0 0 0 0 0.0941176 0 0 0 0 0.156863 0 0 0 0.05 0"
|
|
43
|
+
/>
|
|
44
|
+
<feBlend
|
|
45
|
+
mode="normal"
|
|
46
|
+
in2="BackgroundImageFix"
|
|
47
|
+
result="effect1_dropShadow_632_1403"
|
|
48
|
+
/>
|
|
49
|
+
<feBlend
|
|
50
|
+
mode="normal"
|
|
51
|
+
in="SourceGraphic"
|
|
52
|
+
in2="effect1_dropShadow_632_1403"
|
|
53
|
+
result="shape"
|
|
54
|
+
/>
|
|
55
|
+
</filter>
|
|
56
|
+
</defs>
|
|
57
|
+
</svg>
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
<svg
|
|
2
|
+
viewBox="0 0 36 36"
|
|
3
|
+
fill="none"
|
|
4
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
5
|
+
>
|
|
6
|
+
<g filter="url(#filter0_d_632_1398)">
|
|
7
|
+
<path
|
|
8
|
+
d="M2.5 7C2.5 3.96243 4.96243 1.5 8 1.5H28C31.0376 1.5 33.5 3.96243 33.5 7V27C33.5 30.0376 31.0376 32.5 28 32.5H8C4.96243 32.5 2.5 30.0376 2.5 27V7Z"
|
|
9
|
+
stroke="#D6D6D6"
|
|
10
|
+
shape-rendering="crispEdges"
|
|
11
|
+
/>
|
|
12
|
+
<path
|
|
13
|
+
d="M19.3333 23.6667C19.3333 23.6667 19.8995 23.5858 22.2426 21.2426C24.5858 18.8995 24.5858 15.1005 22.2426 12.7574C21.4125 11.9272 20.3995 11.3911 19.3333 11.1492M19.3333 23.6667H23.3333M19.3333 23.6667L19.3333 19.6667M16.6667 10.3335C16.6667 10.3335 16.1005 10.4143 13.7574 12.7575C11.4142 15.1006 11.4142 18.8996 13.7574 21.2428C14.5875 22.073 15.6005 22.609 16.6667 22.8509M16.6667 10.3335L12.6667 10.3333M16.6667 10.3335L16.6667 14.3333"
|
|
14
|
+
stroke="#424242"
|
|
15
|
+
stroke-width="1.33333"
|
|
16
|
+
stroke-linecap="round"
|
|
17
|
+
stroke-linejoin="round"
|
|
18
|
+
/>
|
|
19
|
+
</g>
|
|
20
|
+
<defs>
|
|
21
|
+
<filter
|
|
22
|
+
id="filter0_d_632_1398"
|
|
23
|
+
x="0"
|
|
24
|
+
y="0"
|
|
25
|
+
width="36"
|
|
26
|
+
height="36"
|
|
27
|
+
filterUnits="userSpaceOnUse"
|
|
28
|
+
color-interpolation-filters="sRGB"
|
|
29
|
+
>
|
|
30
|
+
<feFlood flood-opacity="0" result="BackgroundImageFix" />
|
|
31
|
+
<feColorMatrix
|
|
32
|
+
in="SourceAlpha"
|
|
33
|
+
type="matrix"
|
|
34
|
+
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
|
|
35
|
+
result="hardAlpha"
|
|
36
|
+
/>
|
|
37
|
+
<feOffset dy="1" />
|
|
38
|
+
<feGaussianBlur stdDeviation="1" />
|
|
39
|
+
<feComposite in2="hardAlpha" operator="out" />
|
|
40
|
+
<feColorMatrix
|
|
41
|
+
type="matrix"
|
|
42
|
+
values="0 0 0 0 0.0627451 0 0 0 0 0.0941176 0 0 0 0 0.156863 0 0 0 0.05 0"
|
|
43
|
+
/>
|
|
44
|
+
<feBlend
|
|
45
|
+
mode="normal"
|
|
46
|
+
in2="BackgroundImageFix"
|
|
47
|
+
result="effect1_dropShadow_632_1398"
|
|
48
|
+
/>
|
|
49
|
+
<feBlend
|
|
50
|
+
mode="normal"
|
|
51
|
+
in="SourceGraphic"
|
|
52
|
+
in2="effect1_dropShadow_632_1398"
|
|
53
|
+
result="shape"
|
|
54
|
+
/>
|
|
55
|
+
</filter>
|
|
56
|
+
</defs>
|
|
57
|
+
</svg>
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100">
|
|
2
|
+
<defs />
|
|
3
|
+
<g id="Redo_Layer_2" data-name="Layer 2">
|
|
4
|
+
<g id="Layer_1-2" data-name="Layer 1">
|
|
5
|
+
<circle
|
|
6
|
+
class="cls-1"
|
|
7
|
+
cx="50"
|
|
8
|
+
cy="50"
|
|
9
|
+
r="46.5"
|
|
10
|
+
fill="none"
|
|
11
|
+
stroke="currentColor"
|
|
12
|
+
style="stroke-miterlimit: 10; stroke-width: 7px;"
|
|
13
|
+
/>
|
|
14
|
+
<path
|
|
15
|
+
d="M50,25a4.49,4.49,0,0,1,4.51,4.5A4.43,4.43,0,0,1,50,33.92a4.36,4.36,0,0,1-4.43-4.43A4.42,4.42,0,0,1,50,25ZM46.61,41.43h6.78V75H46.61Z"
|
|
16
|
+
fill="currentColor"
|
|
17
|
+
/>
|
|
18
|
+
</g>
|
|
19
|
+
</g>
|
|
20
|
+
</svg>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<svg
|
|
2
|
+
viewBox="0 0 800 255"
|
|
3
|
+
fill="none"
|
|
4
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
5
|
+
>
|
|
6
|
+
<rect width="800" height="255" fill="#141414" />
|
|
7
|
+
<path
|
|
8
|
+
fill-rule="evenodd"
|
|
9
|
+
clip-rule="evenodd"
|
|
10
|
+
d="M715.79 184.078C743.088 165.472 745.57 138.234 745.57 126.149C745.57 105.625 737.743 91.6218 733.353 85.1C723.999 71.6726 707.391 57.478 671.693 54.6008C665.585 54.0253 659.667 54.0253 653.558 54.0253C623.397 54.4089 606.979 61.3144 595.526 69.179C584.454 76.6599 566.319 93.7318 566.319 127.876C566.319 136.507 566.891 154.155 581.209 171.61C587.89 179.667 594.571 184.078 598.198 186.188C609.079 192.71 626.451 199.04 655.085 199.04C674.175 199.04 686.011 196.739 693.837 194.437C701.855 192.135 708.727 188.874 715.79 184.078ZM683.72 93.9236C688.683 98.3355 695.937 109.269 695.937 126.533C695.937 141.878 689.828 159.142 674.748 165.856C667.494 169.117 658.903 169.117 656.612 169.117C648.404 169.117 626.642 167.39 618.624 143.221C616.142 136.124 615.952 129.218 615.952 126.725C615.952 110.228 623.206 93.9236 639.05 87.21C644.968 84.7163 650.122 84.1409 656.422 84.1409C663.676 84.1409 667.303 85.1 670.739 86.2509C677.229 88.5527 681.811 92.0054 683.72 93.9236ZM538.789 172.569C552.533 156.457 553.106 134.397 553.106 128.259C553.106 120.97 552.724 103.706 541.27 87.21C533.253 75.5091 519.508 62.2736 488.201 59.5881C482.856 59.2045 477.511 59.0127 472.166 59.0127H395.617V194.437H481.138C494.692 194.437 499.655 193.478 506.527 191.751C514.736 189.641 520.844 186.38 523.708 184.846C531.725 180.242 536.498 175.447 538.789 172.569ZM493.546 98.5274C505.382 107.735 505.954 122.888 505.954 127.108C505.954 130.753 505.763 138.042 501.564 146.674C498.319 153.579 492.401 161.06 475.793 163.17C472.929 163.554 470.066 163.746 467.393 163.746H442.768V91.2382H465.866C465.997 91.2382 466.146 91.2376 466.311 91.2369C470.258 91.2204 483.836 91.1636 493.546 98.5274ZM372.621 194.437H228.685V59.0127H370.903V89.32H276.982V111.571H363.839V142.07H276.982V163.746H372.621V194.437ZM155.847 194.437H209.107L175.509 140.344C182.381 138.617 184.863 137.658 188.108 135.74C205.098 126.341 206.434 108.31 206.434 101.98C206.434 89.7037 202.044 81.6473 199.562 77.6191C188.681 60.3554 171.309 59.0127 153.174 59.0127H53.9082V194.437H102.396V145.139H127.976L155.847 194.437ZM156.228 95.2664C158.137 97.9519 158.328 101.021 158.328 102.172C158.328 103.706 158.137 106.776 155.656 109.845C152.601 113.489 147.829 114.64 138.666 114.64H102.396V89.7037H142.484C147.638 89.7037 152.983 90.4709 156.228 95.2664Z"
|
|
11
|
+
fill="white"
|
|
12
|
+
/>
|
|
13
|
+
</svg>
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<svg
|
|
2
|
+
width="24"
|
|
3
|
+
height="24"
|
|
4
|
+
viewBox="0 0 24 24"
|
|
5
|
+
fill="none"
|
|
6
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
7
|
+
>
|
|
8
|
+
<circle opacity="0.2" cx="12" cy="12" r="12" fill="#A6A9BA" />
|
|
9
|
+
<g clip-path="url(#clip0_1503_61903)">
|
|
10
|
+
<path
|
|
11
|
+
d="M15.5999 15.5984L8.3999 8.39844"
|
|
12
|
+
stroke="#14181F"
|
|
13
|
+
stroke-opacity="0.5"
|
|
14
|
+
stroke-width="1.5"
|
|
15
|
+
stroke-linecap="round"
|
|
16
|
+
stroke-linejoin="round"
|
|
17
|
+
/>
|
|
18
|
+
<path
|
|
19
|
+
d="M15.5999 8.39844L8.3999 15.5985"
|
|
20
|
+
stroke="#14181F"
|
|
21
|
+
stroke-opacity="0.5"
|
|
22
|
+
stroke-width="1.5"
|
|
23
|
+
stroke-linecap="round"
|
|
24
|
+
stroke-linejoin="round"
|
|
25
|
+
/>
|
|
26
|
+
</g>
|
|
27
|
+
<defs>
|
|
28
|
+
<clipPath id="clip0_1503_61903">
|
|
29
|
+
<rect
|
|
30
|
+
width="9.6"
|
|
31
|
+
height="9.6"
|
|
32
|
+
fill="white"
|
|
33
|
+
transform="translate(7.19995 7.19922)"
|
|
34
|
+
/>
|
|
35
|
+
</clipPath>
|
|
36
|
+
</defs>
|
|
37
|
+
</svg>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<svg
|
|
2
|
+
viewBox="0 0 25 24"
|
|
3
|
+
fill="none"
|
|
4
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
5
|
+
>
|
|
6
|
+
<path
|
|
7
|
+
d="M9.6665 11.4999L11.6665 13.4999L16.1665 8.99987M20.6665 11.9999C20.6665 16.9083 15.3125 20.4783 13.3645 21.6147C13.1431 21.7439 13.0324 21.8085 12.8762 21.842C12.7549 21.868 12.5781 21.868 12.4568 21.842C12.3006 21.8085 12.1899 21.7439 11.9685 21.6147C10.0205 20.4783 4.6665 16.9083 4.6665 11.9999V7.21747C4.6665 6.41796 4.6665 6.0182 4.79726 5.67457C4.91278 5.37101 5.10049 5.10015 5.34416 4.8854C5.62 4.64231 5.9943 4.50195 6.74291 4.22122L12.1047 2.21054C12.3126 2.13258 12.4165 2.0936 12.5235 2.07815C12.6183 2.06444 12.7147 2.06444 12.8095 2.07815C12.9165 2.0936 13.0204 2.13258 13.2283 2.21054L18.5901 4.22122C19.3387 4.50195 19.713 4.64231 19.9888 4.8854C20.2325 5.10015 20.4202 5.37101 20.5357 5.67457C20.6665 6.0182 20.6665 6.41796 20.6665 7.21747V11.9999Z"
|
|
8
|
+
stroke="currentColor"
|
|
9
|
+
stroke-width="1.5"
|
|
10
|
+
stroke-linecap="round"
|
|
11
|
+
stroke-linejoin="round"
|
|
12
|
+
/>
|
|
13
|
+
</svg>
|