@instructure/ui-list 8.33.1 → 8.33.2

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.
Files changed (47) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/es/InlineList/InlineListItem/InlineListItemLocator.js +2 -1
  3. package/es/InlineList/InlineListItem/index.js +9 -22
  4. package/es/InlineList/InlineListItem/props.js +1 -0
  5. package/es/InlineList/InlineListItem/styles.js +3 -4
  6. package/es/InlineList/InlineListItem/theme.js +5 -5
  7. package/es/InlineList/InlineListLocator.js +2 -1
  8. package/es/InlineList/__examples__/InlineList.examples.js +3 -2
  9. package/es/InlineList/index.js +4 -13
  10. package/es/InlineList/props.js +1 -0
  11. package/es/List/ListItem/index.js +9 -21
  12. package/es/List/ListItem/props.js +1 -0
  13. package/es/List/ListItem/styles.js +3 -4
  14. package/es/List/ListItem/theme.js +6 -6
  15. package/es/List/ListLocator.js +5 -2
  16. package/es/List/__examples__/List.examples.js +1 -1
  17. package/es/List/index.js +6 -19
  18. package/es/List/locator.js +1 -0
  19. package/es/List/props.js +1 -0
  20. package/es/List/styles.js +1 -2
  21. package/es/List/theme.js +3 -3
  22. package/es/index.js +1 -0
  23. package/lib/InlineList/InlineListItem/InlineListItemLocator.js +1 -4
  24. package/lib/InlineList/InlineListItem/index.js +9 -30
  25. package/lib/InlineList/InlineListItem/locator.js +0 -2
  26. package/lib/InlineList/InlineListItem/props.js +1 -4
  27. package/lib/InlineList/InlineListItem/styles.js +2 -5
  28. package/lib/InlineList/InlineListItem/theme.js +5 -6
  29. package/lib/InlineList/InlineListLocator.js +1 -4
  30. package/lib/InlineList/__examples__/InlineList.examples.js +2 -6
  31. package/lib/InlineList/index.js +4 -22
  32. package/lib/InlineList/locator.js +0 -2
  33. package/lib/InlineList/props.js +1 -6
  34. package/lib/List/ListItem/index.js +9 -30
  35. package/lib/List/ListItem/props.js +1 -4
  36. package/lib/List/ListItem/styles.js +2 -5
  37. package/lib/List/ListItem/theme.js +6 -7
  38. package/lib/List/ListLocator.js +3 -4
  39. package/lib/List/__examples__/List.examples.js +0 -5
  40. package/lib/List/index.js +6 -30
  41. package/lib/List/locator.js +0 -2
  42. package/lib/List/props.js +1 -6
  43. package/lib/List/styles.js +1 -3
  44. package/lib/List/theme.js +3 -4
  45. package/lib/index.js +0 -2
  46. package/package.json +13 -13
  47. package/tsconfig.build.tsbuildinfo +1 -1
