@semcore/feedback-form 6.30.0 → 6.30.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.
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
+ ## [6.30.1] - 2024-07-05
6
+
7
+ ### Changed
8
+
9
+ - Version patch update due to children dependencies update (`@semcore/icon` [4.39.1 ~> 4.41.0], `@semcore/button` [5.31.0 ~> 5.31.1], `@semcore/tooltip` [6.36.0 ~> 6.36.1]).
10
+
5
11
  ## [6.30.0] - 2024-06-26
6
12
 
7
13
  ### Changed
@@ -174,7 +180,7 @@ CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangel
174
180
 
175
181
  ### Fixed
176
182
 
177
- - `validateOnBlur=false` behaviour.
183
+ - `validateOnBlur=false` behavior.
178
184
 
179
185
  ## [6.19.0] - 2024-02-01
180
186
 
@@ -580,7 +586,7 @@ CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangel
580
586
 
581
587
  ### Fixed
582
588
 
583
- - Added a11y error binding to field.
589
+ - Added A11Y error binding to field.
584
590
 
585
591
  ## [5.4.3] - 2023-03-24
586
592
 
@@ -660,7 +666,7 @@ CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangel
660
666
 
661
667
  ### Added
662
668
 
663
- - Added aria attributes for better a11y.
669
+ - Added aria attributes for better A11Y.
664
670
 
665
671
  ## [5.1.11] - 2022-08-30
666
672
 
@@ -838,7 +844,7 @@ CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangel
838
844
 
839
845
  ### Added
840
846
 
841
- - Появилась возможность добавления различных стилистических тем через css переменные
847
+ - Появилась возможность добавления различных стилистических тем через CSS переменные
842
848
  - Появилась возможность оптицонально подключать адаптивноссть
843
849
  - Появилась возможность изолировать стили даже в пределах одной страницы
844
850
 
@@ -28,13 +28,13 @@ var _FeedbackItem = require("./component/feedback-item/FeedbackItem");
28
28
  var _SubmitButton = require("./component/submit-button/SubmitButton");
29
29
  var _excluded = ["Children", "styles", "forwardRef", "loading", "background", "theme"];
30
30
  /*__reshadow-styles__:"./style/feedback-form.shadow.css"*/
31
- var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SFeedbackForm_1odos_gg_{max-width:320px}.___SCancel_1odos_gg_,.___SSubmit_1odos_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1odos_gg_{padding:var(--intergalactic-spacing-3x, 12px) var(--intergalactic-spacing-4x, 16px);border-width:1px 0 0;border-top-style:solid;border-radius:0 0 var(--intergalactic-surface-rounded, 6px) var(--intergalactic-surface-rounded, 6px)}.___SSuccess_1odos_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box}.___SEmail_1odos_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px) + var(--intergalactic-spacing-05x, 2px));width:80px;height:80px;background-image:url(\"data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345E0A8'/%3E%3Cpath d='M29 45.2852L29.2 45.6352C35.39 42.1852 53.39 31.9652 56.73 35.1052C55.6 32.0052 39.7 35.4352 29 45.2852Z' fill='white'/%3E%3Cpath d='M28.44 31.6343C26.63 37.6343 19.23 56.1043 15 61.9443L18 62.8543L19.58 61.5343C23.8 51.9843 29.58 35.5343 29.89 30.0743C29.39 29.8143 28.93 30.2143 28.44 31.6343Z' fill='white'/%3E%3Cpath d='M15 62.0078C19.23 56.1678 26.63 37.7378 28.44 31.6678C30.25 25.5978 33.49 37.6678 31.67 42.7878' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M28 45.9424C38.68 35.5824 55.27 31.9424 56.43 35.1024C57.12 36.9924 43 41.3624 38.02 47.4224' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M44.45 21.93C41.21 20.77 35.86 19.04 33 18.24C37.12 16.41 70 4.24 72.67 3C71.75 7.11 67.75 21.28 65.96 27.93C61.13 26.25 56.23 24.78 53.03 23.74C51.0298 26.3907 49.2219 29.1812 47.62 32.09C46.44 28.23 45.29 23.77 44.45 21.93Z' fill='white' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M45 22.08L61.74 11' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M53 23.73L72.64 3' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48 32.58L55.86 25' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.23 30.77L51.69 25.13L52.66 24L54.73 24.61L55.16 24.48L51.8 27.91L49.33 30.18L48 31.29L48.23 30.77Z' fill='black'/%3E%3Cpath d='M33.81 22L23 27.12' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M40.89 23L34 27.37' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M62.04 29L58 38.85' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M46.68 41C50.29 43.42 44.81 49.52 43 51.12' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M47.17 44C51.31 46.09 48.33 51.76 46 54.6' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.86 49C54.37 53.48 36.31 72.72 35 73.78' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cmask id='mask0_11950_117175' style='mask-type:alpha' maskUnits='userSpaceOnUse' x='4' y='6' width='73' height='73'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345DFA7'/%3E%3C/mask%3E%3Cg mask='url(%23mask0_11950_117175)'%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' fill='black'/%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E%0A\")}" /*__inner_css_end__*/, "1odos_gg_") /*__reshadow_css_end__*/, {
32
- "__SFeedbackForm": "___SFeedbackForm_1odos_gg_",
33
- "__SSubmit": "___SSubmit_1odos_gg_",
34
- "__SCancel": "___SCancel_1odos_gg_",
35
- "__SNotice": "___SNotice_1odos_gg_",
36
- "__SSuccess": "___SSuccess_1odos_gg_",
37
- "__SEmail": "___SEmail_1odos_gg_"
31
+ var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SFeedbackForm_1cid8_gg_{max-width:320px}.___SCancel_1cid8_gg_,.___SSubmit_1cid8_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1cid8_gg_{padding:var(--intergalactic-spacing-3x, 12px) var(--intergalactic-spacing-4x, 16px);border-width:1px 0 0;border-top-style:solid;border-radius:0 0 var(--intergalactic-surface-rounded, 6px) var(--intergalactic-surface-rounded, 6px)}.___SSuccess_1cid8_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box}.___SEmail_1cid8_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px) + var(--intergalactic-spacing-05x, 2px));width:80px;height:80px;background-image:url(\"data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345E0A8'/%3E%3Cpath d='M29 45.2852L29.2 45.6352C35.39 42.1852 53.39 31.9652 56.73 35.1052C55.6 32.0052 39.7 35.4352 29 45.2852Z' fill='white'/%3E%3Cpath d='M28.44 31.6343C26.63 37.6343 19.23 56.1043 15 61.9443L18 62.8543L19.58 61.5343C23.8 51.9843 29.58 35.5343 29.89 30.0743C29.39 29.8143 28.93 30.2143 28.44 31.6343Z' fill='white'/%3E%3Cpath d='M15 62.0078C19.23 56.1678 26.63 37.7378 28.44 31.6678C30.25 25.5978 33.49 37.6678 31.67 42.7878' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M28 45.9424C38.68 35.5824 55.27 31.9424 56.43 35.1024C57.12 36.9924 43 41.3624 38.02 47.4224' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M44.45 21.93C41.21 20.77 35.86 19.04 33 18.24C37.12 16.41 70 4.24 72.67 3C71.75 7.11 67.75 21.28 65.96 27.93C61.13 26.25 56.23 24.78 53.03 23.74C51.0298 26.3907 49.2219 29.1812 47.62 32.09C46.44 28.23 45.29 23.77 44.45 21.93Z' fill='white' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M45 22.08L61.74 11' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M53 23.73L72.64 3' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48 32.58L55.86 25' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.23 30.77L51.69 25.13L52.66 24L54.73 24.61L55.16 24.48L51.8 27.91L49.33 30.18L48 31.29L48.23 30.77Z' fill='black'/%3E%3Cpath d='M33.81 22L23 27.12' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M40.89 23L34 27.37' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M62.04 29L58 38.85' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M46.68 41C50.29 43.42 44.81 49.52 43 51.12' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M47.17 44C51.31 46.09 48.33 51.76 46 54.6' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.86 49C54.37 53.48 36.31 72.72 35 73.78' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cmask id='mask0_11950_117175' style='mask-type:alpha' maskUnits='userSpaceOnUse' x='4' y='6' width='73' height='73'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345DFA7'/%3E%3C/mask%3E%3Cg mask='url(%23mask0_11950_117175)'%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' fill='black'/%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E%0A\")}" /*__inner_css_end__*/, "1cid8_gg_") /*__reshadow_css_end__*/, {
32
+ "__SFeedbackForm": "___SFeedbackForm_1cid8_gg_",
33
+ "__SSubmit": "___SSubmit_1cid8_gg_",
34
+ "__SCancel": "___SCancel_1cid8_gg_",
35
+ "__SNotice": "___SNotice_1cid8_gg_",
36
+ "__SSuccess": "___SSuccess_1cid8_gg_",
37
+ "__SEmail": "___SEmail_1cid8_gg_"
38
38
  });
39
39
  var FeedbackForm = /*#__PURE__*/function (_Component) {
40
40
  (0, _inherits2["default"])(FeedbackForm, _Component);
@@ -84,8 +84,7 @@ var FeedbackForm = /*#__PURE__*/function (_Component) {
84
84
  "method": 'POST',
85
85
  "ref": forwardRef
86
86
  }, other), {}, {
87
- "onSubmit": api.handleSubmit,
88
- "title": 'This is feedback'
87
+ "onSubmit": api.handleSubmit
89
88
  })), typeof Children.origin === 'function' ? Children.origin(api) : /*#__PURE__*/_react["default"].createElement(Children, _ref4.cn("Children", {}))));
90
89
  });
91
90
  }
