@instructure/ui-options 8.20.1-snapshot.0 → 8.20.1-snapshot.22

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.
@@ -21,18 +21,16 @@
21
21
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  * SOFTWARE.
23
23
  */
24
- const optionsThemeKeys = ['labelFontWeight', 'background', 'labelColor', 'labelPadding', 'nestedLabelPadding'];
24
+
25
25
  /**
26
26
  * Generates the theme object for the component from the theme and provided additional information
27
27
  * @param {Object} theme The actual theme object.
28
28
  * @return {Object} The final theme object with the overrides and component variables
29
29
  */
30
-
31
30
  const generateComponentTheme = theme => {
32
31
  const colors = theme.colors,
33
32
  typography = theme.typography,
34
- spacing = theme.spacing; // TODO: if updated, update optionsThemeKeys array too
35
-
33
+ spacing = theme.spacing;
36
34
  const componentVariables = {
37
35
  labelFontWeight: typography === null || typography === void 0 ? void 0 : typography.fontWeightBold,
38
36
  background: colors === null || colors === void 0 ? void 0 : colors.backgroundLightest,
@@ -44,5 +42,5 @@ const generateComponentTheme = theme => {
44
42
  };
45
43
  };
46
44
 
47
- export { generateComponentTheme as optionsThemeGenerator, optionsThemeKeys };
45
+ export { generateComponentTheme as optionsThemeGenerator };
48
46
  export default generateComponentTheme;
package/es/index.js CHANGED
@@ -22,6 +22,6 @@
22
22
  * SOFTWARE.
23
23
  */
24
24
  export { Options } from './Options';
25
- export { optionsThemeGenerator, optionsThemeKeys } from './Options/theme';
25
+ export { optionsThemeGenerator } from './Options/theme';
26
26
  export { optionsItemThemeGenerator } from './Options/Item/theme';
27
27
  export { optionsSeparatorThemeGenerator } from './Options/Separator/theme';
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.optionsThemeKeys = exports.optionsThemeGenerator = exports.default = void 0;
6
+ exports.optionsThemeGenerator = exports.default = void 0;
7
7
 
8
8
  /*
9
9
  * The MIT License (MIT)
@@ -28,20 +28,16 @@ exports.optionsThemeKeys = exports.optionsThemeGenerator = exports.default = voi
28
28
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
29
29
  * SOFTWARE.
30
30
  */
31
- const optionsThemeKeys = ['labelFontWeight', 'background', 'labelColor', 'labelPadding', 'nestedLabelPadding'];
31
+
32
32
  /**
33
33
  * Generates the theme object for the component from the theme and provided additional information
34
34
  * @param {Object} theme The actual theme object.
35
35
  * @return {Object} The final theme object with the overrides and component variables
36
36
  */
37
-
38
- exports.optionsThemeKeys = optionsThemeKeys;
39
-
40
37
  const generateComponentTheme = theme => {
41
38
  const colors = theme.colors,
42
39
  typography = theme.typography,
43
- spacing = theme.spacing; // TODO: if updated, update optionsThemeKeys array too
44
-
40
+ spacing = theme.spacing;
45
41
  const componentVariables = {
46
42
  labelFontWeight: typography === null || typography === void 0 ? void 0 : typography.fontWeightBold,
47
43
  background: colors === null || colors === void 0 ? void 0 : colors.backgroundLightest,
package/lib/index.js CHANGED
@@ -27,12 +27,6 @@ Object.defineProperty(exports, "optionsThemeGenerator", {
27
27
  return _theme.optionsThemeGenerator;
28
28
  }
29
29
  });
30
- Object.defineProperty(exports, "optionsThemeKeys", {
31
- enumerable: true,
32
- get: function () {
33
- return _theme.optionsThemeKeys;
34
- }
35
- });
36
30
 
37
31
  var _Options = require("./Options");
38
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instructure/ui-options",
3
- "version": "8.20.1-snapshot.0+c650fffc6",
3
+ "version": "8.20.1-snapshot.22+a60e3a0da",
4
4
  "description": "A view-only component for composing interactive lists and menus.",
5
5
  "author": "Instructure, Inc. Engineering and Product Design",
6
6
  "module": "./es/index.js",
@@ -23,21 +23,21 @@
23
23
  },
24
24
  "license": "MIT",
25
25
  "devDependencies": {
26
- "@instructure/ui-babel-preset": "8.20.1-snapshot.0+c650fffc6",
27
- "@instructure/ui-color-utils": "8.20.1-snapshot.0+c650fffc6",
28
- "@instructure/ui-test-locator": "8.20.1-snapshot.0+c650fffc6",
29
- "@instructure/ui-test-utils": "8.20.1-snapshot.0+c650fffc6",
30
- "@instructure/ui-themes": "8.20.1-snapshot.0+c650fffc6"
26
+ "@instructure/ui-babel-preset": "8.20.1-snapshot.22+a60e3a0da",
27
+ "@instructure/ui-color-utils": "8.20.1-snapshot.22+a60e3a0da",
28
+ "@instructure/ui-test-locator": "8.20.1-snapshot.22+a60e3a0da",
29
+ "@instructure/ui-test-utils": "8.20.1-snapshot.22+a60e3a0da",
30
+ "@instructure/ui-themes": "8.20.1-snapshot.22+a60e3a0da"
31
31
  },
32
32
  "dependencies": {
33
33
  "@babel/runtime": "^7.13.10",
34
- "@instructure/emotion": "8.20.1-snapshot.0+c650fffc6",
35
- "@instructure/shared-types": "8.20.1-snapshot.0+c650fffc6",
36
- "@instructure/ui-icons": "8.20.1-snapshot.0+c650fffc6",
37
- "@instructure/ui-prop-types": "8.20.1-snapshot.0+c650fffc6",
38
- "@instructure/ui-react-utils": "8.20.1-snapshot.0+c650fffc6",
39
- "@instructure/ui-testable": "8.20.1-snapshot.0+c650fffc6",
40
- "@instructure/ui-view": "8.20.1-snapshot.0+c650fffc6",
34
+ "@instructure/emotion": "8.20.1-snapshot.22+a60e3a0da",
35
+ "@instructure/shared-types": "8.20.1-snapshot.22+a60e3a0da",
36
+ "@instructure/ui-icons": "8.20.1-snapshot.22+a60e3a0da",
37
+ "@instructure/ui-prop-types": "8.20.1-snapshot.22+a60e3a0da",
38
+ "@instructure/ui-react-utils": "8.20.1-snapshot.22+a60e3a0da",
39
+ "@instructure/ui-testable": "8.20.1-snapshot.22+a60e3a0da",
40
+ "@instructure/ui-view": "8.20.1-snapshot.22+a60e3a0da",
41
41
  "prop-types": "^15"
42
42
  },
43
43
  "peerDependencies": {
@@ -47,5 +47,5 @@
47
47
  "access": "public"
48
48
  },
49
49
  "sideEffects": false,
50
- "gitHead": "c650fffc673c606c3111d3f03079af4b6a84f76b"
50
+ "gitHead": "a60e3a0daf7729db909fd87efbbd58dd4ac0834c"
51
51
  }
