@edge-zuq/core 1.2.7
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/LICENSE +20 -0
- package/README.md +99 -0
- package/lib/module/assets/logo.png +0 -0
- package/lib/module/data/errors/http-client-error.js +14 -0
- package/lib/module/data/errors/http-client-error.js.map +1 -0
- package/lib/module/data/errors/index.js +6 -0
- package/lib/module/data/errors/index.js.map +1 -0
- package/lib/module/data/errors/save-file-error.js +9 -0
- package/lib/module/data/errors/save-file-error.js.map +1 -0
- package/lib/module/data/errors/unsupported-platform.js +9 -0
- package/lib/module/data/errors/unsupported-platform.js.map +1 -0
- package/lib/module/data/models/index.js +6 -0
- package/lib/module/data/models/index.js.map +1 -0
- package/lib/module/data/models/remote-get-comment-list-model.js +2 -0
- package/lib/module/data/models/remote-get-comment-list-model.js.map +1 -0
- package/lib/module/data/models/remote-get-image-list-model.js +2 -0
- package/lib/module/data/models/remote-get-image-list-model.js.map +1 -0
- package/lib/module/data/models/remote-user-model.js +2 -0
- package/lib/module/data/models/remote-user-model.js.map +1 -0
- package/lib/module/data/protocols/cookie-manager.js +2 -0
- package/lib/module/data/protocols/cookie-manager.js.map +1 -0
- package/lib/module/data/protocols/download-manager.js +4 -0
- package/lib/module/data/protocols/download-manager.js.map +1 -0
- package/lib/module/data/protocols/http-client.js +26 -0
- package/lib/module/data/protocols/http-client.js.map +1 -0
- package/lib/module/data/protocols/index.js +9 -0
- package/lib/module/data/protocols/index.js.map +1 -0
- package/lib/module/data/protocols/notification-manager.js +4 -0
- package/lib/module/data/protocols/notification-manager.js.map +1 -0
- package/lib/module/data/protocols/permission-manager.js +4 -0
- package/lib/module/data/protocols/permission-manager.js.map +1 -0
- package/lib/module/data/protocols/storage.js +4 -0
- package/lib/module/data/protocols/storage.js.map +1 -0
- package/lib/module/data/use-cases/index.js +6 -0
- package/lib/module/data/use-cases/index.js.map +1 -0
- package/lib/module/data/use-cases/remote-get-comment-list.js +29 -0
- package/lib/module/data/use-cases/remote-get-comment-list.js.map +1 -0
- package/lib/module/data/use-cases/remote-get-image-list.js +32 -0
- package/lib/module/data/use-cases/remote-get-image-list.js.map +1 -0
- package/lib/module/data/use-cases/remote-send-diagnostics.js +20 -0
- package/lib/module/data/use-cases/remote-send-diagnostics.js.map +1 -0
- package/lib/module/domain/errors/authentication-expired-error.js +9 -0
- package/lib/module/domain/errors/authentication-expired-error.js.map +1 -0
- package/lib/module/domain/errors/index.js +7 -0
- package/lib/module/domain/errors/index.js.map +1 -0
- package/lib/module/domain/errors/internal-server-error.js +9 -0
- package/lib/module/domain/errors/internal-server-error.js.map +1 -0
- package/lib/module/domain/errors/invalid-credentials-error.js +9 -0
- package/lib/module/domain/errors/invalid-credentials-error.js.map +1 -0
- package/lib/module/domain/errors/no-app-permission-error.js +9 -0
- package/lib/module/domain/errors/no-app-permission-error.js.map +1 -0
- package/lib/module/domain/models/get-comment-list-model.js +2 -0
- package/lib/module/domain/models/get-comment-list-model.js.map +1 -0
- package/lib/module/domain/models/get-image-list-model.js +2 -0
- package/lib/module/domain/models/get-image-list-model.js.map +1 -0
- package/lib/module/domain/models/index.js +6 -0
- package/lib/module/domain/models/index.js.map +1 -0
- package/lib/module/domain/models/user-model.js +2 -0
- package/lib/module/domain/models/user-model.js.map +1 -0
- package/lib/module/domain/use-cases/get-comment-list.js +4 -0
- package/lib/module/domain/use-cases/get-comment-list.js.map +1 -0
- package/lib/module/domain/use-cases/get-image-list.js +4 -0
- package/lib/module/domain/use-cases/get-image-list.js.map +1 -0
- package/lib/module/domain/use-cases/index.js +9 -0
- package/lib/module/domain/use-cases/index.js.map +1 -0
- package/lib/module/domain/use-cases/record-request.js +4 -0
- package/lib/module/domain/use-cases/record-request.js.map +1 -0
- package/lib/module/domain/use-cases/send-diagnostics.js +4 -0
- package/lib/module/domain/use-cases/send-diagnostics.js.map +1 -0
- package/lib/module/domain/use-cases/user-authentication.js +4 -0
- package/lib/module/domain/use-cases/user-authentication.js.map +1 -0
- package/lib/module/domain/use-cases/user-logout.js +4 -0
- package/lib/module/domain/use-cases/user-logout.js.map +1 -0
- package/lib/module/index.js +16 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/infra/axios-http-client-adapter.js +199 -0
- package/lib/module/infra/axios-http-client-adapter.js.map +1 -0
- package/lib/module/infra/index.js +10 -0
- package/lib/module/infra/index.js.map +1 -0
- package/lib/module/infra/isomorphic-id-manager.js +83 -0
- package/lib/module/infra/isomorphic-id-manager.js.map +1 -0
- package/lib/module/infra/mmkv-storage-adapter.js +62 -0
- package/lib/module/infra/mmkv-storage-adapter.js.map +1 -0
- package/lib/module/infra/notifee-notification-manager-adapter.js +69 -0
- package/lib/module/infra/notifee-notification-manager-adapter.js.map +1 -0
- package/lib/module/infra/offline-mutation-queue.js +210 -0
- package/lib/module/infra/offline-mutation-queue.js.map +1 -0
- package/lib/module/infra/rnbu-download-manager-adapter.js +31 -0
- package/lib/module/infra/rnbu-download-manager-adapter.js.map +1 -0
- package/lib/module/infra/rnp-permission-manager-adapter.js +117 -0
- package/lib/module/infra/rnp-permission-manager-adapter.js.map +1 -0
- package/lib/module/infra/storage-cookie-manager-adapter.js +24 -0
- package/lib/module/infra/storage-cookie-manager-adapter.js.map +1 -0
- package/lib/module/main/components/index.js +7 -0
- package/lib/module/main/components/index.js.map +1 -0
- package/lib/module/main/components/request-permissions.js +14 -0
- package/lib/module/main/components/request-permissions.js.map +1 -0
- package/lib/module/main/factories/infra/download-manager-factory.js +7 -0
- package/lib/module/main/factories/infra/download-manager-factory.js.map +1 -0
- package/lib/module/main/factories/infra/http-client-factory.js +7 -0
- package/lib/module/main/factories/infra/http-client-factory.js.map +1 -0
- package/lib/module/main/factories/infra/index.js +10 -0
- package/lib/module/main/factories/infra/index.js.map +1 -0
- package/lib/module/main/factories/infra/isomorphic-id-manager-factory.js +7 -0
- package/lib/module/main/factories/infra/isomorphic-id-manager-factory.js.map +1 -0
- package/lib/module/main/factories/infra/notification-manager-factory.js +7 -0
- package/lib/module/main/factories/infra/notification-manager-factory.js.map +1 -0
- package/lib/module/main/factories/infra/offline-mutation-queue-factory.js +7 -0
- package/lib/module/main/factories/infra/offline-mutation-queue-factory.js.map +1 -0
- package/lib/module/main/factories/infra/permission-manager-factory.js +7 -0
- package/lib/module/main/factories/infra/permission-manager-factory.js.map +1 -0
- package/lib/module/main/factories/infra/storage-factory.js +10 -0
- package/lib/module/main/factories/infra/storage-factory.js.map +1 -0
- package/lib/module/main/factories/use-cases/index.js +6 -0
- package/lib/module/main/factories/use-cases/index.js.map +1 -0
- package/lib/module/main/factories/use-cases/remote-get-comment-list-factory.js +7 -0
- package/lib/module/main/factories/use-cases/remote-get-comment-list-factory.js.map +1 -0
- package/lib/module/main/factories/use-cases/remote-get-image-list-factory.js +7 -0
- package/lib/module/main/factories/use-cases/remote-get-image-list-factory.js.map +1 -0
- package/lib/module/main/factories/use-cases/remote-send-diagnostics-factory.js +7 -0
- package/lib/module/main/factories/use-cases/remote-send-diagnostics-factory.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/presentation/components/atoms/UIBackdrop.js +31 -0
- package/lib/module/presentation/components/atoms/UIBackdrop.js.map +1 -0
- package/lib/module/presentation/components/atoms/UICheckbox.js +47 -0
- package/lib/module/presentation/components/atoms/UICheckbox.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIDot.js +33 -0
- package/lib/module/presentation/components/atoms/UIDot.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIIcon.js +1072 -0
- package/lib/module/presentation/components/atoms/UIIcon.js.map +1 -0
- package/lib/module/presentation/components/atoms/UILoading.js +19 -0
- package/lib/module/presentation/components/atoms/UILoading.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIPage.js +70 -0
- package/lib/module/presentation/components/atoms/UIPage.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIProgress.js +54 -0
- package/lib/module/presentation/components/atoms/UIProgress.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIScrollPage.js +72 -0
- package/lib/module/presentation/components/atoms/UIScrollPage.js.map +1 -0
- package/lib/module/presentation/components/atoms/UISeparator.js +30 -0
- package/lib/module/presentation/components/atoms/UISeparator.js.map +1 -0
- package/lib/module/presentation/components/atoms/UISpacer.js +19 -0
- package/lib/module/presentation/components/atoms/UISpacer.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIStack.js +31 -0
- package/lib/module/presentation/components/atoms/UIStack.js.map +1 -0
- package/lib/module/presentation/components/atoms/UIText.js +48 -0
- package/lib/module/presentation/components/atoms/UIText.js.map +1 -0
- package/lib/module/presentation/components/atoms/index.js +15 -0
- package/lib/module/presentation/components/atoms/index.js.map +1 -0
- package/lib/module/presentation/components/index.js +4 -0
- package/lib/module/presentation/components/index.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIActionSheet.js +199 -0
- package/lib/module/presentation/components/molecules/UIActionSheet.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIButton.js +173 -0
- package/lib/module/presentation/components/molecules/UIButton.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIButtonCTA.js +31 -0
- package/lib/module/presentation/components/molecules/UIButtonCTA.js.map +1 -0
- package/lib/module/presentation/components/molecules/UICheckboxInput.js +84 -0
- package/lib/module/presentation/components/molecules/UICheckboxInput.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIChip.js +49 -0
- package/lib/module/presentation/components/molecules/UIChip.js.map +1 -0
- package/lib/module/presentation/components/molecules/UICurrencyInput.js +32 -0
- package/lib/module/presentation/components/molecules/UICurrencyInput.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIDataList.js +26 -0
- package/lib/module/presentation/components/molecules/UIDataList.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIDataSectionList.js +26 -0
- package/lib/module/presentation/components/molecules/UIDataSectionList.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIDatetimeInput.js +202 -0
- package/lib/module/presentation/components/molecules/UIDatetimeInput.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIError.js +32 -0
- package/lib/module/presentation/components/molecules/UIError.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIImage.js +87 -0
- package/lib/module/presentation/components/molecules/UIImage.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIInlineDatePicker.js +245 -0
- package/lib/module/presentation/components/molecules/UIInlineDatePicker.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIInputIcon.js +38 -0
- package/lib/module/presentation/components/molecules/UIInputIcon.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIList.js +16 -0
- package/lib/module/presentation/components/molecules/UIList.js.map +1 -0
- package/lib/module/presentation/components/molecules/UIRadioInput.js +78 -0
- package/lib/module/presentation/components/molecules/UIRadioInput.js.map +1 -0
- package/lib/module/presentation/components/molecules/UISectionList.js +16 -0
- package/lib/module/presentation/components/molecules/UISectionList.js.map +1 -0
- package/lib/module/presentation/components/molecules/UISkeleton.js +54 -0
- package/lib/module/presentation/components/molecules/UISkeleton.js.map +1 -0
- package/lib/module/presentation/components/molecules/UISwitch.js +65 -0
- package/lib/module/presentation/components/molecules/UISwitch.js.map +1 -0
- package/lib/module/presentation/components/molecules/UITextInput.js +132 -0
- package/lib/module/presentation/components/molecules/UITextInput.js.map +1 -0
- package/lib/module/presentation/components/molecules/UITextInputMask.js +133 -0
- package/lib/module/presentation/components/molecules/UITextInputMask.js.map +1 -0
- package/lib/module/presentation/components/molecules/index.js +23 -0
- package/lib/module/presentation/components/molecules/index.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIAppBar.js +102 -0
- package/lib/module/presentation/components/organisms/UIAppBar.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIAppBarAction.js +21 -0
- package/lib/module/presentation/components/organisms/UIAppBarAction.js.map +1 -0
- package/lib/module/presentation/components/organisms/UICard.js +43 -0
- package/lib/module/presentation/components/organisms/UICard.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIComment.js +73 -0
- package/lib/module/presentation/components/organisms/UIComment.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIErrorBoundary.js +68 -0
- package/lib/module/presentation/components/organisms/UIErrorBoundary.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIForm.js +83 -0
- package/lib/module/presentation/components/organisms/UIForm.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormButton.js +43 -0
- package/lib/module/presentation/components/organisms/UIFormButton.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormCheckboxInput.js +39 -0
- package/lib/module/presentation/components/organisms/UIFormCheckboxInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormCurrencyInput.js +65 -0
- package/lib/module/presentation/components/organisms/UIFormCurrencyInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormDatetimeInput.js +54 -0
- package/lib/module/presentation/components/organisms/UIFormDatetimeInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormMultiselectInput.js +212 -0
- package/lib/module/presentation/components/organisms/UIFormMultiselectInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormRadioInput.js +36 -0
- package/lib/module/presentation/components/organisms/UIFormRadioInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormSelectInput.js +259 -0
- package/lib/module/presentation/components/organisms/UIFormSelectInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormTextInput.js +64 -0
- package/lib/module/presentation/components/organisms/UIFormTextInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIFormTextInputMask.js +69 -0
- package/lib/module/presentation/components/organisms/UIFormTextInputMask.js.map +1 -0
- package/lib/module/presentation/components/organisms/UIRow.js +55 -0
- package/lib/module/presentation/components/organisms/UIRow.js.map +1 -0
- package/lib/module/presentation/components/organisms/UISearchInput.js +33 -0
- package/lib/module/presentation/components/organisms/UISearchInput.js.map +1 -0
- package/lib/module/presentation/components/organisms/UISelectChip.js +94 -0
- package/lib/module/presentation/components/organisms/UISelectChip.js.map +1 -0
- package/lib/module/presentation/components/organisms/UISignature.js +159 -0
- package/lib/module/presentation/components/organisms/UISignature.js.map +1 -0
- package/lib/module/presentation/components/organisms/UISlideButton.js +90 -0
- package/lib/module/presentation/components/organisms/UISlideButton.js.map +1 -0
- package/lib/module/presentation/components/organisms/index.js +24 -0
- package/lib/module/presentation/components/organisms/index.js.map +1 -0
- package/lib/module/presentation/components/permissions/index.js +4 -0
- package/lib/module/presentation/components/permissions/index.js.map +1 -0
- package/lib/module/presentation/components/permissions/request-permissions.js +96 -0
- package/lib/module/presentation/components/permissions/request-permissions.js.map +1 -0
- package/lib/module/presentation/domain/metadata/index.js +5 -0
- package/lib/module/presentation/domain/metadata/index.js.map +1 -0
- package/lib/module/presentation/domain/metadata/use-comments.js +26 -0
- package/lib/module/presentation/domain/metadata/use-comments.js.map +1 -0
- package/lib/module/presentation/domain/metadata/use-images.js +26 -0
- package/lib/module/presentation/domain/metadata/use-images.js.map +1 -0
- package/lib/module/presentation/domain/offline/index.js +12 -0
- package/lib/module/presentation/domain/offline/index.js.map +1 -0
- package/lib/module/presentation/domain/offline/offline-mutation-queue-provider.js +69 -0
- package/lib/module/presentation/domain/offline/offline-mutation-queue-provider.js.map +1 -0
- package/lib/module/presentation/domain/offline/types.js +4 -0
- package/lib/module/presentation/domain/offline/types.js.map +1 -0
- package/lib/module/presentation/domain/offline/use-infinite-offline-query.js +69 -0
- package/lib/module/presentation/domain/offline/use-infinite-offline-query.js.map +1 -0
- package/lib/module/presentation/domain/offline/use-offline-id-v2.js +22 -0
- package/lib/module/presentation/domain/offline/use-offline-id-v2.js.map +1 -0
- package/lib/module/presentation/domain/offline/use-offline-id.js +11 -0
- package/lib/module/presentation/domain/offline/use-offline-id.js.map +1 -0
- package/lib/module/presentation/domain/offline/use-offline-mutation.js +115 -0
- package/lib/module/presentation/domain/offline/use-offline-mutation.js.map +1 -0
- package/lib/module/presentation/domain/offline/use-offline-query.js +33 -0
- package/lib/module/presentation/domain/offline/use-offline-query.js.map +1 -0
- package/lib/module/presentation/domain/offline/use-offline-queue.js +8 -0
- package/lib/module/presentation/domain/offline/use-offline-queue.js.map +1 -0
- package/lib/module/presentation/domain/offline/utils.js +110 -0
- package/lib/module/presentation/domain/offline/utils.js.map +1 -0
- package/lib/module/presentation/domain/provider/index.js +4 -0
- package/lib/module/presentation/domain/provider/index.js.map +1 -0
- package/lib/module/presentation/domain/provider/zuq-core-provider.js +51 -0
- package/lib/module/presentation/domain/provider/zuq-core-provider.js.map +1 -0
- package/lib/module/presentation/domain/utils/exists.js +6 -0
- package/lib/module/presentation/domain/utils/exists.js.map +1 -0
- package/lib/module/presentation/domain/utils/index.js +8 -0
- package/lib/module/presentation/domain/utils/index.js.map +1 -0
- package/lib/module/presentation/domain/utils/react-query.js +10 -0
- package/lib/module/presentation/domain/utils/react-query.js.map +1 -0
- package/lib/module/presentation/domain/utils/use-action-sheet.js +20 -0
- package/lib/module/presentation/domain/utils/use-action-sheet.js.map +1 -0
- package/lib/module/presentation/domain/utils/use-signature-ref.js +8 -0
- package/lib/module/presentation/domain/utils/use-signature-ref.js.map +1 -0
- package/lib/module/presentation/domain/utils/yup.js +5 -0
- package/lib/module/presentation/domain/utils/yup.js.map +1 -0
- package/lib/module/theme.js +211 -0
- package/lib/module/theme.js.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/src/data/errors/http-client-error.d.ts +13 -0
- package/lib/typescript/src/data/errors/http-client-error.d.ts.map +1 -0
- package/lib/typescript/src/data/errors/index.d.ts +4 -0
- package/lib/typescript/src/data/errors/index.d.ts.map +1 -0
- package/lib/typescript/src/data/errors/save-file-error.d.ts +4 -0
- package/lib/typescript/src/data/errors/save-file-error.d.ts.map +1 -0
- package/lib/typescript/src/data/errors/unsupported-platform.d.ts +4 -0
- package/lib/typescript/src/data/errors/unsupported-platform.d.ts.map +1 -0
- package/lib/typescript/src/data/models/index.d.ts +4 -0
- package/lib/typescript/src/data/models/index.d.ts.map +1 -0
- package/lib/typescript/src/data/models/remote-get-comment-list-model.d.ts +16 -0
- package/lib/typescript/src/data/models/remote-get-comment-list-model.d.ts.map +1 -0
- package/lib/typescript/src/data/models/remote-get-image-list-model.d.ts +16 -0
- package/lib/typescript/src/data/models/remote-get-image-list-model.d.ts.map +1 -0
- package/lib/typescript/src/data/models/remote-user-model.d.ts +14 -0
- package/lib/typescript/src/data/models/remote-user-model.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/cookie-manager.d.ts +7 -0
- package/lib/typescript/src/data/protocols/cookie-manager.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/download-manager.d.ts +12 -0
- package/lib/typescript/src/data/protocols/download-manager.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/http-client.d.ts +52 -0
- package/lib/typescript/src/data/protocols/http-client.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/index.d.ts +7 -0
- package/lib/typescript/src/data/protocols/index.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/notification-manager.d.ts +17 -0
- package/lib/typescript/src/data/protocols/notification-manager.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/permission-manager.d.ts +23 -0
- package/lib/typescript/src/data/protocols/permission-manager.d.ts.map +1 -0
- package/lib/typescript/src/data/protocols/storage.d.ts +17 -0
- package/lib/typescript/src/data/protocols/storage.d.ts.map +1 -0
- package/lib/typescript/src/data/use-cases/index.d.ts +4 -0
- package/lib/typescript/src/data/use-cases/index.d.ts.map +1 -0
- package/lib/typescript/src/data/use-cases/remote-get-comment-list.d.ts +9 -0
- package/lib/typescript/src/data/use-cases/remote-get-comment-list.d.ts.map +1 -0
- package/lib/typescript/src/data/use-cases/remote-get-image-list.d.ts +10 -0
- package/lib/typescript/src/data/use-cases/remote-get-image-list.d.ts.map +1 -0
- package/lib/typescript/src/data/use-cases/remote-send-diagnostics.d.ts +11 -0
- package/lib/typescript/src/data/use-cases/remote-send-diagnostics.d.ts.map +1 -0
- package/lib/typescript/src/domain/errors/authentication-expired-error.d.ts +4 -0
- package/lib/typescript/src/domain/errors/authentication-expired-error.d.ts.map +1 -0
- package/lib/typescript/src/domain/errors/index.d.ts +5 -0
- package/lib/typescript/src/domain/errors/index.d.ts.map +1 -0
- package/lib/typescript/src/domain/errors/internal-server-error.d.ts +4 -0
- package/lib/typescript/src/domain/errors/internal-server-error.d.ts.map +1 -0
- package/lib/typescript/src/domain/errors/invalid-credentials-error.d.ts +4 -0
- package/lib/typescript/src/domain/errors/invalid-credentials-error.d.ts.map +1 -0
- package/lib/typescript/src/domain/errors/no-app-permission-error.d.ts +4 -0
- package/lib/typescript/src/domain/errors/no-app-permission-error.d.ts.map +1 -0
- package/lib/typescript/src/domain/models/get-comment-list-model.d.ts +10 -0
- package/lib/typescript/src/domain/models/get-comment-list-model.d.ts.map +1 -0
- package/lib/typescript/src/domain/models/get-image-list-model.d.ts +8 -0
- package/lib/typescript/src/domain/models/get-image-list-model.d.ts.map +1 -0
- package/lib/typescript/src/domain/models/index.d.ts +4 -0
- package/lib/typescript/src/domain/models/index.d.ts.map +1 -0
- package/lib/typescript/src/domain/models/user-model.d.ts +16 -0
- package/lib/typescript/src/domain/models/user-model.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/get-comment-list.d.ts +12 -0
- package/lib/typescript/src/domain/use-cases/get-comment-list.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/get-image-list.d.ts +12 -0
- package/lib/typescript/src/domain/use-cases/get-image-list.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/index.d.ts +7 -0
- package/lib/typescript/src/domain/use-cases/index.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/record-request.d.ts +14 -0
- package/lib/typescript/src/domain/use-cases/record-request.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/send-diagnostics.d.ts +15 -0
- package/lib/typescript/src/domain/use-cases/send-diagnostics.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/user-authentication.d.ts +12 -0
- package/lib/typescript/src/domain/use-cases/user-authentication.d.ts.map +1 -0
- package/lib/typescript/src/domain/use-cases/user-logout.d.ts +10 -0
- package/lib/typescript/src/domain/use-cases/user-logout.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +15 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/infra/axios-http-client-adapter.d.ts +33 -0
- package/lib/typescript/src/infra/axios-http-client-adapter.d.ts.map +1 -0
- package/lib/typescript/src/infra/index.d.ts +8 -0
- package/lib/typescript/src/infra/index.d.ts.map +1 -0
- package/lib/typescript/src/infra/isomorphic-id-manager.d.ts +29 -0
- package/lib/typescript/src/infra/isomorphic-id-manager.d.ts.map +1 -0
- package/lib/typescript/src/infra/mmkv-storage-adapter.d.ts +18 -0
- package/lib/typescript/src/infra/mmkv-storage-adapter.d.ts.map +1 -0
- package/lib/typescript/src/infra/notifee-notification-manager-adapter.d.ts +17 -0
- package/lib/typescript/src/infra/notifee-notification-manager-adapter.d.ts.map +1 -0
- package/lib/typescript/src/infra/offline-mutation-queue.d.ts +56 -0
- package/lib/typescript/src/infra/offline-mutation-queue.d.ts.map +1 -0
- package/lib/typescript/src/infra/rnbu-download-manager-adapter.d.ts +7 -0
- package/lib/typescript/src/infra/rnbu-download-manager-adapter.d.ts.map +1 -0
- package/lib/typescript/src/infra/rnp-permission-manager-adapter.d.ts +20 -0
- package/lib/typescript/src/infra/rnp-permission-manager-adapter.d.ts.map +1 -0
- package/lib/typescript/src/infra/storage-cookie-manager-adapter.d.ts +12 -0
- package/lib/typescript/src/infra/storage-cookie-manager-adapter.d.ts.map +1 -0
- package/lib/typescript/src/main/components/index.d.ts +5 -0
- package/lib/typescript/src/main/components/index.d.ts.map +1 -0
- package/lib/typescript/src/main/components/request-permissions.d.ts +6 -0
- package/lib/typescript/src/main/components/request-permissions.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/download-manager-factory.d.ts +3 -0
- package/lib/typescript/src/main/factories/infra/download-manager-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/http-client-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/infra/http-client-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/index.d.ts +8 -0
- package/lib/typescript/src/main/factories/infra/index.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/isomorphic-id-manager-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/infra/isomorphic-id-manager-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/notification-manager-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/infra/notification-manager-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/offline-mutation-queue-factory.d.ts +5 -0
- package/lib/typescript/src/main/factories/infra/offline-mutation-queue-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/permission-manager-factory.d.ts +3 -0
- package/lib/typescript/src/main/factories/infra/permission-manager-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/infra/storage-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/infra/storage-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/use-cases/index.d.ts +4 -0
- package/lib/typescript/src/main/factories/use-cases/index.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/use-cases/remote-get-comment-list-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/use-cases/remote-get-comment-list-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/use-cases/remote-get-image-list-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/use-cases/remote-get-image-list-factory.d.ts.map +1 -0
- package/lib/typescript/src/main/factories/use-cases/remote-send-diagnostics-factory.d.ts +4 -0
- package/lib/typescript/src/main/factories/use-cases/remote-send-diagnostics-factory.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIBackdrop.d.ts +10 -0
- package/lib/typescript/src/presentation/components/atoms/UIBackdrop.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UICheckbox.d.ts +11 -0
- package/lib/typescript/src/presentation/components/atoms/UICheckbox.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIDot.d.ts +10 -0
- package/lib/typescript/src/presentation/components/atoms/UIDot.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIIcon.d.ts +133 -0
- package/lib/typescript/src/presentation/components/atoms/UIIcon.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UILoading.d.ts +9 -0
- package/lib/typescript/src/presentation/components/atoms/UILoading.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIPage.d.ts +20 -0
- package/lib/typescript/src/presentation/components/atoms/UIPage.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIProgress.d.ts +10 -0
- package/lib/typescript/src/presentation/components/atoms/UIProgress.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIScrollPage.d.ts +17 -0
- package/lib/typescript/src/presentation/components/atoms/UIScrollPage.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UISeparator.d.ts +10 -0
- package/lib/typescript/src/presentation/components/atoms/UISeparator.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UISpacer.d.ts +9 -0
- package/lib/typescript/src/presentation/components/atoms/UISpacer.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIStack.d.ts +14 -0
- package/lib/typescript/src/presentation/components/atoms/UIStack.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/UIText.d.ts +14 -0
- package/lib/typescript/src/presentation/components/atoms/UIText.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/atoms/index.d.ts +13 -0
- package/lib/typescript/src/presentation/components/atoms/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/index.d.ts +2 -0
- package/lib/typescript/src/presentation/components/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIActionSheet.d.ts +17 -0
- package/lib/typescript/src/presentation/components/molecules/UIActionSheet.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIButton.d.ts +18 -0
- package/lib/typescript/src/presentation/components/molecules/UIButton.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIButtonCTA.d.ts +8 -0
- package/lib/typescript/src/presentation/components/molecules/UIButtonCTA.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UICheckboxInput.d.ts +16 -0
- package/lib/typescript/src/presentation/components/molecules/UICheckboxInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIChip.d.ts +17 -0
- package/lib/typescript/src/presentation/components/molecules/UIChip.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UICurrencyInput.d.ts +11 -0
- package/lib/typescript/src/presentation/components/molecules/UICurrencyInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIDataList.d.ts +9 -0
- package/lib/typescript/src/presentation/components/molecules/UIDataList.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIDataSectionList.d.ts +9 -0
- package/lib/typescript/src/presentation/components/molecules/UIDataSectionList.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIDatetimeInput.d.ts +10 -0
- package/lib/typescript/src/presentation/components/molecules/UIDatetimeInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIError.d.ts +8 -0
- package/lib/typescript/src/presentation/components/molecules/UIError.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIImage.d.ts +11 -0
- package/lib/typescript/src/presentation/components/molecules/UIImage.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIInlineDatePicker.d.ts +15 -0
- package/lib/typescript/src/presentation/components/molecules/UIInlineDatePicker.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIInputIcon.d.ts +9 -0
- package/lib/typescript/src/presentation/components/molecules/UIInputIcon.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIList.d.ts +5 -0
- package/lib/typescript/src/presentation/components/molecules/UIList.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UIRadioInput.d.ts +12 -0
- package/lib/typescript/src/presentation/components/molecules/UIRadioInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UISectionList.d.ts +5 -0
- package/lib/typescript/src/presentation/components/molecules/UISectionList.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UISkeleton.d.ts +8 -0
- package/lib/typescript/src/presentation/components/molecules/UISkeleton.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UISwitch.d.ts +10 -0
- package/lib/typescript/src/presentation/components/molecules/UISwitch.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UITextInput.d.ts +13 -0
- package/lib/typescript/src/presentation/components/molecules/UITextInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/UITextInputMask.d.ts +16 -0
- package/lib/typescript/src/presentation/components/molecules/UITextInputMask.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/molecules/index.d.ts +21 -0
- package/lib/typescript/src/presentation/components/molecules/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIAppBar.d.ts +13 -0
- package/lib/typescript/src/presentation/components/organisms/UIAppBar.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIAppBarAction.d.ts +6 -0
- package/lib/typescript/src/presentation/components/organisms/UIAppBarAction.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UICard.d.ts +9 -0
- package/lib/typescript/src/presentation/components/organisms/UICard.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIComment.d.ts +9 -0
- package/lib/typescript/src/presentation/components/organisms/UIComment.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIErrorBoundary.d.ts +9 -0
- package/lib/typescript/src/presentation/components/organisms/UIErrorBoundary.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIForm.d.ts +13 -0
- package/lib/typescript/src/presentation/components/organisms/UIForm.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormButton.d.ts +11 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormButton.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormCheckboxInput.d.ts +9 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormCheckboxInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormCurrencyInput.d.ts +11 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormCurrencyInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormDatetimeInput.d.ts +10 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormDatetimeInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormMultiselectInput.d.ts +30 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormMultiselectInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormRadioInput.d.ts +9 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormRadioInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormSelectInput.d.ts +44 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormSelectInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormTextInput.d.ts +11 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormTextInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormTextInputMask.d.ts +11 -0
- package/lib/typescript/src/presentation/components/organisms/UIFormTextInputMask.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UIRow.d.ts +14 -0
- package/lib/typescript/src/presentation/components/organisms/UIRow.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UISearchInput.d.ts +6 -0
- package/lib/typescript/src/presentation/components/organisms/UISearchInput.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UISelectChip.d.ts +13 -0
- package/lib/typescript/src/presentation/components/organisms/UISelectChip.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UISignature.d.ts +26 -0
- package/lib/typescript/src/presentation/components/organisms/UISignature.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/UISlideButton.d.ts +8 -0
- package/lib/typescript/src/presentation/components/organisms/UISlideButton.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/organisms/index.d.ts +22 -0
- package/lib/typescript/src/presentation/components/organisms/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/permissions/index.d.ts +2 -0
- package/lib/typescript/src/presentation/components/permissions/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/components/permissions/request-permissions.d.ts +15 -0
- package/lib/typescript/src/presentation/components/permissions/request-permissions.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/metadata/index.d.ts +3 -0
- package/lib/typescript/src/presentation/domain/metadata/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/metadata/use-comments.d.ts +11 -0
- package/lib/typescript/src/presentation/domain/metadata/use-comments.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/metadata/use-images.d.ts +11 -0
- package/lib/typescript/src/presentation/domain/metadata/use-images.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/index.d.ts +10 -0
- package/lib/typescript/src/presentation/domain/offline/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/offline-mutation-queue-provider.d.ts +18 -0
- package/lib/typescript/src/presentation/domain/offline/offline-mutation-queue-provider.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/types.d.ts +18 -0
- package/lib/typescript/src/presentation/domain/offline/types.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/use-infinite-offline-query.d.ts +78 -0
- package/lib/typescript/src/presentation/domain/offline/use-infinite-offline-query.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-id-v2.d.ts +9 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-id-v2.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-id.d.ts +3 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-id.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-mutation.d.ts +88 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-mutation.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-query.d.ts +8 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-query.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-queue.d.ts +10 -0
- package/lib/typescript/src/presentation/domain/offline/use-offline-queue.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/offline/utils.d.ts +18 -0
- package/lib/typescript/src/presentation/domain/offline/utils.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/provider/index.d.ts +2 -0
- package/lib/typescript/src/presentation/domain/provider/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/provider/zuq-core-provider.d.ts +13 -0
- package/lib/typescript/src/presentation/domain/provider/zuq-core-provider.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/utils/exists.d.ts +2 -0
- package/lib/typescript/src/presentation/domain/utils/exists.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/utils/index.d.ts +6 -0
- package/lib/typescript/src/presentation/domain/utils/index.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/utils/react-query.d.ts +5 -0
- package/lib/typescript/src/presentation/domain/utils/react-query.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/utils/use-action-sheet.d.ts +6 -0
- package/lib/typescript/src/presentation/domain/utils/use-action-sheet.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/utils/use-signature-ref.d.ts +15 -0
- package/lib/typescript/src/presentation/domain/utils/use-signature-ref.d.ts.map +1 -0
- package/lib/typescript/src/presentation/domain/utils/yup.d.ts +3 -0
- package/lib/typescript/src/presentation/domain/utils/yup.d.ts.map +1 -0
- package/lib/typescript/src/theme.d.ts +214 -0
- package/lib/typescript/src/theme.d.ts.map +1 -0
- package/package.json +210 -0
- package/src/assets/logo.png +0 -0
- package/src/data/errors/http-client-error.ts +23 -0
- package/src/data/errors/index.ts +3 -0
- package/src/data/errors/save-file-error.ts +6 -0
- package/src/data/errors/unsupported-platform.ts +6 -0
- package/src/data/models/index.ts +3 -0
- package/src/data/models/remote-get-comment-list-model.ts +15 -0
- package/src/data/models/remote-get-image-list-model.ts +15 -0
- package/src/data/models/remote-user-model.ts +13 -0
- package/src/data/protocols/cookie-manager.ts +6 -0
- package/src/data/protocols/download-manager.ts +13 -0
- package/src/data/protocols/http-client.ts +75 -0
- package/src/data/protocols/index.ts +6 -0
- package/src/data/protocols/notification-manager.ts +17 -0
- package/src/data/protocols/permission-manager.ts +46 -0
- package/src/data/protocols/storage.ts +18 -0
- package/src/data/use-cases/index.ts +3 -0
- package/src/data/use-cases/remote-get-comment-list.ts +34 -0
- package/src/data/use-cases/remote-get-image-list.ts +40 -0
- package/src/data/use-cases/remote-send-diagnostics.ts +20 -0
- package/src/domain/errors/authentication-expired-error.ts +6 -0
- package/src/domain/errors/index.ts +4 -0
- package/src/domain/errors/internal-server-error.ts +6 -0
- package/src/domain/errors/invalid-credentials-error.ts +6 -0
- package/src/domain/errors/no-app-permission-error.ts +6 -0
- package/src/domain/models/get-comment-list-model.ts +9 -0
- package/src/domain/models/get-image-list-model.ts +7 -0
- package/src/domain/models/index.ts +3 -0
- package/src/domain/models/user-model.ts +15 -0
- package/src/domain/use-cases/get-comment-list.ts +14 -0
- package/src/domain/use-cases/get-image-list.ts +14 -0
- package/src/domain/use-cases/index.ts +6 -0
- package/src/domain/use-cases/record-request.ts +15 -0
- package/src/domain/use-cases/send-diagnostics.ts +15 -0
- package/src/domain/use-cases/user-authentication.ts +16 -0
- package/src/domain/use-cases/user-logout.ts +10 -0
- package/src/index.tsx +29 -0
- package/src/infra/axios-http-client-adapter.ts +271 -0
- package/src/infra/index.ts +7 -0
- package/src/infra/isomorphic-id-manager.ts +107 -0
- package/src/infra/mmkv-storage-adapter.ts +73 -0
- package/src/infra/notifee-notification-manager-adapter.ts +87 -0
- package/src/infra/offline-mutation-queue.ts +280 -0
- package/src/infra/rnbu-download-manager-adapter.ts +29 -0
- package/src/infra/rnp-permission-manager-adapter.ts +147 -0
- package/src/infra/storage-cookie-manager-adapter.ts +29 -0
- package/src/main/components/index.ts +4 -0
- package/src/main/components/request-permissions.tsx +17 -0
- package/src/main/factories/infra/download-manager-factory.ts +6 -0
- package/src/main/factories/infra/http-client-factory.ts +9 -0
- package/src/main/factories/infra/index.ts +7 -0
- package/src/main/factories/infra/isomorphic-id-manager-factory.ts +6 -0
- package/src/main/factories/infra/notification-manager-factory.ts +8 -0
- package/src/main/factories/infra/offline-mutation-queue-factory.ts +22 -0
- package/src/main/factories/infra/permission-manager-factory.ts +6 -0
- package/src/main/factories/infra/storage-factory.ts +11 -0
- package/src/main/factories/use-cases/index.ts +3 -0
- package/src/main/factories/use-cases/remote-get-comment-list-factory.ts +6 -0
- package/src/main/factories/use-cases/remote-get-image-list-factory.ts +6 -0
- package/src/main/factories/use-cases/remote-send-diagnostics-factory.ts +10 -0
- package/src/presentation/components/atoms/UIBackdrop.tsx +35 -0
- package/src/presentation/components/atoms/UICheckbox.tsx +58 -0
- package/src/presentation/components/atoms/UIDot.tsx +40 -0
- package/src/presentation/components/atoms/UIIcon.tsx +1091 -0
- package/src/presentation/components/atoms/UILoading.tsx +17 -0
- package/src/presentation/components/atoms/UIPage.tsx +92 -0
- package/src/presentation/components/atoms/UIProgress.tsx +60 -0
- package/src/presentation/components/atoms/UIScrollPage.tsx +87 -0
- package/src/presentation/components/atoms/UISeparator.tsx +41 -0
- package/src/presentation/components/atoms/UISpacer.tsx +21 -0
- package/src/presentation/components/atoms/UIStack.tsx +44 -0
- package/src/presentation/components/atoms/UIText.tsx +59 -0
- package/src/presentation/components/atoms/index.ts +12 -0
- package/src/presentation/components/index.ts +1 -0
- package/src/presentation/components/molecules/UIActionSheet.tsx +230 -0
- package/src/presentation/components/molecules/UIButton.tsx +192 -0
- package/src/presentation/components/molecules/UIButtonCTA.tsx +38 -0
- package/src/presentation/components/molecules/UICheckboxInput.tsx +106 -0
- package/src/presentation/components/molecules/UIChip.tsx +69 -0
- package/src/presentation/components/molecules/UICurrencyInput.tsx +43 -0
- package/src/presentation/components/molecules/UIDataList.tsx +30 -0
- package/src/presentation/components/molecules/UIDataSectionList.tsx +30 -0
- package/src/presentation/components/molecules/UIDatetimeInput.tsx +205 -0
- package/src/presentation/components/molecules/UIError.tsx +24 -0
- package/src/presentation/components/molecules/UIImage.tsx +85 -0
- package/src/presentation/components/molecules/UIInlineDatePicker.tsx +244 -0
- package/src/presentation/components/molecules/UIInputIcon.tsx +39 -0
- package/src/presentation/components/molecules/UIList.tsx +17 -0
- package/src/presentation/components/molecules/UIRadioInput.tsx +97 -0
- package/src/presentation/components/molecules/UISectionList.tsx +17 -0
- package/src/presentation/components/molecules/UISkeleton.tsx +66 -0
- package/src/presentation/components/molecules/UISwitch.tsx +72 -0
- package/src/presentation/components/molecules/UITextInput.tsx +160 -0
- package/src/presentation/components/molecules/UITextInputMask.tsx +160 -0
- package/src/presentation/components/molecules/index.ts +20 -0
- package/src/presentation/components/organisms/UIAppBar.tsx +103 -0
- package/src/presentation/components/organisms/UIAppBarAction.tsx +13 -0
- package/src/presentation/components/organisms/UICard.tsx +48 -0
- package/src/presentation/components/organisms/UIComment.tsx +64 -0
- package/src/presentation/components/organisms/UIErrorBoundary.tsx +72 -0
- package/src/presentation/components/organisms/UIForm.tsx +81 -0
- package/src/presentation/components/organisms/UIFormButton.tsx +38 -0
- package/src/presentation/components/organisms/UIFormCheckboxInput.tsx +35 -0
- package/src/presentation/components/organisms/UIFormCurrencyInput.tsx +65 -0
- package/src/presentation/components/organisms/UIFormDatetimeInput.tsx +51 -0
- package/src/presentation/components/organisms/UIFormMultiselectInput.tsx +251 -0
- package/src/presentation/components/organisms/UIFormRadioInput.tsx +32 -0
- package/src/presentation/components/organisms/UIFormSelectInput.tsx +316 -0
- package/src/presentation/components/organisms/UIFormTextInput.tsx +62 -0
- package/src/presentation/components/organisms/UIFormTextInputMask.tsx +79 -0
- package/src/presentation/components/organisms/UIRow.tsx +61 -0
- package/src/presentation/components/organisms/UISearchInput.tsx +40 -0
- package/src/presentation/components/organisms/UISelectChip.tsx +104 -0
- package/src/presentation/components/organisms/UISignature.tsx +194 -0
- package/src/presentation/components/organisms/UISlideButton.tsx +112 -0
- package/src/presentation/components/organisms/index.ts +21 -0
- package/src/presentation/components/permissions/index.ts +1 -0
- package/src/presentation/components/permissions/request-permissions.tsx +115 -0
- package/src/presentation/domain/metadata/index.ts +2 -0
- package/src/presentation/domain/metadata/use-comments.ts +27 -0
- package/src/presentation/domain/metadata/use-images.ts +27 -0
- package/src/presentation/domain/offline/index.ts +9 -0
- package/src/presentation/domain/offline/offline-mutation-queue-provider.tsx +95 -0
- package/src/presentation/domain/offline/types.ts +21 -0
- package/src/presentation/domain/offline/use-infinite-offline-query.tsx +89 -0
- package/src/presentation/domain/offline/use-offline-id-v2.ts +29 -0
- package/src/presentation/domain/offline/use-offline-id.ts +12 -0
- package/src/presentation/domain/offline/use-offline-mutation.ts +150 -0
- package/src/presentation/domain/offline/use-offline-query.ts +55 -0
- package/src/presentation/domain/offline/use-offline-queue.ts +6 -0
- package/src/presentation/domain/offline/utils.ts +139 -0
- package/src/presentation/domain/provider/index.ts +1 -0
- package/src/presentation/domain/provider/zuq-core-provider.tsx +52 -0
- package/src/presentation/domain/utils/exists.ts +3 -0
- package/src/presentation/domain/utils/index.ts +5 -0
- package/src/presentation/domain/utils/react-query.ts +10 -0
- package/src/presentation/domain/utils/use-action-sheet.ts +21 -0
- package/src/presentation/domain/utils/use-signature-ref.ts +19 -0
- package/src/presentation/domain/utils/yup.ts +3 -0
- package/src/theme.ts +240 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ActivityIndicator } from 'react-native';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { getThemeColor, type ThemeColor } from '../../../theme';
|
|
4
|
+
|
|
5
|
+
type Props = React.ComponentProps<typeof ActivityIndicator> & {
|
|
6
|
+
color?: ThemeColor;
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
export const UILoading = ({
|
|
10
|
+
color: themeColor = 'brand-violet-500',
|
|
11
|
+
size = 32,
|
|
12
|
+
...props
|
|
13
|
+
}: Props) => {
|
|
14
|
+
const color = getThemeColor(themeColor);
|
|
15
|
+
|
|
16
|
+
return <ActivityIndicator color={color} size={size} {...props} />;
|
|
17
|
+
};
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { StatusBar as RNStatusBar, StyleSheet } from 'react-native';
|
|
3
|
+
import type { ColorValue, StatusBarStyle } from 'react-native';
|
|
4
|
+
import { KeyboardAvoidingView } from 'react-native-keyboard-controller';
|
|
5
|
+
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
6
|
+
import { UIStack } from './UIStack';
|
|
7
|
+
import { theme } from '../../../theme';
|
|
8
|
+
|
|
9
|
+
export type StatusBar = {
|
|
10
|
+
color?: string;
|
|
11
|
+
style?: StatusBarStyle;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
type Props = Omit<
|
|
15
|
+
React.ComponentProps<typeof KeyboardAvoidingView>,
|
|
16
|
+
'contentContainerStyle'
|
|
17
|
+
> & {
|
|
18
|
+
fullWidth?: boolean;
|
|
19
|
+
center?: boolean;
|
|
20
|
+
dark?: boolean;
|
|
21
|
+
background?: ColorValue;
|
|
22
|
+
statusBar?: StatusBar;
|
|
23
|
+
children?: React.ReactNode;
|
|
24
|
+
appBar?: React.ReactNode;
|
|
25
|
+
behavior?: 'height' | 'padding';
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export const UIPage = ({
|
|
29
|
+
children,
|
|
30
|
+
fullWidth,
|
|
31
|
+
center,
|
|
32
|
+
dark,
|
|
33
|
+
style,
|
|
34
|
+
background = '#fff',
|
|
35
|
+
statusBar = {
|
|
36
|
+
color: '#fff',
|
|
37
|
+
style: 'dark-content',
|
|
38
|
+
},
|
|
39
|
+
appBar,
|
|
40
|
+
...props
|
|
41
|
+
}: Props) => {
|
|
42
|
+
const insets = useSafeAreaInsets();
|
|
43
|
+
|
|
44
|
+
const hasHorizontalInset = Boolean(insets.left) || Boolean(insets.right);
|
|
45
|
+
|
|
46
|
+
React.useEffect(() => {
|
|
47
|
+
const stackEntry = RNStatusBar.pushStackEntry({
|
|
48
|
+
backgroundColor: statusBar.color,
|
|
49
|
+
barStyle: statusBar.style,
|
|
50
|
+
});
|
|
51
|
+
return () => {
|
|
52
|
+
if (stackEntry) RNStatusBar.popStackEntry(stackEntry);
|
|
53
|
+
};
|
|
54
|
+
}, [statusBar.color, statusBar.style]);
|
|
55
|
+
|
|
56
|
+
return (
|
|
57
|
+
<UIStack
|
|
58
|
+
spacing={0}
|
|
59
|
+
flex={1}
|
|
60
|
+
style={{
|
|
61
|
+
paddingTop: insets.top,
|
|
62
|
+
}}
|
|
63
|
+
>
|
|
64
|
+
{appBar}
|
|
65
|
+
<KeyboardAvoidingView
|
|
66
|
+
behavior="padding"
|
|
67
|
+
style={[
|
|
68
|
+
styles.page,
|
|
69
|
+
center && styles.center,
|
|
70
|
+
!fullWidth && styles.withPadding,
|
|
71
|
+
dark && styles.dark,
|
|
72
|
+
hasHorizontalInset && {
|
|
73
|
+
paddingHorizontal: insets.left || insets.right,
|
|
74
|
+
},
|
|
75
|
+
{ paddingBottom: Math.max(insets.bottom, 32) },
|
|
76
|
+
!dark && { backgroundColor: background },
|
|
77
|
+
style,
|
|
78
|
+
]}
|
|
79
|
+
{...props}
|
|
80
|
+
>
|
|
81
|
+
{children}
|
|
82
|
+
</KeyboardAvoidingView>
|
|
83
|
+
</UIStack>
|
|
84
|
+
);
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
const styles = StyleSheet.create({
|
|
88
|
+
page: { flex: 1, backgroundColor: '#fff' },
|
|
89
|
+
center: { justifyContent: 'center' },
|
|
90
|
+
withPadding: { paddingHorizontal: 24 },
|
|
91
|
+
dark: { backgroundColor: theme.color.brand.violet['500'] },
|
|
92
|
+
});
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { StyleSheet, View, type StyleProp, type ViewStyle } from 'react-native';
|
|
3
|
+
import { theme } from '../../../theme';
|
|
4
|
+
import Animated, {
|
|
5
|
+
useAnimatedStyle,
|
|
6
|
+
useSharedValue,
|
|
7
|
+
withTiming,
|
|
8
|
+
} from 'react-native-reanimated';
|
|
9
|
+
|
|
10
|
+
type Props = {
|
|
11
|
+
progress: number;
|
|
12
|
+
outerStyle?: StyleProp<ViewStyle>;
|
|
13
|
+
innerStyle?: StyleProp<ViewStyle>;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export const UIProgress = React.memo(
|
|
17
|
+
({ progress, innerStyle, outerStyle }: Props) => {
|
|
18
|
+
const [width, setWidth] = React.useState(0);
|
|
19
|
+
const progressValue = useSharedValue(progress);
|
|
20
|
+
const animatedStyles = useAnimatedStyle(() => ({
|
|
21
|
+
transform: [{ translateX: -width * (1 - progressValue.value) }],
|
|
22
|
+
}));
|
|
23
|
+
|
|
24
|
+
React.useEffect(() => {
|
|
25
|
+
progressValue.value = withTiming(progress);
|
|
26
|
+
}, [progress, progressValue]);
|
|
27
|
+
|
|
28
|
+
return (
|
|
29
|
+
<View style={styles.wrapper}>
|
|
30
|
+
<View
|
|
31
|
+
onLayout={(e) => setWidth(e.nativeEvent.layout.width)}
|
|
32
|
+
style={[styles.outer, outerStyle]}
|
|
33
|
+
>
|
|
34
|
+
<Animated.View style={[styles.inner, animatedStyles, innerStyle]} />
|
|
35
|
+
</View>
|
|
36
|
+
</View>
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
);
|
|
40
|
+
|
|
41
|
+
const styles = StyleSheet.create({
|
|
42
|
+
wrapper: {
|
|
43
|
+
flex: 1,
|
|
44
|
+
flexDirection: 'row',
|
|
45
|
+
},
|
|
46
|
+
outer: {
|
|
47
|
+
flex: 1,
|
|
48
|
+
position: 'relative',
|
|
49
|
+
overflow: 'hidden',
|
|
50
|
+
backgroundColor: theme.color.neutral.light['50'],
|
|
51
|
+
height: 4,
|
|
52
|
+
borderRadius: 2,
|
|
53
|
+
},
|
|
54
|
+
inner: {
|
|
55
|
+
position: 'absolute',
|
|
56
|
+
backgroundColor: theme.color.brand.violet['500'],
|
|
57
|
+
height: 4,
|
|
58
|
+
width: '100%',
|
|
59
|
+
},
|
|
60
|
+
});
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { StatusBar as RNStatusBar, StyleSheet } from 'react-native';
|
|
3
|
+
import type { ColorValue } from 'react-native';
|
|
4
|
+
import { KeyboardAwareScrollView } from 'react-native-keyboard-controller';
|
|
5
|
+
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
6
|
+
import { UIStack } from './UIStack';
|
|
7
|
+
import { theme } from '../../../theme';
|
|
8
|
+
import type { StatusBar } from './UIPage';
|
|
9
|
+
|
|
10
|
+
type Props = React.ComponentProps<typeof KeyboardAwareScrollView> & {
|
|
11
|
+
fullWidth?: boolean;
|
|
12
|
+
center?: boolean;
|
|
13
|
+
dark?: boolean;
|
|
14
|
+
background?: ColorValue;
|
|
15
|
+
statusBar?: StatusBar;
|
|
16
|
+
children?: React.ReactNode;
|
|
17
|
+
appBar?: React.ReactNode;
|
|
18
|
+
behavior?: 'height' | 'padding';
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export const UIScrollPage = ({
|
|
22
|
+
children,
|
|
23
|
+
fullWidth,
|
|
24
|
+
center,
|
|
25
|
+
dark,
|
|
26
|
+
style,
|
|
27
|
+
background = '#fff',
|
|
28
|
+
statusBar = {
|
|
29
|
+
color: '#fff',
|
|
30
|
+
style: 'dark-content',
|
|
31
|
+
},
|
|
32
|
+
appBar,
|
|
33
|
+
keyboardShouldPersistTaps = 'handled',
|
|
34
|
+
...props
|
|
35
|
+
}: Props) => {
|
|
36
|
+
const insets = useSafeAreaInsets();
|
|
37
|
+
|
|
38
|
+
const hasHorizontalInset = Boolean(insets.left) || Boolean(insets.right);
|
|
39
|
+
|
|
40
|
+
React.useEffect(() => {
|
|
41
|
+
const stackEntry = RNStatusBar.pushStackEntry({
|
|
42
|
+
backgroundColor: statusBar.color,
|
|
43
|
+
barStyle: statusBar.style,
|
|
44
|
+
});
|
|
45
|
+
return () => {
|
|
46
|
+
if (stackEntry) RNStatusBar.popStackEntry(stackEntry);
|
|
47
|
+
};
|
|
48
|
+
}, [statusBar.color, statusBar.style]);
|
|
49
|
+
|
|
50
|
+
return (
|
|
51
|
+
<UIStack
|
|
52
|
+
spacing={0}
|
|
53
|
+
flex={1}
|
|
54
|
+
style={{
|
|
55
|
+
paddingTop: insets.top,
|
|
56
|
+
}}
|
|
57
|
+
>
|
|
58
|
+
{appBar}
|
|
59
|
+
<KeyboardAwareScrollView
|
|
60
|
+
behavior="padding"
|
|
61
|
+
style={[
|
|
62
|
+
styles.page,
|
|
63
|
+
center && styles.center,
|
|
64
|
+
!fullWidth && styles.withPadding,
|
|
65
|
+
dark && styles.dark,
|
|
66
|
+
hasHorizontalInset && {
|
|
67
|
+
paddingHorizontal: insets.left || insets.right,
|
|
68
|
+
},
|
|
69
|
+
{ paddingBottom: Math.max(insets.bottom, 32) },
|
|
70
|
+
!dark && { backgroundColor: background },
|
|
71
|
+
style,
|
|
72
|
+
]}
|
|
73
|
+
keyboardShouldPersistTaps={keyboardShouldPersistTaps}
|
|
74
|
+
{...props}
|
|
75
|
+
>
|
|
76
|
+
{children}
|
|
77
|
+
</KeyboardAwareScrollView>
|
|
78
|
+
</UIStack>
|
|
79
|
+
);
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
const styles = StyleSheet.create({
|
|
83
|
+
page: { flex: 1, backgroundColor: '#fff' },
|
|
84
|
+
center: { justifyContent: 'center' },
|
|
85
|
+
withPadding: { paddingHorizontal: 24 },
|
|
86
|
+
dark: { backgroundColor: theme.color.brand.violet['500'] },
|
|
87
|
+
});
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { StyleSheet, View } from 'react-native';
|
|
3
|
+
import { getThemeColor, theme, type ThemeColor } from '../../../theme';
|
|
4
|
+
|
|
5
|
+
type Props = React.ComponentProps<typeof View> & {
|
|
6
|
+
horizontal?: boolean;
|
|
7
|
+
color?: ThemeColor;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export const UISeparator = ({
|
|
11
|
+
horizontal = true,
|
|
12
|
+
style,
|
|
13
|
+
color: themeColor,
|
|
14
|
+
...props
|
|
15
|
+
}: Props) => {
|
|
16
|
+
const color = getThemeColor(themeColor);
|
|
17
|
+
|
|
18
|
+
return (
|
|
19
|
+
<View
|
|
20
|
+
style={[
|
|
21
|
+
styles.separator,
|
|
22
|
+
{
|
|
23
|
+
[horizontal ? 'height' : 'width']: 1,
|
|
24
|
+
},
|
|
25
|
+
color && {
|
|
26
|
+
backgroundColor: color,
|
|
27
|
+
},
|
|
28
|
+
style,
|
|
29
|
+
]}
|
|
30
|
+
{...props}
|
|
31
|
+
/>
|
|
32
|
+
);
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
const styles = StyleSheet.create({
|
|
36
|
+
separator: {
|
|
37
|
+
alignSelf: 'stretch',
|
|
38
|
+
backgroundColor: theme.color.neutral.mid['60'],
|
|
39
|
+
opacity: 0.2,
|
|
40
|
+
},
|
|
41
|
+
});
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { View } from 'react-native';
|
|
2
|
+
import { theme } from '../../../theme';
|
|
3
|
+
import type { ThemeSpacing } from '../../../theme';
|
|
4
|
+
|
|
5
|
+
type Props = {
|
|
6
|
+
horizontal?: boolean;
|
|
7
|
+
size?: ThemeSpacing;
|
|
8
|
+
value?: number;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export const UISpacer = ({ value = 2, horizontal, size = 'sm' }: Props) => {
|
|
12
|
+
return (
|
|
13
|
+
<View
|
|
14
|
+
style={
|
|
15
|
+
horizontal
|
|
16
|
+
? { width: value * theme.spacing[size] }
|
|
17
|
+
: { height: value * theme.spacing[size] }
|
|
18
|
+
}
|
|
19
|
+
/>
|
|
20
|
+
);
|
|
21
|
+
};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { View, type ViewStyle } from 'react-native';
|
|
3
|
+
import { theme, type ThemeSpacing } from '../../../theme';
|
|
4
|
+
|
|
5
|
+
type Props = React.ComponentProps<typeof View> & {
|
|
6
|
+
horizontal?: boolean;
|
|
7
|
+
center?: boolean;
|
|
8
|
+
justify?: ViewStyle['justifyContent'];
|
|
9
|
+
size?: ThemeSpacing;
|
|
10
|
+
spacing?: number;
|
|
11
|
+
flex?: number;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const UIStack = ({
|
|
15
|
+
horizontal = false,
|
|
16
|
+
spacing = 2,
|
|
17
|
+
size = 'sm',
|
|
18
|
+
justify,
|
|
19
|
+
center,
|
|
20
|
+
style,
|
|
21
|
+
flex,
|
|
22
|
+
children,
|
|
23
|
+
...props
|
|
24
|
+
}: Props) => {
|
|
25
|
+
return (
|
|
26
|
+
<View
|
|
27
|
+
style={[
|
|
28
|
+
{
|
|
29
|
+
flexDirection: horizontal ? 'row' : 'column',
|
|
30
|
+
alignItems: center ? 'center' : 'stretch',
|
|
31
|
+
justifyContent: justify,
|
|
32
|
+
gap: theme.spacing[size] * spacing,
|
|
33
|
+
},
|
|
34
|
+
Boolean(flex) && {
|
|
35
|
+
flex,
|
|
36
|
+
},
|
|
37
|
+
style,
|
|
38
|
+
]}
|
|
39
|
+
{...props}
|
|
40
|
+
>
|
|
41
|
+
{children}
|
|
42
|
+
</View>
|
|
43
|
+
);
|
|
44
|
+
};
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { StyleSheet, Text } from 'react-native';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { TextStyle } from 'react-native';
|
|
4
|
+
import { getThemeColor, theme, type ThemeColor } from '../../../theme';
|
|
5
|
+
|
|
6
|
+
type Props = React.ComponentProps<typeof Text> & {
|
|
7
|
+
variant?: 'title' | 'subtitle' | 'body' | 'label';
|
|
8
|
+
color?: ThemeColor;
|
|
9
|
+
align?: TextStyle['textAlign'];
|
|
10
|
+
weight?: TextStyle['fontWeight'];
|
|
11
|
+
size?: TextStyle['fontSize'];
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const UIText = ({
|
|
15
|
+
children,
|
|
16
|
+
style,
|
|
17
|
+
variant = 'body',
|
|
18
|
+
color: themeColor = 'neutral-dark-80',
|
|
19
|
+
align = 'left',
|
|
20
|
+
size,
|
|
21
|
+
weight,
|
|
22
|
+
...props
|
|
23
|
+
}: Props) => {
|
|
24
|
+
if (['title', 'subtitle'].includes(variant) && !weight) weight = '600';
|
|
25
|
+
if (!weight) weight = 'normal';
|
|
26
|
+
|
|
27
|
+
const color = getThemeColor(themeColor);
|
|
28
|
+
|
|
29
|
+
return (
|
|
30
|
+
<Text
|
|
31
|
+
style={[
|
|
32
|
+
styles[variant],
|
|
33
|
+
color && { color },
|
|
34
|
+
align && { textAlign: align },
|
|
35
|
+
weight && { fontFamily: theme.font.weight[weight] },
|
|
36
|
+
Boolean(size) && {
|
|
37
|
+
fontSize: size,
|
|
38
|
+
},
|
|
39
|
+
style,
|
|
40
|
+
]}
|
|
41
|
+
{...props}
|
|
42
|
+
>
|
|
43
|
+
{children}
|
|
44
|
+
</Text>
|
|
45
|
+
);
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
const styles = StyleSheet.create({
|
|
49
|
+
title: {
|
|
50
|
+
fontSize: 26,
|
|
51
|
+
},
|
|
52
|
+
subtitle: { fontSize: 20 },
|
|
53
|
+
body: {
|
|
54
|
+
fontSize: 14,
|
|
55
|
+
},
|
|
56
|
+
label: {
|
|
57
|
+
fontSize: 14,
|
|
58
|
+
},
|
|
59
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export * from './UIPage';
|
|
2
|
+
export * from './UIText';
|
|
3
|
+
export * from './UISpacer';
|
|
4
|
+
export * from './UISeparator';
|
|
5
|
+
export * from './UIBackdrop';
|
|
6
|
+
export * from './UIDot';
|
|
7
|
+
export * from './UILoading';
|
|
8
|
+
export * from './UIIcon';
|
|
9
|
+
export * from './UIStack';
|
|
10
|
+
export * from './UIProgress';
|
|
11
|
+
export * from './UIScrollPage';
|
|
12
|
+
export * from './UICheckbox';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './permissions';
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { BackHandler, Keyboard, StyleSheet, View } from 'react-native';
|
|
3
|
+
import type { StyleProp, ViewStyle } from 'react-native';
|
|
4
|
+
import { Gesture, GestureDetector } from 'react-native-gesture-handler';
|
|
5
|
+
import { useReanimatedKeyboardAnimation } from 'react-native-keyboard-controller';
|
|
6
|
+
import Animated, {
|
|
7
|
+
Easing,
|
|
8
|
+
Extrapolation,
|
|
9
|
+
interpolate,
|
|
10
|
+
runOnJS,
|
|
11
|
+
useAnimatedStyle,
|
|
12
|
+
useDerivedValue,
|
|
13
|
+
useSharedValue,
|
|
14
|
+
withTiming,
|
|
15
|
+
} from 'react-native-reanimated';
|
|
16
|
+
import { Portal } from '@gorhom/portal';
|
|
17
|
+
|
|
18
|
+
import { UIBackdrop, UIIcon, UIStack, UIText } from '../atoms';
|
|
19
|
+
import { UIButton } from './UIButton';
|
|
20
|
+
import { theme } from '../../../theme';
|
|
21
|
+
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
22
|
+
|
|
23
|
+
type Props = {
|
|
24
|
+
visible: boolean;
|
|
25
|
+
title: string;
|
|
26
|
+
onRequestClose: () => void;
|
|
27
|
+
children?: React.ReactNode;
|
|
28
|
+
style?: StyleProp<ViewStyle>;
|
|
29
|
+
zIndexOffset?: number;
|
|
30
|
+
disabledKeyboardOffset?: boolean;
|
|
31
|
+
noPaddingBottom?: boolean;
|
|
32
|
+
estimatedHeight?: number;
|
|
33
|
+
getFullHeight?: (height: number) => void;
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
const ANIMATION_DURATION = 300;
|
|
37
|
+
|
|
38
|
+
const ANIMATION_OPTIONS = {
|
|
39
|
+
duration: ANIMATION_DURATION,
|
|
40
|
+
easing: Easing.out(Easing.cubic),
|
|
41
|
+
};
|
|
42
|
+
const NO_OFFSET = 0;
|
|
43
|
+
|
|
44
|
+
export const UIActionSheet = ({
|
|
45
|
+
visible,
|
|
46
|
+
title,
|
|
47
|
+
onRequestClose,
|
|
48
|
+
children,
|
|
49
|
+
zIndexOffset,
|
|
50
|
+
disabledKeyboardOffset,
|
|
51
|
+
noPaddingBottom = false,
|
|
52
|
+
estimatedHeight,
|
|
53
|
+
getFullHeight,
|
|
54
|
+
style,
|
|
55
|
+
}: Props) => {
|
|
56
|
+
const [open, setOpen] = React.useState(visible);
|
|
57
|
+
const progress = useSharedValue(0);
|
|
58
|
+
const bodyHeight = useSharedValue(estimatedHeight ?? 0);
|
|
59
|
+
const headerHeight = useSharedValue(0);
|
|
60
|
+
const insets = useSafeAreaInsets();
|
|
61
|
+
const height = useDerivedValue(() => {
|
|
62
|
+
if (getFullHeight) {
|
|
63
|
+
runOnJS(getFullHeight)(bodyHeight.value + headerHeight.value);
|
|
64
|
+
}
|
|
65
|
+
return bodyHeight.value + headerHeight.value;
|
|
66
|
+
});
|
|
67
|
+
const { height: keyboardHeight } = useReanimatedKeyboardAnimation();
|
|
68
|
+
const animatedStyle = useAnimatedStyle(() => {
|
|
69
|
+
const keyboardOffset = disabledKeyboardOffset
|
|
70
|
+
? NO_OFFSET
|
|
71
|
+
: Math.abs(keyboardHeight.value);
|
|
72
|
+
return {
|
|
73
|
+
transform: [
|
|
74
|
+
{
|
|
75
|
+
translateY: -progress.value * height.value - keyboardOffset,
|
|
76
|
+
},
|
|
77
|
+
],
|
|
78
|
+
};
|
|
79
|
+
});
|
|
80
|
+
|
|
81
|
+
const onGesture = Gesture.Pan()
|
|
82
|
+
.onUpdate((e) => {
|
|
83
|
+
'worklet';
|
|
84
|
+
const newPosition = e.translationY * 0.9;
|
|
85
|
+
progress.value = interpolate(
|
|
86
|
+
newPosition,
|
|
87
|
+
[0, height.value],
|
|
88
|
+
[0, -1],
|
|
89
|
+
Extrapolation.CLAMP
|
|
90
|
+
);
|
|
91
|
+
})
|
|
92
|
+
.onEnd((e) => {
|
|
93
|
+
'worklet';
|
|
94
|
+
const keepOpen = e.translationY < height.value * 0.5;
|
|
95
|
+
if (keepOpen) {
|
|
96
|
+
progress.value = withTiming(0, ANIMATION_OPTIONS);
|
|
97
|
+
} else if (onRequestClose) {
|
|
98
|
+
runOnJS(onRequestClose)();
|
|
99
|
+
}
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
React.useEffect(() => {
|
|
103
|
+
if (visible) {
|
|
104
|
+
progress.value = withTiming(0, ANIMATION_OPTIONS);
|
|
105
|
+
setOpen(true);
|
|
106
|
+
} else {
|
|
107
|
+
progress.value = withTiming(-1, ANIMATION_OPTIONS, (finished) => {
|
|
108
|
+
if (finished) {
|
|
109
|
+
runOnJS(setOpen)(false);
|
|
110
|
+
}
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
}, [progress, visible]);
|
|
114
|
+
|
|
115
|
+
React.useEffect(() => {
|
|
116
|
+
if (!open) Keyboard.dismiss();
|
|
117
|
+
}, [open]);
|
|
118
|
+
|
|
119
|
+
React.useEffect(() => {
|
|
120
|
+
const subscription = BackHandler.addEventListener(
|
|
121
|
+
'hardwareBackPress',
|
|
122
|
+
() => {
|
|
123
|
+
if (open) {
|
|
124
|
+
onRequestClose?.();
|
|
125
|
+
return true;
|
|
126
|
+
}
|
|
127
|
+
return;
|
|
128
|
+
}
|
|
129
|
+
);
|
|
130
|
+
return () => subscription.remove();
|
|
131
|
+
}, [open, onRequestClose]);
|
|
132
|
+
|
|
133
|
+
if (!open) return null;
|
|
134
|
+
|
|
135
|
+
return (
|
|
136
|
+
<Portal hostName="sheet">
|
|
137
|
+
<UIBackdrop
|
|
138
|
+
visible={visible}
|
|
139
|
+
onPress={onRequestClose}
|
|
140
|
+
animationDuration={ANIMATION_DURATION}
|
|
141
|
+
style={[{ zIndex: 10 + (zIndexOffset ? zIndexOffset + 5 : 0) }]}
|
|
142
|
+
/>
|
|
143
|
+
<Animated.View
|
|
144
|
+
style={[
|
|
145
|
+
styles.container,
|
|
146
|
+
animatedStyle,
|
|
147
|
+
{ bottom: 0, paddingBottom: Math.max(0, insets.bottom) },
|
|
148
|
+
{ zIndex: 15 + (zIndexOffset ?? 0) },
|
|
149
|
+
style,
|
|
150
|
+
]}
|
|
151
|
+
>
|
|
152
|
+
<UIStack
|
|
153
|
+
onLayout={(e) => {
|
|
154
|
+
headerHeight.value = e.nativeEvent.layout.height;
|
|
155
|
+
}}
|
|
156
|
+
>
|
|
157
|
+
<GestureDetector gesture={onGesture}>
|
|
158
|
+
<View style={styles.gestureBarContainer}>
|
|
159
|
+
<View style={styles.gestureBar} />
|
|
160
|
+
</View>
|
|
161
|
+
</GestureDetector>
|
|
162
|
+
<UIStack horizontal center style={styles.titleContainer}>
|
|
163
|
+
<UIText size={16} weight="600" style={styles.title}>
|
|
164
|
+
{title}
|
|
165
|
+
</UIText>
|
|
166
|
+
<UIButton
|
|
167
|
+
borderless
|
|
168
|
+
testID="action-sheet-close"
|
|
169
|
+
accessibilityLabel="action-sheet-close"
|
|
170
|
+
onPress={onRequestClose}
|
|
171
|
+
style={styles.close}
|
|
172
|
+
>
|
|
173
|
+
<UIIcon name="close" size={20} />
|
|
174
|
+
</UIButton>
|
|
175
|
+
</UIStack>
|
|
176
|
+
</UIStack>
|
|
177
|
+
<Animated.View
|
|
178
|
+
onLayout={(e) => {
|
|
179
|
+
bodyHeight.value = e.nativeEvent.layout.height;
|
|
180
|
+
}}
|
|
181
|
+
style={!noPaddingBottom && styles.body}
|
|
182
|
+
>
|
|
183
|
+
{children}
|
|
184
|
+
</Animated.View>
|
|
185
|
+
</Animated.View>
|
|
186
|
+
</Portal>
|
|
187
|
+
);
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
const styles = StyleSheet.create({
|
|
191
|
+
container: {
|
|
192
|
+
zIndex: 15,
|
|
193
|
+
backgroundColor: '#fff',
|
|
194
|
+
position: 'absolute',
|
|
195
|
+
left: 0,
|
|
196
|
+
right: 0,
|
|
197
|
+
bottom: 0,
|
|
198
|
+
borderTopLeftRadius: 17,
|
|
199
|
+
borderTopRightRadius: 17,
|
|
200
|
+
},
|
|
201
|
+
gestureBarContainer: {
|
|
202
|
+
paddingVertical: 5,
|
|
203
|
+
},
|
|
204
|
+
gestureBar: {
|
|
205
|
+
width: 45,
|
|
206
|
+
height: 4,
|
|
207
|
+
borderRadius: 2,
|
|
208
|
+
backgroundColor: theme.color.neutral.light['50'],
|
|
209
|
+
marginVertical: 16,
|
|
210
|
+
alignSelf: 'center',
|
|
211
|
+
},
|
|
212
|
+
title: {
|
|
213
|
+
marginVertical: 8,
|
|
214
|
+
marginHorizontal: 80,
|
|
215
|
+
flex: 1,
|
|
216
|
+
textAlign: 'center',
|
|
217
|
+
},
|
|
218
|
+
close: { position: 'absolute', right: 4, top: -10 },
|
|
219
|
+
titleContainer: {
|
|
220
|
+
width: '100%',
|
|
221
|
+
justifyContent: 'center',
|
|
222
|
+
position: 'relative',
|
|
223
|
+
},
|
|
224
|
+
body: {
|
|
225
|
+
paddingBottom: 32,
|
|
226
|
+
},
|
|
227
|
+
dev: {
|
|
228
|
+
marginVertical: 8,
|
|
229
|
+
},
|
|
230
|
+
});
|