@@ -150,7 +149,7 @@ function Notice(props) {
150
149
  _ref7;
151
150
  var styles = props.styles,
152
151
  _props$theme = props.theme,
153
- theme = _props$theme === void 0 ? 'bg-secondary-neutral' : _props$theme,
152
+ theme = _props$theme === void 0 ? 'muted' : _props$theme,
154
153
  _props$use = props.use,
155
154
  use = _props$use === void 0 ? 'secondary' : _props$use;
156
155
  var SNotice = _notice.NoticeSmart;
@@ -1 +1 @@
1
- {"version":3,"file":"FeedbackForm.js","names":["_core","_interopRequireWildcard","require","_react","_interopRequireDefault","_reactFinalForm","_finalFormFocus","_button","_spinContainer","_notice","_flexBox","_FeedbackItem","_SubmitButton","_excluded","style","_index","sstyled","insert","FeedbackForm","_Component","_inherits2","_super","_createSuper2","_this","_classCallCheck2","_len","arguments","length","args","Array","_key","call","apply","concat","_defineProperty2","_assertThisInitialized2","createFocusDecorator","_createClass2","key","value","getItemProps","validateOnBlur","asProps","render","SFeedbackForm","Box","_this$asProps","Children","styles","forwardRef","loading","background","theme","other","_objectWithoutProperties2","createElement","Form","_extends2","decorators","focusDecorator","api","_ref4","cn","undefined","submitting","_objectSpread2","handleSubmit","origin","Component","Field","onSubmit","description","error","words","split","symbols","join","email","test","String","toLowerCase","Success","props","_ref","arguments[0]","_ref5","SSuccess","SEmail","assignProps","Cancel","_ref2","_ref6","SCancel","Button","Notice","_ref3","_ref7","_props$theme","_props$use","use","SNotice","NoticeSmart","_default","createComponent","Item","FeedbackItem","Submit","SubmitButton","exports"],"sources":["../../src/FeedbackForm.jsx"],"sourcesContent":["import React from 'react';\nimport { Field, Form } from 'react-final-form';\nimport createFocusDecorator from 'final-form-focus';\n\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport Button from '@semcore/button';\nimport SpinContainer from '@semcore/spin-container';\nimport { NoticeSmart } from '@semcore/notice';\nimport { Box } from '@semcore/flex-box';\n\nimport { FeedbackItem } from './component/feedback-item/FeedbackItem';\nimport { SubmitButton } from './component/submit-button/SubmitButton';\n\nimport style from './style/feedback-form.shadow.css';\n\nclass FeedbackForm extends Component {\n static displayName = 'FeedbackForm';\n static style = style;\n static FinalForm = {\n Field,\n Form,\n };\n\n static defaultProps = {\n onSubmit: () => {},\n };\n\n static validate = {\n description: (error) => (value = '') => {\n const words = value.split(/\\s+/);\n const symbols = words.join(' ');\n if (symbols.length < 10 || words.length < 3) {\n return error;\n }\n },\n email: (error) => (value = '') => {\n if (!/.+@.+\\..+/i.test(String(value).toLowerCase())) {\n return error;\n }\n },\n };\n\n focusDecorator = createFocusDecorator();\n\n getItemProps() {\n const { validateOnBlur } = this.asProps;\n\n return {\n validateOnBlur,\n };\n }\n\n render() {\n const SFeedbackForm = Box;\n const { Children, styles, forwardRef, loading, background, theme, ...other } = this.asProps;\n\n return (\n <Form decorators={[this.focusDecorator]} {...other}>\n {(api) =>\n sstyled(styles)(\n <SpinContainer\n background={background}\n theme={theme}\n size='xl'\n loading={loading === undefined ? api.submitting : loading}\n >\n <SFeedbackForm\n tag='form'\n noValidate\n method='POST'\n ref={forwardRef}\n {...other}\n onSubmit={api.handleSubmit}\n title='This is feedback'\n >\n {typeof Children.origin === 'function' ? Children.origin(api) : <Children />}\n </SFeedbackForm>\n </SpinContainer>,\n )\n }\n </Form>\n );\n }\n}\n\nfunction Success(props) {\n const { Children, styles } = props;\n const SSuccess = Root;\n const SEmail = 'div';\n\n return sstyled(styles)(\n <SSuccess render={Box}>\n <SEmail aria-hidden={true} />\n <span>\n <Children />\n </span>\n </SSuccess>,\n );\n}\n// because it is used without a wrapper\nSuccess.style = style;\n\nfunction Cancel(props) {\n const { styles } = props;\n const SCancel = Root;\n return sstyled(styles)(<SCancel render={Button} type='reset' use='secondary' theme='muted' />);\n}\n\nfunction Notice(props) {\n const { styles, theme = 'bg-secondary-neutral', use = 'secondary' } = props;\n const SNotice = Root;\n return sstyled(styles)(<SNotice render={NoticeSmart} theme={theme} use={use} />);\n}\n\nexport default createComponent(FeedbackForm, {\n Item: FeedbackItem,\n Success,\n Submit: SubmitButton,\n Cancel,\n Notice,\n});\n"],"mappings":";;;;;;;;;;;;;;;;;;AAIA,IAAAA,KAAA,GAAAC,uBAAA,CAAAC,OAAA;AAJA,IAAAC,MAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,eAAA,GAAAH,OAAA;AACA,IAAAI,eAAA,GAAAF,sBAAA,CAAAF,OAAA;AAGA,IAAAK,OAAA,GAAAH,sBAAA,CAAAF,OAAA;AACA,IAAAM,cAAA,GAAAJ,sBAAA,CAAAF,OAAA;AACA,IAAAO,OAAA,GAAAP,OAAA;AACA,IA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O,GAC2BC,mBAAW;EAAnD,OAAAL,KAAA,GAAO,IAAAhF,aAAO,EAACgC,MAAM,CAAC,eAAC7C,MAAA,YAAAoD,aAAA,CAAC6C,OAAO,EAAAJ,KAAA,CAAAlC,EAAA,gBAAAG,cAAA,qBAAAjE,KAAA,CAAAwF,WAAA;IAAA,SAA6BpC,KAAK;IAAA,OAAO+C;EAAG,GAAAJ,KAAA,IAAI;AACjF;AAAC,IAAAO,QAAA,GAEc,IAAAC,gBAAe,EAACrF,YAAY,EAAE;EAC3CsF,IAAI,EAAEC,0BAAY;EAClBxB,OAAO,EAAPA,OAAO;EACPyB,MAAM,EAAEC,0BAAY;EACpBlB,MAAM,EAANA,MAAM;EACNK,MAAM,EAANA;AACF,CAAC,CAAC;AAAAc,OAAA,cAAAN,QAAA"}
1
+ {"version":3,"file":"FeedbackForm.js","names":["_core","_interopRequireWildcard","require","_react","_interopRequireDefault","_reactFinalForm","_finalFormFocus","_button","_spinContainer","_notice","_flexBox","_FeedbackItem","_SubmitButton","_excluded","style","_index","sstyled","insert","FeedbackForm","_Component","_inherits2","_super","_createSuper2","_this","_classCallCheck2","_len","arguments","length","args","Array","_key","call","apply","concat","_defineProperty2","_assertThisInitialized2","createFocusDecorator","_createClass2","key","value","getItemProps","validateOnBlur","asProps","render","SFeedbackForm","Box","_this$asProps","Children","styles","forwardRef","loading","background","theme","other","_objectWithoutProperties2","createElement","Form","_extends2","decorators","focusDecorator","api","_ref4","cn","undefined","submitting","_objectSpread2","handleSubmit","origin","Component","Field","onSubmit","description","error","words","split","symbols","join","email","test","String","toLowerCase","Success","props","_ref","arguments[0]","_ref5","SSuccess","SEmail","assignProps","Cancel","_ref2","_ref6","SCancel","Button","Notice","_ref3","_ref7","_props$theme","_props$use","use","SNotice","NoticeSmart","_default","createComponent","Item","FeedbackItem","Submit","SubmitButton","exports"],"sources":["../../src/FeedbackForm.jsx"],"sourcesContent":["import React from 'react';\nimport { Field, Form } from 'react-final-form';\nimport createFocusDecorator from 'final-form-focus';\n\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport Button from '@semcore/button';\nimport SpinContainer from '@semcore/spin-container';\nimport { NoticeSmart } from '@semcore/notice';\nimport { Box } from '@semcore/flex-box';\n\nimport { FeedbackItem } from './component/feedback-item/FeedbackItem';\nimport { SubmitButton } from './component/submit-button/SubmitButton';\n\nimport style from './style/feedback-form.shadow.css';\n\nclass FeedbackForm extends Component {\n static displayName = 'FeedbackForm';\n static style = style;\n static FinalForm = {\n Field,\n Form,\n };\n\n static defaultProps = {\n onSubmit: () => {},\n };\n\n static validate = {\n description: (error) => (value = '') => {\n const words = value.split(/\\s+/);\n const symbols = words.join(' ');\n if (symbols.length < 10 || words.length < 3) {\n return error;\n }\n },\n email: (error) => (value = '') => {\n if (!/.+@.+\\..+/i.test(String(value).toLowerCase())) {\n return error;\n }\n },\n };\n\n focusDecorator = createFocusDecorator();\n\n getItemProps() {\n const { validateOnBlur } = this.asProps;\n\n return {\n validateOnBlur,\n };\n }\n\n render() {\n const SFeedbackForm = Box;\n const { Children, styles, forwardRef, loading, background, theme, ...other } = this.asProps;\n\n return (\n <Form decorators={[this.focusDecorator]} {...other}>\n {(api) =>\n sstyled(styles)(\n <SpinContainer\n background={background}\n theme={theme}\n size='xl'\n loading={loading === undefined ? api.submitting : loading}\n >\n <SFeedbackForm\n tag='form'\n noValidate\n method='POST'\n ref={forwardRef}\n {...other}\n onSubmit={api.handleSubmit}\n >\n {typeof Children.origin === 'function' ? Children.origin(api) : <Children />}\n </SFeedbackForm>\n </SpinContainer>,\n )\n }\n </Form>\n );\n }\n}\n\nfunction Success(props) {\n const { Children, styles } = props;\n const SSuccess = Root;\n const SEmail = 'div';\n\n return sstyled(styles)(\n <SSuccess render={Box}>\n <SEmail aria-hidden={true} />\n <span>\n <Children />\n </span>\n </SSuccess>,\n );\n}\n// because it is used without a wrapper\nSuccess.style = style;\n\nfunction Cancel(props) {\n const { styles } = props;\n const SCancel = Root;\n return sstyled(styles)(<SCancel render={Button} type='reset' use='secondary' theme='muted' />);\n}\n\nfunction Notice(props) {\n const { styles, theme = 'muted', use = 'secondary' } = props;\n const SNotice = Root;\n return sstyled(styles)(<SNotice render={NoticeSmart} theme={theme} use={use} />);\n}\n\nexport default createComponent(FeedbackForm, {\n Item: FeedbackItem,\n Success,\n Submit: SubmitButton,\n Cancel,\n Notice,\n});\n"],"mappings":";;;;;;;;;;;;;;;;;;AAIA,IAAAA,KAAA,GAAAC,uBAAA,CAAAC,OAAA;AAJA,IAAAC,MAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,eAAA,GAAAH,OAAA;AACA,IAAAI,eAAA,GAAAF,sBAAA,CAAAF,OAAA;AAGA,IAAAK,OAAA,GAAAH,sBAAA,CAAAF,OAAA;AACA,IAAAM,cAAA,GAAAJ,sBAAA,CAAAF,OAAA;AACA,IAAAO,OAAA,GAAAP,OAAA;AACA,IAAAQ,QAAA,GAAAR,OAAA;AAEA,IAAAS,aAAA,GAAAT,OAAA;AACA,IAAAU,aAAA,GAAAV,OAAA;AAAsE,IAAAW,SAAA;AAAA;AAAA,IAAAC,KAAA,+BAAAC,MAAA,CAAAC,OAAA,CAAAC,MAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;AAAA;AAAA,IAIhEC,YAAY,0BAAAC,UAAA;EAAA,IAAAC,UAAA,aAAAF,YAAA,EAAAC,UAAA;EAAA,IAAAE,MAAA,OAAAC,aAAA,aAAAJ,YAAA;EAAA,SAAAA,aAAA;IAAA,IAAAK,KAAA;IAAA,IAAAC,gBAAA,mBAAAN,YAAA;IAAA,SAAAO,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAAAC,IAAA,OAAAC,KAAA,CAAAJ,IAAA,GAAAK,IAAA,MAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA;MAAAF,IAAA,CAAAE,IAAA,IAAAJ,SAAA,CAAAI,IAAA;IAAA;IAAAP,KAAA,GAAAF,MAAA,CAAAU,IAAA,CAAAC,K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AAC,eAAC7C,MAAA,YAAAoD,aAAA,CAACqC,OAAO,EAAAD,KAAA,CAAA7B,EAAA,gBAAAG,cAAA,qBAAAjE,KAAA,CAAAwF,WAAA;IAAA,QAAsB,OAAO;IAAA,OAAK,WAAW;IAAA,SAAO;EAAO,GAAAE,KAAA,IAAG;AAC/F;AAEA,SAASI,MAAMA,CAACZ,KAAK,EAAE;EAAA,IAAAa,KAAA,GAAAX,YAAA;IAAAY,KAAA;EACrB,IAAQhD,MAAM,GAAyCkC,KAAK,CAApDlC,MAAM;IAAAiD,YAAA,GAAyCf,KAAK,CAA5C9B,KAAK;IAALA,KAAK,GAAA6C,YAAA,cAAG,OAAO,GAAAA,YAAA;IAAAC,UAAA,GAAwBhB,KAAK,CAA3BiB,GAAG;IAAHA,GAAG,GAAAD,UAAA,cAAG,WAAW,GAAAA,UAAA;EAClD,IAAME,OAAO,GAC2BC,mBAAW;EAAnD,OAAAL,KAAA,GAAO,IAAAhF,aAAO,EAACgC,MAAM,CAAC,eAAC7C,MAAA,YAAAoD,aAAA,CAAC6C,OAAO,EAAAJ,KAAA,CAAAlC,EAAA,gBAAAG,cAAA,qBAAAjE,KAAA,CAAAwF,WAAA;IAAA,SAA6BpC,KAAK;IAAA,OAAO+C;EAAG,GAAAJ,KAAA,IAAI;AACjF;AAAC,IAAAO,QAAA,GAEc,IAAAC,gBAAe,EAACrF,YAAY,EAAE;EAC3CsF,IAAI,EAAEC,0BAAY;EAClBxB,OAAO,EAAPA,OAAO;EACPyB,MAAM,EAAEC,0BAAY;EACpBlB,MAAM,EAANA,MAAM;EACNK,MAAM,EAANA;AACF,CAAC,CAAC;AAAAc,OAAA,cAAAN,QAAA"}
@@ -20,9 +20,9 @@ var _flexBox = require("@semcore/flex-box");
20
20
  var _checkbox = _interopRequireDefault(require("@semcore/checkbox"));
21
21
  var _excluded = ["styles", "id", "label"];
22
22
  /*__reshadow-styles__:"../../style/checkbox-button.shadow.css"*/
23
- var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SCheckboxButton_1mrr9_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_1mrr9_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_1mrr9_gg_.__checked_1mrr9_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_1mrr9_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_1mrr9_gg_.__checked_1mrr9_gg_:hover{background-color:rgba(0,143,248,.2)}}" /*__inner_css_end__*/, "1mrr9_gg_") /*__reshadow_css_end__*/, {
24
- "__SCheckboxButton": "___SCheckboxButton_1mrr9_gg_",
25
- "_checked": "__checked_1mrr9_gg_"
23
+ var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SCheckboxButton_pei2o_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_pei2o_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_pei2o_gg_.__checked_pei2o_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_pei2o_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_pei2o_gg_.__checked_pei2o_gg_:hover{background-color:rgba(0,143,248,.2)}}" /*__inner_css_end__*/, "pei2o_gg_") /*__reshadow_css_end__*/, {
24
+ "__SCheckboxButton": "___SCheckboxButton_pei2o_gg_",
25
+ "_checked": "__checked_pei2o_gg_"
26
26
  });
