@semcore/widget-empty 16.0.11 → 17.0.0-prerelease.18

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 (36) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/README.md +4 -4
  3. package/lib/cjs/Error/index.js +19 -30
  4. package/lib/cjs/Error/index.js.map +1 -1
  5. package/lib/cjs/Error/translations/__intergalactic-dynamic-locales.js +17 -17
  6. package/lib/cjs/Error/translations/__intergalactic-dynamic-locales.js.map +1 -1
  7. package/lib/cjs/NoData/index.js +20 -31
  8. package/lib/cjs/NoData/index.js.map +1 -1
  9. package/lib/cjs/NoData/translations/__intergalactic-dynamic-locales.js +17 -17
  10. package/lib/cjs/NoData/translations/__intergalactic-dynamic-locales.js.map +1 -1
  11. package/lib/cjs/WidgetEmpty.js +55 -58
  12. package/lib/cjs/WidgetEmpty.js.map +1 -1
  13. package/lib/cjs/index.d.js.map +1 -1
  14. package/lib/cjs/index.js +9 -9
  15. package/lib/cjs/index.js.map +1 -1
  16. package/lib/cjs/style/widget-empty.shadow.css +1 -2
  17. package/lib/es6/Error/index.js +12 -23
  18. package/lib/es6/Error/index.js.map +1 -1
  19. package/lib/es6/Error/translations/__intergalactic-dynamic-locales.js +16 -16
  20. package/lib/es6/Error/translations/__intergalactic-dynamic-locales.js.map +1 -1
  21. package/lib/es6/NoData/index.js +13 -24
  22. package/lib/es6/NoData/index.js.map +1 -1
  23. package/lib/es6/NoData/translations/__intergalactic-dynamic-locales.js +16 -16
  24. package/lib/es6/NoData/translations/__intergalactic-dynamic-locales.js.map +1 -1
  25. package/lib/es6/WidgetEmpty.js +49 -53
  26. package/lib/es6/WidgetEmpty.js.map +1 -1
  27. package/lib/es6/index.d.js.map +1 -1
  28. package/lib/es6/style/widget-empty.shadow.css +1 -2
  29. package/lib/esm/Error/index.mjs +13 -21
  30. package/lib/esm/Error/translations/__intergalactic-dynamic-locales.mjs +1 -1
  31. package/lib/esm/NoData/index.mjs +14 -21
  32. package/lib/esm/NoData/translations/__intergalactic-dynamic-locales.mjs +1 -1
  33. package/lib/esm/WidgetEmpty.mjs +49 -50
  34. package/lib/esm/style/widget-empty.shadow.css +1 -2
  35. package/lib/types/index.d.ts +2 -8
  36. package/package.json +4 -4
@@ -1,7 +1,3 @@
1
- import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
2
- import _createClass from "@babel/runtime/helpers/createClass";
3
- import _callSuper from "@babel/runtime/helpers/callSuper";
4
- import _inherits from "@babel/runtime/helpers/inherits";
5
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
6
2
  import { assignProps as _assignProps } from "@semcore/core";
7
3
  import { createComponent, Component, Root } from '@semcore/core';
@@ -9,26 +5,19 @@ import i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';
9
5
  import React from 'react';
10
6
  import WidgetEmpty, { getIconPath } from '../WidgetEmpty';
11
7
  import { localizedMessages } from './translations/__intergalactic-dynamic-locales';
