@axelor/aos-mobile-ui 9.1.10 → 9.2.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.
- package/lib/components/atoms/BorderBar/BorderBar.d.ts +9 -0
- package/lib/components/atoms/BorderBar/BorderBar.js +30 -0
- package/lib/components/atoms/BorderBar/BorderBar.js.map +1 -0
- package/lib/components/atoms/Card/Card.d.ts +2 -1
- package/lib/components/atoms/Card/Card.js +2 -2
- package/lib/components/atoms/Card/Card.js.map +1 -1
- package/lib/components/atoms/HorizontalRule/HorizontalRule.d.ts +3 -1
- package/lib/components/atoms/HorizontalRule/HorizontalRule.js +5 -7
- package/lib/components/atoms/HorizontalRule/HorizontalRule.js.map +1 -1
- package/lib/components/atoms/HtmlInput/HtmlInput.d.ts +3 -1
- package/lib/components/atoms/HtmlInput/HtmlInput.js +13 -8
- package/lib/components/atoms/HtmlInput/HtmlInput.js.map +1 -1
- package/lib/components/atoms/HtmlViewer/HtmlViewer.d.ts +10 -0
- package/lib/components/atoms/HtmlViewer/HtmlViewer.js +93 -0
- package/lib/components/atoms/HtmlViewer/HtmlViewer.js.map +1 -0
- package/lib/components/atoms/Icon/Icon.d.ts +2 -1
- package/lib/components/atoms/Icon/Icon.js +4 -5
- package/lib/components/atoms/Icon/Icon.js.map +1 -1
- package/lib/components/atoms/Input/Input.d.ts +5 -5
- package/lib/components/atoms/Input/Input.js +6 -5
- package/lib/components/atoms/Input/Input.js.map +1 -1
- package/lib/components/atoms/ProgressCircle/ProgressCircle.js +11 -7
- package/lib/components/atoms/ProgressCircle/ProgressCircle.js.map +1 -1
- package/lib/components/atoms/RadioButton/RadioButton.js +25 -21
- package/lib/components/atoms/RadioButton/RadioButton.js.map +1 -1
- package/lib/components/atoms/Screen/Screen.d.ts +1 -2
- package/lib/components/atoms/Screen/Screen.js +2 -9
- package/lib/components/atoms/Screen/Screen.js.map +1 -1
- package/lib/components/atoms/Switch/Switch.d.ts +1 -1
- package/lib/components/atoms/Switch/Switch.js +5 -5
- package/lib/components/atoms/Switch/Switch.js.map +1 -1
- package/lib/components/atoms/Text/Text.d.ts +2 -1
- package/lib/components/atoms/Text/Text.js +1 -1
- package/lib/components/atoms/Text/Text.js.map +1 -1
- package/lib/components/atoms/VerticalRule/VerticalRule.d.ts +8 -0
- package/lib/components/atoms/VerticalRule/VerticalRule.js +33 -0
- package/lib/components/atoms/VerticalRule/VerticalRule.js.map +1 -0
- package/lib/components/atoms/index.d.ts +3 -0
- package/lib/components/atoms/index.js +3 -0
- package/lib/components/atoms/index.js.map +1 -1
- package/lib/components/molecules/Alert/Alert.js +18 -30
- package/lib/components/molecules/Alert/Alert.js.map +1 -1
- package/lib/components/molecules/Badge/Badge.d.ts +2 -1
- package/lib/components/molecules/Badge/Badge.js +15 -12
- package/lib/components/molecules/Badge/Badge.js.map +1 -1
- package/lib/components/molecules/BottomSheet/BottomSheet.js +1 -1
- package/lib/components/molecules/BottomSheet/BottomSheet.js.map +1 -1
- package/lib/components/molecules/Breadcrumb/Breadcrumb.js +1 -1
- package/lib/components/molecules/Button/Button.d.ts +2 -1
- package/lib/components/molecules/Button/Button.js +6 -12
- package/lib/components/molecules/Button/Button.js.map +1 -1
- package/lib/components/molecules/CalendarLegend/CalendarLegend.d.ts +13 -0
- package/lib/components/molecules/CalendarLegend/CalendarLegend.js +89 -0
- package/lib/components/molecules/CalendarLegend/CalendarLegend.js.map +1 -0
- package/lib/components/molecules/CalendarLegend/index.d.ts +2 -0
- package/lib/components/molecules/CalendarLegend/index.js +19 -0
- package/lib/components/molecules/CalendarLegend/index.js.map +1 -0
- package/lib/components/molecules/CalendarLegend/types.d.ts +6 -0
- package/lib/components/molecules/CalendarLegend/types.js +19 -0
- package/lib/components/molecules/CalendarLegend/types.js.map +1 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarMonthGrid.d.ts +15 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarMonthGrid.js +49 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarMonthGrid.js.map +1 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarMonthTitle.d.ts +8 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarMonthTitle.js +35 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarMonthTitle.js.map +1 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarWeekDays.d.ts +7 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarWeekDays.js +44 -0
- package/lib/components/molecules/CalendarMonthGrid/CalendarWeekDays.js.map +1 -0
- package/lib/components/molecules/CalendarMonthGrid/index.d.ts +3 -0
- package/lib/components/molecules/CalendarMonthGrid/index.js +21 -0
- package/lib/components/molecules/CalendarMonthGrid/index.js.map +1 -0
- package/lib/components/molecules/CardIconButton/CardIconButton.js +1 -1
- package/lib/components/molecules/Checkbox/Checkbox.d.ts +1 -1
- package/lib/components/molecules/Checkbox/Checkbox.js +11 -27
- package/lib/components/molecules/Checkbox/Checkbox.js.map +1 -1
- package/lib/components/molecules/Chip/Chip.d.ts +1 -1
- package/lib/components/molecules/Chip/Chip.js +23 -19
- package/lib/components/molecules/Chip/Chip.js.map +1 -1
- package/lib/components/molecules/CircleButton/CircleButton.js +1 -1
- package/lib/components/molecules/CircleButton/CircleButton.js.map +1 -1
- package/lib/components/molecules/ClearableCard/ClearableCard.js +2 -7
- package/lib/components/molecules/ClearableCard/ClearableCard.js.map +1 -1
- package/lib/components/molecules/DoubleIcon/DoubleIcon.js +1 -1
- package/lib/components/molecules/DoubleIcon/DoubleIcon.js.map +1 -1
- package/lib/components/molecules/DropdownCard/DropdownCard.d.ts +4 -3
- package/lib/components/molecules/DropdownCard/DropdownCard.js +36 -55
- package/lib/components/molecules/DropdownCard/DropdownCard.js.map +1 -1
- package/lib/components/molecules/DropdownMenu/DropdownMenu.d.ts +4 -2
- package/lib/components/molecules/DropdownMenu/DropdownMenu.js +52 -26
- package/lib/components/molecules/DropdownMenu/DropdownMenu.js.map +1 -1
- package/lib/components/molecules/EditableHtmlInput/EditableHtmlInput.js +2 -3
- package/lib/components/molecules/EditableHtmlInput/EditableHtmlInput.js.map +1 -1
- package/lib/components/molecules/EditableInput/EditableInput.js +4 -17
- package/lib/components/molecules/EditableInput/EditableInput.js.map +1 -1
- package/lib/components/molecules/FormHtmlInput/FormHtmlInput.d.ts +2 -2
- package/lib/components/molecules/FormHtmlInput/FormHtmlInput.js +13 -23
- package/lib/components/molecules/FormHtmlInput/FormHtmlInput.js.map +1 -1
- package/lib/components/molecules/FormIncrementInput/FormIncrementInput.js +6 -17
- package/lib/components/molecules/FormIncrementInput/FormIncrementInput.js.map +1 -1
- package/lib/components/molecules/FormInput/FormInput.d.ts +1 -1
- package/lib/components/molecules/FormInput/FormInput.js +2 -9
- package/lib/components/molecules/FormInput/FormInput.js.map +1 -1
- package/lib/components/molecules/FormSlider/FormSlider.js +3 -13
- package/lib/components/molecules/FormSlider/FormSlider.js.map +1 -1
- package/lib/components/molecules/GroupedCard/GroupedCard.d.ts +13 -0
- package/lib/components/molecules/GroupedCard/GroupedCard.js +60 -0
- package/lib/components/molecules/GroupedCard/GroupedCard.js.map +1 -0
- package/lib/components/molecules/HorizontalRuleText/HorizontalRuleText.js +5 -6
- package/lib/components/molecules/HorizontalRuleText/HorizontalRuleText.js.map +1 -1
- package/lib/components/molecules/IconInput/IconInput.d.ts +4 -4
- package/lib/components/molecules/IconInput/IconInput.js +15 -23
- package/lib/components/molecules/IconInput/IconInput.js.map +1 -1
- package/lib/components/molecules/IconTile/IconTile.d.ts +19 -0
- package/lib/components/molecules/IconTile/IconTile.js +43 -0
- package/lib/components/molecules/IconTile/IconTile.js.map +1 -0
- package/lib/components/molecules/Increment/Increment.d.ts +1 -1
- package/lib/components/molecules/Increment/Increment.js +3 -5
- package/lib/components/molecules/Increment/Increment.js.map +1 -1
- package/lib/components/molecules/Increment/IncrementButton.js +7 -14
- package/lib/components/molecules/Increment/IncrementButton.js.map +1 -1
- package/lib/components/molecules/Label/Label.d.ts +1 -1
- package/lib/components/molecules/Label/Label.js +11 -15
- package/lib/components/molecules/Label/Label.js.map +1 -1
- package/lib/components/molecules/LabelText/LabelText.js +6 -4
- package/lib/components/molecules/LabelText/LabelText.js.map +1 -1
- package/lib/components/molecules/MovementIndicationCard/MovementIndicationCard.d.ts +6 -7
- package/lib/components/molecules/MovementIndicationCard/MovementIndicationCard.js +91 -33
- package/lib/components/molecules/MovementIndicationCard/MovementIndicationCard.js.map +1 -1
- package/lib/components/molecules/MultiValuePickerButton/MultiValuePickerButton.js +21 -33
- package/lib/components/molecules/MultiValuePickerButton/MultiValuePickerButton.js.map +1 -1
- package/lib/components/molecules/NotesCard/NotesCard.d.ts +2 -1
- package/lib/components/molecules/NotesCard/NotesCard.js +11 -15
- package/lib/components/molecules/NotesCard/NotesCard.js.map +1 -1
- package/lib/components/molecules/NumberBubble/NumberBubble.js +2 -2
- package/lib/components/molecules/NumberBubble/NumberBubble.js.map +1 -1
- package/lib/components/molecules/NumberChevronInput/NumberChevronInput.d.ts +5 -3
- package/lib/components/molecules/NumberChevronInput/NumberChevronInput.js +35 -28
- package/lib/components/molecules/NumberChevronInput/NumberChevronInput.js.map +1 -1
- package/lib/components/molecules/PanelTabs/PanelTabs.js +1 -1
- package/lib/components/molecules/PeriodNavigation/PeriodNavigation.d.ts +14 -0
- package/lib/components/molecules/PeriodNavigation/PeriodNavigation.js +45 -0
- package/lib/components/molecules/PeriodNavigation/PeriodNavigation.js.map +1 -0
- package/lib/components/molecules/RadioSelect/RadioSelect.js +8 -8
- package/lib/components/molecules/RadioSelect/RadioSelect.js.map +1 -1
- package/lib/components/molecules/RightIconButton/RightIconButton.d.ts +4 -1
- package/lib/components/molecules/RightIconButton/RightIconButton.js +8 -7
- package/lib/components/molecules/RightIconButton/RightIconButton.js.map +1 -1
- package/lib/components/molecules/SelectionContainer/SelectionContainer.d.ts +2 -1
- package/lib/components/molecules/SelectionContainer/SelectionContainer.js +46 -58
- package/lib/components/molecules/SelectionContainer/SelectionContainer.js.map +1 -1
- package/lib/components/molecules/StarScore/StarScore.d.ts +1 -1
- package/lib/components/molecules/StarScore/StarScore.js +7 -10
- package/lib/components/molecules/StarScore/StarScore.js.map +1 -1
- package/lib/components/molecules/Stepper/StepList.d.ts +2 -1
- package/lib/components/molecules/Stepper/StepList.js +14 -12
- package/lib/components/molecules/Stepper/StepList.js.map +1 -1
- package/lib/components/molecules/Stepper/Stepper.d.ts +1 -2
- package/lib/components/molecules/Stepper/Stepper.js +17 -28
- package/lib/components/molecules/Stepper/Stepper.js.map +1 -1
- package/lib/components/molecules/SwitchCard/SwitchCard.d.ts +6 -2
- package/lib/components/molecules/SwitchCard/SwitchCard.js +6 -13
- package/lib/components/molecules/SwitchCard/SwitchCard.js.map +1 -1
- package/lib/components/molecules/TextUnit/TextUnit.js +3 -3
- package/lib/components/molecules/TextUnit/TextUnit.js.map +1 -1
- package/lib/components/molecules/ToggleSwitch/ToggleSwitch.js +34 -34
- package/lib/components/molecules/ToggleSwitch/ToggleSwitch.js.map +1 -1
- package/lib/components/molecules/ViewAllContainer/ViewAllContainer.d.ts +2 -1
- package/lib/components/molecules/ViewAllContainer/ViewAllContainer.js +24 -33
- package/lib/components/molecules/ViewAllContainer/ViewAllContainer.js.map +1 -1
- package/lib/components/molecules/index.d.ts +5 -0
- package/lib/components/molecules/index.js +5 -0
- package/lib/components/molecules/index.js.map +1 -1
- package/lib/components/organisms/ActionCard/ActionCard.js +4 -5
- package/lib/components/organisms/ActionCard/ActionCard.js.map +1 -1
- package/lib/components/organisms/ActionSheet/ActionSheet.d.ts +2 -1
- package/lib/components/organisms/ActionSheet/ActionSheet.js +18 -8
- package/lib/components/organisms/ActionSheet/ActionSheet.js.map +1 -1
- package/lib/components/organisms/AgendaView/AgendaDayCell.d.ts +13 -0
- package/lib/components/organisms/AgendaView/AgendaDayCell.js +71 -0
- package/lib/components/organisms/AgendaView/AgendaDayCell.js.map +1 -0
- package/lib/components/organisms/AgendaView/AgendaDayRow.d.ts +14 -0
- package/lib/components/organisms/AgendaView/AgendaDayRow.js +65 -0
- package/lib/components/organisms/AgendaView/AgendaDayRow.js.map +1 -0
- package/lib/components/organisms/AgendaView/AgendaHeader.d.ts +12 -0
- package/lib/components/organisms/AgendaView/AgendaHeader.js +44 -0
- package/lib/components/organisms/AgendaView/AgendaHeader.js.map +1 -0
- package/lib/components/organisms/AgendaView/AgendaItemRow.d.ts +8 -0
- package/lib/components/organisms/AgendaView/AgendaItemRow.js +58 -0
- package/lib/components/organisms/AgendaView/AgendaItemRow.js.map +1 -0
- package/lib/components/organisms/AgendaView/AgendaMonth.d.ts +16 -0
- package/lib/components/organisms/AgendaView/AgendaMonth.js +26 -0
- package/lib/components/organisms/AgendaView/AgendaMonth.js.map +1 -0
- package/lib/components/organisms/AgendaView/AgendaMonthSeparator.d.ts +7 -0
- package/lib/components/organisms/AgendaView/AgendaMonthSeparator.js +41 -0
- package/lib/components/organisms/AgendaView/AgendaMonthSeparator.js.map +1 -0
- package/lib/components/organisms/AgendaView/AgendaView.d.ts +24 -0
- package/lib/components/organisms/AgendaView/AgendaView.js +134 -0
- package/lib/components/organisms/AgendaView/AgendaView.js.map +1 -0
- package/lib/components/organisms/AgendaView/MonthList.d.ts +16 -0
- package/lib/components/organisms/AgendaView/MonthList.js +64 -0
- package/lib/components/organisms/AgendaView/MonthList.js.map +1 -0
- package/lib/components/organisms/AgendaView/MonthPanel.d.ts +17 -0
- package/lib/components/organisms/AgendaView/MonthPanel.js +108 -0
- package/lib/components/organisms/AgendaView/MonthPanel.js.map +1 -0
- package/lib/components/organisms/AgendaView/agenda-view.helpers.d.ts +6 -0
- package/lib/components/organisms/AgendaView/agenda-view.helpers.js +53 -0
- package/lib/components/organisms/AgendaView/agenda-view.helpers.js.map +1 -0
- package/lib/components/organisms/AgendaView/index.d.ts +3 -0
- package/lib/components/organisms/AgendaView/index.js +20 -0
- package/lib/components/organisms/AgendaView/index.js.map +1 -0
- package/lib/components/organisms/AgendaView/types.d.ts +12 -0
- package/lib/components/organisms/AgendaView/types.js +19 -0
- package/lib/components/organisms/AgendaView/types.js.map +1 -0
- package/lib/components/organisms/AgendaView/use-month-panel-drag.d.ts +13 -0
- package/lib/components/organisms/AgendaView/use-month-panel-drag.js +77 -0
- package/lib/components/organisms/AgendaView/use-month-panel-drag.js.map +1 -0
- package/lib/components/organisms/AutoCompleteSearch/AutoCompleteSearch.js +5 -5
- package/lib/components/organisms/AutoCompleteSearch/AutoCompleteSearch.js.map +1 -1
- package/lib/components/organisms/AutoCompleteSearch/ItemCard.d.ts +2 -2
- package/lib/components/organisms/AutoCompleteSearch/ItemCard.js +13 -20
- package/lib/components/organisms/AutoCompleteSearch/ItemCard.js.map +1 -1
- package/lib/components/organisms/AutoCompleteSearch/SearchDetailsPopUp.js +8 -9
- package/lib/components/organisms/AutoCompleteSearch/SearchDetailsPopUp.js.map +1 -1
- package/lib/components/organisms/CalendarRangePicker/CalendarDaySheet.d.ts +12 -0
- package/lib/components/organisms/CalendarRangePicker/CalendarDaySheet.js +60 -0
- package/lib/components/organisms/CalendarRangePicker/CalendarDaySheet.js.map +1 -0
- package/lib/components/organisms/CalendarRangePicker/CalendarRangePicker.d.ts +28 -0
- package/lib/components/organisms/CalendarRangePicker/CalendarRangePicker.js +140 -0
- package/lib/components/organisms/CalendarRangePicker/CalendarRangePicker.js.map +1 -0
- package/lib/components/organisms/CalendarRangePicker/DayCell.d.ts +17 -0
- package/lib/components/organisms/CalendarRangePicker/DayCell.js +131 -0
- package/lib/components/organisms/CalendarRangePicker/DayCell.js.map +1 -0
- package/lib/components/organisms/CalendarRangePicker/RangeMonth.d.ts +18 -0
- package/lib/components/organisms/CalendarRangePicker/RangeMonth.js +35 -0
- package/lib/components/organisms/CalendarRangePicker/RangeMonth.js.map +1 -0
- package/lib/components/organisms/CalendarRangePicker/calendar-range.helpers.d.ts +12 -0
- package/lib/components/organisms/CalendarRangePicker/calendar-range.helpers.js +68 -0
- package/lib/components/organisms/CalendarRangePicker/calendar-range.helpers.js.map +1 -0
- package/lib/components/organisms/CalendarRangePicker/index.d.ts +2 -0
- package/lib/components/organisms/CalendarRangePicker/index.js +19 -0
- package/lib/components/organisms/CalendarRangePicker/index.js.map +1 -0
- package/lib/components/organisms/CalendarRangePicker/types.d.ts +11 -0
- package/lib/components/organisms/CalendarRangePicker/types.js +19 -0
- package/lib/components/organisms/CalendarRangePicker/types.js.map +1 -0
- package/lib/components/organisms/ChipSelect/ChipSelect.js +24 -21
- package/lib/components/organisms/ChipSelect/ChipSelect.js.map +1 -1
- package/lib/components/organisms/DropdownCardSwitch/DropdownCardSwitch.d.ts +2 -0
- package/lib/components/organisms/DropdownCardSwitch/DropdownCardSwitch.js +2 -2
- package/lib/components/organisms/DropdownCardSwitch/DropdownCardSwitch.js.map +1 -1
- package/lib/components/organisms/DropdownMenuItem/DropdownMenuItem.d.ts +3 -2
- package/lib/components/organisms/DropdownMenuItem/DropdownMenuItem.js +36 -34
- package/lib/components/organisms/DropdownMenuItem/DropdownMenuItem.js.map +1 -1
- package/lib/components/organisms/FloatingButton/FloatingActionButton.d.ts +2 -2
- package/lib/components/organisms/FloatingButton/FloatingActionButton.js +2 -1
- package/lib/components/organisms/FloatingButton/FloatingActionButton.js.map +1 -1
- package/lib/components/organisms/GanttView/GanttView.d.ts +36 -0
- package/lib/components/organisms/GanttView/GanttView.js +267 -0
- package/lib/components/organisms/GanttView/GanttView.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttBar.d.ts +12 -0
- package/lib/components/organisms/GanttView/body/GanttBar.js +52 -0
- package/lib/components/organisms/GanttView/body/GanttBar.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttCellStrip.d.ts +10 -0
- package/lib/components/organisms/GanttView/body/GanttCellStrip.js +55 -0
- package/lib/components/organisms/GanttView/body/GanttCellStrip.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttGridLines.d.ts +9 -0
- package/lib/components/organisms/GanttView/body/GanttGridLines.js +45 -0
- package/lib/components/organisms/GanttView/body/GanttGridLines.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttGroupHeader.d.ts +9 -0
- package/lib/components/organisms/GanttView/body/GanttGroupHeader.js +61 -0
- package/lib/components/organisms/GanttView/body/GanttGroupHeader.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttGroupLane.d.ts +10 -0
- package/lib/components/organisms/GanttView/body/GanttGroupLane.js +43 -0
- package/lib/components/organisms/GanttView/body/GanttGroupLane.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttRowLane.d.ts +13 -0
- package/lib/components/organisms/GanttView/body/GanttRowLane.js +53 -0
- package/lib/components/organisms/GanttView/body/GanttRowLane.js.map +1 -0
- package/lib/components/organisms/GanttView/body/GanttRowName.d.ts +9 -0
- package/lib/components/organisms/GanttView/body/GanttRowName.js +51 -0
- package/lib/components/organisms/GanttView/body/GanttRowName.js.map +1 -0
- package/lib/components/organisms/GanttView/body/index.d.ts +6 -0
- package/lib/components/organisms/GanttView/body/index.js +24 -0
- package/lib/components/organisms/GanttView/body/index.js.map +1 -0
- package/lib/components/organisms/GanttView/gantt-view.helpers.d.ts +19 -0
- package/lib/components/organisms/GanttView/gantt-view.helpers.js +219 -0
- package/lib/components/organisms/GanttView/gantt-view.helpers.js.map +1 -0
- package/lib/components/organisms/GanttView/gantt-view.styles.d.ts +124 -0
- package/lib/components/organisms/GanttView/gantt-view.styles.js +148 -0
- package/lib/components/organisms/GanttView/gantt-view.styles.js.map +1 -0
- package/lib/components/organisms/GanttView/header/GanttControls.d.ts +13 -0
- package/lib/components/organisms/GanttView/header/GanttControls.js +53 -0
- package/lib/components/organisms/GanttView/header/GanttControls.js.map +1 -0
- package/lib/components/organisms/GanttView/header/GanttHeader.d.ts +24 -0
- package/lib/components/organisms/GanttView/header/GanttHeader.js +75 -0
- package/lib/components/organisms/GanttView/header/GanttHeader.js.map +1 -0
- package/lib/components/organisms/GanttView/header/index.d.ts +1 -0
- package/lib/components/organisms/GanttView/header/index.js +19 -0
- package/lib/components/organisms/GanttView/header/index.js.map +1 -0
- package/lib/components/organisms/GanttView/index.d.ts +4 -0
- package/lib/components/organisms/GanttView/index.js +21 -0
- package/lib/components/organisms/GanttView/index.js.map +1 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleDayRow.d.ts +10 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleDayRow.js +67 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleDayRow.js.map +1 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleHeader.d.ts +15 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleHeader.js +46 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleHeader.js.map +1 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleSpanRow.d.ts +8 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleSpanRow.js +69 -0
- package/lib/components/organisms/GanttView/scale/GanttScaleSpanRow.js.map +1 -0
- package/lib/components/organisms/GanttView/scale/gantt-scale.helpers.d.ts +6 -0
- package/lib/components/organisms/GanttView/scale/gantt-scale.helpers.js +53 -0
- package/lib/components/organisms/GanttView/scale/gantt-scale.helpers.js.map +1 -0
- package/lib/components/organisms/GanttView/scale/index.d.ts +1 -0
- package/lib/components/organisms/GanttView/scale/index.js +19 -0
- package/lib/components/organisms/GanttView/scale/index.js.map +1 -0
- package/lib/components/organisms/GanttView/types.d.ts +87 -0
- package/lib/components/organisms/GanttView/types.js +19 -0
- package/lib/components/organisms/GanttView/types.js.map +1 -0
- package/lib/components/organisms/GanttView/use-default-zoom.d.ts +2 -0
- package/lib/components/organisms/GanttView/use-default-zoom.js +23 -0
- package/lib/components/organisms/GanttView/use-default-zoom.js.map +1 -0
- package/lib/components/organisms/GroupByScrollList/GroupByScrollList.js +6 -2
- package/lib/components/organisms/GroupByScrollList/GroupByScrollList.js.map +1 -1
- package/lib/components/organisms/HeaderContainer/HeaderContainer.js +21 -17
- package/lib/components/organisms/HeaderContainer/HeaderContainer.js.map +1 -1
- package/lib/components/organisms/ImageBubble/ImageBubble.d.ts +1 -1
- package/lib/components/organisms/ImageBubble/ImageBubble.js +4 -7
- package/lib/components/organisms/ImageBubble/ImageBubble.js.map +1 -1
- package/lib/components/organisms/InfoBubble/InfoBubble.js +1 -1
- package/lib/components/organisms/InfoBubble/InfoBubble.js.map +1 -1
- package/lib/components/organisms/InfoButton/InfoButton.d.ts +1 -1
- package/lib/components/organisms/MultiValuePicker/MultiValuePicker.js +6 -10
- package/lib/components/organisms/MultiValuePicker/MultiValuePicker.js.map +1 -1
- package/lib/components/organisms/Picker/Picker.d.ts +2 -1
- package/lib/components/organisms/Picker/Picker.js +25 -29
- package/lib/components/organisms/Picker/Picker.js.map +1 -1
- package/lib/components/organisms/ProgressBar/ProgressBar.d.ts +1 -1
- package/lib/components/organisms/ProgressBar/ProgressBar.js +11 -16
- package/lib/components/organisms/ProgressBar/ProgressBar.js.map +1 -1
- package/lib/components/organisms/QuantityCard/QuantityCard.d.ts +3 -2
- package/lib/components/organisms/QuantityCard/QuantityCard.js +47 -56
- package/lib/components/organisms/QuantityCard/QuantityCard.js.map +1 -1
- package/lib/components/organisms/ScrollList/DottedButton.js +10 -18
- package/lib/components/organisms/ScrollList/DottedButton.js.map +1 -1
- package/lib/components/organisms/ScrollList/ScrollList.js +9 -7
- package/lib/components/organisms/ScrollList/ScrollList.js.map +1 -1
- package/lib/components/organisms/ScrollList/TopActions.js +5 -3
- package/lib/components/organisms/ScrollList/TopActions.js.map +1 -1
- package/lib/components/organisms/SearchBar/SearchBar.d.ts +3 -3
- package/lib/components/organisms/SearchBar/SearchBar.js +15 -32
- package/lib/components/organisms/SearchBar/SearchBar.js.map +1 -1
- package/lib/components/organisms/SingleSelectScrollList/SingleSelectScrollList.js +1 -1
- package/lib/components/organisms/ToggleButton/ToggleButton.js +2 -2
- package/lib/components/organisms/ToggleButton/ToggleButton.js.map +1 -1
- package/lib/components/organisms/ViewAllEditList/AllLinesAlert.js +14 -16
- package/lib/components/organisms/ViewAllEditList/AllLinesAlert.js.map +1 -1
- package/lib/components/organisms/ViewAllEditList/LineComponent.js +6 -8
- package/lib/components/organisms/ViewAllEditList/LineComponent.js.map +1 -1
- package/lib/components/organisms/ViewAllEditList/ViewAllEditList.d.ts +3 -2
- package/lib/components/organisms/ViewAllEditList/ViewAllEditList.js +5 -9
- package/lib/components/organisms/ViewAllEditList/ViewAllEditList.js.map +1 -1
- package/lib/components/organisms/WeekDayPicker/DayGauge.d.ts +18 -0
- package/lib/components/organisms/WeekDayPicker/DayGauge.js +112 -0
- package/lib/components/organisms/WeekDayPicker/DayGauge.js.map +1 -0
- package/lib/components/organisms/WeekDayPicker/WeekDayPicker.d.ts +18 -0
- package/lib/components/organisms/WeekDayPicker/WeekDayPicker.js +118 -0
- package/lib/components/organisms/WeekDayPicker/WeekDayPicker.js.map +1 -0
- package/lib/components/organisms/WeekDayPicker/WeekRow.d.ts +15 -0
- package/lib/components/organisms/WeekDayPicker/WeekRow.js +39 -0
- package/lib/components/organisms/WeekDayPicker/WeekRow.js.map +1 -0
- package/lib/components/organisms/WeekDayPicker/index.d.ts +3 -0
- package/lib/components/organisms/WeekDayPicker/index.js +20 -0
- package/lib/components/organisms/WeekDayPicker/index.js.map +1 -0
- package/lib/components/organisms/WeekDayPicker/types.d.ts +17 -0
- package/lib/components/organisms/WeekDayPicker/types.js +19 -0
- package/lib/components/organisms/WeekDayPicker/types.js.map +1 -0
- package/lib/components/organisms/WeekDayPicker/week-day.helpers.d.ts +9 -0
- package/lib/components/organisms/WeekDayPicker/week-day.helpers.js +83 -0
- package/lib/components/organisms/WeekDayPicker/week-day.helpers.js.map +1 -0
- package/lib/components/organisms/index.d.ts +4 -0
- package/lib/components/organisms/index.js +4 -0
- package/lib/components/organisms/index.js.map +1 -1
- package/lib/components/templates/BottomBar/BottomBar.js +81 -22
- package/lib/components/templates/BottomBar/BottomBar.js.map +1 -1
- package/lib/components/templates/BottomBar/ItemTitle.d.ts +1 -1
- package/lib/components/templates/BottomBar/ItemTitle.js +1 -2
- package/lib/components/templates/BottomBar/ItemTitle.js.map +1 -1
- package/lib/components/templates/Dashboard/Chart/BarChart.js +3 -3
- package/lib/components/templates/Dashboard/Chart/BarChart.js.map +1 -1
- package/lib/components/templates/Dashboard/Chart/IndicatorChart/IndicatorItem.js +1 -1
- package/lib/components/templates/Dashboard/Chart/IndicatorChart/IndicatorItem.js.map +1 -1
- package/lib/components/templates/Dashboard/Chart/IndicatorChart/SimpleIndicator.js +24 -20
- package/lib/components/templates/Dashboard/Chart/IndicatorChart/SimpleIndicator.js.map +1 -1
- package/lib/components/templates/ObjectCard/ObjectCard.d.ts +3 -2
- package/lib/components/templates/ObjectCard/ObjectCard.js +46 -32
- package/lib/components/templates/ObjectCard/ObjectCard.js.map +1 -1
- package/lib/components/templates/TabsScreen/Tab.js +1 -1
- package/lib/components/templates/TabsScreen/Tab.js.map +1 -1
- package/lib/hooks/index.d.ts +1 -0
- package/lib/hooks/index.js +1 -0
- package/lib/hooks/index.js.map +1 -1
- package/lib/hooks/use-click-outside.js +2 -2
- package/lib/hooks/use-click-outside.js.map +1 -1
- package/lib/hooks/use-orientation.d.ts +1 -0
- package/lib/hooks/use-orientation.js +23 -0
- package/lib/hooks/use-orientation.js.map +1 -0
- package/lib/theme/color/ThemeContext.js +1 -1
- package/lib/theme/color/ThemeContext.js.map +1 -1
- package/lib/theme/color/color.defaults.js +22 -22
- package/lib/theme/color/content.helpers.d.ts +2 -1
- package/lib/theme/color/content.helpers.js +47 -45
- package/lib/theme/color/content.helpers.js.map +1 -1
- package/lib/theme/color/themes.js +83 -80
- package/lib/theme/color/themes.js.map +1 -1
- package/lib/theme/color/types.d.ts +1 -0
- package/lib/theme/writing/writingTheme.js +5 -5
- package/lib/tools/AnimationUtil.d.ts +18 -3
- package/lib/utils/calendar.d.ts +42 -0
- package/lib/utils/calendar.js +64 -0
- package/lib/utils/calendar.js.map +1 -0
- package/lib/utils/commons-styles.d.ts +8 -20
- package/lib/utils/commons-styles.js +14 -22
- package/lib/utils/commons-styles.js.map +1 -1
- package/lib/utils/commons-utlis.d.ts +1 -0
- package/lib/utils/commons-utlis.js +7 -0
- package/lib/utils/commons-utlis.js.map +1 -1
- package/lib/utils/dates.d.ts +30 -0
- package/lib/utils/dates.js +142 -0
- package/lib/utils/dates.js.map +1 -0
- package/lib/utils/index.d.ts +10 -8
- package/lib/utils/index.js +4 -2
- package/lib/utils/index.js.map +1 -1
- package/package.json +14 -14
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClearableCard.js","sourceRoot":"","sources":["../../../../src/components/molecules/ClearableCard/ClearableCard.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,OAAO,EAAC,MAAM,OAAO,CAAC;AACrC,OAAO,EAAC,UAAU,EAAE,UAAU,EAAC,MAAM,cAAc,CAAC;AACpD,OAAO,EAAC,eAAe,EAAC,MAAM
|
|
1
|
+
{"version":3,"file":"ClearableCard.js","sourceRoot":"","sources":["../../../../src/components/molecules/ClearableCard/ClearableCard.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,OAAO,EAAC,MAAM,OAAO,CAAC;AACrC,OAAO,EAAC,UAAU,EAAE,UAAU,EAAC,MAAM,cAAc,CAAC;AACpD,OAAO,EAAC,eAAe,EAAC,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAC,aAAa,EAAC,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAC,MAAM,aAAa,CAAC;AAS7C,MAAM,aAAa,GAAG,CAAC,EACrB,KAAK,EACL,QAAQ,EACR,YAAY,EACZ,SAAS,GAAG,IAAI,GACE,EAAE,EAAE;IACtB,MAAM,MAAM,GAAG,aAAa,EAAE,CAAC;IAE/B,MAAM,YAAY,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC,eAAe,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;IAEtE,OAAO,CACL,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,YAAY,CAAC,MAAM,EAAE,YAAY,CAAC,WAAW,EAAE,KAAK,CAAC,CAAC,CAClE;MAAA,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,IAAI,CAC1C;MAAA,CAAC,SAAS,IAAI,CACZ,CAAC,IAAI,CACH,IAAI,CAAC,MAAM,CACX,SAAS,CAAC,CAAC,IAAI,CAAC,CAChB,OAAO,CAAC,CAAC,YAAY,CAAC,CACtB,IAAI,CAAC,CAAC,UAAU,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC,KAAK,GAAG,IAAI,CAAC,EAC5C,CACH,CACH;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,IAAI,EAAE;QACJ,KAAK,EAAE,KAAK;QACZ,MAAM,EAAE,CAAC;KACV;CACF,CAAC,CAAC;AAEH,eAAe,aAAa,CAAC"}
|
|
@@ -30,7 +30,7 @@ const predefinedPositions = {
|
|
|
30
30
|
};
|
|
31
31
|
const DoubleIcon = ({ style, topIconConfig, bottomIconConfig, size = 18, predefinedPosition, topIconPosition = {}, touchable, onPress, }) => {
|
|
32
32
|
const topIconStyle = useMemo(() => predefinedPositions[predefinedPosition], [predefinedPosition]);
|
|
33
|
-
return (<TouchableOpacity testID="doubleIconTouchable" style={[styles.container, style]} onPress={onPress} disabled={!touchable}>
|
|
33
|
+
return (<TouchableOpacity testID="doubleIconTouchable" style={[styles.container, style]} onPress={onPress} activeOpacity={0.9} disabled={!touchable}>
|
|
34
34
|
<Icon {...bottomIconConfig} size={bottomIconConfig?.size != null ? bottomIconConfig?.size : size}/>
|
|
35
35
|
<View testID="topIconContainer" style={[styles.topIcon, topIconStyle, topIconPosition]}>
|
|
36
36
|
<Icon {...topIconConfig} size={topIconConfig?.size != null ? topIconConfig?.size : size * 0.6}/>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DoubleIcon.js","sourceRoot":"","sources":["../../../../src/components/molecules/DoubleIcon/DoubleIcon.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,OAAO,EAAC,MAAM,OAAO,CAAC;AACrC,OAAO,EAAC,UAAU,EAAE,gBAAgB,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAChE,OAAO,EAAC,IAAI,EAAC,MAAM,aAAa,CAAC;AAEjC,MAAM,mBAAmB,GAAG;IAC1B,IAAI,EAAE,EAAC,IAAI,EAAE,CAAC,EAAE,EAAC;IACjB,GAAG,EAAE,EAAC,GAAG,EAAE,CAAC,EAAE,EAAC;IACf,KAAK,EAAE,EAAC,KAAK,EAAE,CAAC,EAAE,EAAC;IACnB,MAAM,EAAE,EAAC,MAAM,EAAE,CAAC,EAAE,EAAC;IACrB,cAAc,EAAE,EAAC,MAAM,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,EAAC;IACzC,aAAa,EAAE,EAAC,MAAM,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,EAAC;IACtC,UAAU,EAAE,EAAC,GAAG,EAAE,CAAC,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,EAAC;IACjC,WAAW,EAAE,EAAC,GAAG,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,EAAC;CACpC,CAAC;AAwBF,MAAM,UAAU,GAAG,CAAC,EAClB,KAAK,EACL,aAAa,EACb,gBAAgB,EAChB,IAAI,GAAG,EAAE,EACT,kBAAkB,EAClB,eAAe,GAAG,EAAE,EACpB,SAAS,EACT,OAAO,GACS,EAAE,EAAE;IACpB,MAAM,YAAY,GAAG,OAAO,CAC1B,GAAG,EAAE,CAAC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ACjB,aAAa,CAAC,CAAC,GAAG,CAAC,CACnB,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC,CACrB;MAAA,CAAC,IAAI,CACH,IAAI,gBAAgB,CAAC,CACrB,IAAI,CAAC,CAAC,gBAAgB,EAAE,IAAI,IAAI,IAAI,CAAC,CAAC,CAAC,gBAAgB,EAAE,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,EAEvE;MAAA,CAAC,IAAI,CACH,MAAM,CAAC,kBAAkB,CACzB,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,EAAE,YAAY,EAAE,eAAe,CAAC,CAAC,CACvD;QAAA,CAAC,IAAI,CACH,IAAI,aAAa,CAAC,CAClB,IAAI,CAAC,CAAC,aAAa,EAAE,IAAI,IAAI,IAAI,CAAC,CAAC,CAAC,aAAa,EAAE,IAAI,CAAC,CAAC,CAAC,IAAI,GAAG,GAAG,CAAC,EAEzE;MAAA,EAAE,IAAI,CACR;IAAA,EAAE,gBAAgB,CAAC,CACpB,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,SAAS,EAAE;QACT,cAAc,EAAE,QAAQ;QACxB,UAAU,EAAE,QAAQ;QACpB,QAAQ,EAAE,UAAU;KACrB;IACD,OAAO,EAAE;QACP,QAAQ,EAAE,UAAU;KACrB;CACF,CAAC,CAAC;AAEH,eAAe,UAAU,CAAC"}
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { Color } from '../../../theme';
|
|
2
3
|
interface DropdownCardProps {
|
|
3
4
|
style?: any;
|
|
4
5
|
styleText?: any;
|
|
5
|
-
|
|
6
|
-
styleCard?: any;
|
|
6
|
+
styleHeader?: any;
|
|
7
7
|
title: string;
|
|
8
8
|
children: any;
|
|
9
9
|
dropdownIsOpen?: boolean;
|
|
10
10
|
onPress?: () => void;
|
|
11
11
|
showIcon?: boolean;
|
|
12
12
|
iconName?: string;
|
|
13
|
+
iconColor?: Color;
|
|
13
14
|
}
|
|
14
|
-
declare const DropdownCard: ({ style, styleText,
|
|
15
|
+
declare const DropdownCard: ({ style, styleText, styleHeader, title, dropdownIsOpen, children, onPress, showIcon, iconName, iconColor, }: DropdownCardProps) => React.JSX.Element;
|
|
15
16
|
export default DropdownCard;
|
|
@@ -17,77 +17,58 @@
|
|
|
17
17
|
*/
|
|
18
18
|
import React, { useMemo, useState } from 'react';
|
|
19
19
|
import { StyleSheet, TouchableOpacity, View } from 'react-native';
|
|
20
|
-
import { animationUtil } from '../../../tools/AnimationUtil';
|
|
21
20
|
import { useThemeColor } from '../../../theme';
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
|
|
25
|
-
|
|
21
|
+
import { animationUtil } from '../../../tools';
|
|
22
|
+
import { Card, HorizontalRule, Icon, Text } from '../../atoms';
|
|
23
|
+
import { IconTile } from '../../molecules';
|
|
24
|
+
const DropdownCard = ({ style, styleText, styleHeader, title, dropdownIsOpen = false, children, onPress, showIcon = true, iconName, iconColor, }) => {
|
|
26
25
|
const Colors = useThemeColor();
|
|
27
|
-
const
|
|
28
|
-
const
|
|
29
|
-
const displayCard = useMemo(() => {
|
|
30
|
-
return onPress ? dropdownIsOpen : isOpen;
|
|
31
|
-
}, [dropdownIsOpen, isOpen, onPress]);
|
|
26
|
+
const [isOpen, setIsOpen] = useState(dropdownIsOpen);
|
|
27
|
+
const displayContent = useMemo(() => (onPress ? dropdownIsOpen : isOpen), [dropdownIsOpen, isOpen, onPress]);
|
|
32
28
|
const handleCardPress = () => {
|
|
33
29
|
animationUtil.animateNext();
|
|
34
30
|
onPress ? onPress() : setIsOpen(!isOpen);
|
|
35
31
|
};
|
|
36
|
-
return (<
|
|
37
|
-
<TouchableOpacity style={styles.
|
|
38
|
-
<
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
]}>
|
|
44
|
-
<View style={styles.row}>
|
|
45
|
-
{iconName && <Icon name={iconName} style={styles.iconLeft}/>}
|
|
46
|
-
<Text style={styleText} numberOfLines={1}>
|
|
47
|
-
{title}
|
|
48
|
-
</Text>
|
|
49
|
-
</View>
|
|
50
|
-
{showIcon && (<Icon name={displayCard ? 'chevron-up' : 'chevron-down'} color={Colors.primaryColor.background}/>)}
|
|
51
|
-
</View>
|
|
32
|
+
return (<Card style={[styles.card, style]} testID="dropdownCardContainer">
|
|
33
|
+
<TouchableOpacity style={[styles.titleRow, styleHeader]} onPress={handleCardPress} disabled={!showIcon} activeOpacity={0.9} testID="dropdownCardTouchable">
|
|
34
|
+
{iconName && (<IconTile icon={iconName} color={iconColor ?? Colors.primaryColor}/>)}
|
|
35
|
+
<Text style={[styles.title, styleText]} writingType="important" numberOfLines={1}>
|
|
36
|
+
{title}
|
|
37
|
+
</Text>
|
|
38
|
+
{showIcon && (<Icon name={displayContent ? 'chevron-up' : 'chevron-down'} color={Colors.primaryColor.background}/>)}
|
|
52
39
|
</TouchableOpacity>
|
|
53
|
-
{
|
|
54
|
-
|
|
40
|
+
{displayContent && (<View testID="cardContainer" style={styles.childrenContainer}>
|
|
41
|
+
<HorizontalRule style={styles.separator} color={Colors.secondaryColor.background_light}/>
|
|
42
|
+
{children}
|
|
43
|
+
</View>)}
|
|
44
|
+
</Card>);
|
|
55
45
|
};
|
|
56
|
-
const
|
|
57
|
-
|
|
46
|
+
const styles = StyleSheet.create({
|
|
47
|
+
card: {
|
|
58
48
|
flexDirection: 'column',
|
|
59
49
|
justifyContent: 'center',
|
|
60
50
|
alignItems: 'center',
|
|
61
51
|
width: '90%',
|
|
52
|
+
marginVertical: 4,
|
|
53
|
+
paddingHorizontal: 16,
|
|
54
|
+
paddingRight: 16,
|
|
55
|
+
paddingVertical: 12,
|
|
62
56
|
},
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
content: {
|
|
68
|
-
borderColor: Colors.secondaryColor.background,
|
|
69
|
-
borderWidth: 1,
|
|
70
|
-
marginHorizontal: 0,
|
|
71
|
-
height: 40,
|
|
57
|
+
titleRow: {
|
|
58
|
+
flexDirection: 'row',
|
|
59
|
+
alignItems: 'center',
|
|
60
|
+
gap: 10,
|
|
72
61
|
},
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
width: '98%',
|
|
76
|
-
paddingTop: 25,
|
|
77
|
-
paddingLeft: 10,
|
|
78
|
-
paddingRight: 10,
|
|
79
|
-
paddingBottom: 10,
|
|
80
|
-
marginTop: -20,
|
|
81
|
-
borderRadius: 7,
|
|
82
|
-
borderTopLeftRadius: 0,
|
|
83
|
-
borderTopRightRadius: 0,
|
|
84
|
-
zIndex: 30,
|
|
62
|
+
title: {
|
|
63
|
+
flex: 1,
|
|
85
64
|
},
|
|
86
|
-
|
|
87
|
-
|
|
65
|
+
childrenContainer: {
|
|
66
|
+
width: '100%',
|
|
88
67
|
},
|
|
89
|
-
|
|
90
|
-
|
|
68
|
+
separator: {
|
|
69
|
+
marginVertical: 10,
|
|
70
|
+
width: '90%',
|
|
71
|
+
alignSelf: 'center',
|
|
91
72
|
},
|
|
92
73
|
});
|
|
93
74
|
export default DropdownCard;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropdownCard.js","sourceRoot":"","sources":["../../../../src/components/molecules/DropdownCard/DropdownCard.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC/C,OAAO,EAAC,UAAU,EAAE,gBAAgB,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAChE,OAAO,
|
|
1
|
+
{"version":3,"file":"DropdownCard.js","sourceRoot":"","sources":["../../../../src/components/molecules/DropdownCard/DropdownCard.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAA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AE,QAAQ;QACpB,KAAK,EAAE,KAAK;QACZ,cAAc,EAAE,CAAC;QACjB,iBAAiB,EAAE,EAAE;QACrB,YAAY,EAAE,EAAE;QAChB,eAAe,EAAE,EAAE;KACpB;IACD,QAAQ,EAAE;QACR,aAAa,EAAE,KAAK;QACpB,UAAU,EAAE,QAAQ;QACpB,GAAG,EAAE,EAAE;KACR;IACD,KAAK,EAAE;QACL,IAAI,EAAE,CAAC;KACR;IACD,iBAAiB,EAAE;QACjB,KAAK,EAAE,MAAM;KACd;IACD,SAAS,EAAE;QACT,cAAc,EAAE,EAAE;QAClB,KAAK,EAAE,KAAK;QACZ,SAAS,EAAE,QAAQ;KACpB;CACF,CAAC,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import React, { ReactElement } from 'react';
|
|
2
2
|
interface DropdownMenuProps {
|
|
3
3
|
style?: any;
|
|
4
4
|
styleMenu?: any;
|
|
5
|
+
iconSize?: number;
|
|
6
|
+
iconWrapper?: (icon: ReactElement) => ReactElement;
|
|
5
7
|
children: any;
|
|
6
8
|
}
|
|
7
|
-
declare const DropdownMenu: ({ style, styleMenu, children }: DropdownMenuProps) => React.JSX.Element;
|
|
9
|
+
declare const DropdownMenu: ({ style, styleMenu, iconSize, iconWrapper, children, }: DropdownMenuProps) => React.JSX.Element;
|
|
8
10
|
export default DropdownMenu;
|
|
@@ -15,46 +15,72 @@
|
|
|
15
15
|
* You should have received a copy of the GNU Affero General Public License
|
|
16
16
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
17
17
|
*/
|
|
18
|
-
import React, { useMemo, useRef, useState } from 'react';
|
|
19
|
-
import { StyleSheet, TouchableOpacity, View } from 'react-native';
|
|
20
|
-
import { useOutsideClickHandler } from '../../../hooks';
|
|
18
|
+
import React, { useCallback, useMemo, useRef, useState, } from 'react';
|
|
19
|
+
import { Modal, Pressable, StyleSheet, TouchableOpacity, View, } from 'react-native';
|
|
21
20
|
import { useThemeColor } from '../../../theme';
|
|
22
21
|
import { Card, Icon } from '../../atoms';
|
|
23
|
-
const DropdownMenu = ({ style, styleMenu, children }) => {
|
|
24
|
-
const [visible, setVisible] = useState(false);
|
|
22
|
+
const DropdownMenu = ({ style, styleMenu, iconSize = 18, iconWrapper, children, }) => {
|
|
25
23
|
const Colors = useThemeColor();
|
|
24
|
+
const [visible, setVisible] = useState(false);
|
|
25
|
+
const [anchor, setAnchor] = useState(null);
|
|
26
26
|
const wrapperRef = useRef(null);
|
|
27
|
-
const
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
27
|
+
const closeMenu = useCallback(() => {
|
|
28
|
+
setVisible(false);
|
|
29
|
+
setAnchor(null);
|
|
30
|
+
}, []);
|
|
31
|
+
const openMenu = useCallback(() => {
|
|
32
|
+
wrapperRef.current?.measureInWindow?.((left, top, width, height) => setAnchor({ left, top, width, height }));
|
|
33
|
+
setVisible(true);
|
|
34
|
+
}, []);
|
|
35
|
+
const menuItems = useMemo(() => React.Children.map(children, child => {
|
|
36
|
+
if (!React.isValidElement(child))
|
|
37
|
+
return child;
|
|
38
|
+
const onPress = child.props?.onPress;
|
|
39
|
+
if (typeof onPress !== 'function')
|
|
40
|
+
return child;
|
|
41
|
+
return React.cloneElement(child, {
|
|
42
|
+
onPress: () => {
|
|
43
|
+
closeMenu();
|
|
44
|
+
requestAnimationFrame(onPress);
|
|
45
|
+
},
|
|
46
|
+
});
|
|
47
|
+
}), [children, closeMenu]);
|
|
34
48
|
return (<View style={style} ref={wrapperRef} testID="dropdownMenuContainer">
|
|
35
|
-
<TouchableOpacity
|
|
36
|
-
<Icon name="three-dots-vertical" color={Colors.primaryColor.background} size={
|
|
49
|
+
<TouchableOpacity onPress={visible ? closeMenu : openMenu} testID="dropdownMenuTouchable" activeOpacity={0.9}>
|
|
50
|
+
{iconWrapper != null ? (iconWrapper(<Icon name="three-dots-vertical" color={Colors.primaryColor.background} size={iconSize}/>)) : (<Icon name="three-dots-vertical" color={Colors.primaryColor.background} size={iconSize}/>)}
|
|
37
51
|
</TouchableOpacity>
|
|
38
|
-
{visible
|
|
39
|
-
|
|
40
|
-
|
|
52
|
+
<Modal visible={visible} transparent={true} animationType="none" onRequestClose={closeMenu}>
|
|
53
|
+
<Pressable style={styles.backdrop} onPress={closeMenu} testID="dropdownMenuBackdrop"/>
|
|
54
|
+
<View pointerEvents="box-none" style={[
|
|
55
|
+
styles.anchor,
|
|
56
|
+
anchor,
|
|
57
|
+
anchor == null && styles.notPositioned,
|
|
58
|
+
]}>
|
|
59
|
+
<Card style={[styles.menuContainer, styleMenu]}>{menuItems}</Card>
|
|
60
|
+
</View>
|
|
61
|
+
</Modal>
|
|
41
62
|
</View>);
|
|
42
63
|
};
|
|
43
|
-
const
|
|
64
|
+
const styles = StyleSheet.create({
|
|
65
|
+
backdrop: {
|
|
66
|
+
...StyleSheet.absoluteFill,
|
|
67
|
+
},
|
|
68
|
+
anchor: {
|
|
69
|
+
position: 'absolute',
|
|
70
|
+
},
|
|
71
|
+
notPositioned: {
|
|
72
|
+
opacity: 0,
|
|
73
|
+
},
|
|
44
74
|
menuContainer: {
|
|
45
75
|
width: 255,
|
|
46
|
-
top:
|
|
47
|
-
right:
|
|
48
|
-
borderRadius:
|
|
76
|
+
top: 45,
|
|
77
|
+
right: 0,
|
|
78
|
+
borderRadius: 12,
|
|
49
79
|
paddingHorizontal: 10,
|
|
80
|
+
paddingRight: 10,
|
|
50
81
|
paddingVertical: 5,
|
|
51
82
|
position: 'absolute',
|
|
52
|
-
elevation: 6,
|
|
53
|
-
shadowOpacity: 0.5,
|
|
54
|
-
shadowColor: Colors.secondaryColor.background,
|
|
55
|
-
shadowOffset: { width: 0, height: 0 },
|
|
56
83
|
},
|
|
57
|
-
action: { padding: 5, paddingLeft: 15 },
|
|
58
84
|
});
|
|
59
85
|
export default DropdownMenu;
|
|
60
86
|
//# sourceMappingURL=DropdownMenu.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropdownMenu.js","sourceRoot":"","sources":["../../../../src/components/molecules/DropdownMenu/DropdownMenu.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"DropdownMenu.js","sourceRoot":"","sources":["../../../../src/components/molecules/DropdownMenu/DropdownMenu.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAEZ,WAAW,EACX,OAAO,EACP,MAAM,EACN,QAAQ,GACT,MAAM,OAAO,CAAC;AACf,OAAO,EACL,KAAK,EACL,SAAS,EACT,UAAU,EACV,gBAAgB,EAChB,IAAI,GAEL,MAAM,cAAc,CAAC;AACtB,OAAO,EAAC,aAAa,EAAC,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAC,IAAI,EAAE,IAAI,EAAC,MAAM,aAAa,CAAC;AAiBvC,MAAM,YAAY,GAAG,CAAC,EACpB,KAAK,EACL,SAAS,EACT,QAAQ,GAAG,EAAE,EACb,WAAW,EACX,QAAQ,GACU,EAAE,EAAE;IACtB,MAAM,MAAM,GAAG,aAAa,EAAE,CAAC;IAE/B,MAAM,CAAC,OAAO,EAAE,UAAU,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAC9C,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,QAAQ,CAAgB,IAAI,CAAC,CAAC;IAE1D,MAAM,UAAU,GAAG,MAAM,CAAe,IAAI,CAAC,CAAC;IAE9C,MAAM,SAAS,GAAG,WAAW,CAAC,GAAG,EAAE;QACjC,UAAU,CAAC,KAAK,CAAC,CAAC;QAClB,SAAS,CAAC,IAAI,CAAC,CAAC;IAClB,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,MAAM,QAAQ,GAAG,WAAW,CAAC,GAAG,EAAE;QAChC,UAA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AG;QACV,GAAG,EAAE,EAAE;QACP,KAAK,EAAE,CAAC;QACR,YAAY,EAAE,EAAE;QAChB,iBAAiB,EAAE,EAAE;QACrB,YAAY,EAAE,EAAE;QAChB,eAAe,EAAE,CAAC;QAClB,QAAQ,EAAE,UAAU;KACrB;CACF,CAAC,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -41,7 +41,7 @@ const EditableHtmlInput = ({ style, title, placeholder, defaultValue, readonly =
|
|
|
41
41
|
{!checkNullString(title) && <Text style={styles.title}>{title}</Text>}
|
|
42
42
|
<View style={[commonStyles.filter, commonStyles.filterAlign, styles.content]}>
|
|
43
43
|
<HtmlInput style={styles.htmlInput} styleToolbar={styles.htmlToolBar} placeholder={placeholder} defaultInput={value} readonly={readonly || isEditable} onChange={setValue}/>
|
|
44
|
-
{!readonly && (<Icon name={isEditable ? 'pencil-fill' : 'check-lg'} size={
|
|
44
|
+
{!readonly && (<Icon name={isEditable ? 'pencil-fill' : 'check-lg'} size={14} touchable onPress={handleIconPress}/>)}
|
|
45
45
|
</View>
|
|
46
46
|
</View>);
|
|
47
47
|
};
|
|
@@ -59,11 +59,10 @@ const styles = StyleSheet.create({
|
|
|
59
59
|
minHeight: 40,
|
|
60
60
|
},
|
|
61
61
|
htmlInput: {
|
|
62
|
-
fontSize: 14,
|
|
63
62
|
flex: 1,
|
|
64
63
|
},
|
|
65
64
|
htmlToolBar: {
|
|
66
|
-
backgroundColor:
|
|
65
|
+
backgroundColor: undefined,
|
|
67
66
|
marginLeft: -5,
|
|
68
67
|
},
|
|
69
68
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EditableHtmlInput.js","sourceRoot":"","sources":["../../../../src/components/molecules/EditableHtmlInput/EditableHtmlInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC1D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AE,EAAE;KACf;IACD,OAAO,EAAE;QACP,KAAK,EAAE,MAAM;QACb,gBAAgB,EAAE,CAAC;QACnB,SAAS,EAAE,EAAE;KACd;IACD,SAAS,EAAE;QACT,IAAI,EAAE,CAAC;KACR;IACD,WAAW,EAAE;QACX,eAAe,EAAE,SAAS;QAC1B,UAAU,EAAE,CAAC,CAAC;KACf;CACF,CAAC,CAAC;AAEH,eAAe,iBAAiB,CAAC"}
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
17
17
|
*/
|
|
18
18
|
import React, { useEffect, useMemo, useState } from 'react';
|
|
19
|
-
import { StyleSheet,
|
|
20
|
-
import { getCommonStyles } from '../../../utils
|
|
19
|
+
import { StyleSheet, View } from 'react-native';
|
|
20
|
+
import { getCommonStyles } from '../../../utils';
|
|
21
21
|
import { useThemeColor } from '../../../theme';
|
|
22
22
|
import { Icon, Input } from '../../atoms';
|
|
23
23
|
const EditableInput = ({ placeholder, onValidate, defaultValue, multiline = false, numberOfLines = 1, }) => {
|
|
@@ -37,28 +37,15 @@ const EditableInput = ({ placeholder, onValidate, defaultValue, multiline = fals
|
|
|
37
37
|
return (<View style={[
|
|
38
38
|
commonStyles.filter,
|
|
39
39
|
commonStyles.filterAlign,
|
|
40
|
-
commonStyles.filterSize,
|
|
41
40
|
multiline && { height: undefined },
|
|
42
41
|
]}>
|
|
43
42
|
<Input style={styles.input} placeholder={placeholder} value={value} onChange={text => setValue(text)} readOnly={isEditable} multiline={multiline} numberOfLines={numberOfLines} testID="editableInput"/>
|
|
44
|
-
<
|
|
45
|
-
<TouchableOpacity testID="editableInputToggle" onPress={handleIcon}>
|
|
46
|
-
<Icon name={isEditable ? 'pencil-fill' : 'check-lg'} size={15}/>
|
|
47
|
-
</TouchableOpacity>
|
|
48
|
-
</View>
|
|
43
|
+
<Icon name={isEditable ? 'pencil-fill' : 'check-lg'} touchable onPress={handleIcon}/>
|
|
49
44
|
</View>);
|
|
50
45
|
};
|
|
51
46
|
const styles = StyleSheet.create({
|
|
52
47
|
input: {
|
|
53
|
-
|
|
54
|
-
fontSize: 14,
|
|
55
|
-
},
|
|
56
|
-
actions: {
|
|
57
|
-
width: '20%',
|
|
58
|
-
display: 'flex',
|
|
59
|
-
flexDirection: 'row',
|
|
60
|
-
justifyContent: 'flex-end',
|
|
61
|
-
alignItems: 'flex-start',
|
|
48
|
+
flex: 1,
|
|
62
49
|
},
|
|
63
50
|
});
|
|
64
51
|
export default EditableInput;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EditableInput.js","sourceRoot":"","sources":["../../../../src/components/molecules/EditableInput/EditableInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC1D,OAAO,EAAC,UAAU,EAAE,
|
|
1
|
+
{"version":3,"file":"EditableInput.js","sourceRoot":"","sources":["../../../../src/components/molecules/EditableInput/EditableInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC1D,OAAO,EAAC,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAC,eAAe,EAAC,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAC,aAAa,EAAC,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAC,IAAI,EAAE,KAAK,EAAC,MAAM,aAAa,CAAC;AAUxC,MAAM,aAAa,GAAG,CAAC,EACrB,WAAW,EACX,UAAU,EACV,YAAY,EACZ,SAAS,GAAG,KAAK,EACjB,aAAa,GAAG,CAAC,GACE,EAAE,EAAE;IACvB,MAAM,MAAM,GAAG,aAAa,EAAE,CAAC;IAE/B,MAAM,CAAC,UAAU,EA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9C,SAAS,CACT,OAAO,CAAC,CAAC,UAAU,CAAC,EAExB;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,KAAK,EAAE;QACL,IAAI,EAAE,CAAC;KACR;CACF,CAAC,CAAC;AAEH,eAAe,aAAa,CAAC"}
|
|
@@ -7,7 +7,7 @@ interface FormHtmlInputProps {
|
|
|
7
7
|
hideIfNull?: boolean;
|
|
8
8
|
style?: any;
|
|
9
9
|
required?: boolean;
|
|
10
|
-
onChange?: (
|
|
10
|
+
onChange?: (_v?: string) => void;
|
|
11
11
|
}
|
|
12
|
-
declare const FormHtmlInput: ({ title, placeholder, defaultValue, readonly, hideIfNull,
|
|
12
|
+
declare const FormHtmlInput: ({ style, title, placeholder, defaultValue, readonly, hideIfNull, required, onChange, }: FormHtmlInputProps) => React.JSX.Element;
|
|
13
13
|
export default FormHtmlInput;
|
|
@@ -17,11 +17,10 @@
|
|
|
17
17
|
*/
|
|
18
18
|
import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
19
19
|
import { StyleSheet, View } from 'react-native';
|
|
20
|
-
import { HtmlInput, Text } from '../../atoms';
|
|
21
20
|
import { useThemeColor } from '../../../theme';
|
|
22
|
-
import { getCommonStyles } from '../../../utils
|
|
23
|
-
import {
|
|
24
|
-
const FormHtmlInput = ({ title, placeholder
|
|
21
|
+
import { checkNullString, getCommonStyles } from '../../../utils';
|
|
22
|
+
import { HtmlInput, Text } from '../../atoms';
|
|
23
|
+
const FormHtmlInput = ({ style, title, placeholder, defaultValue, readonly = false, hideIfNull = false, required = false, onChange, }) => {
|
|
25
24
|
const Colors = useThemeColor();
|
|
26
25
|
const [value, setValue] = useState(defaultValue);
|
|
27
26
|
const [isFocused, setIsFocused] = useState(false);
|
|
@@ -29,46 +28,37 @@ const FormHtmlInput = ({ title, placeholder = '', defaultValue = null, readonly
|
|
|
29
28
|
useEffect(() => {
|
|
30
29
|
setValue(defaultValue);
|
|
31
30
|
}, [defaultValue]);
|
|
32
|
-
const onValueChange = useCallback(_value => {
|
|
31
|
+
const onValueChange = useCallback((_value) => {
|
|
33
32
|
setValue(_value);
|
|
34
|
-
onChange(_value);
|
|
33
|
+
onChange?.(_value);
|
|
35
34
|
}, [onChange]);
|
|
36
|
-
const commonStyles = useMemo(() => getCommonStyles(Colors, _required), [Colors, _required]);
|
|
37
|
-
const
|
|
38
|
-
const handleFocus = () => {
|
|
35
|
+
const commonStyles = useMemo(() => getCommonStyles(Colors, _required, isFocused), [Colors, _required, isFocused]);
|
|
36
|
+
const handleFocus = useCallback(() => {
|
|
39
37
|
setIsFocused(true);
|
|
40
|
-
};
|
|
41
|
-
const handleBlur = () => {
|
|
38
|
+
}, []);
|
|
39
|
+
const handleBlur = useCallback(() => {
|
|
42
40
|
setIsFocused(false);
|
|
43
|
-
};
|
|
41
|
+
}, []);
|
|
44
42
|
if (hideIfNull && readonly && checkNullString(defaultValue)) {
|
|
45
43
|
return null;
|
|
46
44
|
}
|
|
47
45
|
return (<View style={[styles.container, style]} testID="formHtmlInputContainer">
|
|
48
46
|
<Text style={styles.title}>{title}</Text>
|
|
49
|
-
<View testID="formHtmlInputWrapper" style={[
|
|
50
|
-
commonStyles.filter,
|
|
51
|
-
styles.content,
|
|
52
|
-
isFocused && commonStyles.inputFocused,
|
|
53
|
-
]}>
|
|
47
|
+
<View testID="formHtmlInputWrapper" style={[commonStyles.filter, styles.content]}>
|
|
54
48
|
<HtmlInput defaultInput={value} onChange={onValueChange} placeholder={placeholder} readonly={readonly} style={styles.input} styleToolbar={styles.htmlToolBar} onFocus={handleFocus} onBlur={handleBlur}/>
|
|
55
49
|
</View>
|
|
56
50
|
</View>);
|
|
57
51
|
};
|
|
58
|
-
const
|
|
52
|
+
const styles = StyleSheet.create({
|
|
59
53
|
container: {
|
|
60
54
|
width: '90%',
|
|
61
55
|
alignSelf: 'center',
|
|
62
56
|
},
|
|
63
57
|
content: {
|
|
64
58
|
width: '100%',
|
|
65
|
-
borderColor: _required
|
|
66
|
-
? Colors.errorColor.background
|
|
67
|
-
: Colors.secondaryColor.background,
|
|
68
|
-
borderWidth: 1,
|
|
69
59
|
},
|
|
70
60
|
htmlToolBar: {
|
|
71
|
-
backgroundColor:
|
|
61
|
+
backgroundColor: undefined,
|
|
72
62
|
marginLeft: -5,
|
|
73
63
|
},
|
|
74
64
|
input: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormHtmlInput.js","sourceRoot":"","sources":["../../../../src/components/molecules/FormHtmlInput/FormHtmlInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AACvE,OAAO,EAAC,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAC,
|
|
1
|
+
{"version":3,"file":"FormHtmlInput.js","sourceRoot":"","sources":["../../../../src/components/molecules/FormHtmlInput/FormHtmlInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AACvE,OAAO,EAAC,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAC,aAAa,EAAC,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAC,eAAe,EAAE,eAAe,EAAC,MAAM,gBAAgB,CAAC;AAChE,OAAO,EAAC,SAAS,EAAE,IAAI,EAAC,MAAM,aAAa,CAAC;AAa5C,MAAM,aAAa,GAAG,CAAC,EACrB,KAAK,EACL,KAAK,EACL,WAAW,EACX,YAAY,EACZ,QAAQ,GAAG,KAAK,EAChB,UAAU,GAAG,KAAK,EAClB,QAAQ,GAAG,KAAK,E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emo, useState } from 'react';
|
|
19
19
|
import { StyleSheet, View } from 'react-native';
|
|
20
20
|
import { useThemeColor } from '../../../theme';
|
|
21
|
+
import { getCommonStyles } from '../../../utils';
|
|
21
22
|
import { Text } from '../../atoms';
|
|
22
23
|
import { Increment } from '../../molecules';
|
|
23
|
-
|
|
24
|
-
const FormIncrementInput = ({ style, title, readOnly = false, required = false, defaultValue = null, decimalSpacer, thousandSpacer, onChange, defaultFormatting = true, stepSize = 1, minValue = 0, maxValue = null, isBigButton = false, keyboardType, scale, }) => {
|
|
24
|
+
const FormIncrementInput = ({ style, title, readOnly = false, required = false, defaultValue, decimalSpacer, thousandSpacer, onChange, defaultFormatting = true, stepSize = 1, minValue = 0, maxValue, isBigButton = false, keyboardType, scale, }) => {
|
|
25
25
|
const Colors = useThemeColor();
|
|
26
26
|
const [isFocused, setIsFocused] = useState(false);
|
|
27
27
|
const _required = useMemo(() => required && defaultValue == null, [required, defaultValue]);
|
|
28
|
-
const commonStyles = useMemo(() => getCommonStyles(Colors, _required), [Colors, _required]);
|
|
29
|
-
const styles = useMemo(() => getStyles(Colors, _required), [Colors, _required]);
|
|
28
|
+
const commonStyles = useMemo(() => getCommonStyles(Colors, _required, isFocused), [Colors, _required, isFocused]);
|
|
30
29
|
const handleFocus = useCallback(() => setIsFocused(true), []);
|
|
31
30
|
const handleBlur = useCallback(() => setIsFocused(false), []);
|
|
32
31
|
return (<View testID="formIncrementContainer" style={[styles.container, style]}>
|
|
33
32
|
<Text style={styles.title}>{title}</Text>
|
|
34
|
-
<View testID="formIncrementInnerContainer" style={[
|
|
35
|
-
|
|
36
|
-
commonStyles.filterSize,
|
|
37
|
-
commonStyles.filterAlign,
|
|
38
|
-
styles.content,
|
|
39
|
-
isFocused && commonStyles.inputFocused,
|
|
40
|
-
]}>
|
|
41
|
-
<Increment value={defaultValue} onValueChange={onChange} style={styles.increment} inputStyle={styles.containerInput} decimalSpacer={decimalSpacer} thousandSpacer={thousandSpacer} onFocus={handleFocus} onBlur={handleBlur} readonly={readOnly} defaultFormatting={defaultFormatting} stepSize={stepSize} minValue={minValue} maxValue={maxValue} isBigButton={isBigButton} keyboardType={keyboardType} scale={scale}/>
|
|
33
|
+
<View testID="formIncrementInnerContainer" style={[commonStyles.filter, commonStyles.filterAlign, styles.content]}>
|
|
34
|
+
<Increment value={defaultValue} onValueChange={onChange} style={styles.increment} inputStyle={isBigButton && styles.containerInput} decimalSpacer={decimalSpacer} thousandSpacer={thousandSpacer} onFocus={handleFocus} onBlur={handleBlur} readonly={readOnly} defaultFormatting={defaultFormatting} stepSize={stepSize} minValue={minValue} maxValue={maxValue} isBigButton={isBigButton} keyboardType={keyboardType} scale={scale}/>
|
|
42
35
|
</View>
|
|
43
36
|
</View>);
|
|
44
37
|
};
|
|
45
|
-
const
|
|
38
|
+
const styles = StyleSheet.create({
|
|
46
39
|
container: {
|
|
47
40
|
width: '100%',
|
|
48
41
|
},
|
|
@@ -56,10 +49,6 @@ const getStyles = (Colors, required) => StyleSheet.create({
|
|
|
56
49
|
},
|
|
57
50
|
content: {
|
|
58
51
|
width: '100%',
|
|
59
|
-
borderColor: required
|
|
60
|
-
? Colors.errorColor.background
|
|
61
|
-
: Colors.secondaryColor.background,
|
|
62
|
-
borderWidth: 1,
|
|
63
52
|
marginHorizontal: 0,
|
|
64
53
|
paddingHorizontal: 5,
|
|
65
54
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormIncrementInput.js","sourceRoot":"","sources":["../../../../src/components/molecules/FormIncrementInput/FormIncrementInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC5D,OAAO,EAAsB,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AACnE,OAAO,EAAC,aAAa,
|
|
1
|
+
{"version":3,"file":"FormIncrementInput.js","sourceRoot":"","sources":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