export * from '@geenius/adapters/solidjs'; import { JSX } from 'solid-js'; import { AdapterDomain, AdapterStatusInfo, DomainAdapterConfig, AdapterStatusType } from '@geenius/adapters'; /** * @module bridges * @package @geenius/adapters/solidjs-ark * @description Ark UI Solid bridge components for adapter loading, error, and * toast affordances. The bridge layer is additive; adapter contracts and * SolidJS primitives remain inherited from `@geenius/adapters/solidjs`. */ type ToastBridgeType = "error" | "info" | "loading" | "success" | "warning"; type ToastPlacement = "top-start" | "top" | "top-end" | "bottom-start" | "bottom" | "bottom-end"; interface ToastOptions { id?: string; title?: JSX.Element; description?: JSX.Element; duration?: number; closable?: boolean; } interface ToastBridgeToaster { error: (options: ToastOptions) => void; info: (options: ToastOptions) => void; loading: (options: ToastOptions) => void; success: (options: ToastOptions) => void; warning: (options: ToastOptions) => void; } /** Props for the Ark UI Solid loading bridge. */ interface LoadingBridgeProps { /** Whether the bridge should render the loading indicator. */ loading?: boolean; /** Accessible label and visible text for the progress state. */ label?: string; /** Optional determinate progress value from 0 to 100. */ value?: number; /** Optional class merged into the Ark Progress root. */ class?: string; /** Content rendered when `loading` is false. */ children?: JSX.Element; } /** Renders an Ark UI Progress primitive for async adapter loading states. */ declare function LoadingBridge(props: LoadingBridgeProps): JSX.Element; /** Props for the Ark UI Solid error boundary bridge. */ interface ErrorBoundaryBridgeProps { /** Child tree protected by the SolidJS error boundary. */ children?: JSX.Element; /** Optional externally supplied error, useful for async adapter failures. */ error?: unknown; /** Heading rendered in the Ark field error surface. */ title?: string; /** Optional class merged into the Ark Field root. */ class?: string; /** Callback fired when the bridge observes an error. */ onError?: (error: unknown) => void; /** Custom fallback renderer for teams that need a branded error surface. */ fallback?: (error: unknown, reset: () => void) => JSX.Element; } /** Wraps children in a SolidJS ErrorBoundary and renders failures with Ark UI Field primitives. */ declare function ErrorBoundaryBridge(props: ErrorBoundaryBridgeProps): JSX.Element; /** Props for the Ark UI Solid toast bridge. */ interface ToastBridgeProps { /** Toast title emitted when the bridge is opened. */ title?: JSX.Element; /** Toast body emitted when the bridge is opened. */ description?: JSX.Element; /** Toast tone mapped to the Ark toaster store helpers. */ type?: ToastBridgeType; /** Controls emission; defaults to true when title or description is present. */ open?: boolean; /** Optional stable toast id for update/dedupe behavior. */ id?: string; /** Toast auto-dismiss duration in milliseconds. */ duration?: number; /** Whether Ark renders a close trigger for the toast. */ closable?: boolean; /** Ark toaster placement. */ placement?: ToastPlacement; /** Optional injected Ark toaster for app-level toast orchestration. */ toaster?: ToastBridgeToaster; /** Optional class merged into the Ark Toaster region. */ class?: string; /** Content rendered next to the toaster region. */ children?: JSX.Element; } /** Renders an Ark UI Toaster and optionally emits an adapter notification. */ declare function ToastBridge(props: ToastBridgeProps): JSX.Element; /** * @module AdapterCard * @package @geenius/adapters/solidjs-ark * @description Ark-native SolidJS adapter summary card for a single adapter * domain and provider status. */ /** * Props for rendering a single Ark Solid adapter summary card. * * @property domain Adapter domain represented by the card. * @property status Current provider health and metadata for the domain. * @property onClick Optional callback fired when the card is activated. * @property class Optional class name merged into the card container. */ interface AdapterCardProps { domain: AdapterDomain; status: AdapterStatusInfo; onClick?: () => void; class?: string; } /** Renders an adapter domain summary with Ark variant data attributes. */ declare function AdapterCard(props: AdapterCardProps): JSX.Element; /** * @module AdapterConfigForm * @package @geenius/adapters/solidjs-ark * @description Ark-native SolidJS adapter configuration form using Ark Field * and RadioGroup primitives. */ /** * Props accepted by the Ark Solid adapter configuration form. * * @property domain Adapter domain being configured in the current dialog. * @property initialConfig Existing configuration values used to hydrate the form. * @property onSave Async or sync handler that persists the submitted configuration. * @property onCancel Optional callback invoked when the user dismisses the form. * @property class Optional class merged onto the form root. * @property titleId Optional identifier applied to the form title for dialog labelling. */ interface AdapterConfigFormProps { domain: AdapterDomain; initialConfig?: DomainAdapterConfig; onSave: (config: DomainAdapterConfig) => Promise | void; onCancel?: () => void; class?: string; titleId?: string; } /** Renders an Ark UI Solid provider and credential form. */ declare function AdapterConfigForm(props: AdapterConfigFormProps): JSX.Element; /** * @module AdapterList * @package @geenius/adapters/solidjs-ark * @description Ark-native searchable SolidJS adapter grid backed by the * shared SolidJS adapter provider state. */ /** * Props for rendering the Ark Solid adapter list. * * @property onSelect Optional callback invoked when a domain card is selected. * @property filterStatus Optional status filter applied before rendering the grid. * @property class Optional class name merged into the outer wrapper. */ interface AdapterListProps { onSelect?: (domain: AdapterDomain) => void; filterStatus?: AdapterStatusType; class?: string; } /** Renders a searchable Ark Solid adapter list. */ declare function AdapterList(props: AdapterListProps): JSX.Element; /** * @module AdapterStatusBadge * @package @geenius/adapters/solidjs-ark * @description Ark-native SolidJS status badge for the adapter UI variant. */ /** * Props for rendering the Ark UI Solid adapter status badge. * * @property status Shared adapter status vocabulary value to display. * @property showLabel Whether the human-readable label should be rendered. * @property size Visual size variant for the badge and status dot. * @property class Optional class name merged into the badge wrapper. */ interface AdapterStatusBadgeProps { status: AdapterStatusType; showLabel?: boolean; size?: "sm" | "md"; class?: string; } /** Renders a compact Ark-flavoured badge for adapter lifecycle state. */ declare function AdapterStatusBadge(props: AdapterStatusBadgeProps): JSX.Element; /** * @module AdapterDetailPage * @package @geenius/adapters/solidjs-ark * @description Ark-native SolidJS adapter detail page for a single provider * domain. */ /** * Props for rendering the Ark Solid single-domain adapter detail page. * * @property domain Adapter domain whose provider details should be displayed. * @property onBack Optional callback for returning to the dashboard view. * @property class Optional class name merged into the page container. */ interface AdapterDetailPageProps { domain: AdapterDomain; onBack?: () => void; class?: string; } /** Renders the Ark Solid adapter detail page for one adapter domain. */ declare function AdapterDetailPage(props: AdapterDetailPageProps): JSX.Element; /** * @module AdaptersPage * @package @geenius/adapters/solidjs-ark * @description Ark-native SolidJS adapters overview page using Ark Dialog for * the configuration workflow. */ type RegistryEntry = { domain: AdapterDomain; provider: string; status: AdapterStatusType; }; /** * Props accepted by the Ark Solid adapters overview page. * * @property onNavigateDetail Optional callback used instead of opening the inline modal. * @property onConfigure Optional callback invoked with submitted adapter configuration. * @property class Optional class merged onto the page root. * @property configByDomain Optional configuration snapshot used to hydrate modal forms. * @property registryEntries Optional adapter registry snapshot rendered above the grid. */ interface AdaptersPageProps { onNavigateDetail?: (domain: AdapterDomain) => void; onConfigure?: (domain: AdapterDomain, config: DomainAdapterConfig) => Promise | void; class?: string; configByDomain?: Partial>; registryEntries?: RegistryEntry[]; } /** Renders the Ark Solid adapter management dashboard. */ declare function AdaptersPage(props: AdaptersPageProps): JSX.Element; export { AdapterCard, type AdapterCardProps, AdapterConfigForm, type AdapterConfigFormProps, AdapterDetailPage, type AdapterDetailPageProps, AdapterList, type AdapterListProps, AdapterStatusBadge, type AdapterStatusBadgeProps, AdaptersPage, type AdaptersPageProps, ErrorBoundaryBridge, type ErrorBoundaryBridgeProps, LoadingBridge, type LoadingBridgeProps, ToastBridge, type ToastBridgeProps, type ToastBridgeToaster, type ToastBridgeType, type ToastOptions, type ToastPlacement };