@streamoid/ui 0.4.7 → 0.4.9

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.css CHANGED
@@ -3737,81 +3737,27 @@
3737
3737
  flex-shrink: 0;
3738
3738
  color: var(--alias-text-and-icons-tertiary, #9e9e9e);
3739
3739
  }
3740
- .ScArtifaxSidebar_switchAppRow {
3740
+ .ScArtifaxSidebar_profileRow {
3741
3741
  display: flex;
3742
- align-items: center;
3743
- padding: var(--spacing-md, 0.5rem) var(--spacing-xl, 0.75rem);
3744
- border-radius: var(--radius-3xl, 1rem);
3745
- cursor: pointer;
3746
- height: 2.5rem;
3747
3742
  width: 100%;
3748
- flex-shrink: 0;
3749
- background: transparent;
3750
- border: none;
3751
- text-align: left;
3752
- }
3753
- .ScArtifaxSidebar_switchAppRow:hover {
3754
- background: var(--alias-fill-neutral-neutral, #1a1a1a);
3755
- }
3756
- .ScArtifaxSidebar_switchAppIconBox {
3757
- width: 2rem;
3758
- height: 2rem;
3759
- display: flex;
3760
3743
  align-items: center;
3761
- justify-content: center;
3744
+ gap: var(--spacing-xs, 0.25rem);
3762
3745
  flex-shrink: 0;
3763
3746
  }
3764
- .ScArtifaxSidebar_switchAppIconBox > * {
3765
- width: 1.75rem;
3766
- height: 1.75rem;
3767
- }
3768
- .ScArtifaxSidebar_switchAppLabel {
3747
+ .ScArtifaxSidebar_profileMain {
3748
+ display: flex;
3769
3749
  flex: 1 1 0;
3770
3750
  min-width: 0;
3771
- font-family: var(--font-family-font-family-body, "Inter", sans-serif);
3772
- font-size: 0.875rem;
3773
- font-weight: 400;
3774
- line-height: 1.25rem;
3775
- color: var(--alias-text-and-icons-primary, #f5f5f5);
3776
- margin-left: var(--spacing-md, 0.5rem);
3777
- overflow: hidden;
3778
- text-overflow: ellipsis;
3779
- white-space: nowrap;
3780
- }
3781
- .ScArtifaxSidebar_switchAppRowCollapsed {
3782
- display: flex;
3783
- align-items: center;
3784
- justify-content: center;
3785
- padding: var(--spacing-md, 0.5rem);
3786
- border-radius: var(--radius-3xl, 1rem);
3787
- background: transparent;
3788
- border: none;
3789
- cursor: pointer;
3790
- width: 2.5rem;
3791
- height: 2.5rem;
3792
- flex-shrink: 0;
3793
- }
3794
- .ScArtifaxSidebar_switchAppRowCollapsed:hover {
3795
- background: var(--alias-fill-neutral-neutral, #1a1a1a);
3796
- }
3797
- .ScArtifaxSidebar_switchAppRowCollapsed > * {
3798
- width: 1.75rem;
3799
- height: 1.75rem;
3800
- }
3801
- .ScArtifaxSidebar_profileRow {
3802
- display: flex;
3803
- width: 100%;
3804
3751
  align-items: center;
3805
3752
  gap: var(--spacing-md, 0.5rem);
3806
3753
  padding: var(--spacing-md, 0.5rem) var(--spacing-xl, 0.75rem);
3807
3754
  border-radius: var(--radius-3xl, 1rem);
3808
3755
  cursor: pointer;
3809
- flex-shrink: 0;
3810
3756
  background: transparent;
3811
3757
  border: none;
3812
3758
  text-align: left;
3813
3759
  }
3814
- .ScArtifaxSidebar_profileRow:hover {
3760
+ .ScArtifaxSidebar_profileMain:hover {
3815
3761
  background: var(--alias-fill-neutral-neutral, #1a1a1a);
3816
3762
  }
3817
3763
  .ScArtifaxSidebar_profileRowCollapsed {
@@ -3880,26 +3826,75 @@
3880
3826
  align-items: center;
3881
3827
  justify-content: center;
3882
3828
  }
3883
- .ScArtifaxSidebar_footerExpanded {
3829
+ .ScArtifaxSidebar_askAgentSlot {
3830
+ width: 100%;
3831
+ flex-shrink: 0;
3832
+ padding: 0 var(--spacing-md, 0.5rem) var(--spacing-3xl, 1rem);
3833
+ }
3834
+ .ScArtifaxSidebar_askAgentSlotCollapsed {
3835
+ display: flex;
3836
+ justify-content: center;
3837
+ width: 100%;
3838
+ flex-shrink: 0;
3839
+ padding: var(--spacing-md, 0.5rem) 0;
3840
+ }
3841
+ .ScArtifaxSidebar_askAgent,
3842
+ .ScArtifaxSidebar_askAgentCollapsed {
3884
3843
  display: flex;
3885
3844
  align-items: center;
3886
- gap: var(--spacing-xs, 0.25rem);
3887
- padding: var(--spacing-xs, 0.25rem) var(--spacing-xs, 0.25rem) var(--spacing-xs, 0.25rem) var(--spacing-xl, 0.75rem);
3845
+ justify-content: center;
3846
+ gap: var(--spacing-md, 0.5rem);
3847
+ cursor: pointer;
3848
+ color: #f5f5f5;
3849
+ background:
3850
+ linear-gradient(
3851
+ 135deg,
3852
+ rgba(217, 21, 54, 1) 0%,
3853
+ rgba(238, 94, 58, 1) 100%);
3854
+ border: 0.5px solid rgba(255, 0, 0, 0.32);
3855
+ border-radius: var(--radius-2xl, 0.75rem);
3856
+ }
3857
+ .ScArtifaxSidebar_askAgent {
3888
3858
  width: 100%;
3859
+ padding: var(--spacing-xl, 0.75rem);
3860
+ }
3861
+ .ScArtifaxSidebar_askAgentCollapsed {
3862
+ width: 2.5rem;
3863
+ height: 2.5rem;
3864
+ padding: var(--spacing-md, 0.5rem);
3889
3865
  flex-shrink: 0;
3890
3866
  }
3891
- .ScArtifaxSidebar_footerVersion {
3892
- flex: 1 1 0;
3893
- min-width: 0;
3867
+ .ScArtifaxSidebar_askAgent:hover,
3868
+ .ScArtifaxSidebar_askAgentCollapsed:hover {
3869
+ filter: brightness(1.08);
3870
+ }
3871
+ .ScArtifaxSidebar_askAgentActive {
3872
+ box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.4);
3873
+ }
3874
+ .ScArtifaxSidebar_askAgent:focus-visible,
3875
+ .ScArtifaxSidebar_askAgentCollapsed:focus-visible {
3876
+ outline: 2px solid rgba(255, 255, 255, 0.9);
3877
+ outline-offset: 2px;
3878
+ }
3879
+ .ScArtifaxSidebar_askAgentLabel {
3894
3880
  font-family: var(--font-family-font-family-body, "Inter", sans-serif);
3895
3881
  font-size: 0.75rem;
3896
- font-weight: 400;
3882
+ font-weight: 600;
3897
3883
  line-height: 1.125rem;
3898
- color: var(--alias-text-and-icons-muted, #7a7a7a);
3899
- overflow: hidden;
3900
- text-overflow: ellipsis;
3884
+ color: #f5f5f5;
3901
3885
  white-space: nowrap;
3902
3886
  }
3887
+ .ScArtifaxSidebar_askAgentIcon {
3888
+ display: inline-flex;
3889
+ align-items: center;
3890
+ justify-content: center;
3891
+ flex-shrink: 0;
3892
+ color: #f5f5f5;
3893
+ }
3894
+ .ScArtifaxSidebar_askAgentIcon :where(svg) {
3895
+ width: 1.25rem;
3896
+ height: 1.25rem;
3897
+ }
3903
3898
  .ScArtifaxSidebar_footerToggle {
3904
3899
  display: flex;
3905
3900
  align-items: center;
@@ -3927,14 +3922,6 @@
3927
3922
  width: 100%;
3928
3923
  flex-shrink: 0;
3929
3924
  }
3930
- .ScArtifaxSidebar_footerVersionCenter {
3931
- font-family: var(--font-family-font-family-body, "Inter", sans-serif);
3932
- font-size: 0.75rem;
3933
- font-weight: 400;
3934
- line-height: 1.125rem;
3935
- color: var(--alias-text-and-icons-muted, #7a7a7a);
3936
- text-align: center;
3937
- }
3938
3925
  .ScArtifaxSidebar_placeholderIcon {
3939
3926
  width: 1.25rem;
3940
3927
  height: 1.25rem;
@@ -4123,22 +4110,35 @@
4123
4110
  }
4124
4111
  .ScSideBarLogoUnit_collapsedTrigger {
4125
4112
  display: inline-flex;
4113
+ flex-direction: column;
4126
4114
  align-items: center;
4127
4115
  justify-content: center;
4116
+ gap: var(--spacing-md, 0.5rem);
4128
4117
  background: transparent;
4129
4118
  border: none;
4130
- padding: 0;
4119
+ padding: var(--spacing-md, 0.5rem);
4120
+ border-radius: var(--radius-xl, 0.75rem);
4131
4121
  cursor: pointer;
4132
4122
  flex-shrink: 0;
4123
+ transition: background-color 120ms ease-out;
4133
4124
  }
4134
4125
  .ScSideBarLogoUnit_collapsedTrigger:disabled,
4135
4126
  .ScSideBarLogoUnit_collapsedTrigger.ScSideBarLogoUnit_nonInteractive {
4136
4127
  cursor: default;
4137
4128
  }
4138
- .ScSideBarLogoUnit_collapsedTrigger > * {
4129
+ .ScSideBarLogoUnit_collapsedTrigger:hover,
4130
+ .ScSideBarLogoUnit_collapsedTrigger.ScSideBarLogoUnit_forceHover {
4131
+ background-color: var(--alias-surface-subtle, #1a1a1a);
4132
+ }
4133
+ .ScSideBarLogoUnit_collapsedWordmarkSlot {
4139
4134
  display: inline-flex;
4140
4135
  align-items: center;
4141
4136
  justify-content: center;
4137
+ flex-shrink: 0;
4138
+ }
4139
+ .ScSideBarLogoUnit_collapsedTrigger:hover .ScSideBarLogoUnit_switch,
4140
+ .ScSideBarLogoUnit_collapsedTrigger.ScSideBarLogoUnit_forceHover .ScSideBarLogoUnit_switch {
4141
+ background-color: var(--alias-fill-neutral-neutralplus, #151515);
4142
4142
  }
4143
4143
 
4144
4144
  /* src/SC-Slider/ScSlider.module.css */
package/dist/index.d.mts CHANGED
@@ -355,10 +355,19 @@ interface ArtifaxSidebarCreditWarning {
355
355
  level?: "warning" | "danger";
356
356
  onBuyCredits: () => void;
357
357
  }
358
- interface ArtifaxSidebarSwitchApp {
359
- label?: string;
358
+ interface ArtifaxSidebarAssistantCta {
359
+ /** CTA label, e.g. "Ask CXO". Shown in the expanded rail; hidden when
360
+ * collapsed (the icon becomes the only visible content). */
361
+ label: string;
362
+ /** Leading icon. Rendered in both states; it is the sole content of the
363
+ * collapsed square, so always supply one for collapsed use. */
360
364
  icon?: ReactNode;
361
- onClick?: () => void;
365
+ /** Pressed/active styling — e.g. while the panel this opens is visible.
366
+ * Surfaced as `aria-pressed`. */
367
+ active?: boolean;
368
+ /** Accessible name; falls back to `label`. */
369
+ ariaLabel?: string;
370
+ onClick: () => void;
362
371
  }
363
372
  interface IScArtifaxSidebarProps {
364
373
  expanded: boolean;
@@ -370,16 +379,18 @@ interface IScArtifaxSidebarProps {
370
379
  expandedLogo?: ReactNode;
371
380
  collapsedLogo?: ReactNode;
372
381
  creditWarning?: ArtifaxSidebarCreditWarning | null;
373
- switchApp?: ArtifaxSidebarSwitchApp;
382
+ /** Gradient call-to-action above the profile row (e.g. "Ask CXO"). Omit to
383
+ * hide it. Rendered in both expanded (icon + label pill) and collapsed
384
+ * (icon-only square) states. */
385
+ assistantCta?: ArtifaxSidebarAssistantCta | null;
374
386
  profile?: ArtifaxSidebarProfile;
375
- versionText?: string;
376
387
  toggleIcon?: ReactNode | ((expanded: boolean) => ReactNode);
377
388
  openSections?: Record<string, boolean>;
378
389
  onSectionToggle?: (sectionId: string, open: boolean) => void;
379
390
  className?: string;
380
391
  style?: CSSProperties;
381
392
  }
382
- declare const ScArtifaxSidebar: ({ expanded, onToggle, sections, iconMap, activeItemId, onItemSelect, expandedLogo, collapsedLogo, creditWarning, switchApp, profile, versionText, toggleIcon, openSections, onSectionToggle, className, style, }: IScArtifaxSidebarProps) => JSX.Element;
393
+ declare const ScArtifaxSidebar: ({ expanded, onToggle, sections, iconMap, activeItemId, onItemSelect, expandedLogo, collapsedLogo, creditWarning, assistantCta, profile, toggleIcon, openSections, onSectionToggle, className, style, }: IScArtifaxSidebarProps) => JSX.Element;
383
394
 
384
395
  interface IScGuideProps {
385
396
  /** Heading text. */
@@ -1062,4 +1073,4 @@ interface IScPlanDetailsCardMobileProps extends React.HTMLAttributes<HTMLDivElem
1062
1073
  }
1063
1074
  declare const ScPlanDetailsCardMobile: ({ planName, planCredits, planPrice, badgeText, currentPlanLabel, upgradeButtonText, onUpgrade, className, ...props }: IScPlanDetailsCardMobileProps) => JSX.Element;
1064
1075
 
1065
- export { type ArtifaxMenuItem, type ArtifaxSection, type ArtifaxSidebarCreditWarning, type ArtifaxSidebarIconContext, type ArtifaxSidebarIconMap, type ArtifaxSidebarIconRenderer, type ArtifaxSidebarProfile, type ArtifaxSidebarSwitchApp, CreditWarningBanner, type CreditWarningBannerProps, type IInvoiceHistoryMobileProps, type IScAccessProps, type IScAppCardProps, type IScAppCardV3Props, type IScAppFieldProps, type IScAppListingCardProps, type IScArtifaxInviteProps, type IScArtifaxSidebarProps, type IScBadgesProps, type IScBillingHistoryHeaderProps, type IScBillingHistoryTableListProps, type IScBillingLogsTableHeaderProps, type IScBillingLogsTableListProps, type IScBriefCardProps, type IScButtonProps, type IScCalendarDateCompsProps, type IScCalendarProps, type IScCatalogixInviteProps, type IScCheckFieldProps, type IScCheckboxProps, type IScCreditsUsageCardMobileProps, type IScCreditsUsageCardProps, type IScFieldButtonProps, type IScGoogleSignInProps, type IScGuideProps, type IScHDividerProps, type IScHeaderProps, type IScImageFieldProps, type IScIntialProfileCoverProps, type IScLogoUnitProps, type IScMenuOptionsProps, type IScMobileBottomActionProps, type IScMobileTopNavProps, type IScOnlyFieldProps, type IScOnlyIconProps, type IScPairtextProps, type IScPendingActionProps, type IScPhtogenixInviteProps, type IScPlanCardProps, type IScPlanDetailsCardMobileProps, type IScPlanDetailsCardProps, type IScPopUpMenuProps, type IScProfileImageUpdateProps, type IScProfileOptionsProps, type IScProfileProps, type IScProfileSettingsCompProps, type IScProfileV2MobileProps, type IScProgressBarProps, type IScQuickPromptProps, type IScRadioProps, type IScReferralCardMobileProps, type IScReferralTableHeaderProps, type IScReferralTableListProps, type IScRoleMobileProps, type IScRoleProps, type IScSettingsNavProps, type IScSettingsTabCompProps, type IScSideBarLogoUnitProps, type IScSidebarIconsProps, type IScSidebarMenuProps, type IScSidebarProfileProps, type IScSidebarProps, type IScSliderProps, type IScStrLogoProps, type IScTabCompProps, type IScTabFieldProps, type IScTabSwitcherProps, type IScTableHeaderProps, type IScTableListMobileProps, type IScTableListProps, type IScTextFieldProps, type IScToggleSwitchProps, type IScVDividerProps, type IScVersionProps, type IScWorkspaceCardProps, type IScWorkspaceSettingsMobileProps, type IScWorkspaceSwitchMobileProps, type IScWorkspaceSwitchMobileV2Props, type IUsageHistoryMobileProps, InvoiceHistoryMobile, NscWorkspaceSwitch, type PlanFeatureSection, ScAccess, ScAppCard, ScAppCardV3, ScAppField, ScAppListingCard, ScArtifaxInvite, ScArtifaxSidebar, ScBadges, ScBillingHistoryHeader, ScBillingHistoryTableList, ScBillingLogsTableHeader, ScBillingLogsTableList, ScBriefCard, ScButton, ScCalendar, ScCalendarDateComps, ScCatalogixInvite, ScCheckField, ScCheckbox, ScCreditsUsageCard, ScCreditsUsageCardMobile, ScDp, type ScDpProps, ScFieldButton, ScGoogleSignIn, ScGuide, ScHDivider, ScHeader, ScImageField, ScIntialProfileCover, ScLogoUnit, ScMenuOptions, ScMobileBottomAction, ScMobileTopNav, ScOnlyField, ScOnlyIcon, ScPairtext, ScPendingAction, ScPhtogenixInvite, ScPlanCard, ScPlanDetailsCard, ScPlanDetailsCardMobile, ScPopUpMenu, ScProfile, ScProfileImageUpdate, ScProfileOptions, ScProfileSettingsComp, ScProfileV2Mobile, ScProgressBar, ScQuickPrompt, ScRadio, ScReferralCardMobile, ScReferralTableHeader, ScReferralTableList, ScRole, ScRoleMobile, ScSettingsNav, ScSettingsTabComp, ScSideBarLogoUnit, ScSidebar, ScSidebarIcons, ScSidebarMenu, ScSidebarProfile, ScSlider, ScStrLogo, ScTabComp, ScTabField, ScTabSwitcher, ScTableHeader, ScTableList, ScTableListMobile, ScTextField, ScToggleSwitch, ScVDivider, ScVersion, ScWorkspaceCard, ScWorkspaceSettingsMobile, ScWorkspaceSwitchCard, type ScWorkspaceSwitchCardProps, ScWorkspaceSwitchMobile, ScWorkspaceSwitchMobileV2, type SidebarConfig, type SidebarIconContext, type SidebarIconMap, type SidebarIconRenderer, type SidebarMenuItemConfig, type SidebarProfileConfig, type SidebarSectionConfig, StreamoidSidebar, type StreamoidSidebarProps, StreamoidWorkspaceSwitcher, type StreamoidWorkspaceSwitcherProps, UsageHistoryMobile, type WorkspaceSwitcherConfig, type WorkspaceSwitcherItem };
1076
+ export { type ArtifaxMenuItem, type ArtifaxSection, type ArtifaxSidebarAssistantCta, type ArtifaxSidebarCreditWarning, type ArtifaxSidebarIconContext, type ArtifaxSidebarIconMap, type ArtifaxSidebarIconRenderer, type ArtifaxSidebarProfile, CreditWarningBanner, type CreditWarningBannerProps, type IInvoiceHistoryMobileProps, type IScAccessProps, type IScAppCardProps, type IScAppCardV3Props, type IScAppFieldProps, type IScAppListingCardProps, type IScArtifaxInviteProps, type IScArtifaxSidebarProps, type IScBadgesProps, type IScBillingHistoryHeaderProps, type IScBillingHistoryTableListProps, type IScBillingLogsTableHeaderProps, type IScBillingLogsTableListProps, type IScBriefCardProps, type IScButtonProps, type IScCalendarDateCompsProps, type IScCalendarProps, type IScCatalogixInviteProps, type IScCheckFieldProps, type IScCheckboxProps, type IScCreditsUsageCardMobileProps, type IScCreditsUsageCardProps, type IScFieldButtonProps, type IScGoogleSignInProps, type IScGuideProps, type IScHDividerProps, type IScHeaderProps, type IScImageFieldProps, type IScIntialProfileCoverProps, type IScLogoUnitProps, type IScMenuOptionsProps, type IScMobileBottomActionProps, type IScMobileTopNavProps, type IScOnlyFieldProps, type IScOnlyIconProps, type IScPairtextProps, type IScPendingActionProps, type IScPhtogenixInviteProps, type IScPlanCardProps, type IScPlanDetailsCardMobileProps, type IScPlanDetailsCardProps, type IScPopUpMenuProps, type IScProfileImageUpdateProps, type IScProfileOptionsProps, type IScProfileProps, type IScProfileSettingsCompProps, type IScProfileV2MobileProps, type IScProgressBarProps, type IScQuickPromptProps, type IScRadioProps, type IScReferralCardMobileProps, type IScReferralTableHeaderProps, type IScReferralTableListProps, type IScRoleMobileProps, type IScRoleProps, type IScSettingsNavProps, type IScSettingsTabCompProps, type IScSideBarLogoUnitProps, type IScSidebarIconsProps, type IScSidebarMenuProps, type IScSidebarProfileProps, type IScSidebarProps, type IScSliderProps, type IScStrLogoProps, type IScTabCompProps, type IScTabFieldProps, type IScTabSwitcherProps, type IScTableHeaderProps, type IScTableListMobileProps, type IScTableListProps, type IScTextFieldProps, type IScToggleSwitchProps, type IScVDividerProps, type IScVersionProps, type IScWorkspaceCardProps, type IScWorkspaceSettingsMobileProps, type IScWorkspaceSwitchMobileProps, type IScWorkspaceSwitchMobileV2Props, type IUsageHistoryMobileProps, InvoiceHistoryMobile, NscWorkspaceSwitch, type PlanFeatureSection, ScAccess, ScAppCard, ScAppCardV3, ScAppField, ScAppListingCard, ScArtifaxInvite, ScArtifaxSidebar, ScBadges, ScBillingHistoryHeader, ScBillingHistoryTableList, ScBillingLogsTableHeader, ScBillingLogsTableList, ScBriefCard, ScButton, ScCalendar, ScCalendarDateComps, ScCatalogixInvite, ScCheckField, ScCheckbox, ScCreditsUsageCard, ScCreditsUsageCardMobile, ScDp, type ScDpProps, ScFieldButton, ScGoogleSignIn, ScGuide, ScHDivider, ScHeader, ScImageField, ScIntialProfileCover, ScLogoUnit, ScMenuOptions, ScMobileBottomAction, ScMobileTopNav, ScOnlyField, ScOnlyIcon, ScPairtext, ScPendingAction, ScPhtogenixInvite, ScPlanCard, ScPlanDetailsCard, ScPlanDetailsCardMobile, ScPopUpMenu, ScProfile, ScProfileImageUpdate, ScProfileOptions, ScProfileSettingsComp, ScProfileV2Mobile, ScProgressBar, ScQuickPrompt, ScRadio, ScReferralCardMobile, ScReferralTableHeader, ScReferralTableList, ScRole, ScRoleMobile, ScSettingsNav, ScSettingsTabComp, ScSideBarLogoUnit, ScSidebar, ScSidebarIcons, ScSidebarMenu, ScSidebarProfile, ScSlider, ScStrLogo, ScTabComp, ScTabField, ScTabSwitcher, ScTableHeader, ScTableList, ScTableListMobile, ScTextField, ScToggleSwitch, ScVDivider, ScVersion, ScWorkspaceCard, ScWorkspaceSettingsMobile, ScWorkspaceSwitchCard, type ScWorkspaceSwitchCardProps, ScWorkspaceSwitchMobile, ScWorkspaceSwitchMobileV2, type SidebarConfig, type SidebarIconContext, type SidebarIconMap, type SidebarIconRenderer, type SidebarMenuItemConfig, type SidebarProfileConfig, type SidebarSectionConfig, StreamoidSidebar, type StreamoidSidebarProps, StreamoidWorkspaceSwitcher, type StreamoidWorkspaceSwitcherProps, UsageHistoryMobile, type WorkspaceSwitcherConfig, type WorkspaceSwitcherItem };
package/dist/index.d.ts CHANGED
@@ -355,10 +355,19 @@ interface ArtifaxSidebarCreditWarning {
355
355
  level?: "warning" | "danger";
356
356
  onBuyCredits: () => void;
357
357
  }
358
- interface ArtifaxSidebarSwitchApp {
359
- label?: string;
358
+ interface ArtifaxSidebarAssistantCta {
359
+ /** CTA label, e.g. "Ask CXO". Shown in the expanded rail; hidden when
360
+ * collapsed (the icon becomes the only visible content). */
361
+ label: string;
362
+ /** Leading icon. Rendered in both states; it is the sole content of the
363
+ * collapsed square, so always supply one for collapsed use. */
360
364
  icon?: ReactNode;
361
- onClick?: () => void;
365
+ /** Pressed/active styling — e.g. while the panel this opens is visible.
366
+ * Surfaced as `aria-pressed`. */
367
+ active?: boolean;
368
+ /** Accessible name; falls back to `label`. */
369
+ ariaLabel?: string;
370
+ onClick: () => void;
362
371
  }
363
372
  interface IScArtifaxSidebarProps {
364
373
  expanded: boolean;
@@ -370,16 +379,18 @@ interface IScArtifaxSidebarProps {
370
379
  expandedLogo?: ReactNode;
371
380
  collapsedLogo?: ReactNode;
372
381
  creditWarning?: ArtifaxSidebarCreditWarning | null;
373
- switchApp?: ArtifaxSidebarSwitchApp;
382
+ /** Gradient call-to-action above the profile row (e.g. "Ask CXO"). Omit to
383
+ * hide it. Rendered in both expanded (icon + label pill) and collapsed
384
+ * (icon-only square) states. */
385
+ assistantCta?: ArtifaxSidebarAssistantCta | null;
374
386
  profile?: ArtifaxSidebarProfile;
375
- versionText?: string;
376
387
  toggleIcon?: ReactNode | ((expanded: boolean) => ReactNode);
377
388
  openSections?: Record<string, boolean>;
378
389
  onSectionToggle?: (sectionId: string, open: boolean) => void;
379
390
  className?: string;
380
391
  style?: CSSProperties;
381
392
  }
382
- declare const ScArtifaxSidebar: ({ expanded, onToggle, sections, iconMap, activeItemId, onItemSelect, expandedLogo, collapsedLogo, creditWarning, switchApp, profile, versionText, toggleIcon, openSections, onSectionToggle, className, style, }: IScArtifaxSidebarProps) => JSX.Element;
393
+ declare const ScArtifaxSidebar: ({ expanded, onToggle, sections, iconMap, activeItemId, onItemSelect, expandedLogo, collapsedLogo, creditWarning, assistantCta, profile, toggleIcon, openSections, onSectionToggle, className, style, }: IScArtifaxSidebarProps) => JSX.Element;
383
394
 
384
395
  interface IScGuideProps {
385
396
  /** Heading text. */
@@ -1062,4 +1073,4 @@ interface IScPlanDetailsCardMobileProps extends React.HTMLAttributes<HTMLDivElem
1062
1073
  }
1063
1074
  declare const ScPlanDetailsCardMobile: ({ planName, planCredits, planPrice, badgeText, currentPlanLabel, upgradeButtonText, onUpgrade, className, ...props }: IScPlanDetailsCardMobileProps) => JSX.Element;
1064
1075
 
1065
- export { type ArtifaxMenuItem, type ArtifaxSection, type ArtifaxSidebarCreditWarning, type ArtifaxSidebarIconContext, type ArtifaxSidebarIconMap, type ArtifaxSidebarIconRenderer, type ArtifaxSidebarProfile, type ArtifaxSidebarSwitchApp, CreditWarningBanner, type CreditWarningBannerProps, type IInvoiceHistoryMobileProps, type IScAccessProps, type IScAppCardProps, type IScAppCardV3Props, type IScAppFieldProps, type IScAppListingCardProps, type IScArtifaxInviteProps, type IScArtifaxSidebarProps, type IScBadgesProps, type IScBillingHistoryHeaderProps, type IScBillingHistoryTableListProps, type IScBillingLogsTableHeaderProps, type IScBillingLogsTableListProps, type IScBriefCardProps, type IScButtonProps, type IScCalendarDateCompsProps, type IScCalendarProps, type IScCatalogixInviteProps, type IScCheckFieldProps, type IScCheckboxProps, type IScCreditsUsageCardMobileProps, type IScCreditsUsageCardProps, type IScFieldButtonProps, type IScGoogleSignInProps, type IScGuideProps, type IScHDividerProps, type IScHeaderProps, type IScImageFieldProps, type IScIntialProfileCoverProps, type IScLogoUnitProps, type IScMenuOptionsProps, type IScMobileBottomActionProps, type IScMobileTopNavProps, type IScOnlyFieldProps, type IScOnlyIconProps, type IScPairtextProps, type IScPendingActionProps, type IScPhtogenixInviteProps, type IScPlanCardProps, type IScPlanDetailsCardMobileProps, type IScPlanDetailsCardProps, type IScPopUpMenuProps, type IScProfileImageUpdateProps, type IScProfileOptionsProps, type IScProfileProps, type IScProfileSettingsCompProps, type IScProfileV2MobileProps, type IScProgressBarProps, type IScQuickPromptProps, type IScRadioProps, type IScReferralCardMobileProps, type IScReferralTableHeaderProps, type IScReferralTableListProps, type IScRoleMobileProps, type IScRoleProps, type IScSettingsNavProps, type IScSettingsTabCompProps, type IScSideBarLogoUnitProps, type IScSidebarIconsProps, type IScSidebarMenuProps, type IScSidebarProfileProps, type IScSidebarProps, type IScSliderProps, type IScStrLogoProps, type IScTabCompProps, type IScTabFieldProps, type IScTabSwitcherProps, type IScTableHeaderProps, type IScTableListMobileProps, type IScTableListProps, type IScTextFieldProps, type IScToggleSwitchProps, type IScVDividerProps, type IScVersionProps, type IScWorkspaceCardProps, type IScWorkspaceSettingsMobileProps, type IScWorkspaceSwitchMobileProps, type IScWorkspaceSwitchMobileV2Props, type IUsageHistoryMobileProps, InvoiceHistoryMobile, NscWorkspaceSwitch, type PlanFeatureSection, ScAccess, ScAppCard, ScAppCardV3, ScAppField, ScAppListingCard, ScArtifaxInvite, ScArtifaxSidebar, ScBadges, ScBillingHistoryHeader, ScBillingHistoryTableList, ScBillingLogsTableHeader, ScBillingLogsTableList, ScBriefCard, ScButton, ScCalendar, ScCalendarDateComps, ScCatalogixInvite, ScCheckField, ScCheckbox, ScCreditsUsageCard, ScCreditsUsageCardMobile, ScDp, type ScDpProps, ScFieldButton, ScGoogleSignIn, ScGuide, ScHDivider, ScHeader, ScImageField, ScIntialProfileCover, ScLogoUnit, ScMenuOptions, ScMobileBottomAction, ScMobileTopNav, ScOnlyField, ScOnlyIcon, ScPairtext, ScPendingAction, ScPhtogenixInvite, ScPlanCard, ScPlanDetailsCard, ScPlanDetailsCardMobile, ScPopUpMenu, ScProfile, ScProfileImageUpdate, ScProfileOptions, ScProfileSettingsComp, ScProfileV2Mobile, ScProgressBar, ScQuickPrompt, ScRadio, ScReferralCardMobile, ScReferralTableHeader, ScReferralTableList, ScRole, ScRoleMobile, ScSettingsNav, ScSettingsTabComp, ScSideBarLogoUnit, ScSidebar, ScSidebarIcons, ScSidebarMenu, ScSidebarProfile, ScSlider, ScStrLogo, ScTabComp, ScTabField, ScTabSwitcher, ScTableHeader, ScTableList, ScTableListMobile, ScTextField, ScToggleSwitch, ScVDivider, ScVersion, ScWorkspaceCard, ScWorkspaceSettingsMobile, ScWorkspaceSwitchCard, type ScWorkspaceSwitchCardProps, ScWorkspaceSwitchMobile, ScWorkspaceSwitchMobileV2, type SidebarConfig, type SidebarIconContext, type SidebarIconMap, type SidebarIconRenderer, type SidebarMenuItemConfig, type SidebarProfileConfig, type SidebarSectionConfig, StreamoidSidebar, type StreamoidSidebarProps, StreamoidWorkspaceSwitcher, type StreamoidWorkspaceSwitcherProps, UsageHistoryMobile, type WorkspaceSwitcherConfig, type WorkspaceSwitcherItem };
1076
+ export { type ArtifaxMenuItem, type ArtifaxSection, type ArtifaxSidebarAssistantCta, type ArtifaxSidebarCreditWarning, type ArtifaxSidebarIconContext, type ArtifaxSidebarIconMap, type ArtifaxSidebarIconRenderer, type ArtifaxSidebarProfile, CreditWarningBanner, type CreditWarningBannerProps, type IInvoiceHistoryMobileProps, type IScAccessProps, type IScAppCardProps, type IScAppCardV3Props, type IScAppFieldProps, type IScAppListingCardProps, type IScArtifaxInviteProps, type IScArtifaxSidebarProps, type IScBadgesProps, type IScBillingHistoryHeaderProps, type IScBillingHistoryTableListProps, type IScBillingLogsTableHeaderProps, type IScBillingLogsTableListProps, type IScBriefCardProps, type IScButtonProps, type IScCalendarDateCompsProps, type IScCalendarProps, type IScCatalogixInviteProps, type IScCheckFieldProps, type IScCheckboxProps, type IScCreditsUsageCardMobileProps, type IScCreditsUsageCardProps, type IScFieldButtonProps, type IScGoogleSignInProps, type IScGuideProps, type IScHDividerProps, type IScHeaderProps, type IScImageFieldProps, type IScIntialProfileCoverProps, type IScLogoUnitProps, type IScMenuOptionsProps, type IScMobileBottomActionProps, type IScMobileTopNavProps, type IScOnlyFieldProps, type IScOnlyIconProps, type IScPairtextProps, type IScPendingActionProps, type IScPhtogenixInviteProps, type IScPlanCardProps, type IScPlanDetailsCardMobileProps, type IScPlanDetailsCardProps, type IScPopUpMenuProps, type IScProfileImageUpdateProps, type IScProfileOptionsProps, type IScProfileProps, type IScProfileSettingsCompProps, type IScProfileV2MobileProps, type IScProgressBarProps, type IScQuickPromptProps, type IScRadioProps, type IScReferralCardMobileProps, type IScReferralTableHeaderProps, type IScReferralTableListProps, type IScRoleMobileProps, type IScRoleProps, type IScSettingsNavProps, type IScSettingsTabCompProps, type IScSideBarLogoUnitProps, type IScSidebarIconsProps, type IScSidebarMenuProps, type IScSidebarProfileProps, type IScSidebarProps, type IScSliderProps, type IScStrLogoProps, type IScTabCompProps, type IScTabFieldProps, type IScTabSwitcherProps, type IScTableHeaderProps, type IScTableListMobileProps, type IScTableListProps, type IScTextFieldProps, type IScToggleSwitchProps, type IScVDividerProps, type IScVersionProps, type IScWorkspaceCardProps, type IScWorkspaceSettingsMobileProps, type IScWorkspaceSwitchMobileProps, type IScWorkspaceSwitchMobileV2Props, type IUsageHistoryMobileProps, InvoiceHistoryMobile, NscWorkspaceSwitch, type PlanFeatureSection, ScAccess, ScAppCard, ScAppCardV3, ScAppField, ScAppListingCard, ScArtifaxInvite, ScArtifaxSidebar, ScBadges, ScBillingHistoryHeader, ScBillingHistoryTableList, ScBillingLogsTableHeader, ScBillingLogsTableList, ScBriefCard, ScButton, ScCalendar, ScCalendarDateComps, ScCatalogixInvite, ScCheckField, ScCheckbox, ScCreditsUsageCard, ScCreditsUsageCardMobile, ScDp, type ScDpProps, ScFieldButton, ScGoogleSignIn, ScGuide, ScHDivider, ScHeader, ScImageField, ScIntialProfileCover, ScLogoUnit, ScMenuOptions, ScMobileBottomAction, ScMobileTopNav, ScOnlyField, ScOnlyIcon, ScPairtext, ScPendingAction, ScPhtogenixInvite, ScPlanCard, ScPlanDetailsCard, ScPlanDetailsCardMobile, ScPopUpMenu, ScProfile, ScProfileImageUpdate, ScProfileOptions, ScProfileSettingsComp, ScProfileV2Mobile, ScProgressBar, ScQuickPrompt, ScRadio, ScReferralCardMobile, ScReferralTableHeader, ScReferralTableList, ScRole, ScRoleMobile, ScSettingsNav, ScSettingsTabComp, ScSideBarLogoUnit, ScSidebar, ScSidebarIcons, ScSidebarMenu, ScSidebarProfile, ScSlider, ScStrLogo, ScTabComp, ScTabField, ScTabSwitcher, ScTableHeader, ScTableList, ScTableListMobile, ScTextField, ScToggleSwitch, ScVDivider, ScVersion, ScWorkspaceCard, ScWorkspaceSettingsMobile, ScWorkspaceSwitchCard, type ScWorkspaceSwitchCardProps, ScWorkspaceSwitchMobile, ScWorkspaceSwitchMobileV2, type SidebarConfig, type SidebarIconContext, type SidebarIconMap, type SidebarIconRenderer, type SidebarMenuItemConfig, type SidebarProfileConfig, type SidebarSectionConfig, StreamoidSidebar, type StreamoidSidebarProps, StreamoidWorkspaceSwitcher, type StreamoidWorkspaceSwitcherProps, UsageHistoryMobile, type WorkspaceSwitcherConfig, type WorkspaceSwitcherItem };
package/dist/index.js CHANGED
@@ -3367,22 +3367,23 @@ var ScArtifaxSidebar_default = {
3367
3367
  sectionHeader: "ScArtifaxSidebar_sectionHeader",
3368
3368
  sectionLabel: "ScArtifaxSidebar_sectionLabel",
3369
3369
  sectionChevron: "ScArtifaxSidebar_sectionChevron",
3370
- switchAppRow: "ScArtifaxSidebar_switchAppRow",
3371
- switchAppIconBox: "ScArtifaxSidebar_switchAppIconBox",
3372
- switchAppLabel: "ScArtifaxSidebar_switchAppLabel",
3373
- switchAppRowCollapsed: "ScArtifaxSidebar_switchAppRowCollapsed",
3374
3370
  profileRow: "ScArtifaxSidebar_profileRow",
3371
+ profileMain: "ScArtifaxSidebar_profileMain",
3375
3372
  profileRowCollapsed: "ScArtifaxSidebar_profileRowCollapsed",
3376
3373
  profileAvatar: "ScArtifaxSidebar_profileAvatar",
3377
3374
  profileInfo: "ScArtifaxSidebar_profileInfo",
3378
3375
  profileName: "ScArtifaxSidebar_profileName",
3379
3376
  profileSubtitle: "ScArtifaxSidebar_profileSubtitle",
3380
3377
  creditWarningSlot: "ScArtifaxSidebar_creditWarningSlot",
3381
- footerExpanded: "ScArtifaxSidebar_footerExpanded",
3382
- footerVersion: "ScArtifaxSidebar_footerVersion",
3378
+ askAgentSlot: "ScArtifaxSidebar_askAgentSlot",
3379
+ askAgentSlotCollapsed: "ScArtifaxSidebar_askAgentSlotCollapsed",
3380
+ askAgent: "ScArtifaxSidebar_askAgent",
3381
+ askAgentCollapsed: "ScArtifaxSidebar_askAgentCollapsed",
3382
+ askAgentActive: "ScArtifaxSidebar_askAgentActive",
3383
+ askAgentLabel: "ScArtifaxSidebar_askAgentLabel",
3384
+ askAgentIcon: "ScArtifaxSidebar_askAgentIcon",
3383
3385
  footerToggle: "ScArtifaxSidebar_footerToggle",
3384
3386
  footerCollapsed: "ScArtifaxSidebar_footerCollapsed",
3385
- footerVersionCenter: "ScArtifaxSidebar_footerVersionCenter",
3386
3387
  placeholderIcon: "ScArtifaxSidebar_placeholderIcon"
3387
3388
  };
3388
3389
 
@@ -3428,6 +3429,26 @@ function SectionHeader2({
3428
3429
  }
3429
3430
  );
3430
3431
  }
3432
+ function AskAgentButton({
3433
+ cta,
3434
+ collapsed
3435
+ }) {
3436
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
3437
+ "button",
3438
+ {
3439
+ type: "button",
3440
+ className: (collapsed ? ScArtifaxSidebar_default.askAgentCollapsed : ScArtifaxSidebar_default.askAgent) + (cta.active ? " " + ScArtifaxSidebar_default.askAgentActive : ""),
3441
+ onClick: cta.onClick,
3442
+ "aria-pressed": cta.active ?? void 0,
3443
+ "aria-label": cta.ariaLabel ?? cta.label,
3444
+ title: cta.ariaLabel ?? cta.label,
3445
+ children: [
3446
+ cta.icon ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: ScArtifaxSidebar_default.askAgentIcon, children: cta.icon }) : null,
3447
+ !collapsed ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: ScArtifaxSidebar_default.askAgentLabel, children: cta.label }) : null
3448
+ ]
3449
+ }
3450
+ );
3451
+ }
3431
3452
  var ScArtifaxSidebar = ({
3432
3453
  expanded,
3433
3454
  onToggle,
@@ -3438,9 +3459,8 @@ var ScArtifaxSidebar = ({
3438
3459
  expandedLogo,
3439
3460
  collapsedLogo,
3440
3461
  creditWarning,
3441
- switchApp,
3462
+ assistantCta,
3442
3463
  profile,
3443
- versionText = "v2.1.2",
3444
3464
  toggleIcon,
3445
3465
  openSections,
3446
3466
  onSectionToggle,
@@ -3518,40 +3538,24 @@ var ScArtifaxSidebar = ({
3518
3538
  ] }, section.id);
3519
3539
  })
3520
3540
  ] }),
3521
- creditWarning ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
3522
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3523
- CreditWarningBanner,
3524
- {
3525
- availableCredits: creditWarning.availableCredits,
3526
- remainingPct: creditWarning.remainingPct,
3527
- level: creditWarning.level ?? "danger",
3528
- onBuyCredits: creditWarning.onBuyCredits,
3529
- expanded: true
3530
- }
3531
- ) }),
3532
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {})
3533
- ] }) : null,
3534
- switchApp ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
3535
- /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
3536
- "button",
3537
- {
3538
- type: "button",
3539
- className: ScArtifaxSidebar_default.switchAppRow,
3540
- onClick: switchApp.onClick,
3541
- children: [
3542
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.switchAppIconBox, children: switchApp.icon ?? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_icons35.SiconAppSwitch, {}) }),
3543
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: ScArtifaxSidebar_default.switchAppLabel, children: switchApp.label ?? "Switch App" })
3544
- ]
3545
- }
3546
- ),
3547
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {})
3548
- ] }) : null,
3549
- profile ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
3550
- /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
3541
+ creditWarning ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3542
+ CreditWarningBanner,
3543
+ {
3544
+ availableCredits: creditWarning.availableCredits,
3545
+ remainingPct: creditWarning.remainingPct,
3546
+ level: creditWarning.level ?? "danger",
3547
+ onBuyCredits: creditWarning.onBuyCredits,
3548
+ expanded: true
3549
+ }
3550
+ ) }) : null,
3551
+ assistantCta ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.askAgentSlot, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(AskAgentButton, { cta: assistantCta, collapsed: false }) }) : null,
3552
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {}),
3553
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: ScArtifaxSidebar_default.profileRow, children: [
3554
+ profile ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
3551
3555
  "button",
3552
3556
  {
3553
3557
  type: "button",
3554
- className: ScArtifaxSidebar_default.profileRow,
3558
+ className: ScArtifaxSidebar_default.profileMain,
3555
3559
  onClick: profile.onClick,
3556
3560
  children: [
3557
3561
  /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.profileAvatar, children: profile.avatar }),
@@ -3561,11 +3565,7 @@ var ScArtifaxSidebar = ({
3561
3565
  ] })
