@semcore/widget-empty 3.2.0 → 3.2.1

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 (41) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/README.md +67 -0
  3. package/lib/cjs/Error/index.js.map +1 -1
  4. package/lib/cjs/NoData/index.js.map +1 -1
  5. package/lib/cjs/WidgetEmpty.js +7 -7
  6. package/lib/cjs/WidgetEmpty.js.map +1 -1
  7. package/lib/cjs/index.js.map +1 -1
  8. package/lib/es6/Error/index.js.map +1 -1
  9. package/lib/es6/NoData/index.js.map +1 -1
  10. package/lib/es6/WidgetEmpty.js +7 -7
  11. package/lib/es6/WidgetEmpty.js.map +1 -1
  12. package/lib/es6/index.js.map +1 -1
  13. package/package.json +2 -2
  14. package/src/Error/index.jsx +0 -40
  15. package/src/Error/translations/de.json +0 -4
  16. package/src/Error/translations/en.json +0 -4
  17. package/src/Error/translations/es.json +0 -4
  18. package/src/Error/translations/fr.json +0 -4
  19. package/src/Error/translations/it.json +0 -4
  20. package/src/Error/translations/ja.json +0 -4
  21. package/src/Error/translations/ko.json +0 -4
  22. package/src/Error/translations/pt.json +0 -4
  23. package/src/Error/translations/ru.json +0 -4
  24. package/src/Error/translations/vi.json +0 -4
  25. package/src/Error/translations/zh.json +0 -4
  26. package/src/NoData/index.jsx +0 -40
  27. package/src/NoData/translations/de.json +0 -4
  28. package/src/NoData/translations/en.json +0 -4
  29. package/src/NoData/translations/es.json +0 -4
  30. package/src/NoData/translations/fr.json +0 -4
  31. package/src/NoData/translations/it.json +0 -4
  32. package/src/NoData/translations/ja.json +0 -4
  33. package/src/NoData/translations/ko.json +0 -4
  34. package/src/NoData/translations/pt.json +0 -4
  35. package/src/NoData/translations/ru.json +0 -4
  36. package/src/NoData/translations/vi.json +0 -4
  37. package/src/NoData/translations/zh.json +0 -4
  38. package/src/WidgetEmpty.jsx +0 -57
  39. package/src/index.d.ts +0 -71
  40. package/src/index.js +0 -6
  41. package/src/style/widget-empty.shadow.css +0 -41
package/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangelog.com/en/1.0.0/).
4
4
 
5
+ ## [3.2.1] - 2022-07-22
6
+
7
+ ### Changed
8
+
9
+ - Version patch update due to children dependencies update (`@semcore/utils` [3.34.0 ~> 3.35.0], `@semcore/flex-box` [4.5.6 ~> 4.5.7]).
10
+
5
11
  ## [3.2.0] - 2022-06-30
6
12
 
7
13
  ### Changed
