@vantageos/mosaic-blocks 0.4.8-alpha → 0.5.1-alpha

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.cts CHANGED
@@ -20,7 +20,7 @@ import { Switch } from '@base-ui/react/switch';
20
20
  export { Tooltip } from '@base-ui/react/tooltip';
21
21
  import 'class-variance-authority/types';
22
22
 
23
- declare const version = "0.4.8-alpha";
23
+ declare const version = "0.5.1-alpha";
24
24
 
25
25
  /**
26
26
  * Placeholder component — infra scaffold only.
@@ -2675,7 +2675,6 @@ interface MosaicAgentComposerProps {
2675
2675
  previewConfigLabel: string;
2676
2676
  customInstructionsPreviewLabel: string;
2677
2677
  selectAllModulesLabel: string;
2678
- requiredLabel: string;
2679
2678
  /** Fallback name shown in the preview when `agentName` is empty. Required, no default. */
2680
2679
  unnamedAgentLabel: string;
2681
2680
  }
@@ -2712,6 +2711,13 @@ declare namespace MosaicAgentComposerDesktop {
2712
2711
  interface MosaicAgentComposerMobileProps extends MosaicAgentComposerProps {
2713
2712
  /** Show loading state on submit button */
2714
2713
  isLoading?: boolean;
2714
+ /**
2715
+ * "Required" marker shown on a mandatory module slot. Declared HERE, not on
2716
+ * the shared MosaicAgentComposerProps, because only the mobile composer
2717
+ * renders it — the desktop one never does. (Moved by the
2718
+ * no-lying-prop-contract guard: a prop is required exactly where it is read.)
2719
+ */
2720
+ requiredLabel: string;
2715
2721
  /**
2716
2722
  * Required host-owned strings (mobile-only extras) — no default,
2717
2723
  * no fallback. The host owns the language (e.g. next-intl `t()`).
@@ -2881,10 +2887,6 @@ interface MosaicDeleteConfirmationDialogProps {
2881
2887
  onOpenChange: (open: boolean) => void;
2882
2888
  /** Called when the user confirms deletion */
2883
2889
  onConfirm: () => void;
2884
- /** Human-readable name of the item to be deleted */
2885
- itemName: string;
2886
- /** Type label shown in the title and button ("agent", "template", etc.). Required, no default. */
2887
- itemType: string;
2888
2890
  /** Dialog title. Required — the host owns the language, no default. */
2889
2891
  title: string;
2890
2892
  /** Dialog description. Required — the host owns the language, no default. */
@@ -3212,6 +3214,15 @@ declare namespace MosaicQuickAgentSelector {
3212
3214
  * required prop or a required formatter function — no optional prop with an
3213
3215
  * English default anywhere in this file.
3214
3216
  *
3217
+ * Props are pushed into the `MosaicMemoryCardVariantProps` discriminated
3218
+ * union exactly where they are read — no prop is required on a variant that
3219
+ * never renders it. `formatMoreTags` is required only on the `"detailed"`
3220
+ * (default) member: the `"compact"` variant drops the tags row entirely and
3221
+ * never calls it, so it is not part of `"compact"`'s member of the union
3222
+ * (fixed after being flagged as a "lying prop contract" by the
3223
+ * `no-lying-prop-contract` guard test — see that file and the memory-card's
3224
+ * own type definitions below).
3225
+ *
3215
3226
  * Closes T1 (bu-mcp memory wave) — mosaic-memory-card.
3216
3227
  *
3217
3228
  * @example
@@ -3258,15 +3269,12 @@ interface MosaicMemoryData {
3258
3269
  createdAt: number;
3259
3270
  usageCount: number;
3260
3271
  }
3261
- interface MosaicMemoryCardProps {
3272
+ /**
3273
+ * Props shared by both variants — read unconditionally regardless of
3274
+ * `variant`.
3275
+ */
3276
+ interface MosaicMemoryCardBaseProps {
3262
3277
  memory: MosaicMemoryData;
3263
- /**
3264
- * Layout density.
3265
- * - `"detailed"` (default): icon chip + tags row + labelled usage footer.
3266
- * - `"compact"`: condensed header row, no tags row, raw usage number.
3267
- * @default "detailed"
3268
- */
3269
- variant?: "detailed" | "compact";
3270
3278
  onEdit?: (memory: MosaicMemoryData) => void;
3271
3279
  onDelete?: (memoryId: string) => void;
3272
3280
  /** Label for the "edit" menu item. Required — host-owned, no default. */
@@ -3295,16 +3303,38 @@ interface MosaicMemoryCardProps {
3295
3303
  * Required — host-owned (e.g. `(count) => t("memory.usageCount", { count })`).
3296
3304
  */
3297
3305
  formatUsageCount: (count: number) => React.ReactNode;
3298
- /**
3299
- * Formatter producing the "+N" overflow caption when a memory has more
3300
- * than 3 tags. Only rendered in the detailed variant. Required —
3301
- * host-owned (e.g. `(count) => \`+\${count}\`` or a pluralized `t()` call).
3302
- */
3303
- formatMoreTags: (count: number) => React.ReactNode;
3304
3306
  className?: string;
3305
3307
  /** React 19 ref prop — forwarded to the root element. */
3306
3308
  ref?: React.Ref<HTMLDivElement>;
3307
3309
  }
3310
+ /**
3311
+ * Discriminated union on `variant` — the sole property that differs between
3312
+ * variants (`formatMoreTags`) is required EXACTLY on the branch that reads
3313
+ * it (`"detailed"`, the default), not on the shared base. The `"compact"`
3314
+ * variant never renders a tags row and therefore never calls
3315
+ * `formatMoreTags` — requiring it there would force every host to supply a
3316
+ * value the library never displays (a "lying prop contract"; see the
3317
+ * `no-lying-prop-contract` guard test and the file's changelog note below).
3318
+ */
3319
+ type MosaicMemoryCardVariantProps = {
3320
+ /**
3321
+ * Full-density layout: icon chip + tags row + labelled usage footer.
3322
+ * Default when omitted.
3323
+ * @default "detailed"
3324
+ */
3325
+ variant?: "detailed";
3326
+ /**
3327
+ * Formatter producing the "+N" overflow caption when a memory has more
3328
+ * than 3 tags. Only ever rendered in the detailed variant — required
3329
+ * here, not on `"compact"`. Host-owned (e.g. `(count) => \`+\${count}\``
3330
+ * or a pluralized `t()` call).
3331
+ */
3332
+ formatMoreTags: (count: number) => React.ReactNode;
3333
+ } | {
3334
+ /** Condensed list row, no tags row, no `formatMoreTags` call. */
3335
+ variant: "compact";
3336
+ };
3337
+ type MosaicMemoryCardProps = MosaicMemoryCardBaseProps & MosaicMemoryCardVariantProps;
3308
3338
  /**
3309
3339
  * MosaicMemoryCard — production memory-item card for @vantageos/mosaic-blocks.
3310
3340
  *
@@ -3312,7 +3342,7 @@ interface MosaicMemoryCardProps {
3312
3342
  * see file JSDoc for the exact desktop/mobile differences and how they were
3313
3343
  * modeled as `variant` + CVA compound variants rather than as two components.
3314
3344
  */
3315
- declare function MosaicMemoryCard({ memory, variant, onEdit, onDelete, editLabel, deleteLabel, moreActionsLabel, formatScope, formatTimeAgo, formatUsageCount, formatMoreTags, className, ref, }: MosaicMemoryCardProps): React.JSX.Element;
3345
+ declare function MosaicMemoryCard(props: MosaicMemoryCardProps): React.JSX.Element;
3316
3346
  declare namespace MosaicMemoryCard {
3317
3347
  var displayName: string;
3318
3348
  }
@@ -3934,9 +3964,9 @@ interface MosaicModuleLibraryProps {
3934
3964
  tagListAddPlaceholder: string;
3935
3965
  className?: string;
3936
3966
  }
3937
- interface MosaicModuleFormProps {
3967
+ /** Props shared by both form modes — read unconditionally. */
3968
+ interface MosaicModuleFormBaseProps {
3938
3969
  item?: MosaicModuleItem;
3939
- mode: "create" | "edit";
3940
3970
  formFields?: MosaicModuleFormField[];
3941
3971
  onSave: (data: Omit<MosaicModuleItem, "id"> | MosaicModuleItem) => void;
3942
3972
  onCancel: () => void;
@@ -3949,8 +3979,6 @@ interface MosaicModuleFormProps {
3949
3979
  namePlaceholder: string;
3950
3980
  descriptionPlaceholder: string;
3951
3981
  cancelLabel: string;
3952
- saveChangesLabel: string;
3953
- createItemLabel: string;
3954
3982
  /**
3955
3983
  * Placeholder for the "add a tag" input in `tag-list` fields (used only
3956
3984
  * when the field itself doesn't set its own `placeholder`). Required,
@@ -3958,7 +3986,25 @@ interface MosaicModuleFormProps {
3958
3986
  */
3959
3987
  tagListAddPlaceholder: string;
3960
3988
  }
3961
- declare function MosaicModuleForm({ item, mode, formFields, onSave, onCancel, nameFieldLabel, descriptionFieldLabel, namePlaceholder, descriptionPlaceholder, cancelLabel, saveChangesLabel, createItemLabel, tagListAddPlaceholder, }: MosaicModuleFormProps): React.JSX.Element;
3989
+ /**
3990
+ * Discriminated union on `mode`. The submit button renders EXACTLY ONE label:
3991
+ * `createItemLabel` in "create", `saveChangesLabel` in "edit". Requiring both
3992
+ * in both modes forced every host to supply a string the form never displays —
3993
+ * a "lying prop contract", found by the `no-lying-prop-contract` guard (the
3994
+ * same defect class as MosaicMemoryCard's `formatMoreTags`). Each label now
3995
+ * lives on the branch that actually renders it.
3996
+ */
3997
+ type MosaicModuleFormModeProps = {
3998
+ mode: "create";
3999
+ /** Submit-button label in create mode. Required here — not in "edit". */
4000
+ createItemLabel: string;
4001
+ } | {
4002
+ mode: "edit";
4003
+ /** Submit-button label in edit mode. Required here — not in "create". */
4004
+ saveChangesLabel: string;
4005
+ };
4006
+ type MosaicModuleFormProps = MosaicModuleFormBaseProps & MosaicModuleFormModeProps;
4007
+ declare function MosaicModuleForm(props: MosaicModuleFormProps): React.JSX.Element;
3962
4008
  declare namespace MosaicModuleForm {
3963
4009
  var displayName: string;
3964
4010
  }
@@ -5337,4 +5383,85 @@ declare namespace MosaicUrlScraper {
5337
5383
  var displayName: string;
5338
5384
  }
5339
5385
 
5340
- export { type Breakpoint, type DeviceContextValue, type Feature3ColItem, type FeatureItem, type FooterColumn, type FooterLink, type HeroCta, type LogoItem, MosaicAccordion, MosaicAccordionItem, type MosaicAccordionItemProps, MosaicAccordionPanel, type MosaicAccordionPanelProps, type MosaicAccordionProps, MosaicAccordionTrigger, type MosaicAccordionTriggerProps, type MosaicActionAccent, type MosaicActivity, MosaicActivityFeed, type MosaicActivityFeedProps, MosaicActivityItem, type MosaicActivityItemProps, type MosaicActivityStatus, MosaicAdaptiveGrid, type MosaicAdaptiveGridProps, MosaicAdaptiveModal, type MosaicAdaptiveModalProps, MosaicAdaptiveNavigation, type MosaicAdaptiveNavigationProps, MosaicAgentCard, type MosaicAgentCardProps, MosaicAgentComposer, MosaicAgentComposerDesktop, MosaicAgentComposerMobile, type MosaicAgentComposerMobileProps, type MosaicAgentComposerProps, type MosaicAgentData, MosaicAgentList, AgentListDesktop as MosaicAgentListDesktop, AgentListMobile as MosaicAgentListMobile, type MosaicAgentListProps, type MosaicAgentPreset, MosaicAgentTeamPreview, type MosaicAgentTeamPreviewProps, MosaicAnimatedList, type MosaicAnimatedListProps, MosaicAppSidebar, type MosaicAppSidebarProps, MosaicAvatar, type MosaicAvatarProps, MosaicBadge, type MosaicBadgeProps, MosaicBlurredOrb, type MosaicBlurredOrbProps, type MosaicBreadcrumb, MosaicButton, type MosaicButtonProps, MosaicCard, MosaicCardContent, type MosaicCardContentProps, MosaicCardDescription, type MosaicCardDescriptionProps, MosaicCardFooter, type MosaicCardFooterProps, MosaicCardHeader, type MosaicCardHeaderProps, type MosaicCardProps, MosaicCardTitle, type MosaicCardTitleProps, MosaicCheckbox, type MosaicCheckboxProps, type MosaicClerkMembership, MosaicClerkOrgSwitcher, type MosaicClerkOrgSwitcherProps, type MosaicClerkOrganization, MosaicClerkWebhookHandler, type MosaicClerkWebhookHandlerOptions, MosaicCollapsible, MosaicCollapsiblePanel, type MosaicCollapsiblePanelProps, type MosaicCollapsibleProps, MosaicCollapsibleTrigger, type MosaicCollapsibleTriggerProps, MosaicCombobox, type MosaicComboboxItem, type MosaicComboboxProps, type MosaicComposerModel, type MosaicComposerModule, MosaicCounter, type MosaicCounterProps, MosaicCreateOrgDialog, type MosaicCreateOrgDialogProps, MosaicDashboardContent, type MosaicDashboardContentProps, MosaicDashboardHeader, type MosaicDashboardHeaderProps, MosaicDashboardLayout, type MosaicDashboardLayoutProps, type MosaicDashboardView, MosaicDataTable, type MosaicDataTableColumn, type MosaicDataTablePagination, type MosaicDataTableProps, MosaicDeleteConfirmationDialog, type MosaicDeleteConfirmationDialogProps, MosaicDeviceProvider, type MosaicDeviceProviderProps, MosaicDocumentUpload, type MosaicDocumentUploadFile, type MosaicDocumentUploadFileStatus, type MosaicDocumentUploadProps, MosaicDropdownMenu, type MosaicDropdownMenuItem, type MosaicDropdownMenuProps, MosaicEmptyState, type MosaicEmptyStateProps, MosaicFallingPattern, type MosaicFallingPatternProps, MosaicFeature3Col, type MosaicFeature3ColProps, MosaicFeatureCenteredMedia, type MosaicFeatureCenteredMediaProps, MosaicField, MosaicFieldControl, type MosaicFieldControlProps, MosaicFieldDescription, type MosaicFieldDescriptionProps, MosaicFieldError, type MosaicFieldErrorProps, MosaicFieldLabel, type MosaicFieldLabelProps, type MosaicFieldProps, MosaicFilterBar, type MosaicFilterBarProps, type MosaicFilterOption, MosaicFilterSidebar, type MosaicFilterSidebarProps, MosaicFooterSimple, type MosaicFooterSimpleProps, MosaicHeroSplit, type MosaicHeroSplitProps, MosaicInput, MosaicInputGroup, type MosaicInputGroupProps, type MosaicInputProps, MosaicIntegrationsBadge, type MosaicIntegrationsBadgeProps, MosaicInviteMemberDialog, type MosaicInviteMemberDialogProps, MosaicKanbanBoard, type MosaicKanbanBoardProps, MosaicKanbanColumn, type MosaicKanbanColumnProps, MosaicLogosGrid, type MosaicLogosGridProps, MosaicMainNav, type MosaicMainNavProps, type MosaicMarketplaceItem, MosaicMarketplaceList, MarketplaceListDesktop as MosaicMarketplaceListDesktop, MarketplaceListMobile as MosaicMarketplaceListMobile, type MosaicMarketplaceListProps, MosaicMemberList, type MosaicMemberListProps, MosaicMemoryCard, type MosaicMemoryCardProps, type MosaicMemoryData, type MosaicMemoryScope, type MosaicMemorySource, type MosaicMessage, MosaicMessageCard, type MosaicMessageCardProps, MosaicMessageList, MessageListDesktop as MosaicMessageListDesktop, MessageListMobile as MosaicMessageListMobile, type MosaicMessageListProps, type MosaicMessageReactions, type MosaicMessageSender, type MosaicMessageSenderType, MosaicModuleCard, type MosaicModuleCardProps, type MosaicModuleData, MosaicModuleForm, type MosaicModuleFormField, type MosaicModuleFormProps, type MosaicModuleItem, MosaicModuleLibrary, type MosaicModuleLibraryProps, type MosaicModuleType, MosaicMultiOrgIndicator, type MosaicMultiOrgIndicatorProps, MosaicMultiTenantProvider, type MosaicMultiTenantProviderProps, type MosaicNavItem, MosaicNavbar, type MosaicNavbarProps, type MosaicNavigationItem, type MosaicOrg, type MosaicOrgInfo, type MosaicOrgMember, MosaicOrgPanel, type MosaicOrgPanelProps, type MosaicOrgPanelTab, MosaicOrgProfilePage, type MosaicOrgProfilePageProps, type MosaicOrgRole, MosaicOrgRoleBadge, type MosaicOrgRoleBadgeProps, type MosaicOrgStats, MosaicOrgSwitcher, type MosaicOrgSwitcherProps, type MosaicSelectItem as MosaicPrefSelectItem, type MosaicPreference, type MosaicPreferenceGroup, MosaicPreferencesPanel, type MosaicPreferencesPanelProps, MosaicPricingCard, type MosaicPricingCardProps, type MosaicProfileField, MosaicProfilePanel, type MosaicProfilePanelProps, MosaicProgress, type MosaicProgressProps, type MosaicQuickAction$1 as MosaicQuickAction, MosaicQuickActionCard, type MosaicQuickActionCardProps, MosaicQuickActionsMenu, type MosaicQuickAction as MosaicQuickActionsMenuItem, type MosaicQuickActionsMenuProps, type MosaicQuickAgent, MosaicQuickAgentSelector, type MosaicQuickAgentSelectorProps, MosaicQuickStartPanel, type MosaicQuickStartPanelProps, MosaicRadioGroup, MosaicRadioGroupItem, type MosaicRadioGroupItemProps, type MosaicRadioGroupProps, type MosaicScenario, MosaicScrollArea, type MosaicScrollAreaProps, MosaicSelect, type MosaicSelectItem$1 as MosaicSelectItem, type MosaicSelectProps, type MosaicSelectorCategory, type MosaicSelectorItem, MosaicSelectorModal, type MosaicSelectorModalProps, MosaicSeparator, type MosaicSeparatorProps, type MosaicSidebarFooterStatus, type MosaicSidebarNavItem, type MosaicSidebarQuickAction, type MosaicSidebarRecentItem, MosaicSignInLayout, type MosaicSignInLayoutProps, MosaicSignUpLayout, type MosaicSignUpLayoutProps, MosaicSkeleton, type MosaicSkeletonProps, MosaicSlider, type MosaicSliderProps, type MosaicStatItem, MosaicStatsGrid, type MosaicStatsGridProps, type MosaicStep, MosaicStepPipeline, type MosaicStepPipelineDotsProps, type MosaicStepPipelineProps, type MosaicStepPipelineSegmentsProps, type MosaicStepStatus, MosaicSwitch, type MosaicSwitchProps, MosaicTabs, MosaicTabsList, type MosaicTabsListProps, MosaicTabsPanel, type MosaicTabsPanelProps, type MosaicTabsProps, MosaicTabsTrigger, type MosaicTabsTriggerProps, type MosaicTemplate, type MosaicTemplateAgent, MosaicTemplateCard, type MosaicTemplateCardProps, MosaicTemplateGallery, type MosaicTemplateGalleryProps, type MosaicTemplateMetadata, MosaicTemplatePreview, type MosaicTemplatePreviewProps, MosaicTestimonialsGrid, type MosaicTestimonialsGridProps, MosaicTextarea, type MosaicTextareaProps, MosaicThemeProvider, type MosaicThemeProviderProps, MosaicThemeToggle, type MosaicThemeToggleProps, MosaicTooltip, MosaicTooltipContent, type MosaicTooltipContentProps, type MosaicTooltipProps, MosaicTooltipProvider, type MosaicTooltipProviderProps, MosaicTooltipRoot, type MosaicTooltipRootProps, MosaicTooltipTrigger, type MosaicTooltipTriggerProps, MosaicUrlScraper, type MosaicUrlScraperContent, type MosaicUrlScraperProps, type MosaicUrlScraperState, MosaicUserButton, type MosaicUserButtonProps, type MosaicWorkspaceContext, type NavCta, type NavLink, type OrbPosition, type Orientation, Placeholder, type PricingCta, type SocialLink, type StatItem, type TestimonialItem, type Theme, badgeVariants, buttonVariants, skeletonVariants, useBreakpoint, useDevice, useMosaicWorkspace as useEffectiveWorkspaceId, useIsDesktop, useIsMobile, useIsTablet, useMediaQuery, useMosaicWorkspace, useOrientation, useViewport, version };
5386
+ /**
5387
+ * MosaicChatThread — presentational, auto-scrolling chat message stream
5388
+ *
5389
+ * Presentational atom. Renders a scrollable `role="log"` region that keeps
5390
+ * itself pinned to the bottom as new messages arrive — the standard "chat
5391
+ * thread" behaviour — and surfaces a "scroll to bottom" button once the
5392
+ * user has scrolled up away from the latest message. It does NOT render
5393
+ * chat messages itself: the host composes the actual message list via
5394
+ * `children` (developed in parallel as `MosaicChatMessage`). This keeps the
5395
+ * thread free of any dependency on a specific message shape.
5396
+ *
5397
+ * Local behaviour (no network/data involved, pure UI mechanics):
5398
+ * - Tracks "is the user at the bottom" via the native `scroll` event,
5399
+ * comparing `scrollHeight - scrollTop - clientHeight` against a small
5400
+ * pixel threshold (near-bottom counts as "at bottom").
5401
+ * - When `children` changes (a new message was appended) AND the user was
5402
+ * at the bottom, the container is scrolled to `scrollHeight` again —
5403
+ * the "stick to bottom" auto-anchor.
5404
+ * - When the user has scrolled up, new children arriving do NOT force a
5405
+ * scroll — the "scroll to bottom" button appears instead, and clicking
5406
+ * it scrolls back down and re-arms the auto-anchor.
5407
+ *
5408
+ * Pattern: MosaicUrlScraper.tsx (data-slot, inline cn, React 19 ref prop,
5409
+ * displayName, JSDoc, pure variants module). No icon library — uses a
5410
+ * plain "↓" glyph, matching the url-scraper convention (no lucide-react
5411
+ * runtime dependency).
5412
+ * No "use client" — prepend-use-client.mjs adds it to dist.
5413
+ * Design tokens: --border, --card, --foreground, --accent, --ring.
5414
+ * a11y: root uses `role="log"` (accessible live region for a message
5415
+ * stream) and native scrolling — no focus is trapped or stolen by the
5416
+ * auto-scroll; the "scroll to bottom" button carries a required,
5417
+ * host-supplied `aria-label`.
5418
+ * Bilingual: the only user-facing string, the scroll button's accessible
5419
+ * name, is a required prop (`scrollToBottomLabel`) — zero hardcoded copy,
5420
+ * zero default.
5421
+ *
5422
+ * Ported from any-debate-ai components/chat/conversation.tsx (rewritten
5423
+ * from scratch — no shared code, no license carried over, and no
5424
+ * `use-stick-to-bottom` runtime dependency): dropped the third-party
5425
+ * `StickToBottom` primitive and `ChatConversationContent` split (folded
5426
+ * into a single content wrapper, this library's presentational atoms don't
5427
+ * ship a separate provider/content/button trio when a single component
5428
+ * covers the same behaviour with plain scroll math), kept the scrollable
5429
+ * `role="log"` region + auto-anchor-to-bottom + "scroll to bottom" button
5430
+ * shape.
5431
+ *
5432
+ * @example
5433
+ * <MosaicChatThread scrollToBottomLabel="Revenir au dernier message">
5434
+ * {messages.map((m) => (
5435
+ * <MosaicChatMessage key={m.id} {...m} />
5436
+ * ))}
5437
+ * </MosaicChatThread>
5438
+ */
5439
+
5440
+ interface MosaicChatThreadProps {
5441
+ /** The host-rendered message list (or any other scrollable content). */
5442
+ children: React.ReactNode;
5443
+ /**
5444
+ * Accessible name for the "scroll to bottom" button, shown only once the
5445
+ * user has scrolled away from the latest message. Required, no default —
5446
+ * this is host copy, not an English fallback.
5447
+ */
5448
+ scrollToBottomLabel: string;
5449
+ /** Additional Tailwind classes on the root scrollable element. */
5450
+ className?: string;
5451
+ /** React 19 ref prop — forwarded to the root scrollable element. */
5452
+ ref?: React.Ref<HTMLDivElement>;
5453
+ }
5454
+ /**
5455
+ * MosaicChatThread — production auto-scrolling chat thread atom for
5456
+ * @vantageos/mosaic-blocks.
5457
+ *
5458
+ * Purely presentational: no data fetching, no message rendering, no
5459
+ * conversation state — the host owns the messages and passes them as
5460
+ * `children`; this component only owns the scroll mechanics.
5461
+ */
5462
+ declare function MosaicChatThread({ children, scrollToBottomLabel, className, ref, }: MosaicChatThreadProps): React.JSX.Element;
5463
+ declare namespace MosaicChatThread {
5464
+ var displayName: string;
5465
+ }
5466
+
5467
+ export { type Breakpoint, type DeviceContextValue, type Feature3ColItem, type FeatureItem, type FooterColumn, type FooterLink, type HeroCta, type LogoItem, MosaicAccordion, MosaicAccordionItem, type MosaicAccordionItemProps, MosaicAccordionPanel, type MosaicAccordionPanelProps, type MosaicAccordionProps, MosaicAccordionTrigger, type MosaicAccordionTriggerProps, type MosaicActionAccent, type MosaicActivity, MosaicActivityFeed, type MosaicActivityFeedProps, MosaicActivityItem, type MosaicActivityItemProps, type MosaicActivityStatus, MosaicAdaptiveGrid, type MosaicAdaptiveGridProps, MosaicAdaptiveModal, type MosaicAdaptiveModalProps, MosaicAdaptiveNavigation, type MosaicAdaptiveNavigationProps, MosaicAgentCard, type MosaicAgentCardProps, MosaicAgentComposer, MosaicAgentComposerDesktop, MosaicAgentComposerMobile, type MosaicAgentComposerMobileProps, type MosaicAgentComposerProps, type MosaicAgentData, MosaicAgentList, AgentListDesktop as MosaicAgentListDesktop, AgentListMobile as MosaicAgentListMobile, type MosaicAgentListProps, type MosaicAgentPreset, MosaicAgentTeamPreview, type MosaicAgentTeamPreviewProps, MosaicAnimatedList, type MosaicAnimatedListProps, MosaicAppSidebar, type MosaicAppSidebarProps, MosaicAvatar, type MosaicAvatarProps, MosaicBadge, type MosaicBadgeProps, MosaicBlurredOrb, type MosaicBlurredOrbProps, type MosaicBreadcrumb, MosaicButton, type MosaicButtonProps, MosaicCard, MosaicCardContent, type MosaicCardContentProps, MosaicCardDescription, type MosaicCardDescriptionProps, MosaicCardFooter, type MosaicCardFooterProps, MosaicCardHeader, type MosaicCardHeaderProps, type MosaicCardProps, MosaicCardTitle, type MosaicCardTitleProps, MosaicChatThread, type MosaicChatThreadProps, MosaicCheckbox, type MosaicCheckboxProps, type MosaicClerkMembership, MosaicClerkOrgSwitcher, type MosaicClerkOrgSwitcherProps, type MosaicClerkOrganization, MosaicClerkWebhookHandler, type MosaicClerkWebhookHandlerOptions, MosaicCollapsible, MosaicCollapsiblePanel, type MosaicCollapsiblePanelProps, type MosaicCollapsibleProps, MosaicCollapsibleTrigger, type MosaicCollapsibleTriggerProps, MosaicCombobox, type MosaicComboboxItem, type MosaicComboboxProps, type MosaicComposerModel, type MosaicComposerModule, MosaicCounter, type MosaicCounterProps, MosaicCreateOrgDialog, type MosaicCreateOrgDialogProps, MosaicDashboardContent, type MosaicDashboardContentProps, MosaicDashboardHeader, type MosaicDashboardHeaderProps, MosaicDashboardLayout, type MosaicDashboardLayoutProps, type MosaicDashboardView, MosaicDataTable, type MosaicDataTableColumn, type MosaicDataTablePagination, type MosaicDataTableProps, MosaicDeleteConfirmationDialog, type MosaicDeleteConfirmationDialogProps, MosaicDeviceProvider, type MosaicDeviceProviderProps, MosaicDocumentUpload, type MosaicDocumentUploadFile, type MosaicDocumentUploadFileStatus, type MosaicDocumentUploadProps, MosaicDropdownMenu, type MosaicDropdownMenuItem, type MosaicDropdownMenuProps, MosaicEmptyState, type MosaicEmptyStateProps, MosaicFallingPattern, type MosaicFallingPatternProps, MosaicFeature3Col, type MosaicFeature3ColProps, MosaicFeatureCenteredMedia, type MosaicFeatureCenteredMediaProps, MosaicField, MosaicFieldControl, type MosaicFieldControlProps, MosaicFieldDescription, type MosaicFieldDescriptionProps, MosaicFieldError, type MosaicFieldErrorProps, MosaicFieldLabel, type MosaicFieldLabelProps, type MosaicFieldProps, MosaicFilterBar, type MosaicFilterBarProps, type MosaicFilterOption, MosaicFilterSidebar, type MosaicFilterSidebarProps, MosaicFooterSimple, type MosaicFooterSimpleProps, MosaicHeroSplit, type MosaicHeroSplitProps, MosaicInput, MosaicInputGroup, type MosaicInputGroupProps, type MosaicInputProps, MosaicIntegrationsBadge, type MosaicIntegrationsBadgeProps, MosaicInviteMemberDialog, type MosaicInviteMemberDialogProps, MosaicKanbanBoard, type MosaicKanbanBoardProps, MosaicKanbanColumn, type MosaicKanbanColumnProps, MosaicLogosGrid, type MosaicLogosGridProps, MosaicMainNav, type MosaicMainNavProps, type MosaicMarketplaceItem, MosaicMarketplaceList, MarketplaceListDesktop as MosaicMarketplaceListDesktop, MarketplaceListMobile as MosaicMarketplaceListMobile, type MosaicMarketplaceListProps, MosaicMemberList, type MosaicMemberListProps, MosaicMemoryCard, type MosaicMemoryCardProps, type MosaicMemoryData, type MosaicMemoryScope, type MosaicMemorySource, type MosaicMessage, MosaicMessageCard, type MosaicMessageCardProps, MosaicMessageList, MessageListDesktop as MosaicMessageListDesktop, MessageListMobile as MosaicMessageListMobile, type MosaicMessageListProps, type MosaicMessageReactions, type MosaicMessageSender, type MosaicMessageSenderType, MosaicModuleCard, type MosaicModuleCardProps, type MosaicModuleData, MosaicModuleForm, type MosaicModuleFormField, type MosaicModuleFormProps, type MosaicModuleItem, MosaicModuleLibrary, type MosaicModuleLibraryProps, type MosaicModuleType, MosaicMultiOrgIndicator, type MosaicMultiOrgIndicatorProps, MosaicMultiTenantProvider, type MosaicMultiTenantProviderProps, type MosaicNavItem, MosaicNavbar, type MosaicNavbarProps, type MosaicNavigationItem, type MosaicOrg, type MosaicOrgInfo, type MosaicOrgMember, MosaicOrgPanel, type MosaicOrgPanelProps, type MosaicOrgPanelTab, MosaicOrgProfilePage, type MosaicOrgProfilePageProps, type MosaicOrgRole, MosaicOrgRoleBadge, type MosaicOrgRoleBadgeProps, type MosaicOrgStats, MosaicOrgSwitcher, type MosaicOrgSwitcherProps, type MosaicSelectItem as MosaicPrefSelectItem, type MosaicPreference, type MosaicPreferenceGroup, MosaicPreferencesPanel, type MosaicPreferencesPanelProps, MosaicPricingCard, type MosaicPricingCardProps, type MosaicProfileField, MosaicProfilePanel, type MosaicProfilePanelProps, MosaicProgress, type MosaicProgressProps, type MosaicQuickAction$1 as MosaicQuickAction, MosaicQuickActionCard, type MosaicQuickActionCardProps, MosaicQuickActionsMenu, type MosaicQuickAction as MosaicQuickActionsMenuItem, type MosaicQuickActionsMenuProps, type MosaicQuickAgent, MosaicQuickAgentSelector, type MosaicQuickAgentSelectorProps, MosaicQuickStartPanel, type MosaicQuickStartPanelProps, MosaicRadioGroup, MosaicRadioGroupItem, type MosaicRadioGroupItemProps, type MosaicRadioGroupProps, type MosaicScenario, MosaicScrollArea, type MosaicScrollAreaProps, MosaicSelect, type MosaicSelectItem$1 as MosaicSelectItem, type MosaicSelectProps, type MosaicSelectorCategory, type MosaicSelectorItem, MosaicSelectorModal, type MosaicSelectorModalProps, MosaicSeparator, type MosaicSeparatorProps, type MosaicSidebarFooterStatus, type MosaicSidebarNavItem, type MosaicSidebarQuickAction, type MosaicSidebarRecentItem, MosaicSignInLayout, type MosaicSignInLayoutProps, MosaicSignUpLayout, type MosaicSignUpLayoutProps, MosaicSkeleton, type MosaicSkeletonProps, MosaicSlider, type MosaicSliderProps, type MosaicStatItem, MosaicStatsGrid, type MosaicStatsGridProps, type MosaicStep, MosaicStepPipeline, type MosaicStepPipelineDotsProps, type MosaicStepPipelineProps, type MosaicStepPipelineSegmentsProps, type MosaicStepStatus, MosaicSwitch, type MosaicSwitchProps, MosaicTabs, MosaicTabsList, type MosaicTabsListProps, MosaicTabsPanel, type MosaicTabsPanelProps, type MosaicTabsProps, MosaicTabsTrigger, type MosaicTabsTriggerProps, type MosaicTemplate, type MosaicTemplateAgent, MosaicTemplateCard, type MosaicTemplateCardProps, MosaicTemplateGallery, type MosaicTemplateGalleryProps, type MosaicTemplateMetadata, MosaicTemplatePreview, type MosaicTemplatePreviewProps, MosaicTestimonialsGrid, type MosaicTestimonialsGridProps, MosaicTextarea, type MosaicTextareaProps, MosaicThemeProvider, type MosaicThemeProviderProps, MosaicThemeToggle, type MosaicThemeToggleProps, MosaicTooltip, MosaicTooltipContent, type MosaicTooltipContentProps, type MosaicTooltipProps, MosaicTooltipProvider, type MosaicTooltipProviderProps, MosaicTooltipRoot, type MosaicTooltipRootProps, MosaicTooltipTrigger, type MosaicTooltipTriggerProps, MosaicUrlScraper, type MosaicUrlScraperContent, type MosaicUrlScraperProps, type MosaicUrlScraperState, MosaicUserButton, type MosaicUserButtonProps, type MosaicWorkspaceContext, type NavCta, type NavLink, type OrbPosition, type Orientation, Placeholder, type PricingCta, type SocialLink, type StatItem, type TestimonialItem, type Theme, badgeVariants, buttonVariants, skeletonVariants, useBreakpoint, useDevice, useMosaicWorkspace as useEffectiveWorkspaceId, useIsDesktop, useIsMobile, useIsTablet, useMediaQuery, useMosaicWorkspace, useOrientation, useViewport, version };
package/dist/index.d.ts CHANGED
@@ -20,7 +20,7 @@ import { Switch } from '@base-ui/react/switch';
20
20
  export { Tooltip } from '@base-ui/react/tooltip';
21
21
  import 'class-variance-authority/types';
22
22
 
23
- declare const version = "0.4.8-alpha";
23
+ declare const version = "0.5.1-alpha";
24
24
 
25
25
  /**
26
26
  * Placeholder component — infra scaffold only.
@@ -2675,7 +2675,6 @@ interface MosaicAgentComposerProps {
2675
2675
  previewConfigLabel: string;
2676
2676
  customInstructionsPreviewLabel: string;
2677
2677
  selectAllModulesLabel: string;
2678
- requiredLabel: string;
2679
2678
  /** Fallback name shown in the preview when `agentName` is empty. Required, no default. */
2680
2679
  unnamedAgentLabel: string;
2681
2680
  }
@@ -2712,6 +2711,13 @@ declare namespace MosaicAgentComposerDesktop {
2712
2711
  interface MosaicAgentComposerMobileProps extends MosaicAgentComposerProps {
2713
2712
  /** Show loading state on submit button */
2714
2713
  isLoading?: boolean;
2714
+ /**
2715
+ * "Required" marker shown on a mandatory module slot. Declared HERE, not on
2716
+ * the shared MosaicAgentComposerProps, because only the mobile composer
2717
+ * renders it — the desktop one never does. (Moved by the
2718
+ * no-lying-prop-contract guard: a prop is required exactly where it is read.)
2719
+ */
2720
+ requiredLabel: string;
2715
2721
  /**
2716
2722
  * Required host-owned strings (mobile-only extras) — no default,
2717
2723
  * no fallback. The host owns the language (e.g. next-intl `t()`).
@@ -2881,10 +2887,6 @@ interface MosaicDeleteConfirmationDialogProps {
2881
2887
  onOpenChange: (open: boolean) => void;
2882
2888
  /** Called when the user confirms deletion */
2883
2889
  onConfirm: () => void;
2884
- /** Human-readable name of the item to be deleted */
2885
- itemName: string;
2886
- /** Type label shown in the title and button ("agent", "template", etc.). Required, no default. */
2887
- itemType: string;
2888
2890
  /** Dialog title. Required — the host owns the language, no default. */
2889
2891
  title: string;
2890
2892
  /** Dialog description. Required — the host owns the language, no default. */
@@ -3212,6 +3214,15 @@ declare namespace MosaicQuickAgentSelector {
3212
3214
  * required prop or a required formatter function — no optional prop with an
3213
3215
  * English default anywhere in this file.
3214
3216
  *
3217
+ * Props are pushed into the `MosaicMemoryCardVariantProps` discriminated
3218
+ * union exactly where they are read — no prop is required on a variant that
3219
+ * never renders it. `formatMoreTags` is required only on the `"detailed"`
3220
+ * (default) member: the `"compact"` variant drops the tags row entirely and
3221
+ * never calls it, so it is not part of `"compact"`'s member of the union
3222
+ * (fixed after being flagged as a "lying prop contract" by the
3223
+ * `no-lying-prop-contract` guard test — see that file and the memory-card's
3224
+ * own type definitions below).
3225
+ *
3215
3226
  * Closes T1 (bu-mcp memory wave) — mosaic-memory-card.
3216
3227
  *
3217
3228
  * @example
@@ -3258,15 +3269,12 @@ interface MosaicMemoryData {
3258
3269
  createdAt: number;
3259
3270
  usageCount: number;
3260
3271
  }
3261
- interface MosaicMemoryCardProps {
3272
+ /**
3273
+ * Props shared by both variants — read unconditionally regardless of
3274
+ * `variant`.
3275
+ */
3276
+ interface MosaicMemoryCardBaseProps {
3262
3277
  memory: MosaicMemoryData;
3263
- /**
3264
- * Layout density.
3265
- * - `"detailed"` (default): icon chip + tags row + labelled usage footer.
3266
- * - `"compact"`: condensed header row, no tags row, raw usage number.
3267
- * @default "detailed"
3268
- */
3269
- variant?: "detailed" | "compact";
3270
3278
  onEdit?: (memory: MosaicMemoryData) => void;
3271
3279
  onDelete?: (memoryId: string) => void;
3272
3280
  /** Label for the "edit" menu item. Required — host-owned, no default. */
@@ -3295,16 +3303,38 @@ interface MosaicMemoryCardProps {
3295
3303
  * Required — host-owned (e.g. `(count) => t("memory.usageCount", { count })`).
3296
3304
  */
3297
3305
  formatUsageCount: (count: number) => React.ReactNode;
3298
- /**
3299
- * Formatter producing the "+N" overflow caption when a memory has more
3300
- * than 3 tags. Only rendered in the detailed variant. Required —
3301
- * host-owned (e.g. `(count) => \`+\${count}\`` or a pluralized `t()` call).
3302
- */
3303
- formatMoreTags: (count: number) => React.ReactNode;
3304
3306
  className?: string;
3305
3307
  /** React 19 ref prop — forwarded to the root element. */
3306
3308
  ref?: React.Ref<HTMLDivElement>;
3307
3309
  }
3310
+ /**
3311
+ * Discriminated union on `variant` — the sole property that differs between
3312
+ * variants (`formatMoreTags`) is required EXACTLY on the branch that reads
3313
+ * it (`"detailed"`, the default), not on the shared base. The `"compact"`
3314
+ * variant never renders a tags row and therefore never calls
3315
+ * `formatMoreTags` — requiring it there would force every host to supply a
3316
+ * value the library never displays (a "lying prop contract"; see the
3317
+ * `no-lying-prop-contract` guard test and the file's changelog note below).
3318
+ */
3319
+ type MosaicMemoryCardVariantProps = {
3320
+ /**
3321
+ * Full-density layout: icon chip + tags row + labelled usage footer.
3322
+ * Default when omitted.
3323
+ * @default "detailed"
3324
+ */
3325
+ variant?: "detailed";
3326
+ /**
3327
+ * Formatter producing the "+N" overflow caption when a memory has more
3328
+ * than 3 tags. Only ever rendered in the detailed variant — required
3329
+ * here, not on `"compact"`. Host-owned (e.g. `(count) => \`+\${count}\``
3330
+ * or a pluralized `t()` call).
3331
+ */
3332
+ formatMoreTags: (count: number) => React.ReactNode;
3333
+ } | {
3334
+ /** Condensed list row, no tags row, no `formatMoreTags` call. */
3335
+ variant: "compact";
3336
+ };
3337
+ type MosaicMemoryCardProps = MosaicMemoryCardBaseProps & MosaicMemoryCardVariantProps;
3308
3338
  /**
3309
3339
  * MosaicMemoryCard — production memory-item card for @vantageos/mosaic-blocks.
3310
3340
  *
@@ -3312,7 +3342,7 @@ interface MosaicMemoryCardProps {
3312
3342
  * see file JSDoc for the exact desktop/mobile differences and how they were
3313
3343
  * modeled as `variant` + CVA compound variants rather than as two components.
3314
3344
  */
3315
- declare function MosaicMemoryCard({ memory, variant, onEdit, onDelete, editLabel, deleteLabel, moreActionsLabel, formatScope, formatTimeAgo, formatUsageCount, formatMoreTags, className, ref, }: MosaicMemoryCardProps): React.JSX.Element;
3345
+ declare function MosaicMemoryCard(props: MosaicMemoryCardProps): React.JSX.Element;
3316
3346
  declare namespace MosaicMemoryCard {
3317
3347
  var displayName: string;
3318
3348
  }
@@ -3934,9 +3964,9 @@ interface MosaicModuleLibraryProps {
3934
3964
  tagListAddPlaceholder: string;
3935
3965
  className?: string;
3936
3966
  }
3937
- interface MosaicModuleFormProps {
3967
+ /** Props shared by both form modes — read unconditionally. */
3968
+ interface MosaicModuleFormBaseProps {
3938
3969
  item?: MosaicModuleItem;
3939
- mode: "create" | "edit";
3940
3970
  formFields?: MosaicModuleFormField[];
3941
3971
  onSave: (data: Omit<MosaicModuleItem, "id"> | MosaicModuleItem) => void;
3942
3972
  onCancel: () => void;
@@ -3949,8 +3979,6 @@ interface MosaicModuleFormProps {
3949
3979
  namePlaceholder: string;
3950
3980
  descriptionPlaceholder: string;
3951
3981
  cancelLabel: string;
3952
- saveChangesLabel: string;
3953
- createItemLabel: string;
3954
3982
  /**
3955
3983
  * Placeholder for the "add a tag" input in `tag-list` fields (used only
3956
3984
  * when the field itself doesn't set its own `placeholder`). Required,
@@ -3958,7 +3986,25 @@ interface MosaicModuleFormProps {
3958
3986
  */
3959
3987
  tagListAddPlaceholder: string;
3960
3988
  }
3961
- declare function MosaicModuleForm({ item, mode, formFields, onSave, onCancel, nameFieldLabel, descriptionFieldLabel, namePlaceholder, descriptionPlaceholder, cancelLabel, saveChangesLabel, createItemLabel, tagListAddPlaceholder, }: MosaicModuleFormProps): React.JSX.Element;
3989
+ /**
3990
+ * Discriminated union on `mode`. The submit button renders EXACTLY ONE label:
3991
+ * `createItemLabel` in "create", `saveChangesLabel` in "edit". Requiring both
3992
+ * in both modes forced every host to supply a string the form never displays —
3993
+ * a "lying prop contract", found by the `no-lying-prop-contract` guard (the
3994
+ * same defect class as MosaicMemoryCard's `formatMoreTags`). Each label now
3995
+ * lives on the branch that actually renders it.
3996
+ */
3997
+ type MosaicModuleFormModeProps = {
3998
+ mode: "create";
3999
+ /** Submit-button label in create mode. Required here — not in "edit". */
4000
+ createItemLabel: string;
4001
+ } | {
4002
+ mode: "edit";
4003
+ /** Submit-button label in edit mode. Required here — not in "create". */
4004
+ saveChangesLabel: string;
4005
+ };
4006
+ type MosaicModuleFormProps = MosaicModuleFormBaseProps & MosaicModuleFormModeProps;
4007
+ declare function MosaicModuleForm(props: MosaicModuleFormProps): React.JSX.Element;
3962
4008
  declare namespace MosaicModuleForm {
3963
4009
  var displayName: string;
3964
4010
  }
@@ -5337,4 +5383,85 @@ declare namespace MosaicUrlScraper {
5337
5383
  var displayName: string;
5338
5384
  }
5339
5385
 
5340
- export { type Breakpoint, type DeviceContextValue, type Feature3ColItem, type FeatureItem, type FooterColumn, type FooterLink, type HeroCta, type LogoItem, MosaicAccordion, MosaicAccordionItem, type MosaicAccordionItemProps, MosaicAccordionPanel, type MosaicAccordionPanelProps, type MosaicAccordionProps, MosaicAccordionTrigger, type MosaicAccordionTriggerProps, type MosaicActionAccent, type MosaicActivity, MosaicActivityFeed, type MosaicActivityFeedProps, MosaicActivityItem, type MosaicActivityItemProps, type MosaicActivityStatus, MosaicAdaptiveGrid, type MosaicAdaptiveGridProps, MosaicAdaptiveModal, type MosaicAdaptiveModalProps, MosaicAdaptiveNavigation, type MosaicAdaptiveNavigationProps, MosaicAgentCard, type MosaicAgentCardProps, MosaicAgentComposer, MosaicAgentComposerDesktop, MosaicAgentComposerMobile, type MosaicAgentComposerMobileProps, type MosaicAgentComposerProps, type MosaicAgentData, MosaicAgentList, AgentListDesktop as MosaicAgentListDesktop, AgentListMobile as MosaicAgentListMobile, type MosaicAgentListProps, type MosaicAgentPreset, MosaicAgentTeamPreview, type MosaicAgentTeamPreviewProps, MosaicAnimatedList, type MosaicAnimatedListProps, MosaicAppSidebar, type MosaicAppSidebarProps, MosaicAvatar, type MosaicAvatarProps, MosaicBadge, type MosaicBadgeProps, MosaicBlurredOrb, type MosaicBlurredOrbProps, type MosaicBreadcrumb, MosaicButton, type MosaicButtonProps, MosaicCard, MosaicCardContent, type MosaicCardContentProps, MosaicCardDescription, type MosaicCardDescriptionProps, MosaicCardFooter, type MosaicCardFooterProps, MosaicCardHeader, type MosaicCardHeaderProps, type MosaicCardProps, MosaicCardTitle, type MosaicCardTitleProps, MosaicCheckbox, type MosaicCheckboxProps, type MosaicClerkMembership, MosaicClerkOrgSwitcher, type MosaicClerkOrgSwitcherProps, type MosaicClerkOrganization, MosaicClerkWebhookHandler, type MosaicClerkWebhookHandlerOptions, MosaicCollapsible, MosaicCollapsiblePanel, type MosaicCollapsiblePanelProps, type MosaicCollapsibleProps, MosaicCollapsibleTrigger, type MosaicCollapsibleTriggerProps, MosaicCombobox, type MosaicComboboxItem, type MosaicComboboxProps, type MosaicComposerModel, type MosaicComposerModule, MosaicCounter, type MosaicCounterProps, MosaicCreateOrgDialog, type MosaicCreateOrgDialogProps, MosaicDashboardContent, type MosaicDashboardContentProps, MosaicDashboardHeader, type MosaicDashboardHeaderProps, MosaicDashboardLayout, type MosaicDashboardLayoutProps, type MosaicDashboardView, MosaicDataTable, type MosaicDataTableColumn, type MosaicDataTablePagination, type MosaicDataTableProps, MosaicDeleteConfirmationDialog, type MosaicDeleteConfirmationDialogProps, MosaicDeviceProvider, type MosaicDeviceProviderProps, MosaicDocumentUpload, type MosaicDocumentUploadFile, type MosaicDocumentUploadFileStatus, type MosaicDocumentUploadProps, MosaicDropdownMenu, type MosaicDropdownMenuItem, type MosaicDropdownMenuProps, MosaicEmptyState, type MosaicEmptyStateProps, MosaicFallingPattern, type MosaicFallingPatternProps, MosaicFeature3Col, type MosaicFeature3ColProps, MosaicFeatureCenteredMedia, type MosaicFeatureCenteredMediaProps, MosaicField, MosaicFieldControl, type MosaicFieldControlProps, MosaicFieldDescription, type MosaicFieldDescriptionProps, MosaicFieldError, type MosaicFieldErrorProps, MosaicFieldLabel, type MosaicFieldLabelProps, type MosaicFieldProps, MosaicFilterBar, type MosaicFilterBarProps, type MosaicFilterOption, MosaicFilterSidebar, type MosaicFilterSidebarProps, MosaicFooterSimple, type MosaicFooterSimpleProps, MosaicHeroSplit, type MosaicHeroSplitProps, MosaicInput, MosaicInputGroup, type MosaicInputGroupProps, type MosaicInputProps, MosaicIntegrationsBadge, type MosaicIntegrationsBadgeProps, MosaicInviteMemberDialog, type MosaicInviteMemberDialogProps, MosaicKanbanBoard, type MosaicKanbanBoardProps, MosaicKanbanColumn, type MosaicKanbanColumnProps, MosaicLogosGrid, type MosaicLogosGridProps, MosaicMainNav, type MosaicMainNavProps, type MosaicMarketplaceItem, MosaicMarketplaceList, MarketplaceListDesktop as MosaicMarketplaceListDesktop, MarketplaceListMobile as MosaicMarketplaceListMobile, type MosaicMarketplaceListProps, MosaicMemberList, type MosaicMemberListProps, MosaicMemoryCard, type MosaicMemoryCardProps, type MosaicMemoryData, type MosaicMemoryScope, type MosaicMemorySource, type MosaicMessage, MosaicMessageCard, type MosaicMessageCardProps, MosaicMessageList, MessageListDesktop as MosaicMessageListDesktop, MessageListMobile as MosaicMessageListMobile, type MosaicMessageListProps, type MosaicMessageReactions, type MosaicMessageSender, type MosaicMessageSenderType, MosaicModuleCard, type MosaicModuleCardProps, type MosaicModuleData, MosaicModuleForm, type MosaicModuleFormField, type MosaicModuleFormProps, type MosaicModuleItem, MosaicModuleLibrary, type MosaicModuleLibraryProps, type MosaicModuleType, MosaicMultiOrgIndicator, type MosaicMultiOrgIndicatorProps, MosaicMultiTenantProvider, type MosaicMultiTenantProviderProps, type MosaicNavItem, MosaicNavbar, type MosaicNavbarProps, type MosaicNavigationItem, type MosaicOrg, type MosaicOrgInfo, type MosaicOrgMember, MosaicOrgPanel, type MosaicOrgPanelProps, type MosaicOrgPanelTab, MosaicOrgProfilePage, type MosaicOrgProfilePageProps, type MosaicOrgRole, MosaicOrgRoleBadge, type MosaicOrgRoleBadgeProps, type MosaicOrgStats, MosaicOrgSwitcher, type MosaicOrgSwitcherProps, type MosaicSelectItem as MosaicPrefSelectItem, type MosaicPreference, type MosaicPreferenceGroup, MosaicPreferencesPanel, type MosaicPreferencesPanelProps, MosaicPricingCard, type MosaicPricingCardProps, type MosaicProfileField, MosaicProfilePanel, type MosaicProfilePanelProps, MosaicProgress, type MosaicProgressProps, type MosaicQuickAction$1 as MosaicQuickAction, MosaicQuickActionCard, type MosaicQuickActionCardProps, MosaicQuickActionsMenu, type MosaicQuickAction as MosaicQuickActionsMenuItem, type MosaicQuickActionsMenuProps, type MosaicQuickAgent, MosaicQuickAgentSelector, type MosaicQuickAgentSelectorProps, MosaicQuickStartPanel, type MosaicQuickStartPanelProps, MosaicRadioGroup, MosaicRadioGroupItem, type MosaicRadioGroupItemProps, type MosaicRadioGroupProps, type MosaicScenario, MosaicScrollArea, type MosaicScrollAreaProps, MosaicSelect, type MosaicSelectItem$1 as MosaicSelectItem, type MosaicSelectProps, type MosaicSelectorCategory, type MosaicSelectorItem, MosaicSelectorModal, type MosaicSelectorModalProps, MosaicSeparator, type MosaicSeparatorProps, type MosaicSidebarFooterStatus, type MosaicSidebarNavItem, type MosaicSidebarQuickAction, type MosaicSidebarRecentItem, MosaicSignInLayout, type MosaicSignInLayoutProps, MosaicSignUpLayout, type MosaicSignUpLayoutProps, MosaicSkeleton, type MosaicSkeletonProps, MosaicSlider, type MosaicSliderProps, type MosaicStatItem, MosaicStatsGrid, type MosaicStatsGridProps, type MosaicStep, MosaicStepPipeline, type MosaicStepPipelineDotsProps, type MosaicStepPipelineProps, type MosaicStepPipelineSegmentsProps, type MosaicStepStatus, MosaicSwitch, type MosaicSwitchProps, MosaicTabs, MosaicTabsList, type MosaicTabsListProps, MosaicTabsPanel, type MosaicTabsPanelProps, type MosaicTabsProps, MosaicTabsTrigger, type MosaicTabsTriggerProps, type MosaicTemplate, type MosaicTemplateAgent, MosaicTemplateCard, type MosaicTemplateCardProps, MosaicTemplateGallery, type MosaicTemplateGalleryProps, type MosaicTemplateMetadata, MosaicTemplatePreview, type MosaicTemplatePreviewProps, MosaicTestimonialsGrid, type MosaicTestimonialsGridProps, MosaicTextarea, type MosaicTextareaProps, MosaicThemeProvider, type MosaicThemeProviderProps, MosaicThemeToggle, type MosaicThemeToggleProps, MosaicTooltip, MosaicTooltipContent, type MosaicTooltipContentProps, type MosaicTooltipProps, MosaicTooltipProvider, type MosaicTooltipProviderProps, MosaicTooltipRoot, type MosaicTooltipRootProps, MosaicTooltipTrigger, type MosaicTooltipTriggerProps, MosaicUrlScraper, type MosaicUrlScraperContent, type MosaicUrlScraperProps, type MosaicUrlScraperState, MosaicUserButton, type MosaicUserButtonProps, type MosaicWorkspaceContext, type NavCta, type NavLink, type OrbPosition, type Orientation, Placeholder, type PricingCta, type SocialLink, type StatItem, type TestimonialItem, type Theme, badgeVariants, buttonVariants, skeletonVariants, useBreakpoint, useDevice, useMosaicWorkspace as useEffectiveWorkspaceId, useIsDesktop, useIsMobile, useIsTablet, useMediaQuery, useMosaicWorkspace, useOrientation, useViewport, version };
5386
+ /**
5387
+ * MosaicChatThread — presentational, auto-scrolling chat message stream
5388
+ *
5389
+ * Presentational atom. Renders a scrollable `role="log"` region that keeps
5390
+ * itself pinned to the bottom as new messages arrive — the standard "chat
5391
+ * thread" behaviour — and surfaces a "scroll to bottom" button once the
5392
+ * user has scrolled up away from the latest message. It does NOT render
5393
+ * chat messages itself: the host composes the actual message list via
5394
+ * `children` (developed in parallel as `MosaicChatMessage`). This keeps the
5395
+ * thread free of any dependency on a specific message shape.
5396
+ *
5397
+ * Local behaviour (no network/data involved, pure UI mechanics):
5398
+ * - Tracks "is the user at the bottom" via the native `scroll` event,
5399
+ * comparing `scrollHeight - scrollTop - clientHeight` against a small
5400
+ * pixel threshold (near-bottom counts as "at bottom").
5401
+ * - When `children` changes (a new message was appended) AND the user was
5402
+ * at the bottom, the container is scrolled to `scrollHeight` again —
5403
+ * the "stick to bottom" auto-anchor.
5404
+ * - When the user has scrolled up, new children arriving do NOT force a
5405
+ * scroll — the "scroll to bottom" button appears instead, and clicking
5406
+ * it scrolls back down and re-arms the auto-anchor.
5407
+ *
5408
+ * Pattern: MosaicUrlScraper.tsx (data-slot, inline cn, React 19 ref prop,
5409
+ * displayName, JSDoc, pure variants module). No icon library — uses a
5410
+ * plain "↓" glyph, matching the url-scraper convention (no lucide-react
5411
+ * runtime dependency).
5412
+ * No "use client" — prepend-use-client.mjs adds it to dist.
5413
+ * Design tokens: --border, --card, --foreground, --accent, --ring.
5414
+ * a11y: root uses `role="log"` (accessible live region for a message
5415
+ * stream) and native scrolling — no focus is trapped or stolen by the
5416
+ * auto-scroll; the "scroll to bottom" button carries a required,
5417
+ * host-supplied `aria-label`.
5418
+ * Bilingual: the only user-facing string, the scroll button's accessible
5419
+ * name, is a required prop (`scrollToBottomLabel`) — zero hardcoded copy,
5420
+ * zero default.
5421
+ *
5422
+ * Ported from any-debate-ai components/chat/conversation.tsx (rewritten
5423
+ * from scratch — no shared code, no license carried over, and no
5424
+ * `use-stick-to-bottom` runtime dependency): dropped the third-party
5425
+ * `StickToBottom` primitive and `ChatConversationContent` split (folded
5426
+ * into a single content wrapper, this library's presentational atoms don't
5427
+ * ship a separate provider/content/button trio when a single component
5428
+ * covers the same behaviour with plain scroll math), kept the scrollable
5429
+ * `role="log"` region + auto-anchor-to-bottom + "scroll to bottom" button
5430
+ * shape.
5431
+ *
5432
+ * @example
5433
+ * <MosaicChatThread scrollToBottomLabel="Revenir au dernier message">
5434
+ * {messages.map((m) => (
5435
+ * <MosaicChatMessage key={m.id} {...m} />
5436
+ * ))}
5437
+ * </MosaicChatThread>
5438
+ */
5439
+
5440
+ interface MosaicChatThreadProps {
5441
+ /** The host-rendered message list (or any other scrollable content). */
5442
+ children: React.ReactNode;
5443
+ /**
5444
+ * Accessible name for the "scroll to bottom" button, shown only once the
5445
+ * user has scrolled away from the latest message. Required, no default —
5446
+ * this is host copy, not an English fallback.
5447
+ */
5448
+ scrollToBottomLabel: string;
5449
+ /** Additional Tailwind classes on the root scrollable element. */
5450
+ className?: string;
5451
+ /** React 19 ref prop — forwarded to the root scrollable element. */
5452
+ ref?: React.Ref<HTMLDivElement>;
5453
+ }
5454
+ /**
5455
+ * MosaicChatThread — production auto-scrolling chat thread atom for
5456
+ * @vantageos/mosaic-blocks.
5457
+ *
5458
+ * Purely presentational: no data fetching, no message rendering, no
5459
+ * conversation state — the host owns the messages and passes them as
5460
+ * `children`; this component only owns the scroll mechanics.
5461
+ */
5462
+ declare function MosaicChatThread({ children, scrollToBottomLabel, className, ref, }: MosaicChatThreadProps): React.JSX.Element;
5463
+ declare namespace MosaicChatThread {
5464
+ var displayName: string;
5465
+ }
5466
+
5467
+ export { type Breakpoint, type DeviceContextValue, type Feature3ColItem, type FeatureItem, type FooterColumn, type FooterLink, type HeroCta, type LogoItem, MosaicAccordion, MosaicAccordionItem, type MosaicAccordionItemProps, MosaicAccordionPanel, type MosaicAccordionPanelProps, type MosaicAccordionProps, MosaicAccordionTrigger, type MosaicAccordionTriggerProps, type MosaicActionAccent, type MosaicActivity, MosaicActivityFeed, type MosaicActivityFeedProps, MosaicActivityItem, type MosaicActivityItemProps, type MosaicActivityStatus, MosaicAdaptiveGrid, type MosaicAdaptiveGridProps, MosaicAdaptiveModal, type MosaicAdaptiveModalProps, MosaicAdaptiveNavigation, type MosaicAdaptiveNavigationProps, MosaicAgentCard, type MosaicAgentCardProps, MosaicAgentComposer, MosaicAgentComposerDesktop, MosaicAgentComposerMobile, type MosaicAgentComposerMobileProps, type MosaicAgentComposerProps, type MosaicAgentData, MosaicAgentList, AgentListDesktop as MosaicAgentListDesktop, AgentListMobile as MosaicAgentListMobile, type MosaicAgentListProps, type MosaicAgentPreset, MosaicAgentTeamPreview, type MosaicAgentTeamPreviewProps, MosaicAnimatedList, type MosaicAnimatedListProps, MosaicAppSidebar, type MosaicAppSidebarProps, MosaicAvatar, type MosaicAvatarProps, MosaicBadge, type MosaicBadgeProps, MosaicBlurredOrb, type MosaicBlurredOrbProps, type MosaicBreadcrumb, MosaicButton, type MosaicButtonProps, MosaicCard, MosaicCardContent, type MosaicCardContentProps, MosaicCardDescription, type MosaicCardDescriptionProps, MosaicCardFooter, type MosaicCardFooterProps, MosaicCardHeader, type MosaicCardHeaderProps, type MosaicCardProps, MosaicCardTitle, type MosaicCardTitleProps, MosaicChatThread, type MosaicChatThreadProps, MosaicCheckbox, type MosaicCheckboxProps, type MosaicClerkMembership, MosaicClerkOrgSwitcher, type MosaicClerkOrgSwitcherProps, type MosaicClerkOrganization, MosaicClerkWebhookHandler, type MosaicClerkWebhookHandlerOptions, MosaicCollapsible, MosaicCollapsiblePanel, type MosaicCollapsiblePanelProps, type MosaicCollapsibleProps, MosaicCollapsibleTrigger, type MosaicCollapsibleTriggerProps, MosaicCombobox, type MosaicComboboxItem, type MosaicComboboxProps, type MosaicComposerModel, type MosaicComposerModule, MosaicCounter, type MosaicCounterProps, MosaicCreateOrgDialog, type MosaicCreateOrgDialogProps, MosaicDashboardContent, type MosaicDashboardContentProps, MosaicDashboardHeader, type MosaicDashboardHeaderProps, MosaicDashboardLayout, type MosaicDashboardLayoutProps, type MosaicDashboardView, MosaicDataTable, type MosaicDataTableColumn, type MosaicDataTablePagination, type MosaicDataTableProps, MosaicDeleteConfirmationDialog, type MosaicDeleteConfirmationDialogProps, MosaicDeviceProvider, type MosaicDeviceProviderProps, MosaicDocumentUpload, type MosaicDocumentUploadFile, type MosaicDocumentUploadFileStatus, type MosaicDocumentUploadProps, MosaicDropdownMenu, type MosaicDropdownMenuItem, type MosaicDropdownMenuProps, MosaicEmptyState, type MosaicEmptyStateProps, MosaicFallingPattern, type MosaicFallingPatternProps, MosaicFeature3Col, type MosaicFeature3ColProps, MosaicFeatureCenteredMedia, type MosaicFeatureCenteredMediaProps, MosaicField, MosaicFieldControl, type MosaicFieldControlProps, MosaicFieldDescription, type MosaicFieldDescriptionProps, MosaicFieldError, type MosaicFieldErrorProps, MosaicFieldLabel, type MosaicFieldLabelProps, type MosaicFieldProps, MosaicFilterBar, type MosaicFilterBarProps, type MosaicFilterOption, MosaicFilterSidebar, type MosaicFilterSidebarProps, MosaicFooterSimple, type MosaicFooterSimpleProps, MosaicHeroSplit, type MosaicHeroSplitProps, MosaicInput, MosaicInputGroup, type MosaicInputGroupProps, type MosaicInputProps, MosaicIntegrationsBadge, type MosaicIntegrationsBadgeProps, MosaicInviteMemberDialog, type MosaicInviteMemberDialogProps, MosaicKanbanBoard, type MosaicKanbanBoardProps, MosaicKanbanColumn, type MosaicKanbanColumnProps, MosaicLogosGrid, type MosaicLogosGridProps, MosaicMainNav, type MosaicMainNavProps, type MosaicMarketplaceItem, MosaicMarketplaceList, MarketplaceListDesktop as MosaicMarketplaceListDesktop, MarketplaceListMobile as MosaicMarketplaceListMobile, type MosaicMarketplaceListProps, MosaicMemberList, type MosaicMemberListProps, MosaicMemoryCard, type MosaicMemoryCardProps, type MosaicMemoryData, type MosaicMemoryScope, type MosaicMemorySource, type MosaicMessage, MosaicMessageCard, type MosaicMessageCardProps, MosaicMessageList, MessageListDesktop as MosaicMessageListDesktop, MessageListMobile as MosaicMessageListMobile, type MosaicMessageListProps, type MosaicMessageReactions, type MosaicMessageSender, type MosaicMessageSenderType, MosaicModuleCard, type MosaicModuleCardProps, type MosaicModuleData, MosaicModuleForm, type MosaicModuleFormField, type MosaicModuleFormProps, type MosaicModuleItem, MosaicModuleLibrary, type MosaicModuleLibraryProps, type MosaicModuleType, MosaicMultiOrgIndicator, type MosaicMultiOrgIndicatorProps, MosaicMultiTenantProvider, type MosaicMultiTenantProviderProps, type MosaicNavItem, MosaicNavbar, type MosaicNavbarProps, type MosaicNavigationItem, type MosaicOrg, type MosaicOrgInfo, type MosaicOrgMember, MosaicOrgPanel, type MosaicOrgPanelProps, type MosaicOrgPanelTab, MosaicOrgProfilePage, type MosaicOrgProfilePageProps, type MosaicOrgRole, MosaicOrgRoleBadge, type MosaicOrgRoleBadgeProps, type MosaicOrgStats, MosaicOrgSwitcher, type MosaicOrgSwitcherProps, type MosaicSelectItem as MosaicPrefSelectItem, type MosaicPreference, type MosaicPreferenceGroup, MosaicPreferencesPanel, type MosaicPreferencesPanelProps, MosaicPricingCard, type MosaicPricingCardProps, type MosaicProfileField, MosaicProfilePanel, type MosaicProfilePanelProps, MosaicProgress, type MosaicProgressProps, type MosaicQuickAction$1 as MosaicQuickAction, MosaicQuickActionCard, type MosaicQuickActionCardProps, MosaicQuickActionsMenu, type MosaicQuickAction as MosaicQuickActionsMenuItem, type MosaicQuickActionsMenuProps, type MosaicQuickAgent, MosaicQuickAgentSelector, type MosaicQuickAgentSelectorProps, MosaicQuickStartPanel, type MosaicQuickStartPanelProps, MosaicRadioGroup, MosaicRadioGroupItem, type MosaicRadioGroupItemProps, type MosaicRadioGroupProps, type MosaicScenario, MosaicScrollArea, type MosaicScrollAreaProps, MosaicSelect, type MosaicSelectItem$1 as MosaicSelectItem, type MosaicSelectProps, type MosaicSelectorCategory, type MosaicSelectorItem, MosaicSelectorModal, type MosaicSelectorModalProps, MosaicSeparator, type MosaicSeparatorProps, type MosaicSidebarFooterStatus, type MosaicSidebarNavItem, type MosaicSidebarQuickAction, type MosaicSidebarRecentItem, MosaicSignInLayout, type MosaicSignInLayoutProps, MosaicSignUpLayout, type MosaicSignUpLayoutProps, MosaicSkeleton, type MosaicSkeletonProps, MosaicSlider, type MosaicSliderProps, type MosaicStatItem, MosaicStatsGrid, type MosaicStatsGridProps, type MosaicStep, MosaicStepPipeline, type MosaicStepPipelineDotsProps, type MosaicStepPipelineProps, type MosaicStepPipelineSegmentsProps, type MosaicStepStatus, MosaicSwitch, type MosaicSwitchProps, MosaicTabs, MosaicTabsList, type MosaicTabsListProps, MosaicTabsPanel, type MosaicTabsPanelProps, type MosaicTabsProps, MosaicTabsTrigger, type MosaicTabsTriggerProps, type MosaicTemplate, type MosaicTemplateAgent, MosaicTemplateCard, type MosaicTemplateCardProps, MosaicTemplateGallery, type MosaicTemplateGalleryProps, type MosaicTemplateMetadata, MosaicTemplatePreview, type MosaicTemplatePreviewProps, MosaicTestimonialsGrid, type MosaicTestimonialsGridProps, MosaicTextarea, type MosaicTextareaProps, MosaicThemeProvider, type MosaicThemeProviderProps, MosaicThemeToggle, type MosaicThemeToggleProps, MosaicTooltip, MosaicTooltipContent, type MosaicTooltipContentProps, type MosaicTooltipProps, MosaicTooltipProvider, type MosaicTooltipProviderProps, MosaicTooltipRoot, type MosaicTooltipRootProps, MosaicTooltipTrigger, type MosaicTooltipTriggerProps, MosaicUrlScraper, type MosaicUrlScraperContent, type MosaicUrlScraperProps, type MosaicUrlScraperState, MosaicUserButton, type MosaicUserButtonProps, type MosaicWorkspaceContext, type NavCta, type NavLink, type OrbPosition, type Orientation, Placeholder, type PricingCta, type SocialLink, type StatItem, type TestimonialItem, type Theme, badgeVariants, buttonVariants, skeletonVariants, useBreakpoint, useDevice, useMosaicWorkspace as useEffectiveWorkspaceId, useIsDesktop, useIsMobile, useIsTablet, useMediaQuery, useMosaicWorkspace, useOrientation, useViewport, version };