@instructure/ui-menu 10.0.1-snapshot-3 → 10.0.1-snapshot-6
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 +1 -1
- package/es/Menu/MenuItem/props.js +3 -2
- package/lib/Menu/MenuItem/props.js +3 -2
- package/package.json +19 -19
- package/src/Menu/MenuItem/props.ts +8 -2
- package/src/Menu/README.md +1 -1
- package/tsconfig.build.tsbuildinfo +1 -1
- package/types/Menu/MenuItem/index.d.ts +2 -0
- package/types/Menu/MenuItem/index.d.ts.map +1 -1
- package/types/Menu/MenuItem/props.d.ts +4 -0
- package/types/Menu/MenuItem/props.d.ts.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
## [10.0.1-snapshot-
|
|
6
|
+
## [10.0.1-snapshot-6](https://github.com/instructure/instructure-ui/compare/v10.0.0...v10.0.1-snapshot-6) (2024-08-09)
|
|
7
7
|
|
|
8
8
|
**Note:** Version bump only for package @instructure/ui-menu
|
|
9
9
|
|
|
@@ -39,7 +39,8 @@ const propTypes = {
|
|
|
39
39
|
// eslint-disable-line react/require-default-props
|
|
40
40
|
type: PropTypes.oneOf(['button', 'checkbox', 'radio', 'flyout']),
|
|
41
41
|
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
|
|
42
|
-
href: PropTypes.string
|
|
42
|
+
href: PropTypes.string,
|
|
43
|
+
target: PropTypes.string
|
|
43
44
|
};
|
|
44
|
-
const allowedProps = ['children', 'defaultSelected', 'selected', 'onSelect', 'onClick', 'onKeyDown', 'onKeyUp', 'onMouseOver', 'controls', 'disabled', 'as', 'type', 'value', 'href'];
|
|
45
|
+
const allowedProps = ['children', 'defaultSelected', 'selected', 'onSelect', 'onClick', 'onKeyDown', 'onKeyUp', 'onMouseOver', 'controls', 'disabled', 'as', 'type', 'value', 'href', 'target'];
|
|
45
46
|
export { propTypes, allowedProps };
|
|
@@ -46,6 +46,7 @@ const propTypes = exports.propTypes = {
|
|
|
46
46
|
// eslint-disable-line react/require-default-props
|
|
47
47
|
type: _propTypes.default.oneOf(['button', 'checkbox', 'radio', 'flyout']),
|
|
48
48
|
value: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
|
|
49
|
-
href: _propTypes.default.string
|
|
49
|
+
href: _propTypes.default.string,
|
|
50
|
+
target: _propTypes.default.string
|
|
50
51
|
};
|
|
51
|
-
const allowedProps = exports.allowedProps = ['children', 'defaultSelected', 'selected', 'onSelect', 'onClick', 'onKeyDown', 'onKeyUp', 'onMouseOver', 'controls', 'disabled', 'as', 'type', 'value', 'href'];
|
|
52
|
+
const allowedProps = exports.allowedProps = ['children', 'defaultSelected', 'selected', 'onSelect', 'onClick', 'onKeyDown', 'onKeyUp', 'onMouseOver', 'controls', 'disabled', 'as', 'type', 'value', 'href', 'target'];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@instructure/ui-menu",
|
|
3
|
-
"version": "10.0.1-snapshot-
|
|
3
|
+
"version": "10.0.1-snapshot-6",
|
|
4
4
|
"description": "A dropdown menu component",
|
|
5
5
|
"author": "Instructure, Inc. Engineering and Product Design",
|
|
6
6
|
"module": "./es/index.js",
|
|
@@ -23,11 +23,11 @@
|
|
|
23
23
|
},
|
|
24
24
|
"license": "MIT",
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@instructure/ui-axe-check": "10.0.1-snapshot-
|
|
27
|
-
"@instructure/ui-babel-preset": "10.0.1-snapshot-
|
|
28
|
-
"@instructure/ui-color-utils": "10.0.1-snapshot-
|
|
29
|
-
"@instructure/ui-test-utils": "10.0.1-snapshot-
|
|
30
|
-
"@instructure/ui-themes": "10.0.1-snapshot-
|
|
26
|
+
"@instructure/ui-axe-check": "10.0.1-snapshot-6",
|
|
27
|
+
"@instructure/ui-babel-preset": "10.0.1-snapshot-6",
|
|
28
|
+
"@instructure/ui-color-utils": "10.0.1-snapshot-6",
|
|
29
|
+
"@instructure/ui-test-utils": "10.0.1-snapshot-6",
|
|
30
|
+
"@instructure/ui-themes": "10.0.1-snapshot-6",
|
|
31
31
|
"@testing-library/jest-dom": "^6.4.6",
|
|
32
32
|
"@testing-library/react": "^15.0.7",
|
|
33
33
|
"@testing-library/user-event": "^14.5.2",
|
|
@@ -35,19 +35,19 @@
|
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@babel/runtime": "^7.24.5",
|
|
38
|
-
"@instructure/console": "10.0.1-snapshot-
|
|
39
|
-
"@instructure/emotion": "10.0.1-snapshot-
|
|
40
|
-
"@instructure/shared-types": "10.0.1-snapshot-
|
|
41
|
-
"@instructure/ui-a11y-utils": "10.0.1-snapshot-
|
|
42
|
-
"@instructure/ui-dom-utils": "10.0.1-snapshot-
|
|
43
|
-
"@instructure/ui-icons": "10.0.1-snapshot-
|
|
44
|
-
"@instructure/ui-popover": "10.0.1-snapshot-
|
|
45
|
-
"@instructure/ui-position": "10.0.1-snapshot-
|
|
46
|
-
"@instructure/ui-prop-types": "10.0.1-snapshot-
|
|
47
|
-
"@instructure/ui-react-utils": "10.0.1-snapshot-
|
|
48
|
-
"@instructure/ui-testable": "10.0.1-snapshot-
|
|
49
|
-
"@instructure/ui-utils": "10.0.1-snapshot-
|
|
50
|
-
"@instructure/ui-view": "10.0.1-snapshot-
|
|
38
|
+
"@instructure/console": "10.0.1-snapshot-6",
|
|
39
|
+
"@instructure/emotion": "10.0.1-snapshot-6",
|
|
40
|
+
"@instructure/shared-types": "10.0.1-snapshot-6",
|
|
41
|
+
"@instructure/ui-a11y-utils": "10.0.1-snapshot-6",
|
|
42
|
+
"@instructure/ui-dom-utils": "10.0.1-snapshot-6",
|
|
43
|
+
"@instructure/ui-icons": "10.0.1-snapshot-6",
|
|
44
|
+
"@instructure/ui-popover": "10.0.1-snapshot-6",
|
|
45
|
+
"@instructure/ui-position": "10.0.1-snapshot-6",
|
|
46
|
+
"@instructure/ui-prop-types": "10.0.1-snapshot-6",
|
|
47
|
+
"@instructure/ui-react-utils": "10.0.1-snapshot-6",
|
|
48
|
+
"@instructure/ui-testable": "10.0.1-snapshot-6",
|
|
49
|
+
"@instructure/ui-utils": "10.0.1-snapshot-6",
|
|
50
|
+
"@instructure/ui-view": "10.0.1-snapshot-6",
|
|
51
51
|
"keycode": "^2",
|
|
52
52
|
"prop-types": "^15.8.1"
|
|
53
53
|
},
|
|
@@ -88,6 +88,10 @@ type MenuItemOwnProps = {
|
|
|
88
88
|
* Value of the `href` prop that will be put on the underlying DOM element.
|
|
89
89
|
*/
|
|
90
90
|
href?: string
|
|
91
|
+
/**
|
|
92
|
+
* Where to display the linked URL, as the name for a browsing context (a tab, window, or <iframe>).
|
|
93
|
+
*/
|
|
94
|
+
target?: string
|
|
91
95
|
}
|
|
92
96
|
|
|
93
97
|
type PropKeys = keyof MenuItemOwnProps
|
|
@@ -115,7 +119,8 @@ const propTypes: PropValidators<PropKeys> = {
|
|
|
115
119
|
as: PropTypes.elementType, // eslint-disable-line react/require-default-props
|
|
116
120
|
type: PropTypes.oneOf(['button', 'checkbox', 'radio', 'flyout']),
|
|
117
121
|
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
|
|
118
|
-
href: PropTypes.string
|
|
122
|
+
href: PropTypes.string,
|
|
123
|
+
target: PropTypes.string,
|
|
119
124
|
}
|
|
120
125
|
|
|
121
126
|
const allowedProps: AllowedPropKeys = [
|
|
@@ -132,7 +137,8 @@ const allowedProps: AllowedPropKeys = [
|
|
|
132
137
|
'as',
|
|
133
138
|
'type',
|
|
134
139
|
'value',
|
|
135
|
-
'href'
|
|
140
|
+
'href',
|
|
141
|
+
'target'
|
|
136
142
|
]
|
|
137
143
|
type MenuItemState = {
|
|
138
144
|
selected: boolean
|
package/src/Menu/README.md
CHANGED
|
@@ -53,7 +53,7 @@ class Example extends React.Component {
|
|
|
53
53
|
mountNode={() => document.getElementById('main')}
|
|
54
54
|
>
|
|
55
55
|
<Menu.Item value="mastery">Learning Mastery</Menu.Item>
|
|
56
|
-
<Menu.Item href="https://instructure.github.io/instructure-ui/">Default (Grid view)</Menu.Item>
|
|
56
|
+
<Menu.Item href="https://instructure.github.io/instructure-ui/" target="_blank">Default (Grid view)</Menu.Item>
|
|
57
57
|
<Menu.Item disabled>Individual (List view)</Menu.Item>
|
|
58
58
|
<Menu label="More Options">
|
|
59
59
|
<Menu.Group
|