@hero-design/rn 8.2.2 → 8.3.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.
Files changed (57) hide show
  1. package/.turbo/turbo-build.log +9 -9
  2. package/es/index.js +409 -80
  3. package/lib/index.js +407 -77
  4. package/package.json +5 -5
  5. package/src/components/Box/StyledBox.tsx +8 -6
  6. package/src/components/Card/StyledCard.tsx +1 -1
  7. package/src/components/Card/__tests__/__snapshots__/index.spec.tsx.snap +74 -0
  8. package/src/components/Card/__tests__/index.spec.tsx +2 -0
  9. package/src/components/Card/index.tsx +1 -1
  10. package/src/components/Carousel/CarouselItem.tsx +49 -0
  11. package/src/components/Carousel/CarouselPaginator/StyledCarouselPaginator.tsx +19 -0
  12. package/src/components/Carousel/CarouselPaginator/index.tsx +58 -0
  13. package/src/components/Carousel/StyledCarousel.tsx +55 -0
  14. package/src/components/Carousel/__tests__/StyledCarousel.spec.tsx +13 -0
  15. package/src/components/Carousel/__tests__/__snapshots__/StyledCarousel.spec.tsx.snap +21 -0
  16. package/src/components/Carousel/__tests__/index.spec.tsx +86 -0
  17. package/src/components/Carousel/index.tsx +176 -0
  18. package/src/components/Carousel/types.ts +10 -0
  19. package/src/components/Icon/index.tsx +28 -2
  20. package/src/components/TextInput/__tests__/__snapshots__/index.spec.tsx.snap +160 -0
  21. package/src/components/TextInput/__tests__/index.spec.tsx +50 -3
  22. package/src/components/TextInput/index.tsx +65 -30
  23. package/src/components/Toolbar/ToolbarGroup.tsx +20 -14
  24. package/src/components/Toolbar/ToolbarItem.tsx +9 -1
  25. package/src/components/Toolbar/__tests__/__snapshots__/ToolbarGroup.spec.tsx.snap +12 -0
  26. package/src/components/Toolbar/__tests__/__snapshots__/ToolbarItem.spec.tsx.snap +6 -0
  27. package/src/index.ts +2 -0
  28. package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +27 -0
  29. package/src/theme/components/carousel.ts +39 -0
  30. package/src/theme/getTheme.ts +3 -0
  31. package/src/types.ts +4 -1
  32. package/src/utils/__tests__/helpers.spec.ts +22 -4
  33. package/src/utils/helpers.ts +10 -9
  34. package/types/components/BottomNavigation/StyledBottomNavigation.d.ts +1 -1
  35. package/types/components/Box/StyledBox.d.ts +2 -2
  36. package/types/components/Button/StyledButton.d.ts +1 -1
  37. package/types/components/Button/UtilityButton/StyledUtilityButton.d.ts +1 -1
  38. package/types/components/Card/StyledCard.d.ts +1 -1
  39. package/types/components/Card/index.d.ts +1 -1
  40. package/types/components/Carousel/CarouselItem.d.ts +7 -0
  41. package/types/components/Carousel/CarouselPaginator/StyledCarouselPaginator.d.ts +16 -0
  42. package/types/components/Carousel/CarouselPaginator/index.d.ts +7 -0
  43. package/types/components/Carousel/StyledCarousel.d.ts +34 -0
  44. package/types/components/Carousel/index.d.ts +46 -0
  45. package/types/components/Carousel/types.d.ts +9 -0
  46. package/types/components/Checkbox/StyledCheckbox.d.ts +1 -1
  47. package/types/components/ContentNavigator/StyledContentNavigator.d.ts +1 -1
  48. package/types/components/FAB/ActionGroup/StyledActionItem.d.ts +1 -1
  49. package/types/components/Icon/index.d.ts +3 -3
  50. package/types/components/TextInput/StyledTextInput.d.ts +7 -7
  51. package/types/components/TextInput/index.d.ts +25 -3
  52. package/types/components/Toolbar/ToolbarItem.d.ts +6 -1
  53. package/types/index.d.ts +2 -1
  54. package/types/theme/components/carousel.d.ts +29 -0
  55. package/types/theme/getTheme.d.ts +2 -0
  56. package/types/types.d.ts +3 -2
  57. package/types/utils/helpers.d.ts +2 -2