27
27
  var CheckboxButtonRoot = /*#__PURE__*/function (_Component) {
28
28
  (0, _inherits2["default"])(CheckboxButtonRoot, _Component);
@@ -13,6 +13,7 @@ var _reactFinalForm = require("react-final-form");
13
13
  var _tooltip = _interopRequireDefault(require("@semcore/tooltip"));
14
14
  var _pick = _interopRequireDefault(require("@semcore/utils/lib/pick"));
15
15
  var _uniqueID = _interopRequireDefault(require("@semcore/utils/lib/uniqueID"));
16
+ var _core = require("@semcore/utils/lib/core");
16
17
  var _excluded = ["Children", "tag", "uid", "tooltipProps"],
17
18
  _excluded2 = ["input", "meta"];
18
19
  var deafultTooltipPropsList = ['title', 'theme', 'strategy', 'modifiers', 'placement', 'interaction', 'timeout', 'visible', 'defaultVisible', 'onVisibleChange', 'offset', 'preventOverflow', 'arrow', 'flip', 'computeStyles', 'eventListeners', 'onFirstUpdate'];
@@ -33,11 +34,13 @@ function FeedbackItem(_ref) {
33
34
  var showError = other.validateOnBlur === false ? meta.submitFailed : true;
34
35
  var invalid = meta.invalid && meta.touched;
35
36
  var errorState = showError && invalid;
36
- var inputProps = (0, _objectSpread2["default"])((0, _objectSpread2["default"])({}, input), {}, {
37
+ var popperId = "".concat(uid, "-error-description");
38
+ var inputProps = (0, _core.assignProps)((0, _objectSpread2["default"])((0, _objectSpread2["default"])({}, other), {}, {
37
39
  state: errorState ? 'invalid' : 'normal',
38
40
  'aria-invalid': errorState ? true : false,
39
- 'aria-errormessage': uid
40
- });
41
+ 'aria-errormessage': popperId,
42
+ 'aria-describedby': errorState && meta.active ? popperId : undefined
43
+ }), input);
41
44
  if (meta !== null && meta !== void 0 && meta.error) lastErrorRef.current = meta.error;
42
45
  return /*#__PURE__*/_react["default"].createElement(_tooltip["default"], (0, _extends2["default"])({
43
46
  visible: errorState && meta.active,
@@ -54,8 +57,8 @@ function FeedbackItem(_ref) {
54
57
  input: inputProps,
55
58
  meta: meta
56
59
  }, other))), /*#__PURE__*/_react["default"].createElement(_tooltip["default"].Popper, {
57
- id: uid,
58
- ignorePortalsStacking: true
60
+ w: '100%',
61
+ id: popperId
59
62
  }, (_meta$error = meta.error) !== null && _meta$error !== void 0 ? _meta$error : lastErrorRef.current));
60
63
  });
61
64
  }
