shivanya-sdk 0.1.0 → 0.1.2
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/package.json +28 -29
- package/packages/ai/README.md +66 -0
- package/packages/core/README.md +57 -0
- package/packages/shell/README.md +8 -32
- package/packages/shell/package.json +5 -6
- package/packages/shell/scripts/copy-assets.mjs +24 -0
- package/packages/shell/src/components/DrawerHeader.tsx +34 -9
- package/packages/shell/src/components/ShellBrand.tsx +12 -6
- package/packages/shell/src/components/ShellFooter.tsx +19 -6
- package/packages/shell/src/components/ShellHeader.tsx +22 -37
- package/packages/shell/src/components/ShellMobileNav.tsx +119 -28
- package/packages/shell/src/components/ShellRoot.tsx +10 -5
- package/packages/shell/src/components/ShellSidebar.tsx +102 -41
- package/packages/shell/src/components/SidebarFooter.tsx +30 -10
- package/packages/shell/src/context/ShellProvider.tsx +2 -0
- package/packages/shell/src/hooks/useBreakpoint.ts +2 -0
- package/packages/shell/src/hooks/useShell.ts +7 -3
- package/packages/shell/src/hooks/useSidebar.ts +2 -0
- package/packages/shell/src/index.ts +1 -1
- package/packages/shell/src/layouts/AppShell.tsx +4 -2
- package/packages/shell/src/layouts/BlankShell.tsx +15 -6
- package/packages/shell/src/layouts/CenteredShell.tsx +26 -7
- package/packages/shell/src/layouts/DashboardShell.tsx +38 -37
- package/packages/shell/src/layouts/PageContainer.tsx +28 -9
- package/packages/shell/src/layouts/PageHeader.tsx +41 -13
- package/packages/shell/src/layouts/WebsiteShell.tsx +44 -11
- package/packages/shell/src/styles/blank-shell.css +6 -0
- package/packages/shell/src/styles/centered-shell.css +26 -0
- package/packages/shell/src/styles/dashboard-shell.css +108 -0
- package/packages/shell/src/styles/index.ts +14 -1
- package/packages/shell/src/styles/page-container.css +41 -0
- package/packages/shell/src/styles/page-header.css +71 -0
- package/packages/shell/src/styles/shell-brand.css +42 -0
- package/packages/shell/src/styles/shell-drawer-header.css +24 -0
- package/packages/shell/src/styles/shell-footer.css +65 -0
- package/packages/shell/src/styles/shell-header.css +68 -0
- package/packages/shell/src/styles/shell-main.css +17 -0
- package/packages/shell/src/styles/shell-mobile-nav.css +148 -0
- package/packages/shell/src/styles/shell-root.css +9 -0
- package/packages/shell/src/styles/shell-sidebar-footer.css +57 -0
- package/packages/shell/src/styles/shell-sidebar.css +146 -0
- package/packages/shell/src/styles/website-shell.css +51 -0
- package/packages/shell/tsconfig.json +2 -2
- package/packages/ui/README.md +0 -12
- package/packages/ui/package.json +4 -6
- package/packages/ui/scripts/copy-assets.mjs +61 -0
- package/packages/ui/scripts/generate-icons.mjs +45 -0
- package/packages/ui/src/components/charts/BarChart/components/Bar.tsx +2 -0
- package/packages/ui/src/components/charts/BarChart/hooks/useResizeObserver.ts +2 -0
- package/packages/ui/src/components/charts/BarChart/hooks/useTooltip.ts +2 -0
- package/packages/ui/src/components/data-display/Accordion/Accordion.tsx +2 -0
- package/packages/ui/src/components/data-display/AnimatedNumber/AnimatedNumber.tsx +2 -1
- package/packages/ui/src/components/data-display/Avatar/Avatar.tsx +2 -0
- package/packages/ui/src/components/data-display/Calendar/Calendar.tsx +2 -1
- package/packages/ui/src/components/data-display/Chip/Chip.tsx +2 -0
- package/packages/ui/src/components/data-display/DataGrid/DataGrid.tsx +3 -1
- package/packages/ui/src/components/data-display/List/List.tsx +2 -0
- package/packages/ui/src/components/data-display/TreeView/TreeView.tsx +2 -1
- package/packages/ui/src/components/feedback/Alert/Alert.tsx +2 -1
- package/packages/ui/src/components/feedback/ConfirmDialog/ConfirmDialog.tsx +2 -0
- package/packages/ui/src/components/feedback/Dialog/Dialog.tsx +2 -1
- package/packages/ui/src/components/feedback/Modal/Modal.tsx +2 -0
- package/packages/ui/src/components/feedback/Notification/Notification.tsx +2 -1
- package/packages/ui/src/components/feedback/Popover/Popover.tsx +2 -0
- package/packages/ui/src/components/feedback/Toast/Toast.tsx +2 -1
- package/packages/ui/src/components/forms/Autocomplete/Autocomplete.tsx +3 -1
- package/packages/ui/src/components/forms/DatePicker/DatePicker.tsx +2 -0
- package/packages/ui/src/components/forms/DateRangePicker/DateRangePicker.tsx +2 -1
- package/packages/ui/src/components/forms/FileUpload/FileUpload.tsx +2 -0
- package/packages/ui/src/components/forms/NumberInput/NumberInput.tsx +2 -1
- package/packages/ui/src/components/forms/OtpInput/OtpInput.tsx +2 -1
- package/packages/ui/src/components/forms/PasswordInput/PasswordInput.tsx +2 -1
- package/packages/ui/src/components/forms/Select/Select.tsx +2 -0
- package/packages/ui/src/components/forms/Textarea/Textarea.tsx +2 -1
- package/packages/ui/src/components/foundation/Link/Link.tsx +2 -0
- package/packages/ui/src/components/media/Carousel/Carousel.tsx +2 -0
- package/packages/ui/src/components/media/ImageCropper/ImageCropper.tsx +2 -0
- package/packages/ui/src/components/media/ImageCropper/ImageCropperModal.tsx +2 -1
- package/packages/ui/src/components/media/ImageCropper/hooks.ts +2 -0
- package/packages/ui/src/components/navigation/menu/MenuItem.tsx +49 -2
- package/packages/ui/src/components/navigation/navbar/NavbarItem.tsx +53 -2
- package/packages/ui/src/components/navigation/pagination/Pagination.tsx +2 -0
- package/packages/ui/src/components/navigation/pagination/PaginationItem.tsx +41 -1
- package/packages/ui/src/components/navigation/sidebar/SidebarItem.tsx +53 -2
- package/packages/ui/src/components/navigation/stepper/Step.tsx +2 -0
- package/packages/ui/src/components/navigation/stepper/Stepper.tsx +2 -1
- package/packages/ui/src/components/navigation/tabs/Tab.tsx +45 -1
- package/packages/ui/src/components/navigation/tabs/Tabs.tsx +2 -1
- package/packages/ui/src/components/overlays/CommandPalette/CommandPalette.tsx +85 -89
- package/packages/ui/src/components/overlays/ContextMenu/ContextMenu.tsx +69 -70
- package/packages/ui/src/components/overlays/Drawer/Drawer.tsx +2 -0
- package/packages/ui/src/components/overlays/Sheet/Sheet.tsx +81 -92
- package/packages/ui/src/components/utilities/ClickAwayListener/ClickAwayListener.tsx +2 -0
- package/packages/ui/src/components/utilities/CopyButton/CopyButton.tsx +2 -1
- package/packages/ui/src/components/utilities/FocusTrap/FocusTrap.tsx +2 -0
- package/packages/ui/src/components/utilities/Portal/Portal.tsx +2 -0
- package/packages/ui/src/icons/icons/AccessibilityIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/ActiveUsersIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ActivityIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/AlertCircleIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/AnalyticsIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/AppsIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/ArchiveIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/ArrowDownIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ArrowLeftIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ArrowRightIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/ArrowUpIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ArrowUpRightIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/AspectRatioIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/BadgeIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/BeakerIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/BellIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/BoltIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/BoxIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/BuildingIcon.tsx +56 -0
- package/packages/ui/src/icons/icons/CalendarIcon.tsx +19 -0
- package/packages/ui/src/icons/icons/CalendarRangeIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/CardIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/CarouselIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ChartBarIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/ChartPieIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/CheckCircleIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/CheckIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ChevronDownIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ChevronLeftIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ChevronRightIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ChevronUpIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ChipIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/ClipboardIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ClockIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/CloudSyncIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/CodeIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/CommandPaletteIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/CompassIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/ContainerIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ContextMenuIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ContrastIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/CopyIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/CpuIcon.tsx +19 -0
- package/packages/ui/src/icons/icons/CropIcon.tsx +22 -0
- package/packages/ui/src/icons/icons/CubeIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/CursorClickIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/CursorIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/DashboardIcon.tsx +48 -0
- package/packages/ui/src/icons/icons/DataGridIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/DeleteIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/DeviceMobileIcon.tsx +29 -0
- package/packages/ui/src/icons/icons/DialogIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/DiskIoIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/DiskUsageIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/DonutIcon.tsx +23 -0
- package/packages/ui/src/icons/icons/DownloadIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/DrawerIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ERPIcon.tsx +18 -0
- package/packages/ui/src/icons/icons/EditIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/EmptyStateIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ErrorIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ExpandIcon.tsx +23 -0
- package/packages/ui/src/icons/icons/ExpensesIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/EyeIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/EyeOffIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/FavoriteIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/FileTextIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/FilterIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/FlexIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/FocusIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/FolderIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/FolderOpenIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/FoundationIcon.tsx +23 -0
- package/packages/ui/src/icons/icons/GlobeIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/GoalIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/GridIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/HashIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/HelpIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/HistoryIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/HomeIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/ImageIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ImagesIcon.tsx +36 -0
- package/packages/ui/src/icons/icons/InfoCircleIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ItemsIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/KeyIcon.tsx +23 -0
- package/packages/ui/src/icons/icons/KeyboardIcon.tsx +18 -0
- package/packages/ui/src/icons/icons/LayersIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/LayoutIcon.tsx +25 -0
- package/packages/ui/src/icons/icons/LinkIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ListIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/ListsIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/LiveVisitorsIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/LoadAverageIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/LoaderIcon.tsx +17 -0
- package/packages/ui/src/icons/icons/LockIcon.tsx +17 -0
- package/packages/ui/src/icons/icons/LoginIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/LogoIcon.tsx +18 -0
- package/packages/ui/src/icons/icons/LogoutIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/LogsIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/MailIcon.tsx +17 -0
- package/packages/ui/src/icons/icons/MapPinIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/MemoryIcon.tsx +18 -0
- package/packages/ui/src/icons/icons/MenuIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/MessagesIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/MinusIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ModalIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/MonitorIcon.tsx +20 -0
- package/packages/ui/src/icons/icons/MoonIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/MoreVerticalIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/MousePointerClickIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/MousePointerIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/NavbarIcon.tsx +42 -0
- package/packages/ui/src/icons/icons/NetProfitIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/NetworkIcon.tsx +44 -0
- package/packages/ui/src/icons/icons/NewOrdersIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/NotesIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/NotificationIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/NumberIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/OrdersIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/PaginationIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/PanelBottomIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/PanelLeftIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/PanelRightIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/PanelTopIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/PartnerIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/PendingUpdatesIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/PlusIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/PopoverIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/ProcessesIcon.tsx +17 -0
- package/packages/ui/src/icons/icons/PulseIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/QuestionMarkCircleIcon.tsx +29 -0
- package/packages/ui/src/icons/icons/RadioIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/RamIcon.tsx +21 -0
- package/packages/ui/src/icons/icons/RefreshIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ReminderIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/ReportsIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/RestoreIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/RevenueIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ScreenReaderIcon.tsx +19 -0
- package/packages/ui/src/icons/icons/ScrollIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/SearchIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/SendIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ServerIcon.tsx +40 -0
- package/packages/ui/src/icons/icons/ServerUsersIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/SettingsIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/ShareIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/ShieldCheckIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/ShivanyaLogoIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/SidebarIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/SmartphoneIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/SortIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/SpacerIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/SparklesIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/SquareIcon.tsx +17 -0
- package/packages/ui/src/icons/icons/StackIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/StepperIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/StocksIcon.tsx +18 -0
- package/packages/ui/src/icons/icons/SunIcon.tsx +22 -0
- package/packages/ui/src/icons/icons/SwitchIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/TableIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/TabsIcon.tsx +14 -0
- package/packages/ui/src/icons/icons/TagIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/TagsIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/TasksIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/ThemeIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/TimelineIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ToastIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/ToggleIcon.tsx +24 -0
- package/packages/ui/src/icons/icons/ToolsIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/TooltipIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/TrafficIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/TransactionsIcon.tsx +13 -0
- package/packages/ui/src/icons/icons/TreeViewIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/TrendingDownIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/TrendingUpIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/TypeIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/TypographyIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/UnlockIcon.tsx +18 -0
- package/packages/ui/src/icons/icons/UploadIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/UserCheckIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/UserIcon.tsx +11 -0
- package/packages/ui/src/icons/icons/UserMinusIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/UserPlusIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/UserXIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/UsersIcon.tsx +20 -0
- package/packages/ui/src/icons/icons/VaultIcon.tsx +16 -0
- package/packages/ui/src/icons/icons/VideoIcon.tsx +12 -0
- package/packages/ui/src/icons/icons/WalletIcon.tsx +22 -0
- package/packages/ui/src/icons/icons/WifiIcon.tsx +22 -0
- package/packages/ui/src/icons/icons/WindowIcon.tsx +15 -0
- package/packages/ui/src/icons/icons/WrenchIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/XCircleIcon.tsx +10 -0
- package/packages/ui/src/icons/icons/index.ts +193 -0
- package/packages/ui/src/icons/index.ts +1 -3
- package/packages/ui/src/index.ts +3 -0
- package/packages/ui/src/styles.d.ts +1 -0
- package/playground/README.md +0 -6
- package/playground/public/logo.png +0 -0
- package/playground/src/App.tsx +8 -0
- package/playground/src/config/component-icons.ts +573 -0
- package/playground/src/demos/shell/Components/DrawerHeaderDemo.tsx +92 -4
- package/playground/src/demos/shell/Components/PageContainerDemo.tsx +146 -4
- package/playground/src/demos/shell/Components/PageHeaderDemo.tsx +113 -5
- package/playground/src/demos/shell/Components/ShellBrandDemo.tsx +115 -6
- package/playground/src/demos/shell/Components/ShellFooterDemo.tsx +101 -4
- package/playground/src/demos/shell/Components/ShellHeaderDemo.tsx +131 -26
- package/playground/src/demos/shell/Components/ShellMainDemo.tsx +100 -5
- package/playground/src/demos/shell/Components/ShellMobileNavDemo.tsx +229 -6
- package/playground/src/demos/shell/Components/ShellRootDemo.tsx +64 -1
- package/playground/src/demos/shell/Components/ShellSidebarDemo.tsx +381 -8
- package/playground/src/demos/shell/Components/SidebarFooterDemo.tsx +107 -4
- package/playground/src/demos/shell/Layouts/AppShellDemo.tsx +136 -24
- package/playground/src/demos/shell/Layouts/BlankShellDemo.tsx +94 -4
- package/playground/src/demos/shell/Layouts/CenteredShellDemo.tsx +104 -5
- package/playground/src/demos/shell/Layouts/DashboardShellDemo.tsx +127 -35
- package/playground/src/demos/shell/Layouts/WebsiteShellDemo.tsx +182 -6
- package/playground/src/demos/shell/_demo-utils.tsx +101 -11
- package/playground/src/demos/shell/previews/AppShellPreview.tsx +44 -0
- package/playground/src/demos/shell/previews/BlankShellPreview.tsx +20 -0
- package/playground/src/demos/shell/previews/CenteredShellPreview.tsx +34 -0
- package/playground/src/demos/shell/previews/DashboardShellPreview.tsx +49 -0
- package/playground/src/demos/shell/previews/WebsiteShellPreview.tsx +104 -0
- package/playground/src/demos/shell/shell-demo.css +211 -0
- package/playground/src/demos/ui/icons/IconsDemo.tsx +28 -0
- package/playground/src/demos/ui/icons/icons-demo.css +845 -0
- package/playground/src/discovery/previewDiscovery.ts +50 -0
- package/playground/src/discovery/sdkDiscovery.ts +121 -22
- package/playground/src/index.css +96 -0
- package/playground/src/pages/CategoryPage.tsx +114 -15
- package/playground/src/pages/ComponentPage.tsx +37 -1
- package/playground/src/pages/PackagePage.tsx +125 -13
- package/pnpm-workspace.yaml +1 -1
- package/packages/shell/src/styles/shell.css +0 -559
package/package.json
CHANGED
|
@@ -1,30 +1,29 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "shivanya-sdk",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "Shivanya SDK monorepo",
|
|
5
|
-
"
|
|
6
|
-
"
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
"packageManager": "pnpm@11.9.0"
|
|
1
|
+
{
|
|
2
|
+
"name": "shivanya-sdk",
|
|
3
|
+
"version": "0.1.2",
|
|
4
|
+
"description": "Shivanya SDK monorepo",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "git+https://github.com/adityathute/shivanya-sdk.git"
|
|
8
|
+
},
|
|
9
|
+
"keywords": [
|
|
10
|
+
"shivanya",
|
|
11
|
+
"shivanya-sdk",
|
|
12
|
+
"sdk",
|
|
13
|
+
"typescript",
|
|
14
|
+
"react",
|
|
15
|
+
"react-components",
|
|
16
|
+
"frontend",
|
|
17
|
+
"ui",
|
|
18
|
+
"shell",
|
|
19
|
+
"authentication",
|
|
20
|
+
"analytics",
|
|
21
|
+
"developer-tools",
|
|
22
|
+
"open-source"
|
|
23
|
+
],
|
|
24
|
+
"author": "Aditya Thute",
|
|
25
|
+
"license": "ISC",
|
|
26
|
+
"scripts": {
|
|
27
|
+
"build": "pnpm -r build"
|
|
28
|
+
}
|
|
30
29
|
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# shivanya-ai
|
|
2
|
+
|
|
3
|
+
AI client for the Shivanya platform.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install shivanya-ai
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
import { ShivanyaAI } from "shivanya-ai";
|
|
15
|
+
import { ShivanyaClient } from "shivanya-core";
|
|
16
|
+
|
|
17
|
+
const client = new ShivanyaClient({
|
|
18
|
+
baseURL: "https://api.shivanyams.com",
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
const ai = new ShivanyaAI(client);
|
|
22
|
+
|
|
23
|
+
const response = await ai.chat({
|
|
24
|
+
message: "Hello",
|
|
25
|
+
});
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Dependency
|
|
29
|
+
|
|
30
|
+
`shivanya-ai` uses `shivanya-core` as a package dependency.
|
|
31
|
+
|
|
32
|
+
## Development
|
|
33
|
+
|
|
34
|
+
This package is developed inside the Shivanya SDK pnpm workspace.
|
|
35
|
+
|
|
36
|
+
From the SDK root:
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
pnpm install
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Build the package:
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
pnpm --filter shivanya-ai build
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
## Package Structure
|
|
49
|
+
|
|
50
|
+
```text
|
|
51
|
+
packages/ai/
|
|
52
|
+
├── src/
|
|
53
|
+
│ ├── ai.ts
|
|
54
|
+
│ ├── types.ts
|
|
55
|
+
│ └── index.ts
|
|
56
|
+
├── package.json
|
|
57
|
+
└── tsconfig.json
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Contributing
|
|
61
|
+
|
|
62
|
+
Make changes in the package source, build the package, and submit a pull request.
|
|
63
|
+
|
|
64
|
+
## License
|
|
65
|
+
|
|
66
|
+
ISC
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# shivanya-core
|
|
2
|
+
|
|
3
|
+
Core TypeScript client for the Shivanya platform.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install shivanya-core
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
import { ShivanyaClient } from "shivanya-core";
|
|
15
|
+
|
|
16
|
+
const client = new ShivanyaClient({
|
|
17
|
+
baseURL: "https://api.shivanyams.com",
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
const data = await client.request("/api/example");
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## Development
|
|
24
|
+
|
|
25
|
+
This package is developed inside the Shivanya SDK pnpm workspace.
|
|
26
|
+
|
|
27
|
+
From the SDK root:
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
pnpm install
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
Build the package:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
pnpm --filter shivanya-core build
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## Package Structure
|
|
40
|
+
|
|
41
|
+
```text
|
|
42
|
+
packages/core/
|
|
43
|
+
├── src/
|
|
44
|
+
│ ├── client.ts
|
|
45
|
+
│ ├── errors.ts
|
|
46
|
+
│ └── index.ts
|
|
47
|
+
├── package.json
|
|
48
|
+
└── tsconfig.json
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Contributing
|
|
52
|
+
|
|
53
|
+
Make changes in the package source, build the package, and submit a pull request.
|
|
54
|
+
|
|
55
|
+
## License
|
|
56
|
+
|
|
57
|
+
ISC
|
package/packages/shell/README.md
CHANGED
|
@@ -2,8 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
Reusable application shell and layout components for Shivanya applications.
|
|
4
4
|
|
|
5
|
-
The package provides common layout infrastructure that can be shared across different Shivanya applications without coupling the shell to a specific application.
|
|
6
|
-
|
|
7
5
|
## Installation
|
|
8
6
|
|
|
9
7
|
```bash
|
|
@@ -13,33 +11,22 @@ npm install shivanya-shell
|
|
|
13
11
|
## Usage
|
|
14
12
|
|
|
15
13
|
```tsx
|
|
16
|
-
import {
|
|
17
|
-
AppShell,
|
|
18
|
-
PageContainer,
|
|
19
|
-
} from "shivanya-shell";
|
|
14
|
+
import { DashboardShell } from "shivanya-shell";
|
|
20
15
|
|
|
21
16
|
export function App() {
|
|
22
17
|
return (
|
|
23
|
-
<
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
</PageContainer>
|
|
27
|
-
</AppShell>
|
|
18
|
+
<DashboardShell>
|
|
19
|
+
Your application content
|
|
20
|
+
</DashboardShell>
|
|
28
21
|
);
|
|
29
22
|
}
|
|
30
23
|
```
|
|
31
24
|
|
|
32
|
-
##
|
|
33
|
-
|
|
34
|
-
Current components:
|
|
25
|
+
## Dependency
|
|
35
26
|
|
|
36
|
-
- `
|
|
37
|
-
- `PageContainer`
|
|
38
|
-
- `LayoutProvider`
|
|
39
|
-
- `LayoutContext`
|
|
40
|
-
- `useLayout`
|
|
27
|
+
`shivanya-shell` uses `shivanya-ui` as a package dependency.
|
|
41
28
|
|
|
42
|
-
|
|
29
|
+
React and React DOM are peer dependencies.
|
|
43
30
|
|
|
44
31
|
## Development
|
|
45
32
|
|
|
@@ -63,23 +50,12 @@ Test changes using the SDK playground:
|
|
|
63
50
|
pnpm --filter playground dev
|
|
64
51
|
```
|
|
65
52
|
|
|
66
|
-
## Dependencies
|
|
67
|
-
|
|
68
|
-
`shivanya-shell` uses:
|
|
69
|
-
|
|
70
|
-
```text
|
|
71
|
-
shivanya-ui
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
as a package dependency.
|
|
75
|
-
|
|
76
|
-
React and React DOM are peer dependencies.
|
|
77
|
-
|
|
78
53
|
## Package Structure
|
|
79
54
|
|
|
80
55
|
```text
|
|
81
56
|
packages/shell/
|
|
82
57
|
├── src/
|
|
58
|
+
│ ├── components/
|
|
83
59
|
│ ├── context/
|
|
84
60
|
│ ├── hooks/
|
|
85
61
|
│ ├── layouts/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "shivanya-shell",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.5",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Reusable React shell, layout, and application structure components for Shivanya applications",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -10,17 +10,16 @@
|
|
|
10
10
|
"types": "./dist/index.d.ts",
|
|
11
11
|
"import": "./dist/index.js"
|
|
12
12
|
},
|
|
13
|
-
"./styles": "./
|
|
13
|
+
"./styles": "./dist/styles/shell.css"
|
|
14
14
|
},
|
|
15
15
|
"files": [
|
|
16
|
-
"dist"
|
|
17
|
-
"src/styles"
|
|
16
|
+
"dist"
|
|
18
17
|
],
|
|
19
18
|
"scripts": {
|
|
20
|
-
"build": "tsc &&
|
|
19
|
+
"build": "tsc && node scripts/copy-assets.mjs"
|
|
21
20
|
},
|
|
22
21
|
"dependencies": {
|
|
23
|
-
"shivanya-ui": "^1.0.
|
|
22
|
+
"shivanya-ui": "^1.0.6"
|
|
24
23
|
},
|
|
25
24
|
"peerDependencies": {
|
|
26
25
|
"react": "^18.0.0 || ^19.0.0",
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import fs from "node:fs";
|
|
2
|
+
import path from "node:path";
|
|
3
|
+
import { fileURLToPath } from "node:url";
|
|
4
|
+
|
|
5
|
+
const currentFile = fileURLToPath(import.meta.url);
|
|
6
|
+
const root = path.resolve(path.dirname(currentFile), "..");
|
|
7
|
+
|
|
8
|
+
const source = path.join(root, "src", "styles");
|
|
9
|
+
const target = path.join(root, "dist", "styles");
|
|
10
|
+
|
|
11
|
+
fs.mkdirSync(target, { recursive: true });
|
|
12
|
+
|
|
13
|
+
for (const file of fs.readdirSync(source)) {
|
|
14
|
+
if (!file.endsWith(".css")) {
|
|
15
|
+
continue;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
fs.copyFileSync(
|
|
19
|
+
path.join(source, file),
|
|
20
|
+
path.join(target, file),
|
|
21
|
+
);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
console.log("Shivanya Shell CSS and assets copied.");
|
|
@@ -1,19 +1,44 @@
|
|
|
1
|
+
import {
|
|
2
|
+
CloseIcon,
|
|
3
|
+
IconButton,
|
|
4
|
+
} from "shivanya-ui";
|
|
5
|
+
|
|
1
6
|
import type { ShellBranding } from "../types/shell.js";
|
|
2
7
|
import { ShellBrand } from "./ShellBrand.js";
|
|
3
8
|
|
|
9
|
+
export interface DrawerHeaderProps {
|
|
10
|
+
branding?: ShellBranding;
|
|
11
|
+
onClose?: () => void;
|
|
12
|
+
}
|
|
13
|
+
|
|
4
14
|
export function DrawerHeader({
|
|
5
15
|
branding,
|
|
6
16
|
onClose,
|
|
7
|
-
}: {
|
|
8
|
-
branding?: ShellBranding;
|
|
9
|
-
onClose?: () => void;
|
|
10
|
-
}) {
|
|
17
|
+
}: DrawerHeaderProps) {
|
|
11
18
|
return (
|
|
12
19
|
<header className="shivanya-shell-drawer-header">
|
|
13
|
-
{branding &&
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
20
|
+
{branding && (
|
|
21
|
+
<ShellBrand
|
|
22
|
+
branding={{
|
|
23
|
+
...branding,
|
|
24
|
+
href: undefined,
|
|
25
|
+
}}
|
|
26
|
+
compact={false}
|
|
27
|
+
/>
|
|
28
|
+
)}
|
|
29
|
+
|
|
30
|
+
<IconButton
|
|
31
|
+
size="sm"
|
|
32
|
+
variant="ghost"
|
|
33
|
+
rounded
|
|
34
|
+
iconRotateOnHover
|
|
35
|
+
iconHoverColor="var(--shivanya-color-primary)"
|
|
36
|
+
aria-label="Close menu"
|
|
37
|
+
title="Close menu"
|
|
38
|
+
onClick={onClose}
|
|
39
|
+
>
|
|
40
|
+
<CloseIcon size="sm" />
|
|
41
|
+
</IconButton>
|
|
17
42
|
</header>
|
|
18
43
|
);
|
|
19
|
-
}
|
|
44
|
+
}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import type { ShellBranding } from "../types/shell.js";
|
|
2
2
|
|
|
3
|
+
interface ShellBrandProps {
|
|
4
|
+
branding: ShellBranding;
|
|
5
|
+
compact?: boolean;
|
|
6
|
+
}
|
|
7
|
+
|
|
3
8
|
export function ShellBrand({
|
|
4
9
|
branding,
|
|
5
10
|
compact = false,
|
|
6
|
-
}: {
|
|
7
|
-
branding: ShellBranding;
|
|
8
|
-
compact?: boolean;
|
|
9
|
-
}) {
|
|
11
|
+
}: ShellBrandProps) {
|
|
10
12
|
const content = (
|
|
11
13
|
<span className="shivanya-shell-brand-content">
|
|
12
14
|
{branding.src ? (
|
|
@@ -16,17 +18,21 @@ export function ShellBrand({
|
|
|
16
18
|
className="shivanya-shell-brand-image"
|
|
17
19
|
/>
|
|
18
20
|
) : null}
|
|
21
|
+
|
|
19
22
|
<span className="shivanya-shell-brand-text">
|
|
20
23
|
{branding.name && <strong>{branding.name}</strong>}
|
|
21
24
|
{!compact && branding.subtitle && <small>{branding.subtitle}</small>}
|
|
22
25
|
</span>
|
|
23
26
|
</span>
|
|
24
27
|
);
|
|
25
|
-
|
|
28
|
+
|
|
29
|
+
if (branding.href) {
|
|
26
30
|
return (
|
|
27
31
|
<a className="shivanya-shell-brand" href={branding.href}>
|
|
28
32
|
{content}
|
|
29
33
|
</a>
|
|
30
34
|
);
|
|
35
|
+
}
|
|
36
|
+
|
|
31
37
|
return <span className="shivanya-shell-brand">{content}</span>;
|
|
32
|
-
}
|
|
38
|
+
}
|
|
@@ -7,12 +7,25 @@ export function ShellFooter({
|
|
|
7
7
|
className = "",
|
|
8
8
|
}: ShellFooterProps) {
|
|
9
9
|
return (
|
|
10
|
-
<footer
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
<footer
|
|
11
|
+
className={[
|
|
12
|
+
"shivanya-shell-footer",
|
|
13
|
+
className,
|
|
14
|
+
]
|
|
15
|
+
.filter(Boolean)
|
|
16
|
+
.join(" ")}
|
|
17
|
+
>
|
|
18
|
+
<div className="shivanya-shell-footer-brand">
|
|
19
|
+
{branding && <ShellBrand branding={branding} />}
|
|
20
|
+
</div>
|
|
21
|
+
|
|
22
|
+
<div className="shivanya-shell-footer-content">
|
|
23
|
+
{children}
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
<div className="shivanya-shell-footer-copy">
|
|
14
27
|
© {new Date().getFullYear()}
|
|
15
|
-
</
|
|
28
|
+
</div>
|
|
16
29
|
</footer>
|
|
17
30
|
);
|
|
18
|
-
}
|
|
31
|
+
}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
1
3
|
import type { CSSProperties } from "react";
|
|
2
4
|
import type { ShellHeaderProps } from "../types/shell.js";
|
|
5
|
+
import { Button } from "shivanya-ui";
|
|
3
6
|
import { useShell } from "../hooks/useShell.js";
|
|
4
7
|
import { ShellBrand } from "./ShellBrand.js";
|
|
5
8
|
|
|
@@ -17,63 +20,45 @@ export function ShellHeader({
|
|
|
17
20
|
}: ShellHeaderProps) {
|
|
18
21
|
const shell = useShell();
|
|
19
22
|
|
|
20
|
-
const menuAction = () => {
|
|
21
|
-
if (
|
|
22
|
-
typeof window !== "undefined" &&
|
|
23
|
-
window.matchMedia("(max-width: 767px)").matches
|
|
24
|
-
) {
|
|
25
|
-
shell.toggleMobile();
|
|
26
|
-
} else {
|
|
27
|
-
shell.toggleSidebar();
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
|
|
31
23
|
return (
|
|
32
24
|
<header
|
|
33
25
|
className={`shivanya-shell-header shivanya-shell-header-${position} ${className}`.trim()}
|
|
34
26
|
style={
|
|
35
27
|
{
|
|
36
28
|
"--shivanya-shell-header-height":
|
|
37
|
-
typeof height === "number"
|
|
38
|
-
? `${height}px`
|
|
39
|
-
: height,
|
|
29
|
+
typeof height === "number" ? `${height}px` : height,
|
|
40
30
|
} as CSSProperties
|
|
41
31
|
}
|
|
42
32
|
>
|
|
43
33
|
<div className="shivanya-shell-header-inner">
|
|
44
34
|
<div className="shivanya-shell-header-start">
|
|
45
35
|
{showMenu && (
|
|
46
|
-
<
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
36
|
+
<div className="shivanya-shell-mobile-menu">
|
|
37
|
+
<Button
|
|
38
|
+
type="button"
|
|
39
|
+
variant="ghost"
|
|
40
|
+
size="sm"
|
|
41
|
+
rounded
|
|
42
|
+
onClick={shell.toggleMobile}
|
|
43
|
+
aria-label={menuLabel}
|
|
44
|
+
title={menuLabel}
|
|
45
|
+
>
|
|
46
|
+
☰
|
|
47
|
+
</Button>
|
|
48
|
+
</div>
|
|
55
49
|
)}
|
|
56
50
|
|
|
57
|
-
{
|
|
51
|
+
{branding && <ShellBrand branding={branding} compact={false} />}
|
|
58
52
|
|
|
59
|
-
{
|
|
60
|
-
<ShellBrand
|
|
61
|
-
branding={branding}
|
|
62
|
-
compact={shell.sidebarCollapsed}
|
|
63
|
-
/>
|
|
64
|
-
)}
|
|
53
|
+
{start}
|
|
65
54
|
</div>
|
|
66
55
|
|
|
67
|
-
<div className="shivanya-shell-header-center">
|
|
68
|
-
{center}
|
|
69
|
-
</div>
|
|
56
|
+
<div className="shivanya-shell-header-center">{center}</div>
|
|
70
57
|
|
|
71
|
-
<div className="shivanya-shell-header-end">
|
|
72
|
-
{end}
|
|
73
|
-
</div>
|
|
58
|
+
<div className="shivanya-shell-header-end">{end}</div>
|
|
74
59
|
</div>
|
|
75
60
|
|
|
76
61
|
{children}
|
|
77
62
|
</header>
|
|
78
63
|
);
|
|
79
|
-
}
|
|
64
|
+
}
|