@instructure/ui-side-nav-bar 8.56.0 → 8.56.2-pr-snapshot-1721749364069

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 CHANGED
@@ -3,6 +3,22 @@
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
+ ## [8.56.2-pr-snapshot-1721749364069](https://github.com/instructure/instructure-ui/compare/v8.56.1...v8.56.2-pr-snapshot-1721749364069) (2024-07-23)
7
+
8
+ **Note:** Version bump only for package @instructure/ui-side-nav-bar
9
+
10
+
11
+
12
+
13
+
14
+ ## [8.56.1](https://github.com/instructure/instructure-ui/compare/v8.56.0...v8.56.1) (2024-06-13)
15
+
16
+ **Note:** Version bump only for package @instructure/ui-side-nav-bar
17
+
18
+
19
+
20
+
21
+
6
22
  # [8.56.0](https://github.com/instructure/instructure-ui/compare/v8.55.1...v8.56.0) (2024-05-06)
7
23
 
8
24
  **Note:** Version bump only for package @instructure/ui-side-nav-bar
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.SideNavBarItemLocator = void 0;
7
- var _locator = require("@instructure/ui-test-locator/lib/utils/locator.js");
8
- var _TooltipLocator = require("@instructure/ui-tooltip/lib/Tooltip/TooltipLocator");
7
+ var _uiTestLocator = require("@instructure/ui-test-locator");
8
+ var _TooltipLocator = require("@instructure/ui-tooltip/es/Tooltip/TooltipLocator");
9
9
  var _index = require("./index");
10
10
  /*
11
11
  * The MIT License (MIT)
@@ -35,6 +35,6 @@ var _index = require("./index");
35
35
  // eslint-disable-next-line no-restricted-imports
36
36
 
37
37
  // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
38
- const SideNavBarItemLocator = exports.SideNavBarItemLocator = (0, _locator.locator)(_index.SideNavBarItem.selector, {
38
+ const SideNavBarItemLocator = exports.SideNavBarItemLocator = (0, _uiTestLocator.locator)(_index.SideNavBarItem.selector, {
39
39
  findTooltipContent: (...args) => _TooltipLocator.TooltipLocator.findContent(...args)
40
40
  });
@@ -6,11 +6,10 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = exports.SideNavBarItem = void 0;
8
8
  var _react = require("react");
9
- var _testable = require("@instructure/ui-testable/lib/testable.js");
10
- var _omitProps = require("@instructure/ui-react-utils/lib/omitProps.js");
11
- var _getElementType = require("@instructure/ui-react-utils/lib/getElementType.js");
12
- var _Tooltip = require("@instructure/ui-tooltip/lib/Tooltip");
13
- var _hasVisibleChildren = require("@instructure/ui-a11y-utils/lib/hasVisibleChildren.js");
9
+ var _uiTestable = require("@instructure/ui-testable");
10
+ var _uiReactUtils = require("@instructure/ui-react-utils");
11
+ var _uiTooltip = require("@instructure/ui-tooltip");
12
+ var _uiA11yUtils = require("@instructure/ui-a11y-utils");
14
13
  var _emotion = require("@instructure/emotion");
15
14
  var _styles = _interopRequireDefault(require("./styles"));
16
15
  var _theme = _interopRequireDefault(require("./theme"));
@@ -46,7 +45,7 @@ parent: SideNavBar
46
45
  id: SideNavBar.Item
47
46
  ---
48
47
  **/
