intergalactic 15.104.1 → 15.105.0-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 +23 -0
- package/button/index.d.ts +6 -0
- package/button/lib/cjs/Button.js +84 -67
- package/button/lib/cjs/Button.js.map +1 -1
- package/button/lib/cjs/index.d.js.map +1 -1
- package/button/lib/es6/Button.js +85 -67
- package/button/lib/es6/Button.js.map +1 -1
- package/button/lib/es6/index.d.js.map +1 -1
- package/button/lib/types/index.d.ts +6 -0
- package/components.json +5 -5
- package/data-table/Head.d.ts +4 -1
- package/data-table/lib/cjs/Body.js +3 -3
- package/data-table/lib/cjs/DataTable.js +36 -37
- package/data-table/lib/cjs/DataTable.js.map +1 -1
- package/data-table/lib/cjs/Head.js +13 -8
- package/data-table/lib/cjs/Head.js.map +1 -1
- package/data-table/lib/cjs/style/data-table.shadow.css +7 -4
- package/data-table/lib/es6/Body.js +3 -3
- package/data-table/lib/es6/DataTable.js +36 -37
- package/data-table/lib/es6/DataTable.js.map +1 -1
- package/data-table/lib/es6/Head.js +13 -8
- package/data-table/lib/es6/Head.js.map +1 -1
- package/data-table/lib/es6/style/data-table.shadow.css +7 -4
- package/data-table/lib/types/Head.d.ts +4 -1
- package/data-table/package.json +1 -1
- package/feedback-form/lib/cjs/FeedbackForm.js +9 -9
- package/feedback-form/lib/cjs/FeedbackForm.js.map +1 -1
- package/feedback-form/lib/cjs/component/checkbox-button/CheckboxButton.js +3 -3
- package/feedback-form/lib/cjs/component/feedback-rating/FeedbackRating.js +13 -16
- package/feedback-form/lib/cjs/component/feedback-rating/FeedbackRating.js.map +1 -1
- package/feedback-form/lib/cjs/component/slider-rating/SliderRating.js +6 -6
- package/feedback-form/lib/es6/FeedbackForm.js +9 -9
- package/feedback-form/lib/es6/FeedbackForm.js.map +1 -1
- package/feedback-form/lib/es6/component/checkbox-button/CheckboxButton.js +3 -3
- package/feedback-form/lib/es6/component/feedback-rating/FeedbackRating.js +9 -12
- package/feedback-form/lib/es6/component/feedback-rating/FeedbackRating.js.map +1 -1
- package/feedback-form/lib/es6/component/slider-rating/SliderRating.js +6 -6
- package/feedback-form/package.json +1 -1
- package/fullscreen-modal/index.d.ts +2 -2
- package/fullscreen-modal/lib/cjs/index.d.js.map +1 -1
- package/fullscreen-modal/lib/es6/index.d.js.map +1 -1
- package/fullscreen-modal/lib/types/index.d.ts +2 -2
- package/inline-edit/lib/cjs/InlineEdit.js +4 -4
- package/inline-edit/lib/cjs/translations/de.json +1 -1
- package/inline-edit/lib/cjs/translations/es.json +1 -1
- package/inline-edit/lib/cjs/translations/fr.json +1 -1
- package/inline-edit/lib/cjs/translations/it.json +1 -1
- package/inline-edit/lib/cjs/translations/ja.json +1 -1
- package/inline-edit/lib/cjs/translations/ko.json +1 -1
- package/inline-edit/lib/cjs/translations/nl.json +1 -1
- package/inline-edit/lib/cjs/translations/pl.json +1 -1
- package/inline-edit/lib/cjs/translations/pt.json +1 -1
- package/inline-edit/lib/cjs/translations/sv.json +1 -1
- package/inline-edit/lib/cjs/translations/tr.json +1 -1
- package/inline-edit/lib/cjs/translations/vi.json +1 -1
- package/inline-edit/lib/cjs/translations/zh.json +1 -1
- package/inline-edit/lib/es6/InlineEdit.js +4 -4
- package/inline-edit/lib/es6/translations/de.json +1 -1
- package/inline-edit/lib/es6/translations/es.json +1 -1
- package/inline-edit/lib/es6/translations/fr.json +1 -1
- package/inline-edit/lib/es6/translations/it.json +1 -1
- package/inline-edit/lib/es6/translations/ja.json +1 -1
- package/inline-edit/lib/es6/translations/ko.json +1 -1
- package/inline-edit/lib/es6/translations/nl.json +1 -1
- package/inline-edit/lib/es6/translations/pl.json +1 -1
- package/inline-edit/lib/es6/translations/pt.json +1 -1
- package/inline-edit/lib/es6/translations/sv.json +1 -1
- package/inline-edit/lib/es6/translations/tr.json +1 -1
- package/inline-edit/lib/es6/translations/vi.json +1 -1
- package/inline-edit/lib/es6/translations/zh.json +1 -1
- package/inline-edit/package.json +1 -1
- package/modal/index.d.ts +2 -1
- package/modal/lib/cjs/index.d.js.map +1 -1
- package/modal/lib/es6/index.d.js.map +1 -1
- package/modal/lib/types/index.d.ts +2 -1
- package/notice/index.d.ts +2 -2
- package/notice/lib/cjs/Notice.js +19 -17
- package/notice/lib/cjs/Notice.js.map +1 -1
- package/notice/lib/cjs/index.d.js.map +1 -1
- package/notice/lib/cjs/style/notice.shadow.css +3 -1
- package/notice/lib/es6/Notice.js +19 -17
- package/notice/lib/es6/Notice.js.map +1 -1
- package/notice/lib/es6/index.d.js.map +1 -1
- package/notice/lib/es6/style/notice.shadow.css +3 -1
- package/notice/lib/types/index.d.ts +2 -2
- package/notice/package.json +1 -1
- package/package.json +1 -1
- package/side-panel/index.d.ts +2 -1
- package/side-panel/lib/cjs/index.d.js.map +1 -1
- package/side-panel/lib/es6/index.d.js.map +1 -1
- package/side-panel/lib/types/index.d.ts +2 -1
- package/time-picker/lib/cjs/TimePicker.js +12 -12
- package/time-picker/lib/cjs/translations/de.json +6 -5
- package/time-picker/lib/cjs/translations/es.json +6 -5
- package/time-picker/lib/cjs/translations/fr.json +6 -5
- package/time-picker/lib/cjs/translations/it.json +6 -5
- package/time-picker/lib/cjs/translations/ja.json +6 -5
- package/time-picker/lib/cjs/translations/ko.json +6 -5
- package/time-picker/lib/cjs/translations/nl.json +6 -5
- package/time-picker/lib/cjs/translations/pl.json +6 -5
- package/time-picker/lib/cjs/translations/pt.json +6 -5
- package/time-picker/lib/cjs/translations/sv.json +6 -5
- package/time-picker/lib/cjs/translations/tr.json +6 -5
- package/time-picker/lib/cjs/translations/vi.json +6 -5
- package/time-picker/lib/cjs/translations/zh.json +6 -5
- package/time-picker/lib/es6/TimePicker.js +12 -12
- package/time-picker/lib/es6/translations/de.json +6 -5
- package/time-picker/lib/es6/translations/es.json +6 -5
- package/time-picker/lib/es6/translations/fr.json +6 -5
- package/time-picker/lib/es6/translations/it.json +6 -5
- package/time-picker/lib/es6/translations/ja.json +6 -5
- package/time-picker/lib/es6/translations/ko.json +6 -5
- package/time-picker/lib/es6/translations/nl.json +6 -5
- package/time-picker/lib/es6/translations/pl.json +6 -5
- package/time-picker/lib/es6/translations/pt.json +6 -5
- package/time-picker/lib/es6/translations/sv.json +6 -5
- package/time-picker/lib/es6/translations/tr.json +6 -5
- package/time-picker/lib/es6/translations/vi.json +6 -5
- package/time-picker/lib/es6/translations/zh.json +6 -5
- package/time-picker/package.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { PortalProps } from '@semcore/portal';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport { TextProps } from '@semcore/typography';\n\n/** @deprecated */\nexport interface IModalProps extends ModalProps, UnknownProperties {}\nexport type ModalProps = PortalProps &\n BoxProps &\n FadeInOutProps & {\n /** Duration of animation, ms\n * @default 200\n */\n duration?: number;\n /** This property is responsible for the visibility of the modal window */\n visible?: boolean;\n /** Function called when the component is hidden */\n onClose?: (\n trigger: 'onOutsideClick' | 'onCloseClick' | 'onEscape',\n e?: React.MouseEvent | React.KeyboardEvent,\n ) => void;\n /** Displaying the close button(x) in the upper-right corner of the modal dialog\n * @default true\n * */\n closable?: boolean;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when Modal is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n\n locale?: string;\n\n /**\n * Props for render modal without background and paddings. Useful in carousel for example\n */\n ghost?: boolean;\n };\n\n/** @deprecated */\nexport interface IWindowProps extends WindowProps, UnknownProperties {}\nexport type WindowProps = BoxProps & SlideProps & {};\n\n/** @deprecated */\nexport interface IModalContext extends ModalContext, UnknownProperties {}\nexport type ModalContext = {\n getOverlayProps: PropGetterFn;\n getWindowProps: PropGetterFn;\n getCloseProps: PropGetterFn;\n};\n\ndeclare const Modal: Intergalactic.Component<'div', ModalProps, ModalContext> & {\n Window: Intergalactic.Component<'div', WindowProps>;\n Overlay: typeof Box;\n Close: typeof
|
1
|
+
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { PortalProps } from '@semcore/portal';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport { TextProps } from '@semcore/typography';\nimport Button from '@semcore/button';\n\n/** @deprecated */\nexport interface IModalProps extends ModalProps, UnknownProperties {}\nexport type ModalProps = PortalProps &\n BoxProps &\n FadeInOutProps & {\n /** Duration of animation, ms\n * @default 200\n */\n duration?: number;\n /** This property is responsible for the visibility of the modal window */\n visible?: boolean;\n /** Function called when the component is hidden */\n onClose?: (\n trigger: 'onOutsideClick' | 'onCloseClick' | 'onEscape',\n e?: React.MouseEvent | React.KeyboardEvent,\n ) => void;\n /** Displaying the close button(x) in the upper-right corner of the modal dialog\n * @default true\n * */\n closable?: boolean;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when Modal is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n\n locale?: string;\n\n /**\n * Props for render modal without background and paddings. Useful in carousel for example\n */\n ghost?: boolean;\n };\n\n/** @deprecated */\nexport interface IWindowProps extends WindowProps, UnknownProperties {}\nexport type WindowProps = BoxProps & SlideProps & {};\n\n/** @deprecated */\nexport interface IModalContext extends ModalContext, UnknownProperties {}\nexport type ModalContext = {\n getOverlayProps: PropGetterFn;\n getWindowProps: PropGetterFn;\n getCloseProps: PropGetterFn;\n};\n\ndeclare const Modal: Intergalactic.Component<'div', ModalProps, ModalContext> & {\n Window: Intergalactic.Component<'div', WindowProps>;\n Overlay: typeof Box;\n Close: typeof Button;\n Title: Intergalactic.Component<'div', TextProps>;\n};\n\nexport default Modal;\n"],"mappings":""}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { PortalProps } from '@semcore/portal';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport { TextProps } from '@semcore/typography';\n\n/** @deprecated */\nexport interface IModalProps extends ModalProps, UnknownProperties {}\nexport type ModalProps = PortalProps &\n BoxProps &\n FadeInOutProps & {\n /** Duration of animation, ms\n * @default 200\n */\n duration?: number;\n /** This property is responsible for the visibility of the modal window */\n visible?: boolean;\n /** Function called when the component is hidden */\n onClose?: (\n trigger: 'onOutsideClick' | 'onCloseClick' | 'onEscape',\n e?: React.MouseEvent | React.KeyboardEvent,\n ) => void;\n /** Displaying the close button(x) in the upper-right corner of the modal dialog\n * @default true\n * */\n closable?: boolean;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when Modal is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n\n locale?: string;\n\n /**\n * Props for render modal without background and paddings. Useful in carousel for example\n */\n ghost?: boolean;\n };\n\n/** @deprecated */\nexport interface IWindowProps extends WindowProps, UnknownProperties {}\nexport type WindowProps = BoxProps & SlideProps & {};\n\n/** @deprecated */\nexport interface IModalContext extends ModalContext, UnknownProperties {}\nexport type ModalContext = {\n getOverlayProps: PropGetterFn;\n getWindowProps: PropGetterFn;\n getCloseProps: PropGetterFn;\n};\n\ndeclare const Modal: Intergalactic.Component<'div', ModalProps, ModalContext> & {\n Window: Intergalactic.Component<'div', WindowProps>;\n Overlay: typeof Box;\n Close: typeof
|
1
|
+
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { PortalProps } from '@semcore/portal';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport { TextProps } from '@semcore/typography';\nimport Button from '@semcore/button';\n\n/** @deprecated */\nexport interface IModalProps extends ModalProps, UnknownProperties {}\nexport type ModalProps = PortalProps &\n BoxProps &\n FadeInOutProps & {\n /** Duration of animation, ms\n * @default 200\n */\n duration?: number;\n /** This property is responsible for the visibility of the modal window */\n visible?: boolean;\n /** Function called when the component is hidden */\n onClose?: (\n trigger: 'onOutsideClick' | 'onCloseClick' | 'onEscape',\n e?: React.MouseEvent | React.KeyboardEvent,\n ) => void;\n /** Displaying the close button(x) in the upper-right corner of the modal dialog\n * @default true\n * */\n closable?: boolean;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when Modal is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n\n locale?: string;\n\n /**\n * Props for render modal without background and paddings. Useful in carousel for example\n */\n ghost?: boolean;\n };\n\n/** @deprecated */\nexport interface IWindowProps extends WindowProps, UnknownProperties {}\nexport type WindowProps = BoxProps & SlideProps & {};\n\n/** @deprecated */\nexport interface IModalContext extends ModalContext, UnknownProperties {}\nexport type ModalContext = {\n getOverlayProps: PropGetterFn;\n getWindowProps: PropGetterFn;\n getCloseProps: PropGetterFn;\n};\n\ndeclare const Modal: Intergalactic.Component<'div', ModalProps, ModalContext> & {\n Window: Intergalactic.Component<'div', WindowProps>;\n Overlay: typeof Box;\n Close: typeof Button;\n Title: Intergalactic.Component<'div', TextProps>;\n};\n\nexport default Modal;\n"],"mappings":""}
|
@@ -4,6 +4,7 @@ import { PropGetterFn, UnknownProperties, Intergalactic } from 'intergalactic/co
|
|
4
4
|
import { PortalProps } from 'intergalactic/portal';
|
5
5
|
import { Box, BoxProps } from 'intergalactic/flex-box';
|
6
6
|
import { TextProps } from 'intergalactic/typography';
|
7
|
+
import Button from 'intergalactic/button';
|
7
8
|
|
8
9
|
/** @deprecated */
|
9
10
|
export interface IModalProps extends ModalProps, UnknownProperties {}
|
@@ -54,7 +55,7 @@ export type ModalContext = {
|
|
54
55
|
declare const Modal: Intergalactic.Component<'div', ModalProps, ModalContext> & {
|
55
56
|
Window: Intergalactic.Component<'div', WindowProps>;
|
56
57
|
Overlay: typeof Box;
|
57
|
-
Close: typeof
|
58
|
+
Close: typeof Button;
|
58
59
|
Title: Intergalactic.Component<'div', TextProps>;
|
59
60
|
};
|
60
61
|
|
package/notice/index.d.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { PropGetterFn, UnknownProperties, Intergalactic } from 'intergalactic/core';
|
2
2
|
import { Box, BoxProps } from 'intergalactic/flex-box';
|
3
|
-
import
|
3
|
+
import Button from 'intergalactic/button';
|
4
4
|
import { FadeInOutProps } from 'intergalactic/animation';
|
5
5
|
|
6
6
|
export type NoticeTheme = 'danger' | 'warning' | 'success' | 'info' | 'muted';
|
@@ -65,7 +65,7 @@ declare const Notice: Intergalactic.Component<'div', NoticeProps, NoticeContext>
|
|
65
65
|
Label: Intergalactic.Component<'div', NoticeLabelProps>;
|
66
66
|
Actions: typeof Box;
|
67
67
|
Content: typeof Box;
|
68
|
-
CloseIcon:
|
68
|
+
CloseIcon: typeof Button;
|
69
69
|
};
|
70
70
|
|
71
71
|
declare const NoticeSmart: Intergalactic.Component<'div', NoticeSmartProps>;
|
package/notice/lib/cjs/Notice.js
CHANGED
@@ -16,6 +16,7 @@ var _index = require("intergalactic/utils/lib/core/index");
|
|
16
16
|
var _core = _interopRequireWildcard(require("intergalactic/core"));
|
17
17
|
var _react = _interopRequireDefault(require("react"));
|
18
18
|
var _flexBox = require("intergalactic/flex-box");
|
19
|
+
var _button = _interopRequireDefault(require("intergalactic/button"));
|
19
20
|
var _m = _interopRequireDefault(require("intergalactic/icon/Close/m"));
|
20
21
|
var _resolveColorEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/resolveColorEnhance"));
|
21
22
|
var _animation = require("intergalactic/animation");
|
@@ -25,20 +26,20 @@ var _intergalacticDynamicLocales = require("./translations/__intergalactic-dynam
|
|
25
26
|
var _i18nEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/i18nEnhance"));
|
26
27
|
var _useCssVariable = require("intergalactic/utils/lib/useCssVariable");
|
27
28
|
/*__reshadow-styles__:"./style/notice.shadow.css"*/
|
28
|
-
var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".
|
29
|
-
"__SNotice": "
|
30
|
-
"__SContent": "
|
31
|
-
"__SActions": "
|
32
|
-
"__SLabel": "
|
33
|
-
"_theme_info": "
|
34
|
-
"_theme_danger": "
|
35
|
-
"_theme_warning": "
|
36
|
-
"_theme_success": "
|
37
|
-
"_theme_muted": "
|
38
|
-
"_theme_custom": "
|
39
|
-
"--color": "--
|
40
|
-
"__SCloseIcon": "
|
41
|
-
"--backgroundColor": "--
|
29
|
+
var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___SNotice_1a0qk_gg_{display:flex;padding:var(--intergalactic-spacing-4x, 16px);font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%);box-sizing:border-box;border-style:solid;border-width:1px;border-radius:var(--intergalactic-surface-rounded, 6px);color:var(--intergalactic-text-primary, #191b23)}.___SNotice_1a0qk_gg_._theme_info_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-info, #e9f7ff);border-color:var(--intergalactic-border-info, #8ecdff)}.___SNotice_1a0qk_gg_._theme_info_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-neutral, #6c6e79)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_info_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-neutral-hover-active, #565861)}}.___SNotice_1a0qk_gg_._theme_danger_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-critical, #fff0f7);border-color:var(--intergalactic-border-critical, #ffaeb5)}.___SNotice_1a0qk_gg_._theme_danger_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-critical, #ff4953)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_danger_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-critical-hover-active, #CC3A42)}}.___SNotice_1a0qk_gg_._theme_warning_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-warning, #fff3d9);border-color:var(--intergalactic-border-warning, #ffb26e)}.___SNotice_1a0qk_gg_._theme_warning_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-warning, #ff642d)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_warning_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-warning-hover-active, #CC5024)}}.___SNotice_1a0qk_gg_._theme_success_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-success, #dbfee8);border-color:var(--intergalactic-border-success, #59ddaa)}.___SNotice_1a0qk_gg_._theme_success_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-success, #009f81)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_success_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-success-hover-active, #037E68)}}.___SNotice_1a0qk_gg_._theme_muted_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-neutral, #f4f5f9);border-color:var(--intergalactic-border-secondary, #e0e1e9)}.___SLabel_1a0qk_gg_._theme_info_1a0qk_gg_,.___SNotice_1a0qk_gg_._theme_muted_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-neutral, #6c6e79)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_muted_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-neutral-hover-active, #565861)}}.___SContent_1a0qk_gg_{flex:1 1 auto;width:100%}.___SActions_1a0qk_gg_{flex-shrink:0;margin-top:var(--intergalactic-spacing-3x, 12px)}.___SLabel_1a0qk_gg_{min-height:var(--intergalactic-form-control-m, 28px);height:-moz-fit-content;height:fit-content;margin-right:var(--intergalactic-spacing-2x, 8px);display:inline-flex;align-items:center}.___SLabel_1a0qk_gg_._theme_danger_1a0qk_gg_{color:var(--intergalactic-icon-primary-critical, #ff4953)}.___SLabel_1a0qk_gg_._theme_warning_1a0qk_gg_{color:var(--intergalactic-icon-primary-warning, #ff642d)}.___SLabel_1a0qk_gg_._theme_success_1a0qk_gg_{color:var(--intergalactic-icon-primary-success, #009f81)}.___SLabel_1a0qk_gg_._theme_muted_1a0qk_gg_{color:var(--intergalactic-icon-primary-neutral, #6c6e79)}.___SLabel_1a0qk_gg_._theme_custom_1a0qk_gg_{color:var(--color_1a0qk)}.___SCloseIcon_1a0qk_gg_{flex-shrink:0;margin-left:var(--intergalactic-spacing-4x, 16px)}.___SNotice_1a0qk_gg_._theme_custom_1a0qk_gg_{background-color:var(--backgroundColor_1a0qk);border-color:var(--backgroundColor_1a0qk)}" /*__inner_css_end__*/, "1a0qk_gg_") /*__reshadow_css_end__*/, {
|
30
|
+
"__SNotice": "___SNotice_1a0qk_gg_",
|
31
|
+
"__SContent": "___SContent_1a0qk_gg_",
|
32
|
+
"__SActions": "___SActions_1a0qk_gg_",
|
33
|
+
"__SLabel": "___SLabel_1a0qk_gg_",
|
34
|
+
"_theme_info": "_theme_info_1a0qk_gg_",
|
35
|
+
"_theme_danger": "_theme_danger_1a0qk_gg_",
|
36
|
+
"_theme_warning": "_theme_warning_1a0qk_gg_",
|
37
|
+
"_theme_success": "_theme_success_1a0qk_gg_",
|
38
|
+
"_theme_muted": "_theme_muted_1a0qk_gg_",
|
39
|
+
"_theme_custom": "_theme_custom_1a0qk_gg_",
|
40
|
+
"--color": "--color_1a0qk",
|
41
|
+
"__SCloseIcon": "___SCloseIcon_1a0qk_gg_",
|
42
|
+
"--backgroundColor": "--backgroundColor_1a0qk"
|
42
43
|
});
|
43
44
|
function isCustomTheme(theme) {
|
44
45
|
return !['danger', 'warning', 'success', 'info', 'muted'].includes(theme);
|
@@ -152,10 +153,11 @@ function CloseIcon(_ref14) {
|
|
152
153
|
_ref10;
|
153
154
|
var styles = _ref14.styles,
|
154
155
|
getI18nText = _ref14.getI18nText;
|
155
|
-
var SCloseIcon =
|
156
|
+
var SCloseIcon = _button["default"];
|
156
157
|
return _ref10 = (0, _core.sstyled)(styles), /*#__PURE__*/_react["default"].createElement(SCloseIcon, _ref10.cn("SCloseIcon", (0, _objectSpread2["default"])({}, (0, _core.assignProps)({
|
157
|
-
"
|
158
|
-
"
|
158
|
+
"addonLeft": _m["default"],
|
159
|
+
"use": 'tertiary',
|
160
|
+
"theme": 'muted',
|
159
161
|
"aria-label": getI18nText('close')
|
160
162
|
}, _ref5))));
|
161
163
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Notice.js","names":["_core","_interopRequireWildcard","require","_react","_interopRequireDefault","_flexBox","_m","_resolveColorEnhance","_animation","_logger","_noticeGlobal","_intergalacticDynamicLocales","_i18nEnhance","_useCssVariable","style","_index","sstyled","insert","isCustomTheme","theme","includes","RootNotice","_Component","_inherits2","_super","_createSuper2","_classCallCheck2","apply","arguments","_createClass2","key","value","getLabelProps","_this$asProps","asProps","resolveColor","getCloseIconProps","getI18nText","render","_ref","_ref6","SNotice","FadeInOut","_this$asProps2","Children","styles","hidden","use","isAssertive","color","useTheme","ariaLive","undefined","logger","warn","displayName","createElement","cn","_objectSpread2","assignProps","Component","_defineProperty2","i18nEnhance","localizedMessages","cssVariableEnhance","variable","fallback","map","Number","parseInt","prop","resolveColorEnhance","i18n","locale","Label","_ref11","_ref2","arguments[0]","_ref7","SLabel","Box","Actions","_ref12","_ref3","_ref8","SActions","Content","_ref13","_ref4","_ref9","SContent","CloseIcon","_ref14","_ref5","_ref10","SCloseIcon","Close","_default","createComponent","exports"],"sources":["../../src/Notice.jsx"],"sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box } from '@semcore/flex-box';\nimport Close from '@semcore/icon/Close/m';\nimport resolveColorEnhance from '@semcore/utils/lib/enhances/resolveColorEnhance';\nimport { FadeInOut } from '@semcore/animation';\nimport logger from '@semcore/utils/lib/logger';\nimport NoticeGlobal from '@semcore/notice-global';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport { cssVariableEnhance } from '@semcore/utils/lib/useCssVariable';\n\nimport style from './style/notice.shadow.css';\n\nfunction isCustomTheme(theme) {\n return !['danger', 'warning', 'success', 'info', 'muted'].includes(theme);\n}\n\nclass RootNotice extends Component {\n static displayName = 'Notice';\n static style = style;\n static enhance = [\n i18nEnhance(localizedMessages),\n cssVariableEnhance({\n variable: '--intergalactic-duration-popper',\n fallback: '200',\n map: Number.parseInt,\n prop: 'duration',\n }),\n resolveColorEnhance(),\n ];\n static defaultProps = {\n theme: 'info',\n i18n: localizedMessages,\n locale: 'en',\n };\n\n getLabelProps() {\n const { theme, resolveColor } = this.asProps;\n\n return { theme, resolveColor };\n }\n\n getCloseIconProps() {\n const { getI18nText } = this.asProps;\n\n return { getI18nText };\n }\n\n render() {\n const SNotice = Root;\n const { Children, styles, hidden, theme, use, resolveColor, getI18nText } = this.asProps;\n const isAssertive = theme === 'danger' || theme === 'warning';\n const color = resolveColor(theme);\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n\n let ariaLive = isAssertive ? 'assertive' : 'polite';\n if (theme === 'neutral') {\n ariaLive = undefined;\n }\n\n if (use === 'primary') {\n logger.warn(\n true,\n `Deprecated property-value pair \"use=primary\", use component <NoticeGlobal/> instead`,\n RootNotice.displayName,\n );\n return <NoticeGlobal {...this.asProps} />;\n }\n\n return sstyled(styles)(\n <SNotice\n render={FadeInOut}\n visible={!hidden}\n use:theme={useTheme}\n backgroundColor={color}\n role='region'\n aria-live={ariaLive}\n aria-label={getI18nText(theme === 'danger' ? 'criticalNotification' : 'notification')}\n >\n <Children />\n </SNotice>,\n );\n }\n}\n\nfunction Label({ styles, theme, resolveColor }) {\n const SLabel = Root;\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n const color = resolveColor(theme);\n return sstyled(styles)(<SLabel render={Box} use:theme={useTheme} color={color} />);\n}\n\nfunction Actions({ styles }) {\n const SActions = Root;\n return sstyled(styles)(<SActions render={Box} />);\n}\n\nfunction Content({ styles }) {\n const SContent = Root;\n return sstyled(styles)(<SContent render={Box} />);\n}\n\nfunction CloseIcon({ styles, getI18nText }) {\n const SCloseIcon = Root;\n return sstyled(styles)(\n <SCloseIcon
|
1
|
+
{"version":3,"file":"Notice.js","names":["_core","_interopRequireWildcard","require","_react","_interopRequireDefault","_flexBox","_button","_m","_resolveColorEnhance","_animation","_logger","_noticeGlobal","_intergalacticDynamicLocales","_i18nEnhance","_useCssVariable","style","_index","sstyled","insert","isCustomTheme","theme","includes","RootNotice","_Component","_inherits2","_super","_createSuper2","_classCallCheck2","apply","arguments","_createClass2","key","value","getLabelProps","_this$asProps","asProps","resolveColor","getCloseIconProps","getI18nText","render","_ref","_ref6","SNotice","FadeInOut","_this$asProps2","Children","styles","hidden","use","isAssertive","color","useTheme","ariaLive","undefined","logger","warn","displayName","createElement","cn","_objectSpread2","assignProps","Component","_defineProperty2","i18nEnhance","localizedMessages","cssVariableEnhance","variable","fallback","map","Number","parseInt","prop","resolveColorEnhance","i18n","locale","Label","_ref11","_ref2","arguments[0]","_ref7","SLabel","Box","Actions","_ref12","_ref3","_ref8","SActions","Content","_ref13","_ref4","_ref9","SContent","CloseIcon","_ref14","_ref5","_ref10","SCloseIcon","Button","Close","_default","createComponent","exports"],"sources":["../../src/Notice.jsx"],"sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box } from '@semcore/flex-box';\nimport Button from '@semcore/button';\nimport Close from '@semcore/icon/Close/m';\nimport resolveColorEnhance from '@semcore/utils/lib/enhances/resolveColorEnhance';\nimport { FadeInOut } from '@semcore/animation';\nimport logger from '@semcore/utils/lib/logger';\nimport NoticeGlobal from '@semcore/notice-global';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport { cssVariableEnhance } from '@semcore/utils/lib/useCssVariable';\n\nimport style from './style/notice.shadow.css';\n\nfunction isCustomTheme(theme) {\n return !['danger', 'warning', 'success', 'info', 'muted'].includes(theme);\n}\n\nclass RootNotice extends Component {\n static displayName = 'Notice';\n static style = style;\n static enhance = [\n i18nEnhance(localizedMessages),\n cssVariableEnhance({\n variable: '--intergalactic-duration-popper',\n fallback: '200',\n map: Number.parseInt,\n prop: 'duration',\n }),\n resolveColorEnhance(),\n ];\n static defaultProps = {\n theme: 'info',\n i18n: localizedMessages,\n locale: 'en',\n };\n\n getLabelProps() {\n const { theme, resolveColor } = this.asProps;\n\n return { theme, resolveColor };\n }\n\n getCloseIconProps() {\n const { getI18nText } = this.asProps;\n\n return { getI18nText };\n }\n\n render() {\n const SNotice = Root;\n const { Children, styles, hidden, theme, use, resolveColor, getI18nText } = this.asProps;\n const isAssertive = theme === 'danger' || theme === 'warning';\n const color = resolveColor(theme);\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n\n let ariaLive = isAssertive ? 'assertive' : 'polite';\n if (theme === 'neutral') {\n ariaLive = undefined;\n }\n\n if (use === 'primary') {\n logger.warn(\n true,\n `Deprecated property-value pair \"use=primary\", use component <NoticeGlobal/> instead`,\n RootNotice.displayName,\n );\n return <NoticeGlobal {...this.asProps} />;\n }\n\n return sstyled(styles)(\n <SNotice\n render={FadeInOut}\n visible={!hidden}\n use:theme={useTheme}\n backgroundColor={color}\n role='region'\n aria-live={ariaLive}\n aria-label={getI18nText(theme === 'danger' ? 'criticalNotification' : 'notification')}\n >\n <Children />\n </SNotice>,\n );\n }\n}\n\nfunction Label({ styles, theme, resolveColor }) {\n const SLabel = Root;\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n const color = resolveColor(theme);\n return sstyled(styles)(<SLabel render={Box} use:theme={useTheme} color={color} />);\n}\n\nfunction Actions({ styles }) {\n const SActions = Root;\n return sstyled(styles)(<SActions render={Box} />);\n}\n\nfunction Content({ styles }) {\n const SContent = Root;\n return sstyled(styles)(<SContent render={Box} />);\n}\n\nfunction CloseIcon({ styles, getI18nText }) {\n const SCloseIcon = Root;\n return sstyled(styles)(\n <SCloseIcon\n render={Button}\n addonLeft={Close}\n use='tertiary'\n theme='muted'\n aria-label={getI18nText('close')}\n />,\n );\n}\n\nexport default createComponent(RootNotice, {\n Label,\n Actions,\n Content,\n CloseIcon,\n});\n"],"mappings":";;;;;;;;;;;;;;;AACA,IAAAA,KAAA,GAAAC,uBAAA,CAAAC,OAAA;AADA,IAAAC,MAAA,GAAAC,sBAAA,CAAAF,OAAA;AAEA,IAAAG,QAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAF,sBAAA,CAAAF,OAAA;AACA,IAAAK,EAAA,GAAAH,sBAAA,CAAAF,OAAA;AACA,IAAAM,oBAAA,GAAAJ,sBAAA,CAAAF,OAAA;AACA,IAAAO,UAAA,GAAAP,OAAA;AACA,IAAAQ,OAAA,GAAAN,sBAAA,CAAAF,OAAA;AACA,IAAAS,aAAA,GAAAP,sBAAA,CAAAF,OAAA;AACA,IAAAU,4BAAA,GAAAV,OAAA;AACA,IAAAW,YAAA,GAAAT,sBAAA,CAAAF,OAAA;AACA,IAAAY,eAAA,GAAAZ,OAAA;AAAuE;AAAA,IAAAa,KAAA,+BAAAC,MAAA,CAAAC,OAAA,CAAAC,MAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;AAAA;AAIvE,SAASC,aAAaA,CAACC,KAAK,EAAE;EAC5B,OAAO,CAAC,CAAC,QAAQ,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,OAAO,CAAC,CAACC,QAAQ,CAACD,KAAK,CAAC;AAC3E;AAAC,IAEKE,UAAU,0BAAAC,UAAA;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A,CAAAC,MAAA,EAAa;EAAA,IAAAC,KAAA,GAAAX,YAAA;IAAAY,KAAA;EAAA,IAAV5C,MAAM,GAAA0C,MAAA,CAAN1C,MAAM;EACvB,IAAM6C,QAAQ,GAC2BV,YAAG;EAA5C,OAAAS,KAAA,GAAO,IAAAzE,aAAO,EAAC6B,MAAM,CAAC,eAAC3C,MAAA,YAAAsD,aAAA,CAACkC,QAAQ,EAAAD,KAAA,CAAAhC,EAAA,iBAAAC,cAAA,qBAAA3D,KAAA,CAAA4D,WAAA,MAAA6B,KAAA,IAAgB;AAClD;AAEA,SAASG,SAASA,CAAAC,MAAA,EAA0B;EAAA,IAAAC,KAAA,GAAAhB,YAAA;IAAAiB,MAAA;EAAA,IAAvBjD,MAAM,GAAA+C,MAAA,CAAN/C,MAAM;IAAER,WAAW,GAAAuD,MAAA,CAAXvD,WAAW;EACtC,IAAM0D,UAAU,GAGJC,kBAAM;EAFlB,OAAAF,MAAA,GAAO,IAAA9E,aAAO,EAAC6B,MAAM,CAAC,eACpB3C,MAAA,YAAAsD,aAAA,CAACuC,UAAU,EAAAD,MAAA,CAAArC,EAAA,mBAAAC,cAAA,qBAAA3D,KAAA,CAAA4D,WAAA;IAAA,aAEEsC,aAAK;IAAA,OACZ,UAAU;IAAA,SACR,OAAO;IAAA,cACD5D,WAAW,CAAC,OAAO;EAAC,GAAAwD,KAAA,IAChC;AAEN;AAAC,IAAAK,QAAA,GAEc,IAAAC,gBAAe,EAAC9E,UAAU,EAAE;EACzCqD,KAAK,EAALA,KAAK;EACLO,OAAO,EAAPA,OAAO;EACPK,OAAO,EAAPA,OAAO;EACPK,SAAS,EAATA;AACF,CAAC,CAAC;AAAAS,OAAA,cAAAF,QAAA"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport
|
1
|
+
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport Button from '@semcore/button';\nimport { FadeInOutProps } from '@semcore/animation';\n\nexport type NoticeTheme = 'danger' | 'warning' | 'success' | 'info' | 'muted';\nexport type NoticeUse = 'primary' | 'secondary';\n\n/** @deprecated */\nexport interface INoticeProps extends NoticeProps, UnknownProperties {}\nexport type NoticeProps = BoxProps &\n FadeInOutProps & {\n /** Property for managing visibility of Notice */\n hidden?: boolean;\n /** Notice type\n * @deprecated since version ^4.1.0\n */\n use?: NoticeUse;\n /**\n * Notice theme\n * @default info\n */\n theme?: NoticeTheme;\n /** Duration of animation, ms\n * @default 250\n */\n duration?: number;\n locale?: string;\n };\n\n/** @deprecated */\nexport interface INoticeLabelProps extends NoticeLabelProps, UnknownProperties {}\nexport type NoticeLabelProps = BoxProps & {\n theme?: NoticeTheme;\n};\n\n/** @deprecated */\nexport interface INoticeContext extends NoticeContext, UnknownProperties {}\nexport type NoticeContext = {\n getLabelProps: PropGetterFn;\n};\n\n/** @deprecated */\nexport interface INoticeSmartProps extends NoticeSmartProps, UnknownProperties {}\nexport type NoticeSmartProps = NoticeProps & {\n /**\n * A custom element for additional information\n */\n label?: React.ReactNode;\n /**\n * Custom action element\n */\n actions?: React.ReactNode;\n /**\n * Adds a Close icon\n */\n closable?: boolean;\n /**\n * Callback on a click on the close button\n */\n onClose?: (event: React.SyntheticEvent) => void;\n};\n\ndeclare const Notice: Intergalactic.Component<'div', NoticeProps, NoticeContext> & {\n Label: Intergalactic.Component<'div', NoticeLabelProps>;\n Actions: typeof Box;\n Content: typeof Box;\n CloseIcon: typeof Button;\n};\n\ndeclare const NoticeSmart: Intergalactic.Component<'div', NoticeSmartProps>;\n\nexport { NoticeSmart };\nexport default Notice;\n"],"mappings":""}
|
@@ -86,9 +86,11 @@ SActions {
|
|
86
86
|
}
|
87
87
|
|
88
88
|
SLabel {
|
89
|
-
|
89
|
+
min-height: var(--intergalactic-form-control-m, 28px);
|
90
|
+
height: fit-content;
|
90
91
|
margin-right: var(--intergalactic-spacing-2x, 8px);
|
91
92
|
display: inline-flex;
|
93
|
+
align-items: center;
|
92
94
|
}
|
93
95
|
|
94
96
|
SLabel[theme='info'] {
|
package/notice/lib/es6/Notice.js
CHANGED
@@ -13,6 +13,7 @@ import { assignProps as _assignProps } from 'intergalactic/core';
|
|
13
13
|
import React from 'react';
|
14
14
|
import createComponent, { Component, sstyled, Root } from 'intergalactic/core';
|
15
15
|
import { Box } from 'intergalactic/flex-box';
|
16
|
+
import Button from 'intergalactic/button';
|
16
17
|
import Close from 'intergalactic/icon/Close/m';
|
17
18
|
import resolveColorEnhance from 'intergalactic/utils/lib/enhances/resolveColorEnhance';
|
18
19
|
import { FadeInOut } from 'intergalactic/animation';
|
@@ -22,20 +23,20 @@ import { localizedMessages } from './translations/__intergalactic-dynamic-locale
|
|
22
23
|
import i18nEnhance from 'intergalactic/utils/lib/enhances/i18nEnhance';
|
23
24
|
import { cssVariableEnhance } from 'intergalactic/utils/lib/useCssVariable';
|
24
25
|
/*__reshadow-styles__:"./style/notice.shadow.css"*/
|
25
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
26
|
-
"__SNotice": "
|
27
|
-
"__SContent": "
|
28
|
-
"__SActions": "
|
29
|
-
"__SLabel": "
|
30
|
-
"_theme_info": "
|
31
|
-
"_theme_danger": "
|
32
|
-
"_theme_warning": "
|
33
|
-
"_theme_success": "
|
34
|
-
"_theme_muted": "
|
35
|
-
"_theme_custom": "
|
36
|
-
"--color": "--
|
37
|
-
"__SCloseIcon": "
|
38
|
-
"--backgroundColor": "--
|
26
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SNotice_1a0qk_gg_{display:flex;padding:var(--intergalactic-spacing-4x, 16px);font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%);box-sizing:border-box;border-style:solid;border-width:1px;border-radius:var(--intergalactic-surface-rounded, 6px);color:var(--intergalactic-text-primary, #191b23)}.___SNotice_1a0qk_gg_._theme_info_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-info, #e9f7ff);border-color:var(--intergalactic-border-info, #8ecdff)}.___SNotice_1a0qk_gg_._theme_info_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-neutral, #6c6e79)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_info_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-neutral-hover-active, #565861)}}.___SNotice_1a0qk_gg_._theme_danger_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-critical, #fff0f7);border-color:var(--intergalactic-border-critical, #ffaeb5)}.___SNotice_1a0qk_gg_._theme_danger_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-critical, #ff4953)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_danger_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-critical-hover-active, #CC3A42)}}.___SNotice_1a0qk_gg_._theme_warning_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-warning, #fff3d9);border-color:var(--intergalactic-border-warning, #ffb26e)}.___SNotice_1a0qk_gg_._theme_warning_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-warning, #ff642d)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_warning_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-warning-hover-active, #CC5024)}}.___SNotice_1a0qk_gg_._theme_success_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-success, #dbfee8);border-color:var(--intergalactic-border-success, #59ddaa)}.___SNotice_1a0qk_gg_._theme_success_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-success, #009f81)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_success_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-success-hover-active, #037E68)}}.___SNotice_1a0qk_gg_._theme_muted_1a0qk_gg_{background-color:var(--intergalactic-bg-secondary-neutral, #f4f5f9);border-color:var(--intergalactic-border-secondary, #e0e1e9)}.___SLabel_1a0qk_gg_._theme_info_1a0qk_gg_,.___SNotice_1a0qk_gg_._theme_muted_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_{color:var(--intergalactic-icon-primary-neutral, #6c6e79)}@media (hover:hover){.___SNotice_1a0qk_gg_._theme_muted_1a0qk_gg_ .___SCloseIcon_1a0qk_gg_:hover{color:var(--intergalactic-icon-primary-neutral-hover-active, #565861)}}.___SContent_1a0qk_gg_{flex:1 1 auto;width:100%}.___SActions_1a0qk_gg_{flex-shrink:0;margin-top:var(--intergalactic-spacing-3x, 12px)}.___SLabel_1a0qk_gg_{min-height:var(--intergalactic-form-control-m, 28px);height:-moz-fit-content;height:fit-content;margin-right:var(--intergalactic-spacing-2x, 8px);display:inline-flex;align-items:center}.___SLabel_1a0qk_gg_._theme_danger_1a0qk_gg_{color:var(--intergalactic-icon-primary-critical, #ff4953)}.___SLabel_1a0qk_gg_._theme_warning_1a0qk_gg_{color:var(--intergalactic-icon-primary-warning, #ff642d)}.___SLabel_1a0qk_gg_._theme_success_1a0qk_gg_{color:var(--intergalactic-icon-primary-success, #009f81)}.___SLabel_1a0qk_gg_._theme_muted_1a0qk_gg_{color:var(--intergalactic-icon-primary-neutral, #6c6e79)}.___SLabel_1a0qk_gg_._theme_custom_1a0qk_gg_{color:var(--color_1a0qk)}.___SCloseIcon_1a0qk_gg_{flex-shrink:0;margin-left:var(--intergalactic-spacing-4x, 16px)}.___SNotice_1a0qk_gg_._theme_custom_1a0qk_gg_{background-color:var(--backgroundColor_1a0qk);border-color:var(--backgroundColor_1a0qk)}" /*__inner_css_end__*/, "1a0qk_gg_") /*__reshadow_css_end__*/, {
|
27
|
+
"__SNotice": "___SNotice_1a0qk_gg_",
|
28
|
+
"__SContent": "___SContent_1a0qk_gg_",
|
29
|
+
"__SActions": "___SActions_1a0qk_gg_",
|
30
|
+
"__SLabel": "___SLabel_1a0qk_gg_",
|
31
|
+
"_theme_info": "_theme_info_1a0qk_gg_",
|
32
|
+
"_theme_danger": "_theme_danger_1a0qk_gg_",
|
33
|
+
"_theme_warning": "_theme_warning_1a0qk_gg_",
|
34
|
+
"_theme_success": "_theme_success_1a0qk_gg_",
|
35
|
+
"_theme_muted": "_theme_muted_1a0qk_gg_",
|
36
|
+
"_theme_custom": "_theme_custom_1a0qk_gg_",
|
37
|
+
"--color": "--color_1a0qk",
|
38
|
+
"__SCloseIcon": "___SCloseIcon_1a0qk_gg_",
|
39
|
+
"--backgroundColor": "--backgroundColor_1a0qk"
|
39
40
|
});
|
40
41
|
function isCustomTheme(theme) {
|
41
42
|
return !['danger', 'warning', 'success', 'info', 'muted'].includes(theme);
|
@@ -149,10 +150,11 @@ function CloseIcon(_ref14) {
|
|
149
150
|
_ref10;
|
150
151
|
var styles = _ref14.styles,
|
151
152
|
getI18nText = _ref14.getI18nText;
|
152
|
-
var SCloseIcon =
|
153
|
+
var SCloseIcon = Button;
|
153
154
|
return _ref10 = sstyled(styles), /*#__PURE__*/React.createElement(SCloseIcon, _ref10.cn("SCloseIcon", _objectSpread({}, _assignProps5({
|
154
|
-
"
|
155
|
-
"
|
155
|
+
"addonLeft": Close,
|
156
|
+
"use": 'tertiary',
|
157
|
+
"theme": 'muted',
|
156
158
|
"aria-label": getI18nText('close')
|
157
159
|
}, _ref5))));
|
158
160
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Notice.js","names":["React","createComponent","Component","sstyled","Root","Box","Close","resolveColorEnhance","FadeInOut","logger","NoticeGlobal","localizedMessages","i18nEnhance","cssVariableEnhance","style","_sstyled","insert","isCustomTheme","theme","includes","RootNotice","_Component","_inherits","_super","_createSuper","_classCallCheck","apply","arguments","_createClass","key","value","getLabelProps","_this$asProps","asProps","resolveColor","getCloseIconProps","getI18nText","render","_ref","_ref6","SNotice","_this$asProps2","Children","styles","hidden","use","isAssertive","color","useTheme","ariaLive","undefined","warn","displayName","createElement","cn","_objectSpread","_assignProps","_defineProperty","variable","fallback","map","Number","parseInt","prop","i18n","locale","Label","_ref11","_ref2","arguments[0]","_ref7","SLabel","_assignProps2","Actions","_ref12","_ref3","_ref8","SActions","_assignProps3","Content","_ref13","_ref4","_ref9","SContent","_assignProps4","CloseIcon","_ref14","_ref5","_ref10","SCloseIcon","_assignProps5"],"sources":["../../src/Notice.jsx"],"sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box } from '@semcore/flex-box';\nimport Close from '@semcore/icon/Close/m';\nimport resolveColorEnhance from '@semcore/utils/lib/enhances/resolveColorEnhance';\nimport { FadeInOut } from '@semcore/animation';\nimport logger from '@semcore/utils/lib/logger';\nimport NoticeGlobal from '@semcore/notice-global';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport { cssVariableEnhance } from '@semcore/utils/lib/useCssVariable';\n\nimport style from './style/notice.shadow.css';\n\nfunction isCustomTheme(theme) {\n return !['danger', 'warning', 'success', 'info', 'muted'].includes(theme);\n}\n\nclass RootNotice extends Component {\n static displayName = 'Notice';\n static style = style;\n static enhance = [\n i18nEnhance(localizedMessages),\n cssVariableEnhance({\n variable: '--intergalactic-duration-popper',\n fallback: '200',\n map: Number.parseInt,\n prop: 'duration',\n }),\n resolveColorEnhance(),\n ];\n static defaultProps = {\n theme: 'info',\n i18n: localizedMessages,\n locale: 'en',\n };\n\n getLabelProps() {\n const { theme, resolveColor } = this.asProps;\n\n return { theme, resolveColor };\n }\n\n getCloseIconProps() {\n const { getI18nText } = this.asProps;\n\n return { getI18nText };\n }\n\n render() {\n const SNotice = Root;\n const { Children, styles, hidden, theme, use, resolveColor, getI18nText } = this.asProps;\n const isAssertive = theme === 'danger' || theme === 'warning';\n const color = resolveColor(theme);\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n\n let ariaLive = isAssertive ? 'assertive' : 'polite';\n if (theme === 'neutral') {\n ariaLive = undefined;\n }\n\n if (use === 'primary') {\n logger.warn(\n true,\n `Deprecated property-value pair \"use=primary\", use component <NoticeGlobal/> instead`,\n RootNotice.displayName,\n );\n return <NoticeGlobal {...this.asProps} />;\n }\n\n return sstyled(styles)(\n <SNotice\n render={FadeInOut}\n visible={!hidden}\n use:theme={useTheme}\n backgroundColor={color}\n role='region'\n aria-live={ariaLive}\n aria-label={getI18nText(theme === 'danger' ? 'criticalNotification' : 'notification')}\n >\n <Children />\n </SNotice>,\n );\n }\n}\n\nfunction Label({ styles, theme, resolveColor }) {\n const SLabel = Root;\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n const color = resolveColor(theme);\n return sstyled(styles)(<SLabel render={Box} use:theme={useTheme} color={color} />);\n}\n\nfunction Actions({ styles }) {\n const SActions = Root;\n return sstyled(styles)(<SActions render={Box} />);\n}\n\nfunction Content({ styles }) {\n const SContent = Root;\n return sstyled(styles)(<SContent render={Box} />);\n}\n\nfunction CloseIcon({ styles, getI18nText }) {\n const SCloseIcon = Root;\n return sstyled(styles)(\n <SCloseIcon
|
1
|
+
{"version":3,"file":"Notice.js","names":["React","createComponent","Component","sstyled","Root","Box","Button","Close","resolveColorEnhance","FadeInOut","logger","NoticeGlobal","localizedMessages","i18nEnhance","cssVariableEnhance","style","_sstyled","insert","isCustomTheme","theme","includes","RootNotice","_Component","_inherits","_super","_createSuper","_classCallCheck","apply","arguments","_createClass","key","value","getLabelProps","_this$asProps","asProps","resolveColor","getCloseIconProps","getI18nText","render","_ref","_ref6","SNotice","_this$asProps2","Children","styles","hidden","use","isAssertive","color","useTheme","ariaLive","undefined","warn","displayName","createElement","cn","_objectSpread","_assignProps","_defineProperty","variable","fallback","map","Number","parseInt","prop","i18n","locale","Label","_ref11","_ref2","arguments[0]","_ref7","SLabel","_assignProps2","Actions","_ref12","_ref3","_ref8","SActions","_assignProps3","Content","_ref13","_ref4","_ref9","SContent","_assignProps4","CloseIcon","_ref14","_ref5","_ref10","SCloseIcon","_assignProps5"],"sources":["../../src/Notice.jsx"],"sourcesContent":["import React from 'react';\nimport createComponent, { Component, sstyled, Root } from '@semcore/core';\nimport { Box } from '@semcore/flex-box';\nimport Button from '@semcore/button';\nimport Close from '@semcore/icon/Close/m';\nimport resolveColorEnhance from '@semcore/utils/lib/enhances/resolveColorEnhance';\nimport { FadeInOut } from '@semcore/animation';\nimport logger from '@semcore/utils/lib/logger';\nimport NoticeGlobal from '@semcore/notice-global';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\nimport i18nEnhance from '@semcore/utils/lib/enhances/i18nEnhance';\nimport { cssVariableEnhance } from '@semcore/utils/lib/useCssVariable';\n\nimport style from './style/notice.shadow.css';\n\nfunction isCustomTheme(theme) {\n return !['danger', 'warning', 'success', 'info', 'muted'].includes(theme);\n}\n\nclass RootNotice extends Component {\n static displayName = 'Notice';\n static style = style;\n static enhance = [\n i18nEnhance(localizedMessages),\n cssVariableEnhance({\n variable: '--intergalactic-duration-popper',\n fallback: '200',\n map: Number.parseInt,\n prop: 'duration',\n }),\n resolveColorEnhance(),\n ];\n static defaultProps = {\n theme: 'info',\n i18n: localizedMessages,\n locale: 'en',\n };\n\n getLabelProps() {\n const { theme, resolveColor } = this.asProps;\n\n return { theme, resolveColor };\n }\n\n getCloseIconProps() {\n const { getI18nText } = this.asProps;\n\n return { getI18nText };\n }\n\n render() {\n const SNotice = Root;\n const { Children, styles, hidden, theme, use, resolveColor, getI18nText } = this.asProps;\n const isAssertive = theme === 'danger' || theme === 'warning';\n const color = resolveColor(theme);\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n\n let ariaLive = isAssertive ? 'assertive' : 'polite';\n if (theme === 'neutral') {\n ariaLive = undefined;\n }\n\n if (use === 'primary') {\n logger.warn(\n true,\n `Deprecated property-value pair \"use=primary\", use component <NoticeGlobal/> instead`,\n RootNotice.displayName,\n );\n return <NoticeGlobal {...this.asProps} />;\n }\n\n return sstyled(styles)(\n <SNotice\n render={FadeInOut}\n visible={!hidden}\n use:theme={useTheme}\n backgroundColor={color}\n role='region'\n aria-live={ariaLive}\n aria-label={getI18nText(theme === 'danger' ? 'criticalNotification' : 'notification')}\n >\n <Children />\n </SNotice>,\n );\n }\n}\n\nfunction Label({ styles, theme, resolveColor }) {\n const SLabel = Root;\n const useTheme = isCustomTheme(theme) ? 'custom' : theme;\n const color = resolveColor(theme);\n return sstyled(styles)(<SLabel render={Box} use:theme={useTheme} color={color} />);\n}\n\nfunction Actions({ styles }) {\n const SActions = Root;\n return sstyled(styles)(<SActions render={Box} />);\n}\n\nfunction Content({ styles }) {\n const SContent = Root;\n return sstyled(styles)(<SContent render={Box} />);\n}\n\nfunction CloseIcon({ styles, getI18nText }) {\n const SCloseIcon = Root;\n return sstyled(styles)(\n <SCloseIcon\n render={Button}\n addonLeft={Close}\n use='tertiary'\n theme='muted'\n aria-label={getI18nText('close')}\n />,\n );\n}\n\nexport default createComponent(RootNotice, {\n Label,\n Actions,\n Content,\n CloseIcon,\n});\n"],"mappings":";;;;;;;;;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,eAAe,IAAIC,SAAS,EAAEC,OAAO,EAAEC,IAAI,QAAQ,eAAe;AACzE,SAASC,GAAG,QAAQ,mBAAmB;AACvC,OAAOC,MAAM,MAAM,iBAAiB;AACpC,OAAOC,KAAK,MAAM,uBAAuB;AACzC,OAAOC,mBAAmB,MAAM,iDAAiD;AACjF,SAASC,SAAS,QAAQ,oBAAoB;AAC9C,OAAOC,MAAM,MAAM,2BAA2B;AAC9C,OAAOC,YAAY,MAAM,wBAAwB;AACjD,SAASC,iBAAiB,QAAQ,gDAAgD;AAClF,O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"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport
|
1
|
+
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps } from '@semcore/flex-box';\nimport Button from '@semcore/button';\nimport { FadeInOutProps } from '@semcore/animation';\n\nexport type NoticeTheme = 'danger' | 'warning' | 'success' | 'info' | 'muted';\nexport type NoticeUse = 'primary' | 'secondary';\n\n/** @deprecated */\nexport interface INoticeProps extends NoticeProps, UnknownProperties {}\nexport type NoticeProps = BoxProps &\n FadeInOutProps & {\n /** Property for managing visibility of Notice */\n hidden?: boolean;\n /** Notice type\n * @deprecated since version ^4.1.0\n */\n use?: NoticeUse;\n /**\n * Notice theme\n * @default info\n */\n theme?: NoticeTheme;\n /** Duration of animation, ms\n * @default 250\n */\n duration?: number;\n locale?: string;\n };\n\n/** @deprecated */\nexport interface INoticeLabelProps extends NoticeLabelProps, UnknownProperties {}\nexport type NoticeLabelProps = BoxProps & {\n theme?: NoticeTheme;\n};\n\n/** @deprecated */\nexport interface INoticeContext extends NoticeContext, UnknownProperties {}\nexport type NoticeContext = {\n getLabelProps: PropGetterFn;\n};\n\n/** @deprecated */\nexport interface INoticeSmartProps extends NoticeSmartProps, UnknownProperties {}\nexport type NoticeSmartProps = NoticeProps & {\n /**\n * A custom element for additional information\n */\n label?: React.ReactNode;\n /**\n * Custom action element\n */\n actions?: React.ReactNode;\n /**\n * Adds a Close icon\n */\n closable?: boolean;\n /**\n * Callback on a click on the close button\n */\n onClose?: (event: React.SyntheticEvent) => void;\n};\n\ndeclare const Notice: Intergalactic.Component<'div', NoticeProps, NoticeContext> & {\n Label: Intergalactic.Component<'div', NoticeLabelProps>;\n Actions: typeof Box;\n Content: typeof Box;\n CloseIcon: typeof Button;\n};\n\ndeclare const NoticeSmart: Intergalactic.Component<'div', NoticeSmartProps>;\n\nexport { NoticeSmart };\nexport default Notice;\n"],"mappings":""}
|
@@ -86,9 +86,11 @@ SActions {
|
|
86
86
|
}
|
87
87
|
|
88
88
|
SLabel {
|
89
|
-
|
89
|
+
min-height: var(--intergalactic-form-control-m, 28px);
|
90
|
+
height: fit-content;
|
90
91
|
margin-right: var(--intergalactic-spacing-2x, 8px);
|
91
92
|
display: inline-flex;
|
93
|
+
align-items: center;
|
92
94
|
}
|
93
95
|
|
94
96
|
SLabel[theme='info'] {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { PropGetterFn, UnknownProperties, Intergalactic } from 'intergalactic/core';
|
2
2
|
import { Box, BoxProps } from 'intergalactic/flex-box';
|
3
|
-
import
|
3
|
+
import Button from 'intergalactic/button';
|
4
4
|
import { FadeInOutProps } from 'intergalactic/animation';
|
5
5
|
|
6
6
|
export type NoticeTheme = 'danger' | 'warning' | 'success' | 'info' | 'muted';
|
@@ -65,7 +65,7 @@ declare const Notice: Intergalactic.Component<'div', NoticeProps, NoticeContext>
|
|
65
65
|
Label: Intergalactic.Component<'div', NoticeLabelProps>;
|
66
66
|
Actions: typeof Box;
|
67
67
|
Content: typeof Box;
|
68
|
-
CloseIcon:
|
68
|
+
CloseIcon: typeof Button;
|
69
69
|
};
|
70
70
|
|
71
71
|
declare const NoticeSmart: Intergalactic.Component<'div', NoticeSmartProps>;
|
package/notice/package.json
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"name":"intergalactic/notice","description":"Semrush Notice Component","version":"5.
|
1
|
+
{"name":"intergalactic/notice","description":"Semrush Notice Component","version":"5.39.0-prerelease.0","main":"lib/cjs/index.js","module":"lib/es6/index.js","typings":"lib/types/index.d.ts","sideEffects":false,"author":"UI-kit team <ui-kit-team@semrush.com>","license":"MIT","scripts":{"build":"pnpm semcore-builder --source=js"},"dependencies":{"@semcore/animation":"2.31.2","@semcore/utils":"4.32.2","@semcore/button":"5.35.1","@semcore/flex-box":"5.31.2","@semcore/icon":"4.43.2","@semcore/notice-global":"2.48.2"},"peerDependencies":{"@semcore/core":"^2.17.5","react":"16.8 - 18","react-dom":"16.8 - 18"},"repository":{"type":"git","url":"https://github.com/semrush/intergalactic.git","directory":"semcore/notice"},"devDependencies":{"@types/react":"18.0.21","@semcore/testing-utils":"1.0.0"}}
|
package/package.json
CHANGED
package/side-panel/index.d.ts
CHANGED
@@ -4,6 +4,7 @@ import { FadeInOutProps, SlideProps } from 'intergalactic/animation';
|
|
4
4
|
import { PropGetterFn, UnknownProperties, Intergalactic } from 'intergalactic/core';
|
5
5
|
import { Box, BoxProps, Flex } from 'intergalactic/flex-box';
|
6
6
|
import { Text } from 'intergalactic/typography';
|
7
|
+
import Button from 'intergalactic/button';
|
7
8
|
|
8
9
|
export type OnCloseTriggerType = 'onOutsideClick' | 'onEscape' | 'onCloseClick';
|
9
10
|
export type OnCloseType = (
|
@@ -79,7 +80,7 @@ declare const SidePanel: Intergalactic.Component<'div', SidePanelProps, SidePane
|
|
79
80
|
Title: typeof Text;
|
80
81
|
Overlay: Intergalactic.Component<'div', SidePanelOverlayProps>;
|
81
82
|
Panel: Intergalactic.Component<'div', SidePanelPanelProps>;
|
82
|
-
Close: typeof
|
83
|
+
Close: typeof Button;
|
83
84
|
};
|
84
85
|
|
85
86
|
export default SidePanel;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { PortalProps } from '@semcore/portal';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps, Flex } from '@semcore/flex-box';\nimport { Text } from '@semcore/typography';\n\nexport type OnCloseTriggerType = 'onOutsideClick' | 'onEscape' | 'onCloseClick';\nexport type OnCloseType = (\n trigger: OnCloseTriggerType,\n e?: React.MouseEvent | React.KeyboardEvent,\n) => void;\n\nexport type SidePanelPlacement = 'top' | 'left' | 'right' | 'bottom';\n\n/** @deprecated */\nexport interface ISidePanelProps extends SidePanelProps, UnknownProperties {}\nexport type SidePanelProps = PortalProps &\n BoxProps & {\n /** Animation display duration in ms\n * @default 350\n */\n duration?: number;\n /**\n * The property responsible for the visibility of the component\n */\n visible?: boolean;\n /**\n * Callback for the component closure\n */\n onClose?: OnCloseType;\n /**\n * Property for displaying the close button\n * @default true\n */\n closable?: boolean;\n /**\n * Position of a dropdown window\n * @default right\n */\n placement?: SidePanelPlacement;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when SidePanel is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n };\n\n/** @deprecated */\nexport interface ISidePanelOverlayProps extends SidePanelOverlayProps, UnknownProperties {}\nexport type SidePanelOverlayProps = FadeInOutProps & BoxProps & {};\n\n/** @deprecated */\nexport interface ISidePanelPanelProps extends SidePanelPanelProps, UnknownProperties {}\nexport type SidePanelPanelProps = SlideProps &\n BoxProps & {\n onOutsideClick?: (e?: React.SyntheticEvent) => void;\n };\n\n/** @deprecated */\nexport interface ISidePanelContext extends SidePanelContext, UnknownProperties {}\nexport type SidePanelContext = {\n getOverlayProps?: PropGetterFn;\n getPanelProps?: PropGetterFn;\n getCloseProps?: PropGetterFn;\n};\n\n/** @deprecated */\nexport interface ISidePanelHeaderProps extends SidePanelHeaderProps, UnknownProperties {}\nexport type SidePanelHeaderProps = BoxProps & {\n title?: React.ReactNode;\n};\n\ndeclare const SidePanel: Intergalactic.Component<'div', SidePanelProps, SidePanelContext> & {\n Header: Intergalactic.Component<'div', SidePanelHeaderProps>;\n Back: typeof Box;\n Body: typeof Box;\n Footer: typeof Flex;\n Title: typeof Text;\n Overlay: Intergalactic.Component<'div', SidePanelOverlayProps>;\n Panel: Intergalactic.Component<'div', SidePanelPanelProps>;\n Close: typeof
|
1
|
+
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { PortalProps } from '@semcore/portal';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps, Flex } from '@semcore/flex-box';\nimport { Text } from '@semcore/typography';\nimport Button from '@semcore/button';\n\nexport type OnCloseTriggerType = 'onOutsideClick' | 'onEscape' | 'onCloseClick';\nexport type OnCloseType = (\n trigger: OnCloseTriggerType,\n e?: React.MouseEvent | React.KeyboardEvent,\n) => void;\n\nexport type SidePanelPlacement = 'top' | 'left' | 'right' | 'bottom';\n\n/** @deprecated */\nexport interface ISidePanelProps extends SidePanelProps, UnknownProperties {}\nexport type SidePanelProps = PortalProps &\n BoxProps & {\n /** Animation display duration in ms\n * @default 350\n */\n duration?: number;\n /**\n * The property responsible for the visibility of the component\n */\n visible?: boolean;\n /**\n * Callback for the component closure\n */\n onClose?: OnCloseType;\n /**\n * Property for displaying the close button\n * @default true\n */\n closable?: boolean;\n /**\n * Position of a dropdown window\n * @default right\n */\n placement?: SidePanelPlacement;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when SidePanel is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n };\n\n/** @deprecated */\nexport interface ISidePanelOverlayProps extends SidePanelOverlayProps, UnknownProperties {}\nexport type SidePanelOverlayProps = FadeInOutProps & BoxProps & {};\n\n/** @deprecated */\nexport interface ISidePanelPanelProps extends SidePanelPanelProps, UnknownProperties {}\nexport type SidePanelPanelProps = SlideProps &\n BoxProps & {\n onOutsideClick?: (e?: React.SyntheticEvent) => void;\n };\n\n/** @deprecated */\nexport interface ISidePanelContext extends SidePanelContext, UnknownProperties {}\nexport type SidePanelContext = {\n getOverlayProps?: PropGetterFn;\n getPanelProps?: PropGetterFn;\n getCloseProps?: PropGetterFn;\n};\n\n/** @deprecated */\nexport interface ISidePanelHeaderProps extends SidePanelHeaderProps, UnknownProperties {}\nexport type SidePanelHeaderProps = BoxProps & {\n title?: React.ReactNode;\n};\n\ndeclare const SidePanel: Intergalactic.Component<'div', SidePanelProps, SidePanelContext> & {\n Header: Intergalactic.Component<'div', SidePanelHeaderProps>;\n Back: typeof Box;\n Body: typeof Box;\n Footer: typeof Flex;\n Title: typeof Text;\n Overlay: Intergalactic.Component<'div', SidePanelOverlayProps>;\n Panel: Intergalactic.Component<'div', SidePanelPanelProps>;\n Close: typeof Button;\n};\n\nexport default SidePanel;\n"],"mappings":""}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { PortalProps } from '@semcore/portal';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps, Flex } from '@semcore/flex-box';\nimport { Text } from '@semcore/typography';\n\nexport type OnCloseTriggerType = 'onOutsideClick' | 'onEscape' | 'onCloseClick';\nexport type OnCloseType = (\n trigger: OnCloseTriggerType,\n e?: React.MouseEvent | React.KeyboardEvent,\n) => void;\n\nexport type SidePanelPlacement = 'top' | 'left' | 'right' | 'bottom';\n\n/** @deprecated */\nexport interface ISidePanelProps extends SidePanelProps, UnknownProperties {}\nexport type SidePanelProps = PortalProps &\n BoxProps & {\n /** Animation display duration in ms\n * @default 350\n */\n duration?: number;\n /**\n * The property responsible for the visibility of the component\n */\n visible?: boolean;\n /**\n * Callback for the component closure\n */\n onClose?: OnCloseType;\n /**\n * Property for displaying the close button\n * @default true\n */\n closable?: boolean;\n /**\n * Position of a dropdown window\n * @default right\n */\n placement?: SidePanelPlacement;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when SidePanel is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n };\n\n/** @deprecated */\nexport interface ISidePanelOverlayProps extends SidePanelOverlayProps, UnknownProperties {}\nexport type SidePanelOverlayProps = FadeInOutProps & BoxProps & {};\n\n/** @deprecated */\nexport interface ISidePanelPanelProps extends SidePanelPanelProps, UnknownProperties {}\nexport type SidePanelPanelProps = SlideProps &\n BoxProps & {\n onOutsideClick?: (e?: React.SyntheticEvent) => void;\n };\n\n/** @deprecated */\nexport interface ISidePanelContext extends SidePanelContext, UnknownProperties {}\nexport type SidePanelContext = {\n getOverlayProps?: PropGetterFn;\n getPanelProps?: PropGetterFn;\n getCloseProps?: PropGetterFn;\n};\n\n/** @deprecated */\nexport interface ISidePanelHeaderProps extends SidePanelHeaderProps, UnknownProperties {}\nexport type SidePanelHeaderProps = BoxProps & {\n title?: React.ReactNode;\n};\n\ndeclare const SidePanel: Intergalactic.Component<'div', SidePanelProps, SidePanelContext> & {\n Header: Intergalactic.Component<'div', SidePanelHeaderProps>;\n Back: typeof Box;\n Body: typeof Box;\n Footer: typeof Flex;\n Title: typeof Text;\n Overlay: Intergalactic.Component<'div', SidePanelOverlayProps>;\n Panel: Intergalactic.Component<'div', SidePanelPanelProps>;\n Close: typeof
|
1
|
+
{"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import React from 'react';\nimport { PortalProps } from '@semcore/portal';\nimport { FadeInOutProps, SlideProps } from '@semcore/animation';\nimport { PropGetterFn, UnknownProperties, Intergalactic } from '@semcore/core';\nimport { Box, BoxProps, Flex } from '@semcore/flex-box';\nimport { Text } from '@semcore/typography';\nimport Button from '@semcore/button';\n\nexport type OnCloseTriggerType = 'onOutsideClick' | 'onEscape' | 'onCloseClick';\nexport type OnCloseType = (\n trigger: OnCloseTriggerType,\n e?: React.MouseEvent | React.KeyboardEvent,\n) => void;\n\nexport type SidePanelPlacement = 'top' | 'left' | 'right' | 'bottom';\n\n/** @deprecated */\nexport interface ISidePanelProps extends SidePanelProps, UnknownProperties {}\nexport type SidePanelProps = PortalProps &\n BoxProps & {\n /** Animation display duration in ms\n * @default 350\n */\n duration?: number;\n /**\n * The property responsible for the visibility of the component\n */\n visible?: boolean;\n /**\n * Callback for the component closure\n */\n onClose?: OnCloseType;\n /**\n * Property for displaying the close button\n * @default true\n */\n closable?: boolean;\n /**\n * Position of a dropdown window\n * @default right\n */\n placement?: SidePanelPlacement;\n /**\n * Setting `true` disables mechanism that hides document body scrollbar when SidePanel is visible\n * @default false\n */\n disablePreventScroll?: boolean;\n };\n\n/** @deprecated */\nexport interface ISidePanelOverlayProps extends SidePanelOverlayProps, UnknownProperties {}\nexport type SidePanelOverlayProps = FadeInOutProps & BoxProps & {};\n\n/** @deprecated */\nexport interface ISidePanelPanelProps extends SidePanelPanelProps, UnknownProperties {}\nexport type SidePanelPanelProps = SlideProps &\n BoxProps & {\n onOutsideClick?: (e?: React.SyntheticEvent) => void;\n };\n\n/** @deprecated */\nexport interface ISidePanelContext extends SidePanelContext, UnknownProperties {}\nexport type SidePanelContext = {\n getOverlayProps?: PropGetterFn;\n getPanelProps?: PropGetterFn;\n getCloseProps?: PropGetterFn;\n};\n\n/** @deprecated */\nexport interface ISidePanelHeaderProps extends SidePanelHeaderProps, UnknownProperties {}\nexport type SidePanelHeaderProps = BoxProps & {\n title?: React.ReactNode;\n};\n\ndeclare const SidePanel: Intergalactic.Component<'div', SidePanelProps, SidePanelContext> & {\n Header: Intergalactic.Component<'div', SidePanelHeaderProps>;\n Back: typeof Box;\n Body: typeof Box;\n Footer: typeof Flex;\n Title: typeof Text;\n Overlay: Intergalactic.Component<'div', SidePanelOverlayProps>;\n Panel: Intergalactic.Component<'div', SidePanelPanelProps>;\n Close: typeof Button;\n};\n\nexport default SidePanel;\n"],"mappings":""}
|
@@ -4,6 +4,7 @@ import { FadeInOutProps, SlideProps } from 'intergalactic/animation';
|
|
4
4
|
import { PropGetterFn, UnknownProperties, Intergalactic } from 'intergalactic/core';
|
5
5
|
import { Box, BoxProps, Flex } from 'intergalactic/flex-box';
|
6
6
|
import { Text } from 'intergalactic/typography';
|
7
|
+
import Button from 'intergalactic/button';
|
7
8
|
|
8
9
|
export type OnCloseTriggerType = 'onOutsideClick' | 'onEscape' | 'onCloseClick';
|
9
10
|
export type OnCloseType = (
|
@@ -79,7 +80,7 @@ declare const SidePanel: Intergalactic.Component<'div', SidePanelProps, SidePane
|
|
79
80
|
Title: typeof Text;
|
80
81
|
Overlay: Intergalactic.Component<'div', SidePanelOverlayProps>;
|
81
82
|
Panel: Intergalactic.Component<'div', SidePanelPanelProps>;
|
82
|
-
Close: typeof
|
83
|
+
Close: typeof Button;
|
83
84
|
};
|
84
85
|
|
85
86
|
export default SidePanel;
|
@@ -30,18 +30,18 @@ var _intergalacticDynamicLocales = require("./translations/__intergalactic-dynam
|
|
30
30
|
var _i18nEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/i18nEnhance"));
|
31
31
|
var _keyboardFocusEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/keyboardFocusEnhance"));
|
32
32
|
/*__reshadow-styles__:"./style/time-picker.shadow.css"*/
|
33
|
-
var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".
|
34
|
-
"__STimePicker": "
|
35
|
-
"_keyboardFocused": "
|
36
|
-
"_disabled": "
|
37
|
-
"__SPickerInput": "
|
38
|
-
"_size_m": "
|
39
|
-
"_size_l": "
|
40
|
-
"__SPickerFormat": "
|
41
|
-
"__STimePickerSeparator": "
|
42
|
-
"_placeholder": "
|
43
|
-
"_active": "
|
44
|
-
"__SPickerFormatText": "
|
33
|
+
var style = ( /*__reshadow_css_start__*/_index.sstyled.insert( /*__inner_css_start__*/".___STimePicker_1w4xu_gg_{position:relative;width:auto;outline:0}.___STimePicker_1w4xu_gg_.__keyboardFocused_1w4xu_gg_:focus{box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}.___STimePicker_1w4xu_gg_.__disabled_1w4xu_gg_{color:var(--intergalactic-text-secondary, #6c6e79);cursor:default}.___SPickerInput_1w4xu_gg_{box-sizing:content-box;text-align:center;z-index:1;height:1.5em}.___SPickerInput_1w4xu_gg_.__placeholder_1w4xu_gg_{text-overflow:initial}.___SPickerInput_1w4xu_gg_:focus{background-color:var(--intergalactic-bg-highlight-focus, rgba(0, 143, 248, 0.2))}.___SPickerInput_1w4xu_gg_._size_l_1w4xu_gg_,.___SPickerInput_1w4xu_gg_._size_m_1w4xu_gg_{width:19px;margin:0 var(--intergalactic-spacing-2x, 8px);padding:0}.___SPickerInput_1w4xu_gg_._size_l_1w4xu_gg_{width:21px}.___SPickerFormat_1w4xu_gg_{flex-shrink:0;position:relative;display:inline-flex;padding:0;white-space:nowrap;font-family:inherit;font-weight:var(--intergalactic-medium, 500);line-height:normal;-webkit-text-decoration:none;text-decoration:none;align-items:center;border:1px solid var(--intergalactic-border-primary, #c4c7cf);border-radius:0 var(--intergalactic-control-rounded, 6px) var(--intergalactic-control-rounded, 6px)0;outline:0;box-shadow:none;cursor:pointer;box-sizing:border-box;overflow:visible;-webkit-user-select:none;-moz-user-select:none;user-select:none;touch-action:manipulation;-webkit-tap-highlight-color:transparent;color:var(--intergalactic-text-secondary, #6c6e79);background-color:var(--intergalactic-bg-secondary-neutral, #f4f5f9)}@media (hover:hover){.___SPickerFormat_1w4xu_gg_:hover{color:var(--intergalactic-text-secondary, #6c6e79);background-color:var(--intergalactic-bg-secondary-neutral-hover, #e0e1e9)}}.___SPickerFormat_1w4xu_gg_.__active_1w4xu_gg_,.___SPickerFormat_1w4xu_gg_:active{color:var(--intergalactic-text-secondary, #6c6e79);background-color:var(--intergalactic-bg-secondary-neutral-active, #c4c7cf)}.___SPickerFormat_1w4xu_gg_:focus,.___SPickerFormat_1w4xu_gg_:focus-visible{outline:0}.___SPickerFormat_1w4xu_gg_._size_m_1w4xu_gg_{height:var(--intergalactic-form-control-m, 28px);font-size:var(--intergalactic-fs-200, 14px);margin:0-1px 0 0}.___SPickerFormat_1w4xu_gg_._size_m_1w4xu_gg_ .___SPickerFormatText_1w4xu_gg_{margin:0 var(--intergalactic-spacing-2x, 8px)}.___SPickerFormat_1w4xu_gg_._size_l_1w4xu_gg_{height:var(--intergalactic-form-control-l, 40px);font-size:var(--intergalactic-fs-300, 16px);margin:0 calc(-1*var(--intergalactic-spacing-1x, 4px))0 0}.___SPickerFormat_1w4xu_gg_._size_l_1w4xu_gg_ .___SPickerFormatText_1w4xu_gg_{margin:0 var(--intergalactic-spacing-3x, 12px)}.___SPickerFormat_1w4xu_gg_.__disabled_1w4xu_gg_{opacity:var(--intergalactic-disabled-opacity, 0.3);cursor:default;pointer-events:none;border-color:transparent transparent transparent var(--intergalactic-border-primary, #c4c7cf)}.___SPickerFormat_1w4xu_gg_.__keyboardFocused_1w4xu_gg_{box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}.___STimePickerSeparator_1w4xu_gg_{color:var(--intergalactic-text-primary, #191b23)}.___STimePickerSeparator_1w4xu_gg_.__disabled_1w4xu_gg_{opacity:var(--intergalactic-disabled-opacity, 0.3);pointer-events:none}" /*__inner_css_end__*/, "1w4xu_gg_") /*__reshadow_css_end__*/, {
|
34
|
+
"__STimePicker": "___STimePicker_1w4xu_gg_",
|
35
|
+
"_keyboardFocused": "__keyboardFocused_1w4xu_gg_",
|
36
|
+
"_disabled": "__disabled_1w4xu_gg_",
|
37
|
+
"__SPickerInput": "___SPickerInput_1w4xu_gg_",
|
38
|
+
"_size_m": "_size_m_1w4xu_gg_",
|
39
|
+
"_size_l": "_size_l_1w4xu_gg_",
|
40
|
+
"__SPickerFormat": "___SPickerFormat_1w4xu_gg_",
|
41
|
+
"__STimePickerSeparator": "___STimePickerSeparator_1w4xu_gg_",
|
42
|
+
"_placeholder": "__placeholder_1w4xu_gg_",
|
43
|
+
"_active": "__active_1w4xu_gg_",
|
44
|
+
"__SPickerFormatText": "___SPickerFormatText_1w4xu_gg_"
|
45
45
|
});
|
46
46
|
var MAP_MERIDIEM = {
|
47
47
|
AM: 'PM',
|
@@ -1,7 +1,8 @@
|
|
1
1
|
{
|
2
|
-
"title": "
|
3
|
-
"titleEmpty": "
|
4
|
-
"hours": "
|
5
|
-
"minutes": "
|
6
|
-
"
|
2
|
+
"title": "{time} {meridiem}",
|
3
|
+
"titleEmpty": "Auswählen",
|
4
|
+
"hours": "Stunden",
|
5
|
+
"minutes": "Minuten",
|
6
|
+
"formatToggler": "Zeitraum",
|
7
|
+
"changedFormatNotice": "Zeitraum geändert auf {meridiem}"
|
7
8
|
}
|
@@ -1,7 +1,8 @@
|
|
1
1
|
{
|
2
|
-
"title": "
|
3
|
-
"titleEmpty": "
|
4
|
-
"hours": "
|
5
|
-
"minutes": "
|
6
|
-
"
|
2
|
+
"title": "{time} {meridiem}",
|
3
|
+
"titleEmpty": "Seleccionar",
|
4
|
+
"hours": "Horas",
|
5
|
+
"minutes": "Minutos",
|
6
|
+
"formatToggler": "Período de tiempo",
|
7
|
+
"changedFormatNotice": "Periodo de tiempo cambiado a {meridiem}"
|
7
8
|
}
|
@@ -1,7 +1,8 @@
|
|
1
1
|
{
|
2
|
-
"title": "
|
3
|
-
"titleEmpty": "
|
4
|
-
"hours": "
|
5
|
-
"minutes": "
|
6
|
-
"
|
2
|
+
"title": "{time} {meridiem}",
|
3
|
+
"titleEmpty": "Sélectionner",
|
4
|
+
"hours": "Heures",
|
5
|
+
"minutes": "Minutes",
|
6
|
+
"formatToggler": "Période",
|
7
|
+
"changedFormatNotice": "La période a été définie sur {meridiem}"
|
7
8
|
}
|