@@ -1 +1 @@
1
- {"version":3,"file":"FeedbackItem.js","names":["_react","_interopRequireDefault","require","_reactFinalForm","_tooltip","_pick","_uniqueID","_excluded","_excluded2","deafultTooltipPropsList","FeedbackItem","_ref","Children","tag","uid","_ref$tooltipProps","tooltipProps","tooltipPropsList","props","_objectWithoutProperties2","pick","lastErrorRef","React","useRef","undefined","createElement","Field","_ref2","_meta$error","input","meta","other","showError","validateOnBlur","submitFailed","invalid","touched","errorState","inputProps","_objectSpread2","state","error","current","_extends2","visible","active","theme","placement","flip","fallbackPlacements","Trigger","inline","role","origin","Popper","id","ignorePortalsStacking","enhance","uniqueIDEnhancement"],"sources":["../../../../src/component/feedback-item/FeedbackItem.tsx"],"sourcesContent":["import React from 'react';\nimport { Field } from 'react-final-form';\nimport Tooltip from '@semcore/tooltip';\nimport pick from '@semcore/utils/lib/pick';\nimport uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';\n\nconst deafultTooltipPropsList = [\n 'title',\n 'theme',\n 'strategy',\n 'modifiers',\n 'placement',\n 'interaction',\n 'timeout',\n 'visible',\n 'defaultVisible',\n 'onVisibleChange',\n 'offset',\n 'preventOverflow',\n 'arrow',\n 'flip',\n 'computeStyles',\n 'eventListeners',\n 'onFirstUpdate',\n];\n\nexport function FeedbackItem({\n Children,\n tag,\n uid,\n tooltipProps: tooltipPropsList = deafultTooltipPropsList,\n ...props\n}: any) {\n const tooltipProps = pick(props, tooltipPropsList);\n const lastErrorRef = React.useRef(undefined);\n\n return (\n <Field {...props}>\n {({ input, meta, ...other }) => {\n const showError = other.validateOnBlur === false ? meta.submitFailed : true;\n const invalid = meta.invalid && meta.touched;\n const errorState = showError && invalid;\n const inputProps = {\n ...input,\n state: errorState ? 'invalid' : 'normal',\n 'aria-invalid': errorState ? true : false,\n 'aria-errormessage': uid,\n };\n if (meta?.error) lastErrorRef.current = meta.error;\n\n return (\n <Tooltip\n visible={errorState && meta.active}\n theme='warning'\n placement='left'\n flip={{\n fallbackPlacements: ['right', 'bottom'],\n }}\n {...tooltipProps}\n >\n <Tooltip.Trigger inline={false} role={undefined} tag={tag} {...(tag ? inputProps : {})}>\n {typeof Children.origin === 'function' &&\n Children.origin({\n input: inputProps,\n meta,\n ...other,\n })}\n </Tooltip.Trigger>\n <Tooltip.Popper id={uid} ignorePortalsStacking>\n {meta.error ?? lastErrorRef.current}\n </Tooltip.Popper>\n </Tooltip>\n );\n }}\n </Field>\n );\n}\nFeedbackItem.enhance = [uniqueIDEnhancement()];\n"],"mappings":";;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,eAAA,GAAAD,OAAA;AACA,IAAAE,QAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,KAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,SAAA,GAAAL,sBAAA,CAAAC,OAAA;AAA8D,IAAAK,SAAA;EAAAC,UAAA;AAE9D,IAAMC,uBAAuB,GAAG,CAC9B,OAAO,EACP,OAAO,EACP,UAAU,EACV,WAAW,EACX,WAAW,EACX,aAAa,EACb,SAAS,EACT,SAAS,EACT,gBAAgB,EAChB,iBAAiB,EACjB,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,MAAM,EACN,eAAe,EACf,gBAAgB,EAChB,eAAe,CAChB;AAEM,SAASC,YAAYA,CAAAC,IAAA,EAMpB;EAAA,IALNC,QAAQ,GAAAD,IAAA,CAARC,QAAQ;IACRC,GAAG,GAAAF,IAAA,CAAHE,GAAG;IACHC,GAAG,GAAAH,IAAA,CAAHG,GAAG;IAAAC,iBAAA,GAAAJ,IAAA,CACHK,YAAY;IAAEC,gBAAgB,GAAAF,iBAAA,cAAGN,uBAAuB,GAAAM,iBAAA;IACrDG,KAAK,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AAA,YAAAyB,aAAA,CAACrB,QAAA,WAAO,CAAC8C,OAAO,MAAAP,SAAA;MAACQ,MAAM,EAAE,KAAM;MAACC,IAAI,EAAE5B,SAAU;MAACX,GAAG,EAAEA;IAAI,GAAMA,GAAG,GAAGyB,UAAU,GAAG,CAAC,CAAC,GAClF,OAAO1B,QAAQ,CAACyC,MAAM,KAAK,UAAU,IACpCzC,QAAQ,CAACyC,MAAM,KAAAd,cAAA;MACbV,KAAK,EAAES,UAAU;MACjBR,IAAI,EAAJA;IAAI,GACDC,KAAK,EACR,CACY,eAClB/B,MAAA,YAAAyB,aAAA,CAACrB,QAAA,WAAO,CAACkD,MAAM;MAACC,EAAE,EAAEzC,GAAI;MAAC0C,qBAAqB;IAAA,IAAA5B,WAAA,GAC3CE,IAAI,CAACW,KAAK,cAAAb,WAAA,cAAAA,WAAA,GAAIP,YAAY,CAACqB,OAAO,CACpB,CACT;EAEd,CAAC,CACK;AAEZ;AACAhC,YAAY,CAAC+C,OAAO,GAAG,CAAC,IAAAC,oBAAmB,GAAE,CAAC"}
1
+ {"version":3,"file":"FeedbackItem.js","names":["_react","_interopRequireDefault","require","_reactFinalForm","_tooltip","_pick","_uniqueID","_core","_excluded","_excluded2","deafultTooltipPropsList","FeedbackItem","_ref","Children","tag","uid","_ref$tooltipProps","tooltipProps","tooltipPropsList","props","_objectWithoutProperties2","pick","lastErrorRef","React","useRef","undefined","createElement","Field","_ref2","_meta$error","input","meta","other","showError","validateOnBlur","submitFailed","invalid","touched","errorState","popperId","concat","inputProps","assignProps","_objectSpread2","state","active","error","current","_extends2","visible","theme","placement","flip","fallbackPlacements","Trigger","inline","role","origin","Popper","w","id","enhance","uniqueIDEnhancement"],"sources":["../../../../src/component/feedback-item/FeedbackItem.tsx"],"sourcesContent":["import React from 'react';\nimport { Field } from 'react-final-form';\nimport Tooltip from '@semcore/tooltip';\nimport pick from '@semcore/utils/lib/pick';\nimport uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';\nimport { assignProps } from '@semcore/utils/lib/core';\n\nconst deafultTooltipPropsList = [\n 'title',\n 'theme',\n 'strategy',\n 'modifiers',\n 'placement',\n 'interaction',\n 'timeout',\n 'visible',\n 'defaultVisible',\n 'onVisibleChange',\n 'offset',\n 'preventOverflow',\n 'arrow',\n 'flip',\n 'computeStyles',\n 'eventListeners',\n 'onFirstUpdate',\n];\n\nexport function FeedbackItem({\n Children,\n tag,\n uid,\n tooltipProps: tooltipPropsList = deafultTooltipPropsList,\n ...props\n}: any) {\n const tooltipProps = pick(props, tooltipPropsList);\n const lastErrorRef = React.useRef(undefined);\n\n return (\n <Field {...props}>\n {({ input, meta, ...other }) => {\n const showError = other.validateOnBlur === false ? meta.submitFailed : true;\n const invalid = meta.invalid && meta.touched;\n const errorState = showError && invalid;\n const popperId = `${uid}-error-description`;\n const inputProps = assignProps(\n {\n ...other,\n state: errorState ? 'invalid' : 'normal',\n 'aria-invalid': errorState ? true : false,\n 'aria-errormessage': popperId,\n 'aria-describedby': errorState && meta.active ? popperId : undefined,\n },\n input,\n );\n if (meta?.error) lastErrorRef.current = meta.error;\n\n return (\n <Tooltip\n visible={errorState && meta.active}\n theme='warning'\n placement='left'\n flip={{\n fallbackPlacements: ['right', 'bottom'],\n }}\n {...tooltipProps}\n >\n <Tooltip.Trigger inline={false} role={undefined} tag={tag} {...(tag ? inputProps : {})}>\n {typeof Children.origin === 'function' &&\n Children.origin({\n input: inputProps,\n meta,\n ...other,\n })}\n </Tooltip.Trigger>\n <Tooltip.Popper w={'100%'} id={popperId}>\n {meta.error ?? lastErrorRef.current}\n </Tooltip.Popper>\n </Tooltip>\n );\n }}\n </Field>\n );\n}\nFeedbackItem.enhance = [uniqueIDEnhancement()];\n"],"mappings":";;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,eAAA,GAAAD,OAAA;AACA,IAAAE,QAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,KAAA,GAAAJ,sB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ACC,CAAC,EAAE,MAAO;MAACC,EAAE,EAAErB;IAAS,IAAAV,WAAA,GACrCE,IAAI,CAACe,KAAK,cAAAjB,WAAA,cAAAA,WAAA,GAAIP,YAAY,CAACyB,OAAO,CACpB,CACT;EAEd,CAAC,CACK;AAEZ;AACApC,YAAY,CAACkD,OAAO,GAAG,CAAC,IAAAC,oBAAmB,GAAE,CAAC"}
@@ -42,8 +42,8 @@ var _intergalacticDynamicLocales = require("../../translations/__intergalactic-d
42
42
  var _noticeBubble = require("@semcore/notice-bubble");
43
43
  var _excluded = ["header", "submitText", "formConfig", "notificationText", "learnMoreLink", "Children", "styles", "forwardRef", "status", "theme", "background", "rating", "visible", "onVisibleChange", "notificationVisible", "onNotificationClose", "getI18nText", "errorFeedbackEmail"];
44
44
  /*__reshadow-styles__:"../../style/feedback-rating.shadow.css"*/
45
- var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SFeedbackRating_1btu1_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_1btu1_gg_ li{list-style:none}" /*__inner_css_end__*/, "1btu1_gg_") /*__reshadow_css_end__*/, {
46
- "__SFeedbackRating": "___SFeedbackRating_1btu1_gg_"
45
+ var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SFeedbackRating_1i4d1_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_1i4d1_gg_ li{list-style:none}" /*__inner_css_end__*/, "1i4d1_gg_") /*__reshadow_css_end__*/, {
46
+ "__SFeedbackRating": "___SFeedbackRating_1i4d1_gg_"
47
47
  });
