@procivis/one-react-native-components 0.1.63 → 0.2.54
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 +17 -6
- package/lib/commonjs/components/backup/index.js +17 -0
- package/lib/commonjs/components/backup/index.js.map +1 -0
- package/lib/commonjs/components/backup/preview-credentials.js +42 -0
- package/lib/commonjs/components/backup/preview-credentials.js.map +1 -0
- package/lib/commonjs/components/credential/credential.js +63 -0
- package/lib/commonjs/components/credential/credential.js.map +1 -0
- package/lib/commonjs/components/credential/index.js +17 -0
- package/lib/commonjs/components/credential/index.js.map +1 -0
- package/lib/commonjs/components/entity/EntityButtons.js +69 -0
- package/lib/commonjs/components/entity/EntityButtons.js.map +1 -0
- package/lib/commonjs/components/entity/entity-attributes.js +52 -0
- package/lib/commonjs/components/entity/entity-attributes.js.map +1 -0
- package/lib/commonjs/components/entity/entity-details-with-buttons.js +91 -0
- package/lib/commonjs/components/entity/entity-details-with-buttons.js.map +1 -0
- package/lib/commonjs/components/entity/entity-details.js +74 -0
- package/lib/commonjs/components/entity/entity-details.js.map +1 -0
- package/lib/commonjs/components/entity/index.js +27 -0
- package/lib/commonjs/components/entity/index.js.map +1 -0
- package/lib/commonjs/components/index.js +61 -0
- package/lib/commonjs/components/index.js.map +1 -0
- package/lib/commonjs/components/navigation/header-buttons.js +82 -0
- package/lib/commonjs/components/navigation/header-buttons.js.map +1 -0
- package/lib/commonjs/components/navigation/index.js +17 -0
- package/lib/commonjs/components/navigation/index.js.map +1 -0
- package/lib/commonjs/components/proof-request/group.js +36 -0
- package/lib/commonjs/components/proof-request/group.js.map +1 -0
- package/lib/commonjs/components/proof-request/index.js +39 -0
- package/lib/commonjs/components/proof-request/index.js.map +1 -0
- package/lib/commonjs/components/proof-request/select-credential.js +49 -0
- package/lib/commonjs/components/proof-request/select-credential.js.map +1 -0
- package/lib/commonjs/components/proof-request/share-credential.js +163 -0
- package/lib/commonjs/components/proof-request/share-credential.js.map +1 -0
- package/lib/commonjs/index.js +8 -261
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/ui-components/accessibility/accessibilityHistory.js +81 -0
- package/lib/commonjs/ui-components/accessibility/accessibilityHistory.js.map +1 -0
- package/lib/commonjs/ui-components/blur/blur-view.js +76 -0
- package/lib/commonjs/ui-components/blur/blur-view.js.map +1 -0
- package/lib/commonjs/ui-components/buttons/back-button.js.map +1 -0
- package/lib/commonjs/ui-components/buttons/button.js +153 -0
- package/lib/commonjs/ui-components/buttons/button.js.map +1 -0
- package/lib/commonjs/ui-components/buttons/connectivity-button.js +82 -0
- package/lib/commonjs/ui-components/buttons/connectivity-button.js.map +1 -0
- package/lib/commonjs/ui-components/credential/card/credential-card.js +183 -0
- package/lib/commonjs/ui-components/credential/card/credential-card.js.map +1 -0
- package/lib/commonjs/ui-components/credential/card/credential-details-card.js +199 -0
- package/lib/commonjs/ui-components/credential/card/credential-details-card.js.map +1 -0
- package/lib/commonjs/ui-components/credential/card/credential-header.js +173 -0
- package/lib/commonjs/ui-components/credential/card/credential-header.js.map +1 -0
- package/lib/commonjs/ui-components/credential/card/credential-image-carousel.js +124 -0
- package/lib/commonjs/ui-components/credential/card/credential-image-carousel.js.map +1 -0
- package/lib/commonjs/ui-components/credential/card/index.js +91 -0
- package/lib/commonjs/ui-components/credential/card/index.js.map +1 -0
- package/lib/commonjs/ui-components/credential/credential-attribute-item.js +289 -0
- package/lib/commonjs/ui-components/credential/credential-attribute-item.js.map +1 -0
- package/lib/commonjs/ui-components/credential/selector.js +79 -0
- package/lib/commonjs/ui-components/credential/selector.js.map +1 -0
- package/lib/commonjs/ui-components/detail/detail.js +84 -0
- package/lib/commonjs/ui-components/detail/detail.js.map +1 -0
- package/lib/commonjs/ui-components/entity/avatar.js +106 -0
- package/lib/commonjs/ui-components/entity/avatar.js.map +1 -0
- package/lib/commonjs/ui-components/entity/entity-cluster.js +75 -0
- package/lib/commonjs/ui-components/entity/entity-cluster.js.map +1 -0
- package/lib/commonjs/ui-components/header/header.js +105 -0
- package/lib/commonjs/ui-components/header/header.js.map +1 -0
- package/lib/commonjs/ui-components/header/navigation-header.js +148 -0
- package/lib/commonjs/ui-components/header/navigation-header.js.map +1 -0
- package/lib/commonjs/ui-components/history/data-item.js +70 -0
- package/lib/commonjs/ui-components/history/data-item.js.map +1 -0
- package/lib/commonjs/ui-components/history/history-list-item.js +90 -0
- package/lib/commonjs/ui-components/history/history-list-item.js.map +1 -0
- package/lib/commonjs/ui-components/history/history-section-header.js +49 -0
- package/lib/commonjs/ui-components/history/history-section-header.js.map +1 -0
- package/lib/commonjs/ui-components/icons/entity.js +52 -0
- package/lib/commonjs/ui-components/icons/entity.js.map +1 -0
- package/lib/commonjs/ui-components/index.js +281 -0
- package/lib/commonjs/ui-components/index.js.map +1 -0
- package/lib/commonjs/ui-components/input/selection-input.js +102 -0
- package/lib/commonjs/ui-components/input/selection-input.js.map +1 -0
- package/lib/commonjs/ui-components/input/text-input.js +195 -0
- package/lib/commonjs/ui-components/input/text-input.js.map +1 -0
- package/lib/commonjs/ui-components/loader/loader.js +140 -0
- package/lib/commonjs/ui-components/loader/loader.js.map +1 -0
- package/lib/commonjs/ui-components/nerd-view/nerd-mode-item.js +238 -0
- package/lib/commonjs/ui-components/nerd-view/nerd-mode-item.js.map +1 -0
- package/lib/commonjs/ui-components/pin/index.js +47 -0
- package/lib/commonjs/ui-components/pin/index.js.map +1 -0
- package/lib/commonjs/ui-components/pin/keypad.js +201 -0
- package/lib/commonjs/ui-components/pin/keypad.js.map +1 -0
- package/lib/commonjs/ui-components/pin/pin-code-screen.js +162 -0
- package/lib/commonjs/ui-components/pin/pin-code-screen.js.map +1 -0
- package/lib/commonjs/ui-components/pin/pin-lock-animation.js +824 -0
- package/lib/commonjs/ui-components/pin/pin-lock-animation.js.map +1 -0
- package/lib/commonjs/ui-components/pin/pin-lock.js +83 -0
- package/lib/commonjs/ui-components/pin/pin-lock.js.map +1 -0
- package/lib/commonjs/ui-components/screens/backup-screen.js +87 -0
- package/lib/commonjs/ui-components/screens/backup-screen.js.map +1 -0
- package/lib/commonjs/ui-components/screens/image-preview-screen.js +92 -0
- package/lib/commonjs/ui-components/screens/image-preview-screen.js.map +1 -0
- package/lib/commonjs/ui-components/screens/nerd-mode-screen.js +172 -0
- package/lib/commonjs/ui-components/screens/nerd-mode-screen.js.map +1 -0
- package/lib/commonjs/ui-components/screens/qr-code-scanner-screen.js +120 -0
- package/lib/commonjs/ui-components/screens/qr-code-scanner-screen.js.map +1 -0
- package/lib/commonjs/ui-components/screens/scroll-view-screen.js +94 -0
- package/lib/commonjs/ui-components/screens/scroll-view-screen.js.map +1 -0
- package/lib/commonjs/ui-components/screens/section-list-screen.js +67 -0
- package/lib/commonjs/ui-components/screens/section-list-screen.js.map +1 -0
- package/lib/commonjs/ui-components/searchbar/search-bar.js +99 -0
- package/lib/commonjs/ui-components/searchbar/search-bar.js.map +1 -0
- package/lib/commonjs/utils/array.js +10 -0
- package/lib/commonjs/utils/array.js.map +1 -0
- package/lib/commonjs/utils/backup.js +12 -0
- package/lib/commonjs/utils/backup.js.map +1 -0
- package/lib/commonjs/utils/date.js +98 -1
- package/lib/commonjs/utils/date.js.map +1 -1
- package/lib/commonjs/utils/hooks/connectivity/connectivity.js +148 -0
- package/lib/commonjs/utils/hooks/connectivity/connectivity.js.map +1 -0
- package/lib/commonjs/utils/hooks/connectivity/connectivity.test.js +56 -0
- package/lib/commonjs/utils/hooks/connectivity/connectivity.test.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/backup.js +155 -0
- package/lib/commonjs/utils/hooks/core/backup.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/core-config.js +19 -0
- package/lib/commonjs/utils/hooks/core/core-config.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/core-context.js +72 -0
- package/lib/commonjs/utils/hooks/core/core-context.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/core-init.js +91 -0
- package/lib/commonjs/utils/hooks/core/core-init.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/credential-schemas.js +111 -0
- package/lib/commonjs/utils/hooks/core/credential-schemas.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/credentials.js +170 -0
- package/lib/commonjs/utils/hooks/core/credentials.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/dids.js +35 -0
- package/lib/commonjs/utils/hooks/core/dids.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/error-code.js +15 -0
- package/lib/commonjs/utils/hooks/core/error-code.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/history.js +65 -0
- package/lib/commonjs/utils/hooks/core/history.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/index.js +138 -0
- package/lib/commonjs/utils/hooks/core/index.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/proof-schemas.js +132 -0
- package/lib/commonjs/utils/hooks/core/proof-schemas.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/proofs.js +336 -0
- package/lib/commonjs/utils/hooks/core/proofs.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/query.js +25 -0
- package/lib/commonjs/utils/hooks/core/query.js.map +1 -0
- package/lib/commonjs/utils/hooks/core/trust-entity.js +95 -0
- package/lib/commonjs/utils/hooks/core/trust-entity.js.map +1 -0
- package/lib/commonjs/utils/hooks/credential-card/credential-card-expanding.js +51 -0
- package/lib/commonjs/utils/hooks/credential-card/credential-card-expanding.js.map +1 -0
- package/lib/commonjs/utils/hooks/http/client.js +20 -0
- package/lib/commonjs/utils/hooks/http/client.js.map +1 -0
- package/lib/commonjs/utils/hooks/index.js +85 -11
- package/lib/commonjs/utils/hooks/index.js.map +1 -1
- package/lib/commonjs/utils/hooks/navigation/before-remove.js +28 -0
- package/lib/commonjs/utils/hooks/navigation/before-remove.js.map +1 -0
- package/lib/commonjs/utils/hooks/navigation/close-button-timeout.js +34 -0
- package/lib/commonjs/utils/hooks/navigation/close-button-timeout.js.map +1 -0
- package/lib/commonjs/utils/hooks/navigation/deep-link.js +46 -0
- package/lib/commonjs/utils/hooks/navigation/deep-link.js.map +1 -0
- package/lib/commonjs/utils/hooks/navigation/index.js +50 -0
- package/lib/commonjs/utils/hooks/navigation/index.js.map +1 -0
- package/lib/commonjs/utils/hooks/navigation/open-settings.js +43 -0
- package/lib/commonjs/utils/hooks/navigation/open-settings.js.map +1 -0
- package/lib/commonjs/utils/hooks/pin-security/pin-security.js +87 -0
- package/lib/commonjs/utils/hooks/pin-security/pin-security.js.map +1 -0
- package/lib/commonjs/utils/hooks/revocation/credential-status.js +67 -0
- package/lib/commonjs/utils/hooks/revocation/credential-status.js.map +1 -0
- package/lib/commonjs/utils/index.js +119 -45
- package/lib/commonjs/utils/index.js.map +1 -1
- package/lib/commonjs/utils/parsers/credential-images.js +86 -0
- package/lib/commonjs/utils/parsers/credential-images.js.map +1 -0
- package/lib/commonjs/utils/parsers/credential-sharing.js +255 -0
- package/lib/commonjs/utils/parsers/credential-sharing.js.map +1 -0
- package/lib/commonjs/utils/parsers/credential.js +323 -0
- package/lib/commonjs/utils/parsers/credential.js.map +1 -0
- package/lib/commonjs/utils/parsers/index.js +50 -0
- package/lib/commonjs/utils/parsers/index.js.map +1 -0
- package/lib/commonjs/utils/parsers/query.js +103 -0
- package/lib/commonjs/utils/parsers/query.js.map +1 -0
- package/lib/commonjs/utils/reporting.js +86 -0
- package/lib/commonjs/utils/reporting.js.map +1 -0
- package/lib/commonjs/utils/string.js +20 -0
- package/lib/commonjs/utils/string.js.map +1 -0
- package/lib/commonjs/utils/useMemoAsync.js +1 -1
- package/lib/commonjs/utils/useMemoAsync.js.map +1 -1
- package/lib/commonjs/utils/uuid.js +16 -0
- package/lib/commonjs/utils/uuid.js.map +1 -0
- package/lib/module/components/backup/index.js +2 -0
- package/lib/module/components/backup/index.js.map +1 -0
- package/lib/module/components/backup/preview-credentials.js +34 -0
- package/lib/module/components/backup/preview-credentials.js.map +1 -0
- package/lib/module/components/credential/credential.js +55 -0
- package/lib/module/components/credential/credential.js.map +1 -0
- package/lib/module/components/credential/index.js +2 -0
- package/lib/module/components/credential/index.js.map +1 -0
- package/lib/module/components/entity/EntityButtons.js +60 -0
- package/lib/module/components/entity/EntityButtons.js.map +1 -0
- package/lib/module/components/entity/entity-attributes.js +43 -0
- package/lib/module/components/entity/entity-attributes.js.map +1 -0
- package/lib/module/components/entity/entity-details-with-buttons.js +81 -0
- package/lib/module/components/entity/entity-details-with-buttons.js.map +1 -0
- package/lib/module/components/entity/entity-details.js +64 -0
- package/lib/module/components/entity/entity-details.js.map +1 -0
- package/lib/module/components/entity/index.js +3 -0
- package/lib/module/components/entity/index.js.map +1 -0
- package/lib/module/components/index.js +6 -0
- package/lib/module/components/index.js.map +1 -0
- package/lib/module/components/navigation/header-buttons.js +70 -0
- package/lib/module/components/navigation/header-buttons.js.map +1 -0
- package/lib/module/components/navigation/index.js +2 -0
- package/lib/module/components/navigation/index.js.map +1 -0
- package/lib/module/components/proof-request/group.js +28 -0
- package/lib/module/components/proof-request/group.js.map +1 -0
- package/lib/module/components/proof-request/index.js +4 -0
- package/lib/module/components/proof-request/index.js.map +1 -0
- package/lib/module/components/proof-request/select-credential.js +41 -0
- package/lib/module/components/proof-request/select-credential.js.map +1 -0
- package/lib/module/components/proof-request/share-credential.js +154 -0
- package/lib/module/components/proof-request/share-credential.js.map +1 -0
- package/lib/module/index.js +2 -25
- package/lib/module/index.js.map +1 -1
- package/lib/module/ui-components/accessibility/accessibilityHistory.js +71 -0
- package/lib/module/ui-components/accessibility/accessibilityHistory.js.map +1 -0
- package/lib/module/ui-components/blur/blur-view.js +67 -0
- package/lib/module/ui-components/blur/blur-view.js.map +1 -0
- package/lib/module/ui-components/buttons/back-button.js.map +1 -0
- package/lib/module/ui-components/buttons/button.js +143 -0
- package/lib/module/ui-components/buttons/button.js.map +1 -0
- package/lib/module/ui-components/buttons/connectivity-button.js +73 -0
- package/lib/module/ui-components/buttons/connectivity-button.js.map +1 -0
- package/lib/module/ui-components/credential/card/credential-card.js +171 -0
- package/lib/module/ui-components/credential/card/credential-card.js.map +1 -0
- package/lib/module/ui-components/credential/card/credential-details-card.js +189 -0
- package/lib/module/ui-components/credential/card/credential-details-card.js.map +1 -0
- package/lib/module/ui-components/credential/card/credential-header.js +163 -0
- package/lib/module/ui-components/credential/card/credential-header.js.map +1 -0
- package/lib/module/ui-components/credential/card/credential-image-carousel.js +113 -0
- package/lib/module/ui-components/credential/card/credential-image-carousel.js.map +1 -0
- package/lib/module/ui-components/credential/card/index.js +11 -0
- package/lib/module/ui-components/credential/card/index.js.map +1 -0
- package/lib/module/ui-components/credential/credential-attribute-item.js +279 -0
- package/lib/module/ui-components/credential/credential-attribute-item.js.map +1 -0
- package/lib/module/ui-components/credential/selector.js +70 -0
- package/lib/module/ui-components/credential/selector.js.map +1 -0
- package/lib/module/ui-components/detail/detail.js +75 -0
- package/lib/module/ui-components/detail/detail.js.map +1 -0
- package/lib/module/ui-components/entity/avatar.js +96 -0
- package/lib/module/ui-components/entity/avatar.js.map +1 -0
- package/lib/module/ui-components/entity/entity-cluster.js +65 -0
- package/lib/module/ui-components/entity/entity-cluster.js.map +1 -0
- package/lib/module/ui-components/header/header.js +97 -0
- package/lib/module/ui-components/header/header.js.map +1 -0
- package/lib/module/ui-components/header/navigation-header.js +138 -0
- package/lib/module/ui-components/header/navigation-header.js.map +1 -0
- package/lib/module/ui-components/history/data-item.js +60 -0
- package/lib/module/ui-components/history/data-item.js.map +1 -0
- package/lib/module/ui-components/history/history-list-item.js +80 -0
- package/lib/module/ui-components/history/history-list-item.js.map +1 -0
- package/lib/module/ui-components/history/history-section-header.js +42 -0
- package/lib/module/ui-components/history/history-section-header.js.map +1 -0
- package/lib/module/ui-components/icons/entity.js +43 -0
- package/lib/module/ui-components/icons/entity.js.map +1 -0
- package/lib/module/ui-components/index.js +26 -0
- package/lib/module/ui-components/index.js.map +1 -0
- package/lib/module/ui-components/input/selection-input.js +92 -0
- package/lib/module/ui-components/input/selection-input.js.map +1 -0
- package/lib/module/ui-components/input/text-input.js +185 -0
- package/lib/module/ui-components/input/text-input.js.map +1 -0
- package/lib/module/ui-components/loader/loader.js +130 -0
- package/lib/module/ui-components/loader/loader.js.map +1 -0
- package/lib/module/ui-components/nerd-view/nerd-mode-item.js +227 -0
- package/lib/module/ui-components/nerd-view/nerd-mode-item.js.map +1 -0
- package/lib/module/ui-components/pin/index.js +5 -0
- package/lib/module/ui-components/pin/index.js.map +1 -0
- package/lib/module/ui-components/pin/keypad.js +191 -0
- package/lib/module/ui-components/pin/keypad.js.map +1 -0
- package/lib/module/ui-components/pin/pin-code-screen.js +152 -0
- package/lib/module/ui-components/pin/pin-code-screen.js.map +1 -0
- package/lib/module/ui-components/pin/pin-lock-animation.js +817 -0
- package/lib/module/ui-components/pin/pin-lock-animation.js.map +1 -0
- package/lib/module/ui-components/pin/pin-lock.js +73 -0
- package/lib/module/ui-components/pin/pin-lock.js.map +1 -0
- package/lib/module/ui-components/screens/backup-screen.js +78 -0
- package/lib/module/ui-components/screens/backup-screen.js.map +1 -0
- package/lib/module/ui-components/screens/image-preview-screen.js +83 -0
- package/lib/module/ui-components/screens/image-preview-screen.js.map +1 -0
- package/lib/module/ui-components/screens/nerd-mode-screen.js +161 -0
- package/lib/module/ui-components/screens/nerd-mode-screen.js.map +1 -0
- package/lib/module/ui-components/screens/qr-code-scanner-screen.js +110 -0
- package/lib/module/ui-components/screens/qr-code-scanner-screen.js.map +1 -0
- package/lib/module/ui-components/screens/scroll-view-screen.js +86 -0
- package/lib/module/ui-components/screens/scroll-view-screen.js.map +1 -0
- package/lib/module/ui-components/screens/section-list-screen.js +59 -0
- package/lib/module/ui-components/screens/section-list-screen.js.map +1 -0
- package/lib/module/ui-components/searchbar/search-bar.js +89 -0
- package/lib/module/ui-components/searchbar/search-bar.js.map +1 -0
- package/lib/module/utils/array.js +4 -0
- package/lib/module/utils/array.js.map +1 -0
- package/lib/module/utils/backup.js +5 -0
- package/lib/module/utils/backup.js.map +1 -0
- package/lib/module/utils/date.js +89 -1
- package/lib/module/utils/date.js.map +1 -1
- package/lib/module/utils/hooks/connectivity/connectivity.js +136 -0
- package/lib/module/utils/hooks/connectivity/connectivity.js.map +1 -0
- package/lib/module/utils/hooks/connectivity/connectivity.test.js +54 -0
- package/lib/module/utils/hooks/connectivity/connectivity.test.js.map +1 -0
- package/lib/module/utils/hooks/core/backup.js +143 -0
- package/lib/module/utils/hooks/core/backup.js.map +1 -0
- package/lib/module/utils/hooks/core/core-config.js +12 -0
- package/lib/module/utils/hooks/core/core-config.js.map +1 -0
- package/lib/module/utils/hooks/core/core-context.js +62 -0
- package/lib/module/utils/hooks/core/core-context.js.map +1 -0
- package/lib/module/utils/hooks/core/core-init.js +82 -0
- package/lib/module/utils/hooks/core/core-init.js.map +1 -0
- package/lib/module/utils/hooks/core/credential-schemas.js +95 -0
- package/lib/module/utils/hooks/core/credential-schemas.js.map +1 -0
- package/lib/module/utils/hooks/core/credentials.js +155 -0
- package/lib/module/utils/hooks/core/credentials.js.map +1 -0
- package/lib/module/utils/hooks/core/dids.js +27 -0
- package/lib/module/utils/hooks/core/dids.js.map +1 -0
- package/lib/module/utils/hooks/core/error-code.js +8 -0
- package/lib/module/utils/hooks/core/error-code.js.map +1 -0
- package/lib/module/utils/hooks/core/history.js +57 -0
- package/lib/module/utils/hooks/core/history.js.map +1 -0
- package/lib/module/utils/hooks/core/index.js +13 -0
- package/lib/module/utils/hooks/core/index.js.map +1 -0
- package/lib/module/utils/hooks/core/proof-schemas.js +115 -0
- package/lib/module/utils/hooks/core/proof-schemas.js.map +1 -0
- package/lib/module/utils/hooks/core/proofs.js +312 -0
- package/lib/module/utils/hooks/core/proofs.js.map +1 -0
- package/lib/module/utils/hooks/core/query.js +18 -0
- package/lib/module/utils/hooks/core/query.js.map +1 -0
- package/lib/module/utils/hooks/core/trust-entity.js +84 -0
- package/lib/module/utils/hooks/core/trust-entity.js.map +1 -0
- package/lib/module/utils/hooks/credential-card/credential-card-expanding.js +43 -0
- package/lib/module/utils/hooks/credential-card/credential-card-expanding.js.map +1 -0
- package/lib/module/utils/hooks/http/client.js +13 -0
- package/lib/module/utils/hooks/http/client.js.map +1 -0
- package/lib/module/utils/hooks/index.js +8 -4
- package/lib/module/utils/hooks/index.js.map +1 -1
- package/lib/module/utils/hooks/navigation/before-remove.js +21 -0
- package/lib/module/utils/hooks/navigation/before-remove.js.map +1 -0
- package/lib/module/utils/hooks/navigation/close-button-timeout.js +27 -0
- package/lib/module/utils/hooks/navigation/close-button-timeout.js.map +1 -0
- package/lib/module/utils/hooks/navigation/deep-link.js +38 -0
- package/lib/module/utils/hooks/navigation/deep-link.js.map +1 -0
- package/lib/module/utils/hooks/navigation/index.js +5 -0
- package/lib/module/utils/hooks/navigation/index.js.map +1 -0
- package/lib/module/utils/hooks/navigation/open-settings.js +36 -0
- package/lib/module/utils/hooks/navigation/open-settings.js.map +1 -0
- package/lib/module/utils/hooks/pin-security/pin-security.js +80 -0
- package/lib/module/utils/hooks/pin-security/pin-security.js.map +1 -0
- package/lib/module/utils/hooks/revocation/credential-status.js +61 -0
- package/lib/module/utils/hooks/revocation/credential-status.js.map +1 -0
- package/lib/module/utils/index.js +11 -5
- package/lib/module/utils/index.js.map +1 -1
- package/lib/module/utils/parsers/credential-images.js +78 -0
- package/lib/module/utils/parsers/credential-images.js.map +1 -0
- package/lib/module/utils/parsers/credential-sharing.js +242 -0
- package/lib/module/utils/parsers/credential-sharing.js.map +1 -0
- package/lib/module/utils/parsers/credential.js +304 -0
- package/lib/module/utils/parsers/credential.js.map +1 -0
- package/lib/module/utils/parsers/index.js +5 -0
- package/lib/module/utils/parsers/index.js.map +1 -0
- package/lib/module/utils/parsers/query.js +91 -0
- package/lib/module/utils/parsers/query.js.map +1 -0
- package/lib/module/utils/reporting.js +76 -0
- package/lib/module/utils/reporting.js.map +1 -0
- package/lib/module/utils/string.js +10 -0
- package/lib/module/utils/string.js.map +1 -0
- package/lib/module/utils/useMemoAsync.js +1 -1
- package/lib/module/utils/useMemoAsync.js.map +1 -1
- package/lib/module/utils/uuid.js +9 -0
- package/lib/module/utils/uuid.js.map +1 -0
- package/lib/typescript/components/backup/index.d.ts +1 -0
- package/lib/typescript/components/backup/preview-credentials.d.ts +11 -0
- package/lib/typescript/components/credential/credential.d.ts +16 -0
- package/lib/typescript/components/credential/index.d.ts +1 -0
- package/lib/typescript/components/entity/EntityButtons.d.ts +14 -0
- package/lib/typescript/components/entity/entity-attributes.d.ts +12 -0
- package/lib/typescript/components/entity/entity-details-with-buttons.d.ts +18 -0
- package/lib/typescript/components/entity/entity-details.d.ts +19 -0
- package/lib/typescript/components/entity/index.d.ts +2 -0
- package/lib/typescript/components/index.d.ts +5 -0
- package/lib/typescript/components/navigation/header-buttons.d.ts +21 -0
- package/lib/typescript/components/navigation/index.d.ts +1 -0
- package/lib/typescript/components/proof-request/group.d.ts +2 -0
- package/lib/typescript/components/proof-request/index.d.ts +3 -0
- package/lib/typescript/components/proof-request/select-credential.d.ts +14 -0
- package/lib/typescript/components/proof-request/share-credential.d.ts +27 -0
- package/lib/typescript/index.d.ts +2 -25
- package/lib/typescript/ui-components/accessibility/accessibilityHistory.d.ts +13 -0
- package/lib/typescript/ui-components/buttons/back-button.d.ts +9 -0
- package/lib/typescript/ui-components/credential/card/credential-card.d.ts +25 -0
- package/lib/typescript/ui-components/credential/card/index.d.ts +10 -0
- package/lib/typescript/ui-components/credential/credential-attribute-item.d.ts +49 -0
- package/lib/typescript/ui-components/entity/avatar.d.ts +11 -0
- package/lib/typescript/ui-components/entity/entity-cluster.d.ts +13 -0
- package/lib/typescript/ui-components/index.d.ts +25 -0
- package/lib/typescript/ui-components/pin/index.d.ts +4 -0
- package/lib/typescript/ui-components/pin/pin-lock-animation.d.ts +731 -0
- package/lib/typescript/ui-components/pin/pin-lock.d.ts +13 -0
- package/lib/typescript/ui-components/screens/nerd-mode-screen.d.ts +49 -0
- package/lib/typescript/ui-components/text/typography.d.ts +112 -0
- package/lib/typescript/utils/array.d.ts +1 -0
- package/lib/typescript/utils/backup.d.ts +1 -0
- package/lib/typescript/utils/date.d.ts +32 -0
- package/lib/typescript/utils/hooks/connectivity/connectivity.d.ts +27 -0
- package/lib/typescript/utils/hooks/connectivity/connectivity.test.d.ts +1 -0
- package/lib/typescript/utils/hooks/core/backup.d.ts +12 -0
- package/lib/typescript/utils/hooks/core/core-config.d.ts +1 -0
- package/lib/typescript/utils/hooks/core/core-context.d.ts +15 -0
- package/lib/typescript/utils/hooks/core/core-init.d.ts +3 -0
- package/lib/typescript/utils/hooks/core/credential-schemas.d.ts +11 -0
- package/lib/typescript/utils/hooks/core/credentials.d.ts +18 -0
- package/lib/typescript/utils/hooks/core/dids.d.ts +3 -0
- package/lib/typescript/utils/hooks/core/error-code.d.ts +6 -0
- package/lib/typescript/utils/hooks/core/history.d.ts +6 -0
- package/lib/typescript/utils/hooks/core/index.d.ts +12 -0
- package/lib/typescript/utils/hooks/core/proof-schemas.d.ts +14 -0
- package/lib/typescript/utils/hooks/core/proofs.d.ts +37 -0
- package/lib/typescript/utils/hooks/core/query.d.ts +2 -0
- package/lib/typescript/utils/hooks/core/trust-entity.d.ts +6 -0
- package/lib/typescript/utils/hooks/credential-card/credential-card-expanding.d.ts +10 -0
- package/lib/typescript/utils/hooks/http/client.d.ts +2 -0
- package/lib/typescript/utils/hooks/index.d.ts +8 -4
- package/lib/typescript/utils/hooks/navigation/before-remove.d.ts +1 -0
- package/lib/typescript/utils/hooks/navigation/close-button-timeout.d.ts +3 -0
- package/lib/typescript/utils/hooks/navigation/deep-link.d.ts +2 -0
- package/lib/typescript/utils/hooks/navigation/index.d.ts +4 -0
- package/lib/typescript/utils/hooks/navigation/open-settings.d.ts +6 -0
- package/lib/typescript/utils/hooks/pin-security/pin-security.d.ts +6 -0
- package/lib/typescript/utils/hooks/revocation/credential-status.d.ts +7 -0
- package/lib/typescript/utils/index.d.ts +11 -5
- package/lib/typescript/utils/parsers/credential-images.d.ts +3 -0
- package/lib/typescript/utils/parsers/credential-sharing.d.ts +16 -0
- package/lib/typescript/utils/parsers/credential.d.ts +76 -0
- package/lib/typescript/utils/parsers/index.d.ts +4 -0
- package/lib/typescript/utils/parsers/query.d.ts +7 -0
- package/lib/typescript/utils/ref.d.ts +1 -1
- package/lib/typescript/utils/reporting.d.ts +4 -0
- package/lib/typescript/utils/string.d.ts +4 -0
- package/lib/typescript/utils/uuid.d.ts +6 -0
- package/package.json +29 -2
- package/src/components/backup/index.ts +1 -0
- package/src/components/backup/preview-credentials.tsx +38 -0
- package/src/components/credential/credential.tsx +72 -0
- package/src/components/credential/index.ts +1 -0
- package/src/components/entity/EntityButtons.tsx +79 -0
- package/src/components/entity/entity-attributes.tsx +62 -0
- package/src/components/entity/entity-details-with-buttons.tsx +98 -0
- package/src/components/entity/entity-details.tsx +85 -0
- package/src/components/entity/index.ts +3 -0
- package/src/components/index.ts +5 -0
- package/src/components/navigation/header-buttons.tsx +64 -0
- package/src/components/navigation/index.ts +1 -0
- package/src/components/proof-request/group.tsx +26 -0
- package/src/components/proof-request/index.ts +3 -0
- package/src/components/proof-request/select-credential.tsx +48 -0
- package/src/components/proof-request/share-credential.tsx +194 -0
- package/src/index.ts +2 -25
- package/src/ui-components/accessibility/accessibilityHistory.tsx +77 -0
- package/src/ui-components/blur/blur-view.tsx +82 -0
- package/src/ui-components/buttons/back-button.tsx +30 -0
- package/src/ui-components/buttons/button.tsx +169 -0
- package/src/ui-components/buttons/connectivity-button.tsx +95 -0
- package/src/ui-components/credential/card/credential-card.stories.tsx +54 -0
- package/src/ui-components/credential/card/credential-card.tsx +189 -0
- package/src/ui-components/credential/card/credential-details-card.stories.tsx +299 -0
- package/src/ui-components/credential/card/credential-details-card.tsx +242 -0
- package/src/ui-components/credential/card/credential-header.stories.tsx +50 -0
- package/src/ui-components/credential/card/credential-header.tsx +196 -0
- package/src/ui-components/credential/card/credential-image-carousel.tsx +113 -0
- package/src/ui-components/credential/card/index.ts +16 -0
- package/src/ui-components/credential/credential-attribute-item.tsx +373 -0
- package/src/ui-components/credential/selector.tsx +64 -0
- package/src/ui-components/detail/detail.stories.tsx +65 -0
- package/src/ui-components/detail/detail.tsx +98 -0
- package/src/ui-components/entity/avatar.tsx +100 -0
- package/src/ui-components/entity/entity-cluster.tsx +82 -0
- package/src/ui-components/header/header.stories.tsx +59 -0
- package/src/ui-components/header/header.tsx +105 -0
- package/src/ui-components/header/navigation-header.stories.tsx +56 -0
- package/src/ui-components/header/navigation-header.tsx +147 -0
- package/src/ui-components/history/data-item.tsx +79 -0
- package/src/ui-components/history/history-list-item.tsx +102 -0
- package/src/ui-components/history/history-section-header.tsx +44 -0
- package/src/ui-components/icons/entity.tsx +31 -0
- package/src/ui-components/index.ts +25 -0
- package/src/ui-components/input/selection-input.tsx +112 -0
- package/src/ui-components/input/text-input.tsx +253 -0
- package/src/ui-components/loader/loader.tsx +171 -0
- package/src/ui-components/nerd-view/nerd-mode-item.tsx +299 -0
- package/src/ui-components/pin/index.ts +5 -0
- package/src/ui-components/pin/keypad.tsx +166 -0
- package/src/ui-components/pin/pin-code-screen.tsx +195 -0
- package/src/ui-components/pin/pin-lock-animation.tsx +500 -0
- package/src/ui-components/pin/pin-lock.tsx +82 -0
- package/src/ui-components/screens/backup-screen.tsx +92 -0
- package/src/ui-components/screens/image-preview-screen.stories.tsx +28 -0
- package/src/ui-components/screens/image-preview-screen.tsx +82 -0
- package/src/ui-components/screens/nerd-mode-screen.tsx +214 -0
- package/src/ui-components/screens/qr-code-scanner-screen.stories.tsx +37 -0
- package/src/ui-components/screens/qr-code-scanner-screen.tsx +124 -0
- package/src/ui-components/screens/scroll-view-screen.tsx +91 -0
- package/src/ui-components/screens/section-list-screen.tsx +61 -0
- package/src/ui-components/searchbar/search-bar.tsx +94 -0
- package/src/ui-components/text/typography.stories.tsx +70 -0
- package/src/utils/array.ts +3 -0
- package/src/utils/backup.ts +5 -0
- package/src/utils/date.ts +105 -1
- package/src/utils/hooks/connectivity/connectivity.test.ts +87 -0
- package/src/utils/hooks/connectivity/connectivity.ts +162 -0
- package/src/utils/hooks/core/backup.ts +140 -0
- package/src/utils/hooks/core/core-config.ts +13 -0
- package/src/utils/hooks/core/core-context.tsx +101 -0
- package/src/utils/hooks/core/core-init.ts +92 -0
- package/src/utils/hooks/core/credential-schemas.ts +110 -0
- package/src/utils/hooks/core/credentials.ts +171 -0
- package/src/utils/hooks/core/dids.ts +28 -0
- package/src/utils/hooks/core/error-code.ts +6 -0
- package/src/utils/hooks/core/history.ts +85 -0
- package/src/utils/hooks/core/index.ts +12 -0
- package/src/utils/hooks/core/proof-schemas.ts +130 -0
- package/src/utils/hooks/core/proofs.ts +351 -0
- package/src/utils/hooks/core/query.ts +19 -0
- package/src/utils/hooks/core/trust-entity.ts +109 -0
- package/src/utils/hooks/credential-card/credential-card-expanding.tsx +45 -0
- package/src/utils/hooks/http/client.ts +13 -0
- package/src/utils/hooks/index.ts +8 -5
- package/src/utils/hooks/navigation/before-remove.tsx +22 -0
- package/src/utils/hooks/navigation/close-button-timeout.tsx +29 -0
- package/src/utils/hooks/navigation/deep-link.ts +40 -0
- package/src/utils/hooks/navigation/index.ts +4 -0
- package/src/utils/hooks/navigation/open-settings.ts +40 -0
- package/src/utils/hooks/pin-security/pin-security.ts +99 -0
- package/src/utils/hooks/revocation/credential-status.ts +44 -0
- package/src/utils/index.ts +11 -14
- package/src/utils/parsers/credential-images.tsx +78 -0
- package/src/utils/parsers/credential-sharing.tsx +366 -0
- package/src/utils/parsers/credential.ts +365 -0
- package/src/utils/parsers/index.ts +4 -0
- package/src/utils/parsers/query.tsx +80 -0
- package/src/utils/reporting.ts +84 -0
- package/src/utils/string.ts +17 -0
- package/src/utils/useMemoAsync.ts +1 -1
- package/src/utils/uuid.ts +8 -0
- package/lib/commonjs/accessibility/accessibilityHistory.js +0 -81
- package/lib/commonjs/accessibility/accessibilityHistory.js.map +0 -1
- package/lib/commonjs/blur/blur-view.js +0 -76
- package/lib/commonjs/blur/blur-view.js.map +0 -1
- package/lib/commonjs/buttons/back-button.js.map +0 -1
- package/lib/commonjs/buttons/button.js +0 -153
- package/lib/commonjs/buttons/button.js.map +0 -1
- package/lib/commonjs/buttons/connectivity-button.js +0 -82
- package/lib/commonjs/buttons/connectivity-button.js.map +0 -1
- package/lib/commonjs/credential/card/credential-card.js +0 -189
- package/lib/commonjs/credential/card/credential-card.js.map +0 -1
- package/lib/commonjs/credential/card/credential-details-card.js +0 -201
- package/lib/commonjs/credential/card/credential-details-card.js.map +0 -1
- package/lib/commonjs/credential/card/credential-header.js +0 -172
- package/lib/commonjs/credential/card/credential-header.js.map +0 -1
- package/lib/commonjs/credential/card/credential-image-carousel.js +0 -124
- package/lib/commonjs/credential/card/credential-image-carousel.js.map +0 -1
- package/lib/commonjs/credential/card/index.js +0 -85
- package/lib/commonjs/credential/card/index.js.map +0 -1
- package/lib/commonjs/credential/credential-attribute-item.js +0 -289
- package/lib/commonjs/credential/credential-attribute-item.js.map +0 -1
- package/lib/commonjs/credential/selector.js +0 -79
- package/lib/commonjs/credential/selector.js.map +0 -1
- package/lib/commonjs/detail/detail.js +0 -84
- package/lib/commonjs/detail/detail.js.map +0 -1
- package/lib/commonjs/entity/avatar.js +0 -96
- package/lib/commonjs/entity/avatar.js.map +0 -1
- package/lib/commonjs/entity/entity-cluster.js +0 -66
- package/lib/commonjs/entity/entity-cluster.js.map +0 -1
- package/lib/commonjs/header/header.js +0 -105
- package/lib/commonjs/header/header.js.map +0 -1
- package/lib/commonjs/header/navigation-header.js +0 -148
- package/lib/commonjs/header/navigation-header.js.map +0 -1
- package/lib/commonjs/history/data-item.js +0 -70
- package/lib/commonjs/history/data-item.js.map +0 -1
- package/lib/commonjs/history/history-list-item.js +0 -90
- package/lib/commonjs/history/history-list-item.js.map +0 -1
- package/lib/commonjs/history/history-section-header.js +0 -49
- package/lib/commonjs/history/history-section-header.js.map +0 -1
- package/lib/commonjs/icons/entity.js +0 -34
- package/lib/commonjs/icons/entity.js.map +0 -1
- package/lib/commonjs/input/selection-input.js +0 -102
- package/lib/commonjs/input/selection-input.js.map +0 -1
- package/lib/commonjs/input/text-input.js +0 -195
- package/lib/commonjs/input/text-input.js.map +0 -1
- package/lib/commonjs/loader/loader.js +0 -140
- package/lib/commonjs/loader/loader.js.map +0 -1
- package/lib/commonjs/nerd-view/nerd-mode-item.js +0 -235
- package/lib/commonjs/nerd-view/nerd-mode-item.js.map +0 -1
- package/lib/commonjs/pin/index.js +0 -32
- package/lib/commonjs/pin/index.js.map +0 -1
- package/lib/commonjs/pin/keypad.js +0 -201
- package/lib/commonjs/pin/keypad.js.map +0 -1
- package/lib/commonjs/pin/pin-code-screen.js +0 -162
- package/lib/commonjs/pin/pin-code-screen.js.map +0 -1
- package/lib/commonjs/screens/backup-screen.js +0 -87
- package/lib/commonjs/screens/backup-screen.js.map +0 -1
- package/lib/commonjs/screens/image-preview-screen.js +0 -92
- package/lib/commonjs/screens/image-preview-screen.js.map +0 -1
- package/lib/commonjs/screens/nerd-mode-screen.js +0 -142
- package/lib/commonjs/screens/nerd-mode-screen.js.map +0 -1
- package/lib/commonjs/screens/qr-code-scanner-screen.js +0 -120
- package/lib/commonjs/screens/qr-code-scanner-screen.js.map +0 -1
- package/lib/commonjs/screens/scroll-view-screen.js +0 -94
- package/lib/commonjs/screens/scroll-view-screen.js.map +0 -1
- package/lib/commonjs/screens/section-list-screen.js +0 -67
- package/lib/commonjs/screens/section-list-screen.js.map +0 -1
- package/lib/commonjs/searchbar/search-bar.js +0 -99
- package/lib/commonjs/searchbar/search-bar.js.map +0 -1
- package/lib/module/accessibility/accessibilityHistory.js +0 -71
- package/lib/module/accessibility/accessibilityHistory.js.map +0 -1
- package/lib/module/blur/blur-view.js +0 -67
- package/lib/module/blur/blur-view.js.map +0 -1
- package/lib/module/buttons/back-button.js.map +0 -1
- package/lib/module/buttons/button.js +0 -143
- package/lib/module/buttons/button.js.map +0 -1
- package/lib/module/buttons/connectivity-button.js +0 -73
- package/lib/module/buttons/connectivity-button.js.map +0 -1
- package/lib/module/credential/card/credential-card.js +0 -177
- package/lib/module/credential/card/credential-card.js.map +0 -1
- package/lib/module/credential/card/credential-details-card.js +0 -191
- package/lib/module/credential/card/credential-details-card.js.map +0 -1
- package/lib/module/credential/card/credential-header.js +0 -162
- package/lib/module/credential/card/credential-header.js.map +0 -1
- package/lib/module/credential/card/credential-image-carousel.js +0 -113
- package/lib/module/credential/card/credential-image-carousel.js.map +0 -1
- package/lib/module/credential/card/index.js +0 -11
- package/lib/module/credential/card/index.js.map +0 -1
- package/lib/module/credential/credential-attribute-item.js +0 -279
- package/lib/module/credential/credential-attribute-item.js.map +0 -1
- package/lib/module/credential/selector.js +0 -70
- package/lib/module/credential/selector.js.map +0 -1
- package/lib/module/detail/detail.js +0 -75
- package/lib/module/detail/detail.js.map +0 -1
- package/lib/module/entity/avatar.js +0 -86
- package/lib/module/entity/avatar.js.map +0 -1
- package/lib/module/entity/entity-cluster.js +0 -56
- package/lib/module/entity/entity-cluster.js.map +0 -1
- package/lib/module/header/header.js +0 -97
- package/lib/module/header/header.js.map +0 -1
- package/lib/module/header/navigation-header.js +0 -138
- package/lib/module/header/navigation-header.js.map +0 -1
- package/lib/module/history/data-item.js +0 -60
- package/lib/module/history/data-item.js.map +0 -1
- package/lib/module/history/history-list-item.js +0 -80
- package/lib/module/history/history-list-item.js.map +0 -1
- package/lib/module/history/history-section-header.js +0 -42
- package/lib/module/history/history-section-header.js.map +0 -1
- package/lib/module/icons/entity.js +0 -25
- package/lib/module/icons/entity.js.map +0 -1
- package/lib/module/input/selection-input.js +0 -92
- package/lib/module/input/selection-input.js.map +0 -1
- package/lib/module/input/text-input.js +0 -185
- package/lib/module/input/text-input.js.map +0 -1
- package/lib/module/loader/loader.js +0 -130
- package/lib/module/loader/loader.js.map +0 -1
- package/lib/module/nerd-view/nerd-mode-item.js +0 -224
- package/lib/module/nerd-view/nerd-mode-item.js.map +0 -1
- package/lib/module/pin/index.js +0 -4
- package/lib/module/pin/index.js.map +0 -1
- package/lib/module/pin/keypad.js +0 -191
- package/lib/module/pin/keypad.js.map +0 -1
- package/lib/module/pin/pin-code-screen.js +0 -152
- package/lib/module/pin/pin-code-screen.js.map +0 -1
- package/lib/module/screens/backup-screen.js +0 -78
- package/lib/module/screens/backup-screen.js.map +0 -1
- package/lib/module/screens/image-preview-screen.js +0 -83
- package/lib/module/screens/image-preview-screen.js.map +0 -1
- package/lib/module/screens/nerd-mode-screen.js +0 -132
- package/lib/module/screens/nerd-mode-screen.js.map +0 -1
- package/lib/module/screens/qr-code-scanner-screen.js +0 -110
- package/lib/module/screens/qr-code-scanner-screen.js.map +0 -1
- package/lib/module/screens/scroll-view-screen.js +0 -86
- package/lib/module/screens/scroll-view-screen.js.map +0 -1
- package/lib/module/screens/section-list-screen.js +0 -59
- package/lib/module/screens/section-list-screen.js.map +0 -1
- package/lib/module/searchbar/search-bar.js +0 -89
- package/lib/module/searchbar/search-bar.js.map +0 -1
- package/lib/typescript/accessibility/accessibilityHistory.d.ts +0 -13
- package/lib/typescript/buttons/back-button.d.ts +0 -9
- package/lib/typescript/credential/card/credential-card.d.ts +0 -22
- package/lib/typescript/credential/card/index.d.ts +0 -10
- package/lib/typescript/credential/credential-attribute-item.d.ts +0 -48
- package/lib/typescript/entity/avatar.d.ts +0 -10
- package/lib/typescript/entity/entity-cluster.d.ts +0 -12
- package/lib/typescript/pin/index.d.ts +0 -3
- package/lib/typescript/screens/nerd-mode-screen.d.ts +0 -22
- package/lib/typescript/text/typography.d.ts +0 -112
- package/src/accessibility/accessibilityHistory.tsx +0 -77
- package/src/blur/blur-view.tsx +0 -82
- package/src/buttons/back-button.tsx +0 -31
- package/src/buttons/button.tsx +0 -169
- package/src/buttons/connectivity-button.tsx +0 -95
- package/src/credential/card/credential-card.stories.tsx +0 -52
- package/src/credential/card/credential-card.tsx +0 -195
- package/src/credential/card/credential-details-card.stories.tsx +0 -268
- package/src/credential/card/credential-details-card.tsx +0 -242
- package/src/credential/card/credential-header.stories.tsx +0 -50
- package/src/credential/card/credential-header.tsx +0 -195
- package/src/credential/card/credential-image-carousel.tsx +0 -113
- package/src/credential/card/index.ts +0 -11
- package/src/credential/credential-attribute-item.tsx +0 -372
- package/src/credential/selector.tsx +0 -64
- package/src/detail/detail.stories.tsx +0 -65
- package/src/detail/detail.tsx +0 -98
- package/src/entity/avatar.tsx +0 -87
- package/src/entity/entity-cluster.tsx +0 -72
- package/src/header/header.stories.tsx +0 -59
- package/src/header/header.tsx +0 -105
- package/src/header/navigation-header.stories.tsx +0 -56
- package/src/header/navigation-header.tsx +0 -147
- package/src/history/data-item.tsx +0 -79
- package/src/history/history-list-item.tsx +0 -102
- package/src/history/history-section-header.tsx +0 -44
- package/src/icons/entity.tsx +0 -21
- package/src/input/selection-input.tsx +0 -112
- package/src/input/text-input.tsx +0 -253
- package/src/loader/loader.tsx +0 -169
- package/src/nerd-view/nerd-mode-item.tsx +0 -296
- package/src/pin/index.ts +0 -4
- package/src/pin/keypad.tsx +0 -166
- package/src/pin/pin-code-screen.tsx +0 -195
- package/src/screens/backup-screen.tsx +0 -92
- package/src/screens/image-preview-screen.stories.tsx +0 -28
- package/src/screens/image-preview-screen.tsx +0 -82
- package/src/screens/nerd-mode-screen.tsx +0 -150
- package/src/screens/qr-code-scanner-screen.stories.tsx +0 -37
- package/src/screens/qr-code-scanner-screen.tsx +0 -124
- package/src/screens/scroll-view-screen.tsx +0 -91
- package/src/screens/section-list-screen.tsx +0 -61
- package/src/searchbar/search-bar.tsx +0 -94
- package/src/text/typography.stories.tsx +0 -70
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/accessibility.js +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/accessibility.js.map +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/accessibilityHistoryWrappers.js +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/accessibilityHistoryWrappers.js.map +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/accessibilityLanguage.js +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/accessibilityLanguage.js.map +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/index.js +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/index.js.map +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale/de.json +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale/en.json +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale/fr.json +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale/index.js +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale/index.js.map +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale/it.json +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale.test.js +0 -0
- /package/lib/commonjs/{accessibility → ui-components/accessibility}/locale.test.js.map +0 -0
- /package/lib/commonjs/{action-modal → ui-components/action-modal}/ActionModal.js +0 -0
- /package/lib/commonjs/{action-modal → ui-components/action-modal}/ActionModal.js.map +0 -0
- /package/lib/commonjs/{action-modal → ui-components/action-modal}/index.js +0 -0
- /package/lib/commonjs/{action-modal → ui-components/action-modal}/index.js.map +0 -0
- /package/lib/commonjs/{activity-indicator → ui-components/activity-indicator}/activity-indicator.js +0 -0
- /package/lib/commonjs/{activity-indicator → ui-components/activity-indicator}/activity-indicator.js.map +0 -0
- /package/lib/commonjs/{activity-indicator → ui-components/activity-indicator}/index.js +0 -0
- /package/lib/commonjs/{activity-indicator → ui-components/activity-indicator}/index.js.map +0 -0
- /package/lib/commonjs/{blur → ui-components/blur}/index.js +0 -0
- /package/lib/commonjs/{blur → ui-components/blur}/index.js.map +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/back-button.js +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/filter-button.js +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/filter-button.js.map +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/ghost-button.js +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/ghost-button.js.map +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/index.js +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/index.js.map +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/scan-button.js +0 -0
- /package/lib/commonjs/{buttons → ui-components/buttons}/scan-button.js.map +0 -0
- /package/lib/commonjs/{camera → ui-components/camera}/camera-overlay.js +0 -0
- /package/lib/commonjs/{camera → ui-components/camera}/camera-overlay.js.map +0 -0
- /package/lib/commonjs/{camera → ui-components/camera}/index.js +0 -0
- /package/lib/commonjs/{camera → ui-components/camera}/index.js.map +0 -0
- /package/lib/commonjs/{camera → ui-components/camera}/qr-code-scanner.js +0 -0
- /package/lib/commonjs/{camera → ui-components/camera}/qr-code-scanner.js.map +0 -0
- /package/lib/commonjs/{control → ui-components/control}/checkbox.js +0 -0
- /package/lib/commonjs/{control → ui-components/control}/checkbox.js.map +0 -0
- /package/lib/commonjs/{control → ui-components/control}/index.js +0 -0
- /package/lib/commonjs/{control → ui-components/control}/index.js.map +0 -0
- /package/lib/commonjs/{control → ui-components/control}/switch.js +0 -0
- /package/lib/commonjs/{control → ui-components/control}/switch.js.map +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/card/credential-details-list-item.js +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/card/credential-details-list-item.js.map +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/credential-carousel-images.js +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/credential-carousel-images.js.map +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/index.js +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/index.js.map +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/selector-status.js +0 -0
- /package/lib/commonjs/{credential → ui-components/credential}/selector-status.js.map +0 -0
- /package/lib/commonjs/{detail → ui-components/detail}/index.js +0 -0
- /package/lib/commonjs/{detail → ui-components/detail}/index.js.map +0 -0
- /package/lib/commonjs/{entity → ui-components/entity}/index.js +0 -0
- /package/lib/commonjs/{entity → ui-components/entity}/index.js.map +0 -0
- /package/lib/commonjs/{header → ui-components/header}/focus-aware-status-bar.js +0 -0
- /package/lib/commonjs/{header → ui-components/header}/focus-aware-status-bar.js.map +0 -0
- /package/lib/commonjs/{header → ui-components/header}/foldable-header.js +0 -0
- /package/lib/commonjs/{header → ui-components/header}/foldable-header.js.map +0 -0
- /package/lib/commonjs/{header → ui-components/header}/index.js +0 -0
- /package/lib/commonjs/{header → ui-components/header}/index.js.map +0 -0
- /package/lib/commonjs/{history → ui-components/history}/history-section-list-item.js +0 -0
- /package/lib/commonjs/{history → ui-components/history}/history-section-list-item.js.map +0 -0
- /package/lib/commonjs/{history → ui-components/history}/index.js +0 -0
- /package/lib/commonjs/{history → ui-components/history}/index.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/connectivity.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/connectivity.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/credential.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/credential.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/history.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/history.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/icons.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/icons.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/index.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/index.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/input.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/input.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/keypad.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/keypad.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/loader.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/loader.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/nerd-view.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/nerd-view.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/selector.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/selector.js.map +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/wallet.js +0 -0
- /package/lib/commonjs/{icons → ui-components/icons}/wallet.js.map +0 -0
- /package/lib/commonjs/{image → ui-components/image}/image-or-component.js +0 -0
- /package/lib/commonjs/{image → ui-components/image}/image-or-component.js.map +0 -0
- /package/lib/commonjs/{image → ui-components/image}/index.js +0 -0
- /package/lib/commonjs/{image → ui-components/image}/index.js.map +0 -0
- /package/lib/commonjs/{input → ui-components/input}/index.js +0 -0
- /package/lib/commonjs/{input → ui-components/input}/index.js.map +0 -0
- /package/lib/commonjs/{input → ui-components/input}/radio-group.js +0 -0
- /package/lib/commonjs/{input → ui-components/input}/radio-group.js.map +0 -0
- /package/lib/commonjs/{list → ui-components/list}/index.js +0 -0
- /package/lib/commonjs/{list → ui-components/list}/index.js.map +0 -0
- /package/lib/commonjs/{list → ui-components/list}/list-section-header.js +0 -0
- /package/lib/commonjs/{list → ui-components/list}/list-section-header.js.map +0 -0
- /package/lib/commonjs/{list → ui-components/list}/list-title-header.js +0 -0
- /package/lib/commonjs/{list → ui-components/list}/list-title-header.js.map +0 -0
- /package/lib/commonjs/{loader → ui-components/loader}/index.js +0 -0
- /package/lib/commonjs/{loader → ui-components/loader}/index.js.map +0 -0
- /package/lib/commonjs/{loader → ui-components/loader}/loading-result.js +0 -0
- /package/lib/commonjs/{loader → ui-components/loader}/loading-result.js.map +0 -0
- /package/lib/commonjs/{nerd-view → ui-components/nerd-view}/index.js +0 -0
- /package/lib/commonjs/{nerd-view → ui-components/nerd-view}/index.js.map +0 -0
- /package/lib/commonjs/{pin → ui-components/pin}/pins.js +0 -0
- /package/lib/commonjs/{pin → ui-components/pin}/pins.js.map +0 -0
- /package/lib/commonjs/{screens → ui-components/screens}/index.js +0 -0
- /package/lib/commonjs/{screens → ui-components/screens}/index.js.map +0 -0
- /package/lib/commonjs/{searchbar → ui-components/searchbar}/animated-search-bar.js +0 -0
- /package/lib/commonjs/{searchbar → ui-components/searchbar}/animated-search-bar.js.map +0 -0
- /package/lib/commonjs/{searchbar → ui-components/searchbar}/index.js +0 -0
- /package/lib/commonjs/{searchbar → ui-components/searchbar}/index.js.map +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/button-setting.js +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/button-setting.js.map +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/index.js +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/index.js.map +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/setting-item-separator.js +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/setting-item-separator.js.map +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/setting-item.js +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/setting-item.js.map +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/settings-button.js +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/settings-button.js.map +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/switch-setting.js +0 -0
- /package/lib/commonjs/{settings → ui-components/settings}/switch-setting.js.map +0 -0
- /package/lib/commonjs/{state → ui-components/state}/error-screen.js +0 -0
- /package/lib/commonjs/{state → ui-components/state}/error-screen.js.map +0 -0
- /package/lib/commonjs/{state → ui-components/state}/index.js +0 -0
- /package/lib/commonjs/{state → ui-components/state}/index.js.map +0 -0
- /package/lib/commonjs/{text → ui-components/text}/base.js +0 -0
- /package/lib/commonjs/{text → ui-components/text}/base.js.map +0 -0
- /package/lib/commonjs/{text → ui-components/text}/font.js +0 -0
- /package/lib/commonjs/{text → ui-components/text}/font.js.map +0 -0
- /package/lib/commonjs/{text → ui-components/text}/index.js +0 -0
- /package/lib/commonjs/{text → ui-components/text}/index.js.map +0 -0
- /package/lib/commonjs/{text → ui-components/text}/typography.js +0 -0
- /package/lib/commonjs/{text → ui-components/text}/typography.js.map +0 -0
- /package/lib/commonjs/{theme → ui-components/theme}/color-scheme-context.js +0 -0
- /package/lib/commonjs/{theme → ui-components/theme}/color-scheme-context.js.map +0 -0
- /package/lib/commonjs/{theme → ui-components/theme}/color-scheme.js +0 -0
- /package/lib/commonjs/{theme → ui-components/theme}/color-scheme.js.map +0 -0
- /package/lib/commonjs/{theme → ui-components/theme}/index.js +0 -0
- /package/lib/commonjs/{theme → ui-components/theme}/index.js.map +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/accessibility.js +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/accessibility.js.map +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/accessibilityHistoryWrappers.js +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/accessibilityHistoryWrappers.js.map +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/accessibilityLanguage.js +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/accessibilityLanguage.js.map +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/index.js +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/index.js.map +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale/de.json +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale/en.json +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale/fr.json +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale/index.js +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale/index.js.map +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale/it.json +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale.test.js +0 -0
- /package/lib/module/{accessibility → ui-components/accessibility}/locale.test.js.map +0 -0
- /package/lib/module/{action-modal → ui-components/action-modal}/ActionModal.js +0 -0
- /package/lib/module/{action-modal → ui-components/action-modal}/ActionModal.js.map +0 -0
- /package/lib/module/{action-modal → ui-components/action-modal}/index.js +0 -0
- /package/lib/module/{action-modal → ui-components/action-modal}/index.js.map +0 -0
- /package/lib/module/{activity-indicator → ui-components/activity-indicator}/activity-indicator.js +0 -0
- /package/lib/module/{activity-indicator → ui-components/activity-indicator}/activity-indicator.js.map +0 -0
- /package/lib/module/{activity-indicator → ui-components/activity-indicator}/index.js +0 -0
- /package/lib/module/{activity-indicator → ui-components/activity-indicator}/index.js.map +0 -0
- /package/lib/module/{blur → ui-components/blur}/index.js +0 -0
- /package/lib/module/{blur → ui-components/blur}/index.js.map +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/back-button.js +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/filter-button.js +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/filter-button.js.map +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/ghost-button.js +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/ghost-button.js.map +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/index.js +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/index.js.map +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/scan-button.js +0 -0
- /package/lib/module/{buttons → ui-components/buttons}/scan-button.js.map +0 -0
- /package/lib/module/{camera → ui-components/camera}/camera-overlay.js +0 -0
- /package/lib/module/{camera → ui-components/camera}/camera-overlay.js.map +0 -0
- /package/lib/module/{camera → ui-components/camera}/index.js +0 -0
- /package/lib/module/{camera → ui-components/camera}/index.js.map +0 -0
- /package/lib/module/{camera → ui-components/camera}/qr-code-scanner.js +0 -0
- /package/lib/module/{camera → ui-components/camera}/qr-code-scanner.js.map +0 -0
- /package/lib/module/{control → ui-components/control}/checkbox.js +0 -0
- /package/lib/module/{control → ui-components/control}/checkbox.js.map +0 -0
- /package/lib/module/{control → ui-components/control}/index.js +0 -0
- /package/lib/module/{control → ui-components/control}/index.js.map +0 -0
- /package/lib/module/{control → ui-components/control}/switch.js +0 -0
- /package/lib/module/{control → ui-components/control}/switch.js.map +0 -0
- /package/lib/module/{credential → ui-components/credential}/card/credential-details-list-item.js +0 -0
- /package/lib/module/{credential → ui-components/credential}/card/credential-details-list-item.js.map +0 -0
- /package/lib/module/{credential → ui-components/credential}/credential-carousel-images.js +0 -0
- /package/lib/module/{credential → ui-components/credential}/credential-carousel-images.js.map +0 -0
- /package/lib/module/{credential → ui-components/credential}/index.js +0 -0
- /package/lib/module/{credential → ui-components/credential}/index.js.map +0 -0
- /package/lib/module/{credential → ui-components/credential}/selector-status.js +0 -0
- /package/lib/module/{credential → ui-components/credential}/selector-status.js.map +0 -0
- /package/lib/module/{detail → ui-components/detail}/index.js +0 -0
- /package/lib/module/{detail → ui-components/detail}/index.js.map +0 -0
- /package/lib/module/{entity → ui-components/entity}/index.js +0 -0
- /package/lib/module/{entity → ui-components/entity}/index.js.map +0 -0
- /package/lib/module/{header → ui-components/header}/focus-aware-status-bar.js +0 -0
- /package/lib/module/{header → ui-components/header}/focus-aware-status-bar.js.map +0 -0
- /package/lib/module/{header → ui-components/header}/foldable-header.js +0 -0
- /package/lib/module/{header → ui-components/header}/foldable-header.js.map +0 -0
- /package/lib/module/{header → ui-components/header}/index.js +0 -0
- /package/lib/module/{header → ui-components/header}/index.js.map +0 -0
- /package/lib/module/{history → ui-components/history}/history-section-list-item.js +0 -0
- /package/lib/module/{history → ui-components/history}/history-section-list-item.js.map +0 -0
- /package/lib/module/{history → ui-components/history}/index.js +0 -0
- /package/lib/module/{history → ui-components/history}/index.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/connectivity.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/connectivity.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/credential.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/credential.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/history.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/history.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/icons.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/icons.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/index.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/index.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/input.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/input.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/keypad.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/keypad.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/loader.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/loader.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/nerd-view.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/nerd-view.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/selector.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/selector.js.map +0 -0
- /package/lib/module/{icons → ui-components/icons}/wallet.js +0 -0
- /package/lib/module/{icons → ui-components/icons}/wallet.js.map +0 -0
- /package/lib/module/{image → ui-components/image}/image-or-component.js +0 -0
- /package/lib/module/{image → ui-components/image}/image-or-component.js.map +0 -0
- /package/lib/module/{image → ui-components/image}/index.js +0 -0
- /package/lib/module/{image → ui-components/image}/index.js.map +0 -0
- /package/lib/module/{input → ui-components/input}/index.js +0 -0
- /package/lib/module/{input → ui-components/input}/index.js.map +0 -0
- /package/lib/module/{input → ui-components/input}/radio-group.js +0 -0
- /package/lib/module/{input → ui-components/input}/radio-group.js.map +0 -0
- /package/lib/module/{list → ui-components/list}/index.js +0 -0
- /package/lib/module/{list → ui-components/list}/index.js.map +0 -0
- /package/lib/module/{list → ui-components/list}/list-section-header.js +0 -0
- /package/lib/module/{list → ui-components/list}/list-section-header.js.map +0 -0
- /package/lib/module/{list → ui-components/list}/list-title-header.js +0 -0
- /package/lib/module/{list → ui-components/list}/list-title-header.js.map +0 -0
- /package/lib/module/{loader → ui-components/loader}/index.js +0 -0
- /package/lib/module/{loader → ui-components/loader}/index.js.map +0 -0
- /package/lib/module/{loader → ui-components/loader}/loading-result.js +0 -0
- /package/lib/module/{loader → ui-components/loader}/loading-result.js.map +0 -0
- /package/lib/module/{nerd-view → ui-components/nerd-view}/index.js +0 -0
- /package/lib/module/{nerd-view → ui-components/nerd-view}/index.js.map +0 -0
- /package/lib/module/{pin → ui-components/pin}/pins.js +0 -0
- /package/lib/module/{pin → ui-components/pin}/pins.js.map +0 -0
- /package/lib/module/{screens → ui-components/screens}/index.js +0 -0
- /package/lib/module/{screens → ui-components/screens}/index.js.map +0 -0
- /package/lib/module/{searchbar → ui-components/searchbar}/animated-search-bar.js +0 -0
- /package/lib/module/{searchbar → ui-components/searchbar}/animated-search-bar.js.map +0 -0
- /package/lib/module/{searchbar → ui-components/searchbar}/index.js +0 -0
- /package/lib/module/{searchbar → ui-components/searchbar}/index.js.map +0 -0
- /package/lib/module/{settings → ui-components/settings}/button-setting.js +0 -0
- /package/lib/module/{settings → ui-components/settings}/button-setting.js.map +0 -0
- /package/lib/module/{settings → ui-components/settings}/index.js +0 -0
- /package/lib/module/{settings → ui-components/settings}/index.js.map +0 -0
- /package/lib/module/{settings → ui-components/settings}/setting-item-separator.js +0 -0
- /package/lib/module/{settings → ui-components/settings}/setting-item-separator.js.map +0 -0
- /package/lib/module/{settings → ui-components/settings}/setting-item.js +0 -0
- /package/lib/module/{settings → ui-components/settings}/setting-item.js.map +0 -0
- /package/lib/module/{settings → ui-components/settings}/settings-button.js +0 -0
- /package/lib/module/{settings → ui-components/settings}/settings-button.js.map +0 -0
- /package/lib/module/{settings → ui-components/settings}/switch-setting.js +0 -0
- /package/lib/module/{settings → ui-components/settings}/switch-setting.js.map +0 -0
- /package/lib/module/{state → ui-components/state}/error-screen.js +0 -0
- /package/lib/module/{state → ui-components/state}/error-screen.js.map +0 -0
- /package/lib/module/{state → ui-components/state}/index.js +0 -0
- /package/lib/module/{state → ui-components/state}/index.js.map +0 -0
- /package/lib/module/{text → ui-components/text}/base.js +0 -0
- /package/lib/module/{text → ui-components/text}/base.js.map +0 -0
- /package/lib/module/{text → ui-components/text}/font.js +0 -0
- /package/lib/module/{text → ui-components/text}/font.js.map +0 -0
- /package/lib/module/{text → ui-components/text}/index.js +0 -0
- /package/lib/module/{text → ui-components/text}/index.js.map +0 -0
- /package/lib/module/{text → ui-components/text}/typography.js +0 -0
- /package/lib/module/{text → ui-components/text}/typography.js.map +0 -0
- /package/lib/module/{theme → ui-components/theme}/color-scheme-context.js +0 -0
- /package/lib/module/{theme → ui-components/theme}/color-scheme-context.js.map +0 -0
- /package/lib/module/{theme → ui-components/theme}/color-scheme.js +0 -0
- /package/lib/module/{theme → ui-components/theme}/color-scheme.js.map +0 -0
- /package/lib/module/{theme → ui-components/theme}/index.js +0 -0
- /package/lib/module/{theme → ui-components/theme}/index.js.map +0 -0
- /package/lib/typescript/{accessibility → ui-components/accessibility}/accessibility.d.ts +0 -0
- /package/lib/typescript/{accessibility → ui-components/accessibility}/accessibilityHistoryWrappers.d.ts +0 -0
- /package/lib/typescript/{accessibility → ui-components/accessibility}/accessibilityLanguage.d.ts +0 -0
- /package/lib/typescript/{accessibility → ui-components/accessibility}/index.d.ts +0 -0
- /package/lib/typescript/{accessibility → ui-components/accessibility}/locale/index.d.ts +0 -0
- /package/lib/typescript/{accessibility → ui-components/accessibility}/locale.test.d.ts +0 -0
- /package/lib/typescript/{action-modal → ui-components/action-modal}/ActionModal.d.ts +0 -0
- /package/lib/typescript/{action-modal → ui-components/action-modal}/index.d.ts +0 -0
- /package/lib/typescript/{activity-indicator → ui-components/activity-indicator}/activity-indicator.d.ts +0 -0
- /package/lib/typescript/{activity-indicator → ui-components/activity-indicator}/index.d.ts +0 -0
- /package/lib/typescript/{blur → ui-components/blur}/blur-view.d.ts +0 -0
- /package/lib/typescript/{blur → ui-components/blur}/index.d.ts +0 -0
- /package/lib/typescript/{buttons → ui-components/buttons}/button.d.ts +0 -0
- /package/lib/typescript/{buttons → ui-components/buttons}/connectivity-button.d.ts +0 -0
- /package/lib/typescript/{buttons → ui-components/buttons}/filter-button.d.ts +0 -0
- /package/lib/typescript/{buttons → ui-components/buttons}/ghost-button.d.ts +0 -0
- /package/lib/typescript/{buttons → ui-components/buttons}/index.d.ts +0 -0
- /package/lib/typescript/{buttons → ui-components/buttons}/scan-button.d.ts +0 -0
- /package/lib/typescript/{camera → ui-components/camera}/camera-overlay.d.ts +0 -0
- /package/lib/typescript/{camera → ui-components/camera}/index.d.ts +0 -0
- /package/lib/typescript/{camera → ui-components/camera}/qr-code-scanner.d.ts +0 -0
- /package/lib/typescript/{control → ui-components/control}/checkbox.d.ts +0 -0
- /package/lib/typescript/{control → ui-components/control}/index.d.ts +0 -0
- /package/lib/typescript/{control → ui-components/control}/switch.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/card/credential-details-card.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/card/credential-details-list-item.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/card/credential-header.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/card/credential-image-carousel.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/credential-carousel-images.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/index.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/selector-status.d.ts +0 -0
- /package/lib/typescript/{credential → ui-components/credential}/selector.d.ts +0 -0
- /package/lib/typescript/{detail → ui-components/detail}/detail.d.ts +0 -0
- /package/lib/typescript/{detail → ui-components/detail}/index.d.ts +0 -0
- /package/lib/typescript/{entity → ui-components/entity}/index.d.ts +0 -0
- /package/lib/typescript/{header → ui-components/header}/focus-aware-status-bar.d.ts +0 -0
- /package/lib/typescript/{header → ui-components/header}/foldable-header.d.ts +0 -0
- /package/lib/typescript/{header → ui-components/header}/header.d.ts +0 -0
- /package/lib/typescript/{header → ui-components/header}/index.d.ts +0 -0
- /package/lib/typescript/{header → ui-components/header}/navigation-header.d.ts +0 -0
- /package/lib/typescript/{history → ui-components/history}/data-item.d.ts +0 -0
- /package/lib/typescript/{history → ui-components/history}/history-list-item.d.ts +0 -0
- /package/lib/typescript/{history → ui-components/history}/history-section-header.d.ts +0 -0
- /package/lib/typescript/{history → ui-components/history}/history-section-list-item.d.ts +0 -0
- /package/lib/typescript/{history → ui-components/history}/index.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/connectivity.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/credential.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/entity.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/history.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/icons.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/index.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/input.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/keypad.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/loader.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/nerd-view.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/selector.d.ts +0 -0
- /package/lib/typescript/{icons → ui-components/icons}/wallet.d.ts +0 -0
- /package/lib/typescript/{image → ui-components/image}/image-or-component.d.ts +0 -0
- /package/lib/typescript/{image → ui-components/image}/index.d.ts +0 -0
- /package/lib/typescript/{input → ui-components/input}/index.d.ts +0 -0
- /package/lib/typescript/{input → ui-components/input}/radio-group.d.ts +0 -0
- /package/lib/typescript/{input → ui-components/input}/selection-input.d.ts +0 -0
- /package/lib/typescript/{input → ui-components/input}/text-input.d.ts +0 -0
- /package/lib/typescript/{list → ui-components/list}/index.d.ts +0 -0
- /package/lib/typescript/{list → ui-components/list}/list-section-header.d.ts +0 -0
- /package/lib/typescript/{list → ui-components/list}/list-title-header.d.ts +0 -0
- /package/lib/typescript/{loader → ui-components/loader}/index.d.ts +0 -0
- /package/lib/typescript/{loader → ui-components/loader}/loader.d.ts +0 -0
- /package/lib/typescript/{loader → ui-components/loader}/loading-result.d.ts +0 -0
- /package/lib/typescript/{nerd-view → ui-components/nerd-view}/index.d.ts +0 -0
- /package/lib/typescript/{nerd-view → ui-components/nerd-view}/nerd-mode-item.d.ts +0 -0
- /package/lib/typescript/{pin → ui-components/pin}/keypad.d.ts +0 -0
- /package/lib/typescript/{pin → ui-components/pin}/pin-code-screen.d.ts +0 -0
- /package/lib/typescript/{pin → ui-components/pin}/pins.d.ts +0 -0
- /package/lib/typescript/{screens → ui-components/screens}/backup-screen.d.ts +0 -0
- /package/lib/typescript/{screens → ui-components/screens}/image-preview-screen.d.ts +0 -0
- /package/lib/typescript/{screens → ui-components/screens}/index.d.ts +0 -0
- /package/lib/typescript/{screens → ui-components/screens}/qr-code-scanner-screen.d.ts +0 -0
- /package/lib/typescript/{screens → ui-components/screens}/scroll-view-screen.d.ts +0 -0
- /package/lib/typescript/{screens → ui-components/screens}/section-list-screen.d.ts +0 -0
- /package/lib/typescript/{searchbar → ui-components/searchbar}/animated-search-bar.d.ts +0 -0
- /package/lib/typescript/{searchbar → ui-components/searchbar}/index.d.ts +0 -0
- /package/lib/typescript/{searchbar → ui-components/searchbar}/search-bar.d.ts +0 -0
- /package/lib/typescript/{settings → ui-components/settings}/button-setting.d.ts +0 -0
- /package/lib/typescript/{settings → ui-components/settings}/index.d.ts +0 -0
- /package/lib/typescript/{settings → ui-components/settings}/setting-item-separator.d.ts +0 -0
- /package/lib/typescript/{settings → ui-components/settings}/setting-item.d.ts +0 -0
- /package/lib/typescript/{settings → ui-components/settings}/settings-button.d.ts +0 -0
- /package/lib/typescript/{settings → ui-components/settings}/switch-setting.d.ts +0 -0
- /package/lib/typescript/{state → ui-components/state}/error-screen.d.ts +0 -0
- /package/lib/typescript/{state → ui-components/state}/index.d.ts +0 -0
- /package/lib/typescript/{text → ui-components/text}/base.d.ts +0 -0
- /package/lib/typescript/{text → ui-components/text}/font.d.ts +0 -0
- /package/lib/typescript/{text → ui-components/text}/index.d.ts +0 -0
- /package/lib/typescript/{theme → ui-components/theme}/color-scheme-context.d.ts +0 -0
- /package/lib/typescript/{theme → ui-components/theme}/color-scheme.d.ts +0 -0
- /package/lib/typescript/{theme → ui-components/theme}/index.d.ts +0 -0
- /package/src/{accessibility → ui-components/accessibility}/accessibility.ts +0 -0
- /package/src/{accessibility → ui-components/accessibility}/accessibilityHistoryWrappers.tsx +0 -0
- /package/src/{accessibility → ui-components/accessibility}/accessibilityLanguage.tsx +0 -0
- /package/src/{accessibility → ui-components/accessibility}/index.ts +0 -0
- /package/src/{accessibility → ui-components/accessibility}/locale/de.json +0 -0
- /package/src/{accessibility → ui-components/accessibility}/locale/en.json +0 -0
- /package/src/{accessibility → ui-components/accessibility}/locale/fr.json +0 -0
- /package/src/{accessibility → ui-components/accessibility}/locale/index.ts +0 -0
- /package/src/{accessibility → ui-components/accessibility}/locale/it.json +0 -0
- /package/src/{accessibility → ui-components/accessibility}/locale.test.ts +0 -0
- /package/src/{action-modal → ui-components/action-modal}/ActionModal.stories.tsx +0 -0
- /package/src/{action-modal → ui-components/action-modal}/ActionModal.tsx +0 -0
- /package/src/{action-modal → ui-components/action-modal}/index.ts +0 -0
- /package/src/{activity-indicator → ui-components/activity-indicator}/activity-indicator.stories.tsx +0 -0
- /package/src/{activity-indicator → ui-components/activity-indicator}/activity-indicator.tsx +0 -0
- /package/src/{activity-indicator → ui-components/activity-indicator}/index.ts +0 -0
- /package/src/{blur → ui-components/blur}/index.ts +0 -0
- /package/src/{buttons → ui-components/buttons}/back-button.stories.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/button.stories.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/connectivity-button.stories.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/filter-button.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/ghost-button.stories.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/ghost-button.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/index.ts +0 -0
- /package/src/{buttons → ui-components/buttons}/scan-button.stories.tsx +0 -0
- /package/src/{buttons → ui-components/buttons}/scan-button.tsx +0 -0
- /package/src/{camera → ui-components/camera}/camera-overlay.tsx +0 -0
- /package/src/{camera → ui-components/camera}/index.tsx +0 -0
- /package/src/{camera → ui-components/camera}/qr-code-scanner.tsx +0 -0
- /package/src/{control → ui-components/control}/checkbox.stories.tsx +0 -0
- /package/src/{control → ui-components/control}/checkbox.tsx +0 -0
- /package/src/{control → ui-components/control}/index.ts +0 -0
- /package/src/{control → ui-components/control}/switch.stories.tsx +0 -0
- /package/src/{control → ui-components/control}/switch.tsx +0 -0
- /package/src/{credential → ui-components/credential}/card/credential-details-list-item.tsx +0 -0
- /package/src/{credential → ui-components/credential}/credential-carousel-images.tsx +0 -0
- /package/src/{credential → ui-components/credential}/index.ts +0 -0
- /package/src/{credential → ui-components/credential}/selector-status.ts +0 -0
- /package/src/{credential → ui-components/credential}/selector.stories.tsx +0 -0
- /package/src/{detail → ui-components/detail}/index.tsx +0 -0
- /package/src/{entity → ui-components/entity}/avatar.stories.tsx +0 -0
- /package/src/{entity → ui-components/entity}/entity-cluster.stories.tsx +0 -0
- /package/src/{entity → ui-components/entity}/index.ts +0 -0
- /package/src/{header → ui-components/header}/focus-aware-status-bar.tsx +0 -0
- /package/src/{header → ui-components/header}/foldable-header.tsx +0 -0
- /package/src/{header → ui-components/header}/index.ts +0 -0
- /package/src/{history → ui-components/history}/history-section-list-item.tsx +0 -0
- /package/src/{history → ui-components/history}/index.ts +0 -0
- /package/src/{icons → ui-components/icons}/connectivity.tsx +0 -0
- /package/src/{icons → ui-components/icons}/credential.tsx +0 -0
- /package/src/{icons → ui-components/icons}/history.tsx +0 -0
- /package/src/{icons → ui-components/icons}/icons.tsx +0 -0
- /package/src/{icons → ui-components/icons}/index.ts +0 -0
- /package/src/{icons → ui-components/icons}/input.tsx +0 -0
- /package/src/{icons → ui-components/icons}/keypad.tsx +0 -0
- /package/src/{icons → ui-components/icons}/loader.tsx +0 -0
- /package/src/{icons → ui-components/icons}/nerd-view.tsx +0 -0
- /package/src/{icons → ui-components/icons}/selector.tsx +0 -0
- /package/src/{icons → ui-components/icons}/wallet.tsx +0 -0
- /package/src/{image → ui-components/image}/image-or-component.tsx +0 -0
- /package/src/{image → ui-components/image}/index.tsx +0 -0
- /package/src/{input → ui-components/input}/index.ts +0 -0
- /package/src/{input → ui-components/input}/radio-group.tsx +0 -0
- /package/src/{input → ui-components/input}/selection-input.stories.tsx +0 -0
- /package/src/{list → ui-components/list}/index.ts +0 -0
- /package/src/{list → ui-components/list}/list-section-header.tsx +0 -0
- /package/src/{list → ui-components/list}/list-title-header.tsx +0 -0
- /package/src/{loader → ui-components/loader}/index.ts +0 -0
- /package/src/{loader → ui-components/loader}/loader.stories.tsx +0 -0
- /package/src/{loader → ui-components/loader}/loading-result.stories.tsx +0 -0
- /package/src/{loader → ui-components/loader}/loading-result.tsx +0 -0
- /package/src/{nerd-view → ui-components/nerd-view}/index.ts +0 -0
- /package/src/{pin → ui-components/pin}/pin-code-screen.stories.tsx +0 -0
- /package/src/{pin → ui-components/pin}/pins.tsx +0 -0
- /package/src/{screens → ui-components/screens}/index.ts +0 -0
- /package/src/{searchbar → ui-components/searchbar}/animated-search-bar.tsx +0 -0
- /package/src/{searchbar → ui-components/searchbar}/index.ts +0 -0
- /package/src/{searchbar → ui-components/searchbar}/search-bar.stories.tsx +0 -0
- /package/src/{settings → ui-components/settings}/button-setting.tsx +0 -0
- /package/src/{settings → ui-components/settings}/index.ts +0 -0
- /package/src/{settings → ui-components/settings}/setting-item-separator.tsx +0 -0
- /package/src/{settings → ui-components/settings}/setting-item.tsx +0 -0
- /package/src/{settings → ui-components/settings}/settings-button.tsx +0 -0
- /package/src/{settings → ui-components/settings}/switch-setting.tsx +0 -0
- /package/src/{state → ui-components/state}/error-screen.stories.tsx +0 -0
- /package/src/{state → ui-components/state}/error-screen.tsx +0 -0
- /package/src/{state → ui-components/state}/index.ts +0 -0
- /package/src/{text → ui-components/text}/base.tsx +0 -0
- /package/src/{text → ui-components/text}/font.ts +0 -0
- /package/src/{text → ui-components/text}/index.ts +0 -0
- /package/src/{text → ui-components/text}/typography.tsx +0 -0
- /package/src/{theme → ui-components/theme}/color-scheme-context.tsx +0 -0
- /package/src/{theme → ui-components/theme}/color-scheme.ts +0 -0
- /package/src/{theme → ui-components/theme}/index.ts +0 -0
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.validityCheckedCardFromCredential = exports.shareCredentialCardFromCredential = exports.shareCredentialCardAttributeFromClaim = exports.selectCredentialCardFromCredential = exports.selectCredentialCardAttributeFromClaim = exports.missingCredentialCardFromRequest = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _credential = require("../../ui-components/credential");
|
|
9
|
+
var _icons = require("../../ui-components/icons");
|
|
10
|
+
var _testID = require("../testID");
|
|
11
|
+
var _credential2 = require("./credential");
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
const validityCheckedCardFromCredential = (credential, invalidLVVC, expanded, multipleCredentialsAvailable, config, notice, testID, labels) => {
|
|
14
|
+
let credentialHeaderDetail;
|
|
15
|
+
if (invalidLVVC) {
|
|
16
|
+
credentialHeaderDetail = {
|
|
17
|
+
credentialDetailErrorColor: true,
|
|
18
|
+
credentialDetailPrimary: labels.revoked,
|
|
19
|
+
credentialDetailTestID: (0, _testID.concatTestID)(testID, 'header.invalid')
|
|
20
|
+
};
|
|
21
|
+
} else if (!expanded && multipleCredentialsAvailable) {
|
|
22
|
+
credentialHeaderDetail = {
|
|
23
|
+
credentialDetailPrimary: labels.multipleCredentials,
|
|
24
|
+
credentialDetailTestID: (0, _testID.concatTestID)(testID, 'header.multiple'),
|
|
25
|
+
statusIcon: _icons.CredentialWarningIcon
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
const card = (0, _credential2.getCredentialCardPropsFromCredential)(credential, credential.claims, config, notice, testID, labels);
|
|
29
|
+
return {
|
|
30
|
+
...card,
|
|
31
|
+
header: {
|
|
32
|
+
...card.header,
|
|
33
|
+
...credentialHeaderDetail
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
exports.validityCheckedCardFromCredential = validityCheckedCardFromCredential;
|
|
38
|
+
const missingCredentialCardFromRequest = (request, notice, testID, labels) => {
|
|
39
|
+
var _request$name;
|
|
40
|
+
return {
|
|
41
|
+
cardImage: undefined,
|
|
42
|
+
color: undefined,
|
|
43
|
+
testID,
|
|
44
|
+
header: {
|
|
45
|
+
credentialDetailErrorColor: true,
|
|
46
|
+
credentialDetailPrimary: labels.missingCredential,
|
|
47
|
+
credentialDetailTestID: (0, _testID.concatTestID)(testID, 'header.missing'),
|
|
48
|
+
credentialName: (_request$name = request.name) !== null && _request$name !== void 0 ? _request$name : request.id,
|
|
49
|
+
statusIcon: _icons.CredentialWarningIcon
|
|
50
|
+
},
|
|
51
|
+
...notice
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
exports.missingCredentialCardFromRequest = missingCredentialCardFromRequest;
|
|
55
|
+
const getAttributeSelectorStatus = (field, validityState, credential, claim, selected) => {
|
|
56
|
+
if (!credential || validityState !== _credential2.ValidityState.Valid) {
|
|
57
|
+
return _credential.SelectorStatus.Rejected;
|
|
58
|
+
}
|
|
59
|
+
if (field.required) {
|
|
60
|
+
if (claim) {
|
|
61
|
+
return _credential.SelectorStatus.Required;
|
|
62
|
+
} else {
|
|
63
|
+
return _credential.SelectorStatus.Rejected;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
if (!claim) {
|
|
67
|
+
return _credential.SelectorStatus.Disabled;
|
|
68
|
+
}
|
|
69
|
+
return selected ? _credential.SelectorStatus.SelectedCheckmark : _credential.SelectorStatus.Empty;
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
// Returns a spread list of all claims with their full JSON path as key, including all intermediate objects
|
|
73
|
+
const spreadClaims = function (claims) {
|
|
74
|
+
let parentClaimPath = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
75
|
+
return claims.reduce((acc, claim) => {
|
|
76
|
+
const result = [claim];
|
|
77
|
+
if (Array.isArray(claim.value)) {
|
|
78
|
+
const claimPath = parentClaimPath ? `${parentClaimPath}/${claim.key}` : claim.key;
|
|
79
|
+
result.push(...spreadClaims(claim.value, claimPath));
|
|
80
|
+
}
|
|
81
|
+
return [...acc, ...result];
|
|
82
|
+
}, []);
|
|
83
|
+
};
|
|
84
|
+
const getDisplayedAttributes = (request, validityState, credential, selectiveDisclosureSupported, selectedFields) => {
|
|
85
|
+
if (credential && selectiveDisclosureSupported === false) {
|
|
86
|
+
return credential.claims.map(claim => ({
|
|
87
|
+
claim,
|
|
88
|
+
id: claim.id,
|
|
89
|
+
status: _credential.SelectorStatus.Required
|
|
90
|
+
}));
|
|
91
|
+
}
|
|
92
|
+
return request.fields.map(field => {
|
|
93
|
+
const selected = !field.required && (selectedFields === null || selectedFields === void 0 ? void 0 : selectedFields.includes(field.id));
|
|
94
|
+
const claim = credential && spreadClaims(credential.claims).find(_ref => {
|
|
95
|
+
let {
|
|
96
|
+
key
|
|
97
|
+
} = _ref;
|
|
98
|
+
return key === field.keyMap[credential.id];
|
|
99
|
+
});
|
|
100
|
+
const status = getAttributeSelectorStatus(field, validityState, credential, claim, selected);
|
|
101
|
+
return {
|
|
102
|
+
claim,
|
|
103
|
+
field,
|
|
104
|
+
id: field.id,
|
|
105
|
+
selected,
|
|
106
|
+
status
|
|
107
|
+
};
|
|
108
|
+
});
|
|
109
|
+
};
|
|
110
|
+
const shareCredentialCardAttributeFromClaim = (id, config, testID, labels, claim, field) => {
|
|
111
|
+
var _field$name$split$pop, _field$name, _field$name2;
|
|
112
|
+
if (claim) {
|
|
113
|
+
return {
|
|
114
|
+
...(0, _credential2.detailsCardAttributeFromClaim)(claim, config, testID),
|
|
115
|
+
id
|
|
116
|
+
};
|
|
117
|
+
}
|
|
118
|
+
return {
|
|
119
|
+
id,
|
|
120
|
+
name: (_field$name$split$pop = field === null || field === void 0 ? void 0 : (_field$name = field.name) === null || _field$name === void 0 ? void 0 : _field$name.split('/').pop()) !== null && _field$name$split$pop !== void 0 ? _field$name$split$pop : id,
|
|
121
|
+
path: (_field$name2 = field === null || field === void 0 ? void 0 : field.name) !== null && _field$name2 !== void 0 ? _field$name2 : id,
|
|
122
|
+
value: labels.missingAttribute,
|
|
123
|
+
valueErrorColor: true
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
|
|
127
|
+
// Will propagate the attribute status (right accessory + selected?) for all nested attributes
|
|
128
|
+
// Note: This function MUTATES the input attribute
|
|
129
|
+
exports.shareCredentialCardAttributeFromClaim = shareCredentialCardAttributeFromClaim;
|
|
130
|
+
const setStatusForNestedObjectOrArrayFields = (attribute, status, disabled) => {
|
|
131
|
+
const accessory = status && /*#__PURE__*/_react.default.createElement(_credential.Selector, {
|
|
132
|
+
status: status
|
|
133
|
+
});
|
|
134
|
+
const isObject = attribute.attributes && attribute.attributes.length > 0;
|
|
135
|
+
const isArray = attribute.values && attribute.values.length > 0;
|
|
136
|
+
|
|
137
|
+
// If the attribute is not an object or array, we update the attribute and return
|
|
138
|
+
if (!isObject && !isArray) {
|
|
139
|
+
attribute.rightAccessory = accessory;
|
|
140
|
+
attribute.disabled = disabled;
|
|
141
|
+
return attribute;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
// The object can be optional (tappable radio-checkmark), or required (checkmark)
|
|
145
|
+
if (status === _credential.SelectorStatus.SelectedCheckmark || status === _credential.SelectorStatus.Empty) {
|
|
146
|
+
// If it's a selectable object, the accessory is rendered next to the object title,
|
|
147
|
+
// The nested attributes have no accessory, and can not be selected
|
|
148
|
+
attribute.rightAccessory = accessory;
|
|
149
|
+
setStatusForNestedObjectOrArrayFields(attribute, undefined, true);
|
|
150
|
+
} else {
|
|
151
|
+
var _attribute$attributes;
|
|
152
|
+
const nested = (_attribute$attributes = attribute.attributes) !== null && _attribute$attributes !== void 0 ? _attribute$attributes : attribute.values;
|
|
153
|
+
// If the object is required / rejected, the accessory is rendered next to each nested attribute (except other object titles)
|
|
154
|
+
// all fields are disabled
|
|
155
|
+
for (const nestedAttribute of nested) {
|
|
156
|
+
setStatusForNestedObjectOrArrayFields(nestedAttribute, status, true);
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
};
|
|
160
|
+
const shareCredentialCardFromCredential = (credential, invalidLVVC, expanded, multipleCredentialsAvailable, request, selectedFields, config, testID, labels) => {
|
|
161
|
+
var _credential$issuerDid, _credential$issuerDid2;
|
|
162
|
+
const selectiveDisclosureSupported = (0, _credential2.supportsSelectiveDisclosure)(credential ? {
|
|
163
|
+
...credential,
|
|
164
|
+
issuerDid: (_credential$issuerDid = credential.issuerDid) === null || _credential$issuerDid === void 0 ? void 0 : _credential$issuerDid.did
|
|
165
|
+
} : undefined, config);
|
|
166
|
+
const notice = selectiveDisclosureSupported === false ? {
|
|
167
|
+
text: labels.selectiveDisclosureNotice,
|
|
168
|
+
noticeIcon: _icons.CredentialNoticeWarningIcon
|
|
169
|
+
} : undefined;
|
|
170
|
+
const cardTestId = (0, _testID.concatTestID)(testID, 'card');
|
|
171
|
+
const card = credential ? validityCheckedCardFromCredential(credential, invalidLVVC, expanded, multipleCredentialsAvailable, config, notice, cardTestId, labels) : missingCredentialCardFromRequest(request, notice, cardTestId, labels);
|
|
172
|
+
const validityState = (0, _credential2.getValidityState)(credential ? {
|
|
173
|
+
...credential,
|
|
174
|
+
issuerDid: (_credential$issuerDid2 = credential.issuerDid) === null || _credential$issuerDid2 === void 0 ? void 0 : _credential$issuerDid2.did
|
|
175
|
+
} : undefined);
|
|
176
|
+
const displayedAttributes = getDisplayedAttributes(request, validityState, credential, selectiveDisclosureSupported, selectedFields);
|
|
177
|
+
const attributes = displayedAttributes.map((_ref2, index) => {
|
|
178
|
+
let {
|
|
179
|
+
claim,
|
|
180
|
+
field,
|
|
181
|
+
id,
|
|
182
|
+
selected,
|
|
183
|
+
status
|
|
184
|
+
} = _ref2;
|
|
185
|
+
const disabled = !credential || !field || field.required || !claim;
|
|
186
|
+
const attribute = {
|
|
187
|
+
...shareCredentialCardAttributeFromClaim(id, config, (0, _testID.concatTestID)(testID, 'attribute', `${index}`), labels, claim, field),
|
|
188
|
+
selected
|
|
189
|
+
};
|
|
190
|
+
setStatusForNestedObjectOrArrayFields(attribute, status, disabled);
|
|
191
|
+
return attribute;
|
|
192
|
+
});
|
|
193
|
+
return {
|
|
194
|
+
attributes: (0, _credential2.nestAttributes)(attributes),
|
|
195
|
+
card
|
|
196
|
+
};
|
|
197
|
+
};
|
|
198
|
+
exports.shareCredentialCardFromCredential = shareCredentialCardFromCredential;
|
|
199
|
+
const selectCredentialCardAttributeFromClaim = (id, config, testID, labels, claim, field) => {
|
|
200
|
+
const attribute = shareCredentialCardAttributeFromClaim(id, config, testID, labels, claim, field);
|
|
201
|
+
if (!claim) {
|
|
202
|
+
return attribute;
|
|
203
|
+
}
|
|
204
|
+
return {
|
|
205
|
+
...attribute,
|
|
206
|
+
rightAccessory: _icons.RequiredAttributeIcon
|
|
207
|
+
};
|
|
208
|
+
};
|
|
209
|
+
exports.selectCredentialCardAttributeFromClaim = selectCredentialCardAttributeFromClaim;
|
|
210
|
+
const selectCredentialCardFromCredential = (credential, selected, request, config, testID, labels) => {
|
|
211
|
+
var _credential$issuerDid3;
|
|
212
|
+
const selectiveDisclosureSupported = (0, _credential2.supportsSelectiveDisclosure)(credential ? {
|
|
213
|
+
...credential,
|
|
214
|
+
issuerDid: (_credential$issuerDid3 = credential.issuerDid) === null || _credential$issuerDid3 === void 0 ? void 0 : _credential$issuerDid3.did
|
|
215
|
+
} : undefined, config);
|
|
216
|
+
const rightAccessory = /*#__PURE__*/_react.default.createElement(_credential.Selector, {
|
|
217
|
+
status: selected ? _credential.SelectorStatus.SelectedRadio : _credential.SelectorStatus.Empty
|
|
218
|
+
});
|
|
219
|
+
const notice = selectiveDisclosureSupported === false ? {
|
|
220
|
+
text: labels.selectiveDisclosureNotice,
|
|
221
|
+
noticeIcon: _icons.CredentialNoticeWarningIcon
|
|
222
|
+
} : undefined;
|
|
223
|
+
const {
|
|
224
|
+
header,
|
|
225
|
+
...cardProps
|
|
226
|
+
} = (0, _credential2.getCredentialCardPropsFromCredential)(credential, credential.claims, config, notice, testID, labels);
|
|
227
|
+
const card = {
|
|
228
|
+
header: {
|
|
229
|
+
...header,
|
|
230
|
+
accessory: rightAccessory
|
|
231
|
+
},
|
|
232
|
+
...cardProps
|
|
233
|
+
};
|
|
234
|
+
const attributes = request.fields.map(field => {
|
|
235
|
+
const claim = spreadClaims(credential.claims).find(_ref3 => {
|
|
236
|
+
let {
|
|
237
|
+
key
|
|
238
|
+
} = _ref3;
|
|
239
|
+
return key === field.keyMap[credential.id];
|
|
240
|
+
});
|
|
241
|
+
const attribute = selectCredentialCardAttributeFromClaim(field.id, config, testID, labels, claim, field);
|
|
242
|
+
return {
|
|
243
|
+
...attribute,
|
|
244
|
+
rightAccessory: /*#__PURE__*/_react.default.createElement(_credential.Selector, {
|
|
245
|
+
status: field.required && !claim ? _credential.SelectorStatus.Rejected : _credential.SelectorStatus.Required
|
|
246
|
+
})
|
|
247
|
+
};
|
|
248
|
+
});
|
|
249
|
+
return {
|
|
250
|
+
attributes: (0, _credential2.nestAttributes)(attributes),
|
|
251
|
+
card
|
|
252
|
+
};
|
|
253
|
+
};
|
|
254
|
+
exports.selectCredentialCardFromCredential = selectCredentialCardFromCredential;
|
|
255
|
+
//# sourceMappingURL=credential-sharing.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_credential","_icons","_testID","_credential2","obj","__esModule","default","validityCheckedCardFromCredential","credential","invalidLVVC","expanded","multipleCredentialsAvailable","config","notice","testID","labels","credentialHeaderDetail","credentialDetailErrorColor","credentialDetailPrimary","revoked","credentialDetailTestID","concatTestID","multipleCredentials","statusIcon","CredentialWarningIcon","card","getCredentialCardPropsFromCredential","claims","header","exports","missingCredentialCardFromRequest","request","_request$name","cardImage","undefined","color","missingCredential","credentialName","name","id","getAttributeSelectorStatus","field","validityState","claim","selected","ValidityState","Valid","SelectorStatus","Rejected","required","Required","Disabled","SelectedCheckmark","Empty","spreadClaims","parentClaimPath","arguments","length","reduce","acc","result","Array","isArray","value","claimPath","key","push","getDisplayedAttributes","selectiveDisclosureSupported","selectedFields","map","status","fields","includes","find","_ref","keyMap","shareCredentialCardAttributeFromClaim","_field$name$split$pop","_field$name","_field$name2","detailsCardAttributeFromClaim","split","pop","path","missingAttribute","valueErrorColor","setStatusForNestedObjectOrArrayFields","attribute","disabled","accessory","createElement","Selector","isObject","attributes","values","rightAccessory","_attribute$attributes","nested","nestedAttribute","shareCredentialCardFromCredential","_credential$issuerDid","_credential$issuerDid2","supportsSelectiveDisclosure","issuerDid","did","text","selectiveDisclosureNotice","noticeIcon","CredentialNoticeWarningIcon","cardTestId","getValidityState","displayedAttributes","_ref2","index","nestAttributes","selectCredentialCardAttributeFromClaim","RequiredAttributeIcon","selectCredentialCardFromCredential","_credential$issuerDid3","SelectedRadio","cardProps","_ref3"],"sources":["credential-sharing.tsx"],"sourcesContent":["import {\n Claim,\n Config,\n CredentialDetail,\n PresentationDefinitionField,\n PresentationDefinitionRequestedCredential,\n} from '@procivis/react-native-one-core';\nimport React from 'react';\n\nimport {\n CredentialAttribute,\n CredentialCardProps,\n CredentialDetailsCardProps,\n CredentialHeaderProps,\n Selector,\n SelectorStatus,\n} from '../../ui-components/credential';\nimport { CredentialCardNotice } from '../../ui-components/credential/card/credential-card';\nimport { CredentialNoticeWarningIcon, CredentialWarningIcon, RequiredAttributeIcon } from '../../ui-components/icons';\nimport { concatTestID } from '../testID';\nimport {\n CardLabels,\n detailsCardAttributeFromClaim,\n getCredentialCardPropsFromCredential,\n getValidityState,\n nestAttributes,\n supportsSelectiveDisclosure,\n ValidityState,\n} from './credential';\n\nexport const validityCheckedCardFromCredential = (\n credential: CredentialDetail,\n invalidLVVC: boolean,\n expanded: boolean,\n multipleCredentialsAvailable: boolean,\n config: Config,\n notice: CredentialCardNotice | undefined,\n testID: string,\n labels: ShareCredentialCardLabels,\n): Omit<CredentialCardProps, 'onHeaderPress' | 'style' | 'testID'> => {\n let credentialHeaderDetail:\n | Pick<\n CredentialHeaderProps,\n | 'credentialDetailPrimary'\n | 'credentialDetailSecondary'\n | 'credentialDetailErrorColor'\n | 'credentialDetailTestID'\n | 'statusIcon'\n >\n | undefined;\n if (invalidLVVC) {\n credentialHeaderDetail = {\n credentialDetailErrorColor: true,\n credentialDetailPrimary: labels.revoked,\n credentialDetailTestID: concatTestID(testID, 'header.invalid'),\n };\n } else if (!expanded && multipleCredentialsAvailable) {\n credentialHeaderDetail = {\n credentialDetailPrimary: labels.multipleCredentials,\n credentialDetailTestID: concatTestID(testID, 'header.multiple'),\n statusIcon: CredentialWarningIcon,\n };\n }\n\n const card = getCredentialCardPropsFromCredential(credential, credential.claims, config, notice, testID, labels);\n return {\n ...card,\n header: {\n ...card.header,\n ...credentialHeaderDetail,\n },\n };\n};\n\nexport const missingCredentialCardFromRequest = (\n request: PresentationDefinitionRequestedCredential,\n notice: CredentialCardNotice | undefined,\n testID: string,\n labels: ShareCredentialCardLabels,\n): Omit<CredentialCardProps, 'onHeaderPress' | 'style'> => {\n return {\n cardImage: undefined,\n color: undefined,\n testID,\n header: {\n credentialDetailErrorColor: true,\n credentialDetailPrimary: labels.missingCredential,\n credentialDetailTestID: concatTestID(testID, 'header.missing'),\n credentialName: request.name ?? request.id,\n statusIcon: CredentialWarningIcon,\n },\n ...notice,\n };\n};\n\ninterface DisplayedAttribute {\n claim?: Claim;\n field?: PresentationDefinitionField;\n id: string;\n selected?: boolean;\n status: SelectorStatus;\n}\n\nconst getAttributeSelectorStatus = (\n field: PresentationDefinitionField,\n validityState: ValidityState,\n credential?: CredentialDetail,\n claim?: Claim,\n selected?: boolean,\n): SelectorStatus => {\n if (!credential || validityState !== ValidityState.Valid) {\n return SelectorStatus.Rejected;\n }\n if (field.required) {\n if (claim) {\n return SelectorStatus.Required;\n } else {\n return SelectorStatus.Rejected;\n }\n }\n if (!claim) {\n return SelectorStatus.Disabled;\n }\n return selected ? SelectorStatus.SelectedCheckmark : SelectorStatus.Empty;\n};\n\n// Returns a spread list of all claims with their full JSON path as key, including all intermediate objects\nconst spreadClaims = (claims: Claim[], parentClaimPath = ''): Claim[] => {\n return claims.reduce((acc, claim) => {\n const result = [claim];\n if (Array.isArray(claim.value)) {\n const claimPath = parentClaimPath ? `${parentClaimPath}/${claim.key}` : claim.key;\n result.push(...spreadClaims(claim.value, claimPath));\n }\n return [...acc, ...result];\n }, [] as Claim[]);\n};\n\nconst getDisplayedAttributes = (\n request: PresentationDefinitionRequestedCredential,\n validityState: ValidityState,\n credential?: CredentialDetail,\n selectiveDisclosureSupported?: boolean,\n selectedFields?: string[],\n): DisplayedAttribute[] => {\n if (credential && selectiveDisclosureSupported === false) {\n return credential.claims.map((claim) => ({\n claim,\n id: claim.id,\n status: SelectorStatus.Required,\n }));\n }\n\n return request.fields.map((field) => {\n const selected = !field.required && selectedFields?.includes(field.id);\n const claim =\n credential &&\n spreadClaims(credential.claims).find(({ key }) => {\n return key === field.keyMap[credential.id];\n });\n const status = getAttributeSelectorStatus(field, validityState, credential, claim, selected);\n return { claim, field, id: field.id, selected, status };\n });\n};\n\nexport const shareCredentialCardAttributeFromClaim = (\n id: string,\n config: Config,\n testID: string,\n labels: ShareCredentialCardLabels,\n claim?: Claim,\n field?: PresentationDefinitionField,\n): CredentialAttribute => {\n if (claim) {\n return { ...detailsCardAttributeFromClaim(claim, config, testID), id };\n }\n return {\n id,\n name: field?.name?.split('/').pop() ?? id,\n path: field?.name ?? id,\n value: labels.missingAttribute,\n valueErrorColor: true,\n };\n};\n\n// Will propagate the attribute status (right accessory + selected?) for all nested attributes\n// Note: This function MUTATES the input attribute\nconst setStatusForNestedObjectOrArrayFields = (\n attribute: CredentialAttribute,\n status?: SelectorStatus,\n disabled?: boolean,\n) => {\n const accessory = status && <Selector status={status} />;\n const isObject = attribute.attributes && attribute.attributes.length > 0;\n const isArray = attribute.values && attribute.values.length > 0;\n\n // If the attribute is not an object or array, we update the attribute and return\n if (!isObject && !isArray) {\n attribute.rightAccessory = accessory;\n attribute.disabled = disabled;\n return attribute;\n }\n\n // The object can be optional (tappable radio-checkmark), or required (checkmark)\n if (status === SelectorStatus.SelectedCheckmark || status === SelectorStatus.Empty) {\n // If it's a selectable object, the accessory is rendered next to the object title,\n // The nested attributes have no accessory, and can not be selected\n attribute.rightAccessory = accessory;\n setStatusForNestedObjectOrArrayFields(attribute, undefined, true);\n } else {\n const nested = attribute.attributes ?? attribute.values;\n // If the object is required / rejected, the accessory is rendered next to each nested attribute (except other object titles)\n // all fields are disabled\n for (const nestedAttribute of nested) {\n setStatusForNestedObjectOrArrayFields(nestedAttribute, status, true);\n }\n }\n};\n\nexport type ShareCredentialCardLabels = CardLabels & {\n selectiveDisclosureNotice: string;\n missingAttribute: string;\n missingCredential: string;\n multipleCredentials: string;\n};\n\nexport const shareCredentialCardFromCredential = (\n credential: CredentialDetail | undefined,\n invalidLVVC: boolean,\n expanded: boolean,\n multipleCredentialsAvailable: boolean,\n request: PresentationDefinitionRequestedCredential,\n selectedFields: string[] | undefined,\n config: Config,\n testID: string,\n labels: ShareCredentialCardLabels,\n): Omit<CredentialDetailsCardProps, 'expanded'> => {\n const selectiveDisclosureSupported = supportsSelectiveDisclosure(\n credential ? { ...credential, issuerDid: credential.issuerDid?.did } : undefined,\n config,\n );\n const notice: CredentialCardNotice | undefined =\n selectiveDisclosureSupported === false\n ? {\n text: labels.selectiveDisclosureNotice,\n noticeIcon: CredentialNoticeWarningIcon,\n }\n : undefined;\n const cardTestId = concatTestID(testID, 'card');\n const card = credential\n ? validityCheckedCardFromCredential(\n credential,\n invalidLVVC,\n expanded,\n multipleCredentialsAvailable,\n config,\n notice,\n cardTestId,\n labels,\n )\n : missingCredentialCardFromRequest(request, notice, cardTestId, labels);\n const validityState = getValidityState(\n credential ? { ...credential, issuerDid: credential.issuerDid?.did } : undefined,\n );\n const displayedAttributes = getDisplayedAttributes(\n request,\n validityState,\n credential,\n selectiveDisclosureSupported,\n selectedFields,\n );\n\n const attributes: CredentialAttribute[] = displayedAttributes.map(({ claim, field, id, selected, status }, index) => {\n const disabled = !credential || !field || field.required || !claim;\n const attribute: CredentialAttribute = {\n ...shareCredentialCardAttributeFromClaim(\n id,\n config,\n concatTestID(testID, 'attribute', `${index}`),\n labels,\n claim,\n field,\n ),\n selected,\n };\n\n setStatusForNestedObjectOrArrayFields(attribute, status, disabled);\n return attribute;\n });\n return {\n attributes: nestAttributes(attributes),\n card,\n };\n};\n\nexport const selectCredentialCardAttributeFromClaim = (\n id: string,\n config: Config,\n testID: string,\n labels: ShareCredentialCardLabels,\n claim?: Claim,\n field?: PresentationDefinitionField,\n): CredentialAttribute => {\n const attribute = shareCredentialCardAttributeFromClaim(id, config, testID, labels, claim, field);\n if (!claim) {\n return attribute;\n }\n return {\n ...attribute,\n rightAccessory: RequiredAttributeIcon,\n };\n};\n\nexport const selectCredentialCardFromCredential = (\n credential: CredentialDetail,\n selected: boolean,\n request: PresentationDefinitionRequestedCredential,\n config: Config,\n testID: string,\n labels: ShareCredentialCardLabels,\n): Omit<CredentialDetailsCardProps, 'expanded'> => {\n const selectiveDisclosureSupported = supportsSelectiveDisclosure(\n credential ? { ...credential, issuerDid: credential.issuerDid?.did } : undefined,\n config,\n );\n const rightAccessory = <Selector status={selected ? SelectorStatus.SelectedRadio : SelectorStatus.Empty} />;\n const notice: CredentialCardNotice | undefined =\n selectiveDisclosureSupported === false\n ? {\n text: labels.selectiveDisclosureNotice,\n noticeIcon: CredentialNoticeWarningIcon,\n }\n : undefined;\n const { header, ...cardProps } = getCredentialCardPropsFromCredential(\n credential,\n credential.claims,\n config,\n notice,\n testID,\n labels,\n );\n const card = {\n header: {\n ...header,\n accessory: rightAccessory,\n },\n ...cardProps,\n };\n const attributes: CredentialAttribute[] = request.fields.map((field) => {\n const claim = spreadClaims(credential.claims).find(({ key }) => {\n return key === field.keyMap[credential.id];\n });\n\n const attribute = selectCredentialCardAttributeFromClaim(field.id, config, testID, labels, claim, field);\n return {\n ...attribute,\n rightAccessory: (\n <Selector status={field.required && !claim ? SelectorStatus.Rejected : SelectorStatus.Required} />\n ),\n };\n });\n return {\n attributes: nestAttributes(attributes),\n card,\n };\n};\n"],"mappings":";;;;;;AAOA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAEA,IAAAC,WAAA,GAAAD,OAAA;AASA,IAAAE,MAAA,GAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AACA,IAAAI,YAAA,GAAAJ,OAAA;AAQsB,SAAAD,uBAAAM,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEf,MAAMG,iCAAiC,GAAGA,CAC/CC,UAA4B,EAC5BC,WAAoB,EACpBC,QAAiB,EACjBC,4BAAqC,EACrCC,MAAc,EACdC,MAAwC,EACxCC,MAAc,EACdC,MAAiC,KACmC;EACpE,IAAIC,sBASS;EACb,IAAIP,WAAW,EAAE;IACfO,sBAAsB,GAAG;MACvBC,0BAA0B,EAAE,IAAI;MAChCC,uBAAuB,EAAEH,MAAM,CAACI,OAAO;MACvCC,sBAAsB,EAAE,IAAAC,oBAAY,EAACP,MAAM,EAAE,gBAAgB;IAC/D,CAAC;EACH,CAAC,MAAM,IAAI,CAACJ,QAAQ,IAAIC,4BAA4B,EAAE;IACpDK,sBAAsB,GAAG;MACvBE,uBAAuB,EAAEH,MAAM,CAACO,mBAAmB;MACnDF,sBAAsB,EAAE,IAAAC,oBAAY,EAACP,MAAM,EAAE,iBAAiB,CAAC;MAC/DS,UAAU,EAAEC;IACd,CAAC;EACH;EAEA,MAAMC,IAAI,GAAG,IAAAC,iDAAoC,EAAClB,UAAU,EAAEA,UAAU,CAACmB,MAAM,EAAEf,MAAM,EA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,SAAS,GAAG4B,sCAAsC,CAAC3E,KAAK,CAACF,EAAE,EAAE3B,MAAM,EAAEE,MAAM,EAAEC,MAAM,EAAE4B,KAAK,EAAEF,KAAK,CAAC;IACxG,OAAO;MACL,GAAG+C,SAAS;MACZQ,cAAc,eACZnG,MAAA,CAAAS,OAAA,CAAAqF,aAAA,CAAC3F,WAAA,CAAA4F,QAAQ;QAACrB,MAAM,EAAE9B,KAAK,CAACQ,QAAQ,IAAI,CAACN,KAAK,GAAGI,0BAAc,CAACC,QAAQ,GAAGD,0BAAc,CAACG;MAAS;IAEnG,CAAC;EACH,CAAC,CAAC;EACF,OAAO;IACL4C,UAAU,EAAE,IAAAqB,2BAAc,EAACrB,UAAU,CAAC;IACtCrE;EACF,CAAC;AACH,CAAC;AAACI,OAAA,CAAAyF,kCAAA,GAAAA,kCAAA"}
|
|
@@ -0,0 +1,323 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getCredentialCardPropsFromCredential = exports.findClaimByPath = exports.detailsCardFromCredentialWithClaims = exports.detailsCardFromCredential = exports.detailsCardAttributeFromClaim = exports.cardHeaderFromCredential = exports.ValidityState = void 0;
|
|
7
|
+
exports.getCredentialSchemaWithoutImages = getCredentialSchemaWithoutImages;
|
|
8
|
+
exports.supportsSelectiveDisclosure = exports.nestAttributes = exports.hasMsoValidityIssues = exports.getValidityState = void 0;
|
|
9
|
+
var _reactNativeOneCore = require("@procivis/react-native-one-core");
|
|
10
|
+
var _icons = require("../../ui-components/icons");
|
|
11
|
+
var _date = require("../date");
|
|
12
|
+
var _testID = require("../testID");
|
|
13
|
+
var _credentialImages = require("./credential-images");
|
|
14
|
+
let ValidityState;
|
|
15
|
+
exports.ValidityState = ValidityState;
|
|
16
|
+
(function (ValidityState) {
|
|
17
|
+
ValidityState["Revoked"] = "revoked";
|
|
18
|
+
ValidityState["Suspended"] = "suspended";
|
|
19
|
+
ValidityState["Valid"] = "valid";
|
|
20
|
+
})(ValidityState || (exports.ValidityState = ValidityState = {}));
|
|
21
|
+
const getValidityState = credential => {
|
|
22
|
+
if ((credential === null || credential === void 0 ? void 0 : credential.state) === _reactNativeOneCore.CredentialStateEnum.REVOKED) {
|
|
23
|
+
return ValidityState.Revoked;
|
|
24
|
+
}
|
|
25
|
+
if ((credential === null || credential === void 0 ? void 0 : credential.state) === _reactNativeOneCore.CredentialStateEnum.SUSPENDED) {
|
|
26
|
+
return ValidityState.Suspended;
|
|
27
|
+
}
|
|
28
|
+
return ValidityState.Valid;
|
|
29
|
+
};
|
|
30
|
+
exports.getValidityState = getValidityState;
|
|
31
|
+
const supportsSelectiveDisclosure = (credential, config) => {
|
|
32
|
+
var _formatConfig$capabil, _formatConfig$capabil2;
|
|
33
|
+
const formatConfig = credential && (config === null || config === void 0 ? void 0 : config.format[credential.schema.format]);
|
|
34
|
+
return formatConfig ? Boolean((_formatConfig$capabil = formatConfig.capabilities) === null || _formatConfig$capabil === void 0 ? void 0 : (_formatConfig$capabil2 = _formatConfig$capabil.features) === null || _formatConfig$capabil2 === void 0 ? void 0 : _formatConfig$capabil2.includes(_reactNativeOneCore.FormatFeatureEnum.SelectiveDisclosure)) : undefined;
|
|
35
|
+
};
|
|
36
|
+
exports.supportsSelectiveDisclosure = supportsSelectiveDisclosure;
|
|
37
|
+
const findClaimByPathParts = (path, claims) => {
|
|
38
|
+
if (!(claims !== null && claims !== void 0 && claims.length)) {
|
|
39
|
+
return undefined;
|
|
40
|
+
}
|
|
41
|
+
const [first, second, ...rest] = path;
|
|
42
|
+
const claim = claims.find(c => c.key === first);
|
|
43
|
+
if (claim === undefined || second === undefined || claim.dataType !== _reactNativeOneCore.DataTypeEnum.Object) {
|
|
44
|
+
return claim;
|
|
45
|
+
}
|
|
46
|
+
return findClaimByPathParts([`${first}/${second}`, ...rest], claim.value);
|
|
47
|
+
};
|
|
48
|
+
const findClaimByPath = (path, claims) => path ? findClaimByPathParts(path.split('/'), claims) : undefined;
|
|
49
|
+
exports.findClaimByPath = findClaimByPath;
|
|
50
|
+
const formatCredentialDetail = (claim, config, testID) => {
|
|
51
|
+
var _attributeValue$value;
|
|
52
|
+
const attributeValue = detailsCardAttributeValueFromClaim(claim, config, testID);
|
|
53
|
+
return (_attributeValue$value = attributeValue.value) !== null && _attributeValue$value !== void 0 ? _attributeValue$value : '';
|
|
54
|
+
};
|
|
55
|
+
const hasMsoValidityIssues = credential => {
|
|
56
|
+
const mdocMsoValidity = 'mdocMsoValidity' in credential ? credential.mdocMsoValidity : undefined;
|
|
57
|
+
const mdocMsoValidityIssue = Boolean((mdocMsoValidity === null || mdocMsoValidity === void 0 ? void 0 : mdocMsoValidity.nextUpdate) && new Date(mdocMsoValidity.nextUpdate) < new Date());
|
|
58
|
+
return mdocMsoValidityIssue;
|
|
59
|
+
};
|
|
60
|
+
exports.hasMsoValidityIssues = hasMsoValidityIssues;
|
|
61
|
+
const cardHeaderFromCredential = function (credential) {
|
|
62
|
+
var _formatDateTimeLocali, _layoutProperties$log, _layoutProperties$log2, _layoutProperties$log3;
|
|
63
|
+
let claims = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
64
|
+
let config = arguments.length > 2 ? arguments[2] : undefined;
|
|
65
|
+
let testID = arguments.length > 3 ? arguments[3] : undefined;
|
|
66
|
+
let labels = arguments.length > 4 ? arguments[4] : undefined;
|
|
67
|
+
let credentialDetailPrimary = (_formatDateTimeLocali = (0, _date.formatDateTimeLocalized)(new Date(credential.issuanceDate))) !== null && _formatDateTimeLocali !== void 0 ? _formatDateTimeLocali : '';
|
|
68
|
+
let credentialDetailSecondary;
|
|
69
|
+
let credentialDetailErrorColor;
|
|
70
|
+
let credentialDetailTestID;
|
|
71
|
+
let statusIcon;
|
|
72
|
+
const {
|
|
73
|
+
layoutProperties
|
|
74
|
+
} = credential.schema;
|
|
75
|
+
switch (credential.state) {
|
|
76
|
+
case _reactNativeOneCore.CredentialStateEnum.SUSPENDED:
|
|
77
|
+
credentialDetailPrimary = credential.suspendEndDate ? labels.suspendedUntil((0, _date.formatDateTimeLocalized)(new Date(credential.suspendEndDate))) : labels.suspended;
|
|
78
|
+
credentialDetailTestID = (0, _testID.concatTestID)(testID, 'suspended');
|
|
79
|
+
statusIcon = _icons.CredentialWarningIcon;
|
|
80
|
+
break;
|
|
81
|
+
case _reactNativeOneCore.CredentialStateEnum.REVOKED:
|
|
82
|
+
credentialDetailPrimary = labels.revoked;
|
|
83
|
+
credentialDetailErrorColor = true;
|
|
84
|
+
credentialDetailTestID = (0, _testID.concatTestID)(testID, 'revoked');
|
|
85
|
+
statusIcon = _icons.CredentialErrorIcon;
|
|
86
|
+
break;
|
|
87
|
+
default:
|
|
88
|
+
{
|
|
89
|
+
if (hasMsoValidityIssues(credential)) {
|
|
90
|
+
credentialDetailPrimary = labels.validityIssues;
|
|
91
|
+
credentialDetailTestID = (0, _testID.concatTestID)(testID, 'validity-issue');
|
|
92
|
+
statusIcon = _icons.CredentialWarningIcon;
|
|
93
|
+
} else {
|
|
94
|
+
const primary = findClaimByPath(layoutProperties === null || layoutProperties === void 0 ? void 0 : layoutProperties.primaryAttribute, claims);
|
|
95
|
+
if (primary) {
|
|
96
|
+
credentialDetailPrimary = formatCredentialDetail(primary, config, (0, _testID.concatTestID)(testID, 'primary'));
|
|
97
|
+
}
|
|
98
|
+
const secondary = findClaimByPath(layoutProperties === null || layoutProperties === void 0 ? void 0 : layoutProperties.secondaryAttribute, claims);
|
|
99
|
+
if (secondary) {
|
|
100
|
+
credentialDetailSecondary = formatCredentialDetail(secondary, config, (0, _testID.concatTestID)(testID, 'secondary'));
|
|
101
|
+
}
|
|
102
|
+
credentialDetailTestID = (0, _testID.concatTestID)(testID, 'detail');
|
|
103
|
+
}
|
|
104
|
+
break;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
return {
|
|
108
|
+
color: layoutProperties === null || layoutProperties === void 0 ? void 0 : (_layoutProperties$log = layoutProperties.logo) === null || _layoutProperties$log === void 0 ? void 0 : _layoutProperties$log.backgroundColor,
|
|
109
|
+
credentialDetailErrorColor,
|
|
110
|
+
credentialDetailPrimary,
|
|
111
|
+
credentialDetailSecondary,
|
|
112
|
+
credentialDetailTestID,
|
|
113
|
+
credentialName: credential.schema.name,
|
|
114
|
+
icon: layoutProperties !== null && layoutProperties !== void 0 && (_layoutProperties$log2 = layoutProperties.logo) !== null && _layoutProperties$log2 !== void 0 && _layoutProperties$log2.image ? {
|
|
115
|
+
imageSource: {
|
|
116
|
+
uri: layoutProperties.logo.image
|
|
117
|
+
}
|
|
118
|
+
} : undefined,
|
|
119
|
+
iconLabelColor: layoutProperties === null || layoutProperties === void 0 ? void 0 : (_layoutProperties$log3 = layoutProperties.logo) === null || _layoutProperties$log3 === void 0 ? void 0 : _layoutProperties$log3.fontColor,
|
|
120
|
+
statusIcon,
|
|
121
|
+
testID
|
|
122
|
+
};
|
|
123
|
+
};
|
|
124
|
+
exports.cardHeaderFromCredential = cardHeaderFromCredential;
|
|
125
|
+
const getCredentialCardPropsFromCredential = function (credential) {
|
|
126
|
+
var _layoutProperties$bac, _layoutProperties$bac2;
|
|
127
|
+
let claims = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
128
|
+
let config = arguments.length > 2 ? arguments[2] : undefined;
|
|
129
|
+
let notice = arguments.length > 3 ? arguments[3] : undefined;
|
|
130
|
+
let testID = arguments.length > 4 ? arguments[4] : undefined;
|
|
131
|
+
let labels = arguments.length > 5 ? arguments[5] : undefined;
|
|
132
|
+
const {
|
|
133
|
+
layoutProperties
|
|
134
|
+
} = credential.schema;
|
|
135
|
+
if (hasMsoValidityIssues(credential)) {
|
|
136
|
+
notice = {
|
|
137
|
+
text: labels.validityIssuesNotice,
|
|
138
|
+
noticeIcon: _icons.CredentialNoticeWarningIcon
|
|
139
|
+
};
|
|
140
|
+
}
|
|
141
|
+
const result = {
|
|
142
|
+
cardCarouselImages: (0, _credentialImages.getCarouselImagesFromClaims)(claims, layoutProperties, (0, _testID.concatTestID)(testID, 'carousel')),
|
|
143
|
+
cardImage: layoutProperties !== null && layoutProperties !== void 0 && (_layoutProperties$bac = layoutProperties.background) !== null && _layoutProperties$bac !== void 0 && _layoutProperties$bac.image ? {
|
|
144
|
+
imageSource: {
|
|
145
|
+
uri: layoutProperties.background.image
|
|
146
|
+
}
|
|
147
|
+
} : undefined,
|
|
148
|
+
color: layoutProperties === null || layoutProperties === void 0 ? void 0 : (_layoutProperties$bac2 = layoutProperties.background) === null || _layoutProperties$bac2 === void 0 ? void 0 : _layoutProperties$bac2.color,
|
|
149
|
+
header: cardHeaderFromCredential(credential, claims, config, (0, _testID.concatTestID)(testID, 'header'), labels),
|
|
150
|
+
testID,
|
|
151
|
+
notice
|
|
152
|
+
};
|
|
153
|
+
return result;
|
|
154
|
+
};
|
|
155
|
+
exports.getCredentialCardPropsFromCredential = getCredentialCardPropsFromCredential;
|
|
156
|
+
const detailsCardAttributeFromClaim = (claim, config, testID) => {
|
|
157
|
+
const value = detailsCardAttributeValueFromClaim(claim, config, testID);
|
|
158
|
+
return {
|
|
159
|
+
id: claim.id,
|
|
160
|
+
name: claim.key.split('/').pop(),
|
|
161
|
+
path: claim.key,
|
|
162
|
+
...value
|
|
163
|
+
};
|
|
164
|
+
};
|
|
165
|
+
exports.detailsCardAttributeFromClaim = detailsCardAttributeFromClaim;
|
|
166
|
+
const detailsCardAttributeValueFromClaim = (claim, config, testID) => {
|
|
167
|
+
const typeConfig = config === null || config === void 0 ? void 0 : config.datatype[claim.dataType];
|
|
168
|
+
if (claim.array) {
|
|
169
|
+
return {
|
|
170
|
+
values: claim.value.map((arrayValue, index) => {
|
|
171
|
+
return detailsCardAttributeFromClaim({
|
|
172
|
+
...arrayValue,
|
|
173
|
+
id: `${arrayValue.id}/${index}`
|
|
174
|
+
}, config, (0, _testID.concatTestID)(testID, index.toString()));
|
|
175
|
+
})
|
|
176
|
+
};
|
|
177
|
+
} else {
|
|
178
|
+
switch (typeConfig === null || typeConfig === void 0 ? void 0 : typeConfig.type) {
|
|
179
|
+
case _reactNativeOneCore.DataTypeEnum.Object:
|
|
180
|
+
{
|
|
181
|
+
if (!Array.isArray(claim.value)) {
|
|
182
|
+
return {
|
|
183
|
+
attributes: []
|
|
184
|
+
};
|
|
185
|
+
}
|
|
186
|
+
return {
|
|
187
|
+
attributes: claim.value.map((nestedClaim, index) => detailsCardAttributeFromClaim(nestedClaim, config, (0, _testID.concatTestID)(testID, index.toString())))
|
|
188
|
+
};
|
|
189
|
+
}
|
|
190
|
+
case _reactNativeOneCore.DataTypeEnum.Date:
|
|
191
|
+
{
|
|
192
|
+
var _formatDateLocalized;
|
|
193
|
+
const date = claim.value;
|
|
194
|
+
return {
|
|
195
|
+
testID: testID,
|
|
196
|
+
value: (_formatDateLocalized = (0, _date.formatDateLocalized)(new Date(date))) !== null && _formatDateLocalized !== void 0 ? _formatDateLocalized : date
|
|
197
|
+
};
|
|
198
|
+
}
|
|
199
|
+
case _reactNativeOneCore.DataTypeEnum.File:
|
|
200
|
+
{
|
|
201
|
+
var _typeConfig$params;
|
|
202
|
+
if (((_typeConfig$params = typeConfig.params) === null || _typeConfig$params === void 0 ? void 0 : _typeConfig$params.showAs) === 'IMAGE') {
|
|
203
|
+
return {
|
|
204
|
+
image: {
|
|
205
|
+
uri: claim.value
|
|
206
|
+
},
|
|
207
|
+
testID: testID
|
|
208
|
+
};
|
|
209
|
+
} else {
|
|
210
|
+
return {
|
|
211
|
+
testID: testID,
|
|
212
|
+
value: claim.value
|
|
213
|
+
};
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
default:
|
|
217
|
+
return {
|
|
218
|
+
testID: testID,
|
|
219
|
+
value: String(claim.value)
|
|
220
|
+
};
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
};
|
|
224
|
+
const detailsCardFromCredential = (credential, config, testID, labels) => {
|
|
225
|
+
return detailsCardFromCredentialWithClaims(credential, credential.claims, config, testID, labels);
|
|
226
|
+
};
|
|
227
|
+
exports.detailsCardFromCredential = detailsCardFromCredential;
|
|
228
|
+
const detailsCardFromCredentialWithClaims = (credential, claims, config, testID, labels) => {
|
|
229
|
+
const attributes = claims.map((claim, index) => detailsCardAttributeFromClaim(claim, config, (0, _testID.concatTestID)(testID, 'attribute', index.toString())));
|
|
230
|
+
const card = getCredentialCardPropsFromCredential(credential, claims, config, undefined, (0, _testID.concatTestID)(testID, 'card'), labels);
|
|
231
|
+
return {
|
|
232
|
+
attributes,
|
|
233
|
+
card
|
|
234
|
+
};
|
|
235
|
+
};
|
|
236
|
+
|
|
237
|
+
// Converts a flat list of attributes into a nested structure
|
|
238
|
+
// modifies the names to not include slashes
|
|
239
|
+
exports.detailsCardFromCredentialWithClaims = detailsCardFromCredentialWithClaims;
|
|
240
|
+
const nestAttributes = attributes => {
|
|
241
|
+
const result = [];
|
|
242
|
+
for (const attribute of attributes) {
|
|
243
|
+
const attributePath = attribute.path.split('/');
|
|
244
|
+
if (attributePath.length === 0) {
|
|
245
|
+
result.push(attribute);
|
|
246
|
+
} else {
|
|
247
|
+
const [first, ...rest] = attributePath;
|
|
248
|
+
const parent = result.find(a => a.name === first);
|
|
249
|
+
if (parent) {
|
|
250
|
+
insertAttributeInObject({
|
|
251
|
+
...attribute,
|
|
252
|
+
path: rest.join('/')
|
|
253
|
+
}, parent);
|
|
254
|
+
} else {
|
|
255
|
+
result.push(nestAttributeInDummyObject(attribute));
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
return result;
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
// We nest the leaf node in a (one or more) nested object(s)
|
|
263
|
+
// to make sure the tree structure is correctly rendered in proof request screens.
|
|
264
|
+
exports.nestAttributes = nestAttributes;
|
|
265
|
+
const nestAttributeInDummyObject = attribute => {
|
|
266
|
+
const pathParts = attribute.path.split('/');
|
|
267
|
+
const [first, ...rest] = pathParts;
|
|
268
|
+
if (!rest.length) {
|
|
269
|
+
return attribute;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
// The dummy object is not selectable, and contains a placeholder ID
|
|
273
|
+
// the user can't interact with it.
|
|
274
|
+
return {
|
|
275
|
+
attributes: [nestAttributeInDummyObject({
|
|
276
|
+
...attribute,
|
|
277
|
+
path: rest.join('/')
|
|
278
|
+
})],
|
|
279
|
+
disabled: true,
|
|
280
|
+
id: `${attribute.id}/${first}`,
|
|
281
|
+
name: first,
|
|
282
|
+
path: attribute.path
|
|
283
|
+
};
|
|
284
|
+
};
|
|
285
|
+
|
|
286
|
+
// Recursively insert an attribute into an object
|
|
287
|
+
// Will create nested objects if necessary
|
|
288
|
+
const insertAttributeInObject = (attribute, object) => {
|
|
289
|
+
var _object$attributes;
|
|
290
|
+
const pathParts = attribute.path.split('/');
|
|
291
|
+
const [first, ...rest] = pathParts;
|
|
292
|
+
const nextParent = (_object$attributes = object.attributes) === null || _object$attributes === void 0 ? void 0 : _object$attributes.find(a => a.name === first);
|
|
293
|
+
if (!nextParent) {
|
|
294
|
+
var _object$attributes2;
|
|
295
|
+
(_object$attributes2 = object.attributes) === null || _object$attributes2 === void 0 ? void 0 : _object$attributes2.push(nestAttributeInDummyObject(attribute));
|
|
296
|
+
} else {
|
|
297
|
+
insertAttributeInObject({
|
|
298
|
+
...attribute,
|
|
299
|
+
path: rest.join('/')
|
|
300
|
+
}, nextParent);
|
|
301
|
+
}
|
|
302
|
+
};
|
|
303
|
+
function parseBase64Image(image) {
|
|
304
|
+
return image ? '__BASE64IMAGE__' : '';
|
|
305
|
+
}
|
|
306
|
+
function getCredentialSchemaWithoutImages(credentialSchema) {
|
|
307
|
+
var _credentialSchema$lay, _credentialSchema$lay2, _credentialSchema$lay3, _credentialSchema$lay4, _credentialSchema$lay5, _credentialSchema$lay6;
|
|
308
|
+
return {
|
|
309
|
+
...credentialSchema,
|
|
310
|
+
layoutProperties: {
|
|
311
|
+
...credentialSchema.layoutProperties,
|
|
312
|
+
background: {
|
|
313
|
+
...((_credentialSchema$lay = credentialSchema.layoutProperties) === null || _credentialSchema$lay === void 0 ? void 0 : _credentialSchema$lay.background),
|
|
314
|
+
image: parseBase64Image((_credentialSchema$lay2 = credentialSchema.layoutProperties) === null || _credentialSchema$lay2 === void 0 ? void 0 : (_credentialSchema$lay3 = _credentialSchema$lay2.background) === null || _credentialSchema$lay3 === void 0 ? void 0 : _credentialSchema$lay3.image)
|
|
315
|
+
},
|
|
316
|
+
logo: {
|
|
317
|
+
...((_credentialSchema$lay4 = credentialSchema.layoutProperties) === null || _credentialSchema$lay4 === void 0 ? void 0 : _credentialSchema$lay4.logo),
|
|
318
|
+
image: parseBase64Image((_credentialSchema$lay5 = credentialSchema.layoutProperties) === null || _credentialSchema$lay5 === void 0 ? void 0 : (_credentialSchema$lay6 = _credentialSchema$lay5.logo) === null || _credentialSchema$lay6 === void 0 ? void 0 : _credentialSchema$lay6.image)
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
};
|
|
322
|
+
}
|
|
323
|
+
//# sourceMappingURL=credential.js.map
|