@thecb/components 11.0.2-beta.0 → 11.0.2-beta.1
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 +96 -627
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.esm.js +96 -627
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/link/ExternalLink.d.ts +1 -0
- package/src/components/atoms/link/ExternalLink.js +3 -2
- package/src/components/atoms/link/Link.stories.js +8 -0
package/package.json
CHANGED
|
@@ -17,6 +17,7 @@ const ExternalLink = forwardRef(
|
|
|
17
17
|
weight = FONT_WEIGHT_REGULAR,
|
|
18
18
|
extraStyles = ``,
|
|
19
19
|
variant = "primary",
|
|
20
|
+
containerTabIndex = "-1",
|
|
20
21
|
tabIndex = "0",
|
|
21
22
|
dataQa,
|
|
22
23
|
ariaLabel,
|
|
@@ -43,7 +44,7 @@ const ExternalLink = forwardRef(
|
|
|
43
44
|
};
|
|
44
45
|
|
|
45
46
|
return (
|
|
46
|
-
<Box padding="0" tabIndex={
|
|
47
|
+
<Box padding="0" tabIndex={containerTabIndex} onKeyDown={handleKeyDown}>
|
|
47
48
|
<StyledExternalLink
|
|
48
49
|
href={href}
|
|
49
50
|
target={newTab ? "_blank" : ""}
|
|
@@ -54,7 +55,7 @@ const ExternalLink = forwardRef(
|
|
|
54
55
|
hovercolor={themeValues.hoverColor}
|
|
55
56
|
activeColor={themeValues.activeColor}
|
|
56
57
|
fontFamily={themeValues.fontFamily}
|
|
57
|
-
tabIndex=
|
|
58
|
+
tabIndex={tabIndex}
|
|
58
59
|
extrastyles={extraStyles}
|
|
59
60
|
rel={newTab ? "noopener" : ""}
|
|
60
61
|
data-qa={dataQa}
|
|
@@ -20,6 +20,7 @@ const meta = {
|
|
|
20
20
|
fontWeight: undefined,
|
|
21
21
|
fontSize: undefined,
|
|
22
22
|
margin: undefined,
|
|
23
|
+
containerTabIndex: undefined,
|
|
23
24
|
tabIndex: undefined,
|
|
24
25
|
extraStyles: undefined,
|
|
25
26
|
dataQa: undefined,
|
|
@@ -100,6 +101,13 @@ const meta = {
|
|
|
100
101
|
defaultValue: { summary: undefined }
|
|
101
102
|
}
|
|
102
103
|
},
|
|
104
|
+
containerTabIndex: {
|
|
105
|
+
description: "Override for tab index value for link's container",
|
|
106
|
+
table: {
|
|
107
|
+
type: { summary: "string" },
|
|
108
|
+
defaultValue: { summary: undefined }
|
|
109
|
+
}
|
|
110
|
+
},
|
|
103
111
|
tabIndex: {
|
|
104
112
|
description: "Override for tab index value for link",
|
|
105
113
|
table: {
|