@aurora-ds/components 0.15.4 → 0.16.1
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/README.md +1 -0
- package/dist/cjs/components/actions/button/Button.props.d.ts +9 -0
- package/dist/cjs/components/actions/icon-button/IconButton.props.d.ts +9 -0
- package/dist/cjs/components/data-display/skeleton/Skeleton.d.ts +4 -0
- package/dist/cjs/components/data-display/skeleton/Skeleton.props.d.ts +7 -0
- package/dist/cjs/components/data-display/skeleton/Skeleton.styles.d.ts +3 -0
- package/dist/cjs/components/data-display/skeleton/index.d.ts +2 -0
- package/dist/cjs/components/forms/select/Select.d.ts +7 -0
- package/dist/cjs/components/forms/select/Select.props.d.ts +31 -0
- package/dist/cjs/components/forms/select/Select.styles.d.ts +10 -0
- package/dist/cjs/components/forms/select/SelectItem/SelectItem.d.ts +7 -0
- package/dist/cjs/components/forms/select/SelectItem/SelectItem.props.d.ts +19 -0
- package/dist/cjs/components/forms/select/SelectItem/SelectItem.styles.d.ts +7 -0
- package/dist/cjs/components/forms/select/SelectItem/index.d.ts +2 -0
- package/dist/cjs/components/forms/select/index.d.ts +2 -0
- package/dist/cjs/components/index.d.ts +3 -0
- package/dist/cjs/components/overlay/modal/Modal.d.ts +4 -0
- package/dist/cjs/components/overlay/modal/Modal.props.d.ts +13 -0
- package/dist/cjs/components/overlay/modal/Modal.styles.d.ts +4 -0
- package/dist/cjs/components/overlay/modal/index.d.ts +2 -0
- package/dist/cjs/constants/animations.d.ts +1 -0
- package/dist/cjs/index.js +410 -179
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/interfaces/index.d.ts +1 -0
- package/dist/cjs/interfaces/select.types.d.ts +5 -0
- package/dist/cjs/resources/Icons.d.ts +2 -1
- package/dist/cjs/resources/icons/CloseIcon.d.ts +2 -0
- package/dist/esm/components/actions/button/Button.props.d.ts +9 -0
- package/dist/esm/components/actions/icon-button/IconButton.props.d.ts +9 -0
- package/dist/esm/components/data-display/skeleton/Skeleton.d.ts +4 -0
- package/dist/esm/components/data-display/skeleton/Skeleton.props.d.ts +7 -0
- package/dist/esm/components/data-display/skeleton/Skeleton.styles.d.ts +3 -0
- package/dist/esm/components/data-display/skeleton/index.d.ts +2 -0
- package/dist/esm/components/forms/select/Select.d.ts +7 -0
- package/dist/esm/components/forms/select/Select.props.d.ts +31 -0
- package/dist/esm/components/forms/select/Select.styles.d.ts +10 -0
- package/dist/esm/components/forms/select/SelectItem/SelectItem.d.ts +7 -0
- package/dist/esm/components/forms/select/SelectItem/SelectItem.props.d.ts +19 -0
- package/dist/esm/components/forms/select/SelectItem/SelectItem.styles.d.ts +7 -0
- package/dist/esm/components/forms/select/SelectItem/index.d.ts +2 -0
- package/dist/esm/components/forms/select/index.d.ts +2 -0
- package/dist/esm/components/index.d.ts +3 -0
- package/dist/esm/components/overlay/modal/Modal.d.ts +4 -0
- package/dist/esm/components/overlay/modal/Modal.props.d.ts +13 -0
- package/dist/esm/components/overlay/modal/Modal.styles.d.ts +4 -0
- package/dist/esm/components/overlay/modal/index.d.ts +2 -0
- package/dist/esm/constants/animations.d.ts +1 -0
- package/dist/esm/index.js +411 -183
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/interfaces/index.d.ts +1 -0
- package/dist/esm/interfaces/select.types.d.ts +5 -0
- package/dist/esm/resources/Icons.d.ts +2 -1
- package/dist/esm/resources/icons/CloseIcon.d.ts +2 -0
- package/dist/index.d.ts +76 -3
- package/package.json +1 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { ChevronDownIcon } from '@resources/icons/ChevronDownIcon.tsx';
|
|
2
2
|
import { ChevronRightIcon } from '@resources/icons/ChevronRightIcon.tsx';
|
|
3
|
+
import { CloseIcon } from '@resources/icons/CloseIcon.tsx';
|
|
3
4
|
import { EyeIcon } from '@resources/icons/EyeIcon.tsx';
|
|
4
5
|
import { EyeOffIcon } from '@resources/icons/EyeOffIcon.tsx';
|
|
5
6
|
import { InfoIcon } from '@resources/icons/InfoIcon.tsx';
|
|
6
7
|
import { MoreHorizontalIcon } from '@resources/icons/MoreHorizontalIcon.tsx';
|
|
7
|
-
export { ChevronDownIcon, ChevronRightIcon, InfoIcon, MoreHorizontalIcon, EyeIcon, EyeOffIcon, };
|
|
8
|
+
export { ChevronDownIcon, ChevronRightIcon, InfoIcon, MoreHorizontalIcon, EyeIcon, EyeOffIcon, CloseIcon };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
|
-
import { PropsWithChildren, FC, ReactNode, MouseEvent,
|
|
2
|
+
import { PropsWithChildren, FC, ReactNode, MouseEvent, CSSProperties, FormEvent, ComponentPropsWithoutRef, RefObject } from 'react';
|
|
3
3
|
import { Theme } from '@aurora-ds/theme';
|
|
4
4
|
|
|
5
5
|
type IconProps = PropsWithChildren<{
|
|
@@ -232,6 +232,12 @@ type ButtonVariantStyle = {
|
|
|
232
232
|
textColor: keyof Theme['colors'];
|
|
233
233
|
};
|
|
234
234
|
|
|
235
|
+
type SelectOption = {
|
|
236
|
+
label: string;
|
|
237
|
+
value: string | number;
|
|
238
|
+
disabled?: boolean;
|
|
239
|
+
};
|
|
240
|
+
|
|
235
241
|
type AvatarGroupProps = {
|
|
236
242
|
/** Avatar children */
|
|
237
243
|
children: ReactNode;
|
|
@@ -241,6 +247,14 @@ type AvatarGroupProps = {
|
|
|
241
247
|
size?: AvatarSize;
|
|
242
248
|
};
|
|
243
249
|
|
|
250
|
+
type SkeletonProps = {
|
|
251
|
+
width: CSSProperties['width'];
|
|
252
|
+
height: CSSProperties['height'];
|
|
253
|
+
borderRadius?: keyof Theme['radius'];
|
|
254
|
+
};
|
|
255
|
+
|
|
256
|
+
declare const Skeleton: FC<SkeletonProps>;
|
|
257
|
+
|
|
244
258
|
type ButtonProps = {
|
|
245
259
|
/** Button text label */
|
|
246
260
|
label: string;
|
|
@@ -260,6 +274,12 @@ type ButtonProps = {
|
|
|
260
274
|
disabled?: boolean;
|
|
261
275
|
/** Custom text color (overrides variant color) */
|
|
262
276
|
textColor?: keyof Theme['colors'];
|
|
277
|
+
/** Custom backgroundColor (overrides variant backgroundColor) */
|
|
278
|
+
backgroundColor?: keyof Theme['colors'];
|
|
279
|
+
/** Custom hover backgroundColor (overrides variant hover backgroundColor) */
|
|
280
|
+
hoverBackgroundColor?: keyof Theme['colors'];
|
|
281
|
+
/** Custom active backgroundColor (overrides variant active backgroundColor) */
|
|
282
|
+
activeBackgroundColor?: keyof Theme['colors'];
|
|
263
283
|
/** Size of the button */
|
|
264
284
|
size?: IconButtonSizes;
|
|
265
285
|
/** Accessibility label for screen readers */
|
|
@@ -299,6 +319,12 @@ type IconButtonProps = {
|
|
|
299
319
|
disabled?: boolean;
|
|
300
320
|
/** Custom text/icon color (overrides variant color) */
|
|
301
321
|
textColor?: keyof Theme['colors'];
|
|
322
|
+
/** Custom backgroundColor (overrides variant backgroundColor) */
|
|
323
|
+
backgroundColor?: keyof Theme['colors'];
|
|
324
|
+
/** Custom hover backgroundColor (overrides variant hover backgroundColor) */
|
|
325
|
+
hoverBackgroundColor?: keyof Theme['colors'];
|
|
326
|
+
/** Custom active backgroundColor (overrides variant active backgroundColor) */
|
|
327
|
+
activeBackgroundColor?: keyof Theme['colors'];
|
|
302
328
|
/** Size of the icon button */
|
|
303
329
|
size?: IconButtonSizes;
|
|
304
330
|
/** Accessibility label for screen readers */
|
|
@@ -378,6 +404,38 @@ type TextAreaProps = {
|
|
|
378
404
|
|
|
379
405
|
declare const _default: react.MemoExoticComponent<react.ForwardRefExoticComponent<TextAreaProps & react.RefAttributes<HTMLTextAreaElement>>>;
|
|
380
406
|
|
|
407
|
+
type SelectProps = {
|
|
408
|
+
/**
|
|
409
|
+
* The options to display in the select dropdown
|
|
410
|
+
*/
|
|
411
|
+
options: SelectOption[];
|
|
412
|
+
/**
|
|
413
|
+
* The currently selected value
|
|
414
|
+
*/
|
|
415
|
+
value?: string | number;
|
|
416
|
+
/**
|
|
417
|
+
* Callback when selection changes
|
|
418
|
+
*/
|
|
419
|
+
onChange?: (value: string | number) => void;
|
|
420
|
+
/**
|
|
421
|
+
* Placeholder text when no option is selected
|
|
422
|
+
*/
|
|
423
|
+
placeholder?: string;
|
|
424
|
+
/**
|
|
425
|
+
* Whether the select is disabled
|
|
426
|
+
*/
|
|
427
|
+
disabled?: boolean;
|
|
428
|
+
/**
|
|
429
|
+
* Width of the select
|
|
430
|
+
*/
|
|
431
|
+
width?: string | number;
|
|
432
|
+
};
|
|
433
|
+
|
|
434
|
+
/**
|
|
435
|
+
* Select component that uses Menu for dropdown
|
|
436
|
+
*/
|
|
437
|
+
declare const Select: FC<SelectProps>;
|
|
438
|
+
|
|
381
439
|
type StackProps = {
|
|
382
440
|
/** Stack children elements */
|
|
383
441
|
children: ReactNode;
|
|
@@ -681,6 +739,21 @@ type MenuItemProps = {
|
|
|
681
739
|
|
|
682
740
|
declare const MenuItem: FC<MenuItemProps>;
|
|
683
741
|
|
|
742
|
+
type ModalProps = {
|
|
743
|
+
isOpen: boolean;
|
|
744
|
+
onClose: () => void;
|
|
745
|
+
label: string;
|
|
746
|
+
children: ReactNode;
|
|
747
|
+
isForm?: boolean;
|
|
748
|
+
action?: {
|
|
749
|
+
label: string;
|
|
750
|
+
onClick: () => void;
|
|
751
|
+
disabled?: boolean;
|
|
752
|
+
};
|
|
753
|
+
};
|
|
754
|
+
|
|
755
|
+
declare const Modal: FC<ModalProps>;
|
|
756
|
+
|
|
684
757
|
type DrawerItemProps = {
|
|
685
758
|
/** DrawerItem text label */
|
|
686
759
|
label: string;
|
|
@@ -866,5 +939,5 @@ type UseTransitionRenderReturnType = {
|
|
|
866
939
|
*/
|
|
867
940
|
declare const useTransitionRender: (isOpen: boolean, duration?: number) => UseTransitionRenderReturnType;
|
|
868
941
|
|
|
869
|
-
export { Accordion, Avatar, AvatarGroup, Breadcrumb, BreadcrumbEllipsis, BreadcrumbLink, BreadcrumbPage, BreadcrumbSeparator, Button, Card, Chip, DrawerItem, _default$2 as Form, Grid, Icon, IconButton, _default$1 as Input, Menu, MenuGroup, MenuItem, Page, PageSection, Separator, Stack, TabItem, Tabs, Text, _default as TextArea, useAnchorPosition, useClickOutside, useTransitionRender };
|
|
870
|
-
export type { AccordionProps, AnchorOrigin, AnchorPosition, AvatarGroupProps, AvatarProps, BreadcrumbEllipsisProps, BreadcrumbLinkProps, BreadcrumbPageProps, BreadcrumbProps, BreadcrumbSeparatorProps, ButtonProps, ButtonVariantStyle, ButtonVariants, CardProps, ChipColor, ChipProps, ChipSize, ChipVariant, DrawerItemProps, FormProps, GridProps, IconButtonProps, IconProps, InputProps, MenuGroupProps, MenuItemProps, MenuProps, PageProps, PageSectionProps, SeparatorProps, StackProps, TabItemProps, TabsProps, TextAreaProps, TextProps, TextVariantStyle, TextVariants, UseTransitionRenderReturnType };
|
|
942
|
+
export { Accordion, Avatar, AvatarGroup, Breadcrumb, BreadcrumbEllipsis, BreadcrumbLink, BreadcrumbPage, BreadcrumbSeparator, Button, Card, Chip, DrawerItem, _default$2 as Form, Grid, Icon, IconButton, _default$1 as Input, Menu, MenuGroup, MenuItem, Modal, Page, PageSection, Select, Separator, Skeleton, Stack, TabItem, Tabs, Text, _default as TextArea, useAnchorPosition, useClickOutside, useTransitionRender };
|
|
943
|
+
export type { AccordionProps, AnchorOrigin, AnchorPosition, AvatarGroupProps, AvatarProps, BreadcrumbEllipsisProps, BreadcrumbLinkProps, BreadcrumbPageProps, BreadcrumbProps, BreadcrumbSeparatorProps, ButtonProps, ButtonVariantStyle, ButtonVariants, CardProps, ChipColor, ChipProps, ChipSize, ChipVariant, DrawerItemProps, FormProps, GridProps, IconButtonProps, IconProps, InputProps, MenuGroupProps, MenuItemProps, MenuProps, ModalProps, PageProps, PageSectionProps, SelectProps, SeparatorProps, SkeletonProps, StackProps, TabItemProps, TabsProps, TextAreaProps, TextProps, TextVariantStyle, TextVariants, UseTransitionRenderReturnType };
|