3562
3566
  ]
3563
3567
  }
3564
- ),
3565
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {})
3566
- ] }) : null,
3567
- /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: ScArtifaxSidebar_default.footerExpanded, children: [
3568
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: ScArtifaxSidebar_default.footerVersion, children: versionText }),
3568
+ ) : /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: ScArtifaxSidebar_default.profileMain, "aria-hidden": "true" }),
3569
3569
  /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3570
3570
  "button",
3571
3571
  {
@@ -3595,34 +3595,20 @@ var ScArtifaxSidebar = ({
3595
3595
  /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.sectionContainerCollapsed, children: section.items.map((item) => renderMenuItem2(item, section.id)) })
3596
3596
  ] }, section.id))
3597
3597
  ] }),
3598
- creditWarning ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
3599
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3600
- CreditWarningBanner,
3601
- {
3602
- availableCredits: creditWarning.availableCredits,
3603
- remainingPct: creditWarning.remainingPct,
3604
- level: creditWarning.level ?? "danger",
3605
- onBuyCredits: creditWarning.onBuyCredits,
3606
- expanded: false
3607
- }
3608
- ) }),
3609
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {})
3610
- ] }) : null,
3611
- switchApp ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
3612
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3613
- "button",
3614
- {
3615
- type: "button",
3616
- className: ScArtifaxSidebar_default.switchAppRowCollapsed,
3617
- onClick: switchApp.onClick,
3618
- "aria-label": switchApp.label ?? "Switch App",
3619
- children: switchApp.icon ?? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_icons35.SiconAppSwitch, {})
3620
- }
3621
- ),
3622
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {})
3623
- ] }) : null,
3624
- profile ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
3625
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3598
+ creditWarning ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3599
+ CreditWarningBanner,
3600
+ {
3601
+ availableCredits: creditWarning.availableCredits,
3602
+ remainingPct: creditWarning.remainingPct,
3603
+ level: creditWarning.level ?? "danger",
3604
+ onBuyCredits: creditWarning.onBuyCredits,
3605
+ expanded: false
3606
+ }
3607
+ ) }) : null,
3608
+ assistantCta ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.askAgentSlotCollapsed, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(AskAgentButton, { cta: assistantCta, collapsed: true }) }) : null,
3609
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {}),
3610
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: ScArtifaxSidebar_default.footerCollapsed, children: [
3611
+ profile ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3626
3612
  "button",
3627
3613
  {
3628
3614
  type: "button",
@@ -3631,10 +3617,7 @@ var ScArtifaxSidebar = ({
3631
3617
  "aria-label": profile.name,
3632
3618
  children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: ScArtifaxSidebar_default.profileAvatar, children: profile.avatar })
3633
3619
  }
3634
- ),
3635
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ScHDivider, {})
3636
- ] }) : null,
3637
- /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: ScArtifaxSidebar_default.footerCollapsed, children: [
3620
+ ) : null,
3638
3621
  /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
