@pagopa/io-app-design-system 1.16.0 → 1.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +131 -54
- package/lib/commonjs/components/banner/__test__/__snapshots__/banner.test.tsx.snap +4 -4
- package/lib/commonjs/components/buttons/__test__/__snapshots__/button.test.tsx.snap +4 -4
- package/lib/commonjs/components/checkbox/AnimatedCheckbox.js +6 -2
- package/lib/commonjs/components/checkbox/AnimatedCheckbox.js.map +1 -1
- package/lib/commonjs/components/codeInput/CodeInput.js +103 -0
- package/lib/commonjs/components/codeInput/CodeInput.js.map +1 -0
- package/lib/commonjs/components/codeInput/index.js +17 -0
- package/lib/commonjs/components/codeInput/index.js.map +1 -0
- package/lib/commonjs/components/icons/Icon.js +2 -0
- package/lib/commonjs/components/icons/Icon.js.map +1 -1
- package/lib/commonjs/components/icons/README.md +79 -19
- package/lib/commonjs/components/icons/svg/IconSparkles.js +30 -0
- package/lib/commonjs/components/icons/svg/IconSparkles.js.map +1 -0
- package/lib/commonjs/components/icons/svg/originals/IconSparkles.svg +3 -0
- package/lib/commonjs/components/index.js +48 -26
- package/lib/commonjs/components/index.js.map +1 -1
- package/lib/commonjs/components/layout/HeaderSecondLevel.js +5 -4
- package/lib/commonjs/components/layout/HeaderSecondLevel.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemAction.js +4 -3
- package/lib/commonjs/components/listitems/ListItemAction.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemHeader.js +87 -0
- package/lib/commonjs/components/listitems/ListItemHeader.js.map +1 -0
- package/lib/commonjs/components/listitems/ListItemInfo.js +18 -14
- package/lib/commonjs/components/listitems/ListItemInfo.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemInfoCopy.js +5 -30
- package/lib/commonjs/components/listitems/ListItemInfoCopy.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemNav.js +15 -23
- package/lib/commonjs/components/listitems/ListItemNav.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemNavAlert.js +4 -22
- package/lib/commonjs/components/listitems/ListItemNavAlert.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemRadio.js +69 -10
- package/lib/commonjs/components/listitems/ListItemRadio.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemRadioWithAmount.js +64 -0
- package/lib/commonjs/components/listitems/ListItemRadioWithAmount.js.map +1 -0
- package/lib/commonjs/components/listitems/ListItemTransaction.js +8 -5
- package/lib/commonjs/components/listitems/ListItemTransaction.js.map +1 -1
- package/lib/commonjs/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +684 -34
- package/lib/commonjs/components/listitems/__test__/listitem.test.js +17 -0
- package/lib/commonjs/components/listitems/__test__/listitem.test.js.map +1 -1
- package/lib/commonjs/components/listitems/index.js +22 -0
- package/lib/commonjs/components/listitems/index.js.map +1 -1
- package/lib/commonjs/components/modules/ModuleCheckout.js +103 -0
- package/lib/commonjs/components/modules/ModuleCheckout.js.map +1 -0
- package/lib/commonjs/components/modules/index.js +11 -0
- package/lib/commonjs/components/modules/index.js.map +1 -1
- package/lib/commonjs/components/numberpad/NumberPad.js +7 -10
- package/lib/commonjs/components/numberpad/NumberPad.js.map +1 -1
- package/lib/commonjs/components/pictograms/Pictogram.js +19 -1
- package/lib/commonjs/components/pictograms/Pictogram.js.map +1 -1
- package/lib/commonjs/components/pictograms/README.md +103 -14
- package/lib/commonjs/components/pictograms/svg/PictogramBiometric.js +82 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBiometric.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBleedEnded.js +43 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBleedEnded.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBleedLostConnection.js +64 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBleedLostConnection.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBleedPending.js +15 -9
- package/lib/commonjs/components/pictograms/svg/PictogramBleedPending.js.map +1 -1
- package/lib/commonjs/components/pictograms/svg/PictogramBleedQrCode.js +79 -0
- package/lib/commonjs/components/pictograms/svg/PictogramBleedQrCode.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramEmailDotCheck.js +60 -0
- package/lib/commonjs/components/pictograms/svg/PictogramEmailDotCheck.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramEmailDotNotif.js +58 -0
- package/lib/commonjs/components/pictograms/svg/PictogramEmailDotNotif.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramEnded.js +43 -0
- package/lib/commonjs/components/pictograms/svg/PictogramEnded.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramLostConnection.js +58 -0
- package/lib/commonjs/components/pictograms/svg/PictogramLostConnection.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/PictogramPending.js +15 -9
- package/lib/commonjs/components/pictograms/svg/PictogramPending.js.map +1 -1
- package/lib/commonjs/components/pictograms/svg/PictogramQrCode.js +91 -0
- package/lib/commonjs/components/pictograms/svg/PictogramQrCode.js.map +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramBiometric.svg +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramBleedEnded.svg +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramBleedLostConnection.svg +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramBleedPending.svg +1 -1
- package/lib/commonjs/components/pictograms/svg/originals/PictogramBleedQrCode.svg +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramEmailDotCheck.svg +41 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramEmailDotNotif.svg +35 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramEnded.svg +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramLostConnection.svg +1 -0
- package/lib/commonjs/components/pictograms/svg/originals/PictogramPending.svg +1 -1
- package/lib/commonjs/components/pictograms/svg/originals/PictogramQrCode.svg +1 -0
- package/lib/commonjs/components/radio/RadioGroup.js +2 -1
- package/lib/commonjs/components/radio/RadioGroup.js.map +1 -1
- package/lib/commonjs/components/stepper/Stepper.js +52 -0
- package/lib/commonjs/components/stepper/Stepper.js.map +1 -0
- package/lib/commonjs/components/stepper/index.js +17 -0
- package/lib/commonjs/components/stepper/index.js.map +1 -0
- package/lib/commonjs/components/typography/H1.js +5 -3
- package/lib/commonjs/components/typography/H1.js.map +1 -1
- package/lib/commonjs/components/typography/H2.js +5 -3
- package/lib/commonjs/components/typography/H2.js.map +1 -1
- package/lib/commonjs/components/typography/H3.js +5 -3
- package/lib/commonjs/components/typography/H3.js.map +1 -1
- package/lib/commonjs/components/typography/H4.js +2 -1
- package/lib/commonjs/components/typography/H4.js.map +1 -1
- package/lib/commonjs/components/typography/H6.js +4 -2
- package/lib/commonjs/components/typography/H6.js.map +1 -1
- package/lib/commonjs/components/typography/Hero.js +7 -3
- package/lib/commonjs/components/typography/Hero.js.map +1 -1
- package/lib/commonjs/components/typography/LabelSmall.js +6 -1
- package/lib/commonjs/components/typography/LabelSmall.js.map +1 -1
- package/lib/commonjs/components/typography/LabelSmallAlt.js +39 -0
- package/lib/commonjs/components/typography/LabelSmallAlt.js.map +1 -0
- package/lib/commonjs/components/typography/README.md +23 -0
- package/lib/commonjs/components/typography/__test__/__snapshots__/typography.test.tsx.snap +84 -74
- package/lib/commonjs/components/typography/index.js +11 -0
- package/lib/commonjs/components/typography/index.js.map +1 -1
- package/lib/module/components/banner/__test__/__snapshots__/banner.test.tsx.snap +4 -4
- package/lib/module/components/buttons/__test__/__snapshots__/button.test.tsx.snap +4 -4
- package/lib/module/components/checkbox/AnimatedCheckbox.js +6 -2
- package/lib/module/components/checkbox/AnimatedCheckbox.js.map +1 -1
- package/lib/module/components/codeInput/CodeInput.js +94 -0
- package/lib/module/components/codeInput/CodeInput.js.map +1 -0
- package/lib/module/components/codeInput/index.js +2 -0
- package/lib/module/components/codeInput/index.js.map +1 -0
- package/lib/module/components/icons/Icon.js +2 -0
- package/lib/module/components/icons/Icon.js.map +1 -1
- package/lib/module/components/icons/README.md +79 -19
- package/lib/module/components/icons/svg/IconSparkles.js +21 -0
- package/lib/module/components/icons/svg/IconSparkles.js.map +1 -0
- package/lib/module/components/icons/svg/originals/IconSparkles.svg +3 -0
- package/lib/module/components/index.js +5 -3
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/components/layout/HeaderSecondLevel.js +5 -4
- package/lib/module/components/layout/HeaderSecondLevel.js.map +1 -1
- package/lib/module/components/listitems/ListItemAction.js +4 -3
- package/lib/module/components/listitems/ListItemAction.js.map +1 -1
- package/lib/module/components/listitems/ListItemHeader.js +77 -0
- package/lib/module/components/listitems/ListItemHeader.js.map +1 -0
- package/lib/module/components/listitems/ListItemInfo.js +18 -14
- package/lib/module/components/listitems/ListItemInfo.js.map +1 -1
- package/lib/module/components/listitems/ListItemInfoCopy.js +7 -32
- package/lib/module/components/listitems/ListItemInfoCopy.js.map +1 -1
- package/lib/module/components/listitems/ListItemNav.js +17 -26
- package/lib/module/components/listitems/ListItemNav.js.map +1 -1
- package/lib/module/components/listitems/ListItemNavAlert.js +6 -24
- package/lib/module/components/listitems/ListItemNavAlert.js.map +1 -1
- package/lib/module/components/listitems/ListItemRadio.js +69 -10
- package/lib/module/components/listitems/ListItemRadio.js.map +1 -1
- package/lib/module/components/listitems/ListItemRadioWithAmount.js +54 -0
- package/lib/module/components/listitems/ListItemRadioWithAmount.js.map +1 -0
- package/lib/module/components/listitems/ListItemTransaction.js +10 -7
- package/lib/module/components/listitems/ListItemTransaction.js.map +1 -1
- package/lib/module/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +684 -34
- package/lib/module/components/listitems/__test__/listitem.test.js +17 -0
- package/lib/module/components/listitems/__test__/listitem.test.js.map +1 -1
- package/lib/module/components/listitems/index.js +2 -0
- package/lib/module/components/listitems/index.js.map +1 -1
- package/lib/module/components/modules/ModuleCheckout.js +95 -0
- package/lib/module/components/modules/ModuleCheckout.js.map +1 -0
- package/lib/module/components/modules/index.js +1 -0
- package/lib/module/components/modules/index.js.map +1 -1
- package/lib/module/components/numberpad/NumberPad.js +6 -7
- package/lib/module/components/numberpad/NumberPad.js.map +1 -1
- package/lib/module/components/pictograms/Pictogram.js +19 -1
- package/lib/module/components/pictograms/Pictogram.js.map +1 -1
- package/lib/module/components/pictograms/README.md +103 -14
- package/lib/module/components/pictograms/svg/PictogramBiometric.js +74 -0
- package/lib/module/components/pictograms/svg/PictogramBiometric.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramBleedEnded.js +35 -0
- package/lib/module/components/pictograms/svg/PictogramBleedEnded.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramBleedLostConnection.js +56 -0
- package/lib/module/components/pictograms/svg/PictogramBleedLostConnection.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramBleedPending.js +15 -9
- package/lib/module/components/pictograms/svg/PictogramBleedPending.js.map +1 -1
- package/lib/module/components/pictograms/svg/PictogramBleedQrCode.js +71 -0
- package/lib/module/components/pictograms/svg/PictogramBleedQrCode.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramEmailDotCheck.js +52 -0
- package/lib/module/components/pictograms/svg/PictogramEmailDotCheck.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramEmailDotNotif.js +50 -0
- package/lib/module/components/pictograms/svg/PictogramEmailDotNotif.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramEnded.js +35 -0
- package/lib/module/components/pictograms/svg/PictogramEnded.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramLostConnection.js +50 -0
- package/lib/module/components/pictograms/svg/PictogramLostConnection.js.map +1 -0
- package/lib/module/components/pictograms/svg/PictogramPending.js +15 -9
- package/lib/module/components/pictograms/svg/PictogramPending.js.map +1 -1
- package/lib/module/components/pictograms/svg/PictogramQrCode.js +83 -0
- package/lib/module/components/pictograms/svg/PictogramQrCode.js.map +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramBiometric.svg +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramBleedEnded.svg +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramBleedLostConnection.svg +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramBleedPending.svg +1 -1
- package/lib/module/components/pictograms/svg/originals/PictogramBleedQrCode.svg +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramEmailDotCheck.svg +41 -0
- package/lib/module/components/pictograms/svg/originals/PictogramEmailDotNotif.svg +35 -0
- package/lib/module/components/pictograms/svg/originals/PictogramEnded.svg +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramLostConnection.svg +1 -0
- package/lib/module/components/pictograms/svg/originals/PictogramPending.svg +1 -1
- package/lib/module/components/pictograms/svg/originals/PictogramQrCode.svg +1 -0
- package/lib/module/components/radio/RadioGroup.js +2 -1
- package/lib/module/components/radio/RadioGroup.js.map +1 -1
- package/lib/module/components/stepper/Stepper.js +43 -0
- package/lib/module/components/stepper/Stepper.js.map +1 -0
- package/lib/module/components/stepper/index.js +2 -0
- package/lib/module/components/stepper/index.js.map +1 -0
- package/lib/module/components/typography/H1.js +5 -3
- package/lib/module/components/typography/H1.js.map +1 -1
- package/lib/module/components/typography/H2.js +5 -3
- package/lib/module/components/typography/H2.js.map +1 -1
- package/lib/module/components/typography/H3.js +5 -3
- package/lib/module/components/typography/H3.js.map +1 -1
- package/lib/module/components/typography/H4.js +2 -1
- package/lib/module/components/typography/H4.js.map +1 -1
- package/lib/module/components/typography/H6.js +4 -2
- package/lib/module/components/typography/H6.js.map +1 -1
- package/lib/module/components/typography/Hero.js +7 -3
- package/lib/module/components/typography/Hero.js.map +1 -1
- package/lib/module/components/typography/LabelSmall.js +6 -1
- package/lib/module/components/typography/LabelSmall.js.map +1 -1
- package/lib/module/components/typography/LabelSmallAlt.js +32 -0
- package/lib/module/components/typography/LabelSmallAlt.js.map +1 -0
- package/lib/module/components/typography/README.md +23 -0
- package/lib/module/components/typography/__test__/__snapshots__/typography.test.tsx.snap +84 -74
- package/lib/module/components/typography/index.js +1 -0
- package/lib/module/components/typography/index.js.map +1 -1
- package/lib/typescript/components/checkbox/AnimatedCheckbox.d.ts.map +1 -1
- package/lib/typescript/components/codeInput/CodeInput.d.ts +11 -0
- package/lib/typescript/components/codeInput/CodeInput.d.ts.map +1 -0
- package/lib/typescript/components/codeInput/index.d.ts +2 -0
- package/lib/typescript/components/codeInput/index.d.ts.map +1 -0
- package/lib/typescript/components/icons/Icon.d.ts +1 -0
- package/lib/typescript/components/icons/Icon.d.ts.map +1 -1
- package/lib/typescript/components/icons/svg/IconSparkles.d.ts +5 -0
- package/lib/typescript/components/icons/svg/IconSparkles.d.ts.map +1 -0
- package/lib/typescript/components/index.d.ts +5 -3
- package/lib/typescript/components/index.d.ts.map +1 -1
- package/lib/typescript/components/layout/HeaderSecondLevel.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemAction.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemHeader.d.ts +34 -0
- package/lib/typescript/components/listitems/ListItemHeader.d.ts.map +1 -0
- package/lib/typescript/components/listitems/ListItemInfo.d.ts +8 -3
- package/lib/typescript/components/listitems/ListItemInfo.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemInfoCopy.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemNav.d.ts +4 -1
- package/lib/typescript/components/listitems/ListItemNav.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemNavAlert.d.ts +2 -2
- package/lib/typescript/components/listitems/ListItemNavAlert.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemRadio.d.ts +21 -3
- package/lib/typescript/components/listitems/ListItemRadio.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemRadioWithAmount.d.ts +13 -0
- package/lib/typescript/components/listitems/ListItemRadioWithAmount.d.ts.map +1 -0
- package/lib/typescript/components/listitems/ListItemTransaction.d.ts.map +1 -1
- package/lib/typescript/components/listitems/index.d.ts +2 -0
- package/lib/typescript/components/listitems/index.d.ts.map +1 -1
- package/lib/typescript/components/modules/ModuleCheckout.d.ts +15 -0
- package/lib/typescript/components/modules/ModuleCheckout.d.ts.map +1 -0
- package/lib/typescript/components/modules/index.d.ts +1 -0
- package/lib/typescript/components/modules/index.d.ts.map +1 -1
- package/lib/typescript/components/numberpad/NumberPad.d.ts +2 -1
- package/lib/typescript/components/numberpad/NumberPad.d.ts.map +1 -1
- package/lib/typescript/components/pictograms/Pictogram.d.ts +7 -1
- package/lib/typescript/components/pictograms/Pictogram.d.ts.map +1 -1
- package/lib/typescript/components/pictograms/svg/PictogramBiometric.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramBiometric.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramBleedEnded.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramBleedEnded.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramBleedLostConnection.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramBleedLostConnection.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramBleedPending.d.ts.map +1 -1
- package/lib/typescript/components/pictograms/svg/PictogramBleedQrCode.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramBleedQrCode.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramEmailDotCheck.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramEmailDotCheck.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramEmailDotNotif.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramEmailDotNotif.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramEnded.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramEnded.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramLostConnection.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramLostConnection.d.ts.map +1 -0
- package/lib/typescript/components/pictograms/svg/PictogramPending.d.ts.map +1 -1
- package/lib/typescript/components/pictograms/svg/PictogramQrCode.d.ts +5 -0
- package/lib/typescript/components/pictograms/svg/PictogramQrCode.d.ts.map +1 -0
- package/lib/typescript/components/radio/RadioGroup.d.ts +4 -3
- package/lib/typescript/components/radio/RadioGroup.d.ts.map +1 -1
- package/lib/typescript/components/stepper/Stepper.d.ts +8 -0
- package/lib/typescript/components/stepper/Stepper.d.ts.map +1 -0
- package/lib/typescript/components/stepper/index.d.ts +2 -0
- package/lib/typescript/components/stepper/index.d.ts.map +1 -0
- package/lib/typescript/components/typography/H1.d.ts +1 -1
- package/lib/typescript/components/typography/H1.d.ts.map +1 -1
- package/lib/typescript/components/typography/H2.d.ts +1 -1
- package/lib/typescript/components/typography/H2.d.ts.map +1 -1
- package/lib/typescript/components/typography/H3.d.ts +1 -1
- package/lib/typescript/components/typography/H3.d.ts.map +1 -1
- package/lib/typescript/components/typography/H4.d.ts.map +1 -1
- package/lib/typescript/components/typography/H6.d.ts.map +1 -1
- package/lib/typescript/components/typography/Hero.d.ts +1 -1
- package/lib/typescript/components/typography/Hero.d.ts.map +1 -1
- package/lib/typescript/components/typography/LabelSmall.d.ts.map +1 -1
- package/lib/typescript/components/typography/LabelSmallAlt.d.ts +14 -0
- package/lib/typescript/components/typography/LabelSmallAlt.d.ts.map +1 -0
- package/lib/typescript/components/typography/index.d.ts +1 -0
- package/lib/typescript/components/typography/index.d.ts.map +1 -1
- package/package.json +9 -2
- package/src/components/banner/__test__/__snapshots__/banner.test.tsx.snap +4 -4
- package/src/components/buttons/__test__/__snapshots__/button.test.tsx.snap +4 -4
- package/src/components/checkbox/AnimatedCheckbox.tsx +6 -4
- package/src/components/codeInput/CodeInput.tsx +121 -0
- package/src/components/codeInput/index.tsx +1 -0
- package/src/components/icons/Icon.tsx +2 -0
- package/src/components/icons/README.md +79 -19
- package/src/components/icons/svg/IconSparkles.tsx +14 -0
- package/src/components/icons/svg/originals/IconSparkles.svg +3 -0
- package/src/components/index.tsx +5 -3
- package/src/components/layout/HeaderSecondLevel.tsx +6 -9
- package/src/components/listitems/ListItemAction.tsx +4 -3
- package/src/components/listitems/ListItemHeader.tsx +146 -0
- package/src/components/listitems/ListItemInfo.tsx +33 -16
- package/src/components/listitems/ListItemInfoCopy.tsx +14 -57
- package/src/components/listitems/ListItemNav.tsx +32 -44
- package/src/components/listitems/ListItemNavAlert.tsx +21 -42
- package/src/components/listitems/ListItemRadio.tsx +99 -12
- package/src/components/listitems/ListItemRadioWithAmount.tsx +69 -0
- package/src/components/listitems/ListItemTransaction.tsx +12 -7
- package/src/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +684 -34
- package/src/components/listitems/__test__/listitem.test.tsx +21 -0
- package/src/components/listitems/index.tsx +2 -0
- package/src/components/modules/ModuleCheckout.tsx +98 -0
- package/src/components/modules/index.tsx +1 -0
- package/src/components/numberpad/NumberPad.tsx +7 -8
- package/src/components/pictograms/Pictogram.tsx +23 -2
- package/src/components/pictograms/README.md +103 -14
- package/src/components/pictograms/svg/PictogramBiometric.tsx +78 -0
- package/src/components/pictograms/svg/PictogramBleedEnded.tsx +38 -0
- package/src/components/pictograms/svg/PictogramBleedLostConnection.tsx +66 -0
- package/src/components/pictograms/svg/PictogramBleedPending.tsx +17 -9
- package/src/components/pictograms/svg/PictogramBleedQrCode.tsx +86 -0
- package/src/components/pictograms/svg/PictogramEmailDotCheck.tsx +53 -0
- package/src/components/pictograms/svg/PictogramEmailDotNotif.tsx +51 -0
- package/src/components/pictograms/svg/PictogramEnded.tsx +34 -0
- package/src/components/pictograms/svg/PictogramLostConnection.tsx +58 -0
- package/src/components/pictograms/svg/PictogramPending.tsx +17 -9
- package/src/components/pictograms/svg/PictogramQrCode.tsx +102 -0
- package/src/components/pictograms/svg/originals/PictogramBiometric.svg +1 -0
- package/src/components/pictograms/svg/originals/PictogramBleedEnded.svg +1 -0
- package/src/components/pictograms/svg/originals/PictogramBleedLostConnection.svg +1 -0
- package/src/components/pictograms/svg/originals/PictogramBleedPending.svg +1 -1
- package/src/components/pictograms/svg/originals/PictogramBleedQrCode.svg +1 -0
- package/src/components/pictograms/svg/originals/PictogramEmailDotCheck.svg +41 -0
- package/src/components/pictograms/svg/originals/PictogramEmailDotNotif.svg +35 -0
- package/src/components/pictograms/svg/originals/PictogramEnded.svg +1 -0
- package/src/components/pictograms/svg/originals/PictogramLostConnection.svg +1 -0
- package/src/components/pictograms/svg/originals/PictogramPending.svg +1 -1
- package/src/components/pictograms/svg/originals/PictogramQrCode.svg +1 -0
- package/src/components/radio/RadioGroup.tsx +5 -4
- package/src/components/stepper/Stepper.tsx +62 -0
- package/src/components/stepper/index.tsx +1 -0
- package/src/components/typography/H1.tsx +8 -3
- package/src/components/typography/H2.tsx +8 -3
- package/src/components/typography/H3.tsx +8 -3
- package/src/components/typography/H4.tsx +5 -1
- package/src/components/typography/H6.tsx +6 -1
- package/src/components/typography/Hero.tsx +10 -3
- package/src/components/typography/LabelSmall.tsx +8 -1
- package/src/components/typography/LabelSmallAlt.tsx +51 -0
- package/src/components/typography/README.md +23 -0
- package/src/components/typography/__test__/__snapshots__/typography.test.tsx.snap +84 -74
- package/src/components/typography/index.tsx +1 -0
- package/lib/commonjs/components/icons/generateNewIcons.js +0 -165
- package/lib/commonjs/components/icons/generateNewIcons.js.map +0 -1
- package/lib/commonjs/components/icons/generateNewTimestamp.js +0 -8
- package/lib/commonjs/components/icons/generateNewTimestamp.js.map +0 -1
- package/lib/commonjs/components/icons/timestamp.txt +0 -1
- package/lib/commonjs/components/pictograms/generateNewPictograms.js +0 -163
- package/lib/commonjs/components/pictograms/generateNewPictograms.js.map +0 -1
- package/lib/commonjs/components/pictograms/timestamp.txt +0 -1
- package/lib/commonjs/stories/ButtonDS.stories.js +0 -34
- package/lib/commonjs/stories/ButtonDS.stories.js.map +0 -1
- package/lib/commonjs/stories/H1.stories.js +0 -33
- package/lib/commonjs/stories/H1.stories.js.map +0 -1
- package/lib/commonjs/stories/H2.stories.js +0 -33
- package/lib/commonjs/stories/H2.stories.js.map +0 -1
- package/lib/commonjs/stories/H3.stories.js +0 -33
- package/lib/commonjs/stories/H3.stories.js.map +0 -1
- package/lib/commonjs/stories/H4.stories.js +0 -33
- package/lib/commonjs/stories/H4.stories.js.map +0 -1
- package/lib/commonjs/stories/H5.stories.js +0 -33
- package/lib/commonjs/stories/H5.stories.js.map +0 -1
- package/lib/commonjs/stories/H6.stories.js +0 -33
- package/lib/commonjs/stories/H6.stories.js.map +0 -1
- package/lib/commonjs/stories/Label.stories.js +0 -33
- package/lib/commonjs/stories/Label.stories.js.map +0 -1
- package/lib/commonjs/stories/LabelSmall.stories.js +0 -33
- package/lib/commonjs/stories/LabelSmall.stories.js.map +0 -1
- package/lib/commonjs/stories/Link.stories.js +0 -33
- package/lib/commonjs/stories/Link.stories.js.map +0 -1
- package/lib/commonjs/stories/ModuleIDP.stories.js +0 -45
- package/lib/commonjs/stories/ModuleIDP.stories.js.map +0 -1
- package/lib/commonjs/stories/Monospace.stories.js +0 -33
- package/lib/commonjs/stories/Monospace.stories.js.map +0 -1
- package/lib/module/components/icons/generateNewIcons.js +0 -163
- package/lib/module/components/icons/generateNewIcons.js.map +0 -1
- package/lib/module/components/icons/generateNewTimestamp.js +0 -6
- package/lib/module/components/icons/generateNewTimestamp.js.map +0 -1
- package/lib/module/components/icons/timestamp.txt +0 -1
- package/lib/module/components/pictograms/generateNewPictograms.js +0 -161
- package/lib/module/components/pictograms/generateNewPictograms.js.map +0 -1
- package/lib/module/components/pictograms/timestamp.txt +0 -1
- package/lib/module/stories/ButtonDS.stories.js +0 -27
- package/lib/module/stories/ButtonDS.stories.js.map +0 -1
- package/lib/module/stories/H1.stories.js +0 -26
- package/lib/module/stories/H1.stories.js.map +0 -1
- package/lib/module/stories/H2.stories.js +0 -26
- package/lib/module/stories/H2.stories.js.map +0 -1
- package/lib/module/stories/H3.stories.js +0 -26
- package/lib/module/stories/H3.stories.js.map +0 -1
- package/lib/module/stories/H4.stories.js +0 -26
- package/lib/module/stories/H4.stories.js.map +0 -1
- package/lib/module/stories/H5.stories.js +0 -26
- package/lib/module/stories/H5.stories.js.map +0 -1
- package/lib/module/stories/H6.stories.js +0 -26
- package/lib/module/stories/H6.stories.js.map +0 -1
- package/lib/module/stories/Label.stories.js +0 -26
- package/lib/module/stories/Label.stories.js.map +0 -1
- package/lib/module/stories/LabelSmall.stories.js +0 -26
- package/lib/module/stories/LabelSmall.stories.js.map +0 -1
- package/lib/module/stories/Link.stories.js +0 -26
- package/lib/module/stories/Link.stories.js.map +0 -1
- package/lib/module/stories/ModuleIDP.stories.js +0 -37
- package/lib/module/stories/ModuleIDP.stories.js.map +0 -1
- package/lib/module/stories/Monospace.stories.js +0 -26
- package/lib/module/stories/Monospace.stories.js.map +0 -1
- package/lib/typescript/stories/ButtonDS.stories.d.ts +0 -14
- package/lib/typescript/stories/ButtonDS.stories.d.ts.map +0 -1
- package/lib/typescript/stories/H1.stories.d.ts +0 -19
- package/lib/typescript/stories/H1.stories.d.ts.map +0 -1
- package/lib/typescript/stories/H2.stories.d.ts +0 -19
- package/lib/typescript/stories/H2.stories.d.ts.map +0 -1
- package/lib/typescript/stories/H3.stories.d.ts +0 -19
- package/lib/typescript/stories/H3.stories.d.ts.map +0 -1
- package/lib/typescript/stories/H4.stories.d.ts +0 -19
- package/lib/typescript/stories/H4.stories.d.ts.map +0 -1
- package/lib/typescript/stories/H5.stories.d.ts +0 -19
- package/lib/typescript/stories/H5.stories.d.ts.map +0 -1
- package/lib/typescript/stories/H6.stories.d.ts +0 -19
- package/lib/typescript/stories/H6.stories.d.ts.map +0 -1
- package/lib/typescript/stories/Label.stories.d.ts +0 -21
- package/lib/typescript/stories/Label.stories.d.ts.map +0 -1
- package/lib/typescript/stories/LabelSmall.stories.d.ts +0 -21
- package/lib/typescript/stories/LabelSmall.stories.d.ts.map +0 -1
- package/lib/typescript/stories/Link.stories.d.ts +0 -21
- package/lib/typescript/stories/Link.stories.d.ts.map +0 -1
- package/lib/typescript/stories/ModuleIDP.stories.d.ts +0 -24
- package/lib/typescript/stories/ModuleIDP.stories.d.ts.map +0 -1
- package/lib/typescript/stories/Monospace.stories.d.ts +0 -19
- package/lib/typescript/stories/Monospace.stories.d.ts.map +0 -1
- package/src/components/icons/generateNewIcons.js +0 -186
- package/src/components/icons/generateNewTimestamp.js +0 -7
- package/src/components/icons/timestamp.txt +0 -1
- package/src/components/pictograms/generateNewPictograms.js +0 -181
- package/src/components/pictograms/timestamp.txt +0 -1
- package/src/stories/ButtonDS.stories.ts +0 -31
- package/src/stories/H1.stories.ts +0 -28
- package/src/stories/H2.stories.ts +0 -28
- package/src/stories/H3.stories.ts +0 -28
- package/src/stories/H4.stories.ts +0 -28
- package/src/stories/H5.stories.ts +0 -28
- package/src/stories/H6.stories.ts +0 -28
- package/src/stories/Label.stories.ts +0 -28
- package/src/stories/LabelSmall.stories.ts +0 -28
- package/src/stories/Link.stories.ts +0 -28
- package/src/stories/ModuleIDP.stories.tsx +0 -44
- package/src/stories/Monospace.stories.ts +0 -28
|
@@ -10,6 +10,7 @@ var _core = require("../../core");
|
|
|
10
10
|
var _icons = require("../icons");
|
|
11
11
|
var _typography = require("../typography");
|
|
12
12
|
var _buttons = require("../buttons");
|
|
13
|
+
var _badge = require("../badge");
|
|
13
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
15
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
16
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
@@ -19,7 +20,7 @@ const ListItemInfo = _ref => {
|
|
|
19
20
|
value,
|
|
20
21
|
numberOfLines = 2,
|
|
21
22
|
icon,
|
|
22
|
-
|
|
23
|
+
endElement,
|
|
23
24
|
accessibilityLabel,
|
|
24
25
|
testID
|
|
25
26
|
} = _ref;
|
|
@@ -27,43 +28,46 @@ const ListItemInfo = _ref => {
|
|
|
27
28
|
const componentValueToAccessibility = (0, _react.useMemo)(() => typeof value === "string" ? value : "", [value]);
|
|
28
29
|
const listItemAccessibilityLabel = (0, _react.useMemo)(() => accessibilityLabel ? accessibilityLabel : `${label}; ${componentValueToAccessibility}`, [label, componentValueToAccessibility, accessibilityLabel]);
|
|
29
30
|
const itemInfoTextComponent = (0, _react.useMemo)(() => /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
30
|
-
accessible:
|
|
31
|
-
importantForAccessibility:
|
|
32
|
-
accessibilityElementsHidden:
|
|
31
|
+
accessible: endElement === undefined ? true : false,
|
|
32
|
+
importantForAccessibility: endElement === undefined || endElement.type === "badge" ? "yes" : "no-hide-descendants",
|
|
33
|
+
accessibilityElementsHidden: endElement !== undefined && endElement.type !== "badge"
|
|
33
34
|
}, /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
34
35
|
weight: "Regular",
|
|
35
36
|
color: theme["textBody-tertiary"]
|
|
36
37
|
}, label), typeof value === "string" ? /*#__PURE__*/_react.default.createElement(_typography.H6, {
|
|
37
38
|
color: theme["textBody-default"],
|
|
38
39
|
numberOfLines: numberOfLines
|
|
39
|
-
}, value) : value), [label, value, numberOfLines, theme,
|
|
40
|
+
}, value) : value), [label, value, numberOfLines, theme, endElement]);
|
|
40
41
|
const listItemInfoAction = (0, _react.useCallback)(() => {
|
|
41
|
-
if (
|
|
42
|
+
if (endElement) {
|
|
42
43
|
const {
|
|
43
44
|
type,
|
|
44
45
|
componentProps
|
|
45
|
-
} =
|
|
46
|
-
const accessibilityLabel = `${listItemAccessibilityLabel}; ${componentProps.accessibilityLabel}`;
|
|
46
|
+
} = endElement;
|
|
47
47
|
switch (type) {
|
|
48
48
|
case "buttonLink":
|
|
49
|
+
const buttonLinkAccessibilityLabel = `${listItemAccessibilityLabel}; ${componentProps.accessibilityLabel}`;
|
|
49
50
|
return /*#__PURE__*/_react.default.createElement(_buttons.ButtonLink, _extends({}, componentProps, {
|
|
50
|
-
accessibilityLabel:
|
|
51
|
+
accessibilityLabel: buttonLinkAccessibilityLabel
|
|
51
52
|
}));
|
|
52
53
|
case "iconButton":
|
|
54
|
+
const iconButtonAccessibilityLabel = `${listItemAccessibilityLabel}; ${componentProps.accessibilityLabel}`;
|
|
53
55
|
return /*#__PURE__*/_react.default.createElement(_buttons.IconButton, _extends({}, componentProps, {
|
|
54
|
-
accessibilityLabel:
|
|
56
|
+
accessibilityLabel: iconButtonAccessibilityLabel
|
|
55
57
|
}));
|
|
58
|
+
case "badge":
|
|
59
|
+
return /*#__PURE__*/_react.default.createElement(_badge.Badge, componentProps);
|
|
56
60
|
default:
|
|
57
61
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null);
|
|
58
62
|
}
|
|
59
63
|
}
|
|
60
64
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null);
|
|
61
|
-
}, [
|
|
65
|
+
}, [endElement, listItemAccessibilityLabel]);
|
|
62
66
|
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
63
67
|
style: _core.IOListItemStyles.listItem,
|
|
64
68
|
testID: testID,
|
|
65
|
-
accessible:
|
|
66
|
-
accessibilityLabel:
|
|
69
|
+
accessible: endElement === undefined ? true : false,
|
|
70
|
+
accessibilityLabel: listItemAccessibilityLabel
|
|
67
71
|
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
68
72
|
style: _core.IOListItemStyles.listItemInner
|
|
69
73
|
}, icon && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
@@ -76,7 +80,7 @@ const ListItemInfo = _ref => {
|
|
|
76
80
|
size: _core.IOListItemVisualParams.iconSize
|
|
77
81
|
})), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
78
82
|
style: _core.IOStyles.flex
|
|
79
|
-
}, itemInfoTextComponent),
|
|
83
|
+
}, itemInfoTextComponent), endElement && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
80
84
|
style: {
|
|
81
85
|
marginLeft: _core.IOListItemVisualParams.actionMargin
|
|
82
86
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_core","_icons","_typography","_buttons","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_extends","assign","bind","target","i","arguments","length","source","apply","ListItemInfo","_ref","label","value","numberOfLines","icon","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_core","_icons","_typography","_buttons","_badge","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_extends","assign","bind","target","i","arguments","length","source","apply","ListItemInfo","_ref","label","value","numberOfLines","icon","endElement","accessibilityLabel","testID","theme","useIOTheme","componentValueToAccessibility","useMemo","listItemAccessibilityLabel","itemInfoTextComponent","createElement","View","accessible","undefined","importantForAccessibility","type","accessibilityElementsHidden","LabelSmall","weight","color","H6","listItemInfoAction","useCallback","componentProps","buttonLinkAccessibilityLabel","ButtonLink","iconButtonAccessibilityLabel","IconButton","Badge","Fragment","style","IOListItemStyles","listItem","listItemInner","marginRight","IOListItemVisualParams","actionMargin","Icon","name","size","iconSize","IOStyles","flex","marginLeft","exports","_default"],"sourceRoot":"../../../../src","sources":["components/listitems/ListItemInfo.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,KAAA,GAAAF,OAAA;AAOA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,WAAA,GAAAJ,OAAA;AACA,IAAAK,QAAA,GAAAL,OAAA;AACA,IAAAM,MAAA,GAAAN,OAAA;AAAiC,SAAAO,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAT,wBAAAa,GAAA,EAAAJ,WAAA,SAAAA,WAAA,IAAAI,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,oBAAAA,GAAA,wBAAAA,GAAA,4BAAAE,OAAA,EAAAF,GAAA,UAAAG,KAAA,GAAAR,wBAAA,CAAAC,WAAA,OAAAO,KAAA,IAAAA,KAAA,CAAAC,GAAA,CAAAJ,GAAA,YAAAG,KAAA,CAAAE,GAAA,CAAAL,GAAA,SAAAM,MAAA,WAAAC,qBAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,GAAA,IAAAX,GAAA,QAAAW,GAAA,kBAAAH,MAAA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uC,aAAA,CAACpD,YAAA,CAAAqD,IAAI;IAACmB,KAAK,EAAE;MAAEI,WAAW,EAAEC,4BAAsB,CAACC;IAAa;EAAE,gBAChEjF,MAAA,CAAAgB,OAAA,CAAAuC,aAAA,CAAClD,MAAA,CAAA6E,IAAI;IACHC,IAAI,EAAEtC,IAAK;IACXmB,KAAK,EAAC,UAAU;IAChBoB,IAAI,EAAEJ,4BAAsB,CAACK;EAAS,CACvC,CACG,CACP,eACDrF,MAAA,CAAAgB,OAAA,CAAAuC,aAAA,CAACpD,YAAA,CAAAqD,IAAI;IAACmB,KAAK,EAAEW,cAAQ,CAACC;EAAK,GAAEjC,qBAA4B,CAAC,EACzDR,UAAU,iBACT9C,MAAA,CAAAgB,OAAA,CAAAuC,aAAA,CAACpD,YAAA,CAAAqD,IAAI;IAACmB,KAAK,EAAE;MAAEa,UAAU,EAAER,4BAAsB,CAACC;IAAa;EAAE,GAC9Df,kBAAkB,CAAC,CAChB,CAEJ,CACF,CAAC;AAEX,CAAC;AAACuB,OAAA,CAAAjD,YAAA,GAAAA,YAAA;AAAA,IAAAkD,QAAA,GAEalD,YAAY;AAAAiD,OAAA,CAAAzE,OAAA,GAAA0E,QAAA"}
|
|
@@ -8,20 +8,10 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
9
|
var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
|
|
10
10
|
var _core = require("../../core");
|
|
11
|
-
var _fonts = require("../../utils/fonts");
|
|
12
11
|
var _icons = require("../icons");
|
|
13
|
-
var _spacer = require("../spacer");
|
|
14
12
|
var _typography = require("../typography");
|
|
15
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
16
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
17
|
-
// TODO: Remove this when legacy look is deprecated https://pagopa.atlassian.net/browse/IOPLT-153
|
|
18
|
-
const legacyStyles = _reactNative.StyleSheet.create({
|
|
19
|
-
textValue: {
|
|
20
|
-
fontSize: 18,
|
|
21
|
-
lineHeight: 24,
|
|
22
|
-
...(0, _fonts.makeFontStyleObject)("SemiBold", undefined, "TitilliumWeb")
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
15
|
const ListItemInfoCopy = _ref => {
|
|
26
16
|
var _IOScaleValues$basicB;
|
|
27
17
|
let {
|
|
@@ -38,31 +28,16 @@ const ListItemInfoCopy = _ref => {
|
|
|
38
28
|
isExperimental
|
|
39
29
|
} = (0, _core.useIOExperimentalDesign)();
|
|
40
30
|
const theme = (0, _core.useIOTheme)();
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
const legacyInfoCopyText = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_typography.Body, {
|
|
44
|
-
weight: "Regular"
|
|
45
|
-
}, label), /*#__PURE__*/_react.default.createElement(_spacer.VSpacer, {
|
|
46
|
-
size: 4
|
|
47
|
-
}), typeof value === "string" ? /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
48
|
-
style: [legacyStyles.textValue, {
|
|
49
|
-
color: _core.IOColors.blue
|
|
50
|
-
}],
|
|
51
|
-
numberOfLines: numberOfLines
|
|
52
|
-
}, value) : {
|
|
53
|
-
value
|
|
54
|
-
});
|
|
55
|
-
const infoCopyText = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
31
|
+
const foregroundColor = isExperimental ? theme["interactiveElem-default"] : "blue";
|
|
32
|
+
const listItemInfoCopyContent = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
56
33
|
weight: "Regular",
|
|
57
34
|
color: theme["textBody-tertiary"]
|
|
58
35
|
}, label), typeof value === "string" ? /*#__PURE__*/_react.default.createElement(_typography.H6, {
|
|
59
|
-
color:
|
|
36
|
+
color: foregroundColor,
|
|
60
37
|
numberOfLines: numberOfLines
|
|
61
38
|
}, value) : {
|
|
62
39
|
value
|
|
63
40
|
});
|
|
64
|
-
const infoCopyTextComponent = isExperimental ? infoCopyText : legacyInfoCopyText;
|
|
65
|
-
const iconColor = isExperimental ? theme["interactiveElem-default"] : "blue";
|
|
66
41
|
const mapBackgroundStates = {
|
|
67
42
|
default: (0, _core.hexToRgba)(_core.IOColors[theme["listItem-pressed"]], 0),
|
|
68
43
|
pressed: _core.IOColors[theme["listItem-pressed"]]
|
|
@@ -117,13 +92,13 @@ const ListItemInfoCopy = _ref => {
|
|
|
117
92
|
size: _core.IOListItemVisualParams.iconSize
|
|
118
93
|
})), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
119
94
|
style: _core.IOStyles.flex
|
|
120
|
-
},
|
|
95
|
+
}, listItemInfoCopyContent), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
121
96
|
style: {
|
|
122
97
|
marginLeft: _core.IOListItemVisualParams.iconMargin
|
|
123
98
|
}
|
|
124
99
|
}, /*#__PURE__*/_react.default.createElement(_icons.Icon, {
|
|
125
100
|
name: "copy",
|
|
126
|
-
color:
|
|
101
|
+
color: foregroundColor,
|
|
127
102
|
size: _core.IOListItemVisualParams.chevronSize
|
|
128
103
|
})))));
|
|
129
104
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeReanimated","_core","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeReanimated","_core","_icons","_typography","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","ListItemInfoCopy","_ref","_IOScaleValues$basicB","label","value","numberOfLines","onPress","icon","accessibilityLabel","testID","isPressed","useSharedValue","isExperimental","useIOExperimentalDesign","theme","useIOTheme","foregroundColor","listItemInfoCopyContent","createElement","Fragment","LabelSmall","weight","color","H6","mapBackgroundStates","hexToRgba","IOColors","pressed","animationScaleValue","IOScaleValues","basicButton","pressedState","progressPressed","useDerivedValue","withSpring","IOSpringValues","button","animatedScaleStyle","useAnimatedStyle","scale","interpolate","Extrapolate","CLAMP","transform","animatedBackgroundStyle","backgroundColor","interpolateColor","handlePressIn","useCallback","handlePressOut","Pressable","onPressIn","onPressOut","accessible","accessibilityRole","View","style","IOListItemStyles","listItem","listItemInner","marginRight","IOListItemVisualParams","iconMargin","Icon","name","size","iconSize","IOStyles","flex","marginLeft","chevronSize","exports","_default"],"sourceRoot":"../../../../src","sources":["components/listitems/ListItemInfoCopy.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAH,uBAAA,CAAAC,OAAA;AASA,IAAAG,KAAA,GAAAH,OAAA;AAYA,IAAAI,MAAA,GAAAJ,OAAA;AACA,IAAAK,WAAA,GAAAL,OAAA;AAA+C,SAAAM,yBAAAC,WAAA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|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
9
|
var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
|
|
10
10
|
var _core = require("../../core");
|
|
11
|
-
var
|
|
11
|
+
var _badge = require("../badge");
|
|
12
12
|
var _icons = require("../icons");
|
|
13
13
|
var _logos = require("../logos");
|
|
14
|
+
var _spacer = require("../spacer");
|
|
14
15
|
var _typography = require("../typography");
|
|
15
16
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
16
17
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
17
|
-
// TODO: Remove this when legacy look is deprecated https://pagopa.atlassian.net/browse/IOPLT-153
|
|
18
|
-
const legacyStyles = _reactNative.StyleSheet.create({
|
|
19
|
-
textValue: {
|
|
20
|
-
fontSize: 18,
|
|
21
|
-
lineHeight: 24,
|
|
22
|
-
color: _core.IOColors.bluegreyDark,
|
|
23
|
-
...(0, _fonts.makeFontStyleObject)("SemiBold", undefined, "TitilliumWeb")
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
18
|
const ListItemNav = _ref => {
|
|
27
19
|
var _IOScaleValues$basicB;
|
|
28
20
|
let {
|
|
@@ -33,27 +25,27 @@ const ListItemNav = _ref => {
|
|
|
33
25
|
iconColor = "grey-450",
|
|
34
26
|
paymentLogo,
|
|
35
27
|
accessibilityLabel,
|
|
36
|
-
testID
|
|
28
|
+
testID,
|
|
29
|
+
hideChevron = false,
|
|
30
|
+
badgeProps
|
|
37
31
|
} = _ref;
|
|
38
32
|
const isPressed = (0, _reactNativeReanimated.useSharedValue)(0);
|
|
39
33
|
const {
|
|
40
34
|
isExperimental
|
|
41
35
|
} = (0, _core.useIOExperimentalDesign)();
|
|
42
36
|
const theme = (0, _core.useIOTheme)();
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
},
|
|
50
|
-
const navText = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_typography.H6, {
|
|
37
|
+
const listItemNavContent = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, badgeProps && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
38
|
+
style: {
|
|
39
|
+
alignSelf: "flex-start"
|
|
40
|
+
}
|
|
41
|
+
}, /*#__PURE__*/_react.default.createElement(_badge.Badge, badgeProps)), /*#__PURE__*/_react.default.createElement(_spacer.VSpacer, {
|
|
42
|
+
size: 4
|
|
43
|
+
})), typeof value === "string" ? /*#__PURE__*/_react.default.createElement(_typography.H6, {
|
|
51
44
|
color: theme["textBody-default"]
|
|
52
|
-
}, value), description && /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
45
|
+
}, value) : value, description && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, typeof description === "string" ? /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
53
46
|
weight: "Regular",
|
|
54
47
|
color: theme["textBody-tertiary"]
|
|
55
|
-
}, description));
|
|
56
|
-
const navTextComponent = isExperimental ? navText : legacyNavText;
|
|
48
|
+
}, description) : description));
|
|
57
49
|
const mapBackgroundStates = {
|
|
58
50
|
default: (0, _core.hexToRgba)(_core.IOColors[theme["listItem-pressed"]], 0),
|
|
59
51
|
pressed: _core.IOColors[theme["listItem-pressed"]]
|
|
@@ -116,7 +108,7 @@ const ListItemNav = _ref => {
|
|
|
116
108
|
size: _core.IOListItemVisualParams.iconSize
|
|
117
109
|
})), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
118
110
|
style: _core.IOStyles.flex
|
|
119
|
-
},
|
|
111
|
+
}, listItemNavContent), !hideChevron && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
120
112
|
style: {
|
|
121
113
|
marginLeft: _core.IOListItemVisualParams.iconMargin
|
|
122
114
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeReanimated","_core","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeReanimated","_core","_badge","_icons","_logos","_spacer","_typography","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","ListItemNav","_ref","_IOScaleValues$basicB","value","description","onPress","icon","iconColor","paymentLogo","accessibilityLabel","testID","hideChevron","badgeProps","isPressed","useSharedValue","isExperimental","useIOExperimentalDesign","theme","useIOTheme","listItemNavContent","createElement","Fragment","View","style","alignSelf","Badge","VSpacer","size","H6","color","LabelSmall","weight","mapBackgroundStates","hexToRgba","IOColors","pressed","navIconColor","animationScaleValue","IOScaleValues","basicButton","pressedState","progressPressed","useDerivedValue","withSpring","IOSpringValues","button","animatedScaleStyle","useAnimatedStyle","scale","interpolate","Extrapolate","CLAMP","transform","animatedBackgroundStyle","backgroundColor","interpolateColor","handlePressIn","useCallback","handlePressOut","Pressable","onPressIn","onPressOut","accessible","accessibilityRole","IOListItemStyles","listItem","listItemInner","marginRight","IOListItemVisualParams","iconMargin","Icon","name","iconSize","LogoPayment","IOStyles","flex","marginLeft","chevronSize","exports","_default"],"sourceRoot":"../../../../src","sources":["components/listitems/ListItemNav.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAH,uBAAA,CAAAC,OAAA;AASA,IAAAG,KAAA,GAAAH,OAAA;AAYA,IAAAI,MAAA,GAAAJ,OAAA;AACA,IAAAK,MAAA,GAAAL,OAAA;AACA,IAAAM,MAAA,GAAAN,OAAA;AACA,IAAAO,OAAA,GAAAP,OAAA;AACA,IAAAQ,WAAA,GAAAR,OAAA;AAA+C,SAAAS,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAX,wBAAAe,GAAA,EAAAJ,WAAA,SAAAA,WAAA,IAAAI,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,oBAAAA,GAAA,wBAAAA,GAAA,4BAAAE,OAAA,EAAAF,GAAA,UAAAG,KAAA,GAAAR,wBAAA,CAAAC,WAAA,OAAAO,KAAA,IAAAA,KAAA,CAAAC,GAAA,CAAAJ,GAAA,YAAAG,KAAA,CAAAE,GAAA,CAAAL,GAAA,SAAAM,MAAA,WAAAC,qBAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,GAAA,IAAAX,GAAA,QAAAW,GAAA,kBAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAd,GAAA,EAAAW,GAAA,SAAAI,IAAA,GAAA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YAAa;IACpBT,IAAI,EAAEyC,4BAAsB,CAACS;EAAY,CAC1C,CACG,CAEK,CACF,CACN,CAAC;AAEhB,CAAC;AAACC,OAAA,CAAA9E,WAAA,GAAAA,WAAA;AAAA,IAAA+E,QAAA,GAEa/E,WAAW;AAAA8E,OAAA,CAAA7F,OAAA,GAAA8F,QAAA"}
|
|
@@ -8,19 +8,10 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
9
|
var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
|
|
10
10
|
var _core = require("../../core");
|
|
11
|
-
var _fonts = require("../../utils/fonts");
|
|
12
11
|
var _icons = require("../icons");
|
|
13
12
|
var _typography = require("../typography");
|
|
14
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
15
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
16
|
-
// TODO: Remove this when legacy look is deprecated https://pagopa.atlassian.net/browse/IOPLT-153
|
|
17
|
-
const legacyStyles = _reactNative.StyleSheet.create({
|
|
18
|
-
textValue: {
|
|
19
|
-
fontSize: 18,
|
|
20
|
-
lineHeight: 24,
|
|
21
|
-
...(0, _fonts.makeFontStyleObject)("SemiBold", undefined, "TitilliumWeb")
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
15
|
const ListItemNavAlert = _ref => {
|
|
25
16
|
var _IOScaleValues$basicB;
|
|
26
17
|
let {
|
|
@@ -38,21 +29,12 @@ const ListItemNavAlert = _ref => {
|
|
|
38
29
|
const theme = (0, _core.useIOTheme)();
|
|
39
30
|
|
|
40
31
|
// TODO: Remove this when legacy look is deprecated https://pagopa.atlassian.net/browse/IOPLT-153
|
|
41
|
-
const
|
|
42
|
-
style: [legacyStyles.textValue, {
|
|
43
|
-
color: _core.IOColors.bluegreyDark
|
|
44
|
-
}]
|
|
45
|
-
}, value), description && /*#__PURE__*/_react.default.createElement(_typography.Body, {
|
|
46
|
-
weight: "SemiBold",
|
|
47
|
-
color: theme.errorText
|
|
48
|
-
}, description));
|
|
49
|
-
const navAlertText = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_typography.H6, {
|
|
32
|
+
const listItemNavAlertContent = /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, typeof value === "string" ? /*#__PURE__*/_react.default.createElement(_typography.H6, {
|
|
50
33
|
color: theme["textBody-default"]
|
|
51
|
-
}, value), description && /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
34
|
+
}, value) : value, description && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, typeof description === "string" ? /*#__PURE__*/_react.default.createElement(_typography.LabelSmall, {
|
|
52
35
|
weight: "SemiBold",
|
|
53
36
|
color: theme.errorText
|
|
54
|
-
}, description));
|
|
55
|
-
const navAlertTextComponent = isExperimental ? navAlertText : legacyNavAlertText;
|
|
37
|
+
}, description) : description));
|
|
56
38
|
const iconColor = isExperimental ? theme["interactiveElem-default"] : "blue";
|
|
57
39
|
const mapBackgroundStates = {
|
|
58
40
|
default: (0, _core.hexToRgba)(_core.IOColors[theme["listItem-pressed"]], 0),
|
|
@@ -108,7 +90,7 @@ const ListItemNavAlert = _ref => {
|
|
|
108
90
|
size: _core.IOListItemVisualParams.iconSize
|
|
109
91
|
})), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
110
92
|
style: _core.IOStyles.flex
|
|
111
|
-
},
|
|
93
|
+
}, listItemNavAlertContent), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
112
94
|
style: {
|
|
113
95
|
marginLeft: _core.IOListItemVisualParams.iconMargin
|
|
114
96
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeReanimated","_core","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeReanimated","_core","_icons","_typography","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","ListItemNavAlert","_ref","_IOScaleValues$basicB","value","description","withoutIcon","onPress","accessibilityLabel","testID","isPressed","useSharedValue","isExperimental","useIOExperimentalDesign","theme","useIOTheme","listItemNavAlertContent","createElement","Fragment","H6","color","LabelSmall","weight","errorText","iconColor","mapBackgroundStates","hexToRgba","IOColors","pressed","animationScaleValue","IOScaleValues","basicButton","pressedState","progressPressed","useDerivedValue","withSpring","IOSpringValues","button","animatedScaleStyle","useAnimatedStyle","scale","interpolate","Extrapolate","CLAMP","transform","animatedBackgroundStyle","backgroundColor","interpolateColor","handlePressIn","useCallback","handlePressOut","Pressable","onPressIn","onPressOut","accessible","accessibilityRole","View","style","IOListItemStyles","listItem","listItemInner","marginRight","IOListItemVisualParams","iconMargin","Icon","name","errorIcon","size","iconSize","IOStyles","flex","marginLeft","chevronSize","exports","_default"],"sourceRoot":"../../../../src","sources":["components/listitems/ListItemNavAlert.tsx"],"mappings":";;;;;;AAAA,IAA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AA,CAAAe,OAAA,CAAA+B,aAAA,CAACxC,MAAA,CAAAuF,IAAI;IACHC,IAAI,EAAC,sBAAsB;IAC3B7C,KAAK,EAAEI,SAAU;IACjB2C,IAAI,EAAEL,4BAAsB,CAACU;EAAY,CAC1C,CACG,CACO,CACF,CACN,CAAC;AAEhB,CAAC;AAACC,OAAA,CAAAxE,gBAAA,GAAAA,gBAAA;AAAA,IAAAyE,QAAA,GAEazE,gBAAgB;AAAAwE,OAAA,CAAAvF,OAAA,GAAAwF,QAAA"}
|
|
@@ -8,11 +8,13 @@ var React = _interopRequireWildcard(require("react"));
|
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
9
|
var _reactNativeHapticFeedback = _interopRequireDefault(require("react-native-haptic-feedback"));
|
|
10
10
|
var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
|
|
11
|
+
var _rnPlaceholder = _interopRequireDefault(require("rn-placeholder"));
|
|
11
12
|
var _core = require("../../core");
|
|
12
13
|
var _icons = require("../icons");
|
|
13
14
|
var _spacer = require("../spacer");
|
|
14
15
|
var _typography = require("../typography");
|
|
15
16
|
var _AnimatedRadio = require("../radio/AnimatedRadio");
|
|
17
|
+
var _logos = require("../logos");
|
|
16
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
19
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
18
20
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -21,7 +23,7 @@ const DISABLED_OPACITY = 0.5;
|
|
|
21
23
|
// disabled: the component is no longer touchable
|
|
22
24
|
// onPress:
|
|
23
25
|
/**
|
|
24
|
-
*
|
|
26
|
+
* `ListItemRadio` component with the automatic state management that uses a {@link AnimatedCheckBox}
|
|
25
27
|
* The toggleValue change when a `onPress` event is received and dispatch the `onValueChange`.
|
|
26
28
|
*
|
|
27
29
|
* @param props
|
|
@@ -32,16 +34,16 @@ const ListItemRadio = _ref => {
|
|
|
32
34
|
let {
|
|
33
35
|
value,
|
|
34
36
|
description,
|
|
35
|
-
|
|
37
|
+
startImage,
|
|
36
38
|
selected,
|
|
37
39
|
disabled,
|
|
38
40
|
onValueChange,
|
|
41
|
+
loadingProps,
|
|
39
42
|
testID
|
|
40
43
|
} = _ref;
|
|
41
44
|
const [toggleValue, setToggleValue] = (0, React.useState)(selected ?? false);
|
|
42
45
|
// Animations
|
|
43
46
|
const isPressed = (0, _reactNativeReanimated.useSharedValue)(0);
|
|
44
|
-
|
|
45
47
|
// Scaling transformation applied when the button is pressed
|
|
46
48
|
const animationScaleValue = _core.IOScaleValues === null || _core.IOScaleValues === void 0 || (_IOScaleValues$basicB = _core.IOScaleValues.basicButton) === null || _IOScaleValues$basicB === void 0 ? void 0 : _IOScaleValues$basicB.pressedState;
|
|
47
49
|
const progressPressed = (0, _reactNativeReanimated.useDerivedValue)(() => (0, _reactNativeReanimated.withSpring)(isPressed.value, _core.IOSpringValues.button));
|
|
@@ -83,7 +85,63 @@ const ListItemRadio = _ref => {
|
|
|
83
85
|
onValueChange(!toggleValue);
|
|
84
86
|
}
|
|
85
87
|
};
|
|
86
|
-
|
|
88
|
+
const disabledStyle = {
|
|
89
|
+
opacity: disabled ? DISABLED_OPACITY : 1
|
|
90
|
+
};
|
|
91
|
+
const SkeletonDescriptionLines = () => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_spacer.VSpacer, {
|
|
92
|
+
size: 8
|
|
93
|
+
}), /*#__PURE__*/React.createElement(_rnPlaceholder.default.Box, {
|
|
94
|
+
animate: "fade",
|
|
95
|
+
radius: 8,
|
|
96
|
+
width: "100%",
|
|
97
|
+
height: 8
|
|
98
|
+
}), /*#__PURE__*/React.createElement(_spacer.VSpacer, {
|
|
99
|
+
size: 8
|
|
100
|
+
}), /*#__PURE__*/React.createElement(_rnPlaceholder.default.Box, {
|
|
101
|
+
animate: "fade",
|
|
102
|
+
radius: 8,
|
|
103
|
+
width: "100%",
|
|
104
|
+
height: 8
|
|
105
|
+
}), /*#__PURE__*/React.createElement(_spacer.VSpacer, {
|
|
106
|
+
size: 8
|
|
107
|
+
}), /*#__PURE__*/React.createElement(_rnPlaceholder.default.Box, {
|
|
108
|
+
animate: "fade",
|
|
109
|
+
radius: 8,
|
|
110
|
+
width: "100%",
|
|
111
|
+
height: 8
|
|
112
|
+
}));
|
|
113
|
+
const SkeletonIcon = () => /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
114
|
+
style: {
|
|
115
|
+
marginRight: _core.IOSelectionListItemVisualParams.iconMargin
|
|
116
|
+
}
|
|
117
|
+
}, /*#__PURE__*/React.createElement(_rnPlaceholder.default.Box, {
|
|
118
|
+
animate: "fade",
|
|
119
|
+
radius: 4,
|
|
120
|
+
width: _core.IOSelectionListItemVisualParams.iconSize,
|
|
121
|
+
height: _core.IOSelectionListItemVisualParams.iconSize
|
|
122
|
+
}));
|
|
123
|
+
const SkeletonComponent = () => /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
124
|
+
style: _core.IOSelectionListItemStyles.listItem
|
|
125
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
126
|
+
style: _core.IOSelectionListItemStyles.listItemInner
|
|
127
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
128
|
+
style: [_core.IOStyles.flex, _core.IOStyles.rowSpaceBetween, _core.IOStyles.alignCenter]
|
|
129
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
130
|
+
style: [_core.IOStyles.row, _core.IOStyles.alignCenter]
|
|
131
|
+
}, (loadingProps === null || loadingProps === void 0 ? void 0 : loadingProps.skeletonIcon) && /*#__PURE__*/React.createElement(SkeletonIcon, null), /*#__PURE__*/React.createElement(_rnPlaceholder.default.Box, {
|
|
132
|
+
animate: "fade",
|
|
133
|
+
radius: 8,
|
|
134
|
+
width: 179,
|
|
135
|
+
height: 16
|
|
136
|
+
})), /*#__PURE__*/React.createElement(_spacer.HSpacer, {
|
|
137
|
+
size: 8
|
|
138
|
+
}), /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
139
|
+
pointerEvents: "none",
|
|
140
|
+
style: disabledStyle
|
|
141
|
+
}, /*#__PURE__*/React.createElement(_AnimatedRadio.AnimatedRadio, {
|
|
142
|
+
checked: toggleValue
|
|
143
|
+
})))), (loadingProps === null || loadingProps === void 0 ? void 0 : loadingProps.skeletonDescription) && /*#__PURE__*/React.createElement(SkeletonDescriptionLines, null));
|
|
144
|
+
return loadingProps !== null && loadingProps !== void 0 && loadingProps.state ? /*#__PURE__*/React.createElement(SkeletonComponent, null) : /*#__PURE__*/React.createElement(_reactNative.Pressable, {
|
|
87
145
|
onPress: toggleRadioItem,
|
|
88
146
|
onPressIn: handlePressIn,
|
|
89
147
|
onPressOut: handlePressOut,
|
|
@@ -91,9 +149,7 @@ const ListItemRadio = _ref => {
|
|
|
91
149
|
testID: testID,
|
|
92
150
|
disabled: disabled
|
|
93
151
|
}, /*#__PURE__*/React.createElement(_reactNativeReanimated.default.View, {
|
|
94
|
-
style: [_core.IOSelectionListItemStyles.listItem, animatedBackgroundStyle,
|
|
95
|
-
opacity: disabled ? DISABLED_OPACITY : 1
|
|
96
|
-
}]
|
|
152
|
+
style: [_core.IOSelectionListItemStyles.listItem, animatedBackgroundStyle, disabledStyle]
|
|
97
153
|
// This is required to avoid opacity
|
|
98
154
|
// inheritance on Android
|
|
99
155
|
,
|
|
@@ -106,14 +162,17 @@ const ListItemRadio = _ref => {
|
|
|
106
162
|
style: [_core.IOStyles.row, {
|
|
107
163
|
flexShrink: 1
|
|
108
164
|
}]
|
|
109
|
-
},
|
|
165
|
+
}, startImage && /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
110
166
|
style: {
|
|
111
167
|
marginRight: _core.IOSelectionListItemVisualParams.iconMargin
|
|
112
168
|
}
|
|
113
|
-
}, /*#__PURE__*/React.createElement(_icons.Icon, {
|
|
114
|
-
name: icon,
|
|
169
|
+
}, startImage.icon && /*#__PURE__*/React.createElement(_icons.Icon, {
|
|
170
|
+
name: startImage.icon,
|
|
115
171
|
color: "grey-300",
|
|
116
172
|
size: _core.IOSelectionListItemVisualParams.iconSize
|
|
173
|
+
}), startImage.paymentLogo && /*#__PURE__*/React.createElement(_logos.LogoPayment, {
|
|
174
|
+
name: startImage.paymentLogo,
|
|
175
|
+
size: _core.IOSelectionListItemVisualParams.iconSize
|
|
117
176
|
})), /*#__PURE__*/React.createElement(_typography.H6, {
|
|
118
177
|
color: "black",
|
|
119
178
|
style: {
|