@newhighsco/chipset 6.17.5 → 6.18.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/package.json +25 -15
- package/src/components/Backdrop/Backdrop.jsx +1 -1
- package/src/components/Button/Button.jsx +1 -1
- package/src/components/Button/ButtonGroup.jsx +2 -1
- package/src/components/Card/Card.jsx +1 -1
- package/src/components/ContentContainer/ContentContainer.jsx +1 -1
- package/src/components/CreditLockup/CreditLockup.module.scss +0 -1
- package/src/components/Grid/Grid.jsx +2 -1
- package/src/components/Grid/GridItem.jsx +2 -1
- package/src/components/Icon/Icon.jsx +1 -1
- package/src/components/Icon/Icon.module.scss +1 -0
- package/src/components/List/List.jsx +1 -1
- package/src/components/LiveStream/LiveStream.jsx +1 -1
- package/src/components/Navigation/Navigation.jsx +13 -4
- package/src/components/Prose/Prose.jsx +2 -1
- package/src/components/SiteContainer/SiteContainer.jsx +1 -1
- package/src/components/Tooltip/Tooltip.jsx +1 -1
- package/src/hooks/index.js +1 -0
- package/src/hooks/use-ids.js +7 -0
- package/src/utils/class-names.js +6 -0
- package/src/utils/index.js +1 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@newhighsco/chipset",
|
|
3
3
|
"description": "Shareable, theme-able component library by New High Score",
|
|
4
|
-
"version": "6.
|
|
4
|
+
"version": "6.18.0",
|
|
5
5
|
"author": "New High Score",
|
|
6
6
|
"license": "ISC",
|
|
7
7
|
"repository": {
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
"test": "jest --runInBand",
|
|
29
29
|
"test:list": "jest --listTests",
|
|
30
30
|
"snapshot": "chromatic --storybook-build-dir build --auto-accept-changes main --exit-once-uploaded --only-changed",
|
|
31
|
+
"analyze": "omlet analyze",
|
|
31
32
|
"lint": "concurrently yarn:lint:*",
|
|
32
33
|
"lint:js": "eslint --cache --ignore-path .gitignore .",
|
|
33
34
|
"lint:css": "stylelint --cache --ignore-path .gitignore '**/*.?(s)css'",
|
|
@@ -49,38 +50,39 @@
|
|
|
49
50
|
"@newhighsco/browserslist-config": "2.0.0",
|
|
50
51
|
"@newhighsco/commitlint-config": "1.1.46",
|
|
51
52
|
"@newhighsco/editor-config": "1.2.0",
|
|
52
|
-
"@newhighsco/eslint-config": "4.1.
|
|
53
|
-
"@newhighsco/postcss-config": "3.5.
|
|
53
|
+
"@newhighsco/eslint-config": "4.1.43",
|
|
54
|
+
"@newhighsco/postcss-config": "3.5.341",
|
|
54
55
|
"@newhighsco/prettier-config": "2.1.32",
|
|
55
56
|
"@newhighsco/release-config": "1.4.6",
|
|
56
|
-
"@newhighsco/storybook-preset": "7.
|
|
57
|
+
"@newhighsco/storybook-preset": "7.1.1",
|
|
57
58
|
"@newhighsco/stylelint-config": "4.0.17",
|
|
59
|
+
"@omlet/cli": "2.0.0",
|
|
58
60
|
"@storybook/react-webpack5": "8.6.14",
|
|
59
|
-
"@testing-library/dom": "10.4.
|
|
60
|
-
"@testing-library/jest-dom": "6.6.
|
|
61
|
+
"@testing-library/dom": "10.4.1",
|
|
62
|
+
"@testing-library/jest-dom": "6.6.4",
|
|
61
63
|
"@testing-library/react": "16.3.0",
|
|
62
64
|
"babel-loader": "10.0.0",
|
|
63
|
-
"chromatic": "13.1.
|
|
65
|
+
"chromatic": "13.1.3",
|
|
64
66
|
"concurrently": "9.2.0",
|
|
65
67
|
"eslint": "8.57.1",
|
|
66
68
|
"husky": "9.1.7",
|
|
67
69
|
"identity-obj-proxy": "3.0.0",
|
|
68
|
-
"jest": "30.0.
|
|
69
|
-
"jest-environment-jsdom": "30.0.
|
|
70
|
+
"jest": "30.0.5",
|
|
71
|
+
"jest-environment-jsdom": "30.0.5",
|
|
70
72
|
"jest-junit": "16.0.0",
|
|
71
73
|
"postcss": "8.5.6",
|
|
72
74
|
"prettier": "3.6.2",
|
|
73
|
-
"react": "19.1.
|
|
74
|
-
"react-dom": "19.1.
|
|
75
|
+
"react": "19.1.1",
|
|
76
|
+
"react-dom": "19.1.1",
|
|
75
77
|
"sass-true": "9.0.0",
|
|
76
78
|
"semantic-release": "24.2.7",
|
|
77
79
|
"storybook": "8.6.14",
|
|
78
|
-
"stylelint": "16.
|
|
79
|
-
"webpack": "5.
|
|
80
|
+
"stylelint": "16.23.1",
|
|
81
|
+
"webpack": "5.101.0"
|
|
80
82
|
},
|
|
81
83
|
"peerDependencies": {
|
|
82
|
-
"react": "19.1.
|
|
83
|
-
"react-dom": "19.1.
|
|
84
|
+
"react": "19.1.1",
|
|
85
|
+
"react-dom": "19.1.1"
|
|
84
86
|
},
|
|
85
87
|
"browserslist": [
|
|
86
88
|
"extends @newhighsco/browserslist-config"
|
|
@@ -95,6 +97,14 @@
|
|
|
95
97
|
"@newhighsco/eslint-config"
|
|
96
98
|
]
|
|
97
99
|
},
|
|
100
|
+
"omlet": {
|
|
101
|
+
"exports": {
|
|
102
|
+
".": "src/index.js"
|
|
103
|
+
},
|
|
104
|
+
"ignore": [
|
|
105
|
+
"example/**"
|
|
106
|
+
]
|
|
107
|
+
},
|
|
98
108
|
"prettier": "@newhighsco/prettier-config",
|
|
99
109
|
"release": {
|
|
100
110
|
"extends": "@newhighsco/release-config",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import classNames from 'classnames'
|
|
2
1
|
import { bool, func, node, object, oneOfType, shape, string } from 'prop-types'
|
|
3
2
|
import React from 'react'
|
|
4
3
|
|
|
4
|
+
import { classNames } from '../../utils'
|
|
5
5
|
import SmartLink from '../SmartLink'
|
|
6
6
|
|
|
7
7
|
const Button = ({ active, children, theme, className, setRef, ...rest }) => {
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import classNames from 'classnames'
|
|
2
1
|
import {
|
|
3
2
|
func,
|
|
4
3
|
node,
|
|
@@ -10,6 +9,7 @@ import {
|
|
|
10
9
|
} from 'prop-types'
|
|
11
10
|
import React from 'react'
|
|
12
11
|
|
|
12
|
+
import { classNames } from '../../utils'
|
|
13
13
|
import CardHeading from './CardHeading'
|
|
14
14
|
import CardImage from './CardImage'
|
|
15
15
|
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import classNames from 'classnames'
|
|
2
1
|
import { arrayOf, node, oneOf, oneOfType, shape, string } from 'prop-types'
|
|
3
2
|
import React from 'react'
|
|
4
3
|
|
|
4
|
+
import { classNames } from '../../utils'
|
|
5
|
+
|
|
5
6
|
const GridItem = ({ sizes, children, theme, className, ...rest }) => {
|
|
6
7
|
if (!children) return null
|
|
7
8
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import classNames from 'classnames'
|
|
2
1
|
import { bool, shape, string } from 'prop-types'
|
|
3
2
|
import React, { useEffect, useState } from 'react'
|
|
4
3
|
|
|
4
|
+
import { classNames } from '../../utils'
|
|
5
5
|
import Grid from '../Grid'
|
|
6
6
|
import ResponsiveMedia from '../ResponsiveMedia'
|
|
7
7
|
import VisuallyHidden from '../VisuallyHidden'
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import classNames from 'classnames'
|
|
2
1
|
import { array, bool, func, shape, string } from 'prop-types'
|
|
3
2
|
import React from 'react'
|
|
4
3
|
|
|
5
|
-
import { useToggle } from '../../hooks'
|
|
4
|
+
import { useIds, useToggle } from '../../hooks'
|
|
5
|
+
import { classNames } from '../../utils'
|
|
6
6
|
import Button from '../Button'
|
|
7
7
|
import Icon from '../Icon'
|
|
8
8
|
import List from '../List'
|
|
@@ -22,6 +22,7 @@ const Navigation = ({
|
|
|
22
22
|
className
|
|
23
23
|
}) => {
|
|
24
24
|
const [visible, setVisibility] = useToggle(!toggle)
|
|
25
|
+
const [titleId, menuId] = useIds(['title', 'menu'])
|
|
25
26
|
|
|
26
27
|
if (!links.length) return null
|
|
27
28
|
|
|
@@ -31,11 +32,18 @@ const Navigation = ({
|
|
|
31
32
|
}
|
|
32
33
|
|
|
33
34
|
return (
|
|
34
|
-
<nav
|
|
35
|
-
|
|
35
|
+
<nav
|
|
36
|
+
aria-labelledby={titleId}
|
|
37
|
+
role="navigation"
|
|
38
|
+
className={classNames(theme?.root, className)}
|
|
39
|
+
>
|
|
40
|
+
<VisuallyHidden as="h2" id={titleId}>
|
|
41
|
+
{title}
|
|
42
|
+
</VisuallyHidden>
|
|
36
43
|
{toggle && (
|
|
37
44
|
<Button
|
|
38
45
|
active={visible}
|
|
46
|
+
aria-controls={menuId}
|
|
39
47
|
aria-expanded={visible}
|
|
40
48
|
onClick={toggleVisibility}
|
|
41
49
|
theme={{ root: theme?.toggle, active: theme?.toggleActive }}
|
|
@@ -49,6 +57,7 @@ const Navigation = ({
|
|
|
49
57
|
</Button>
|
|
50
58
|
)}
|
|
51
59
|
<List
|
|
60
|
+
id={menuId}
|
|
52
61
|
role="menubar"
|
|
53
62
|
unstyled
|
|
54
63
|
inline={inline}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import classNames from 'classnames'
|
|
2
1
|
import { node, shape, string } from 'prop-types'
|
|
3
2
|
import React from 'react'
|
|
4
3
|
|
|
4
|
+
import { classNames } from '../../utils'
|
|
5
|
+
|
|
5
6
|
const Prose = ({ html, children, theme, className, ...rest }) => {
|
|
6
7
|
if (!html && !children) return null
|
|
7
8
|
|
package/src/hooks/index.js
CHANGED
package/src/utils/index.js
CHANGED