3639
3622
  "button",
3640
3623
  {
@@ -3644,8 +3627,7 @@ var ScArtifaxSidebar = ({
3644
3627
  "aria-label": "Expand sidebar",
3645
3628
  children: resolveToggleIcon2(toggleIcon, false)
3646
3629
  }
3647
- ),
3648
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: ScArtifaxSidebar_default.footerVersionCenter, children: versionText })
3630
+ )
3649
3631
  ] })
3650
3632
  ] })
3651
3633
  }
@@ -3734,7 +3716,8 @@ var ScSideBarLogoUnit_default = {
3734
3716
  switch: "ScSideBarLogoUnit_switch",
3735
3717
  switchIcon: "ScSideBarLogoUnit_switchIcon",
3736
3718
  collapsed: "ScSideBarLogoUnit_collapsed",
3737
- collapsedTrigger: "ScSideBarLogoUnit_collapsedTrigger"
3719
+ collapsedTrigger: "ScSideBarLogoUnit_collapsedTrigger",
3720
+ collapsedWordmarkSlot: "ScSideBarLogoUnit_collapsedWordmarkSlot"
3738
3721
  };
3739
3722
 
3740
3723
  // src/SC-SideBarLogoUnit/ScSideBarLogoUnit.tsx
@@ -3759,21 +3742,30 @@ var ScSideBarLogoUnit = ({
3759
3742
  onSwitchClick?.();
3760
3743
  };
3761
3744
  if (state === "collapsed") {
3745
+ const collapsedClasses = [
3746
+ ScSideBarLogoUnit_default.collapsedTrigger,
3747
+ interactive ? "" : ScSideBarLogoUnit_default.nonInteractive,
3748
+ hover === true ? ScSideBarLogoUnit_default.forceHover : ""
3749
+ ].filter(Boolean).join(" ");
3762
3750
  return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
3763
3751
  "div",
3764
3752
  {
3765
3753
  className: ScSideBarLogoUnit_default.scSideBarLogoUnit + " " + ScSideBarLogoUnit_default.collapsed + (className ? " " + className : ""),
3766
3754
  style,
3767
- children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
3755
+ children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
3768
3756
  "button",
3769
3757
  {
3770
3758
  type: "button",
3771
- className: ScSideBarLogoUnit_default.collapsedTrigger + (interactive ? "" : " " + ScSideBarLogoUnit_default.nonInteractive),
3759
+ className: collapsedClasses,
3772
3760
  onClick: interactive ? handleClick : void 0,
3773
3761
  disabled,
3774
3762
  "aria-label": interactive ? switchAriaLabel : void 0,
3775
3763
  "aria-disabled": !interactive || disabled,
3776
- children: wordmark
3764
+ style: hover === false ? { backgroundColor: "transparent" } : void 0,
3765
+ children: [
3766
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: ScSideBarLogoUnit_default.collapsedWordmarkSlot, children: wordmark }),
3767
+ hideSwitch ? null : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: ScSideBarLogoUnit_default.switch, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: ScSideBarLogoUnit_default.switchIcon, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_icons37.SiconDoubleArrow, { size: 16, strokeWidth: 1.5 }) }) })
3768
+ ]
3777
3769
  }
