@juspay/blend-design-system 0.0.24-beta → 0.0.24

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.
Files changed (34) hide show
  1. package/dist/components/Avatar/StyledAvatar.d.ts +0 -7
  2. package/dist/components/Avatar/avatar.tokens.d.ts +6 -4
  3. package/dist/components/Avatar/avatarUtils.d.ts +7 -0
  4. package/dist/components/Avatar/types.d.ts +1 -1
  5. package/dist/components/Button/Button.d.ts +3 -0
  6. package/dist/components/Button/ButtonBase.d.ts +11 -0
  7. package/dist/components/Button/types.d.ts +4 -0
  8. package/dist/components/ChatInput/ChatInput.d.ts +23 -2
  9. package/dist/components/ChatInput/types.d.ts +3 -4
  10. package/dist/components/ChatInput/utils.d.ts +0 -4
  11. package/dist/components/CodeEditor/CodeEditor.d.ts +3 -0
  12. package/dist/components/CodeEditor/CodeEditorHeader.d.ts +13 -0
  13. package/dist/components/CodeEditor/MonacoEditorWrapper.d.ts +18 -0
  14. package/dist/components/CodeEditor/index.d.ts +2 -0
  15. package/dist/components/CodeEditor/types.d.ts +27 -0
  16. package/dist/components/CodeEditor/utils.d.ts +9 -0
  17. package/dist/components/Inputs/MultiValueInput/MultiValueInput.d.ts +1 -1
  18. package/dist/components/Inputs/MultiValueInput/types.d.ts +2 -1
  19. package/dist/components/Skeleton/SkeletonCompound.d.ts +0 -15
  20. package/dist/components/Skeleton/hooks/useSkeletonBase.d.ts +0 -4
  21. package/dist/components/Skeleton/index.d.ts +2 -2
  22. package/dist/components/Skeleton/types.d.ts +0 -12
  23. package/dist/components/Skeleton/utils.d.ts +18 -0
  24. package/dist/components/Snackbar/Snackbar.d.ts +6 -3
  25. package/dist/components/Snackbar/types.d.ts +9 -0
  26. package/dist/components/Tags/Tag.d.ts +15 -0
  27. package/dist/components/Tags/TagBase.d.ts +20 -0
  28. package/dist/components/Tags/index.d.ts +1 -1
  29. package/dist/components/Tags/types.d.ts +7 -2
  30. package/dist/main.d.ts +1 -0
  31. package/dist/main.js +21820 -20487
  32. package/package.json +3 -1
  33. package/dist/components/Skeleton/SkeletonButton.d.ts +0 -13
  34. package/dist/components/Tags/Tags.d.ts +0 -3
@@ -1,8 +1 @@
1
- import { StyledAvatarContainerProps, StyledAvatarIndicatorProps } from './types';
2
- export declare const StyledAvatarContainer: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, StyledAvatarContainerProps>> & string;
3
1
  export declare const StyledAvatarImage: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, never>> & string;
4
- export declare const StyledAvatarFallback: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
5
- export declare const StyledAvatarIndicator: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, StyledAvatarIndicatorProps>> & string;
6
- export declare const StyledAvatarWrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
7
- export declare const StyledAvatarLeadingSlot: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
8
- export declare const StyledAvatarTrailingSlot: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
@@ -11,7 +11,7 @@ export type AvatarVariant = 'withImage' | 'withoutImage';
11
11
  *
12
12
  * Structure:
13
13
  * - gap: Spacing between avatar and slots
14
- * - container: Main avatar container properties
14
+ * - avatar: Main avatar container properties
15
15
  * - text: Fallback text styling
16
16
  * - indicator: Online status indicator
17
17
  * - slot: Leading and trailing slot styling
@@ -55,9 +55,11 @@ export type AvatarTokensType = {
55
55
  [key in AvatarState]: CSSObject['backgroundColor'];
56
56
  };
