@weni/unnnic-system 3.9.3-alpha.0 → 3.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/components/Accordion/Accordion.vue.d.ts +1 -1
- package/dist/components/Alert/Alert.vue.d.ts +116 -17
- package/dist/components/Alert/Alert.vue.d.ts.map +1 -1
- package/dist/components/Alert/Version1dot1.vue.d.ts +38 -2
- package/dist/components/Alert/Version1dot1.vue.d.ts.map +1 -1
- package/dist/components/AudioRecorder/AudioHandler.vue.d.ts +2 -2
- package/dist/components/AudioRecorder/AudioPlayer.vue.d.ts +1 -1
- package/dist/components/AudioRecorder/AudioRecorder.vue.d.ts +5 -5
- package/dist/components/AvatarIcon/AvatarIcon.vue.d.ts +3 -3
- package/dist/components/Banner/Banner.vue.d.ts +1 -1
- package/dist/components/Banner/InfoBanner.vue.d.ts +1 -1
- package/dist/components/Breadcrumb/Breadcrumb.vue.d.ts +1 -1
- package/dist/components/Button/Button.vue.d.ts +1 -1
- package/dist/components/Button/Button.vue.d.ts.map +1 -1
- package/dist/components/Button/ButtonIcon.vue.d.ts +1 -1
- package/dist/components/Button/types.d.ts +1 -1
- package/dist/components/Button/types.d.ts.map +1 -1
- package/dist/components/Card/AccountCard.vue.d.ts +5 -5
- package/dist/components/Card/BlankCard.vue.d.ts +1 -1
- package/dist/components/Card/Card.vue.d.ts +27 -27
- package/dist/components/Card/CardCompany.vue.d.ts +414 -11
- package/dist/components/Card/CardData.vue.d.ts +1 -1
- package/dist/components/Card/CardStatusesContainer.vue.d.ts +5 -5
- package/dist/components/Card/ContentCard.vue.d.ts +3 -3
- package/dist/components/Card/DashCard.vue.d.ts +5 -5
- package/dist/components/Card/DefaultCard.vue.d.ts +1 -1
- package/dist/components/Card/MarketplaceCard.vue.d.ts +2 -2
- package/dist/components/Card/SimpleCard.vue.d.ts +3 -3
- package/dist/components/Card/StatusCard.vue.d.ts +2 -2
- package/dist/components/Card/TitleCard.vue.d.ts +3 -3
- package/dist/components/CardImage/CardImage.vue.d.ts +31 -24
- package/dist/components/CardInformation/CardInformation.vue.d.ts +5 -5
- package/dist/components/CardProject/CardProject.vue.d.ts +3 -3
- package/dist/components/Carousel/Carousel.vue.d.ts +416 -13
- package/dist/components/Carousel/TagCarousel.vue.d.ts +415 -12
- package/dist/components/ChartBar/ChartBar.vue.d.ts +5 -5
- package/dist/components/ChartLine/ChartLine.vue.d.ts +1 -1
- package/dist/components/ChatText/ChatText.vue.d.ts +2 -2
- package/dist/components/ChatsContact/ChatsContact.vue.d.ts +446 -21
- package/dist/components/ChatsDashboardTagLive/ChatsDashboardTagLive.vue.d.ts +1 -1
- package/dist/components/ChatsHeader/ChatsHeader.vue.d.ts +1 -1
- package/dist/components/ChatsHeader/ChatsHeader.vue.d.ts.map +1 -1
- package/dist/components/ChatsMessage/ChatsMessage.vue.d.ts +5 -5
- package/dist/components/ChatsMessage/ChatsMessageStatusBackdrop.vue.d.ts +2 -2
- package/dist/components/ChatsNavbar/ChatsNavbar.vue.d.ts +1 -1
- package/dist/components/ChatsUserAvatar/ChatsUserAvatar.vue.d.ts +2 -2
- package/dist/components/Checkbox/Checkbox.vue.d.ts +26 -19
- package/dist/components/Checkbox/Checkbox.vue.d.ts.map +1 -1
- package/dist/components/Comment/Comment.vue.d.ts +1 -1
- package/dist/components/DataArea/DataArea.vue.d.ts +2 -2
- package/dist/components/DataTable/index.vue.d.ts +1 -1
- package/dist/components/DataTable/index.vue.d.ts.map +1 -1
- package/dist/components/DateFilter/DateFilter.vue.d.ts +41 -251
- package/dist/components/DatePicker/DatePicker.vue.d.ts +4 -4
- package/dist/components/Drawer/Drawer.vue.d.ts +4 -4
- package/dist/components/Dropdown/Dropdown.vue.d.ts +1 -1
- package/dist/components/Dropdown/LanguageSelect.vue.d.ts +3 -3
- package/dist/components/Flag.vue.d.ts +2 -2
- package/dist/components/FormElement/FormElement.vue.d.ts +28 -51
- package/dist/components/FormElement/FormElement.vue.d.ts.map +1 -1
- package/dist/components/Icon.vue.d.ts +1 -1
- package/dist/components/Icon.vue.d.ts.map +1 -1
- package/dist/components/IconLoading/IconLoading.vue.d.ts +1 -1
- package/dist/components/ImportCard/ImportCard.vue.d.ts +4 -4
- package/dist/components/Input/BaseInput.vue.d.ts +2 -33
- package/dist/components/Input/BaseInput.vue.d.ts.map +1 -1
- package/dist/components/Input/Input.vue.d.ts +41 -251
- package/dist/components/Input/Input.vue.d.ts.map +1 -1
- package/dist/components/Input/TextInput.vue.d.ts +25 -85
- package/dist/components/Input/TextInput.vue.d.ts.map +1 -1
- package/dist/components/InputDatePicker/InputDatePicker.vue.d.ts +46 -256
- package/dist/components/InputNext/InputNext.vue.d.ts +5 -5
- package/dist/components/Label/Label.vue.d.ts +15 -9
- package/dist/components/Label/Label.vue.d.ts.map +1 -1
- package/dist/components/Modal/Modal.vue.d.ts +2 -2
- package/dist/components/ModalDialog/ModalDialog.vue.d.ts +6 -6
- package/dist/components/ModalNext/ModalNext.vue.d.ts +46 -256
- package/dist/components/ModalUpload/ModalUpload.vue.d.ts +9 -9
- package/dist/components/MoodRating/MoodRating.vue.d.ts +1 -1
- package/dist/components/MultiSelect/MultiSelect.vue.d.ts +14 -26
- package/dist/components/Pagination/Pagination.vue.d.ts +3 -3
- package/dist/components/ProgressBar/ProgressBar.vue.d.ts +1 -1
- package/dist/components/Radio/Radio.vue.d.ts +6 -10
- package/dist/components/Radio/Radio.vue.d.ts.map +1 -1
- package/dist/components/SelectSmart/SelectSmart.vue.d.ts +470 -120
- package/dist/components/SelectSmart/SelectSmartMultipleHeader.vue.d.ts +414 -11
- package/dist/components/SelectSmart/SelectSmartOption.vue.d.ts +28 -21
- package/dist/components/SelectSmart/SelectSmartOption.vue.d.ts.map +1 -1
- package/dist/components/SelectTime/index.vue.d.ts +25 -85
- package/dist/components/SkeletonLoading/skeletonTheme.vue.d.ts +1 -1
- package/dist/components/Slider/Slider.vue.d.ts +2 -2
- package/dist/components/StarRating/StarRating.vue.d.ts +1 -1
- package/dist/components/Switch/Switch.vue.d.ts +21 -55
- package/dist/components/Switch/Switch.vue.d.ts.map +1 -1
- package/dist/components/Tab/Tab.vue.d.ts +2 -13
- package/dist/components/TableNext/TableBodyCell.vue.d.ts +2 -2
- package/dist/components/TableNext/TablePagination.vue.d.ts +3 -3
- package/dist/components/TabsExpanded/TabsExpanded.vue.d.ts +1 -1
- package/dist/components/Tag/BrandTag.vue.d.ts +51 -0
- package/dist/components/Tag/BrandTag.vue.d.ts.map +1 -0
- package/dist/components/Tag/DefaultTag.vue.d.ts +83 -4
- package/dist/components/Tag/DefaultTag.vue.d.ts.map +1 -1
- package/dist/components/Tag/IndicatorTag.vue.d.ts +151 -0
- package/dist/components/Tag/IndicatorTag.vue.d.ts.map +1 -0
- package/dist/components/Tag/Tag.vue.d.ts +414 -12
- package/dist/components/Tag/Tag.vue.d.ts.map +1 -1
- package/dist/components/Tag/TagNext.vue.d.ts +24 -0
- package/dist/components/Tag/TagNext.vue.d.ts.map +1 -0
- package/dist/components/TextArea/TextArea.vue.d.ts +33 -78
- package/dist/components/TextArea/TextArea.vue.d.ts.map +1 -1
- package/dist/components/ToolTip/ToolTip.vue.d.ts +1 -1
- package/dist/components/Tour/Tour.vue.d.ts +3 -3
- package/dist/components/Tour/TourPopover.vue.d.ts +3 -3
- package/dist/components/UploadArea/UploadArea.vue.d.ts +4 -4
- package/dist/components/index.d.ts +7710 -6271
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/ui/popover/PopoverContent.vue.d.ts +1 -1
- package/dist/components/ui/popover/PopoverContent.vue.d.ts.map +1 -1
- package/dist/{es-61b41785.mjs → es-8146fb1b.mjs} +1 -1
- package/dist/{index-10160248.mjs → index-724ed422.mjs} +8813 -9353
- package/dist/locales/en.json.d.ts +1 -2
- package/dist/locales/es.json.d.ts +1 -2
- package/dist/locales/pt_br.json.d.ts +1 -2
- package/dist/{pt-br-31a68683.mjs → pt-br-af294ec9.mjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/unnnic.mjs +151 -158
- package/dist/unnnic.umd.js +36 -35
- package/dist/utils/call.d.ts +1 -2
- package/dist/utils/call.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/assets/scss/scheme-colors.scss +223 -309
- package/src/components/Alert/Alert.vue +135 -26
- package/src/components/Alert/AlertBanner.vue +182 -0
- package/src/components/Alert/AlertCaller.vue +49 -0
- package/src/components/Alert/Version1dot1.vue +36 -0
- package/src/components/Alert/__tests__/Alert.spec.js +45 -2
- package/src/components/Alert/__tests__/AlertBanner.spec.js +89 -0
- package/src/components/Alert/__tests__/AlertCaller.spec.js +98 -0
- package/src/components/Alert/__tests__/Version1dot1.spec.js +21 -0
- package/src/components/Alert/__tests__/__snapshots__/Alert.spec.js.snap +7 -11
- package/src/components/Alert/__tests__/__snapshots__/AlertBanner.spec.js.snap +2 -2
- package/src/components/Alert/__tests__/__snapshots__/Version1dot1.spec.js.snap +1 -1
- package/src/components/Button/Button.vue +117 -67
- package/src/components/Button/types.ts +1 -0
- package/src/components/ChatsContact/ChatsContact.vue +6 -10
- package/src/components/Checkbox/Checkbox.vue +65 -117
- package/src/components/Checkbox/__tests__/Checkbox.spec.js +21 -6
- package/src/components/FormElement/FormElement.vue +93 -63
- package/src/components/Icon.vue +0 -2
- package/src/components/Input/BaseInput.vue +14 -33
- package/src/components/Input/Input.scss +22 -22
- package/src/components/Input/Input.vue +56 -79
- package/src/components/Input/TextInput.vue +65 -81
- package/src/components/Input/__test__/Input.spec.js +33 -13
- package/src/components/Input/__test__/TextInput.spec.js +8 -6
- package/src/components/Input/__test__/__snapshots__/Input.spec.js.snap +4 -17
- package/src/components/Input/__test__/__snapshots__/TextInput.spec.js.snap +1 -7
- package/src/components/Label/Label.vue +21 -52
- package/src/components/Label/__tests__/Label.spec.js +1 -1
- package/src/components/Label/__tests__/__snapshots__/Label.spec.js.snap +1 -1
- package/src/components/Radio/Radio.vue +66 -118
- package/src/components/Radio/__test__/Radio.spec.js +20 -14
- package/src/components/Radio/__test__/__snapshots__/Radio.spec.js.snap +3 -4
- package/src/components/SelectSmart/SelectSmart.vue +3 -4
- package/src/components/Switch/Switch.vue +91 -132
- package/src/components/Switch/__tests__/Switch.spec.js +75 -8
- package/src/components/Switch/__tests__/__snapshots__/Switch.spec.js.snap +6 -5
- package/src/components/Tab/Tab.vue +23 -37
- package/src/components/Tab/__test__/__snapshots__/Tab.spec.js.snap +1 -1
- package/src/components/TableNext/__test__/__snapshots__/TableNext.spec.js.snap +2 -2
- package/src/components/TableNext/__test__/__snapshots__/TablePagination.spec.js.snap +2 -2
- package/src/components/Tag/BrandTag.vue +96 -0
- package/src/components/Tag/DefaultTag.vue +107 -51
- package/src/components/Tag/IndicatorTag.vue +107 -0
- package/src/components/Tag/Tag.vue +79 -32
- package/src/components/Tag/TagNext.vue +60 -0
- package/src/components/TextArea/TextArea.vue +12 -41
- package/src/components/TextArea/__test__/__snapshots__/TextArea.spec.js.snap +3 -11
- package/src/components/index.ts +18 -33
- package/src/locales/en.json +1 -2
- package/src/locales/es.json +1 -2
- package/src/locales/pt_br.json +1 -2
- package/src/stories/Alert.stories.js +67 -6
- package/src/stories/Button.stories.js +39 -29
- package/src/stories/Checkbox.stories.js +4 -11
- package/src/stories/Input.stories.js +76 -71
- package/src/stories/Label.stories.js +0 -7
- package/src/stories/Radio.stories.js +1 -28
- package/src/stories/Switch.stories.js +5 -10
- package/src/stories/Tab.stories.js +4 -11
- package/src/stories/Tag.stories.js +43 -24
- package/src/stories/TextArea.stories.js +2 -14
- package/src/types/scheme-colors.d.ts +0 -1
- package/src/utils/call.js +18 -46
- package/dist/assets/tokens/colors.json.d.ts +0 -376
- package/dist/components/CheckboxGroup/CheckboxGroup.vue.d.ts +0 -28
- package/dist/components/CheckboxGroup/CheckboxGroup.vue.d.ts.map +0 -1
- package/dist/components/PageHeader/PageHeader.vue.d.ts +0 -28
- package/dist/components/PageHeader/PageHeader.vue.d.ts.map +0 -1
- package/dist/components/PageHeader/index.d.ts +0 -3
- package/dist/components/PageHeader/index.d.ts.map +0 -1
- package/dist/components/PageHeader/types.d.ts +0 -9
- package/dist/components/PageHeader/types.d.ts.map +0 -1
- package/dist/components/Tag/types.d.ts +0 -18
- package/dist/components/Tag/types.d.ts.map +0 -1
- package/dist/components/Toast/Toast.vue.d.ts +0 -16
- package/dist/components/Toast/Toast.vue.d.ts.map +0 -1
- package/dist/components/Toast/ToastManager.d.ts +0 -14
- package/dist/components/Toast/ToastManager.d.ts.map +0 -1
- package/dist/components/Toast/types.d.ts +0 -35
- package/dist/components/Toast/types.d.ts.map +0 -1
- package/src/assets/icons/checkbox-checked-disabled.svg +0 -3
- package/src/assets/icons/checkbox-checked.svg +0 -3
- package/src/assets/icons/checkbox-less-disabled.svg +0 -3
- package/src/assets/icons/checkbox-less.svg +0 -3
- package/src/assets/icons/radio-checked.svg +0 -3
- package/src/assets/icons/switch-checked-disabled.svg +0 -3
- package/src/assets/icons/switch-checked.svg +0 -3
- package/src/components/CheckboxGroup/CheckboxGroup.vue +0 -96
- package/src/components/MultiSelectV2/MultSelectOption.vue +0 -67
- package/src/components/MultiSelectV2/__tests__/MultiSelect.spec.js +0 -556
- package/src/components/MultiSelectV2/__tests__/MultiSelectOption.spec.js +0 -229
- package/src/components/MultiSelectV2/__tests__/__snapshots__/MultiSelect.spec.js.snap +0 -121
- package/src/components/MultiSelectV2/__tests__/__snapshots__/MultiSelectOption.spec.js.snap +0 -51
- package/src/components/MultiSelectV2/index.vue +0 -221
- package/src/components/PageHeader/PageHeader.vue +0 -148
- package/src/components/PageHeader/index.ts +0 -2
- package/src/components/PageHeader/types.ts +0 -10
- package/src/components/Popover/__tests__/Popover.spec.js +0 -147
- package/src/components/Popover/__tests__/__snapshots__/Popover.spec.js.snap +0 -8
- package/src/components/Popover/index.vue +0 -146
- package/src/components/RadioGroup/RadioGroup.vue +0 -142
- package/src/components/Select/SelectOption.vue +0 -65
- package/src/components/Select/__tests__/Select.spec.js +0 -412
- package/src/components/Select/__tests__/SelectItem.spec.js +0 -330
- package/src/components/Select/__tests__/SelectOption.spec.js +0 -174
- package/src/components/Select/__tests__/__snapshots__/Select.spec.js.snap +0 -97
- package/src/components/Select/__tests__/__snapshots__/SelectItem.spec.js.snap +0 -15
- package/src/components/Select/__tests__/__snapshots__/SelectOption.spec.js.snap +0 -25
- package/src/components/Select/index.vue +0 -249
- package/src/components/Tag/types.ts +0 -19
- package/src/components/Toast/Toast.vue +0 -246
- package/src/components/Toast/ToastManager.ts +0 -110
- package/src/components/Toast/__tests__/Toast.spec.js +0 -291
- package/src/components/Toast/__tests__/ToastManager.spec.js +0 -294
- package/src/components/Toast/types.ts +0 -57
- package/src/stories/CheckboxGroup.stories.js +0 -105
- package/src/stories/MultiSelectV2.stories.js +0 -158
- package/src/stories/PageHeader.stories.js +0 -330
- package/src/stories/RadioGroup.stories.js +0 -144
- package/src/stories/Select.stories.js +0 -158
- package/src/stories/Toast.mdx +0 -123
- package/src/stories/Toast.stories.js +0 -126
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
:class="`unnnic-tag
|
|
4
|
+
${clickable ? 'unnnic-tag--clickable' : ''}`"
|
|
5
|
+
>
|
|
6
|
+
<ToolTip
|
|
7
|
+
:enabled="enableTooltip"
|
|
8
|
+
:text="tooltipText"
|
|
9
|
+
side="bottom"
|
|
10
|
+
>
|
|
11
|
+
<span class="unnnic-tag__count">{{ count }}</span>
|
|
12
|
+
</ToolTip>
|
|
13
|
+
<span class="unnnic-tag__label">{{ text }}</span>
|
|
14
|
+
<UnnnicIcon
|
|
15
|
+
v-if="hasBackButton"
|
|
16
|
+
icon="arrow-right-1-1"
|
|
17
|
+
class="unnnic-tag__icon"
|
|
18
|
+
scheme="neutral-darkest"
|
|
19
|
+
size="xs"
|
|
20
|
+
/>
|
|
21
|
+
</div>
|
|
22
|
+
</template>
|
|
23
|
+
|
|
24
|
+
<script>
|
|
25
|
+
import UnnnicIcon from '../Icon.vue';
|
|
26
|
+
import ToolTip from '../ToolTip/ToolTip.vue';
|
|
27
|
+
|
|
28
|
+
export default {
|
|
29
|
+
name: 'UnnnicTag',
|
|
30
|
+
components: {
|
|
31
|
+
UnnnicIcon,
|
|
32
|
+
ToolTip,
|
|
33
|
+
},
|
|
34
|
+
props: {
|
|
35
|
+
text: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: null,
|
|
38
|
+
},
|
|
39
|
+
tooltipText: {
|
|
40
|
+
type: String,
|
|
41
|
+
default: null,
|
|
42
|
+
},
|
|
43
|
+
count: {
|
|
44
|
+
type: Number,
|
|
45
|
+
default: 0,
|
|
46
|
+
},
|
|
47
|
+
clickable: {
|
|
48
|
+
type: Boolean,
|
|
49
|
+
default: false,
|
|
50
|
+
},
|
|
51
|
+
hasBackButton: {
|
|
52
|
+
type: Boolean,
|
|
53
|
+
default: false,
|
|
54
|
+
},
|
|
55
|
+
enableTooltip: {
|
|
56
|
+
type: Boolean,
|
|
57
|
+
default: false,
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
};
|
|
61
|
+
</script>
|
|
62
|
+
|
|
63
|
+
<style lang="scss" scoped>
|
|
64
|
+
@use '@/assets/scss/unnnic' as *;
|
|
65
|
+
|
|
66
|
+
.unnnic-tag {
|
|
67
|
+
display: flex;
|
|
68
|
+
align-items: center;
|
|
69
|
+
justify-content: center;
|
|
70
|
+
border-radius: $unnnic-border-radius-sm;
|
|
71
|
+
background-color: $unnnic-color-background-sky;
|
|
72
|
+
padding: $unnnic-inset-nano;
|
|
73
|
+
border: $unnnic-border-width-thinner solid $unnnic-color-background-sky;
|
|
74
|
+
|
|
75
|
+
&:hover {
|
|
76
|
+
border: $unnnic-border-width-thinner solid $unnnic-color-neutral-cleanest;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
&--clickable {
|
|
80
|
+
cursor: pointer;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
&__count {
|
|
84
|
+
background-color: $unnnic-color-neutral-soft;
|
|
85
|
+
border-radius: $unnnic-border-radius-sm;
|
|
86
|
+
padding: $unnnic-inline-nano;
|
|
87
|
+
font-family: $unnnic-font-family-secondary;
|
|
88
|
+
font-size: $unnnic-font-size-body-md;
|
|
89
|
+
font-weight: $unnnic-font-weight-regular;
|
|
90
|
+
line-height: ($unnnic-font-size-body-md + $unnnic-line-height-medium);
|
|
91
|
+
color: $unnnic-color-neutral-darkest;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
&__label {
|
|
95
|
+
padding: 0 $unnnic-inline-xs;
|
|
96
|
+
font-family: $unnnic-font-family-secondary;
|
|
97
|
+
font-size: $unnnic-font-size-body-md;
|
|
98
|
+
font-weight: $unnnic-font-weight-regular;
|
|
99
|
+
line-height: ($unnnic-font-size-body-md + $unnnic-line-height-medium);
|
|
100
|
+
color: $unnnic-color-neutral-darkest;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
&__icon {
|
|
104
|
+
margin-right: $unnnic-inline-ant;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
</style>
|
|
@@ -1,43 +1,90 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
:isSelected="disabled || hasCloseIcon"
|
|
7
|
-
isClickable
|
|
8
|
-
@click="hasCloseIcon ? $emit('close') : $emit('click')"
|
|
9
|
-
/>
|
|
10
|
-
|
|
11
|
-
<DefaultTag
|
|
12
|
-
v-else
|
|
13
|
-
:size="type === 'next' ? 'small' : size"
|
|
2
|
+
<component
|
|
3
|
+
:is="currentComponent"
|
|
4
|
+
class="unnnic-tag-content"
|
|
5
|
+
v-bind="$attrs"
|
|
14
6
|
:text="text"
|
|
7
|
+
:disabled="disabled"
|
|
8
|
+
:hasCloseIcon="hasCloseIcon"
|
|
15
9
|
:scheme="scheme"
|
|
10
|
+
:count="count"
|
|
11
|
+
:hasBackButton="hasBackButton"
|
|
12
|
+
:clickable="clickable"
|
|
13
|
+
:tooltipText="tooltipText"
|
|
14
|
+
:enableTooltip="enableTooltip"
|
|
16
15
|
:leftIcon="leftIcon"
|
|
16
|
+
:rightIcon="rightIcon"
|
|
17
17
|
/>
|
|
18
18
|
</template>
|
|
19
19
|
|
|
20
|
-
<script
|
|
21
|
-
import UnnnicChip from '../Chip/Chip.vue';
|
|
20
|
+
<script>
|
|
22
21
|
import DefaultTag from './DefaultTag.vue';
|
|
23
|
-
import
|
|
22
|
+
import IndicatorTag from './IndicatorTag.vue';
|
|
23
|
+
import BrandTag from './BrandTag.vue';
|
|
24
|
+
import TagNext from './TagNext.vue';
|
|
24
25
|
|
|
25
|
-
|
|
26
|
+
export default {
|
|
26
27
|
name: 'UnnnicTag',
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
}
|
|
28
|
+
props: {
|
|
29
|
+
type: {
|
|
30
|
+
type: String,
|
|
31
|
+
default: 'default',
|
|
32
|
+
validator(value) {
|
|
33
|
+
return ['default', 'indicator', 'brand', 'next'].indexOf(value) !== -1;
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
text: {
|
|
37
|
+
type: String,
|
|
38
|
+
default: null,
|
|
39
|
+
},
|
|
40
|
+
tooltipText: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: null,
|
|
43
|
+
},
|
|
44
|
+
clickable: {
|
|
45
|
+
type: Boolean,
|
|
46
|
+
default: false,
|
|
47
|
+
},
|
|
48
|
+
count: {
|
|
49
|
+
type: Number,
|
|
50
|
+
default: 0,
|
|
51
|
+
},
|
|
52
|
+
disabled: {
|
|
53
|
+
type: Boolean,
|
|
54
|
+
default: false,
|
|
55
|
+
},
|
|
56
|
+
hasCloseIcon: {
|
|
57
|
+
type: Boolean,
|
|
58
|
+
default: false,
|
|
59
|
+
},
|
|
60
|
+
scheme: {
|
|
61
|
+
type: String,
|
|
62
|
+
default: 'aux-purple',
|
|
63
|
+
},
|
|
64
|
+
hasBackButton: {
|
|
65
|
+
type: Boolean,
|
|
66
|
+
default: false,
|
|
67
|
+
},
|
|
68
|
+
enableTooltip: {
|
|
69
|
+
type: Boolean,
|
|
70
|
+
default: false,
|
|
71
|
+
},
|
|
72
|
+
leftIcon: {
|
|
73
|
+
type: String,
|
|
74
|
+
default: '',
|
|
75
|
+
},
|
|
76
|
+
rightIcon: {
|
|
77
|
+
type: String,
|
|
78
|
+
default: '',
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
computed: {
|
|
82
|
+
currentComponent() {
|
|
83
|
+
if (this.type === 'indicator') return IndicatorTag;
|
|
84
|
+
if (this.type === 'brand') return BrandTag;
|
|
85
|
+
if (this.type === 'next') return TagNext;
|
|
86
|
+
return DefaultTag;
|
|
87
|
+
},
|
|
88
|
+
},
|
|
89
|
+
};
|
|
43
90
|
</script>
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<section :class="['unnnic-tag-next', `unnnic-tag-next--${scheme}`]">
|
|
3
|
+
<p class="unnnic-tag-next__text">
|
|
4
|
+
{{ text }}
|
|
5
|
+
</p>
|
|
6
|
+
</section>
|
|
7
|
+
</template>
|
|
8
|
+
|
|
9
|
+
<script>
|
|
10
|
+
export default {
|
|
11
|
+
name: 'TagNext',
|
|
12
|
+
props: {
|
|
13
|
+
text: {
|
|
14
|
+
type: String,
|
|
15
|
+
default: null,
|
|
16
|
+
},
|
|
17
|
+
scheme: {
|
|
18
|
+
type: String,
|
|
19
|
+
default: 'weni',
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
</script>
|
|
24
|
+
|
|
25
|
+
<style lang="scss" scoped>
|
|
26
|
+
@use '@/assets/scss/unnnic' as *;
|
|
27
|
+
|
|
28
|
+
.unnnic-tag-next {
|
|
29
|
+
display: flex;
|
|
30
|
+
align-items: center;
|
|
31
|
+
justify-content: center;
|
|
32
|
+
width: auto;
|
|
33
|
+
|
|
34
|
+
border-radius: $unnnic-border-radius-pill;
|
|
35
|
+
padding: 0 $unnnic-spacing-xs;
|
|
36
|
+
|
|
37
|
+
font-family: $unnnic-font-family-secondary;
|
|
38
|
+
font-size: $unnnic-font-size-body-md;
|
|
39
|
+
font-weight: $unnnic-font-weight-regular;
|
|
40
|
+
line-height: ($unnnic-font-size-body-md + $unnnic-line-height-medium);
|
|
41
|
+
|
|
42
|
+
&__text {
|
|
43
|
+
margin: 0;
|
|
44
|
+
|
|
45
|
+
overflow: hidden;
|
|
46
|
+
white-space: nowrap;
|
|
47
|
+
text-overflow: ellipsis;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&--aux-purple {
|
|
51
|
+
background-color: $unnnic-color-aux-purple-100;
|
|
52
|
+
color: $unnnic-color-aux-purple-500;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
&--weni {
|
|
56
|
+
background-color: $unnnic-color-weni-100;
|
|
57
|
+
color: $unnnic-color-weni-600;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
</style>
|
|
@@ -4,8 +4,7 @@
|
|
|
4
4
|
:size="size"
|
|
5
5
|
:disabled="disabled"
|
|
6
6
|
:message="message"
|
|
7
|
-
:
|
|
8
|
-
:error="computedError"
|
|
7
|
+
:error="errors.join(', ') || type === 'error'"
|
|
9
8
|
>
|
|
10
9
|
<textarea
|
|
11
10
|
ref="textarea"
|
|
@@ -19,14 +18,13 @@
|
|
|
19
18
|
:disabled="disabled"
|
|
20
19
|
:value="modelValue"
|
|
21
20
|
@input="$emit('update:modelValue', fullySanitize($event.target.value))"
|
|
22
|
-
|
|
21
|
+
></textarea>
|
|
23
22
|
|
|
24
23
|
<template
|
|
25
24
|
v-if="maxLength"
|
|
26
25
|
#rightMessage
|
|
26
|
+
>{{ modelValue.length }}/{{ maxLength }}</template
|
|
27
27
|
>
|
|
28
|
-
{{ modelValue.length }}/{{ maxLength }}
|
|
29
|
-
</template>
|
|
30
28
|
</UnnnicFormElement>
|
|
31
29
|
</template>
|
|
32
30
|
|
|
@@ -45,14 +43,6 @@ export default {
|
|
|
45
43
|
default: 'md',
|
|
46
44
|
},
|
|
47
45
|
|
|
48
|
-
resize: {
|
|
49
|
-
type: String,
|
|
50
|
-
default: 'vertical',
|
|
51
|
-
validator(value) {
|
|
52
|
-
return ['none', 'vertical'].indexOf(value) !== -1;
|
|
53
|
-
},
|
|
54
|
-
},
|
|
55
|
-
|
|
56
46
|
label: {
|
|
57
47
|
type: String,
|
|
58
48
|
},
|
|
@@ -86,28 +76,13 @@ export default {
|
|
|
86
76
|
},
|
|
87
77
|
},
|
|
88
78
|
|
|
89
|
-
tooltip: {
|
|
90
|
-
type: String,
|
|
91
|
-
default: '',
|
|
92
|
-
},
|
|
93
|
-
|
|
94
79
|
errors: {
|
|
95
|
-
type:
|
|
80
|
+
type: Array,
|
|
96
81
|
default: () => [],
|
|
97
82
|
},
|
|
98
83
|
},
|
|
99
84
|
emits: ['update:modelValue'],
|
|
100
85
|
|
|
101
|
-
computed: {
|
|
102
|
-
computedError() {
|
|
103
|
-
if (Array.isArray(this.errors)) {
|
|
104
|
-
return this.errors.join(', ') || this.type === 'error';
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
return this.errors || this.type === 'error';
|
|
108
|
-
},
|
|
109
|
-
},
|
|
110
|
-
|
|
111
86
|
methods: {
|
|
112
87
|
fullySanitize,
|
|
113
88
|
focus() {
|
|
@@ -121,35 +96,31 @@ export default {
|
|
|
121
96
|
@use '@/assets/scss/unnnic' as *;
|
|
122
97
|
@use '@/components/Input/Input' as *;
|
|
123
98
|
|
|
124
|
-
* {
|
|
125
|
-
margin: 0;
|
|
126
|
-
padding: 0;
|
|
127
|
-
box-sizing: border-box;
|
|
128
|
-
}
|
|
129
|
-
|
|
130
99
|
.unnnic-text-area {
|
|
131
100
|
&__textarea {
|
|
132
101
|
@include input-base;
|
|
133
102
|
|
|
134
103
|
display: block;
|
|
135
104
|
width: 100%;
|
|
136
|
-
|
|
137
|
-
|
|
105
|
+
resize: vertical;
|
|
106
|
+
box-sizing: border-box;
|
|
138
107
|
|
|
139
108
|
scrollbar-width: thin;
|
|
140
109
|
|
|
141
|
-
padding: $unnnic-space-3 $unnnic-space-4;
|
|
142
|
-
|
|
143
110
|
&--size-md {
|
|
144
111
|
@include input-md-font;
|
|
145
112
|
|
|
146
|
-
min-height:
|
|
113
|
+
min-height: 6.25 * $unnnic-font-size;
|
|
114
|
+
padding: ($unnnic-spacing-ant - $unnnic-border-width-thinner)
|
|
115
|
+
($unnnic-spacing-sm - $unnnic-border-width-thinner);
|
|
147
116
|
}
|
|
148
117
|
|
|
149
118
|
&--size-sm {
|
|
150
119
|
@include input-sm-font;
|
|
151
120
|
|
|
152
|
-
min-height: $unnnic-
|
|
121
|
+
min-height: 5 * $unnnic-font-size;
|
|
122
|
+
padding: ($unnnic-spacing-xs)
|
|
123
|
+
($unnnic-spacing-sm - $unnnic-border-width-thinner);
|
|
153
124
|
}
|
|
154
125
|
|
|
155
126
|
&.unnnic-text-area__textarea--type-error {
|
|
@@ -2,16 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
exports[`TextArea.vue > matches the snapshot 1`] = `
|
|
4
4
|
"<section data-v-9f8d6c86="" data-v-735b3c51="" class="unnnic-form-element">
|
|
5
|
-
<
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
</section><textarea data-v-735b3c51="" class="unnnic-text-area__textarea unnnic-text-area__textarea--size-md unnnic-text-area__textarea--type-normal" placeholder="Enter text" maxlength="200" value=""></textarea>
|
|
9
|
-
<section data-v-9f8d6c86="" class="unnnic-form-element__hints-container">
|
|
10
|
-
<section data-v-9f8d6c86="" class="unnnic-form-element__message-container">
|
|
11
|
-
<!--v-if-->
|
|
12
|
-
<!--v-if-->
|
|
13
|
-
</section>
|
|
14
|
-
<p data-v-9f8d6c86="">0/200</p>
|
|
15
|
-
</section>
|
|
5
|
+
<p data-v-9f8d6c86="" class="unnnic-form-element__label">Description</p><textarea data-v-735b3c51="" class="unnnic-text-area__textarea unnnic-text-area__textarea--size-md unnnic-text-area__textarea--type-normal" placeholder="Enter text" maxlength="200" value=""></textarea>
|
|
6
|
+
<!--v-if-->
|
|
7
|
+
<p data-v-9f8d6c86="" class="unnnic-form-element__message"> <span data-v-9f8d6c86="" class="unnnic-form-element__right-message">0/200</span></p>
|
|
16
8
|
</section>"
|
|
17
9
|
`;
|
package/src/components/index.ts
CHANGED
|
@@ -25,7 +25,6 @@ import cardImage from './CardImage/CardImage.vue';
|
|
|
25
25
|
import cardProject from './CardProject/CardProject.vue';
|
|
26
26
|
import cardInformation from './CardInformation/CardInformation.vue';
|
|
27
27
|
import checkbox from './Checkbox/Checkbox.vue';
|
|
28
|
-
import checkboxGroup from './CheckboxGroup/CheckboxGroup.vue';
|
|
29
28
|
import collapse from './Collapse/Collapse.vue';
|
|
30
29
|
import radio from './Radio/Radio.vue';
|
|
31
30
|
import languageSelect from './Dropdown/LanguageSelect.vue';
|
|
@@ -91,19 +90,16 @@ import Navigator from './Navigator/index.vue';
|
|
|
91
90
|
import SelectTime from './SelectTime/index.vue';
|
|
92
91
|
import DataTable from './DataTable/index.vue';
|
|
93
92
|
import Chip from './Chip/Chip.vue';
|
|
94
|
-
import
|
|
95
|
-
import
|
|
93
|
+
import Tabs from './ui/tabs/Tabs.vue';
|
|
94
|
+
import TabsList from './ui/tabs/TabsList.vue';
|
|
95
|
+
import TabsTrigger from './ui/tabs/TabsTrigger.vue';
|
|
96
|
+
import TabsContent from './ui/tabs/TabsContent.vue';
|
|
96
97
|
import Popover from './ui/popover/Popover.vue';
|
|
97
98
|
import PopoverContent from './ui/popover/PopoverContent.vue';
|
|
98
99
|
import PopoverTrigger from './ui/popover/PopoverTrigger.vue';
|
|
99
100
|
import PopoverFooter from './ui/popover/PopoverFooter.vue';
|
|
100
101
|
import TemplatePreview from './TemplatePreview/TemplatePreview.vue';
|
|
101
102
|
import TemplatePreviewModal from './TemplatePreview/TemplatePreviewModal.vue';
|
|
102
|
-
import Tabs from './ui/tabs/Tabs.vue';
|
|
103
|
-
import TabsList from './ui/tabs/TabsList.vue';
|
|
104
|
-
import TabsTrigger from './ui/tabs/TabsTrigger.vue';
|
|
105
|
-
import TabsContent from './ui/tabs/TabsContent.vue';
|
|
106
|
-
import PageHeader from './PageHeader/PageHeader.vue';
|
|
107
103
|
|
|
108
104
|
type VueComponent = Component;
|
|
109
105
|
|
|
@@ -138,7 +134,6 @@ export const components: ComponentsMap = {
|
|
|
138
134
|
unnnicCardProject: cardProject,
|
|
139
135
|
unnnicCardInformation: cardInformation,
|
|
140
136
|
unnnicCheckbox: checkbox,
|
|
141
|
-
unnnicCheckboxGroup: checkboxGroup,
|
|
142
137
|
unnnicCollapse: collapse,
|
|
143
138
|
unnnicRadio: radio,
|
|
144
139
|
unnnicLanguageSelect: languageSelect,
|
|
@@ -207,16 +202,13 @@ export const components: ComponentsMap = {
|
|
|
207
202
|
unnnicTemplatePreviewModal: TemplatePreviewModal,
|
|
208
203
|
unnnicDataTable: DataTable,
|
|
209
204
|
unnnicChip: Chip,
|
|
210
|
-
unnnicToast: Toast,
|
|
211
|
-
unnnicToastManager: toast,
|
|
212
|
-
unnnicPopover: Popover,
|
|
213
|
-
unnnicPopoverContent: PopoverContent,
|
|
214
|
-
unnnicPopoverTrigger: PopoverTrigger,
|
|
215
205
|
unnnicTabs: Tabs,
|
|
216
206
|
unnnicTabsList: TabsList,
|
|
217
207
|
unnnicTabsTrigger: TabsTrigger,
|
|
218
208
|
unnnicTabsContent: TabsContent,
|
|
219
|
-
|
|
209
|
+
unnnicPopover: Popover,
|
|
210
|
+
unnnicPopoverContent: PopoverContent,
|
|
211
|
+
unnnicPopoverTrigger: PopoverTrigger,
|
|
220
212
|
};
|
|
221
213
|
|
|
222
214
|
export const unnnicFontSize = fontSize;
|
|
@@ -246,7 +238,6 @@ export const unnnicCardImage = cardImage as VueComponent;
|
|
|
246
238
|
export const unnnicCardProject = cardProject as VueComponent;
|
|
247
239
|
export const unnnicCardInformation = cardInformation;
|
|
248
240
|
export const unnnicCheckbox = checkbox;
|
|
249
|
-
export const unnnicCheckboxGroup = checkboxGroup;
|
|
250
241
|
export const unnnicCollapse = collapse;
|
|
251
242
|
export const unnnicRadio = radio;
|
|
252
243
|
export const unnniclanguageSelect = languageSelect as VueComponent;
|
|
@@ -269,7 +260,7 @@ export const unnnicAccordion = accordion;
|
|
|
269
260
|
export const unnnicIndicator = indicator;
|
|
270
261
|
export const unnnicSkeletonLoading = skeletonLoading;
|
|
271
262
|
export const unnnicCarousel = carousel;
|
|
272
|
-
export const unnnicLabel = label
|
|
263
|
+
export const unnnicLabel = label;
|
|
273
264
|
export const unnnicTab = tab;
|
|
274
265
|
export const unnnicTabsExpanded = tabsExpanded;
|
|
275
266
|
export const unnnicBanner = banner;
|
|
@@ -313,21 +304,19 @@ export const unnnicNavigator = Navigator;
|
|
|
313
304
|
export const unnnicDataTable = DataTable as VueComponent;
|
|
314
305
|
export const unnnicSelectTime = SelectTime as VueComponent;
|
|
315
306
|
export const unnnicChip = Chip;
|
|
316
|
-
export const
|
|
317
|
-
export const
|
|
307
|
+
export const unnnicTabs = Tabs;
|
|
308
|
+
export const unnnicTabsList = TabsList;
|
|
309
|
+
export const unnnicTabsTrigger = TabsTrigger;
|
|
310
|
+
export const unnnicTabsContent = TabsContent;
|
|
318
311
|
export const unnnicPopover = Popover;
|
|
319
312
|
export const unnnicPopoverContent = PopoverContent;
|
|
320
313
|
export const unnnicPopoverTrigger = PopoverTrigger;
|
|
321
314
|
export const unnnicPopoverFooter = PopoverFooter;
|
|
322
315
|
export const unnnicTemplatePreview = TemplatePreview as VueComponent;
|
|
323
316
|
export const unnnicTemplatePreviewModal = TemplatePreviewModal as VueComponent;
|
|
324
|
-
export const unnnicTabs = Tabs;
|
|
325
|
-
export const unnnicTabsList = TabsList;
|
|
326
|
-
export const unnnicTabsTrigger = TabsTrigger;
|
|
327
|
-
export const unnnicTabsContent = TabsContent;
|
|
328
|
-
export const unnnicPageHeader = PageHeader;
|
|
329
317
|
|
|
330
318
|
export const UnnnicFontSize = fontSize;
|
|
319
|
+
export const UnnnicFormElement = formElement;
|
|
331
320
|
export const UnnnicInput = input;
|
|
332
321
|
export const UnnnicInputNext = inputNext;
|
|
333
322
|
export const UnnnicInputDatePicker = inputDatePicker;
|
|
@@ -353,7 +342,6 @@ export const UnnnicCardImage = cardImage as VueComponent;
|
|
|
353
342
|
export const UnnnicCardProject = cardProject as VueComponent;
|
|
354
343
|
export const UnnnicCardInformation = cardInformation;
|
|
355
344
|
export const UnnnicCheckbox = checkbox;
|
|
356
|
-
export const UnnnicCheckboxGroup = checkboxGroup;
|
|
357
345
|
export const UnnnicCollapse = collapse;
|
|
358
346
|
export const UnnnicRadio = radio;
|
|
359
347
|
export const UnnniclanguageSelect = languageSelect as VueComponent;
|
|
@@ -376,7 +364,7 @@ export const UnnnicAccordion = accordion;
|
|
|
376
364
|
export const UnnnicIndicator = indicator;
|
|
377
365
|
export const UnnnicSkeletonLoading = skeletonLoading;
|
|
378
366
|
export const UnnnicCarousel = carousel;
|
|
379
|
-
export const UnnnicLabel = label
|
|
367
|
+
export const UnnnicLabel = label;
|
|
380
368
|
export const UnnnicTab = tab;
|
|
381
369
|
export const UnnnicTabsExpanded = tabsExpanded;
|
|
382
370
|
export const UnnnicBanner = banner;
|
|
@@ -420,16 +408,13 @@ export const UnnnicNavigator = Navigator;
|
|
|
420
408
|
export const UnnnicDataTable = DataTable as VueComponent;
|
|
421
409
|
export const UnnnicSelectTime = SelectTime as VueComponent;
|
|
422
410
|
export const UnnnicChip = Chip;
|
|
423
|
-
export const
|
|
424
|
-
export const
|
|
411
|
+
export const UnnnicTabs = Tabs;
|
|
412
|
+
export const UnnnicTabsList = TabsList;
|
|
413
|
+
export const UnnnicTabsTrigger = TabsTrigger;
|
|
414
|
+
export const UnnnicTabsContent = TabsContent;
|
|
425
415
|
export const UnnnicPopover = Popover;
|
|
426
416
|
export const UnnnicPopoverContent = PopoverContent;
|
|
427
417
|
export const UnnnicPopoverTrigger = PopoverTrigger;
|
|
428
418
|
export const UnnnicPopoverFooter = PopoverFooter;
|
|
429
419
|
export const UnnnicTemplatePreview = TemplatePreview as VueComponent;
|
|
430
420
|
export const UnnnicTemplatePreviewModal = TemplatePreviewModal as VueComponent;
|
|
431
|
-
export const UnnnicTabs = Tabs;
|
|
432
|
-
export const UnnnicTabsList = TabsList;
|
|
433
|
-
export const UnnnicTabsTrigger = TabsTrigger;
|
|
434
|
-
export const UnnnicTabsContent = TabsContent;
|
|
435
|
-
export const UnnnicPageHeader = PageHeader;
|
package/src/locales/en.json
CHANGED
package/src/locales/es.json
CHANGED