jornada-ui 0.4.10 → 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 +7 -6
- package/lib/commonjs/components/supply-error-card/index.js.map +1 -1
- 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 +12 -12
- package/lib/commonjs/stories/supply-error-card/supply-error-card.stories.js.map +1 -1
- 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 +7 -6
- package/lib/module/components/supply-error-card/index.js.map +1 -1
- 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 +12 -12
- package/lib/module/stories/supply-error-card/supply-error-card.stories.js.map +1 -1
- 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 +3 -8
- 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 +3 -8
- 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 +10 -6
- package/src/components/supply-error-card/interface.d.ts +3 -9
- 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 +12 -12
- package/src/stories/trip-details-card/trip-details-card.stories.tsx +38 -5
- package/src/styles/theme/theme.ts +1 -0
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import React, { forwardRef } from "react";
|
|
5
|
-
import { Text } from "react-native";
|
|
6
|
-
|
|
7
|
-
// typings
|
|
8
|
-
import { asBaseComponent } from "../../@types/as-base-component";
|
|
9
|
-
|
|
10
|
-
//styles
|
|
11
|
-
import { styles } from "./styles";
|
|
12
|
-
|
|
13
|
-
import type { ITextInterface } from "./interface";
|
|
14
|
-
|
|
15
|
-
const Typography = forwardRef<any, ITextInterface>((props, ref): React.ReactElement => {
|
|
16
|
-
// desestruturando as propiedades do componente
|
|
17
|
-
const {
|
|
18
|
-
text = "Hello Dev",
|
|
19
|
-
color = "#1E1E1E",
|
|
20
|
-
size = 23,
|
|
21
|
-
lineHeight = 24,
|
|
22
|
-
align = "left",
|
|
23
|
-
textDecoration,
|
|
24
|
-
fontWeight
|
|
25
|
-
fontFamily,
|
|
26
|
-
margin,
|
|
27
|
-
marginLeft,
|
|
28
|
-
marginRight,
|
|
29
|
-
marginTop,
|
|
30
|
-
marginBottom,
|
|
31
|
-
padding,
|
|
32
|
-
paddingLeft,
|
|
33
|
-
paddingRight,
|
|
34
|
-
paddingTop,
|
|
35
|
-
paddingBottom,
|
|
36
|
-
numberOfLines,
|
|
37
|
-
ellipsizeMode,
|
|
38
|
-
} = props;
|
|
39
|
-
|
|
40
|
-
// montando os dados que estão vindo via props para o componente
|
|
41
|
-
const data = {
|
|
42
|
-
color,
|
|
43
|
-
size,
|
|
44
|
-
lineHeight,
|
|
45
|
-
align,
|
|
46
|
-
textDecoration,
|
|
47
|
-
fontWeight,
|
|
48
|
-
fontFamily,
|
|
49
|
-
margin,
|
|
50
|
-
marginLeft,
|
|
51
|
-
marginRight,
|
|
52
|
-
marginTop,
|
|
53
|
-
marginBottom,
|
|
54
|
-
padding,
|
|
55
|
-
paddingLeft,
|
|
56
|
-
paddingRight,
|
|
57
|
-
paddingTop,
|
|
58
|
-
paddingBottom,
|
|
59
|
-
} as ITextInterface;
|
|
60
|
-
|
|
61
|
-
return (
|
|
62
|
-
<Text
|
|
63
|
-
ref={ref}
|
|
64
|
-
numberOfLines={numberOfLines}
|
|
65
|
-
ellipsizeMode={ellipsizeMode}
|
|
66
|
-
style={styles(data).text}
|
|
67
|
-
>
|
|
68
|
-
{text}
|
|
69
|
-
</Text>
|
|
70
|
-
);
|
|
71
|
-
});
|
|
72
|
-
|
|
73
|
-
Typography.displayName = "Text";
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Componente Typography para a interação da ui.
|
|
77
|
-
*/
|
|
78
|
-
export default asBaseComponent(Typography);
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React, { forwardRef } from "react";
|
|
5
|
+
import { Text } from "react-native";
|
|
6
|
+
|
|
7
|
+
// typings
|
|
8
|
+
import { asBaseComponent } from "../../@types/as-base-component";
|
|
9
|
+
|
|
10
|
+
//styles
|
|
11
|
+
import { styles } from "./styles";
|
|
12
|
+
|
|
13
|
+
import type { ITextInterface } from "./interface";
|
|
14
|
+
|
|
15
|
+
const Typography = forwardRef<any, ITextInterface>((props, ref): React.ReactElement => {
|
|
16
|
+
// desestruturando as propiedades do componente
|
|
17
|
+
const {
|
|
18
|
+
text = "Hello Dev",
|
|
19
|
+
color = "#1E1E1E",
|
|
20
|
+
size = 23,
|
|
21
|
+
lineHeight = 24,
|
|
22
|
+
align = "left",
|
|
23
|
+
textDecoration,
|
|
24
|
+
fontWeight,
|
|
25
|
+
fontFamily,
|
|
26
|
+
margin,
|
|
27
|
+
marginLeft,
|
|
28
|
+
marginRight,
|
|
29
|
+
marginTop,
|
|
30
|
+
marginBottom,
|
|
31
|
+
padding,
|
|
32
|
+
paddingLeft,
|
|
33
|
+
paddingRight,
|
|
34
|
+
paddingTop,
|
|
35
|
+
paddingBottom,
|
|
36
|
+
numberOfLines,
|
|
37
|
+
ellipsizeMode,
|
|
38
|
+
} = props;
|
|
39
|
+
|
|
40
|
+
// montando os dados que estão vindo via props para o componente
|
|
41
|
+
const data = {
|
|
42
|
+
color,
|
|
43
|
+
size,
|
|
44
|
+
lineHeight,
|
|
45
|
+
align,
|
|
46
|
+
textDecoration,
|
|
47
|
+
fontWeight,
|
|
48
|
+
fontFamily,
|
|
49
|
+
margin,
|
|
50
|
+
marginLeft,
|
|
51
|
+
marginRight,
|
|
52
|
+
marginTop,
|
|
53
|
+
marginBottom,
|
|
54
|
+
padding,
|
|
55
|
+
paddingLeft,
|
|
56
|
+
paddingRight,
|
|
57
|
+
paddingTop,
|
|
58
|
+
paddingBottom,
|
|
59
|
+
} as ITextInterface;
|
|
60
|
+
|
|
61
|
+
return (
|
|
62
|
+
<Text
|
|
63
|
+
ref={ref}
|
|
64
|
+
numberOfLines={numberOfLines}
|
|
65
|
+
ellipsizeMode={ellipsizeMode}
|
|
66
|
+
style={styles(data).text}
|
|
67
|
+
>
|
|
68
|
+
{text}
|
|
69
|
+
</Text>
|
|
70
|
+
);
|
|
71
|
+
});
|
|
72
|
+
|
|
73
|
+
Typography.displayName = "Text";
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* Componente Typography para a interação da ui.
|
|
77
|
+
*/
|
|
78
|
+
export default asBaseComponent(Typography);
|
package/src/index.tsx
CHANGED
|
@@ -40,6 +40,13 @@ export { default as BottomMessageConexion } from "./components/bottom-message-co
|
|
|
40
40
|
export { default as ToastMessage } from "./components/toast-message";
|
|
41
41
|
export { default as ModalTypeActivities } from "./components/modal-type-activities";
|
|
42
42
|
export { default as ResumeRaking } from "./components/resume-raking";
|
|
43
|
+
export { default as ListSupplies } from "./components/list-supplies";
|
|
44
|
+
export { default as ListDevices } from "./components/list-devices";
|
|
45
|
+
export { default as ModalActivityReason } from "./components/modals/modal-activity-reason";
|
|
46
|
+
export { default as ModalJourneyRectification } from "./components/modals/modal-journey-rectification";
|
|
47
|
+
export { default as ModalCreteActivitie } from "./components/modals/modal-create-activitie";
|
|
48
|
+
export { default as ModalToConfirmations } from "./components/modals/modal-to-confimations";
|
|
49
|
+
export { default as ActivityTimeline } from "./components/activity-step";
|
|
43
50
|
|
|
44
51
|
// adicionar o storybook + teste
|
|
45
52
|
export { default as WeeklyHoursBalance } from "./components/weekly-hours-balance";
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React from "react";
|
|
5
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
6
|
+
import { View } from "react-native";
|
|
7
|
+
|
|
8
|
+
// components
|
|
9
|
+
import ListDevices from "../../components/list-devices";
|
|
10
|
+
|
|
11
|
+
// styles
|
|
12
|
+
import { theme } from "../../styles/theme/theme";
|
|
13
|
+
|
|
14
|
+
const meta: Meta<typeof ListDevices> = {
|
|
15
|
+
title: "componente/ListDevices",
|
|
16
|
+
component: ListDevices,
|
|
17
|
+
parameters: {
|
|
18
|
+
docs: {
|
|
19
|
+
description: {
|
|
20
|
+
component: `
|
|
21
|
+
### ListDevices
|
|
22
|
+
|
|
23
|
+
Exibe uma lista de dispositivos Bluetooth. **Não há mudança visual** ao clicar/selecionar.
|
|
24
|
+
A seleção é apenas lógica (armazenada via \`onSelect\` e/ou \`selectedId/defaultSelectedId\`).
|
|
25
|
+
|
|
26
|
+
**Props**
|
|
27
|
+
- \`data: { id: number; nameDevice: string; macDevice?: string }\`[]
|
|
28
|
+
- \`titleColor?: string\`
|
|
29
|
+
- \`textColorDescription?: string\`
|
|
30
|
+
- \`selectedId?: number | null\` (controlado, sem efeito visual)
|
|
31
|
+
- \`defaultSelectedId?: number | null\` (não-controlado)
|
|
32
|
+
- \`onSelect?: (device) => void\`
|
|
33
|
+
- \`disabled?: boolean\`
|
|
34
|
+
`,
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
|
|
39
|
+
argTypes: {
|
|
40
|
+
titleColor: { control: "color", description: "Cor do título (nameDevice)" },
|
|
41
|
+
textColorDescription: { control: "color", description: "Cor da descrição (MAC)" },
|
|
42
|
+
selectedId: { control: "number", description: "ID selecionado (controlado)" },
|
|
43
|
+
defaultSelectedId: { control: "number", description: "ID inicial (não-controlado)" },
|
|
44
|
+
disabled: { control: "boolean", description: "Desabilita interação" },
|
|
45
|
+
onSelect: { action: "onSelect", description: "Callback ao selecionar" },
|
|
46
|
+
data: { control: "object", description: "Itens da lista" },
|
|
47
|
+
},
|
|
48
|
+
decorators: [
|
|
49
|
+
(Story) => (
|
|
50
|
+
<View style={{ padding: 16, backgroundColor: theme.colors.neutral[400] }}>
|
|
51
|
+
<Story />
|
|
52
|
+
</View>
|
|
53
|
+
),
|
|
54
|
+
],
|
|
55
|
+
};
|
|
56
|
+
export default meta;
|
|
57
|
+
|
|
58
|
+
type Story = StoryObj<typeof meta>;
|
|
59
|
+
|
|
60
|
+
const sampleData = [
|
|
61
|
+
{ id: 1, nameDevice: "Dispositivo X", macDevice: "AA:BB:CC:DD:EE:01" },
|
|
62
|
+
{ id: 2, nameDevice: "Celular Y Exemplo", macDevice: "AA:BB:CC:DD:EE:02" },
|
|
63
|
+
{ id: 3, nameDevice: "Celular A Exemplo", macDevice: "AA:BB:CC:DD:EE:03" },
|
|
64
|
+
{ id: 4, nameDevice: "Celular B Exemplo", macDevice: "AA:BB:CC:DD:EE:04" },
|
|
65
|
+
];
|
|
66
|
+
|
|
67
|
+
export const NaoControlado = {
|
|
68
|
+
name: "Não-controlado (memória interna, sem visual)",
|
|
69
|
+
args: {
|
|
70
|
+
data: sampleData,
|
|
71
|
+
defaultSelectedId: 2,
|
|
72
|
+
},
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
export const Controlado: Story = {
|
|
76
|
+
name: "Controlado (selectedId + onSelect, sem visual)",
|
|
77
|
+
args: { data: sampleData },
|
|
78
|
+
render: (args: React.ComponentProps<typeof ListDevices> = {}) => {
|
|
79
|
+
const [selectedId, setSelectedId] = React.useState<number | null>(1);
|
|
80
|
+
|
|
81
|
+
return (
|
|
82
|
+
<ListDevices
|
|
83
|
+
{...args}
|
|
84
|
+
selectedId={selectedId}
|
|
85
|
+
onSelect={(device) => {
|
|
86
|
+
setSelectedId(device.id);
|
|
87
|
+
args.onSelect?.(device);
|
|
88
|
+
}}
|
|
89
|
+
/>
|
|
90
|
+
);
|
|
91
|
+
},
|
|
92
|
+
};
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
/** Sem seleção inicial, apenas demonstrativo */
|
|
96
|
+
export const Basico: Story = {
|
|
97
|
+
name: "Básico (sem seleção inicial)",
|
|
98
|
+
args: {
|
|
99
|
+
data: sampleData,
|
|
100
|
+
titleColor: theme.colors.black[25],
|
|
101
|
+
textColorDescription: theme.colors.gray[700],
|
|
102
|
+
},
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
/** Interação desabilitada */
|
|
106
|
+
export const Desabilitado: Story = {
|
|
107
|
+
name: "Desabilitado",
|
|
108
|
+
args: {
|
|
109
|
+
data: sampleData,
|
|
110
|
+
disabled: true,
|
|
111
|
+
titleColor: theme.colors.black[25],
|
|
112
|
+
textColorDescription: theme.colors.gray[700],
|
|
113
|
+
},
|
|
114
|
+
};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
5
|
+
|
|
6
|
+
// components
|
|
7
|
+
import ListSupplies from "../../components/list-supplies";
|
|
8
|
+
|
|
9
|
+
const meta: Meta<typeof ListSupplies> = {
|
|
10
|
+
title: "componente/ListSupplies",
|
|
11
|
+
component: ListSupplies,
|
|
12
|
+
args: {
|
|
13
|
+
dataRegistro: "11/03/2025 às 14:53:27",
|
|
14
|
+
namePosto: "POSTO TRES GARCAS LTDA",
|
|
15
|
+
litragem: 100,
|
|
16
|
+
valor: 450.75,
|
|
17
|
+
},
|
|
18
|
+
parameters: {
|
|
19
|
+
notes: `
|
|
20
|
+
# ListSupplies
|
|
21
|
+
Card visual para exibir uma lavagem de cavalo registrada.
|
|
22
|
+
### Como usar:
|
|
23
|
+
\`\`\`tsx
|
|
24
|
+
<ListSupplies
|
|
25
|
+
dataRegistro="11/03/2025 às 14:53:27"
|
|
26
|
+
namePosto= "POSTO TRES GARCAS LTDA"
|
|
27
|
+
litragem= {100}
|
|
28
|
+
valor= {450.75}
|
|
29
|
+
corBarra="#2ECC71"
|
|
30
|
+
/>
|
|
31
|
+
\`\`\`
|
|
32
|
+
`,
|
|
33
|
+
docs: {
|
|
34
|
+
description: {
|
|
35
|
+
component: `
|
|
36
|
+
### list-supplies
|
|
37
|
+
|
|
38
|
+
Componente de **list-supplies** para visualizar os abastecimentos realizados.
|
|
39
|
+
|
|
40
|
+
- \`corBarra\`: define sa cor da barra lateral, pode ser utilizada para diferenciar utilização em atualizações futuras
|
|
41
|
+
- \`imagemUrl\`Pode ser passada por parâmetro, caso não seja passada, o componente não exibirá a imagem
|
|
42
|
+
- \`dataRegistro\`: campo obrigatório, deve ser passado por parâmetro a data e hora do registro
|
|
43
|
+
- \`namePosto\`: campo obrigatório, deve ser passado por parâmetro o nome do posto
|
|
44
|
+
- \`litragem\`: campo obrigatório, deve ser passado por parâmetro a litragem abastecida
|
|
45
|
+
- \`valor\`: campo opcional, pode ser passado por parâmetro o valor total do abastecimento
|
|
46
|
+
- \`Todos os outros campos\`: podem ser definids e mostrados de maneira dinâmica, passando os valores por parâmetro
|
|
47
|
+
`,
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
export default meta;
|
|
54
|
+
|
|
55
|
+
type Story = StoryObj<typeof meta>;
|
|
56
|
+
|
|
57
|
+
export const Padrao: Story = {
|
|
58
|
+
name: "list-supplies",
|
|
59
|
+
args: {
|
|
60
|
+
dataRegistro: "11/03/2025 às 14:53:27",
|
|
61
|
+
namePosto: "POSTO TRES GARCAS LTDA",
|
|
62
|
+
litragem: 100,
|
|
63
|
+
valor: 450.75,
|
|
64
|
+
imagemUrl: "https://placehold.co/300x300",
|
|
65
|
+
},
|
|
66
|
+
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import type { StoryObj, Meta } from "@storybook/react";
|
|
5
|
+
|
|
6
|
+
// components
|
|
7
|
+
import ModalActivityReason from "../../components/modals/modal-activity-reason";
|
|
8
|
+
|
|
9
|
+
const meta: Meta<typeof ModalActivityReason> = {
|
|
10
|
+
title: "Componente/ModalActivityReason",
|
|
11
|
+
component: ModalActivityReason,
|
|
12
|
+
args: {
|
|
13
|
+
visible: false,
|
|
14
|
+
onClose: () => {},
|
|
15
|
+
modalConfirm: () => {},
|
|
16
|
+
},
|
|
17
|
+
parameters: {
|
|
18
|
+
docs: {
|
|
19
|
+
description: {
|
|
20
|
+
component: `
|
|
21
|
+
### ModalActivityReason
|
|
22
|
+
Este componente exibe um modal para fazer a exclusão de uma atividade.
|
|
23
|
+
## Uso
|
|
24
|
+
\`\`\`tsx
|
|
25
|
+
<ModalActivityReason
|
|
26
|
+
visible={boolean}
|
|
27
|
+
onClose={function}
|
|
28
|
+
modalConfirm={function}
|
|
29
|
+
textTitle={string} (opcional)
|
|
30
|
+
/>
|
|
31
|
+
Componente de **modal-activity-reason** para exibir um modal solicitando o motivo de exclusão ou outra ação crítica.
|
|
32
|
+
|
|
33
|
+
- \`visible\`: define a visibilidade do modal, controlando se deve estar aberto ou fechado
|
|
34
|
+
- \`onClose\`: função obrigatória, chamada ao cancelar ou fechar o modal
|
|
35
|
+
- \`modalConfirm\`: função obrigatória, chamada ao confirmar a ação (retorna \`true\` por padrão)
|
|
36
|
+
- \`textTitle\`: campo opcional, permite personalizar o título exibido no cabeçalho do modal
|
|
37
|
+
- \`MaintenanceDescriptionInput\`: campo de texto exibido no corpo do modal para o usuário inserir a justificativa
|
|
38
|
+
- \`Botões\`: dois botões de ação — **CANCELAR** e **CONFIRMAR**
|
|
39
|
+
- **CANCELAR**: fecha o modal sem executar ação
|
|
40
|
+
- **CONFIRMAR**: chama \`modalConfirm(true)\` e em seguida \`onClose()\`
|
|
41
|
+
|
|
42
|
+
> Caso \`textTitle\` não seja passado, o modal exibirá "Motivo da exclusão" como título padrão.
|
|
43
|
+
`,
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
export default meta;
|
|
50
|
+
|
|
51
|
+
type Story = StoryObj<typeof ModalActivityReason>;
|
|
52
|
+
|
|
53
|
+
export const Default: Story = {
|
|
54
|
+
name: "modal-activity-reason",
|
|
55
|
+
args: {
|
|
56
|
+
visible: true,
|
|
57
|
+
onClose: () => {},
|
|
58
|
+
modalConfirm: () => {},
|
|
59
|
+
},
|
|
60
|
+
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import type { StoryObj, Meta } from "@storybook/react";
|
|
5
|
+
|
|
6
|
+
// components
|
|
7
|
+
import ModalJourneyRectification from "../../components/modals/modal-journey-rectification";
|
|
8
|
+
|
|
9
|
+
const meta: Meta<typeof ModalJourneyRectification> = {
|
|
10
|
+
title: "Componente/ModalJourneyRectification",
|
|
11
|
+
component: ModalJourneyRectification,
|
|
12
|
+
args: {
|
|
13
|
+
visible: false,
|
|
14
|
+
onClose: () => {},
|
|
15
|
+
modalConfirm: () => {},
|
|
16
|
+
},
|
|
17
|
+
parameters: {
|
|
18
|
+
docs: {
|
|
19
|
+
description: {
|
|
20
|
+
component: `
|
|
21
|
+
### ModalJourneyRectification
|
|
22
|
+
Este componente exibe um modal para fazer a exclusão de uma atividade.
|
|
23
|
+
## Uso
|
|
24
|
+
\`\`\`tsx
|
|
25
|
+
<ModalJourneyRectification
|
|
26
|
+
visible={boolean}
|
|
27
|
+
onClose={function}
|
|
28
|
+
modalConfirm={function}
|
|
29
|
+
textTitle={string} (opcional)
|
|
30
|
+
/>
|
|
31
|
+
Componente de **modal-journey-rectification** para exibir um modal solicitando o motivo de exclusão ou outra ação crítica.
|
|
32
|
+
|
|
33
|
+
- \`visible\`: define a visibilidade do modal, controlando se deve estar aberto ou fechado
|
|
34
|
+
- \`onClose\`: função obrigatória, chamada ao cancelar ou fechar o modal
|
|
35
|
+
- \`modalConfirm\`: função obrigatória, chamada ao confirmar a ação (retorna \`true\` por padrão)
|
|
36
|
+
- \`textTitle\`: campo opcional, permite personalizar o título exibido no cabeçalho do modal
|
|
37
|
+
- \`MaintenanceDescriptionInput\`: campo de texto exibido no corpo do modal para o usuário inserir a justificativa
|
|
38
|
+
- \`Botões\`: dois botões de ação — **CANCELAR** e **CONFIRMAR**
|
|
39
|
+
- **CANCELAR**: fecha o modal sem executar ação
|
|
40
|
+
- **CONFIRMAR**: chama \`modalConfirm(true)\` e em seguida \`onClose()\`
|
|
41
|
+
|
|
42
|
+
> Caso \`textTitle\` não seja passado, o modal exibirá "Motivo da exclusão" como título padrão.
|
|
43
|
+
`,
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
export default meta;
|
|
50
|
+
|
|
51
|
+
type Story = StoryObj<typeof ModalJourneyRectification>;
|
|
52
|
+
|
|
53
|
+
export const Default: Story = {
|
|
54
|
+
name: "modal-journey-rectification",
|
|
55
|
+
args: {
|
|
56
|
+
visible: true,
|
|
57
|
+
onClose: () => {},
|
|
58
|
+
modalConfirm: () => {},
|
|
59
|
+
},
|
|
60
|
+
};
|
|
@@ -11,14 +11,14 @@ const meta: Meta<typeof SupplyErrorCard> = {
|
|
|
11
11
|
title: "componente/SupplyErrorCard",
|
|
12
12
|
component: SupplyErrorCard as React.FC,
|
|
13
13
|
args: {
|
|
14
|
-
|
|
15
|
-
{ id: 101,
|
|
16
|
-
{ id: 203,
|
|
17
|
-
{ id: 310,
|
|
14
|
+
errors: [
|
|
15
|
+
{ id: 101, descricacao: "Erro ao sincronizar abastecimento #101. Clique para corrigir." },
|
|
16
|
+
{ id: 203, descricacao: "Valor inválido no abastecimento #203." },
|
|
17
|
+
{ id: 310, descricacao: "Imagem do comprovante ausente no abastecimento #310." },
|
|
18
18
|
],
|
|
19
19
|
},
|
|
20
20
|
argTypes: {
|
|
21
|
-
|
|
21
|
+
errors: {
|
|
22
22
|
description: "Lista de mensagens de erro/exceção relacionadas a abastecimentos.",
|
|
23
23
|
control: "object",
|
|
24
24
|
table: {
|
|
@@ -35,13 +35,13 @@ Ao **clicar**, expande e mostra a lista completa. O ícone alterna entre *chevro
|
|
|
35
35
|
|
|
36
36
|
## Uso básico
|
|
37
37
|
\`\`\`tsx
|
|
38
|
-
const
|
|
39
|
-
{ id: 101,
|
|
40
|
-
{ id: 203,
|
|
41
|
-
{ id: 310,
|
|
38
|
+
const errors = [
|
|
39
|
+
{ id: 101, descricao: "Erro ao sincronizar abastecimento #101. Clique para corrigir." },
|
|
40
|
+
{ id: 203, descricao: "Valor inválido no abastecimento #203." },
|
|
41
|
+
{ id: 310, descricao: "Imagem do comprovante ausente no abastecimento #310." },
|
|
42
42
|
];
|
|
43
43
|
|
|
44
|
-
<SupplyErrorCard
|
|
44
|
+
<SupplyErrorCard errors={mensagens} />
|
|
45
45
|
\`\`\`
|
|
46
46
|
|
|
47
47
|
## Dicas
|
|
@@ -58,7 +58,7 @@ type Story = StoryObj<typeof meta>;
|
|
|
58
58
|
export const Default: Story = {
|
|
59
59
|
name: "supply-error-card-default",
|
|
60
60
|
args: {
|
|
61
|
-
|
|
61
|
+
errors: [
|
|
62
62
|
{ id: 101, mensagem: "Erro ao sincronizar abastecimento #101. Clique para corrigir." },
|
|
63
63
|
{ id: 203, mensagem: "Valor inválido no abastecimento #203." },
|
|
64
64
|
{ id: 310, mensagem: "Imagem do comprovante ausente no abastecimento #310." },
|
|
@@ -68,5 +68,5 @@ export const Default: Story = {
|
|
|
68
68
|
|
|
69
69
|
export const SupplyErrorCardNotMessage: Story = {
|
|
70
70
|
name: "supply-error-card",
|
|
71
|
-
args: {
|
|
71
|
+
args: { errors: [] },
|
|
72
72
|
};
|
|
@@ -10,7 +10,6 @@ const meta: Meta<typeof TripDetailsCard> = {
|
|
|
10
10
|
title: "componente/TripDetailsCard",
|
|
11
11
|
component: TripDetailsCard,
|
|
12
12
|
args: {
|
|
13
|
-
dataRegistro: "11/03/2025 às 14:53:27",
|
|
14
13
|
origem: "TIMÓTEO - MG",
|
|
15
14
|
destino: "CAMPINAS - SP",
|
|
16
15
|
proximoCarregamento: "CONTAGEM - MG",
|
|
@@ -22,13 +21,41 @@ Card visual para exibir uma lavagem de cavalo registrada.
|
|
|
22
21
|
### Como usar:
|
|
23
22
|
\`\`\`tsx
|
|
24
23
|
<TripDetailsCard
|
|
24
|
+
dataRegistro: "11/03/2025 às 14:53:27",
|
|
25
|
+
origem= "TIMÓTEO - MG",
|
|
26
|
+
destino= "CAMPINAS - SP",
|
|
25
27
|
numero={1}
|
|
26
|
-
dataRegistro="11/03/2025 às 14:53:27"
|
|
27
28
|
cavalo="RGA6B87"
|
|
29
|
+
peso= 25000,
|
|
30
|
+
baseCalculo= 3500,
|
|
28
31
|
corBarra="#2ECC71"
|
|
32
|
+
numeroCte= {12034}
|
|
33
|
+
kmCarregado= {100}
|
|
34
|
+
kmVazio= {200}
|
|
29
35
|
/>
|
|
30
36
|
\`\`\`
|
|
31
37
|
`,
|
|
38
|
+
docs: {
|
|
39
|
+
description: {
|
|
40
|
+
component: `
|
|
41
|
+
### TripDetailsCard
|
|
42
|
+
|
|
43
|
+
Componente de **trip-details-card** para visualizar os detalhes de uma viagem.
|
|
44
|
+
|
|
45
|
+
- \`corBarra\`: define a cor da barra lateral, útil para diferenciar ou categorizar viagens
|
|
46
|
+
- \`dataRegistro\`: campo obrigatório, deve ser passado por parâmetro a data e hora do carregamento
|
|
47
|
+
- \`numeroCte\`: campo obrigatório, representa o número do CTE associado à viagem
|
|
48
|
+
- \`origem\`: campo obrigatório, local de origem do carregamento
|
|
49
|
+
- \`destino\`: campo obrigatório, local de destino do carregamento
|
|
50
|
+
- \`proximoCarregamento\`: campo opcional, indica o próximo ponto de carregamento
|
|
51
|
+
- \`peso\`: campo opcional, peso da carga em quilogramas
|
|
52
|
+
- \`kmCarregado\`: campo opcional, quilometragem percorrida carregado
|
|
53
|
+
- \`kmVazio\`: campo opcional, quilometragem percorrida vazio
|
|
54
|
+
- \`baseCalculo\`: campo opcional, valor base usado para cálculo do PRO
|
|
55
|
+
- \`Interação\`: o componente possui um botão de expansão, que mostra ou oculta os detalhes da viagem ao ser clicado
|
|
56
|
+
`,
|
|
57
|
+
},
|
|
58
|
+
},
|
|
32
59
|
},
|
|
33
60
|
};
|
|
34
61
|
|
|
@@ -37,12 +64,18 @@ export default meta;
|
|
|
37
64
|
type Story = StoryObj<typeof meta>;
|
|
38
65
|
|
|
39
66
|
export const Padrao: Story = {
|
|
40
|
-
name: "card
|
|
67
|
+
name: "trip-details-card",
|
|
41
68
|
args: {
|
|
42
|
-
numero: 1,
|
|
43
69
|
dataRegistro: "11/03/2025 às 14:53:27",
|
|
70
|
+
origem: "TIMÓTEO - MG",
|
|
71
|
+
destino: "CAMPINAS - SP",
|
|
72
|
+
numero: 1,
|
|
44
73
|
cavalo: "RGA6B87",
|
|
74
|
+
peso: 25000,
|
|
75
|
+
baseCalculo: 3500,
|
|
45
76
|
corBarra: "#2ECC71",
|
|
46
|
-
|
|
77
|
+
numeroCte: 12034,
|
|
78
|
+
kmCarregado: 100,
|
|
79
|
+
kmVazio: 200,
|
|
47
80
|
},
|
|
48
81
|
};
|