@weni/unnnic-system 3.7.0 → 3.7.1-alpha.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 +1 -1
- package/dist/components/Accordion/Accordion.vue.d.ts +1 -1
- package/dist/components/Alert/Alert.vue.d.ts +18 -117
- package/dist/components/Alert/Alert.vue.d.ts.map +1 -1
- package/dist/components/Alert/Version1dot1.vue.d.ts +2 -38
- 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 +5 -5
- 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 +24 -31
- 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 +7 -7
- package/dist/components/Carousel/TagCarousel.vue.d.ts +6 -6
- 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 +27 -34
- 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 +19 -26
- package/dist/components/Checkbox/Checkbox.vue.d.ts.map +1 -1
- package/dist/components/CheckboxGroup/CheckboxGroup.vue.d.ts +28 -0
- package/dist/components/CheckboxGroup/CheckboxGroup.vue.d.ts.map +1 -0
- 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 +251 -41
- 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 +51 -28
- 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 +33 -2
- package/dist/components/Input/BaseInput.vue.d.ts.map +1 -1
- package/dist/components/Input/Input.vue.d.ts +251 -41
- package/dist/components/Input/Input.vue.d.ts.map +1 -1
- package/dist/components/Input/TextInput.vue.d.ts +85 -25
- package/dist/components/Input/TextInput.vue.d.ts.map +1 -1
- package/dist/components/InputDatePicker/InputDatePicker.vue.d.ts +257 -47
- package/dist/components/InputNext/InputNext.vue.d.ts +5 -5
- package/dist/components/Label/Label.vue.d.ts +9 -15
- 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 +199 -34
- package/dist/components/ModalDialog/ModalDialog.vue.d.ts.map +1 -1
- package/dist/components/ModalNext/ModalNext.vue.d.ts +256 -46
- package/dist/components/ModalUpload/ModalUpload.vue.d.ts +8 -8
- package/dist/components/MoodRating/MoodRating.vue.d.ts +1 -1
- package/dist/components/MultiSelect/MultiSelect.vue.d.ts +20 -14
- 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 +8 -6
- package/dist/components/Radio/Radio.vue.d.ts.map +1 -1
- package/dist/components/SelectSmart/SelectSmart.vue.d.ts +113 -60
- package/dist/components/SelectSmart/SelectSmartMultipleHeader.vue.d.ts +5 -5
- package/dist/components/SelectSmart/SelectSmartOption.vue.d.ts +21 -28
- package/dist/components/SelectSmart/SelectSmartOption.vue.d.ts.map +1 -1
- package/dist/components/SelectTime/index.vue.d.ts +85 -25
- 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 +55 -21
- package/dist/components/Switch/Switch.vue.d.ts.map +1 -1
- package/dist/components/Tab/Tab.vue.d.ts +13 -2
- 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 +1 -1
- package/dist/components/Tag/DefaultTag.vue.d.ts +1 -1
- package/dist/components/Tag/IndicatorTag.vue.d.ts +2 -2
- package/dist/components/Tag/Tag.vue.d.ts +5 -5
- package/dist/components/TextArea/TextArea.vue.d.ts +66 -30
- package/dist/components/TextArea/TextArea.vue.d.ts.map +1 -1
- package/dist/components/Toast/Toast.vue.d.ts +16 -0
- package/dist/components/Toast/Toast.vue.d.ts.map +1 -0
- package/dist/components/Toast/ToastManager.d.ts +14 -0
- package/dist/components/Toast/ToastManager.d.ts.map +1 -0
- package/dist/components/Toast/types.d.ts +35 -0
- package/dist/components/Toast/types.d.ts.map +1 -0
- 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 +4043 -1328
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/ui/dialog/Dialog.vue.d.ts +23 -0
- package/dist/components/ui/dialog/Dialog.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/DialogClose.vue.d.ts +19 -0
- package/dist/components/ui/dialog/DialogClose.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/DialogContent.vue.d.ts +40 -0
- package/dist/components/ui/dialog/DialogContent.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/DialogFooter.vue.d.ts +25 -0
- package/dist/components/ui/dialog/DialogFooter.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/DialogHeader.vue.d.ts +29 -0
- package/dist/components/ui/dialog/DialogHeader.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/DialogTitle.vue.d.ts +23 -0
- package/dist/components/ui/dialog/DialogTitle.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/DialogTrigger.vue.d.ts +19 -0
- package/dist/components/ui/dialog/DialogTrigger.vue.d.ts.map +1 -0
- package/dist/components/ui/dialog/index.d.ts +8 -0
- package/dist/components/ui/dialog/index.d.ts.map +1 -0
- package/dist/components/ui/popover/Popover.vue.d.ts +23 -0
- package/dist/components/ui/popover/Popover.vue.d.ts.map +1 -0
- package/dist/components/ui/popover/PopoverContent.vue.d.ts +43 -0
- package/dist/components/ui/popover/PopoverContent.vue.d.ts.map +1 -0
- package/dist/components/ui/popover/PopoverTrigger.vue.d.ts +19 -0
- package/dist/components/ui/popover/PopoverTrigger.vue.d.ts.map +1 -0
- package/dist/components/ui/popover/index.d.ts +5 -0
- package/dist/components/ui/popover/index.d.ts.map +1 -0
- package/dist/{es-c4737166.mjs → es-3d0df246.mjs} +1 -1
- package/dist/{index-bd5f89f9.mjs → index-8cf13f7a.mjs} +18886 -11928
- package/dist/locales/en.json.d.ts +2 -1
- package/dist/locales/es.json.d.ts +2 -1
- package/dist/locales/pt_br.json.d.ts +2 -1
- package/dist/{pt-br-ec3b3330.mjs → pt-br-b04d6fba.mjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/unnnic.mjs +195 -172
- package/dist/unnnic.umd.js +56 -50
- package/dist/utils/call.d.ts +2 -1
- package/dist/utils/call.d.ts.map +1 -1
- package/package.json +2 -1
- package/src/assets/icons/checkbox-checked-disabled.svg +3 -0
- package/src/assets/icons/checkbox-checked.svg +3 -0
- package/src/assets/icons/checkbox-less-disabled.svg +3 -0
- package/src/assets/icons/checkbox-less.svg +3 -0
- package/src/assets/icons/radio-checked.svg +3 -0
- package/src/assets/icons/switch-checked-disabled.svg +3 -0
- package/src/assets/icons/switch-checked.svg +3 -0
- package/src/assets/scss/tailwind.scss +8 -0
- package/src/components/Alert/Alert.vue +26 -135
- package/src/components/Alert/SIMPLE_MIGRATION_GUIDE.md +152 -0
- package/src/components/Alert/Version1dot1.vue +0 -36
- package/src/components/Alert/__tests__/Alert.spec.js +2 -45
- package/src/components/Alert/__tests__/Version1dot1.spec.js +0 -21
- package/src/components/Alert/__tests__/__snapshots__/Alert.spec.js.snap +11 -7
- package/src/components/Alert/__tests__/__snapshots__/Version1dot1.spec.js.snap +2 -2
- package/src/components/Button/Button.vue +72 -117
- package/src/components/Button/types.ts +0 -1
- package/src/components/Checkbox/Checkbox.vue +98 -64
- package/src/components/Checkbox/__tests__/Checkbox.spec.js +6 -21
- package/src/components/CheckboxGroup/CheckboxGroup.vue +96 -0
- package/src/components/FormElement/FormElement.vue +63 -93
- package/src/components/Icon.vue +3 -0
- package/src/components/Input/BaseInput.vue +33 -14
- package/src/components/Input/Input.scss +19 -21
- package/src/components/Input/Input.vue +77 -56
- package/src/components/Input/TextInput.vue +80 -68
- package/src/components/Input/__test__/TextInput.spec.js +6 -8
- package/src/components/Input/__test__/__snapshots__/Input.spec.js.snap +14 -5
- package/src/components/Input/__test__/__snapshots__/TextInput.spec.js.snap +1 -1
- package/src/components/Label/Label.vue +52 -21
- 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/ModalDialog/ModalDialog.vue +60 -146
- package/src/components/ModalDialog/__tests__/__snapshots__/ModalDialog.spec.js.snap +1 -22
- package/src/components/Popover/__tests__/Popover.spec.js +147 -0
- package/src/components/Popover/__tests__/__snapshots__/Popover.spec.js.snap +8 -0
- package/src/components/Popover/index.vue +146 -0
- package/src/components/Radio/Radio.vue +80 -67
- package/src/components/Radio/__test__/Radio.spec.js +14 -20
- package/src/components/Radio/__test__/__snapshots__/Radio.spec.js.snap +3 -3
- package/src/components/RadioGroup/RadioGroup.vue +142 -0
- package/src/components/Select/SelectOption.vue +65 -0
- package/src/components/Select/__tests__/Select.spec.js +412 -0
- package/src/components/Select/__tests__/SelectItem.spec.js +330 -0
- package/src/components/Select/__tests__/SelectOption.spec.js +174 -0
- package/src/components/Select/__tests__/__snapshots__/Select.spec.js.snap +97 -0
- package/src/components/Select/__tests__/__snapshots__/SelectItem.spec.js.snap +15 -0
- package/src/components/Select/__tests__/__snapshots__/SelectOption.spec.js.snap +25 -0
- package/src/components/Select/index.vue +245 -0
- package/src/components/SelectSmart/SelectSmart.vue +4 -3
- package/src/components/Switch/Switch.vue +123 -96
- package/src/components/Switch/__tests__/Switch.spec.js +8 -75
- package/src/components/Switch/__tests__/__snapshots__/Switch.spec.js.snap +5 -6
- package/src/components/Tab/Tab.vue +37 -23
- 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/TextArea/TextArea.vue +34 -11
- package/src/components/TextArea/__test__/__snapshots__/TextArea.spec.js.snap +11 -3
- package/src/components/Toast/Toast.vue +246 -0
- package/src/components/Toast/ToastManager.ts +110 -0
- package/src/components/Toast/__tests__/Toast.spec.js +284 -0
- package/src/components/Toast/__tests__/ToastManager.spec.js +294 -0
- package/src/components/Toast/types.ts +57 -0
- package/src/components/index.ts +58 -9
- package/src/components/ui/dialog/Dialog.vue +15 -0
- package/src/components/ui/dialog/DialogClose.vue +25 -0
- package/src/components/ui/dialog/DialogContent.vue +114 -0
- package/src/components/ui/dialog/DialogFooter.vue +46 -0
- package/src/components/ui/dialog/DialogHeader.vue +78 -0
- package/src/components/ui/dialog/DialogTitle.vue +34 -0
- package/src/components/ui/dialog/DialogTrigger.vue +12 -0
- package/src/components/ui/dialog/index.ts +7 -0
- package/src/components/ui/popover/Popover.vue +19 -0
- package/src/components/ui/popover/PopoverContent.vue +98 -0
- package/src/components/ui/popover/PopoverTrigger.vue +23 -0
- package/src/components/ui/popover/index.ts +4 -0
- package/src/locales/en.json +2 -1
- package/src/locales/es.json +2 -1
- package/src/locales/pt_br.json +2 -1
- package/src/stories/Alert.stories.js +6 -67
- package/src/stories/Button.stories.js +29 -39
- package/src/stories/Checkbox.stories.js +11 -4
- package/src/stories/CheckboxGroup.stories.js +105 -0
- package/src/stories/Dialog.stories.js +832 -0
- package/src/stories/Input.stories.js +71 -76
- package/src/stories/Label.stories.js +7 -0
- package/src/stories/ModalDialog.mdx +3 -0
- package/src/stories/ModalDialog.stories.js +1 -1
- package/src/stories/Popover.stories.js +306 -0
- package/src/stories/RadioGroup.stories.js +144 -0
- package/src/stories/Select.stories.js +158 -0
- package/src/stories/Switch.stories.js +10 -5
- package/src/stories/Tab.stories.js +11 -4
- package/src/stories/TextArea.stories.js +13 -2
- package/src/stories/Toast.mdx +123 -0
- package/src/stories/Toast.stories.js +126 -0
- package/src/types/scheme-colors.d.ts +1 -0
- package/src/utils/call.js +46 -18
- package/src/components/Alert/AlertBanner.vue +0 -182
- package/src/components/Alert/AlertCaller.vue +0 -49
- package/src/components/Alert/__tests__/AlertBanner.spec.js +0 -89
- package/src/components/Alert/__tests__/AlertCaller.spec.js +0 -98
package/src/components/index.ts
CHANGED
|
@@ -25,6 +25,7 @@ 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';
|
|
28
29
|
import collapse from './Collapse/Collapse.vue';
|
|
29
30
|
import radio from './Radio/Radio.vue';
|
|
30
31
|
import languageSelect from './Dropdown/LanguageSelect.vue';
|
|
@@ -88,10 +89,22 @@ import ModalDialog from './ModalDialog/ModalDialog.vue';
|
|
|
88
89
|
import Tour from './Tour/Tour.vue';
|
|
89
90
|
import Navigator from './Navigator/index.vue';
|
|
90
91
|
import SelectTime from './SelectTime/index.vue';
|
|
91
|
-
import DataTable from './DataTable/index.vue';
|
|
92
|
-
import Chip from './Chip/Chip.vue';
|
|
93
92
|
import TemplatePreview from './TemplatePreview/TemplatePreview.vue';
|
|
94
93
|
import TemplatePreviewModal from './TemplatePreview/TemplatePreviewModal.vue';
|
|
94
|
+
import DataTable from './DataTable/index.vue';
|
|
95
|
+
import Chip from './Chip/Chip.vue';
|
|
96
|
+
import Toast from './Toast/Toast.vue';
|
|
97
|
+
import { toast } from './Toast/ToastManager';
|
|
98
|
+
import Popover from './ui/popover/Popover.vue';
|
|
99
|
+
import PopoverContent from './ui/popover/PopoverContent.vue';
|
|
100
|
+
import PopoverTrigger from './ui/popover/PopoverTrigger.vue';
|
|
101
|
+
import Dialog from './ui/dialog/Dialog.vue';
|
|
102
|
+
import DialogContent from './ui/dialog/DialogContent.vue';
|
|
103
|
+
import DialogFooter from './ui/dialog/DialogFooter.vue';
|
|
104
|
+
import DialogHeader from './ui/dialog/DialogHeader.vue';
|
|
105
|
+
import DialogTitle from './ui/dialog/DialogTitle.vue';
|
|
106
|
+
import DialogTrigger from './ui/dialog/DialogTrigger.vue';
|
|
107
|
+
import DialogClose from './ui/dialog/DialogClose.vue';
|
|
95
108
|
|
|
96
109
|
type VueComponent = Component;
|
|
97
110
|
|
|
@@ -126,6 +139,7 @@ export const components: ComponentsMap = {
|
|
|
126
139
|
unnnicCardProject: cardProject,
|
|
127
140
|
unnnicCardInformation: cardInformation,
|
|
128
141
|
unnnicCheckbox: checkbox,
|
|
142
|
+
unnnicCheckboxGroup: checkboxGroup,
|
|
129
143
|
unnnicCollapse: collapse,
|
|
130
144
|
unnnicRadio: radio,
|
|
131
145
|
unnnicLanguageSelect: languageSelect,
|
|
@@ -194,6 +208,18 @@ export const components: ComponentsMap = {
|
|
|
194
208
|
unnnicTemplatePreviewModal: TemplatePreviewModal,
|
|
195
209
|
unnnicDataTable: DataTable,
|
|
196
210
|
unnnicChip: Chip,
|
|
211
|
+
unnnicToast: Toast,
|
|
212
|
+
unnnicToastManager: toast,
|
|
213
|
+
unnnicPopover: Popover,
|
|
214
|
+
unnnicPopoverContent: PopoverContent,
|
|
215
|
+
unnnicPopoverTrigger: PopoverTrigger,
|
|
216
|
+
unnnicDialog: Dialog,
|
|
217
|
+
unnnicDialogContent: DialogContent,
|
|
218
|
+
unnnicDialogFooter: DialogFooter,
|
|
219
|
+
unnnicDialogHeader: DialogHeader,
|
|
220
|
+
unnnicDialogTitle: DialogTitle,
|
|
221
|
+
unnnicDialogTrigger: DialogTrigger,
|
|
222
|
+
unnnicDialogClose: DialogClose,
|
|
197
223
|
};
|
|
198
224
|
|
|
199
225
|
export const unnnicFontSize = fontSize;
|
|
@@ -223,6 +249,7 @@ export const unnnicCardImage = cardImage as VueComponent;
|
|
|
223
249
|
export const unnnicCardProject = cardProject as VueComponent;
|
|
224
250
|
export const unnnicCardInformation = cardInformation;
|
|
225
251
|
export const unnnicCheckbox = checkbox;
|
|
252
|
+
export const unnnicCheckboxGroup = checkboxGroup;
|
|
226
253
|
export const unnnicCollapse = collapse;
|
|
227
254
|
export const unnnicRadio = radio;
|
|
228
255
|
export const unnniclanguageSelect = languageSelect as VueComponent;
|
|
@@ -245,7 +272,7 @@ export const unnnicAccordion = accordion;
|
|
|
245
272
|
export const unnnicIndicator = indicator;
|
|
246
273
|
export const unnnicSkeletonLoading = skeletonLoading;
|
|
247
274
|
export const unnnicCarousel = carousel;
|
|
248
|
-
export const unnnicLabel = label;
|
|
275
|
+
export const unnnicLabel = label as VueComponent;
|
|
249
276
|
export const unnnicTab = tab;
|
|
250
277
|
export const unnnicTabsExpanded = tabsExpanded;
|
|
251
278
|
export const unnnicBanner = banner;
|
|
@@ -286,14 +313,23 @@ export const unnnicDrawer = Drawer;
|
|
|
286
313
|
export const unnnicTableNext = TableNext;
|
|
287
314
|
export const unnnicTour = Tour;
|
|
288
315
|
export const unnnicNavigator = Navigator;
|
|
289
|
-
export const unnnicDataTable = DataTable as VueComponent;
|
|
290
316
|
export const unnnicSelectTime = SelectTime as VueComponent;
|
|
291
|
-
export const unnnicChip = Chip;
|
|
292
317
|
export const unnnicTemplatePreview = TemplatePreview as VueComponent;
|
|
293
318
|
export const unnnicTemplatePreviewModal = TemplatePreviewModal as VueComponent;
|
|
319
|
+
export const unnnicDataTable = DataTable as VueComponent;
|
|
320
|
+
export const unnnicChip = Chip;
|
|
321
|
+
export const unnnicPopover = Popover;
|
|
322
|
+
export const unnnicPopoverContent = PopoverContent;
|
|
323
|
+
export const unnnicPopoverTrigger = PopoverTrigger;
|
|
324
|
+
export const unnnicDialog = Dialog;
|
|
325
|
+
export const unnnicDialogContent = DialogContent;
|
|
326
|
+
export const unnnicDialogFooter = DialogFooter;
|
|
327
|
+
export const unnnicDialogHeader = DialogHeader;
|
|
328
|
+
export const unnnicDialogTitle = DialogTitle;
|
|
329
|
+
export const unnnicDialogTrigger = DialogTrigger;
|
|
330
|
+
export const unnnicDialogClose = DialogClose;
|
|
294
331
|
|
|
295
332
|
export const UnnnicFontSize = fontSize;
|
|
296
|
-
export const UnnnicFormElement = formElement;
|
|
297
333
|
export const UnnnicInput = input;
|
|
298
334
|
export const UnnnicInputNext = inputNext;
|
|
299
335
|
export const UnnnicInputDatePicker = inputDatePicker;
|
|
@@ -319,6 +355,7 @@ export const UnnnicCardImage = cardImage as VueComponent;
|
|
|
319
355
|
export const UnnnicCardProject = cardProject as VueComponent;
|
|
320
356
|
export const UnnnicCardInformation = cardInformation;
|
|
321
357
|
export const UnnnicCheckbox = checkbox;
|
|
358
|
+
export const UnnnicCheckboxGroup = checkboxGroup;
|
|
322
359
|
export const UnnnicCollapse = collapse;
|
|
323
360
|
export const UnnnicRadio = radio;
|
|
324
361
|
export const UnnniclanguageSelect = languageSelect as VueComponent;
|
|
@@ -341,7 +378,7 @@ export const UnnnicAccordion = accordion;
|
|
|
341
378
|
export const UnnnicIndicator = indicator;
|
|
342
379
|
export const UnnnicSkeletonLoading = skeletonLoading;
|
|
343
380
|
export const UnnnicCarousel = carousel;
|
|
344
|
-
export const UnnnicLabel = label;
|
|
381
|
+
export const UnnnicLabel = label as VueComponent;
|
|
345
382
|
export const UnnnicTab = tab;
|
|
346
383
|
export const UnnnicTabsExpanded = tabsExpanded;
|
|
347
384
|
export const UnnnicBanner = banner;
|
|
@@ -382,8 +419,20 @@ export const UnnnicDrawer = Drawer;
|
|
|
382
419
|
export const UnnnicTableNext = TableNext;
|
|
383
420
|
export const UnnnicTour = Tour;
|
|
384
421
|
export const UnnnicNavigator = Navigator;
|
|
385
|
-
export const UnnnicDataTable = DataTable as VueComponent;
|
|
386
422
|
export const UnnnicSelectTime = SelectTime as VueComponent;
|
|
387
|
-
export const UnnnicChip = Chip;
|
|
388
423
|
export const UnnnicTemplatePreview = TemplatePreview as VueComponent;
|
|
389
424
|
export const UnnnicTemplatePreviewModal = TemplatePreviewModal as VueComponent;
|
|
425
|
+
export const UnnnicDataTable = DataTable as VueComponent;
|
|
426
|
+
export const UnnnicChip = Chip;
|
|
427
|
+
export const UnnnicToast = Toast;
|
|
428
|
+
export const UnnnicToastManager = toast;
|
|
429
|
+
export const UnnnicPopover = Popover;
|
|
430
|
+
export const UnnnicPopoverContent = PopoverContent;
|
|
431
|
+
export const UnnnicPopoverTrigger = PopoverTrigger;
|
|
432
|
+
export const UnnnicDialog = Dialog;
|
|
433
|
+
export const UnnnicDialogContent = DialogContent;
|
|
434
|
+
export const UnnnicDialogFooter = DialogFooter;
|
|
435
|
+
export const UnnnicDialogHeader = DialogHeader;
|
|
436
|
+
export const UnnnicDialogTitle = DialogTitle;
|
|
437
|
+
export const UnnnicDialogTrigger = DialogTrigger;
|
|
438
|
+
export const UnnnicDialogClose = DialogClose;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { DialogRootEmits, DialogRootProps } from 'reka-ui';
|
|
3
|
+
import { DialogRoot, useForwardPropsEmits } from 'reka-ui';
|
|
4
|
+
|
|
5
|
+
const props = defineProps<DialogRootProps>();
|
|
6
|
+
const emits = defineEmits<DialogRootEmits>();
|
|
7
|
+
|
|
8
|
+
const forwarded = useForwardPropsEmits(props, emits);
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
<template>
|
|
12
|
+
<DialogRoot v-bind="forwarded">
|
|
13
|
+
<slot />
|
|
14
|
+
</DialogRoot>
|
|
15
|
+
</template>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { DialogCloseProps } from 'reka-ui';
|
|
3
|
+
import { DialogClose } from 'reka-ui';
|
|
4
|
+
|
|
5
|
+
const props = defineProps<DialogCloseProps>();
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<template>
|
|
9
|
+
<DialogClose
|
|
10
|
+
class="unnnic-dialog-close"
|
|
11
|
+
v-bind="props"
|
|
12
|
+
>
|
|
13
|
+
<slot />
|
|
14
|
+
</DialogClose>
|
|
15
|
+
</template>
|
|
16
|
+
|
|
17
|
+
<style lang="scss" scoped>
|
|
18
|
+
@use '@/assets/scss/unnnic' as *;
|
|
19
|
+
|
|
20
|
+
.unnnic-dialog-close {
|
|
21
|
+
> * {
|
|
22
|
+
width: 100%;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
</style>
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { DialogContentEmits, DialogContentProps } from 'reka-ui';
|
|
3
|
+
import type { HTMLAttributes } from 'vue';
|
|
4
|
+
import { reactiveOmit } from '@vueuse/core';
|
|
5
|
+
import {
|
|
6
|
+
DialogContent,
|
|
7
|
+
DialogOverlay,
|
|
8
|
+
DialogPortal,
|
|
9
|
+
useForwardPropsEmits,
|
|
10
|
+
} from 'reka-ui';
|
|
11
|
+
import { cn } from '@/lib/utils';
|
|
12
|
+
|
|
13
|
+
const props = withDefaults(
|
|
14
|
+
defineProps<
|
|
15
|
+
DialogContentProps & {
|
|
16
|
+
class?: HTMLAttributes['class'];
|
|
17
|
+
size?: 'small' | 'medium' | 'large';
|
|
18
|
+
}
|
|
19
|
+
>(),
|
|
20
|
+
{
|
|
21
|
+
size: 'medium',
|
|
22
|
+
},
|
|
23
|
+
);
|
|
24
|
+
const emits = defineEmits<DialogContentEmits>();
|
|
25
|
+
|
|
26
|
+
const delegatedProps = reactiveOmit(props, 'class');
|
|
27
|
+
|
|
28
|
+
const forwarded = useForwardPropsEmits(delegatedProps, emits);
|
|
29
|
+
</script>
|
|
30
|
+
|
|
31
|
+
<template>
|
|
32
|
+
<DialogPortal>
|
|
33
|
+
<DialogOverlay
|
|
34
|
+
class="unnnic-dialog-overlay data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0"
|
|
35
|
+
/>
|
|
36
|
+
<DialogContent
|
|
37
|
+
v-bind="forwarded"
|
|
38
|
+
:class="
|
|
39
|
+
cn(
|
|
40
|
+
'unnnic-dialog-content',
|
|
41
|
+
`unnnic-dialog-content--size-${props.size}`,
|
|
42
|
+
'duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]',
|
|
43
|
+
|
|
44
|
+
props.class,
|
|
45
|
+
)
|
|
46
|
+
"
|
|
47
|
+
>
|
|
48
|
+
<slot />
|
|
49
|
+
</DialogContent>
|
|
50
|
+
</DialogPortal>
|
|
51
|
+
</template>
|
|
52
|
+
|
|
53
|
+
<style lang="scss" scoped>
|
|
54
|
+
@use '@/assets/scss/unnnic' as *;
|
|
55
|
+
|
|
56
|
+
.unnnic-dialog-overlay {
|
|
57
|
+
position: fixed;
|
|
58
|
+
top: 0;
|
|
59
|
+
left: 0;
|
|
60
|
+
z-index: 9999;
|
|
61
|
+
|
|
62
|
+
width: 100vw;
|
|
63
|
+
height: 100vh;
|
|
64
|
+
background: rgba(53, 57, 69, 0.5);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.unnnic-dialog-content {
|
|
68
|
+
z-index: 10000;
|
|
69
|
+
|
|
70
|
+
position: fixed;
|
|
71
|
+
top: 50%;
|
|
72
|
+
left: 50%;
|
|
73
|
+
|
|
74
|
+
transform: translate(-50%, -50%);
|
|
75
|
+
|
|
76
|
+
width: 100%;
|
|
77
|
+
max-height: calc(100% - $unnnic-space-20);
|
|
78
|
+
|
|
79
|
+
display: flex;
|
|
80
|
+
flex-direction: column;
|
|
81
|
+
|
|
82
|
+
box-shadow: $unnnic-shadow-2;
|
|
83
|
+
border-radius: $unnnic-radius-4;
|
|
84
|
+
background-color: $unnnic-color-bg-base;
|
|
85
|
+
|
|
86
|
+
&--size-small {
|
|
87
|
+
max-width: 360px;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
&--size-medium {
|
|
91
|
+
max-width: 560px;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
&--size-large {
|
|
95
|
+
max-width: 800px;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
> * {
|
|
99
|
+
&::-webkit-scrollbar {
|
|
100
|
+
width: $unnnic-spacing-inline-nano;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
&::-webkit-scrollbar-thumb {
|
|
104
|
+
background: $unnnic-color-neutral-cleanest;
|
|
105
|
+
border-radius: $unnnic-border-radius-pill;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
&::-webkit-scrollbar-track {
|
|
109
|
+
background: $unnnic-color-neutral-soft;
|
|
110
|
+
border-radius: $unnnic-border-radius-pill;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
</style>
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { HTMLAttributes } from 'vue';
|
|
3
|
+
import { cn } from '@/lib/utils';
|
|
4
|
+
|
|
5
|
+
const props = withDefaults(
|
|
6
|
+
defineProps<{ class?: HTMLAttributes['class']; divider?: boolean }>(),
|
|
7
|
+
{
|
|
8
|
+
divider: true,
|
|
9
|
+
},
|
|
10
|
+
);
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<template>
|
|
14
|
+
<footer
|
|
15
|
+
:class="
|
|
16
|
+
cn(
|
|
17
|
+
'unnnic-dialog-footer',
|
|
18
|
+
{ 'unnnic-dialog-footer--with-divider': props.divider },
|
|
19
|
+
props.class,
|
|
20
|
+
)
|
|
21
|
+
"
|
|
22
|
+
>
|
|
23
|
+
<slot />
|
|
24
|
+
</footer>
|
|
25
|
+
</template>
|
|
26
|
+
|
|
27
|
+
<style lang="scss" scoped>
|
|
28
|
+
@use '@/assets/scss/unnnic' as *;
|
|
29
|
+
|
|
30
|
+
.unnnic-dialog-footer {
|
|
31
|
+
display: flex;
|
|
32
|
+
justify-content: center;
|
|
33
|
+
align-items: center;
|
|
34
|
+
gap: $unnnic-space-2;
|
|
35
|
+
|
|
36
|
+
padding: $unnnic-space-6;
|
|
37
|
+
|
|
38
|
+
&--with-divider {
|
|
39
|
+
border-top: 1px solid $unnnic-color-border-soft;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
> * {
|
|
43
|
+
width: 100%;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
</style>
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { HTMLAttributes } from 'vue';
|
|
3
|
+
import { cn } from '@/lib/utils';
|
|
4
|
+
import UnnnicButton from '@/components/Button/Button.vue';
|
|
5
|
+
import DialogClose from './DialogClose.vue';
|
|
6
|
+
import UnnnicIcon, { SchemeColor } from '@/components/Icon.vue';
|
|
7
|
+
|
|
8
|
+
const props = withDefaults(
|
|
9
|
+
defineProps<{
|
|
10
|
+
class?: HTMLAttributes['class'];
|
|
11
|
+
divider?: boolean;
|
|
12
|
+
type?: 'default' | 'success' | 'warning' | 'attention';
|
|
13
|
+
closeButton?: boolean;
|
|
14
|
+
}>(),
|
|
15
|
+
{
|
|
16
|
+
divider: true,
|
|
17
|
+
closeButton: true,
|
|
18
|
+
type: 'default',
|
|
19
|
+
},
|
|
20
|
+
);
|
|
21
|
+
|
|
22
|
+
const iconsMapper = {
|
|
23
|
+
default: { icon: '', scheme: '' as SchemeColor },
|
|
24
|
+
success: { icon: 'check_circle', scheme: 'aux-green-500' as SchemeColor },
|
|
25
|
+
warning: { icon: 'warning', scheme: 'aux-red-500' as SchemeColor },
|
|
26
|
+
attention: { icon: 'error', scheme: 'aux-yellow-500' as SchemeColor },
|
|
27
|
+
};
|
|
28
|
+
</script>
|
|
29
|
+
|
|
30
|
+
<template>
|
|
31
|
+
<header
|
|
32
|
+
:class="
|
|
33
|
+
cn(
|
|
34
|
+
'unnnic-dialog-header',
|
|
35
|
+
{ 'unnnic-dialog-header--with-divider': props.divider },
|
|
36
|
+
props.class,
|
|
37
|
+
)
|
|
38
|
+
"
|
|
39
|
+
>
|
|
40
|
+
<UnnnicIcon
|
|
41
|
+
v-if="iconsMapper[props.type]?.icon"
|
|
42
|
+
:icon="iconsMapper[props.type]?.icon"
|
|
43
|
+
:scheme="iconsMapper[props.type]?.scheme"
|
|
44
|
+
size="md"
|
|
45
|
+
/>
|
|
46
|
+
<slot />
|
|
47
|
+
|
|
48
|
+
<DialogClose
|
|
49
|
+
v-if="props.closeButton"
|
|
50
|
+
class="unnnic-dialog-header__close"
|
|
51
|
+
>
|
|
52
|
+
<UnnnicButton
|
|
53
|
+
type="tertiary"
|
|
54
|
+
iconCenter="close"
|
|
55
|
+
/>
|
|
56
|
+
</DialogClose>
|
|
57
|
+
</header>
|
|
58
|
+
</template>
|
|
59
|
+
|
|
60
|
+
<style lang="scss" scoped>
|
|
61
|
+
@use '@/assets/scss/unnnic' as *;
|
|
62
|
+
|
|
63
|
+
.unnnic-dialog-header {
|
|
64
|
+
display: flex;
|
|
65
|
+
align-items: center;
|
|
66
|
+
gap: $unnnic-space-2;
|
|
67
|
+
|
|
68
|
+
padding: $unnnic-space-6;
|
|
69
|
+
|
|
70
|
+
&--with-divider {
|
|
71
|
+
border-bottom: 1px solid $unnnic-color-border-soft;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&__close {
|
|
75
|
+
margin-left: auto;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
</style>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { DialogTitleProps } from 'reka-ui';
|
|
3
|
+
import type { HTMLAttributes } from 'vue';
|
|
4
|
+
import { reactiveOmit } from '@vueuse/core';
|
|
5
|
+
import { DialogTitle, useForwardProps } from 'reka-ui';
|
|
6
|
+
import { cn } from '@/lib/utils';
|
|
7
|
+
|
|
8
|
+
const props = defineProps<
|
|
9
|
+
DialogTitleProps & { class?: HTMLAttributes['class'] }
|
|
10
|
+
>();
|
|
11
|
+
|
|
12
|
+
const delegatedProps = reactiveOmit(props, 'class');
|
|
13
|
+
|
|
14
|
+
const forwardedProps = useForwardProps(delegatedProps);
|
|
15
|
+
</script>
|
|
16
|
+
|
|
17
|
+
<template>
|
|
18
|
+
<DialogTitle
|
|
19
|
+
v-bind="forwardedProps"
|
|
20
|
+
:class="cn('unnnic-dialog-title', props.class)"
|
|
21
|
+
>
|
|
22
|
+
<slot />
|
|
23
|
+
</DialogTitle>
|
|
24
|
+
</template>
|
|
25
|
+
|
|
26
|
+
<style lang="scss" scoped>
|
|
27
|
+
@use '@/assets/scss/unnnic' as *;
|
|
28
|
+
|
|
29
|
+
.unnnic-dialog-title {
|
|
30
|
+
font: $unnnic-font-display-2;
|
|
31
|
+
color: $unnnic-color-fg-emphasized;
|
|
32
|
+
margin: 0;
|
|
33
|
+
}
|
|
34
|
+
</style>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { DialogTriggerProps } from 'reka-ui';
|
|
3
|
+
import { DialogTrigger } from 'reka-ui';
|
|
4
|
+
|
|
5
|
+
const props = defineProps<DialogTriggerProps>();
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<template>
|
|
9
|
+
<DialogTrigger v-bind="props">
|
|
10
|
+
<slot />
|
|
11
|
+
</DialogTrigger>
|
|
12
|
+
</template>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { default as Dialog } from './Dialog.vue';
|
|
2
|
+
export { default as DialogClose } from './DialogClose.vue';
|
|
3
|
+
export { default as DialogContent } from './DialogContent.vue';
|
|
4
|
+
export { default as DialogFooter } from './DialogFooter.vue';
|
|
5
|
+
export { default as DialogHeader } from './DialogHeader.vue';
|
|
6
|
+
export { default as DialogTitle } from './DialogTitle.vue';
|
|
7
|
+
export { default as DialogTrigger } from './DialogTrigger.vue';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { PopoverRootEmits, PopoverRootProps } from 'reka-ui';
|
|
3
|
+
import { PopoverRoot, useForwardPropsEmits } from 'reka-ui';
|
|
4
|
+
|
|
5
|
+
defineOptions({
|
|
6
|
+
name: 'UnnnicPopover',
|
|
7
|
+
});
|
|
8
|
+
|
|
9
|
+
const props = defineProps<PopoverRootProps>();
|
|
10
|
+
const emits = defineEmits<PopoverRootEmits>();
|
|
11
|
+
|
|
12
|
+
const forwarded = useForwardPropsEmits(props, emits);
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<template>
|
|
16
|
+
<PopoverRoot v-bind="forwarded">
|
|
17
|
+
<slot />
|
|
18
|
+
</PopoverRoot>
|
|
19
|
+
</template>
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<PopoverPortal>
|
|
3
|
+
<PopoverContent
|
|
4
|
+
v-bind="{ ...forwarded, ...$attrs }"
|
|
5
|
+
:class="
|
|
6
|
+
cn(
|
|
7
|
+
'unnnic-popover',
|
|
8
|
+
`unnnic-popover--size-${props.size}`,
|
|
9
|
+
'bg-popover text-popover-foreground outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
|
|
10
|
+
)
|
|
11
|
+
"
|
|
12
|
+
>
|
|
13
|
+
<section :class="`unnnic-popover__content ${props.class || ''}`">
|
|
14
|
+
<slot />
|
|
15
|
+
</section>
|
|
16
|
+
|
|
17
|
+
<footer
|
|
18
|
+
v-if="$slots.footer"
|
|
19
|
+
class="unnnic-popover__footer"
|
|
20
|
+
>
|
|
21
|
+
<slot name="footer" />
|
|
22
|
+
</footer>
|
|
23
|
+
</PopoverContent>
|
|
24
|
+
</PopoverPortal>
|
|
25
|
+
</template>
|
|
26
|
+
|
|
27
|
+
<script setup lang="ts">
|
|
28
|
+
import type { PopoverContentEmits, PopoverContentProps } from 'reka-ui';
|
|
29
|
+
import type { HTMLAttributes } from 'vue';
|
|
30
|
+
import { reactiveOmit } from '@vueuse/core';
|
|
31
|
+
import { PopoverContent, PopoverPortal, useForwardPropsEmits } from 'reka-ui';
|
|
32
|
+
import { cn } from '@/lib/utils';
|
|
33
|
+
|
|
34
|
+
defineOptions({
|
|
35
|
+
inheritAttrs: false,
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
const props = withDefaults(
|
|
39
|
+
defineProps<
|
|
40
|
+
PopoverContentProps & {
|
|
41
|
+
class?: HTMLAttributes['class'];
|
|
42
|
+
size?: 'small' | 'medium' | 'large';
|
|
43
|
+
}
|
|
44
|
+
>(),
|
|
45
|
+
{
|
|
46
|
+
align: 'center',
|
|
47
|
+
sideOffset: 4,
|
|
48
|
+
size: 'medium',
|
|
49
|
+
},
|
|
50
|
+
);
|
|
51
|
+
const emits = defineEmits<PopoverContentEmits>();
|
|
52
|
+
|
|
53
|
+
const delegatedProps = reactiveOmit(props, 'class', 'size');
|
|
54
|
+
|
|
55
|
+
const forwarded = useForwardPropsEmits(delegatedProps, emits);
|
|
56
|
+
</script>
|
|
57
|
+
|
|
58
|
+
<style lang="scss">
|
|
59
|
+
@use '@/assets/scss/unnnic' as *;
|
|
60
|
+
|
|
61
|
+
$popover-space: $unnnic-space-4;
|
|
62
|
+
|
|
63
|
+
.unnnic-popover {
|
|
64
|
+
z-index: 10000;
|
|
65
|
+
|
|
66
|
+
border-radius: $unnnic-radius-2;
|
|
67
|
+
box-shadow: $unnnic-shadow-1;
|
|
68
|
+
|
|
69
|
+
&--size-small {
|
|
70
|
+
width: 240px;
|
|
71
|
+
}
|
|
72
|
+
&--size-medium {
|
|
73
|
+
width: 320px;
|
|
74
|
+
}
|
|
75
|
+
&--size-large {
|
|
76
|
+
width: 400px;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
&__content {
|
|
80
|
+
padding: $popover-space;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
&__footer {
|
|
84
|
+
border-top: 1px solid $unnnic-color-border-soft;
|
|
85
|
+
|
|
86
|
+
padding: $popover-space;
|
|
87
|
+
|
|
88
|
+
display: flex;
|
|
89
|
+
justify-content: center;
|
|
90
|
+
align-items: center;
|
|
91
|
+
gap: $unnnic-space-2;
|
|
92
|
+
|
|
93
|
+
> * {
|
|
94
|
+
width: 100%;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
</style>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { PopoverTriggerProps } from 'reka-ui';
|
|
3
|
+
import { PopoverTrigger } from 'reka-ui';
|
|
4
|
+
|
|
5
|
+
const props = defineProps<PopoverTriggerProps>();
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<template>
|
|
9
|
+
<PopoverTrigger
|
|
10
|
+
v-bind="props"
|
|
11
|
+
class="unnnic-popover-trigger"
|
|
12
|
+
>
|
|
13
|
+
<slot />
|
|
14
|
+
</PopoverTrigger>
|
|
15
|
+
</template>
|
|
16
|
+
|
|
17
|
+
<style scoped>
|
|
18
|
+
.unnnic-popover-trigger {
|
|
19
|
+
border: none;
|
|
20
|
+
background: transparent;
|
|
21
|
+
padding: 0;
|
|
22
|
+
}
|
|
23
|
+
</style>
|
package/src/locales/en.json
CHANGED
package/src/locales/es.json
CHANGED