@idealyst/components 1.2.1 → 1.2.3

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 (54) hide show
  1. package/package.json +3 -3
  2. package/src/Accordion/Accordion.web.tsx +4 -0
  3. package/src/Accordion/types.ts +7 -0
  4. package/src/ActivityIndicator/ActivityIndicator.web.tsx +4 -0
  5. package/src/Alert/Alert.web.tsx +4 -0
  6. package/src/Alert/types.ts +7 -0
  7. package/src/Avatar/Avatar.web.tsx +4 -0
  8. package/src/Avatar/types.ts +4 -0
  9. package/src/Badge/Badge.web.tsx +4 -0
  10. package/src/Badge/types.ts +4 -0
  11. package/src/Breadcrumb/Breadcrumb.web.tsx +4 -0
  12. package/src/Button/Button.web.tsx +4 -0
  13. package/src/Button/types.ts +4 -0
  14. package/src/Card/Card.web.tsx +4 -0
  15. package/src/Card/types.ts +4 -0
  16. package/src/Checkbox/Checkbox.web.tsx +4 -0
  17. package/src/Checkbox/types.ts +4 -0
  18. package/src/Chip/Chip.web.tsx +4 -0
  19. package/src/Chip/types.ts +4 -0
  20. package/src/Dialog/Dialog.web.tsx +4 -0
  21. package/src/Dialog/types.ts +4 -0
  22. package/src/Divider/Divider.web.tsx +4 -0
  23. package/src/Divider/types.ts +4 -0
  24. package/src/Icon/Icon.web.tsx +4 -0
  25. package/src/Input/Input.web.tsx +4 -0
  26. package/src/Input/types.ts +4 -0
  27. package/src/Link/Link.web.tsx +4 -0
  28. package/src/List/List.web.tsx +4 -0
  29. package/src/List/types.ts +7 -0
  30. package/src/Menu/Menu.web.tsx +4 -0
  31. package/src/Popover/Popover.web.tsx +4 -0
  32. package/src/Progress/Progress.web.tsx +4 -0
  33. package/src/Progress/types.ts +7 -0
  34. package/src/RadioButton/RadioButton.web.tsx +4 -0
  35. package/src/Screen/Screen.web.tsx +4 -0
  36. package/src/Screen/types.ts +4 -0
  37. package/src/Select/Select.styles.tsx +4 -0
  38. package/src/Select/Select.web.tsx +4 -0
  39. package/src/Select/types.ts +4 -0
  40. package/src/Skeleton/Skeleton.web.tsx +4 -0
  41. package/src/Slider/Slider.web.tsx +4 -0
  42. package/src/Slider/types.ts +7 -0
  43. package/src/Switch/Switch.web.tsx +4 -0
  44. package/src/Switch/types.ts +7 -0
  45. package/src/TabBar/TabBar.web.tsx +4 -0
  46. package/src/Table/Table.web.tsx +4 -0
  47. package/src/Table/types.ts +7 -0
  48. package/src/Text/Text.web.tsx +4 -0
  49. package/src/Text/types.ts +4 -0
  50. package/src/TextArea/TextArea.web.tsx +4 -0
  51. package/src/Tooltip/Tooltip.web.tsx +4 -0
  52. package/src/Tooltip/types.ts +7 -0
  53. package/src/View/View.web.tsx +4 -0
  54. package/src/View/types.ts +4 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@idealyst/components",
3
- "version": "1.2.1",
3
+ "version": "1.2.3",
4
4
  "description": "Shared component library for React and React Native",
5
5
  "documentation": "https://github.com/IdealystIO/idealyst-framework/tree/main/packages/components#readme",
6
6
  "readme": "README.md",
@@ -56,7 +56,7 @@
56
56
  "publish:npm": "npm publish"
57
57
  },
58
58
  "peerDependencies": {
59
- "@idealyst/theme": "^1.2.1",
59
+ "@idealyst/theme": "^1.2.3",
60
60
  "@mdi/js": ">=7.0.0",
61
61
  "@mdi/react": ">=1.0.0",
62
62
  "@react-native-vector-icons/common": ">=12.0.0",
@@ -106,7 +106,7 @@
106
106
  }
107
107
  },