12
- var Error = /*#__PURE__*/function (_Component) {
13
- function Error() {
14
- _classCallCheck(this, Error);
15
- return _callSuper(this, Error, arguments);
8
+ class Error extends Component {
9
+ render() {
10
+ var _ref = this.asProps;
11
+ const {
12
+ Children,
13
+ description,
14
+ getI18nText
15
+ } = this.asProps;
16
+ return /*#__PURE__*/React.createElement(WidgetEmpty, _assignProps({
17
+ "icon": getIconPath('warning')
18
+ }, _ref), /*#__PURE__*/React.createElement(WidgetEmpty.Title, null, getI18nText('title')), /*#__PURE__*/React.createElement(WidgetEmpty.Description, null, description || getI18nText('description')), /*#__PURE__*/React.createElement(Children, null));
16
19
  }
17
- _inherits(Error, _Component);
18
- return _createClass(Error, [{
19
- key: "render",
20
- value: function render() {
21
- var _ref = this.asProps;
22
- var _this$asProps = this.asProps,
23
- Children = _this$asProps.Children,
24
- description = _this$asProps.description,
25
- getI18nText = _this$asProps.getI18nText;
26
- return /*#__PURE__*/React.createElement(WidgetEmpty, _assignProps({
27
- "icon": getIconPath('warning')
28
- }, _ref), /*#__PURE__*/React.createElement(WidgetEmpty.Title, null, getI18nText('title')), /*#__PURE__*/React.createElement(WidgetEmpty.Description, null, description || getI18nText('description')), /*#__PURE__*/React.createElement(Children, null));
29
- }
30
- }]);
31
- }(Component);
20
+ }
32
21
  _defineProperty(Error, "displayName", 'WidgetError');
33
22
  _defineProperty(Error, "defaultProps", {
34
23
  i18n: localizedMessages,
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["createComponent","Component","Root","i18nEnhance","React","WidgetEmpty","getIconPath","localizedMessages","Error","_Component","_classCallCheck","_callSuper","arguments","_inherits","_createClass","key","value","render","_ref","asProps","_this$asProps","Children","description","getI18nText","createElement","_assignProps","Title","Description","_defineProperty","i18n","locale"],"sources":["../../../src/Error/index.jsx"],"sourcesContent":["import { createComponent, Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport React from 'react';\n\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\n\nclass Error extends Component {\n static displayName = 'WidgetError';\n static defaultProps = {\n i18n: localizedMessages,\n locale: 'en',\n };\n\n static enhance = [i18nEnhance(localizedMessages)];\n\n render() {\n const { Children, description, getI18nText } = this.asProps;\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath('warning')}>\n <WidgetEmpty.Title>{getI18nText('title')}</WidgetEmpty.Title>\n <WidgetEmpty.Description>\n {description || getI18nText('description')}\n </WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(Error);\n"],"mappings":";;;;;;AAAA,SAASA,eAAe,EAAEC,SAAS,EAAEC,IAAI,QAAQ,eAAe;AAChE,OAAOC,WAAW,MAAM,8CAA8C;AACtE,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,WAAW,IAAIC,WAAW,QAAQ,gBAAgB;AACzD,SAASC,iBAAiB,QAAQ,gDAAgD;AAAC,IAE7EC,KAAK,0BAAAC,UAAA;EAAA,SAAAD,MAAA;IAAAE,eAAA,OAAAF,KAAA;IAAA,OAAAG,UAAA,OAAAH,KAAA,EAAAI,SAAA;EAAA;EAAAC,SAAA,CAAAL,KAAA,EAAAC,UAAA;EAAA,OAAAK,YAAA,CAAAN,KAAA;IAAAO,GAAA;IAAAC,KAAA,EAST,SAAAC,MAAMA,CAAA,EAAG;MAAA,IAAAC,IAAA,QAAAC,OAAA;MACP,IAAAC,aAAA,GAA+C,IAAI,CAACD,OAAO;QAAnDE,QAAQ,GAAAD,aAAA,CAARC,QAAQ;QAAEC,WAAW,GAAAF,aAAA,CAAXE,WAAW;QAAEC,WAAW,GAAAH,aAAA,CAAXG,WAAW;MAE1C,oBACEnB,KAAA,CAAAoB,aAAA,CAAcnB,WAAW,EAAAoB,YAAA;QAAA,QAAQnB,WAAW,CAAC,SAAS;MAAC,GAAAY,IAAA,gBACrDd,KAAA,CAAAoB,aAAA,CAACnB,WAAW,CAACqB,KAAK,QAAEH,WAAW,CAAC,OAAO,CAAqB,CAAC,eAC7DnB,KAAA,CAAAoB,aAAA,CAACnB,WAAW,CAACsB,WAAW,QACrBL,WAAW,IAAIC,WAAW,CAAC,aAAa,CAClB,CAAC,eAC1BnB,KAAA,CAAAoB,aAAA,CAACH,QAAQ,MAAE,CACP,CAAC;IAEX;EAAC;AAAA,EArBiBpB,SAAS;AAAA2B,eAAA,CAAvBpB,KAAK,iBACY,aAAa;AAAAoB,eAAA,CAD9BpB,KAAK,kBAEa;EACpBqB,IAAI,EAAEtB,iBAAiB;EACvBuB,MAAM,EAAE;AACV,CAAC;AAAAF,eAAA,CALGpB,KAAK,aAOQ,CAACL,WAAW,CAACI,iBAAiB,CAAC,CAAC;AAiBnD,eAAeP,eAAe,CAACQ,KAAK,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":["createComponent","Component","Root","i18nEnhance","React","WidgetEmpty","getIconPath","localizedMessages","Error","render","_ref","asProps","Children","description","getI18nText","createElement","_assignProps","Title","Description","_defineProperty","i18n","locale"],"sources":["../../../src/Error/index.jsx"],"sourcesContent":["import { createComponent, Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport React from 'react';\n\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\n\nclass Error extends Component {\n static displayName = 'WidgetError';\n static defaultProps = {\n i18n: localizedMessages,\n locale: 'en',\n };\n\n static enhance = [i18nEnhance(localizedMessages)];\n\n render() {\n const { Children, description, getI18nText } = this.asProps;\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath('warning')}>\n <WidgetEmpty.Title>{getI18nText('title')}</WidgetEmpty.Title>\n <WidgetEmpty.Description>\n {description || getI18nText('description')}\n </WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(Error);\n"],"mappings":";;AAAA,SAASA,eAAe,EAAEC,SAAS,EAAEC,IAAI,QAAQ,eAAe;AAChE,OAAOC,WAAW,MAAM,8CAA8C;AACtE,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,WAAW,IAAIC,WAAW,QAAQ,gBAAgB;AACzD,SAASC,iBAAiB,QAAQ,gDAAgD;AAElF,MAAMC,KAAK,SAASP,SAAS,CAAC;EAS5BQ,MAAMA,CAAA,EAAG;IAAA,IAAAC,IAAA,QAAAC,OAAA;IACP,MAAM;MAAEC,QAAQ;MAAEC,WAAW;MAAEC;IAAY,CAAC,GAAG,IAAI,CAACH,OAAO;IAE3D,oBACEP,KAAA,CAAAW,aAAA,CAAcV,WAAW,EAAAW,YAAA;MAAA,QAAQV,WAAW,CAAC,SAAS;IAAC,GAAAI,IAAA,gBACrDN,KAAA,CAAAW,aAAA,CAACV,WAAW,CAACY,KAAK,QAAEH,WAAW,CAAC,OAAO,CAAqB,CAAC,eAC7DV,KAAA,CAAAW,aAAA,CAACV,WAAW,CAACa,WAAW,QACrBL,WAAW,IAAIC,WAAW,CAAC,aAAa,CAClB,CAAC,eAC1BV,KAAA,CAAAW,aAAA,CAACH,QAAQ,MAAE,CACP,CAAC;EAEX;AACF;AAACO,eAAA,CAtBKX,KAAK,iBACY,aAAa;AAAAW,eAAA,CAD9BX,KAAK,kBAEa;EACpBY,IAAI,EAAEb,iBAAiB;EACvBc,MAAM,EAAE;AACV,CAAC;AAAAF,eAAA,CALGX,KAAK,aAOQ,CAACL,WAAW,CAACI,iBAAiB,CAAC,CAAC;AAiBnD,eAAeP,eAAe,CAACQ,KAAK,CAAC","ignoreList":[]}
@@ -13,21 +13,21 @@ import sv from './sv.json';
13
13
  import tr from './tr.json';
14
14
  import vi from './vi.json';
15
15
  import zh from './zh.json';
16
- export var localizedMessages = {
17
- de: de,
18
- en: en,
19
- es: es,
20
- fr: fr,
21
- it: it,
22
- ja: ja,
23
- ko: ko,
24
- nl: nl,
25
- pt: pt,
26
- ru: ru,
27
- tr: tr,
28
- vi: vi,
29
- zh: zh,
30
- pl: pl,
31
- sv: sv
16
+ export const localizedMessages = {
17
+ de,
18
+ en,
19
+ es,
20
+ fr,
21
+ it,
22
+ ja,
23
+ ko,
24
+ nl,
25
+ pt,
26
+ ru,
27
+ tr,
28
+ vi,
29
+ zh,
30
+ pl,
31
+ sv
32
32
  };
33
33
  //# sourceMappingURL=__intergalactic-dynamic-locales.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"__intergalactic-dynamic-locales.js","names":["de","en","es","fr","it","ja","ko","nl","pl","pt","ru","sv","tr","vi","zh","localizedMessages"],"sources":["../../../../src/Error/translations/__intergalactic-dynamic-locales.ts"],"sourcesContent":["import de from './de.json';\nimport en from './en.json';\nimport es from './es.json';\nimport fr from './fr.json';\nimport it from './it.json';\nimport ja from './ja.json';\nimport ko from './ko.json';\nimport nl from './nl.json';\nimport pl from './pl.json';\nimport pt from './pt.json';\nimport ru from './ru.json';\nimport sv from './sv.json';\nimport tr from './tr.json';\nimport vi from './vi.json';\nimport zh from './zh.json';\n\nexport const localizedMessages = {\n de,\n en,\n es,\n fr,\n it,\n ja,\n ko,\n nl,\n pt,\n ru,\n tr,\n vi,\n zh,\n pl,\n sv,\n};\n"],"mappings":"AAAA,OAAOA,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAE1B,OAAO,IAAMC,iBAAiB,GAAG;EAC/Bf,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFE,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFE,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFN,EAAE,EAAFA,EAAE;EACFG,EAAE,EAAFA;AACF,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"__intergalactic-dynamic-locales.js","names":["de","en","es","fr","it","ja","ko","nl","pl","pt","ru","sv","tr","vi","zh","localizedMessages"],"sources":["../../../../src/Error/translations/__intergalactic-dynamic-locales.ts"],"sourcesContent":["import de from './de.json';\nimport en from './en.json';\nimport es from './es.json';\nimport fr from './fr.json';\nimport it from './it.json';\nimport ja from './ja.json';\nimport ko from './ko.json';\nimport nl from './nl.json';\nimport pl from './pl.json';\nimport pt from './pt.json';\nimport ru from './ru.json';\nimport sv from './sv.json';\nimport tr from './tr.json';\nimport vi from './vi.json';\nimport zh from './zh.json';\n\nexport const localizedMessages = {\n de,\n en,\n es,\n fr,\n it,\n ja,\n ko,\n nl,\n pt,\n ru,\n tr,\n vi,\n zh,\n pl,\n sv,\n};\n"],"mappings":"AAAA,OAAOA,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAE1B,OAAO,MAAMC,iBAAiB,GAAG;EAC/Bf,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFE,EAAE;EACFC,EAAE;EACFE,EAAE;EACFC,EAAE;EACFC,EAAE;EACFN,EAAE;EACFG;AACF,CAAC","ignoreList":[]}
@@ -1,7 +1,3 @@
1
- import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
2
- import _createClass from "@babel/runtime/helpers/createClass";
3
- import _callSuper from "@babel/runtime/helpers/callSuper";
4
- import _inherits from "@babel/runtime/helpers/inherits";
5
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
6
2
  import { assignProps as _assignProps } from "@semcore/core";
7
3
  import { createComponent, Component, Root } from '@semcore/core';
@@ -9,27 +5,20 @@ import i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';
9
5
  import React from 'react';
10
6
  import WidgetEmpty, { getIconPath } from '../WidgetEmpty';
11
7
  import { localizedMessages } from './translations/__intergalactic-dynamic-locales';
12
- var NoData = /*#__PURE__*/function (_Component) {
13
- function NoData() {
14
- _classCallCheck(this, NoData);
15
- return _callSuper(this, NoData, arguments);
8
+ class NoData extends Component {
9
+ render() {
10
+ var _ref = this.asProps;
11
+ const {
12
+ Children,
13
+ type,
14
+ description,
15
+ getI18nText
16
+ } = this.asProps;
17
+ return /*#__PURE__*/React.createElement(WidgetEmpty, _assignProps({
18
+ "icon": getIconPath(type)
19
+ }, _ref), /*#__PURE__*/React.createElement(WidgetEmpty.Title, null, getI18nText('title')), /*#__PURE__*/React.createElement(WidgetEmpty.Description, null, description || getI18nText('description')), /*#__PURE__*/React.createElement(Children, null));
16
20
  }
17
- _inherits(NoData, _Component);
18
- return _createClass(NoData, [{
19
- key: "render",
20
- value: function render() {
21
- var _ref = this.asProps;
22
- var _this$asProps = this.asProps,
23
- Children = _this$asProps.Children,
24
- type = _this$asProps.type,
25
- description = _this$asProps.description,
26
- getI18nText = _this$asProps.getI18nText;
27
- return /*#__PURE__*/React.createElement(WidgetEmpty, _assignProps({
28
- "icon": getIconPath(type)
29
- }, _ref), /*#__PURE__*/React.createElement(WidgetEmpty.Title, null, getI18nText('title')), /*#__PURE__*/React.createElement(WidgetEmpty.Description, null, description || getI18nText('description')), /*#__PURE__*/React.createElement(Children, null));
30
- }
31
- }]);
32
- }(Component);
21
+ }
33
22
  _defineProperty(NoData, "displayName", 'WidgetNoData');
34
23
  _defineProperty(NoData, "enhance", [i18nEnhance(localizedMessages)]);
35
24
  _defineProperty(NoData, "defaultProps", {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["createComponent","Component","Root","i18nEnhance","React","WidgetEmpty","getIconPath","localizedMessages","NoData","_Component","_classCallCheck","_callSuper","arguments","_inherits","_createClass","key","value","render","_ref","asProps","_this$asProps","Children","type","description","getI18nText","createElement","_assignProps","Title","Description","_defineProperty","i18n","locale"],"sources":["../../../src/NoData/index.jsx"],"sourcesContent":["import { createComponent, Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport React from 'react';\n\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\n\nclass NoData extends Component {\n static displayName = 'WidgetNoData';\n static enhance = [i18nEnhance(localizedMessages)];\n static defaultProps = {\n i18n: localizedMessages,\n locale: 'en',\n type: 'other-data',\n };\n\n render() {\n const { Children, type, description, getI18nText } = this.asProps;\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath(type)}>\n <WidgetEmpty.Title>{getI18nText('title')}</WidgetEmpty.Title>\n <WidgetEmpty.Description>\n {description || getI18nText('description')}\n </WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(NoData);\n"],"mappings":";;;;;;AAAA,SAASA,eAAe,EAAEC,SAAS,EAAEC,IAAI,QAAQ,eAAe;AAChE,OAAOC,WAAW,MAAM,8CAA8C;AACtE,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,WAAW,IAAIC,WAAW,QAAQ,gBAAgB;AACzD,SAASC,iBAAiB,QAAQ,gDAAgD;AAAC,IAE7EC,MAAM,0BAAAC,UAAA;EAAA,SAAAD,OAAA;IAAAE,eAAA,OAAAF,MAAA;IAAA,OAAAG,UAAA,OAAAH,MAAA,EAAAI,SAAA;EAAA;EAAAC,SAAA,CAAAL,MAAA,EAAAC,UAAA;EAAA,OAAAK,YAAA,CAAAN,MAAA;IAAAO,GAAA;IAAAC,KAAA,EASV,SAAAC,MAAMA,CAAA,EAAG;MAAA,IAAAC,IAAA,QAAAC,OAAA;MACP,IAAAC,aAAA,GAAqD,IAAI,CAACD,OAAO;QAAzDE,QAAQ,GAAAD,aAAA,CAARC,QAAQ;QAAEC,IAAI,GAAAF,aAAA,CAAJE,IAAI;QAAEC,WAAW,GAAAH,aAAA,CAAXG,WAAW;QAAEC,WAAW,GAAAJ,aAAA,CAAXI,WAAW;MAEhD,oBACEpB,KAAA,CAAAqB,aAAA,CAAcpB,WAAW,EAAAqB,YAAA;QAAA,QAAQpB,WAAW,CAACgB,IAAI;MAAC,GAAAJ,IAAA,gBAChDd,KAAA,CAAAqB,aAAA,CAACpB,WAAW,CAACsB,KAAK,QAAEH,WAAW,CAAC,OAAO,CAAqB,CAAC,eAC7DpB,KAAA,CAAAqB,aAAA,CAACpB,WAAW,CAACuB,WAAW,QACrBL,WAAW,IAAIC,WAAW,CAAC,aAAa,CAClB,CAAC,eAC1BpB,KAAA,CAAAqB,aAAA,CAACJ,QAAQ,MAAE,CACP,CAAC;IAEX;EAAC;AAAA,EArBkBpB,SAAS;AAAA4B,eAAA,CAAxBrB,MAAM,iBACW,cAAc;AAAAqB,eAAA,CAD/BrB,MAAM,aAEO,CAACL,WAAW,CAACI,iBAAiB,CAAC,CAAC;AAAAsB,eAAA,CAF7CrB,MAAM,kBAGY;EACpBsB,IAAI,EAAEvB,iBAAiB;EACvBwB,MAAM,EAAE,IAAI;EACZT,IAAI,EAAE;AACR,CAAC;AAiBH,eAAetB,eAAe,CAACQ,MAAM,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":["createComponent","Component","Root","i18nEnhance","React","WidgetEmpty","getIconPath","localizedMessages","NoData","render","_ref","asProps","Children","type","description","getI18nText","createElement","_assignProps","Title","Description","_defineProperty","i18n","locale"],"sources":["../../../src/NoData/index.jsx"],"sourcesContent":["import { createComponent, Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport React from 'react';\n\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\n\nclass NoData extends Component {\n static displayName = 'WidgetNoData';\n static enhance = [i18nEnhance(localizedMessages)];\n static defaultProps = {\n i18n: localizedMessages,\n locale: 'en',\n type: 'other-data',\n };\n\n render() {\n const { Children, type, description, getI18nText } = this.asProps;\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath(type)}>\n <WidgetEmpty.Title>{getI18nText('title')}</WidgetEmpty.Title>\n <WidgetEmpty.Description>\n {description || getI18nText('description')}\n </WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(NoData);\n"],"mappings":";;AAAA,SAASA,eAAe,EAAEC,SAAS,EAAEC,IAAI,QAAQ,eAAe;AAChE,OAAOC,WAAW,MAAM,8CAA8C;AACtE,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,WAAW,IAAIC,WAAW,QAAQ,gBAAgB;AACzD,SAASC,iBAAiB,QAAQ,gDAAgD;AAElF,MAAMC,MAAM,SAASP,SAAS,CAAC;EAS7BQ,MAAMA,CAAA,EAAG;IAAA,IAAAC,IAAA,QAAAC,OAAA;IACP,MAAM;MAAEC,QAAQ;MAAEC,IAAI;MAAEC,WAAW;MAAEC;IAAY,CAAC,GAAG,IAAI,CAACJ,OAAO;IAEjE,oBACEP,KAAA,CAAAY,aAAA,CAAcX,WAAW,EAAAY,YAAA;MAAA,QAAQX,WAAW,CAACO,IAAI;IAAC,GAAAH,IAAA,gBAChDN,KAAA,CAAAY,aAAA,CAACX,WAAW,CAACa,KAAK,QAAEH,WAAW,CAAC,OAAO,CAAqB,CAAC,eAC7DX,KAAA,CAAAY,aAAA,CAACX,WAAW,CAACc,WAAW,QACrBL,WAAW,IAAIC,WAAW,CAAC,aAAa,CAClB,CAAC,eAC1BX,KAAA,CAAAY,aAAA,CAACJ,QAAQ,MAAE,CACP,CAAC;EAEX;AACF;AAACQ,eAAA,CAtBKZ,MAAM,iBACW,cAAc;AAAAY,eAAA,CAD/BZ,MAAM,aAEO,CAACL,WAAW,CAACI,iBAAiB,CAAC,CAAC;AAAAa,eAAA,CAF7CZ,MAAM,kBAGY;EACpBa,IAAI,EAAEd,iBAAiB;EACvBe,MAAM,EAAE,IAAI;EACZT,IAAI,EAAE;AACR,CAAC;AAiBH,eAAeb,eAAe,CAACQ,MAAM,CAAC","ignoreList":[]}
@@ -13,21 +13,21 @@ import sv from './sv.json';
13
13
  import tr from './tr.json';
14
14
  import vi from './vi.json';
15
15
  import zh from './zh.json';
16
- export var localizedMessages = {
17
- de: de,
18
- en: en,
19
- es: es,
20
- fr: fr,
21
- it: it,
22
- ja: ja,
23
- ko: ko,
24
- nl: nl,
25
- pt: pt,
26
- ru: ru,
27
- tr: tr,
28
- vi: vi,
29
- zh: zh,
30
- pl: pl,
31
- sv: sv
16
+ export const localizedMessages = {
17
+ de,
18
+ en,
19
+ es,
20
+ fr,
21
+ it,
22
+ ja,
23
+ ko,
24
+ nl,
25
+ pt,
26
+ ru,
27
+ tr,
28
+ vi,
29
+ zh,
30
+ pl,
31
+ sv
32
32
  };
33
33
  //# sourceMappingURL=__intergalactic-dynamic-locales.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"__intergalactic-dynamic-locales.js","names":["de","en","es","fr","it","ja","ko","nl","pl","pt","ru","sv","tr","vi","zh","localizedMessages"],"sources":["../../../../src/NoData/translations/__intergalactic-dynamic-locales.ts"],"sourcesContent":["import de from './de.json';\nimport en from './en.json';\nimport es from './es.json';\nimport fr from './fr.json';\nimport it from './it.json';\nimport ja from './ja.json';\nimport ko from './ko.json';\nimport nl from './nl.json';\nimport pl from './pl.json';\nimport pt from './pt.json';\nimport ru from './ru.json';\nimport sv from './sv.json';\nimport tr from './tr.json';\nimport vi from './vi.json';\nimport zh from './zh.json';\n\nexport const localizedMessages = {\n de,\n en,\n es,\n fr,\n it,\n ja,\n ko,\n nl,\n pt,\n ru,\n tr,\n vi,\n zh,\n pl,\n sv,\n};\n"],"mappings":"AAAA,OAAOA,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAE1B,OAAO,IAAMC,iBAAiB,GAAG;EAC/Bf,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFE,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFE,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFC,EAAE,EAAFA,EAAE;EACFN,EAAE,EAAFA,EAAE;EACFG,EAAE,EAAFA;AACF,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"__intergalactic-dynamic-locales.js","names":["de","en","es","fr","it","ja","ko","nl","pl","pt","ru","sv","tr","vi","zh","localizedMessages"],"sources":["../../../../src/NoData/translations/__intergalactic-dynamic-locales.ts"],"sourcesContent":["import de from './de.json';\nimport en from './en.json';\nimport es from './es.json';\nimport fr from './fr.json';\nimport it from './it.json';\nimport ja from './ja.json';\nimport ko from './ko.json';\nimport nl from './nl.json';\nimport pl from './pl.json';\nimport pt from './pt.json';\nimport ru from './ru.json';\nimport sv from './sv.json';\nimport tr from './tr.json';\nimport vi from './vi.json';\nimport zh from './zh.json';\n\nexport const localizedMessages = {\n de,\n en,\n es,\n fr,\n it,\n ja,\n ko,\n nl,\n pt,\n ru,\n tr,\n vi,\n zh,\n pl,\n sv,\n};\n"],"mappings":"AAAA,OAAOA,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAC1B,OAAOC,EAAE,MAAM,WAAW;AAE1B,OAAO,MAAMC,iBAAiB,GAAG;EAC/Bf,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFC,EAAE;EACFE,EAAE;EACFC,EAAE;EACFE,EAAE;EACFC,EAAE;EACFC,EAAE;EACFN,EAAE;EACFG;AACF,CAAC","ignoreList":[]}
@@ -1,76 +1,72 @@
1
- import _objectSpread from "@babel/runtime/helpers/objectSpread2";
2
- import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
3
- import _createClass from "@babel/runtime/helpers/createClass";
4
- import _callSuper from "@babel/runtime/helpers/callSuper";
5
- import _inherits from "@babel/runtime/helpers/inherits";
6
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
7
2
  import { sstyled as _sstyled } from "@semcore/core";
8
3
  import { assignProps as _assignProps3 } from "@semcore/core";
9
4
  import { assignProps as _assignProps2 } from "@semcore/core";
10
5
  import { assignProps as _assignProps } from "@semcore/core";
6
+ import { Box, Flex } from '@semcore/base-components';
11
7
  import { createComponent, Component, sstyled, Root } from '@semcore/core';
12
8
  import isNode from '@semcore/core/lib/utils/isNode';
13
- import { Box, Flex } from '@semcore/flex-box';
14
9
  import { getIllustrationPath } from '@semcore/illustration';
15
10
  import React from 'react';
16
11
  /*!__reshadow-styles__:"./style/widget-empty.shadow.css"*/
17
- var style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SWidgetEmpty_171y9_gg_{flex-direction:column;justify-content:center;align-items:center;margin-bottom:var(--intergalactic-spacing-4x, 16px)}.___SImage_171y9_gg_{display:flex;align-items:flex-end;justify-content:center;margin-bottom:var(--intergalactic-spacing-3x, 12px);width:80px;height:80px}.___SDescription_171y9_gg_,.___STitle_171y9_gg_{text-align:center;color:var(--intergalactic-text-secondary, #6c6e79)}.___STitle_171y9_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%);font-weight:var(--intergalactic-bold, 700)}.___SDescription_171y9_gg_{text-wrap:balance;font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%);max-width:400px}.___STitle_171y9_gg_+.___SDescription_171y9_gg_{margin-top:var(--intergalactic-spacing-1x, 4px)}.___SDescription_171y9_gg_+.___SDescription_171y9_gg_{margin-top:var(--intergalactic-spacing-2x, 8px)}", /*__inner_css_end__*/"171y9_gg_"),
12
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SWidgetEmpty_8oyu7_gg_{flex-direction:column;justify-content:center;align-items:center}.___SImage_8oyu7_gg_{display:flex;align-items:flex-end;justify-content:center;margin-bottom:var(--intergalactic-spacing-3x, 12px);width:80px;height:80px}.___SDescription_8oyu7_gg_,.___STitle_8oyu7_gg_{text-align:center;color:var(--intergalactic-text-secondary, #6c6e79)}.___STitle_8oyu7_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%);font-weight:var(--intergalactic-bold, 700)}.___SDescription_8oyu7_gg_{text-wrap:balance;font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%);max-width:400px}.___STitle_8oyu7_gg_+.___SDescription_8oyu7_gg_{margin-top:var(--intergalactic-spacing-1x, 4px)}.___SDescription_8oyu7_gg_+.___SDescription_8oyu7_gg_{margin-top:var(--intergalactic-spacing-2x, 8px)}", /*__inner_css_end__*/"8oyu7_gg_"),
18
13
  /*__reshadow_css_end__*/
19
14
  {
20
- "__SWidgetEmpty": "___SWidgetEmpty_171y9_gg_",
21
- "__SImage": "___SImage_171y9_gg_",
22
- "__STitle": "___STitle_171y9_gg_",
23
- "__SDescription": "___SDescription_171y9_gg_"
15
+ "__SWidgetEmpty": "___SWidgetEmpty_8oyu7_gg_",
16
+ "__SImage": "___SImage_8oyu7_gg_",
17
+ "__STitle": "___STitle_8oyu7_gg_",
18
+ "__SDescription": "___SDescription_8oyu7_gg_"
24
19
  });
25
- export var getIconPath = function getIconPath(name) {
26
- return getIllustrationPath(name);
27
- };
28
- var WidgetEmpty = /*#__PURE__*/function (_Component) {
29
- function WidgetEmpty() {
30
- _classCallCheck(this, WidgetEmpty);
31
- return _callSuper(this, WidgetEmpty, arguments);
32
- }
33
- _inherits(WidgetEmpty, _Component);
34
- return _createClass(WidgetEmpty, [{
35
- key: "render",
36
- value: function render() {
37
- var _ref = this.asProps,
38
- _ref4;
39
- var SWidgetEmpty = Flex;
40
- var _this$asProps = this.asProps,
41
- Children = _this$asProps.Children,
42
- icon = _this$asProps.icon,
43
- styles = _this$asProps.styles;
44
- var SImage = 'div';
45
- return _ref4 = sstyled(styles), /*#__PURE__*/React.createElement(SWidgetEmpty, _ref4.cn("SWidgetEmpty", _objectSpread({}, _assignProps({
20
+ export const getIconPath = name => getIllustrationPath(name);
21
+ class WidgetEmpty extends Component {
22
+ render() {
23
+ var _ref = this.asProps,
24
+ _ref4;
25
+ const SWidgetEmpty = Flex;
26
+ const {
27
+ Children,
28
+ icon,
29
+ styles
30
+ } = this.asProps;
31
+ const SImage = 'div';
32
+ return _ref4 = sstyled(styles), /*#__PURE__*/React.createElement(SWidgetEmpty, _ref4.cn("SWidgetEmpty", {
33
+ ..._assignProps({
46
34
  "role": 'status'
47
- }, _ref))), isNode(icon) && /*#__PURE__*/React.createElement(SImage, _ref4.cn("SImage", {
48
- "aria-hidden": 'true'
49
- }), typeof icon === 'string' ? /*#__PURE__*/React.createElement("img", _ref4.cn("img", {
50
- "src": icon,
51
- "alt": ''
52
- })) : icon), /*#__PURE__*/React.createElement(Children, _ref4.cn("Children", {})));
53
- }
54
- }]);
55
- }(Component);
35
+ }, _ref)
36
+ }), isNode(icon) && /*#__PURE__*/React.createElement(SImage, _ref4.cn("SImage", {
37
+ "aria-hidden": 'true'
38
+ }), typeof icon === 'string' ? /*#__PURE__*/React.createElement("img", _ref4.cn("img", {
39
+ "src": icon,
40
+ "alt": ''
41
+ })) : icon), /*#__PURE__*/React.createElement(Children, _ref4.cn("Children", {})));
42
+ }
43
+ }
56
44
  _defineProperty(WidgetEmpty, "displayName", 'WidgetEmpty');
57
45
  _defineProperty(WidgetEmpty, "style", style);
58
- var Title = function Title(props) {
46
+ function Title(props) {
59
47
  var _ref2 = arguments[0],
60
48
  _ref5;
61
- var STitle = Box;
62
- var styles = props.styles;
63
- return _ref5 = sstyled(styles), /*#__PURE__*/React.createElement(STitle, _ref5.cn("STitle", _objectSpread({}, _assignProps2({}, _ref2))));
64
- };
65
- var Description = function Description(props) {
49
+ const STitle = Box;
50
+ const {
51
+ styles
52
+ } = props;
53
+ return _ref5 = sstyled(styles), /*#__PURE__*/React.createElement(STitle, _ref5.cn("STitle", {
54
+ ..._assignProps2({}, _ref2)
55
+ }));
56
+ }
57
+ function Description(props) {
66
58
  var _ref3 = arguments[0],
67
59
  _ref6;
68
- var SDescription = Box;
69
- var styles = props.styles;
70
- return _ref6 = sstyled(styles), /*#__PURE__*/React.createElement(SDescription, _ref6.cn("SDescription", _objectSpread({}, _assignProps3({}, _ref3))));
71
- };
60
+ const SDescription = Box;
61
+ const {
62
+ styles
63
+ } = props;
64
+ return _ref6 = sstyled(styles), /*#__PURE__*/React.createElement(SDescription, _ref6.cn("SDescription", {
65
+ ..._assignProps3({}, _ref3)
66
+ }));
67
+ }
72
68
  export default createComponent(WidgetEmpty, {
73
- Title: Title,
74
- Description: Description
69
+ Title,
70
+ Description
75
71
  });
76
72
  //# sourceMappingURL=WidgetEmpty.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"WidgetEmpty.js","names":["createComponent","Component","sstyled","Root","isNode","Box","Flex","getIllustrationPath","React","style","_sstyled","insert","getIconPath","name","WidgetEmpty","_Component","_classCallCheck","_callSuper","arguments","_inherits","_createClass","key","value","render","_ref","asProps","_ref4","SWidgetEmpty","_this$asProps","Children","icon","styles","SImage","createElement","cn","_objectSpread","_assignProps","_defineProperty","Title","props","_ref2","arguments[0]","_ref5","STitle","_assignProps2","Description","_ref3","_ref6","SDescription","_assignProps3"],"sources":["../../src/WidgetEmpty.jsx"],"sourcesContent":["import { createComponent, Component, sstyled, Root } from '@semcore/core';\nimport isNode from '@semcore/core/lib/utils/isNode';\nimport { Box, Flex } from '@semcore/flex-box';\nimport { getIllustrationPath } from '@semcore/illustration';\nimport React from 'react';\n\nimport style from './style/widget-empty.shadow.css';\n\nexport const getIconPath = (name) => getIllustrationPath(name);\n\nclass WidgetEmpty extends Component {\n static displayName = 'WidgetEmpty';\n static style = style;\n\n render() {\n const SWidgetEmpty = Root;\n const { Children, icon, styles } = this.asProps;\n const SImage = 'div';\n\n return sstyled(styles)(\n <SWidgetEmpty render={Flex} role='status'>\n {isNode(icon) && (\n <SImage aria-hidden='true'>\n {typeof icon === 'string' ? <img src={icon} alt='' /> : icon}\n </SImage>\n )}\n <Children />\n </SWidgetEmpty>,\n );\n }\n}\n\nconst Title = (props) => {\n const STitle = Root;\n const { styles } = props;\n return sstyled(styles)(<STitle render={Box} />);\n};\n\nconst Description = (props) => {\n const SDescription = Root;\n const { styles } = props;\n return sstyled(sty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CAAC;AACtD,CAAC;AAED,eAAe9C,eAAe,CAACc,WAAW,EAAE;EAC1CwB,KAAK,EAALA,KAAK;EACLO,WAAW,EAAXA;AACF,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"WidgetEmpty.js","names":["Box","Flex","createComponent","Component","sstyled","Root","isNode","getIllustrationPath","React","style","_sstyled","insert","getIconPath","name","WidgetEmpty","render","_ref","asProps","_ref4","SWidgetEmpty","Children","icon","styles","SImage","createElement","cn","_assignProps","_defineProperty","Title","props","_ref2","arguments[0]","_ref5","STitle","_assignProps2","Description","_ref3","_ref6","SDescription","_assignProps3"],"sources":["../../src/WidgetEmpty.jsx"],"sourcesContent":["import { Box, Flex } from '@semcore/base-components';\nimport { createComponent, Component, sstyled, Root } from '@semcore/core';\nimport isNode from '@semcore/core/lib/utils/isNode';\nimport { getIllustrationPath } from '@semcore/illustration';\nimport React from 'react';\n\nimport style from './style/widget-empty.shadow.css';\n\nexport const getIconPath = (name) => getIllustrationPath(name);\n\nclass WidgetEmpty extends Component {\n static displayName = 'WidgetEmpty';\n static style = style;\n\n render() {\n const SWidgetEmpty = Root;\n const { Children, icon, styles } = this.asProps;\n const SImage = 'div';\n\n return sstyled(styles)(\n <SWidgetEmpty render={Flex} role='status'>\n {isNode(icon) && (\n <SImage aria-hidden='true'>\n {typeof icon === 'string' ? <img src={icon} alt='' /> : icon}\n </SImage>\n )}\n <Children />\n </SWidgetEmpty>,\n );\n }\n}\n\nfunction Title(props) {\n const STitle = Root;\n const { styles } = props;\n return sstyled(styles)(<STitle render={Box} />);\n}\n\nfunction Description(props) {\n const SDescription = Root;\n const { styles } = props;\n return sstyled(styles)(<SDescription render={Box} />);\n}\n\nexport default createComponent(WidgetEmpty, {\n Title,\n Description,\n});\n"],"mappings":";;;;;AAAA,SAASA,GAAG,EAAEC,IAAI,QAAQ,0BAA0B;AACpD,SAASC,eAAe,EAAEC,SAAS,EAAEC,OAAO,EAAEC,IAAI,QAAQ,eAAe;AACzE,OAA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,KAAA;EACpB,MAAMC,MAAM,GAE2BjC,GAAG;EAD1C,MAAM;IAAEsB;EAAO,CAAC,GAAGO,KAAK;EACxB,OAAAG,KAAA,GAAO5B,OAAO,CAACkB,MAAM,CAAC,eAACd,KAAA,CAAAgB,aAAA,CAACS,MAAM,EAAAD,KAAA,CAAAP,EAAA;IAAA,GAAAS,aAAA,KAAAJ,KAAA;EAAA,EAAe,CAAC;AAChD;AAEA,SAASK,WAAWA,CAACN,KAAK,EAAE;EAAA,IAAAO,KAAA,GAAAL,YAAA;IAAAM,KAAA;EAC1B,MAAMC,YAAY,GAE2BtC,GAAG;EADhD,MAAM;IAAEsB;EAAO,CAAC,GAAGO,KAAK;EACxB,OAAAQ,KAAA,GAAOjC,OAAO,CAACkB,MAAM,CAAC,eAACd,KAAA,CAAAgB,aAAA,CAACc,YAAY,EAAAD,KAAA,CAAAZ,EAAA;IAAA,GAAAc,aAAA,KAAAH,KAAA;EAAA,EAAe,CAAC;AACtD;AAEA,eAAelC,eAAe,CAACY,WAAW,EAAE;EAC1Cc,KAAK;EACLO;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import type { Intergalactic, UnknownProperties } from '@semcore/core';\nimport type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport type { Box, FlexProps } from '@semcore/flex-box';\nimport type { TIllustrationNamesWidgetEmpty } from '@semcore/illustration';\n\nexport type iconNamesWidgetEmpty = TIllustrationNamesWidgetEmpty;\n\n/** @deprecated */\nexport interface IWidgetEmptyProps extends WidgetEmptyProps, UnknownProperties {}\nexport type WidgetEmptyProps = FlexProps & {\n /**\n * URL before the icon or the whole component\n */\n icon?: React.ReactNode;\n};\n\n/** @deprecated */\nexport interface IWidgetErrorProps extends WidgetErrorProps, UnknownProperties {}\nexport type WidgetErrorProps = WidgetEmptyProps &\n WithI18nEnhanceProps & {\n /** Error description. If it is absent, use the local default one */\n description?: React.ReactNode;\n };\n\n/** @deprecated */\nexport interface IWidgetNoDataProps extends WidgetNoDataProps, UnknownProperties {}\nexport type WidgetNoDataProps = WidgetEmptyProps &\n WithI18nEnhanceProps & {\n /** Error description. If it is absent, use the local default one */\n description?: React.ReactNode;\n /** Data types */\n type?: iconNamesWidgetEmpty;\n };\n\ndeclare const WidgetEmpty: Intergalactic.Component<'div', WidgetEmptyProps> & {\n Title: typeof Box;\n Description: typeof Box;\n};\n\nexport declare const NoData: Intergalactic.Component<'div', WidgetNoDataProps>;\nexport declare const Error: Intergalactic.Component<'div', WidgetErrorProps>;\nexport declare const getIconPath: (name: string) => string;\n\nexport default WidgetEmpty;\n"],"mappings":"","ignoreList":[]}
1
+ {"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import type { Box, FlexProps } from '@semcore/base-components';\nimport type { Intergalactic } from '@semcore/core';\nimport type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport type { TIllustrationNamesWidgetEmpty } from '@semcore/illustration';\n\nexport type iconNamesWidgetEmpty = TIllustrationNamesWidgetEmpty;\n\nexport type WidgetEmptyProps = FlexProps & {\n /**\n * URL before the icon or the whole component\n */\n icon?: React.ReactNode;\n};\n\nexport type WidgetErrorProps = WidgetEmptyProps &\n WithI18nEnhanceProps & {\n /** Error description. If it is absent, use the local default one */\n description?: React.ReactNode;\n };\n\nexport type WidgetNoDataProps = WidgetEmptyProps &\n WithI18nEnhanceProps & {\n /** Error description. If it is absent, use the local default one */\n description?: React.ReactNode;\n /** Data types */\n type?: iconNamesWidgetEmpty;\n };\n\ndeclare const WidgetEmpty: Intergalactic.Component<'div', WidgetEmptyProps> & {\n Title: typeof Box;\n Description: typeof Box;\n};\n\nexport declare const NoData: Intergalactic.Component<'div', WidgetNoDataProps>;\nexport declare const Error: Intergalactic.Component<'div', WidgetErrorProps>;\nexport declare const getIconPath: (name: string) => string;\n\nexport default WidgetEmpty;\n"],"mappings":"","ignoreList":[]}
@@ -2,7 +2,6 @@ SWidgetEmpty {
2
2
  flex-direction: column;
3
3
  justify-content: center;
4
4
  align-items: center;
5
- margin-bottom: var(--intergalactic-spacing-4x, 16px);
6
5
  }
7
6
 
8
7
  SImage {
@@ -37,4 +36,4 @@ STitle+SDescription {
37
36
 
38
37
  SDescription+SDescription {
39
38
  margin-top: var(--intergalactic-spacing-2x, 8px);
40
- }
39
+ }
@@ -1,30 +1,22 @@
1
- import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
2
- import _createClass from "@babel/runtime/helpers/esm/createClass";
3
- import _callSuper from "@babel/runtime/helpers/esm/callSuper";
4
- import _inherits from "@babel/runtime/helpers/esm/inherits";
5
1
  import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
6
- import { createComponent, assignProps, Component } from "@semcore/core";
2
+ import { createComponent, Component, assignProps } from "@semcore/core";
7
3
  import i18nEnhance from "@semcore/core/lib/utils/enhances/i18nEnhance";
8
4
  import React from "react";
9
5
  import WidgetEmpty, { getIconPath } from "../WidgetEmpty.mjs";
10
6
  import { localizedMessages } from "./translations/__intergalactic-dynamic-locales.mjs";
11
- var Error = /* @__PURE__ */ (function(_Component) {
12
- function Error2() {
13
- _classCallCheck(this, Error2);
14
- return _callSuper(this, Error2, arguments);
7
+ class Error extends Component {
8
+ render() {
9
+ var _ref = this.asProps;
10
+ const {
11
+ Children,
12
+ description,
13
+ getI18nText
14
+ } = this.asProps;
15
+ return /* @__PURE__ */ React.createElement(WidgetEmpty, assignProps({
16
+ "icon": getIconPath("warning")
17
+ }, _ref), /* @__PURE__ */ React.createElement(WidgetEmpty.Title, null, getI18nText("title")), /* @__PURE__ */ React.createElement(WidgetEmpty.Description, null, description || getI18nText("description")), /* @__PURE__ */ React.createElement(Children, null));
15
18
  }
16
- _inherits(Error2, _Component);
17
- return _createClass(Error2, [{
18
- key: "render",
19
- value: function render() {
20
- var _ref = this.asProps;
21
- var _this$asProps = this.asProps, Children = _this$asProps.Children, description = _this$asProps.description, getI18nText = _this$asProps.getI18nText;
22
- return /* @__PURE__ */ React.createElement(WidgetEmpty, assignProps({
23
- "icon": getIconPath("warning")
24
- }, _ref), /* @__PURE__ */ React.createElement(WidgetEmpty.Title, null, getI18nText("title")), /* @__PURE__ */ React.createElement(WidgetEmpty.Description, null, description || getI18nText("description")), /* @__PURE__ */ React.createElement(Children, null));
25
- }
26
- }]);
27
- })(Component);
19
+ }
28
20
  _defineProperty(Error, "displayName", "WidgetError");
29
21
  _defineProperty(Error, "defaultProps", {
30
22
  i18n: localizedMessages,
@@ -13,7 +13,7 @@ import sv from "./sv.json.mjs";
13
13
  import tr from "./tr.json.mjs";
14
14
  import vi from "./vi.json.mjs";
15
15
  import zh from "./zh.json.mjs";
16
- var localizedMessages = {
16
+ const localizedMessages = {
17
17
  de,
18
18
  en,
19
19
  es,
@@ -1,30 +1,23 @@
1
- import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
2
- import _createClass from "@babel/runtime/helpers/esm/createClass";
3
- import _callSuper from "@babel/runtime/helpers/esm/callSuper";
4
- import _inherits from "@babel/runtime/helpers/esm/inherits";
5
1
  import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
6
- import { createComponent, assignProps, Component } from "@semcore/core";
2
+ import { createComponent, Component, assignProps } from "@semcore/core";
7
3
  import i18nEnhance from "@semcore/core/lib/utils/enhances/i18nEnhance";
8
4
  import React from "react";
9
5
  import WidgetEmpty, { getIconPath } from "../WidgetEmpty.mjs";
10
6
  import { localizedMessages } from "./translations/__intergalactic-dynamic-locales.mjs";
11
- var NoData = /* @__PURE__ */ (function(_Component) {
12
- function NoData2() {
13
- _classCallCheck(this, NoData2);
14
- return _callSuper(this, NoData2, arguments);
7
+ class NoData extends Component {
8
+ render() {
9
+ var _ref = this.asProps;
10
+ const {
11
+ Children,
12
+ type,
13
+ description,
14
+ getI18nText
15
+ } = this.asProps;
16
+ return /* @__PURE__ */ React.createElement(WidgetEmpty, assignProps({
17
+ "icon": getIconPath(type)
18
+ }, _ref), /* @__PURE__ */ React.createElement(WidgetEmpty.Title, null, getI18nText("title")), /* @__PURE__ */ React.createElement(WidgetEmpty.Description, null, description || getI18nText("description")), /* @__PURE__ */ React.createElement(Children, null));
15
19
  }
16
- _inherits(NoData2, _Component);
17
- return _createClass(NoData2, [{
18
- key: "render",
19
- value: function render() {
20
- var _ref = this.asProps;
21
- var _this$asProps = this.asProps, Children = _this$asProps.Children, type = _this$asProps.type, description = _this$asProps.description, getI18nText = _this$asProps.getI18nText;
22
- return /* @__PURE__ */ React.createElement(WidgetEmpty, assignProps({
23
- "icon": getIconPath(type)
24
- }, _ref), /* @__PURE__ */ React.createElement(WidgetEmpty.Title, null, getI18nText("title")), /* @__PURE__ */ React.createElement(WidgetEmpty.Description, null, description || getI18nText("description")), /* @__PURE__ */ React.createElement(Children, null));
25
- }
26
- }]);
27
- })(Component);
20
+ }
28
21
  _defineProperty(NoData, "displayName", "WidgetNoData");
29
22
  _defineProperty(NoData, "enhance", [i18nEnhance(localizedMessages)]);
30
23
  _defineProperty(NoData, "defaultProps", {
@@ -13,7 +13,7 @@ import sv from "./sv.json.mjs";
13
13
  import tr from "./tr.json.mjs";
14
14
  import vi from "./vi.json.mjs";
15
15
  import zh from "./zh.json.mjs";
16
- var localizedMessages = {
16
+ const localizedMessages = {
17
17
  de,
18
18
  en,
19
19
  es,