intergalactic 15.60.1-prerelease-e7be36ff → 15.61.0-prerelease-5e9c09fb
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/base-trigger/lib/cjs/BaseTrigger.js +18 -18
- package/base-trigger/lib/cjs/ButtonTrigger.js +3 -3
- package/base-trigger/lib/cjs/FilterTrigger.js +7 -7
- package/base-trigger/lib/cjs/LinkTrigger.js +12 -12
- package/base-trigger/lib/es6/BaseTrigger.js +18 -18
- package/base-trigger/lib/es6/ButtonTrigger.js +3 -3
- package/base-trigger/lib/es6/FilterTrigger.js +7 -7
- package/base-trigger/lib/es6/LinkTrigger.js +12 -12
- package/components.json +10 -10
- package/d3-chart/lib/cjs/Area.js +11 -11
- package/d3-chart/lib/cjs/Axis.js +14 -14
- package/d3-chart/lib/cjs/Bar.js +10 -10
- package/d3-chart/lib/cjs/Bubble.js +12 -12
- package/d3-chart/lib/cjs/Donut.js +9 -9
- package/d3-chart/lib/cjs/Dots.js +8 -8
- package/d3-chart/lib/cjs/HorizontalBar.js +10 -10
- package/d3-chart/lib/cjs/Hover.js +3 -3
- package/d3-chart/lib/cjs/Line.js +9 -9
- package/d3-chart/lib/cjs/Plot.js +3 -3
- package/d3-chart/lib/cjs/Radar.js +19 -19
- package/d3-chart/lib/cjs/RadialTree.js +11 -11
- package/d3-chart/lib/cjs/ReferenceLine.js +9 -9
- package/d3-chart/lib/cjs/ScatterPlot.js +9 -9
- package/d3-chart/lib/cjs/Tooltip.js +9 -9
- package/d3-chart/lib/cjs/Venn.js +9 -9
- package/d3-chart/lib/cjs/a11y/PlotA11yModule.js +2 -2
- package/d3-chart/lib/cjs/a11y/PlotA11yView.js +2 -2
- package/d3-chart/lib/cjs/component/ChartLegend/LegendFlex/LegendFlex.js +4 -4
- package/d3-chart/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js +17 -17
- package/d3-chart/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js +6 -6
- package/d3-chart/lib/es6/Area.js +11 -11
- package/d3-chart/lib/es6/Axis.js +14 -14
- package/d3-chart/lib/es6/Bar.js +10 -10
- package/d3-chart/lib/es6/Bubble.js +12 -12
- package/d3-chart/lib/es6/Donut.js +9 -9
- package/d3-chart/lib/es6/Dots.js +8 -8
- package/d3-chart/lib/es6/HorizontalBar.js +10 -10
- package/d3-chart/lib/es6/Hover.js +3 -3
- package/d3-chart/lib/es6/Line.js +9 -9
- package/d3-chart/lib/es6/Plot.js +3 -3
- package/d3-chart/lib/es6/Radar.js +19 -19
- package/d3-chart/lib/es6/RadialTree.js +11 -11
- package/d3-chart/lib/es6/ReferenceLine.js +9 -9
- package/d3-chart/lib/es6/ScatterPlot.js +9 -9
- package/d3-chart/lib/es6/Tooltip.js +9 -9
- package/d3-chart/lib/es6/Venn.js +9 -9
- package/d3-chart/lib/es6/a11y/PlotA11yModule.js +2 -2
- package/d3-chart/lib/es6/a11y/PlotA11yView.js +2 -2
- package/d3-chart/lib/es6/component/ChartLegend/LegendFlex/LegendFlex.js +4 -4
- package/d3-chart/lib/es6/component/ChartLegend/LegendItem/LegendItem.js +17 -17
- package/d3-chart/lib/es6/component/ChartLegend/LegendTable/LegendTable.js +6 -6
- package/date-picker/lib/cjs/components/Calendar.js +21 -21
- package/date-picker/lib/cjs/components/DateRangeComparatorAbstract.js +26 -26
- package/date-picker/lib/cjs/components/InputTrigger.js +26 -26
- package/date-picker/lib/cjs/components/PickerAbstract.js +26 -26
- package/date-picker/lib/cjs/components/RangePickerAbstract.js +26 -26
- package/date-picker/lib/es6/components/Calendar.js +21 -21
- package/date-picker/lib/es6/components/DateRangeComparatorAbstract.js +26 -26
- package/date-picker/lib/es6/components/InputTrigger.js +26 -26
- package/date-picker/lib/es6/components/PickerAbstract.js +26 -26
- package/date-picker/lib/es6/components/RangePickerAbstract.js +26 -26
- package/dropdown/lib/cjs/Dropdown.js +2 -2
- package/dropdown/lib/es6/Dropdown.js +2 -2
- package/dropdown-menu/index.d.ts +9 -0
- package/dropdown-menu/lib/cjs/DropdownMenu.js +311 -95
- package/dropdown-menu/lib/cjs/DropdownMenu.js.map +1 -1
- package/dropdown-menu/lib/cjs/index.d.js.map +1 -1
- package/dropdown-menu/lib/cjs/style/dropdown-menu.shadow.css +20 -1
- package/dropdown-menu/lib/cjs/styleScrollArea.js +6 -6
- package/dropdown-menu/lib/es6/DropdownMenu.js +316 -97
- package/dropdown-menu/lib/es6/DropdownMenu.js.map +1 -1
- package/dropdown-menu/lib/es6/index.d.js.map +1 -1
- package/dropdown-menu/lib/es6/style/dropdown-menu.shadow.css +20 -1
- package/dropdown-menu/lib/es6/styleScrollArea.js +6 -6
- package/dropdown-menu/lib/types/index.d.ts +9 -0
- package/feature-popover/lib/cjs/FeaturePopover.js +10 -10
- package/feature-popover/lib/es6/FeaturePopover.js +10 -10
- package/format-text/lib/cjs/FormatText.js +5 -5
- package/format-text/lib/cjs/style/format-text.shadow.css +3 -1
- package/format-text/lib/es6/FormatText.js +5 -5
- package/format-text/lib/es6/style/format-text.shadow.css +3 -1
- package/link/lib/cjs/Link.js +12 -12
- package/link/lib/cjs/style/link.shadow.css +4 -6
- package/link/lib/es6/Link.js +12 -12
- package/link/lib/es6/style/link.shadow.css +4 -6
- package/package.json +3 -3
- package/popper/lib/cjs/Popper.js +6 -6
- package/popper/lib/es6/Popper.js +6 -6
- package/select/lib/cjs/InputSearch.js +6 -6
- package/select/lib/cjs/Select.js +9 -9
- package/select/lib/es6/InputSearch.js +6 -6
- package/select/lib/es6/Select.js +9 -9
- package/tag/index.d.ts +35 -33
- package/tag/lib/cjs/Tag.js +89 -56
- package/tag/lib/cjs/Tag.js.map +1 -1
- package/tag/lib/cjs/index.d.js.map +1 -1
- package/tag/lib/cjs/style/tag.shadow.css +27 -2
- package/tag/lib/es6/Tag.js +89 -56
- package/tag/lib/es6/Tag.js.map +1 -1
- package/tag/lib/es6/index.d.js.map +1 -1
- package/tag/lib/es6/style/tag.shadow.css +27 -2
- package/tag/lib/types/index.d.ts +35 -33
- package/time-picker/lib/cjs/TimePicker.js +12 -12
- package/time-picker/lib/es6/TimePicker.js +12 -12
- package/tooltip/lib/cjs/Tooltip.js +7 -7
- package/tooltip/lib/es6/Tooltip.js +7 -7
- package/utils/lib/themes/auto.css +6 -6
- package/utils/lib/themes/dark.css +0 -2
- package/utils/lib/themes/dark.json +0 -1
- package/utils/lib/themes/default.css +6 -4
- package/utils/lib/themes/default.json +3 -2
- package/utils/lib/themes/light.css +6 -4
- package/utils/lib/themes/light.json +3 -2
- package/utils/lib/use/useFocusLock.js +5 -0
- package/utils/lib/use/useFocusLock.js.map +1 -1
- package/utils/lib/use/useFocusLock.mjs +5 -0
- package/utils/lib/use/useFocusLock.mjs.map +1 -1
package/link/lib/es6/Link.js
CHANGED
@@ -19,18 +19,18 @@ import logger from 'intergalactic/utils/lib/logger';
|
|
19
19
|
import hasLabels from 'intergalactic/utils/lib/hasLabels';
|
20
20
|
import resolveColorEnhance from 'intergalactic/utils/lib/enhances/resolveColorEnhance';
|
21
21
|
/*__reshadow-styles__:"./style/link.shadow.css"*/
|
22
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
23
|
-
"__SLink": "
|
24
|
-
"_keyboardFocused": "
|
25
|
-
"_disabled": "
|
26
|
-
"_noWrapText": "
|
27
|
-
"_inline": "
|
28
|
-
"__SAddon": "
|
29
|
-
"__SText": "
|
30
|
-
"_active": "
|
31
|
-
"_enableVisited": "
|
32
|
-
"_text-color": "__text-
|
33
|
-
"--text-color": "--text-
|
22
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SLink_otxxu_gg_{display:inline-block;font-family:inherit;color:var(--intergalactic-text-link, #006dca);line-height:normal;position:relative;cursor:pointer;-webkit-text-decoration:none;text-decoration:none;border:0;padding:0;margin:0;box-shadow:none;-webkit-tap-highlight-color:transparent;outline:0;background:0 0;transition:color .15s ease-in-out}.___SLink_otxxu_gg_:active,.___SLink_otxxu_gg_:focus{outline:0;-webkit-text-decoration:none;text-decoration:none}@media (hover:hover){.___SLink_otxxu_gg_:hover{outline:0;-webkit-text-decoration:none;text-decoration:none}}.___SLink_otxxu_gg_::-moz-focus-inner{border:0;padding:0}.___SLink_otxxu_gg_.__active_otxxu_gg_,.___SLink_otxxu_gg_:active{color:var(--intergalactic-text-link-hover-active, #044792)}@media (hover:hover){.___SLink_otxxu_gg_:hover{color:var(--intergalactic-text-link-hover-active, #044792)}}.___SLink_otxxu_gg_.__active_otxxu_gg_ .___SText_otxxu_gg_,.___SLink_otxxu_gg_:active .___SText_otxxu_gg_{border-color:currentColor}@media (hover:hover){.___SLink_otxxu_gg_:hover .___SText_otxxu_gg_{border-color:currentColor}}.___SLink_otxxu_gg_.__enableVisited_otxxu_gg_:visited{color:var(--intergalactic-text-link-visited, #8649e1)}@media (hover:hover){.___SLink_otxxu_gg_.__enableVisited_otxxu_gg_:visited:hover{color:var(--intergalactic-text-link-visited, #8649e1)}}.___SLink_otxxu_gg_.__keyboardFocused_otxxu_gg_{outline-color:var(--intergalactic-keyboard-focus-outline, rgba(0, 143, 248, 0.5));outline-style:solid;outline-width:3px}.___SLink_otxxu_gg_.__disabled_otxxu_gg_{opacity:var(--intergalactic-disabled-opacity, 0.3);cursor:default;pointer-events:none}.___SLink_otxxu_gg_.__noWrapText_otxxu_gg_{white-space:nowrap}.___SLink_otxxu_gg_.__inline_otxxu_gg_{display:inline}.___SAddon_otxxu_gg_{display:inline-flex;justify-content:center;align-items:center;margin-bottom:var(--intergalactic-spacing-05x, 2px);vertical-align:middle}.___SLink_otxxu_gg_ .___SAddon_otxxu_gg_:not(:only-child):first-child{margin-right:var(--intergalactic-spacing-1x, 4px)}.___SLink_otxxu_gg_ .___SAddon_otxxu_gg_:not(:only-child):last-child{margin-left:var(--intergalactic-spacing-1x, 4px)}.___SText_otxxu_gg_{border-bottom-width:1px;border-bottom-style:solid;border-color:transparent;transition:border-bottom-color .15s ease-in-out}.___SLink_otxxu_gg_.__text-color_otxxu_gg_{color:var(--text-color_otxxu)}.___SLink_otxxu_gg_.__text-color_otxxu_gg_.__active_otxxu_gg_,.___SLink_otxxu_gg_.__text-color_otxxu_gg_:active{color:var(--text-color_otxxu);filter:brightness(.8)}@media (hover:hover){.___SLink_otxxu_gg_.__text-color_otxxu_gg_:hover{color:var(--text-color_otxxu);filter:brightness(.8)}}@media (prefers-reduced-motion){.___SLink_otxxu_gg_,.___SText_otxxu_gg_{transition:none}}" /*__inner_css_end__*/, "otxxu_gg_") /*__reshadow_css_end__*/, {
|
23
|
+
"__SLink": "___SLink_otxxu_gg_",
|
24
|
+
"_keyboardFocused": "__keyboardFocused_otxxu_gg_",
|
25
|
+
"_disabled": "__disabled_otxxu_gg_",
|
26
|
+
"_noWrapText": "__noWrapText_otxxu_gg_",
|
27
|
+
"_inline": "__inline_otxxu_gg_",
|
28
|
+
"__SAddon": "___SAddon_otxxu_gg_",
|
29
|
+
"__SText": "___SText_otxxu_gg_",
|
30
|
+
"_active": "__active_otxxu_gg_",
|
31
|
+
"_enableVisited": "__enableVisited_otxxu_gg_",
|
32
|
+
"_text-color": "__text-color_otxxu_gg_",
|
33
|
+
"--text-color": "--text-color_otxxu"
|
34
34
|
});
|
35
35
|
var RootLink = /*#__PURE__*/function (_Component) {
|
36
36
|
_inherits(RootLink, _Component);
|
@@ -43,12 +43,10 @@ SLink {
|
|
43
43
|
}
|
44
44
|
}
|
45
45
|
|
46
|
-
SLink[keyboardFocused]
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
inset: 0;
|
51
|
-
box-shadow: var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));
|
46
|
+
SLink[keyboardFocused] {
|
47
|
+
outline-color: var(--intergalactic-keyboard-focus-outline, rgba(0, 143, 248, 0.5));
|
48
|
+
outline-style: solid;
|
49
|
+
outline-width: 3px;
|
52
50
|
}
|
53
51
|
|
54
52
|
SLink[disabled] {
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "intergalactic",
|
3
|
-
"version": "15.
|
3
|
+
"version": "15.61.0-prerelease-5e9c09fb",
|
4
4
|
"license": "MIT",
|
5
5
|
"dependencies": {
|
6
6
|
"intergalactic-migrate": "0.0.0",
|
@@ -26,8 +26,8 @@
|
|
26
26
|
"@babel/runtime": "^7.17.9",
|
27
27
|
"text-mask-core": "5.1.2",
|
28
28
|
"@popperjs/core": "2.11.5",
|
29
|
-
"
|
30
|
-
"
|
29
|
+
"@phytonmk/nano-css": "5.3.7",
|
30
|
+
"unplugin": "1.2.0"
|
31
31
|
},
|
32
32
|
"peerDependencies": {
|
33
33
|
"react": "16.8 - 18",
|
package/popper/lib/cjs/Popper.js
CHANGED
@@ -40,12 +40,12 @@ var _excluded = ["placement", "modifiers", "strategy", "onFirstUpdate"],
|
|
40
40
|
_excluded2 = ["onKeyDown"],
|
41
41
|
_excluded3 = ["onKeyDown"];
|
42
42
|
/*__reshadow-styles__:"./style/popper.shadow.css"*/
|
43
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
44
|
-
"__SPopper": "
|
45
|
-
"_keyboardFocused": "
|
46
|
-
"_hideFocus": "
|
47
|
-
"__SFocusHint": "
|
48
|
-
"__STrigger": "
|
43
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SPopper_102vs_gg_{outline:0;z-index:var(--intergalactic-z-index-popper, 700);color:var(--intergalactic-text-primary, #191b23)}.___SPopper_102vs_gg_.__keyboardFocused_102vs_gg_:focus:after{position:absolute;display:block;content:\"\";top:0;right:0;bottom:0;left:0;box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));pointer-events:none}.___SPopper_102vs_gg_.__keyboardFocused_102vs_gg_.__hideFocus_102vs_gg_:focus:after{box-shadow:none}.___SFocusHint_102vs_gg_{display:none}.___STrigger_102vs_gg_:focus .___SFocusHint_102vs_gg_,.___STrigger_102vs_gg_:focus-within .___SFocusHint_102vs_gg_{display:inline}" /*__inner_css_end__*/, "102vs_gg_") /*__reshadow_css_end__*/, {
|
44
|
+
"__SPopper": "___SPopper_102vs_gg_",
|
45
|
+
"_keyboardFocused": "__keyboardFocused_102vs_gg_",
|
46
|
+
"_hideFocus": "__hideFocus_102vs_gg_",
|
47
|
+
"__SFocusHint": "___SFocusHint_102vs_gg_",
|
48
|
+
"__STrigger": "___STrigger_102vs_gg_"
|
49
49
|
});
|
50
50
|
function isObject(obj) {
|
51
51
|
return (0, _typeof2["default"])(obj) === 'object' && !Array.isArray(obj);
|
package/popper/lib/es6/Popper.js
CHANGED
@@ -35,12 +35,12 @@ import keyboardFocusEnhance, { useFocusSource } from 'intergalactic/utils/lib/en
|
|
35
35
|
import { hasParent } from 'intergalactic/utils/lib/hasParent';
|
36
36
|
import _createPopper from './createPopper';
|
37
37
|
/*__reshadow-styles__:"./style/popper.shadow.css"*/
|
38
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
39
|
-
"__SPopper": "
|
40
|
-
"_keyboardFocused": "
|
41
|
-
"_hideFocus": "
|
42
|
-
"__SFocusHint": "
|
43
|
-
"__STrigger": "
|
38
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SPopper_102vs_gg_{outline:0;z-index:var(--intergalactic-z-index-popper, 700);color:var(--intergalactic-text-primary, #191b23)}.___SPopper_102vs_gg_.__keyboardFocused_102vs_gg_:focus:after{position:absolute;display:block;content:\"\";top:0;right:0;bottom:0;left:0;box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));pointer-events:none}.___SPopper_102vs_gg_.__keyboardFocused_102vs_gg_.__hideFocus_102vs_gg_:focus:after{box-shadow:none}.___SFocusHint_102vs_gg_{display:none}.___STrigger_102vs_gg_:focus .___SFocusHint_102vs_gg_,.___STrigger_102vs_gg_:focus-within .___SFocusHint_102vs_gg_{display:inline}" /*__inner_css_end__*/, "102vs_gg_") /*__reshadow_css_end__*/, {
|
39
|
+
"__SPopper": "___SPopper_102vs_gg_",
|
40
|
+
"_keyboardFocused": "__keyboardFocused_102vs_gg_",
|
41
|
+
"_hideFocus": "__hideFocus_102vs_gg_",
|
42
|
+
"__SFocusHint": "___SFocusHint_102vs_gg_",
|
43
|
+
"__STrigger": "___STrigger_102vs_gg_"
|
44
44
|
});
|
45
45
|
function isObject(obj) {
|
46
46
|
return _typeof(obj) === 'object' && !Array.isArray(obj);
|
@@ -22,12 +22,12 @@ var _context = require("./context");
|
|
22
22
|
var _i18nEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/i18nEnhance"));
|
23
23
|
var _intergalacticDynamicLocales = require("./translations/__intergalactic-dynamic-locales");
|
24
24
|
/*__reshadow-styles__:"./style/input-search.shadow.css"*/
|
25
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
26
|
-
"__SInputSearch": "
|
27
|
-
"_size_m": "
|
28
|
-
"__SSearchClear": "
|
29
|
-
"_hide": "
|
30
|
-
"__SOutline": "
|
25
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SInputSearch_1a87i_gg_._size_m_1a87i_gg_{height:32px}.___SSearchClear_1a87i_gg_.__hide_1a87i_gg_{visibility:hidden}.___SOutline_1a87i_gg_{top:-1px;left:-1px;width:100%;border-radius:var(--intergalactic-control-rounded, 6px) var(--intergalactic-control-rounded, 6px)0 0}" /*__inner_css_end__*/, "1a87i_gg_") /*__reshadow_css_end__*/, {
|
26
|
+
"__SInputSearch": "___SInputSearch_1a87i_gg_",
|
27
|
+
"_size_m": "_size_m_1a87i_gg_",
|
28
|
+
"__SSearchClear": "___SSearchClear_1a87i_gg_",
|
29
|
+
"_hide": "__hide_1a87i_gg_",
|
30
|
+
"__SOutline": "___SOutline_1a87i_gg_"
|
31
31
|
});
|
32
32
|
var InputSearchRoot = /*#__PURE__*/function (_Component) {
|
33
33
|
(0, _inherits2["default"])(InputSearchRoot, _Component);
|
package/select/lib/cjs/Select.js
CHANGED
@@ -36,15 +36,15 @@ var _intergalacticDynamicLocales = require("./translations/__intergalactic-dynam
|
|
36
36
|
var _useFocusLock = require("intergalactic/utils/lib/use/useFocusLock");
|
37
37
|
var _excluded = ["Children", "options", "multiselect", "value", "uid", "forcedAdvancedMode"];
|
38
38
|
/*__reshadow-styles__:"./style/select.shadow.css"*/
|
39
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
40
|
-
"__SOptionCheckbox": "
|
41
|
-
"_checked": "
|
42
|
-
"_indeterminate": "
|
43
|
-
"_theme": "
|
44
|
-
"--theme": "--
|
45
|
-
"_size_l": "
|
46
|
-
"_size_m": "
|
47
|
-
"_selected": "
|
39
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SOptionCheckbox_83krg_gg_{margin-top:var(--intergalactic-spacing-05x, 2px);margin-right:var(--intergalactic-spacing-2x, 8px);margin-bottom:auto;position:relative;flex-shrink:0;width:16px;height:16px}.___SOptionCheckbox_83krg_gg_::before{content:\"\";position:absolute;top:0;left:0;right:0;bottom:0;background:var(--intergalactic-bg-primary-neutral, #ffffff);border:1px solid;border-radius:var(--intergalactic-addon-rounded, 4px);border-color:var(--intergalactic-border-primary, #c4c7cf)}.___SOptionCheckbox_83krg_gg_::after{content:\"\";position:absolute;top:0;left:0;right:0;bottom:0;margin:0 var(--intergalactic-spacing-05x, 2px);background-repeat:no-repeat;background-position:center center;background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAiIGhlaWdodD0iNyIgdmlld0JveD0iMCAwIDEwIDciIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik04LjI1IDFMNCA1LjI1TDEuNzUgMyIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPC9zdmc+Cg==)}.___SOptionCheckbox_83krg_gg_._size_l_83krg_gg_{width:20px;height:20px}.___SOptionCheckbox_83krg_gg_._size_l_83krg_gg_::after{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iOSIgdmlld0JveD0iMCAwIDEyIDkiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik0xMSAxLjVMNC43NSA3Ljc1TDEgNCIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPC9zdmc+Cg==)}.___SOptionCheckbox_83krg_gg_.__checked_83krg_gg_:before,.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_:before{background-color:var(--intergalactic-control-primary-info, #008ff8);border-color:var(--intergalactic-control-primary-info, #008ff8)}.___SOptionCheckbox_83krg_gg_.__theme_83krg_gg_:before{border-color:var(--theme_83krg)}.___SOptionCheckbox_83krg_gg_.__theme_83krg_gg_.__checked_83krg_gg_:before{background-color:var(--theme_83krg);border-color:var(--theme_83krg)}.___SOptionCheckbox_83krg_gg_.__selected_83krg_gg_{background-color:var(--intergalactic-dropdown-menu-item-selected, rgba(196, 229, 254, 0.7))}@media (hover:hover){.___SOptionCheckbox_83krg_gg_.__selected_83krg_gg_:hover{background-color:var(--intergalactic-dropdown-menu-item-selected-hover, #c4e5fe)}}.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_:after{background-color:#fff;background-image:none;margin:auto;border-radius:1px}.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_._size_l_83krg_gg_:after{width:12px;height:2px}.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_._size_m_83krg_gg_:after{width:8px;height:2px}" /*__inner_css_end__*/, "83krg_gg_") /*__reshadow_css_end__*/, {
|
40
|
+
"__SOptionCheckbox": "___SOptionCheckbox_83krg_gg_",
|
41
|
+
"_checked": "__checked_83krg_gg_",
|
42
|
+
"_indeterminate": "__indeterminate_83krg_gg_",
|
43
|
+
"_theme": "__theme_83krg_gg_",
|
44
|
+
"--theme": "--theme_83krg",
|
45
|
+
"_size_l": "_size_l_83krg_gg_",
|
46
|
+
"_size_m": "_size_m_83krg_gg_",
|
47
|
+
"_selected": "__selected_83krg_gg_"
|
48
48
|
});
|
49
49
|
function isSelectedOption(value, valueOption) {
|
50
50
|
return Array.isArray(value) ? value.includes(valueOption) : valueOption === value;
|
@@ -19,12 +19,12 @@ import { selectContext } from './context';
|
|
19
19
|
import i18nEnhance from 'intergalactic/utils/lib/enhances/i18nEnhance';
|
20
20
|
import { localizedMessages } from './translations/__intergalactic-dynamic-locales';
|
21
21
|
/*__reshadow-styles__:"./style/input-search.shadow.css"*/
|
22
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
23
|
-
"__SInputSearch": "
|
24
|
-
"_size_m": "
|
25
|
-
"__SSearchClear": "
|
26
|
-
"_hide": "
|
27
|
-
"__SOutline": "
|
22
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SInputSearch_1a87i_gg_._size_m_1a87i_gg_{height:32px}.___SSearchClear_1a87i_gg_.__hide_1a87i_gg_{visibility:hidden}.___SOutline_1a87i_gg_{top:-1px;left:-1px;width:100%;border-radius:var(--intergalactic-control-rounded, 6px) var(--intergalactic-control-rounded, 6px)0 0}" /*__inner_css_end__*/, "1a87i_gg_") /*__reshadow_css_end__*/, {
|
23
|
+
"__SInputSearch": "___SInputSearch_1a87i_gg_",
|
24
|
+
"_size_m": "_size_m_1a87i_gg_",
|
25
|
+
"__SSearchClear": "___SSearchClear_1a87i_gg_",
|
26
|
+
"_hide": "__hide_1a87i_gg_",
|
27
|
+
"__SOutline": "___SOutline_1a87i_gg_"
|
28
28
|
});
|
29
29
|
var InputSearchRoot = /*#__PURE__*/function (_Component) {
|
30
30
|
_inherits(InputSearchRoot, _Component);
|
package/select/lib/es6/Select.js
CHANGED
@@ -33,15 +33,15 @@ import i18nEnhance from 'intergalactic/utils/lib/enhances/i18nEnhance';
|
|
33
33
|
import { localizedMessages } from './translations/__intergalactic-dynamic-locales';
|
34
34
|
import { setFocus } from 'intergalactic/utils/lib/use/useFocusLock';
|
35
35
|
/*__reshadow-styles__:"./style/select.shadow.css"*/
|
36
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
37
|
-
"__SOptionCheckbox": "
|
38
|
-
"_checked": "
|
39
|
-
"_indeterminate": "
|
40
|
-
"_theme": "
|
41
|
-
"--theme": "--
|
42
|
-
"_size_l": "
|
43
|
-
"_size_m": "
|
44
|
-
"_selected": "
|
36
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SOptionCheckbox_83krg_gg_{margin-top:var(--intergalactic-spacing-05x, 2px);margin-right:var(--intergalactic-spacing-2x, 8px);margin-bottom:auto;position:relative;flex-shrink:0;width:16px;height:16px}.___SOptionCheckbox_83krg_gg_::before{content:\"\";position:absolute;top:0;left:0;right:0;bottom:0;background:var(--intergalactic-bg-primary-neutral, #ffffff);border:1px solid;border-radius:var(--intergalactic-addon-rounded, 4px);border-color:var(--intergalactic-border-primary, #c4c7cf)}.___SOptionCheckbox_83krg_gg_::after{content:\"\";position:absolute;top:0;left:0;right:0;bottom:0;margin:0 var(--intergalactic-spacing-05x, 2px);background-repeat:no-repeat;background-position:center center;background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAiIGhlaWdodD0iNyIgdmlld0JveD0iMCAwIDEwIDciIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik04LjI1IDFMNCA1LjI1TDEuNzUgMyIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPC9zdmc+Cg==)}.___SOptionCheckbox_83krg_gg_._size_l_83krg_gg_{width:20px;height:20px}.___SOptionCheckbox_83krg_gg_._size_l_83krg_gg_::after{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iOSIgdmlld0JveD0iMCAwIDEyIDkiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik0xMSAxLjVMNC43NSA3Ljc1TDEgNCIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPC9zdmc+Cg==)}.___SOptionCheckbox_83krg_gg_.__checked_83krg_gg_:before,.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_:before{background-color:var(--intergalactic-control-primary-info, #008ff8);border-color:var(--intergalactic-control-primary-info, #008ff8)}.___SOptionCheckbox_83krg_gg_.__theme_83krg_gg_:before{border-color:var(--theme_83krg)}.___SOptionCheckbox_83krg_gg_.__theme_83krg_gg_.__checked_83krg_gg_:before{background-color:var(--theme_83krg);border-color:var(--theme_83krg)}.___SOptionCheckbox_83krg_gg_.__selected_83krg_gg_{background-color:var(--intergalactic-dropdown-menu-item-selected, rgba(196, 229, 254, 0.7))}@media (hover:hover){.___SOptionCheckbox_83krg_gg_.__selected_83krg_gg_:hover{background-color:var(--intergalactic-dropdown-menu-item-selected-hover, #c4e5fe)}}.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_:after{background-color:#fff;background-image:none;margin:auto;border-radius:1px}.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_._size_l_83krg_gg_:after{width:12px;height:2px}.___SOptionCheckbox_83krg_gg_.__indeterminate_83krg_gg_._size_m_83krg_gg_:after{width:8px;height:2px}" /*__inner_css_end__*/, "83krg_gg_") /*__reshadow_css_end__*/, {
|
37
|
+
"__SOptionCheckbox": "___SOptionCheckbox_83krg_gg_",
|
38
|
+
"_checked": "__checked_83krg_gg_",
|
39
|
+
"_indeterminate": "__indeterminate_83krg_gg_",
|
40
|
+
"_theme": "__theme_83krg_gg_",
|
41
|
+
"--theme": "--theme_83krg",
|
42
|
+
"_size_l": "_size_l_83krg_gg_",
|
43
|
+
"_size_m": "_size_m_83krg_gg_",
|
44
|
+
"_selected": "__selected_83krg_gg_"
|
45
45
|
});
|
46
46
|
function isSelectedOption(value, valueOption) {
|
47
47
|
return Array.isArray(value) ? value.includes(valueOption) : valueOption === value;
|
package/tag/index.d.ts
CHANGED
@@ -2,6 +2,7 @@ import React from 'react';
|
|
2
2
|
import { PropGetterFn, UnknownProperties, Intergalactic } from 'intergalactic/core';
|
3
3
|
import { BoxProps } from 'intergalactic/flex-box';
|
4
4
|
import { IconProps } from 'intergalactic/icon';
|
5
|
+
import { KeyboardFocusProps } from 'intergalactic/utils/lib/enhances/keyboardFocusEnhance';
|
5
6
|
|
6
7
|
export type TagSize = 'xl' | 'l' | 'm';
|
7
8
|
/** @deprecated */
|
@@ -18,38 +19,39 @@ export type TagUse = 'primary' | 'secondary';
|
|
18
19
|
|
19
20
|
/** @deprecated */
|
20
21
|
export interface ITagProps extends TagProps, UnknownProperties {}
|
21
|
-
export type TagProps = BoxProps &
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
22
|
+
export type TagProps = BoxProps &
|
23
|
+
KeyboardFocusProps & {
|
24
|
+
/** Value responsible for tag availability
|
25
|
+
*/
|
26
|
+
disabled?: boolean;
|
27
|
+
/** Value responsible for tag activity
|
28
|
+
*/
|
29
|
+
active?: boolean;
|
30
|
+
/** Interactive tag
|
31
|
+
*/
|
32
|
+
interactive?: boolean;
|
33
|
+
/** Tag type
|
34
|
+
* @default secondary
|
35
|
+
* @deprecated v4.0.0
|
36
|
+
* @use ITagProps.theme
|
37
|
+
*/
|
38
|
+
use?: TagUse;
|
39
|
+
/** Tag theme, there are several default themes or you can use your color
|
40
|
+
* @default primary
|
41
|
+
*/
|
42
|
+
theme?: TagTheme;
|
43
|
+
/** Tag color text */
|
44
|
+
color?: string;
|
45
|
+
/** Tag size
|
46
|
+
* @default m
|
47
|
+
*/
|
48
|
+
size?: TagSize;
|
49
|
+
/** Left addon tag */
|
50
|
+
addonLeft?: React.ElementType;
|
51
|
+
/** Right addon tag */
|
52
|
+
addonRight?: React.ElementType;
|
53
|
+
locale?: string;
|
54
|
+
};
|
53
55
|
|
54
56
|
/** @deprecated */
|
55
57
|
export interface ITagCloseProps extends TagCloseProps, UnknownProperties {}
|
@@ -76,7 +78,7 @@ export type TagAddonProps = BoxProps & {};
|
|
76
78
|
|
77
79
|
/** @deprecated */
|
78
80
|
export interface ITagTextProps extends TagTextProps, UnknownProperties {}
|
79
|
-
export type TagTextProps = BoxProps & {};
|
81
|
+
export type TagTextProps = BoxProps & KeyboardFocusProps & {};
|
80
82
|
|
81
83
|
declare const Tag: Intergalactic.Component<'div', TagProps, TagContext> & {
|
82
84
|
Text: Intergalactic.Component<'div', TagTextProps>;
|
package/tag/lib/cjs/Tag.js
CHANGED
@@ -23,27 +23,29 @@ var _intergalacticDynamicLocales = require("./translations/__intergalactic-dynam
|
|
23
23
|
var _i18nEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/i18nEnhance"));
|
24
24
|
var _resolveColorEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/resolveColorEnhance"));
|
25
25
|
var _uniqueID = _interopRequireDefault(require("intergalactic/utils/lib/uniqueID"));
|
26
|
+
var _keyboardFocusEnhance = _interopRequireDefault(require("intergalactic/utils/lib/enhances/keyboardFocusEnhance"));
|
26
27
|
var _assignProps6 = require("intergalactic/utils/lib/assignProps");
|
27
28
|
/*__reshadow-styles__:"./style/tag.shadow.css"*/
|
28
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
29
|
-
"__STag": "
|
30
|
-
"
|
31
|
-
"
|
32
|
-
"
|
33
|
-
"
|
34
|
-
"
|
35
|
-
"
|
36
|
-
"
|
37
|
-
"
|
38
|
-
"
|
39
|
-
"
|
40
|
-
"
|
41
|
-
"
|
42
|
-
"
|
43
|
-
"
|
44
|
-
"
|
45
|
-
"
|
46
|
-
"
|
29
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___STag_1egau_gg_{position:relative;display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;border:1px solid var(--intergalactic-bg-primary-neutral, #ffffff);box-sizing:border-box;background-color:var(--intergalactic-bg-primary-neutral, #ffffff);border-radius:var(--intergalactic-tag-rounded, 24px);padding-left:var(--intergalactic-spacing-1x, 4px);padding-right:var(--intergalactic-spacing-1x, 4px);font-weight:var(--intergalactic-medium, 500);color:var(--tag-color_1egau)}.___STag_1egau_gg_:has(.___SText_1egau_gg_:focus){box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5))}.___STag_1egau_gg_::after,.___STag_1egau_gg_::before{content:\"\";position:absolute;border-radius:var(--intergalactic-tag-rounded, 24px);filter:brightness(150%)}.___STag_1egau_gg_::before{top:0;left:0;right:0;bottom:0;background-color:var(--tag-color_1egau);opacity:.2}.___STag_1egau_gg_::after{top:-1px;left:-1px;right:-1px;bottom:-1px;pointer-events:none;border:1px solid var(--tag-color_1egau);opacity:.1}.___STag_1egau_gg_:active,.___STag_1egau_gg_:focus{outline:0;-webkit-text-decoration:none;text-decoration:none}@media (hover:hover){.___STag_1egau_gg_:hover{outline:0;-webkit-text-decoration:none;text-decoration:none}}.___STag_1egau_gg_.__keyboardFocused_1egau_gg_{box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));z-index:1}.___STag_1egau_gg_.__keyboardFocused_1egau_gg_:has(:focus){box-shadow:none}.___STag_1egau_gg_.__disabled_1egau_gg_{opacity:var(--intergalactic-disabled-opacity, 0.3);cursor:default;pointer-events:none}.___STag_1egau_gg_.__interactive_1egau_gg_{cursor:pointer}.___STag_1egau_gg_._size_m_1egau_gg_{height:20px;min-width:20px}.___STag_1egau_gg_._size_m_1egau_gg_ .___SCircle_1egau_gg_:first-child{margin-left:calc(-1*var(--intergalactic-spacing-05x, 2px))}.___STag_1egau_gg_._size_m_1egau_gg_ .___SCircle_1egau_gg_:last-child{margin-right:calc(-1*var(--intergalactic-spacing-05x, 2px))}.___STag_1egau_gg_._size_m_1egau_gg_ .___SText_1egau_gg_{font-size:var(--intergalactic-fs-100, 12px);line-height:var(--intergalactic-lh-100, 133%)}.___STag_1egau_gg_._size_l_1egau_gg_{height:28px;min-width:28px}.___STag_1egau_gg_._size_l_1egau_gg_ .___SText_1egau_gg_{font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%)}.___STag_1egau_gg_._size_xl_1egau_gg_{height:40px;min-width:40px}.___STag_1egau_gg_._size_xl_1egau_gg_ .___SText_1egau_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%)}.___STag_1egau_gg_._theme_primary_1egau_gg_::before{top:-1px;left:-1px;right:-1px;bottom:-1px}.___STag_1egau_gg_._theme_primary_1egau_gg_:after{display:none}.___STag_1egau_gg_._theme_primary_1egau_gg_.__active_1egau_gg_:before,.___STag_1egau_gg_._theme_primary_1egau_gg_.__interactive_1egau_gg_:active:before{opacity:.3}@media (hover:hover){.___STag_1egau_gg_._theme_primary_1egau_gg_.__interactive_1egau_gg_:hover:before{opacity:.3}}.___STag_1egau_gg_._theme_additional_1egau_gg_::before,.___STag_1egau_gg_._theme_secondary_1egau_gg_::before{opacity:.01}.___STag_1egau_gg_._theme_additional_1egau_gg_.__active_1egau_gg_:before,.___STag_1egau_gg_._theme_additional_1egau_gg_.__interactive_1egau_gg_:active:before,.___STag_1egau_gg_._theme_secondary_1egau_gg_.__active_1egau_gg_:before,.___STag_1egau_gg_._theme_secondary_1egau_gg_.__interactive_1egau_gg_:active:before{opacity:.1}@media (hover:hover){.___STag_1egau_gg_._theme_additional_1egau_gg_.__interactive_1egau_gg_:hover:before,.___STag_1egau_gg_._theme_secondary_1egau_gg_.__interactive_1egau_gg_:hover:before{opacity:.1}}.___SClose_1egau_gg_ path,.___STag_1egau_gg_._theme_additional-invert_1egau_gg_::after,.___STag_1egau_gg_._theme_additional_1egau_gg_::after,.___STag_1egau_gg_._theme_secondary-invert_1egau_gg_::after,.___STag_1egau_gg_._theme_secondary_1egau_gg_::after{opacity:.5}.___STag_1egau_gg_._theme_primary-invert_1egau_gg_{background-color:var(--intergalactic-tag-primary-white-normal, rgba(255, 255, 255, 0.15))}.___STag_1egau_gg_._theme_additional-invert_1egau_gg_,.___STag_1egau_gg_._theme_primary-invert_1egau_gg_,.___STag_1egau_gg_._theme_secondary-invert_1egau_gg_{color:var(--intergalactic-text-primary-invert, #ffffff)}.___STag_1egau_gg_._theme_additional_1egau_gg_::after{border-style:dashed}.___SText_1egau_gg_{display:inline-block;padding-left:var(--intergalactic-spacing-1x, 4px);padding-right:var(--intergalactic-spacing-1x, 4px);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;outline:0;position:relative}.___SText_1egau_gg_.__keyboardFocused_1egau_gg_{box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));z-index:1}.___SText_1egau_gg_:not(:only-child):first-child{padding-right:0}.___SText_1egau_gg_:not(:first-child):not(:last-child){padding-left:0;padding-right:0}.___SText_1egau_gg_:not(:only-child):last-child{padding-left:0}.___SAddon_1egau_gg_,.___SCircle_1egau_gg_{display:inline-flex;align-items:center;justify-content:center}.___SAddon_1egau_gg_{flex-shrink:0;padding-left:var(--intergalactic-spacing-1x, 4px);padding-right:var(--intergalactic-spacing-1x, 4px);position:relative}.___SCircle_1egau_gg_{overflow:hidden;border-radius:50%;margin:0 var(--intergalactic-spacing-1x, 4px)}.___SCircle_1egau_gg_:first-child{margin-left:0}.___SCircle_1egau_gg_:last-child{margin-right:0}.___SCircle_1egau_gg_._size_m_1egau_gg_{width:16px;height:16px}.___SCircle_1egau_gg_._size_l_1egau_gg_,.___SCircle_1egau_gg_._size_xl_1egau_gg_{width:20px;height:20px}.___SClose_1egau_gg_{cursor:pointer;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:var(--intergalactic-spacing-1x, 4px)}@media (hover:hover){.___SClose_1egau_gg_:hover path{opacity:1}}" /*__inner_css_end__*/, "1egau_gg_") /*__reshadow_css_end__*/, {
|
30
|
+
"__STag": "___STag_1egau_gg_",
|
31
|
+
"_keyboardFocused": "__keyboardFocused_1egau_gg_",
|
32
|
+
"_disabled": "__disabled_1egau_gg_",
|
33
|
+
"_interactive": "__interactive_1egau_gg_",
|
34
|
+
"_theme_primary-invert": "_theme_primary-invert_1egau_gg_",
|
35
|
+
"_theme_secondary-invert": "_theme_secondary-invert_1egau_gg_",
|
36
|
+
"_theme_additional-invert": "_theme_additional-invert_1egau_gg_",
|
37
|
+
"__SText": "___SText_1egau_gg_",
|
38
|
+
"__SAddon": "___SAddon_1egau_gg_",
|
39
|
+
"__SCircle": "___SCircle_1egau_gg_",
|
40
|
+
"_size_m": "_size_m_1egau_gg_",
|
41
|
+
"_size_l": "_size_l_1egau_gg_",
|
42
|
+
"_size_xl": "_size_xl_1egau_gg_",
|
43
|
+
"--tag-color": "--tag-color_1egau",
|
44
|
+
"_theme_primary": "_theme_primary_1egau_gg_",
|
45
|
+
"_active": "__active_1egau_gg_",
|
46
|
+
"_theme_secondary": "_theme_secondary_1egau_gg_",
|
47
|
+
"_theme_additional": "_theme_additional_1egau_gg_",
|
48
|
+
"__SClose": "___SClose_1egau_gg_"
|
47
49
|
});
|
48
50
|
var legacyThemeRecommendedMigration = {
|
49
51
|
primary: {
|
@@ -65,13 +67,27 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
65
67
|
var _this;
|
66
68
|
(0, _classCallCheck2["default"])(this, RootTag);
|
67
69
|
_this = _super.call(this, props);
|
68
|
-
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "
|
69
|
-
|
70
|
-
|
71
|
-
|
70
|
+
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "state", {
|
71
|
+
focusable: 'container'
|
72
|
+
});
|
73
|
+
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "handleCloseMount", function () {
|
74
|
+
_this.setState({
|
75
|
+
focusable: 'text'
|
76
|
+
});
|
77
|
+
});
|
78
|
+
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "handleCloseUnmount", function () {
|
79
|
+
_this.setState({
|
80
|
+
focusable: 'container'
|
81
|
+
});
|
82
|
+
});
|
83
|
+
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "handleKeyDown", function (event) {
|
84
|
+
switch (event.code) {
|
85
|
+
case 'Space':
|
72
86
|
case 'Enter':
|
73
|
-
|
74
|
-
|
87
|
+
if (_this.asProps.onClick) {
|
88
|
+
event.preventDefault();
|
89
|
+
_this.asProps.onClick(event);
|
90
|
+
}
|
75
91
|
break;
|
76
92
|
}
|
77
93
|
});
|
@@ -86,17 +102,30 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
86
102
|
size: size
|
87
103
|
};
|
88
104
|
}
|
105
|
+
}, {
|
106
|
+
key: "getTextProps",
|
107
|
+
value: function getTextProps() {
|
108
|
+
var interactive = this.asProps.interactive;
|
109
|
+
var id = this.asProps.id || "igc-".concat(this.asProps.uid, "-tag");
|
110
|
+
var focusable = this.state.focusable;
|
111
|
+
return {
|
112
|
+
tabIndex: focusable === 'text' && interactive ? 0 : -1,
|
113
|
+
id: "".concat(id, "-text")
|
114
|
+
};
|
115
|
+
}
|
89
116
|
}, {
|
90
117
|
key: "getCloseProps",
|
91
118
|
value: function getCloseProps() {
|
92
|
-
var
|
93
|
-
|
94
|
-
id = _this$asProps2.id,
|
95
|
-
uid = _this$asProps2.uid;
|
119
|
+
var getI18nText = this.asProps.getI18nText;
|
120
|
+
var id = this.asProps.id || "igc-".concat(this.asProps.uid, "-tag");
|
96
121
|
return {
|
97
122
|
getI18nText: getI18nText,
|
98
|
-
|
99
|
-
|
123
|
+
id: "".concat(id, "-clear"),
|
124
|
+
'aria-labelledby': "".concat(id, "-clear ").concat(id, "-text"),
|
125
|
+
'aria-label': getI18nText('remove'),
|
126
|
+
'aria-hidden': 'true',
|
127
|
+
onMount: this.handleCloseMount,
|
128
|
+
onUnmount: this.handleCloseUnmount
|
100
129
|
};
|
101
130
|
}
|
102
131
|
}, {
|
@@ -105,26 +134,27 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
105
134
|
var _ref = this.asProps,
|
106
135
|
_ref6;
|
107
136
|
var STag = _flexBox.Box;
|
108
|
-
var _this$
|
109
|
-
Children = _this$
|
110
|
-
styles = _this$
|
111
|
-
color = _this$
|
112
|
-
interactive = _this$
|
113
|
-
disabled = _this$
|
114
|
-
addonLeft = _this$
|
115
|
-
addonRight = _this$
|
116
|
-
resolveColor = _this$
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
137
|
+
var _this$asProps = this.asProps,
|
138
|
+
Children = _this$asProps.Children,
|
139
|
+
styles = _this$asProps.styles,
|
140
|
+
color = _this$asProps.color,
|
141
|
+
interactive = _this$asProps.interactive,
|
142
|
+
disabled = _this$asProps.disabled,
|
143
|
+
addonLeft = _this$asProps.addonLeft,
|
144
|
+
addonRight = _this$asProps.addonRight,
|
145
|
+
resolveColor = _this$asProps.resolveColor,
|
146
|
+
outerId = _this$asProps.id,
|
147
|
+
uid = _this$asProps.uid,
|
148
|
+
onKeyDown = _this$asProps.onKeyDown;
|
149
|
+
var focusable = this.state.focusable;
|
121
150
|
var id = outerId || "igc-".concat(uid, "-tag");
|
122
151
|
return _ref6 = (0, _core.sstyled)(styles), /*#__PURE__*/_react["default"].createElement(STag, _ref6.cn("STag", (0, _objectSpread2["default"])({}, (0, _core.assignProps)({
|
123
152
|
"id": id,
|
124
153
|
"use:interactive": !disabled && interactive,
|
125
|
-
"
|
154
|
+
"role": interactive ? 'button' : undefined,
|
126
155
|
"tag-color": resolveColor(color),
|
127
|
-
"onKeyDown": (0, _assignProps6.callAllEventHandlers)(onKeyDown, this.handleKeyDown)
|
156
|
+
"onKeyDown": (0, _assignProps6.callAllEventHandlers)(onKeyDown, this.handleKeyDown),
|
157
|
+
"use:tabIndex": interactive && focusable === 'container' ? 0 : -1
|
128
158
|
}, _ref))), addonLeft ? /*#__PURE__*/_react["default"].createElement(Tag.Addon, {
|
129
159
|
tag: addonLeft
|
130
160
|
}) : null, (0, _addonTextChildren["default"])(Children, Tag.Text, Tag.Addon), addonRight ? /*#__PURE__*/_react["default"].createElement(Tag.Addon, {
|
@@ -136,7 +166,7 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
136
166
|
}(_core.Component);
|
137
167
|
(0, _defineProperty2["default"])(RootTag, "displayName", 'Tag');
|
138
168
|
(0, _defineProperty2["default"])(RootTag, "style", style);
|
139
|
-
(0, _defineProperty2["default"])(RootTag, "enhance", [(0, _i18nEnhance["default"])(_intergalacticDynamicLocales.localizedMessages), (0, _uniqueID["default"])(), (0, _resolveColorEnhance["default"])()]);
|
169
|
+
(0, _defineProperty2["default"])(RootTag, "enhance", [(0, _i18nEnhance["default"])(_intergalacticDynamicLocales.localizedMessages), (0, _uniqueID["default"])(), (0, _resolveColorEnhance["default"])(), (0, _keyboardFocusEnhance["default"])()]);
|
140
170
|
(0, _defineProperty2["default"])(RootTag, "defaultProps", {
|
141
171
|
theme: 'primary',
|
142
172
|
color: 'gray-500',
|
@@ -153,15 +183,21 @@ function Text(props) {
|
|
153
183
|
"tag": 'span'
|
154
184
|
}, _ref2))));
|
155
185
|
}
|
186
|
+
Text.enhance = [(0, _keyboardFocusEnhance["default"])()];
|
156
187
|
function Close(props) {
|
157
188
|
var _ref3 = arguments[0],
|
158
189
|
_ref8;
|
159
190
|
var SClose = _flexBox.Box;
|
160
|
-
var styles = props.styles
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
191
|
+
var styles = props.styles;
|
192
|
+
_react["default"].useEffect(function () {
|
193
|
+
var _props$onMount;
|
194
|
+
(_props$onMount = props.onMount) === null || _props$onMount === void 0 ? void 0 : _props$onMount.call(props);
|
195
|
+
return function () {
|
196
|
+
var _props$onUnmount;
|
197
|
+
return (_props$onUnmount = props.onUnmount) === null || _props$onUnmount === void 0 ? void 0 : _props$onUnmount.call(props);
|
198
|
+
};
|
199
|
+
}, []);
|
200
|
+
var onKeyDown = _react["default"].useCallback(function (event) {
|
165
201
|
if (props.onKeyDown) {
|
166
202
|
return props.onKeyDown(event);
|
167
203
|
}
|
@@ -169,13 +205,10 @@ function Close(props) {
|
|
169
205
|
event.preventDefault();
|
170
206
|
props.onClick(event);
|
171
207
|
}
|
172
|
-
}
|
208
|
+
}, [props.onKeyDown, props.onClick]);
|
173
209
|
return _ref8 = (0, _core.sstyled)(styles), /*#__PURE__*/_react["default"].createElement(SClose, _ref8.cn("SClose", (0, _objectSpread2["default"])({}, (0, _core.assignProps)({
|
174
210
|
"tag": _m["default"],
|
175
211
|
"interactive": true,
|
176
|
-
"id": "igc-".concat(uid, "-tag-clear"),
|
177
|
-
"aria-labelledby": "igc-".concat(uid, "-tag-clear ").concat(tagId),
|
178
|
-
"aria-label": getI18nText('remove'),
|
179
212
|
"onKeyDown": onKeyDown
|
180
213
|
}, _ref3))));
|
181
214
|
}
|