49
- let SideNavBarItem = exports.SideNavBarItem = (_dec = (0, _emotion.withStyle)(_styles.default, _theme.default), _dec2 = (0, _testable.testable)(), _dec(_class = _dec2(_class = (_class2 = class SideNavBarItem extends _react.Component {
48
+ let SideNavBarItem = exports.SideNavBarItem = (_dec = (0, _emotion.withStyle)(_styles.default, _theme.default), _dec2 = (0, _uiTestable.testable)(), _dec(_class = _dec2(_class = (_class2 = class SideNavBarItem extends _react.Component {
50
49
  constructor(...args) {
51
50
  super(...args);
52
51
  this.ref = null;
@@ -72,13 +71,13 @@ let SideNavBarItem = exports.SideNavBarItem = (_dec = (0, _emotion.withStyle)(_s
72
71
  }
73
72
  renderLink(addRef) {
74
73
  var _this$props$styles, _this$props$styles2, _this$props$styles3;
75
- const ElementType = (0, _getElementType.getElementType)(SideNavBarItem, this.props);
74
+ const ElementType = (0, _uiReactUtils.getElementType)(SideNavBarItem, this.props);
76
75
  const _this$props3 = this.props,
77
76
  href = _this$props3.href,
78
77
  onClick = _this$props3.onClick,
79
78
  icon = _this$props3.icon,
80
79
  label = _this$props3.label;
81
- const props = (0, _omitProps.omitProps)(this.props, SideNavBarItem.allowedProps);
80
+ const props = (0, _uiReactUtils.omitProps)(this.props, SideNavBarItem.allowedProps);
82
81
  return (0, _emotion.jsx)(ElementType, Object.assign({}, props, {
83
82
  href: href,
84
83
  onClick: onClick,
@@ -96,9 +95,9 @@ let SideNavBarItem = exports.SideNavBarItem = (_dec = (0, _emotion.withStyle)(_s
96
95
  const _this$props4 = this.props,
97
96
  minimized = _this$props4.minimized,
98
97
  label = _this$props4.label;
99
- const hasTooltip = minimized && (0, _hasVisibleChildren.hasVisibleChildren)(label);
98
+ const hasTooltip = minimized && (0, _uiA11yUtils.hasVisibleChildren)(label);
100
99
  const link = this.renderLink(!hasTooltip);
101
- return hasTooltip ? (0, _emotion.jsx)(_Tooltip.Tooltip, {
100
+ return hasTooltip ? (0, _emotion.jsx)(_uiTooltip.Tooltip, {
102
101
  renderTip: label,
103
102
  placement: "end",
104
103
  elementRef: this.handleRef
@@ -10,7 +10,7 @@ Object.defineProperty(exports, "SideNavBarItemLocator", {
10
10
  }
11
11
  });
12
12
  exports.SideNavBarLocator = void 0;
13
- var _locator = require("@instructure/ui-test-locator/lib/utils/locator.js");
13
+ var _uiTestLocator = require("@instructure/ui-test-locator");
14
14
  var _index = require("./index");
15
15
  var _SideNavBarItemLocator = require("./SideNavBarItem/SideNavBarItemLocator");
16
16
  /*
@@ -38,7 +38,7 @@ var _SideNavBarItemLocator = require("./SideNavBarItem/SideNavBarItemLocator");
38
38
  */
39
39
 
40
40
  // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
41
- const SideNavBarLocator = exports.SideNavBarLocator = (0, _locator.locator)(_index.SideNavBar.selector, {
41
+ const SideNavBarLocator = exports.SideNavBarLocator = (0, _uiTestLocator.locator)(_index.SideNavBar.selector, {
42
42
  findAllItems: (...args) => {
43
43
  return _SideNavBarItemLocator.SideNavBarItemLocator.findAll(...args);
44
44
  },
@@ -14,11 +14,10 @@ Object.defineProperty(exports, "SideNavBarItem", {
14
14
  });
15
15
  exports.default = void 0;
16
16
  var _react = _interopRequireWildcard(require("react"));
17
- var _testable = require("@instructure/ui-testable/lib/testable.js");
18
- var _omitProps = require("@instructure/ui-react-utils/lib/omitProps.js");
19
- var _safeCloneElement = require("@instructure/ui-react-utils/lib/safeCloneElement.js");
20
- var _IconMoveStartLine = require("@instructure/ui-icons/lib/IconMoveStartLine.js");
21
- var _ScreenReaderContent = require("@instructure/ui-a11y-content/lib/ScreenReaderContent");
17
+ var _uiTestable = require("@instructure/ui-testable");
18
+ var _uiReactUtils = require("@instructure/ui-react-utils");
19
+ var _uiIcons = require("@instructure/ui-icons");
20
+ var _uiA11yContent = require("@instructure/ui-a11y-content");
22
21
  var _emotion = require("@instructure/emotion");
23
22
  var _SideNavBarItem = require("./SideNavBarItem");
24
23
  var _styles = _interopRequireDefault(require("./styles"));
@@ -60,7 +59,7 @@ const navMinimized = ({
60
59
  category: components
61
60
  ---
62
61
  **/
63
- let SideNavBar = exports.SideNavBar = (_dec = (0, _emotion.withStyle)(_styles.default, _theme.default), _dec2 = (0, _testable.testable)(), _dec(_class = _dec2(_class = (_class2 = class SideNavBar extends _react.Component {
62
+ let SideNavBar = exports.SideNavBar = (_dec = (0, _emotion.withStyle)(_styles.default, _theme.default), _dec2 = (0, _uiTestable.testable)(), _dec(_class = _dec2(_class = (_class2 = class SideNavBar extends _react.Component {
64
63
  constructor(props) {
65
64
  super(props);
66
65
  this.ref = null;
@@ -100,7 +99,7 @@ let SideNavBar = exports.SideNavBar = (_dec = (0, _emotion.withStyle)(_styles.de
100
99
  renderChildren() {
101
100
  return _react.Children.map(this.props.children, child => {
102
101
  var _this$props$styles;
103
- const navItem = (0, _safeCloneElement.safeCloneElement)(child, {
102
+ const navItem = (0, _uiReactUtils.safeCloneElement)(child, {
104
103
  minimized: this.state.minimized
105
104
  });
106
105
  return (0, _emotion.jsx)("li", {
@@ -114,7 +113,7 @@ let SideNavBar = exports.SideNavBar = (_dec = (0, _emotion.withStyle)(_styles.de
114
113
  render() {
115
114
  var _this$props$styles2, _this$props$styles3, _this$props$styles4;
116
115
  const label = this.props.label;
117
- const props = (0, _omitProps.omitProps)(this.props, SideNavBar.allowedProps, ['minimized']);
116
+ const props = (0, _uiReactUtils.omitProps)(this.props, SideNavBar.allowedProps, ['minimized']);
118
117
  return (0, _emotion.jsx)("nav", Object.assign({}, props, {
119
118
  css: (_this$props$styles2 = this.props.styles) === null || _this$props$styles2 === void 0 ? void 0 : _this$props$styles2.navigation,
120
119
  "aria-label": label,
@@ -126,11 +125,11 @@ let SideNavBar = exports.SideNavBar = (_dec = (0, _emotion.withStyle)(_styles.de
126
125
  }, this.renderChildren()), (0, _emotion.jsx)(_SideNavBarItem.SideNavBarItem, {
127
126
  "aria-expanded": !this.minimized,
128
127
  onClick: this.handleNavToggle,
129
- icon: (0, _emotion.jsx)(_IconMoveStartLine.IconMoveStartLine, {
128
+ icon: (0, _emotion.jsx)(_uiIcons.IconMoveStartLine, {
130
129
  css: (_this$props$styles4 = this.props.styles) === null || _this$props$styles4 === void 0 ? void 0 : _this$props$styles4.toggleIcon,
131
130
  inline: false
132
131
  }),
133
- label: (0, _emotion.jsx)(_ScreenReaderContent.ScreenReaderContent, null, this.toggleMessage())
132
+ label: (0, _emotion.jsx)(_uiA11yContent.ScreenReaderContent, null, this.toggleMessage())
134
133
  }));
135
134
  }
136
135
  }, _class2.displayName = "SideNavBar", _class2.componentId = 'SideNavBar', _class2.allowedProps = _props.allowedProps, _class2.propTypes = _props.propTypes, _class2.defaultProps = {
@@ -6,8 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.propTypes = exports.allowedProps = void 0;
8
8
  var _propTypes = _interopRequireDefault(require("prop-types"));
9
- var _controllable = require("@instructure/ui-prop-types/lib/controllable.js");
10
- var _Children = require("@instructure/ui-prop-types/lib/Children.js");
9
+ var _uiPropTypes = require("@instructure/ui-prop-types");
11
10
  var _SideNavBarItem = require("./SideNavBarItem");
12
11
  /*
13
12
  * The MIT License (MIT)
@@ -34,8 +33,8 @@ var _SideNavBarItem = require("./SideNavBarItem");
34
33
  */
35
34
 
36
35
  const propTypes = exports.propTypes = {
37
- children: _Children.Children.oneOf([_SideNavBarItem.SideNavBarItem]),
38
- minimized: (0, _controllable.controllable)(_propTypes.default.bool, 'onMinimized', 'defaultMinimized'),
36
+ children: _uiPropTypes.Children.oneOf([_SideNavBarItem.SideNavBarItem]),
37
+ minimized: (0, _uiPropTypes.controllable)(_propTypes.default.bool, 'onMinimized', 'defaultMinimized'),
39
38
  defaultMinimized: _propTypes.default.bool,
40
39
  onMinimized: _propTypes.default.func,
41
40
  label: _propTypes.default.string.isRequired,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instructure/ui-side-nav-bar",
3
- "version": "8.56.0",
3
+ "version": "8.56.2-pr-snapshot-1721749364069",
4
4
  "description": "Main and application level navigational components",
5
5
  "author": "Instructure, Inc. Engineering and Product Design",
6
6
  "module": "./es/index.js",
@@ -23,32 +23,32 @@
23
23
  },
24
24
  "license": "MIT",
25
25
  "devDependencies": {
26
- "@instructure/ui-babel-preset": "8.56.0",
27
- "@instructure/ui-color-utils": "8.56.0",
28
- "@instructure/ui-test-locator": "8.56.0",
29
- "@instructure/ui-test-utils": "8.56.0",
30
- "@instructure/ui-themes": "8.56.0"
26
+ "@instructure/ui-babel-preset": "8.56.2-pr-snapshot-1721749364069",
27
+ "@instructure/ui-color-utils": "8.56.2-pr-snapshot-1721749364069",
28
+ "@instructure/ui-test-locator": "8.56.2-pr-snapshot-1721749364069",
29
+ "@instructure/ui-test-utils": "8.56.2-pr-snapshot-1721749364069",
30
+ "@instructure/ui-themes": "8.56.2-pr-snapshot-1721749364069"
31
31
  },
32
32
  "dependencies": {
33
33
  "@babel/runtime": "^7.23.2",
34
- "@instructure/console": "8.56.0",
35
- "@instructure/debounce": "8.56.0",
36
- "@instructure/emotion": "8.56.0",
37
- "@instructure/shared-types": "8.56.0",
38
- "@instructure/ui-a11y-content": "8.56.0",
39
- "@instructure/ui-a11y-utils": "8.56.0",
40
- "@instructure/ui-badge": "8.56.0",
41
- "@instructure/ui-dom-utils": "8.56.0",
42
- "@instructure/ui-focusable": "8.56.0",
43
- "@instructure/ui-icons": "8.56.0",
44
- "@instructure/ui-menu": "8.56.0",
45
- "@instructure/ui-prop-types": "8.56.0",
46
- "@instructure/ui-react-utils": "8.56.0",
47
- "@instructure/ui-testable": "8.56.0",
48
- "@instructure/ui-tooltip": "8.56.0",
49
- "@instructure/ui-truncate-list": "8.56.0",
50
- "@instructure/ui-utils": "8.56.0",
51
- "@instructure/ui-view": "8.56.0",
34
+ "@instructure/console": "8.56.2-pr-snapshot-1721749364069",
35
+ "@instructure/debounce": "8.56.2-pr-snapshot-1721749364069",
36
+ "@instructure/emotion": "8.56.2-pr-snapshot-1721749364069",
37
+ "@instructure/shared-types": "8.56.2-pr-snapshot-1721749364069",
38
+ "@instructure/ui-a11y-content": "8.56.2-pr-snapshot-1721749364069",
39
+ "@instructure/ui-a11y-utils": "8.56.2-pr-snapshot-1721749364069",
40
+ "@instructure/ui-badge": "8.56.2-pr-snapshot-1721749364069",
41
+ "@instructure/ui-dom-utils": "8.56.2-pr-snapshot-1721749364069",
42
+ "@instructure/ui-focusable": "8.56.2-pr-snapshot-1721749364069",
43
+ "@instructure/ui-icons": "8.56.2-pr-snapshot-1721749364069",
44
+ "@instructure/ui-menu": "8.56.2-pr-snapshot-1721749364069",
45
+ "@instructure/ui-prop-types": "8.56.2-pr-snapshot-1721749364069",
46
+ "@instructure/ui-react-utils": "8.56.2-pr-snapshot-1721749364069",
47
+ "@instructure/ui-testable": "8.56.2-pr-snapshot-1721749364069",
48
+ "@instructure/ui-tooltip": "8.56.2-pr-snapshot-1721749364069",
49
+ "@instructure/ui-truncate-list": "8.56.2-pr-snapshot-1721749364069",
50
+ "@instructure/ui-utils": "8.56.2-pr-snapshot-1721749364069",
51
+ "@instructure/ui-view": "8.56.2-pr-snapshot-1721749364069",
52
52
  "prop-types": "^15.8.1"
53
53
  },
54
54
  "peerDependencies": {