48
48
  var FeedbackRatingRoot = /*#__PURE__*/function (_Component) {
49
49
  (0, _inherits2["default"])(FeedbackRatingRoot, _Component);
@@ -19,12 +19,12 @@ var _react = _interopRequireDefault(require("react"));
19
19
  var _flexBox = require("@semcore/flex-box");
20
20
  var _keyboardFocusEnhance = _interopRequireDefault(require("@semcore/utils/lib/enhances/keyboardFocusEnhance"));
21
21
  /*__reshadow-styles__:"../../style/slider-rating.shadow.css"*/
22
- var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SSliderRating_xvu7s_gg_ .___SStar_xvu7s_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}@media (hover:hover){.___SSliderRating_xvu7s_gg_ .___SStar_xvu7s_gg_:hover{cursor:pointer;transform:scale(1.3)}}.___SSliderRating_xvu7s_gg_.__keyboardFocused_xvu7s_gg_{outline:0;box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}@media (hover:hover){.___SSliderRating_xvu7s_gg_.__readonly_xvu7s_gg_ .___SStar_xvu7s_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_xvu7s_gg_.__filled_xvu7s_gg_:active{animation:wobble .8s ease-in-out}.___SStar_xvu7s_gg_ path{fill:transparent;stroke:var(--intergalactic-slider-rating-normal, #a9abb6);stroke-width:2}.___SStar_xvu7s_gg_.__filled_xvu7s_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}" /*__inner_css_end__*/, "xvu7s_gg_") /*__reshadow_css_end__*/, {
23
- "__SSliderRating": "___SSliderRating_xvu7s_gg_",
24
- "__SStar": "___SStar_xvu7s_gg_",
25
- "_keyboardFocused": "__keyboardFocused_xvu7s_gg_",
26
- "_readonly": "__readonly_xvu7s_gg_",
27
- "_filled": "__filled_xvu7s_gg_"
22
+ var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SSliderRating_17fwp_gg_ .___SStar_17fwp_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}@media (hover:hover){.___SSliderRating_17fwp_gg_ .___SStar_17fwp_gg_:hover{cursor:pointer;transform:scale(1.3)}}.___SSliderRating_17fwp_gg_.__keyboardFocused_17fwp_gg_{outline:0;box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}@media (hover:hover){.___SSliderRating_17fwp_gg_.__readonly_17fwp_gg_ .___SStar_17fwp_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_17fwp_gg_.__filled_17fwp_gg_:active{animation:wobble .8s ease-in-out}.___SStar_17fwp_gg_ path{fill:transparent;stroke:var(--intergalactic-slider-rating-normal, #a9abb6);stroke-width:2}.___SStar_17fwp_gg_.__filled_17fwp_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}" /*__inner_css_end__*/, "17fwp_gg_") /*__reshadow_css_end__*/, {
23
+ "__SSliderRating": "___SSliderRating_17fwp_gg_",
24
+ "__SStar": "___SStar_17fwp_gg_",
25
+ "_keyboardFocused": "__keyboardFocused_17fwp_gg_",
26
+ "_readonly": "__readonly_17fwp_gg_",
27
+ "_filled": "__filled_17fwp_gg_"
28
28
  });
29
29
  var MIN = 1;
30
30
  var MAX = 5;
@@ -23,13 +23,13 @@ import { Box } from '@semcore/flex-box';
23
23
  import { FeedbackItem } from './component/feedback-item/FeedbackItem';
24
24
  import { SubmitButton } from './component/submit-button/SubmitButton';
25
25
  /*__reshadow-styles__:"./style/feedback-form.shadow.css"*/
26
- var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SFeedbackForm_1odos_gg_{max-width:320px}.___SCancel_1odos_gg_,.___SSubmit_1odos_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1odos_gg_{padding:var(--intergalactic-spacing-3x, 12px) var(--intergalactic-spacing-4x, 16px);border-width:1px 0 0;border-top-style:solid;border-radius:0 0 var(--intergalactic-surface-rounded, 6px) var(--intergalactic-surface-rounded, 6px)}.___SSuccess_1odos_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box}.___SEmail_1odos_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px) + var(--intergalactic-spacing-05x, 2px));width:80px;height:80px;background-image:url(\"data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345E0A8'/%3E%3Cpath d='M29 45.2852L29.2 45.6352C35.39 42.1852 53.39 31.9652 56.73 35.1052C55.6 32.0052 39.7 35.4352 29 45.2852Z' fill='white'/%3E%3Cpath d='M28.44 31.6343C26.63 37.6343 19.23 56.1043 15 61.9443L18 62.8543L19.58 61.5343C23.8 51.9843 29.58 35.5343 29.89 30.0743C29.39 29.8143 28.93 30.2143 28.44 31.6343Z' fill='white'/%3E%3Cpath d='M15 62.0078C19.23 56.1678 26.63 37.7378 28.44 31.6678C30.25 25.5978 33.49 37.6678 31.67 42.7878' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M28 45.9424C38.68 35.5824 55.27 31.9424 56.43 35.1024C57.12 36.9924 43 41.3624 38.02 47.4224' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M44.45 21.93C41.21 20.77 35.86 19.04 33 18.24C37.12 16.41 70 4.24 72.67 3C71.75 7.11 67.75 21.28 65.96 27.93C61.13 26.25 56.23 24.78 53.03 23.74C51.0298 26.3907 49.2219 29.1812 47.62 32.09C46.44 28.23 45.29 23.77 44.45 21.93Z' fill='white' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M45 22.08L61.74 11' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M53 23.73L72.64 3' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48 32.58L55.86 25' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.23 30.77L51.69 25.13L52.66 24L54.73 24.61L55.16 24.48L51.8 27.91L49.33 30.18L48 31.29L48.23 30.77Z' fill='black'/%3E%3Cpath d='M33.81 22L23 27.12' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M40.89 23L34 27.37' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M62.04 29L58 38.85' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M46.68 41C50.29 43.42 44.81 49.52 43 51.12' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M47.17 44C51.31 46.09 48.33 51.76 46 54.6' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.86 49C54.37 53.48 36.31 72.72 35 73.78' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cmask id='mask0_11950_117175' style='mask-type:alpha' maskUnits='userSpaceOnUse' x='4' y='6' width='73' height='73'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345DFA7'/%3E%3C/mask%3E%3Cg mask='url(%23mask0_11950_117175)'%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' fill='black'/%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E%0A\")}" /*__inner_css_end__*/, "1odos_gg_") /*__reshadow_css_end__*/, {
27
- "__SFeedbackForm": "___SFeedbackForm_1odos_gg_",
28
- "__SSubmit": "___SSubmit_1odos_gg_",
29
- "__SCancel": "___SCancel_1odos_gg_",
30
- "__SNotice": "___SNotice_1odos_gg_",
31
- "__SSuccess": "___SSuccess_1odos_gg_",
32
- "__SEmail": "___SEmail_1odos_gg_"
26
+ var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SFeedbackForm_1cid8_gg_{max-width:320px}.___SCancel_1cid8_gg_,.___SSubmit_1cid8_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1cid8_gg_{padding:var(--intergalactic-spacing-3x, 12px) var(--intergalactic-spacing-4x, 16px);border-width:1px 0 0;border-top-style:solid;border-radius:0 0 var(--intergalactic-surface-rounded, 6px) var(--intergalactic-surface-rounded, 6px)}.___SSuccess_1cid8_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box}.___SEmail_1cid8_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px) + var(--intergalactic-spacing-05x, 2px));width:80px;height:80px;background-image:url(\"data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345E0A8'/%3E%3Cpath d='M29 45.2852L29.2 45.6352C35.39 42.1852 53.39 31.9652 56.73 35.1052C55.6 32.0052 39.7 35.4352 29 45.2852Z' fill='white'/%3E%3Cpath d='M28.44 31.6343C26.63 37.6343 19.23 56.1043 15 61.9443L18 62.8543L19.58 61.5343C23.8 51.9843 29.58 35.5343 29.89 30.0743C29.39 29.8143 28.93 30.2143 28.44 31.6343Z' fill='white'/%3E%3Cpath d='M15 62.0078C19.23 56.1678 26.63 37.7378 28.44 31.6678C30.25 25.5978 33.49 37.6678 31.67 42.7878' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M28 45.9424C38.68 35.5824 55.27 31.9424 56.43 35.1024C57.12 36.9924 43 41.3624 38.02 47.4224' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M44.45 21.93C41.21 20.77 35.86 19.04 33 18.24C37.12 16.41 70 4.24 72.67 3C71.75 7.11 67.75 21.28 65.96 27.93C61.13 26.25 56.23 24.78 53.03 23.74C51.0298 26.3907 49.2219 29.1812 47.62 32.09C46.44 28.23 45.29 23.77 44.45 21.93Z' fill='white' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M45 22.08L61.74 11' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M53 23.73L72.64 3' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48 32.58L55.86 25' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.23 30.77L51.69 25.13L52.66 24L54.73 24.61L55.16 24.48L51.8 27.91L49.33 30.18L48 31.29L48.23 30.77Z' fill='black'/%3E%3Cpath d='M33.81 22L23 27.12' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M40.89 23L34 27.37' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M62.04 29L58 38.85' stroke='white' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M46.68 41C50.29 43.42 44.81 49.52 43 51.12' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M47.17 44C51.31 46.09 48.33 51.76 46 54.6' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M48.86 49C54.37 53.48 36.31 72.72 35 73.78' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cmask id='mask0_11950_117175' style='mask-type:alpha' maskUnits='userSpaceOnUse' x='4' y='6' width='73' height='73'%3E%3Cpath d='M28.1632 6.00003C27.9554 5.99875 27.7493 6.03875 27.5571 6.11772C27.3648 6.19668 27.1902 6.31304 27.0432 6.46003L14.1332 19.38C7.645 25.8687 4 34.669 4 43.845C4 53.0211 7.645 61.8213 14.1332 68.31C17.3463 71.5242 21.1611 74.0738 25.3597 75.8134C29.5583 77.5529 34.0585 78.4482 38.6032 78.4482C43.1479 78.4482 47.6481 77.5529 51.8467 75.8134C56.0454 74.0738 59.8602 71.5242 63.0732 68.31L75.9832 55.4C76.1316 55.2536 76.2495 55.0792 76.3301 54.887C76.4108 54.6948 76.4526 54.4885 76.4532 54.28V6.89003C76.4506 6.65307 76.3546 6.42671 76.1861 6.26009C76.0176 6.09346 75.7902 6.00002 75.5532 6.00003H28.1632Z' fill='%2345DFA7'/%3E%3C/mask%3E%3Cg mask='url(%23mask0_11950_117175)'%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' fill='black'/%3E%3Cpath d='M5 74.6871C7.49 72.3471 13.24 63.6871 14.52 61.2471C28.18 59.1271 34.71 71.2471 34.98 74.7671C32.7234 79.651 30.1305 84.3723 27.22 88.8971' stroke='black' stroke-width='0.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E%0A\")}" /*__inner_css_end__*/, "1cid8_gg_") /*__reshadow_css_end__*/, {
27
+ "__SFeedbackForm": "___SFeedbackForm_1cid8_gg_",
28
+ "__SSubmit": "___SSubmit_1cid8_gg_",
29
+ "__SCancel": "___SCancel_1cid8_gg_",
30
+ "__SNotice": "___SNotice_1cid8_gg_",
31
+ "__SSuccess": "___SSuccess_1cid8_gg_",
32
+ "__SEmail": "___SEmail_1cid8_gg_"
33
33
  });
34
34
  var FeedbackForm = /*#__PURE__*/function (_Component) {
35
35
  _inherits(FeedbackForm, _Component);
@@ -79,8 +79,7 @@ var FeedbackForm = /*#__PURE__*/function (_Component) {
79
79
  "method": 'POST',
80
80
  "ref": forwardRef
81
81
  }, other), {}, {
82
- "onSubmit": api.handleSubmit,
83
- "title": 'This is feedback'
82
+ "onSubmit": api.handleSubmit
84
83
  })), typeof Children.origin === 'function' ? Children.origin(api) : /*#__PURE__*/React.createElement(Children, _ref4.cn("Children", {}))));
85
84
  });
86
85
  }