3778
3770
  )
3779
3771
  }
package/dist/index.mjs CHANGED
@@ -3260,32 +3260,28 @@ var ScArtifaxSidebar_default = {
3260
3260
  sectionHeader: "ScArtifaxSidebar_sectionHeader",
3261
3261
  sectionLabel: "ScArtifaxSidebar_sectionLabel",
3262
3262
  sectionChevron: "ScArtifaxSidebar_sectionChevron",
3263
- switchAppRow: "ScArtifaxSidebar_switchAppRow",
3264
- switchAppIconBox: "ScArtifaxSidebar_switchAppIconBox",
3265
- switchAppLabel: "ScArtifaxSidebar_switchAppLabel",
3266
- switchAppRowCollapsed: "ScArtifaxSidebar_switchAppRowCollapsed",
3267
3263
  profileRow: "ScArtifaxSidebar_profileRow",
3264
+ profileMain: "ScArtifaxSidebar_profileMain",
3268
3265
  profileRowCollapsed: "ScArtifaxSidebar_profileRowCollapsed",
3269
3266
  profileAvatar: "ScArtifaxSidebar_profileAvatar",
3270
3267
  profileInfo: "ScArtifaxSidebar_profileInfo",
3271
3268
  profileName: "ScArtifaxSidebar_profileName",
3272
3269
  profileSubtitle: "ScArtifaxSidebar_profileSubtitle",
3273
3270
  creditWarningSlot: "ScArtifaxSidebar_creditWarningSlot",
3274
- footerExpanded: "ScArtifaxSidebar_footerExpanded",
3275
- footerVersion: "ScArtifaxSidebar_footerVersion",
3271
+ askAgentSlot: "ScArtifaxSidebar_askAgentSlot",
3272
+ askAgentSlotCollapsed: "ScArtifaxSidebar_askAgentSlotCollapsed",
3273
+ askAgent: "ScArtifaxSidebar_askAgent",
3274
+ askAgentCollapsed: "ScArtifaxSidebar_askAgentCollapsed",
3275
+ askAgentActive: "ScArtifaxSidebar_askAgentActive",
3276
+ askAgentLabel: "ScArtifaxSidebar_askAgentLabel",
3277
+ askAgentIcon: "ScArtifaxSidebar_askAgentIcon",
3276
3278
  footerToggle: "ScArtifaxSidebar_footerToggle",
3277
3279
  footerCollapsed: "ScArtifaxSidebar_footerCollapsed",
3278
- footerVersionCenter: "ScArtifaxSidebar_footerVersionCenter",
3279
3280
  placeholderIcon: "ScArtifaxSidebar_placeholderIcon"
3280
3281
  };
