@iqual/nuxt-icms 1.0.14 → 1.2.1
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/assets/css/ckeditor.css +4 -0
- package/assets/css/components/container.css +2 -2
- package/assets/css/tailwind.css +1 -1
- package/assets/css/typography.css +4 -0
- package/assets/symbols/download.svg +3 -0
- package/bundles.ts +4 -1
- package/components/Blokkli/TextMedia/index.vue +1 -2
- package/components/Blokkli/Timeline/Element/icms_timeline_element.svg +7 -0
- package/components/Blokkli/Timeline/Element/icon.svg +7 -0
- package/components/Blokkli/Timeline/Element/index.vue +14 -0
- package/components/Blokkli/Timeline/Layout/icms_layout_timeline.svg +16 -0
- package/components/Blokkli/Timeline/Layout/icon.svg +16 -0
- package/components/Blokkli/Timeline/Layout/index.vue +14 -0
- package/components/Blokkli/iFrame/icon-blokkli-option-large-spacing-bottom.svg +1 -0
- package/components/Blokkli/iFrame/icon-blokkli-option-large-spacing-top.svg +1 -0
- package/components/Blokkli/iFrame/icon-blokkli-option-no-spacing.svg +1 -0
- package/components/Blokkli/iFrame/icon-blokkli-option-small-spacing-bottom.svg +1 -0
- package/components/Blokkli/iFrame/icon-blokkli-option-small-spacing-top.svg +1 -0
- package/components/Blokkli/iFrame/{Layout/index.vue → index.vue} +2 -6
- package/components/DesignSystem/Atoms/Caption.vue +15 -0
- package/components/DesignSystem/Atoms/LinkListItem.vue +21 -0
- package/components/DesignSystem/Molecules/MediaSlider.vue +25 -8
- package/components/DesignSystem/Organisms/Map.vue +61 -0
- package/components/DesignSystem/Organisms/TimelineElement.vue +92 -0
- package/components/Media/Image/index.vue +4 -162
- package/components/Node/Icms/Page/SearchResult/fragment.graphql +8 -0
- package/components/Node/Icms/Page/SearchResult/index.vue +12 -0
- package/components/Node/Icms/Page/Teaser/fragment.graphql +17 -0
- package/components/Node/Icms/Page/Teaser/index.vue +20 -0
- package/components/Node/Icms/Page/fragment.graphql +18 -0
- package/components/Paragraph/CallToAction/index.vue +12 -8
- package/components/Paragraph/Card/Layout/index.vue +2 -2
- package/components/Paragraph/Downloads/index.vue +3 -14
- package/components/Paragraph/FAQ/Layout/index.vue +23 -1
- package/components/Paragraph/FlipTeasers/index.vue +2 -2
- package/components/Paragraph/Gallery/index.vue +32 -171
- package/components/Paragraph/HeroImage/index.vue +13 -4
- package/components/Paragraph/Media/index.vue +7 -2
- package/components/Paragraph/Table/index.vue +2 -2
- package/components/Paragraph/Team/Layout/index.vue +2 -2
- package/components/Paragraph/Teasers/fragment.graphql +2 -15
- package/components/Paragraph/Teasers/index.vue +11 -14
- package/components/Paragraph/TextMedia/index.vue +40 -33
- package/components/Paragraph/Timeline/Element/fragment.graphql +16 -0
- package/components/Paragraph/Timeline/Element/index.vue +31 -0
- package/components/Paragraph/Timeline/Layout/fragment.graphql +15 -0
- package/components/Paragraph/Timeline/Layout/index.vue +325 -0
- package/components/Paragraph/iFrame/{Layout/fragment.graphql → fragment.graphql} +2 -6
- package/components/Paragraph/iFrame/index.vue +56 -0
- package/components/Search/Facets/FacetDropdownUI.vue +222 -0
- package/components/Search/Facets/FacetedSearchUI.vue +397 -0
- package/components/Search/Facets/fragment.graphql +40 -0
- package/components/Section/Header/LanguageDropdown.vue +60 -73
- package/components/Section/Header/LanguageSwitcher.vue +37 -0
- package/components/Section/Header/MetaMenu.vue +10 -1
- package/components/Section/Header/index.vue +80 -67
- package/components/ui/accordion/Accordion.vue +2 -2
- package/components/ui/accordion/AccordionContent.vue +5 -5
- package/components/ui/accordion/AccordionItem.vue +9 -10
- package/components/ui/accordion/AccordionTrigger.vue +5 -5
- package/components/ui/alert/Alert.vue +17 -0
- package/components/ui/alert/AlertDescription.vue +14 -0
- package/components/ui/alert/AlertTitle.vue +14 -0
- package/components/ui/alert/index.ts +24 -0
- package/components/ui/alert-dialog/AlertDialog.vue +15 -0
- package/components/ui/alert-dialog/AlertDialogAction.vue +22 -0
- package/components/ui/alert-dialog/AlertDialogCancel.vue +29 -0
- package/components/ui/alert-dialog/AlertDialogContent.vue +43 -0
- package/components/ui/alert-dialog/AlertDialogDescription.vue +27 -0
- package/components/ui/alert-dialog/AlertDialogFooter.vue +21 -0
- package/components/ui/alert-dialog/AlertDialogHeader.vue +16 -0
- package/components/ui/alert-dialog/AlertDialogTitle.vue +24 -0
- package/components/ui/alert-dialog/AlertDialogTrigger.vue +12 -0
- package/components/ui/alert-dialog/index.ts +9 -0
- package/components/ui/aspect-ratio/AspectRatio.vue +12 -0
- package/components/ui/aspect-ratio/index.ts +1 -0
- package/components/ui/auto-form/AutoForm.vue +106 -0
- package/components/ui/auto-form/AutoFormField.vue +45 -0
- package/components/ui/auto-form/AutoFormFieldArray.vue +110 -0
- package/components/ui/auto-form/AutoFormFieldBoolean.vue +41 -0
- package/components/ui/auto-form/AutoFormFieldDate.vue +57 -0
- package/components/ui/auto-form/AutoFormFieldEnum.vue +49 -0
- package/components/ui/auto-form/AutoFormFieldFile.vue +74 -0
- package/components/ui/auto-form/AutoFormFieldInput.vue +36 -0
- package/components/ui/auto-form/AutoFormFieldNumber.vue +32 -0
- package/components/ui/auto-form/AutoFormFieldObject.vue +78 -0
- package/components/ui/auto-form/AutoFormLabel.vue +14 -0
- package/components/ui/auto-form/constant.ts +40 -0
- package/components/ui/auto-form/dependencies.ts +93 -0
- package/components/ui/auto-form/index.ts +15 -0
- package/components/ui/auto-form/interface.ts +95 -0
- package/components/ui/auto-form/utils.ts +188 -0
- package/components/ui/avatar/Avatar.vue +22 -0
- package/components/ui/avatar/AvatarFallback.vue +12 -0
- package/components/ui/avatar/AvatarImage.vue +10 -0
- package/components/ui/avatar/index.ts +25 -0
- package/components/ui/badge/Badge.vue +17 -0
- package/components/ui/badge/index.ts +26 -0
- package/components/ui/breadcrumb/Breadcrumb.vue +13 -0
- package/components/ui/breadcrumb/BreadcrumbEllipsis.vue +22 -0
- package/components/ui/breadcrumb/BreadcrumbItem.vue +16 -0
- package/components/ui/breadcrumb/BreadcrumbLink.vue +20 -0
- package/components/ui/breadcrumb/BreadcrumbList.vue +16 -0
- package/components/ui/breadcrumb/BreadcrumbPage.vue +19 -0
- package/components/ui/breadcrumb/BreadcrumbSeparator.vue +21 -0
- package/components/ui/breadcrumb/index.ts +7 -0
- package/components/ui/button/Button.vue +4 -2
- package/components/ui/button/index.ts +9 -9
- package/components/ui/calendar/Calendar.vue +62 -0
- package/components/ui/calendar/CalendarCell.vue +26 -0
- package/components/ui/calendar/CalendarCellTrigger.vue +40 -0
- package/components/ui/calendar/CalendarGrid.vue +26 -0
- package/components/ui/calendar/CalendarGridBody.vue +12 -0
- package/components/ui/calendar/CalendarGridHead.vue +12 -0
- package/components/ui/calendar/CalendarGridRow.vue +23 -0
- package/components/ui/calendar/CalendarHeadCell.vue +23 -0
- package/components/ui/calendar/CalendarHeader.vue +23 -0
- package/components/ui/calendar/CalendarHeading.vue +33 -0
- package/components/ui/calendar/CalendarNextButton.vue +34 -0
- package/components/ui/calendar/CalendarPrevButton.vue +34 -0
- package/components/ui/calendar/index.ts +12 -0
- package/components/ui/card/Card.vue +21 -0
- package/components/ui/card/CardContent.vue +14 -0
- package/components/ui/card/CardDescription.vue +14 -0
- package/components/ui/card/CardFooter.vue +14 -0
- package/components/ui/card/CardHeader.vue +14 -0
- package/components/ui/card/CardTitle.vue +18 -0
- package/components/ui/card/index.ts +6 -0
- package/components/ui/carousel/Carousel.vue +3 -23
- package/components/ui/carousel/CarouselContent.vue +1 -2
- package/components/ui/carousel/CarouselItem.vue +5 -7
- package/components/ui/carousel/CarouselNext.vue +7 -9
- package/components/ui/carousel/CarouselPrevious.vue +7 -9
- package/components/ui/carousel/index.ts +3 -1
- package/components/ui/carousel/interface.ts +3 -1
- package/components/ui/carousel/useCarousel.ts +13 -23
- package/components/ui/chart/ChartCrosshair.vue +45 -0
- package/components/ui/chart/ChartLegend.vue +50 -0
- package/components/ui/chart/ChartSingleTooltip.vue +64 -0
- package/components/ui/chart/ChartTooltip.vue +40 -0
- package/components/ui/chart/index.ts +18 -0
- package/components/ui/chart/interface.ts +64 -0
- package/components/ui/chart-area/AreaChart.vue +141 -0
- package/components/ui/chart-area/index.ts +66 -0
- package/components/ui/chart-bar/BarChart.vue +116 -0
- package/components/ui/chart-bar/index.ts +66 -0
- package/components/ui/chart-donut/DonutChart.vue +101 -0
- package/components/ui/chart-donut/index.ts +39 -0
- package/components/ui/chart-line/LineChart.vue +107 -0
- package/components/ui/chart-line/index.ts +66 -0
- package/components/ui/checkbox/Checkbox.vue +1 -1
- package/components/ui/collapsible/Collapsible.vue +15 -0
- package/components/ui/collapsible/CollapsibleContent.vue +12 -0
- package/components/ui/collapsible/CollapsibleTrigger.vue +12 -0
- package/components/ui/collapsible/index.ts +3 -0
- package/components/ui/command/Command.vue +31 -0
- package/components/ui/command/CommandDialog.vue +21 -0
- package/components/ui/command/CommandEmpty.vue +21 -0
- package/components/ui/command/CommandGroup.vue +30 -0
- package/components/ui/command/CommandInput.vue +35 -0
- package/components/ui/command/CommandItem.vue +27 -0
- package/components/ui/command/CommandList.vue +28 -0
- package/components/ui/command/CommandSeparator.vue +24 -0
- package/components/ui/command/CommandShortcut.vue +14 -0
- package/components/ui/command/index.ts +9 -0
- package/components/ui/context-menu/ContextMenu.vue +15 -0
- package/components/ui/context-menu/ContextMenuCheckboxItem.vue +41 -0
- package/components/ui/context-menu/ContextMenuContent.vue +37 -0
- package/components/ui/context-menu/ContextMenuGroup.vue +12 -0
- package/components/ui/context-menu/ContextMenuItem.vue +35 -0
- package/components/ui/context-menu/ContextMenuLabel.vue +27 -0
- package/components/ui/context-menu/ContextMenuPortal.vue +12 -0
- package/components/ui/context-menu/ContextMenuRadioGroup.vue +19 -0
- package/components/ui/context-menu/ContextMenuRadioItem.vue +41 -0
- package/components/ui/context-menu/ContextMenuSeparator.vue +22 -0
- package/components/ui/context-menu/ContextMenuShortcut.vue +14 -0
- package/components/ui/context-menu/ContextMenuSub.vue +19 -0
- package/components/ui/context-menu/ContextMenuSubContent.vue +36 -0
- package/components/ui/context-menu/ContextMenuSubTrigger.vue +36 -0
- package/components/ui/context-menu/ContextMenuTrigger.vue +14 -0
- package/components/ui/context-menu/index.ts +14 -0
- package/components/ui/dialog/Dialog.vue +2 -6
- package/components/ui/dialog/DialogClose.vue +2 -1
- package/components/ui/dialog/DialogContent.vue +10 -12
- package/components/ui/dialog/DialogDescription.vue +6 -10
- package/components/ui/dialog/DialogScrollContent.vue +15 -21
- package/components/ui/dialog/DialogTitle.vue +9 -6
- package/components/ui/dialog/DialogTrigger.vue +2 -1
- package/components/ui/drawer/Drawer.vue +19 -0
- package/components/ui/drawer/DrawerContent.vue +28 -0
- package/components/ui/drawer/DrawerDescription.vue +21 -0
- package/components/ui/drawer/DrawerFooter.vue +14 -0
- package/components/ui/drawer/DrawerHeader.vue +14 -0
- package/components/ui/drawer/DrawerOverlay.vue +19 -0
- package/components/ui/drawer/DrawerTitle.vue +21 -0
- package/components/ui/drawer/index.ts +8 -0
- package/components/ui/dropdown-menu/DropdownMenu.vue +15 -0
- package/components/ui/dropdown-menu/DropdownMenuCheckboxItem.vue +41 -0
- package/components/ui/dropdown-menu/DropdownMenuContent.vue +39 -0
- package/components/ui/dropdown-menu/DropdownMenuGroup.vue +12 -0
- package/components/ui/dropdown-menu/DropdownMenuItem.vue +30 -0
- package/components/ui/dropdown-menu/DropdownMenuLabel.vue +26 -0
- package/components/ui/dropdown-menu/DropdownMenuRadioGroup.vue +19 -0
- package/components/ui/dropdown-menu/DropdownMenuRadioItem.vue +42 -0
- package/components/ui/dropdown-menu/DropdownMenuSeparator.vue +24 -0
- package/components/ui/dropdown-menu/DropdownMenuShortcut.vue +14 -0
- package/components/ui/dropdown-menu/DropdownMenuSub.vue +19 -0
- package/components/ui/dropdown-menu/DropdownMenuSubContent.vue +31 -0
- package/components/ui/dropdown-menu/DropdownMenuSubTrigger.vue +35 -0
- package/components/ui/dropdown-menu/DropdownMenuTrigger.vue +14 -0
- package/components/ui/dropdown-menu/index.ts +16 -0
- package/components/ui/form/FormControl.vue +16 -0
- package/components/ui/form/FormDescription.vue +20 -0
- package/components/ui/form/FormItem.vue +20 -0
- package/components/ui/form/FormLabel.vue +23 -0
- package/components/ui/form/FormMessage.vue +16 -0
- package/components/ui/form/index.ts +7 -0
- package/components/ui/form/injectionKeys.ts +4 -0
- package/components/ui/form/useFormField.ts +30 -0
- package/components/ui/hover-card/HoverCard.vue +15 -0
- package/components/ui/hover-card/HoverCardContent.vue +43 -0
- package/components/ui/hover-card/HoverCardTrigger.vue +12 -0
- package/components/ui/hover-card/index.ts +3 -0
- package/components/ui/input/Input.vue +1 -1
- package/components/ui/menubar/Menubar.vue +36 -0
- package/components/ui/menubar/MenubarCheckboxItem.vue +41 -0
- package/components/ui/menubar/MenubarContent.vue +45 -0
- package/components/ui/menubar/MenubarGroup.vue +12 -0
- package/components/ui/menubar/MenubarItem.vue +36 -0
- package/components/ui/menubar/MenubarLabel.vue +14 -0
- package/components/ui/menubar/MenubarMenu.vue +12 -0
- package/components/ui/menubar/MenubarRadioGroup.vue +20 -0
- package/components/ui/menubar/MenubarRadioItem.vue +41 -0
- package/components/ui/menubar/MenubarSeparator.vue +21 -0
- package/components/ui/menubar/MenubarShortcut.vue +14 -0
- package/components/ui/menubar/MenubarSub.vue +20 -0
- package/components/ui/menubar/MenubarSubContent.vue +40 -0
- package/components/ui/menubar/MenubarSubTrigger.vue +32 -0
- package/components/ui/menubar/MenubarTrigger.vue +31 -0
- package/components/ui/menubar/index.ts +15 -0
- package/components/ui/navigation-menu/NavigationMenu.vue +34 -0
- package/components/ui/navigation-menu/NavigationMenuContent.vue +35 -0
- package/components/ui/navigation-menu/NavigationMenuIndicator.vue +26 -0
- package/components/ui/navigation-menu/NavigationMenuItem.vue +12 -0
- package/components/ui/navigation-menu/NavigationMenuLink.vue +19 -0
- package/components/ui/navigation-menu/NavigationMenuList.vue +31 -0
- package/components/ui/navigation-menu/NavigationMenuTrigger.vue +36 -0
- package/components/ui/navigation-menu/NavigationMenuViewport.vue +35 -0
- package/components/ui/navigation-menu/index.ts +14 -0
- package/components/ui/number-field/NumberField.vue +24 -0
- package/components/ui/number-field/NumberFieldContent.vue +14 -0
- package/components/ui/number-field/NumberFieldDecrement.vue +26 -0
- package/components/ui/number-field/NumberFieldIncrement.vue +26 -0
- package/components/ui/number-field/NumberFieldInput.vue +16 -0
- package/components/ui/number-field/index.ts +5 -0
- package/components/ui/pagination/PaginationEllipsis.vue +24 -0
- package/components/ui/pagination/PaginationFirst.vue +31 -0
- package/components/ui/pagination/PaginationLast.vue +31 -0
- package/components/ui/pagination/PaginationNext.vue +31 -0
- package/components/ui/pagination/PaginationPrev.vue +31 -0
- package/components/ui/pagination/index.ts +10 -0
- package/components/ui/pin-input/PinInput.vue +25 -0
- package/components/ui/pin-input/PinInputGroup.vue +20 -0
- package/components/ui/pin-input/PinInputInput.vue +20 -0
- package/components/ui/pin-input/PinInputSeparator.vue +16 -0
- package/components/ui/pin-input/index.ts +4 -0
- package/components/ui/popover/Popover.vue +15 -0
- package/components/ui/popover/PopoverContent.vue +49 -0
- package/components/ui/popover/PopoverTrigger.vue +12 -0
- package/components/ui/popover/index.ts +3 -0
- package/components/ui/progress/Progress.vue +41 -0
- package/components/ui/progress/index.ts +1 -0
- package/components/ui/radio-group/RadioGroupItem.vue +1 -1
- package/components/ui/range-calendar/RangeCalendar.vue +62 -0
- package/components/ui/range-calendar/RangeCalendarCell.vue +26 -0
- package/components/ui/range-calendar/RangeCalendarCellTrigger.vue +42 -0
- package/components/ui/range-calendar/RangeCalendarGrid.vue +26 -0
- package/components/ui/range-calendar/RangeCalendarGridBody.vue +12 -0
- package/components/ui/range-calendar/RangeCalendarGridHead.vue +12 -0
- package/components/ui/range-calendar/RangeCalendarGridRow.vue +23 -0
- package/components/ui/range-calendar/RangeCalendarHeadCell.vue +23 -0
- package/components/ui/range-calendar/RangeCalendarHeader.vue +23 -0
- package/components/ui/range-calendar/RangeCalendarHeading.vue +33 -0
- package/components/ui/range-calendar/RangeCalendarNextButton.vue +34 -0
- package/components/ui/range-calendar/RangeCalendarPrevButton.vue +34 -0
- package/components/ui/range-calendar/index.ts +12 -0
- package/components/ui/resizable/ResizableHandle.vue +28 -0
- package/components/ui/resizable/ResizablePanelGroup.vue +23 -0
- package/components/ui/resizable/index.ts +3 -0
- package/components/ui/scroll-area/ScrollArea.vue +31 -0
- package/components/ui/scroll-area/ScrollBar.vue +32 -0
- package/components/ui/scroll-area/index.ts +2 -0
- package/components/ui/select/SelectContent.vue +1 -1
- package/components/ui/select/SelectItem.vue +1 -1
- package/components/ui/select/SelectSeparator.vue +1 -1
- package/components/ui/select/SelectTrigger.vue +1 -1
- package/components/ui/separator/Separator.vue +37 -0
- package/components/ui/separator/index.ts +1 -0
- package/components/ui/sheet/Sheet.vue +15 -0
- package/components/ui/sheet/SheetClose.vue +12 -0
- package/components/ui/sheet/SheetContent.vue +58 -0
- package/components/ui/sheet/SheetDescription.vue +24 -0
- package/components/ui/sheet/SheetFooter.vue +19 -0
- package/components/ui/sheet/SheetHeader.vue +16 -0
- package/components/ui/sheet/SheetTitle.vue +24 -0
- package/components/ui/sheet/SheetTrigger.vue +12 -0
- package/components/ui/sheet/index.ts +32 -0
- package/components/ui/sidebar/Sidebar.vue +85 -0
- package/components/ui/sidebar/SidebarContent.vue +17 -0
- package/components/ui/sidebar/SidebarFooter.vue +17 -0
- package/components/ui/sidebar/SidebarGroup.vue +17 -0
- package/components/ui/sidebar/SidebarGroupAction.vue +26 -0
- package/components/ui/sidebar/SidebarGroupContent.vue +17 -0
- package/components/ui/sidebar/SidebarGroupLabel.vue +24 -0
- package/components/ui/sidebar/SidebarHeader.vue +17 -0
- package/components/ui/sidebar/SidebarInput.vue +21 -0
- package/components/ui/sidebar/SidebarInset.vue +20 -0
- package/components/ui/sidebar/SidebarMenu.vue +17 -0
- package/components/ui/sidebar/SidebarMenuAction.vue +34 -0
- package/components/ui/sidebar/SidebarMenuBadge.vue +25 -0
- package/components/ui/sidebar/SidebarMenuButton.vue +51 -0
- package/components/ui/sidebar/SidebarMenuButtonChild.vue +35 -0
- package/components/ui/sidebar/SidebarMenuItem.vue +17 -0
- package/components/ui/sidebar/SidebarMenuSkeleton.vue +34 -0
- package/components/ui/sidebar/SidebarMenuSub.vue +21 -0
- package/components/ui/sidebar/SidebarMenuSubButton.vue +35 -0
- package/components/ui/sidebar/SidebarMenuSubItem.vue +8 -0
- package/components/ui/sidebar/SidebarProvider.vue +81 -0
- package/components/ui/sidebar/SidebarRail.vue +32 -0
- package/components/ui/sidebar/SidebarSeparator.vue +18 -0
- package/components/ui/sidebar/SidebarTrigger.vue +26 -0
- package/components/ui/sidebar/index.ts +60 -0
- package/components/ui/sidebar/utils.ts +19 -0
- package/components/ui/skeleton/Skeleton.vue +14 -0
- package/components/ui/skeleton/index.ts +1 -0
- package/components/ui/slider/Slider.vue +37 -0
- package/components/ui/slider/index.ts +1 -0
- package/components/ui/sonner/Sonner.vue +23 -0
- package/components/ui/sonner/index.ts +1 -0
- package/components/ui/stepper/Stepper.vue +32 -0
- package/components/ui/stepper/StepperDescription.vue +24 -0
- package/components/ui/stepper/StepperIndicator.vue +36 -0
- package/components/ui/stepper/StepperItem.vue +28 -0
- package/components/ui/stepper/StepperSeparator.vue +32 -0
- package/components/ui/stepper/StepperTitle.vue +24 -0
- package/components/ui/stepper/StepperTrigger.vue +27 -0
- package/components/ui/stepper/index.ts +7 -0
- package/components/ui/switch/Switch.vue +40 -0
- package/components/ui/switch/index.ts +1 -0
- package/components/ui/table/Table.vue +16 -0
- package/components/ui/table/TableBody.vue +14 -0
- package/components/ui/table/TableCaption.vue +14 -0
- package/components/ui/table/TableCell.vue +21 -0
- package/components/ui/table/TableEmpty.vue +38 -0
- package/components/ui/table/TableFooter.vue +14 -0
- package/components/ui/table/TableHead.vue +14 -0
- package/components/ui/table/TableHeader.vue +14 -0
- package/components/ui/table/TableRow.vue +14 -0
- package/components/ui/table/index.ts +9 -0
- package/components/ui/tabs/TabsContent.vue +6 -11
- package/components/ui/tabs/TabsList.vue +8 -8
- package/components/ui/tabs/TabsTrigger.vue +9 -11
- package/components/ui/tags-input/TagsInput.vue +24 -0
- package/components/ui/tags-input/TagsInputInput.vue +21 -0
- package/components/ui/tags-input/TagsInputItem.vue +24 -0
- package/components/ui/tags-input/TagsInputItemDelete.vue +26 -0
- package/components/ui/tags-input/TagsInputItemText.vue +21 -0
- package/components/ui/tags-input/index.ts +5 -0
- package/components/ui/textarea/Textarea.vue +1 -1
- package/components/ui/toast/Toast.vue +30 -0
- package/components/ui/toast/ToastAction.vue +21 -0
- package/components/ui/toast/ToastClose.vue +24 -0
- package/components/ui/toast/ToastDescription.vue +21 -0
- package/components/ui/toast/ToastProvider.vue +12 -0
- package/components/ui/toast/ToastTitle.vue +21 -0
- package/components/ui/toast/ToastViewport.vue +19 -0
- package/components/ui/toast/Toaster.vue +30 -0
- package/components/ui/toast/index.ts +39 -0
- package/components/ui/toast/use-toast.ts +165 -0
- package/components/ui/toggle/Toggle.vue +38 -0
- package/components/ui/toggle/index.ts +28 -0
- package/components/ui/toggle-group/ToggleGroup.vue +36 -0
- package/components/ui/toggle-group/ToggleGroupItem.vue +37 -0
- package/components/ui/toggle-group/index.ts +2 -0
- package/components/ui/tooltip/Tooltip.vue +15 -0
- package/components/ui/tooltip/TooltipContent.vue +33 -0
- package/components/ui/tooltip/TooltipProvider.vue +12 -0
- package/components/ui/tooltip/TooltipTrigger.vue +12 -0
- package/components/ui/tooltip/index.ts +4 -0
- package/components/ui/v-calendar/Calendar.vue +343 -0
- package/components/ui/v-calendar/index.ts +22 -0
- package/composables/useAccordionScroll.ts +1 -1
- package/composables/useContentSearch.ts +0 -0
- package/composables/useImageSources.ts +208 -0
- package/composables/useLightbox.ts +81 -0
- package/composables/useMainMenuLinks.ts +1 -1
- package/composables/useMessageBus.ts +74 -0
- package/composables/useMetaMenuLinks.ts +1 -1
- package/composables/useNavigationOffset.ts +1 -1
- package/layouts/default.vue +2 -2
- package/layouts/error.vue +8 -10
- package/modules/dynamicEntityComponentResolver.ts +182 -0
- package/modules/dynamicParagraphResolver.ts +1 -1
- package/nuxt.config.ts +28 -32
- package/package.json +3 -2
- package/pages/[...slug]/index.vue +2 -2
- package/pages/index.vue +2 -2
- package/pages/node/[nid]/index.vue +2 -2
- package/queries/query.contentSearch.graphql +17 -0
- package/tailwind.config.ts +1 -0
- package/types/fslightbox-vue.d.ts +1 -0
- package/components/Blokkli/iFrame/Element/icon.svg +0 -5
- package/components/Blokkli/iFrame/Element/index.vue +0 -14
- package/components/Paragraph/iFrame/Element/fragment.graphql +0 -9
- package/components/Paragraph/iFrame/Element/index.vue +0 -16
- package/components/Paragraph/iFrame/Layout/index.vue +0 -161
- package/composables/languageLinks.ts +0 -31
- package/modules/dynamicNodeResolver.ts +0 -95
- package/pages/search/index.vue +0 -69
- package/pages/static-page/example.vue +0 -40
- package/queries/fragment.routeQuery.graphql +0 -51
- /package/components/Blokkli/{iFrame → Timeline}/Layout/icon-blokkli-option-large-spacing-bottom.svg +0 -0
- /package/components/Blokkli/{iFrame → Timeline}/Layout/icon-blokkli-option-large-spacing-top.svg +0 -0
- /package/components/Blokkli/{iFrame → Timeline}/Layout/icon-blokkli-option-no-spacing.svg +0 -0
- /package/components/Blokkli/{iFrame → Timeline}/Layout/icon-blokkli-option-small-spacing-bottom.svg +0 -0
- /package/components/Blokkli/{iFrame → Timeline}/Layout/icon-blokkli-option-small-spacing-top.svg +0 -0
- /package/components/Blokkli/iFrame/{Layout/icon.svg → icon.svg} +0 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { HTMLAttributes } from 'vue'
|
|
3
|
+
import { cn } from '@/lib/utils'
|
|
4
|
+
|
|
5
|
+
const props = defineProps<{
|
|
6
|
+
class?: HTMLAttributes['class']
|
|
7
|
+
}>()
|
|
8
|
+
</script>
|
|
9
|
+
|
|
10
|
+
<template>
|
|
11
|
+
<div :class="cn('flex items-center p-6 pt-0', props.class)">
|
|
12
|
+
<slot />
|
|
13
|
+
</div>
|
|
14
|
+
</template>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { HTMLAttributes } from 'vue'
|
|
3
|
+
import { cn } from '@/lib/utils'
|
|
4
|
+
|
|
5
|
+
const props = defineProps<{
|
|
6
|
+
class?: HTMLAttributes['class']
|
|
7
|
+
}>()
|
|
8
|
+
</script>
|
|
9
|
+
|
|
10
|
+
<template>
|
|
11
|
+
<div :class="cn('flex flex-col gap-y-1.5 p-6', props.class)">
|
|
12
|
+
<slot />
|
|
13
|
+
</div>
|
|
14
|
+
</template>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { HTMLAttributes } from 'vue'
|
|
3
|
+
import { cn } from '@/lib/utils'
|
|
4
|
+
|
|
5
|
+
const props = defineProps<{
|
|
6
|
+
class?: HTMLAttributes['class']
|
|
7
|
+
}>()
|
|
8
|
+
</script>
|
|
9
|
+
|
|
10
|
+
<template>
|
|
11
|
+
<h3
|
|
12
|
+
:class="
|
|
13
|
+
cn('text-2xl font-semibold leading-none tracking-tight', props.class)
|
|
14
|
+
"
|
|
15
|
+
>
|
|
16
|
+
<slot />
|
|
17
|
+
</h3>
|
|
18
|
+
</template>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { default as Card } from './Card.vue'
|
|
2
|
+
export { default as CardContent } from './CardContent.vue'
|
|
3
|
+
export { default as CardDescription } from './CardDescription.vue'
|
|
4
|
+
export { default as CardFooter } from './CardFooter.vue'
|
|
5
|
+
export { default as CardHeader } from './CardHeader.vue'
|
|
6
|
+
export { default as CardTitle } from './CardTitle.vue'
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import type {
|
|
3
|
-
CarouselEmits,
|
|
4
|
-
CarouselProps,
|
|
5
|
-
WithClassAsProps,
|
|
6
|
-
} from './interface'
|
|
2
|
+
import type { CarouselEmits, CarouselProps, WithClassAsProps } from './interface'
|
|
7
3
|
import { cn } from '@/lib/utils'
|
|
8
4
|
import { useProvideCarousel } from './useCarousel'
|
|
9
5
|
|
|
@@ -13,15 +9,7 @@ const props = withDefaults(defineProps<CarouselProps & WithClassAsProps>(), {
|
|
|
13
9
|
|
|
14
10
|
const emits = defineEmits<CarouselEmits>()
|
|
15
11
|
|
|
16
|
-
const {
|
|
17
|
-
canScrollNext,
|
|
18
|
-
canScrollPrev,
|
|
19
|
-
carouselApi,
|
|
20
|
-
carouselRef,
|
|
21
|
-
orientation,
|
|
22
|
-
scrollNext,
|
|
23
|
-
scrollPrev,
|
|
24
|
-
} = useProvideCarousel(props, emits)
|
|
12
|
+
const { canScrollNext, canScrollPrev, carouselApi, carouselRef, orientation, scrollNext, scrollPrev } = useProvideCarousel(props, emits)
|
|
25
13
|
|
|
26
14
|
defineExpose({
|
|
27
15
|
canScrollNext,
|
|
@@ -59,14 +47,6 @@ function onKeyDown(event: KeyboardEvent) {
|
|
|
59
47
|
tabindex="0"
|
|
60
48
|
@keydown="onKeyDown"
|
|
61
49
|
>
|
|
62
|
-
<slot
|
|
63
|
-
:can-scroll-next
|
|
64
|
-
:can-scroll-prev
|
|
65
|
-
:carousel-api
|
|
66
|
-
:carousel-ref
|
|
67
|
-
:orientation
|
|
68
|
-
:scroll-next
|
|
69
|
-
:scroll-prev
|
|
70
|
-
/>
|
|
50
|
+
<slot :can-scroll-next :can-scroll-prev :carousel-api :carousel-ref :orientation :scroll-next :scroll-prev />
|
|
71
51
|
</div>
|
|
72
52
|
</template>
|
|
@@ -12,13 +12,11 @@ const { orientation } = useCarousel()
|
|
|
12
12
|
<div
|
|
13
13
|
role="group"
|
|
14
14
|
aria-roledescription="slide"
|
|
15
|
-
:class="
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
)
|
|
21
|
-
"
|
|
15
|
+
:class="cn(
|
|
16
|
+
'min-w-0 shrink-0 grow-0 basis-full',
|
|
17
|
+
orientation === 'horizontal' ? 'pl-4' : 'pt-4',
|
|
18
|
+
props.class,
|
|
19
|
+
)"
|
|
22
20
|
>
|
|
23
21
|
<slot />
|
|
24
22
|
</div>
|
|
@@ -13,15 +13,13 @@ const { orientation, canScrollNext, scrollNext } = useCarousel()
|
|
|
13
13
|
<template>
|
|
14
14
|
<Button
|
|
15
15
|
:disabled="!canScrollNext"
|
|
16
|
-
:class="
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
)
|
|
24
|
-
"
|
|
16
|
+
:class="cn(
|
|
17
|
+
'touch-manipulation absolute h-8 w-8 rounded-full p-0',
|
|
18
|
+
orientation === 'horizontal'
|
|
19
|
+
? '-right-12 top-1/2 -translate-y-1/2'
|
|
20
|
+
: '-bottom-12 left-1/2 -translate-x-1/2 rotate-90',
|
|
21
|
+
props.class,
|
|
22
|
+
)"
|
|
25
23
|
variant="outline"
|
|
26
24
|
@click="scrollNext"
|
|
27
25
|
>
|
|
@@ -13,15 +13,13 @@ const { orientation, canScrollPrev, scrollPrev } = useCarousel()
|
|
|
13
13
|
<template>
|
|
14
14
|
<Button
|
|
15
15
|
:disabled="!canScrollPrev"
|
|
16
|
-
:class="
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
)
|
|
24
|
-
"
|
|
16
|
+
:class="cn(
|
|
17
|
+
'touch-manipulation absolute h-8 w-8 rounded-full p-0',
|
|
18
|
+
orientation === 'horizontal'
|
|
19
|
+
? '-left-12 top-1/2 -translate-y-1/2'
|
|
20
|
+
: '-top-12 left-1/2 -translate-x-1/2 rotate-90',
|
|
21
|
+
props.class,
|
|
22
|
+
)"
|
|
25
23
|
variant="outline"
|
|
26
24
|
@click="scrollPrev"
|
|
27
25
|
>
|
|
@@ -3,6 +3,8 @@ export { default as CarouselContent } from './CarouselContent.vue'
|
|
|
3
3
|
export { default as CarouselItem } from './CarouselItem.vue'
|
|
4
4
|
export { default as CarouselNext } from './CarouselNext.vue'
|
|
5
5
|
export { default as CarouselPrevious } from './CarouselPrevious.vue'
|
|
6
|
-
export type {
|
|
6
|
+
export type {
|
|
7
|
+
UnwrapRefCarouselApi as CarouselApi,
|
|
8
|
+
} from './interface'
|
|
7
9
|
|
|
8
10
|
export { useCarousel } from './useCarousel'
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type useEmblaCarousel from 'embla-carousel-vue'
|
|
2
|
-
import type {
|
|
2
|
+
import type {
|
|
3
|
+
EmblaCarouselVueType,
|
|
4
|
+
} from 'embla-carousel-vue'
|
|
3
5
|
import type { HTMLAttributes, UnwrapRef } from 'vue'
|
|
4
6
|
|
|
5
7
|
type CarouselApi = EmblaCarouselVueType[1]
|
|
@@ -1,21 +1,18 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
UnwrapRefCarouselApi as CarouselApi,
|
|
3
|
-
CarouselEmits,
|
|
4
|
-
CarouselProps,
|
|
5
|
-
} from './interface'
|
|
1
|
+
import type { UnwrapRefCarouselApi as CarouselApi, CarouselEmits, CarouselProps } from './interface'
|
|
6
2
|
import { createInjectionState } from '@vueuse/core'
|
|
7
3
|
import emblaCarouselVue from 'embla-carousel-vue'
|
|
8
4
|
import { onMounted, ref } from 'vue'
|
|
9
5
|
|
|
10
6
|
const [useProvideCarousel, useInjectCarousel] = createInjectionState(
|
|
11
|
-
({
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
7
|
+
({
|
|
8
|
+
opts,
|
|
9
|
+
orientation,
|
|
10
|
+
plugins,
|
|
11
|
+
}: CarouselProps, emits: CarouselEmits) => {
|
|
12
|
+
const [emblaNode, emblaApi] = emblaCarouselVue({
|
|
13
|
+
...opts,
|
|
14
|
+
axis: orientation === 'horizontal' ? 'x' : 'y',
|
|
15
|
+
}, plugins)
|
|
19
16
|
|
|
20
17
|
function scrollPrev() {
|
|
21
18
|
emblaApi.value?.scrollPrev()
|
|
@@ -33,7 +30,8 @@ const [useProvideCarousel, useInjectCarousel] = createInjectionState(
|
|
|
33
30
|
}
|
|
34
31
|
|
|
35
32
|
onMounted(() => {
|
|
36
|
-
if (!emblaApi.value)
|
|
33
|
+
if (!emblaApi.value)
|
|
34
|
+
return
|
|
37
35
|
|
|
38
36
|
emblaApi.value?.on('init', onSelect)
|
|
39
37
|
emblaApi.value?.on('reInit', onSelect)
|
|
@@ -42,15 +40,7 @@ const [useProvideCarousel, useInjectCarousel] = createInjectionState(
|
|
|
42
40
|
emits('init-api', emblaApi.value)
|
|
43
41
|
})
|
|
44
42
|
|
|
45
|
-
return {
|
|
46
|
-
carouselRef: emblaNode,
|
|
47
|
-
carouselApi: emblaApi,
|
|
48
|
-
canScrollPrev,
|
|
49
|
-
canScrollNext,
|
|
50
|
-
scrollPrev,
|
|
51
|
-
scrollNext,
|
|
52
|
-
orientation,
|
|
53
|
-
}
|
|
43
|
+
return { carouselRef: emblaNode, carouselApi: emblaApi, canScrollPrev, canScrollNext, scrollPrev, scrollNext, orientation }
|
|
54
44
|
},
|
|
55
45
|
)
|
|
56
46
|
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { BulletLegendItemInterface } from '@unovis/ts'
|
|
3
|
+
import type { Component } from 'vue'
|
|
4
|
+
import { omit } from '@unovis/ts'
|
|
5
|
+
import { VisCrosshair, VisTooltip } from '@unovis/vue'
|
|
6
|
+
import { createApp } from 'vue'
|
|
7
|
+
import { ChartTooltip } from '.'
|
|
8
|
+
|
|
9
|
+
const props = withDefaults(defineProps<{
|
|
10
|
+
colors: string[]
|
|
11
|
+
index: string
|
|
12
|
+
items: BulletLegendItemInterface[]
|
|
13
|
+
customTooltip?: Component
|
|
14
|
+
}>(), {
|
|
15
|
+
colors: () => [],
|
|
16
|
+
})
|
|
17
|
+
|
|
18
|
+
// Use weakmap to store reference to each datapoint for Tooltip
|
|
19
|
+
const wm = new WeakMap()
|
|
20
|
+
function template(d: any) {
|
|
21
|
+
if (wm.has(d)) {
|
|
22
|
+
return wm.get(d)
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
const componentDiv = document.createElement('div')
|
|
26
|
+
const omittedData = Object.entries(omit(d, [props.index])).map(([key, value]) => {
|
|
27
|
+
const legendReference = props.items.find(i => i.name === key)
|
|
28
|
+
return { ...legendReference, value }
|
|
29
|
+
})
|
|
30
|
+
const TooltipComponent = props.customTooltip ?? ChartTooltip
|
|
31
|
+
createApp(TooltipComponent, { title: d[props.index].toString(), data: omittedData }).mount(componentDiv)
|
|
32
|
+
wm.set(d, componentDiv.innerHTML)
|
|
33
|
+
return componentDiv.innerHTML
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
function color(d: unknown, i: number) {
|
|
38
|
+
return props.colors[i] ?? 'transparent'
|
|
39
|
+
}
|
|
40
|
+
</script>
|
|
41
|
+
|
|
42
|
+
<template>
|
|
43
|
+
<VisTooltip :horizontal-shift="20" :vertical-shift="20" />
|
|
44
|
+
<VisCrosshair :template="template" :color="color" />
|
|
45
|
+
</template>
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { BulletLegendItemInterface } from '@unovis/ts'
|
|
3
|
+
import { buttonVariants } from '@/lib/registry/default/ui/button'
|
|
4
|
+
import { BulletLegend } from '@unovis/ts'
|
|
5
|
+
import { VisBulletLegend } from '@unovis/vue'
|
|
6
|
+
import { nextTick, onMounted, ref } from 'vue'
|
|
7
|
+
|
|
8
|
+
const props = withDefaults(defineProps<{ items: BulletLegendItemInterface[] }>(), {
|
|
9
|
+
items: () => [],
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
const emits = defineEmits<{
|
|
13
|
+
'legendItemClick': [d: BulletLegendItemInterface, i: number]
|
|
14
|
+
'update:items': [payload: BulletLegendItemInterface[]]
|
|
15
|
+
}>()
|
|
16
|
+
|
|
17
|
+
const elRef = ref<HTMLElement>()
|
|
18
|
+
|
|
19
|
+
onMounted(() => {
|
|
20
|
+
const selector = `.${BulletLegend.selectors.item}`
|
|
21
|
+
nextTick(() => {
|
|
22
|
+
const elements = elRef.value?.querySelectorAll(selector)
|
|
23
|
+
const classes = buttonVariants({ variant: 'ghost', size: 'xs' }).split(' ')
|
|
24
|
+
elements?.forEach(el => el.classList.add(...classes, '!inline-flex', '!mr-2'))
|
|
25
|
+
})
|
|
26
|
+
})
|
|
27
|
+
|
|
28
|
+
function onLegendItemClick(d: BulletLegendItemInterface, i: number) {
|
|
29
|
+
emits('legendItemClick', d, i)
|
|
30
|
+
const isBulletActive = !props.items[i].inactive
|
|
31
|
+
const isFilterApplied = props.items.some(i => i.inactive)
|
|
32
|
+
if (isFilterApplied && isBulletActive) {
|
|
33
|
+
// reset filter
|
|
34
|
+
emits('update:items', props.items.map(item => ({ ...item, inactive: false })))
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
// apply selection, set other item as inactive
|
|
38
|
+
emits('update:items', props.items.map(item => item.name === d.name ? ({ ...d, inactive: false }) : { ...item, inactive: true }))
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
</script>
|
|
42
|
+
|
|
43
|
+
<template>
|
|
44
|
+
<div ref="elRef" class="w-max">
|
|
45
|
+
<VisBulletLegend
|
|
46
|
+
:items="items"
|
|
47
|
+
:on-legend-item-click="onLegendItemClick"
|
|
48
|
+
/>
|
|
49
|
+
</div>
|
|
50
|
+
</template>
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { BulletLegendItemInterface } from '@unovis/ts'
|
|
3
|
+
import type { Component } from 'vue'
|
|
4
|
+
import { omit } from '@unovis/ts'
|
|
5
|
+
import { VisTooltip } from '@unovis/vue'
|
|
6
|
+
import { createApp } from 'vue'
|
|
7
|
+
import { ChartTooltip } from '.'
|
|
8
|
+
|
|
9
|
+
const props = withDefaults(defineProps<{
|
|
10
|
+
selector: string
|
|
11
|
+
index: string
|
|
12
|
+
items?: BulletLegendItemInterface[]
|
|
13
|
+
valueFormatter?: (tick: number, i?: number, ticks?: number[]) => string
|
|
14
|
+
customTooltip?: Component
|
|
15
|
+
}>(), {
|
|
16
|
+
valueFormatter: (tick: number) => `${tick}`,
|
|
17
|
+
})
|
|
18
|
+
|
|
19
|
+
// Use weakmap to store reference to each datapoint for Tooltip
|
|
20
|
+
const wm = new WeakMap()
|
|
21
|
+
function template(d: any, i: number, elements: (HTMLElement | SVGElement)[]) {
|
|
22
|
+
if (props.index in d) {
|
|
23
|
+
if (wm.has(d)) {
|
|
24
|
+
return wm.get(d)
|
|
25
|
+
}
|
|
26
|
+
else {
|
|
27
|
+
const componentDiv = document.createElement('div')
|
|
28
|
+
const omittedData = Object.entries(omit(d, [props.index])).map(([key, value]) => {
|
|
29
|
+
const legendReference = props.items?.find(i => i.name === key)
|
|
30
|
+
return { ...legendReference, value: props.valueFormatter(value) }
|
|
31
|
+
})
|
|
32
|
+
const TooltipComponent = props.customTooltip ?? ChartTooltip
|
|
33
|
+
createApp(TooltipComponent, { title: d[props.index], data: omittedData }).mount(componentDiv)
|
|
34
|
+
wm.set(d, componentDiv.innerHTML)
|
|
35
|
+
return componentDiv.innerHTML
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
else {
|
|
40
|
+
const data = d.data
|
|
41
|
+
|
|
42
|
+
if (wm.has(data)) {
|
|
43
|
+
return wm.get(data)
|
|
44
|
+
}
|
|
45
|
+
else {
|
|
46
|
+
const style = getComputedStyle(elements[i])
|
|
47
|
+
const omittedData = [{ name: data.name, value: props.valueFormatter(data[props.index]), color: style.fill }]
|
|
48
|
+
const componentDiv = document.createElement('div')
|
|
49
|
+
const TooltipComponent = props.customTooltip ?? ChartTooltip
|
|
50
|
+
createApp(TooltipComponent, { title: d[props.index], data: omittedData }).mount(componentDiv)
|
|
51
|
+
wm.set(d, componentDiv.innerHTML)
|
|
52
|
+
return componentDiv.innerHTML
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
</script>
|
|
57
|
+
|
|
58
|
+
<template>
|
|
59
|
+
<VisTooltip
|
|
60
|
+
:horizontal-shift="20" :vertical-shift="20" :triggers="{
|
|
61
|
+
[selector]: template,
|
|
62
|
+
}"
|
|
63
|
+
/>
|
|
64
|
+
</template>
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { Card, CardContent, CardHeader, CardTitle } from '@/lib/registry/default/ui/card'
|
|
3
|
+
|
|
4
|
+
defineProps<{
|
|
5
|
+
title?: string
|
|
6
|
+
data: {
|
|
7
|
+
name: string
|
|
8
|
+
color: string
|
|
9
|
+
value: any
|
|
10
|
+
}[]
|
|
11
|
+
}>()
|
|
12
|
+
</script>
|
|
13
|
+
|
|
14
|
+
<template>
|
|
15
|
+
<Card class="text-sm">
|
|
16
|
+
<CardHeader v-if="title" class="p-3 border-b">
|
|
17
|
+
<CardTitle>
|
|
18
|
+
{{ title }}
|
|
19
|
+
</CardTitle>
|
|
20
|
+
</CardHeader>
|
|
21
|
+
<CardContent class="p-3 min-w-[180px] flex flex-col gap-1">
|
|
22
|
+
<div v-for="(item, key) in data" :key="key" class="flex justify-between">
|
|
23
|
+
<div class="flex items-center">
|
|
24
|
+
<span class="w-2.5 h-2.5 mr-2">
|
|
25
|
+
<svg width="100%" height="100%" viewBox="0 0 30 30">
|
|
26
|
+
<path
|
|
27
|
+
d=" M 15 15 m -14, 0 a 14,14 0 1,1 28,0 a 14,14 0 1,1 -28,0"
|
|
28
|
+
:stroke="item.color"
|
|
29
|
+
:fill="item.color"
|
|
30
|
+
stroke-width="1"
|
|
31
|
+
/>
|
|
32
|
+
</svg>
|
|
33
|
+
</span>
|
|
34
|
+
<span>{{ item.name }}</span>
|
|
35
|
+
</div>
|
|
36
|
+
<span class="font-semibold ml-4">{{ item.value }}</span>
|
|
37
|
+
</div>
|
|
38
|
+
</CardContent>
|
|
39
|
+
</Card>
|
|
40
|
+
</template>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export { default as ChartCrosshair } from './ChartCrosshair.vue'
|
|
2
|
+
export { default as ChartLegend } from './ChartLegend.vue'
|
|
3
|
+
export { default as ChartSingleTooltip } from './ChartSingleTooltip.vue'
|
|
4
|
+
export { default as ChartTooltip } from './ChartTooltip.vue'
|
|
5
|
+
|
|
6
|
+
export function defaultColors(count: number = 3) {
|
|
7
|
+
const quotient = Math.floor(count / 2)
|
|
8
|
+
const remainder = count % 2
|
|
9
|
+
|
|
10
|
+
const primaryCount = quotient + remainder
|
|
11
|
+
const secondaryCount = quotient
|
|
12
|
+
return [
|
|
13
|
+
...Array.from(new Array(primaryCount).keys()).map(i => `hsl(var(--vis-primary-color) / ${1 - (1 / primaryCount) * i})`),
|
|
14
|
+
...Array.from(new Array(secondaryCount).keys()).map(i => `hsl(var(--vis-secondary-color) / ${1 - (1 / secondaryCount) * i})`),
|
|
15
|
+
]
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export * from './interface'
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import type { Spacing } from '@unovis/ts'
|
|
2
|
+
|
|
3
|
+
type KeyOf<T extends Record<string, any>> = Extract<keyof T, string>
|
|
4
|
+
|
|
5
|
+
export interface BaseChartProps<T extends Record<string, any>> {
|
|
6
|
+
/**
|
|
7
|
+
* The source data, in which each entry is a dictionary.
|
|
8
|
+
*/
|
|
9
|
+
data: T[]
|
|
10
|
+
/**
|
|
11
|
+
* Select the categories from your data. Used to populate the legend and toolip.
|
|
12
|
+
*/
|
|
13
|
+
categories: KeyOf<T>[]
|
|
14
|
+
/**
|
|
15
|
+
* Sets the key to map the data to the axis.
|
|
16
|
+
*/
|
|
17
|
+
index: KeyOf<T>
|
|
18
|
+
/**
|
|
19
|
+
* Change the default colors.
|
|
20
|
+
*/
|
|
21
|
+
colors?: string[]
|
|
22
|
+
/**
|
|
23
|
+
* Margin of each the container
|
|
24
|
+
*/
|
|
25
|
+
margin?: Spacing
|
|
26
|
+
/**
|
|
27
|
+
* Change the opacity of the non-selected field
|
|
28
|
+
* @default 0.2
|
|
29
|
+
*/
|
|
30
|
+
filterOpacity?: number
|
|
31
|
+
/**
|
|
32
|
+
* Function to format X label
|
|
33
|
+
*/
|
|
34
|
+
xFormatter?: (tick: number | Date, i: number, ticks: number[] | Date[]) => string
|
|
35
|
+
/**
|
|
36
|
+
* Function to format Y label
|
|
37
|
+
*/
|
|
38
|
+
yFormatter?: (tick: number | Date, i: number, ticks: number[] | Date[]) => string
|
|
39
|
+
/**
|
|
40
|
+
* Controls the visibility of the X axis.
|
|
41
|
+
* @default true
|
|
42
|
+
*/
|
|
43
|
+
showXAxis?: boolean
|
|
44
|
+
/**
|
|
45
|
+
* Controls the visibility of the Y axis.
|
|
46
|
+
* @default true
|
|
47
|
+
*/
|
|
48
|
+
showYAxis?: boolean
|
|
49
|
+
/**
|
|
50
|
+
* Controls the visibility of tooltip.
|
|
51
|
+
* @default true
|
|
52
|
+
*/
|
|
53
|
+
showTooltip?: boolean
|
|
54
|
+
/**
|
|
55
|
+
* Controls the visibility of legend.
|
|
56
|
+
* @default true
|
|
57
|
+
*/
|
|
58
|
+
showLegend?: boolean
|
|
59
|
+
/**
|
|
60
|
+
* Controls the visibility of gridline.
|
|
61
|
+
* @default true
|
|
62
|
+
*/
|
|
63
|
+
showGridLine?: boolean
|
|
64
|
+
}
|