@olwiba/ui 0.1.14 → 0.2.0
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/index.d.ts +328 -36
- package/dist/index.js +1160 -326
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/app/AuthSection.tsx +158 -56
- package/src/app/BillingPanel.tsx +155 -0
- package/src/app/OnboardingWizard.tsx +128 -0
- package/src/app/SettingsSection.tsx +29 -0
- package/src/app/TeamMembersPanel.tsx +184 -0
- package/src/components/ActivityFeed.tsx +82 -0
- package/src/components/CommandMenu.tsx +106 -0
- package/src/components/DataTable.tsx +212 -0
- package/src/components/FileUpload.tsx +214 -0
- package/src/components/NotificationsPopover.tsx +146 -0
- package/src/components/Notify.tsx +96 -0
- package/src/index.ts +38 -2
- package/src/marketing/ContactSection.tsx +13 -2
- package/src/marketing/CtaSection.tsx +93 -9
- package/src/marketing/FeaturesSection.tsx +27 -12
- package/src/marketing/HeroSection.tsx +5 -2
- package/src/marketing/NewsletterSection.tsx +12 -2
- package/src/marketing/TeamSection.tsx +10 -2
- package/src/mechanics/Carousel.tsx +112 -0
- package/src/marketing/CarouselSection.tsx +0 -126
- package/src/marketing/CtaCardSection.tsx +0 -95
package/dist/index.d.ts
CHANGED
|
@@ -5,6 +5,8 @@ import React__default, { ReactNode } from 'react';
|
|
|
5
5
|
import { ButtonProps as ButtonProps$1, CardProps as CardProps$1, BadgeProps as BadgeProps$1, InputProps as InputProps$1, TextareaProps as TextareaProps$1, CheckboxProps as CheckboxProps$1, SwitchProps as SwitchProps$1 } from '@olwiba/cn';
|
|
6
6
|
export { CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Enchanted, EnchantedProps } from '@olwiba/cn';
|
|
7
7
|
import { LucideIcon } from 'lucide-react';
|
|
8
|
+
import { ColumnDef } from '@tanstack/react-table';
|
|
9
|
+
export { ColumnDef as DataTableColumn } from '@tanstack/react-table';
|
|
8
10
|
export { MdxContent, MdxContentProps } from './mdx/index.js';
|
|
9
11
|
|
|
10
12
|
declare function cn(...inputs: ClassValue[]): string;
|
|
@@ -260,19 +262,34 @@ interface AppShellProps {
|
|
|
260
262
|
declare function AppShell({ brand, navItems, action, user, pageTitle, headerStart, headerEnd, renderLink, collapsible, sidebarPosition, side, children, }?: AppShellProps): react_jsx_runtime.JSX.Element;
|
|
261
263
|
|
|
262
264
|
interface AuthFormProps {
|
|
263
|
-
/**
|
|
264
|
-
|
|
265
|
+
/**
|
|
266
|
+
* Controls form title, fields, and footer text.
|
|
267
|
+
* - `'signin'` / `'signup'` — email + password
|
|
268
|
+
* - `'forgot-password'` — email only, sends a reset link
|
|
269
|
+
* - `'reset-password'` — new password + confirmation
|
|
270
|
+
* - `'verify'` — one-time code entry (email verification or 2FA)
|
|
271
|
+
* @default 'signin'
|
|
272
|
+
*/
|
|
273
|
+
mode?: 'signin' | 'signup' | 'forgot-password' | 'reset-password' | 'verify';
|
|
265
274
|
onSubmit?: (e: React.FormEvent<HTMLFormElement>) => void;
|
|
266
275
|
onSso?: () => void;
|
|
267
276
|
/** (signin) Link to the sign-up page */
|
|
268
277
|
signUpHref?: string;
|
|
269
|
-
/** (signup) Link back to the sign-in page */
|
|
278
|
+
/** (signup / forgot-password / reset-password / verify) Link back to the sign-in page */
|
|
270
279
|
signInHref?: string;
|
|
271
280
|
forgotPasswordHref?: string;
|
|
281
|
+
/** (verify) Re-sends the one-time code */
|
|
282
|
+
onResend?: () => void;
|
|
283
|
+
/** (verify) Address the code was sent to, shown in the description */
|
|
284
|
+
destination?: string;
|
|
285
|
+
/** (verify) Number of digits in the code. @default 6 */
|
|
286
|
+
codeLength?: number;
|
|
272
287
|
/** Brand node — in centered layout renders above the card; in split layout renders inside the card */
|
|
273
288
|
brand?: React.ReactNode;
|
|
274
289
|
/** Error message displayed below the form fields */
|
|
275
290
|
error?: string;
|
|
291
|
+
/** Positive confirmation message displayed below the form fields (e.g. "Reset link sent") */
|
|
292
|
+
success?: string;
|
|
276
293
|
/** Disables the submit button and shows a loading label */
|
|
277
294
|
loading?: boolean;
|
|
278
295
|
/** Render prop for links — use to inject framework-native link components (e.g. TanStack Router Link) */
|
|
@@ -295,6 +312,108 @@ interface AuthSectionProps extends AuthFormProps {
|
|
|
295
312
|
}
|
|
296
313
|
declare function AuthSection({ layout, children, panel, className, ...formProps }: AuthSectionProps): react_jsx_runtime.JSX.Element;
|
|
297
314
|
|
|
315
|
+
interface SettingsSectionProps {
|
|
316
|
+
title: string;
|
|
317
|
+
description?: string;
|
|
318
|
+
/** Form fields, buttons, or any content for the right-hand column — e.g. a `<form>`. */
|
|
319
|
+
children: React.ReactNode;
|
|
320
|
+
/** Marks the section as a destructive action (e.g. "Delete account") — renders the title in the destructive color. @default false */
|
|
321
|
+
danger?: boolean;
|
|
322
|
+
className?: string;
|
|
323
|
+
}
|
|
324
|
+
/**
|
|
325
|
+
* One title+description+content row for a settings page. Stack a few inside
|
|
326
|
+
* a `<div className="divide-y divide-border">` to build a full settings
|
|
327
|
+
* page — one block reused per row, rather than a bespoke layout each time.
|
|
328
|
+
*/
|
|
329
|
+
declare function SettingsSection({ title, description, children, danger, className }: SettingsSectionProps): react_jsx_runtime.JSX.Element;
|
|
330
|
+
|
|
331
|
+
interface TeamMemberRecord {
|
|
332
|
+
id: string;
|
|
333
|
+
name: string;
|
|
334
|
+
email: string;
|
|
335
|
+
avatar?: string;
|
|
336
|
+
role: string;
|
|
337
|
+
}
|
|
338
|
+
interface TeamMembersPanelProps {
|
|
339
|
+
members: TeamMemberRecord[];
|
|
340
|
+
/** Roles offered in the invite dialog and the per-row role menu. @default ['Owner', 'Admin', 'Member'] */
|
|
341
|
+
roles?: string[];
|
|
342
|
+
onInvite?: (email: string, role: string) => void;
|
|
343
|
+
onRoleChange?: (memberId: string, role: string) => void;
|
|
344
|
+
onRemove?: (memberId: string) => void;
|
|
345
|
+
title?: string;
|
|
346
|
+
description?: string;
|
|
347
|
+
}
|
|
348
|
+
/**
|
|
349
|
+
* Member list with role management and an invite dialog. One block for
|
|
350
|
+
* team/org administration — built on `DataTable` rather than a bespoke list.
|
|
351
|
+
*/
|
|
352
|
+
declare function TeamMembersPanel({ members, roles, onInvite, onRoleChange, onRemove, title, description, }: TeamMembersPanelProps): react_jsx_runtime.JSX.Element;
|
|
353
|
+
|
|
354
|
+
interface BillingUsageMetric {
|
|
355
|
+
label: string;
|
|
356
|
+
used: number;
|
|
357
|
+
limit: number;
|
|
358
|
+
unit?: string;
|
|
359
|
+
}
|
|
360
|
+
interface BillingInvoice {
|
|
361
|
+
id: string;
|
|
362
|
+
date: string;
|
|
363
|
+
amount: string;
|
|
364
|
+
status: 'paid' | 'open' | 'void';
|
|
365
|
+
downloadUrl?: string;
|
|
366
|
+
}
|
|
367
|
+
interface BillingPaymentMethod {
|
|
368
|
+
brand: string;
|
|
369
|
+
last4: string;
|
|
370
|
+
expiry: string;
|
|
371
|
+
}
|
|
372
|
+
interface BillingPanelProps {
|
|
373
|
+
planName: string;
|
|
374
|
+
planPrice?: string;
|
|
375
|
+
renewalDate?: string;
|
|
376
|
+
usage?: BillingUsageMetric[];
|
|
377
|
+
paymentMethod?: BillingPaymentMethod;
|
|
378
|
+
invoices?: BillingInvoice[];
|
|
379
|
+
onManagePlan?: () => void;
|
|
380
|
+
onUpdatePaymentMethod?: () => void;
|
|
381
|
+
className?: string;
|
|
382
|
+
}
|
|
383
|
+
/**
|
|
384
|
+
* In-app billing summary — current plan + usage, payment method, invoice
|
|
385
|
+
* history. Built from `SettingsSection` rows and `DataTable`, rather than a
|
|
386
|
+
* one-off billing page each time. Marketing plan comparisons stay in
|
|
387
|
+
* `PricingSection`/`UpgradePrompt` — this is the account-side view.
|
|
388
|
+
*/
|
|
389
|
+
declare function BillingPanel({ planName, planPrice, renewalDate, usage, paymentMethod, invoices, onManagePlan, onUpdatePaymentMethod, className, }: BillingPanelProps): react_jsx_runtime.JSX.Element;
|
|
390
|
+
|
|
391
|
+
interface OnboardingStep {
|
|
392
|
+
id: string;
|
|
393
|
+
title: string;
|
|
394
|
+
description?: string;
|
|
395
|
+
content: React.ReactNode;
|
|
396
|
+
/** Runs before advancing past this step. Return `false`/an error string to block. */
|
|
397
|
+
onNext?: () => boolean | string | Promise<boolean | string>;
|
|
398
|
+
}
|
|
399
|
+
interface OnboardingWizardProps {
|
|
400
|
+
steps: OnboardingStep[];
|
|
401
|
+
/** Called after the last step's `onNext` succeeds. */
|
|
402
|
+
onComplete?: () => void;
|
|
403
|
+
onStepChange?: (index: number) => void;
|
|
404
|
+
/** Controlled current step index — omit to let the component manage it internally. */
|
|
405
|
+
step?: number;
|
|
406
|
+
onStepIndexChange?: (index: number) => void;
|
|
407
|
+
completeLabel?: string;
|
|
408
|
+
className?: string;
|
|
409
|
+
}
|
|
410
|
+
/**
|
|
411
|
+
* Stateful multi-step onboarding flow. One component driven by a `steps`
|
|
412
|
+
* prop — swap the array to reshape the flow rather than hand-building a
|
|
413
|
+
* new wizard per feature.
|
|
414
|
+
*/
|
|
415
|
+
declare function OnboardingWizard({ steps, onComplete, onStepChange, step: stepProp, onStepIndexChange, completeLabel, className, }: OnboardingWizardProps): react_jsx_runtime.JSX.Element;
|
|
416
|
+
|
|
298
417
|
interface EmptyStateProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
299
418
|
icon?: LucideIcon;
|
|
300
419
|
title: string;
|
|
@@ -412,8 +531,10 @@ interface FeaturesSectionProps {
|
|
|
412
531
|
description: string;
|
|
413
532
|
href?: string;
|
|
414
533
|
}>;
|
|
534
|
+
/** How the feature cards are arranged. @default 'grid' */
|
|
535
|
+
layout?: 'grid' | 'carousel';
|
|
415
536
|
}
|
|
416
|
-
declare function FeaturesSection({ title, description, badge, features, }: FeaturesSectionProps): react_jsx_runtime.JSX.Element;
|
|
537
|
+
declare function FeaturesSection({ title, description, badge, features, layout, }: FeaturesSectionProps): react_jsx_runtime.JSX.Element;
|
|
417
538
|
|
|
418
539
|
interface GroupedFeatureGroup {
|
|
419
540
|
label: string;
|
|
@@ -459,23 +580,6 @@ interface TechStackSectionProps {
|
|
|
459
580
|
}
|
|
460
581
|
declare function TechStackSection({ badge, title, description, items, }: TechStackSectionProps): react_jsx_runtime.JSX.Element;
|
|
461
582
|
|
|
462
|
-
interface CarouselSectionProps {
|
|
463
|
-
title?: string;
|
|
464
|
-
description?: string;
|
|
465
|
-
badge?: string;
|
|
466
|
-
features: Array<{
|
|
467
|
-
icon: LucideIcon;
|
|
468
|
-
title: string;
|
|
469
|
-
description: string;
|
|
470
|
-
href?: string;
|
|
471
|
-
}>;
|
|
472
|
-
}
|
|
473
|
-
/**
|
|
474
|
-
* Horizontally scrolling card carousel for feature-style content.
|
|
475
|
-
* Scroll-snap based with prev/next controls — no carousel dependency.
|
|
476
|
-
*/
|
|
477
|
-
declare function CarouselSection({ title, description, badge, features, }: CarouselSectionProps): react_jsx_runtime.JSX.Element;
|
|
478
|
-
|
|
479
583
|
interface FeatureMarqueeItem {
|
|
480
584
|
icon: LucideIcon;
|
|
481
585
|
title: string;
|
|
@@ -496,7 +600,7 @@ declare function FeatureMarqueeSection({ badge, title, description, rows, speed,
|
|
|
496
600
|
|
|
497
601
|
interface CtaSectionProps {
|
|
498
602
|
heading: string;
|
|
499
|
-
description
|
|
603
|
+
description?: string;
|
|
500
604
|
primaryCta: {
|
|
501
605
|
label: string;
|
|
502
606
|
href: string;
|
|
@@ -506,22 +610,18 @@ interface CtaSectionProps {
|
|
|
506
610
|
href: string;
|
|
507
611
|
};
|
|
508
612
|
footnote?: string;
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
label: string;
|
|
518
|
-
href: string;
|
|
519
|
-
};
|
|
520
|
-
footnote?: string;
|
|
613
|
+
/**
|
|
614
|
+
* Visual treatment of the section.
|
|
615
|
+
* - `'default'` — badge icon, radial glow, primary + secondary CTAs
|
|
616
|
+
* - `'showcase'` — large watermark icon with a scroll-reveal, single pill CTA
|
|
617
|
+
* @default 'default'
|
|
618
|
+
*/
|
|
619
|
+
variant?: 'default' | 'showcase';
|
|
620
|
+
/** (showcase) Watermark icon rendered behind the content. @default <Rocket /> */
|
|
521
621
|
icon?: React.ReactNode;
|
|
522
622
|
renderLink?: AppShellRenderLink;
|
|
523
623
|
}
|
|
524
|
-
declare function
|
|
624
|
+
declare function CtaSection(props: CtaSectionProps): react_jsx_runtime.JSX.Element;
|
|
525
625
|
|
|
526
626
|
interface PricingFeature {
|
|
527
627
|
label: string;
|
|
@@ -857,6 +957,24 @@ interface PageTransitionProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
857
957
|
}
|
|
858
958
|
declare function PageTransition({ variant, duration, children, className, style, ...props }: PageTransitionProps): react_jsx_runtime.JSX.Element;
|
|
859
959
|
|
|
960
|
+
interface CarouselProps {
|
|
961
|
+
/** Items to scroll through — each child becomes one snap slide. */
|
|
962
|
+
children: React.ReactNode;
|
|
963
|
+
/** Width classes applied to each slide. @default 'w-[280px] sm:w-[320px]' */
|
|
964
|
+
itemClassName?: string;
|
|
965
|
+
/** Prev/next control placement. @default 'top-right' */
|
|
966
|
+
controls?: 'top-right' | 'none';
|
|
967
|
+
/** Accessible label for the scroll region. */
|
|
968
|
+
ariaLabel?: string;
|
|
969
|
+
className?: string;
|
|
970
|
+
}
|
|
971
|
+
/**
|
|
972
|
+
* Scroll-snap carousel behavior — wraps any children in a horizontally
|
|
973
|
+
* scrolling track with prev/next controls. A mechanic, not a section:
|
|
974
|
+
* feed it cards, images, or whole blocks. No carousel dependency.
|
|
975
|
+
*/
|
|
976
|
+
declare function Carousel({ children, itemClassName, controls, ariaLabel, className, }: CarouselProps): react_jsx_runtime.JSX.Element;
|
|
977
|
+
|
|
860
978
|
interface SpotlightItem {
|
|
861
979
|
id: string;
|
|
862
980
|
label: string;
|
|
@@ -956,6 +1074,180 @@ interface ConfirmDialogProps extends Pick<UseConfirmReturn, 'isOpen' | 'options'
|
|
|
956
1074
|
}
|
|
957
1075
|
declare function ConfirmDialog({ isOpen, options, handleConfirm, handleCancel, destructive }: ConfirmDialogProps): react_jsx_runtime.JSX.Element;
|
|
958
1076
|
|
|
1077
|
+
interface CommandMenuItem {
|
|
1078
|
+
id: string;
|
|
1079
|
+
label: string;
|
|
1080
|
+
icon?: LucideIcon;
|
|
1081
|
+
shortcut?: string;
|
|
1082
|
+
keywords?: string[];
|
|
1083
|
+
onSelect: () => void;
|
|
1084
|
+
}
|
|
1085
|
+
interface CommandMenuGroup {
|
|
1086
|
+
heading: string;
|
|
1087
|
+
items: CommandMenuItem[];
|
|
1088
|
+
}
|
|
1089
|
+
interface CommandMenuProps {
|
|
1090
|
+
groups: CommandMenuGroup[];
|
|
1091
|
+
placeholder?: string;
|
|
1092
|
+
emptyMessage?: string;
|
|
1093
|
+
/** Controlled open state — omit to let the component manage it internally. */
|
|
1094
|
+
open?: boolean;
|
|
1095
|
+
onOpenChange?: (open: boolean) => void;
|
|
1096
|
+
/** Registers Cmd+K (mac) / Ctrl+K (win) to toggle the palette. @default true */
|
|
1097
|
+
hotkey?: boolean;
|
|
1098
|
+
}
|
|
1099
|
+
/**
|
|
1100
|
+
* Global search / Cmd+K command palette. One component — pass different
|
|
1101
|
+
* `groups` per surface rather than building a bespoke dialog each time.
|
|
1102
|
+
*/
|
|
1103
|
+
declare function CommandMenu({ groups, placeholder, emptyMessage, open: openProp, onOpenChange, hotkey, }: CommandMenuProps): react_jsx_runtime.JSX.Element;
|
|
1104
|
+
|
|
1105
|
+
interface DataTableProps<TData> {
|
|
1106
|
+
columns: ColumnDef<TData>[];
|
|
1107
|
+
data: TData[];
|
|
1108
|
+
/** Shows a quick-filter input above the table, matching against `searchKey`. */
|
|
1109
|
+
searchKey?: string;
|
|
1110
|
+
searchPlaceholder?: string;
|
|
1111
|
+
/** Adds a checkbox column and reports the selected rows. */
|
|
1112
|
+
selectable?: boolean;
|
|
1113
|
+
onSelectionChange?: (rows: TData[]) => void;
|
|
1114
|
+
/** Rows per page. Set to `0` to disable pagination entirely. @default 10 */
|
|
1115
|
+
pageSize?: number;
|
|
1116
|
+
/** Slot rendered top-right of the toolbar — e.g. an "Add" button. */
|
|
1117
|
+
toolbar?: React.ReactNode;
|
|
1118
|
+
onRowClick?: (row: TData) => void;
|
|
1119
|
+
emptyMessage?: string;
|
|
1120
|
+
className?: string;
|
|
1121
|
+
}
|
|
1122
|
+
/**
|
|
1123
|
+
* Sortable, paginated, optionally-selectable data table. One component —
|
|
1124
|
+
* toggle `searchKey`/`selectable`/`pageSize` rather than reaching for a
|
|
1125
|
+
* different table component per use case.
|
|
1126
|
+
*/
|
|
1127
|
+
declare function DataTable<TData>({ columns, data, searchKey, searchPlaceholder, selectable, onSelectionChange, pageSize, toolbar, onRowClick, emptyMessage, className, }: DataTableProps<TData>): react_jsx_runtime.JSX.Element;
|
|
1128
|
+
|
|
1129
|
+
interface FileUploadEntry {
|
|
1130
|
+
id: string;
|
|
1131
|
+
file: File;
|
|
1132
|
+
/** 0–100. Omit while pending, or when not tracking progress. */
|
|
1133
|
+
progress?: number;
|
|
1134
|
+
status?: 'pending' | 'uploading' | 'done' | 'error';
|
|
1135
|
+
error?: string;
|
|
1136
|
+
}
|
|
1137
|
+
interface FileUploadProps {
|
|
1138
|
+
/** Comma-separated MIME types / extensions, e.g. `"image/png,image/jpeg"`. */
|
|
1139
|
+
accept?: string;
|
|
1140
|
+
multiple?: boolean;
|
|
1141
|
+
maxSizeMb?: number;
|
|
1142
|
+
maxFiles?: number;
|
|
1143
|
+
/** Controlled file list — pass this (with `onFilesChange`) to drive upload progress from your own network layer. */
|
|
1144
|
+
files?: FileUploadEntry[];
|
|
1145
|
+
/** Uncontrolled default list. */
|
|
1146
|
+
defaultFiles?: FileUploadEntry[];
|
|
1147
|
+
onFilesChange?: (files: FileUploadEntry[]) => void;
|
|
1148
|
+
/** Fired with the raw, already-validated `File` objects a user just added. */
|
|
1149
|
+
onFilesAdded?: (files: File[]) => void;
|
|
1150
|
+
disabled?: boolean;
|
|
1151
|
+
/** Helper text under the drop zone, e.g. "PNG or JPG, up to 5MB". */
|
|
1152
|
+
hint?: string;
|
|
1153
|
+
className?: string;
|
|
1154
|
+
}
|
|
1155
|
+
/**
|
|
1156
|
+
* Drag-and-drop file picker with a validated queue list. One component —
|
|
1157
|
+
* toggle `multiple`/`accept`/`maxSizeMb`/`maxFiles` rather than reaching for
|
|
1158
|
+
* a separate dropzone per use case. Progress/status is presentation-only;
|
|
1159
|
+
* wire `files`/`onFilesChange` to your own upload layer to drive it.
|
|
1160
|
+
*/
|
|
1161
|
+
declare function FileUpload({ accept, multiple, maxSizeMb, maxFiles, files: filesProp, defaultFiles, onFilesChange, onFilesAdded, disabled, hint, className, }: FileUploadProps): react_jsx_runtime.JSX.Element;
|
|
1162
|
+
|
|
1163
|
+
interface NotifyAction {
|
|
1164
|
+
label: string;
|
|
1165
|
+
onClick: () => void;
|
|
1166
|
+
}
|
|
1167
|
+
interface NotificationToastProps {
|
|
1168
|
+
variant?: 'success' | 'info' | 'warning' | 'error' | 'message';
|
|
1169
|
+
title: string;
|
|
1170
|
+
description?: string;
|
|
1171
|
+
/** Avatar image — overrides the variant icon (e.g. for a message-from-a-person toast). */
|
|
1172
|
+
avatar?: string;
|
|
1173
|
+
/** Primary action, right-aligned next to the description (e.g. "Undo"). */
|
|
1174
|
+
action?: NotifyAction;
|
|
1175
|
+
/** Secondary action, rendered after the primary one (e.g. "Decline"). */
|
|
1176
|
+
secondaryAction?: NotifyAction;
|
|
1177
|
+
onDismiss?: () => void;
|
|
1178
|
+
}
|
|
1179
|
+
/**
|
|
1180
|
+
* Rich toast content — rendered via `notify()` inside sonner's `toast.custom`.
|
|
1181
|
+
* One component: `variant` swaps the default icon, `avatar`/`action`/
|
|
1182
|
+
* `secondaryAction` add the pieces a given toast needs, rather than a
|
|
1183
|
+
* separate toast component per shape.
|
|
1184
|
+
*/
|
|
1185
|
+
declare function NotificationToast({ variant, title, description, avatar, action, secondaryAction, onDismiss, }: NotificationToastProps): react_jsx_runtime.JSX.Element;
|
|
1186
|
+
interface NotifyOptions extends Omit<NotificationToastProps, 'onDismiss'> {
|
|
1187
|
+
duration?: number;
|
|
1188
|
+
}
|
|
1189
|
+
/** Fires a `NotificationToast` through sonner. Requires `<Toaster />` from `@olwiba/cn` mounted once in your app. */
|
|
1190
|
+
declare function notify(options: NotifyOptions): string | number;
|
|
1191
|
+
|
|
1192
|
+
interface NotificationItem {
|
|
1193
|
+
id: string;
|
|
1194
|
+
title: string;
|
|
1195
|
+
description?: string;
|
|
1196
|
+
/** Pre-formatted timestamp, e.g. "2h ago" or "Yesterday". */
|
|
1197
|
+
timestamp?: string;
|
|
1198
|
+
read?: boolean;
|
|
1199
|
+
/** Avatar image — takes precedence over `icon`. */
|
|
1200
|
+
avatar?: string;
|
|
1201
|
+
icon?: React.ReactNode;
|
|
1202
|
+
}
|
|
1203
|
+
interface NotificationsPopoverProps {
|
|
1204
|
+
notifications: NotificationItem[];
|
|
1205
|
+
onNotificationClick?: (notification: NotificationItem) => void;
|
|
1206
|
+
/** Shows a "Mark all read" action in the header when there are unread items. */
|
|
1207
|
+
onMarkAllRead?: () => void;
|
|
1208
|
+
title?: string;
|
|
1209
|
+
emptyMessage?: string;
|
|
1210
|
+
/** Popover alignment relative to the bell button. @default 'end' */
|
|
1211
|
+
align?: 'start' | 'center' | 'end';
|
|
1212
|
+
/** Controlled open state — omit to let the component manage it internally. */
|
|
1213
|
+
open?: boolean;
|
|
1214
|
+
onOpenChange?: (open: boolean) => void;
|
|
1215
|
+
className?: string;
|
|
1216
|
+
}
|
|
1217
|
+
/**
|
|
1218
|
+
* Bell button + persistent notification inbox. Complements `notify()` toasts:
|
|
1219
|
+
* a toast announces an event as it happens, this popover holds the history.
|
|
1220
|
+
* Presentation-only — pass `notifications` from your own data layer and
|
|
1221
|
+
* persist read state via `onMarkAllRead`/`onNotificationClick`.
|
|
1222
|
+
*/
|
|
1223
|
+
declare function NotificationsPopover({ notifications, onNotificationClick, onMarkAllRead, title, emptyMessage, align, open, onOpenChange, className, }: NotificationsPopoverProps): react_jsx_runtime.JSX.Element;
|
|
1224
|
+
|
|
1225
|
+
interface ActivityFeedItem {
|
|
1226
|
+
id: string;
|
|
1227
|
+
/** Main line — pass rich nodes for emphasis, e.g. <><b>Ana</b> deployed to production</>. */
|
|
1228
|
+
title: React.ReactNode;
|
|
1229
|
+
description?: string;
|
|
1230
|
+
/** Pre-formatted timestamp, e.g. "2h ago" or "Mar 4". */
|
|
1231
|
+
timestamp?: string;
|
|
1232
|
+
/** Avatar image — takes precedence over `icon`. */
|
|
1233
|
+
avatar?: string;
|
|
1234
|
+
/** Fallback initials when `avatar` is set but fails to load. */
|
|
1235
|
+
initials?: string;
|
|
1236
|
+
/** Icon node rendered in the timeline marker when there is no avatar. */
|
|
1237
|
+
icon?: React.ReactNode;
|
|
1238
|
+
}
|
|
1239
|
+
interface ActivityFeedProps {
|
|
1240
|
+
items: ActivityFeedItem[];
|
|
1241
|
+
emptyMessage?: string;
|
|
1242
|
+
className?: string;
|
|
1243
|
+
}
|
|
1244
|
+
/**
|
|
1245
|
+
* Vertical activity timeline — avatar or icon markers connected by a rail,
|
|
1246
|
+
* one row per event. Presentation-only: pass pre-formatted timestamps and
|
|
1247
|
+
* rich `title` nodes from your own data layer.
|
|
1248
|
+
*/
|
|
1249
|
+
declare function ActivityFeed({ items, emptyMessage, className, }: ActivityFeedProps): react_jsx_runtime.JSX.Element;
|
|
1250
|
+
|
|
959
1251
|
declare const sizes: {
|
|
960
1252
|
readonly sm: {
|
|
961
1253
|
readonly outer: "w-44";
|
|
@@ -1322,4 +1614,4 @@ interface UsePaginationReturn {
|
|
|
1322
1614
|
}
|
|
1323
1615
|
declare function usePagination(total: number, pageSize: number): UsePaginationReturn;
|
|
1324
1616
|
|
|
1325
|
-
export { AnimatedPill, type AnimatedPillProps, AppContent, type AppContentProps, AppGrid, AppGridCell, type AppGridCellProps, type AppGridProps, type AppNavItem, AppScreen, AppShell, type AppShellAction, type AppShellBrand, type AppShellProps, type AppShellRenderLink, type AppShellUser, type AuthFormProps, AuthSection, type AuthSectionProps, Badge, type BadgeProps, BrandColorSwitchMinimal, Button, type ButtonProps, Card, type CardProps,
|
|
1617
|
+
export { ActivityFeed, type ActivityFeedItem, type ActivityFeedProps, AnimatedPill, type AnimatedPillProps, AppContent, type AppContentProps, AppGrid, AppGridCell, type AppGridCellProps, type AppGridProps, type AppNavItem, AppScreen, AppShell, type AppShellAction, type AppShellBrand, type AppShellProps, type AppShellRenderLink, type AppShellUser, type AuthFormProps, AuthSection, type AuthSectionProps, Badge, type BadgeProps, type BillingInvoice, BillingPanel, type BillingPanelProps, type BillingPaymentMethod, type BillingUsageMetric, BrandColorSwitchMinimal, Button, type ButtonProps, Card, type CardProps, Carousel, type CarouselProps, ChangelogCard, type ChangelogCardProps, type ChangelogHighlight, ChangelogList, type ChangelogListProps, type ChangelogReleaseType, Checkbox, type CheckboxProps, CommandMenu, type CommandMenuGroup, type CommandMenuItem, type CommandMenuProps, type ComparisonColumn, ComparisonSection, type ComparisonSectionProps, ConfirmDialog, type ConfirmDialogProps, type ConfirmOptions, type ContactInfoItem, ContactSection, type ContactSectionProps, ContextMenu, type ContextMenuDef, type ContextMenuProps, CountUp, type CountUpProps, CountdownTimer, type CountdownTimerProps, CtaSection, type CtaSectionProps, DataTable, type DataTableProps, DevBanner, type DevBannerProps, Dock, type DockItem, type DockProps, EmptyState, type EmptyStateProps, ErrorPage, type ErrorPageProps, FadeIn, type FadeInProps, FaqSection, type FaqSectionProps, FeatureCard, type FeatureCardProps, type FeatureMarqueeItem, type FeatureMarqueeRow, FeatureMarqueeSection, type FeatureMarqueeSectionProps, FeaturesSection, type FeaturesSectionProps, FileUpload, type FileUploadEntry, type FileUploadProps, FlowBracket, type FlowBracketProps, FlowConnector, type FlowConnectorProps, Footer, type FooterProps, FullPageSpinner, GlassCard, type GlassCardProps, Grid, GridItem, type GridItemProps, type GridProps, type GroupedFeatureGroup, GroupedFeaturesSection, type GroupedFeaturesSectionProps, HeroSection, type HeroSectionProps, type Hotkey, ImageCard, type ImageCardProps, Input, type InputProps, LogoStrip, type LogoStripProps, type MarketingSectionSpacing, ModeSwitchMinimal, Navbar, type NavbarProps, NewsletterSection, type NewsletterSectionProps, type NotificationItem, NotificationToast, type NotificationToastProps, NotificationsPopover, type NotificationsPopoverProps, type NotifyAction, type NotifyOptions, OlwibaUIProvider, type OlwibaUIProviderProps, type OnboardingStep, OnboardingWizard, type OnboardingWizardProps, Overlay, type OverlayProps, type OverlayVariant, PageHeader, type PageHeaderBackButton, type PageHeaderBreadcrumb, type PageHeaderProps, PageTransition, type PageTransitionProps, PhoneFrame, type PhoneFrameProps, type PostAuthor, PostCard, type PostCardProps, PostList, type PostListProps, PricingCard, type PricingCardProps, type PricingFeature, type PricingPlan, PricingSection, type PricingSectionProps, PublicPageFrame, type PublicPageFrameProps, type QualificationColumn, QualificationSection, type QualificationSectionProps, RegisterHotkeys, RootErrorFallback, Section, type SectionProps, SectionTitle, type SectionTitleProps, SettingsSection, type SettingsSectionProps, Spotlight, type SpotlightGroup, type SpotlightItem, type SpotlightProps, Stack, type StackProps, StaggerChildren, type StaggerChildrenProps, StatCard, type StatCardProps, StatsSection, type StatsSectionProps, type StepItem, StepsSection, type StepsSectionProps, Suspensed, Switch, type SwitchProps, type TeamMember, type TeamMemberRecord, TeamMembersPanel, type TeamMembersPanelProps, TeamSection, type TeamSectionProps, type TechStackItem, TechStackSection, type TechStackSectionProps, TestimonialCard, type TestimonialCardProps, TestimonialsSection, type TestimonialsSectionProps, Textarea, type TextareaProps, ThemeColorUpdater, ThemeSwitchMinimal, type UIMode, Underlay, type UnderlayProps, type UnderlayVariant, type UpgradeComparisonRow, UpgradePrompt, type UpgradePromptProps, type UseConfirmReturn, type UseControlledOpenReturn, type UsePaginationReturn, VersionBanner, cn, marketingSectionSpacing, notify, useConfirm, useControlledOpen, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useMounted, useOlwibaUI, usePagination, useScrolledPast, useUIMode };
|