@rabex-kit/rabex-ui 0.2.75 → 0.2.77

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.
@@ -1,6 +1,5 @@
1
1
  import React from 'react';
2
2
  import { SwitchProps as MuiSwitchProps } from '@mui/material';
3
- export declare type SwitchProps = MuiSwitchProps;
4
3
  declare module '@mui/material/Switch' {
5
4
  interface SwitchPropsSizeOverrides {
6
5
  small: true;
@@ -10,6 +9,9 @@ declare module '@mui/material/Switch' {
10
9
  '2xs': true;
11
10
  }
12
11
  }
12
+ export declare type SwitchProps = Omit<MuiSwitchProps, 'size'> & {
13
+ size: 'sm' | 'xs' | '2xs' | 'small' | 'medium';
14
+ };
13
15
  /**
14
16
  * Rabex Switch
15
17
  *
package/dist/index.d.ts CHANGED
@@ -117,5 +117,6 @@ import UploadButton, { UploadButtonProps } from './UploadButton';
117
117
  import Zoom, { ZoomProps } from './Zoom';
118
118
  import SegmentedControl, { SegmentedControlProps } from './SegmentedControl';
119
119
  import SegmentedControlTab, { SegmentedControlTabProps } from './SegmentedControlTab';
120
- export { theme, Typography, Button, LoadingButton, Tabs, Tab, Box, Grid, NoSsr, Skeleton, Stack, Chip, Paper, Divider, Checkbox, Radio, Tooltip, Avatar, Breadcrumbs, CurrencyPairsTitle, List, ListItem, ListItemButton, ListItemIcon, ListItemAvatar, ListItemSecondaryAction, ListSubHeader, ListItemText, SvgIcon, ToggleButton, ToggleButtonGroup, TabPanel, IconButton, Select, SelectItem, DynamicBackground, DynamicBackgroundContainer, Table, TableHead, TableBody, TableRow, TableCell, TableContainer, TablePagination, TableFooter, TableSortLabel, RTable, RTableHead, RTableRow, Input, InputLabel, RadioGroup, FormLabel, FormControl, FormGroup, FormControlLabel, FormHelperText, TabContext, TabList, Link, useTheme, useCopyToClipboard, useMediaQuery, useOnScreen, useScrollTrigger, useTime, useWindowSize, useResponsive, numberUtils, searchUtils, Slider, InputAdornment, Accordion, AccordionDetails, AccordionActions, AccordionSummary, Stepper, StepContent, StepConnector, StepButton, StepIcon, Step, StepLabel, MobileStepper, CssBaseline, Backdrop, Modal, ModalContent, Container, Alert, AlertAction, AlertTimer, AlertTitle, UploadButton, Snackbar, SnackbarContent, LinearProgress, CircularProgress, TextField, FormikTextField, FormikInput, FormikSelect, MenuItem, ThemeProvider, styled, MenuList, Menu, Popover, Popper, Fade, Autocomplete, Zoom, Collapse, Grow, Slide, Dialog, DialogActions, DialogContent, DialogTitle, SwipeableDrawer, SeeMore, ClickAwayListener, Pagination, PaginationItem, Drawer, SliderContent, SegmentedControl, SegmentedControlTab, };
121
- export type { Theme, CSSObject, TypographyProps, ButtonProps, LoadingButtonProps, TabsProps, TabProps, BoxProps, GridProps, NoSsrProps, SkeletonProps, StackProps, ChipProps, PaperProps, DividerProps, CheckboxProps, RadioProps, TooltipProps, BreadcrumbsProps, ListProps, ListItemProps, ListItemAvatarProps, ListItemButtonProps, ListItemIconProps, ListItemTextProps, ListItemSecondaryActionProps, ListSubHeaderProps, SvgIconProps, ToggleButtonProps, ToggleButtonGroupProps, TabPanelProps, IconButtonProps, AvatarProps, CurrencyPairsTitleProps, SelectProps, SelectItemProps, DynamicBackgroundProps, DynamicBackgroundContainerProps, TableProps, TableHeadProps, TableBodyProps, TableRowProps, TableCellProps, TableContainerProps, TablePaginationProps, TableFooterProps, TableSortLabelProps, RTableProps, RTableRowProps, RTableHeadProps, InputProps, InputLabelProps, RadioGroupProps, FormLabelProps, FormControlProps, FormGroupProps, FormControlLabelProps, FormHelperTextProps, TabContextProps, TabListProps, LinkProps, SliderProps, InputAdornmentProps, AccordionProps, AccordionDetailsProps, AccordionActionsProps, AccordionSummaryProps, StepperProps, StepContentProps, StepConnectorProps, StepButtonProps, StepIconProps, StepProps, StepLabelProps, MobileStepperProps, Palette, PaletteColor, BackdropProps, ModalProps, ModalContentProps, ContainerProps, AlertProps, AlertActionProps, AlertTimerProps, AlertTitleProps, UploadButtonProps, SnackbarProps, SnackbarContentProps, LinearProgressProps, CircularProgressProps, TextFieldProps, FormikTextFieldProps, FormikInputProps, FormikSelectProps, MenuItemProps, MenuListProps, MenuProps, PopoverProps, PopperProps, ZoomProps, CollapseProps, FadeProps, AutocompleteProps, GrowProps, SlideProps, DialogProps, DialogActionsProps, DialogContentProps, DialogTitleProps, SwipeableDrawerProps, SeeMoreProps, ClickAwayListenerProps, PaginationProps, PaginationItemProps, DrawerProps, SliderContentProps, SegmentedControlProps, SegmentedControlTabProps };
120
+ import Switch, { SwitchProps } from './Switch';
121
+ export { theme, Typography, Button, LoadingButton, Tabs, Tab, Box, Grid, NoSsr, Skeleton, Stack, Chip, Paper, Divider, Checkbox, Radio, Tooltip, Avatar, Breadcrumbs, CurrencyPairsTitle, List, ListItem, ListItemButton, ListItemIcon, ListItemAvatar, ListItemSecondaryAction, ListSubHeader, ListItemText, SvgIcon, ToggleButton, ToggleButtonGroup, TabPanel, IconButton, Select, SelectItem, DynamicBackground, DynamicBackgroundContainer, Table, TableHead, TableBody, TableRow, TableCell, TableContainer, TablePagination, TableFooter, TableSortLabel, RTable, RTableHead, RTableRow, Input, InputLabel, RadioGroup, FormLabel, FormControl, FormGroup, FormControlLabel, FormHelperText, TabContext, TabList, Link, useTheme, useCopyToClipboard, useMediaQuery, useOnScreen, useScrollTrigger, useTime, useWindowSize, useResponsive, numberUtils, searchUtils, Slider, InputAdornment, Accordion, AccordionDetails, AccordionActions, AccordionSummary, Stepper, StepContent, StepConnector, StepButton, StepIcon, Step, StepLabel, MobileStepper, CssBaseline, Backdrop, Modal, ModalContent, Container, Alert, AlertAction, AlertTimer, AlertTitle, UploadButton, Snackbar, SnackbarContent, LinearProgress, CircularProgress, TextField, FormikTextField, FormikInput, FormikSelect, MenuItem, ThemeProvider, styled, MenuList, Menu, Popover, Popper, Fade, Autocomplete, Zoom, Collapse, Grow, Slide, Dialog, DialogActions, DialogContent, DialogTitle, SwipeableDrawer, SeeMore, ClickAwayListener, Pagination, PaginationItem, Drawer, SliderContent, SegmentedControl, SegmentedControlTab, Switch, };
122
+ export type { Theme, CSSObject, TypographyProps, ButtonProps, LoadingButtonProps, TabsProps, TabProps, BoxProps, GridProps, NoSsrProps, SkeletonProps, StackProps, ChipProps, PaperProps, DividerProps, CheckboxProps, RadioProps, TooltipProps, BreadcrumbsProps, ListProps, ListItemProps, ListItemAvatarProps, ListItemButtonProps, ListItemIconProps, ListItemTextProps, ListItemSecondaryActionProps, ListSubHeaderProps, SvgIconProps, ToggleButtonProps, ToggleButtonGroupProps, TabPanelProps, IconButtonProps, AvatarProps, CurrencyPairsTitleProps, SelectProps, SelectItemProps, DynamicBackgroundProps, DynamicBackgroundContainerProps, TableProps, TableHeadProps, TableBodyProps, TableRowProps, TableCellProps, TableContainerProps, TablePaginationProps, TableFooterProps, TableSortLabelProps, RTableProps, RTableRowProps, RTableHeadProps, InputProps, InputLabelProps, RadioGroupProps, FormLabelProps, FormControlProps, FormGroupProps, FormControlLabelProps, FormHelperTextProps, TabContextProps, TabListProps, LinkProps, SliderProps, InputAdornmentProps, AccordionProps, AccordionDetailsProps, AccordionActionsProps, AccordionSummaryProps, StepperProps, StepContentProps, StepConnectorProps, StepButtonProps, StepIconProps, StepProps, StepLabelProps, MobileStepperProps, Palette, PaletteColor, BackdropProps, ModalProps, ModalContentProps, ContainerProps, AlertProps, AlertActionProps, AlertTimerProps, AlertTitleProps, UploadButtonProps, SnackbarProps, SnackbarContentProps, LinearProgressProps, CircularProgressProps, TextFieldProps, FormikTextFieldProps, FormikInputProps, FormikSelectProps, MenuItemProps, MenuListProps, MenuProps, PopoverProps, PopperProps, ZoomProps, CollapseProps, FadeProps, AutocompleteProps, GrowProps, SlideProps, DialogProps, DialogActionsProps, DialogContentProps, DialogTitleProps, SwipeableDrawerProps, SeeMoreProps, ClickAwayListenerProps, PaginationProps, PaginationItemProps, DrawerProps, SliderContentProps, SegmentedControlProps, SegmentedControlTabProps, SwitchProps, };
@@ -123,6 +123,7 @@ var MuiStepper = _interopDefault(require('@mui/material/Stepper/Stepper.js'));
123
123
  var MuiSwipeableDrawer = _interopDefault(require('@mui/material/SwipeableDrawer/SwipeableDrawer.js'));
124
124
  var ClickAwayListener$1 = require('@mui/base/ClickAwayListener');
125
125
  var MuiZoom = _interopDefault(require('@mui/material/Zoom/Zoom.js'));
126
+ var MuiSwitch = _interopDefault(require('@mui/material/Switch/Switch.js'));
126
127
 
127
128
  /**
128
129
  * The accordion component allows the user to show and hide sections of related content on a page.
@@ -7303,6 +7304,31 @@ var SegmentedControlTab = /*#__PURE__*/styled(function (props) {
7303
7304
  });
7304
7305
  SegmentedControlTab.defaultProps = {};
7305
7306
 
7307
+ /**
7308
+ * Rabex Switch
7309
+ *
7310
+ * A thin wrapper around MUI Switch.
7311
+ *
7312
+ * Styling and behavior are controlled exclusively via theme overrides.
7313
+ * This keeps the component lightweight, predictable, and consistent
7314
+ * across the application.
7315
+ *
7316
+ * @example
7317
+ * ```tsx
7318
+ * import { Switch } from '@rabex-kit/rabex-ui';
7319
+ *
7320
+ * <Switch checked={value} onChange={handleChange} />
7321
+ * ```
7322
+ *
7323
+ * For labeling, always use `FormControlLabel`.
7324
+ */
7325
+ var Switch = function Switch(props) {
7326
+ return React__default.createElement(MuiSwitch, Object.assign({}, props));
7327
+ };
7328
+ Switch.defaultProps = {
7329
+ size: '2xs'
7330
+ };
7331
+
7306
7332
  exports.useMediaQuery = useMediaQuery;
7307
7333
  exports.useScrollTrigger = useScrollTrigger_js;
7308
7334
  exports.useTheme = useTheme$1;
@@ -7402,6 +7428,7 @@ exports.StepLabel = StepLabel;
7402
7428
  exports.Stepper = Stepper;
7403
7429
  exports.SvgIcon = SvgIcon;
7404
7430
  exports.SwipeableDrawer = SwipeableDrawer;
7431
+ exports.Switch = Switch;
7405
7432
  exports.Tab = Tab;
7406
7433
  exports.TabContext = TabContext;
7407
7434
  exports.TabList = TabList;