@@ -145,7 +144,7 @@ function Notice(props) {
145
144
  _ref7;
146
145
  var styles = props.styles,
147
146
  _props$theme = props.theme,
148
- theme = _props$theme === void 0 ? 'bg-secondary-neutral' : _props$theme,
147
+ theme = _props$theme === void 0 ? 'muted' : _props$theme,
149
148
  _props$use = props.use,
150
149
  use = _props$use === void 0 ? 'secondary' : _props$use;
151
150
  var SNotice = NoticeSmart;
@@ -1 +1 @@
1
- {"version":3,"file":"FeedbackForm.js","names":["React","Field","Form","createFocusDecorator","createComponent","Component","sstyled","Root","Button","SpinContainer","NoticeSmart","Box","FeedbackItem","SubmitButton","style","_sstyled","insert","FeedbackForm","_Component","_inherits","_super","_createSuper","_this","_classCallCheck","_len","arguments","length","args","Array","_key","call","apply","concat","_defineProperty","_assertThisInitialized","_createClass","key","value","getItemProps","validateOnBlur","asProps","render","SFeedbackForm","_this$asProps","Children","styles","forwardRef","loading","background","theme","other","_objectWithoutProperties","_excluded","createElement","_extends","decorators","focusDecorator","api","_ref4","cn","undefined","submitting","_objectSpread","handleSubmit","origin","onSubmit","description","error","words","split","symbols","join","email","test","String","toLowerCase","Success","props","_ref","arguments[0]","_ref5","SSuccess","SEmail","_assignProps","Cancel","_ref2","_ref6","SCancel","_assignProps2","Notice","_ref3","_ref7","_props$theme","_props$use","use","SNotice","_assignProps3","Item","Submit"],"sources":["../../src/FeedbackForm.jsx"],"sourcesContent":["import React from 'react';\nimport { Field, Form } from 'react-final-form';\nimport createFocusDecorator from 'final-form-focus';\n\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport Button from '@semcore/button';\nimport SpinContainer from '@semcore/spin-container';\nimport { NoticeSmart } from '@semcore/notice';\nimport { Box } from '@semcore/flex-box';\n\nimport { FeedbackItem } from './component/feedback-item/FeedbackItem';\nimport { SubmitButton } from './component/submit-button/SubmitButton';\n\nimport style from './style/feedback-form.shadow.css';\n\nclass FeedbackForm extends Component {\n static displayName = 'FeedbackForm';\n static style = style;\n static FinalForm = {\n Field,\n Form,\n };\n\n static defaultProps = {\n onSubmit: () => {},\n };\n\n static validate = {\n description: (error) => (value = '') => {\n const words = value.split(/\\s+/);\n const symbols = words.join(' ');\n if (symbols.length < 10 || words.length < 3) {\n return error;\n }\n },\n email: (error) => (value = '') => {\n if (!/.+@.+\\..+/i.test(String(value).toLowerCase())) {\n return error;\n }\n },\n };\n\n focusDecorator = createFocusDecorator();\n\n getItemProps() {\n const { validateOnBlur } = this.asProps;\n\n return {\n validateOnBlur,\n };\n }\n\n render() {\n const SFeedbackForm = Box;\n const { Children, styles, forwardRef, loading, background, theme, ...other } = this.asProps;\n\n return (\n <Form decorators={[this.focusDecorator]} {...other}>\n {(api) =>\n sstyled(styles)(\n <SpinContainer\n background={background}\n theme={theme}\n size='xl'\n loading={loading === undefined ? api.submitting : loading}\n >\n <SFeedbackForm\n tag='form'\n noValidate\n method='POST'\n ref={forwardRef}\n {...other}\n onSubmit={api.handleSubmit}\n title='This is feedback'\n >\n {typeof Children.origin === 'function' ? Children.origin(api) : <Children />}\n </SFeedbackForm>\n </SpinContainer>,\n )\n }\n </Form>\n );\n }\n}\n\nfunction Success(props) {\n const { Children, styles } = props;\n const SSuccess = Root;\n const SEmail = 'div';\n\n return sstyled(styles)(\n <SSuccess render={Box}>\n <SEmail aria-hidden={true} />\n <span>\n <Children />\n </span>\n </SSuccess>,\n );\n}\n// because it is used without a wrapper\nSuccess.style = style;\n\nfunction Cancel(props) {\n const { styles } = props;\n const SCancel = Root;\n return sstyled(styles)(<SCancel render={Button} type='reset' use='secondary' theme='muted' />);\n}\n\nfunction Notice(props) {\n const { styles, theme = 'bg-secondary-neutral', use = 'secondary' } = props;\n const SNotice = Root;\n return sstyled(styles)(<SNotice render={NoticeSmart} theme={theme} use={use} />);\n}\n\nexport default createComponent(FeedbackForm, {\n Item: FeedbackItem,\n Success,\n Submit: SubmitButton,\n Cancel,\n Notice,\n});\n"],"mappings":";;;;;;;;;;;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,EAAEC,IAAI,QAAQ,kBAAkB;AAC9C,OAAOC,oBAAoB,MAAM,kBAAkB;AAEnD,OAAOC,eAAe,IAAIC,SAAS,EAAEC,OAAO,EAAEC,IAAI,QAAQ,eAAe;AACzE,OAAOC,MAAM,MAAM,iBAAiB;AACpC,OAAOC,aAAa,MAAM,yBAAyB;AACnD,SAASC,WAAW,QAAQ,iBAAiB;AAC7C,SAASC,GAAG,QAAQ,mBAAmB;AAEvC,SAASC,YAAY,QAAQ,wCAAwC;AACrE,SAASC,YAAY,QAAQ,wCAAwC;AAAC;AAAA,IAAAC,KAAA,+BAAAC,QAAA,CAAAC,MAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;AAAA;AAAA,IAIhEC,YAAY,0BAAAC,UAAA;EAAAC,SAAA,CAAAF,YAAA,EAAAC,UAAA;EAAA,IAAAE,MAAA,GAAAC,YAAA,CAAAJ,YAAA;EAAA,SAAAA,aAAA;IAAA,IAAAK,KAAA;IAAAC,eAAA,OAAAN,YAAA;IAAA,SAAAO,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAAAC,IAAA,OAAAC,KAAA,CAAAJ,IAAA,GAAAK,IAAA,MAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA;MAAAF,IAAA,CAAAE,IAAA,IAAAJ,SAAA,CAAAI,IAAA;IAAA;IAAAP,KAAA,GAAAF,MAAA,CAAAU,IAAA,CAAAC,KAAA,CAAAX,MAAA,SAAAY,MAAA,CAAAL,IAAA;IAAAM,eAAA,CAAAC,sBAAA,CAAAZ,KAAA,qBA2BCnB,oBAAoB,EAAE;IAAA,OAAAmB,KAAA;EAAA;EAAAa,YAAA,CAAAlB,YAAA;I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A;IAAAY,KAAA;EACrB,IAAQ9C,MAAM,GAAwDgC,KAAK,CAAnEhC,MAAM;IAAA+C,YAAA,GAAwDf,KAAK,CAA3D5B,KAAK;IAALA,KAAK,GAAA2C,YAAA,cAAG,sBAAsB,GAAAA,YAAA;IAAAC,UAAA,GAAwBhB,KAAK,CAA3BiB,GAAG;IAAHA,GAAG,GAAAD,UAAA,cAAG,WAAW,GAAAA,UAAA;EACjE,IAAME,OAAO,GAC2BrF,WAAW;EAAnD,OAAAiF,KAAA,GAAOrF,OAAO,CAACuC,MAAM,CAAC,eAAC7C,KAAA,CAAAqD,aAAA,CAAC0C,OAAO,EAAAJ,KAAA,CAAAhC,EAAA,YAAAG,aAAA,KAAAkC,aAAA;IAAA,SAA6B/C,KAAK;IAAA,OAAO6C;EAAG,GAAAJ,KAAA,IAAI;AACjF;AAEA,eAAetF,eAAe,CAACa,YAAY,EAAE;EAC3CgF,IAAI,EAAErF,YAAY;EAClBgE,OAAO,EAAPA,OAAO;EACPsB,MAAM,EAAErF,YAAY;EACpBuE,MAAM,EAANA,MAAM;EACNK,MAAM,EAANA;AACF,CAAC,CAAC"}
1
+ {"version":3,"file":"FeedbackForm.js","names":["React","Field","Form","createFocusDecorator","createComponent","Component","sstyled","Root","Button","SpinContainer","NoticeSmart","Box","FeedbackItem","SubmitButton","style","_sstyled","insert","FeedbackForm","_Component","_inherits","_super","_createSuper","_this","_classCallCheck","_len","arguments","length","args","Array","_key","call","apply","concat","_defineProperty","_assertThisInitialized","_createClass","key","value","getItemProps","validateOnBlur","asProps","render","SFeedbackForm","_this$asProps","Children","styles","forwardRef","loading","background","theme","other","_objectWithoutProperties","_excluded","createElement","_extends","decorators","focusDecorator","api","_ref4","cn","undefined","submitting","_objectSpread","handleSubmit","origin","onSubmit","description","error","words","split","symbols","join","email","test","String","toLowerCase","Success","props","_ref","arguments[0]","_ref5","SSuccess","SEmail","_assignProps","Cancel","_ref2","_ref6","SCancel","_assignProps2","Notice","_ref3","_ref7","_props$theme","_props$use","use","SNotice","_assignProps3","Item","Submit"],"sources":["../../src/FeedbackForm.jsx"],"sourcesContent":["import React from 'react';\nimport { Field, Form } from 'react-final-form';\nimport createFocusDecorator from 'final-form-focus';\n\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport Button from '@semcore/button';\nimport SpinContainer from '@semcore/spin-container';\nimport { NoticeSmart } from '@semcore/notice';\nimport { Box } from '@semcore/flex-box';\n\nimport { FeedbackItem } from './component/feedback-item/FeedbackItem';\nimport { SubmitButton } from './component/submit-button/SubmitButton';\n\nimport style from './style/feedback-form.shadow.css';\n\nclass FeedbackForm extends Component {\n static displayName = 'FeedbackForm';\n static style = style;\n static FinalForm = {\n Field,\n Form,\n };\n\n static defaultProps = {\n onSubmit: () => {},\n };\n\n static validate = {\n description: (error) => (value = '') => {\n const words = value.split(/\\s+/);\n const symbols = words.join(' ');\n if (symbols.length < 10 || words.length < 3) {\n return error;\n }\n },\n email: (error) => (value = '') => {\n if (!/.+@.+\\..+/i.test(String(value).toLowerCase())) {\n return error;\n }\n },\n };\n\n focusDecorator = createFocusDecorator();\n\n getItemProps() {\n const { validateOnBlur } = this.asProps;\n\n return {\n validateOnBlur,\n };\n }\n\n render() {\n const SFeedbackForm = Box;\n const { Children, styles, forwardRef, loading, background, theme, ...other } = this.asProps;\n\n return (\n <Form decorators={[this.focusDecorator]} {...other}>\n {(api) =>\n sstyled(styles)(\n <SpinContainer\n background={background}\n theme={theme}\n size='xl'\n loading={loading === undefined ? api.submitting : loading}\n >\n <SFeedbackForm\n tag='form'\n noValidate\n method='POST'\n ref={forwardRef}\n {...other}\n onSubmit={api.handleSubmit}\n >\n {typeof Children.origin === 'function' ? Children.origin(api) : <Children />}\n </SFeedbackForm>\n </SpinContainer>,\n )\n }\n </Form>\n );\n }\n}\n\nfunction Success(props) {\n const { Children, styles } = props;\n const SSuccess = Root;\n const SEmail = 'div';\n\n return sstyled(styles)(\n <SSuccess render={Box}>\n <SEmail aria-hidden={true} />\n <span>\n <Children />\n </span>\n </SSuccess>,\n );\n}\n// because it is used without a wrapper\nSuccess.style = style;\n\nfunction Cancel(props) {\n const { styles } = props;\n const SCancel = Root;\n return sstyled(styles)(<SCancel render={Button} type='reset' use='secondary' theme='muted' />);\n}\n\nfunction Notice(props) {\n const { styles, theme = 'muted', use = 'secondary' } = props;\n const SNotice = Root;\n return sstyled(styles)(<SNotice render={NoticeSmart} theme={theme} use={use} />);\n}\n\nexport default createComponent(FeedbackForm, {\n Item: FeedbackItem,\n Success,\n Submit: SubmitButton,\n Cancel,\n Notice,\n});\n"],"mappings":";;;;;;;;;;;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,EAAEC,IAAI,QAAQ,kBAAkB;AAC9C,OAAOC,oBAAoB,MAAM,kBAAkB;AAEnD,OAAOC,eAAe,IAAIC,SAAS,EAAEC,OAAO,EAAEC,IAAI,QAAQ,eAAe;AACzE,OAAOC,MAAM,MAAM,iBAAiB;AACpC,OAAOC,aAAa,MAAM,yBAAyB;AACnD,SAASC,WAAW,QAAQ,iBAAiB;AAC7C,SAASC,GAAG,QAAQ,mBAAmB;AAEvC,SAASC,YAAY,QAAQ,wCAAwC;AACrE,SAASC,YAAY,QAAQ,wCAAwC;AAAC;AAAA,IAAAC,KAAA,+BAAAC,QAAA,CAAAC,MAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;AAAA;AAAA,IAIhEC,YAAY,0BAAAC,UAAA;EAAAC,SAAA,CAAAF,YAAA,EAAAC,UAAA;EAAA,IAAAE,MAAA,GAAAC,YAAA,CAAAJ,YAAA;EAAA,SAAAA,aAAA;IAAA,IAAAK,KAAA;IAAAC,eAAA,OAAAN,YAAA;IAAA,SAAAO,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAAAC,IAAA,OAAAC,KAAA,CAAAJ,IAAA,GAAAK,IAAA,MAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA;MAAAF,IAAA,CAAAE,IAAA,IAAAJ,S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,CAACkC,OAAO,EAAAD,KAAA,CAAA3B,EAAA,YAAAG,aAAA,KAAA0B,aAAA;IAAA,QAAsB,OAAO;IAAA,OAAK,WAAW;IAAA,SAAO;EAAO,GAAAH,KAAA,IAAG;AAC/F;AAEA,SAASI,MAAMA,CAACZ,KAAK,EAAE;EAAA,IAAAa,KAAA,GAAAX,YAAA;IAAAY,KAAA;EACrB,IAAQ9C,MAAM,GAAyCgC,KAAK,CAApDhC,MAAM;IAAA+C,YAAA,GAAyCf,KAAK,CAA5C5B,KAAK;IAALA,KAAK,GAAA2C,YAAA,cAAG,OAAO,GAAAA,YAAA;IAAAC,UAAA,GAAwBhB,KAAK,CAA3BiB,GAAG;IAAHA,GAAG,GAAAD,UAAA,cAAG,WAAW,GAAAA,UAAA;EAClD,IAAME,OAAO,GAC2BrF,WAAW;EAAnD,OAAAiF,KAAA,GAAOrF,OAAO,CAACuC,MAAM,CAAC,eAAC7C,KAAA,CAAAqD,aAAA,CAAC0C,OAAO,EAAAJ,KAAA,CAAAhC,EAAA,YAAAG,aAAA,KAAAkC,aAAA;IAAA,SAA6B/C,KAAK;IAAA,OAAO6C;EAAG,GAAAJ,KAAA,IAAI;AACjF;AAEA,eAAetF,eAAe,CAACa,YAAY,EAAE;EAC3CgF,IAAI,EAAErF,YAAY;EAClBgE,OAAO,EAAPA,OAAO;EACPsB,MAAM,EAAErF,YAAY;EACpBuE,MAAM,EAANA,MAAM;EACNK,MAAM,EAANA;AACF,CAAC,CAAC"}
@@ -12,9 +12,9 @@ import React from 'react';
12
12
  import createComponent, { Component, Root, sstyled } from '@semcore/core';
13
13
  import { Box } from '@semcore/flex-box';
14
14
  /*__reshadow-styles__:"../../style/checkbox-button.shadow.css"*/
15
- var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SCheckboxButton_1mrr9_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_1mrr9_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_1mrr9_gg_.__checked_1mrr9_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_1mrr9_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_1mrr9_gg_.__checked_1mrr9_gg_:hover{background-color:rgba(0,143,248,.2)}}" /*__inner_css_end__*/, "1mrr9_gg_") /*__reshadow_css_end__*/, {
16
- "__SCheckboxButton": "___SCheckboxButton_1mrr9_gg_",
17
- "_checked": "__checked_1mrr9_gg_"
15
+ var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SCheckboxButton_pei2o_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_pei2o_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_pei2o_gg_.__checked_pei2o_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_pei2o_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_pei2o_gg_.__checked_pei2o_gg_:hover{background-color:rgba(0,143,248,.2)}}" /*__inner_css_end__*/, "pei2o_gg_") /*__reshadow_css_end__*/, {
16
+ "__SCheckboxButton": "___SCheckboxButton_pei2o_gg_",
17
+ "_checked": "__checked_pei2o_gg_"
18
18
  });