108
108
  "devDependencies": {
109
- "@idealyst/theme": "^1.2.1",
109
+ "@idealyst/theme": "^1.2.3",
110
110
  "@mdi/react": "^1.6.1",
111
111
  "@types/react": "^19.1.0",
112
112
  "react": "^19.1.0",
@@ -107,6 +107,10 @@ const AccordionItem: React.FC<AccordionItemProps> = ({
107
107
  );
108
108
  };
109
109
 
110
+ /**
111
+ * Expandable sections for organizing content into collapsible panels.
112
+ * Supports single or multiple expanded sections with keyboard navigation.
113
+ */
110
114
  const Accordion: React.FC<AccordionProps> = ({
111
115
  items,
112
116
  allowMultiple = false,
@@ -14,7 +14,14 @@ export interface AccordionItem {
14
14
  disabled?: boolean;
15
15
  }
16
16
 
17
+ /**
18
+ * Expandable content panels for organizing information in collapsible sections.
19
+ * Supports single or multiple expanded items simultaneously.
20
+ */
17
21
  export interface AccordionProps extends ContainerStyleProps, AccessibilityProps {
22
+ /**
23
+ * Array of accordion items to display
24
+ */
18
25
  items: AccordionItem[];
19
26
  allowMultiple?: boolean;
20
27
  defaultExpanded?: string[];
@@ -5,6 +5,10 @@ import { activityIndicatorStyles } from './ActivityIndicator.styles';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
  import { getWebLiveRegionAriaProps } from '../utils/accessibility';
7
7
 
8
+ /**
9
+ * Spinning loading indicator for async operations and content loading.
10
+ * Supports intent-based coloring and automatic hiding when stopped.
11
+ */
8
12
  const ActivityIndicator = forwardRef<HTMLDivElement, ActivityIndicatorProps>(({
9
13
  animating = true,
10
14
  size = 'md',
@@ -16,6 +16,10 @@ const defaultIcons = {
16
16
  neutral: 'record-circle',
17
17
  };
18
18
 
19
+ /**
20
+ * Notification banner for displaying important messages, warnings, or status updates.
21
+ * Supports multiple intents, dismissibility, and custom actions.
22
+ */
19
23
  const Alert = forwardRef<HTMLDivElement, AlertProps>(({
20
24
  title,
21
25
  message,
@@ -6,7 +6,14 @@ import { BaseProps } from '../utils/viewStyleProps';
6
6
  export type AlertIntentVariant = Intent;
7
7
  export type AlertType= 'filled' | 'outlined' | 'soft';
8
8
 
9
+ /**
10
+ * Feedback message component for displaying important information to users.
11
+ * Supports multiple intent colors, dismissible behavior, and custom actions.
12
+ */
9
13
  export interface AlertProps extends BaseProps {
14
+ /**
15
+ * The title of the alert
16
+ */
10
17
  title?: string;
11
18
  message?: string;
12
19
  children?: React.ReactNode;
@@ -5,6 +5,10 @@ import { avatarStyles } from './Avatar.styles';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
  import { getWebAriaProps } from '../utils/accessibility';
7
7
 
8
+ /**
9
+ * User or entity representation with image support and fallback initials.
10
+ * Available in circle or square shapes with multiple sizes.
11
+ */
8
12
  const Avatar = forwardRef<HTMLDivElement, AvatarProps>(({
9
13
  src,
10
14
  alt,
@@ -8,6 +8,10 @@ export type AvatarColorVariant = Color;
8
8
  export type AvatarSizeVariant = 'sm' | 'md' | 'lg' | 'xl';
9
9
  export type AvatarShapeVariant = 'circle' | 'square';
10
10
 
11
+ /**
12
+ * User or entity representation with image, initials fallback, or icon.
13
+ * Supports circular and square shapes with multiple size options.
14
+ */
11
15
  export interface AvatarProps extends BaseProps, AccessibilityProps {
12
16
  /**
13
17
  * Image source (URL or require())
@@ -5,6 +5,10 @@ import { badgeStyles } from './Badge.styles';
5
5
  import { IconSvg } from '../Icon/IconSvg/IconSvg.web';
6
6
  import useMergeRefs from '../hooks/useMergeRefs';
7
7
 
8
+ /**
9
+ * Small status indicator for counts, labels, or notifications.
10
+ * Available in filled, outlined, and dot variants with customizable colors.
11
+ */
8
12
  const Badge = forwardRef<HTMLSpanElement, BadgeProps>((props, ref) => {
9
13
  const {
10
14
  children,
@@ -9,6 +9,10 @@ export type BadgeColorVariant = Color;
9
9
  export type BadgeSizeVariant = Size;
10
10
  export type BadgeType = 'filled' | 'outlined' | 'dot';
11
11
 
12
+ /**
13
+ * Small status indicator component for counts, labels, or status dots.
14
+ * Supports filled, outlined, and dot variants with customizable colors.
15
+ */
12
16
  export interface BadgeProps extends BaseProps {
13
17
  /**
14
18
  * The content to display inside the badge
@@ -148,6 +148,10 @@ const BreadcrumbEllipsis: React.FC<BreadcrumbEllipsisProps> = ({ size, intent })
148
148
  );
149
149
  };
150
150
 
151
+ /**
152
+ * Navigation trail showing the current page location within a hierarchy.
153
+ * Supports custom separators, responsive collapsing, and icon prefixes.
154
+ */
151
155
  const Breadcrumb: React.FC<BreadcrumbProps> = ({
152
156
  items,
153
157
  separator = '/',
@@ -6,6 +6,10 @@ import { IconSvg } from '../Icon/IconSvg/IconSvg.web';
6
6
  import useMergeRefs from '../hooks/useMergeRefs';
7
7
  import { getWebInteractiveAriaProps, generateAccessibilityId } from '../utils/accessibility';
8
8
 
9
+ /**
10
+ * Interactive button component with multiple visual variants, sizes, and icon support.
11
+ * Supports contained, outlined, and text styles with customizable intent colors.
12
+ */
9
13
  const Button = forwardRef<HTMLButtonElement, ButtonProps>((props, ref) => {
10
14
  const {
11
15
  title,
@@ -18,6 +18,10 @@ export type ButtonSizeVariant = Size;
18
18
  */
19
19
  export type ButtonGradient = 'darken' | 'lighten';
20
20
 
21
+ /**
22
+ * Interactive button component with multiple visual variants, sizes, and icon support.
23
+ * Supports contained, outlined, and text styles with customizable intent colors.
24
+ */
21
25
  export interface ButtonProps extends BaseProps, InteractiveAccessibilityProps {
22
26
  /**
23
27
  * The text or content to display inside the button
@@ -5,6 +5,10 @@ import { cardStyles } from './Card.styles';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
  import { getWebInteractiveAriaProps } from '../utils/accessibility';
7
7
 
8
+ /**
9
+ * Container component for grouping related content with elevation and styling options.
10
+ * Supports elevated, outlined, and filled variants with optional click interaction.
11
+ */
8
12
  const Card = forwardRef<HTMLDivElement | HTMLButtonElement, CardProps>(({
9
13
  children,
10
14
  type = 'elevated',
package/src/Card/types.ts CHANGED
@@ -9,6 +9,10 @@ export type CardIntentVariant = Intent;
9
9
  export type CardType = 'default' | 'outlined' | 'elevated' | 'filled';
10
10
  export type CardRadiusVariant = 'none' | Size;
11
11
 
12
+ /**
13
+ * Container component for grouping related content with visual separation.
14
+ * Supports multiple visual styles including outlined, elevated, and filled variants.
15
+ */
12
16
  export interface CardProps extends ContainerStyleProps, InteractiveAccessibilityProps {
13
17
  /**
14
18
  * The content to display inside the card
@@ -6,6 +6,10 @@ import { IconSvg } from '../Icon/IconSvg/IconSvg.web';
6
6
  import useMergeRefs from '../hooks/useMergeRefs';
7
7
  import { getWebSelectionAriaProps, generateAccessibilityId, combineIds } from '../utils/accessibility';
8
8
 
9
+ /**
10
+ * Checkbox input for boolean selection with support for indeterminate state.
11
+ * Includes label, helper text, and error display options.
12
+ */
9
13
  const Checkbox = forwardRef<HTMLDivElement, CheckboxProps>(({
10
14
  checked = false,
11
15
  indeterminate = false,
@@ -9,6 +9,10 @@ export type CheckboxIntentVariant = Intent;
9
9
  export type CheckboxSizeVariant = Size;
10
10
  export type CheckboxVariant = 'default' | 'outlined';
11
11
 
12
+ /**
13
+ * Checkbox component for multiple selection inputs.
14
+ * Supports checked, unchecked, and indeterminate states with optional labels.
15
+ */
12
16
  export interface CheckboxProps extends FormInputStyleProps, SelectionAccessibilityProps {
13
17
  /**
14
18
  * Whether the checkbox is checked
@@ -6,6 +6,10 @@ import { IconSvg } from '../Icon/IconSvg/IconSvg.web';
6
6
  import { isIconName } from '../Icon/icon-resolver';
7
7
  import useMergeRefs from '../hooks/useMergeRefs';
8
8
 
9
+ /**
10
+ * Compact interactive element for tags, filters, or selections.
11
+ * Supports icons, selection state, and delete functionality.
12
+ */
9
13
  const Chip = forwardRef<HTMLDivElement, ChipProps>(({
10
14
  label,
11
15
  type = 'filled',
package/src/Chip/types.ts CHANGED
@@ -8,6 +8,10 @@ export type ChipSize = Size;
8
8
  export type ChipType = 'filled' | 'outlined' | 'soft';
9
9
  export type ChipIntent = Intent;
10
10
 
11
+ /**
12
+ * Compact element for tags, filters, or selections.
13
+ * Supports deletable and selectable modes with icon customization.
14
+ */
11
15
  export interface ChipProps extends BaseProps, SelectionAccessibilityProps {
12
16
  /** The text content of the chip */
13
17
  label: string;
@@ -7,6 +7,10 @@ import Icon from '../Icon';
7
7
  import useMergeRefs from '../hooks/useMergeRefs';
8
8
  import { getWebInteractiveAriaProps, generateAccessibilityId } from '../utils/accessibility';
9
9
 
10
+ /**
11
+ * Modal overlay dialog for focused user interactions and confirmations.
12
+ * Handles focus trapping, escape key, and backdrop click dismissal.
13
+ */
10
14
  const Dialog = forwardRef<HTMLDivElement, DialogProps>(({
11
15
  open,
12
16
  onOpenChange,
@@ -8,6 +8,10 @@ export type DialogSizeVariant = 'sm' | 'md' | 'lg' | 'fullscreen';
8
8
  export type DialogType = 'default' | 'alert' | 'confirmation';
9
9
  export type DialogAnimationType = 'slide' | 'fade' | 'none';
10
10
 
11
+ /**
12
+ * Modal dialog component for focused interactions requiring user attention.
13
+ * Supports multiple sizes, animation types, and configurable close behaviors.
14
+ */
11
15
  export interface DialogProps extends BaseProps, InteractiveAccessibilityProps {
12
16
  /**
13
17
  * Whether the dialog is open/visible
@@ -4,6 +4,10 @@ import { DividerProps } from './types';
4
4
  import { dividerStyles } from './Divider.styles';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
 
7
+ /**
8
+ * Visual separator for dividing content sections horizontally or vertically.
9
+ * Supports solid, dashed, and dotted styles with optional text content.
10
+ */
7
11
  const Divider = forwardRef<HTMLDivElement, DividerProps>(({
8
12
  orientation = 'horizontal',
9
13
  type = 'solid',
@@ -11,6 +11,10 @@ export type DividerThicknessVariant = 'thin' | 'md' | 'thick';
11
11
  export type DividerLengthVariant = 'full' | 'auto' | number;
12
12
  export type DividerSpacingVariant = 'none' | Size;
13
13
 
14
+ /**
15
+ * Visual separator for grouping or dividing content sections.
16
+ * Supports horizontal and vertical orientations with optional centered content.
17
+ */
14
18
  export interface DividerProps extends BaseProps {
15
19
  /**
16
20
  * The orientation of the divider
@@ -8,6 +8,10 @@ import useMergeRefs from '../hooks/useMergeRefs';
8
8
  import { getColorFromString, Intent, Color } from '@idealyst/theme';
9
9
  import { IconRegistry } from './IconRegistry';
10
10
 
11
+ /**
12
+ * Vector icon display from the Material Design Icons library.
13
+ * Supports intent-based coloring and theme-aware sizing.
14
+ */
11
15
  const Icon = forwardRef<HTMLSpanElement, IconProps>((props, ref) => {
12
16
  const {
13
17
  name,
@@ -7,6 +7,10 @@ import { inputStyles } from './Input.styles';
7
7
  import { InputProps } from './types';
8
8
  import { getWebFormAriaProps, generateAccessibilityId, combineIds } from '../utils/accessibility';
9
9
 
10
+ /**
11
+ * Text input field with support for icons, password visibility toggle, and validation states.
12
+ * Available in outlined and filled variants with multiple sizes.
13
+ */
10
14
  const Input = React.forwardRef<HTMLInputElement, InputProps>(({
11
15
  value,
12
16
  onChangeText,
@@ -10,6 +10,10 @@ export type InputSize = Size;
10
10
  export type InputType = 'outlined' | 'filled' | 'bare';
11
11
  export type InputInputType = 'text' | 'email' | 'password' | 'number';
12
12
 
13
+ /**
14
+ * Text input field with support for icons, validation states, and multiple visual styles.
15
+ * Includes built-in password visibility toggle and platform-specific keyboard handling.
16
+ */
13
17
  export interface InputProps extends FormInputStyleProps, FormAccessibilityProps {
14
18
  /**
15
19
  * The current value of the input
@@ -3,6 +3,10 @@ import { useNavigator } from '@idealyst/navigation';
3
3
  import { Pressable } from '../Pressable';
4
4
  import type { LinkProps } from './types';
5
5
 
6
+ /**
7
+ * Navigation component for routing to other screens within the application.
8
+ * Integrates with the navigation system for seamless page transitions.
9
+ */
6
10
  const Link: React.FC<LinkProps> = ({
7
11
  to,
8
12
  vars,
@@ -4,6 +4,10 @@ import { listStyles } from './List.styles';
4
4
  import type { ListProps } from './types';
5
5
  import { ListProvider } from './ListContext';
6
6
 
7
+ /**
8
+ * Container for displaying a collection of related items in a vertical layout.
9
+ * Provides consistent spacing and optional scrolling with ListItem children.
10
+ */
7
11
  const List: React.FC<ListProps> = ({
8
12
  children,
9
13
  type = 'default',
package/src/List/types.ts CHANGED
@@ -27,7 +27,14 @@ export interface ListItemProps extends SelectableAccessibilityProps {
27
27
  testID?: string;
28
28
  }
29
29
 
30
+ /**
31
+ * Container for organizing related items in a vertical list format.
32
+ * Supports bordered, divided, and default visual styles with optional scrolling.
33
+ */
30
34
  export interface ListProps extends ContainerStyleProps, AccessibilityProps {
35
+ /**
36
+ * List items to display
37
+ */
31
38
  children: ReactNode;
32
39
  type?: ListType;
33
40
  size?: ListSizeVariant;
@@ -7,6 +7,10 @@ import useMergeRefs from '../hooks/useMergeRefs';
7
7
  import { PositionedPortal } from '../internal/PositionedPortal';
8
8
  import { getWebInteractiveAriaProps, generateAccessibilityId, MENU_KEYS } from '../utils/accessibility';
9
9
 
10
+ /**
11
+ * Dropdown menu for actions and navigation triggered by a button or element.
12
+ * Includes keyboard navigation, icons, and separator support.
13
+ */
10
14
  const Menu = forwardRef<HTMLDivElement, MenuProps>(({
11
15
  children,
12
16
  items,
@@ -6,6 +6,10 @@ import useMergeRefs from '../hooks/useMergeRefs';
6
6
  import { PositionedPortal } from '../internal/PositionedPortal';
7
7
  import { getWebInteractiveAriaProps, generateAccessibilityId } from '../utils/accessibility';
8
8
 
9
+ /**
10
+ * Floating content panel anchored to an element for contextual information or actions.
11
+ * Supports multiple placements and automatic dismissal behaviors.
12
+ */
9
13
  const Popover = forwardRef<HTMLDivElement, PopoverProps>(({
10
14
  open,
11
15
  onOpenChange,
@@ -3,6 +3,10 @@ import { getWebProps } from 'react-native-unistyles/web';
3
3
  import { progressStyles } from './Progress.styles';
4
4
  import type { ProgressProps } from './types';
5
5
 
6
+ /**
7
+ * Visual indicator for task completion or loading status.
8
+ * Supports linear and circular variants with determinate or indeterminate states.
9
+ */
6
10
  const Progress: React.FC<ProgressProps> = ({
7
11
  value = 0,
8
12
  max = 100,
@@ -7,7 +7,14 @@ export type ProgressIntentVariant = Intent;
7
7
  export type ProgressSizeVariant = Size;
8
8
  export type ProgressVariant = 'linear' | 'circular';
9
9
 
10
+ /**
11
+ * Visual indicator for task completion or loading status.
12
+ * Supports linear and circular variants with determinate and indeterminate modes.
13
+ */
10
14
  export interface ProgressProps extends BaseProps {
15
+ /**
16
+ * Current progress value (0-100 by default, or 0-max if max is specified)
17
+ */
11
18
  value?: number;
12
19
  max?: number;
13
20
  variant?: ProgressVariant;
@@ -5,6 +5,10 @@ import type { RadioButtonProps } from './types';
5
5
  import { useRadioGroup } from './RadioGroup.web';
6
6
  import { getWebSelectionAriaProps, generateAccessibilityId } from '../utils/accessibility';
7
7
 
8
+ /**
9
+ * Single-select option within a radio button group.
10
+ * Works with RadioGroup for managing exclusive selection state.
11
+ */
8
12
  const RadioButton: React.FC<RadioButtonProps> = ({
9
13
  value,
10
14
  checked: checkedProp,
@@ -4,6 +4,10 @@ import { ScreenProps } from './types';
4
4
  import { screenStyles } from './Screen.styles';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
 
7
+ /**
8
+ * Full-screen container for page layouts with background color and safe area support.
9
+ * Provides the outermost wrapper for screen-level content.
10
+ */
7
11
  const Screen = forwardRef<HTMLDivElement, ScreenProps>(({
8
12
  children,
9
13
  background = 'screen',
@@ -3,6 +3,10 @@ import type { StyleProp, ViewStyle } from 'react-native';
3
3
  import { Surface } from '@idealyst/theme';
4
4
  import { ContainerStyleProps } from '../utils/viewStyleProps';
5
5
 
6
+ /**
7
+ * Full-screen container component with safe area support.
8
+ * Provides consistent page-level layout with optional scrolling and safe area insets.
9
+ */
6
10
  export interface ScreenProps extends ContainerStyleProps {
7
11
  /**
8
12
  * The content to display inside the screen
@@ -32,6 +32,10 @@ export type SelectDynamicProps = {
32
32
  export const selectStyles = defineStyle('Select', (theme: Theme) => ({
33
33
  container: (_props: SelectDynamicProps) => ({
34
34
  position: 'relative' as const,
35
+ _web: {
36
+ display: 'inline-flex',
37
+ flexDirection: 'column',
38
+ },
35
39
  variants: {
36
40
  margin: {
37
41
  margin: theme.sizes.$view.padding,
@@ -7,6 +7,10 @@ import { PositionedPortal } from '../internal/PositionedPortal';
7
7
  import { selectStyles } from './Select.styles';
8
8
  import { SelectOption, SelectProps } from './types';
9
9
 
10
+ /**
11
+ * Dropdown selection component with search, keyboard navigation, and custom option rendering.
12
+ * Supports single selection with filterable options list.
13
+ */
10
14
  const Select = forwardRef<HTMLDivElement, SelectProps>(({
11
15
  options,
12
16
  value,
@@ -31,6 +31,10 @@ export interface SelectOption {
31
31
  icon?: ReactNode;
32
32
  }
33
33
 
34
+ /**
35
+ * Dropdown selection component for choosing from a list of options.
36
+ * Supports searchable filtering on web and native presentation modes on iOS.
37
+ */
34
38
  export interface SelectProps extends FormInputStyleProps, FormAccessibilityProps {
35
39
  /**
36
40
  * Array of options to display in the select
@@ -4,6 +4,10 @@ import { skeletonStyles } from './Skeleton.styles';
4
4
  import type { SkeletonProps, SkeletonGroupProps } from './types';
5
5
  import { getWebLiveRegionAriaProps } from '../utils/accessibility';
6
6
 
7
+ /**
8
+ * Placeholder animation for loading content with customizable shapes and animations.
9
+ * Available in pulse and wave animation styles.
10
+ */
7
11
  const Skeleton: React.FC<SkeletonProps> = ({
8
12
  width = '100%',
9
13
  height = 20,
@@ -7,6 +7,10 @@ import { isIconName } from '../Icon/icon-resolver';
7
7
  import useMergeRefs from '../hooks/useMergeRefs';
8
8
  import { getWebRangeAriaProps, generateAccessibilityId, SLIDER_KEYS } from '../utils/accessibility';
9
9
 
10
+ /**
11
+ * Range slider for selecting numeric values within a min/max range.
12
+ * Supports marks, value labels, keyboard navigation, and custom step increments.
13
+ */
10
14
  const Slider = forwardRef<HTMLDivElement, SliderProps>(({
11
15
  value: controlledValue,
12
16
  defaultValue = 0,
@@ -8,7 +8,14 @@ import { RangeAccessibilityProps } from '../utils/accessibility';
8
8
  export type SliderIntentVariant = Intent;
9
9
  export type SliderSizeVariant = Size;
10
10
 
11
+ /**
12
+ * Range input component for selecting numeric values within a defined range.
13
+ * Supports step intervals, marks, and real-time value display.
14
+ */
11
15
  export interface SliderProps extends FormInputStyleProps, RangeAccessibilityProps {
16
+ /**
17
+ * Current slider value
18
+ */
12
19
  value?: number;
13
20
  defaultValue?: number;
14
21
  min?: number;
@@ -7,6 +7,10 @@ import { isIconName } from '../Icon/icon-resolver';
7
7
  import useMergeRefs from '../hooks/useMergeRefs';
8
8
  import { getWebSelectionAriaProps, generateAccessibilityId } from '../utils/accessibility';
9
9
 
10
+ /**
11
+ * Toggle switch for binary on/off states with optional label and icons.
12
+ * Supports custom enabled/disabled icons and multiple sizes.
13
+ */
10
14
  const Switch = forwardRef<HTMLDivElement | HTMLButtonElement, SwitchProps>(({
11
15
  checked = false,
12
16
  onCheckedChange,
@@ -8,7 +8,14 @@ import { SelectionAccessibilityProps } from '../utils/accessibility';
8
8
  export type SwitchIntentVariant = Intent;
9
9
  export type SwitchSizeVariant = Size;
10
10
 
11
+ /**
12
+ * Toggle switch component for binary on/off states.
13
+ * Supports custom icons for enabled/disabled states and optional label positioning.
14
+ */
11
15
  export interface SwitchProps extends FormInputStyleProps, SelectionAccessibilityProps {
16
+ /**
17
+ * Whether the switch is on
18
+ */
12
19
  checked?: boolean;
13
20
  onCheckedChange?: (checked: boolean) => void;
14
21
  disabled?: boolean;
@@ -111,6 +111,10 @@ const Tab: React.FC<TabProps> = ({
111
111
  );
112
112
  };
113
113
 
114
+ /**
115
+ * Horizontal tab navigation for switching between views or content sections.
116
+ * Supports standard underline and pill styles with animated indicator.
117
+ */
114
118
  const TabBar: React.FC<TabBarProps> = ({
115
119
  items,
116
120
  value: controlledValue,
@@ -130,6 +130,10 @@ function TD({
130
130
  // Main Table Component
131
131
  // ============================================================================
132
132
 
133
+ /**
134
+ * Data display component for structured tabular content with columns and rows.
135
+ * Supports custom cell rendering, sticky headers, and row click handling.
136
+ */
133
137
  function Table<T = any>({
134
138
  columns,
135
139
  data,
@@ -18,7 +18,14 @@ export interface TableColumn<T = any> extends SortableAccessibilityProps {
18
18
  align?: TableAlignVariant;
19
19
  }
20
20
 
21
+ /**
22
+ * Data display component for rendering tabular information with columns and rows.
23
+ * Supports sticky headers, row selection, and custom cell rendering.
24
+ */
21
25
  export interface TableProps<T = any> extends ContainerStyleProps, AccessibilityProps {
26
+ /**
27
+ * Column definitions for the table
28
+ */
22
29
  columns: TableColumn<T>[];
23
30
  data: T[];
24
31
  type?: TableType;
@@ -4,6 +4,10 @@ import { TextProps } from './types';
4
4
  import { textStyles } from './Text.styles';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
 
7
+ /**
8
+ * Typography component for displaying text with predefined styles and semantic variants.
9
+ * Supports multiple typography scales, colors, weights, and alignments.
10
+ */
7
11
  const Text = forwardRef<HTMLSpanElement, TextProps>(({
8
12
  children,
9
13
  typography = 'body1',
package/src/Text/types.ts CHANGED
@@ -9,6 +9,10 @@ export type TextWeightVariant = 'light' | 'normal' | 'medium' | 'semibold' | 'bo
9
9
  export type TextAlignVariant = 'left' | 'center' | 'right';
10
10
  export type TextTypographyVariant = Typography;
11
11
 
12
+ /**
13
+ * Typography component for rendering text with consistent styling.
14
+ * Supports semantic typography variants, custom weights, and theme-aware colors.
15
+ */
12
16
  export interface TextProps extends TextSpacingStyleProps {
13
17
  /**
14
18
  * The text content to display
@@ -5,6 +5,10 @@ import type { TextAreaProps } from './types';
5
5
  import useMergeRefs from '../hooks/useMergeRefs';
6
6
  import { getWebFormAriaProps, combineIds, generateAccessibilityId } from '../utils/accessibility';
7
7
 
8
+ /**
9
+ * Multi-line text input with auto-grow, character counting, and validation support.
10
+ * Includes label, helper text, and error message display.
11
+ */
8
12
  const TextArea = forwardRef<HTMLDivElement, TextAreaProps>(({
9
13
  value: controlledValue,
10
14
  defaultValue = '',
@@ -5,6 +5,10 @@ import type { TooltipProps } from './types';
5
5
  import { PositionedPortal } from '../internal/PositionedPortal';
6
6
  import { getWebAriaProps, generateAccessibilityId } from '../utils/accessibility';
7
7
 
8
+ /**
9
+ * Contextual popup for displaying additional information on hover or focus.
10
+ * Supports multiple placements, delays, and keyboard accessibility.
11
+ */
8
12
  const Tooltip: React.FC<TooltipProps> = ({
9
13
  content,
10
14
  children,
@@ -8,7 +8,14 @@ export type TooltipIntentVariant = Intent;
8
8
  export type TooltipSizeVariant = Size;
9
9
  export type TooltipPlacement = 'top' | 'bottom' | 'left' | 'right';
10
10
 
11
+ /**
12
+ * Contextual popup that displays helpful information on hover or focus.
13
+ * Supports configurable placement and delay timing.
14
+ */
11
15
  export interface TooltipProps extends BaseProps, AccessibilityProps {
16
+ /**
17
+ * Content to display in the tooltip
18
+ */
12
19
  content: string | React.ReactNode;
13
20
  children: React.ReactNode;
14
21
  placement?: TooltipPlacement;
@@ -5,6 +5,10 @@ import { ViewProps } from './types';
5
5
  import { viewStyles } from './View.styles';
6
6
  import useMergeRefs from '../hooks/useMergeRefs';
7
7
 
8
+ /**
9
+ * Fundamental layout container with background, border, and spacing options.
10
+ * The base building block for composing UI layouts.
11
+ */
8
12
  const View = forwardRef<HTMLDivElement, ViewProps>(({
9
13
  children,
10
14
  background = 'transparent',
package/src/View/types.ts CHANGED
@@ -28,6 +28,10 @@ export type ViewBackgroundVariant = Surface | 'transparent';
28
28
  export type ViewRadiusVariant = Size | 'none';
29
29
  export type ViewBorderVariant = 'none' | 'thin' | 'thick';
30
30
 
31
+ /**
32
+ * Fundamental layout building block with responsive styling support.
33
+ * Supports theme-aware backgrounds, borders, and breakpoint-based style values.
34
+ */
31
35
  export interface ViewProps extends ContainerStyleProps {
32
36
  /**
33
37
  * The content to display inside the view