@geniusdynamics/ns8-ui-lib 1.0.4 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ns8-ui-lib.css +3 -1
- package/dist/ns8-ui-lib.es.js +36815 -19727
- package/dist/ns8-ui-lib.es.js.map +1 -1
- package/dist/ns8-ui-lib.umd.js +24 -11
- package/dist/ns8-ui-lib.umd.js.map +1 -1
- package/package.json +25 -19
- package/src/App.vue +7 -3
- package/src/components/HelloWorld.vue +2 -2
- package/src/components/NS/CompleteDemo.vue +49 -49
- package/src/components/NS/Demo.vue +20 -20
- package/src/components/NS/cards/NSBackupCard.vue +59 -41
- package/src/components/NS/cards/NSSystemInfoCard.vue +164 -136
- package/src/components/NS/cards/NSSystemdServiceCard.vue +27 -27
- package/src/components/NS/checkbox/NSCheckbox.vue +6 -8
- package/src/components/NS/data-table/NSDataTable.vue +34 -40
- package/src/components/NS/empty-state/NSEmptyState.vue +3 -3
- package/src/components/NS/inline-notification/NSInlineNotification.vue +9 -9
- package/src/components/NS/lottie-animation/NSLottieAnimation.vue +140 -116
- package/src/components/NS/modal/NSModal.vue +12 -14
- package/src/components/NS/modal/NSModalTrigger.vue +1 -1
- package/src/components/NS/pagination/NSPagination.vue +10 -10
- package/src/components/NS/progress/NSProgress.vue +3 -3
- package/src/components/NS/progress/NSProgressBar.vue +4 -4
- package/src/components/NS/slider/NSByteSlider.vue +3 -3
- package/src/components/NS/slider/NSSlider.vue +2 -2
- package/src/components/NS/tag/NSTag.vue +6 -7
- package/src/components/NS/text-input/NSTextInput.vue +9 -13
- package/src/components/NS/toast-notification/NSToastNotification.vue +9 -11
- package/src/components/NS/toggle/NSToggle.vue +5 -8
- package/src/components/NS/wizard/NSWizard.vue +21 -21
- package/src/components/ui/accordion/Accordion.vue +18 -0
- package/src/components/ui/accordion/AccordionContent.vue +23 -0
- package/src/components/ui/accordion/AccordionItem.vue +24 -0
- package/src/components/ui/accordion/AccordionTrigger.vue +37 -0
- package/src/components/ui/alert/Alert.vue +21 -0
- package/src/components/ui/alert/AlertDescription.vue +17 -0
- package/src/components/ui/alert/AlertTitle.vue +17 -0
- package/src/components/ui/alert-dialog/AlertDialog.vue +15 -0
- package/src/components/ui/alert-dialog/AlertDialogAction.vue +18 -0
- package/src/components/ui/alert-dialog/AlertDialogCancel.vue +25 -0
- package/src/components/ui/alert-dialog/AlertDialogContent.vue +44 -0
- package/src/components/ui/alert-dialog/AlertDialogDescription.vue +23 -0
- package/src/components/ui/alert-dialog/AlertDialogFooter.vue +22 -0
- package/src/components/ui/alert-dialog/AlertDialogHeader.vue +17 -0
- package/src/components/ui/alert-dialog/AlertDialogTitle.vue +21 -0
- package/src/components/ui/alert-dialog/AlertDialogTrigger.vue +12 -0
- package/src/components/ui/aspect-ratio/AspectRatio.vue +16 -0
- package/src/components/ui/avatar/Avatar.vue +18 -0
- package/src/components/ui/avatar/AvatarFallback.vue +21 -0
- package/src/components/ui/avatar/AvatarImage.vue +16 -0
- package/src/components/ui/breadcrumb/Breadcrumb.vue +17 -0
- package/src/components/ui/breadcrumb/BreadcrumbEllipsis.vue +23 -0
- package/src/components/ui/breadcrumb/BreadcrumbItem.vue +17 -0
- package/src/components/ui/breadcrumb/BreadcrumbLink.vue +21 -0
- package/src/components/ui/breadcrumb/BreadcrumbList.vue +17 -0
- package/src/components/ui/breadcrumb/BreadcrumbPage.vue +20 -0
- package/src/components/ui/breadcrumb/BreadcrumbSeparator.vue +22 -0
- package/src/components/ui/button/Button.vue +2 -0
- package/src/components/ui/button-group/ButtonGroup.vue +22 -0
- package/src/components/ui/button-group/ButtonGroupSeparator.vue +24 -0
- package/src/components/ui/button-group/ButtonGroupText.vue +29 -0
- package/src/components/ui/calendar/Calendar.vue +160 -0
- package/src/components/ui/calendar/CalendarCell.vue +23 -0
- package/src/components/ui/calendar/CalendarCellTrigger.vue +39 -0
- package/src/components/ui/calendar/CalendarGrid.vue +23 -0
- package/src/components/ui/calendar/CalendarGridBody.vue +15 -0
- package/src/components/ui/calendar/CalendarGridHead.vue +16 -0
- package/src/components/ui/calendar/CalendarGridRow.vue +22 -0
- package/src/components/ui/calendar/CalendarHeadCell.vue +23 -0
- package/src/components/ui/calendar/CalendarHeader.vue +23 -0
- package/src/components/ui/calendar/CalendarHeading.vue +30 -0
- package/src/components/ui/calendar/CalendarNextButton.vue +31 -0
- package/src/components/ui/calendar/CalendarPrevButton.vue +31 -0
- package/src/components/ui/card/Card.vue +1 -1
- package/src/components/ui/card/CardAction.vue +1 -1
- package/src/components/ui/card/CardContent.vue +1 -1
- package/src/components/ui/card/CardDescription.vue +1 -1
- package/src/components/ui/card/CardFooter.vue +1 -1
- package/src/components/ui/card/CardHeader.vue +1 -1
- package/src/components/ui/card/CardTitle.vue +1 -1
- package/src/components/ui/carousel/Carousel.vue +53 -0
- package/src/components/ui/carousel/CarouselContent.vue +33 -0
- package/src/components/ui/carousel/CarouselItem.vue +24 -0
- package/src/components/ui/carousel/CarouselNext.vue +41 -0
- package/src/components/ui/carousel/CarouselPrevious.vue +41 -0
- package/src/components/ui/checkbox/Checkbox.vue +35 -0
- package/src/components/ui/collapsible/Collapsible.vue +19 -0
- package/src/components/ui/collapsible/CollapsibleContent.vue +15 -0
- package/src/components/ui/collapsible/CollapsibleTrigger.vue +15 -0
- package/src/components/ui/combobox/Combobox.vue +19 -0
- package/src/components/ui/combobox/ComboboxAnchor.vue +23 -0
- package/src/components/ui/combobox/ComboboxEmpty.vue +21 -0
- package/src/components/ui/combobox/ComboboxGroup.vue +27 -0
- package/src/components/ui/combobox/ComboboxInput.vue +42 -0
- package/src/components/ui/combobox/ComboboxItem.vue +24 -0
- package/src/components/ui/combobox/ComboboxItemIndicator.vue +23 -0
- package/src/components/ui/combobox/ComboboxList.vue +33 -0
- package/src/components/ui/combobox/ComboboxSeparator.vue +21 -0
- package/src/components/ui/combobox/ComboboxTrigger.vue +24 -0
- package/src/components/ui/combobox/ComboboxViewport.vue +23 -0
- package/src/components/ui/command/Command.vue +87 -0
- package/src/components/ui/command/CommandDialog.vue +31 -0
- package/src/components/ui/command/CommandEmpty.vue +27 -0
- package/src/components/ui/command/CommandGroup.vue +45 -0
- package/src/components/ui/command/CommandInput.vue +39 -0
- package/src/components/ui/command/CommandItem.vue +76 -0
- package/src/components/ui/command/CommandList.vue +25 -0
- package/src/components/ui/command/CommandSeparator.vue +21 -0
- package/src/components/ui/command/CommandShortcut.vue +17 -0
- package/src/components/ui/context-menu/ContextMenu.vue +18 -0
- package/src/components/ui/context-menu/ContextMenuCheckboxItem.vue +39 -0
- package/src/components/ui/context-menu/ContextMenuContent.vue +37 -0
- package/src/components/ui/context-menu/ContextMenuGroup.vue +15 -0
- package/src/components/ui/context-menu/ContextMenuItem.vue +38 -0
- package/src/components/ui/context-menu/ContextMenuLabel.vue +22 -0
- package/src/components/ui/context-menu/ContextMenuPortal.vue +15 -0
- package/src/components/ui/context-menu/ContextMenuRadioGroup.vue +21 -0
- package/src/components/ui/context-menu/ContextMenuRadioItem.vue +39 -0
- package/src/components/ui/context-menu/ContextMenuSeparator.vue +21 -0
- package/src/components/ui/context-menu/ContextMenuShortcut.vue +17 -0
- package/src/components/ui/context-menu/ContextMenuSub.vue +21 -0
- package/src/components/ui/context-menu/ContextMenuSubContent.vue +32 -0
- package/src/components/ui/context-menu/ContextMenuSubTrigger.vue +32 -0
- package/src/components/ui/context-menu/ContextMenuTrigger.vue +17 -0
- package/src/components/ui/dialog/Dialog.vue +15 -64
- package/src/components/ui/dialog/DialogClose.vue +15 -0
- package/src/components/ui/dialog/DialogContent.vue +62 -0
- package/src/components/ui/dialog/DialogDescription.vue +23 -0
- package/src/components/ui/dialog/DialogFooter.vue +27 -0
- package/src/components/ui/dialog/DialogHeader.vue +17 -0
- package/src/components/ui/dialog/DialogOverlay.vue +21 -0
- package/src/components/ui/dialog/DialogScrollContent.vue +59 -0
- package/src/components/ui/dialog/DialogTitle.vue +23 -0
- package/src/components/ui/dialog/DialogTrigger.vue +15 -0
- package/src/components/ui/drawer/Drawer.vue +23 -0
- package/src/components/ui/drawer/DrawerClose.vue +15 -0
- package/src/components/ui/drawer/DrawerContent.vue +38 -0
- package/src/components/ui/drawer/DrawerDescription.vue +21 -0
- package/src/components/ui/drawer/DrawerFooter.vue +17 -0
- package/src/components/ui/drawer/DrawerHeader.vue +17 -0
- package/src/components/ui/drawer/DrawerOverlay.vue +19 -0
- package/src/components/ui/drawer/DrawerTitle.vue +21 -0
- package/src/components/ui/drawer/DrawerTrigger.vue +15 -0
- package/src/components/ui/dropdown-menu/DropdownMenu.vue +19 -0
- package/src/components/ui/dropdown-menu/DropdownMenuCheckboxItem.vue +39 -0
- package/src/components/ui/dropdown-menu/DropdownMenuContent.vue +39 -0
- package/src/components/ui/dropdown-menu/DropdownMenuGroup.vue +15 -0
- package/src/components/ui/dropdown-menu/DropdownMenuItem.vue +31 -0
- package/src/components/ui/dropdown-menu/DropdownMenuLabel.vue +23 -0
- package/src/components/ui/dropdown-menu/DropdownMenuRadioGroup.vue +21 -0
- package/src/components/ui/dropdown-menu/DropdownMenuRadioItem.vue +40 -0
- package/src/components/ui/dropdown-menu/DropdownMenuSeparator.vue +23 -0
- package/src/components/ui/dropdown-menu/DropdownMenuShortcut.vue +17 -0
- package/src/components/ui/dropdown-menu/DropdownMenuSub.vue +18 -0
- package/src/components/ui/dropdown-menu/DropdownMenuSubContent.vue +27 -0
- package/src/components/ui/dropdown-menu/DropdownMenuSubTrigger.vue +31 -0
- package/src/components/ui/dropdown-menu/DropdownMenuTrigger.vue +17 -0
- package/src/components/ui/empty/Empty.vue +20 -0
- package/src/components/ui/empty/EmptyContent.vue +20 -0
- package/src/components/ui/empty/EmptyDescription.vue +20 -0
- package/src/components/ui/empty/EmptyHeader.vue +20 -0
- package/src/components/ui/empty/EmptyMedia.vue +21 -0
- package/src/components/ui/empty/EmptyTitle.vue +17 -0
- package/src/components/ui/field/Field.vue +25 -0
- package/src/components/ui/field/FieldContent.vue +20 -0
- package/src/components/ui/field/FieldDescription.vue +22 -0
- package/src/components/ui/field/FieldError.vue +53 -0
- package/src/components/ui/field/FieldGroup.vue +20 -0
- package/src/components/ui/field/FieldLabel.vue +23 -0
- package/src/components/ui/field/FieldLegend.vue +24 -0
- package/src/components/ui/field/FieldSeparator.vue +29 -0
- package/src/components/ui/field/FieldSet.vue +21 -0
- package/src/components/ui/field/FieldTitle.vue +20 -0
- package/src/components/ui/form/FormControl.vue +17 -0
- package/src/components/ui/form/FormDescription.vue +21 -0
- package/src/components/ui/form/FormItem.vue +23 -0
- package/src/components/ui/form/FormLabel.vue +25 -0
- package/src/components/ui/form/FormMessage.vue +23 -0
- package/src/components/ui/hover-card/HoverCard.vue +19 -0
- package/src/components/ui/hover-card/HoverCardContent.vue +43 -0
- package/src/components/ui/hover-card/HoverCardTrigger.vue +15 -0
- package/src/components/ui/input/Input.vue +3 -3
- package/src/components/ui/input-group/InputGroup.vue +8 -8
- package/src/components/ui/input-group/InputGroupButton.vue +9 -1
- package/src/components/ui/input-group/InputGroupInput.vue +1 -1
- package/src/components/ui/input-group/InputGroupText.vue +1 -1
- package/src/components/ui/input-group/InputGroupTextarea.vue +1 -1
- package/src/components/ui/input-otp/InputOTP.vue +28 -0
- package/src/components/ui/input-otp/InputOTPGroup.vue +22 -0
- package/src/components/ui/input-otp/InputOTPSeparator.vue +21 -0
- package/src/components/ui/input-otp/InputOTPSlot.vue +32 -0
- package/src/components/ui/item/Item.vue +2 -0
- package/src/components/ui/item/ItemActions.vue +1 -1
- package/src/components/ui/item/ItemContent.vue +1 -1
- package/src/components/ui/item/ItemDescription.vue +2 -2
- package/src/components/ui/item/ItemFooter.vue +1 -1
- package/src/components/ui/item/ItemGroup.vue +1 -1
- package/src/components/ui/item/ItemHeader.vue +1 -1
- package/src/components/ui/item/ItemSeparator.vue +1 -1
- package/src/components/ui/item/ItemTitle.vue +1 -1
- package/src/components/ui/kbd/Kbd.vue +21 -0
- package/src/components/ui/kbd/KbdGroup.vue +17 -0
- package/src/components/ui/label/Label.vue +1 -1
- package/src/components/ui/menubar/Menubar.vue +33 -0
- package/src/components/ui/menubar/MenubarCheckboxItem.vue +39 -0
- package/src/components/ui/menubar/MenubarContent.vue +45 -0
- package/src/components/ui/menubar/MenubarGroup.vue +15 -0
- package/src/components/ui/menubar/MenubarItem.vue +36 -0
- package/src/components/ui/menubar/MenubarLabel.vue +20 -0
- package/src/components/ui/menubar/MenubarMenu.vue +15 -0
- package/src/components/ui/menubar/MenubarRadioGroup.vue +21 -0
- package/src/components/ui/menubar/MenubarRadioItem.vue +39 -0
- package/src/components/ui/menubar/MenubarSeparator.vue +21 -0
- package/src/components/ui/menubar/MenubarShortcut.vue +17 -0
- package/src/components/ui/menubar/MenubarSub.vue +24 -0
- package/src/components/ui/menubar/MenubarSubContent.vue +39 -0
- package/src/components/ui/menubar/MenubarSubTrigger.vue +28 -0
- package/src/components/ui/menubar/MenubarTrigger.vue +28 -0
- package/src/components/ui/native-select/NativeSelect.vue +50 -0
- package/src/components/ui/native-select/NativeSelectOptGroup.vue +15 -0
- package/src/components/ui/native-select/NativeSelectOption.vue +15 -0
- package/src/components/ui/navigation-menu/NavigationMenu.vue +35 -0
- package/src/components/ui/navigation-menu/NavigationMenuContent.vue +31 -0
- package/src/components/ui/navigation-menu/NavigationMenuIndicator.vue +23 -0
- package/src/components/ui/navigation-menu/NavigationMenuItem.vue +21 -0
- package/src/components/ui/navigation-menu/NavigationMenuLink.vue +26 -0
- package/src/components/ui/navigation-menu/NavigationMenuList.vue +28 -0
- package/src/components/ui/navigation-menu/NavigationMenuTrigger.vue +32 -0
- package/src/components/ui/navigation-menu/NavigationMenuViewport.vue +31 -0
- package/src/components/ui/number-field/NumberField.vue +20 -0
- package/src/components/ui/number-field/NumberFieldContent.vue +14 -0
- package/src/components/ui/number-field/NumberFieldDecrement.vue +22 -0
- package/src/components/ui/number-field/NumberFieldIncrement.vue +22 -0
- package/src/components/ui/number-field/NumberFieldInput.vue +16 -0
- package/src/components/ui/pagination/Pagination.vue +26 -0
- package/src/components/ui/pagination/PaginationContent.vue +22 -0
- package/src/components/ui/pagination/PaginationEllipsis.vue +25 -0
- package/src/components/ui/pagination/PaginationFirst.vue +33 -0
- package/src/components/ui/pagination/PaginationItem.vue +34 -0
- package/src/components/ui/pagination/PaginationLast.vue +33 -0
- package/src/components/ui/pagination/PaginationNext.vue +33 -0
- package/src/components/ui/pagination/PaginationPrevious.vue +33 -0
- package/src/components/ui/pin-input/PinInput.vue +26 -0
- package/src/components/ui/pin-input/PinInputGroup.vue +21 -0
- package/src/components/ui/pin-input/PinInputSeparator.vue +19 -0
- package/src/components/ui/pin-input/PinInputSlot.vue +21 -0
- package/src/components/ui/popover/Popover.vue +19 -0
- package/src/components/ui/popover/PopoverAnchor.vue +15 -0
- package/src/components/ui/popover/PopoverContent.vue +45 -0
- package/src/components/ui/popover/PopoverTrigger.vue +15 -0
- package/src/components/ui/progress/Progress.vue +9 -12
- package/src/components/ui/radio-group/RadioGroup.vue +25 -0
- package/src/components/ui/radio-group/RadioGroupItem.vue +40 -0
- package/src/components/ui/range-calendar/RangeCalendar.vue +62 -0
- package/src/components/ui/range-calendar/RangeCalendarCell.vue +23 -0
- package/src/components/ui/range-calendar/RangeCalendarCellTrigger.vue +41 -0
- package/src/components/ui/range-calendar/RangeCalendarGrid.vue +23 -0
- package/src/components/ui/range-calendar/RangeCalendarGridBody.vue +15 -0
- package/src/components/ui/range-calendar/RangeCalendarGridHead.vue +15 -0
- package/src/components/ui/range-calendar/RangeCalendarGridRow.vue +22 -0
- package/src/components/ui/range-calendar/RangeCalendarHeadCell.vue +23 -0
- package/src/components/ui/range-calendar/RangeCalendarHeader.vue +23 -0
- package/src/components/ui/range-calendar/RangeCalendarHeading.vue +30 -0
- package/src/components/ui/range-calendar/RangeCalendarNextButton.vue +32 -0
- package/src/components/ui/range-calendar/RangeCalendarPrevButton.vue +32 -0
- package/src/components/ui/resizable/ResizableHandle.vue +30 -0
- package/src/components/ui/resizable/ResizablePanel.vue +21 -0
- package/src/components/ui/resizable/ResizablePanelGroup.vue +25 -0
- package/src/components/ui/scroll-area/ScrollArea.vue +2 -2
- package/src/components/ui/scroll-area/ScrollBar.vue +22 -16
- package/src/components/ui/select/SelectContent.vue +27 -18
- package/src/components/ui/select/SelectItem.vue +3 -3
- package/src/components/ui/select/SelectLabel.vue +1 -1
- package/src/components/ui/select/SelectScrollDownButton.vue +2 -2
- package/src/components/ui/select/SelectScrollUpButton.vue +2 -2
- package/src/components/ui/select/SelectSeparator.vue +1 -1
- package/src/components/ui/select/SelectTrigger.vue +2 -2
- package/src/components/ui/separator/Separator.vue +1 -1
- package/src/components/ui/sheet/SheetContent.vue +31 -28
- package/src/components/ui/sheet/SheetDescription.vue +1 -1
- package/src/components/ui/sheet/SheetFooter.vue +1 -1
- package/src/components/ui/sheet/SheetHeader.vue +1 -1
- package/src/components/ui/sheet/SheetOverlay.vue +1 -1
- package/src/components/ui/sheet/SheetTitle.vue +1 -1
- package/src/components/ui/sidebar/Sidebar.vue +16 -16
- package/src/components/ui/sidebar/SidebarContent.vue +1 -1
- package/src/components/ui/sidebar/SidebarFooter.vue +1 -1
- package/src/components/ui/sidebar/SidebarGroup.vue +1 -1
- package/src/components/ui/sidebar/SidebarGroupAction.vue +3 -3
- package/src/components/ui/sidebar/SidebarGroupContent.vue +1 -1
- package/src/components/ui/sidebar/SidebarGroupLabel.vue +2 -2
- package/src/components/ui/sidebar/SidebarHeader.vue +1 -1
- package/src/components/ui/sidebar/SidebarInput.vue +1 -1
- package/src/components/ui/sidebar/SidebarInset.vue +2 -2
- package/src/components/ui/sidebar/SidebarMenu.vue +1 -1
- package/src/components/ui/sidebar/SidebarMenuAction.vue +7 -7
- package/src/components/ui/sidebar/SidebarMenuBadge.vue +6 -6
- package/src/components/ui/sidebar/SidebarMenuItem.vue +1 -1
- package/src/components/ui/sidebar/SidebarMenuSkeleton.vue +3 -3
- package/src/components/ui/sidebar/SidebarMenuSub.vue +2 -2
- package/src/components/ui/sidebar/SidebarMenuSubButton.vue +5 -5
- package/src/components/ui/sidebar/SidebarMenuSubItem.vue +1 -1
- package/src/components/ui/sidebar/SidebarProvider.vue +1 -1
- package/src/components/ui/sidebar/SidebarRail.vue +6 -6
- package/src/components/ui/sidebar/SidebarSeparator.vue +1 -1
- package/src/components/ui/sidebar/SidebarTrigger.vue +2 -2
- package/src/components/ui/skeleton/Skeleton.vue +1 -1
- package/src/components/ui/slider/Slider.vue +43 -0
- package/src/components/ui/sonner/Sonner.vue +7 -7
- package/src/components/ui/spinner/Spinner.vue +17 -0
- package/src/components/ui/stepper/Stepper.vue +27 -0
- package/src/components/ui/stepper/StepperDescription.vue +19 -0
- package/src/components/ui/stepper/StepperIndicator.vue +32 -0
- package/src/components/ui/stepper/StepperItem.vue +23 -0
- package/src/components/ui/stepper/StepperSeparator.vue +27 -0
- package/src/components/ui/stepper/StepperTitle.vue +19 -0
- package/src/components/ui/stepper/StepperTrigger.vue +22 -0
- package/src/components/ui/switch/Switch.vue +2 -2
- package/src/components/ui/table/Table.vue +12 -6
- package/src/components/ui/table/TableBody.vue +1 -1
- package/src/components/ui/table/TableCaption.vue +1 -1
- package/src/components/ui/table/TableCell.vue +1 -1
- package/src/components/ui/table/TableEmpty.vue +17 -14
- package/src/components/ui/table/TableFooter.vue +1 -1
- package/src/components/ui/table/TableHead.vue +1 -1
- package/src/components/ui/table/TableHeader.vue +1 -1
- package/src/components/ui/table/TableRow.vue +1 -1
- package/src/components/ui/tabs/Tabs.vue +1 -1
- package/src/components/ui/tabs/TabsContent.vue +1 -1
- package/src/components/ui/tabs/TabsList.vue +1 -1
- package/src/components/ui/tabs/TabsTrigger.vue +1 -1
- package/src/components/ui/tags-input/TagsInput.vue +26 -0
- package/src/components/ui/tags-input/TagsInputInput.vue +17 -0
- package/src/components/ui/tags-input/TagsInputItem.vue +20 -0
- package/src/components/ui/tags-input/TagsInputItemDelete.vue +22 -0
- package/src/components/ui/tags-input/TagsInputItemText.vue +19 -0
- package/src/components/ui/textarea/Textarea.vue +1 -1
- package/src/components/ui/toggle/Toggle.vue +35 -0
- package/src/components/ui/toggle-group/ToggleGroup.vue +49 -0
- package/src/components/ui/toggle-group/ToggleGroupItem.vue +46 -0
- package/src/components/ui/tooltip/TooltipContent.vue +2 -2
- package/dist/index.d.ts +0 -23
- package/dist/src/App.vue.d.ts +0 -2
- package/dist/src/components/HelloWorld.vue.d.ts +0 -5
- package/dist/src/components/NS/cards/NSBackupCard.vue.d.ts +0 -51
- package/dist/src/components/NS/cards/NSSystemInfoCard.vue.d.ts +0 -58
- package/dist/src/components/NS/cards/NSSystemdServiceCard.vue.d.ts +0 -47
- package/dist/src/components/NS/cards/index.d.ts +0 -3
- package/dist/src/components/NS/checkbox/NSCheckbox.vue.d.ts +0 -37
- package/dist/src/components/NS/checkbox/index.d.ts +0 -1
- package/dist/src/components/NS/data-table/NSDataTable.vue.d.ts +0 -98
- package/dist/src/components/NS/data-table/index.d.ts +0 -1
- package/dist/src/components/NS/empty-state/NSEmptyState.vue.d.ts +0 -45
- package/dist/src/components/NS/empty-state/index.d.ts +0 -1
- package/dist/src/components/NS/index.d.ts +0 -35
- package/dist/src/components/NS/inline-notification/NSInlineNotification.vue.d.ts +0 -44
- package/dist/src/components/NS/inline-notification/index.d.ts +0 -1
- package/dist/src/components/NS/lottie-animation/NSLottieAnimation.vue.d.ts +0 -75
- package/dist/src/components/NS/lottie-animation/index.d.ts +0 -1
- package/dist/src/components/NS/modal/NSModal.vue.d.ts +0 -56
- package/dist/src/components/NS/modal/NSModalTrigger.vue.d.ts +0 -64
- package/dist/src/components/NS/modal/index.d.ts +0 -2
- package/dist/src/components/NS/pagination/NSPagination.vue.d.ts +0 -36
- package/dist/src/components/NS/pagination/index.d.ts +0 -1
- package/dist/src/components/NS/progress/NSProgress.vue.d.ts +0 -37
- package/dist/src/components/NS/progress/NSProgressBar.vue.d.ts +0 -39
- package/dist/src/components/NS/progress/index.d.ts +0 -2
- package/dist/src/components/NS/slider/NSByteSlider.vue.d.ts +0 -50
- package/dist/src/components/NS/slider/NSSlider.vue.d.ts +0 -49
- package/dist/src/components/NS/slider/index.d.ts +0 -2
- package/dist/src/components/NS/tag/NSTag.vue.d.ts +0 -41
- package/dist/src/components/NS/tag/index.d.ts +0 -1
- package/dist/src/components/NS/text-input/NSTextInput.vue.d.ts +0 -67
- package/dist/src/components/NS/text-input/index.d.ts +0 -1
- package/dist/src/components/NS/toast-notification/NSToastNotification.vue.d.ts +0 -44
- package/dist/src/components/NS/toast-notification/index.d.ts +0 -1
- package/dist/src/components/NS/toggle/NSToggle.vue.d.ts +0 -51
- package/dist/src/components/NS/toggle/index.d.ts +0 -1
- package/dist/src/components/NS/wizard/NSWizard.vue.d.ts +0 -86
- package/dist/src/components/NS/wizard/index.d.ts +0 -1
- package/dist/src/components/ui/badge/Badge.vue.d.ts +0 -24
- package/dist/src/components/ui/badge/index.d.ts +0 -6
- package/dist/src/components/ui/button/Button.vue.d.ts +0 -27
- package/dist/src/components/ui/button/index.d.ts +0 -7
- package/dist/src/components/ui/card/Card.vue.d.ts +0 -21
- package/dist/src/components/ui/card/CardAction.vue.d.ts +0 -21
- package/dist/src/components/ui/card/CardContent.vue.d.ts +0 -21
- package/dist/src/components/ui/card/CardDescription.vue.d.ts +0 -21
- package/dist/src/components/ui/card/CardFooter.vue.d.ts +0 -21
- package/dist/src/components/ui/card/CardHeader.vue.d.ts +0 -21
- package/dist/src/components/ui/card/CardTitle.vue.d.ts +0 -21
- package/dist/src/components/ui/card/index.d.ts +0 -7
- package/dist/src/components/ui/checkbox/NsCheckbox.vue.d.ts +0 -49
- package/dist/src/components/ui/checkbox/index.d.ts +0 -11
- package/dist/src/components/ui/dialog/Dialog.vue.d.ts +0 -28
- package/dist/src/components/ui/dialog/index.d.ts +0 -1
- package/dist/src/components/ui/empty-state/NsEmptyState.vue.d.ts +0 -45
- package/dist/src/components/ui/empty-state/index.d.ts +0 -11
- package/dist/src/components/ui/inline-notification/NsInlineNotification.vue.d.ts +0 -45
- package/dist/src/components/ui/inline-notification/index.d.ts +0 -6
- package/dist/src/components/ui/input/Input.vue.d.ts +0 -12
- package/dist/src/components/ui/input/index.d.ts +0 -1
- package/dist/src/components/ui/input-group/InputGroup.vue.d.ts +0 -21
- package/dist/src/components/ui/input-group/InputGroupAddon.vue.d.ts +0 -25
- package/dist/src/components/ui/input-group/InputGroupButton.vue.d.ts +0 -22
- package/dist/src/components/ui/input-group/InputGroupInput.vue.d.ts +0 -6
- package/dist/src/components/ui/input-group/InputGroupText.vue.d.ts +0 -21
- package/dist/src/components/ui/input-group/InputGroupTextarea.vue.d.ts +0 -6
- package/dist/src/components/ui/input-group/index.d.ts +0 -22
- package/dist/src/components/ui/item/Item.vue.d.ts +0 -27
- package/dist/src/components/ui/item/ItemActions.vue.d.ts +0 -21
- package/dist/src/components/ui/item/ItemContent.vue.d.ts +0 -21
- package/dist/src/components/ui/item/ItemDescription.vue.d.ts +0 -21
- package/dist/src/components/ui/item/ItemFooter.vue.d.ts +0 -21
- package/dist/src/components/ui/item/ItemGroup.vue.d.ts +0 -21
- package/dist/src/components/ui/item/ItemHeader.vue.d.ts +0 -21
- package/dist/src/components/ui/item/ItemMedia.vue.d.ts +0 -23
- package/dist/src/components/ui/item/ItemSeparator.vue.d.ts +0 -7
- package/dist/src/components/ui/item/ItemTitle.vue.d.ts +0 -21
- package/dist/src/components/ui/item/index.d.ts +0 -20
- package/dist/src/components/ui/label/Label.vue.d.ts +0 -22
- package/dist/src/components/ui/label/index.d.ts +0 -1
- package/dist/src/components/ui/progress/Progress.vue.d.ts +0 -9
- package/dist/src/components/ui/progress/index.d.ts +0 -1
- package/dist/src/components/ui/scroll-area/ScrollArea.vue.d.ts +0 -22
- package/dist/src/components/ui/scroll-area/ScrollBar.vue.d.ts +0 -9
- package/dist/src/components/ui/scroll-area/index.d.ts +0 -2
- package/dist/src/components/ui/select/Select.vue.d.ts +0 -28
- package/dist/src/components/ui/select/SelectContent.vue.d.ts +0 -32
- package/dist/src/components/ui/select/SelectGroup.vue.d.ts +0 -18
- package/dist/src/components/ui/select/SelectItem.vue.d.ts +0 -23
- package/dist/src/components/ui/select/SelectItemText.vue.d.ts +0 -18
- package/dist/src/components/ui/select/SelectLabel.vue.d.ts +0 -22
- package/dist/src/components/ui/select/SelectScrollDownButton.vue.d.ts +0 -22
- package/dist/src/components/ui/select/SelectScrollUpButton.vue.d.ts +0 -22
- package/dist/src/components/ui/select/SelectSeparator.vue.d.ts +0 -7
- package/dist/src/components/ui/select/SelectTrigger.vue.d.ts +0 -25
- package/dist/src/components/ui/select/SelectValue.vue.d.ts +0 -18
- package/dist/src/components/ui/select/index.d.ts +0 -11
- package/dist/src/components/ui/separator/Separator.vue.d.ts +0 -10
- package/dist/src/components/ui/separator/index.d.ts +0 -1
- package/dist/src/components/ui/sheet/Sheet.vue.d.ts +0 -25
- package/dist/src/components/ui/sheet/SheetClose.vue.d.ts +0 -18
- package/dist/src/components/ui/sheet/SheetContent.vue.d.ts +0 -39
- package/dist/src/components/ui/sheet/SheetDescription.vue.d.ts +0 -22
- package/dist/src/components/ui/sheet/SheetFooter.vue.d.ts +0 -21
- package/dist/src/components/ui/sheet/SheetHeader.vue.d.ts +0 -21
- package/dist/src/components/ui/sheet/SheetOverlay.vue.d.ts +0 -22
- package/dist/src/components/ui/sheet/SheetTitle.vue.d.ts +0 -22
- package/dist/src/components/ui/sheet/SheetTrigger.vue.d.ts +0 -18
- package/dist/src/components/ui/sheet/index.d.ts +0 -8
- package/dist/src/components/ui/sidebar/Sidebar.vue.d.ts +0 -24
- package/dist/src/components/ui/sidebar/SidebarContent.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarFooter.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarGroup.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarGroupAction.vue.d.ts +0 -22
- package/dist/src/components/ui/sidebar/SidebarGroupContent.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarGroupLabel.vue.d.ts +0 -22
- package/dist/src/components/ui/sidebar/SidebarHeader.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarInput.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarInset.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarMenu.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarMenuAction.vue.d.ts +0 -25
- package/dist/src/components/ui/sidebar/SidebarMenuBadge.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarMenuButton.vue.d.ts +0 -27
- package/dist/src/components/ui/sidebar/SidebarMenuButtonChild.vue.d.ts +0 -30
- package/dist/src/components/ui/sidebar/SidebarMenuItem.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarMenuSkeleton.vue.d.ts +0 -7
- package/dist/src/components/ui/sidebar/SidebarMenuSub.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarMenuSubButton.vue.d.ts +0 -27
- package/dist/src/components/ui/sidebar/SidebarMenuSubItem.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarProvider.vue.d.ts +0 -30
- package/dist/src/components/ui/sidebar/SidebarRail.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarSeparator.vue.d.ts +0 -21
- package/dist/src/components/ui/sidebar/SidebarTrigger.vue.d.ts +0 -6
- package/dist/src/components/ui/sidebar/index.d.ts +0 -37
- package/dist/src/components/ui/sidebar/utils.d.ts +0 -56
- package/dist/src/components/ui/skeleton/Skeleton.vue.d.ts +0 -6
- package/dist/src/components/ui/skeleton/index.d.ts +0 -1
- package/dist/src/components/ui/sonner/Sonner.vue.d.ts +0 -3
- package/dist/src/components/ui/sonner/index.d.ts +0 -1
- package/dist/src/components/ui/switch/Switch.vue.d.ts +0 -28
- package/dist/src/components/ui/switch/index.d.ts +0 -1
- package/dist/src/components/ui/table/Table.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableBody.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableCaption.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableCell.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableEmpty.vue.d.ts +0 -24
- package/dist/src/components/ui/table/TableFooter.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableHead.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableHeader.vue.d.ts +0 -21
- package/dist/src/components/ui/table/TableRow.vue.d.ts +0 -21
- package/dist/src/components/ui/table/index.d.ts +0 -9
- package/dist/src/components/ui/table/utils.d.ts +0 -3
- package/dist/src/components/ui/tabs/Tabs.vue.d.ts +0 -28
- package/dist/src/components/ui/tabs/TabsContent.vue.d.ts +0 -22
- package/dist/src/components/ui/tabs/TabsList.vue.d.ts +0 -22
- package/dist/src/components/ui/tabs/TabsTrigger.vue.d.ts +0 -22
- package/dist/src/components/ui/tabs/index.d.ts +0 -4
- package/dist/src/components/ui/tag/NsTag.vue.d.ts +0 -42
- package/dist/src/components/ui/tag/index.d.ts +0 -8
- package/dist/src/components/ui/text-input/NsTextInput.vue.d.ts +0 -79
- package/dist/src/components/ui/text-input/index.d.ts +0 -15
- package/dist/src/components/ui/textarea/Textarea.vue.d.ts +0 -12
- package/dist/src/components/ui/textarea/index.d.ts +0 -1
- package/dist/src/components/ui/toggle/NsToggle.vue.d.ts +0 -54
- package/dist/src/components/ui/toggle/index.d.ts +0 -15
- package/dist/src/components/ui/tooltip/Tooltip.vue.d.ts +0 -24
- package/dist/src/components/ui/tooltip/TooltipContent.vue.d.ts +0 -30
- package/dist/src/components/ui/tooltip/TooltipProvider.vue.d.ts +0 -20
- package/dist/src/components/ui/tooltip/TooltipTrigger.vue.d.ts +0 -18
- package/dist/src/components/ui/tooltip/index.d.ts +0 -4
- package/dist/src/composables/index.d.ts +0 -8
- package/dist/src/composables/useDateTimeService.d.ts +0 -10
- package/dist/src/composables/useFilterService.d.ts +0 -8
- package/dist/src/composables/useIconService.d.ts +0 -153
- package/dist/src/composables/usePageTitleService.d.ts +0 -3
- package/dist/src/composables/useQueryParamService.d.ts +0 -13
- package/dist/src/composables/useStorageService.d.ts +0 -5
- package/dist/src/composables/useTaskService.d.ts +0 -18
- package/dist/src/composables/useUtilService.d.ts +0 -27
- package/dist/src/lib/utils.d.ts +0 -2
- package/dist/src/main.d.ts +0 -0
|
@@ -1,56 +1,68 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import { computed } from
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
import { computed } from "vue";
|
|
3
|
+
import {
|
|
4
|
+
HardDrive,
|
|
5
|
+
Activity,
|
|
6
|
+
CheckCircle,
|
|
7
|
+
AlertCircle,
|
|
8
|
+
Clock,
|
|
9
|
+
} from "lucide-vue-next";
|
|
10
|
+
import {
|
|
11
|
+
Card,
|
|
12
|
+
CardContent,
|
|
13
|
+
CardDescription,
|
|
14
|
+
CardHeader,
|
|
15
|
+
CardTitle,
|
|
16
|
+
} from "@/components/ui/card";
|
|
17
|
+
import { Progress } from "@/components/ui/progress";
|
|
18
|
+
import { Badge } from "@/components/ui/badge";
|
|
19
|
+
import { Button } from "@/components/ui/button";
|
|
20
|
+
import { cn } from "@/lib/utils";
|
|
9
21
|
|
|
10
22
|
interface SystemMetrics {
|
|
11
|
-
totalSpace: string
|
|
12
|
-
usedSpace: string
|
|
13
|
-
freeSpace: string
|
|
14
|
-
usagePercentage: number
|
|
15
|
-
temperature?: string
|
|
16
|
-
loadAverage?: string[]
|
|
17
|
-
uptime?: string
|
|
18
|
-
processes?: number
|
|
23
|
+
totalSpace: string;
|
|
24
|
+
usedSpace: string;
|
|
25
|
+
freeSpace: string;
|
|
26
|
+
usagePercentage: number;
|
|
27
|
+
temperature?: string;
|
|
28
|
+
loadAverage?: string[];
|
|
29
|
+
uptime?: string;
|
|
30
|
+
processes?: number;
|
|
19
31
|
memory?: {
|
|
20
|
-
total: string
|
|
21
|
-
used: string
|
|
22
|
-
free: string
|
|
23
|
-
percentage: number
|
|
24
|
-
}
|
|
32
|
+
total: string;
|
|
33
|
+
used: string;
|
|
34
|
+
free: string;
|
|
35
|
+
percentage: number;
|
|
36
|
+
};
|
|
25
37
|
cpu?: {
|
|
26
|
-
cores: number
|
|
27
|
-
usage: number
|
|
28
|
-
frequency: string
|
|
29
|
-
}
|
|
38
|
+
cores: number;
|
|
39
|
+
usage: number;
|
|
40
|
+
frequency: string;
|
|
41
|
+
};
|
|
30
42
|
}
|
|
31
43
|
|
|
32
44
|
interface Props {
|
|
33
|
-
title?: string
|
|
34
|
-
description?: string
|
|
35
|
-
metrics?: SystemMetrics
|
|
36
|
-
loading?: boolean
|
|
37
|
-
refreshInterval?: number
|
|
38
|
-
showTemperature?: boolean
|
|
39
|
-
showLoadAverage?: boolean
|
|
40
|
-
showUptime?: boolean
|
|
41
|
-
showProcesses?: boolean
|
|
42
|
-
showMemory?: boolean
|
|
43
|
-
showCpu?: boolean
|
|
44
|
-
showStorage?: boolean
|
|
45
|
-
refreshable?: boolean
|
|
46
|
-
light?: boolean
|
|
47
|
-
maxHeight?: string
|
|
48
|
-
class?: string
|
|
45
|
+
title?: string;
|
|
46
|
+
description?: string;
|
|
47
|
+
metrics?: SystemMetrics;
|
|
48
|
+
loading?: boolean;
|
|
49
|
+
refreshInterval?: number;
|
|
50
|
+
showTemperature?: boolean;
|
|
51
|
+
showLoadAverage?: boolean;
|
|
52
|
+
showUptime?: boolean;
|
|
53
|
+
showProcesses?: boolean;
|
|
54
|
+
showMemory?: boolean;
|
|
55
|
+
showCpu?: boolean;
|
|
56
|
+
showStorage?: boolean;
|
|
57
|
+
refreshable?: boolean;
|
|
58
|
+
light?: boolean;
|
|
59
|
+
maxHeight?: string;
|
|
60
|
+
class?: string;
|
|
49
61
|
}
|
|
50
62
|
|
|
51
63
|
const props = withDefaults(defineProps<Props>(), {
|
|
52
|
-
title:
|
|
53
|
-
description:
|
|
64
|
+
title: "System Information",
|
|
65
|
+
description: "Current system status and metrics",
|
|
54
66
|
loading: false,
|
|
55
67
|
showTemperature: false,
|
|
56
68
|
showLoadAverage: true,
|
|
@@ -61,83 +73,81 @@ const props = withDefaults(defineProps<Props>(), {
|
|
|
61
73
|
showStorage: true,
|
|
62
74
|
refreshable: true,
|
|
63
75
|
light: false,
|
|
64
|
-
})
|
|
76
|
+
});
|
|
65
77
|
|
|
66
78
|
const emit = defineEmits<{
|
|
67
|
-
refresh: []
|
|
68
|
-
}>()
|
|
79
|
+
refresh: [];
|
|
80
|
+
}>();
|
|
69
81
|
|
|
70
|
-
const hasMetrics = computed(() => !!props.metrics)
|
|
82
|
+
const hasMetrics = computed(() => !!props.metrics);
|
|
71
83
|
|
|
72
84
|
const storageVariant = computed(() => {
|
|
73
|
-
if (!props.metrics?.usagePercentage) return
|
|
74
|
-
|
|
75
|
-
const percentage = props.metrics.usagePercentage
|
|
76
|
-
if (percentage >= 90) return
|
|
77
|
-
if (percentage >= 80) return
|
|
78
|
-
if (percentage >= 60) return
|
|
79
|
-
return
|
|
80
|
-
})
|
|
85
|
+
if (!props.metrics?.usagePercentage) return "default";
|
|
86
|
+
|
|
87
|
+
const percentage = props.metrics.usagePercentage;
|
|
88
|
+
if (percentage >= 90) return "destructive";
|
|
89
|
+
if (percentage >= 80) return "warning";
|
|
90
|
+
if (percentage >= 60) return "default";
|
|
91
|
+
return "success";
|
|
92
|
+
});
|
|
81
93
|
|
|
82
94
|
const memoryVariant = computed(() => {
|
|
83
|
-
if (!props.metrics?.memory?.percentage) return
|
|
84
|
-
|
|
85
|
-
const percentage = props.metrics.memory.percentage
|
|
86
|
-
if (percentage >= 90) return
|
|
87
|
-
if (percentage >= 80) return
|
|
88
|
-
if (percentage >= 60) return
|
|
89
|
-
return
|
|
90
|
-
})
|
|
95
|
+
if (!props.metrics?.memory?.percentage) return "default";
|
|
96
|
+
|
|
97
|
+
const percentage = props.metrics.memory.percentage;
|
|
98
|
+
if (percentage >= 90) return "destructive";
|
|
99
|
+
if (percentage >= 80) return "warning";
|
|
100
|
+
if (percentage >= 60) return "default";
|
|
101
|
+
return "success";
|
|
102
|
+
});
|
|
91
103
|
|
|
92
104
|
const cpuVariant = computed(() => {
|
|
93
|
-
if (!props.metrics?.cpu?.usage) return
|
|
94
|
-
|
|
95
|
-
const usage = props.metrics.cpu.usage
|
|
96
|
-
if (usage >= 90) return
|
|
97
|
-
if (usage >= 80) return
|
|
98
|
-
if (usage >= 60) return
|
|
99
|
-
return
|
|
100
|
-
})
|
|
101
|
-
|
|
102
|
-
const containerClasses = computed(() => {
|
|
103
|
-
return cn('w-full', props.class)
|
|
104
|
-
})
|
|
105
|
+
if (!props.metrics?.cpu?.usage) return "default";
|
|
106
|
+
|
|
107
|
+
const usage = props.metrics.cpu.usage;
|
|
108
|
+
if (usage >= 90) return "destructive";
|
|
109
|
+
if (usage >= 80) return "warning";
|
|
110
|
+
if (usage >= 60) return "default";
|
|
111
|
+
return "success";
|
|
112
|
+
});
|
|
105
113
|
|
|
106
114
|
const cardClasses = computed(() => {
|
|
107
115
|
return cn(
|
|
108
|
-
|
|
109
|
-
props.light ?
|
|
110
|
-
)
|
|
111
|
-
})
|
|
116
|
+
"transition-all duration-200 hover:shadow-md",
|
|
117
|
+
props.light ? "bg-background/95" : "bg-background",
|
|
118
|
+
);
|
|
119
|
+
});
|
|
112
120
|
|
|
113
121
|
const metricsGridClasses = computed(() => {
|
|
114
|
-
return cn(
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
122
|
+
return cn("grid gap-4", {
|
|
123
|
+
"grid-cols-1": !props.showMemory && !props.showCpu && !props.showStorage,
|
|
124
|
+
"grid-cols-2":
|
|
125
|
+
(props.showMemory && !props.showCpu && !props.showStorage) ||
|
|
126
|
+
(!props.showMemory && props.showCpu && !props.showStorage) ||
|
|
127
|
+
(!props.showMemory && !props.showCpu && props.showStorage),
|
|
128
|
+
"grid-cols-3":
|
|
129
|
+
(props.showMemory && props.showCpu && !props.showStorage) ||
|
|
130
|
+
(props.showMemory && !props.showCpu && props.showStorage) ||
|
|
131
|
+
(!props.showMemory && props.showCpu && props.showStorage),
|
|
132
|
+
"lg:grid-cols-4": props.showMemory && props.showCpu && props.showStorage,
|
|
133
|
+
});
|
|
134
|
+
});
|
|
125
135
|
</script>
|
|
126
136
|
|
|
127
137
|
<template>
|
|
128
138
|
<Card :class="cardClasses">
|
|
129
|
-
<CardHeader class="pb-3">
|
|
130
|
-
<div class="flex items-center justify-between">
|
|
139
|
+
<CardHeader class="tw:pb-3">
|
|
140
|
+
<div class="tw:flex tw:items-center tw:justify-between">
|
|
131
141
|
<div>
|
|
132
|
-
<CardTitle class="flex items-center gap-2">
|
|
133
|
-
<Activity class="h-5 w-5 text-primary" />
|
|
142
|
+
<CardTitle class="tw:flex tw:items-center tw:gap-2">
|
|
143
|
+
<Activity class="tw:h-5 tw:w-5 tw:text-primary" />
|
|
134
144
|
{{ title }}
|
|
135
145
|
</CardTitle>
|
|
136
146
|
<CardDescription>
|
|
137
147
|
{{ description }}
|
|
138
148
|
</CardDescription>
|
|
139
149
|
</div>
|
|
140
|
-
|
|
150
|
+
|
|
141
151
|
<!-- Refresh button -->
|
|
142
152
|
<Button
|
|
143
153
|
v-if="refreshable && !loading"
|
|
@@ -145,108 +155,126 @@ const metricsGridClasses = computed(() => {
|
|
|
145
155
|
size="sm"
|
|
146
156
|
@click="emit('refresh')"
|
|
147
157
|
>
|
|
148
|
-
<Clock class="h-4 w-4" />
|
|
158
|
+
<Clock class="tw:h-4 tw:w-4" />
|
|
149
159
|
</Button>
|
|
150
160
|
</div>
|
|
151
161
|
</CardHeader>
|
|
152
162
|
|
|
153
|
-
<CardContent class="space-y-4">
|
|
163
|
+
<CardContent class="tw:space-y-4">
|
|
154
164
|
<!-- Loading state -->
|
|
155
|
-
<div v-if="loading" class="space-y-3">
|
|
156
|
-
<div class="space-y-2">
|
|
157
|
-
<div class="h-2 bg-secondary rounded-full" />
|
|
158
|
-
<div class="h-2 bg-secondary rounded-full" />
|
|
159
|
-
<div class="h-2 bg-secondary rounded-full" />
|
|
165
|
+
<div v-if="loading" class="tw:space-y-3">
|
|
166
|
+
<div class="tw:space-y-2">
|
|
167
|
+
<div class="tw:h-2 tw:bg-secondary tw:rounded-full" />
|
|
168
|
+
<div class="tw:h-2 tw:bg-secondary tw:rounded-full" />
|
|
169
|
+
<div class="tw:h-2 tw:bg-secondary tw:rounded-full" />
|
|
160
170
|
</div>
|
|
161
171
|
</div>
|
|
162
172
|
|
|
163
173
|
<!-- System metrics -->
|
|
164
174
|
<div v-else-if="hasMetrics" :class="metricsGridClasses">
|
|
165
175
|
<!-- Storage metrics -->
|
|
166
|
-
<div v-if="showStorage" class="space-y-2">
|
|
167
|
-
<div
|
|
168
|
-
|
|
176
|
+
<div v-if="showStorage" class="tw:space-y-2">
|
|
177
|
+
<div
|
|
178
|
+
class="tw:flex tw:items-center tw:gap-2 tw:text-sm tw:font-medium"
|
|
179
|
+
>
|
|
180
|
+
<HardDrive class="tw:h-4 tw:w-4" />
|
|
169
181
|
Storage
|
|
170
182
|
</div>
|
|
171
|
-
<Progress
|
|
172
|
-
:value="metrics.usagePercentage"
|
|
183
|
+
<Progress
|
|
184
|
+
:value="metrics.usagePercentage"
|
|
173
185
|
:variant="storageVariant"
|
|
174
|
-
class="mb-2"
|
|
186
|
+
class="tw:mb-2"
|
|
175
187
|
/>
|
|
176
|
-
<div class="text-xs text-muted-foreground space-y-1">
|
|
188
|
+
<div class="tw:text-xs tw:text-muted-foreground tw:space-y-1">
|
|
177
189
|
<div>Used: {{ metrics.usedSpace }} / {{ metrics.totalSpace }}</div>
|
|
178
190
|
<div>Free: {{ metrics.freeSpace }}</div>
|
|
179
191
|
</div>
|
|
180
192
|
</div>
|
|
181
193
|
|
|
182
194
|
<!-- Memory metrics -->
|
|
183
|
-
<div v-if="showMemory && metrics?.memory" class="space-y-2">
|
|
184
|
-
<div
|
|
185
|
-
|
|
195
|
+
<div v-if="showMemory && metrics?.memory" class="tw:space-y-2">
|
|
196
|
+
<div
|
|
197
|
+
class="tw:flex tw:items-center tw:gap-2 tw:text-sm tw:font-medium"
|
|
198
|
+
>
|
|
199
|
+
<Activity class="tw:h-4 tw:w-4" />
|
|
186
200
|
Memory
|
|
187
201
|
</div>
|
|
188
|
-
<Progress
|
|
189
|
-
:value="metrics.memory.percentage"
|
|
202
|
+
<Progress
|
|
203
|
+
:value="metrics.memory.percentage"
|
|
190
204
|
:variant="memoryVariant"
|
|
191
|
-
class="mb-2"
|
|
205
|
+
class="tw:mb-2"
|
|
192
206
|
/>
|
|
193
|
-
<div class="text-xs text-muted-foreground space-y-1">
|
|
194
|
-
<div>
|
|
207
|
+
<div class="tw:text-xs tw:text-muted-foreground tw:space-y-1">
|
|
208
|
+
<div>
|
|
209
|
+
Used: {{ metrics.memory.used }} / {{ metrics.memory.total }}
|
|
210
|
+
</div>
|
|
195
211
|
<div>Free: {{ metrics.memory.free }}</div>
|
|
196
212
|
</div>
|
|
197
213
|
</div>
|
|
198
214
|
|
|
199
215
|
<!-- CPU metrics -->
|
|
200
|
-
<div v-if="showCpu && metrics?.cpu" class="space-y-2">
|
|
201
|
-
<div
|
|
202
|
-
|
|
216
|
+
<div v-if="showCpu && metrics?.cpu" class="tw:space-y-2">
|
|
217
|
+
<div
|
|
218
|
+
class="tw:flex tw:items-center tw:gap-2 tw:text-sm tw:font-medium"
|
|
219
|
+
>
|
|
220
|
+
<Activity class="tw:h-4 tw:w-4" />
|
|
203
221
|
CPU
|
|
204
222
|
</div>
|
|
205
|
-
<Progress
|
|
206
|
-
:value="metrics.cpu.usage"
|
|
223
|
+
<Progress
|
|
224
|
+
:value="metrics.cpu.usage"
|
|
207
225
|
:variant="cpuVariant"
|
|
208
|
-
class="mb-2"
|
|
226
|
+
class="tw:mb-2"
|
|
209
227
|
/>
|
|
210
|
-
<div class="text-xs text-muted-foreground space-y-1">
|
|
228
|
+
<div class="tw:text-xs tw:text-muted-foreground tw:space-y-1">
|
|
211
229
|
<div>Usage: {{ metrics.cpu.usage }}%</div>
|
|
212
230
|
<div>Cores: {{ metrics.cpu.cores }}</div>
|
|
213
|
-
<div v-if="metrics.cpu.frequency">
|
|
231
|
+
<div v-if="metrics.cpu.frequency">
|
|
232
|
+
Frequency: {{ metrics.cpu.frequency }}
|
|
233
|
+
</div>
|
|
214
234
|
</div>
|
|
215
235
|
</div>
|
|
216
236
|
</div>
|
|
217
237
|
|
|
218
238
|
<!-- Additional system info -->
|
|
219
|
-
<div
|
|
239
|
+
<div
|
|
240
|
+
v-if="hasMetrics"
|
|
241
|
+
class="tw:grid tw:grid-cols-1 md:tw:grid-cols-2 lg:tw:grid-cols-4 tw:gap-3 tw:pt-4 tw:border-t"
|
|
242
|
+
>
|
|
220
243
|
<!-- Temperature -->
|
|
221
244
|
<div v-if="showTemperature && metrics?.temperature">
|
|
222
|
-
<div class="text-xs text-muted-foreground">Temperature</div>
|
|
223
|
-
<div class="text-sm font-medium">{{ metrics.temperature }}</div>
|
|
245
|
+
<div class="tw:text-xs tw:text-muted-foreground">Temperature</div>
|
|
246
|
+
<div class="tw:text-sm tw:font-medium">{{ metrics.temperature }}</div>
|
|
224
247
|
</div>
|
|
225
248
|
|
|
226
249
|
<!-- Load average -->
|
|
227
250
|
<div v-if="showLoadAverage && metrics?.loadAverage">
|
|
228
|
-
<div class="text-xs text-muted-foreground">Load Average</div>
|
|
229
|
-
<div class="text-sm font-medium">
|
|
251
|
+
<div class="tw:text-xs tw:text-muted-foreground">Load Average</div>
|
|
252
|
+
<div class="tw:text-sm tw:font-medium">
|
|
253
|
+
{{ metrics.loadAverage.join(", ") }}
|
|
254
|
+
</div>
|
|
230
255
|
</div>
|
|
231
256
|
|
|
232
257
|
<!-- Uptime -->
|
|
233
258
|
<div v-if="showUptime && metrics?.uptime">
|
|
234
|
-
<div class="text-xs text-muted-foreground">Uptime</div>
|
|
235
|
-
<div class="text-sm font-medium">{{ metrics.uptime }}</div>
|
|
259
|
+
<div class="tw:text-xs tw:text-muted-foreground">Uptime</div>
|
|
260
|
+
<div class="tw:text-sm tw:font-medium">{{ metrics.uptime }}</div>
|
|
236
261
|
</div>
|
|
237
262
|
|
|
238
263
|
<!-- Processes -->
|
|
239
264
|
<div v-if="showProcesses && metrics?.processes">
|
|
240
|
-
<div class="text-xs text-muted-foreground">Processes</div>
|
|
241
|
-
<div class="text-sm font-medium">{{ metrics.processes }}</div>
|
|
265
|
+
<div class="tw:text-xs tw:text-muted-foreground">Processes</div>
|
|
266
|
+
<div class="tw:text-sm tw:font-medium">{{ metrics.processes }}</div>
|
|
242
267
|
</div>
|
|
243
268
|
</div>
|
|
244
269
|
|
|
245
270
|
<!-- No data state -->
|
|
246
|
-
<div
|
|
247
|
-
|
|
271
|
+
<div
|
|
272
|
+
v-if="!hasMetrics && !loading"
|
|
273
|
+
class="tw:flex tw:items-center tw:gap-3 tw:text-muted-foreground"
|
|
274
|
+
>
|
|
275
|
+
<AlertCircle class="tw:h-5 tw:w-5" />
|
|
248
276
|
<span>No system metrics available</span>
|
|
249
277
|
</div>
|
|
250
278
|
</CardContent>
|
|
251
279
|
</Card>
|
|
252
|
-
</template>
|
|
280
|
+
</template>
|
|
@@ -125,16 +125,16 @@ const iconClass = computed(() => {
|
|
|
125
125
|
|
|
126
126
|
<template>
|
|
127
127
|
<Card :class="cardClasses">
|
|
128
|
-
<CardHeader class="pb-3">
|
|
129
|
-
<div class="flex items-center justify-between">
|
|
130
|
-
<CardTitle class="flex items-center gap-3">
|
|
128
|
+
<CardHeader class="tw:pb-3">
|
|
129
|
+
<div class="tw:flex tw:items-center tw:justify-between">
|
|
130
|
+
<CardTitle class="tw:flex tw:items-center tw:gap-3">
|
|
131
131
|
<component
|
|
132
132
|
v-if="icon"
|
|
133
133
|
:is="icon"
|
|
134
134
|
:class="iconClass"
|
|
135
135
|
/>
|
|
136
136
|
<div>
|
|
137
|
-
<div class="text-lg font-semibold">{{ title }}</div>
|
|
137
|
+
<div class="tw:text-lg tw:font-semibold">{{ title }}</div>
|
|
138
138
|
<CardDescription v-if="description">
|
|
139
139
|
{{ description }}
|
|
140
140
|
</CardDescription>
|
|
@@ -148,53 +148,53 @@ const iconClass = computed(() => {
|
|
|
148
148
|
</div>
|
|
149
149
|
</CardHeader>
|
|
150
150
|
|
|
151
|
-
<CardContent class="space-y-4">
|
|
151
|
+
<CardContent class="tw:space-y-4">
|
|
152
152
|
<!-- Loading state -->
|
|
153
|
-
<div v-if="loading" class="space-y-3">
|
|
154
|
-
<Skeleton class="h-4 w-3/4" />
|
|
155
|
-
<Skeleton class="h-4 w-1/2" />
|
|
156
|
-
<Skeleton class="h-4 w-2/3" />
|
|
153
|
+
<div v-if="loading" class="tw:space-y-3">
|
|
154
|
+
<Skeleton class="tw:h-4 tw:w-3/4" />
|
|
155
|
+
<Skeleton class="tw:h-4 tw:w-1/2" />
|
|
156
|
+
<Skeleton class="tw:h-4 tw:w-2/3" />
|
|
157
157
|
</div>
|
|
158
158
|
|
|
159
159
|
<!-- Service details -->
|
|
160
|
-
<div v-else class="space-y-3">
|
|
160
|
+
<div v-else class="tw:space-y-3">
|
|
161
161
|
<!-- Service name -->
|
|
162
|
-
<div v-if="serviceName" class="text-sm text-muted-foreground">
|
|
163
|
-
<span class="font-medium">Service:</span> {{ serviceName }}
|
|
162
|
+
<div v-if="serviceName" class="tw:text-sm tw:text-muted-foreground">
|
|
163
|
+
<span class="tw:font-medium">Service:</span> {{ serviceName }}
|
|
164
164
|
</div>
|
|
165
165
|
|
|
166
166
|
<!-- Uptime -->
|
|
167
|
-
<div v-if="showUptime && status?.uptime" class="flex items-center gap-2">
|
|
168
|
-
<Clock class="h-4 w-4 text-muted-foreground" />
|
|
169
|
-
<span class="text-sm">
|
|
170
|
-
<span class="font-medium">Uptime:</span> {{ status.uptime }}
|
|
167
|
+
<div v-if="showUptime && status?.uptime" class="tw:flex tw:items-center tw:gap-2">
|
|
168
|
+
<Clock class="tw:h-4 tw:w-4 tw:text-muted-foreground" />
|
|
169
|
+
<span class="tw:text-sm">
|
|
170
|
+
<span class="tw:font-medium">Uptime:</span> {{ status.uptime }}
|
|
171
171
|
</span>
|
|
172
172
|
</div>
|
|
173
173
|
|
|
174
174
|
<!-- Last restart -->
|
|
175
|
-
<div v-if="status?.lastRestart" class="text-sm text-muted-foreground">
|
|
176
|
-
<span class="font-medium">Last restart:</span> {{ status.lastRestart }}
|
|
175
|
+
<div v-if="status?.lastRestart" class="tw:text-sm tw:text-muted-foreground">
|
|
176
|
+
<span class="tw:font-medium">Last restart:</span> {{ status.lastRestart }}
|
|
177
177
|
</div>
|
|
178
178
|
|
|
179
179
|
<!-- Metrics -->
|
|
180
|
-
<div v-if="showMetrics" class="grid grid-cols-2 gap-3">
|
|
181
|
-
<div v-if="status?.memory" class="text-sm">
|
|
182
|
-
<span class="font-medium">Memory:</span> {{ status.memory }}
|
|
180
|
+
<div v-if="showMetrics" class="tw:grid tw:grid-cols-2 tw:gap-3">
|
|
181
|
+
<div v-if="status?.memory" class="tw:text-sm">
|
|
182
|
+
<span class="tw:font-medium">Memory:</span> {{ status.memory }}
|
|
183
183
|
</div>
|
|
184
|
-
<div v-if="status?.cpu" class="text-sm">
|
|
185
|
-
<span class="font-medium">CPU:</span> {{ status.cpu }}
|
|
184
|
+
<div v-if="status?.cpu" class="tw:text-sm">
|
|
185
|
+
<span class="tw:font-medium">CPU:</span> {{ status.cpu }}
|
|
186
186
|
</div>
|
|
187
187
|
</div>
|
|
188
188
|
|
|
189
189
|
<!-- Custom status message -->
|
|
190
|
-
<div v-if="status?.status && status?.status !== statusText" class="text-sm">
|
|
190
|
+
<div v-if="status?.status && status?.status !== statusText" class="tw:text-sm">
|
|
191
191
|
{{ status.status }}
|
|
192
192
|
</div>
|
|
193
193
|
</div>
|
|
194
194
|
|
|
195
195
|
<!-- Action buttons -->
|
|
196
|
-
<div class="flex items-center justify-between pt-4 border-t">
|
|
197
|
-
<div class="flex gap-2">
|
|
196
|
+
<div class="tw:flex tw:items-center tw:justify-between tw:pt-4 tw:border-t">
|
|
197
|
+
<div class="tw:flex tw:gap-2">
|
|
198
198
|
<Button
|
|
199
199
|
v-if="status?.enabled && !status?.running"
|
|
200
200
|
variant="default"
|
|
@@ -242,7 +242,7 @@ const iconClass = computed(() => {
|
|
|
242
242
|
size="sm"
|
|
243
243
|
@click="emit('view', serviceName)"
|
|
244
244
|
>
|
|
245
|
-
<MoreHorizontal class="h-4 w-4" />
|
|
245
|
+
<MoreHorizontal class="tw:h-4 tw:w-4" />
|
|
246
246
|
</Button>
|
|
247
247
|
</div>
|
|
248
248
|
</CardContent>
|
|
@@ -47,8 +47,7 @@ const isChecked = computed({
|
|
|
47
47
|
:required="required"
|
|
48
48
|
:name="name"
|
|
49
49
|
:value="value"
|
|
50
|
-
:class="cn(
|
|
51
|
-
'peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground',
|
|
50
|
+
:class="cn( 'peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground',
|
|
52
51
|
{
|
|
53
52
|
'border-destructive': errorMessage,
|
|
54
53
|
'data-[state=checked]:bg-destructive data-[state=checked]:text-destructive-foreground': errorMessage
|
|
@@ -61,17 +60,16 @@ const isChecked = computed({
|
|
|
61
60
|
'opacity-50': indeterminate
|
|
62
61
|
})"
|
|
63
62
|
>
|
|
64
|
-
<Check v-if="!indeterminate" class="h-4 w-4" />
|
|
65
|
-
<div v-else class="h-1 w-2 bg-current rounded-sm" />
|
|
63
|
+
<Check v-if="!indeterminate" class="tw:h-4 tw:w-4" />
|
|
64
|
+
<div v-else class="tw:h-1 tw:w-2 tw:bg-current tw:rounded-sm" />
|
|
66
65
|
</CheckboxIndicator>
|
|
67
66
|
</CheckboxRoot>
|
|
68
67
|
|
|
69
|
-
<div class="grid gap-1.5">
|
|
68
|
+
<div class="tw:grid tw:gap-1.5">
|
|
70
69
|
<label
|
|
71
70
|
v-if="label || $slots.label"
|
|
72
71
|
:for="checkboxId"
|
|
73
|
-
:class="cn(
|
|
74
|
-
'text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 cursor-pointer',
|
|
72
|
+
:class="cn( 'text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 cursor-pointer',
|
|
75
73
|
{
|
|
76
74
|
'sr-only': hideLabel,
|
|
77
75
|
'cursor-not-allowed': disabled,
|
|
@@ -93,7 +91,7 @@ const isChecked = computed({
|
|
|
93
91
|
|
|
94
92
|
<p
|
|
95
93
|
v-if="errorMessage"
|
|
96
|
-
class="text-sm text-destructive"
|
|
94
|
+
class="tw:text-sm tw:text-destructive"
|
|
97
95
|
>
|
|
98
96
|
{{ errorMessage }}
|
|
99
97
|
</p>
|