package/README.md CHANGED
@@ -0,0 +1,67 @@
1
+ # @semcore/widget-empty
2
+
3
+ [![version](https://img.shields.io/npm/v/@semcore/widget-empty.svg)](https://www.npmjs.com/@semcore/widget-empty)
4
+ [![downloads](https://img.shields.io/npm/dt/@semcore/widget-empty.svg)](https://www.npmjs.com/package/@semcore/widget-empty)
5
+ [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://github.com/semrush/intergalactic/blob/master/LICENSE)
6
+
7
+ > This component is part of the Intergalactic design system
8
+
9
+ ### 📖 [Component documentation](https://developer.semrush.com/intergalactic/components/widget-empty/)
10
+
11
+ ### 🏠 [Design system](https://developer.semrush.com/intergalactic/)
12
+
13
+ ## Install
14
+
15
+ ```sh
16
+ npm install @semcore/ui
17
+ ```
18
+
19
+ ## Usage
20
+
21
+ ```jsx
22
+ import WidgetEmpty, { NoData, Error } from '@semcore/ui/widget-empty';
23
+ ```
24
+
25
+ <details>
26
+ <summary>Alternative installation and use</summary>
27
+
28
+ **We do not recommend this usage path due to possible dependency and update issues.**
29
+
30
+ ### Install
31
+
32
+ You can only install one package from the design system
33
+
34
+ ```sh
35
+ npm install @semcore/widget-empty @semcore/core
36
+ ```
37
+
38
+ `@semcore/core` - _is the basic package by which we create our components, and it contains all of the common logic
39
+ of the components that is discussed below. There should only be one version of the package in the project._
40
+
41
+ ### Usage
42
+
43
+ You can use the package the same way but without `/ui/` in the import path.
44
+
45
+ ```jsx
46
+ import Accordion from '@semcore/widget-empty';
47
+ ```
48
+
49
+ </details>
50
+
51
+ ## 👤 Author
52
+
53
+ [UI-kit team](https://github.com/semrush/intergalactic/blob/master/MAINTAINERS) and [others ❤️](https://github.com/semrush/intergalactic/graphs/contributors)
54
+
55
+ ## 🤝 Contributing
56
+
57
+ Contributions, issues and feature requests are welcome!
58
+
59
+ Feel free to check [issues page](https://github.com/semrush/intergalactic/issues). You can also take a look at the [contributing guide](https://github.com/semrush/intergalactic/blob/master/CONTRIBUTING.md).
60
+
61
+ ## Show your support
62
+
63
+ Give a ⭐️ if this project helped you!
64
+
65
+ ## 📝 License
66
+
67
+ This project is [MIT](https://github.com/semrush/intergalactic/blob/master/LICENSE) licensed.
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/Error/index.jsx"],"names":["i18n","de","en","es","fr","it","ja","ru","zh","pt","ko","vi","Error","asProps","Children","description","getI18nText","title","descriptionText","WidgetEmpty","Component"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAEA;;AAFA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA,IAAMA,IAAI,GAAG;AAAEC,EAAAA,EAAE,EAAFA,cAAF;AAAMC,EAAAA,EAAE,EAAFA,cAAN;AAAUC,EAAAA,EAAE,EAAFA,cAAV;AAAcC,EAAAA,EAAE,EAAFA,cAAd;AAAkBC,EAAAA,EAAE,EAAFA,cAAlB;AAAsBC,EAAAA,EAAE,EAAFA,cAAtB;AAA0BC,EAAAA,EAAE,EAAFA,cAA1B;AAA8BC,EAAAA,EAAE,EAAFA,cAA9B;AAAkCC,EAAAA,EAAE,EAAFA,cAAlC;AAAsCC,EAAAA,EAAE,EAAFA,cAAtC;AAA0CC,EAAAA,EAAE,EAAFA;AAA1C,CAAb;;IAEMC,K;;;;;;;;;;;;WAOJ,kBAAS;AAAA;AACP,0BAA+C,KAAKC,OAApD;AAAA,UAAQC,QAAR,iBAAQA,QAAR;AAAA,UAAkBC,WAAlB,iBAAkBA,WAAlB;AAAA,UAA+BC,WAA/B,iBAA+BA,WAA/B;;AACA,yBAAgDA,WAAW,EAA3D;AAAA,UAAQC,KAAR,gBAAQA,KAAR;AAAA,UAA4BC,eAA5B,gBAAeH,WAAf;;AAEA,0BACE,gCAAcI,uBAAd;AAAA,gBAAiC,8BAAY,SAAZ;AAAjC,6BACE,gCAAC,uBAAD,CAAa,KAAb,QAAoBF,KAApB,CADF,eAEE,gCAAC,uBAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,gCAAC,QAAD,OAHF,CADF;AAOD;;;EAlBiBE,e;;iCAAdR,K,iBACiB,a;iCADjBA,K,kBAEkB;AACpBZ,EAAAA,IAAI,EAAJA;AADoB,C;iCAFlBY,K,aAKa,CAAC,8BAAD,C;;eAgBJ,sBAAgBA,KAAhB,C","sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass Error extends Component {\n static displayName = 'WidgetError';\n static defaultProps = {\n i18n,\n };\n static enhance = [i18nEnhance()];\n\n render() {\n const { Children, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath('warning')}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(Error);\n"],"file":"index.js"}
1
+ {"version":3,"file":"index.js","names":["i18n","de","en","es","fr","it","ja","ru","zh","pt","ko","vi","Error","asProps","Children","description","getI18nText","title","descriptionText","WidgetEmpty","getIconPath","Component","i18nEnhance","createComponent"],"sources":["../../../src/Error/index.jsx"],"sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass Error extends Component {\n static displayName = 'WidgetError';\n static defaultProps = {\n i18n,\n };\n static enhance = [i18nEnhance()];\n\n render() {\n const { Children, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath('warning')}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(Error);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAEA;;AAFA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA,IAAMA,IAAI,GAAG;EAAEC,EAAE,EAAFA,cAAF;EAAMC,EAAE,EAAFA,cAAN;EAAUC,EAAE,EAAFA,cAAV;EAAcC,EAAE,EAAFA,cAAd;EAAkBC,EAAE,EAAFA,cAAlB;EAAsBC,EAAE,EAAFA,cAAtB;EAA0BC,EAAE,EAAFA,cAA1B;EAA8BC,EAAE,EAAFA,cAA9B;EAAkCC,EAAE,EAAFA,cAAlC;EAAsCC,EAAE,EAAFA,cAAtC;EAA0CC,EAAE,EAAFA;AAA1C,CAAb;;IAEMC,K;;;;;;;;;;;;WAOJ,kBAAS;MAAA;MACP,oBAA+C,KAAKC,OAApD;MAAA,IAAQC,QAAR,iBAAQA,QAAR;MAAA,IAAkBC,WAAlB,iBAAkBA,WAAlB;MAAA,IAA+BC,WAA/B,iBAA+BA,WAA/B;;MACA,mBAAgDA,WAAW,EAA3D;MAAA,IAAQC,KAAR,gBAAQA,KAAR;MAAA,IAA4BC,eAA5B,gBAAeH,WAAf;;MAEA,oBACE,gCAAcI,uBAAd;QAAA,QAAiC,IAAAC,wBAAA,EAAY,SAAZ;MAAjC,uBACE,gCAAC,uBAAD,CAAa,KAAb,QAAoBH,KAApB,CADF,eAEE,gCAAC,uBAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,gCAAC,QAAD,OAHF,CADF;IAOD;;;EAlBiBG,e;;iCAAdT,K,iBACiB,a;iCADjBA,K,kBAEkB;EACpBZ,IAAI,EAAJA;AADoB,C;iCAFlBY,K,aAKa,CAAC,IAAAU,uBAAA,GAAD,C;;eAgBJ,IAAAC,gBAAA,EAAgBX,KAAhB,C"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/NoData/index.jsx"],"names":["i18n","de","en","es","fr","it","ja","ru","zh","pt","ko","vi","NoData","asProps","Children","type","description","getI18nText","title","descriptionText","WidgetEmpty","Component"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAEA;;AAFA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA,IAAMA,IAAI,GAAG;AAAEC,EAAAA,EAAE,EAAFA,cAAF;AAAMC,EAAAA,EAAE,EAAFA,cAAN;AAAUC,EAAAA,EAAE,EAAFA,cAAV;AAAcC,EAAAA,EAAE,EAAFA,cAAd;AAAkBC,EAAAA,EAAE,EAAFA,cAAlB;AAAsBC,EAAAA,EAAE,EAAFA,cAAtB;AAA0BC,EAAAA,EAAE,EAAFA,cAA1B;AAA8BC,EAAAA,EAAE,EAAFA,cAA9B;AAAkCC,EAAAA,EAAE,EAAFA,cAAlC;AAAsCC,EAAAA,EAAE,EAAFA,cAAtC;AAA0CC,EAAAA,EAAE,EAAFA;AAA1C,CAAb;;IAEMC,M;;;;;;;;;;;;WAQJ,kBAAS;AAAA;AACP,0BAAqD,KAAKC,OAA1D;AAAA,UAAQC,QAAR,iBAAQA,QAAR;AAAA,UAAkBC,IAAlB,iBAAkBA,IAAlB;AAAA,UAAwBC,WAAxB,iBAAwBA,WAAxB;AAAA,UAAqCC,WAArC,iBAAqCA,WAArC;;AACA,yBAAgDA,WAAW,EAA3D;AAAA,UAAQC,KAAR,gBAAQA,KAAR;AAAA,UAA4BC,eAA5B,gBAAeH,WAAf;;AACA,0BACE,gCAAcI,uBAAd;AAAA,gBAAiC,8BAAYL,IAAZ;AAAjC,6BACE,gCAAC,uBAAD,CAAa,KAAb,QAAoBG,KAApB,CADF,eAEE,gCAAC,uBAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,gCAAC,QAAD,OAHF,CADF;AAOD;;;EAlBkBE,e;;iCAAfT,M,iBACiB,c;iCADjBA,M,aAEa,CAAC,8BAAD,C;iCAFbA,M,kBAGkB;AACpBZ,EAAAA,IAAI,EAAJA,IADoB;AAEpBe,EAAAA,IAAI,EAAE;AAFc,C;;eAkBT,sBAAgBH,MAAhB,C","sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass NoData extends Component {\n static displayName = 'WidgetNoData';\n static enhance = [i18nEnhance()];\n static defaultProps = {\n i18n,\n type: 'other-data',\n };\n\n render() {\n const { Children, type, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n return (\n <Root render={WidgetEmpty} icon={getIconPath(type)}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(NoData);\n"],"file":"index.js"}
1
+ {"version":3,"file":"index.js","names":["i18n","de","en","es","fr","it","ja","ru","zh","pt","ko","vi","NoData","asProps","Children","type","description","getI18nText","title","descriptionText","WidgetEmpty","getIconPath","Component","i18nEnhance","createComponent"],"sources":["../../../src/NoData/index.jsx"],"sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass NoData extends Component {\n static displayName = 'WidgetNoData';\n static enhance = [i18nEnhance()];\n static defaultProps = {\n i18n,\n type: 'other-data',\n };\n\n render() {\n const { Children, type, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n return (\n <Root render={WidgetEmpty} icon={getIconPath(type)}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(NoData);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAEA;;AAFA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA,IAAMA,IAAI,GAAG;EAAEC,EAAE,EAAFA,cAAF;EAAMC,EAAE,EAAFA,cAAN;EAAUC,EAAE,EAAFA,cAAV;EAAcC,EAAE,EAAFA,cAAd;EAAkBC,EAAE,EAAFA,cAAlB;EAAsBC,EAAE,EAAFA,cAAtB;EAA0BC,EAAE,EAAFA,cAA1B;EAA8BC,EAAE,EAAFA,cAA9B;EAAkCC,EAAE,EAAFA,cAAlC;EAAsCC,EAAE,EAAFA,cAAtC;EAA0CC,EAAE,EAAFA;AAA1C,CAAb;;IAEMC,M;;;;;;;;;;;;WAQJ,kBAAS;MAAA;MACP,oBAAqD,KAAKC,OAA1D;MAAA,IAAQC,QAAR,iBAAQA,QAAR;MAAA,IAAkBC,IAAlB,iBAAkBA,IAAlB;MAAA,IAAwBC,WAAxB,iBAAwBA,WAAxB;MAAA,IAAqCC,WAArC,iBAAqCA,WAArC;;MACA,mBAAgDA,WAAW,EAA3D;MAAA,IAAQC,KAAR,gBAAQA,KAAR;MAAA,IAA4BC,eAA5B,gBAAeH,WAAf;;MACA,oBACE,gCAAcI,uBAAd;QAAA,QAAiC,IAAAC,wBAAA,EAAYN,IAAZ;MAAjC,uBACE,gCAAC,uBAAD,CAAa,KAAb,QAAoBG,KAApB,CADF,eAEE,gCAAC,uBAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,gCAAC,QAAD,OAHF,CADF;IAOD;;;EAlBkBG,e;;iCAAfV,M,iBACiB,c;iCADjBA,M,aAEa,CAAC,IAAAW,uBAAA,GAAD,C;iCAFbX,M,kBAGkB;EACpBZ,IAAI,EAAJA,IADoB;EAEpBe,IAAI,EAAE;AAFc,C;;eAkBT,IAAAS,gBAAA,EAAgBZ,MAAhB,C"}
@@ -46,17 +46,17 @@ var style = (
46
46
  /*__reshadow_css_start__*/
47
47
  _core.sstyled.insert(
48
48
  /*__inner_css_start__*/
49
- ".___SWidgetEmpty_lxb2f_gg_{flex-direction:column;justify-content:center;align-items:center;margin-bottom:16px}.___SImage_lxb2f_gg_{display:flex;align-items:flex-end;justify-content:center;margin-bottom:12px}.___STitle_lxb2f_gg_{color:#6c6e79}.___STitle_lxb2f_gg_{font-size:16px;line-height:1.5;font-weight:700}.___SDescription_lxb2f_gg_{text-align:center;font-size:14px;line-height:1.42;color:#6c6e79;max-width:400px}.___STitle_lxb2f_gg_+.___SDescription_lxb2f_gg_{margin-top:4px}.___SDescription_lxb2f_gg_+.___SDescription_lxb2f_gg_{margin-top:8px}"
49
+ ".___SWidgetEmpty_1x43k_gg_{flex-direction:column;justify-content:center;align-items:center;margin-bottom:16px}.___SImage_1x43k_gg_{display:flex;align-items:flex-end;justify-content:center;margin-bottom:12px}.___STitle_1x43k_gg_{color:#6c6e79}.___STitle_1x43k_gg_{font-size:16px;line-height:1.5;font-weight:700}.___SDescription_1x43k_gg_{text-align:center;font-size:14px;line-height:1.42;color:#6c6e79;max-width:400px}.___STitle_1x43k_gg_+.___SDescription_1x43k_gg_{margin-top:4px}.___SDescription_1x43k_gg_+.___SDescription_1x43k_gg_{margin-top:8px}"
50
50
  /*__inner_css_end__*/
51
- , "p56ifs_gg_")
51
+ , "1x43k_gg_")
52
52
  /*__reshadow_css_end__*/
53
53
  , {
54
- "__SWidgetEmpty": "___SWidgetEmpty_lxb2f_gg_",
55
- "__SImage": "___SImage_lxb2f_gg_",
56
- "__STitle": "___STitle_lxb2f_gg_",
57
- "__SDescription": "___SDescription_lxb2f_gg_"
54
+ "__SWidgetEmpty": "___SWidgetEmpty_1x43k_gg_",
55
+ "__SImage": "___SImage_1x43k_gg_",
56
+ "__STitle": "___STitle_1x43k_gg_",
57
+ "__SDescription": "___SDescription_1x43k_gg_"
58
58
  });
59
- var version = "3.2.0";
59
+ var version = "3.2.1";
60
60
 
61
61
  var getIconPath = function getIconPath(name) {
62
62
  return "https://static.semrush.com/ui-kit/widget-empty/".concat(version, "/").concat(name, ".svg");
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/WidgetEmpty.jsx"],"names":["version","getIconPath","name","WidgetEmpty","SWidgetEmpty","Flex","asProps","Children","icon","styles","SImage","Component","style","Title","props","STitle","Box","Description","SDescription"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA;;AADA;;AAEA;;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAAMA,OAAO,UAAb;;AAIO,IAAMC,WAAW,GAAG,SAAdA,WAAc,CAACC,IAAD,EAAU;AACnC,kEAAyDF,OAAzD,cAAoEE,IAApE;AACD,CAFM;;;;IAIDC,W;;;;;;;;;;;;WAIJ,kBAAS;AAAA;AAAA;;AACP,UAAMC,YAAY,GAKMC,aALxB;AACA,0BAAmC,KAAKC,OAAxC;AAAA,UAAQC,QAAR,iBAAQA,QAAR;AAAA,UAAkBC,IAAlB,iBAAkBA,IAAlB;AAAA,UAAwBC,MAAxB,iBAAwBA,MAAxB;AACA,UAAMC,MAAM,GAAG,KAAf;AAEA,qBAAO,mBAAQD,MAAR,CAAP,eACE,gCAAC,YAAD,iFACG,wBAAOD,IAAP,kBACC,gCAAC,MAAD,0BACG,OAAOA,IAAP,KAAgB,QAAhB,gBACC;AAAA,eAAUA,IAAV;AAAA,eAAoB,mBAApB;AAAA,iBAA+C,GAA/C;AAAA,kBAA4D;AAA5D,SADD,GAGCA,IAJJ,CAFJ,eAUE,gCAAC,QAAD,2BAVF,CADF;AAcD;;;EAvBuBG,e;;iCAApBR,W,iBACiB,a;iCADjBA,W,WAEWS,K;;AAwBjB,IAAMC,KAAK,GAAG,SAARA,KAAQ,CAACC,KAAD,EAAW;AAAA;AAAA;;AACvB,MAAMC,MAAM,GAE2BC,YAFvC;AACA,MAAQP,MAAR,GAAmBK,KAAnB,CAAQL,MAAR;AACA,iBAAO,mBAAQA,MAAR,CAAP,eAAuB,gCAAC,MAAD,2EAAvB;AACD,CAJD;;AAMA,IAAMQ,WAAW,GAAG,SAAdA,WAAc,CAACH,KAAD,EAAW;AAAA;AAAA;;AAC7B,MAAMI,YAAY,GAE2BF,YAF7C;AACA,MAAQP,MAAR,GAAmBK,KAAnB,CAAQL,MAAR;AACA,iBAAO,mBAAQA,MAAR,CAAP,eAAuB,gCAAC,YAAD,iFAAvB;AACD,CAJD;;eAMe,sBAAgBN,WAAhB,EAA6B;AAC1CU,EAAAA,KAAK,EAALA,KAD0C;AAE1CI,EAAAA,WAAW,EAAXA;AAF0C,CAA7B,C","sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box, Flex } from '@semcore/flex-box';\nimport isNode from '@semcore/utils/lib/isNode';\n\nimport style from './style/widget-empty.shadow.css';\n\nconst version = preval`\n module.exports = require('../package.json').version\n`;\n\nexport const getIconPath = (name) => {\n return `https://static.semrush.com/ui-kit/widget-empty/${version}/${name}.svg`;\n};\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}>\n {isNode(icon) && (\n <SImage>\n {typeof icon === 'string' ? (\n <img src={icon} alt=\"widget empty icon\" width={100} height={72} />\n ) : (\n icon\n )}\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(styles)(<SDescription render={Box} />);\n};\n\nexport default createComponent(WidgetEmpty, {\n Title,\n Description,\n});\n"],"file":"WidgetEmpty.js"}
1
+ {"version":3,"file":"WidgetEmpty.js","names":["version","getIconPath","name","WidgetEmpty","SWidgetEmpty","Flex","asProps","Children","icon","styles","SImage","sstyled","isNode","Component","style","Title","props","STitle","Box","Description","SDescription","createComponent"],"sources":["../../src/WidgetEmpty.jsx"],"sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box, Flex } from '@semcore/flex-box';\nimport isNode from '@semcore/utils/lib/isNode';\n\nimport style from './style/widget-empty.shadow.css';\n\nconst version = preval`\n module.exports = require('../package.json').version\n`;\n\nexport const getIconPath = (name) => {\n return `https://static.semrush.com/ui-kit/widget-empty/${version}/${name}.svg`;\n};\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}>\n {isNode(icon) && (\n <SImage>\n {typeof icon === 'string' ? (\n <img src={icon} alt=\"widget empty icon\" width={100} height={72} />\n ) : (\n icon\n )}\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(styles)(<SDescription render={Box} />);\n};\n\nexport default createComponent(WidgetEmpty, {\n Title,\n Description,\n});\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA;;AADA;;AAEA;;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAAMA,OAAO,UAAb;;AAIO,IAAMC,WAAW,GAAG,SAAdA,WAAc,CAACC,IAAD,EAAU;EACnC,gEAAyDF,OAAzD,cAAoEE,IAApE;AACD,CAFM;;;;IAIDC,W;;;;;;;;;;;;WAIJ,kBAAS;MAAA;MAAA;;MACP,IAAMC,YAAY,GAKMC,aALxB;MACA,oBAAmC,KAAKC,OAAxC;MAAA,IAAQC,QAAR,iBAAQA,QAAR;MAAA,IAAkBC,IAAlB,iBAAkBA,IAAlB;MAAA,IAAwBC,MAAxB,iBAAwBA,MAAxB;MACA,IAAMC,MAAM,GAAG,KAAf;MAEA,eAAO,IAAAC,aAAA,EAAQF,MAAR,CAAP,eACE,gCAAC,YAAD,iFACG,IAAAG,kBAAA,EAAOJ,IAAP,kBACC,gCAAC,MAAD,0BACG,OAAOA,IAAP,KAAgB,QAAhB,gBACC;QAAA,OAAUA,IAAV;QAAA,OAAoB,mBAApB;QAAA,SAA+C,GAA/C;QAAA,UAA4D;MAA5D,GADD,GAGCA,IAJJ,CAFJ,eAUE,gCAAC,QAAD,2BAVF,CADF;IAcD;;;EAvBuBK,e;;iCAApBV,W,iBACiB,a;iCADjBA,W,WAEWW,K;;AAwBjB,IAAMC,KAAK,GAAG,SAARA,KAAQ,CAACC,KAAD,EAAW;EAAA;EAAA;;EACvB,IAAMC,MAAM,GAE2BC,YAFvC;EACA,IAAQT,MAAR,GAAmBO,KAAnB,CAAQP,MAAR;EACA,eAAO,IAAAE,aAAA,EAAQF,MAAR,CAAP,eAAuB,gCAAC,MAAD,2EAAvB;AACD,CAJD;;AAMA,IAAMU,WAAW,GAAG,SAAdA,WAAc,CAACH,KAAD,EAAW;EAAA;EAAA;;EAC7B,IAAMI,YAAY,GAE2BF,YAF7C;EACA,IAAQT,MAAR,GAAmBO,KAAnB,CAAQP,MAAR;EACA,eAAO,IAAAE,aAAA,EAAQF,MAAR,CAAP,eAAuB,gCAAC,YAAD,iFAAvB;AACD,CAJD;;eAMe,IAAAY,gBAAA,EAAgBlB,WAAhB,EAA6B;EAC1CY,KAAK,EAALA,KAD0C;EAE1CI,WAAW,EAAXA;AAF0C,CAA7B,C"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAEA;;AAEA","sourcesContent":["export { default } from './WidgetEmpty';\nexport * from './WidgetEmpty';\n\nexport { default as NoData } from './NoData';\n\nexport { default as Error } from './Error';\n"],"file":"index.js"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/index.js"],"sourcesContent":["export { default } from './WidgetEmpty';\nexport * from './WidgetEmpty';\n\nexport { default as NoData } from './NoData';\n\nexport { default as Error } from './Error';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;;AAEA;;AAEA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/Error/index.jsx"],"names":["React","WidgetEmpty","getIconPath","createComponent","Component","Root","i18nEnhance","de","en","es","fr","it","ja","pt","ru","zh","ko","vi","i18n","Error","asProps","Children","description","getI18nText","title","descriptionText"],"mappings":";;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,WAAP,IAAsBC,WAAtB,QAAyC,gBAAzC;AACA,OAAOC,eAAP,IAA0BC,SAA1B,EAAqCC,IAArC,QAAiD,eAAjD;AACA,OAAOC,WAAP,MAAwB,yCAAxB;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AAEA,IAAMC,IAAI,GAAG;AAAEX,EAAAA,EAAE,EAAFA,EAAF;AAAMC,EAAAA,EAAE,EAAFA,EAAN;AAAUC,EAAAA,EAAE,EAAFA,EAAV;AAAcC,EAAAA,EAAE,EAAFA,EAAd;AAAkBC,EAAAA,EAAE,EAAFA,EAAlB;AAAsBC,EAAAA,EAAE,EAAFA,EAAtB;AAA0BE,EAAAA,EAAE,EAAFA,EAA1B;AAA8BC,EAAAA,EAAE,EAAFA,EAA9B;AAAkCF,EAAAA,EAAE,EAAFA,EAAlC;AAAsCG,EAAAA,EAAE,EAAFA,EAAtC;AAA0CC,EAAAA,EAAE,EAAFA;AAA1C,CAAb;;IAEME,K;;;;;;;;;;;;;WAOJ,kBAAS;AAAA;AACP,0BAA+C,KAAKC,OAApD;AAAA,UAAQC,QAAR,iBAAQA,QAAR;AAAA,UAAkBC,WAAlB,iBAAkBA,WAAlB;AAAA,UAA+BC,WAA/B,iBAA+BA,WAA/B;;AACA,yBAAgDA,WAAW,EAA3D;AAAA,UAAQC,KAAR,gBAAQA,KAAR;AAAA,UAA4BC,eAA5B,gBAAeH,WAAf;;AAEA,0BACE,oBAAcrB,WAAd;AAAA,gBAAiCC,WAAW,CAAC,SAAD;AAA5C,6BACE,oBAAC,WAAD,CAAa,KAAb,QAAoBsB,KAApB,CADF,eAEE,oBAAC,WAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,oBAAC,QAAD,OAHF,CADF;AAOD;;;;EAlBiBrB,S;;gBAAde,K,iBACiB,a;;gBADjBA,K,kBAEkB;AACpBD,EAAAA,IAAI,EAAJA;AADoB,C;;gBAFlBC,K,aAKa,CAACb,WAAW,EAAZ,C;;AAgBnB,eAAeH,eAAe,CAACgB,KAAD,CAA9B","sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass Error extends Component {\n static displayName = 'WidgetError';\n static defaultProps = {\n i18n,\n };\n static enhance = [i18nEnhance()];\n\n render() {\n const { Children, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath('warning')}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(Error);\n"],"file":"index.js"}
1
+ {"version":3,"file":"index.js","names":["React","WidgetEmpty","getIconPath","createComponent","Component","Root","i18nEnhance","de","en","es","fr","it","ja","pt","ru","zh","ko","vi","i18n","Error","asProps","Children","description","getI18nText","title","descriptionText"],"sources":["../../../src/Error/index.jsx"],"sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass Error extends Component {\n static displayName = 'WidgetError';\n static defaultProps = {\n i18n,\n };\n static enhance = [i18nEnhance()];\n\n render() {\n const { Children, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n\n return (\n <Root render={WidgetEmpty} icon={getIconPath('warning')}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(Error);\n"],"mappings":";;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,WAAP,IAAsBC,WAAtB,QAAyC,gBAAzC;AACA,OAAOC,eAAP,IAA0BC,SAA1B,EAAqCC,IAArC,QAAiD,eAAjD;AACA,OAAOC,WAAP,MAAwB,yCAAxB;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AAEA,IAAMC,IAAI,GAAG;EAAEX,EAAE,EAAFA,EAAF;EAAMC,EAAE,EAAFA,EAAN;EAAUC,EAAE,EAAFA,EAAV;EAAcC,EAAE,EAAFA,EAAd;EAAkBC,EAAE,EAAFA,EAAlB;EAAsBC,EAAE,EAAFA,EAAtB;EAA0BE,EAAE,EAAFA,EAA1B;EAA8BC,EAAE,EAAFA,EAA9B;EAAkCF,EAAE,EAAFA,EAAlC;EAAsCG,EAAE,EAAFA,EAAtC;EAA0CC,EAAE,EAAFA;AAA1C,CAAb;;IAEME,K;;;;;;;;;;;;;WAOJ,kBAAS;MAAA;MACP,oBAA+C,KAAKC,OAApD;MAAA,IAAQC,QAAR,iBAAQA,QAAR;MAAA,IAAkBC,WAAlB,iBAAkBA,WAAlB;MAAA,IAA+BC,WAA/B,iBAA+BA,WAA/B;;MACA,mBAAgDA,WAAW,EAA3D;MAAA,IAAQC,KAAR,gBAAQA,KAAR;MAAA,IAA4BC,eAA5B,gBAAeH,WAAf;;MAEA,oBACE,oBAAcrB,WAAd;QAAA,QAAiCC,WAAW,CAAC,SAAD;MAA5C,uBACE,oBAAC,WAAD,CAAa,KAAb,QAAoBsB,KAApB,CADF,eAEE,oBAAC,WAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,oBAAC,QAAD,OAHF,CADF;IAOD;;;;EAlBiBrB,S;;gBAAde,K,iBACiB,a;;gBADjBA,K,kBAEkB;EACpBD,IAAI,EAAJA;AADoB,C;;gBAFlBC,K,aAKa,CAACb,WAAW,EAAZ,C;;AAgBnB,eAAeH,eAAe,CAACgB,KAAD,CAA9B"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/NoData/index.jsx"],"names":["React","WidgetEmpty","getIconPath","createComponent","Component","Root","i18nEnhance","de","en","es","fr","it","ja","pt","ru","zh","ko","vi","i18n","NoData","asProps","Children","type","description","getI18nText","title","descriptionText"],"mappings":";;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,WAAP,IAAsBC,WAAtB,QAAyC,gBAAzC;AACA,OAAOC,eAAP,IAA0BC,SAA1B,EAAqCC,IAArC,QAAiD,eAAjD;AACA,OAAOC,WAAP,MAAwB,yCAAxB;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AAEA,IAAMC,IAAI,GAAG;AAAEX,EAAAA,EAAE,EAAFA,EAAF;AAAMC,EAAAA,EAAE,EAAFA,EAAN;AAAUC,EAAAA,EAAE,EAAFA,EAAV;AAAcC,EAAAA,EAAE,EAAFA,EAAd;AAAkBC,EAAAA,EAAE,EAAFA,EAAlB;AAAsBC,EAAAA,EAAE,EAAFA,EAAtB;AAA0BE,EAAAA,EAAE,EAAFA,EAA1B;AAA8BC,EAAAA,EAAE,EAAFA,EAA9B;AAAkCF,EAAAA,EAAE,EAAFA,EAAlC;AAAsCG,EAAAA,EAAE,EAAFA,EAAtC;AAA0CC,EAAAA,EAAE,EAAFA;AAA1C,CAAb;;IAEME,M;;;;;;;;;;;;;WAQJ,kBAAS;AAAA;AACP,0BAAqD,KAAKC,OAA1D;AAAA,UAAQC,QAAR,iBAAQA,QAAR;AAAA,UAAkBC,IAAlB,iBAAkBA,IAAlB;AAAA,UAAwBC,WAAxB,iBAAwBA,WAAxB;AAAA,UAAqCC,WAArC,iBAAqCA,WAArC;;AACA,yBAAgDA,WAAW,EAA3D;AAAA,UAAQC,KAAR,gBAAQA,KAAR;AAAA,UAA4BC,eAA5B,gBAAeH,WAAf;;AACA,0BACE,oBAActB,WAAd;AAAA,gBAAiCC,WAAW,CAACoB,IAAD;AAA5C,6BACE,oBAAC,WAAD,CAAa,KAAb,QAAoBG,KAApB,CADF,eAEE,oBAAC,WAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,oBAAC,QAAD,OAHF,CADF;AAOD;;;;EAlBkBtB,S;;gBAAfe,M,iBACiB,c;;gBADjBA,M,aAEa,CAACb,WAAW,EAAZ,C;;gBAFba,M,kBAGkB;AACpBD,EAAAA,IAAI,EAAJA,IADoB;AAEpBI,EAAAA,IAAI,EAAE;AAFc,C;;AAkBxB,eAAenB,eAAe,CAACgB,MAAD,CAA9B","sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass NoData extends Component {\n static displayName = 'WidgetNoData';\n static enhance = [i18nEnhance()];\n static defaultProps = {\n i18n,\n type: 'other-data',\n };\n\n render() {\n const { Children, type, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n return (\n <Root render={WidgetEmpty} icon={getIconPath(type)}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(NoData);\n"],"file":"index.js"}
1
+ {"version":3,"file":"index.js","names":["React","WidgetEmpty","getIconPath","createComponent","Component","Root","i18nEnhance","de","en","es","fr","it","ja","pt","ru","zh","ko","vi","i18n","NoData","asProps","Children","type","description","getI18nText","title","descriptionText"],"sources":["../../../src/NoData/index.jsx"],"sourcesContent":["import React from 'react';\nimport WidgetEmpty, { getIconPath } from '../WidgetEmpty';\nimport createComponent, { Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport de from './translations/de.json';\nimport en from './translations/en.json';\nimport es from './translations/es.json';\nimport fr from './translations/fr.json';\nimport it from './translations/it.json';\nimport ja from './translations/ja.json';\nimport pt from './translations/pt.json';\nimport ru from './translations/ru.json';\nimport zh from './translations/zh.json';\nimport ko from './translations/ko.json';\nimport vi from './translations/vi.json';\n\nconst i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };\n\nclass NoData extends Component {\n static displayName = 'WidgetNoData';\n static enhance = [i18nEnhance()];\n static defaultProps = {\n i18n,\n type: 'other-data',\n };\n\n render() {\n const { Children, type, description, getI18nText } = this.asProps;\n const { title, description: descriptionText } = getI18nText();\n return (\n <Root render={WidgetEmpty} icon={getIconPath(type)}>\n <WidgetEmpty.Title>{title}</WidgetEmpty.Title>\n <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>\n <Children />\n </Root>\n );\n }\n}\n\nexport default createComponent(NoData);\n"],"mappings":";;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,WAAP,IAAsBC,WAAtB,QAAyC,gBAAzC;AACA,OAAOC,eAAP,IAA0BC,SAA1B,EAAqCC,IAArC,QAAiD,eAAjD;AACA,OAAOC,WAAP,MAAwB,yCAAxB;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AACA,OAAOC,EAAP,MAAe,wBAAf;AAEA,IAAMC,IAAI,GAAG;EAAEX,EAAE,EAAFA,EAAF;EAAMC,EAAE,EAAFA,EAAN;EAAUC,EAAE,EAAFA,EAAV;EAAcC,EAAE,EAAFA,EAAd;EAAkBC,EAAE,EAAFA,EAAlB;EAAsBC,EAAE,EAAFA,EAAtB;EAA0BE,EAAE,EAAFA,EAA1B;EAA8BC,EAAE,EAAFA,EAA9B;EAAkCF,EAAE,EAAFA,EAAlC;EAAsCG,EAAE,EAAFA,EAAtC;EAA0CC,EAAE,EAAFA;AAA1C,CAAb;;IAEME,M;;;;;;;;;;;;;WAQJ,kBAAS;MAAA;MACP,oBAAqD,KAAKC,OAA1D;MAAA,IAAQC,QAAR,iBAAQA,QAAR;MAAA,IAAkBC,IAAlB,iBAAkBA,IAAlB;MAAA,IAAwBC,WAAxB,iBAAwBA,WAAxB;MAAA,IAAqCC,WAArC,iBAAqCA,WAArC;;MACA,mBAAgDA,WAAW,EAA3D;MAAA,IAAQC,KAAR,gBAAQA,KAAR;MAAA,IAA4BC,eAA5B,gBAAeH,WAAf;;MACA,oBACE,oBAActB,WAAd;QAAA,QAAiCC,WAAW,CAACoB,IAAD;MAA5C,uBACE,oBAAC,WAAD,CAAa,KAAb,QAAoBG,KAApB,CADF,eAEE,oBAAC,WAAD,CAAa,WAAb,QAA0BF,WAAW,IAAIG,eAAzC,CAFF,eAGE,oBAAC,QAAD,OAHF,CADF;IAOD;;;;EAlBkBtB,S;;gBAAfe,M,iBACiB,c;;gBADjBA,M,aAEa,CAACb,WAAW,EAAZ,C;;gBAFba,M,kBAGkB;EACpBD,IAAI,EAAJA,IADoB;EAEpBI,IAAI,EAAE;AAFc,C;;AAkBxB,eAAenB,eAAe,CAACgB,MAAD,CAA9B"}
@@ -27,17 +27,17 @@ var style = (
27
27
  /*__reshadow_css_start__*/
28
28
  _sstyled.insert(
29
29
  /*__inner_css_start__*/
30
- ".___SWidgetEmpty_lxb2f_gg_{flex-direction:column;justify-content:center;align-items:center;margin-bottom:16px}.___SImage_lxb2f_gg_{display:flex;align-items:flex-end;justify-content:center;margin-bottom:12px}.___STitle_lxb2f_gg_{color:#6c6e79}.___STitle_lxb2f_gg_{font-size:16px;line-height:1.5;font-weight:700}.___SDescription_lxb2f_gg_{text-align:center;font-size:14px;line-height:1.42;color:#6c6e79;max-width:400px}.___STitle_lxb2f_gg_+.___SDescription_lxb2f_gg_{margin-top:4px}.___SDescription_lxb2f_gg_+.___SDescription_lxb2f_gg_{margin-top:8px}"
30
+ ".___SWidgetEmpty_1x43k_gg_{flex-direction:column;justify-content:center;align-items:center;margin-bottom:16px}.___SImage_1x43k_gg_{display:flex;align-items:flex-end;justify-content:center;margin-bottom:12px}.___STitle_1x43k_gg_{color:#6c6e79}.___STitle_1x43k_gg_{font-size:16px;line-height:1.5;font-weight:700}.___SDescription_1x43k_gg_{text-align:center;font-size:14px;line-height:1.42;color:#6c6e79;max-width:400px}.___STitle_1x43k_gg_+.___SDescription_1x43k_gg_{margin-top:4px}.___SDescription_1x43k_gg_+.___SDescription_1x43k_gg_{margin-top:8px}"
31
31
  /*__inner_css_end__*/
32
- , "p56ifs_gg_")
32
+ , "1x43k_gg_")
33
33
  /*__reshadow_css_end__*/
34
34
  , {
35
- "__SWidgetEmpty": "___SWidgetEmpty_lxb2f_gg_",
36
- "__SImage": "___SImage_lxb2f_gg_",
37
- "__STitle": "___STitle_lxb2f_gg_",
38
- "__SDescription": "___SDescription_lxb2f_gg_"
35
+ "__SWidgetEmpty": "___SWidgetEmpty_1x43k_gg_",
36
+ "__SImage": "___SImage_1x43k_gg_",
37
+ "__STitle": "___STitle_1x43k_gg_",
38
+ "__SDescription": "___SDescription_1x43k_gg_"
39
39
  });
40
- var version = "3.2.0";
40
+ var version = "3.2.1";
41
41
  export var getIconPath = function getIconPath(name) {
42
42
  return "https://static.semrush.com/ui-kit/widget-empty/".concat(version, "/").concat(name, ".svg");
43
43
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/WidgetEmpty.jsx"],"names":["React","createComponent","Component","sstyled","Root","Box","Flex","isNode","version","getIconPath","name","WidgetEmpty","SWidgetEmpty","asProps","Children","icon","styles","SImage","style","Title","props","STitle","Description","SDescription"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,eAAP,IAA0BC,SAA1B,EAAqCC,OAArC,EAA8CC,IAA9C,QAA0D,eAA1D;AACA,SAASC,GAAT,EAAcC,IAAd,QAA0B,mBAA1B;AACA,OAAOC,MAAP,MAAmB,2BAAnB;;;;;;;;;;;;;;;;;AAIA,IAAMC,OAAO,UAAb;AAIA,OAAO,IAAMC,WAAW,GAAG,SAAdA,WAAc,CAACC,IAAD,EAAU;AACnC,kEAAyDF,OAAzD,cAAoEE,IAApE;AACD,CAFM;;IAIDC,W;;;;;;;;;;;;;WAIJ,kBAAS;AAAA;AAAA;;AACP,UAAMC,YAAY,GAKMN,IALxB;AACA,0BAAmC,KAAKO,OAAxC;AAAA,UAAQC,QAAR,iBAAQA,QAAR;AAAA,UAAkBC,IAAlB,iBAAkBA,IAAlB;AAAA,UAAwBC,MAAxB,iBAAwBA,MAAxB;AACA,UAAMC,MAAM,GAAG,KAAf;AAEA,qBAAOd,OAAO,CAACa,MAAD,CAAd,eACE,oBAAC,YAAD,uEACGT,MAAM,CAACQ,IAAD,CAAN,iBACC,oBAAC,MAAD,0BACG,OAAOA,IAAP,KAAgB,QAAhB,gBACC;AAAA,eAAUA,IAAV;AAAA,eAAoB,mBAApB;AAAA,iBAA+C,GAA/C;AAAA,kBAA4D;AAA5D,SADD,GAGCA,IAJJ,CAFJ,eAUE,oBAAC,QAAD,2BAVF,CADF;AAcD;;;;EAvBuBb,S;;gBAApBS,W,iBACiB,a;;gBADjBA,W,WAEWO,K;;AAwBjB,IAAMC,KAAK,GAAG,SAARA,KAAQ,CAACC,KAAD,EAAW;AAAA;AAAA;;AACvB,MAAMC,MAAM,GAE2BhB,GAFvC;AACA,MAAQW,MAAR,GAAmBI,KAAnB,CAAQJ,MAAR;AACA,iBAAOb,OAAO,CAACa,MAAD,CAAd,eAAuB,oBAAC,MAAD,kEAAvB;AACD,CAJD;;AAMA,IAAMM,WAAW,GAAG,SAAdA,WAAc,CAACF,KAAD,EAAW;AAAA;AAAA;;AAC7B,MAAMG,YAAY,GAE2BlB,GAF7C;AACA,MAAQW,MAAR,GAAmBI,KAAnB,CAAQJ,MAAR;AACA,iBAAOb,OAAO,CAACa,MAAD,CAAd,eAAuB,oBAAC,YAAD,wEAAvB;AACD,CAJD;;AAMA,eAAef,eAAe,CAACU,WAAD,EAAc;AAC1CQ,EAAAA,KAAK,EAALA,KAD0C;AAE1CG,EAAAA,WAAW,EAAXA;AAF0C,CAAd,CAA9B","sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box, Flex } from '@semcore/flex-box';\nimport isNode from '@semcore/utils/lib/isNode';\n\nimport style from './style/widget-empty.shadow.css';\n\nconst version = preval`\n module.exports = require('../package.json').version\n`;\n\nexport const getIconPath = (name) => {\n return `https://static.semrush.com/ui-kit/widget-empty/${version}/${name}.svg`;\n};\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}>\n {isNode(icon) && (\n <SImage>\n {typeof icon === 'string' ? (\n <img src={icon} alt=\"widget empty icon\" width={100} height={72} />\n ) : (\n icon\n )}\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(styles)(<SDescription render={Box} />);\n};\n\nexport default createComponent(WidgetEmpty, {\n Title,\n Description,\n});\n"],"file":"WidgetEmpty.js"}
1
+ {"version":3,"file":"WidgetEmpty.js","names":["React","createComponent","Component","sstyled","Root","Box","Flex","isNode","version","getIconPath","name","WidgetEmpty","SWidgetEmpty","asProps","Children","icon","styles","SImage","style","Title","props","STitle","Description","SDescription"],"sources":["../../src/WidgetEmpty.jsx"],"sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box, Flex } from '@semcore/flex-box';\nimport isNode from '@semcore/utils/lib/isNode';\n\nimport style from './style/widget-empty.shadow.css';\n\nconst version = preval`\n module.exports = require('../package.json').version\n`;\n\nexport const getIconPath = (name) => {\n return `https://static.semrush.com/ui-kit/widget-empty/${version}/${name}.svg`;\n};\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}>\n {isNode(icon) && (\n <SImage>\n {typeof icon === 'string' ? (\n <img src={icon} alt=\"widget empty icon\" width={100} height={72} />\n ) : (\n icon\n )}\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(styles)(<SDescription render={Box} />);\n};\n\nexport default createComponent(WidgetEmpty, {\n Title,\n Description,\n});\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,eAAP,IAA0BC,SAA1B,EAAqCC,OAArC,EAA8CC,IAA9C,QAA0D,eAA1D;AACA,SAASC,GAAT,EAAcC,IAAd,QAA0B,mBAA1B;AACA,OAAOC,MAAP,MAAmB,2BAAnB;;;;;;;;;;;;;;;;;AAIA,IAAMC,OAAO,UAAb;AAIA,OAAO,IAAMC,WAAW,GAAG,SAAdA,WAAc,CAACC,IAAD,EAAU;EACnC,gEAAyDF,OAAzD,cAAoEE,IAApE;AACD,CAFM;;IAIDC,W;;;;;;;;;;;;;WAIJ,kBAAS;MAAA;MAAA;;MACP,IAAMC,YAAY,GAKMN,IALxB;MACA,oBAAmC,KAAKO,OAAxC;MAAA,IAAQC,QAAR,iBAAQA,QAAR;MAAA,IAAkBC,IAAlB,iBAAkBA,IAAlB;MAAA,IAAwBC,MAAxB,iBAAwBA,MAAxB;MACA,IAAMC,MAAM,GAAG,KAAf;MAEA,eAAOd,OAAO,CAACa,MAAD,CAAd,eACE,oBAAC,YAAD,uEACGT,MAAM,CAACQ,IAAD,CAAN,iBACC,oBAAC,MAAD,0BACG,OAAOA,IAAP,KAAgB,QAAhB,gBACC;QAAA,OAAUA,IAAV;QAAA,OAAoB,mBAApB;QAAA,SAA+C,GAA/C;QAAA,UAA4D;MAA5D,GADD,GAGCA,IAJJ,CAFJ,eAUE,oBAAC,QAAD,2BAVF,CADF;IAcD;;;;EAvBuBb,S;;gBAApBS,W,iBACiB,a;;gBADjBA,W,WAEWO,K;;AAwBjB,IAAMC,KAAK,GAAG,SAARA,KAAQ,CAACC,KAAD,EAAW;EAAA;EAAA;;EACvB,IAAMC,MAAM,GAE2BhB,GAFvC;EACA,IAAQW,MAAR,GAAmBI,KAAnB,CAAQJ,MAAR;EACA,eAAOb,OAAO,CAACa,MAAD,CAAd,eAAuB,oBAAC,MAAD,kEAAvB;AACD,CAJD;;AAMA,IAAMM,WAAW,GAAG,SAAdA,WAAc,CAACF,KAAD,EAAW;EAAA;EAAA;;EAC7B,IAAMG,YAAY,GAE2BlB,GAF7C;EACA,IAAQW,MAAR,GAAmBI,KAAnB,CAAQJ,MAAR;EACA,eAAOb,OAAO,CAACa,MAAD,CAAd,eAAuB,oBAAC,YAAD,wEAAvB;AACD,CAJD;;AAMA,eAAef,eAAe,CAACU,WAAD,EAAc;EAC1CQ,KAAK,EAALA,KAD0C;EAE1CG,WAAW,EAAXA;AAF0C,CAAd,CAA9B"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.js"],"names":["default","NoData","Error"],"mappings":"AAAA,SAASA,OAAT,QAAwB,eAAxB;AACA,cAAc,eAAd;AAEA,SAASA,OAAO,IAAIC,MAApB,QAAkC,UAAlC;AAEA,SAASD,OAAO,IAAIE,KAApB,QAAiC,SAAjC","sourcesContent":["export { default } from './WidgetEmpty';\nexport * from './WidgetEmpty';\n\nexport { default as NoData } from './NoData';\n\nexport { default as Error } from './Error';\n"],"file":"index.js"}
1
+ {"version":3,"file":"index.js","names":["default","NoData","Error"],"sources":["../../src/index.js"],"sourcesContent":["export { default } from './WidgetEmpty';\nexport * from './WidgetEmpty';\n\nexport { default as NoData } from './NoData';\n\nexport { default as Error } from './Error';\n"],"mappings":"AAAA,SAASA,OAAT,QAAwB,eAAxB;AACA,cAAc,eAAd;AAEA,SAASA,OAAO,IAAIC,MAApB,QAAkC,UAAlC;AAEA,SAASD,OAAO,IAAIE,KAApB,QAAiC,SAAjC"}
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@semcore/widget-empty",
3
3
  "description": "SEMRush WidgetEmpty Component",
4
- "version": "3.2.0",
4
+ "version": "3.2.1",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/es6/index.js",
7
7
  "typings": "lib/types/index.d.ts",
8
8
  "sideEffects": false,
9
- "author": "Roman Lysov <r.lysov@semrush.com>",
9
+ "author": "UI-kit team <ui-kit-team@semrush.com>",
10
10
  "license": "MIT",
11
11
  "scripts": {
12
12
  "build": "build --source=js",
@@ -1,40 +0,0 @@
1
- import React from 'react';
2
- import WidgetEmpty, { getIconPath } from '../WidgetEmpty';
3
- import createComponent, { Component, Root } from '@semcore/core';
4
- import i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';
5
- import de from './translations/de.json';
6
- import en from './translations/en.json';
7
- import es from './translations/es.json';
8
- import fr from './translations/fr.json';
9
- import it from './translations/it.json';
10
- import ja from './translations/ja.json';
11
- import pt from './translations/pt.json';
12
- import ru from './translations/ru.json';
13
- import zh from './translations/zh.json';
14
- import ko from './translations/ko.json';
15
- import vi from './translations/vi.json';
16
-
17
- const i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };
18
-
19
- class Error extends Component {
20
- static displayName = 'WidgetError';
21
- static defaultProps = {
22
- i18n,
23
- };
24
- static enhance = [i18nEnhance()];
25
-
26
- render() {
27
- const { Children, description, getI18nText } = this.asProps;
28
- const { title, description: descriptionText } = getI18nText();
29
-
30
- return (
31
- <Root render={WidgetEmpty} icon={getIconPath('warning')}>
32
- <WidgetEmpty.Title>{title}</WidgetEmpty.Title>
33
- <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>
34
- <Children />
35
- </Root>
36
- );
37
- }
38
- }
39
-
40
- export default createComponent(Error);
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Es ist ein Fehler aufgetreten",
3
- "description": "Keine Sorge – wir wissen von dem Problem und arbeiten an seiner Behebung. Bitte versuchen Sie es später erneut."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Something went wrong",
3
- "description": "Don't worry though, we are aware of the issue and are working to fix it. Please try again later."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Algo salió mal",
3
- "description": "De todas maneras no te preocupes, estamos al corriente del problema y estamos tratando de solucionarlo. Inténtalo de nuevo más tarde."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Une erreur est survenue",
3
- "description": "Ne vous inquiétez pas, nous avons connaissance du problème et travaillons pour le réparer. Veuillez réessayer plus tard."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Si è verificato un errore",
3
- "description": "Ma non preoccuparti, siamo a conoscenza del problema e stiamo lavorando per porvi rimedio. Riprova più tardi."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "エラーが発生しました",
3
- "description": "私たちは問題を把握し、解決に向けて取り組んでおります。ご安心ください。後で再試行してください。"
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "오류가 발생했습니다",
3
- "description": "문제를 파악했으며 해결 중입니다. 나중에 다시 시도해 주세요."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Algo deu errado",
3
- "description": "Não se preocupe, estamos cientes do problema e estamos trabalhando para resolvê-lo. Tente novamente mais tarde."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Произошла ошибка",
3
- "description": "Мы уже знаем об этой проблеме и в настоящий момент устраняем ее. Повторите попытку позже."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Đã xảy ra lỗi",
3
- "description": "Đừng lo lắng, chúng tôi đã nhận thấy vấn đề và đang khắc phục nó. Vui lòng thử lại sau."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "出错了",
3
- "description": "不过别担心,我们已发现问题,正在努力解决。请稍后重试。"
4
- }
@@ -1,40 +0,0 @@
1
- import React from 'react';
2
- import WidgetEmpty, { getIconPath } from '../WidgetEmpty';
3
- import createComponent, { Component, Root } from '@semcore/core';
4
- import i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';
5
- import de from './translations/de.json';
6
- import en from './translations/en.json';
7
- import es from './translations/es.json';
8
- import fr from './translations/fr.json';
9
- import it from './translations/it.json';
10
- import ja from './translations/ja.json';
11
- import pt from './translations/pt.json';
12
- import ru from './translations/ru.json';
13
- import zh from './translations/zh.json';
14
- import ko from './translations/ko.json';
15
- import vi from './translations/vi.json';
16
-
17
- const i18n = { de, en, es, fr, it, ja, ru, zh, pt, ko, vi };
18
-
19
- class NoData extends Component {
20
- static displayName = 'WidgetNoData';
21
- static enhance = [i18nEnhance()];
22
- static defaultProps = {
23
- i18n,
24
- type: 'other-data',
25
- };
26
-
27
- render() {
28
- const { Children, type, description, getI18nText } = this.asProps;
29
- const { title, description: descriptionText } = getI18nText();
30
- return (
31
- <Root render={WidgetEmpty} icon={getIconPath(type)}>
32
- <WidgetEmpty.Title>{title}</WidgetEmpty.Title>
33
- <WidgetEmpty.Description>{description || descriptionText}</WidgetEmpty.Description>
34
- <Children />
35
- </Root>
36
- );
37
- }
38
- }
39
-
40
- export default createComponent(NoData);
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Keine anzuzeigenden Daten",
3
- "description": "Ändern Sie die Datums- oder Filtereinstellungen."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "We have no data to show",
3
- "description": "Try selecting a different date or changing your filter settings."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "No hay datos para mostrar.",
3
- "description": "Intenta cambiar la fecha o la configuración de filtros."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Nous n'avons pas de données à afficher",
3
- "description": "Essayez de modifier la date ou les paramètres du filtre."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Nessun dato da visualizzare",
3
- "description": "Prova a modificare la data o le impostazioni del filtro."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "表示するデータはありません",
3
- "description": "日付かフィルタ適応の設定を変えて、結果をご覧ください。"
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "표시할 데이터가 없습니다.",
3
- "description": "다른 날짜를 선택하거나 필터 설정을 변경하세요."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Não há dados a serem exibidos",
3
- "description": "Tente alterar a data ou as configurações do filtro."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Данные отсутствуют",
3
- "description": "Попробуйте изменить дату или настройки фильтров."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "Chúng tôi không có dữ liệu để hiển thị",
3
- "description": "Vui lòng chọn ngày khác hoặc đổi chế độ lọc."
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- "title": "我们没有要显示的数据",
3
- "description": "尝试更改日期或过滤设置以查看结果。"
4
- }
@@ -1,57 +0,0 @@
1
- import React from 'react';
2
- import createComponent, { Component, sstyled, Root } from '@semcore/core';
3
- import { Box, Flex } from '@semcore/flex-box';
4
- import isNode from '@semcore/utils/lib/isNode';
5
-
6
- import style from './style/widget-empty.shadow.css';
7
-
8
- const version = preval`
9
- module.exports = require('../package.json').version
10
- `;
11
-
12
- export const getIconPath = (name) => {
13
- return `https://static.semrush.com/ui-kit/widget-empty/${version}/${name}.svg`;
14
- };
15
-
16
- class WidgetEmpty extends Component {
17
- static displayName = 'WidgetEmpty';
18
- static style = style;
19
-
20
- render() {
21
- const SWidgetEmpty = Root;
22
- const { Children, icon, styles } = this.asProps;
23
- const SImage = 'div';
24
-
25
- return sstyled(styles)(
26
- <SWidgetEmpty render={Flex}>
27
- {isNode(icon) && (
28
- <SImage>
29
- {typeof icon === 'string' ? (
30
- <img src={icon} alt="widget empty icon" width={100} height={72} />
31
- ) : (
32
- icon
33
- )}
34
- </SImage>
35
- )}
36
- <Children />
37
- </SWidgetEmpty>,
38
- );
39
- }
40
- }
41
-
42
- const Title = (props) => {
43
- const STitle = Root;
44
- const { styles } = props;
45
- return sstyled(styles)(<STitle render={Box} />);
46
- };
47
-
48
- const Description = (props) => {
49
- const SDescription = Root;
50
- const { styles } = props;
51
- return sstyled(styles)(<SDescription render={Box} />);
52
- };
53
-
54
- export default createComponent(WidgetEmpty, {
55
- Title,
56
- Description,
57
- });
package/src/index.d.ts DELETED
@@ -1,71 +0,0 @@
1
- import { ComponentProps } from 'react';
2
- import { CProps, ReturnEl } from '@semcore/core';
3
- import { Box, IFlexProps } from '@semcore/flex-box';
4
- import { IWithI18nEnhanceProps } from '@semcore/utils/lib/enhances/i18nEnhance';
5
-
6
- export type iconNamesWidgetEmpty =
7
- | 'area-chart'
8
- | 'choropleth-map-chart'
9
- | 'coffee'
10
- | 'combined-chart'
11
- | 'congrats'
12
- | 'deleted-page'
13
- | 'donut-chart'
14
- | 'duplicates'
15
- | 'funnel-chart'
16
- | 'good'
17
- | 'heat-map-chart'
18
- | 'horizontal-bar-chart'
19
- | 'kagi-chart'
20
- | 'line-chart'
21
- | 'lollipop-chart'
22
- | 'nexttime'
23
- | 'nothing-found'
24
- | 'other-data'
25
- | 'pie-chart'
26
- | 'processing'
27
- | 'radar-chart'
28
- | 'radial-tree-chart'
29
- | 'sankey-chart'
30
- | 'scatter-plot-chart'
31
- | 'stacked-area-chart'
32
- | 'suggestion'
33
- | 'suggestions'
34
- | 'table'
35
- | 'tag-cloud'
36
- | 'text-links-etc'
37
- | 'under-construction'
38
- | 'venn-chart'
39
- | 'vertical-bar-chart'
40
- | 'warning';
41
-
42
- export interface IWidgetEmptyProps extends IFlexProps {
43
- /**
44
- * URL before the icon or the whole component
45
- */
46
- icon?: React.ReactNode;
47
- }
48
-
49
- export interface IWidgetErrorProps extends IWidgetEmptyProps, IWithI18nEnhanceProps {
50
- /** Error description. If it is absent, use the local default one */
51
- description?: React.ReactNode;
52
- }
53
-
54
- export interface IWidgetNoDataProps extends IWidgetEmptyProps, IWithI18nEnhanceProps {
55
- /** Error description. If it is absent, use the local default one */
56
- description?: React.ReactNode;
57
- /* Data types */
58
- type?: iconNamesWidgetEmpty;
59
- }
60
-
61
- declare const WidgetEmpty: (<T>(props: CProps<IWidgetEmptyProps> & T) => ReturnEl) & {
62
- Title: <T>(props: ComponentProps<typeof Box> & T) => ReturnEl;
63
- Description: <T>(props: ComponentProps<typeof Box> & T) => ReturnEl;
64
- };
65
-
66
- declare const NoData: <T>(props: CProps<IWidgetNoDataProps> & T) => ReturnEl;
67
- declare const Error: <T>(props: CProps<IWidgetErrorProps> & T) => ReturnEl;
68
- declare const getIconPath: (name: string) => string;
69
-
70
- export default WidgetEmpty;
71
- export { getIconPath, NoData, Error };
package/src/index.js DELETED
@@ -1,6 +0,0 @@
1
- export { default } from './WidgetEmpty';
2
- export * from './WidgetEmpty';
3
-
4
- export { default as NoData } from './NoData';
5
-
6
- export { default as Error } from './Error';
@@ -1,41 +0,0 @@
1
- @import '@semcore/utils/style/var.css';
2
-
3
- SWidgetEmpty {
4
- flex-direction: column;
5
- justify-content: center;
6
- align-items: center;
7
- margin-bottom: 16px;
8
- }
9
-
10
- SImage {
11
- display: flex;
12
- align-items: flex-end;
13
- justify-content: center;
14
- margin-bottom: 12px;
15
- }
16
-
17
- STitle {
18
- color: var(--gray-500);
19
- }
20
-
21
- STitle {
22
- font-size: var(--fs-300);
23
- line-height: var(--lh-300);
24
- font-weight: bold;
25
- }
26
-
27
- SDescription {
28
- text-align: center;
29
- font-size: var(--fs-200);
30
- line-height: var(--lh-200);
31
- color: var(--gray-500);
32
- max-width: 400px;
33
- }
34
-
35
- STitle + SDescription {
36
- margin-top: 4px;
37
- }
38
-
39
- SDescription + SDescription {
40
- margin-top: 8px;
41
- }