flarecms 0.2.1 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/lib/cache.d.ts +18 -0
- package/dist/api/lib/response.d.ts +44 -0
- package/dist/api/middlewares/auth.d.ts +10 -0
- package/dist/api/middlewares/cors.d.ts +1 -0
- package/dist/api/middlewares/rbac.d.ts +21 -0
- package/dist/api/routes/auth.d.ts +6 -0
- package/dist/api/routes/collections.d.ts +6 -0
- package/dist/api/routes/content.d.ts +6 -0
- package/dist/api/routes/device.d.ts +6 -0
- package/dist/api/routes/magic.d.ts +6 -0
- package/dist/api/routes/mcp.d.ts +6 -0
- package/dist/api/routes/oauth.d.ts +6 -0
- package/dist/api/routes/plugins.d.ts +6 -0
- package/dist/api/routes/settings.d.ts +6 -0
- package/dist/api/routes/setup.d.ts +6 -0
- package/dist/api/routes/tokens.d.ts +6 -0
- package/dist/api/schemas/auth.d.ts +12 -0
- package/dist/api/schemas/index.d.ts +43 -0
- package/dist/api/schemas/tokens.d.ts +20 -0
- package/dist/auth/index.d.ts +11 -0
- package/dist/cli/commands.d.ts +3 -0
- package/dist/cli/commands.js +50 -28
- package/dist/cli/index.d.ts +2 -0
- package/dist/cli/index.js +50 -28
- package/dist/cli/mcp.d.ts +9 -0
- package/dist/cli/tests/cli.test.d.ts +1 -0
- package/dist/cli/tests/create-plugin-template.test.d.ts +1 -0
- package/dist/cli/tests/create.test.d.ts +1 -0
- package/dist/cli/tests/plugin.test.d.ts +1 -0
- package/dist/cli/tests/publish.test.d.ts +1 -0
- package/dist/client/FlareAdminRouter.d.ts +20 -0
- package/dist/client/app.d.ts +1 -0
- package/dist/client/components/app-sidebar.d.ts +5 -0
- package/dist/client/components/blocks/block-card.d.ts +7 -0
- package/dist/client/components/blocks/block-form.d.ts +7 -0
- package/dist/client/components/blocks/block-renderer.d.ts +10 -0
- package/dist/client/components/blocks/block-table.d.ts +7 -0
- package/dist/client/components/collection-modal.d.ts +6 -0
- package/dist/client/components/content-list.d.ts +3 -0
- package/dist/client/components/dynamic-form.d.ts +9 -0
- package/dist/client/components/field-modal.d.ts +8 -0
- package/dist/client/components/plugin-widget.d.ts +6 -0
- package/dist/client/components/settings/api-token-section.d.ts +1 -0
- package/dist/client/components/settings/general-section.d.ts +1 -0
- package/dist/client/components/settings/security-section.d.ts +1 -0
- package/dist/client/components/settings/seo-section.d.ts +1 -0
- package/dist/client/components/settings/signup-section.d.ts +1 -0
- package/dist/client/components/ui/accordion.d.ts +6 -0
- package/dist/client/components/ui/avatar.d.ts +11 -0
- package/dist/client/components/ui/badge.d.ts +7 -0
- package/dist/client/components/ui/button.d.ts +11 -0
- package/dist/client/components/ui/card.d.ts +11 -0
- package/dist/client/components/ui/checkbox.d.ts +3 -0
- package/dist/client/components/ui/collapsible.d.ts +5 -0
- package/dist/client/components/ui/dialog.d.ts +17 -0
- package/dist/client/components/ui/icon-picker.d.ts +27 -0
- package/dist/client/components/ui/icons-data.d.ts +5 -0
- package/dist/client/components/ui/input.d.ts +3 -0
- package/dist/client/components/ui/label.d.ts +3 -0
- package/dist/client/components/ui/popover.d.ts +10 -0
- package/dist/client/components/ui/select.d.ts +15 -0
- package/dist/client/components/ui/separator.d.ts +3 -0
- package/dist/client/components/ui/sheet.d.ts +14 -0
- package/dist/client/components/ui/sidebar.d.ts +63 -0
- package/dist/client/components/ui/skeleton.d.ts +2 -0
- package/dist/client/components/ui/sonner.d.ts +3 -0
- package/dist/client/components/ui/switch.d.ts +5 -0
- package/dist/client/components/ui/table.d.ts +10 -0
- package/dist/client/components/ui/tabs.d.ts +10 -0
- package/dist/client/components/ui/textarea.d.ts +3 -0
- package/dist/client/components/ui/tooltip.d.ts +6 -0
- package/dist/client/hooks/use-mobile.d.ts +1 -0
- package/dist/client/index.d.ts +8 -0
- package/dist/client/layouts/admin-layout.d.ts +6 -0
- package/dist/client/layouts/settings-layout.d.ts +6 -0
- package/dist/client/lib/api.d.ts +18 -0
- package/dist/client/lib/block-registry.d.ts +24 -0
- package/dist/client/lib/block-types.d.ts +132 -0
- package/dist/client/lib/utils.d.ts +2 -0
- package/dist/client/main.d.ts +1 -0
- package/dist/client/pages/collection-detail.d.ts +7 -0
- package/dist/client/pages/collections.d.ts +1 -0
- package/dist/client/pages/dashboard.d.ts +1 -0
- package/dist/client/pages/device.d.ts +1 -0
- package/dist/client/pages/document-detail-page.d.ts +1 -0
- package/dist/client/pages/documents-page.d.ts +1 -0
- package/dist/client/pages/login.d.ts +1 -0
- package/dist/client/pages/plugin-manager.d.ts +1 -0
- package/dist/client/pages/plugin-page.d.ts +6 -0
- package/dist/client/pages/settings.d.ts +1 -0
- package/dist/client/pages/setup.d.ts +1 -0
- package/dist/client/pages/signup.d.ts +1 -0
- package/dist/client/store/auth.d.ts +10 -0
- package/dist/client/store/collections.d.ts +3 -0
- package/dist/client/store/config.d.ts +4 -0
- package/dist/client/store/fetcher.d.ts +4 -0
- package/dist/client/store/plugins.d.ts +21 -0
- package/dist/client/store/router.d.ts +84 -0
- package/dist/client/store/schema.d.ts +7 -0
- package/dist/client/store/settings.d.ts +7 -0
- package/dist/client/types.d.ts +31 -0
- package/dist/db/dynamic.d.ts +5 -0
- package/dist/db/index.d.ts +8 -0
- package/dist/db/migrations/001_initial_schema.d.ts +3 -0
- package/dist/db/migrations/002_auth_tables.d.ts +3 -0
- package/dist/db/migrations/003_plugins.d.ts +3 -0
- package/dist/db/migrator.d.ts +10 -0
- package/dist/db/schema.d.ts +151 -0
- package/dist/index.d.ts +11 -0
- package/dist/plugins/adapt-entry.d.ts +5 -0
- package/dist/plugins/context.d.ts +21 -0
- package/dist/plugins/define-plugin.d.ts +22 -0
- package/dist/plugins/hooks.d.ts +37 -0
- package/dist/plugins/index.d.ts +7 -0
- package/dist/plugins/manager.d.ts +41 -0
- package/dist/plugins/middleware.d.ts +8 -0
- package/dist/plugins/noop-sandbox.d.ts +18 -0
- package/dist/plugins/routes.d.ts +32 -0
- package/dist/plugins/sandbox/bridge.d.ts +45 -0
- package/dist/plugins/sandbox/runner.d.ts +14 -0
- package/dist/plugins/sandbox/types.d.ts +71 -0
- package/dist/plugins/sandbox/wrapper.d.ts +6 -0
- package/dist/plugins/types.d.ts +725 -0
- package/dist/server/index.d.ts +18 -0
- package/dist/types.d.ts +19 -0
- package/package.json +34 -10
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SecuritySection(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SEOSection(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SignupSection(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Accordion as AccordionPrimitive } from '@base-ui/react/accordion';
|
|
2
|
+
declare function Accordion({ className, ...props }: AccordionPrimitive.Root.Props): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare function AccordionItem({ className, ...props }: AccordionPrimitive.Item.Props): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function AccordionTrigger({ className, children, ...props }: AccordionPrimitive.Trigger.Props): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function AccordionContent({ className, children, ...props }: AccordionPrimitive.Panel.Props): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export { Accordion, AccordionItem, AccordionTrigger, AccordionContent };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Avatar as AvatarPrimitive } from "@base-ui/react/avatar";
|
|
3
|
+
declare const Avatar: React.ForwardRefExoticComponent<Omit<import("@base-ui/react").AvatarRootProps & {
|
|
4
|
+
size?: "default" | "sm" | "lg";
|
|
5
|
+
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
declare function AvatarImage({ className, ...props }: AvatarPrimitive.Image.Props): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function AvatarFallback({ className, ...props }: AvatarPrimitive.Fallback.Props): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function AvatarBadge({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function AvatarGroup({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function AvatarGroupCount({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export { Avatar, AvatarImage, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarBadge, };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
2
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
3
|
+
declare const badgeVariants: (props?: ({
|
|
4
|
+
variant?: "default" | "link" | "outline" | "secondary" | "ghost" | "destructive" | null | undefined;
|
|
5
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
6
|
+
declare function Badge({ className, variant, render, ...props }: useRender.ComponentProps<'span'> & VariantProps<typeof badgeVariants>): import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
|
|
7
|
+
export { Badge, badgeVariants };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
3
|
+
declare const buttonVariants: (props?: ({
|
|
4
|
+
variant?: "default" | "link" | "outline" | "secondary" | "ghost" | "destructive" | null | undefined;
|
|
5
|
+
size?: "default" | "icon" | "xs" | "sm" | "lg" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
declare const Button: React.ForwardRefExoticComponent<Omit<import("@base-ui/react").ButtonProps & VariantProps<(props?: ({
|
|
8
|
+
variant?: "default" | "link" | "outline" | "secondary" | "ghost" | "destructive" | null | undefined;
|
|
9
|
+
size?: "default" | "icon" | "xs" | "sm" | "lg" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
10
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
11
|
+
export { Button, buttonVariants };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare function Card({ className, size, ...props }: React.ComponentProps<"div"> & {
|
|
3
|
+
size?: "default" | "sm";
|
|
4
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function CardHeader({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function CardTitle({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function CardDescription({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function CardAction({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function CardContent({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function CardFooter({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export { Card, CardHeader, CardFooter, CardTitle, CardAction, CardDescription, CardContent, };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Collapsible as CollapsiblePrimitive } from "@base-ui/react/collapsible";
|
|
2
|
+
declare function Collapsible({ ...props }: CollapsiblePrimitive.Root.Props): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare function CollapsibleTrigger({ ...props }: CollapsiblePrimitive.Trigger.Props): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function CollapsibleContent({ ...props }: CollapsiblePrimitive.Panel.Props): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export { Collapsible, CollapsibleTrigger, CollapsibleContent };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Dialog as DialogPrimitive } from "@base-ui/react/dialog";
|
|
3
|
+
declare function Dialog({ ...props }: DialogPrimitive.Root.Props): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function DialogTrigger({ ...props }: DialogPrimitive.Trigger.Props): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function DialogPortal({ children, ...props }: DialogPrimitive.Portal.Props): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function DialogClose({ ...props }: DialogPrimitive.Close.Props): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function DialogOverlay({ className, ...props }: DialogPrimitive.Backdrop.Props): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function DialogContent({ className, children, showCloseButton, ...props }: DialogPrimitive.Popup.Props & {
|
|
9
|
+
showCloseButton?: boolean;
|
|
10
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
declare function DialogHeader({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
declare function DialogFooter({ className, showCloseButton, children, ...props }: React.ComponentProps<"div"> & {
|
|
13
|
+
showCloseButton?: boolean;
|
|
14
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
declare function DialogTitle({ className, ...props }: DialogPrimitive.Title.Props): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
declare function DialogDescription({ className, ...props }: DialogPrimitive.Description.Props): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { PopoverTrigger } from './popover';
|
|
3
|
+
import type { LucideProps } from 'lucide-react';
|
|
4
|
+
import { type IconName } from 'lucide-react/dynamic';
|
|
5
|
+
import { iconsData } from './icons-data';
|
|
6
|
+
export type IconData = (typeof iconsData)[number];
|
|
7
|
+
interface IconPickerProps extends Omit<React.ComponentPropsWithoutRef<typeof PopoverTrigger>, 'onSelect' | 'onOpenChange'> {
|
|
8
|
+
value?: IconName;
|
|
9
|
+
defaultValue?: IconName;
|
|
10
|
+
onValueChange?: (value: IconName) => void;
|
|
11
|
+
open?: boolean;
|
|
12
|
+
defaultOpen?: boolean;
|
|
13
|
+
onOpenChange?: (open: boolean) => void;
|
|
14
|
+
searchable?: boolean;
|
|
15
|
+
searchPlaceholder?: string;
|
|
16
|
+
triggerPlaceholder?: string;
|
|
17
|
+
iconsList?: IconData[];
|
|
18
|
+
categorized?: boolean;
|
|
19
|
+
modal?: boolean;
|
|
20
|
+
children?: React.ReactNode;
|
|
21
|
+
}
|
|
22
|
+
declare const IconPicker: React.ForwardRefExoticComponent<IconPickerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
23
|
+
interface IconProps extends Omit<LucideProps, 'ref'> {
|
|
24
|
+
name: IconName;
|
|
25
|
+
}
|
|
26
|
+
declare const Icon: React.ForwardRefExoticComponent<IconProps & React.RefAttributes<SVGSVGElement>>;
|
|
27
|
+
export { IconPicker, Icon, type IconName };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Popover as PopoverPrimitive } from '@base-ui/react/popover';
|
|
3
|
+
declare function Popover({ ...props }: React.PropsWithChildren<PopoverPrimitive.Root.Props>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare const PopoverTrigger: React.ForwardRefExoticComponent<Omit<React.PropsWithChildren<PopoverPrimitive.Trigger.Props<unknown>>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
+
declare function PopoverContent({ className, align, side, sideOffset, alignOffset, ...props }: React.PropsWithChildren<PopoverPrimitive.Popup.Props & Pick<PopoverPrimitive.Positioner.Props, 'align' | 'alignOffset' | 'side' | 'sideOffset'>>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function PopoverAnchor({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function PopoverHeader({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function PopoverTitle({ className, ...props }: PopoverPrimitive.Title.Props): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function PopoverDescription({ className, ...props }: PopoverPrimitive.Description.Props): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export { Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Select as SelectPrimitive } from '@base-ui/react/select';
|
|
3
|
+
declare const Select: typeof SelectPrimitive.Root;
|
|
4
|
+
declare function SelectGroup({ className, ...props }: SelectPrimitive.Group.Props): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function SelectValue({ className, ...props }: SelectPrimitive.Value.Props): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function SelectTrigger({ className, size, children, ...props }: SelectPrimitive.Trigger.Props & {
|
|
7
|
+
size?: 'sm' | 'default';
|
|
8
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function SelectContent({ className, children, side, sideOffset, align, alignOffset, alignItemWithTrigger, ...props }: SelectPrimitive.Popup.Props & Pick<SelectPrimitive.Positioner.Props, 'align' | 'alignOffset' | 'side' | 'sideOffset' | 'alignItemWithTrigger'>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function SelectLabel({ className, ...props }: SelectPrimitive.GroupLabel.Props): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
declare function SelectItem({ className, children, ...props }: SelectPrimitive.Item.Props): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
declare function SelectSeparator({ className, ...props }: SelectPrimitive.Separator.Props): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
declare function SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpArrow>): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
declare function SelectScrollDownButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollDownArrow>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export { Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Dialog as SheetPrimitive } from '@base-ui/react/dialog';
|
|
3
|
+
declare function Sheet({ ...props }: SheetPrimitive.Root.Props): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function SheetTrigger({ ...props }: SheetPrimitive.Trigger.Props): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function SheetClose({ ...props }: SheetPrimitive.Close.Props): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function SheetContent({ className, children, side, showCloseButton, ...props }: SheetPrimitive.Popup.Props & {
|
|
7
|
+
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
8
|
+
showCloseButton?: boolean;
|
|
9
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function SheetHeader({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
declare function SheetFooter({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
declare function SheetTitle({ className, ...props }: SheetPrimitive.Title.Props): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
declare function SheetDescription({ className, ...props }: SheetPrimitive.Description.Props): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export { Sheet, SheetTrigger, SheetClose, SheetContent, SheetHeader, SheetFooter, SheetTitle, SheetDescription, };
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { useRender } from "@base-ui/react/use-render";
|
|
3
|
+
import { type VariantProps } from "class-variance-authority";
|
|
4
|
+
import { Button } from "./button";
|
|
5
|
+
import { Input } from "./input";
|
|
6
|
+
import { Separator } from "./separator";
|
|
7
|
+
import { TooltipContent } from "./tooltip";
|
|
8
|
+
type SidebarContextProps = {
|
|
9
|
+
state: "expanded" | "collapsed";
|
|
10
|
+
open: boolean;
|
|
11
|
+
setOpen: (open: boolean) => void;
|
|
12
|
+
openMobile: boolean;
|
|
13
|
+
setOpenMobile: (open: boolean) => void;
|
|
14
|
+
isMobile: boolean;
|
|
15
|
+
toggleSidebar: () => void;
|
|
16
|
+
};
|
|
17
|
+
declare function useSidebar(): SidebarContextProps;
|
|
18
|
+
declare function SidebarProvider({ defaultOpen, open: openProp, onOpenChange: setOpenProp, className, style, children, ...props }: React.ComponentProps<"div"> & {
|
|
19
|
+
defaultOpen?: boolean;
|
|
20
|
+
open?: boolean;
|
|
21
|
+
onOpenChange?: (open: boolean) => void;
|
|
22
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
declare function Sidebar({ side, variant, collapsible, className, children, dir, ...props }: React.ComponentProps<"div"> & {
|
|
24
|
+
side?: "left" | "right";
|
|
25
|
+
variant?: "sidebar" | "floating" | "inset";
|
|
26
|
+
collapsible?: "offcanvas" | "icon" | "none";
|
|
27
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
declare function SidebarTrigger({ className, onClick, ...props }: React.ComponentProps<typeof Button>): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
declare function SidebarRail({ className, ...props }: React.ComponentProps<"button">): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
declare function SidebarInset({ className, ...props }: React.ComponentProps<"main">): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
declare function SidebarInput({ className, ...props }: React.ComponentProps<typeof Input>): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
declare function SidebarHeader({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
33
|
+
declare function SidebarFooter({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
34
|
+
declare function SidebarSeparator({ className, ...props }: React.ComponentProps<typeof Separator>): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
declare function SidebarContent({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
36
|
+
declare function SidebarGroup({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
37
|
+
declare function SidebarGroupLabel({ className, render, ...props }: useRender.ComponentProps<"div"> & React.ComponentProps<"div">): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
38
|
+
declare function SidebarGroupAction({ className, render, ...props }: useRender.ComponentProps<"button"> & React.ComponentProps<"button">): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
39
|
+
declare function SidebarGroupContent({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
declare function SidebarMenu({ className, ...props }: React.ComponentProps<"ul">): import("react/jsx-runtime").JSX.Element;
|
|
41
|
+
declare function SidebarMenuItem({ className, ...props }: React.ComponentProps<"li">): import("react/jsx-runtime").JSX.Element;
|
|
42
|
+
declare const sidebarMenuButtonVariants: (props?: ({
|
|
43
|
+
variant?: "default" | "outline" | null | undefined;
|
|
44
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
45
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
46
|
+
declare function SidebarMenuButton({ render, isActive, variant, size, tooltip, className, ...props }: useRender.ComponentProps<"button"> & React.ComponentProps<"button"> & {
|
|
47
|
+
isActive?: boolean;
|
|
48
|
+
tooltip?: string | React.ComponentProps<typeof TooltipContent>;
|
|
49
|
+
} & VariantProps<typeof sidebarMenuButtonVariants>): import("react/jsx-runtime").JSX.Element;
|
|
50
|
+
declare function SidebarMenuAction({ className, render, showOnHover, ...props }: useRender.ComponentProps<"button"> & React.ComponentProps<"button"> & {
|
|
51
|
+
showOnHover?: boolean;
|
|
52
|
+
}): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
53
|
+
declare function SidebarMenuBadge({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
54
|
+
declare function SidebarMenuSkeleton({ className, showIcon, ...props }: React.ComponentProps<"div"> & {
|
|
55
|
+
showIcon?: boolean;
|
|
56
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
57
|
+
declare function SidebarMenuSub({ className, ...props }: React.ComponentProps<"ul">): import("react/jsx-runtime").JSX.Element;
|
|
58
|
+
declare function SidebarMenuSubItem({ className, ...props }: React.ComponentProps<"li">): import("react/jsx-runtime").JSX.Element;
|
|
59
|
+
declare function SidebarMenuSubButton({ render, size, isActive, className, ...props }: useRender.ComponentProps<"a"> & React.ComponentProps<"a"> & {
|
|
60
|
+
size?: "sm" | "md";
|
|
61
|
+
isActive?: boolean;
|
|
62
|
+
}): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
63
|
+
export { Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, useSidebar, };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare function Table({ className, ...props }: React.ComponentProps<"table">): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare function TableHeader({ className, ...props }: React.ComponentProps<"thead">): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function TableBody({ className, ...props }: React.ComponentProps<"tbody">): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function TableFooter({ className, ...props }: React.ComponentProps<"tfoot">): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function TableRow({ className, ...props }: React.ComponentProps<"tr">): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function TableHead({ className, ...props }: React.ComponentProps<"th">): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function TableCell({ className, ...props }: React.ComponentProps<"td">): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function TableCaption({ className, ...props }: React.ComponentProps<"caption">): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption, };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Tabs as TabsPrimitive } from "@base-ui/react/tabs";
|
|
2
|
+
import { type VariantProps } from "class-variance-authority";
|
|
3
|
+
declare function Tabs({ className, orientation, ...props }: TabsPrimitive.Root.Props): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare const tabsListVariants: (props?: ({
|
|
5
|
+
variant?: "default" | "line" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
declare function TabsList({ className, variant, ...props }: TabsPrimitive.List.Props & VariantProps<typeof tabsListVariants>): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function TabsTrigger({ className, ...props }: TabsPrimitive.Tab.Props): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function TabsContent({ className, ...props }: TabsPrimitive.Panel.Props): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export { Tabs, TabsList, TabsTrigger, TabsContent, tabsListVariants };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Tooltip as TooltipPrimitive } from "@base-ui/react/tooltip";
|
|
2
|
+
declare function TooltipProvider({ delay, ...props }: TooltipPrimitive.Provider.Props): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare function Tooltip({ ...props }: TooltipPrimitive.Root.Props): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function TooltipTrigger({ ...props }: TooltipPrimitive.Trigger.Props): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function TooltipContent({ className, side, sideOffset, align, alignOffset, children, ...props }: TooltipPrimitive.Popup.Props & Pick<TooltipPrimitive.Positioner.Props, "align" | "alignOffset" | "side" | "sideOffset">): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function useIsMobile(): boolean;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from './FlareAdminRouter';
|
|
2
|
+
export { default as FlareAdminApp } from './app';
|
|
3
|
+
export * from './store/auth';
|
|
4
|
+
export * from './store/collections';
|
|
5
|
+
export * from './store/router';
|
|
6
|
+
export * from './lib/api';
|
|
7
|
+
export * from './lib/block-registry';
|
|
8
|
+
export * from './lib/utils';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export declare function SettingsSidebar(): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare function SettingsLayout({ children, title, subtitle, }: {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
title: string;
|
|
5
|
+
subtitle: string;
|
|
6
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Core API instance pre-configured with:
|
|
3
|
+
* 1. Automatic Bearer Token injection via beforeRequest hook
|
|
4
|
+
* 2. Automatic Zero-Config redirect via afterResponse hook
|
|
5
|
+
* 3. Standard error handling for non-2xx responses (built-in ky behavior)
|
|
6
|
+
*/
|
|
7
|
+
export declare const api: import("ky").KyInstance;
|
|
8
|
+
/**
|
|
9
|
+
* A legacy wrapper for components still expecting a standard Response object from apiFetch.
|
|
10
|
+
* Uses the ky 'api' instance under the hood.
|
|
11
|
+
*
|
|
12
|
+
* @deprecated Use the 'api' instance directly (e.g., api.get().json()) for new code.
|
|
13
|
+
*/
|
|
14
|
+
export declare function apiFetch(path: string, options?: RequestInit): Promise<any>;
|
|
15
|
+
/**
|
|
16
|
+
* Sends a Block Kit interaction to a plugin's admin handler.
|
|
17
|
+
*/
|
|
18
|
+
export declare function sendPluginInteraction(pluginId: string, interaction: any): Promise<unknown>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Registry for custom plugin blocks.
|
|
4
|
+
*
|
|
5
|
+
* Plugins can register React components here to be rendered by the
|
|
6
|
+
* host application when the backend returns a 'custom' block.
|
|
7
|
+
*/
|
|
8
|
+
type CustomBlockComponent = React.ComponentType<any>;
|
|
9
|
+
/**
|
|
10
|
+
* Registers a new React component as a custom block type.
|
|
11
|
+
*
|
|
12
|
+
* @param name - Unique identifier for the custom block
|
|
13
|
+
* @param component - React component to render
|
|
14
|
+
*/
|
|
15
|
+
export declare function registerPluginBlock(name: string, component: CustomBlockComponent): void;
|
|
16
|
+
/**
|
|
17
|
+
* Retrieves a registered custom block component.
|
|
18
|
+
*/
|
|
19
|
+
export declare function getPluginBlock(name: string): CustomBlockComponent | undefined;
|
|
20
|
+
/**
|
|
21
|
+
* Checks if a custom block type is registered.
|
|
22
|
+
*/
|
|
23
|
+
export declare function hasPluginBlock(name: string): boolean;
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Block Kit Type System
|
|
3
|
+
*
|
|
4
|
+
* A declarative UI definition system for sandboxed plugins.
|
|
5
|
+
*/
|
|
6
|
+
export type BlockType = 'header' | 'text' | 'divider' | 'stat' | 'input' | 'textarea' | 'select' | 'toggle' | 'button' | 'button_group' | 'table' | 'alert' | 'card' | 'grid' | 'form' | 'custom';
|
|
7
|
+
export interface BaseBlock {
|
|
8
|
+
type: BlockType;
|
|
9
|
+
id?: string;
|
|
10
|
+
className?: string;
|
|
11
|
+
}
|
|
12
|
+
export interface HeaderBlock extends BaseBlock {
|
|
13
|
+
type: 'header';
|
|
14
|
+
text: string;
|
|
15
|
+
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
16
|
+
}
|
|
17
|
+
export interface TextBlock extends BaseBlock {
|
|
18
|
+
type: 'text';
|
|
19
|
+
text: string;
|
|
20
|
+
variant?: 'muted' | 'success' | 'warning' | 'error' | 'primary';
|
|
21
|
+
}
|
|
22
|
+
export interface DividerBlock extends BaseBlock {
|
|
23
|
+
type: 'divider';
|
|
24
|
+
}
|
|
25
|
+
export interface StatBlock extends BaseBlock {
|
|
26
|
+
type: 'stat';
|
|
27
|
+
label: string;
|
|
28
|
+
value: string | number;
|
|
29
|
+
change?: number;
|
|
30
|
+
changeLabel?: string;
|
|
31
|
+
}
|
|
32
|
+
export interface InputBlock extends BaseBlock {
|
|
33
|
+
type: 'input';
|
|
34
|
+
id: string;
|
|
35
|
+
label?: string;
|
|
36
|
+
placeholder?: string;
|
|
37
|
+
value?: string;
|
|
38
|
+
inputType?: 'text' | 'password' | 'email' | 'number' | 'url';
|
|
39
|
+
}
|
|
40
|
+
export interface TextareaBlock extends BaseBlock {
|
|
41
|
+
type: 'textarea';
|
|
42
|
+
id: string;
|
|
43
|
+
label?: string;
|
|
44
|
+
placeholder?: string;
|
|
45
|
+
value?: string;
|
|
46
|
+
rows?: number;
|
|
47
|
+
}
|
|
48
|
+
export interface SelectBlock extends BaseBlock {
|
|
49
|
+
type: 'select';
|
|
50
|
+
id: string;
|
|
51
|
+
label?: string;
|
|
52
|
+
options: Array<{
|
|
53
|
+
label: string;
|
|
54
|
+
value: string;
|
|
55
|
+
}>;
|
|
56
|
+
value?: string;
|
|
57
|
+
}
|
|
58
|
+
export interface ToggleBlock extends BaseBlock {
|
|
59
|
+
type: 'toggle';
|
|
60
|
+
id: string;
|
|
61
|
+
label?: string;
|
|
62
|
+
value?: boolean;
|
|
63
|
+
}
|
|
64
|
+
export interface ButtonBlock extends BaseBlock {
|
|
65
|
+
type: 'button';
|
|
66
|
+
id: string;
|
|
67
|
+
label: string;
|
|
68
|
+
variant?: 'default' | 'outline' | 'secondary' | 'ghost' | 'destructive' | 'link';
|
|
69
|
+
size?: 'default' | 'sm' | 'lg' | 'icon';
|
|
70
|
+
}
|
|
71
|
+
export interface ButtonGroupBlock extends BaseBlock {
|
|
72
|
+
type: 'button_group';
|
|
73
|
+
buttons: ButtonBlock[];
|
|
74
|
+
align?: 'left' | 'center' | 'right';
|
|
75
|
+
}
|
|
76
|
+
export interface TableBlock extends BaseBlock {
|
|
77
|
+
type: 'table';
|
|
78
|
+
columns: Array<{
|
|
79
|
+
key: string;
|
|
80
|
+
label: string;
|
|
81
|
+
}>;
|
|
82
|
+
rows: Array<Record<string, any>>;
|
|
83
|
+
}
|
|
84
|
+
export interface AlertBlock extends BaseBlock {
|
|
85
|
+
type: 'alert';
|
|
86
|
+
title?: string;
|
|
87
|
+
message: string;
|
|
88
|
+
status: 'info' | 'success' | 'warning' | 'destructive';
|
|
89
|
+
}
|
|
90
|
+
export interface CardBlock extends BaseBlock {
|
|
91
|
+
type: 'card';
|
|
92
|
+
title?: string;
|
|
93
|
+
description?: string;
|
|
94
|
+
blocks: Block[];
|
|
95
|
+
}
|
|
96
|
+
export interface GridBlock extends BaseBlock {
|
|
97
|
+
type: 'grid';
|
|
98
|
+
columns?: number;
|
|
99
|
+
gap?: number;
|
|
100
|
+
blocks: Block[];
|
|
101
|
+
}
|
|
102
|
+
export interface FormBlock extends BaseBlock {
|
|
103
|
+
type: 'form';
|
|
104
|
+
id: string;
|
|
105
|
+
submitLabel?: string;
|
|
106
|
+
blocks: Block[];
|
|
107
|
+
}
|
|
108
|
+
export interface CustomBlock extends BaseBlock {
|
|
109
|
+
type: 'custom';
|
|
110
|
+
component: string;
|
|
111
|
+
props?: Record<string, any>;
|
|
112
|
+
}
|
|
113
|
+
export type Block = HeaderBlock | TextBlock | DividerBlock | StatBlock | InputBlock | TextareaBlock | SelectBlock | ToggleBlock | ButtonBlock | ButtonGroupBlock | TableBlock | AlertBlock | CardBlock | GridBlock | FormBlock | CustomBlock;
|
|
114
|
+
export type BlockInteraction = {
|
|
115
|
+
type: 'page_load';
|
|
116
|
+
page: string;
|
|
117
|
+
} | {
|
|
118
|
+
type: 'block_action';
|
|
119
|
+
blockId: string;
|
|
120
|
+
value?: any;
|
|
121
|
+
} | {
|
|
122
|
+
type: 'form_submit';
|
|
123
|
+
formId: string;
|
|
124
|
+
values: Record<string, any>;
|
|
125
|
+
};
|
|
126
|
+
export interface BlockResponse {
|
|
127
|
+
blocks: Block[];
|
|
128
|
+
toast?: {
|
|
129
|
+
type: 'success' | 'error' | 'info' | 'warning';
|
|
130
|
+
message: string;
|
|
131
|
+
};
|
|
132
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import './index.css';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function CollectionsPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function DashboardPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function DevicePage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function DocumentDetailPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function DocumentsPage(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function LoginPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function PluginManagerPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SettingsPage(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SetupPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SignupPage(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export interface AuthState {
|
|
2
|
+
token: string | null;
|
|
3
|
+
user: {
|
|
4
|
+
email: string;
|
|
5
|
+
role: string;
|
|
6
|
+
} | null;
|
|
7
|
+
}
|
|
8
|
+
export declare const $auth: import("nanostores").WritableAtom<AuthState>;
|
|
9
|
+
export declare const login: (token: string, email: string) => void;
|
|
10
|
+
export declare const logout: () => void;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const $basePath: import("nanostores").PreinitializedWritableAtom<string> & object;
|
|
2
|
+
export declare const $apiBaseUrl: import("nanostores").PreinitializedWritableAtom<string> & object;
|
|
3
|
+
export declare function setBase(base: string): void;
|
|
4
|
+
export declare function setApiBaseUrl(url: string): void;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const createFetcherStore: <T = unknown, E = any>(keyInput: import("@nanostores/query").KeyInput, { fetcher, ...fetcherSettings }?: import("@nanostores/query").CommonSettings<T>) => import("@nanostores/query").FetcherStore<T, E>, createMutatorStore: <Data = void, Result = unknown, E_1 = any>(mutator: import("@nanostores/query").ManualMutator<Data, Result>, opts?: {
|
|
2
|
+
throttleCalls?: boolean | undefined;
|
|
3
|
+
onError?: ((error: unknown) => void) | undefined;
|
|
4
|
+
} | undefined) => import("@nanostores/query").MutatorStore<Data, Result, E_1>;
|