19
19
  import Checkbox from '@semcore/checkbox';
20
20
  var CheckboxButtonRoot = /*#__PURE__*/function (_Component) {
@@ -8,6 +8,7 @@ import { Field } from 'react-final-form';
8
8
  import Tooltip from '@semcore/tooltip';
9
9
  import pick from '@semcore/utils/lib/pick';
10
10
  import uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';
11
+ import { assignProps } from '@semcore/utils/lib/core';
11
12
  var deafultTooltipPropsList = ['title', 'theme', 'strategy', 'modifiers', 'placement', 'interaction', 'timeout', 'visible', 'defaultVisible', 'onVisibleChange', 'offset', 'preventOverflow', 'arrow', 'flip', 'computeStyles', 'eventListeners', 'onFirstUpdate'];
12
13
  export function FeedbackItem(_ref) {
13
14
  var Children = _ref.Children,
@@ -26,11 +27,13 @@ export function FeedbackItem(_ref) {
26
27
  var showError = other.validateOnBlur === false ? meta.submitFailed : true;
27
28
  var invalid = meta.invalid && meta.touched;
28
29
  var errorState = showError && invalid;
29
- var inputProps = _objectSpread(_objectSpread({}, input), {}, {
30
+ var popperId = "".concat(uid, "-error-description");
31
+ var inputProps = assignProps(_objectSpread(_objectSpread({}, other), {}, {
30
32
  state: errorState ? 'invalid' : 'normal',
31
33
  'aria-invalid': errorState ? true : false,
32
- 'aria-errormessage': uid
33
- });
34
+ 'aria-errormessage': popperId,
35
+ 'aria-describedby': errorState && meta.active ? popperId : undefined
36
+ }), input);
34
37
  if (meta !== null && meta !== void 0 && meta.error) lastErrorRef.current = meta.error;
35
38
  return /*#__PURE__*/React.createElement(Tooltip, _extends({
36
39
  visible: errorState && meta.active,
@@ -47,8 +50,8 @@ export function FeedbackItem(_ref) {
47
50
  input: inputProps,
48
51
  meta: meta
49
52
  }, other))), /*#__PURE__*/React.createElement(Tooltip.Popper, {
50
- id: uid,
51
- ignorePortalsStacking: true
53
+ w: '100%',
54
+ id: popperId
52
55
  }, (_meta$error = meta.error) !== null && _meta$error !== void 0 ? _meta$error : lastErrorRef.current));
53
56
  });
54
57
  }
@@ -1 +1 @@
1
- {"version":3,"file":"FeedbackItem.js","names":["React","Field","Tooltip","pick","uniqueIDEnhancement","deafultTooltipPropsList","FeedbackItem","_ref","Children","tag","uid","_ref$tooltipProps","tooltipProps","tooltipPropsList","props","_objectWithoutProperties","_excluded","lastErrorRef","useRef","undefined","createElement","_ref2","_meta$error","input","meta","other","_excluded2","showError","validateOnBlur","submitFailed","invalid","touched","errorState","inputProps","_objectSpread","state","error","current","_extends","visible","active","theme","placement","flip","fallbackPlacements","Trigger","inline","role","origin","Popper","id","ignorePortalsStacking","enhance"],"sources":["../../../../src/component/feedback-item/FeedbackItem.tsx"],"sourcesContent":["import React from 'react';\nimport { Field } from 'react-final-form';\nimport Tooltip from '@semcore/tooltip';\nimport pick from '@semcore/utils/lib/pick';\nimport uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';\n\nconst deafultTooltipPropsList = [\n 'title',\n 'theme',\n 'strategy',\n 'modifiers',\n 'placement',\n 'interaction',\n 'timeout',\n 'visible',\n 'defaultVisible',\n 'onVisibleChange',\n 'offset',\n 'preventOverflow',\n 'arrow',\n 'flip',\n 'computeStyles',\n 'eventListeners',\n 'onFirstUpdate',\n];\n\nexport function FeedbackItem({\n Children,\n tag,\n uid,\n tooltipProps: tooltipPropsList = deafultTooltipPropsList,\n ...props\n}: any) {\n const tooltipProps = pick(props, tooltipPropsList);\n const lastErrorRef = React.useRef(undefined);\n\n return (\n <Field {...props}>\n {({ input, meta, ...other }) => {\n const showError = other.validateOnBlur === false ? meta.submitFailed : true;\n const invalid = meta.invalid && meta.touched;\n const errorState = showError && invalid;\n const inputProps = {\n ...input,\n state: errorState ? 'invalid' : 'normal',\n 'aria-invalid': errorState ? true : false,\n 'aria-errormessage': uid,\n };\n if (meta?.error) lastErrorRef.current = meta.error;\n\n return (\n <Tooltip\n visible={errorState && meta.active}\n theme='warning'\n placement='left'\n flip={{\n fallbackPlacements: ['right', 'bottom'],\n }}\n {...tooltipProps}\n >\n <Tooltip.Trigger inline={false} role={undefined} tag={tag} {...(tag ? inputProps : {})}>\n {typeof Children.origin === 'function' &&\n Children.origin({\n input: inputProps,\n meta,\n ...other,\n })}\n </Tooltip.Trigger>\n <Tooltip.Popper id={uid} ignorePortalsStacking>\n {meta.error ?? lastErrorRef.current}\n </Tooltip.Popper>\n </Tooltip>\n );\n }}\n </Field>\n );\n}\nFeedbackItem.enhance = [uniqueIDEnhancement()];\n"],"mappings":";;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,QAAQ,kBAAkB;AACxC,OAAOC,OAAO,MAAM,kBAAkB;AACtC,OAAOC,IAAI,MAAM,yBAAyB;AAC1C,OAAOC,mBAAmB,MAAM,6BAA6B;AAE7D,IAAMC,uBAAuB,GAAG,CAC9B,OAAO,EACP,OAAO,EACP,UAAU,EACV,WAAW,EACX,WAAW,EACX,aAAa,EACb,SAAS,EACT,SAAS,EACT,gBAAgB,EAChB,iBAAiB,EACjB,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,MAAM,EACN,eAAe,EACf,gBAAgB,EAChB,eAAe,CAChB;AAED,OAAO,SAASC,YAAYA,CAAAC,IAAA,EAMpB;EAAA,IALNC,QAAQ,GAAAD,IAAA,CAARC,QAAQ;IACRC,GAAG,GAAAF,IAAA,CAAHE,GAAG;IACHC,GAAG,GAAAH,IAAA,CAAHG,GAAG;IAAAC,iBAAA,GAAAJ,IAAA,CACHK,YAAY;IAAEC,gBAAgB,GAAAF,iBAAA,cAAGN,uBAAuB,GAAAM,iBAAA;IACrDG,KAAK,GAAAC,wBAAA,CAAAR,IAAA,EAAAS,SAAA;EAER,IAAMJ,YAAY,GAAGT,IAAI,CAACW,KAAK,EAAED,gBAAgB,CAAC;EAClD,IAAMI,YAAY,GAAGjB,KAAK,CAACkB,MAAM,CAACC,SAAS,CAAC;EAE5C,oBACEnB,KAAA,CAAAoB,aAAA,CAACnB,KAAK,EAAKa,KAAK,EACb,UAAAO,KAAA,EAA+B;IAAA,IAAAC,WAAA;IAAA,IAA5BC,KAAK,GAAAF,KAAA,CAALE,KAAK;MAAEC,IAAI,GAAAH,KAAA,CAAJG,IAAI;MAAKC,KAAK,GAAAV,wBAAA,CAAAM,KAAA,EAAAK,UA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A,IAAA7B,WAAA,GAC3CE,IAAI,CAACY,KAAK,cAAAd,WAAA,cAAAA,WAAA,GAAIL,YAAY,CAACoB,OAAO,CACpB,CACT;EAEd,CAAC,CACK;AAEZ;AACA/B,YAAY,CAAC8C,OAAO,GAAG,CAAChD,mBAAmB,EAAE,CAAC"}
1
+ {"version":3,"file":"FeedbackItem.js","names":["React","Field","Tooltip","pick","uniqueIDEnhancement","assignProps","deafultTooltipPropsList","FeedbackItem","_ref","Children","tag","uid","_ref$tooltipProps","tooltipProps","tooltipPropsList","props","_objectWithoutProperties","_excluded","lastErrorRef","useRef","undefined","createElement","_ref2","_meta$error","input","meta","other","_excluded2","showError","validateOnBlur","submitFailed","invalid","touched","errorState","popperId","concat","inputProps","_objectSpread","state","active","error","current","_extends","visible","theme","placement","flip","fallbackPlacements","Trigger","inline","role","origin","Popper","w","id","enhance"],"sources":["../../../../src/component/feedback-item/FeedbackItem.tsx"],"sourcesContent":["import React from 'react';\nimport { Field } from 'react-final-form';\nimport Tooltip from '@semcore/tooltip';\nimport pick from '@semcore/utils/lib/pick';\nimport uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';\nimport { assignProps } from '@semcore/utils/lib/core';\n\nconst deafultTooltipPropsList = [\n 'title',\n 'theme',\n 'strategy',\n 'modifiers',\n 'placement',\n 'interaction',\n 'timeout',\n 'visible',\n 'defaultVisible',\n 'onVisibleChange',\n 'offset',\n 'preventOverflow',\n 'arrow',\n 'flip',\n 'computeStyles',\n 'eventListeners',\n 'onFirstUpdate',\n];\n\nexport function FeedbackItem({\n Children,\n tag,\n uid,\n tooltipProps: tooltipPropsList = deafultTooltipPropsList,\n ...props\n}: any) {\n const tooltipProps = pick(props, tooltipPropsList);\n const lastErrorRef = React.useRef(undefined);\n\n return (\n <Field {...props}>\n {({ input, meta, ...other }) => {\n const showError = other.validateOnBlur === false ? meta.submitFailed : true;\n const invalid = meta.invalid && meta.touched;\n const errorState = showError && invalid;\n const popperId = `${uid}-error-description`;\n const inputProps = assignProps(\n {\n ...other,\n state: errorState ? 'invalid' : 'normal',\n 'aria-invalid': errorState ? true : false,\n 'aria-errormessage': popperId,\n 'aria-describedby': errorState && meta.active ? popperId : undefined,\n },\n input,\n );\n if (meta?.error) lastErrorRef.current = meta.error;\n\n return (\n <Tooltip\n visible={errorState && meta.active}\n theme='warning'\n placement='left'\n flip={{\n fallbackPlacements: ['right', 'bottom'],\n }}\n {...tooltipProps}\n >\n <Tooltip.Trigger inline={false} role={undefined} tag={tag} {...(tag ? inputProps : {})}>\n {typeof Children.origin === 'function' &&\n Children.origin({\n input: inputProps,\n meta,\n ...other,\n })}\n </Tooltip.Trigger>\n <Tooltip.Popper w={'100%'} id={popperId}>\n {meta.error ?? lastErrorRef.current}\n </Tooltip.Popper>\n </Tooltip>\n );\n }}\n </Field>\n );\n}\nFeedbackItem.enhance = [uniqueIDEnhancement()];\n"],"mappings":";;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,QAAQ,kBAAkB;AACxC,OAAOC,OAAO,MAAM,kBAAkB;AACtC,OAAOC,IAAI,MAAM,yBAAyB;AAC1C,OAAOC,mBAAmB,MAAM,6BAA6B;AAC7D,SAASC,WAAW,QAAQ,yBAAyB;AAErD,IAAMC,uBAAuB,GAAG,CAC9B,OAAO,EACP,OAAO,EACP,UAAU,EACV,WAAW,EACX,WAAW,EACX,aAAa,EACb,SAAS,EACT,SAAS,EACT,gBAAgB,EAChB,iBAAiB,EACjB,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,MAAM,EACN,eAAe,EACf,gBAAgB,EAChB,eAAe,CAChB;AAED,OAAO,SAASC,YAAYA,CAAAC,IAAA,EAMpB;EAAA,IALNC,QAAQ,GAAAD,IAAA,CAARC,QAAQ;IACRC,GAAG,GAAAF,IAAA,CAAHE,GAAG;IACHC,GAAG,GAAAH,IAAA,CAAHG,GAAG;IAAAC,iBAAA,GAAAJ,IAAA,CACHK,YAAY;IAAEC,gBAAgB,GAAAF,i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EV,UAAU,IAAIR,IAAI,CAACc,MAAO;MACnCK,KAAK,EAAC,SAAS;MACfC,SAAS,EAAC,MAAM;MAChBC,IAAI,EAAE;QACJC,kBAAkB,EAAE,CAAC,OAAO,EAAE,QAAQ;MACxC;IAAE,GACElC,YAAY,gBAEhBb,KAAA,CAAAqB,aAAA,CAACnB,OAAO,CAAC8C,OAAO,EAAAN,QAAA;MAACO,MAAM,EAAE,KAAM;MAACC,IAAI,EAAE9B,SAAU;MAACV,GAAG,EAAEA;IAAI,GAAMA,GAAG,GAAG0B,UAAU,GAAG,CAAC,CAAC,GAClF,OAAO3B,QAAQ,CAAC0C,MAAM,KAAK,UAAU,IACpC1C,QAAQ,CAAC0C,MAAM,CAAAd,aAAA;MACbb,KAAK,EAAEY,UAAU;MACjBX,IAAI,EAAJA;IAAI,GACDC,KAAK,EACR,CACY,eAClB1B,KAAA,CAAAqB,aAAA,CAACnB,OAAO,CAACkD,MAAM;MAACC,CAAC,EAAE,MAAO;MAACC,EAAE,EAAEpB;IAAS,IAAAX,WAAA,GACrCE,IAAI,CAACe,KAAK,cAAAjB,WAAA,cAAAA,WAAA,GAAIL,YAAY,CAACuB,OAAO,CACpB,CACT;EAEd,CAAC,CACK;AAEZ;AACAlC,YAAY,CAACgD,OAAO,GAAG,CAACnD,mBAAmB,EAAE,CAAC"}
@@ -37,8 +37,8 @@ import Input from '@semcore/input';
37
37
  import { localizedMessages } from '../../translations/__intergalactic-dynamic-locales';