3281
3282
 
3282
3283
  // src/SC-Artifax-Sidebar/ScArtifaxSidebar.tsx
3283
- import {
3284
- SiconAppSwitch,
3285
- SiconCollapse as SiconCollapse3,
3286
- SiconDown,
3287
- SiconUp
3288
- } from "@streamoid/icons";
3284
+ import { SiconCollapse as SiconCollapse3, SiconDown, SiconUp } from "@streamoid/icons";
3289
3285
  import { Fragment as Fragment15, jsx as jsx41, jsxs as jsxs33 } from "react/jsx-runtime";
3290
3286
  function ArtifaxPlaceholderIcon() {
3291
3287
  return /* @__PURE__ */ jsx41("span", { "aria-hidden": "true", className: ScArtifaxSidebar_default.placeholderIcon });
@@ -3326,6 +3322,26 @@ function SectionHeader2({
3326
3322
  }
3327
3323
  );
3328
3324
  }
3325
+ function AskAgentButton({
3326
+ cta,
3327
+ collapsed
3328
+ }) {
3329
+ return /* @__PURE__ */ jsxs33(
3330
+ "button",
3331
+ {
3332
+ type: "button",
3333
+ className: (collapsed ? ScArtifaxSidebar_default.askAgentCollapsed : ScArtifaxSidebar_default.askAgent) + (cta.active ? " " + ScArtifaxSidebar_default.askAgentActive : ""),
3334
+ onClick: cta.onClick,
3335
+ "aria-pressed": cta.active ?? void 0,
3336
+ "aria-label": cta.ariaLabel ?? cta.label,
3337
+ title: cta.ariaLabel ?? cta.label,
3338
+ children: [
3339
+ cta.icon ? /* @__PURE__ */ jsx41("span", { className: ScArtifaxSidebar_default.askAgentIcon, children: cta.icon }) : null,
3340
+ !collapsed ? /* @__PURE__ */ jsx41("span", { className: ScArtifaxSidebar_default.askAgentLabel, children: cta.label }) : null
3341
+ ]
3342
+ }
3343
+ );
3344
+ }
3329
3345
  var ScArtifaxSidebar = ({
3330
3346
  expanded,
3331
3347
  onToggle,
@@ -3336,9 +3352,8 @@ var ScArtifaxSidebar = ({
3336
3352
  expandedLogo,
3337
3353
  collapsedLogo,
3338
3354
  creditWarning,
3339
- switchApp,
3355
+ assistantCta,
3340
3356
  profile,
3341
- versionText = "v2.1.2",
3342
3357
  toggleIcon,
3343
3358
  openSections,
3344
3359
  onSectionToggle,
@@ -3416,40 +3431,24 @@ var ScArtifaxSidebar = ({
3416
3431
  ] }, section.id);
3417
3432
  })
3418
3433
  ] }),
