intergalactic 15.99.0-prerelease.1 → 15.100.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 +18 -0
- package/button/lib/cjs/Button.js +26 -26
- package/button/lib/es6/Button.js +26 -26
- package/card/lib/cjs/Card.js +8 -8
- package/card/lib/es6/Card.js +8 -8
- package/carousel/lib/cjs/Carousel.js +21 -21
- package/carousel/lib/es6/Carousel.js +21 -21
- package/color-picker/lib/cjs/ColorPicker.js +23 -23
- package/color-picker/lib/cjs/PaletteManager.js +23 -23
- package/color-picker/lib/cjs/components/InputColor.js +23 -23
- package/color-picker/lib/es6/ColorPicker.js +23 -23
- package/color-picker/lib/es6/PaletteManager.js +23 -23
- package/color-picker/lib/es6/components/InputColor.js +23 -23
- package/components.json +16 -16
- package/data-table/lib/cjs/Body.js +8 -2
- package/data-table/lib/cjs/Body.js.map +1 -1
- package/data-table/lib/cjs/DataTable.js +37 -37
- package/data-table/lib/cjs/style/scroll-shadows.shadow.css +7 -0
- package/data-table/lib/es6/Body.js +8 -2
- package/data-table/lib/es6/Body.js.map +1 -1
- package/data-table/lib/es6/DataTable.js +37 -37
- package/data-table/lib/es6/style/scroll-shadows.shadow.css +7 -0
- package/date-picker/lib/cjs/components/Calendar.js +21 -21
- package/date-picker/lib/cjs/components/DateRangeComparatorAbstract.js +29 -29
- package/date-picker/lib/cjs/components/InputTrigger.js +29 -29
- package/date-picker/lib/cjs/components/PickerAbstract.js +29 -29
- package/date-picker/lib/cjs/components/RangePickerAbstract.js +29 -29
- package/date-picker/lib/es6/components/Calendar.js +21 -21
- package/date-picker/lib/es6/components/DateRangeComparatorAbstract.js +29 -29
- package/date-picker/lib/es6/components/InputTrigger.js +29 -29
- package/date-picker/lib/es6/components/PickerAbstract.js +29 -29
- package/date-picker/lib/es6/components/RangePickerAbstract.js +29 -29
- package/drag-and-drop/lib/cjs/DragAndDrop.js +16 -16
- package/drag-and-drop/lib/es6/DragAndDrop.js +16 -16
- package/ellipsis/lib/cjs/Ellipsis.js +10 -10
- package/ellipsis/lib/es6/Ellipsis.js +10 -10
- package/errors/lib/cjs/Error.js +9 -9
- package/errors/lib/es6/Error.js +9 -9
- package/feedback-form/lib/cjs/FeedbackForm.js +7 -7
- package/feedback-form/lib/cjs/component/checkbox-button/CheckboxButton.js +3 -3
- package/feedback-form/lib/cjs/component/feedback-rating/FeedbackRating.js +2 -2
- package/feedback-form/lib/cjs/component/slider-rating/SliderRating.js +6 -6
- package/feedback-form/lib/es6/FeedbackForm.js +7 -7
- package/feedback-form/lib/es6/component/checkbox-button/CheckboxButton.js +3 -3
- package/feedback-form/lib/es6/component/feedback-rating/FeedbackRating.js +2 -2
- package/feedback-form/lib/es6/component/slider-rating/SliderRating.js +6 -6
- package/inline-edit/lib/cjs/InlineEdit.js +3 -3
- package/inline-edit/lib/cjs/InlineEdit.js.map +1 -1
- package/inline-edit/lib/cjs/translations/en.json +1 -1
- package/inline-edit/lib/es6/InlineEdit.js +3 -3
- package/inline-edit/lib/es6/InlineEdit.js.map +1 -1
- package/inline-edit/lib/es6/translations/en.json +1 -1
- package/inline-input/lib/cjs/InlineInput.js +14 -14
- package/inline-input/lib/es6/InlineInput.js +14 -14
- package/link/lib/cjs/Link.js +12 -12
- package/link/lib/es6/Link.js +12 -12
- package/notice-bubble/lib/cjs/NoticeBubble.js +42 -23
- package/notice-bubble/lib/cjs/NoticeBubble.js.map +1 -1
- package/notice-bubble/lib/cjs/style/notice-bubble.shadow.css +17 -9
- package/notice-bubble/lib/es6/NoticeBubble.js +42 -23
- package/notice-bubble/lib/es6/NoticeBubble.js.map +1 -1
- package/notice-bubble/lib/es6/style/notice-bubble.shadow.css +17 -9
- package/package.json +1 -1
- package/pagination/lib/cjs/Pagination.js +10 -10
- package/pagination/lib/es6/Pagination.js +10 -10
- package/tag/index.d.ts +14 -0
- package/tag/lib/cjs/Tag.js +187 -45
- package/tag/lib/cjs/Tag.js.map +1 -1
- package/tag/lib/cjs/index.d.js.map +1 -1
- package/tag/lib/cjs/index.js +8 -2
- package/tag/lib/cjs/index.js.map +1 -1
- package/tag/lib/cjs/style/tag.shadow.css +100 -27
- package/tag/lib/cjs/translations/en.json +1 -1
- package/tag/lib/es6/Tag.js +188 -44
- package/tag/lib/es6/Tag.js.map +1 -1
- package/tag/lib/es6/index.d.js.map +1 -1
- package/tag/lib/es6/index.js +1 -1
- package/tag/lib/es6/index.js.map +1 -1
- package/tag/lib/es6/style/tag.shadow.css +100 -27
- package/tag/lib/es6/translations/en.json +1 -1
- package/tag/lib/types/index.d.ts +14 -0
- package/time-picker/lib/cjs/TimePicker.js +12 -12
- package/time-picker/lib/es6/TimePicker.js +12 -12
- package/tooltip/index.d.ts +9 -3
- package/tooltip/lib/cjs/Tooltip.js +18 -10
- package/tooltip/lib/cjs/Tooltip.js.map +1 -1
- package/tooltip/lib/cjs/index.d.js.map +1 -1
- package/tooltip/lib/cjs/style/tooltip.shadow.css +8 -0
- package/tooltip/lib/es6/Tooltip.js +18 -10
- package/tooltip/lib/es6/Tooltip.js.map +1 -1
- package/tooltip/lib/es6/index.d.js.map +1 -1
- package/tooltip/lib/es6/style/tooltip.shadow.css +8 -0
- package/tooltip/lib/types/index.d.ts +9 -3
@@ -1,4 +1,5 @@
|
|
1
|
-
STag
|
1
|
+
STag,
|
2
|
+
STagContainerClose {
|
2
3
|
position: relative;
|
3
4
|
display: inline-flex;
|
4
5
|
align-items: center;
|
@@ -13,8 +14,9 @@ STag {
|
|
13
14
|
font-weight: var(--intergalactic-medium, 500);
|
14
15
|
color: var(--tag-color);
|
15
16
|
|
16
|
-
&[interactive]
|
17
|
+
&[interactive][keyboardFocused] {
|
17
18
|
box-shadow: var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));
|
19
|
+
z-index: 1;
|
18
20
|
}
|
19
21
|
|
20
22
|
&::before {
|
@@ -52,27 +54,19 @@ STag {
|
|
52
54
|
}
|
53
55
|
}
|
54
56
|
|
55
|
-
STag[
|
56
|
-
|
57
|
-
z-index: 1;
|
58
|
-
}
|
59
|
-
|
60
|
-
STag[interactive][keyboardFocused]:has(:focus) {
|
61
|
-
box-shadow: none;
|
62
|
-
}
|
63
|
-
|
64
|
-
|
65
|
-
STag[disabled] {
|
57
|
+
STag[disabled],
|
58
|
+
STagContainerClose[disabled] {
|
66
59
|
opacity: var(--intergalactic-disabled-opacity, 0.3);
|
67
60
|
cursor: default;
|
68
61
|
pointer-events: none;
|
69
62
|
}
|
70
63
|
|
71
|
-
STag[
|
64
|
+
STag[interactiveView] {
|
72
65
|
cursor: pointer;
|
73
66
|
}
|
74
67
|
|
75
|
-
STag[size='m']
|
68
|
+
STag[size='m'],
|
69
|
+
STagContainerClose[size='m'] {
|
76
70
|
height: 20px;
|
77
71
|
min-width: 20px;
|
78
72
|
|
@@ -90,7 +84,8 @@ STag[size='m'] {
|
|
90
84
|
}
|
91
85
|
}
|
92
86
|
|
93
|
-
STag[size='l']
|
87
|
+
STag[size='l'],
|
88
|
+
STagContainerClose[size='l'] {
|
94
89
|
height: 28px;
|
95
90
|
min-width: 28px;
|
96
91
|
|
@@ -100,9 +95,11 @@ STag[size='l'] {
|
|
100
95
|
}
|
101
96
|
}
|
102
97
|
|
103
|
-
STag[size='xl']
|
98
|
+
STag[size='xl'],
|
99
|
+
STagContainerClose[size='xl'] {
|
104
100
|
height: 40px;
|
105
101
|
min-width: 40px;
|
102
|
+
padding: 0 var(--intergalactic-spacing-2x, 8px);
|
106
103
|
|
107
104
|
& SText {
|
108
105
|
font-size: var(--intergalactic-fs-300, 16px);
|
@@ -110,7 +107,8 @@ STag[size='xl'] {
|
|
110
107
|
}
|
111
108
|
}
|
112
109
|
|
113
|
-
STag[theme='primary']
|
110
|
+
STag[theme='primary'],
|
111
|
+
STagContainerClose[theme='primary'] {
|
114
112
|
&::before {
|
115
113
|
top: -1px;
|
116
114
|
left: -1px;
|
@@ -122,8 +120,8 @@ STag[theme='primary'] {
|
|
122
120
|
display: none;
|
123
121
|
}
|
124
122
|
|
125
|
-
&[
|
126
|
-
&[
|
123
|
+
&[interactiveView]:hover,
|
124
|
+
&[interactiveView]:active,
|
127
125
|
&[active] {
|
128
126
|
&:before {
|
129
127
|
opacity: 0.3;
|
@@ -132,13 +130,15 @@ STag[theme='primary'] {
|
|
132
130
|
}
|
133
131
|
|
134
132
|
STag[theme='secondary'],
|
135
|
-
|
133
|
+
STagContainerClose[theme='secondary'],
|
134
|
+
STag[theme='additional'],
|
135
|
+
STagContainerClose[theme='additional'] {
|
136
136
|
&::before {
|
137
137
|
opacity: 0.01;
|
138
138
|
}
|
139
139
|
|
140
|
-
&[
|
141
|
-
&[
|
140
|
+
&[interactiveView]:hover,
|
141
|
+
&[interactiveView]:active,
|
142
142
|
&[active] {
|
143
143
|
&:before {
|
144
144
|
opacity: 0.1;
|
@@ -147,21 +147,28 @@ STag[theme='additional'] {
|
|
147
147
|
}
|
148
148
|
|
149
149
|
STag[theme='secondary'],
|
150
|
+
STagContainerClose[theme='secondary'],
|
150
151
|
STag[theme='additional'],
|
152
|
+
STagContainerClose[theme='additional'],
|
151
153
|
STag[theme='secondary-invert'],
|
152
|
-
|
154
|
+
STagContainerClose[theme='secondary-invert'],
|
155
|
+
STag[theme='additional-invert'],
|
156
|
+
STagContainerClose[theme='additional-invert'] {
|
153
157
|
&::after {
|
154
158
|
opacity: 0.5;
|
155
159
|
}
|
156
160
|
}
|
157
161
|
|
158
|
-
STag[theme='primary-invert']
|
162
|
+
STag[theme='primary-invert'],
|
163
|
+
STagContainerClose[theme='primary-invert'] {
|
159
164
|
background-color: var(--intergalactic-tag-primary-white-normal, rgba(255, 255, 255, 0.15));
|
160
165
|
color: var(--intergalactic-text-primary-invert, #ffffff);
|
161
166
|
}
|
162
167
|
|
163
168
|
STag[theme='secondary-invert'],
|
164
|
-
|
169
|
+
STagContainerClose[theme='secondary-invert'],
|
170
|
+
STag[theme='additional-invert'],
|
171
|
+
STagContainerClose[theme='additional-invert'] {
|
165
172
|
color: var(--intergalactic-text-primary-invert, #ffffff);
|
166
173
|
}
|
167
174
|
|
@@ -182,7 +189,7 @@ SText {
|
|
182
189
|
position: relative;
|
183
190
|
}
|
184
191
|
|
185
|
-
|
192
|
+
SText[keyboardFocused] {
|
186
193
|
box-shadow: var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));
|
187
194
|
z-index: 1;
|
188
195
|
}
|
@@ -258,4 +265,70 @@ SClose {
|
|
258
265
|
&:hover path {
|
259
266
|
opacity: 1;
|
260
267
|
}
|
268
|
+
}
|
269
|
+
|
270
|
+
STagContainer {
|
271
|
+
display: inline-flex;
|
272
|
+
position: relative;
|
273
|
+
align-items: center;
|
274
|
+
justify-content: center;
|
275
|
+
|
276
|
+
STag {
|
277
|
+
border-top-right-radius: 0;
|
278
|
+
border-bottom-right-radius: 0;
|
279
|
+
padding-right: var(--intergalactic-spacing-05x, 2px);
|
280
|
+
|
281
|
+
&::before,
|
282
|
+
&::after {
|
283
|
+
border-right: 0;
|
284
|
+
border-top-right-radius: 0;
|
285
|
+
border-bottom-right-radius: 0;
|
286
|
+
margin-right: -1px;
|
287
|
+
}
|
288
|
+
|
289
|
+
SText {
|
290
|
+
padding-right: 0;
|
291
|
+
}
|
292
|
+
}
|
293
|
+
|
294
|
+
STagContainerClose {
|
295
|
+
cursor: pointer;
|
296
|
+
border-top-left-radius: 0;
|
297
|
+
border-bottom-left-radius: 0;
|
298
|
+
padding-left: 0;
|
299
|
+
padding-right: 0;
|
300
|
+
min-width: 20px;
|
301
|
+
|
302
|
+
&::before,
|
303
|
+
&::after {
|
304
|
+
border-left: 0;
|
305
|
+
border-top-left-radius: 0;
|
306
|
+
border-bottom-left-radius: 0;
|
307
|
+
}
|
308
|
+
|
309
|
+
&::before {
|
310
|
+
left: -1px;
|
311
|
+
}
|
312
|
+
|
313
|
+
svg {
|
314
|
+
padding-left: 0;
|
315
|
+
padding-right: var(--intergalactic-spacing-1x, 4px);
|
316
|
+
}
|
317
|
+
|
318
|
+
svg path {
|
319
|
+
opacity: 0.5;
|
320
|
+
}
|
321
|
+
|
322
|
+
&:hover svg path {
|
323
|
+
opacity: 1;
|
324
|
+
}
|
325
|
+
}
|
326
|
+
|
327
|
+
STagContainerClose[size='xl'] {
|
328
|
+
svg {
|
329
|
+
padding-left: var(--intergalactic-spacing-1x, 4px);
|
330
|
+
padding-right: var(--intergalactic-spacing-2x, 8px);
|
331
|
+
}
|
332
|
+
|
333
|
+
}
|
261
334
|
}
|
package/tag/lib/es6/Tag.js
CHANGED
@@ -6,6 +6,8 @@ import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
6
|
import _createSuper from "@babel/runtime/helpers/createSuper";
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
8
8
|
import { sstyled as _sstyled } from 'intergalactic/utils/lib/core/index';
|
9
|
+
import { assignProps as _assignProps7 } from 'intergalactic/core';
|
10
|
+
import { assignProps as _assignProps6 } from 'intergalactic/core';
|
9
11
|
import { assignProps as _assignProps5 } from 'intergalactic/core';
|
10
12
|
import { assignProps as _assignProps4 } from 'intergalactic/core';
|
11
13
|
import { assignProps as _assignProps3 } from 'intergalactic/core';
|
@@ -22,29 +24,32 @@ import i18nEnhance from 'intergalactic/utils/lib/enhances/i18nEnhance';
|
|
22
24
|
import resolveColorEnhance from 'intergalactic/utils/lib/enhances/resolveColorEnhance';
|
23
25
|
import uniqueIDEnhancement from 'intergalactic/utils/lib/uniqueID';
|
24
26
|
import keyboardFocusEnhance from 'intergalactic/utils/lib/enhances/keyboardFocusEnhance';
|
27
|
+
import log from 'intergalactic/utils/lib/logger';
|
25
28
|
/*__reshadow-styles__:"./style/tag.shadow.css"*/
|
26
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
27
|
-
"__STag": "
|
28
|
-
"
|
29
|
-
"
|
30
|
-
"
|
31
|
-
"_theme_primary-invert": "_theme_primary-
|
32
|
-
"_theme_secondary-invert": "_theme_secondary-
|
33
|
-
"_theme_additional-invert": "_theme_additional-
|
34
|
-
"__SText": "
|
35
|
-
"
|
36
|
-
"
|
37
|
-
"
|
38
|
-
"
|
39
|
-
"
|
40
|
-
"
|
41
|
-
"
|
42
|
-
"
|
43
|
-
"
|
44
|
-
"
|
45
|
-
"
|
29
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___STagContainerClose_9qjw2_gg_,.___STag_9qjw2_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_9qjw2)}.___STagContainerClose_9qjw2_gg_.__interactive_9qjw2_gg_.__keyboardFocused_9qjw2_gg_,.___STag_9qjw2_gg_.__interactive_9qjw2_gg_.__keyboardFocused_9qjw2_gg_{box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));z-index:1}.___STagContainerClose_9qjw2_gg_::before,.___STag_9qjw2_gg_::before{content:\"\";position:absolute;top:0;left:0;right:0;bottom:0;border-radius:var(--intergalactic-tag-rounded, 24px);background-color:var(--tag-color_9qjw2);opacity:.2;filter:brightness(150%)}.___STagContainerClose_9qjw2_gg_::after,.___STag_9qjw2_gg_::after{content:\"\";position:absolute;top:-1px;left:-1px;right:-1px;bottom:-1px;border-radius:var(--intergalactic-tag-rounded, 24px);pointer-events:none;border:1px solid var(--tag-color_9qjw2);opacity:.1;filter:brightness(150%)}.___STagContainerClose_9qjw2_gg_:active,.___STagContainerClose_9qjw2_gg_:focus,.___STag_9qjw2_gg_:active,.___STag_9qjw2_gg_:focus{outline:0;-webkit-text-decoration:none;text-decoration:none}@media (hover:hover){.___STagContainerClose_9qjw2_gg_:hover,.___STag_9qjw2_gg_:hover{outline:0;-webkit-text-decoration:none;text-decoration:none}}.___STagContainerClose_9qjw2_gg_.__disabled_9qjw2_gg_,.___STag_9qjw2_gg_.__disabled_9qjw2_gg_{opacity:var(--intergalactic-disabled-opacity, 0.3);cursor:default;pointer-events:none}.___STag_9qjw2_gg_.__interactiveView_9qjw2_gg_{cursor:pointer}.___STagContainerClose_9qjw2_gg_._size_m_9qjw2_gg_,.___STag_9qjw2_gg_._size_m_9qjw2_gg_{height:20px;min-width:20px}.___STagContainerClose_9qjw2_gg_._size_m_9qjw2_gg_ .___SCircle_9qjw2_gg_:first-child,.___STag_9qjw2_gg_._size_m_9qjw2_gg_ .___SCircle_9qjw2_gg_:first-child{margin-left:calc(-1*var(--intergalactic-spacing-05x, 2px))}.___STagContainerClose_9qjw2_gg_._size_m_9qjw2_gg_ .___SCircle_9qjw2_gg_:last-child,.___STag_9qjw2_gg_._size_m_9qjw2_gg_ .___SCircle_9qjw2_gg_:last-child{margin-right:calc(-1*var(--intergalactic-spacing-05x, 2px))}.___STagContainerClose_9qjw2_gg_._size_m_9qjw2_gg_ .___SText_9qjw2_gg_,.___STag_9qjw2_gg_._size_m_9qjw2_gg_ .___SText_9qjw2_gg_{font-size:var(--intergalactic-fs-100, 12px);line-height:var(--intergalactic-lh-100, 133%)}.___STagContainerClose_9qjw2_gg_._size_l_9qjw2_gg_,.___STag_9qjw2_gg_._size_l_9qjw2_gg_{height:28px;min-width:28px}.___STagContainerClose_9qjw2_gg_._size_l_9qjw2_gg_ .___SText_9qjw2_gg_,.___STag_9qjw2_gg_._size_l_9qjw2_gg_ .___SText_9qjw2_gg_{font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%)}.___STagContainerClose_9qjw2_gg_._size_xl_9qjw2_gg_,.___STag_9qjw2_gg_._size_xl_9qjw2_gg_{height:40px;min-width:40px;padding:0 var(--intergalactic-spacing-2x, 8px)}.___STagContainerClose_9qjw2_gg_._size_xl_9qjw2_gg_ .___SText_9qjw2_gg_,.___STag_9qjw2_gg_._size_xl_9qjw2_gg_ .___SText_9qjw2_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%)}.___STagContainerClose_9qjw2_gg_._theme_primary_9qjw2_gg_::before,.___STag_9qjw2_gg_._theme_primary_9qjw2_gg_::before{top:-1px;left:-1px;right:-1px;bottom:-1px}.___STagContainerClose_9qjw2_gg_._theme_primary_9qjw2_gg_:after,.___STag_9qjw2_gg_._theme_primary_9qjw2_gg_:after{display:none}.___STagContainerClose_9qjw2_gg_._theme_primary_9qjw2_gg_.__active_9qjw2_gg_:before,.___STagContainerClose_9qjw2_gg_._theme_primary_9qjw2_gg_.__interactiveView_9qjw2_gg_:active:before,.___STag_9qjw2_gg_._theme_primary_9qjw2_gg_.__active_9qjw2_gg_:before,.___STag_9qjw2_gg_._theme_primary_9qjw2_gg_.__interactiveView_9qjw2_gg_:active:before{opacity:.3}@media (hover:hover){.___STagContainerClose_9qjw2_gg_._theme_primary_9qjw2_gg_.__interactiveView_9qjw2_gg_:hover:before,.___STag_9qjw2_gg_._theme_primary_9qjw2_gg_.__interactiveView_9qjw2_gg_:hover:before{opacity:.3}}.___STagContainerClose_9qjw2_gg_._theme_additional_9qjw2_gg_::before,.___STagContainerClose_9qjw2_gg_._theme_secondary_9qjw2_gg_::before,.___STag_9qjw2_gg_._theme_additional_9qjw2_gg_::before,.___STag_9qjw2_gg_._theme_secondary_9qjw2_gg_::before{opacity:.01}.___STagContainerClose_9qjw2_gg_._theme_additional_9qjw2_gg_.__active_9qjw2_gg_:before,.___STagContainerClose_9qjw2_gg_._theme_additional_9qjw2_gg_.__interactiveView_9qjw2_gg_:active:before,.___STagContainerClose_9qjw2_gg_._theme_secondary_9qjw2_gg_.__active_9qjw2_gg_:before,.___STagContainerClose_9qjw2_gg_._theme_secondary_9qjw2_gg_.__interactiveView_9qjw2_gg_:active:before,.___STag_9qjw2_gg_._theme_additional_9qjw2_gg_.__active_9qjw2_gg_:before,.___STag_9qjw2_gg_._theme_additional_9qjw2_gg_.__interactiveView_9qjw2_gg_:active:before,.___STag_9qjw2_gg_._theme_secondary_9qjw2_gg_.__active_9qjw2_gg_:before,.___STag_9qjw2_gg_._theme_secondary_9qjw2_gg_.__interactiveView_9qjw2_gg_:active:before{opacity:.1}@media (hover:hover){.___STagContainerClose_9qjw2_gg_._theme_additional_9qjw2_gg_.__interactiveView_9qjw2_gg_:hover:before,.___STagContainerClose_9qjw2_gg_._theme_secondary_9qjw2_gg_.__interactiveView_9qjw2_gg_:hover:before,.___STag_9qjw2_gg_._theme_additional_9qjw2_gg_.__interactiveView_9qjw2_gg_:hover:before,.___STag_9qjw2_gg_._theme_secondary_9qjw2_gg_.__interactiveView_9qjw2_gg_:hover:before{opacity:.1}}.___SClose_9qjw2_gg_ path,.___STagContainerClose_9qjw2_gg_._theme_additional-invert_9qjw2_gg_::after,.___STagContainerClose_9qjw2_gg_._theme_additional_9qjw2_gg_::after,.___STagContainerClose_9qjw2_gg_._theme_secondary-invert_9qjw2_gg_::after,.___STagContainerClose_9qjw2_gg_._theme_secondary_9qjw2_gg_::after,.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_ svg path,.___STag_9qjw2_gg_._theme_additional-invert_9qjw2_gg_::after,.___STag_9qjw2_gg_._theme_additional_9qjw2_gg_::after,.___STag_9qjw2_gg_._theme_secondary-invert_9qjw2_gg_::after,.___STag_9qjw2_gg_._theme_secondary_9qjw2_gg_::after{opacity:.5}.___STagContainerClose_9qjw2_gg_._theme_primary-invert_9qjw2_gg_,.___STag_9qjw2_gg_._theme_primary-invert_9qjw2_gg_{background-color:var(--intergalactic-tag-primary-white-normal, rgba(255, 255, 255, 0.15));color:var(--intergalactic-text-primary-invert, #ffffff)}.___STagContainerClose_9qjw2_gg_._theme_additional-invert_9qjw2_gg_,.___STagContainerClose_9qjw2_gg_._theme_secondary-invert_9qjw2_gg_,.___STag_9qjw2_gg_._theme_additional-invert_9qjw2_gg_,.___STag_9qjw2_gg_._theme_secondary-invert_9qjw2_gg_{color:var(--intergalactic-text-primary-invert, #ffffff)}.___STag_9qjw2_gg_._theme_additional_9qjw2_gg_::after{border-style:dashed}.___SText_9qjw2_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_9qjw2_gg_.__keyboardFocused_9qjw2_gg_{box-shadow:var(--intergalactic-keyboard-focus, 0px 0px 0px 3px rgba(0, 143, 248, 0.5));z-index:1}.___SText_9qjw2_gg_:not(:only-child):first-child{padding-right:0}.___SText_9qjw2_gg_:not(:first-child):not(:last-child){padding-left:0;padding-right:0}.___SText_9qjw2_gg_:not(:only-child):last-child{padding-left:0}.___SAddon_9qjw2_gg_,.___SCircle_9qjw2_gg_{display:inline-flex;align-items:center;justify-content:center}.___SAddon_9qjw2_gg_{flex-shrink:0;padding-left:var(--intergalactic-spacing-1x, 4px);padding-right:var(--intergalactic-spacing-1x, 4px);position:relative}.___SCircle_9qjw2_gg_{overflow:hidden;border-radius:50%;margin:0 var(--intergalactic-spacing-1x, 4px)}.___SCircle_9qjw2_gg_:first-child{margin-left:0}.___SCircle_9qjw2_gg_:last-child{margin-right:0}.___SCircle_9qjw2_gg_._size_m_9qjw2_gg_{width:16px;height:16px}.___SCircle_9qjw2_gg_._size_l_9qjw2_gg_,.___SCircle_9qjw2_gg_._size_xl_9qjw2_gg_{width:20px;height:20px}.___SClose_9qjw2_gg_{cursor:pointer;flex-shrink:0;padding:var(--intergalactic-spacing-1x, 4px)}@media (hover:hover){.___SClose_9qjw2_gg_:hover path{opacity:1}}.___SClose_9qjw2_gg_,.___STagContainer_9qjw2_gg_{display:inline-flex;position:relative;align-items:center;justify-content:center}.___STagContainer_9qjw2_gg_ .___STag_9qjw2_gg_{border-top-right-radius:0;border-bottom-right-radius:0;padding-right:var(--intergalactic-spacing-05x, 2px)}.___STagContainer_9qjw2_gg_ .___STag_9qjw2_gg_::after,.___STagContainer_9qjw2_gg_ .___STag_9qjw2_gg_::before{border-right:0;border-top-right-radius:0;border-bottom-right-radius:0;margin-right:-1px}.___STagContainer_9qjw2_gg_ .___STag_9qjw2_gg_ .___SText_9qjw2_gg_{padding-right:0}.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_{cursor:pointer;border-top-left-radius:0;border-bottom-left-radius:0;padding-left:0;padding-right:0;min-width:20px}.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_::after,.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_::before{border-left:0;border-top-left-radius:0;border-bottom-left-radius:0}.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_::before{left:-1px}.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_ svg{padding-left:0;padding-right:var(--intergalactic-spacing-1x, 4px)}@media (hover:hover){.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_:hover svg path{opacity:1}}.___STagContainer_9qjw2_gg_ .___STagContainerClose_9qjw2_gg_._size_xl_9qjw2_gg_ svg{padding-left:var(--intergalactic-spacing-1x, 4px);padding-right:var(--intergalactic-spacing-2x, 8px)}" /*__inner_css_end__*/, "9qjw2_gg_") /*__reshadow_css_end__*/, {
|
30
|
+
"__STag": "___STag_9qjw2_gg_",
|
31
|
+
"_disabled": "__disabled_9qjw2_gg_",
|
32
|
+
"__STagContainerClose": "___STagContainerClose_9qjw2_gg_",
|
33
|
+
"_interactiveView": "__interactiveView_9qjw2_gg_",
|
34
|
+
"_theme_primary-invert": "_theme_primary-invert_9qjw2_gg_",
|
35
|
+
"_theme_secondary-invert": "_theme_secondary-invert_9qjw2_gg_",
|
36
|
+
"_theme_additional-invert": "_theme_additional-invert_9qjw2_gg_",
|
37
|
+
"__SText": "___SText_9qjw2_gg_",
|
38
|
+
"_keyboardFocused": "__keyboardFocused_9qjw2_gg_",
|
39
|
+
"__SAddon": "___SAddon_9qjw2_gg_",
|
40
|
+
"__SCircle": "___SCircle_9qjw2_gg_",
|
41
|
+
"_size_m": "_size_m_9qjw2_gg_",
|
42
|
+
"_size_l": "_size_l_9qjw2_gg_",
|
43
|
+
"_size_xl": "_size_xl_9qjw2_gg_",
|
44
|
+
"--tag-color": "--tag-color_9qjw2",
|
45
|
+
"_interactive": "__interactive_9qjw2_gg_",
|
46
|
+
"_theme_primary": "_theme_primary_9qjw2_gg_",
|
47
|
+
"_active": "__active_9qjw2_gg_",
|
48
|
+
"_theme_secondary": "_theme_secondary_9qjw2_gg_",
|
49
|
+
"_theme_additional": "_theme_additional_9qjw2_gg_",
|
50
|
+
"__SClose": "___SClose_9qjw2_gg_",
|
51
|
+
"__STagContainer": "___STagContainer_9qjw2_gg_"
|
46
52
|
});
|
47
|
-
import { callAllEventHandlers } from 'intergalactic/utils/lib/assignProps';
|
48
53
|
var legacyThemeRecommendedMigration = {
|
49
54
|
primary: {
|
50
55
|
muted: 'gray-500',
|
@@ -108,7 +113,8 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
108
113
|
var focusable = this.state.focusable;
|
109
114
|
return {
|
110
115
|
tabIndex: focusable === 'text' && interactive ? 0 : -1,
|
111
|
-
id: "".concat(id, "-text")
|
116
|
+
id: "".concat(id, "-text"),
|
117
|
+
role: focusable === 'text' && interactive ? 'button' : undefined
|
112
118
|
};
|
113
119
|
}
|
114
120
|
}, {
|
@@ -121,7 +127,6 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
121
127
|
id: "".concat(id, "-clear"),
|
122
128
|
'aria-labelledby': "".concat(id, "-clear ").concat(id, "-text"),
|
123
129
|
'aria-label': getI18nText('remove'),
|
124
|
-
'aria-hidden': 'true',
|
125
130
|
onMount: this.handleCloseMount,
|
126
131
|
onUnmount: this.handleCloseUnmount
|
127
132
|
};
|
@@ -130,7 +135,7 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
130
135
|
key: "render",
|
131
136
|
value: function render() {
|
132
137
|
var _ref = this.asProps,
|
133
|
-
|
138
|
+
_ref8;
|
134
139
|
var STag = Box;
|
135
140
|
var _this$asProps = this.asProps,
|
136
141
|
Children = _this$asProps.Children,
|
@@ -145,13 +150,16 @@ var RootTag = /*#__PURE__*/function (_Component) {
|
|
145
150
|
uid = _this$asProps.uid;
|
146
151
|
var focusable = this.state.focusable;
|
147
152
|
var id = outerId || "igc-".concat(uid, "-tag");
|
148
|
-
|
153
|
+
var isInteractiveView = !disabled && interactive;
|
154
|
+
var isInteractive = !disabled && interactive && focusable === 'container';
|
155
|
+
return _ref8 = sstyled(styles), /*#__PURE__*/React.createElement(STag, _ref8.cn("STag", _objectSpread({}, _assignProps({
|
149
156
|
"id": id,
|
150
|
-
"use:interactive":
|
151
|
-
"
|
157
|
+
"use:interactive": isInteractive,
|
158
|
+
"use:interactiveView": isInteractiveView,
|
152
159
|
"tag-color": resolveColor(color),
|
153
160
|
"onKeyDown": this.handleKeyDown,
|
154
|
-
"use:tabIndex":
|
161
|
+
"use:tabIndex": isInteractive ? 0 : -1,
|
162
|
+
"role": isInteractive ? 'button' : undefined
|
155
163
|
}, _ref))), addonLeft ? /*#__PURE__*/React.createElement(Tag.Addon, {
|
156
164
|
tag: addonLeft
|
157
165
|
}) : null, addonTextChildren(Children, Tag.Text, Tag.Addon), addonRight ? /*#__PURE__*/React.createElement(Tag.Addon, {
|
@@ -171,24 +179,153 @@ _defineProperty(RootTag, "defaultProps", {
|
|
171
179
|
i18n: localizedMessages,
|
172
180
|
locale: 'en'
|
173
181
|
});
|
182
|
+
var RootTagContainer = /*#__PURE__*/function (_Component2) {
|
183
|
+
_inherits(RootTagContainer, _Component2);
|
184
|
+
var _super2 = _createSuper(RootTagContainer);
|
185
|
+
function RootTagContainer() {
|
186
|
+
_classCallCheck(this, RootTagContainer);
|
187
|
+
return _super2.apply(this, arguments);
|
188
|
+
}
|
189
|
+
_createClass(RootTagContainer, [{
|
190
|
+
key: "getTagProps",
|
191
|
+
value: function getTagProps() {
|
192
|
+
var _this$asProps2 = this.asProps,
|
193
|
+
size = _this$asProps2.size,
|
194
|
+
theme = _this$asProps2.theme,
|
195
|
+
color = _this$asProps2.color,
|
196
|
+
disabled = _this$asProps2.disabled,
|
197
|
+
active = _this$asProps2.active,
|
198
|
+
uid = _this$asProps2.uid,
|
199
|
+
outerId = _this$asProps2.id;
|
200
|
+
var id = outerId || "igc-".concat(uid, "-tag");
|
201
|
+
return {
|
202
|
+
id: "".concat(id, "-text"),
|
203
|
+
disabled: disabled,
|
204
|
+
size: size,
|
205
|
+
theme: theme,
|
206
|
+
color: color,
|
207
|
+
active: active
|
208
|
+
};
|
209
|
+
}
|
210
|
+
}, {
|
211
|
+
key: "getCloseProps",
|
212
|
+
value: function getCloseProps() {
|
213
|
+
var _this$asProps3 = this.asProps,
|
214
|
+
size = _this$asProps3.size,
|
215
|
+
theme = _this$asProps3.theme,
|
216
|
+
color = _this$asProps3.color,
|
217
|
+
disabled = _this$asProps3.disabled,
|
218
|
+
active = _this$asProps3.active,
|
219
|
+
uid = _this$asProps3.uid,
|
220
|
+
outerId = _this$asProps3.id,
|
221
|
+
getI18nText = _this$asProps3.getI18nText;
|
222
|
+
var id = outerId || "igc-".concat(uid, "-tag");
|
223
|
+
return {
|
224
|
+
disabled: disabled,
|
225
|
+
size: size,
|
226
|
+
theme: theme,
|
227
|
+
color: color,
|
228
|
+
active: active,
|
229
|
+
id: "".concat(id, "-clear"),
|
230
|
+
'aria-labelledby': "".concat(id, "-clear ").concat(id, "-text"),
|
231
|
+
'aria-label': getI18nText('remove')
|
232
|
+
};
|
233
|
+
}
|
234
|
+
}, {
|
235
|
+
key: "render",
|
236
|
+
value: function render() {
|
237
|
+
var _ref2 = this.asProps,
|
238
|
+
_ref9;
|
239
|
+
var STagContainer = Box;
|
240
|
+
var _this$asProps4 = this.asProps,
|
241
|
+
styles = _this$asProps4.styles,
|
242
|
+
Children = _this$asProps4.Children;
|
243
|
+
return _ref9 = sstyled(styles), /*#__PURE__*/React.createElement(STagContainer, _ref9.cn("STagContainer", _objectSpread({}, _assignProps2({}, _ref2))), /*#__PURE__*/React.createElement(Children, _ref9.cn("Children", {})));
|
244
|
+
}
|
245
|
+
}]);
|
246
|
+
return RootTagContainer;
|
247
|
+
}(Component);
|
248
|
+
_defineProperty(RootTagContainer, "displayName", 'TagContainer');
|
249
|
+
_defineProperty(RootTagContainer, "style", style);
|
250
|
+
_defineProperty(RootTagContainer, "enhance", [i18nEnhance(localizedMessages), uniqueIDEnhancement()]);
|
251
|
+
var RootCloseTagContainer = /*#__PURE__*/function (_Component3) {
|
252
|
+
_inherits(RootCloseTagContainer, _Component3);
|
253
|
+
var _super3 = _createSuper(RootCloseTagContainer);
|
254
|
+
function RootCloseTagContainer() {
|
255
|
+
var _this2;
|
256
|
+
_classCallCheck(this, RootCloseTagContainer);
|
257
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
258
|
+
args[_key] = arguments[_key];
|
259
|
+
}
|
260
|
+
_this2 = _super3.call.apply(_super3, [this].concat(args));
|
261
|
+
_defineProperty(_assertThisInitialized(_this2), "handleKeyDown", function (event) {
|
262
|
+
var _this2$asProps = _this2.asProps,
|
263
|
+
onKeyDown = _this2$asProps.onKeyDown,
|
264
|
+
onClick = _this2$asProps.onClick;
|
265
|
+
if (onKeyDown) {
|
266
|
+
return onKeyDown(event);
|
267
|
+
}
|
268
|
+
if (onClick && (event.key === 'Enter' || event.key === ' ')) {
|
269
|
+
event.preventDefault();
|
270
|
+
onClick(event);
|
271
|
+
}
|
272
|
+
});
|
273
|
+
return _this2;
|
274
|
+
}
|
275
|
+
_createClass(RootCloseTagContainer, [{
|
276
|
+
key: "render",
|
277
|
+
value: function render() {
|
278
|
+
var _ref3 = this.asProps,
|
279
|
+
_ref10;
|
280
|
+
var STagContainerClose = Box;
|
281
|
+
var _this$asProps5 = this.asProps,
|
282
|
+
Children = _this$asProps5.Children,
|
283
|
+
styles = _this$asProps5.styles,
|
284
|
+
color = _this$asProps5.color,
|
285
|
+
resolveColor = _this$asProps5.resolveColor;
|
286
|
+
return _ref10 = sstyled(styles), /*#__PURE__*/React.createElement(STagContainerClose, _ref10.cn("STagContainerClose", _objectSpread({}, _assignProps3({
|
287
|
+
"tag": 'button',
|
288
|
+
"interactive": true,
|
289
|
+
"interactiveView": true,
|
290
|
+
"tag-color": resolveColor(color),
|
291
|
+
"onKeyDown": this.handleKeyDown
|
292
|
+
}, _ref3))), /*#__PURE__*/React.createElement(Children, _ref10.cn("Children", {})));
|
293
|
+
}
|
294
|
+
}]);
|
295
|
+
return RootCloseTagContainer;
|
296
|
+
}(Component);
|
297
|
+
_defineProperty(RootCloseTagContainer, "displayName", 'CloseTagContainer');
|
298
|
+
_defineProperty(RootCloseTagContainer, "style", style);
|
299
|
+
_defineProperty(RootCloseTagContainer, "defaultProps", function () {
|
300
|
+
return {
|
301
|
+
theme: 'primary',
|
302
|
+
color: 'gray-500',
|
303
|
+
size: 'm',
|
304
|
+
i18n: localizedMessages,
|
305
|
+
locale: 'en',
|
306
|
+
children: /*#__PURE__*/React.createElement(CloseTagContainer.Close, null)
|
307
|
+
};
|
308
|
+
});
|
309
|
+
_defineProperty(RootCloseTagContainer, "enhance", [resolveColorEnhance(), keyboardFocusEnhance()]);
|
174
310
|
function Text(props) {
|
175
|
-
var
|
176
|
-
|
311
|
+
var _ref4 = arguments[0],
|
312
|
+
_ref11;
|
177
313
|
var SText = Box;
|
178
314
|
var styles = props.styles;
|
179
|
-
return
|
315
|
+
return _ref11 = sstyled(styles), /*#__PURE__*/React.createElement(SText, _ref11.cn("SText", _objectSpread({}, _assignProps4({
|
180
316
|
"tag": 'span'
|
181
|
-
},
|
317
|
+
}, _ref4))));
|
182
318
|
}
|
183
319
|
Text.enhance = [keyboardFocusEnhance()];
|
184
320
|
function Close(props) {
|
185
|
-
var
|
186
|
-
|
321
|
+
var _ref5 = arguments[0],
|
322
|
+
_ref12;
|
187
323
|
var SClose = Box;
|
188
324
|
var styles = props.styles;
|
189
325
|
React.useEffect(function () {
|
190
326
|
var _props$onMount;
|
191
327
|
(_props$onMount = props.onMount) === null || _props$onMount === void 0 ? void 0 : _props$onMount.call(props);
|
328
|
+
log.warn(true, 'Tag.Close is deprecated and will be removed in the next major release. Please, use TagContainer and TagContainer.Close', 'Tag.Close');
|
192
329
|
return function () {
|
193
330
|
var _props$onUnmount;
|
194
331
|
return (_props$onUnmount = props.onUnmount) === null || _props$onUnmount === void 0 ? void 0 : _props$onUnmount.call(props);
|
@@ -203,29 +340,29 @@ function Close(props) {
|
|
203
340
|
props.onClick(event);
|
204
341
|
}
|
205
342
|
}, [props.onKeyDown, props.onClick]);
|
206
|
-
return
|
343
|
+
return _ref12 = sstyled(styles), /*#__PURE__*/React.createElement(SClose, _ref12.cn("SClose", _objectSpread({}, _assignProps5({
|
207
344
|
"tag": CloseM,
|
208
345
|
"interactive": true,
|
209
346
|
"onKeyDown": onKeyDown
|
210
|
-
},
|
347
|
+
}, _ref5))));
|
211
348
|
}
|
212
349
|
function Addon(props) {
|
213
|
-
var
|
214
|
-
|
350
|
+
var _ref6 = arguments[0],
|
351
|
+
_ref13;
|
215
352
|
var SAddon = Box;
|
216
353
|
var styles = props.styles;
|
217
|
-
return
|
354
|
+
return _ref13 = sstyled(styles), /*#__PURE__*/React.createElement(SAddon, _ref13.cn("SAddon", _objectSpread({}, _assignProps6({
|
218
355
|
"tag": 'span'
|
219
|
-
},
|
356
|
+
}, _ref6))));
|
220
357
|
}
|
221
358
|
function Circle(props) {
|
222
|
-
var
|
223
|
-
|
359
|
+
var _ref7 = arguments[0],
|
360
|
+
_ref14;
|
224
361
|
var SCircle = Box;
|
225
362
|
var styles = props.styles;
|
226
|
-
return
|
363
|
+
return _ref14 = sstyled(styles), /*#__PURE__*/React.createElement(SCircle, _ref14.cn("SCircle", _objectSpread({}, _assignProps7({
|
227
364
|
"tag": 'span'
|
228
|
-
},
|
365
|
+
}, _ref7))));
|
229
366
|
}
|
230
367
|
var Tag = createComponent(RootTag, {
|
231
368
|
Text: Text,
|
@@ -233,5 +370,12 @@ var Tag = createComponent(RootTag, {
|
|
233
370
|
Close: Close,
|
234
371
|
Circle: Circle
|
235
372
|
});
|
373
|
+
var CloseTagContainer = createComponent(RootCloseTagContainer, {
|
374
|
+
Close: CloseM
|
375
|
+
});
|
376
|
+
export var TagContainer = createComponent(RootTagContainer, {
|
377
|
+
Tag: Tag,
|
378
|
+
Close: CloseTagContainer
|
379
|
+
});
|
236
380
|
export default Tag;
|
237
381
|
//# sourceMappingURL=Tag.js.map
|