jornada-ui 0.4.11 → 0.4.12
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/README.md +31 -31
- package/lib/commonjs/common/icons-svg/bluetooth/index.js +45 -27
- package/lib/commonjs/common/icons-svg/bluetooth/index.js.map +1 -1
- package/lib/commonjs/common/icons-svg/constants/index.js +7 -5
- package/lib/commonjs/common/icons-svg/constants/index.js.map +1 -1
- package/lib/commonjs/common/icons-svg/index.js +19 -4
- package/lib/commonjs/common/icons-svg/index.js.map +1 -1
- package/lib/commonjs/common/icons-svg/plus-container/index.js +42 -0
- package/lib/commonjs/common/icons-svg/plus-container/index.js.map +1 -0
- package/lib/commonjs/common/icons-svg/trash/index.js +41 -0
- package/lib/commonjs/common/icons-svg/trash/index.js.map +1 -0
- package/lib/commonjs/components/activity-step/components/activite-row/index.js +137 -0
- package/lib/commonjs/components/activity-step/components/activite-row/index.js.map +1 -0
- package/lib/commonjs/components/activity-step/index.js +77 -0
- package/lib/commonjs/components/activity-step/index.js.map +1 -0
- package/lib/commonjs/components/activity-step/interface.js +6 -0
- package/lib/commonjs/components/activity-step/interface.js.map +1 -0
- package/lib/commonjs/components/activity-step/styles.js +86 -0
- package/lib/commonjs/components/activity-step/styles.js.map +1 -0
- package/lib/commonjs/components/card-scheduled-journey/index.js +8 -6
- package/lib/commonjs/components/card-scheduled-journey/index.js.map +1 -1
- package/lib/commonjs/components/inputs/input-date-time/index.js +136 -0
- package/lib/commonjs/components/inputs/input-date-time/index.js.map +1 -0
- package/lib/commonjs/components/inputs/input-date-time/interface.d.js +2 -0
- package/lib/commonjs/components/inputs/input-date-time/interface.d.js.map +1 -0
- package/lib/commonjs/components/inputs/input-date-time/styles.js +66 -0
- package/lib/commonjs/components/inputs/input-date-time/styles.js.map +1 -0
- package/lib/commonjs/components/list-devices/helpers/get-icon-by-status.js +25 -0
- package/lib/commonjs/components/list-devices/helpers/get-icon-by-status.js.map +1 -0
- package/lib/commonjs/components/list-devices/index.js +97 -0
- package/lib/commonjs/components/list-devices/index.js.map +1 -0
- package/lib/commonjs/components/list-devices/interface.d.js +2 -0
- package/lib/commonjs/components/list-devices/interface.d.js.map +1 -0
- package/lib/commonjs/components/list-devices/styles.js +60 -0
- package/lib/commonjs/components/list-devices/styles.js.map +1 -0
- package/lib/commonjs/components/list-supplies/index.js +171 -0
- package/lib/commonjs/components/list-supplies/index.js.map +1 -0
- package/lib/commonjs/components/list-supplies/interface.d.js +2 -0
- package/lib/commonjs/components/list-supplies/interface.d.js.map +1 -0
- package/lib/commonjs/components/maintenance-description-input/index.js +3 -0
- package/lib/commonjs/components/maintenance-description-input/index.js.map +1 -1
- package/lib/commonjs/components/maintenance-description-input/styles.js +1 -1
- package/lib/commonjs/components/maintenance-description-input/styles.js.map +1 -1
- package/lib/commonjs/components/modals/modal-activity-reason/index.js +170 -0
- package/lib/commonjs/components/modals/modal-activity-reason/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-activity-reason/interface.d.js +2 -0
- package/lib/commonjs/components/modals/modal-activity-reason/interface.d.js.map +1 -0
- package/lib/commonjs/components/modals/modal-create-activitie/helpers/index.js +27 -0
- package/lib/commonjs/components/modals/modal-create-activitie/helpers/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-create-activitie/index.js +203 -0
- package/lib/commonjs/components/modals/modal-create-activitie/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-create-activitie/interface.js +2 -0
- package/lib/commonjs/components/modals/modal-create-activitie/interface.js.map +1 -0
- package/lib/commonjs/components/modals/modal-create-activitie/styles.js +42 -0
- package/lib/commonjs/components/modals/modal-create-activitie/styles.js.map +1 -0
- package/lib/commonjs/components/modals/modal-exclude-activitie/index.js +2 -0
- package/lib/commonjs/components/modals/modal-exclude-activitie/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-journey-rectification/index.js +242 -0
- package/lib/commonjs/components/modals/modal-journey-rectification/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-journey-rectification/interface.d.js +2 -0
- package/lib/commonjs/components/modals/modal-journey-rectification/interface.d.js.map +1 -0
- package/lib/commonjs/components/modals/modal-to-confimations/index.js +182 -0
- package/lib/commonjs/components/modals/modal-to-confimations/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-to-confimations/interface.js +2 -0
- package/lib/commonjs/components/modals/modal-to-confimations/interface.js.map +1 -0
- package/lib/commonjs/components/selects/select-date-and-hours/index.js +80 -0
- package/lib/commonjs/components/selects/select-date-and-hours/index.js.map +1 -0
- package/lib/commonjs/components/selects/select-date-and-hours/interface.js +6 -0
- package/lib/commonjs/components/selects/select-date-and-hours/interface.js.map +1 -0
- package/lib/commonjs/components/selects/select-date-and-hours/styles.js +34 -0
- package/lib/commonjs/components/selects/select-date-and-hours/styles.js.map +1 -0
- package/lib/commonjs/components/selects/select-option/index.js +4 -2
- package/lib/commonjs/components/selects/select-option/index.js.map +1 -1
- package/lib/commonjs/components/selects/select-option/styles.js +6 -7
- package/lib/commonjs/components/selects/select-option/styles.js.map +1 -1
- package/lib/commonjs/components/supply-error-card/index.js +6 -6
- package/lib/commonjs/components/toast-message/index.js +8 -7
- package/lib/commonjs/components/toast-message/index.js.map +1 -1
- package/lib/commonjs/components/travel-history/index.js +7 -7
- package/lib/commonjs/components/travel-history/index.js.map +1 -1
- package/lib/commonjs/components/trip-details-card/index.js +94 -13
- package/lib/commonjs/components/trip-details-card/index.js.map +1 -1
- package/lib/commonjs/components/typography/index.js +5 -5
- package/lib/commonjs/components/typography/index.js.map +1 -1
- package/lib/commonjs/index.js +53 -4
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/stories/list-devices/list-devices.stories.js +146 -0
- package/lib/commonjs/stories/list-devices/list-devices.stories.js.map +1 -0
- package/lib/commonjs/stories/list-supplies/list-supplies.stories.js +69 -0
- package/lib/commonjs/stories/list-supplies/list-supplies.stories.js.map +1 -0
- package/lib/commonjs/stories/modal-activity-reason/modal-activity-reason.stories.js +63 -0
- package/lib/commonjs/stories/modal-activity-reason/modal-activity-reason.stories.js.map +1 -0
- package/lib/commonjs/stories/modal-journey-rectification/modal-journey-rectification.stories.js +63 -0
- package/lib/commonjs/stories/modal-journey-rectification/modal-journey-rectification.stories.js.map +1 -0
- package/lib/commonjs/stories/supply-error-card/supply-error-card.stories.js +2 -2
- package/lib/commonjs/stories/trip-details-card/trip-details-card.stories.js +39 -6
- package/lib/commonjs/stories/trip-details-card/trip-details-card.stories.js.map +1 -1
- package/lib/commonjs/styles/theme/theme.js +1 -0
- package/lib/commonjs/styles/theme/theme.js.map +1 -1
- package/lib/module/common/icons-svg/bluetooth/index.js +45 -27
- package/lib/module/common/icons-svg/bluetooth/index.js.map +1 -1
- package/lib/module/common/icons-svg/constants/index.js +7 -5
- package/lib/module/common/icons-svg/constants/index.js.map +1 -1
- package/lib/module/common/icons-svg/index.js +19 -4
- package/lib/module/common/icons-svg/index.js.map +1 -1
- package/lib/module/common/icons-svg/plus-container/index.js +36 -0
- package/lib/module/common/icons-svg/plus-container/index.js.map +1 -0
- package/lib/module/common/icons-svg/trash/index.js +34 -0
- package/lib/module/common/icons-svg/trash/index.js.map +1 -0
- package/lib/module/components/activity-step/components/activite-row/index.js +134 -0
- package/lib/module/components/activity-step/components/activite-row/index.js.map +1 -0
- package/lib/module/components/activity-step/index.js +73 -0
- package/lib/module/components/activity-step/index.js.map +1 -0
- package/lib/module/components/activity-step/interface.js +4 -0
- package/lib/module/components/activity-step/interface.js.map +1 -0
- package/lib/module/components/activity-step/styles.js +83 -0
- package/lib/module/components/activity-step/styles.js.map +1 -0
- package/lib/module/components/card-scheduled-journey/index.js +8 -6
- package/lib/module/components/card-scheduled-journey/index.js.map +1 -1
- package/lib/module/components/inputs/input-date-time/index.js +130 -0
- package/lib/module/components/inputs/input-date-time/index.js.map +1 -0
- package/lib/module/components/inputs/input-date-time/interface.d.js +2 -0
- package/lib/module/components/inputs/input-date-time/interface.d.js.map +1 -0
- package/lib/module/components/inputs/input-date-time/styles.js +62 -0
- package/lib/module/components/inputs/input-date-time/styles.js.map +1 -0
- package/lib/module/components/list-devices/helpers/get-icon-by-status.js +21 -0
- package/lib/module/components/list-devices/helpers/get-icon-by-status.js.map +1 -0
- package/lib/module/components/list-devices/index.js +93 -0
- package/lib/module/components/list-devices/index.js.map +1 -0
- package/lib/module/components/list-devices/interface.d.js +2 -0
- package/lib/module/components/list-devices/interface.d.js.map +1 -0
- package/lib/module/components/list-devices/styles.js +56 -0
- package/lib/module/components/list-devices/styles.js.map +1 -0
- package/lib/module/components/list-supplies/index.js +165 -0
- package/lib/module/components/list-supplies/index.js.map +1 -0
- package/lib/module/components/list-supplies/interface.d.js +2 -0
- package/lib/module/components/list-supplies/interface.d.js.map +1 -0
- package/lib/module/components/maintenance-description-input/index.js +3 -0
- package/lib/module/components/maintenance-description-input/index.js.map +1 -1
- package/lib/module/components/maintenance-description-input/styles.js +1 -1
- package/lib/module/components/maintenance-description-input/styles.js.map +1 -1
- package/lib/module/components/modals/modal-activity-reason/index.js +165 -0
- package/lib/module/components/modals/modal-activity-reason/index.js.map +1 -0
- package/lib/module/components/modals/modal-activity-reason/interface.d.js +2 -0
- package/lib/module/components/modals/modal-activity-reason/interface.d.js.map +1 -0
- package/lib/module/components/modals/modal-create-activitie/helpers/index.js +24 -0
- package/lib/module/components/modals/modal-create-activitie/helpers/index.js.map +1 -0
- package/lib/module/components/modals/modal-create-activitie/index.js +196 -0
- package/lib/module/components/modals/modal-create-activitie/index.js.map +1 -0
- package/lib/module/components/modals/modal-create-activitie/interface.js +2 -0
- package/lib/module/components/modals/modal-create-activitie/interface.js.map +1 -0
- package/lib/module/components/modals/modal-create-activitie/styles.js +39 -0
- package/lib/module/components/modals/modal-create-activitie/styles.js.map +1 -0
- package/lib/module/components/modals/modal-exclude-activitie/index.js +2 -0
- package/lib/module/components/modals/modal-exclude-activitie/index.js.map +1 -0
- package/lib/module/components/modals/modal-journey-rectification/index.js +236 -0
- package/lib/module/components/modals/modal-journey-rectification/index.js.map +1 -0
- package/lib/module/components/modals/modal-journey-rectification/interface.d.js +2 -0
- package/lib/module/components/modals/modal-journey-rectification/interface.d.js.map +1 -0
- package/lib/module/components/modals/modal-to-confimations/index.js +179 -0
- package/lib/module/components/modals/modal-to-confimations/index.js.map +1 -0
- package/lib/module/components/modals/modal-to-confimations/interface.js +2 -0
- package/lib/module/components/modals/modal-to-confimations/interface.js.map +1 -0
- package/lib/module/components/selects/select-date-and-hours/index.js +74 -0
- package/lib/module/components/selects/select-date-and-hours/index.js.map +1 -0
- package/lib/module/components/selects/select-date-and-hours/interface.js +4 -0
- package/lib/module/components/selects/select-date-and-hours/interface.js.map +1 -0
- package/lib/module/components/selects/select-date-and-hours/styles.js +31 -0
- package/lib/module/components/selects/select-date-and-hours/styles.js.map +1 -0
- package/lib/module/components/selects/select-option/index.js +4 -2
- package/lib/module/components/selects/select-option/index.js.map +1 -1
- package/lib/module/components/selects/select-option/styles.js +6 -7
- package/lib/module/components/selects/select-option/styles.js.map +1 -1
- package/lib/module/components/supply-error-card/index.js +6 -6
- package/lib/module/components/toast-message/index.js +8 -7
- package/lib/module/components/toast-message/index.js.map +1 -1
- package/lib/module/components/travel-history/index.js +7 -7
- package/lib/module/components/travel-history/index.js.map +1 -1
- package/lib/module/components/trip-details-card/index.js +94 -13
- package/lib/module/components/trip-details-card/index.js.map +1 -1
- package/lib/module/components/typography/index.js +5 -5
- package/lib/module/components/typography/index.js.map +1 -1
- package/lib/module/index.js +7 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/stories/list-devices/list-devices.stories.js +140 -0
- package/lib/module/stories/list-devices/list-devices.stories.js.map +1 -0
- package/lib/module/stories/list-supplies/list-supplies.stories.js +63 -0
- package/lib/module/stories/list-supplies/list-supplies.stories.js.map +1 -0
- package/lib/module/stories/modal-activity-reason/modal-activity-reason.stories.js +57 -0
- package/lib/module/stories/modal-activity-reason/modal-activity-reason.stories.js.map +1 -0
- package/lib/module/stories/modal-journey-rectification/modal-journey-rectification.stories.js +57 -0
- package/lib/module/stories/modal-journey-rectification/modal-journey-rectification.stories.js.map +1 -0
- package/lib/module/stories/supply-error-card/supply-error-card.stories.js +2 -2
- package/lib/module/stories/trip-details-card/trip-details-card.stories.js +39 -6
- package/lib/module/stories/trip-details-card/trip-details-card.stories.js.map +1 -1
- package/lib/module/styles/theme/theme.js +1 -0
- package/lib/module/styles/theme/theme.js.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/bluetooth/index.d.ts +5 -1
- package/lib/typescript/commonjs/src/common/icons-svg/bluetooth/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/constants/index.d.ts +2 -0
- package/lib/typescript/commonjs/src/common/icons-svg/constants/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/plus-container/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/common/icons-svg/plus-container/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/common/icons-svg/trash/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/common/icons-svg/trash/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/activity-step/components/activite-row/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/activity-step/components/activite-row/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/activity-step/index.d.ts +17 -0
- package/lib/typescript/commonjs/src/components/activity-step/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/activity-step/interface.d.ts +40 -0
- package/lib/typescript/commonjs/src/components/activity-step/interface.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/activity-step/styles.d.ts +75 -0
- package/lib/typescript/commonjs/src/components/activity-step/styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/card-scheduled-journey/index.d.ts +2 -1
- package/lib/typescript/commonjs/src/components/card-scheduled-journey/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/styles.d.ts +59 -0
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/list-devices/helpers/get-icon-by-status.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/list-devices/helpers/get-icon-by-status.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/list-devices/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/list-devices/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/list-devices/styles.d.ts +57 -0
- package/lib/typescript/commonjs/src/components/list-devices/styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/list-supplies/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/list-supplies/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/maintenance-description-input/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/modals/modal-activity-reason/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/modals/modal-activity-reason/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/helpers/index.d.ts +21 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/helpers/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/interface.d.ts +19 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/interface.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/styles.d.ts +33 -0
- package/lib/typescript/commonjs/src/components/modals/modal-create-activitie/styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-exclude-activitie/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-exclude-activitie/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-journey-rectification/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/modals/modal-journey-rectification/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-to-confimations/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/modals/modal-to-confimations/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/modals/modal-to-confimations/interface.d.ts +28 -0
- package/lib/typescript/commonjs/src/components/modals/modal-to-confimations/interface.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/interface.d.ts +22 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/interface.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/styles.d.ts +26 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/selects/select-option/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/components/selects/select-option/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/selects/select-option/styles.d.ts +0 -1
- package/lib/typescript/commonjs/src/components/selects/select-option/styles.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/supply-error-card/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/toast-message/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/trip-details-card/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/index.d.ts +7 -0
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/stories/list-devices/list-devices.stories.d.ts +22 -0
- package/lib/typescript/commonjs/src/stories/list-devices/list-devices.stories.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/stories/list-supplies/list-supplies.stories.d.ts +10 -0
- package/lib/typescript/commonjs/src/stories/list-supplies/list-supplies.stories.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/stories/modal-activity-reason/modal-activity-reason.stories.d.ts +10 -0
- package/lib/typescript/commonjs/src/stories/modal-activity-reason/modal-activity-reason.stories.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts +10 -0
- package/lib/typescript/commonjs/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/stories/trip-details-card/trip-details-card.stories.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/styles/global/theme-provider.d.ts +1 -0
- package/lib/typescript/commonjs/src/styles/global/theme-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/styles/theme/theme.d.ts +1 -0
- package/lib/typescript/commonjs/src/styles/theme/theme.d.ts.map +1 -1
- package/lib/typescript/module/src/common/icons-svg/bluetooth/index.d.ts +5 -1
- package/lib/typescript/module/src/common/icons-svg/bluetooth/index.d.ts.map +1 -1
- package/lib/typescript/module/src/common/icons-svg/constants/index.d.ts +2 -0
- package/lib/typescript/module/src/common/icons-svg/constants/index.d.ts.map +1 -1
- package/lib/typescript/module/src/common/icons-svg/index.d.ts.map +1 -1
- package/lib/typescript/module/src/common/icons-svg/plus-container/index.d.ts +11 -0
- package/lib/typescript/module/src/common/icons-svg/plus-container/index.d.ts.map +1 -0
- package/lib/typescript/module/src/common/icons-svg/trash/index.d.ts +11 -0
- package/lib/typescript/module/src/common/icons-svg/trash/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/activity-step/components/activite-row/index.d.ts +11 -0
- package/lib/typescript/module/src/components/activity-step/components/activite-row/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/activity-step/index.d.ts +17 -0
- package/lib/typescript/module/src/components/activity-step/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/activity-step/interface.d.ts +40 -0
- package/lib/typescript/module/src/components/activity-step/interface.d.ts.map +1 -0
- package/lib/typescript/module/src/components/activity-step/styles.d.ts +75 -0
- package/lib/typescript/module/src/components/activity-step/styles.d.ts.map +1 -0
- package/lib/typescript/module/src/components/card-scheduled-journey/index.d.ts +2 -1
- package/lib/typescript/module/src/components/card-scheduled-journey/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/inputs/input-date-time/index.d.ts +8 -0
- package/lib/typescript/module/src/components/inputs/input-date-time/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/inputs/input-date-time/styles.d.ts +59 -0
- package/lib/typescript/module/src/components/inputs/input-date-time/styles.d.ts.map +1 -0
- package/lib/typescript/module/src/components/list-devices/helpers/get-icon-by-status.d.ts +15 -0
- package/lib/typescript/module/src/components/list-devices/helpers/get-icon-by-status.d.ts.map +1 -0
- package/lib/typescript/module/src/components/list-devices/index.d.ts +11 -0
- package/lib/typescript/module/src/components/list-devices/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/list-devices/styles.d.ts +57 -0
- package/lib/typescript/module/src/components/list-devices/styles.d.ts.map +1 -0
- package/lib/typescript/module/src/components/list-supplies/index.d.ts +8 -0
- package/lib/typescript/module/src/components/list-supplies/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/maintenance-description-input/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/modals/modal-activity-reason/index.d.ts +8 -0
- package/lib/typescript/module/src/components/modals/modal-activity-reason/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/helpers/index.d.ts +21 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/helpers/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/index.d.ts +8 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/interface.d.ts +19 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/interface.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/styles.d.ts +33 -0
- package/lib/typescript/module/src/components/modals/modal-create-activitie/styles.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-exclude-activitie/index.d.ts +1 -0
- package/lib/typescript/module/src/components/modals/modal-exclude-activitie/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-journey-rectification/index.d.ts +8 -0
- package/lib/typescript/module/src/components/modals/modal-journey-rectification/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-to-confimations/index.d.ts +8 -0
- package/lib/typescript/module/src/components/modals/modal-to-confimations/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/modals/modal-to-confimations/interface.d.ts +28 -0
- package/lib/typescript/module/src/components/modals/modal-to-confimations/interface.d.ts.map +1 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/index.d.ts +13 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/interface.d.ts +22 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/interface.d.ts.map +1 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/styles.d.ts +26 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/styles.d.ts.map +1 -0
- package/lib/typescript/module/src/components/selects/select-option/index.d.ts +1 -0
- package/lib/typescript/module/src/components/selects/select-option/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/selects/select-option/styles.d.ts +0 -1
- package/lib/typescript/module/src/components/selects/select-option/styles.d.ts.map +1 -1
- package/lib/typescript/module/src/components/supply-error-card/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/toast-message/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/trip-details-card/index.d.ts.map +1 -1
- package/lib/typescript/module/src/index.d.ts +7 -0
- package/lib/typescript/module/src/index.d.ts.map +1 -1
- package/lib/typescript/module/src/stories/list-devices/list-devices.stories.d.ts +22 -0
- package/lib/typescript/module/src/stories/list-devices/list-devices.stories.d.ts.map +1 -0
- package/lib/typescript/module/src/stories/list-supplies/list-supplies.stories.d.ts +10 -0
- package/lib/typescript/module/src/stories/list-supplies/list-supplies.stories.d.ts.map +1 -0
- package/lib/typescript/module/src/stories/modal-activity-reason/modal-activity-reason.stories.d.ts +10 -0
- package/lib/typescript/module/src/stories/modal-activity-reason/modal-activity-reason.stories.d.ts.map +1 -0
- package/lib/typescript/module/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts +10 -0
- package/lib/typescript/module/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts.map +1 -0
- package/lib/typescript/module/src/stories/trip-details-card/trip-details-card.stories.d.ts.map +1 -1
- package/lib/typescript/module/src/styles/global/theme-provider.d.ts +1 -0
- package/lib/typescript/module/src/styles/global/theme-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/styles/theme/theme.d.ts +1 -0
- package/lib/typescript/module/src/styles/theme/theme.d.ts.map +1 -1
- package/package.json +2 -1
- package/src/common/icons-svg/bluetooth/index.tsx +51 -24
- package/src/common/icons-svg/constants/index.ts +67 -65
- package/src/common/icons-svg/index.tsx +289 -280
- package/src/common/icons-svg/plus-container/index.tsx +32 -0
- package/src/common/icons-svg/trash/index.tsx +31 -0
- package/src/components/activity-step/components/activite-row/index.tsx +141 -0
- package/src/components/activity-step/index.tsx +73 -0
- package/src/components/activity-step/interface.ts +54 -0
- package/src/components/activity-step/styles.ts +72 -0
- package/src/components/card-scheduled-journey/index.tsx +140 -138
- package/src/components/card-scheduled-journey/interface.d.ts +145 -140
- package/src/components/inputs/input-date-time/index.tsx +133 -0
- package/src/components/inputs/input-date-time/interface.d.ts +25 -0
- package/src/components/inputs/input-date-time/styles.ts +63 -0
- package/src/components/list-devices/helpers/get-icon-by-status.tsx +20 -0
- package/src/components/list-devices/index.tsx +102 -0
- package/src/components/list-devices/interface.d.ts +36 -0
- package/src/components/list-devices/styles.ts +68 -0
- package/src/components/list-supplies/index.tsx +153 -0
- package/src/components/list-supplies/interface.d.ts +9 -0
- package/src/components/maintenance-description-input/index.tsx +1 -0
- package/src/components/maintenance-description-input/styles.ts +1 -1
- package/src/components/modals/modal-activity-reason/index.tsx +168 -0
- package/src/components/modals/modal-activity-reason/interface.d.ts +9 -0
- package/src/components/modals/modal-create-activitie/helpers/index.ts +14 -0
- package/src/components/modals/modal-create-activitie/index.tsx +210 -0
- package/src/components/modals/modal-create-activitie/interface.ts +22 -0
- package/src/components/modals/modal-create-activitie/styles.ts +24 -0
- package/src/components/modals/modal-exclude-activitie/index.ts +0 -0
- package/src/components/modals/modal-journey-rectification/index.tsx +236 -0
- package/src/components/modals/modal-journey-rectification/interface.d.ts +10 -0
- package/src/components/modals/modal-to-confimations/index.tsx +182 -0
- package/src/components/modals/modal-to-confimations/interface.ts +36 -0
- package/src/components/selects/select-date-and-hours/index.tsx +70 -0
- package/src/components/selects/select-date-and-hours/interface.ts +31 -0
- package/src/components/selects/select-date-and-hours/styles.ts +24 -0
- package/src/components/selects/select-option/index.tsx +2 -1
- package/src/components/selects/select-option/interface.d.ts +1 -1
- package/src/components/selects/select-option/styles.ts +74 -75
- package/src/components/supply-error-card/index.tsx +109 -109
- package/src/components/supply-error-card/interface.d.ts +133 -133
- package/src/components/toast-message/index.tsx +75 -74
- package/src/components/travel-history/index.tsx +7 -7
- package/src/components/trip-details-card/index.tsx +89 -12
- package/src/components/trip-details-card/interface.d.ts +4 -1
- package/src/components/typography/index.tsx +78 -78
- package/src/index.tsx +7 -0
- package/src/stories/list-devices/list-devices.stories.tsx +114 -0
- package/src/stories/list-supplies/list-supplies.stories.tsx +66 -0
- package/src/stories/modal-activity-reason/modal-activity-reason.stories.tsx +60 -0
- package/src/stories/modal-journey-rectification/modal-journey-rectification.stories.tsx +60 -0
- package/src/stories/supply-error-card/supply-error-card.stories.tsx +72 -72
- package/src/stories/trip-details-card/trip-details-card.stories.tsx +38 -5
- package/src/styles/theme/theme.ts +1 -0
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import React, { forwardRef, useCallback } from "react";
|
|
6
|
+
|
|
7
|
+
import { TouchableOpacity, View } from "react-native";
|
|
8
|
+
|
|
9
|
+
// components
|
|
10
|
+
import Typography from "../../../typography";
|
|
11
|
+
|
|
12
|
+
// commons / svg
|
|
13
|
+
import { Icons } from "../../../../common/icons-svg";
|
|
14
|
+
|
|
15
|
+
// typyngs
|
|
16
|
+
import type { IActivitieRowProps } from "../../interface";
|
|
17
|
+
import { asBaseComponent } from "../../../../@types/as-base-component";
|
|
18
|
+
|
|
19
|
+
// styles
|
|
20
|
+
import { theme } from "../../../../styles/theme/theme";
|
|
21
|
+
import { styles } from "../../styles";
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Componente ActivityRows para a interação da ui.
|
|
25
|
+
*/
|
|
26
|
+
const ActivityRows = forwardRef<any, IActivitieRowProps<any>>(
|
|
27
|
+
({ index, activities, items, onAdd, onEdit, onDelete }, ref): React.ReactElement => {
|
|
28
|
+
const handleAdd = useCallback(() => onAdd(activities), [onAdd, activities]);
|
|
29
|
+
const handleEdit = useCallback(() => onEdit(activities), [onEdit, activities]);
|
|
30
|
+
const handleDelete = useCallback(() => onDelete(activities), [onDelete, activities]);
|
|
31
|
+
|
|
32
|
+
const isInvalid = !!activities.invalid;
|
|
33
|
+
|
|
34
|
+
const dateText =
|
|
35
|
+
activities.date instanceof Date
|
|
36
|
+
? `${String(activities.date.getDate()).padStart(2, "0")}/${String(
|
|
37
|
+
activities.date.getMonth() + 1
|
|
38
|
+
).padStart(2, "0")}/${activities.date.getFullYear()}`
|
|
39
|
+
: String(activities.date ?? "");
|
|
40
|
+
|
|
41
|
+
const timeText =
|
|
42
|
+
activities.time instanceof Date
|
|
43
|
+
? `${String(activities.time.getHours()).padStart(2, "0")}:${String(
|
|
44
|
+
activities.time.getMinutes()
|
|
45
|
+
).padStart(2, "0")}`
|
|
46
|
+
: String(activities.time ?? "");
|
|
47
|
+
|
|
48
|
+
return (
|
|
49
|
+
<View ref={ref} style={styles.row}>
|
|
50
|
+
<View style={styles.badge}>
|
|
51
|
+
<Typography
|
|
52
|
+
text={String(index + 1)}
|
|
53
|
+
color={theme.colors.neutral[25]}
|
|
54
|
+
size={theme.fontSizes.sm}
|
|
55
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
56
|
+
/>
|
|
57
|
+
</View>
|
|
58
|
+
|
|
59
|
+
{Boolean(index !== items?.length - 1) && (
|
|
60
|
+
<View
|
|
61
|
+
style={{
|
|
62
|
+
width: 2,
|
|
63
|
+
height: 76,
|
|
64
|
+
backgroundColor: theme.colors.blue[500],
|
|
65
|
+
position: "absolute",
|
|
66
|
+
left: 21,
|
|
67
|
+
top: 60,
|
|
68
|
+
}}
|
|
69
|
+
/>
|
|
70
|
+
)}
|
|
71
|
+
|
|
72
|
+
<View style={styles.card}>
|
|
73
|
+
<Typography
|
|
74
|
+
numberOfLines={1}
|
|
75
|
+
style={styles.title}
|
|
76
|
+
text={activities.title ?? "Não informada"}
|
|
77
|
+
color={isInvalid ? theme.colors.red[900] : theme.colors.blue[500]}
|
|
78
|
+
size={14}
|
|
79
|
+
fontFamily={theme.fonts.inter_medium_500}
|
|
80
|
+
lineHeight={34}
|
|
81
|
+
/>
|
|
82
|
+
|
|
83
|
+
<View style={[styles.pill, isInvalid ? styles.pillInvalid : styles.pillOk]}>
|
|
84
|
+
<Icons
|
|
85
|
+
icon="CALENDAR"
|
|
86
|
+
size={18}
|
|
87
|
+
color={isInvalid ? theme.colors.red[900] : theme.colors.blue[500]}
|
|
88
|
+
/>
|
|
89
|
+
<Typography
|
|
90
|
+
text={dateText}
|
|
91
|
+
color={isInvalid ? theme.colors.red[800] : theme.colors.blue[400]}
|
|
92
|
+
size={theme.fontSizes.xs}
|
|
93
|
+
fontFamily={theme.fonts.inter_medium_500}
|
|
94
|
+
/>
|
|
95
|
+
<Typography
|
|
96
|
+
text="|"
|
|
97
|
+
color={isInvalid ? theme.colors.red[800] : theme.colors.blue[400]}
|
|
98
|
+
size={theme.fontSizes.sm}
|
|
99
|
+
style={styles.sep}
|
|
100
|
+
/>
|
|
101
|
+
<Typography
|
|
102
|
+
text={timeText}
|
|
103
|
+
color={isInvalid ? theme.colors.red[800] : theme.colors.blue[500]}
|
|
104
|
+
size={theme.fontSizes.xs}
|
|
105
|
+
fontFamily={theme.fonts.inter_medium_500}
|
|
106
|
+
/>
|
|
107
|
+
</View>
|
|
108
|
+
</View>
|
|
109
|
+
|
|
110
|
+
<View style={styles.actions}>
|
|
111
|
+
<TouchableOpacity style={styles.iconButton} onPress={handleEdit} testID="edit-activity">
|
|
112
|
+
<Icons icon="NOTE_PINCEL" size={18} color={theme.colors.blue[350]} />
|
|
113
|
+
</TouchableOpacity>
|
|
114
|
+
|
|
115
|
+
<TouchableOpacity
|
|
116
|
+
style={styles.iconButton}
|
|
117
|
+
onPress={handleAdd}
|
|
118
|
+
testID="add-after-activity"
|
|
119
|
+
>
|
|
120
|
+
<Icons icon="PLUS_CONTAINER" size={18} color={theme.colors.green[500]} />
|
|
121
|
+
</TouchableOpacity>
|
|
122
|
+
|
|
123
|
+
<TouchableOpacity
|
|
124
|
+
style={styles.iconButton}
|
|
125
|
+
onPress={handleDelete}
|
|
126
|
+
testID="delete-activity"
|
|
127
|
+
>
|
|
128
|
+
<Icons icon="TRASH" size={18} color={theme.colors.red[900]} />
|
|
129
|
+
</TouchableOpacity>
|
|
130
|
+
</View>
|
|
131
|
+
</View>
|
|
132
|
+
);
|
|
133
|
+
}
|
|
134
|
+
);
|
|
135
|
+
|
|
136
|
+
ActivityRows.displayName = "ActivityRows";
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* EXPORTS
|
|
140
|
+
*/
|
|
141
|
+
export default asBaseComponent(ActivityRows);
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React, { forwardRef, useCallback } from "react";
|
|
5
|
+
|
|
6
|
+
import { View, FlatList } from "react-native";
|
|
7
|
+
|
|
8
|
+
// components
|
|
9
|
+
import ActivityRows from "./components/activite-row";
|
|
10
|
+
|
|
11
|
+
// typings
|
|
12
|
+
import type { ActivityItemModel, ActivityTimelineProps } from "./interface";
|
|
13
|
+
import { asBaseComponent } from "../../@types/as-base-component";
|
|
14
|
+
|
|
15
|
+
// styles
|
|
16
|
+
import { styles, ROW_HEIGHT } from "./styles";
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Componente ActivityTimeline para a interação da ui.
|
|
20
|
+
*/
|
|
21
|
+
const ActivityTimeline = forwardRef<any, ActivityTimelineProps<any>>(
|
|
22
|
+
(
|
|
23
|
+
{ data, onAdd, onEdit, onDelete, showIndexBadge = true, testID = "activity-timeline" },
|
|
24
|
+
ref
|
|
25
|
+
): React.ReactElement => {
|
|
26
|
+
const keyExtractor = useCallback((it: ActivityItemModel) => String(it.id), []);
|
|
27
|
+
|
|
28
|
+
const renderItem = useCallback(
|
|
29
|
+
({ item, index }: { item: ActivityItemModel; index: number }) => (
|
|
30
|
+
<ActivityRows
|
|
31
|
+
index={index}
|
|
32
|
+
items={data}
|
|
33
|
+
activities={item}
|
|
34
|
+
onAdd={onAdd}
|
|
35
|
+
onEdit={onEdit}
|
|
36
|
+
onDelete={onDelete}
|
|
37
|
+
showIndexBadge={showIndexBadge}
|
|
38
|
+
/>
|
|
39
|
+
),
|
|
40
|
+
[onAdd, onEdit, onDelete, showIndexBadge]
|
|
41
|
+
);
|
|
42
|
+
|
|
43
|
+
const getItemLayout = useCallback(
|
|
44
|
+
(_: any, index: number) => ({
|
|
45
|
+
length: ROW_HEIGHT,
|
|
46
|
+
offset: ROW_HEIGHT * index,
|
|
47
|
+
index,
|
|
48
|
+
}),
|
|
49
|
+
[]
|
|
50
|
+
);
|
|
51
|
+
return (
|
|
52
|
+
<FlatList
|
|
53
|
+
ref={ref}
|
|
54
|
+
testID={testID}
|
|
55
|
+
data={data}
|
|
56
|
+
keyExtractor={keyExtractor}
|
|
57
|
+
renderItem={renderItem}
|
|
58
|
+
contentContainerStyle={styles.listContainer}
|
|
59
|
+
getItemLayout={getItemLayout}
|
|
60
|
+
initialNumToRender={10}
|
|
61
|
+
maxToRenderPerBatch={10}
|
|
62
|
+
removeClippedSubviews
|
|
63
|
+
windowSize={7}
|
|
64
|
+
ListEmptyComponent={<View style={{ height: 8 }} />}
|
|
65
|
+
/>
|
|
66
|
+
);
|
|
67
|
+
}
|
|
68
|
+
);
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* EXPORTS
|
|
72
|
+
*/
|
|
73
|
+
export default asBaseComponent(ActivityTimeline);
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/* eslint-disable no-unused-vars */
|
|
2
|
+
/**
|
|
3
|
+
* IMPORTS
|
|
4
|
+
*/
|
|
5
|
+
import type { TouchableOpacityProps } from "react-native";
|
|
6
|
+
import type { SVG_NAME } from "../../common/icons-svg/constants";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* IMPORTS
|
|
10
|
+
*/
|
|
11
|
+
type ActivityId = string | number;
|
|
12
|
+
|
|
13
|
+
type ActivityItemModel = {
|
|
14
|
+
id: ActivityId;
|
|
15
|
+
title: string; // "Operação com veículo", "Refeição", ...
|
|
16
|
+
date: Date | string; // pode vir Date ou string já formatada
|
|
17
|
+
time: Date | string; // idem
|
|
18
|
+
invalid?: boolean; // destaca em vermelho
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
type IconName = keyof typeof SVG_NAME;
|
|
22
|
+
|
|
23
|
+
type OnActivity = (item: ActivityItemModel) => void;
|
|
24
|
+
|
|
25
|
+
type ActivityTimelineProps<T> = TouchableOpacityProps & {
|
|
26
|
+
data: T[];
|
|
27
|
+
onAdd: T; // add novo após o item
|
|
28
|
+
onEdit: T;
|
|
29
|
+
onDelete: T;
|
|
30
|
+
showIndexBadge?: boolean; // mostra o “3/4/5”
|
|
31
|
+
testID?: string;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
type IActivitieRowProps<T> = {
|
|
35
|
+
index: number;
|
|
36
|
+
activities: ActivityItemModel;
|
|
37
|
+
items: T[];
|
|
38
|
+
onAdd: OnActivity;
|
|
39
|
+
onEdit: OnActivity;
|
|
40
|
+
onDelete: OnActivity;
|
|
41
|
+
showIndexBadge?: boolean;
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* EXPORT
|
|
46
|
+
*/
|
|
47
|
+
export type {
|
|
48
|
+
ActivityId,
|
|
49
|
+
ActivityItemModel,
|
|
50
|
+
IconName,
|
|
51
|
+
OnActivity,
|
|
52
|
+
ActivityTimelineProps,
|
|
53
|
+
IActivitieRowProps,
|
|
54
|
+
};
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { StyleSheet } from "react-native";
|
|
6
|
+
|
|
7
|
+
// styles
|
|
8
|
+
import { theme } from "../../styles/theme/theme";
|
|
9
|
+
|
|
10
|
+
export const ROW_HEIGHT = 72;
|
|
11
|
+
|
|
12
|
+
const styles = StyleSheet.create({
|
|
13
|
+
listContainer: { paddingVertical: 8 },
|
|
14
|
+
row: {
|
|
15
|
+
width: "100%",
|
|
16
|
+
minHeight: ROW_HEIGHT,
|
|
17
|
+
paddingVertical: 8,
|
|
18
|
+
paddingHorizontal: 8,
|
|
19
|
+
flexDirection: "row",
|
|
20
|
+
alignItems: "center",
|
|
21
|
+
justifyContent: "center",
|
|
22
|
+
gap: 6,
|
|
23
|
+
},
|
|
24
|
+
badge: {
|
|
25
|
+
width: 28,
|
|
26
|
+
height: 28,
|
|
27
|
+
borderRadius: 14,
|
|
28
|
+
backgroundColor: theme.colors.blue[500],
|
|
29
|
+
alignItems: "center",
|
|
30
|
+
justifyContent: "center",
|
|
31
|
+
},
|
|
32
|
+
card: {
|
|
33
|
+
flex: 1,
|
|
34
|
+
borderRadius: 10,
|
|
35
|
+
},
|
|
36
|
+
title: { marginBottom: 6 },
|
|
37
|
+
pill: {
|
|
38
|
+
flexDirection: "row",
|
|
39
|
+
alignItems: "center",
|
|
40
|
+
borderWidth: 1,
|
|
41
|
+
borderRadius: 10,
|
|
42
|
+
paddingHorizontal: 10,
|
|
43
|
+
paddingVertical: 8,
|
|
44
|
+
gap: 4,
|
|
45
|
+
},
|
|
46
|
+
pillOk: {
|
|
47
|
+
backgroundColor: "#F3F3F5",
|
|
48
|
+
borderColor: "#C4D4E5",
|
|
49
|
+
},
|
|
50
|
+
pillInvalid: {
|
|
51
|
+
backgroundColor: "#FDE7E7",
|
|
52
|
+
borderColor: theme.colors.red[900],
|
|
53
|
+
},
|
|
54
|
+
sep: { marginHorizontal: 8, opacity: 0.5 },
|
|
55
|
+
actions: { flexDirection: "row", gap: 8 },
|
|
56
|
+
iconButton: {
|
|
57
|
+
width: 36,
|
|
58
|
+
height: 36,
|
|
59
|
+
borderRadius: 8,
|
|
60
|
+
backgroundColor: theme.colors.neutral[25],
|
|
61
|
+
borderWidth: 1,
|
|
62
|
+
borderColor: theme.colors.neutral[200],
|
|
63
|
+
alignItems: "center",
|
|
64
|
+
justifyContent: "center",
|
|
65
|
+
marginTop: 36,
|
|
66
|
+
},
|
|
67
|
+
});
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* EXPORTS
|
|
71
|
+
*/
|
|
72
|
+
export { styles };
|
|
@@ -1,138 +1,140 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import React, { forwardRef } from "react";
|
|
5
|
-
import { Dimensions } from "react-native";
|
|
6
|
-
|
|
7
|
-
// components
|
|
8
|
-
import Box from "../box";
|
|
9
|
-
import Typography from "../typography";
|
|
10
|
-
|
|
11
|
-
// typings
|
|
12
|
-
import { asBaseComponent } from "../../@types/as-base-component";
|
|
13
|
-
import { type ICardScheduledJourney } from "./interface";
|
|
14
|
-
|
|
15
|
-
// styles
|
|
16
|
-
import { theme } from "../../styles/theme/theme";
|
|
17
|
-
|
|
18
|
-
// icons / svg
|
|
19
|
-
import { Icons } from "../../common/icons-svg";
|
|
20
|
-
|
|
21
|
-
const CardScheduledJourney = forwardRef<any, ICardScheduledJourney>(
|
|
22
|
-
(props, ref): React.ReactElement => {
|
|
23
|
-
const {
|
|
24
|
-
title,
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
const
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
);
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React, { forwardRef } from "react";
|
|
5
|
+
import { Dimensions } from "react-native";
|
|
6
|
+
|
|
7
|
+
// components
|
|
8
|
+
import Box from "../box";
|
|
9
|
+
import Typography from "../typography";
|
|
10
|
+
|
|
11
|
+
// typings
|
|
12
|
+
import { asBaseComponent } from "../../@types/as-base-component";
|
|
13
|
+
import { type ICardScheduledJourney } from "./interface";
|
|
14
|
+
|
|
15
|
+
// styles
|
|
16
|
+
import { theme } from "../../styles/theme/theme";
|
|
17
|
+
|
|
18
|
+
// icons / svg
|
|
19
|
+
import { Icons } from "../../common/icons-svg";
|
|
20
|
+
|
|
21
|
+
const CardScheduledJourney = forwardRef<any, ICardScheduledJourney>(
|
|
22
|
+
(props, ref): React.ReactElement => {
|
|
23
|
+
const {
|
|
24
|
+
title,
|
|
25
|
+
subTitle,
|
|
26
|
+
duracao,
|
|
27
|
+
color = {},
|
|
28
|
+
backgroundColor,
|
|
29
|
+
borderStyled,
|
|
30
|
+
paddingStyle,
|
|
31
|
+
marginStyle,
|
|
32
|
+
flexStyle,
|
|
33
|
+
style,
|
|
34
|
+
width,
|
|
35
|
+
widthChildren,
|
|
36
|
+
icon,
|
|
37
|
+
borderRight,
|
|
38
|
+
} = props;
|
|
39
|
+
|
|
40
|
+
const { width: widthScreen } = Dimensions.get("window");
|
|
41
|
+
const isMobile = widthScreen < 768;
|
|
42
|
+
return (
|
|
43
|
+
<Box
|
|
44
|
+
ref={ref}
|
|
45
|
+
style={style}
|
|
46
|
+
width={width}
|
|
47
|
+
height={80}
|
|
48
|
+
backgroundColor={backgroundColor ?? theme.colors.neutral[25]}
|
|
49
|
+
borderStyled={{
|
|
50
|
+
borderWidth: borderStyled?.borderWidth ?? theme.borderWidths.thin,
|
|
51
|
+
borderRadius: borderStyled?.borderRadius ?? theme.borderWidths.thin_bold,
|
|
52
|
+
borderColor: borderStyled?.borderColor ?? theme.colors.gray[700],
|
|
53
|
+
}}
|
|
54
|
+
>
|
|
55
|
+
{/**CHILDREN */}
|
|
56
|
+
<Box
|
|
57
|
+
flexStyle={{
|
|
58
|
+
flexDirection: "row",
|
|
59
|
+
justifyContent: "space-between",
|
|
60
|
+
alignItems: "center",
|
|
61
|
+
}}
|
|
62
|
+
width={widthChildren}
|
|
63
|
+
borderStyled={{
|
|
64
|
+
borderRadius: borderStyled?.borderRadius ?? theme.borderWidths.thick,
|
|
65
|
+
}}
|
|
66
|
+
paddingStyle={{
|
|
67
|
+
paddingLeft: paddingStyle?.paddingLeft ?? 8,
|
|
68
|
+
}}
|
|
69
|
+
>
|
|
70
|
+
{/**ICONE*/}
|
|
71
|
+
<Box
|
|
72
|
+
width={65}
|
|
73
|
+
height={65}
|
|
74
|
+
backgroundColor={backgroundColor ?? theme.colors.neutral[25]}
|
|
75
|
+
flexStyle={{
|
|
76
|
+
justifyContent: flexStyle?.justifyContent ?? "center",
|
|
77
|
+
alignItems: flexStyle?.alignItems ?? "center",
|
|
78
|
+
}}
|
|
79
|
+
borderStyled={{
|
|
80
|
+
borderWidth: borderStyled?.borderWidth ?? theme.borderWidths.thin,
|
|
81
|
+
borderRadius: borderStyled?.borderRadius ?? theme.borderWidths.thick,
|
|
82
|
+
borderColor: borderStyled?.borderColor ?? theme.colors.gray[700],
|
|
83
|
+
}}
|
|
84
|
+
>
|
|
85
|
+
{icon && <Icons icon={icon} size={theme.fontSizes["2xl"]} />}
|
|
86
|
+
</Box>
|
|
87
|
+
|
|
88
|
+
{/**TITLE E DESCRIÇÃO */}
|
|
89
|
+
<Box
|
|
90
|
+
width={isMobile ? "73%" : "90%"}
|
|
91
|
+
flexStyle={{
|
|
92
|
+
flexDirection: "column",
|
|
93
|
+
justifyContent: "space-between",
|
|
94
|
+
}}
|
|
95
|
+
marginStyle={{ marginTop: marginStyle?.marginTop ?? -20 }}
|
|
96
|
+
>
|
|
97
|
+
<Typography
|
|
98
|
+
text={title}
|
|
99
|
+
size={theme.fontSizes.sm}
|
|
100
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
101
|
+
fontWeight={"700"}
|
|
102
|
+
color={color.colorText ?? theme.colors.black[25]}
|
|
103
|
+
lineHeight={theme.fontSizes.lg}
|
|
104
|
+
letterSpacing={"regular"}
|
|
105
|
+
/>
|
|
106
|
+
|
|
107
|
+
<Typography
|
|
108
|
+
text={`${subTitle ?? "Duração"}: ${duracao}`}
|
|
109
|
+
size={theme.fontSizes.xs}
|
|
110
|
+
fontWeight={"300"}
|
|
111
|
+
fontFamily={theme.fonts.inter_light_300}
|
|
112
|
+
color={color.colorText ?? theme.colors.black[25]}
|
|
113
|
+
lineHeight={theme.fontSizes.lg}
|
|
114
|
+
letterSpacing={"regular"}
|
|
115
|
+
marginTop={4}
|
|
116
|
+
/>
|
|
117
|
+
</Box>
|
|
118
|
+
|
|
119
|
+
{/**BORDAR */}
|
|
120
|
+
<Box
|
|
121
|
+
width={12}
|
|
122
|
+
height={78}
|
|
123
|
+
backgroundColor={borderRight ?? theme.colors.green[400]}
|
|
124
|
+
borderStyled={{
|
|
125
|
+
borderWidth: theme.borderWidths.thin,
|
|
126
|
+
borderTopRightRadius: theme.borderWidths.thick,
|
|
127
|
+
borderBottomRightRadius: theme.borderWidths.thick,
|
|
128
|
+
borderColor: borderRight ?? theme.colors.green[400],
|
|
129
|
+
}}
|
|
130
|
+
/>
|
|
131
|
+
</Box>
|
|
132
|
+
</Box>
|
|
133
|
+
);
|
|
134
|
+
}
|
|
135
|
+
);
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* Componente CardScheduledJourney para a interação da ui.
|
|
139
|
+
*/
|
|
140
|
+
export default asBaseComponent(CardScheduledJourney);
|