dhre-ui-kit 0.0.178 → 0.0.180
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/lib/index.d.ts +1 -1
- package/lib/index.js +27 -27
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +27 -27
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.d.ts
CHANGED
|
@@ -632,7 +632,7 @@ interface CustomDropdownProps {
|
|
|
632
632
|
menuContainerStyle?: ViewStyle;
|
|
633
633
|
activeColor?: string;
|
|
634
634
|
}
|
|
635
|
-
declare const CustomDropdown: React$1.
|
|
635
|
+
declare const CustomDropdown: (props: CustomDropdownProps) => React$1.JSX.Element;
|
|
636
636
|
|
|
637
637
|
interface CustomSwitchBtnProps {
|
|
638
638
|
value: boolean;
|
package/lib/index.js
CHANGED
|
@@ -251,12 +251,12 @@ const theme = {
|
|
|
251
251
|
dark: "#404040"
|
|
252
252
|
},
|
|
253
253
|
[Theme.BORDER_SEPRATOR]: {
|
|
254
|
-
light: "#
|
|
255
|
-
dark: "#
|
|
254
|
+
light: "#F5F5F5",
|
|
255
|
+
dark: "#282828"
|
|
256
256
|
},
|
|
257
257
|
[Theme.BORDER_SEPERATOR_HEADER]: {
|
|
258
258
|
light: "#E1E1E1",
|
|
259
|
-
dark: "#
|
|
259
|
+
dark: "#373737"
|
|
260
260
|
},
|
|
261
261
|
[Theme.WARNING]: {
|
|
262
262
|
light: "#B65E01",
|
|
@@ -3368,28 +3368,28 @@ const styles$8 = reactNative.StyleSheet.create({
|
|
|
3368
3368
|
}
|
|
3369
3369
|
});
|
|
3370
3370
|
|
|
3371
|
-
const CustomDropdown = ({
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3387
|
-
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3391
|
-
|
|
3392
|
-
}
|
|
3371
|
+
const CustomDropdown = (props) => {
|
|
3372
|
+
const {
|
|
3373
|
+
labelField = "label",
|
|
3374
|
+
valueField = "value",
|
|
3375
|
+
label,
|
|
3376
|
+
placeholder,
|
|
3377
|
+
containerStyle,
|
|
3378
|
+
dropdownStyle,
|
|
3379
|
+
dropdownFocusStyle,
|
|
3380
|
+
placeholderStyle,
|
|
3381
|
+
selectedTextStyle,
|
|
3382
|
+
iconStyle,
|
|
3383
|
+
labelStyle,
|
|
3384
|
+
labelFocusStyle,
|
|
3385
|
+
defaultValue,
|
|
3386
|
+
iconColor,
|
|
3387
|
+
itemTextStyle,
|
|
3388
|
+
onValueChange,
|
|
3389
|
+
itemContainerStyle,
|
|
3390
|
+
menuContainerStyle,
|
|
3391
|
+
activeColor
|
|
3392
|
+
} = props;
|
|
3393
3393
|
const [value, setValue] = React.useState(defaultValue);
|
|
3394
3394
|
const [isFocus, setIsFocus] = React.useState(false);
|
|
3395
3395
|
const renderLabel = () => {
|
|
@@ -3427,7 +3427,6 @@ const CustomDropdown = ({
|
|
|
3427
3427
|
placeholderStyle: [styles$7.placeholderStyle, placeholderStyle],
|
|
3428
3428
|
selectedTextStyle: [styles$7.selectedTextStyle, selectedTextStyle],
|
|
3429
3429
|
iconStyle: [styles$7.iconStyle, iconStyle],
|
|
3430
|
-
data: data ?? [],
|
|
3431
3430
|
labelField,
|
|
3432
3431
|
valueField,
|
|
3433
3432
|
placeholder: !isFocus ? placeholder : "",
|
|
@@ -3440,7 +3439,8 @@ const CustomDropdown = ({
|
|
|
3440
3439
|
itemTextStyle,
|
|
3441
3440
|
containerStyle: menuContainerStyle,
|
|
3442
3441
|
activeColor,
|
|
3443
|
-
itemContainerStyle: [styles$7.itemListStyle, itemContainerStyle]
|
|
3442
|
+
itemContainerStyle: [styles$7.itemListStyle, itemContainerStyle],
|
|
3443
|
+
...props
|
|
3444
3444
|
}
|
|
3445
3445
|
));
|
|
3446
3446
|
};
|