3419
- creditWarning ? /* @__PURE__ */ jsxs33(Fragment15, { children: [
3420
- /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ jsx41(
3421
- CreditWarningBanner,
3422
- {
3423
- availableCredits: creditWarning.availableCredits,
3424
- remainingPct: creditWarning.remainingPct,
3425
- level: creditWarning.level ?? "danger",
3426
- onBuyCredits: creditWarning.onBuyCredits,
3427
- expanded: true
3428
- }
3429
- ) }),
3430
- /* @__PURE__ */ jsx41(ScHDivider, {})
3431
- ] }) : null,
3432
- switchApp ? /* @__PURE__ */ jsxs33(Fragment15, { children: [
3433
- /* @__PURE__ */ jsxs33(
3434
- "button",
3435
- {
3436
- type: "button",
3437
- className: ScArtifaxSidebar_default.switchAppRow,
3438
- onClick: switchApp.onClick,
3439
- children: [
3440
- /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.switchAppIconBox, children: switchApp.icon ?? /* @__PURE__ */ jsx41(SiconAppSwitch, {}) }),
3441
- /* @__PURE__ */ jsx41("span", { className: ScArtifaxSidebar_default.switchAppLabel, children: switchApp.label ?? "Switch App" })
3442
- ]
3443
- }
3444
- ),
3445
- /* @__PURE__ */ jsx41(ScHDivider, {})
3446
- ] }) : null,
3447
- profile ? /* @__PURE__ */ jsxs33(Fragment15, { children: [
3448
- /* @__PURE__ */ jsxs33(
3434
+ creditWarning ? /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ jsx41(
3435
+ CreditWarningBanner,
3436
+ {
3437
+ availableCredits: creditWarning.availableCredits,
3438
+ remainingPct: creditWarning.remainingPct,
3439
+ level: creditWarning.level ?? "danger",
3440
+ onBuyCredits: creditWarning.onBuyCredits,
3441
+ expanded: true
3442
+ }
3443
+ ) }) : null,
3444
+ assistantCta ? /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.askAgentSlot, children: /* @__PURE__ */ jsx41(AskAgentButton, { cta: assistantCta, collapsed: false }) }) : null,
3445
+ /* @__PURE__ */ jsx41(ScHDivider, {}),
3446
+ /* @__PURE__ */ jsxs33("div", { className: ScArtifaxSidebar_default.profileRow, children: [
3447
+ profile ? /* @__PURE__ */ jsxs33(
3449
3448
  "button",
3450
3449
  {
3451
3450
  type: "button",
3452
- className: ScArtifaxSidebar_default.profileRow,
3451
+ className: ScArtifaxSidebar_default.profileMain,
3453
3452
  onClick: profile.onClick,
3454
3453
  children: [
3455
3454
  /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.profileAvatar, children: profile.avatar }),
@@ -3459,11 +3458,7 @@ var ScArtifaxSidebar = ({
3459
3458
  ] })
3460
3459
  ]
3461
3460
  }
3462
- ),
3463
- /* @__PURE__ */ jsx41(ScHDivider, {})
3464
- ] }) : null,
3465
- /* @__PURE__ */ jsxs33("div", { className: ScArtifaxSidebar_default.footerExpanded, children: [
3466
- /* @__PURE__ */ jsx41("span", { className: ScArtifaxSidebar_default.footerVersion, children: versionText }),
3461
+ ) : /* @__PURE__ */ jsx41("span", { className: ScArtifaxSidebar_default.profileMain, "aria-hidden": "true" }),
3467
3462
  /* @__PURE__ */ jsx41(
3468
3463
  "button",
3469
3464
  {
@@ -3493,34 +3488,20 @@ var ScArtifaxSidebar = ({
3493
3488
  /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.sectionContainerCollapsed, children: section.items.map((item) => renderMenuItem2(item, section.id)) })
3494
3489
  ] }, section.id))
