@thecb/components 10.4.6-beta.6 → 10.4.7-beta.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/dist/index.cjs.js +226 -303
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +227 -303
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/index.js +0 -1
- package/src/components/atoms/toggle-switch/ToggleSwitch.js +34 -61
- package/src/components/atoms/toggle-switch/ToggleSwitch.stories.js +3 -3
- package/src/components/atoms/toggle-switch/ToggleSwitch.theme.js +5 -5
- package/src/components/molecules/account-and-routing-modal/AccountAndRoutingModal.js +50 -50
- package/dist/src/apps/checkout/pages/payment/sub-pages/payment-amount/PaymentAmount_old.js +0 -49322
- package/src/.DS_Store +0 -0
- package/src/components/.DS_Store +0 -0
- package/src/components/atoms/.DS_Store +0 -0
- package/src/components/atoms/icons/.DS_Store +0 -0
- package/src/components/atoms/wallet-name/WalletName.js +0 -74
- package/src/components/atoms/wallet-name/WalletName.stories.js +0 -20
- package/src/components/atoms/wallet-name/WalletName.theme.js +0 -9
- package/src/components/atoms/wallet-name/index.js +0 -3
package/src/.DS_Store
DELETED
|
Binary file
|
package/src/components/.DS_Store
DELETED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import React, { Fragment, useContext } from "react";
|
|
2
|
-
import { Box } from "../layouts";
|
|
3
|
-
import { themeComponent } from "../../../util/themeUtils";
|
|
4
|
-
import ButtonWithAction from "../button-with-action";
|
|
5
|
-
import { noop } from "../../../util/general";
|
|
6
|
-
import Text from "../text/Text";
|
|
7
|
-
import { ThemeContext } from "styled-components";
|
|
8
|
-
import { fallbackValues } from "./WalletName.theme";
|
|
9
|
-
import Module from "../../molecules/module/Module";
|
|
10
|
-
|
|
11
|
-
const WalletName = ({
|
|
12
|
-
personName,
|
|
13
|
-
action = noop,
|
|
14
|
-
text = "Not you?",
|
|
15
|
-
actionText = "Check out as a guest"
|
|
16
|
-
}) => {
|
|
17
|
-
const themeContext = useContext(ThemeContext);
|
|
18
|
-
const { isMobile } = themeContext;
|
|
19
|
-
|
|
20
|
-
return (
|
|
21
|
-
<Fragment>
|
|
22
|
-
<Module spacingBottom={isMobile ? "0" : "1.5rem"}>
|
|
23
|
-
<Box
|
|
24
|
-
padding="24px"
|
|
25
|
-
spacingBottom="0"
|
|
26
|
-
margin="0 0 0 0"
|
|
27
|
-
extraStyles={
|
|
28
|
-
isMobile
|
|
29
|
-
? `box-shadow: 0px 1px 2px 0px #292A331A; box-shadow: 0px 2px 6px 0px #292A3333; box-shadow: 0px 1px 0px 0px #292A331A inset;
|
|
30
|
-
; display: flex; flex-direction: column; flex-wrap: wrap;
|
|
31
|
-
span {text - align: right;}`
|
|
32
|
-
: `display: flex; justify-content: space-between; align-items: center; `
|
|
33
|
-
}
|
|
34
|
-
>
|
|
35
|
-
<Box padding="0 0 0">
|
|
36
|
-
<Text>{personName}</Text>
|
|
37
|
-
</Box>
|
|
38
|
-
{!isMobile && (
|
|
39
|
-
<Box padding="0">
|
|
40
|
-
<Text extraStyles="font-size: 12px">{text}</Text>
|
|
41
|
-
<ButtonWithAction
|
|
42
|
-
text={actionText}
|
|
43
|
-
action={action}
|
|
44
|
-
variant="smallGhost"
|
|
45
|
-
extraStyles="span {font-size: 12px;}"
|
|
46
|
-
/>
|
|
47
|
-
</Box>
|
|
48
|
-
)}
|
|
49
|
-
</Box>
|
|
50
|
-
</Module>
|
|
51
|
-
{isMobile && (
|
|
52
|
-
<Box
|
|
53
|
-
padding="0"
|
|
54
|
-
extraStyles="display: flex; align-items: center; justify-content: flex-end;"
|
|
55
|
-
>
|
|
56
|
-
<Text extraStyles="font-size: 12px">{text}</Text>
|
|
57
|
-
<ButtonWithAction
|
|
58
|
-
text={actionText}
|
|
59
|
-
action={action}
|
|
60
|
-
variant="smallGhost"
|
|
61
|
-
extraStyles="span {font-size: 12px;}"
|
|
62
|
-
/>
|
|
63
|
-
</Box>
|
|
64
|
-
)}
|
|
65
|
-
</Fragment>
|
|
66
|
-
);
|
|
67
|
-
};
|
|
68
|
-
|
|
69
|
-
export default themeComponent(
|
|
70
|
-
WalletName,
|
|
71
|
-
"WalletName",
|
|
72
|
-
fallbackValues,
|
|
73
|
-
"primary"
|
|
74
|
-
);
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import WalletName from "./WalletName";
|
|
3
|
-
import { text } from "@storybook/addon-knobs";
|
|
4
|
-
import page from "../../../../.storybook/page";
|
|
5
|
-
|
|
6
|
-
export const walletName = () => {
|
|
7
|
-
return (
|
|
8
|
-
<WalletName
|
|
9
|
-
personName={text("personName", "Storybook McGee", "props")}
|
|
10
|
-
action={() => window.alert("action fired!")}
|
|
11
|
-
/>
|
|
12
|
-
);
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
const story = page({
|
|
16
|
-
title: "Components|Atoms/WalletName",
|
|
17
|
-
component: WalletName
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
export default story;
|