@hero-design/rn 8.103.2 → 8.103.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.
- package/.turbo/turbo-build.log +3 -3
- package/CHANGELOG.md +7 -0
- package/es/index.js +102 -86
- package/eslint.config.js +1 -0
- package/lib/index.js +102 -86
- package/package.json +1 -1
- package/src/components/DatePicker/StyledDatePicker.tsx +1 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerIOS.spec.tsx.snap +2 -0
- package/src/components/PinInput/PinCell.tsx +6 -1
- package/src/components/PinInput/StyledPinInput.tsx +2 -2
- package/src/components/PinInput/__tests__/__snapshots__/PinCell.spec.tsx.snap +30 -0
- package/src/components/PinInput/__tests__/__snapshots__/index.spec.tsx.snap +287 -5
- package/src/components/PinInput/__tests__/index.spec.tsx +33 -0
- package/src/components/PinInput/index.tsx +6 -2
- package/src/components/Select/MultiSelect/index.tsx +15 -4
- package/src/components/Select/SingleSelect/index.tsx +15 -4
- package/src/components/Select/index.internal.tsx +13 -0
- package/src/components/Select/index.tsx +14 -2
- package/src/components/Select/types.ts +4 -0
- package/src/components/TimePicker/StyledTimePicker.tsx +1 -0
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerIOS.spec.tsx.snap +1 -0
- package/src/index.internal.ts +5 -0
- package/src/types.internal.ts +8 -0
- package/stats/8.103.2/rn-stats.html +3 -1
- package/stats/8.103.3/rn-stats.html +4844 -0
- package/types/components/Checkbox/index.d.ts +1 -1
- package/types/components/PinInput/StyledPinInput.d.ts +2 -4
- package/types/components/Select/MultiSelect/index.d.ts +5 -1
- package/types/components/Select/SingleSelect/index.d.ts +5 -1
- package/types/components/Select/index.d.ts +5 -3
- package/types/components/Select/index.internal.d.ts +8 -0
- package/types/components/Select/types.d.ts +4 -0
- package/types/components/TextInput/index.d.ts +1 -1
- package/types/index.internal.d.ts +4 -0
- package/types/types.internal.d.ts +3 -0
|
@@ -40,6 +40,6 @@ type getStateType = {
|
|
|
40
40
|
readonly: boolean;
|
|
41
41
|
checked?: boolean;
|
|
42
42
|
};
|
|
43
|
-
export declare const getThemeState: ({ disabled, readonly, checked, }: getStateType) => "
|
|
43
|
+
export declare const getThemeState: ({ disabled, readonly, checked, }: getStateType) => "disabled" | "default" | "readonly" | "checked";
|
|
44
44
|
declare const Checkbox: ({ checked, description, withBorder, disabled, onPress, style, testID, readonly, }: CheckboxProps) => React.JSX.Element;
|
|
45
45
|
export default Checkbox;
|
|
@@ -5,12 +5,10 @@ export declare const StyledWrapper: import("@emotion/native").StyledComponent<im
|
|
|
5
5
|
}, {}, {
|
|
6
6
|
ref?: import("react").Ref<View> | undefined;
|
|
7
7
|
}>;
|
|
8
|
-
export declare const StyledPinWrapper: import("@emotion/native").StyledComponent<import("react-native").
|
|
8
|
+
export declare const StyledPinWrapper: import("@emotion/native").StyledComponent<import("react-native").PressableProps & import("react").RefAttributes<View> & {
|
|
9
9
|
theme?: import("@emotion/react").Theme;
|
|
10
10
|
as?: React.ElementType;
|
|
11
|
-
}, {}, {
|
|
12
|
-
ref?: import("react").Ref<View> | undefined;
|
|
13
|
-
}>;
|
|
11
|
+
}, {}, {}>;
|
|
14
12
|
export type State = 'default' | 'disabled' | 'error';
|
|
15
13
|
export declare const StyledCell: import("@emotion/native").StyledComponent<import("react-native").ViewProps & {
|
|
16
14
|
theme?: import("@emotion/react").Theme;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { TextInputProps as NativeTextInputProps } from 'react-native';
|
|
3
|
+
import { TextInputProps } from '../../TextInput';
|
|
3
4
|
import type { SelectOptionType, SelectProps } from '../types';
|
|
4
5
|
export interface MultiSelectProps<V, T extends SelectOptionType<V> = SelectOptionType<V>> extends SelectProps<V, T> {
|
|
5
6
|
/**
|
|
@@ -26,5 +27,8 @@ export interface MultiSelectProps<V, T extends SelectOptionType<V> = SelectOptio
|
|
|
26
27
|
*/
|
|
27
28
|
supportedOrientations?: ('portrait' | 'landscape')[];
|
|
28
29
|
}
|
|
29
|
-
|
|
30
|
+
export interface InternalMultiSelectProps<V, T extends SelectOptionType<V> = SelectOptionType<V>> extends MultiSelectProps<V, T> {
|
|
31
|
+
TextInputComponent?: React.ComponentType<TextInputProps>;
|
|
32
|
+
}
|
|
33
|
+
declare function MultiSelect<V, T extends SelectOptionType<V>>({ footerLabel, label, loading, inputProps, onConfirm, onDismiss, onEndReached, onQueryChange, options, renderOption, renderSelectedValue, query, error, editable, disabled, required, style, testID, value, supportedOrientations, bottomSheetConfig, ...rest }: InternalMultiSelectProps<V, T>): React.JSX.Element;
|
|
30
34
|
export default MultiSelect;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { TextInputProps as NativeTextInputProps } from 'react-native';
|
|
3
|
+
import { TextInputProps } from '../../TextInput';
|
|
3
4
|
import type { SelectOptionType, SelectProps } from '../types';
|
|
4
5
|
export interface SingleSelectProps<V, T extends SelectOptionType<V> = SelectOptionType<V>> extends SelectProps<V, T> {
|
|
5
6
|
/**
|
|
@@ -19,5 +20,8 @@ export interface SingleSelectProps<V, T extends SelectOptionType<V> = SelectOpti
|
|
|
19
20
|
*/
|
|
20
21
|
supportedOrientations?: ('portrait' | 'landscape')[];
|
|
21
22
|
}
|
|
22
|
-
|
|
23
|
+
export interface InternalSingleSelectProps<V, T extends SelectOptionType<V> = SelectOptionType<V>> extends SingleSelectProps<V, T> {
|
|
24
|
+
TextInputComponent?: React.ComponentType<TextInputProps>;
|
|
25
|
+
}
|
|
26
|
+
declare const SingleSelect: <V, T extends SelectOptionType<V>>({ label, loading, inputProps, onConfirm, onDismiss, onEndReached, onQueryChange, options, renderOption, renderSelectedValue, query, error, editable, disabled, required, style, testID, value, supportedOrientations, bottomSheetConfig, ...rest }: InternalSingleSelectProps<V, T>) => React.JSX.Element;
|
|
23
27
|
export default SingleSelect;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import MultiSelect from './MultiSelect';
|
|
2
1
|
import type { MultiSelectProps } from './MultiSelect';
|
|
3
2
|
import type { SingleSelectProps } from './SingleSelect';
|
|
3
|
+
import { SelectOptionType } from './types';
|
|
4
4
|
export type { MultiSelectProps, SingleSelectProps };
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
type SingleSelectType = <V, T extends SelectOptionType<V> = SelectOptionType<V>>(props: Omit<SingleSelectProps<V, T>, 'TextInputComponent'>) => React.ReactElement;
|
|
6
|
+
type MultiSelectType = <V, T extends SelectOptionType<V> = SelectOptionType<V>>(props: Omit<MultiSelectProps<V, T>, 'TextInputComponent'>) => React.ReactElement;
|
|
7
|
+
declare const _default: SingleSelectType & {
|
|
8
|
+
Multi: MultiSelectType;
|
|
7
9
|
};
|
|
8
10
|
export default _default;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import MultiSelect from './MultiSelect';
|
|
2
|
+
import type { InternalMultiSelectProps } from './MultiSelect';
|
|
3
|
+
import type { InternalSingleSelectProps } from './SingleSelect';
|
|
4
|
+
export type { InternalMultiSelectProps as MultiSelectProps, InternalSingleSelectProps as SingleSelectProps, };
|
|
5
|
+
declare const _default: (<V, T extends import("./types").SelectOptionType<V>>({ label, loading, inputProps, onConfirm, onDismiss, onEndReached, onQueryChange, options, renderOption, renderSelectedValue, query, error, editable, disabled, required, style, testID, value, supportedOrientations, bottomSheetConfig, ...rest }: InternalSingleSelectProps<V, T>) => import("react").JSX.Element) & {
|
|
6
|
+
Multi: typeof MultiSelect;
|
|
7
|
+
};
|
|
8
|
+
export default _default;
|
|
@@ -81,4 +81,8 @@ export interface SelectProps<V, T extends SelectOptionType<V>> extends Pick<Text
|
|
|
81
81
|
variant?: BottomSheetProps['variant'];
|
|
82
82
|
header?: BottomSheetProps['header'];
|
|
83
83
|
};
|
|
84
|
+
/**
|
|
85
|
+
* Inject a custom TextInput component (e.g., from rn-work-uikit). Defaults to local TextInput.
|
|
86
|
+
*/
|
|
87
|
+
TextInputComponent?: React.ComponentType<TextInputProps>;
|
|
84
88
|
}
|
|
@@ -110,7 +110,7 @@ export declare const renderSuffix: ({ state, loading, suffix, }: {
|
|
|
110
110
|
state: State;
|
|
111
111
|
loading: boolean;
|
|
112
112
|
suffix?: IconName | React.ReactElement;
|
|
113
|
-
}) => "number" | "swag" | "wallet" | React.JSX.Element | "search" | "bold" | "menu" | "filter" | "image" | "switch" | "
|
|
113
|
+
}) => "number" | "swag" | "wallet" | React.JSX.Element | "search" | "bold" | "menu" | "filter" | "image" | "switch" | "activate" | "add-emoji" | "add-person" | "adjustment" | "alignment" | "antenna" | "archive" | "assignment-warning" | "bank" | "bell" | "billing" | "bolt" | "bookmark-added" | "bookmark-checked" | "bookmark" | "box-check" | "box" | "bpay" | "buildings" | "cake" | "calendar-clock" | "calendar" | "candy-box-menu" | "caret-down-small" | "caret-down" | "caret-left-small" | "caret-left" | "caret-right-small" | "caret-right" | "caret-up-small" | "caret-up" | "check-radio" | "circle-add" | "circle-cancel" | "circle-check" | "circle-down" | "circle-info" | "circle-left" | "circle-ok" | "circle-pencil" | "circle-question" | "circle-remove" | "circle-right" | "circle-up" | "circle-warning" | "clock-3" | "clock" | "cloud-download" | "cloud-upload" | "cog" | "coin" | "contacts" | "credit-card" | "diamond" | "direction-arrows" | "directory" | "document" | "dollar-coin-shine" | "dot" | "double-buildings" | "edit-template" | "envelope" | "exclude" | "expand-content" | "expense" | "explore_nearby" | "eye-circle" | "eye-invisible" | "eye" | "face-meh" | "face-sad" | "face-smiley" | "feed" | "feedbacks" | "file-certified" | "file-clone" | "file-copy" | "file-csv" | "file-dispose" | "file-doc" | "file-excel" | "file-export" | "file-lock" | "file-pdf" | "file-powerpoint" | "file-search" | "file-secured" | "file-sheets" | "file-slide" | "file-verified" | "file-word" | "file" | "folder-user" | "folder" | "format-bold" | "format-heading1" | "format-heading2" | "format-italic" | "format-list-bulleted" | "format-list-numbered" | "format-underlined" | "funnel-filter" | "global-dollar" | "globe" | "graduation-cap" | "graph" | "happy-sun" | "health-bag" | "heart" | "hero-points" | "home" | "import" | "incident-siren" | "instapay-daily" | "instapay-now" | "instapay" | "list" | "loading-2" | "loading" | "location-on" | "location" | "lock" | "looks-one" | "looks-two" | "media-content" | "money-notes" | "moneybag" | "moon" | "multiple-stars" | "multiple-users" | "near-me" | "node" | "open-folder" | "paperclip-vertical" | "paperclip" | "payment-summary" | "pencil" | "phone" | "piggy-bank" | "plane-up" | "plane" | "play-arrow" | "play-circle" | "print" | "raising-hands" | "reply-arrow" | "reply" | "reschedule" | "rostering" | "salary-sacrifice" | "save" | "schedule-send" | "schedule" | "search-person" | "send" | "speaker-active" | "speaker" | "star-award" | "star-badge" | "star-circle" | "star-medal" | "star" | "steps-circle" | "stopwatch" | "suitcase" | "surfing" | "survey" | "swag-pillar-benefit" | "swag-pillar-career" | "swag-pillar-money" | "swag-pillar-work" | "swipe-right" | "tag" | "target" | "teams" | "thumb-down" | "timesheet" | "touch-id" | "trash-bin" | "unlock" | "user" | "video-1" | "video-2" | "warning" | "academic-hat-outlined" | "accommodation-outlined" | "activate-outlined" | "add-credit-card-outlined" | "add-person-outlined" | "add-section-outlined" | "add-time-outlined" | "add" | "adjustment-outlined" | "afternoon-outlined" | "ai-outlined" | "alignment-2-outlined" | "alignment-outlined" | "all-caps" | "application-outlined" | "arrow-down" | "arrow-downwards" | "arrow-left" | "arrow-leftwards" | "arrow-right" | "arrow-rightwards" | "arrow-up" | "arrow-upwards" | "article-outlined" | "at-sign" | "auto-graph-outlined" | "automotive-outlined" | "bakery-outlined" | "bar-outlined" | "beauty-outlined" | "beer-outlined" | "bell-active-outlined" | "bell-outlined" | "bell-slash-outlined" | "bill-management-outlined" | "billing-outlined" | "body-outlined" | "bolt-outlined" | "book-outlined" | "bookmark-added-outlined" | "bookmark-checked-outlined" | "bookmark-outlined" | "box-1-outlined" | "box-check-outlined" | "box-outlined" | "bullet-points" | "cake-outlined" | "calculator-outlined" | "calendar-dates-outlined" | "calendar-star-outlined" | "call-outlined" | "call-split-outlined" | "camera-outlined" | "cancel" | "car-forward-outlined" | "cashback-outlined" | "charging-station-outlined" | "chat-bubble-outlined" | "chat-unread-outlined" | "checkmark" | "circle-add-outlined" | "circle-cancel-outlined" | "circle-down-outlined" | "circle-info-outlined" | "circle-left-outlined" | "circle-ok-outlined" | "circle-question-outlined" | "circle-remove-outlined" | "circle-right-outlined" | "circle-up-outlined" | "circle-warning-outlined" | "clock-2-outlined" | "clock-in-outlined" | "clock-out-outlined" | "clock-outlined" | "cog-outlined" | "coin-outlined" | "coin-super-outlined" | "comment-outlined" | "contacts-outlined" | "contacts-user-outlined" | "credit-card-outlined" | "cultural-site-outlined" | "cup-outlined" | "dentistry-outlined" | "direction-arrows-outlined" | "directory-outlined" | "document-outlined" | "dollar-box-outlined" | "dollar-card-outlined" | "dollar-coin-shine-outlined" | "dollar-credit-card-outlined" | "dollar-sign" | "double-buildings-outlined" | "double-left-arrows" | "double-right-arrows" | "download-box-outlined" | "download-outlined" | "edit-template-outlined" | "electronics-outlined" | "email-outlined" | "end-break-outlined" | "enter-arrow" | "entertainment-outlined" | "envelope-outlined" | "evening-outlined" | "expense-approval-outlined" | "expense-outlined" | "explore-outlined" | "extension-outlined" | "external-link" | "eye-invisible-outlined" | "eye-outlined" | "face-id" | "face-meh-outlined" | "face-open-smiley-outlined" | "face-sad-outlined" | "face-smiley-outlined" | "fastfood-outlined" | "feed-outlined" | "file-certified-outlined" | "file-clone-outlined" | "file-copy-outlined" | "file-dispose-outlined" | "file-dollar-certified-outlined" | "file-dollar-outlined" | "file-download-outlined" | "file-export-outlined" | "file-lock-outlined" | "file-outlined" | "file-search-outlined" | "file-secured-outlined" | "file-statutory-outlined" | "file-verified-outlined" | "filter-outlined" | "fitness-outlined" | "folder-outlined" | "folder-upload-outlined" | "folder-user-outlined" | "form-outlined" | "funnel-filter-outline" | "goal-outlined" | "graph-outlined" | "grocery-outlined" | "hand-holding-user-outlined" | "handshake-outlined" | "happy-sun-outlined" | "health-bag-outlined" | "heart-outlined" | "home-active-outlined" | "home-outlined" | "id-card-outlined" | "image-outlined" | "import-outlined" | "instapay-outlined" | "italic" | "job-search-outlined" | "leave-approval-outlined" | "link-1" | "link-2" | "list-outlined" | "live-help-outlined" | "local_mall_outlined" | "location-on-outlined" | "location-outlined" | "lock-outlined" | "locked-file-outlined" | "log-out" | "mail-outlined" | "map-outlined" | "media-content-outlined" | "menu-close" | "menu-expand" | "menu-fold-outlined" | "menu-unfold-outlined" | "moneybag-outlined" | "moon-outlined" | "more-horizontal" | "more-vertical" | "morning-outlined" | "multiple-folders-outlined" | "multiple-users-outlined" | "near-me-outlined" | "node-outlined" | "number-points" | "overview-outlined" | "park-outlined" | "payment-summary-outlined" | "payslip-outlined" | "pencil-outlined" | "percentage" | "phone-outlined" | "piggy-bank-outlined" | "plane-outlined" | "play-circle-outlined" | "print-outlined" | "propane-tank-outlined" | "qr-code-outlined" | "qualification-outlined" | "re-assign" | "redeem" | "refresh" | "remove" | "reply-outlined" | "restart" | "restaurant-outlined" | "resume-outlined" | "return-arrow" | "rostering-outlined" | "safety-outlined" | "save-outlined" | "schedule-outlined" | "search-outlined" | "search-secured-outlined" | "send-outlined" | "share-1" | "share-2" | "share-outlined-2" | "share-outlined" | "shield-check-outlined" | "shop-outlined" | "shopping_basket_outlined" | "show-chart-outlined" | "single-down-arrow" | "single-left-arrow" | "single-right-arrow" | "single-up-arrow" | "smart-match-outlined" | "sparkle-outlined" | "speaker-active-outlined" | "speaker-outlined" | "star-circle-outlined" | "star-outlined" | "start-break-outlined" | "stash-outlined" | "stopwatch-outlined" | "strikethrough" | "styler-outlined" | "suitcase-clock-outlined" | "suitcase-outlined" | "survey-outlined" | "switch-outlined" | "sync" | "tag-outlined" | "target-outlined" | "tennis-outlined" | "thumb-down-outlined" | "ticket-outlined" | "timesheet-outlined" | "timesheets-outlined" | "today-outlined" | "transfer" | "transportation-outlined" | "trash-bin-outlined" | "umbrela-outlined" | "unavailability-outlined" | "unavailable" | "underline" | "union-outlined" | "unlock-outlined" | "upload-outlined" | "user-circle-outlined" | "user-gear-outlined" | "user-outlined" | "user-rectangle-outlined" | "video-1-outlined" | "video-2-outlined" | "volunteer-outlined" | "wallet-outlined" | "wellness-outlined" | undefined;
|
|
114
114
|
export declare const renderPrefix: ({ state, prefix, }: {
|
|
115
115
|
state: State;
|
|
116
116
|
prefix?: IconName | React.ReactElement;
|