3495
3490
  ] }),
3496
- creditWarning ? /* @__PURE__ */ jsxs33(Fragment15, { children: [
3497
- /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ jsx41(
3498
- CreditWarningBanner,
3499
- {
3500
- availableCredits: creditWarning.availableCredits,
3501
- remainingPct: creditWarning.remainingPct,
3502
- level: creditWarning.level ?? "danger",
3503
- onBuyCredits: creditWarning.onBuyCredits,
3504
- expanded: false
3505
- }
3506
- ) }),
3507
- /* @__PURE__ */ jsx41(ScHDivider, {})
3508
- ] }) : null,
3509
- switchApp ? /* @__PURE__ */ jsxs33(Fragment15, { children: [
3510
- /* @__PURE__ */ jsx41(
3511
- "button",
3512
- {
3513
- type: "button",
3514
- className: ScArtifaxSidebar_default.switchAppRowCollapsed,
3515
- onClick: switchApp.onClick,
3516
- "aria-label": switchApp.label ?? "Switch App",
3517
- children: switchApp.icon ?? /* @__PURE__ */ jsx41(SiconAppSwitch, {})
3518
- }
3519
- ),
3520
- /* @__PURE__ */ jsx41(ScHDivider, {})
3521
- ] }) : null,
3522
- profile ? /* @__PURE__ */ jsxs33(Fragment15, { children: [
3523
- /* @__PURE__ */ jsx41(
3491
+ creditWarning ? /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.creditWarningSlot, children: /* @__PURE__ */ jsx41(
3492
+ CreditWarningBanner,
3493
+ {
3494
+ availableCredits: creditWarning.availableCredits,
3495
+ remainingPct: creditWarning.remainingPct,
3496
+ level: creditWarning.level ?? "danger",
3497
+ onBuyCredits: creditWarning.onBuyCredits,
3498
+ expanded: false
3499
+ }
3500
+ ) }) : null,
3501
+ assistantCta ? /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.askAgentSlotCollapsed, children: /* @__PURE__ */ jsx41(AskAgentButton, { cta: assistantCta, collapsed: true }) }) : null,
3502
+ /* @__PURE__ */ jsx41(ScHDivider, {}),
3503
+ /* @__PURE__ */ jsxs33("div", { className: ScArtifaxSidebar_default.footerCollapsed, children: [
3504
+ profile ? /* @__PURE__ */ jsx41(
3524
3505
  "button",
3525
3506
  {
3526
3507
  type: "button",
@@ -3529,10 +3510,7 @@ var ScArtifaxSidebar = ({
3529
3510
  "aria-label": profile.name,
3530
3511
  children: /* @__PURE__ */ jsx41("div", { className: ScArtifaxSidebar_default.profileAvatar, children: profile.avatar })
3531
3512
  }
3532
- ),
3533
- /* @__PURE__ */ jsx41(ScHDivider, {})
3534
- ] }) : null,
3535
- /* @__PURE__ */ jsxs33("div", { className: ScArtifaxSidebar_default.footerCollapsed, children: [
3513
+ ) : null,
3536
3514
  /* @__PURE__ */ jsx41(
3537
3515
  "button",
3538
3516
  {
@@ -3542,8 +3520,7 @@ var ScArtifaxSidebar = ({
3542
3520
  "aria-label": "Expand sidebar",
3543
3521
  children: resolveToggleIcon2(toggleIcon, false)
3544
3522
  }
3545
- ),
3546
- /* @__PURE__ */ jsx41("span", { className: ScArtifaxSidebar_default.footerVersionCenter, children: versionText })
3523
+ )
3547
3524
  ] })
3548
3525
  ] })
