@runtypelabs/persona 3.6.0 → 3.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -374,6 +374,18 @@ export const DEFAULT_COMPONENTS: ComponentTokens = {
374
374
  border: 'palette.colors.gray.200',
375
375
  },
376
376
  },
377
+ scrollToBottom: {
378
+ background: 'components.button.primary.background',
379
+ foreground: 'components.button.primary.foreground',
380
+ border: 'semantic.colors.primary',
381
+ size: '40px',
382
+ borderRadius: 'palette.radius.full',
383
+ shadow: 'palette.shadows.sm',
384
+ padding: '0.5rem 0.875rem',
385
+ gap: '0.5rem',
386
+ fontSize: '0.875rem',
387
+ iconSize: '14px',
388
+ },
377
389
  artifact: {
378
390
  pane: {
379
391
  background: 'semantic.colors.container',
@@ -656,6 +668,7 @@ export function themeToCssVariables(theme: PersonaTheme): Record<string, string>
656
668
  cssVars['--persona-radius-md'] = cssVars['--persona-palette-radius-md'] ?? '0.375rem';
657
669
  cssVars['--persona-radius-lg'] = cssVars['--persona-palette-radius-lg'] ?? '0.5rem';
658
670
  cssVars['--persona-radius-xl'] = cssVars['--persona-palette-radius-xl'] ?? '0.75rem';
671
+ cssVars['--persona-radius-full'] = cssVars['--persona-palette-radius-full'] ?? '9999px';
659
672
  cssVars['--persona-launcher-radius'] =
660
673
  cssVars['--persona-components-launcher-borderRadius'] ??
661
674
  cssVars['--persona-palette-radius-full'] ??
@@ -742,6 +755,42 @@ export function themeToCssVariables(theme: PersonaTheme): Record<string, string>
742
755
  cssVars['--persona-components-message-assistant-border'] ?? cssVars['--persona-border'];
743
756
  cssVars['--persona-message-assistant-shadow'] =
744
757
  cssVars['--persona-components-message-assistant-shadow'] ?? '0 1px 2px 0 rgb(0 0 0 / 0.05)';
758
+ cssVars['--persona-scroll-to-bottom-bg'] =
759
+ cssVars['--persona-components-scrollToBottom-background'] ??
760
+ cssVars['--persona-button-primary-bg'] ??
761
+ cssVars['--persona-accent'];
762
+ cssVars['--persona-scroll-to-bottom-fg'] =
763
+ cssVars['--persona-components-scrollToBottom-foreground'] ??
764
+ cssVars['--persona-button-primary-fg'] ??
765
+ cssVars['--persona-text-inverse'];
766
+ cssVars['--persona-scroll-to-bottom-border'] =
767
+ cssVars['--persona-components-scrollToBottom-border'] ??
768
+ cssVars['--persona-primary'];
769
+ cssVars['--persona-scroll-to-bottom-size'] =
770
+ cssVars['--persona-components-scrollToBottom-size'] ??
771
+ '40px';
772
+ cssVars['--persona-scroll-to-bottom-radius'] =
773
+ cssVars['--persona-components-scrollToBottom-borderRadius'] ??
774
+ cssVars['--persona-button-radius'] ??
775
+ cssVars['--persona-radius-full'] ??
776
+ '9999px';
777
+ cssVars['--persona-scroll-to-bottom-shadow'] =
778
+ cssVars['--persona-components-scrollToBottom-shadow'] ??
779
+ cssVars['--persona-palette-shadows-sm'] ??
780
+ '0 1px 2px 0 rgb(0 0 0 / 0.05)';
781
+ cssVars['--persona-scroll-to-bottom-padding'] =
782
+ cssVars['--persona-components-scrollToBottom-padding'] ??
783
+ '0.5rem 0.875rem';
784
+ cssVars['--persona-scroll-to-bottom-gap'] =
785
+ cssVars['--persona-components-scrollToBottom-gap'] ??
786
+ '0.5rem';
787
+ cssVars['--persona-scroll-to-bottom-font-size'] =
788
+ cssVars['--persona-components-scrollToBottom-fontSize'] ??
789
+ cssVars['--persona-palette-typography-fontSize-sm'] ??
790
+ '0.875rem';
791
+ cssVars['--persona-scroll-to-bottom-icon-size'] =
792
+ cssVars['--persona-components-scrollToBottom-iconSize'] ??
793
+ '14px';
745
794
 
746
795
  cssVars['--persona-tool-bubble-shadow'] =
747
796
  cssVars['--persona-components-toolBubble-shadow'] ?? '0 5px 15px rgba(15, 23, 42, 0.08)';