@dhis2-ui/css 10.16.3 → 10.16.5

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.
@@ -17,12 +17,9 @@ A tool for adding a global normalization stylesheet into the DOM that applies DH
17
17
  import { CssReset } from '@dhis2/ui'
18
18
  \`\`\`
19
19
  `;
20
- const App = _ref => {
21
- let {
22
- children
23
- } = _ref;
24
- return /*#__PURE__*/_react.default.createElement("div", null, children);
25
- };
20
+ const App = ({
21
+ children
22
+ }) => /*#__PURE__*/_react.default.createElement("div", null, children);
26
23
  var _default = exports.default = {
27
24
  title: 'CSS Reset',
28
25
  component: _index.CssReset,
@@ -8,28 +8,22 @@ var _style = _interopRequireDefault(require("styled-jsx/style"));
8
8
  var theme = _interopRequireWildcard(require("@dhis2/ui-constants"));
9
9
  var _propTypes = _interopRequireDefault(require("prop-types"));
10
10
  var _react = _interopRequireDefault(require("react"));
11
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
12
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
11
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
13
12
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
14
13
  const toPrefixedThemeSection = themeSectionKey =>
15
14
  // eslint-disable-next-line import/namespace
16
- Object.entries(theme[themeSectionKey]).reduce((prefixed, _ref) => {
17
- let [key, value] = _ref;
15
+ Object.entries(theme[themeSectionKey]).reduce((prefixed, [key, value]) => {
18
16
  prefixed[`${themeSectionKey}-${key}`] = value;
19
17
  return prefixed;
20
18
  }, {});
21
- const toCustomPropertyString = themeSection => Object.entries(themeSection).map(_ref2 => {
22
- let [key, value] = _ref2;
23
- return `--${key}: ${value};`;
24
- }).join('\n');
25
- const CssVariables = _ref3 => {
26
- let {
27
- colors = false,
28
- theme = false,
29
- layers = false,
30
- spacers = false,
31
- elevations = false
32
- } = _ref3;
19
+ const toCustomPropertyString = themeSection => Object.entries(themeSection).map(([key, value]) => `--${key}: ${value};`).join('\n');
20
+ const CssVariables = ({
21
+ colors = false,
22
+ theme = false,
23
+ layers = false,
24
+ spacers = false,
25
+ elevations = false
26
+ }) => {
33
27
  const allowedProps = {
34
28
  colors,
35
29
  theme,
@@ -15,12 +15,9 @@ A utility for adding DHIS2 theme variables to global CSS variables.
15
15
  import { CssVariables } from '@dhis2/ui'
16
16
  \`\`\`
17
17
  `;
18
- const App = _ref => {
19
- let {
20
- children
21
- } = _ref;
22
- return /*#__PURE__*/_react.default.createElement("div", null, children);
23
- };
18
+ const App = ({
19
+ children
20
+ }) => /*#__PURE__*/_react.default.createElement("div", null, children);
24
21
  var _default = exports.default = {
25
22
  title: 'CSS Variables',
26
23
  component: _index.CssVariables,
@@ -10,12 +10,9 @@ A tool for adding a global normalization stylesheet into the DOM that applies DH
10
10
  import { CssReset } from '@dhis2/ui'
11
11
  \`\`\`
12
12
  `;
13
- const App = _ref => {
14
- let {
15
- children
16
- } = _ref;
17
- return /*#__PURE__*/React.createElement("div", null, children);
18
- };
13
+ const App = ({
14
+ children
15
+ }) => /*#__PURE__*/React.createElement("div", null, children);
19
16
  export default {
20
17
  title: 'CSS Reset',
21
18
  component: CssReset,
@@ -4,23 +4,18 @@ import PropTypes from 'prop-types';
4
4
  import React from 'react';
5
5
  const toPrefixedThemeSection = themeSectionKey =>
6
6
  // eslint-disable-next-line import/namespace
7
- Object.entries(theme[themeSectionKey]).reduce((prefixed, _ref) => {
8
- let [key, value] = _ref;
7
+ Object.entries(theme[themeSectionKey]).reduce((prefixed, [key, value]) => {
9
8
  prefixed[`${themeSectionKey}-${key}`] = value;
10
9
  return prefixed;
11
10
  }, {});
12
- const toCustomPropertyString = themeSection => Object.entries(themeSection).map(_ref2 => {
13
- let [key, value] = _ref2;
14
- return `--${key}: ${value};`;
15
- }).join('\n');
16
- const CssVariables = _ref3 => {
17
- let {
18
- colors = false,
19
- theme = false,
20
- layers = false,
21
- spacers = false,
22
- elevations = false
23
- } = _ref3;
11
+ const toCustomPropertyString = themeSection => Object.entries(themeSection).map(([key, value]) => `--${key}: ${value};`).join('\n');
12
+ const CssVariables = ({
13
+ colors = false,
14
+ theme = false,
15
+ layers = false,
16
+ spacers = false,
17
+ elevations = false
18
+ }) => {
24
19
  const allowedProps = {
25
20
  colors,
26
21
  theme,
@@ -8,12 +8,9 @@ A utility for adding DHIS2 theme variables to global CSS variables.
8
8
  import { CssVariables } from '@dhis2/ui'
9
9
  \`\`\`
10
10
  `;
11
- const App = _ref => {
12
- let {
13
- children
14
- } = _ref;
15
- return /*#__PURE__*/React.createElement("div", null, children);
16
- };
11
+ const App = ({
12
+ children
13
+ }) => /*#__PURE__*/React.createElement("div", null, children);
17
14
  export default {
18
15
  title: 'CSS Variables',
19
16
  component: CssVariables,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dhis2-ui/css",
3
- "version": "10.16.3",
3
+ "version": "10.16.5",
4
4
  "description": "UI CSS",
5
5
  "repository": {
6
6
  "type": "git",
@@ -33,7 +33,7 @@
33
33
  },
34
34
  "dependencies": {
35
35
  "@dhis2/prop-types": "^3.1.2",
36
- "@dhis2/ui-constants": "10.16.3",
36
+ "@dhis2/ui-constants": "10.16.5",
37
37
  "classnames": "^2.3.1",
38
38
  "prop-types": "^15.7.2"
39
39
  },