57
57
  border: {
58
- [key in AvatarState]: {
59
- color: CSSObject['borderColor'];
60
- width: CSSObject['borderWidth'];
58
+ [key in AvatarSize]: {
59
+ [key in AvatarState]: {
60
+ color: CSSObject['borderColor'];
61
+ width: CSSObject['borderWidth'];
62
+ };
61
63
  };
62
64
  };
63
65
  size: {
@@ -5,3 +5,10 @@ export declare const hexToRgb: (hex: string) => {
5
5
  g: number;
6
6
  b: number;
7
7
  } | null;
8
+ /**
9
+ * Get a consistent color for an avatar based on the full name/text
10
+ * Uses hash of the entire text to ensure unique colors for different names
11
+ * @param text - The text to generate color from (e.g., name or alt text)
12
+ * @returns A hex color code
13
+ */
14
+ export declare const getColorFromText: (text: string) => string;
@@ -1,7 +1,7 @@
1
1
  import { HTMLAttributes } from 'react';
2
2
  export declare enum AvatarSize {
3
- XS = "xs",
4
3
  SM = "sm",
4
+ REGULAR = "regular",
5
5
  MD = "md",
6
6
  LG = "lg",
7
7
  XL = "xl"
@@ -9,8 +9,11 @@ declare const Button: import('react').ForwardRefExoticComponent<{
9
9
  disabled?: boolean;
10
10
  onClick?: () => void;
11
11
  loading?: boolean;
12
+ showSkeleton?: boolean;
13
+ skeletonVariant?: import('../Skeleton').SkeletonVariant;
12
14
  buttonGroupPosition?: "center" | "left" | "right";
13
15
  fullWidth?: boolean;
16
+ width?: string | number;
14
17
  justifyContent?: import('styled-components').CSSObject["justifyContent"];
15
18
  state?: ButtonState;
16
19
  } & Omit<import('react').ButtonHTMLAttributes<HTMLButtonElement>, "style" | "className"> & import('react').RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1,11 @@
1
+ import { ButtonProps } from './types';
2
+ import { ButtonTokensType } from './button.tokens';
3
+ export type ButtonBaseProps = Omit<ButtonProps, 'showSkeleton' | 'skeletonVariant'> & {
4
+ isSkeleton?: boolean;
5
+ tokens?: ButtonTokensType;
6
+ };
7
+ declare const ButtonBase: import('react').ForwardRefExoticComponent<Omit<ButtonProps, "showSkeleton" | "skeletonVariant"> & {
8
+ isSkeleton?: boolean;
9
+ tokens?: ButtonTokensType;
10
+ } & import('react').RefAttributes<HTMLButtonElement>>;
11
+ export default ButtonBase;
@@ -1,5 +1,6 @@
1
1
  import { default as React } from 'react';
2
2
  import { CSSObject } from 'styled-components';
3
+ import { SkeletonVariant } from '../Skeleton/skeleton.tokens';
3
4
  export declare enum ButtonType {
4
5
  PRIMARY = "primary",
5
6
  SECONDARY = "secondary",
@@ -32,8 +33,11 @@ export type ButtonProps = {
32
33
  disabled?: boolean;
33
34
  onClick?: () => void;
34
35
  loading?: boolean;
36
+ showSkeleton?: boolean;
37
+ skeletonVariant?: SkeletonVariant;
35
38
  buttonGroupPosition?: 'center' | 'left' | 'right';
36
39
  fullWidth?: boolean;
40
+ width?: string | number;
37
41
  justifyContent?: CSSObject['justifyContent'];
38
42
  state?: ButtonState;
39
43
  } & Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'style' | 'className'>;
@@ -1,5 +1,26 @@
1
1
  import { default as React } from 'react';
2
- import { ChatInputProps, AttachedFile } from './types';
2
+ import { AttachedFile, TopQuery } from './types';
3
3
  export declare const getDocIcon: (fileType: AttachedFile["type"]) => React.ReactNode;
4
- declare const ChatInput: React.ForwardRefExoticComponent<ChatInputProps & React.RefAttributes<HTMLTextAreaElement>>;
4
+ declare const ChatInput: React.ForwardRefExoticComponent<Omit<React.TextareaHTMLAttributes<HTMLTextAreaElement>, "value" | "onChange"> & {
5
+ value?: string;
6
+ slot1?: React.ReactNode;
7
+ onChange?: (value: string) => void;
8
+ onSend?: (message: string, files: AttachedFile[]) => void;
9
+ onAttachFiles?: (files: File[]) => void;
10
+ onVoiceRecord?: () => void;
11
+ onFileRemove?: (fileId: string) => void;
12
+ onFileClick?: (file: AttachedFile) => void;
13
+ placeholder?: string;
14
+ disabled?: boolean;
15
+ maxLength?: number;
16
+ autoResize?: boolean;
17
+ attachedFiles?: AttachedFile[];
18
+ topQueries?: TopQuery[];
19
+ onTopQuerySelect?: (query: TopQuery) => void;
20
+ topQueriesMaxHeight?: number;
21
+ attachButtonIcon?: React.ReactNode;
22
+ voiceButtonIcon?: React.ReactNode;
23
+ sendButtonIcon?: React.ReactNode;
24
+ overflowMenuProps?: Partial<import('../Menu').MenuProps>;
25
+ } & React.RefAttributes<HTMLTextAreaElement>>;
5
26
  export default ChatInput;
@@ -1,4 +1,4 @@
1
- import { ReactNode } from 'react';
1
+ import { ReactNode, TextareaHTMLAttributes } from 'react';
2
2
  import { MenuProps } from '../Menu/types';
3
3
  export type AttachedFile = {
4
4
  id: string;
@@ -12,8 +12,9 @@ export type TopQuery = {
12
12
  id: string;
13
13
  text: string;
14
14
  };
15
- export type ChatInputProps = {
15
+ export type ChatInputProps = Omit<TextareaHTMLAttributes<HTMLTextAreaElement>, 'onChange' | 'value'> & {
16
16
  value?: string;
17
+ slot1?: ReactNode;
17
18
  onChange?: (value: string) => void;
18
19
  onSend?: (message: string, files: AttachedFile[]) => void;
19
20
  onAttachFiles?: (files: File[]) => void;
@@ -32,8 +33,6 @@ export type ChatInputProps = {
32
33
  voiceButtonIcon?: ReactNode;
33
34
  sendButtonIcon?: ReactNode;
34
35
  overflowMenuProps?: Partial<MenuProps>;
35
- 'aria-label'?: string;
36
- 'aria-describedby'?: string;
37
36
  };
38
37
  export type ChatInputTokens = {
39
38
  container: {
@@ -12,10 +12,6 @@ export declare const createOverflowMenuItems: (hiddenFiles: AttachedFile[], onFi
12
12
  * Handle textarea auto-resize functionality
13
13
  */
14
14
  export declare const handleAutoResize: (element: HTMLTextAreaElement | null, autoResize: boolean) => void;
15
- /**
16
- * Check if Enter key should trigger send
17
- */
18
- export declare const shouldSendOnEnter: (key: string, shiftKey: boolean, metaKey: boolean, ctrlKey: boolean) => boolean;
19
15
  /**
20
16
  * Validate message length against maxLength
21
17
  */
@@ -0,0 +1,3 @@
1
+ import { CodeEditorProps } from './types';
2
+ declare const CodeEditor: import('react').ForwardRefExoticComponent<CodeEditorProps & import('react').RefAttributes<HTMLDivElement>>;
3
+ export default CodeEditor;
@@ -0,0 +1,13 @@
1
+ import { CodeBlockTokenType } from '../CodeBlock/codeBlock.token';
2
+ import { ReactNode } from 'react';
3
+ type CodeEditorHeaderProps = {
4
+ header: string;
5
+ headerLeftSlot?: ReactNode;
6
+ headerRightSlot?: ReactNode;
7
+ showCopyButton: boolean;
8
+ isCopied: boolean;
9
+ onCopy: () => void;
10
+ tokens: CodeBlockTokenType;
11
+ };
12
+ export declare const CodeEditorHeader: ({ header, headerLeftSlot, headerRightSlot, showCopyButton, isCopied, onCopy, tokens, }: CodeEditorHeaderProps) => import("react/jsx-runtime").JSX.Element;
13
+ export {};
@@ -0,0 +1,18 @@
1
+ import { CodeBlockTokenType } from '../CodeBlock/codeBlock.token';
2
+ type MonacoEditorWrapperProps = {
3
+ value: string;
4
+ language: string;
5
+ onChange?: (value: string) => void;
6
+ readOnly: boolean;
7
+ disabled: boolean;
8
+ placeholder?: string;
9
+ showLineNumbers: boolean;
10
+ minHeight: string | number;
11
+ maxHeight?: string | number;
12
+ height?: string | number;
13
+ tokens: CodeBlockTokenType;
14
+ onFocus?: () => void;
15
+ onBlur?: () => void;
16
+ };
17
+ export declare const MonacoEditorWrapper: ({ value, language, onChange, readOnly, disabled, placeholder, showLineNumbers, minHeight, maxHeight, height, tokens, onFocus, onBlur, }: MonacoEditorWrapperProps) => import("react/jsx-runtime").JSX.Element;
18
+ export {};
@@ -0,0 +1,2 @@
1
+ export { default as CodeEditor } from './CodeEditor';
2
+ export * from './types';
@@ -0,0 +1,27 @@
1
+ import { ReactNode } from 'react';
2
+ import { SupportedLanguage } from '../CodeBlock/types';
3
+ export declare enum CodeEditorVariant {
4
+ DEFAULT = "default",
5
+ NO_GUTTER = "no-gutter"
6
+ }
7
+ export type CodeEditorProps = {
8
+ value: string;
9
+ onChange?: (value: string) => void;
10
+ variant?: CodeEditorVariant;
11
+ showLineNumbers?: boolean;
12
+ showHeader?: boolean;
13
+ header?: string;
14
+ headerLeftSlot?: ReactNode;
15
+ headerRightSlot?: ReactNode;
16
+ showCopyButton?: boolean;
17
+ language?: SupportedLanguage;
18
+ placeholder?: string;
19
+ readOnly?: boolean;
20
+ disabled?: boolean;
21
+ minHeight?: string | number;
22
+ maxHeight?: string | number;
23
+ height?: string | number;
24
+ className?: string;
25
+ onBlur?: () => void;
26
+ onFocus?: () => void;
27
+ };
@@ -0,0 +1,9 @@
1
+ import { CodeEditorVariant } from './types';
2
+ /**
3
+ * Determines if line numbers should be shown
4
+ */
5
+ export declare const shouldShowLineNumbers: (showLineNumbers: boolean | undefined, variant: CodeEditorVariant) => boolean;
6
+ /**
7
+ * Calculates container styles with min/max height
8
+ */
9
+ export declare const getContainerStyles: (minHeight?: string | number, maxHeight?: string | number) => React.CSSProperties;
@@ -1,3 +1,3 @@
1
1
  import { MultiValueInputProps } from './types';
2
- declare const MultiValueInput: ({ label, sublabel, disabled, required, error, errorMessage, hintText, tags, onTagAdd, onTagRemove, onChange, size, ...rest }: MultiValueInputProps) => import("react/jsx-runtime").JSX.Element;
2
+ declare const MultiValueInput: ({ value, label, sublabel, disabled, required, error, errorMessage, hintText, tags, onTagAdd, onTagRemove, onChange, size, ...rest }: MultiValueInputProps) => import("react/jsx-runtime").JSX.Element;
3
3
  export default MultiValueInput;
@@ -12,6 +12,7 @@ export declare enum MultiValueInputState {
12
12
  DISABLED = "disabled"
13
13
  }
14
14
  export type MultiValueInputProps = {
15
+ value?: string;
15
16
  label?: string;
16
17
  sublabel?: string;
17
18
  helpIconHintText?: string;
@@ -24,4 +25,4 @@ export type MultiValueInputProps = {
24
25
  onTagRemove?: (tag: string) => void;
25
26
  onChange?: (value: string) => void;
26
27
  size?: TextInputSize;
27
- } & Omit<React.InputHTMLAttributes<HTMLInputElement>, 'size' | 'style' | 'className' | 'onChange'>;
28
+ } & Omit<React.InputHTMLAttributes<HTMLInputElement>, 'size' | 'style' | 'className' | 'onChange' | 'value'>;
@@ -6,7 +6,6 @@ import { SkeletonProps } from './types';
6
6
  * <Skeleton loading={true}>
7
7
  * <Skeleton.Avatar size="md" />
8
8
  * <Skeleton.Text lines={2} />
9
- * <Skeleton.Button />
10
9
  * </Skeleton>
11
10
  *
12
11
  * Or traditional:
@@ -26,20 +25,6 @@ declare const SkeletonCompound: import('react').ForwardRefExoticComponent<import
26
25
  size?: import('./types').SkeletonSize;
27
26
  shape?: "circle" | "square";
28
27
  } & import('react').RefAttributes<HTMLDivElement>>;
29
- /**
30
- * Button skeleton with perfect token mirroring and dynamic sizing
31
- */
32
- Button: import('react').ForwardRefExoticComponent<import('./types').BaseSkeletonProps & Omit<import('../Primitives/Block/Block').BlockProps, "children"> & {
33
- buttonType?: import('../Button').ButtonType;
34
- size?: import('../Button').ButtonSize;
35
- subType?: import('../Button').ButtonSubType;
36
- width?: string | number;
37
- fullWidth?: boolean;
38
- buttonGroupPosition?: "center" | "left" | "right";
39
- text?: string;
40
- hasLeadingIcon?: boolean;
41
- hasTrailingIcon?: boolean;
42
- } & import('react').RefAttributes<HTMLDivElement>>;
43
28
  /**
44
29
  * Card skeleton with default layout or custom children
45
30
  */
@@ -15,7 +15,3 @@ export declare const useSkeletonBase: (loading: boolean, children?: ReactNode) =
15
15
  tokens: SkeletonTokensType;
16
16
  prefersReducedMotion: boolean;
17
17
  };
18
- /**
19
- * Common skeleton component props validation and defaults
20
- */
21
- export declare const useSkeletonDefaults: <T extends Record<string, unknown>>(props: T, defaults: Partial<T>) => T;
@@ -1,10 +1,10 @@
1
1
  export { default as Skeleton } from './SkeletonCompound';
2
2
  export { default as SkeletonBase } from './Skeleton';
3
3
  export { default as SkeletonAvatar } from './SkeletonAvatar';
4
- export { default as SkeletonButton } from './SkeletonButton';
5
4
  export { default as SkeletonCard } from './SkeletonCard';
6
5
  export { useSkeletonBase } from './hooks/useSkeletonBase';
7
- export type { SkeletonProps, SkeletonAvatarProps, SkeletonButtonProps, SkeletonCardProps, SkeletonSize, BaseSkeletonProps, SkeletonVariant, SkeletonShape, } from './types';
6
+ export { getSkeletonState, mergeSkeletonProps, getSkeletonDefaults, } from './utils';
7
+ export type { SkeletonProps, SkeletonAvatarProps, SkeletonCardProps, SkeletonSize, BaseSkeletonProps, SkeletonVariant, SkeletonShape, } from './types';
8
8
  export type { SkeletonTokensType, ResponsiveSkeletonTokens, } from './skeleton.tokens';
9
9
  export { getSkeletonTokens } from './skeleton.tokens';
10
10
  export { default } from './SkeletonCompound';
@@ -1,7 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { BlockProps } from '../Primitives/Block/Block';
3
3
  import { SkeletonVariant, SkeletonShape } from './skeleton.tokens';
4
- import { ButtonType, ButtonSize, ButtonSubType } from '../Button/types';
5
4
  export type SkeletonSize = 'sm' | 'md' | 'lg';
6
5
  export type BaseSkeletonProps = {
7
6
  variant?: SkeletonVariant;
@@ -19,17 +18,6 @@ export type SkeletonAvatarProps = BaseSkeletonProps & Omit<BlockProps, 'children
19
18
  size?: SkeletonSize;
20
19
  shape?: 'circle' | 'square';
21
20
  };
22
- export type SkeletonButtonProps = BaseSkeletonProps & Omit<BlockProps, 'children'> & {
23
- buttonType?: ButtonType;
24
- size?: ButtonSize;
25
- subType?: ButtonSubType;
26
- width?: string | number;
27
- fullWidth?: boolean;
28
- buttonGroupPosition?: 'center' | 'left' | 'right';
29
- text?: string;
30
- hasLeadingIcon?: boolean;
31
- hasTrailingIcon?: boolean;
32
- };
33
21
  export type SkeletonCardProps = BaseSkeletonProps & Omit<BlockProps, 'children'> & {
34
22
  children?: ReactNode;
35
23
  padding?: string | number;
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Simple utility function for skeleton state logic
3
+ * Not a hook since it doesn't call any React hooks internally
4
+ */
5
+ export declare function getSkeletonState(showSkeleton: boolean): {
6
+ shouldShowSkeleton: boolean;
7
+ shouldShowContent: boolean;
8
+ };
9
+ /**
10
+ * Helper function for merging component props with skeleton props
11
+ * Not a hook since it's just a pure utility function
12
+ */
13
+ export declare function mergeSkeletonProps<TComponentProps, TSkeletonProps>(componentProps: TComponentProps, skeletonProps?: Partial<TSkeletonProps>): TComponentProps & Partial<TSkeletonProps>;
14
+ /**
15
+ * Common skeleton component props validation and defaults
16
+ * Renamed from useSkeletonDefaults since it's not a hook
17
+ */
18
+ export declare function getSkeletonDefaults<T extends Record<string, unknown>>(props: T, defaults: Partial<T>): T;
@@ -1,6 +1,9 @@
1
1
  import { default as React } from 'react';
2
- import { Toaster as Snackbar } from 'sonner';
3
- import { AddToastOptions, CustomToastProps } from './types';
2
+ import { AddToastOptions, CustomToastProps, SnackbarPosition } from './types';
4
3
  export declare const StyledToast: React.FC<CustomToastProps>;
5
- export declare const addSnackbar: ({ header, description, variant, onClose, actionButton, duration, }: AddToastOptions) => string | number;
4
+ export declare const addSnackbar: ({ header, description, variant, onClose, actionButton, duration, position, }: AddToastOptions) => string | number;
5
+ type SnackbarProps = {
6
+ position?: SnackbarPosition;
7
+ };
8
+ declare const Snackbar: React.FC<SnackbarProps>;
6
9
  export default Snackbar;
@@ -4,6 +4,14 @@ export declare enum SnackbarVariant {
4
4
  WARNING = "warning",
5
5
  ERROR = "error"
6
6
  }
7
+ export declare enum SnackbarPosition {
8
+ TOP_LEFT = "top-left",
9
+ TOP_RIGHT = "top-right",
10
+ BOTTOM_LEFT = "bottom-left",
11
+ BOTTOM_RIGHT = "bottom-right",
12
+ TOP_CENTER = "top-center",
13
+ BOTTOM_CENTER = "bottom-center"
14
+ }
7
15
  export type AddToastOptions = {
8
16
  header: string;
9
17
  description?: string;
@@ -15,6 +23,7 @@ export type AddToastOptions = {
15
23
  autoDismiss?: boolean;
16
24
  };
17
25
  duration?: number;
26
+ position?: SnackbarPosition;
18
27
  };
19
28
  export type CustomToastProps = {
20
29
  header: string;
@@ -0,0 +1,15 @@
1
+ import { TagColor, TagShape, TagSize, TagVariant } from './types';
2
+ declare const Tag: import('react').ForwardRefExoticComponent<Omit<import('../Primitives/Block/Block').BlockProps, "children"> & {
3
+ text: string;
4
+ variant?: TagVariant;
5
+ color?: TagColor;
6
+ size?: TagSize;
7
+ shape?: TagShape;
8
+ leftSlot?: import('react').ReactNode;
9
+ rightSlot?: import('react').ReactNode;
10
+ splitTagPosition?: "left" | "right";
11
+ } & {
12
+ showSkeleton?: boolean;
13
+ skeletonVariant?: import('../Skeleton').SkeletonVariant;
14
+ } & import('react').RefAttributes<HTMLDivElement>>;
15
+ export default Tag;
@@ -0,0 +1,20 @@
1
+ import { TagTokensType } from './tag.tokens';
2
+ import { TagProps, TagColor, TagShape, TagSize, TagVariant } from './types';
3
+ export type TagBaseProps = TagProps & {
4
+ isSkeleton?: boolean;
5
+ tokens?: TagTokensType;
6
+ };
7
+ declare const TagBase: import('react').ForwardRefExoticComponent<Omit<import('../Primitives/Block/Block').BlockProps, "children"> & {
8
+ text: string;
9
+ variant?: TagVariant;
10
+ color?: TagColor;
11
+ size?: TagSize;
12
+ shape?: TagShape;
13
+ leftSlot?: import('react').ReactNode;
14
+ rightSlot?: import('react').ReactNode;
15
+ splitTagPosition?: "left" | "right";
16
+ } & {
17
+ isSkeleton?: boolean;
18
+ tokens?: TagTokensType;
19
+ } & import('react').RefAttributes<HTMLDivElement>>;
20
+ export default TagBase;
@@ -1,2 +1,2 @@
1
- export { default as Tag } from './Tags';
1
+ export { default as Tag } from './Tag';
2
2
  export * from './types';
@@ -1,4 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
+ import { SkeletonVariant } from '../Skeleton/skeleton.tokens';
3
+ import { BlockProps } from '../Primitives/Block/Block';
2
4
  export declare enum TagVariant {
3
5
  NO_FILL = "noFill",
4
6
  ATTENTIVE = "attentive",
@@ -22,7 +24,7 @@ export declare enum TagShape {
22
24
  ROUNDED = "rounded",
23
25
  SQUARICAL = "squarical"
24
26
  }
25
- export type TagProps = {
27
+ export type TagProps = Omit<BlockProps, 'children'> & {
26
28
  text: string;
27
29
  variant?: TagVariant;
28
30
  color?: TagColor;
@@ -30,6 +32,9 @@ export type TagProps = {
30
32
  shape?: TagShape;
31
33
  leftSlot?: ReactNode;
32
34
  rightSlot?: ReactNode;
33
- onClick?: () => void;
34
35
  splitTagPosition?: 'left' | 'right';
35
36
  };
37
+ export type TagWithSkeletonProps = TagProps & {
38
+ showSkeleton?: boolean;
39
+ skeletonVariant?: SkeletonVariant;
40
+ };
package/dist/main.d.ts CHANGED
@@ -37,6 +37,7 @@ export * from './components/Upload';
37
37
  export * from './components/WorkflowCanvas';
38
38
  export * from './components/ChatInput';
39
39
  export * from './components/CodeBlock';
40
+ export * from './components/CodeEditor';
40
41
  export * from './components/ButtonGroup';
41
42
  export * from './components/Button';
42
43
  export * from './context';