@@ -0,0 +1,29 @@
1
+ import type { GlobalTheme } from '../global';
2
+ declare const getCarouselTheme: (theme: GlobalTheme) => {
3
+ colors: {
4
+ paginatorBackgroundColor: string;
5
+ };
6
+ sizes: {
7
+ indicatorWidth: number;
8
+ paginatorHeight: number;
9
+ paginatorWidth: number;
10
+ };
11
+ radii: {
12
+ paginatorBorderRadius: number;
13
+ };
14
+ space: {
15
+ headingMarginTop: number;
16
+ headingMarginBottom: number;
17
+ paginatorMarginHorizontal: number;
18
+ };
19
+ fonts: {
20
+ heading: string;
21
+ };
22
+ fontSizes: {
23
+ heading: number;
24
+ };
25
+ lineHeights: {
26
+ heading: number;
27
+ };
28
+ };
29
+ export default getCarouselTheme;
@@ -8,6 +8,7 @@ import getBottomSheetTheme from './components/bottomSheet';
8
8
  import getButtonTheme from './components/button';
9
9
  import getCalendarTheme from './components/calendar';
10
10
  import getCardTheme from './components/card';
11
+ import getCarouselTheme from './components/carousel';
11
12
  import getCheckboxTheme from './components/checkbox';
12
13
  import getContentNavigatorTheme from './components/contentNavigator';
13
14
  import getDatePickerTheme from './components/datePicker';
@@ -49,6 +50,7 @@ declare type Theme = GlobalTheme & {
49
50
  button: ReturnType<typeof getButtonTheme>;
50
51
  calendar: ReturnType<typeof getCalendarTheme>;
51
52
  card: ReturnType<typeof getCardTheme>;
53
+ carousel: ReturnType<typeof getCarouselTheme>;
52
54
  checkbox: ReturnType<typeof getCheckboxTheme>;
53
55
  contentNavigator: ReturnType<typeof getContentNavigatorTheme>;
54
56
  datePicker: ReturnType<typeof getDatePickerTheme>;
package/types/types.d.ts CHANGED
@@ -2,9 +2,10 @@ import type { BottomNavigationTabType } from './components/BottomNavigation';
2
2
  import type { IconName } from './components/Icon';
3
3
  import type { SingleSelectProps, MultiSelectProps } from './components/Select';
4
4
  import type { TabType } from './components/Tabs';
5
- import type { TextInputProps } from './components/TextInput';
5
+ import type { TextInputProps, TextInputHandles } from './components/TextInput';
6
6
  import type { RichTextEditorRef, RichTextEditorProps } from './components/RichTextEditor';
7
7
  import type { Theme } from './theme';
8
8
  import type { ListRenderOptionInfo, SectionListRenderOptionInfo } from './components/Select/types';
9
9
  import { SwipeableProps } from './components/Swipeable';
10
- export type { BottomNavigationTabType, IconName, SingleSelectProps, MultiSelectProps, ListRenderOptionInfo, SectionListRenderOptionInfo, SwipeableProps, RichTextEditorProps, RichTextEditorRef, TabType, TextInputProps, Theme, };
10
+ import { TextProps } from './components/Typography/Text';
11
+ export type { BottomNavigationTabType, IconName, SingleSelectProps, MultiSelectProps, ListRenderOptionInfo, SectionListRenderOptionInfo, SwipeableProps, RichTextEditorProps, RichTextEditorRef, TabType, TextInputProps, TextProps, TextInputHandles, Theme, };
@@ -1,4 +1,4 @@
1
1
  export declare const isIOS: boolean;
2
2
  export declare const isAndroid: boolean;
3
- export declare const pick: (keys: Array<string>, props: Record<string, any>) => {};
4
- export declare const omit: (keys: Array<string>, props: Record<string, any>) => Record<string, any>;
3
+ export declare function pick<O, T extends keyof O>(keys: T[], obj: O): Pick<O, T>;
4
+ export declare function omit<O, T extends keyof O>(keys: T[], obj: O): Omit<O, T>;