package/CHANGELOG.md CHANGED
@@ -3,6 +3,10 @@
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.33.2](https://github.com/instructure/instructure-ui/compare/v8.33.1...v8.33.2) (2023-01-25)
7
+
8
+ **Note:** Version bump only for package @instructure/ui-list
9
+
6
10
  ## [8.33.1](https://github.com/instructure/instructure-ui/compare/v8.33.0...v8.33.1) (2023-01-06)
7
11
 
8
12
  **Note:** Version bump only for package @instructure/ui-list
@@ -23,8 +23,9 @@
23
23
  */
24
24
  import { locator } from '@instructure/ui-test-locator';
25
25
  import { InlineListLocator } from '../InlineListLocator';
26
- import { InlineListItem } from './index'; // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
26
+ import { InlineListItem } from './index';
27
27
 
28
+ // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
28
29
  export const InlineListItemLocator = locator(InlineListItem.selector, {
29
30
  findNestedOptions: function () {
30
31
  return InlineListLocator.find(...arguments);
@@ -1,8 +1,6 @@
1
1
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
2
2
  const _excluded = ["delimiter", "size", "margin", "padding", "elementRef", "children", "spacing", "styles"];
3
-
4
3
  var _dec, _dec2, _class, _class2;
5
-
6
4
  /*
7
5
  * The MIT License (MIT)
8
6
  *
@@ -26,7 +24,6 @@ var _dec, _dec2, _class, _class2;
26
24
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27
25
  * SOFTWARE.
28
26
  */
29
-
30
27
  /** @jsx jsx */
31
28
  import { Component } from 'react';
32
29
  import { View } from '@instructure/ui-view';
@@ -36,7 +33,6 @@ import { withStyle, jsx } from '@instructure/emotion';
36
33
  import generateStyle from './styles';
37
34
  import generateComponentTheme from './theme';
38
35
  import { propTypes, allowedProps } from './props';
39
-
40
36
  /**
41
37
  ---
42
38
  parent: InlineList
@@ -48,41 +44,33 @@ let InlineListItem = (_dec = withStyle(generateStyle, generateComponentTheme), _
48
44
  constructor() {
49
45
  super(...arguments);
50
46
  this.ref = null;
51
-
52
47
  this.handleRef = el => {
53
48
  const elementRef = this.props.elementRef;
54
49
  this.ref = el;
55
-
56
50
  if (typeof elementRef === 'function') {
57
51
  elementRef(el);
58
52
  }
59
53
  };
60
54
  }
61
-
62
55
  componentDidMount() {
63
56
  var _this$props$makeStyle, _this$props;
64
-
65
57
  (_this$props$makeStyle = (_this$props = this.props).makeStyles) === null || _this$props$makeStyle === void 0 ? void 0 : _this$props$makeStyle.call(_this$props);
66
58
  }
67
-
68
59
  componentDidUpdate() {
69
60
  var _this$props$makeStyle2, _this$props2;
70
-
71
61
  (_this$props$makeStyle2 = (_this$props2 = this.props).makeStyles) === null || _this$props$makeStyle2 === void 0 ? void 0 : _this$props$makeStyle2.call(_this$props2);
72
62
  }
73
-
74
63
  render() {
75
64
  const _this$props3 = this.props,
76
- delimiter = _this$props3.delimiter,
77
- size = _this$props3.size,
78
- margin = _this$props3.margin,
79
- padding = _this$props3.padding,
80
- elementRef = _this$props3.elementRef,
81
- children = _this$props3.children,
82
- spacing = _this$props3.spacing,
83
- styles = _this$props3.styles,
84
- rest = _objectWithoutProperties(_this$props3, _excluded);
85
-
65
+ delimiter = _this$props3.delimiter,
66
+ size = _this$props3.size,
67
+ margin = _this$props3.margin,
68
+ padding = _this$props3.padding,
69
+ elementRef = _this$props3.elementRef,
70
+ children = _this$props3.children,
71
+ spacing = _this$props3.spacing,
72
+ styles = _this$props3.styles,
73
+ rest = _objectWithoutProperties(_this$props3, _excluded);
86
74
  return jsx(View, Object.assign({}, passthroughProps(rest), {
87
75
  css: styles === null || styles === void 0 ? void 0 : styles.inlineListItem,
88
76
  as: "li",
@@ -96,7 +84,6 @@ let InlineListItem = (_dec = withStyle(generateStyle, generateComponentTheme), _
96
84
  "aria-hidden": "true"
97
85
  }));
98
86
  }
99
-
100
87
  }, _class2.displayName = "InlineListItem", _class2.componentId = 'InlineList.Item', _class2.propTypes = propTypes, _class2.allowedProps = allowedProps, _class2.defaultProps = {
101
88
  padding: 'none',
102
89
  spacing: 'none',
@@ -21,6 +21,7 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  import PropTypes from 'prop-types';
25
26
  import { ThemeablePropTypes } from '@instructure/emotion';
26
27
  const propTypes = {
@@ -21,8 +21,8 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
- import { logError as error } from '@instructure/console';
25
24
 
25
+ import { logError as error } from '@instructure/console';
26
26
  /**
27
27
  * ---
28
28
  * private: true
@@ -37,8 +37,8 @@ import { logError as error } from '@instructure/console';
37
37
  */
38
38
  const generateStyle = (componentTheme, props) => {
39
39
  const size = props.size,
40
- delimiter = props.delimiter,
41
- spacing = props.spacing;
40
+ delimiter = props.delimiter,
41
+ spacing = props.spacing;
42
42
  const withDelimiter = delimiter !== 'none';
43
43
  const withSpacing = spacing !== 'none';
44
44
  error(!(withDelimiter && withSpacing), `[InlineList] \`itemSpacing\` has no effect inside Lists with the \`delimiter\` prop set to anything other than \`none\`.`);
@@ -142,5 +142,4 @@ const generateStyle = (componentTheme, props) => {
142
142
  }
143
143
  };
144
144
  };
145
-
146
145
  export default generateStyle;
@@ -29,9 +29,9 @@
29
29
  */
30
30
  const generateComponentTheme = theme => {
31
31
  const colors = theme.colors,
32
- spacing = theme.spacing,
33
- typography = theme.typography,
34
- themeName = theme.key;
32
+ spacing = theme.spacing,
33
+ typography = theme.typography,
34
+ themeName = theme.key;
35
35
  const themeSpecificStyle = {
36
36
  canvas: {
37
37
  color: theme['ic-brand-font-color-dark']
@@ -59,9 +59,9 @@ const generateComponentTheme = theme => {
59
59
  spacingXLarge: spacing === null || spacing === void 0 ? void 0 : spacing.xLarge,
60
60
  spacingXXLarge: spacing === null || spacing === void 0 ? void 0 : spacing.xxLarge
61
61
  };
62
- return { ...componentVariables,
62
+ return {
63
+ ...componentVariables,
63
64
  ...themeSpecificStyle[themeName]
64
65
  };
65
66
  };
66
-
67
67
  export default generateComponentTheme;
@@ -23,8 +23,9 @@
23
23
  */
24
24
  import { locator } from '@instructure/ui-test-locator';
25
25
  import { InlineList } from './index';
26
- import { InlineListItemLocator } from './InlineListItem/InlineListItemLocator'; // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
26
+ import { InlineListItemLocator } from './InlineListItem/InlineListItemLocator';
27
27
 
28
+ // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
28
29
  export const InlineListLocator = locator(InlineList.selector, {
29
30
  findAllItems: function () {
30
31
  return InlineListItemLocator.findAll(...arguments);
@@ -1,5 +1,4 @@
1
1
  var _InlineList$Item, _InlineList$Item2, _InlineList$Item3;
2
-
3
2
  /*
4
3
  * The MIT License (MIT)
5
4
  *
@@ -23,6 +22,7 @@ var _InlineList$Item, _InlineList$Item2, _InlineList$Item3;
23
22
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
24
23
  * SOFTWARE.
25
24
  */
25
+
26
26
  import React from 'react';
27
27
  import { InlineList } from '../index';
28
28
  export default {
@@ -39,7 +39,8 @@ export default {
39
39
  };
40
40
  },
41
41
  filter: props => {
42
- return (// itemSpacing has no affect on the list if the delimiter prop is set
42
+ return (
43
+ // itemSpacing has no affect on the list if the delimiter prop is set
43
44
  // to anything other than 'none' so filter the others
44
45
  props.delimiter !== 'none' && props.itemSpacing !== 'none'
45
46
  );
@@ -1,8 +1,6 @@
1
1
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
2
2
  const _excluded = ["as", "margin", "elementRef"];
3
-
4
3
  var _dec, _class, _class2;
5
-
6
4
  /*
7
5
  * The MIT License (MIT)
8
6
  *
@@ -32,7 +30,6 @@ import { passthroughProps, safeCloneElement } from '@instructure/ui-react-utils'
32
30
  import { testable } from '@instructure/ui-testable';
33
31
  import { InlineListItem } from './InlineListItem';
34
32
  import { propTypes, allowedProps } from './props';
35
-
36
33
  /**
37
34
  ---
38
35
  category: components
@@ -43,17 +40,14 @@ let InlineList = (_dec = testable(), _dec(_class = (_class2 = class InlineList e
43
40
  constructor() {
44
41
  super(...arguments);
45
42
  this.ref = null;
46
-
47
43
  this.handleRef = el => {
48
44
  const elementRef = this.props.elementRef;
49
45
  this.ref = el;
50
-
51
46
  if (typeof elementRef === 'function') {
52
47
  elementRef(el);
53
48
  }
54
49
  };
55
50
  }
56
-
57
51
  renderChildren() {
58
52
  return Children.map(this.props.children, child => {
59
53
  if (!child) return; // ignore null, falsy children
@@ -65,14 +59,12 @@ let InlineList = (_dec = testable(), _dec(_class = (_class2 = class InlineList e
65
59
  });
66
60
  });
67
61
  }
68
-
69
62
  render() {
70
63
  const _this$props = this.props,
71
- as = _this$props.as,
72
- margin = _this$props.margin,
73
- elementRef = _this$props.elementRef,
74
- rest = _objectWithoutProperties(_this$props, _excluded);
75
-
64
+ as = _this$props.as,
65
+ margin = _this$props.margin,
66
+ elementRef = _this$props.elementRef,
67
+ rest = _objectWithoutProperties(_this$props, _excluded);
76
68
  return /*#__PURE__*/React.createElement(View, Object.assign({}, passthroughProps(rest), {
77
69
  as: as,
78
70
  margin: margin,
@@ -81,7 +73,6 @@ let InlineList = (_dec = testable(), _dec(_class = (_class2 = class InlineList e
81
73
  display: "block"
82
74
  }), this.renderChildren());
83
75
  }
84
-
85
76
  }, _class2.displayName = "InlineList", _class2.propTypes = propTypes, _class2.allowedProps = allowedProps, _class2.defaultProps = {
86
77
  itemSpacing: 'none',
87
78
  as: 'ul',
@@ -21,6 +21,7 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  import PropTypes from 'prop-types';
25
26
  import { Children as ChildrenPropTypes } from '@instructure/ui-prop-types';
26
27
  import { ThemeablePropTypes } from '@instructure/emotion';
@@ -1,8 +1,6 @@
1
1
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
2
2
  const _excluded = ["delimiter", "spacing", "size", "margin", "padding", "elementRef", "children", "styles"];
3
-
4
3
  var _dec, _dec2, _class, _class2;
5
-
6
4
  /*
7
5
  * The MIT License (MIT)
8
6
  *
@@ -36,7 +34,6 @@ import { withStyle, jsx } from '@instructure/emotion';
36
34
  import generateStyle from './styles';
37
35
  import generateComponentTheme from './theme';
38
36
  import { propTypes, allowedProps } from './props';
39
-
40
37
  /**
41
38
  ---
42
39
  parent: List
@@ -48,41 +45,33 @@ let ListItem = (_dec = withStyle(generateStyle, generateComponentTheme), _dec2 =
48
45
  constructor() {
49
46
  super(...arguments);
50
47
  this.ref = null;
51
-
52
48
  this.handleRef = el => {
53
49
  const elementRef = this.props.elementRef;
54
50
  this.ref = el;
55
-
56
51
  if (typeof elementRef === 'function') {
57
52
  elementRef(el);
58
53
  }
59
54
  };
60
55
  }
61
-
62
56
  componentDidMount() {
63
57
  var _this$props$makeStyle, _this$props;
64
-
65
58
  (_this$props$makeStyle = (_this$props = this.props).makeStyles) === null || _this$props$makeStyle === void 0 ? void 0 : _this$props$makeStyle.call(_this$props);
66
59
  }
67
-
68
60
  componentDidUpdate() {
69
61
  var _this$props$makeStyle2, _this$props2;
70
-
71
62
  (_this$props$makeStyle2 = (_this$props2 = this.props).makeStyles) === null || _this$props$makeStyle2 === void 0 ? void 0 : _this$props$makeStyle2.call(_this$props2);
72
63
  }
73
-
74
64
  render() {
75
65
  const _this$props3 = this.props,
76
- delimiter = _this$props3.delimiter,
77
- spacing = _this$props3.spacing,
78
- size = _this$props3.size,
79
- margin = _this$props3.margin,
80
- padding = _this$props3.padding,
81
- elementRef = _this$props3.elementRef,
82
- children = _this$props3.children,
83
- styles = _this$props3.styles,
84
- rest = _objectWithoutProperties(_this$props3, _excluded);
85
-
66
+ delimiter = _this$props3.delimiter,
67
+ spacing = _this$props3.spacing,
68
+ size = _this$props3.size,
69
+ margin = _this$props3.margin,
70
+ padding = _this$props3.padding,
71
+ elementRef = _this$props3.elementRef,
72
+ children = _this$props3.children,
73
+ styles = _this$props3.styles,
74
+ rest = _objectWithoutProperties(_this$props3, _excluded);
86
75
  return jsx(View, Object.assign({}, passthroughProps(rest), {
87
76
  css: styles === null || styles === void 0 ? void 0 : styles.listItem,
88
77
  as: "li",
@@ -92,7 +81,6 @@ let ListItem = (_dec = withStyle(generateStyle, generateComponentTheme), _dec2 =
92
81
  elementRef: this.handleRef
93
82
  }), children);
94
83
  }
95
-
96
84
  }, _class2.displayName = "ListItem", _class2.componentId = 'List.Item', _class2.propTypes = propTypes, _class2.allowedProps = allowedProps, _class2.defaultProps = {
97
85
  padding: 'none',
98
86
  spacing: 'none',
@@ -21,6 +21,7 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  import PropTypes from 'prop-types';
25
26
  import { ThemeablePropTypes } from '@instructure/emotion';
26
27
  const propTypes = {
@@ -21,8 +21,8 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
- import { logError as error } from '@instructure/console';
25
24
 
25
+ import { logError as error } from '@instructure/console';
26
26
  /**
27
27
  * ---
28
28
  * private: true
@@ -37,8 +37,8 @@ import { logError as error } from '@instructure/console';
37
37
  */
38
38
  const generateStyle = (componentTheme, props) => {
39
39
  const size = props.size,
40
- delimiter = props.delimiter,
41
- spacing = props.spacing;
40
+ delimiter = props.delimiter,
41
+ spacing = props.spacing;
42
42
  const withDelimiter = delimiter !== 'none';
43
43
  const withSpacing = spacing !== 'none';
44
44
  error(!(withDelimiter && withSpacing), `[List] \`itemSpacing\` has no effect inside Lists with the \`delimiter\` prop set to anything other than \`none\`.`);
@@ -123,5 +123,4 @@ const generateStyle = (componentTheme, props) => {
123
123
  }
124
124
  };
125
125
  };
126
-
127
126
  export default generateStyle;
@@ -29,10 +29,10 @@
29
29
  */
30
30
  const generateComponentTheme = theme => {
31
31
  const borders = theme.borders,
32
- colors = theme.colors,
33
- spacing = theme.spacing,
34
- typography = theme.typography,
35
- themeName = theme.key;
32
+ colors = theme.colors,
33
+ spacing = theme.spacing,
34
+ typography = theme.typography,
35
+ themeName = theme.key;
36
36
  const themeSpecificStyle = {
37
37
  canvas: {
38
38
  color: theme['ic-brand-font-color-dark']
@@ -57,9 +57,9 @@ const generateComponentTheme = theme => {
57
57
  delimiterDashedBorder: `${borders === null || borders === void 0 ? void 0 : borders.widthSmall} dashed ${colors === null || colors === void 0 ? void 0 : colors.borderMedium}`,
58
58
  delimiterSolidBorder: `${borders === null || borders === void 0 ? void 0 : borders.widthSmall} solid ${colors === null || colors === void 0 ? void 0 : colors.borderMedium}`
59
59
  };
60
- return { ...componentVariables,
60
+ return {
61
+ ...componentVariables,
61
62
  ...themeSpecificStyle[themeName]
62
63
  };
63
64
  };
64
-
65
65
  export default generateComponentTheme;
@@ -21,11 +21,14 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  import { locator } from '@instructure/ui-test-locator';
25
- import { List } from './index'; // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
26
+ import { List } from './index';
26
27
 
27
- const ListItemLocator = locator(List.Item.selector); // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
28
+ // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
29
+ const ListItemLocator = locator(List.Item.selector);
28
30
 
31
+ // @ts-expect-error ts-migrate(2339) FIXME: Property 'selector' does not exist on type 'typeof... Remove this comment to see the full error message
29
32
  export const ListLocator = locator(List.selector, {
30
33
  findAllItems: function () {
31
34
  return ListItemLocator.findAll(...arguments);
@@ -1,5 +1,4 @@
1
1
  var _List$Item, _List$Item2, _List$Item3;
2
-
3
2
  /*
4
3
  * The MIT License (MIT)
5
4
  *
@@ -23,6 +22,7 @@ var _List$Item, _List$Item2, _List$Item3;
23
22
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
24
23
  * SOFTWARE.
25
24
  */
25
+
26
26
  import React from 'react';
27
27
  import { List } from '../index';
28
28
  export default {
package/es/List/index.js CHANGED
@@ -1,8 +1,6 @@
1
1
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
2
2
  const _excluded = ["as", "margin", "isUnstyled", "elementRef", "styles"];
3
-
4
3
  var _dec, _dec2, _class, _class2;
5
-
6
4
  /*
7
5
  * The MIT License (MIT)
8
6
  *
@@ -37,7 +35,6 @@ import { withStyle, jsx } from '@instructure/emotion';
37
35
  import generateStyle from './styles';
38
36
  import generateComponentTheme from './theme';
39
37
  import { propTypes, allowedProps } from './props';
40
-
41
38
  /**
42
39
  ---
43
40
  category: components
@@ -48,29 +45,22 @@ let List = (_dec = withStyle(generateStyle, generateComponentTheme), _dec2 = tes
48
45
  constructor() {
49
46
  super(...arguments);
50
47
  this.ref = null;
51
-
52
48
  this.handleRef = el => {
53
49
  const elementRef = this.props.elementRef;
54
50
  this.ref = el;
55
-
56
51
  if (typeof elementRef === 'function') {
57
52
  elementRef(el);
58
53
  }
59
54
  };
60
55
  }
61
-
62
56
  componentDidMount() {
63
57
  var _this$props$makeStyle, _this$props;
64
-
65
58
  (_this$props$makeStyle = (_this$props = this.props).makeStyles) === null || _this$props$makeStyle === void 0 ? void 0 : _this$props$makeStyle.call(_this$props);
66
59
  }
67
-
68
60
  componentDidUpdate() {
69
61
  var _this$props$makeStyle2, _this$props2;
70
-
71
62
  (_this$props$makeStyle2 = (_this$props2 = this.props).makeStyles) === null || _this$props$makeStyle2 === void 0 ? void 0 : _this$props$makeStyle2.call(_this$props2);
72
63
  }
73
-
74
64
  renderChildren() {
75
65
  return Children.map(this.props.children, child => {
76
66
  if (!child) return; // ignore null, falsy children
@@ -83,16 +73,14 @@ let List = (_dec = withStyle(generateStyle, generateComponentTheme), _dec2 = tes
83
73
  });
84
74
  });
85
75
  }
86
-
87
76
  render() {
88
77
  const _this$props3 = this.props,
89
- as = _this$props3.as,
90
- margin = _this$props3.margin,
91
- isUnstyled = _this$props3.isUnstyled,
92
- elementRef = _this$props3.elementRef,
93
- styles = _this$props3.styles,
94
- rest = _objectWithoutProperties(_this$props3, _excluded);
95
-
78
+ as = _this$props3.as,
79
+ margin = _this$props3.margin,
80
+ isUnstyled = _this$props3.isUnstyled,
81
+ elementRef = _this$props3.elementRef,
82
+ styles = _this$props3.styles,
83
+ rest = _objectWithoutProperties(_this$props3, _excluded);
96
84
  return jsx(View, Object.assign({}, passthroughProps(rest), {
97
85
  css: styles === null || styles === void 0 ? void 0 : styles.list,
98
86
  as: as,
@@ -101,7 +89,6 @@ let List = (_dec = withStyle(generateStyle, generateComponentTheme), _dec2 = tes
101
89
  display: "block"
102
90
  }), this.renderChildren());
103
91
  }
104
-
105
92
  }, _class2.displayName = "List", _class2.componentId = 'List', _class2.propTypes = propTypes, _class2.allowedProps = allowedProps, _class2.defaultProps = {
106
93
  as: 'ul',
107
94
  delimiter: 'none',
@@ -21,6 +21,7 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  import { ListLocator } from './ListLocator';
25
26
  export { ListLocator };
26
27
  export default ListLocator;
package/es/List/props.js CHANGED
@@ -21,6 +21,7 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  import PropTypes from 'prop-types';
25
26
  import { Children as ChildrenPropTypes } from '@instructure/ui-prop-types';
26
27
  import { ThemeablePropTypes } from '@instructure/emotion';
package/es/List/styles.js CHANGED
@@ -34,7 +34,7 @@
34
34
  */
35
35
  const generateStyle = (componentTheme, props) => {
36
36
  const isUnstyled = props.isUnstyled,
37
- as = props.as;
37
+ as = props.as;
38
38
  const ordered = as === 'ol';
39
39
  return {
40
40
  list: {
@@ -61,5 +61,4 @@ const generateStyle = (componentTheme, props) => {
61
61
  }
62
62
  };
63
63
  };
64
-
65
64
  export default generateStyle;
package/es/List/theme.js CHANGED
@@ -29,14 +29,14 @@
29
29
  */
30
30
  const generateComponentTheme = theme => {
31
31
  const spacing = theme.spacing,
32
- typography = theme.typography;
32
+ typography = theme.typography;
33
33
  const componentVariables = {
34
34
  listPadding: spacing === null || spacing === void 0 ? void 0 : spacing.large,
35
35
  orderedNumberFontWeight: typography === null || typography === void 0 ? void 0 : typography.fontWeightBold,
36
36
  orderedNumberMargin: spacing === null || spacing === void 0 ? void 0 : spacing.xSmall
37
37
  };
38
- return { ...componentVariables
38
+ return {
39
+ ...componentVariables
39
40
  };
40
41
  };
41
-
42
42
  export default generateComponentTheme;
package/es/index.js CHANGED
@@ -21,5 +21,6 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
+
24
25
  export { InlineList } from './InlineList';
25
26
  export { List, ListItem } from './List';
@@ -4,13 +4,9 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.InlineListItemLocator = void 0;
7
-
8
7
  var _locator = require("@instructure/ui-test-locator/lib/utils/locator.js");
9
-
10
8
  var _InlineListLocator = require("../InlineListLocator");
11
-
12
9
  var _index = require("./index");
13
-
14
10
  /*
15
11
  * The MIT License (MIT)
16
12
  *
@@ -34,6 +30,7 @@ var _index = require("./index");
34
30
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
35
31
  * SOFTWARE.
36
32
  */
33
+
37
34
  // @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
35
  const InlineListItemLocator = (0, _locator.locator)(_index.InlineListItem.selector, {
39
36
  findNestedOptions: function () {