@draftbit/core 46.4.4-33fa1d.2 → 46.4.4-38a1ca.2
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/commonjs/Provider.js +9 -0
- package/lib/commonjs/components/Accordion/AccordionGroup.js +14 -0
- package/lib/commonjs/components/Accordion/AccordionItem.js +13 -0
- package/lib/commonjs/components/Accordion/index.js +3 -0
- package/lib/commonjs/components/ActionSheet/ActionSheet.js +9 -0
- package/lib/commonjs/components/ActionSheet/ActionSheetCancel.js +5 -0
- package/lib/commonjs/components/ActionSheet/ActionSheetItem.js +7 -0
- package/lib/commonjs/components/ActionSheet/index.js +4 -0
- package/lib/commonjs/components/AnimatedCircularProgress.js +15 -0
- package/lib/commonjs/components/AspectRatio.js +10 -0
- package/lib/commonjs/components/AvatarEdit.js +12 -0
- package/lib/commonjs/components/Banner.js +23 -9
- package/lib/commonjs/components/Button.js +19 -2
- package/lib/commonjs/components/Card.js +14 -0
- package/lib/commonjs/components/CardBlock.js +15 -0
- package/lib/commonjs/components/CardContainer.js +18 -0
- package/lib/commonjs/components/CardContainerRating.js +20 -2
- package/lib/commonjs/components/CardContainerShortImage.js +12 -0
- package/lib/commonjs/components/CardInline.js +14 -1
- package/lib/commonjs/components/Carousel.js +21 -3
- package/lib/commonjs/components/Checkbox/Checkbox.js +18 -3
- package/lib/commonjs/components/Checkbox/CheckboxGroup.js +11 -0
- package/lib/commonjs/components/Checkbox/CheckboxGroupRow.js +20 -0
- package/lib/commonjs/components/Checkbox/CheckboxRow.js +24 -3
- package/lib/commonjs/components/Checkbox/context.js +5 -0
- package/lib/commonjs/components/Checkbox/index.js +4 -0
- package/lib/commonjs/components/CircleImage.js +9 -0
- package/lib/commonjs/components/CircularProgress.js +13 -3
- package/lib/commonjs/components/Config.js +13 -5
- package/lib/commonjs/components/Container.js +11 -0
- package/lib/commonjs/components/DatePicker/DatePicker.js +72 -30
- package/lib/commonjs/components/DatePicker/{DatePickerComponent.web.js → DatePickerComponent.__web.js} +13 -0
- package/lib/commonjs/components/DatePicker/DatePickerComponent.js +9 -0
- package/lib/commonjs/components/DeprecatedButton.js +23 -0
- package/lib/commonjs/components/DeprecatedCardWrapper.js +12 -15
- package/lib/commonjs/components/DeprecatedFAB.js +26 -0
- package/lib/commonjs/components/Divider.js +9 -0
- package/lib/commonjs/components/Elevation.js +11 -0
- package/lib/commonjs/components/FAB.js +10 -0
- package/lib/commonjs/components/FieldSearchBarFull.js +18 -0
- package/lib/commonjs/components/FormRow.js +10 -0
- package/lib/commonjs/components/Header.js +13 -0
- package/lib/commonjs/components/HeaderLarge.js +9 -0
- package/lib/commonjs/components/HeaderMedium.js +9 -0
- package/lib/commonjs/components/HeaderOverline.js +9 -0
- package/lib/commonjs/components/IconButton.js +10 -0
- package/lib/commonjs/components/Image.js +17 -0
- package/lib/commonjs/components/Layout.js +12 -2
- package/lib/commonjs/components/NumberInput.js +21 -8
- package/lib/commonjs/components/Picker/Picker.js +42 -9
- package/lib/commonjs/components/Picker/PickerComponent.android.js +23 -6
- package/lib/commonjs/components/Picker/PickerComponent.ios.js +27 -8
- package/lib/commonjs/components/Picker/PickerComponent.web.js +23 -6
- package/lib/commonjs/components/Portal/Portal.js +14 -4
- package/lib/commonjs/components/Portal/PortalConsumer.js +15 -5
- package/lib/commonjs/components/Portal/PortalHost.js +31 -4
- package/lib/commonjs/components/Portal/PortalManager.js +19 -7
- package/lib/commonjs/components/ProgressBar.js +25 -5
- package/lib/commonjs/components/ProgressCircle.js +10 -0
- package/lib/commonjs/components/ProgressIndicator.js +9 -0
- package/lib/commonjs/components/RadioButton/RadioButton.js +14 -1
- package/lib/commonjs/components/RadioButton/RadioButtonFieldGroup.js +10 -0
- package/lib/commonjs/components/RadioButton/RadioButtonGroup.js +14 -0
- package/lib/commonjs/components/RadioButton/RadioButtonRow.js +21 -1
- package/lib/commonjs/components/RadioButton/context.js +5 -0
- package/lib/commonjs/components/RadioButton/index.js +5 -0
- package/lib/commonjs/components/Row.js +11 -0
- package/lib/commonjs/components/RowBodyIcon.js +10 -0
- package/lib/commonjs/components/RowHeadlineImageCaption.js +11 -2
- package/lib/commonjs/components/RowHeadlineImageIcon.js +10 -0
- package/lib/commonjs/components/SVG.js +9 -0
- package/lib/commonjs/components/ScreenContainer.js +14 -0
- package/lib/commonjs/components/Slider.js +21 -0
- package/lib/commonjs/components/StarRating.js +10 -0
- package/lib/commonjs/components/StepIndicator.js +39 -5
- package/lib/commonjs/components/Stepper.js +26 -7
- package/lib/commonjs/components/Surface.js +14 -0
- package/lib/commonjs/components/Swiper/Swiper.js +8 -0
- package/lib/commonjs/components/Swiper/SwiperItem.js +6 -0
- package/lib/commonjs/components/Swiper/index.js +3 -0
- package/lib/commonjs/components/Switch.js +18 -5
- package/lib/commonjs/components/Text.js +18 -3
- package/lib/commonjs/components/TextField.js +62 -12
- package/lib/commonjs/components/ToggleButton.js +14 -0
- package/lib/commonjs/components/Touchable.js +5 -0
- package/lib/commonjs/components/Touchable.web.js +2 -0
- package/lib/commonjs/components/Typography.js +5 -0
- package/lib/commonjs/components/useAuthState.js +9 -0
- package/lib/commonjs/constants.js +4 -0
- package/lib/commonjs/hooks.js +7 -4
- package/lib/commonjs/index.js +52 -0
- package/lib/commonjs/interfaces/Icon.js +5 -3
- package/lib/commonjs/mappings/Accordion.js +2 -0
- package/lib/commonjs/mappings/AccordionItem.js +2 -0
- package/lib/commonjs/mappings/ActionSheet.js +2 -0
- package/lib/commonjs/mappings/ActionSheetCancel.js +2 -0
- package/lib/commonjs/mappings/ActionSheetItem.js +2 -0
- package/lib/commonjs/mappings/ActivityIndicator.js +2 -0
- package/lib/commonjs/mappings/AudioPlayer.js +34 -2
- package/lib/commonjs/mappings/AvatarEdit.js +2 -0
- package/lib/commonjs/mappings/Banner.js +2 -0
- package/lib/commonjs/mappings/BlurView.js +2 -0
- package/lib/commonjs/mappings/Button.js +5 -6
- package/lib/commonjs/mappings/Card.js +4 -3
- package/lib/commonjs/mappings/CardBlock.js +5 -6
- package/lib/commonjs/mappings/CardContainer.js +7 -5
- package/lib/commonjs/mappings/CardContainerRating.js +4 -4
- package/lib/commonjs/mappings/CardContainerShortImage.js +2 -0
- package/lib/commonjs/mappings/CardInline.js +2 -0
- package/lib/commonjs/mappings/Carousel.js +2 -0
- package/lib/commonjs/mappings/Checkbox.js +2 -0
- package/lib/commonjs/mappings/CheckboxGroup.js +2 -0
- package/lib/commonjs/mappings/CheckboxRow.js +2 -0
- package/lib/commonjs/mappings/CircleImage.js +2 -0
- package/lib/commonjs/mappings/Container.js +2 -0
- package/lib/commonjs/mappings/CustomCode.js +2 -0
- package/lib/commonjs/mappings/DatePicker.js +24 -7
- package/lib/commonjs/mappings/Divider.js +2 -0
- package/lib/commonjs/mappings/FAB.js +2 -0
- package/lib/commonjs/mappings/Fetch.js +2 -0
- package/lib/commonjs/mappings/FieldSearchBarFull.js +3 -2
- package/lib/commonjs/mappings/FlashList.js +2 -0
- package/lib/commonjs/mappings/FlatList.js +2 -0
- package/lib/commonjs/mappings/HeaderLarge.js +2 -0
- package/lib/commonjs/mappings/HeaderMedium.js +2 -0
- package/lib/commonjs/mappings/HeaderOverline.js +2 -0
- package/lib/commonjs/mappings/Icon.js +3 -2
- package/lib/commonjs/mappings/IconButton.js +2 -0
- package/lib/commonjs/mappings/Image.js +2 -0
- package/lib/commonjs/mappings/ImageBackground.js +2 -0
- package/lib/commonjs/mappings/KeyboardAvoidingView.js +2 -0
- package/lib/commonjs/mappings/KeyboardAwareScrollView.js +2 -0
- package/lib/commonjs/mappings/Layout.js +2 -0
- package/lib/commonjs/mappings/LinearGradient.js +2 -0
- package/lib/commonjs/mappings/MapCallout.js +2 -0
- package/lib/commonjs/mappings/MapMarker.js +2 -0
- package/lib/commonjs/mappings/MapView.js +2 -0
- package/lib/commonjs/mappings/Modal.js +2 -0
- package/lib/commonjs/mappings/NumberInput.js +4 -4
- package/lib/commonjs/mappings/Picker.js +4 -4
- package/lib/commonjs/mappings/ProgressBar.js +2 -0
- package/lib/commonjs/mappings/ProgressCircle.js +2 -0
- package/lib/commonjs/mappings/ProgressIndicator.js +2 -0
- package/lib/commonjs/mappings/RadioButton.js +2 -0
- package/lib/commonjs/mappings/RadioButtonGroup.js +2 -0
- package/lib/commonjs/mappings/RadioButtonRow.js +2 -0
- package/lib/commonjs/mappings/RowBodyIcon.js +2 -0
- package/lib/commonjs/mappings/RowHeadlineImageCaption.js +2 -0
- package/lib/commonjs/mappings/RowHeadlineImageIcon.js +8 -12
- package/lib/commonjs/mappings/SVG.js +2 -0
- package/lib/commonjs/mappings/SafeAreaView.js +2 -0
- package/lib/commonjs/mappings/ScrollView.js +2 -0
- package/lib/commonjs/mappings/Slider.js +2 -0
- package/lib/commonjs/mappings/StarRating.js +3 -1
- package/lib/commonjs/mappings/Stepper.js +3 -1
- package/lib/commonjs/mappings/Surface.js +2 -0
- package/lib/commonjs/mappings/Swiper.js +2 -0
- package/lib/commonjs/mappings/SwiperItem.js +2 -0
- package/lib/commonjs/mappings/Switch.js +2 -0
- package/lib/commonjs/mappings/Text.js +5 -5
- package/lib/commonjs/mappings/TextArea.js +17 -5
- package/lib/commonjs/mappings/TextField.js +22 -11
- package/lib/commonjs/mappings/TextInput.js +17 -5
- package/lib/commonjs/mappings/ToggleButton.js +2 -0
- package/lib/commonjs/mappings/Touchable.js +2 -0
- package/lib/commonjs/mappings/Video.js +2 -0
- package/lib/commonjs/mappings/View.js +2 -0
- package/lib/commonjs/mappings/WebView.js +2 -0
- package/lib/commonjs/styles/DarkTheme.js +6 -5
- package/lib/commonjs/styles/DefaultTheme.js +17 -26
- package/lib/commonjs/styles/fonts.js +5 -3
- package/lib/commonjs/styles/overlay.js +14 -5
- package/lib/commonjs/styles/shadow.js +9 -0
- package/lib/commonjs/theming.js +4 -0
- package/lib/commonjs/utilities.js +14 -2
- package/lib/module/Provider.js +1 -0
- package/lib/module/components/Accordion/AccordionGroup.js +4 -0
- package/lib/module/components/Accordion/AccordionItem.js +3 -0
- package/lib/module/components/ActionSheet/ActionSheet.js +2 -0
- package/lib/module/components/ActionSheet/ActionSheetCancel.js +2 -0
- package/lib/module/components/ActionSheet/ActionSheetItem.js +2 -0
- package/lib/module/components/AnimatedCircularProgress.js +6 -0
- package/lib/module/components/AspectRatio.js +7 -18
- package/lib/module/components/AvatarEdit.js +3 -0
- package/lib/module/components/Banner.js +10 -9
- package/lib/module/components/Button.js +10 -2
- package/lib/module/components/Card.js +2 -0
- package/lib/module/components/CardBlock.js +6 -0
- package/lib/module/components/CardContainer.js +7 -0
- package/lib/module/components/CardContainerRating.js +8 -2
- package/lib/module/components/CardContainerShortImage.js +7 -18
- package/lib/module/components/CardInline.js +2 -0
- package/lib/module/components/Carousel.js +9 -3
- package/lib/module/components/Checkbox/Checkbox.js +9 -3
- package/lib/module/components/Checkbox/CheckboxGroup.js +5 -0
- package/lib/module/components/Checkbox/CheckboxGroupRow.js +8 -0
- package/lib/module/components/Checkbox/CheckboxRow.js +11 -3
- package/lib/module/components/Checkbox/context.js +2 -0
- package/lib/module/components/CircleImage.js +3 -0
- package/lib/module/components/CircularProgress.js +9 -3
- package/lib/module/components/Config.js +11 -5
- package/lib/module/components/Container.js +3 -0
- package/lib/module/components/DatePicker/DatePicker.js +56 -30
- package/lib/module/components/DatePicker/{DatePickerComponent.web.js → DatePickerComponent.__web.js} +5 -0
- package/lib/module/components/DatePicker/DatePickerComponent.js +4 -0
- package/lib/module/components/DeprecatedButton.js +12 -21
- package/lib/module/components/DeprecatedCardWrapper.js +6 -0
- package/lib/module/components/DeprecatedFAB.js +13 -0
- package/lib/module/components/Divider.js +4 -18
- package/lib/module/components/Elevation.js +5 -14
- package/lib/module/components/FAB.js +3 -0
- package/lib/module/components/FieldSearchBarFull.js +9 -0
- package/lib/module/components/FormRow.js +1 -0
- package/lib/module/components/Header.js +2 -0
- package/lib/module/components/HeaderLarge.js +2 -0
- package/lib/module/components/HeaderMedium.js +2 -0
- package/lib/module/components/HeaderOverline.js +2 -0
- package/lib/module/components/IconButton.js +3 -0
- package/lib/module/components/Image.js +12 -18
- package/lib/module/components/Layout.js +3 -4
- package/lib/module/components/NumberInput.js +16 -8
- package/lib/module/components/Picker/Picker.js +25 -8
- package/lib/module/components/Picker/PickerComponent.android.js +10 -6
- package/lib/module/components/Picker/PickerComponent.ios.js +11 -8
- package/lib/module/components/Picker/PickerComponent.web.js +10 -6
- package/lib/module/components/Portal/Portal.js +6 -4
- package/lib/module/components/Portal/PortalConsumer.js +10 -5
- package/lib/module/components/Portal/PortalHost.js +22 -4
- package/lib/module/components/Portal/PortalManager.js +14 -7
- package/lib/module/components/ProgressBar.js +17 -5
- package/lib/module/components/ProgressCircle.js +2 -0
- package/lib/module/components/ProgressIndicator.js +2 -0
- package/lib/module/components/RadioButton/RadioButton.js +6 -1
- package/lib/module/components/RadioButton/RadioButtonFieldGroup.js +3 -0
- package/lib/module/components/RadioButton/RadioButtonGroup.js +7 -0
- package/lib/module/components/RadioButton/RadioButtonRow.js +13 -22
- package/lib/module/components/RadioButton/context.js +2 -0
- package/lib/module/components/Row.js +2 -0
- package/lib/module/components/RowBodyIcon.js +2 -0
- package/lib/module/components/RowHeadlineImageCaption.js +3 -2
- package/lib/module/components/RowHeadlineImageIcon.js +2 -0
- package/lib/module/components/SVG.js +2 -0
- package/lib/module/components/ScreenContainer.js +6 -0
- package/lib/module/components/Slider.js +10 -0
- package/lib/module/components/StarRating.js +3 -0
- package/lib/module/components/StepIndicator.js +29 -5
- package/lib/module/components/Stepper.js +16 -9
- package/lib/module/components/Surface.js +5 -0
- package/lib/module/components/Swiper/Swiper.js +4 -0
- package/lib/module/components/Swiper/SwiperItem.js +2 -0
- package/lib/module/components/Switch.js +7 -5
- package/lib/module/components/Text.js +10 -3
- package/lib/module/components/TextField.js +50 -12
- package/lib/module/components/ToggleButton.js +5 -0
- package/lib/module/components/Touchable.js +1 -0
- package/lib/module/components/useAuthState.js +4 -0
- package/lib/module/constants.js +1 -2
- package/lib/module/hooks.js +2 -4
- package/lib/module/index.js +2 -4
- package/lib/module/interfaces/Icon.js +1 -2
- package/lib/module/mappings/AudioPlayer.js +33 -3
- package/lib/module/mappings/Button.js +3 -6
- package/lib/module/mappings/Card.js +2 -3
- package/lib/module/mappings/CardBlock.js +3 -6
- package/lib/module/mappings/CardContainer.js +5 -5
- package/lib/module/mappings/CardContainerRating.js +2 -4
- package/lib/module/mappings/DatePicker.js +23 -8
- package/lib/module/mappings/Fetch.js +1 -0
- package/lib/module/mappings/FieldSearchBarFull.js +1 -2
- package/lib/module/mappings/Icon.js +1 -2
- package/lib/module/mappings/NumberInput.js +2 -4
- package/lib/module/mappings/Picker.js +2 -4
- package/lib/module/mappings/RowHeadlineImageIcon.js +6 -12
- package/lib/module/mappings/StarRating.js +1 -1
- package/lib/module/mappings/Stepper.js +2 -2
- package/lib/module/mappings/Text.js +3 -5
- package/lib/module/mappings/TextArea.js +16 -6
- package/lib/module/mappings/TextField.js +20 -11
- package/lib/module/mappings/TextInput.js +16 -6
- package/lib/module/styles/DarkTheme.js +2 -4
- package/lib/module/styles/DefaultTheme.js +13 -26
- package/lib/module/styles/fonts.js +1 -2
- package/lib/module/styles/overlay.js +10 -4
- package/lib/module/styles/shadow.js +6 -0
- package/lib/module/utilities.js +5 -2
- package/lib/typescript/src/Provider.d.ts +1 -1
- package/lib/typescript/src/Provider.d.ts.map +1 -1
- package/lib/typescript/src/components/Accordion/AccordionGroup.d.ts +1 -1
- package/lib/typescript/src/components/Accordion/AccordionGroup.d.ts.map +1 -1
- package/lib/typescript/src/components/Accordion/AccordionItem.d.ts +1 -1
- package/lib/typescript/src/components/Accordion/AccordionItem.d.ts.map +1 -1
- package/lib/typescript/src/components/ActionSheet/ActionSheetCancel.d.ts +1 -1
- package/lib/typescript/src/components/ActionSheet/ActionSheetCancel.d.ts.map +1 -1
- package/lib/typescript/src/components/ActionSheet/ActionSheetItem.d.ts +1 -1
- package/lib/typescript/src/components/ActionSheet/ActionSheetItem.d.ts.map +1 -1
- package/lib/typescript/src/components/AnimatedCircularProgress.d.ts +1 -1
- package/lib/typescript/src/components/AnimatedCircularProgress.d.ts.map +1 -1
- package/lib/typescript/src/components/AspectRatio.d.ts +1 -1
- package/lib/typescript/src/components/AspectRatio.d.ts.map +1 -1
- package/lib/typescript/src/components/AvatarEdit.d.ts +1 -1
- package/lib/typescript/src/components/AvatarEdit.d.ts.map +1 -1
- package/lib/typescript/src/components/Banner.d.ts +1 -1
- package/lib/typescript/src/components/Banner.d.ts.map +1 -1
- package/lib/typescript/src/components/Card.d.ts +1 -1
- package/lib/typescript/src/components/Card.d.ts.map +1 -1
- package/lib/typescript/src/components/CardBlock.d.ts +1 -1
- package/lib/typescript/src/components/CardBlock.d.ts.map +1 -1
- package/lib/typescript/src/components/CardContainer.d.ts +1 -1
- package/lib/typescript/src/components/CardContainer.d.ts.map +1 -1
- package/lib/typescript/src/components/CardContainerRating.d.ts +1 -1
- package/lib/typescript/src/components/CardContainerRating.d.ts.map +1 -1
- package/lib/typescript/src/components/CardContainerShortImage.d.ts +1 -1
- package/lib/typescript/src/components/CardContainerShortImage.d.ts.map +1 -1
- package/lib/typescript/src/components/CardInline.d.ts +1 -1
- package/lib/typescript/src/components/CardInline.d.ts.map +1 -1
- package/lib/typescript/src/components/Carousel.d.ts +1 -1
- package/lib/typescript/src/components/Carousel.d.ts.map +1 -1
- package/lib/typescript/src/components/CircularProgress.d.ts +1 -1
- package/lib/typescript/src/components/CircularProgress.d.ts.map +1 -1
- package/lib/typescript/src/components/Container.d.ts +1 -1
- package/lib/typescript/src/components/Container.d.ts.map +1 -1
- package/lib/typescript/src/components/DatePicker/DatePicker.d.ts +7 -5
- package/lib/typescript/src/components/DatePicker/DatePicker.d.ts.map +1 -1
- package/lib/typescript/src/components/DatePicker/{DatePickerComponent.web.d.ts → DatePickerComponent.__web.d.ts} +1 -1
- package/lib/typescript/src/components/DatePicker/{DatePickerComponent.web.d.ts.map → DatePickerComponent.__web.d.ts.map} +1 -1
- package/lib/typescript/src/components/DatePicker/DatePickerComponent.d.ts.map +1 -1
- package/lib/typescript/src/components/DatePicker/DatePickerComponentType.d.ts +1 -0
- package/lib/typescript/src/components/DatePicker/DatePickerComponentType.d.ts.map +1 -1
- package/lib/typescript/src/components/DeprecatedButton.d.ts +1 -1
- package/lib/typescript/src/components/DeprecatedButton.d.ts.map +1 -1
- package/lib/typescript/src/components/DeprecatedCardWrapper.d.ts +1 -1
- package/lib/typescript/src/components/DeprecatedCardWrapper.d.ts.map +1 -1
- package/lib/typescript/src/components/DeprecatedFAB.d.ts +1 -1
- package/lib/typescript/src/components/DeprecatedFAB.d.ts.map +1 -1
- package/lib/typescript/src/components/Divider.d.ts +1 -1
- package/lib/typescript/src/components/Divider.d.ts.map +1 -1
- package/lib/typescript/src/components/Elevation.d.ts +1 -1
- package/lib/typescript/src/components/Elevation.d.ts.map +1 -1
- package/lib/typescript/src/components/FAB.d.ts +1 -1
- package/lib/typescript/src/components/FAB.d.ts.map +1 -1
- package/lib/typescript/src/components/FieldSearchBarFull.d.ts +1 -1
- package/lib/typescript/src/components/FieldSearchBarFull.d.ts.map +1 -1
- package/lib/typescript/src/components/FormRow.d.ts +1 -1
- package/lib/typescript/src/components/FormRow.d.ts.map +1 -1
- package/lib/typescript/src/components/Header.d.ts +1 -1
- package/lib/typescript/src/components/Header.d.ts.map +1 -1
- package/lib/typescript/src/components/HeaderLarge.d.ts +1 -1
- package/lib/typescript/src/components/HeaderLarge.d.ts.map +1 -1
- package/lib/typescript/src/components/HeaderMedium.d.ts +1 -1
- package/lib/typescript/src/components/HeaderMedium.d.ts.map +1 -1
- package/lib/typescript/src/components/HeaderOverline.d.ts +1 -1
- package/lib/typescript/src/components/HeaderOverline.d.ts.map +1 -1
- package/lib/typescript/src/components/IconButton.d.ts +1 -1
- package/lib/typescript/src/components/IconButton.d.ts.map +1 -1
- package/lib/typescript/src/components/Justification.d.ts +1 -1
- package/lib/typescript/src/components/Justification.d.ts.map +1 -1
- package/lib/typescript/src/components/Picker/Picker.d.ts +1 -1
- package/lib/typescript/src/components/Picker/Picker.d.ts.map +1 -1
- package/lib/typescript/src/components/Portal/Portal.d.ts +1 -1
- package/lib/typescript/src/components/Portal/Portal.d.ts.map +1 -1
- package/lib/typescript/src/components/Portal/PortalConsumer.d.ts +1 -1
- package/lib/typescript/src/components/Portal/PortalConsumer.d.ts.map +1 -1
- package/lib/typescript/src/components/Portal/PortalHost.d.ts +2 -2
- package/lib/typescript/src/components/Portal/PortalHost.d.ts.map +1 -1
- package/lib/typescript/src/components/Portal/PortalManager.d.ts +1 -1
- package/lib/typescript/src/components/Portal/PortalManager.d.ts.map +1 -1
- package/lib/typescript/src/components/ProgressBar.d.ts +1 -1
- package/lib/typescript/src/components/ProgressBar.d.ts.map +1 -1
- package/lib/typescript/src/components/ProgressCircle.d.ts +1 -1
- package/lib/typescript/src/components/ProgressCircle.d.ts.map +1 -1
- package/lib/typescript/src/components/ProgressIndicator.d.ts +1 -1
- package/lib/typescript/src/components/ProgressIndicator.d.ts.map +1 -1
- package/lib/typescript/src/components/RadioButton/RadioButton.d.ts +1 -1
- package/lib/typescript/src/components/RadioButton/RadioButton.d.ts.map +1 -1
- package/lib/typescript/src/components/ResizeMode.d.ts +1 -1
- package/lib/typescript/src/components/ResizeMode.d.ts.map +1 -1
- package/lib/typescript/src/components/Row.d.ts +1 -1
- package/lib/typescript/src/components/Row.d.ts.map +1 -1
- package/lib/typescript/src/components/RowBodyIcon.d.ts +1 -1
- package/lib/typescript/src/components/RowBodyIcon.d.ts.map +1 -1
- package/lib/typescript/src/components/RowHeadlineImageCaption.d.ts +1 -1
- package/lib/typescript/src/components/RowHeadlineImageCaption.d.ts.map +1 -1
- package/lib/typescript/src/components/RowHeadlineImageIcon.d.ts +1 -1
- package/lib/typescript/src/components/RowHeadlineImageIcon.d.ts.map +1 -1
- package/lib/typescript/src/components/SVG.d.ts +1 -1
- package/lib/typescript/src/components/SVG.d.ts.map +1 -1
- package/lib/typescript/src/components/ScreenContainer.d.ts +1 -1
- package/lib/typescript/src/components/ScreenContainer.d.ts.map +1 -1
- package/lib/typescript/src/components/Slider.d.ts +1 -1
- package/lib/typescript/src/components/Slider.d.ts.map +1 -1
- package/lib/typescript/src/components/StarRating.d.ts +1 -1
- package/lib/typescript/src/components/StarRating.d.ts.map +1 -1
- package/lib/typescript/src/components/StepIndicator.d.ts +2 -2
- package/lib/typescript/src/components/StepIndicator.d.ts.map +1 -1
- package/lib/typescript/src/components/Stepper.d.ts +2 -3
- package/lib/typescript/src/components/Stepper.d.ts.map +1 -1
- package/lib/typescript/src/components/Surface.d.ts +1 -1
- package/lib/typescript/src/components/Surface.d.ts.map +1 -1
- package/lib/typescript/src/components/Switch.d.ts +2 -2
- package/lib/typescript/src/components/Switch.d.ts.map +1 -1
- package/lib/typescript/src/components/Text.d.ts +1 -1
- package/lib/typescript/src/components/Text.d.ts.map +1 -1
- package/lib/typescript/src/components/TextField.d.ts +1 -1
- package/lib/typescript/src/components/TextField.d.ts.map +1 -1
- package/lib/typescript/src/components/ToggleButton.d.ts +1 -1
- package/lib/typescript/src/components/ToggleButton.d.ts.map +1 -1
- package/lib/typescript/src/components/Touchable.d.ts +1 -1
- package/lib/typescript/src/components/Touchable.d.ts.map +1 -1
- package/lib/typescript/src/components/Typography.d.ts +1 -1
- package/lib/typescript/src/components/Typography.d.ts.map +1 -1
- package/lib/typescript/src/interfaces/Icon.d.ts +2 -2
- package/lib/typescript/src/interfaces/Icon.d.ts.map +1 -1
- package/lib/typescript/src/mappings/AudioPlayer.d.ts +62 -1
- package/lib/typescript/src/mappings/AudioPlayer.d.ts.map +1 -1
- package/lib/typescript/src/mappings/DatePicker.d.ts +42 -0
- package/lib/typescript/src/mappings/DatePicker.d.ts.map +1 -1
- package/lib/typescript/src/mappings/Stepper.d.ts.map +1 -1
- package/lib/typescript/src/mappings/TextArea.d.ts +21 -1
- package/lib/typescript/src/mappings/TextArea.d.ts.map +1 -1
- package/lib/typescript/src/mappings/TextField.d.ts +22 -2
- package/lib/typescript/src/mappings/TextField.d.ts.map +1 -1
- package/lib/typescript/src/mappings/TextInput.d.ts +21 -1
- package/lib/typescript/src/mappings/TextInput.d.ts.map +1 -1
- package/lib/typescript/src/styles/DefaultTheme.d.ts +1 -1
- package/lib/typescript/src/styles/DefaultTheme.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/components/DatePicker/DatePicker.js +20 -14
- package/src/components/DatePicker/DatePicker.tsx +36 -18
- package/src/components/DatePicker/{DatePickerComponent.web.js → DatePickerComponent.__web.js} +2 -2
- package/src/components/DatePicker/{DatePickerComponent.web.tsx → DatePickerComponent.__web.tsx} +3 -0
- package/src/components/DatePicker/DatePickerComponent.js +2 -2
- package/src/components/DatePicker/DatePickerComponent.tsx +2 -0
- package/src/components/DatePicker/DatePickerComponentType.ts +1 -0
- package/src/components/Picker/Picker.js +1 -1
- package/src/components/Picker/Picker.tsx +2 -2
- package/src/components/Stepper.js +5 -3
- package/src/components/Stepper.tsx +5 -5
- package/src/mappings/AudioPlayer.js +39 -2
- package/src/mappings/AudioPlayer.ts +41 -1
- package/src/mappings/DatePicker.js +28 -4
- package/src/mappings/DatePicker.ts +30 -3
- package/src/mappings/Stepper.js +5 -2
- package/src/mappings/Stepper.ts +5 -1
- package/src/mappings/TextArea.js +15 -4
- package/src/mappings/TextArea.ts +15 -3
- package/src/mappings/TextField.js +14 -4
- package/src/mappings/TextField.ts +14 -4
- package/src/mappings/TextInput.js +15 -4
- package/src/mappings/TextInput.ts +15 -3
|
@@ -5,19 +5,24 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.checkboxGroupContext = exports.Direction = void 0;
|
|
7
7
|
exports.useCheckboxGroupContext = useCheckboxGroupContext;
|
|
8
|
+
|
|
8
9
|
var _react = require("react");
|
|
10
|
+
|
|
9
11
|
let Direction;
|
|
10
12
|
exports.Direction = Direction;
|
|
13
|
+
|
|
11
14
|
(function (Direction) {
|
|
12
15
|
Direction["Horizontal"] = "horizontal";
|
|
13
16
|
Direction["Vertical"] = "vertical";
|
|
14
17
|
})(Direction || (exports.Direction = Direction = {}));
|
|
18
|
+
|
|
15
19
|
const checkboxGroupContext = /*#__PURE__*/(0, _react.createContext)({
|
|
16
20
|
onValueChange: () => {},
|
|
17
21
|
values: [],
|
|
18
22
|
direction: undefined
|
|
19
23
|
});
|
|
20
24
|
exports.checkboxGroupContext = checkboxGroupContext;
|
|
25
|
+
|
|
21
26
|
function useCheckboxGroupContext() {
|
|
22
27
|
return (0, _react.useContext)(checkboxGroupContext);
|
|
23
28
|
}
|
|
@@ -21,7 +21,11 @@ Object.defineProperty(exports, "CheckboxRow", {
|
|
|
21
21
|
return _CheckboxRow.default;
|
|
22
22
|
}
|
|
23
23
|
});
|
|
24
|
+
|
|
24
25
|
var _Checkbox = _interopRequireDefault(require("./Checkbox"));
|
|
26
|
+
|
|
25
27
|
var _CheckboxGroup = _interopRequireDefault(require("./CheckboxGroup"));
|
|
28
|
+
|
|
26
29
|
var _CheckboxRow = _interopRequireDefault(require("./CheckboxRow"));
|
|
30
|
+
|
|
27
31
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
@@ -4,13 +4,21 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var React = _interopRequireWildcard(require("react"));
|
|
9
|
+
|
|
8
10
|
var _reactNative = require("react-native");
|
|
11
|
+
|
|
9
12
|
var _Config = _interopRequireDefault(require("./Config"));
|
|
13
|
+
|
|
10
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
|
+
|
|
11
16
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
17
|
+
|
|
12
18
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
19
|
+
|
|
13
20
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
21
|
+
|
|
14
22
|
const CircleImage = _ref => {
|
|
15
23
|
let {
|
|
16
24
|
source = _Config.default.placeholderImageURL,
|
|
@@ -31,5 +39,6 @@ const CircleImage = _ref => {
|
|
|
31
39
|
resizeMode: "cover"
|
|
32
40
|
}, props));
|
|
33
41
|
};
|
|
42
|
+
|
|
34
43
|
var _default = CircleImage;
|
|
35
44
|
exports.default = _default;
|
|
@@ -4,16 +4,21 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
8
10
|
var _reactNative = require("react-native");
|
|
11
|
+
|
|
9
12
|
var _reactNativeSvg = require("react-native-svg");
|
|
13
|
+
|
|
10
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
|
-
|
|
12
|
-
function
|
|
13
|
-
|
|
15
|
+
|
|
16
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17
|
+
|
|
14
18
|
class CircularProgress extends _react.default.Component {
|
|
15
19
|
constructor() {
|
|
16
20
|
super(...arguments);
|
|
21
|
+
|
|
17
22
|
_defineProperty(this, "polarToCartesian", (centerX, centerY, radius, angleInDegrees) => {
|
|
18
23
|
var angleInRadians = (angleInDegrees - 90) * Math.PI / 180.0;
|
|
19
24
|
return {
|
|
@@ -21,6 +26,7 @@ class CircularProgress extends _react.default.Component {
|
|
|
21
26
|
y: centerY + radius * Math.sin(angleInRadians)
|
|
22
27
|
};
|
|
23
28
|
});
|
|
29
|
+
|
|
24
30
|
_defineProperty(this, "circlePath", (x, y, radius, startAngle, endAngle) => {
|
|
25
31
|
var start = this.polarToCartesian(x, y, radius, endAngle * 0.9999);
|
|
26
32
|
var end = this.polarToCartesian(x, y, radius, startAngle);
|
|
@@ -28,8 +34,10 @@ class CircularProgress extends _react.default.Component {
|
|
|
28
34
|
var d = ["M", start.x, start.y, "A", radius, radius, 0, largeArcFlag, 0, end.x, end.y];
|
|
29
35
|
return d.join(" ");
|
|
30
36
|
});
|
|
37
|
+
|
|
31
38
|
_defineProperty(this, "clampFill", fill => Math.min(100, Math.max(0, fill)));
|
|
32
39
|
}
|
|
40
|
+
|
|
33
41
|
render() {
|
|
34
42
|
const {
|
|
35
43
|
size,
|
|
@@ -107,6 +115,8 @@ class CircularProgress extends _react.default.Component {
|
|
|
107
115
|
style: localChildrenContainerStyle
|
|
108
116
|
}, children(fill)));
|
|
109
117
|
}
|
|
118
|
+
|
|
110
119
|
}
|
|
120
|
+
|
|
111
121
|
var _default = CircularProgress;
|
|
112
122
|
exports.default = _default;
|
|
@@ -4,38 +4,46 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var _reactNative = require("react-native");
|
|
9
|
+
|
|
8
10
|
const getWindowDimensions = () => {
|
|
9
11
|
const {
|
|
10
12
|
width,
|
|
11
13
|
height
|
|
12
14
|
} = _reactNative.Dimensions.get("window");
|
|
15
|
+
|
|
13
16
|
return {
|
|
14
17
|
windowWidth: width,
|
|
15
18
|
windowHeight: height
|
|
16
19
|
};
|
|
17
20
|
};
|
|
21
|
+
|
|
18
22
|
const {
|
|
19
23
|
windowWidth,
|
|
20
24
|
windowHeight
|
|
21
25
|
} = getWindowDimensions();
|
|
26
|
+
|
|
22
27
|
const getFilters = options => {
|
|
23
28
|
const {
|
|
24
29
|
width,
|
|
25
30
|
height
|
|
26
31
|
} = options;
|
|
27
32
|
const filters = ["c_scale", "q_auto", "dpr_auto"];
|
|
28
|
-
if (width) filters.push(
|
|
29
|
-
if (height) filters.push(
|
|
33
|
+
if (width) filters.push("w_".concat(width));
|
|
34
|
+
if (height) filters.push("h_".concat(height));
|
|
30
35
|
return filters.join(",");
|
|
31
36
|
};
|
|
37
|
+
|
|
32
38
|
const buildImageUrl = (options, name) => {
|
|
33
39
|
const filters = getFilters(options);
|
|
34
|
-
return ["https://res.cloudinary.com/altos/image/upload", filters,
|
|
40
|
+
return ["https://res.cloudinary.com/altos/image/upload", filters, "".concat(name, ".png")].join("/");
|
|
35
41
|
};
|
|
42
|
+
|
|
36
43
|
const getExtension = () => {
|
|
37
44
|
return _reactNative.Platform.OS === "web" ? ".svg" : ".png";
|
|
38
45
|
};
|
|
46
|
+
|
|
39
47
|
var _default = {
|
|
40
48
|
windowWidth,
|
|
41
49
|
windowHeight,
|
|
@@ -74,7 +82,7 @@ var _default = {
|
|
|
74
82
|
fieldSearchBarFullIconSize: 24,
|
|
75
83
|
stepperButtonSize: 40,
|
|
76
84
|
radioButtonSize: 24,
|
|
77
|
-
topSafeAreaViewHeight: 0
|
|
78
|
-
|
|
85
|
+
topSafeAreaViewHeight: 0 // topSafeAreaViewHeight: Platform.OS === "android" ? Constants.statusBarHeight : 0
|
|
86
|
+
|
|
79
87
|
};
|
|
80
88
|
exports.default = _default;
|
|
@@ -4,14 +4,23 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var React = _interopRequireWildcard(require("react"));
|
|
9
|
+
|
|
8
10
|
var _reactNative = require("react-native");
|
|
11
|
+
|
|
9
12
|
var _theming = require("../theming");
|
|
13
|
+
|
|
10
14
|
var _Elevation = _interopRequireDefault(require("./Elevation"));
|
|
15
|
+
|
|
11
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
|
+
|
|
12
18
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
19
|
+
|
|
13
20
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
21
|
+
|
|
14
22
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
23
|
+
|
|
15
24
|
const Container = _ref => {
|
|
16
25
|
let {
|
|
17
26
|
useThemeGutterPadding,
|
|
@@ -89,5 +98,7 @@ const Container = _ref => {
|
|
|
89
98
|
style: innerStyle
|
|
90
99
|
}, children));
|
|
91
100
|
};
|
|
101
|
+
|
|
92
102
|
var _default = (0, _theming.withTheme)(Container);
|
|
103
|
+
|
|
93
104
|
exports.default = _default;
|
|
@@ -4,23 +4,40 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var React = _interopRequireWildcard(require("react"));
|
|
9
|
+
|
|
8
10
|
var _reactNative = require("react-native");
|
|
11
|
+
|
|
9
12
|
var _reactNativeSafeAreaContext = require("react-native-safe-area-context");
|
|
13
|
+
|
|
10
14
|
var _dateformat = _interopRequireDefault(require("dateformat"));
|
|
15
|
+
|
|
11
16
|
var _theming = require("../../theming");
|
|
17
|
+
|
|
12
18
|
var _Portal = _interopRequireDefault(require("../Portal/Portal"));
|
|
19
|
+
|
|
13
20
|
var _Touchable = _interopRequireDefault(require("../Touchable"));
|
|
21
|
+
|
|
14
22
|
var _DatePickerComponent = _interopRequireDefault(require("./DatePickerComponent"));
|
|
23
|
+
|
|
24
|
+
var _utilities = require("../../utilities");
|
|
25
|
+
|
|
15
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
27
|
+
|
|
16
28
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
29
|
+
|
|
17
30
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
31
|
+
|
|
18
32
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
33
|
+
|
|
19
34
|
const AnimatedText = _reactNative.Animated.createAnimatedComponent(_reactNative.Text);
|
|
35
|
+
|
|
20
36
|
const FOCUS_ANIMATION_DURATION = 150;
|
|
21
37
|
const BLUR_ANIMATION_DURATION = 180;
|
|
22
38
|
const ICON_SIZE = 24;
|
|
23
39
|
const MONTHS = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
|
|
40
|
+
|
|
24
41
|
const DatePicker = _ref => {
|
|
25
42
|
let {
|
|
26
43
|
Icon,
|
|
@@ -42,7 +59,11 @@ const DatePicker = _ref => {
|
|
|
42
59
|
rightIconName,
|
|
43
60
|
leftIconMode = "inset",
|
|
44
61
|
label,
|
|
62
|
+
labelSize,
|
|
63
|
+
labelColor,
|
|
45
64
|
placeholder,
|
|
65
|
+
borderColor: inputBorderColor,
|
|
66
|
+
borderColorActive: inputBorderColorActive,
|
|
46
67
|
...props
|
|
47
68
|
} = _ref;
|
|
48
69
|
const [value, setValue] = React.useState(date || defaultValue);
|
|
@@ -59,50 +80,58 @@ const DatePicker = _ref => {
|
|
|
59
80
|
measured: false,
|
|
60
81
|
width: 0
|
|
61
82
|
});
|
|
83
|
+
const {
|
|
84
|
+
textStyles
|
|
85
|
+
} = (0, _utilities.extractStyles)(style);
|
|
86
|
+
|
|
62
87
|
const getValidDate = () => {
|
|
63
88
|
if (!value) {
|
|
64
89
|
return new Date();
|
|
65
90
|
}
|
|
91
|
+
|
|
66
92
|
return typeof (value === null || value === void 0 ? void 0 : value.getMonth) === "function" ? value : new Date();
|
|
67
93
|
};
|
|
94
|
+
|
|
68
95
|
const formatDate = () => {
|
|
69
96
|
if (!value) return "";
|
|
70
97
|
let newDate = getValidDate();
|
|
71
98
|
if (format) return (0, _dateformat.default)(newDate, format);
|
|
99
|
+
|
|
72
100
|
if (mode === "time") {
|
|
73
|
-
return
|
|
101
|
+
return "".concat(newDate.toLocaleTimeString());
|
|
74
102
|
}
|
|
103
|
+
|
|
75
104
|
if (mode === "datetime") {
|
|
76
|
-
return
|
|
105
|
+
return "".concat(newDate.toLocaleString());
|
|
77
106
|
}
|
|
78
|
-
|
|
107
|
+
|
|
108
|
+
return "".concat(MONTHS[newDate.getMonth()], " ").concat(newDate.getDate(), ", ").concat(newDate.getFullYear());
|
|
79
109
|
};
|
|
110
|
+
|
|
80
111
|
const toggleVisibility = async () => {
|
|
81
112
|
setPickerVisible(!pickerVisible);
|
|
82
113
|
focused ? _handleBlur() : _handleFocus();
|
|
83
114
|
};
|
|
84
|
-
const insets = (0, _reactNativeSafeAreaContext.useSafeAreaInsets)();
|
|
85
115
|
|
|
86
|
-
// const _restoreLabel = () =>
|
|
116
|
+
const insets = (0, _reactNativeSafeAreaContext.useSafeAreaInsets)(); // const _restoreLabel = () =>
|
|
87
117
|
// Animated.timing(labeled, {
|
|
88
118
|
// toValue: 1,
|
|
89
119
|
// duration: FOCUS_ANIMATION_DURATION,
|
|
90
120
|
// useNativeDriver: true,
|
|
91
121
|
// }).start();
|
|
92
|
-
|
|
93
122
|
// const _minmizeLabel = () =>
|
|
94
123
|
// Animated.timing(labeled, {
|
|
95
124
|
// toValue: 0,
|
|
96
125
|
// duration: BLUR_ANIMATION_DURATION,
|
|
97
126
|
// useNativeDriver: true,
|
|
98
127
|
// }).start();
|
|
99
|
-
|
|
100
128
|
// const _showPlaceholder = () =>
|
|
101
129
|
// setTimeout(() => setPlaceholder1(placeholder || ""), 50);
|
|
102
130
|
|
|
103
131
|
const _hidePlaceholder = () => {
|
|
104
132
|
setPlaceholder1("");
|
|
105
133
|
};
|
|
134
|
+
|
|
106
135
|
React.useEffect(() => {
|
|
107
136
|
setValue(date);
|
|
108
137
|
}, [date]);
|
|
@@ -125,34 +154,42 @@ const DatePicker = _ref => {
|
|
|
125
154
|
}, [value, focused, placeholder1, labeled]);
|
|
126
155
|
React.useEffect(() => {
|
|
127
156
|
const _showPlaceholder = () => setTimeout(() => setPlaceholder1(placeholder || ""), 50);
|
|
157
|
+
|
|
128
158
|
if (focused || !label) {
|
|
129
159
|
_showPlaceholder();
|
|
130
160
|
} else {
|
|
131
161
|
_hidePlaceholder();
|
|
132
162
|
}
|
|
163
|
+
|
|
133
164
|
return () => {
|
|
134
165
|
clearTimeout(_showPlaceholder());
|
|
135
166
|
};
|
|
136
167
|
}, [focused, label, placeholder]);
|
|
168
|
+
|
|
137
169
|
const _handleFocus = () => {
|
|
138
170
|
if (disabled) {
|
|
139
171
|
return;
|
|
140
172
|
}
|
|
173
|
+
|
|
141
174
|
setFocused(true);
|
|
142
175
|
};
|
|
176
|
+
|
|
143
177
|
const _handleBlur = () => {
|
|
144
178
|
if (disabled) {
|
|
145
179
|
return;
|
|
146
180
|
}
|
|
181
|
+
|
|
147
182
|
setFocused(false);
|
|
148
183
|
};
|
|
184
|
+
|
|
149
185
|
const MINIMIZED_LABEL_Y_OFFSET = -(typography.caption.lineHeight + 4);
|
|
150
186
|
const OUTLINE_MINIMIZED_LABEL_Y_OFFSET = -(16 * 0.5 + 4);
|
|
151
|
-
const MAXIMIZED_LABEL_FONT_SIZE = typography.subtitle1.fontSize;
|
|
152
|
-
const MINIMIZED_LABEL_FONT_SIZE = typography.caption.fontSize;
|
|
187
|
+
const MAXIMIZED_LABEL_FONT_SIZE = (textStyles === null || textStyles === void 0 ? void 0 : textStyles.fontSize) || typography.subtitle1.fontSize;
|
|
188
|
+
const MINIMIZED_LABEL_FONT_SIZE = labelSize ? labelSize : typography.caption.fontSize;
|
|
153
189
|
const hasActiveOutline = focused;
|
|
154
190
|
let inputTextColor, activeColor, underlineColor, borderColor, placeholderColor, containerStyle, backgroundColor, inputStyle;
|
|
155
191
|
inputTextColor = colors.strong;
|
|
192
|
+
|
|
156
193
|
if (disabled) {
|
|
157
194
|
activeColor = colors.light;
|
|
158
195
|
placeholderColor = colors.light;
|
|
@@ -160,11 +197,12 @@ const DatePicker = _ref => {
|
|
|
160
197
|
underlineColor = "transparent";
|
|
161
198
|
backgroundColor = colors.divider;
|
|
162
199
|
} else {
|
|
163
|
-
activeColor = colors.primary;
|
|
164
|
-
placeholderColor = borderColor = colors.light;
|
|
165
|
-
underlineColor = colors.light;
|
|
200
|
+
activeColor = inputBorderColorActive || colors.primary;
|
|
201
|
+
placeholderColor = borderColor = inputBorderColor || colors.light;
|
|
202
|
+
underlineColor = inputBorderColor || colors.light;
|
|
166
203
|
backgroundColor = colors.background;
|
|
167
204
|
}
|
|
205
|
+
|
|
168
206
|
const {
|
|
169
207
|
lineHeight,
|
|
170
208
|
...subtitle1
|
|
@@ -177,12 +215,14 @@ const DatePicker = _ref => {
|
|
|
177
215
|
...subtitle1,
|
|
178
216
|
height: lineHeight
|
|
179
217
|
};
|
|
218
|
+
|
|
180
219
|
if (type === "underline") {
|
|
181
220
|
containerStyle = {
|
|
182
221
|
borderTopLeftRadius: roundness,
|
|
183
222
|
borderTopRightRadius: roundness,
|
|
184
223
|
paddingBottom: 12,
|
|
185
|
-
marginTop: 16
|
|
224
|
+
marginTop: 16,
|
|
225
|
+
backgroundColor
|
|
186
226
|
};
|
|
187
227
|
} else {
|
|
188
228
|
containerStyle = {
|
|
@@ -196,15 +236,19 @@ const DatePicker = _ref => {
|
|
|
196
236
|
};
|
|
197
237
|
inputStyle.paddingHorizontal = 12;
|
|
198
238
|
}
|
|
239
|
+
|
|
199
240
|
if (leftIconName && leftIconMode === "outset") {
|
|
200
241
|
containerStyle.marginLeft = ICON_SIZE + 8;
|
|
201
242
|
}
|
|
243
|
+
|
|
202
244
|
let leftIconColor;
|
|
245
|
+
|
|
203
246
|
if (focused) {
|
|
204
247
|
leftIconColor = colors.primary;
|
|
205
248
|
} else {
|
|
206
249
|
leftIconColor = colors.light;
|
|
207
250
|
}
|
|
251
|
+
|
|
208
252
|
const leftIconProps = {
|
|
209
253
|
size: 24,
|
|
210
254
|
color: leftIconColor,
|
|
@@ -214,9 +258,9 @@ const DatePicker = _ref => {
|
|
|
214
258
|
position: "absolute",
|
|
215
259
|
marginTop: type === "solid" ? leftIconMode === "inset" ? MINIMIZED_LABEL_FONT_SIZE + 4 : 16 : leftIconMode === "outset" ? 16 : 0
|
|
216
260
|
};
|
|
217
|
-
const labelStyle = {
|
|
218
|
-
...typography.subtitle1,
|
|
261
|
+
const labelStyle = { ...typography.subtitle1,
|
|
219
262
|
top: type === "solid" ? 16 : 0,
|
|
263
|
+
fontFamily: textStyles === null || textStyles === void 0 ? void 0 : textStyles.fontFamily,
|
|
220
264
|
left: leftIconName && leftIconMode === "inset" ? ICON_SIZE + (type === "solid" ? 16 : 12) : 0,
|
|
221
265
|
transform: [{
|
|
222
266
|
// Move label to top
|
|
@@ -238,27 +282,23 @@ const DatePicker = _ref => {
|
|
|
238
282
|
})
|
|
239
283
|
}]
|
|
240
284
|
};
|
|
241
|
-
const inputStyles = [styles.input, inputStyle, type === "solid" ? {
|
|
285
|
+
const inputStyles = (0, _utilities.applyStyles)([styles.input, inputStyle, type === "solid" ? {
|
|
242
286
|
marginHorizontal: 12
|
|
243
|
-
} : {}];
|
|
244
|
-
|
|
245
|
-
// const render = (props) => <NativeTextInput {...props} />;
|
|
287
|
+
} : {}], textStyles); // const render = (props) => <NativeTextInput {...props} />;
|
|
246
288
|
|
|
247
289
|
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
248
|
-
style: [styles.container
|
|
290
|
+
style: [styles.container]
|
|
249
291
|
}, /*#__PURE__*/React.createElement(_Touchable.default, {
|
|
250
292
|
disabled: disabled,
|
|
251
293
|
onPress: toggleVisibility
|
|
252
294
|
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
253
295
|
pointerEvents: "none"
|
|
254
296
|
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
255
|
-
style: [styles.container
|
|
297
|
+
style: [styles.container]
|
|
256
298
|
}, leftIconName && leftIconMode === "outset" ? /*#__PURE__*/React.createElement(Icon, _extends({}, leftIconProps, {
|
|
257
299
|
style: leftIconStyle
|
|
258
300
|
})) : null, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
259
|
-
style: [containerStyle
|
|
260
|
-
height: style.height
|
|
261
|
-
} : {}]
|
|
301
|
+
style: [containerStyle]
|
|
262
302
|
}, type === "underline" ?
|
|
263
303
|
/*#__PURE__*/
|
|
264
304
|
// When type === 'flat', render an underline
|
|
@@ -277,8 +317,7 @@ const DatePicker = _ref => {
|
|
|
277
317
|
React.createElement(_reactNative.View, {
|
|
278
318
|
pointerEvents: "none",
|
|
279
319
|
style: [_reactNative.StyleSheet.absoluteFill, {
|
|
280
|
-
opacity:
|
|
281
|
-
// Hide the label in minimized state until we measure its width
|
|
320
|
+
opacity: // Hide the label in minimized state until we measure its width
|
|
282
321
|
date || focused ? labelLayout.measured ? 1 : 0 : 1
|
|
283
322
|
}]
|
|
284
323
|
}, /*#__PURE__*/React.createElement(AnimatedText, {
|
|
@@ -289,7 +328,7 @@ const DatePicker = _ref => {
|
|
|
289
328
|
style: [styles.placeholder, type === "solid" ? {
|
|
290
329
|
paddingHorizontal: 12
|
|
291
330
|
} : {}, labelStyle, {
|
|
292
|
-
color: colors.light,
|
|
331
|
+
color: labelColor || colors.light,
|
|
293
332
|
opacity: labeled.interpolate({
|
|
294
333
|
inputRange: [0, 1],
|
|
295
334
|
outputRange: [hasActiveOutline ? 1 : 0, 0]
|
|
@@ -300,13 +339,12 @@ const DatePicker = _ref => {
|
|
|
300
339
|
style: [styles.placeholder, type === "solid" ? {
|
|
301
340
|
paddingHorizontal: 12
|
|
302
341
|
} : {}, labelStyle, {
|
|
303
|
-
color:
|
|
342
|
+
color: labelColor || placeholder,
|
|
304
343
|
opacity: hasActiveOutline ? labeled : 1
|
|
305
344
|
}],
|
|
306
345
|
numberOfLines: 1
|
|
307
346
|
}, label)) : null, leftIconName && leftIconMode === "inset" ? /*#__PURE__*/React.createElement(Icon, _extends({}, leftIconProps, {
|
|
308
|
-
style: {
|
|
309
|
-
...leftIconStyle,
|
|
347
|
+
style: { ...leftIconStyle,
|
|
310
348
|
marginLeft: type === "solid" ? 16 : 0
|
|
311
349
|
}
|
|
312
350
|
})) : null, /*#__PURE__*/React.createElement(_reactNative.TextInput, _extends({
|
|
@@ -342,6 +380,7 @@ const DatePicker = _ref => {
|
|
|
342
380
|
}, /*#__PURE__*/React.createElement(_DatePickerComponent.default, {
|
|
343
381
|
value: getValidDate(),
|
|
344
382
|
mode: mode,
|
|
383
|
+
style: inputStyles,
|
|
345
384
|
isVisible: pickerVisible,
|
|
346
385
|
toggleVisibility: toggleVisibility,
|
|
347
386
|
onChange: (_event, data) => {
|
|
@@ -351,6 +390,7 @@ const DatePicker = _ref => {
|
|
|
351
390
|
}
|
|
352
391
|
})))));
|
|
353
392
|
};
|
|
393
|
+
|
|
354
394
|
const styles = _reactNative.StyleSheet.create({
|
|
355
395
|
container: {
|
|
356
396
|
alignSelf: "stretch"
|
|
@@ -390,5 +430,7 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
390
430
|
alignSelf: "flex-end"
|
|
391
431
|
}
|
|
392
432
|
});
|
|
433
|
+
|
|
393
434
|
var _default = (0, _theming.withTheme)(DatePicker);
|
|
435
|
+
|
|
394
436
|
exports.default = _default;
|
|
@@ -4,18 +4,27 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
8
10
|
var _dateFns = _interopRequireDefault(require("@date-io/date-fns"));
|
|
11
|
+
|
|
9
12
|
var _pickers = require("@material-ui/pickers");
|
|
13
|
+
|
|
10
14
|
var _styles = require("@material-ui/core/styles");
|
|
15
|
+
|
|
11
16
|
var _theming = require("../../theming");
|
|
17
|
+
|
|
12
18
|
var _DefaultTheme = _interopRequireDefault(require("../../styles/DefaultTheme"));
|
|
19
|
+
|
|
13
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
|
+
|
|
14
22
|
const DatePickerComponent = _ref => {
|
|
15
23
|
let {
|
|
16
24
|
value,
|
|
17
25
|
onChange,
|
|
18
26
|
mode,
|
|
27
|
+
style,
|
|
19
28
|
toggleVisibility,
|
|
20
29
|
isVisible,
|
|
21
30
|
theme
|
|
@@ -44,8 +53,12 @@ const DatePickerComponent = _ref => {
|
|
|
44
53
|
},
|
|
45
54
|
onClose: () => toggleVisibility(),
|
|
46
55
|
variant: "dialog",
|
|
56
|
+
inputVariant: "outlined",
|
|
57
|
+
style: style,
|
|
47
58
|
TextFieldComponent: () => null
|
|
48
59
|
})));
|
|
49
60
|
};
|
|
61
|
+
|
|
50
62
|
var _default = (0, _theming.withTheme)(DatePickerComponent);
|
|
63
|
+
|
|
51
64
|
exports.default = _default;
|
|
@@ -4,15 +4,22 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
+
|
|
7
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
8
10
|
var _reactNative = require("react-native");
|
|
11
|
+
|
|
9
12
|
var _datetimepicker = _interopRequireDefault(require("@react-native-community/datetimepicker"));
|
|
13
|
+
|
|
10
14
|
var _reactNativeModalDatetimePicker = _interopRequireDefault(require("react-native-modal-datetime-picker"));
|
|
15
|
+
|
|
11
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
|
+
|
|
12
18
|
const DatePickerComponent = _ref => {
|
|
13
19
|
let {
|
|
14
20
|
value,
|
|
15
21
|
onChange,
|
|
22
|
+
style,
|
|
16
23
|
mode,
|
|
17
24
|
toggleVisibility
|
|
18
25
|
} = _ref;
|
|
@@ -29,11 +36,13 @@ const DatePickerComponent = _ref => {
|
|
|
29
36
|
onChange(null, data);
|
|
30
37
|
}
|
|
31
38
|
}) : /*#__PURE__*/_react.default.createElement(_datetimepicker.default, {
|
|
39
|
+
style: style,
|
|
32
40
|
value: value,
|
|
33
41
|
mode: mode,
|
|
34
42
|
onChange: onChange,
|
|
35
43
|
display: "default"
|
|
36
44
|
});
|
|
37
45
|
};
|
|
46
|
+
|
|
38
47
|
var _default = DatePickerComponent;
|
|
39
48
|
exports.default = _default;
|