@@ -25,14 +25,6 @@
25
25
  import type { Theme } from '@instructure/ui-themes'
26
26
  import type { OptionsTheme } from '@instructure/shared-types'
27
27
 
28
- const optionsThemeKeys: (keyof OptionsTheme)[] = [
29
- 'labelFontWeight',
30
- 'background',
31
- 'labelColor',
32
- 'labelPadding',
33
- 'nestedLabelPadding'
34
- ]
35
-
36
28
  /**
37
29
  * Generates the theme object for the component from the theme and provided additional information
38
30
  * @param {Object} theme The actual theme object.
@@ -41,7 +33,6 @@ const optionsThemeKeys: (keyof OptionsTheme)[] = [
41
33
  const generateComponentTheme = (theme: Theme): OptionsTheme => {
42
34
  const { colors, typography, spacing } = theme
43
35
 
44
- // TODO: if updated, update optionsThemeKeys array too
45
36
  const componentVariables: OptionsTheme = {
46
37
  labelFontWeight: typography?.fontWeightBold,
47
38
 
@@ -57,5 +48,5 @@ const generateComponentTheme = (theme: Theme): OptionsTheme => {
57
48
  }
58
49
  }
59
50
 
60
- export { generateComponentTheme as optionsThemeGenerator, optionsThemeKeys }
51
+ export { generateComponentTheme as optionsThemeGenerator }
61
52
  export default generateComponentTheme
package/src/index.ts CHANGED
@@ -24,7 +24,7 @@
24
24
 
25
25
  export { Options } from './Options'
26
26
 
27
- export { optionsThemeGenerator, optionsThemeKeys } from './Options/theme'
27
+ export { optionsThemeGenerator } from './Options/theme'
28
28
  export { optionsItemThemeGenerator } from './Options/Item/theme'
29
29
  export { optionsSeparatorThemeGenerator } from './Options/Separator/theme'
30
30