3549
3526
  }
@@ -3632,7 +3609,8 @@ var ScSideBarLogoUnit_default = {
3632
3609
  switch: "ScSideBarLogoUnit_switch",
3633
3610
  switchIcon: "ScSideBarLogoUnit_switchIcon",
3634
3611
  collapsed: "ScSideBarLogoUnit_collapsed",
3635
- collapsedTrigger: "ScSideBarLogoUnit_collapsedTrigger"
3612
+ collapsedTrigger: "ScSideBarLogoUnit_collapsedTrigger",
3613
+ collapsedWordmarkSlot: "ScSideBarLogoUnit_collapsedWordmarkSlot"
3636
3614
  };
3637
3615
 
3638
3616
  // src/SC-SideBarLogoUnit/ScSideBarLogoUnit.tsx
@@ -3657,21 +3635,30 @@ var ScSideBarLogoUnit = ({
3657
3635
  onSwitchClick?.();
3658
3636
  };
3659
3637
  if (state === "collapsed") {
3638
+ const collapsedClasses = [
3639
+ ScSideBarLogoUnit_default.collapsedTrigger,
3640
+ interactive ? "" : ScSideBarLogoUnit_default.nonInteractive,
3641
+ hover === true ? ScSideBarLogoUnit_default.forceHover : ""
3642
+ ].filter(Boolean).join(" ");
3660
3643
  return /* @__PURE__ */ jsx43(
3661
3644
  "div",
3662
3645
  {
3663
3646
  className: ScSideBarLogoUnit_default.scSideBarLogoUnit + " " + ScSideBarLogoUnit_default.collapsed + (className ? " " + className : ""),
3664
3647
  style,
3665
- children: /* @__PURE__ */ jsx43(
3648
+ children: /* @__PURE__ */ jsxs35(
3666
3649
  "button",
3667
3650
  {
3668
3651
  type: "button",
3669
- className: ScSideBarLogoUnit_default.collapsedTrigger + (interactive ? "" : " " + ScSideBarLogoUnit_default.nonInteractive),
3652
+ className: collapsedClasses,
3670
3653
  onClick: interactive ? handleClick : void 0,
3671
3654
  disabled,
3672
3655
  "aria-label": interactive ? switchAriaLabel : void 0,
3673
3656
  "aria-disabled": !interactive || disabled,
3674
- children: wordmark
3657
+ style: hover === false ? { backgroundColor: "transparent" } : void 0,
3658
+ children: [
3659
+ /* @__PURE__ */ jsx43("span", { className: ScSideBarLogoUnit_default.collapsedWordmarkSlot, children: wordmark }),
3660
+ hideSwitch ? null : /* @__PURE__ */ jsx43("span", { className: ScSideBarLogoUnit_default.switch, children: /* @__PURE__ */ jsx43("span", { className: ScSideBarLogoUnit_default.switchIcon, children: /* @__PURE__ */ jsx43(SiconDoubleArrow, { size: 16, strokeWidth: 1.5 }) }) })
3661
+ ]
3675
3662
  }
3676
3663
  )
3677
3664
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@streamoid/ui",
3
- "version": "0.4.7",
3
+ "version": "0.4.9",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",