@thecb/components 7.0.2-beta.6 → 7.0.2-beta.8
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 +7 -6
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +7 -6
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/icons/ClipboardIcon.js +2 -2
- package/src/components/molecules/copyable/Copyable.js +6 -6
- package/src/components/molecules/popover/Popover.js +2 -2
package/package.json
CHANGED
|
@@ -21,8 +21,8 @@ const ClipboardIcon = ({ themeValues }) => {
|
|
|
21
21
|
height="18"
|
|
22
22
|
>
|
|
23
23
|
<path
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
fillRule="evenodd"
|
|
25
|
+
clipRule="evenodd"
|
|
26
26
|
d="M9.83929 3.43753H14.1607V5.59825H9.83929L9.83929 3.43753ZM8.75893 3.43753C8.75893 2.84087 9.24262 2.35718 9.83929 2.35718H14.1607C14.7574 2.35718 15.2411 2.84087 15.2411 3.43753V5.59825C15.2411 6.19491 14.7574 6.67861 14.1607 6.67861H9.83929C9.24262 6.67861 8.75893 6.19491 8.75893 5.59825V3.43753ZM6.59821 3.70762H7.94866V5.32816H6.59821C6.29988 5.32816 6.05804 5.57001 6.05804 5.86834V17.4822C6.05804 17.7805 6.29988 18.0224 6.59821 18.0224H17.4018C17.7001 18.0224 17.942 17.7805 17.942 17.4822V5.86834C17.942 5.57001 17.7001 5.32816 17.4018 5.32816H16.0513V3.70762H17.4018C18.5951 3.70762 19.5625 4.67501 19.5625 5.86834V17.4822C19.5625 18.6755 18.5951 19.6429 17.4018 19.6429H6.59821C5.40488 19.6429 4.4375 18.6755 4.4375 17.4822V5.86834C4.4375 4.67501 5.40488 3.70762 6.59821 3.70762Z"
|
|
27
27
|
fill={themeValues.singleIconColor}
|
|
28
28
|
/>
|
|
@@ -46,9 +46,9 @@ const Copyable = ({
|
|
|
46
46
|
copyErrorPopoverContent = "Unable to copy value",
|
|
47
47
|
copiedPopoverContentDuration = 1000,
|
|
48
48
|
hasPopover = true,
|
|
49
|
-
popoverMinWidth = "
|
|
49
|
+
popoverMinWidth = "max-content",
|
|
50
50
|
popoverID = 0,
|
|
51
|
-
popoverExtraStyles
|
|
51
|
+
popoverExtraStyles,
|
|
52
52
|
}) => {
|
|
53
53
|
const [popoverContent, setPopoverContent] = useState(initialPopoverContent);
|
|
54
54
|
const [startTimer, setStartTimer] = useState(false);
|
|
@@ -96,7 +96,7 @@ const Copyable = ({
|
|
|
96
96
|
onCopy?.();
|
|
97
97
|
setAttemptCopy(false);
|
|
98
98
|
})
|
|
99
|
-
.catch(error => {
|
|
99
|
+
.catch((error) => {
|
|
100
100
|
console.error(error);
|
|
101
101
|
setPopoverContent(copyErrorPopoverContent);
|
|
102
102
|
setAttemptCopy(false);
|
|
@@ -118,18 +118,18 @@ const Copyable = ({
|
|
|
118
118
|
top: "auto",
|
|
119
119
|
right: "auto",
|
|
120
120
|
bottom: "auto",
|
|
121
|
-
left: `calc(-${popoverArrowWidth} - 8px)
|
|
121
|
+
left: `calc(-${popoverArrowWidth} - 8px)`,
|
|
122
122
|
}}
|
|
123
123
|
arrowPosition={{
|
|
124
124
|
arrowTop: "auto",
|
|
125
125
|
arrowRight: "-8px",
|
|
126
126
|
arrowBottom: `calc(50% - ${popoverArrowWidth})`,
|
|
127
|
-
arrowLeft: "auto"
|
|
127
|
+
arrowLeft: "auto",
|
|
128
128
|
}}
|
|
129
129
|
transform="translate(-100%, -75%)"
|
|
130
130
|
arrowDirection="right"
|
|
131
131
|
popoverID={popoverID}
|
|
132
|
-
buttonExtraStyles="margin: 0"
|
|
132
|
+
buttonExtraStyles="margin: 0;min-width:auto"
|
|
133
133
|
extraStyles={popoverExtraStyles}
|
|
134
134
|
triggerText={CopyableContent({ content, onClick })}
|
|
135
135
|
content={popoverContent}
|
|
@@ -39,7 +39,7 @@ const Popover = ({
|
|
|
39
39
|
position, // { top: string, right: string, bottom: string, left: string }
|
|
40
40
|
arrowPosition, // { top: string, right: string, bottom: string, left: string }
|
|
41
41
|
arrowDirection = "down",
|
|
42
|
-
transform,
|
|
42
|
+
transform = "none",
|
|
43
43
|
buttonExtraStyles
|
|
44
44
|
}) => {
|
|
45
45
|
const { hoverColor, activeColor, popoverTriggerColor } = themeValues;
|
|
@@ -127,7 +127,7 @@ const Popover = ({
|
|
|
127
127
|
bottom: ${bottom};
|
|
128
128
|
left: ${left};
|
|
129
129
|
height: ${height};
|
|
130
|
-
transform: ${transform
|
|
130
|
+
transform: ${transform};
|
|
131
131
|
`}
|
|
132
132
|
>
|
|
133
133
|
<Paragraph>{content}</Paragraph>
|