@semcore/feedback-form 17.0.0 → 17.0.1-prerelease.0
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 +6 -0
- package/lib/cjs/FeedbackForm.js +7 -7
- package/lib/cjs/component/checkbox-button/CheckboxButton.js +3 -3
- package/lib/cjs/component/feedback-rating/FeedbackRating.js +3 -3
- package/lib/cjs/component/feedback-rating/FeedbackRating.type.js.map +1 -1
- package/lib/cjs/component/slider-rating/SliderRating.js +6 -6
- package/lib/es6/FeedbackForm.js +7 -7
- package/lib/es6/component/checkbox-button/CheckboxButton.js +3 -3
- package/lib/es6/component/feedback-rating/FeedbackRating.js +3 -3
- package/lib/es6/component/feedback-rating/FeedbackRating.type.js.map +1 -1
- package/lib/es6/component/slider-rating/SliderRating.js +6 -6
- package/lib/esm/FeedbackForm.mjs +9 -8
- package/lib/esm/component/checkbox-button/CheckboxButton.mjs +5 -4
- package/lib/esm/component/feedback-rating/FeedbackRating.mjs +5 -4
- package/lib/esm/component/slider-rating/SliderRating.mjs +8 -7
- package/lib/types/component/feedback-rating/FeedbackRating.type.d.ts +2 -2
- package/package.json +18 -18
package/CHANGELOG.md
CHANGED
package/lib/cjs/FeedbackForm.js
CHANGED
|
@@ -18,15 +18,15 @@ var _reactFinalForm = require("react-final-form");
|
|
|
18
18
|
var _FeedbackItem = require("./component/feedback-item/FeedbackItem");
|
|
19
19
|
var _SubmitButton = require("./component/submit-button/SubmitButton");
|
|
20
20
|
/*!__reshadow-styles__:"./style/feedback-form.shadow.css"*/
|
|
21
|
-
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".
|
|
21
|
+
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".___SFeedbackForm_1mbbt_gg_{max-width:320px}.___SCancel_1mbbt_gg_,.___SSubmit_1mbbt_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1mbbt_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_1mbbt_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box;outline:0}.___SEmail_1mbbt_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px));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__*/"1mbbt_gg_"),
|
|
22
22
|
/*__reshadow_css_end__*/
|
|
23
23
|
{
|
|
24
|
-
"__SFeedbackForm": "
|
|
25
|
-
"__SSubmit": "
|
|
26
|
-
"__SCancel": "
|
|
27
|
-
"__SNotice": "
|
|
28
|
-
"__SSuccess": "
|
|
29
|
-
"__SEmail": "
|
|
24
|
+
"__SFeedbackForm": "___SFeedbackForm_1mbbt_gg_",
|
|
25
|
+
"__SSubmit": "___SSubmit_1mbbt_gg_",
|
|
26
|
+
"__SCancel": "___SCancel_1mbbt_gg_",
|
|
27
|
+
"__SNotice": "___SNotice_1mbbt_gg_",
|
|
28
|
+
"__SSuccess": "___SSuccess_1mbbt_gg_",
|
|
29
|
+
"__SEmail": "___SEmail_1mbbt_gg_"
|
|
30
30
|
});
|
|
31
31
|
class FeedbackForm extends _core.Component {
|
|
32
32
|
constructor(...args) {
|
|
@@ -11,11 +11,11 @@ var _baseComponents = require("@semcore/base-components");
|
|
|
11
11
|
var _checkbox = _interopRequireDefault(require("@semcore/checkbox"));
|
|
12
12
|
var _react = _interopRequireDefault(require("react"));
|
|
13
13
|
/*!__reshadow-styles__:"../../style/checkbox-button.shadow.css"*/
|
|
14
|
-
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".
|
|
14
|
+
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".___SCheckboxButton_1n501_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_1n501_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_1n501_gg_.__checked_1n501_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_1n501_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_1n501_gg_.__checked_1n501_gg_:hover{background-color:rgba(0,143,248,.2)}}", /*__inner_css_end__*/"1n501_gg_"),
|
|
15
15
|
/*__reshadow_css_end__*/
|
|
16
16
|
{
|
|
17
|
-
"__SCheckboxButton": "
|
|
18
|
-
"_checked": "
|
|
17
|
+
"__SCheckboxButton": "___SCheckboxButton_1n501_gg_",
|
|
18
|
+
"_checked": "__checked_1n501_gg_"
|
|
19
19
|
});
|
|
20
20
|
class CheckboxButtonRoot extends _core.Component {
|
|
21
21
|
constructor(...args) {
|
|
@@ -31,11 +31,11 @@ var _FeedbackItem = require("../feedback-item/FeedbackItem");
|
|
|
31
31
|
var _SliderRating = _interopRequireDefault(require("../slider-rating/SliderRating"));
|
|
32
32
|
var _SubmitButton = require("../submit-button/SubmitButton");
|
|
33
33
|
/*!__reshadow-styles__:"../../style/feedback-rating.shadow.css"*/
|
|
34
|
-
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".
|
|
34
|
+
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".___SFeedbackRating_13l9c_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_13l9c_gg_ li{list-style:none}.___SFeedbackRating_13l9c_gg_ .___SHeader_13l9c_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%);font-weight:var(--intergalactic-bold, 700);margin:var(--intergalactic-spacing-4x, 16px)0;text-align:center}", /*__inner_css_end__*/"13l9c_gg_"),
|
|
35
35
|
/*__reshadow_css_end__*/
|
|
36
36
|
{
|
|
37
|
-
"__SFeedbackRating": "
|
|
38
|
-
"__SHeader": "
|
|
37
|
+
"__SFeedbackRating": "___SFeedbackRating_13l9c_gg_",
|
|
38
|
+
"__SHeader": "___SHeader_13l9c_gg_"
|
|
39
39
|
});
|
|
40
40
|
class FeedbackRatingRoot extends _core.Component {
|
|
41
41
|
constructor(...args) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FeedbackRating.type.js","names":[],"sources":["../../../../src/component/feedback-rating/FeedbackRating.type.ts"],"sourcesContent":["import type {
|
|
1
|
+
{"version":3,"file":"FeedbackRating.type.js","names":[],"sources":["../../../../src/component/feedback-rating/FeedbackRating.type.ts"],"sourcesContent":["import type { NSCheckbox } from '@semcore/checkbox';\nimport type { Intergalactic } from '@semcore/core';\nimport type { IllustrationProps } from '@semcore/illustration';\nimport type Notice from '@semcore/notice';\nimport type React from 'react';\nimport type { FieldProps } from 'react-final-form';\n\nimport type { FeedbackFormProps } from '../../index';\nimport type { localizedMessages } from '../../translations/__intergalactic-dynamic-locales';\n\nexport type FormConfigItem = {\n key: string;\n label: React.ReactNode;\n type: 'input' | 'checkbox' | 'textarea' | 'email';\n description?: React.ReactNode;\n validate?: (value: any) => Error | string | undefined;\n};\n\nexport type FeedbackRatingProps = Intergalactic.InternalTypings.EfficientOmit<\n FeedbackFormProps,\n 'initialValues' | 'loading'\n> & {\n /** Status of form */\n status: 'default' | 'success' | 'error' | 'loading';\n\n /** Flag for show/hide notification */\n notificationVisible: boolean;\n /** Notification close callback */\n onNotificationClose: () => void;\n /** Text in notification panel */\n notificationText: string;\n /** Title in notification panel */\n notificationTitle?: string;\n /** Optional link in notification panel */\n learnMoreLink?: string;\n /** Rating value */\n rating: number;\n /** Visible modal form flag */\n visible: boolean;\n /** Visibility changes callback */\n onVisibleChange: (visible: boolean, rating: number) => void;\n\n /** Width for modal with form */\n modalWidth?: number | string;\n\n /** Header of modal with form */\n header: React.ReactNode;\n /** Text for submit button of form */\n submitText?: string;\n /** Config for form fields */\n formConfig: FormConfigItem[];\n\n /** Initial form values including rating */\n initialValues: Record<string, any> & { rating: number };\n /** Email address shown in error messages */\n errorFeedbackEmail: string;\n /** Specifies the locale for i18n support */\n locale?: string;\n /** Illustration element */\n Illustration?: Intergalactic.Component<'svg', IllustrationProps>;\n /** Notice component */\n Notice?: typeof Notice;\n};\n\nexport type FeedbackRatingItemProps = FieldProps<any, any> & {\n /**\n * Allows to override which passed props will be passed to the Tooltip component.\n */\n tooltipProps?: string[];\n};\n\nexport type FeedbackRatingCheckboxProps = Omit<NSCheckbox.Props, 'label'> & {\n focused: boolean;\n label: React.ReactNode;\n};\n\nexport type FeedbackRatingDefaultProps = {\n onSubmit: () => void;\n i18n: typeof localizedMessages;\n locale: 'en';\n Illustration: Intergalactic.Component<'svg', IllustrationProps>;\n Notice: typeof Notice;\n};\n"],"mappings":"","ignoreList":[]}
|
|
@@ -13,14 +13,14 @@ var _uniqueID = _interopRequireDefault(require("@semcore/core/lib/utils/uniqueID
|
|
|
13
13
|
var _react = _interopRequireDefault(require("react"));
|
|
14
14
|
var _intergalacticDynamicLocales = require("../../translations/__intergalactic-dynamic-locales");
|
|
15
15
|
/*!__reshadow-styles__:"../../style/slider-rating.shadow.css"*/
|
|
16
|
-
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".
|
|
16
|
+
const style = (/*__reshadow_css_start__*/_core.sstyled.insert(/*__inner_css_start__*/".___SSliderRating_1lhka_gg_ .___SStar_1lhka_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}.___SSliderRating_1lhka_gg_:focus-visible .___SStar_1lhka_gg_.__hovered_1lhka_gg_{cursor:pointer;transform:scale(1.3)}@media (hover:hover){.___SSliderRating_1lhka_gg_ .___SStar_1lhka_gg_:hover{cursor:pointer;transform:scale(1.3)}.___SSliderRating_1lhka_gg_.__readonly_1lhka_gg_ .___SStar_1lhka_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_1lhka_gg_.__filled_1lhka_gg_:active{animation:wobble .8s ease-in-out}.___SStar_1lhka_gg_ path{fill:var(--intergalactic-slider-rating-normal, #a9abb6)}.___SStar_1lhka_gg_.__filled_1lhka_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}", /*__inner_css_end__*/"1lhka_gg_"),
|
|
17
17
|
/*__reshadow_css_end__*/
|
|
18
18
|
{
|
|
19
|
-
"__SSliderRating": "
|
|
20
|
-
"__SStar": "
|
|
21
|
-
"_hovered": "
|
|
22
|
-
"_readonly": "
|
|
23
|
-
"_filled": "
|
|
19
|
+
"__SSliderRating": "___SSliderRating_1lhka_gg_",
|
|
20
|
+
"__SStar": "___SStar_1lhka_gg_",
|
|
21
|
+
"_hovered": "__hovered_1lhka_gg_",
|
|
22
|
+
"_readonly": "__readonly_1lhka_gg_",
|
|
23
|
+
"_filled": "__filled_1lhka_gg_"
|
|
24
24
|
});
|
|
25
25
|
const MIN = 1;
|
|
26
26
|
const MAX = 5;
|
package/lib/es6/FeedbackForm.js
CHANGED
|
@@ -15,15 +15,15 @@ import { Field, Form } from 'react-final-form';
|
|
|
15
15
|
import { FeedbackItem } from './component/feedback-item/FeedbackItem';
|
|
16
16
|
import { SubmitButton } from './component/submit-button/SubmitButton';
|
|
17
17
|
/*!__reshadow-styles__:"./style/feedback-form.shadow.css"*/
|
|
18
|
-
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".
|
|
18
|
+
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SFeedbackForm_1mbbt_gg_{max-width:320px}.___SCancel_1mbbt_gg_,.___SSubmit_1mbbt_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1mbbt_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_1mbbt_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box;outline:0}.___SEmail_1mbbt_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px));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__*/"1mbbt_gg_"),
|
|
19
19
|
/*__reshadow_css_end__*/
|
|
20
20
|
{
|
|
21
|
-
"__SFeedbackForm": "
|
|
22
|
-
"__SSubmit": "
|
|
23
|
-
"__SCancel": "
|
|
24
|
-
"__SNotice": "
|
|
25
|
-
"__SSuccess": "
|
|
26
|
-
"__SEmail": "
|
|
21
|
+
"__SFeedbackForm": "___SFeedbackForm_1mbbt_gg_",
|
|
22
|
+
"__SSubmit": "___SSubmit_1mbbt_gg_",
|
|
23
|
+
"__SCancel": "___SCancel_1mbbt_gg_",
|
|
24
|
+
"__SNotice": "___SNotice_1mbbt_gg_",
|
|
25
|
+
"__SSuccess": "___SSuccess_1mbbt_gg_",
|
|
26
|
+
"__SEmail": "___SEmail_1mbbt_gg_"
|
|
27
27
|
});
|
|
28
28
|
class FeedbackForm extends Component {
|
|
29
29
|
constructor(...args) {
|
|
@@ -6,11 +6,11 @@ import Checkbox from '@semcore/checkbox';
|
|
|
6
6
|
import { createComponent, Component, Root, sstyled } from '@semcore/core';
|
|
7
7
|
import React from 'react';
|
|
8
8
|
/*!__reshadow-styles__:"../../style/checkbox-button.shadow.css"*/
|
|
9
|
-
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".
|
|
9
|
+
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SCheckboxButton_1n501_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_1n501_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_1n501_gg_.__checked_1n501_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_1n501_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_1n501_gg_.__checked_1n501_gg_:hover{background-color:rgba(0,143,248,.2)}}", /*__inner_css_end__*/"1n501_gg_"),
|
|
10
10
|
/*__reshadow_css_end__*/
|
|
11
11
|
{
|
|
12
|
-
"__SCheckboxButton": "
|
|
13
|
-
"_checked": "
|
|
12
|
+
"__SCheckboxButton": "___SCheckboxButton_1n501_gg_",
|
|
13
|
+
"_checked": "__checked_1n501_gg_"
|
|
14
14
|
});
|
|
15
15
|
class CheckboxButtonRoot extends Component {
|
|
16
16
|
constructor(...args) {
|
|
@@ -23,11 +23,11 @@ import createFocusDecorator from 'final-form-focus';
|
|
|
23
23
|
import React from 'react';
|
|
24
24
|
import { Field, Form } from 'react-final-form';
|
|
25
25
|
/*!__reshadow-styles__:"../../style/feedback-rating.shadow.css"*/
|
|
26
|
-
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".
|
|
26
|
+
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SFeedbackRating_13l9c_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_13l9c_gg_ li{list-style:none}.___SFeedbackRating_13l9c_gg_ .___SHeader_13l9c_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%);font-weight:var(--intergalactic-bold, 700);margin:var(--intergalactic-spacing-4x, 16px)0;text-align:center}", /*__inner_css_end__*/"13l9c_gg_"),
|
|
27
27
|
/*__reshadow_css_end__*/
|
|
28
28
|
{
|
|
29
|
-
"__SFeedbackRating": "
|
|
30
|
-
"__SHeader": "
|
|
29
|
+
"__SFeedbackRating": "___SFeedbackRating_13l9c_gg_",
|
|
30
|
+
"__SHeader": "___SHeader_13l9c_gg_"
|
|
31
31
|
});
|
|
32
32
|
import { localizedMessages } from '../../translations/__intergalactic-dynamic-locales';
|
|
33
33
|
import CheckboxButton from '../checkbox-button/CheckboxButton';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FeedbackRating.type.js","names":[],"sources":["../../../../src/component/feedback-rating/FeedbackRating.type.ts"],"sourcesContent":["import type {
|
|
1
|
+
{"version":3,"file":"FeedbackRating.type.js","names":[],"sources":["../../../../src/component/feedback-rating/FeedbackRating.type.ts"],"sourcesContent":["import type { NSCheckbox } from '@semcore/checkbox';\nimport type { Intergalactic } from '@semcore/core';\nimport type { IllustrationProps } from '@semcore/illustration';\nimport type Notice from '@semcore/notice';\nimport type React from 'react';\nimport type { FieldProps } from 'react-final-form';\n\nimport type { FeedbackFormProps } from '../../index';\nimport type { localizedMessages } from '../../translations/__intergalactic-dynamic-locales';\n\nexport type FormConfigItem = {\n key: string;\n label: React.ReactNode;\n type: 'input' | 'checkbox' | 'textarea' | 'email';\n description?: React.ReactNode;\n validate?: (value: any) => Error | string | undefined;\n};\n\nexport type FeedbackRatingProps = Intergalactic.InternalTypings.EfficientOmit<\n FeedbackFormProps,\n 'initialValues' | 'loading'\n> & {\n /** Status of form */\n status: 'default' | 'success' | 'error' | 'loading';\n\n /** Flag for show/hide notification */\n notificationVisible: boolean;\n /** Notification close callback */\n onNotificationClose: () => void;\n /** Text in notification panel */\n notificationText: string;\n /** Title in notification panel */\n notificationTitle?: string;\n /** Optional link in notification panel */\n learnMoreLink?: string;\n /** Rating value */\n rating: number;\n /** Visible modal form flag */\n visible: boolean;\n /** Visibility changes callback */\n onVisibleChange: (visible: boolean, rating: number) => void;\n\n /** Width for modal with form */\n modalWidth?: number | string;\n\n /** Header of modal with form */\n header: React.ReactNode;\n /** Text for submit button of form */\n submitText?: string;\n /** Config for form fields */\n formConfig: FormConfigItem[];\n\n /** Initial form values including rating */\n initialValues: Record<string, any> & { rating: number };\n /** Email address shown in error messages */\n errorFeedbackEmail: string;\n /** Specifies the locale for i18n support */\n locale?: string;\n /** Illustration element */\n Illustration?: Intergalactic.Component<'svg', IllustrationProps>;\n /** Notice component */\n Notice?: typeof Notice;\n};\n\nexport type FeedbackRatingItemProps = FieldProps<any, any> & {\n /**\n * Allows to override which passed props will be passed to the Tooltip component.\n */\n tooltipProps?: string[];\n};\n\nexport type FeedbackRatingCheckboxProps = Omit<NSCheckbox.Props, 'label'> & {\n focused: boolean;\n label: React.ReactNode;\n};\n\nexport type FeedbackRatingDefaultProps = {\n onSubmit: () => void;\n i18n: typeof localizedMessages;\n locale: 'en';\n Illustration: Intergalactic.Component<'svg', IllustrationProps>;\n Notice: typeof Notice;\n};\n"],"mappings":"","ignoreList":[]}
|
|
@@ -9,14 +9,14 @@ import i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';
|
|
|
9
9
|
import uniqueIDEnhancement from '@semcore/core/lib/utils/uniqueID';
|
|
10
10
|
import React from 'react';
|
|
11
11
|
/*!__reshadow-styles__:"../../style/slider-rating.shadow.css"*/
|
|
12
|
-
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".
|
|
12
|
+
const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SSliderRating_1lhka_gg_ .___SStar_1lhka_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}.___SSliderRating_1lhka_gg_:focus-visible .___SStar_1lhka_gg_.__hovered_1lhka_gg_{cursor:pointer;transform:scale(1.3)}@media (hover:hover){.___SSliderRating_1lhka_gg_ .___SStar_1lhka_gg_:hover{cursor:pointer;transform:scale(1.3)}.___SSliderRating_1lhka_gg_.__readonly_1lhka_gg_ .___SStar_1lhka_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_1lhka_gg_.__filled_1lhka_gg_:active{animation:wobble .8s ease-in-out}.___SStar_1lhka_gg_ path{fill:var(--intergalactic-slider-rating-normal, #a9abb6)}.___SStar_1lhka_gg_.__filled_1lhka_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}", /*__inner_css_end__*/"1lhka_gg_"),
|
|
13
13
|
/*__reshadow_css_end__*/
|
|
14
14
|
{
|
|
15
|
-
"__SSliderRating": "
|
|
16
|
-
"__SStar": "
|
|
17
|
-
"_hovered": "
|
|
18
|
-
"_readonly": "
|
|
19
|
-
"_filled": "
|
|
15
|
+
"__SSliderRating": "___SSliderRating_1lhka_gg_",
|
|
16
|
+
"__SStar": "___SStar_1lhka_gg_",
|
|
17
|
+
"_hovered": "__hovered_1lhka_gg_",
|
|
18
|
+
"_readonly": "__readonly_1lhka_gg_",
|
|
19
|
+
"_filled": "__filled_1lhka_gg_"
|
|
20
20
|
});
|
|
21
21
|
import { localizedMessages } from '../../translations/__intergalactic-dynamic-locales';
|
|
22
22
|
const MIN = 1;
|
package/lib/esm/FeedbackForm.mjs
CHANGED
|
@@ -10,21 +10,22 @@ import React from "react";
|
|
|
10
10
|
import { Form, Field } from "react-final-form";
|
|
11
11
|
import { FeedbackItem } from "./component/feedback-item/FeedbackItem.mjs";
|
|
12
12
|
import { SubmitButton } from "./component/submit-button/SubmitButton.mjs";
|
|
13
|
+
/*!__reshadow-styles__:"./style/feedback-form.shadow.css"*/
|
|
13
14
|
const style = (
|
|
14
15
|
/*__reshadow_css_start__*/
|
|
15
16
|
(sstyled.insert(
|
|
16
17
|
/*__inner_css_start__*/
|
|
17
|
-
`.
|
|
18
|
+
`.___SFeedbackForm_1mbbt_gg_{max-width:320px}.___SCancel_1mbbt_gg_,.___SSubmit_1mbbt_gg_{display:inline-flex;margin-right:var(--intergalactic-spacing-2x, 8px)}.___SNotice_1mbbt_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_1mbbt_gg_{display:flex;align-items:center;flex-direction:column;width:320px;padding:var(--intergalactic-spacing-10x, 40px);box-sizing:border-box;outline:0}.___SEmail_1mbbt_gg_{margin-bottom:calc(var(--intergalactic-spacing-4x, 16px));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")}`,
|
|
18
19
|
/*__inner_css_end__*/
|
|
19
|
-
"
|
|
20
|
+
"1mbbt_gg_"
|
|
20
21
|
), /*__reshadow_css_end__*/
|
|
21
22
|
{
|
|
22
|
-
"__SFeedbackForm": "
|
|
23
|
-
"__SSubmit": "
|
|
24
|
-
"__SCancel": "
|
|
25
|
-
"__SNotice": "
|
|
26
|
-
"__SSuccess": "
|
|
27
|
-
"__SEmail": "
|
|
23
|
+
"__SFeedbackForm": "___SFeedbackForm_1mbbt_gg_",
|
|
24
|
+
"__SSubmit": "___SSubmit_1mbbt_gg_",
|
|
25
|
+
"__SCancel": "___SCancel_1mbbt_gg_",
|
|
26
|
+
"__SNotice": "___SNotice_1mbbt_gg_",
|
|
27
|
+
"__SSuccess": "___SSuccess_1mbbt_gg_",
|
|
28
|
+
"__SEmail": "___SEmail_1mbbt_gg_"
|
|
28
29
|
})
|
|
29
30
|
);
|
|
30
31
|
class FeedbackForm extends Component {
|
|
@@ -3,17 +3,18 @@ import { sstyled, Component, assignProps, createComponent } from "@semcore/core"
|
|
|
3
3
|
import { Box } from "@semcore/base-components";
|
|
4
4
|
import Checkbox from "@semcore/checkbox";
|
|
5
5
|
import React from "react";
|
|
6
|
+
/*!__reshadow-styles__:"../../style/checkbox-button.shadow.css"*/
|
|
6
7
|
const style = (
|
|
7
8
|
/*__reshadow_css_start__*/
|
|
8
9
|
(sstyled.insert(
|
|
9
10
|
/*__inner_css_start__*/
|
|
10
|
-
".
|
|
11
|
+
".___SCheckboxButton_1n501_gg_{margin-top:var(--intergalactic-spacing-2x, 8px);border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:var(--intergalactic-rounded-medium, 6px)}.___SCheckboxButton_1n501_gg_ label{width:100%;padding:var(--intergalactic-spacing-3x, 12px);box-sizing:border-box}.___SCheckboxButton_1n501_gg_.__checked_1n501_gg_{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}@media (hover:hover){.___SCheckboxButton_1n501_gg_:hover{cursor:pointer;border-color:var(--intergalactic-border-info-active, #006dca);background-color:rgba(0,143,248,.1)}.___SCheckboxButton_1n501_gg_.__checked_1n501_gg_:hover{background-color:rgba(0,143,248,.2)}}",
|
|
11
12
|
/*__inner_css_end__*/
|
|
12
|
-
"
|
|
13
|
+
"1n501_gg_"
|
|
13
14
|
), /*__reshadow_css_end__*/
|
|
14
15
|
{
|
|
15
|
-
"__SCheckboxButton": "
|
|
16
|
-
"_checked": "
|
|
16
|
+
"__SCheckboxButton": "___SCheckboxButton_1n501_gg_",
|
|
17
|
+
"_checked": "__checked_1n501_gg_"
|
|
17
18
|
})
|
|
18
19
|
);
|
|
19
20
|
class CheckboxButtonRoot extends Component {
|
|
@@ -23,17 +23,18 @@ import CheckboxButton from "../checkbox-button/CheckboxButton.mjs";
|
|
|
23
23
|
import { FeedbackItem } from "../feedback-item/FeedbackItem.mjs";
|
|
24
24
|
import SliderRating from "../slider-rating/SliderRating.mjs";
|
|
25
25
|
import { SubmitButton } from "../submit-button/SubmitButton.mjs";
|
|
26
|
+
/*!__reshadow-styles__:"../../style/feedback-rating.shadow.css"*/
|
|
26
27
|
const style = (
|
|
27
28
|
/*__reshadow_css_start__*/
|
|
28
29
|
(sstyled.insert(
|
|
29
30
|
/*__inner_css_start__*/
|
|
30
|
-
".
|
|
31
|
+
".___SFeedbackRating_13l9c_gg_ ul{margin:0;padding:0;list-style:none}.___SFeedbackRating_13l9c_gg_ li{list-style:none}.___SFeedbackRating_13l9c_gg_ .___SHeader_13l9c_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%);font-weight:var(--intergalactic-bold, 700);margin:var(--intergalactic-spacing-4x, 16px)0;text-align:center}",
|
|
31
32
|
/*__inner_css_end__*/
|
|
32
|
-
"
|
|
33
|
+
"13l9c_gg_"
|
|
33
34
|
), /*__reshadow_css_end__*/
|
|
34
35
|
{
|
|
35
|
-
"__SFeedbackRating": "
|
|
36
|
-
"__SHeader": "
|
|
36
|
+
"__SFeedbackRating": "___SFeedbackRating_13l9c_gg_",
|
|
37
|
+
"__SHeader": "___SHeader_13l9c_gg_"
|
|
37
38
|
})
|
|
38
39
|
);
|
|
39
40
|
class FeedbackRatingRoot extends Component {
|
|
@@ -5,20 +5,21 @@ import i18nEnhance from "@semcore/core/lib/utils/enhances/i18nEnhance";
|
|
|
5
5
|
import uniqueIDEnhancement from "@semcore/core/lib/utils/uniqueID";
|
|
6
6
|
import React from "react";
|
|
7
7
|
import { localizedMessages } from "../../translations/__intergalactic-dynamic-locales.mjs";
|
|
8
|
+
/*!__reshadow-styles__:"../../style/slider-rating.shadow.css"*/
|
|
8
9
|
const style = (
|
|
9
10
|
/*__reshadow_css_start__*/
|
|
10
11
|
(sstyled.insert(
|
|
11
12
|
/*__inner_css_start__*/
|
|
12
|
-
".
|
|
13
|
+
".___SSliderRating_1lhka_gg_ .___SStar_1lhka_gg_{transition:all calc(var(--intergalactic-duration-control, 200)*1ms) ease-out}.___SSliderRating_1lhka_gg_:focus-visible .___SStar_1lhka_gg_.__hovered_1lhka_gg_{cursor:pointer;transform:scale(1.3)}@media (hover:hover){.___SSliderRating_1lhka_gg_ .___SStar_1lhka_gg_:hover{cursor:pointer;transform:scale(1.3)}.___SSliderRating_1lhka_gg_.__readonly_1lhka_gg_ .___SStar_1lhka_gg_:hover{cursor:default;transform:none;transition:none}}.___SStar_1lhka_gg_.__filled_1lhka_gg_:active{animation:wobble .8s ease-in-out}.___SStar_1lhka_gg_ path{fill:var(--intergalactic-slider-rating-normal, #a9abb6)}.___SStar_1lhka_gg_.__filled_1lhka_gg_ path{stroke-width:0;fill:var(--intergalactic-slider-rating-hover-active, #fdc23c)}",
|
|
13
14
|
/*__inner_css_end__*/
|
|
14
|
-
"
|
|
15
|
+
"1lhka_gg_"
|
|
15
16
|
), /*__reshadow_css_end__*/
|
|
16
17
|
{
|
|
17
|
-
"__SSliderRating": "
|
|
18
|
-
"__SStar": "
|
|
19
|
-
"_hovered": "
|
|
20
|
-
"_readonly": "
|
|
21
|
-
"_filled": "
|
|
18
|
+
"__SSliderRating": "___SSliderRating_1lhka_gg_",
|
|
19
|
+
"__SStar": "___SStar_1lhka_gg_",
|
|
20
|
+
"_hovered": "__hovered_1lhka_gg_",
|
|
21
|
+
"_readonly": "__readonly_1lhka_gg_",
|
|
22
|
+
"_filled": "__filled_1lhka_gg_"
|
|
22
23
|
})
|
|
23
24
|
);
|
|
24
25
|
const MIN = 1;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { NSCheckbox } from '@semcore/checkbox';
|
|
2
2
|
import type { Intergalactic } from '@semcore/core';
|
|
3
3
|
import type { IllustrationProps } from '@semcore/illustration';
|
|
4
4
|
import type Notice from '@semcore/notice';
|
|
@@ -59,7 +59,7 @@ export type FeedbackRatingItemProps = FieldProps<any, any> & {
|
|
|
59
59
|
*/
|
|
60
60
|
tooltipProps?: string[];
|
|
61
61
|
};
|
|
62
|
-
export type FeedbackRatingCheckboxProps = Omit<
|
|
62
|
+
export type FeedbackRatingCheckboxProps = Omit<NSCheckbox.Props, 'label'> & {
|
|
63
63
|
focused: boolean;
|
|
64
64
|
label: React.ReactNode;
|
|
65
65
|
};
|
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": "17.0.0",
|
|
4
|
+
"version": "17.0.1-prerelease.0",
|
|
5
5
|
"main": "lib/cjs/index.js",
|
|
6
6
|
"module": "lib/es6/index.js",
|
|
7
7
|
"typings": "lib/types/index.d.ts",
|
|
@@ -14,25 +14,25 @@
|
|
|
14
14
|
"require": "./lib/cjs/index.js"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@semcore/checkbox": "^17.0.0",
|
|
18
|
-
"@semcore/notice-bubble": "^17.0.0",
|
|
19
|
-
"@semcore/typography": "^17.0.0",
|
|
20
|
-
"@semcore/link": "^17.0.0",
|
|
21
|
-
"@semcore/modal": "^17.0.0",
|
|
22
|
-
"@semcore/illustration": "17.0.
|
|
23
|
-
"@semcore/textarea": "^17.0.0",
|
|
24
|
-
"@semcore/input": "^17.0.0",
|
|
17
|
+
"@semcore/checkbox": "^17.0.2-prerelease.0",
|
|
18
|
+
"@semcore/notice-bubble": "^17.0.1-prerelease.0",
|
|
19
|
+
"@semcore/typography": "^17.0.2-prerelease.0",
|
|
20
|
+
"@semcore/link": "^17.0.1-prerelease.0",
|
|
21
|
+
"@semcore/modal": "^17.0.1-prerelease.0",
|
|
22
|
+
"@semcore/illustration": "^17.0.1",
|
|
23
|
+
"@semcore/textarea": "^17.0.1-prerelease.0",
|
|
24
|
+
"@semcore/input": "^17.0.1-prerelease.0",
|
|
25
25
|
"final-form": "4.20.7",
|
|
26
|
-
"@semcore/button": "^17.0.0",
|
|
27
|
-
"@semcore/notice": "^17.0.0",
|
|
28
|
-
"@semcore/spin-container": "^17.0.0",
|
|
29
|
-
"@semcore/tooltip": "^17.0.0",
|
|
26
|
+
"@semcore/button": "^17.0.1-prerelease.0",
|
|
27
|
+
"@semcore/notice": "^17.0.1-prerelease.0",
|
|
28
|
+
"@semcore/spin-container": "^17.0.1-prerelease.0",
|
|
29
|
+
"@semcore/tooltip": "^17.0.1-prerelease.0",
|
|
30
30
|
"final-form-focus": "1.1.2",
|
|
31
31
|
"react-final-form": "6.5.9"
|
|
32
32
|
},
|
|
33
33
|
"peerDependencies": {
|
|
34
|
-
"@semcore/base-components": "^17.0.
|
|
35
|
-
"@semcore/icon": "^17.0.
|
|
34
|
+
"@semcore/base-components": "^17.0.2",
|
|
35
|
+
"@semcore/icon": "^17.0.1"
|
|
36
36
|
},
|
|
37
37
|
"repository": {
|
|
38
38
|
"type": "git",
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@types/final-form-focus": "1.1.7",
|
|
44
|
+
"@semcore/core": "17.0.1",
|
|
45
|
+
"@semcore/base-components": "17.0.2-prerelease.0",
|
|
44
46
|
"@semcore/testing-utils": "1.0.0",
|
|
45
|
-
"@semcore/
|
|
46
|
-
"@semcore/base-components": "17.0.0",
|
|
47
|
-
"@semcore/icon": "17.0.0"
|
|
47
|
+
"@semcore/icon": "17.0.1-prerelease.0"
|
|
48
48
|
},
|
|
49
49
|
"overrides": {
|
|
50
50
|
"final-form": {
|