@weni/unnnic-system 3.25.7 → 3.26.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/dist/{es-Cez02syJ.mjs → es-Dhz_Vb5J.mjs} +1 -1
- package/dist/{index-B-NJIYYT.mjs → index-CyIfw1Zx.mjs} +7464 -7435
- package/dist/index.d.ts +12 -0
- package/dist/{pt-br-u8UEMjaT.mjs → pt-br-LgmWO25q.mjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/tokens/colors.d.ts +2 -0
- package/dist/tokens/colors.mjs +2 -0
- package/dist/unnnic.mjs +18 -17
- package/dist/unnnic.umd.js +29 -29
- package/package.json +2 -1
- package/src/assets/scss/colors-hsl.scss +2 -0
- package/src/assets/scss/colors.scss +0 -43
- package/src/assets/scss/deprecated/colors.scss +1 -0
- package/src/assets/scss/scheme-colors.scss +3 -0
- package/src/assets/scss/semantic-colors.scss +48 -0
- package/src/assets/scss/semantic-text-utilities.scss +9 -0
- package/src/assets/scss/tailwind.scss +1 -1
- package/src/assets/scss/theme.scss +98 -0
- package/src/assets/scss/unnnic.scss +2 -0
- package/src/assets/tokens/colors-primitives.json +155 -0
- package/src/assets/tokens/colors-semantic-dark.json +55 -0
- package/src/assets/tokens/colors-semantic.json +55 -0
- package/src/components/Alert/__tests__/__snapshots__/Alert.spec.js.snap +1 -1
- package/src/components/AudioRecorder/AudioTranscriptionButton.vue +3 -1
- package/src/components/Button/Button.vue +17 -18
- package/src/components/Card/CardCompany.vue +1 -1
- package/src/components/CardNumber/CardNumber.vue +1 -1
- package/src/components/CardProject/CardProject.vue +4 -4
- package/src/components/Carousel/TagCarousel.vue +2 -2
- package/src/components/ChartRainbow/ChartRainbow.vue +2 -2
- package/src/components/ChatsContact/ChatsContact.vue +12 -10
- package/src/components/ChatsContact/__tests__/__snapshots__/ChatsContact.spec.js.snap +1 -1
- package/src/components/ChatsMessage/ChatsMessage.vue +6 -7
- package/src/components/ChatsMessage/ChatsMessageStatusBackdrop.vue +1 -1
- package/src/components/ChatsMessage/ReplyMessage.vue +4 -4
- package/src/components/ChatsNavbar/ChatsNavbar.vue +1 -1
- package/src/components/ChatsUserAvatar/ChatsUserAvatar.vue +3 -3
- package/src/components/Chip/Chip.vue +20 -26
- package/src/components/Chip/__tests__/Chip.spec.js +3 -3
- package/src/components/DataTable/index.vue +2 -2
- package/src/components/DatePicker/DatePicker.vue +4 -4
- package/src/components/EmojiPicker/EmojiPicker.vue +40 -4
- package/src/components/EmojiPicker/__tests__/EmojiPicker.spec.js +1 -1
- package/src/components/FormElement/FormElement.vue +1 -1
- package/src/components/Input/Input.scss +2 -2
- package/src/components/Input/TextInput.vue +1 -1
- package/src/components/SelectTime/index.vue +1 -1
- package/src/components/Sidebar/index.vue +1 -1
- package/src/components/SkeletonLoading/skeletonTheme.vue +2 -4
- package/src/components/Table/Table.vue +1 -1
- package/src/components/Tag/DefaultTag.vue +9 -11
- package/src/components/TemplatePreview/TemplatePreview.vue +1 -1
- package/src/components/Toast/Toast.vue +4 -4
- package/src/components/Toast/__tests__/Toast.spec.js +5 -5
- package/src/components/ToolTip/ToolTip.vue +1 -1
- package/src/components/Tour/TourMask.vue +1 -1
- package/src/components/ui/dialog/DialogContent.vue +1 -1
- package/src/components/ui/popover/PopoverContent.vue +1 -1
- package/src/components/ui/popover/PopoverOption.vue +2 -2
- package/src/components/ui/tooltip/TooltipContent.vue +5 -4
- package/src/composables/useTheme.ts +67 -0
- package/src/index.ts +2 -0
- package/src/stories/Colors.stories.js +6 -1
- package/src/stories/Icon.stories.js +1 -0
- package/src/stories/IconLoading.stories.js +1 -0
- package/src/types/scheme-colors.d.ts +2 -0
- package/src/assets/tokens/colors.json +0 -552
|
@@ -115,14 +115,14 @@ const iconScheme = computed((): SchemeColor => {
|
|
|
115
115
|
}
|
|
116
116
|
|
|
117
117
|
const typeToSchemeMap: Record<ButtonType, SchemeColor> = {
|
|
118
|
-
primary: 'fg-
|
|
118
|
+
primary: 'fg-on-primary',
|
|
119
119
|
secondary: 'fg-emphasized',
|
|
120
120
|
tertiary: 'fg-emphasized',
|
|
121
|
-
warning: 'fg-
|
|
122
|
-
attention: 'fg-
|
|
121
|
+
warning: 'fg-on-primary',
|
|
122
|
+
attention: 'fg-on-primary',
|
|
123
123
|
};
|
|
124
124
|
|
|
125
|
-
return typeToSchemeMap[buttonType.value] || 'fg-
|
|
125
|
+
return typeToSchemeMap[buttonType.value] || 'fg-on-primary';
|
|
126
126
|
});
|
|
127
127
|
|
|
128
128
|
const isSizePropValid = computed(() => {
|
|
@@ -228,7 +228,7 @@ watch(
|
|
|
228
228
|
&--primary,
|
|
229
229
|
&--warning,
|
|
230
230
|
&--attention {
|
|
231
|
-
color: $unnnic-color-fg-
|
|
231
|
+
color: $unnnic-color-fg-on-primary;
|
|
232
232
|
}
|
|
233
233
|
|
|
234
234
|
&--secondary,
|
|
@@ -237,15 +237,15 @@ watch(
|
|
|
237
237
|
}
|
|
238
238
|
|
|
239
239
|
&--primary {
|
|
240
|
-
background-color: $unnnic-color-bg-
|
|
240
|
+
background-color: $unnnic-color-bg-accent-strong;
|
|
241
241
|
|
|
242
242
|
&:hover:enabled {
|
|
243
|
-
background-color: $unnnic-color-teal-
|
|
243
|
+
background-color: $unnnic-color-teal-11;
|
|
244
244
|
}
|
|
245
245
|
|
|
246
246
|
&:active:enabled,
|
|
247
247
|
&.unnnic-button--pressed {
|
|
248
|
-
background-color: $unnnic-color-teal-
|
|
248
|
+
background-color: $unnnic-color-teal-12;
|
|
249
249
|
}
|
|
250
250
|
}
|
|
251
251
|
|
|
@@ -254,12 +254,12 @@ watch(
|
|
|
254
254
|
box-shadow: inset 0 0 0 1px $unnnic-color-border-base;
|
|
255
255
|
|
|
256
256
|
&:hover:enabled {
|
|
257
|
-
background-color: $unnnic-color-
|
|
257
|
+
background-color: $unnnic-color-bg-base-soft;
|
|
258
258
|
}
|
|
259
259
|
|
|
260
260
|
&:active:enabled,
|
|
261
261
|
&.unnnic-button--pressed {
|
|
262
|
-
background-color: $unnnic-color-
|
|
262
|
+
background-color: $unnnic-color-bg-muted;
|
|
263
263
|
}
|
|
264
264
|
|
|
265
265
|
&:disabled {
|
|
@@ -271,39 +271,38 @@ watch(
|
|
|
271
271
|
background-color: transparent;
|
|
272
272
|
|
|
273
273
|
&:hover:enabled {
|
|
274
|
-
background-color:
|
|
274
|
+
background-color: $unnnic-color-bg-base-soft;
|
|
275
275
|
}
|
|
276
276
|
|
|
277
277
|
&:active:enabled,
|
|
278
278
|
&.unnnic-button--pressed {
|
|
279
|
-
background-color:
|
|
279
|
+
background-color: $unnnic-color-bg-muted;
|
|
280
280
|
}
|
|
281
281
|
}
|
|
282
282
|
|
|
283
283
|
&--warning {
|
|
284
284
|
background-color: $unnnic-color-bg-red-strong;
|
|
285
|
-
color: $unnnic-color-fg-inverted;
|
|
286
285
|
|
|
287
286
|
&:hover:enabled {
|
|
288
|
-
background-color: $unnnic-color-red-
|
|
287
|
+
background-color: $unnnic-color-red-11;
|
|
289
288
|
}
|
|
290
289
|
|
|
291
290
|
&:active:enabled,
|
|
292
291
|
&.unnnic-button--pressed {
|
|
293
|
-
background-color: $unnnic-color-red-
|
|
292
|
+
background-color: $unnnic-color-red-12;
|
|
294
293
|
}
|
|
295
294
|
}
|
|
296
295
|
|
|
297
296
|
&--attention {
|
|
298
|
-
background-color: $unnnic-color-yellow-
|
|
297
|
+
background-color: $unnnic-color-bg-yellow-strong;
|
|
299
298
|
|
|
300
299
|
&:hover:enabled {
|
|
301
|
-
background-color: $unnnic-color-yellow-
|
|
300
|
+
background-color: $unnnic-color-yellow-11;
|
|
302
301
|
}
|
|
303
302
|
|
|
304
303
|
&:active:enabled,
|
|
305
304
|
&.unnnic-button--pressed {
|
|
306
|
-
background-color: $unnnic-color-yellow-
|
|
305
|
+
background-color: $unnnic-color-yellow-12;
|
|
307
306
|
}
|
|
308
307
|
}
|
|
309
308
|
|
|
@@ -54,7 +54,7 @@ export default {
|
|
|
54
54
|
span {
|
|
55
55
|
font-weight: $unnnic-font-weight-black;
|
|
56
56
|
font-size: $unnnic-font-size-title-lg;
|
|
57
|
-
color: $unnnic-color-
|
|
57
|
+
color: $unnnic-color-fg-emphasized;
|
|
58
58
|
line-height: $unnnic-font-size-title-lg + $unnnic-line-height-md;
|
|
59
59
|
}
|
|
60
60
|
}
|
|
@@ -302,13 +302,13 @@ export default {
|
|
|
302
302
|
}
|
|
303
303
|
|
|
304
304
|
&--ACTIVE {
|
|
305
|
-
background-color: $unnnic-color-green-
|
|
306
|
-
color: $unnnic-color-
|
|
305
|
+
background-color: $unnnic-color-bg-green-plain;
|
|
306
|
+
color: $unnnic-color-fg-success;
|
|
307
307
|
}
|
|
308
308
|
|
|
309
309
|
&--IN_TEST {
|
|
310
|
-
background-color: $unnnic-color-orange-
|
|
311
|
-
color: $unnnic-color-
|
|
310
|
+
background-color: $unnnic-color-bg-orange-plain;
|
|
311
|
+
color: $unnnic-color-fg-warning;
|
|
312
312
|
}
|
|
313
313
|
|
|
314
314
|
&--INACTIVE {
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
<UnnnicIcon
|
|
8
8
|
icon="arrow-left-1-1"
|
|
9
9
|
size="sm"
|
|
10
|
-
:scheme="hasPrev ? '
|
|
10
|
+
:scheme="hasPrev ? 'fg-emphasized' : 'fg-muted'"
|
|
11
11
|
clickable
|
|
12
12
|
@click="previous()"
|
|
13
13
|
/>
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
<UnnnicIcon
|
|
50
50
|
icon="arrow-right-1-1"
|
|
51
51
|
size="sm"
|
|
52
|
-
:scheme="hasNext ? '
|
|
52
|
+
:scheme="hasNext ? 'fg-emphasized' : 'fg-muted'"
|
|
53
53
|
clickable
|
|
54
54
|
@click="next()"
|
|
55
55
|
/>
|
|
@@ -176,13 +176,13 @@ export default {
|
|
|
176
176
|
font-weight: $unnnic-font-weight-black;
|
|
177
177
|
|
|
178
178
|
.number {
|
|
179
|
-
color: $unnnic-color-
|
|
179
|
+
color: $unnnic-color-fg-emphasized;
|
|
180
180
|
font-size: $unnnic-font-size-h3;
|
|
181
181
|
line-height: $unnnic-font-size-h3 + $unnnic-line-height-md;
|
|
182
182
|
}
|
|
183
183
|
|
|
184
184
|
.symbol {
|
|
185
|
-
color: $unnnic-color-
|
|
185
|
+
color: $unnnic-color-fg-muted;
|
|
186
186
|
font-size: $unnnic-font-size-h4;
|
|
187
187
|
line-height: $unnnic-font-size-h4 + $unnnic-line-height-md;
|
|
188
188
|
}
|
|
@@ -22,12 +22,12 @@
|
|
|
22
22
|
<slot name="avatar">
|
|
23
23
|
<UserAvatar
|
|
24
24
|
v-if="discussionGoal"
|
|
25
|
-
scheme="purple-
|
|
25
|
+
scheme="bg-purple-plain"
|
|
26
26
|
>
|
|
27
27
|
<template #content>
|
|
28
28
|
<UnnnicIcon
|
|
29
29
|
icon="communication"
|
|
30
|
-
scheme="
|
|
30
|
+
scheme="fg-base"
|
|
31
31
|
/>
|
|
32
32
|
</template>
|
|
33
33
|
</UserAvatar>
|
|
@@ -36,6 +36,8 @@
|
|
|
36
36
|
:username="title"
|
|
37
37
|
:photoUrl="userPhoto"
|
|
38
38
|
:active="isHovered || selected"
|
|
39
|
+
scheme="bg-muted"
|
|
40
|
+
textColor="fg-emphasized"
|
|
39
41
|
/>
|
|
40
42
|
</slot>
|
|
41
43
|
<div class="chats-contact__infos">
|
|
@@ -268,7 +270,7 @@ export default {
|
|
|
268
270
|
},
|
|
269
271
|
schemePin: {
|
|
270
272
|
type: String,
|
|
271
|
-
default: '
|
|
273
|
+
default: 'fg-emphasized',
|
|
272
274
|
},
|
|
273
275
|
pendingResponse: {
|
|
274
276
|
type: Boolean,
|
|
@@ -572,13 +574,13 @@ export default {
|
|
|
572
574
|
&__project-tag {
|
|
573
575
|
display: block;
|
|
574
576
|
flex-shrink: 1;
|
|
575
|
-
|
|
577
|
+
background: $unnnic-color-bg-muted;
|
|
576
578
|
|
|
577
579
|
font: $unnnic-font-caption-1;
|
|
578
580
|
color: $unnnic-color-fg-emphasized;
|
|
579
581
|
|
|
580
|
-
border-radius: $unnnic-radius-
|
|
581
|
-
padding:
|
|
582
|
+
border-radius: $unnnic-radius-full;
|
|
583
|
+
padding: $unnnic-space-05 $unnnic-space-3;
|
|
582
584
|
}
|
|
583
585
|
|
|
584
586
|
&__media {
|
|
@@ -605,7 +607,7 @@ export default {
|
|
|
605
607
|
&__additional-information {
|
|
606
608
|
width: 100%; // important to ellipsis work
|
|
607
609
|
|
|
608
|
-
color: $unnnic-color-fg-
|
|
610
|
+
color: $unnnic-color-fg-base;
|
|
609
611
|
}
|
|
610
612
|
|
|
611
613
|
&__pending-response {
|
|
@@ -661,7 +663,7 @@ export default {
|
|
|
661
663
|
line-height: $unnnic-font-size-body-lg;
|
|
662
664
|
|
|
663
665
|
&--active {
|
|
664
|
-
color: $unnnic-color-
|
|
666
|
+
color: $unnnic-color-fg-info;
|
|
665
667
|
font-weight: $unnnic-font-weight-bold;
|
|
666
668
|
}
|
|
667
669
|
}
|
|
@@ -672,7 +674,7 @@ export default {
|
|
|
672
674
|
align-items: center;
|
|
673
675
|
|
|
674
676
|
border-radius: 50%;
|
|
675
|
-
background: $unnnic-color-
|
|
677
|
+
background: $unnnic-color-bg-info;
|
|
676
678
|
|
|
677
679
|
width: 1.25rem;
|
|
678
680
|
min-width: 1.25rem;
|
|
@@ -681,7 +683,7 @@ export default {
|
|
|
681
683
|
font-size: $unnnic-font-size-body-md;
|
|
682
684
|
font-weight: $unnnic-font-weight-bold;
|
|
683
685
|
line-height: $unnnic-line-height-small;
|
|
684
|
-
color: $unnnic-color-
|
|
686
|
+
color: $unnnic-color-fg-info;
|
|
685
687
|
}
|
|
686
688
|
|
|
687
689
|
&__new-message-indicator {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
exports[`UnnnicChatsContact > should match snapshot 1`] = `
|
|
4
4
|
"<div data-v-8ce6efd5="" class="chats-contact" tabindex="0" style="position: relative; overflow: hidden;">
|
|
5
|
-
<section data-v-c735998e="" data-v-8ce6efd5="" class="user-avatar user-avatar--xl user-avatar--
|
|
5
|
+
<section data-v-c735998e="" data-v-8ce6efd5="" class="user-avatar user-avatar--xl user-avatar--bg-muted"><span data-v-c735998e="" class="text-fg-emphasized">C</span></section>
|
|
6
6
|
<div data-v-8ce6efd5="" class="chats-contact__infos">
|
|
7
7
|
<section data-v-8ce6efd5="" class="chats-contact__infos__title-container">
|
|
8
8
|
<h1 data-v-8ce6efd5="" class="chats-contact__infos__title ellipsis" title="Contact Name">Contact Name</h1>
|
|
@@ -321,7 +321,7 @@ $defaultLineHeight: $unnnic-font-size-body-gt + $unnnic-line-height-medium;
|
|
|
321
321
|
|
|
322
322
|
background-color: $unnnic-color-bg-base;
|
|
323
323
|
|
|
324
|
-
font
|
|
324
|
+
font: $unnnic-font-body;
|
|
325
325
|
|
|
326
326
|
box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.1);
|
|
327
327
|
|
|
@@ -342,10 +342,10 @@ $defaultLineHeight: $unnnic-font-size-body-gt + $unnnic-line-height-medium;
|
|
|
342
342
|
}
|
|
343
343
|
|
|
344
344
|
&.sent {
|
|
345
|
-
background-color:
|
|
345
|
+
background-color: $unnnic-color-bg-accent-plain;
|
|
346
346
|
|
|
347
347
|
&.automatic {
|
|
348
|
-
background-color: $unnnic-color-
|
|
348
|
+
background-color: $unnnic-color-bg-info;
|
|
349
349
|
}
|
|
350
350
|
}
|
|
351
351
|
|
|
@@ -430,7 +430,7 @@ $defaultLineHeight: $unnnic-font-size-body-gt + $unnnic-line-height-medium;
|
|
|
430
430
|
padding: $unnnic-spacing-nano 0;
|
|
431
431
|
|
|
432
432
|
font-size: $unnnic-font-size-body-gt;
|
|
433
|
-
color: $unnnic-color-fg-
|
|
433
|
+
color: $unnnic-color-fg-emphasized;
|
|
434
434
|
line-height: $defaultLineHeight;
|
|
435
435
|
word-break: break-word;
|
|
436
436
|
}
|
|
@@ -450,9 +450,8 @@ $defaultLineHeight: $unnnic-font-size-body-gt + $unnnic-line-height-medium;
|
|
|
450
450
|
}
|
|
451
451
|
|
|
452
452
|
&__time {
|
|
453
|
-
font
|
|
454
|
-
|
|
455
|
-
color: $unnnic-color-fg-muted;
|
|
453
|
+
font: $unnnic-font-caption-2;
|
|
454
|
+
color: $unnnic-color-fg-base;
|
|
456
455
|
margin: 0;
|
|
457
456
|
padding: 0;
|
|
458
457
|
|
|
@@ -196,10 +196,10 @@ onUpdated(() => {
|
|
|
196
196
|
background: rgba(8, 103, 102, 0.1);
|
|
197
197
|
}
|
|
198
198
|
&--you {
|
|
199
|
-
border-left: 2px solid $unnnic-color-
|
|
199
|
+
border-left: 2px solid $unnnic-color-bg-teal-strong;
|
|
200
200
|
}
|
|
201
201
|
&--contact {
|
|
202
|
-
border-left: 2px solid $unnnic-color-purple-
|
|
202
|
+
border-left: 2px solid $unnnic-color-bg-purple-strong;
|
|
203
203
|
}
|
|
204
204
|
&__message-container {
|
|
205
205
|
display: flex;
|
|
@@ -212,10 +212,10 @@ onUpdated(() => {
|
|
|
212
212
|
font-weight: $unnnic-font-weight-bold;
|
|
213
213
|
line-height: $unnnic-font-size-body-gt + $unnnic-line-height-md;
|
|
214
214
|
&--you {
|
|
215
|
-
color: $unnnic-color-
|
|
215
|
+
color: $unnnic-color-bg-teal-strong;
|
|
216
216
|
}
|
|
217
217
|
&--contact {
|
|
218
|
-
color: $unnnic-color-purple-
|
|
218
|
+
color: $unnnic-color-bg-purple-strong;
|
|
219
219
|
}
|
|
220
220
|
}
|
|
221
221
|
&__content {
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
v-if="username === 'Agent'"
|
|
17
17
|
icon="single-neutral-actions-1"
|
|
18
18
|
size="sm"
|
|
19
|
-
:scheme="disabled ? 'fg-
|
|
19
|
+
:scheme="disabled ? 'fg-on-primary' : ''"
|
|
20
20
|
/>
|
|
21
21
|
<UnnnicIcon
|
|
22
22
|
v-else-if="username === 'Bot'"
|
|
23
23
|
icon="science-fiction-robot-2"
|
|
24
24
|
size="sm"
|
|
25
|
-
:scheme="disabled ? 'fg-
|
|
25
|
+
:scheme="disabled ? 'fg-on-primary' : ''"
|
|
26
26
|
/>
|
|
27
27
|
<img
|
|
28
28
|
v-else-if="!!photoUrl"
|
|
@@ -119,7 +119,7 @@ $avatar-sizes:
|
|
|
119
119
|
|
|
120
120
|
&.disabled {
|
|
121
121
|
background: $unnnic-color-gray-7;
|
|
122
|
-
color: $unnnic-color-fg-
|
|
122
|
+
color: $unnnic-color-fg-on-primary;
|
|
123
123
|
}
|
|
124
124
|
|
|
125
125
|
&.clickable {
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
]"
|
|
12
12
|
@click="onClick"
|
|
13
13
|
>
|
|
14
|
-
<p
|
|
14
|
+
<p class="chip__text">{{ text }}</p>
|
|
15
15
|
<p
|
|
16
16
|
v-if="count"
|
|
17
17
|
:class="['chip__count', countColorClass]"
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
<UnnnicIcon
|
|
23
23
|
v-if="type === 'multiple'"
|
|
24
24
|
:icon="isSelected ? 'close' : 'add'"
|
|
25
|
-
|
|
25
|
+
scheme="fg-emphasized"
|
|
26
26
|
class="chip__icon"
|
|
27
27
|
size="sm"
|
|
28
28
|
/>
|
|
@@ -48,13 +48,6 @@ const shouldShowBorder = computed(() => {
|
|
|
48
48
|
return !props.isSelected;
|
|
49
49
|
});
|
|
50
50
|
|
|
51
|
-
const textColorClass = computed(() => {
|
|
52
|
-
if (props.isSelected) {
|
|
53
|
-
return 'chip__text--is-selected';
|
|
54
|
-
}
|
|
55
|
-
return '';
|
|
56
|
-
});
|
|
57
|
-
|
|
58
51
|
const countColorClass = computed(() => {
|
|
59
52
|
if (props.isSelected) {
|
|
60
53
|
return 'chip__count--is-selected';
|
|
@@ -78,18 +71,25 @@ const chipClass = computed(() => {
|
|
|
78
71
|
align-items: center;
|
|
79
72
|
gap: $unnnic-space-2;
|
|
80
73
|
flex-shrink: 0;
|
|
81
|
-
border-radius:
|
|
74
|
+
border-radius: $unnnic-radius-full;
|
|
82
75
|
background-color: $unnnic-color-bg-base;
|
|
83
|
-
border: 1px solid
|
|
76
|
+
border: 1px solid $unnnic-color-border-base;
|
|
77
|
+
|
|
78
|
+
cursor: default;
|
|
79
|
+
|
|
80
|
+
transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1); // Same as UnnnicButton
|
|
84
81
|
|
|
85
82
|
&:hover {
|
|
86
83
|
background-color: $unnnic-color-bg-soft;
|
|
87
84
|
}
|
|
88
85
|
|
|
89
86
|
&--is-selected {
|
|
90
|
-
background-color: $unnnic-color-
|
|
87
|
+
background-color: $unnnic-color-bg-accent-plain;
|
|
88
|
+
border-color: transparent;
|
|
89
|
+
|
|
91
90
|
&:hover {
|
|
92
|
-
background-color: $unnnic-color-
|
|
91
|
+
background-color: $unnnic-color-bg-accent-plain;
|
|
92
|
+
border-color: $unnnic-color-border-accent-plain;
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
|
|
@@ -102,12 +102,8 @@ const chipClass = computed(() => {
|
|
|
102
102
|
}
|
|
103
103
|
|
|
104
104
|
&__text {
|
|
105
|
-
color: $unnnic-color-fg-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
&--is-selected {
|
|
109
|
-
color: $unnnic-color-fg-active;
|
|
110
|
-
}
|
|
105
|
+
color: $unnnic-color-fg-emphasized;
|
|
106
|
+
@include unnnic-font-caption-1;
|
|
111
107
|
}
|
|
112
108
|
|
|
113
109
|
&__count {
|
|
@@ -116,15 +112,13 @@ const chipClass = computed(() => {
|
|
|
116
112
|
justify-content: center;
|
|
117
113
|
align-items: center;
|
|
118
114
|
gap: 10px;
|
|
119
|
-
border-radius:
|
|
120
|
-
background: $unnnic-color-bg-
|
|
121
|
-
color: $unnnic-color-fg-
|
|
122
|
-
|
|
123
|
-
font-weight: $unnnic-font-weight-medium;
|
|
115
|
+
border-radius: $unnnic-radius-full;
|
|
116
|
+
background: $unnnic-color-bg-muted;
|
|
117
|
+
color: $unnnic-color-fg-emphasized;
|
|
118
|
+
@include unnnic-font-caption-2;
|
|
124
119
|
|
|
125
120
|
&--is-selected {
|
|
126
|
-
|
|
127
|
-
background: $unnnic-color-white;
|
|
121
|
+
background: $unnnic-color-bg-teal-plain;
|
|
128
122
|
}
|
|
129
123
|
}
|
|
130
124
|
}
|
|
@@ -42,7 +42,7 @@ describe('Chip', () => {
|
|
|
42
42
|
expect(wrapper.classes()).not.toContain('chip--border');
|
|
43
43
|
|
|
44
44
|
const textElement = wrapper.find('.chip__text');
|
|
45
|
-
expect(textElement.
|
|
45
|
+
expect(textElement.exists()).toBe(true);
|
|
46
46
|
});
|
|
47
47
|
});
|
|
48
48
|
|
|
@@ -82,14 +82,14 @@ describe('Chip', () => {
|
|
|
82
82
|
let icon = wrapper.findComponent({ name: 'UnnnicIcon' });
|
|
83
83
|
expect(icon.exists()).toBe(true);
|
|
84
84
|
expect(icon.props('icon')).toBe('add');
|
|
85
|
-
expect(icon.props('scheme')).toBe('
|
|
85
|
+
expect(icon.props('scheme')).toBe('fg-emphasized');
|
|
86
86
|
expect(icon.props('size')).toBe('sm');
|
|
87
87
|
|
|
88
88
|
await wrapper.setProps({ isSelected: true });
|
|
89
89
|
|
|
90
90
|
icon = wrapper.findComponent({ name: 'UnnnicIcon' });
|
|
91
91
|
expect(icon.props('icon')).toBe('close');
|
|
92
|
-
expect(icon.props('scheme')).toBe('
|
|
92
|
+
expect(icon.props('scheme')).toBe('fg-emphasized');
|
|
93
93
|
});
|
|
94
94
|
});
|
|
95
95
|
|
|
@@ -398,7 +398,7 @@ $tableBorder: 1px solid $unnnic-color-border-base;
|
|
|
398
398
|
}
|
|
399
399
|
|
|
400
400
|
&::-webkit-scrollbar-thumb {
|
|
401
|
-
background: $unnnic-color-
|
|
401
|
+
background: $unnnic-color-border-emphasized;
|
|
402
402
|
border-radius: $unnnic-border-radius-pill;
|
|
403
403
|
}
|
|
404
404
|
|
|
@@ -458,7 +458,7 @@ $tableBorder: 1px solid $unnnic-color-border-base;
|
|
|
458
458
|
}
|
|
459
459
|
|
|
460
460
|
&::-webkit-scrollbar-thumb {
|
|
461
|
-
background: $unnnic-color-
|
|
461
|
+
background: $unnnic-color-border-emphasized;
|
|
462
462
|
border-radius: $unnnic-border-radius-pill;
|
|
463
463
|
}
|
|
464
464
|
|
|
@@ -1068,12 +1068,12 @@ onMounted(() => {
|
|
|
1068
1068
|
.selected {
|
|
1069
1069
|
font-weight: $unnnic-font-weight-black;
|
|
1070
1070
|
background-color: $unnnic-color-bg-base-soft;
|
|
1071
|
-
color: $unnnic-color-
|
|
1071
|
+
color: $unnnic-color-fg-accent;
|
|
1072
1072
|
border-radius: 0;
|
|
1073
1073
|
|
|
1074
1074
|
&.highlighted {
|
|
1075
|
-
background-color: $unnnic-color-
|
|
1076
|
-
color: $unnnic-color-fg-
|
|
1075
|
+
background-color: $unnnic-color-bg-accent-strong;
|
|
1076
|
+
color: $unnnic-color-fg-on-primary;
|
|
1077
1077
|
|
|
1078
1078
|
&.left {
|
|
1079
1079
|
border-top-left-radius: $unnnic-border-radius-sm;
|
|
@@ -1128,7 +1128,7 @@ onMounted(() => {
|
|
|
1128
1128
|
|
|
1129
1129
|
&.selected {
|
|
1130
1130
|
font-weight: $unnnic-font-weight-bold;
|
|
1131
|
-
color: $unnnic-color-
|
|
1131
|
+
color: $unnnic-color-fg-accent;
|
|
1132
1132
|
}
|
|
1133
1133
|
}
|
|
1134
1134
|
}
|
|
@@ -62,7 +62,7 @@ const emit = defineEmits<{
|
|
|
62
62
|
const emojiPickerRef = ref<HTMLElement>();
|
|
63
63
|
const emojiIndex = computed(() => new EmojiIndex(data));
|
|
64
64
|
|
|
65
|
-
const accentColor = '
|
|
65
|
+
const accentColor = 'var(--unnnic-color-fg-accent)';
|
|
66
66
|
|
|
67
67
|
const currentLocale = computed(() => props.locale || 'pt-br');
|
|
68
68
|
|
|
@@ -125,6 +125,7 @@ const onEmojiSelect = (emoji: Emoji) => {
|
|
|
125
125
|
|
|
126
126
|
<style lang="scss" scoped>
|
|
127
127
|
@use '@/assets/scss/unnnic' as *;
|
|
128
|
+
@use '@/components/Input/Input.scss' as *;
|
|
128
129
|
|
|
129
130
|
.emoji-picker {
|
|
130
131
|
position: absolute;
|
|
@@ -146,6 +147,7 @@ const onEmojiSelect = (emoji: Emoji) => {
|
|
|
146
147
|
border-radius: $unnnic-radius-4;
|
|
147
148
|
font-family: $unnnic-font-family;
|
|
148
149
|
border: 1px solid $unnnic-color-border-base;
|
|
150
|
+
background-color: $unnnic-color-bg-base;
|
|
149
151
|
box-shadow: $unnnic-shadow-1;
|
|
150
152
|
cursor: default;
|
|
151
153
|
color: $unnnic-color-fg-emphasized;
|
|
@@ -153,15 +155,33 @@ const onEmojiSelect = (emoji: Emoji) => {
|
|
|
153
155
|
|
|
154
156
|
:deep(.emoji-mart-emoji) {
|
|
155
157
|
cursor: pointer;
|
|
158
|
+
|
|
159
|
+
&::before {
|
|
160
|
+
background-color: $unnnic-color-bg-base-soft;
|
|
161
|
+
}
|
|
156
162
|
}
|
|
157
163
|
|
|
158
|
-
:deep(.emoji-mart-
|
|
159
|
-
|
|
164
|
+
:deep(.emoji-mart-search) {
|
|
165
|
+
margin: $unnnic-space-2 0;
|
|
166
|
+
|
|
167
|
+
input {
|
|
168
|
+
@include input-base;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
:deep(.emoji-mart-category) {
|
|
173
|
+
.emoji-mart-emoji span {
|
|
174
|
+
cursor: pointer;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
.emoji-mart-category-label {
|
|
178
|
+
background-color: transparent;
|
|
179
|
+
}
|
|
160
180
|
}
|
|
161
181
|
|
|
162
182
|
:deep(.emoji-mart-anchor) {
|
|
163
183
|
cursor: pointer;
|
|
164
|
-
color:
|
|
184
|
+
color: $unnnic-color-fg-base;
|
|
165
185
|
}
|
|
166
186
|
|
|
167
187
|
:deep(.emoji-mart-anchor:hover),
|
|
@@ -182,6 +202,22 @@ const onEmojiSelect = (emoji: Emoji) => {
|
|
|
182
202
|
:deep(.emoji-type-image.emoji-set-twitter) {
|
|
183
203
|
background-image: none !important;
|
|
184
204
|
}
|
|
205
|
+
|
|
206
|
+
:deep(.emoji-mart-scroll) {
|
|
207
|
+
&::-webkit-scrollbar {
|
|
208
|
+
width: $unnnic-space-2;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
&::-webkit-scrollbar-thumb {
|
|
212
|
+
background: $unnnic-color-border-emphasized;
|
|
213
|
+
border-radius: $unnnic-radius-full;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
&::-webkit-scrollbar-track {
|
|
217
|
+
background: $unnnic-color-border-muted;
|
|
218
|
+
border-radius: $unnnic-radius-full;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
185
221
|
}
|
|
186
222
|
|
|
187
223
|
@keyframes slideInUp {
|
|
@@ -102,7 +102,7 @@ describe('UnnnicEmojiPicker', () => {
|
|
|
102
102
|
expect(picker.props('navPosition')).toBe('bottom');
|
|
103
103
|
expect(picker.props('noResultsEmoji')).toBe('cry');
|
|
104
104
|
expect(picker.props('maxFrequentRows')).toBe(3);
|
|
105
|
-
expect(picker.props('color')).toBe('
|
|
105
|
+
expect(picker.props('color')).toBe('var(--unnnic-color-fg-accent)');
|
|
106
106
|
expect(picker.props('i18n')).toBeDefined();
|
|
107
107
|
});
|
|
108
108
|
|