38
38
  import { NoticeBubbleContainer, NoticeBubbleManager } from '@semcore/notice-bubble';
39
39
  /*__reshadow-styles__:"../../style/feedback-rating.shadow.css"*/
40
- var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SFeedbackRating_1btu1_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_1btu1_gg_ li{list-style:none}" /*__inner_css_end__*/, "1btu1_gg_") /*__reshadow_css_end__*/, {
41
- "__SFeedbackRating": "___SFeedbackRating_1btu1_gg_"
40
+ var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SFeedbackRating_1i4d1_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_1i4d1_gg_ li{list-style:none}" /*__inner_css_end__*/, "1i4d1_gg_") /*__reshadow_css_end__*/, {
41
+ "__SFeedbackRating": "___SFeedbackRating_1i4d1_gg_"
42
42
  });
43
43
  var FeedbackRatingRoot = /*#__PURE__*/function (_Component) {
44
44
  _inherits(FeedbackRatingRoot, _Component);
@@ -12,12 +12,12 @@ import React from 'react';
12
12
  import createComponent, { Component, Root, sstyled } from '@semcore/core';
13
13
  import { Flex, Box } from '@semcore/flex-box';
14
14
  /*__reshadow-styles__:"../../style/slider-rating.shadow.css"*/
15
- var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SSliderRating_xvu7s_gg_ .___SStar_xvu7s_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}@media (hover:hover){.___SSliderRating_xvu7s_gg_ .___SStar_xvu7s_gg_:hover{cursor:pointer;transform:scale(1.3)}}.___SSliderRating_xvu7s_gg_.__keyboardFocused_xvu7s_gg_{outline:0;box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}@media (hover:hover){.___SSliderRating_xvu7s_gg_.__readonly_xvu7s_gg_ .___SStar_xvu7s_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_xvu7s_gg_.__filled_xvu7s_gg_:active{animation:wobble .8s ease-in-out}.___SStar_xvu7s_gg_ path{fill:transparent;stroke:var(--intergalactic-slider-rating-normal, #a9abb6);stroke-width:2}.___SStar_xvu7s_gg_.__filled_xvu7s_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}" /*__inner_css_end__*/, "xvu7s_gg_") /*__reshadow_css_end__*/, {
16
- "__SSliderRating": "___SSliderRating_xvu7s_gg_",
17
- "__SStar": "___SStar_xvu7s_gg_",
18
- "_keyboardFocused": "__keyboardFocused_xvu7s_gg_",
19
- "_readonly": "__readonly_xvu7s_gg_",
20
- "_filled": "__filled_xvu7s_gg_"
15
+ var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SSliderRating_17fwp_gg_ .___SStar_17fwp_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}@media (hover:hover){.___SSliderRating_17fwp_gg_ .___SStar_17fwp_gg_:hover{cursor:pointer;transform:scale(1.3)}}.___SSliderRating_17fwp_gg_.__keyboardFocused_17fwp_gg_{outline:0;box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}@media (hover:hover){.___SSliderRating_17fwp_gg_.__readonly_17fwp_gg_ .___SStar_17fwp_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_17fwp_gg_.__filled_17fwp_gg_:active{animation:wobble .8s ease-in-out}.___SStar_17fwp_gg_ path{fill:transparent;stroke:var(--intergalactic-slider-rating-normal, #a9abb6);stroke-width:2}.___SStar_17fwp_gg_.__filled_17fwp_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}" /*__inner_css_end__*/, "17fwp_gg_") /*__reshadow_css_end__*/, {
16
+ "__SSliderRating": "___SSliderRating_17fwp_gg_",
17
+ "__SStar": "___SStar_17fwp_gg_",
18
+ "_keyboardFocused": "__keyboardFocused_17fwp_gg_",
19
+ "_readonly": "__readonly_17fwp_gg_",
20
+ "_filled": "__filled_17fwp_gg_"
21
21
  });
22
22
  import keyboardFocusEnhance from '@semcore/utils/lib/enhances/keyboardFocusEnhance';
23
23
  var MIN = 1;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@semcore/feedback-form",
3
3
  "description": "Semrush Feedback Form Component",
4
- "version": "6.30.0",
4
+ "version": "6.30.1",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/es6/index.js",
7
7
  "typings": "lib/types/index.d.ts",
@@ -10,20 +10,20 @@
10
10
  "license": "MIT",
11
11
  "dependencies": {
12
12
  "@semcore/checkbox": "7.32.0",
13
- "@semcore/notice-bubble": "5.36.0",
14
- "@semcore/typography": "5.37.0",
15
- "@semcore/link": "5.33.0",
16
- "@semcore/modal": "4.39.0",
13
+ "@semcore/notice-bubble": "5.37.0",
14
+ "@semcore/typography": "5.38.0",
15
+ "@semcore/link": "5.33.1",
16
+ "@semcore/modal": "4.40.0",
17
17
  "@semcore/illustration": "2.29.0",
18
- "@semcore/icon": "4.39.1",
18
+ "@semcore/icon": "4.41.0",
19
19
  "@semcore/textarea": "5.28.0",
20
20
  "@semcore/input": "4.30.0",
21
21
  "final-form": "4.20.7",
22
- "@semcore/button": "5.31.0",
22
+ "@semcore/button": "5.31.1",
23
23
  "@semcore/flex-box": "5.29.0",
24
- "@semcore/notice": "5.35.0",
25
- "@semcore/spin-container": "7.29.0",
26
- "@semcore/tooltip": "6.36.0",
24
+ "@semcore/notice": "5.36.0",
25
+ "@semcore/spin-container": "7.30.0",
26
+ "@semcore/tooltip": "6.36.1",
27
27
  "@semcore/utils": "4.30.0",
28
28
  "final-form-focus": "1.1.2",
29
29
  "react-final-form": "6.5.9"