@digigov/react-core 2.0.0-d57821ba → 2.0.0-daaf7bdf
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/Base/compat/Input/CheckboxInput.native/index.js +33 -0
- package/Base/compat/Input/CheckboxInput.native/package.json +6 -0
- package/Base/compat/Input/CheckboxInput.native.d.ts +4 -0
- package/Base/compat/Input/CheckboxInput.native.js.map +7 -0
- package/Base/compat/Input/RadioInput.native/index.js +32 -0
- package/Base/compat/Input/RadioInput.native/package.json +6 -0
- package/Base/compat/Input/RadioInput.native.d.ts +4 -0
- package/Base/compat/Input/RadioInput.native.js.map +7 -0
- package/Base/compat/Input/StringInput.native/index.js +99 -0
- package/Base/compat/Input/StringInput.native/package.json +6 -0
- package/Base/compat/Input/StringInput.native.d.ts +7 -0
- package/Base/compat/Input/StringInput.native.js.map +7 -0
- package/Base/compat/Input/index.native/index.js +24 -0
- package/Base/compat/Input/index.native/package.json +6 -0
- package/Base/compat/Input/index.native.d.ts +7 -0
- package/Base/compat/Input/index.native.js.map +7 -0
- package/Base/compat/button.native/index.js +48 -0
- package/Base/compat/button.native/package.json +6 -0
- package/Base/compat/button.native.d.ts +5 -0
- package/Base/compat/button.native.js.map +7 -0
- package/Base/compat/details.native/index.js +40 -0
- package/Base/compat/details.native/package.json +6 -0
- package/Base/compat/details.native.d.ts +8 -0
- package/Base/compat/details.native.js.map +7 -0
- package/Base/compat/li.native/index.js +9 -0
- package/Base/compat/li.native/package.json +6 -0
- package/Base/compat/li.native.d.ts +6 -0
- package/Base/compat/li.native.js.map +7 -0
- package/Base/compat/ol.native/index.js +33 -0
- package/Base/compat/ol.native/package.json +6 -0
- package/Base/compat/ol.native.d.ts +6 -0
- package/Base/compat/ol.native.js.map +7 -0
- package/Base/index.d.ts +2 -95
- package/Base/index.js +3 -98
- package/Base/index.js.map +3 -3
- package/Base/index.native/index.js +160 -0
- package/Base/index.native/package.json +6 -0
- package/Base/index.native.d.ts +7 -0
- package/Base/index.native.js.map +7 -0
- package/Base/index.web/index.js +104 -0
- package/Base/index.web/package.json +6 -0
- package/Base/index.web.d.ts +97 -0
- package/Base/index.web.js.map +7 -0
- package/Base/mapping.native/index.js +34 -0
- package/Base/mapping.native/package.json +6 -0
- package/Base/mapping.native.d.ts +6 -0
- package/Base/mapping.native.js.map +7 -0
- package/Base/utils/index.js +86 -0
- package/Base/utils/package.json +6 -0
- package/Base/utils.d.ts +41 -0
- package/Base/utils.js.map +7 -0
- package/Base/wrap.native/index.js +64 -0
- package/Base/wrap.native/package.json +6 -0
- package/Base/wrap.native.d.ts +2 -0
- package/Base/wrap.native.js.map +7 -0
- package/CallToAction/index.js +1 -1
- package/CallToAction/index.js.map +2 -2
- package/Card/index.js +2 -1
- package/Card/index.js.map +2 -2
- package/CheckboxItem/index.js +4 -16
- package/CheckboxItem/index.js.map +2 -2
- package/CheckboxItemInput/index.d.ts +2 -0
- package/CheckboxItemInput/index.js +6 -0
- package/CheckboxItemInput/index.js.map +7 -0
- package/CheckboxItemInput/index.native/index.js +20 -0
- package/CheckboxItemInput/index.native/package.json +6 -0
- package/CheckboxItemInput/index.native.d.ts +4 -0
- package/CheckboxItemInput/index.native.js.map +7 -0
- package/CheckboxItemInput/index.web/index.js +26 -0
- package/CheckboxItemInput/index.web/package.json +6 -0
- package/CheckboxItemInput/index.web.d.ts +10 -0
- package/CheckboxItemInput/index.web.js.map +7 -0
- package/CheckboxItemInput/package.json +6 -0
- package/Chip/index.js +2 -1
- package/Chip/index.js.map +2 -2
- package/CodeBlockContainer/index.d.ts +1 -9
- package/CodeBlockContainer/index.js +2 -3
- package/CodeBlockContainer/index.js.map +2 -2
- package/CodeBlockContent/index.d.ts +1 -1
- package/CodeBlockContent/index.js +3 -2
- package/CodeBlockContent/index.js.map +2 -2
- package/CodeBlockHeader/index.d.ts +1 -1
- package/CodeBlockHeader/index.js +1 -3
- package/CodeBlockHeader/index.js.map +2 -2
- package/CopyToClipboardContainer/index.d.ts +2 -31
- package/CopyToClipboardContainer/index.js +3 -40
- package/CopyToClipboardContainer/index.js.map +3 -3
- package/CopyToClipboardContainer/index.web/index.js +44 -0
- package/CopyToClipboardContainer/index.web/package.json +6 -0
- package/CopyToClipboardContainer/index.web.d.ts +31 -0
- package/CopyToClipboardContainer/index.web.js.map +7 -0
- package/CopyToClipboardMessage/index.d.ts +2 -18
- package/CopyToClipboardMessage/index.js +3 -21
- package/CopyToClipboardMessage/index.js.map +3 -3
- package/CopyToClipboardMessage/index.native/index.js +18 -0
- package/CopyToClipboardMessage/index.native/package.json +6 -0
- package/CopyToClipboardMessage/index.native.d.ts +6 -0
- package/CopyToClipboardMessage/index.native.js.map +7 -0
- package/CopyToClipboardMessage/index.web/index.js +24 -0
- package/CopyToClipboardMessage/index.web/package.json +6 -0
- package/CopyToClipboardMessage/index.web.d.ts +18 -0
- package/CopyToClipboardMessage/index.web.js.map +7 -0
- package/DateInputItem/index.d.ts +2 -26
- package/DateInputItem/index.js +3 -41
- package/DateInputItem/index.js.map +3 -3
- package/DateInputItem/index.native/index.js +17 -0
- package/DateInputItem/index.native/package.json +6 -0
- package/DateInputItem/index.native.d.ts +4 -0
- package/DateInputItem/index.native.js.map +7 -0
- package/DateInputItem/index.web/index.js +32 -0
- package/DateInputItem/index.web/package.json +6 -0
- package/DateInputItem/index.web.d.ts +26 -0
- package/DateInputItem/index.web.js.map +7 -0
- package/Details/index.d.ts +2 -10
- package/Details/index.js +3 -22
- package/Details/index.js.map +3 -3
- package/Details/index.native/index.js +17 -0
- package/Details/index.native/package.json +6 -0
- package/Details/index.native.d.ts +4 -0
- package/Details/index.native.js.map +7 -0
- package/Details/index.web/index.js +25 -0
- package/Details/index.web/package.json +6 -0
- package/Details/index.web.d.ts +10 -0
- package/Details/index.web.js.map +7 -0
- package/FieldsetLegend/index.js +1 -4
- package/FieldsetLegend/index.js.map +2 -2
- package/LabelTitle/index.js +2 -4
- package/LabelTitle/index.js.map +2 -2
- package/NavListItemActionContainer/index.d.ts +2 -10
- package/NavListItemActionContainer/index.js +3 -20
- package/NavListItemActionContainer/index.js.map +3 -3
- package/NavListItemActionContainer/index.native/index.js +17 -0
- package/NavListItemActionContainer/index.native/package.json +6 -0
- package/NavListItemActionContainer/index.native.d.ts +7 -0
- package/NavListItemActionContainer/index.native.js.map +7 -0
- package/NavListItemActionContainer/index.web/index.js +23 -0
- package/NavListItemActionContainer/index.web/package.json +6 -0
- package/NavListItemActionContainer/index.web.d.ts +10 -0
- package/NavListItemActionContainer/index.web.js.map +7 -0
- package/NotificationBannerLink/index.d.ts +2 -11
- package/NotificationBannerLink/index.js +3 -19
- package/NotificationBannerLink/index.js.map +3 -3
- package/NotificationBannerLink/index.native/index.js +16 -0
- package/NotificationBannerLink/index.native/package.json +6 -0
- package/NotificationBannerLink/index.native.d.ts +8 -0
- package/NotificationBannerLink/index.native.js.map +7 -0
- package/NotificationBannerLink/index.web/index.js +22 -0
- package/NotificationBannerLink/index.web/package.json +6 -0
- package/NotificationBannerLink/index.web.d.ts +11 -0
- package/NotificationBannerLink/index.web.js.map +7 -0
- package/PhaseBanner/index.js +2 -1
- package/PhaseBanner/index.js.map +2 -2
- package/PhaseBannerTag/index.d.ts +2 -2
- package/PhaseBannerTag/index.js +1 -1
- package/PhaseBannerTag/index.js.map +1 -1
- package/PhaseBannerText/index.js +1 -1
- package/PhaseBannerText/index.js.map +2 -2
- package/RadioItem/index.js +2 -1
- package/RadioItem/index.js.map +2 -2
- package/SummaryList/index.d.ts +1 -1
- package/SummaryList/index.js.map +2 -2
- package/SummaryListItemKey/index.d.ts +14 -0
- package/SummaryListItemKey/index.js +5 -2
- package/SummaryListItemKey/index.js.map +2 -2
- package/TextArea/index.d.ts +2 -24
- package/TextArea/index.js +3 -27
- package/TextArea/index.js.map +3 -3
- package/TextArea/index.native/index.js +16 -0
- package/TextArea/index.native/package.json +6 -0
- package/TextArea/index.native.d.ts +4 -0
- package/TextArea/index.native.js.map +7 -0
- package/TextArea/index.web/index.js +30 -0
- package/TextArea/index.web/package.json +6 -0
- package/TextArea/index.web.d.ts +24 -0
- package/TextArea/index.web.js.map +7 -0
- package/TextInput/index.d.ts +2 -46
- package/TextInput/index.js +3 -40
- package/TextInput/index.js.map +3 -3
- package/TextInput/index.native/index.js +19 -0
- package/TextInput/index.native/package.json +6 -0
- package/TextInput/index.native.d.ts +4 -0
- package/TextInput/index.native.js.map +7 -0
- package/TextInput/index.web/index.js +43 -0
- package/TextInput/index.web/package.json +6 -0
- package/TextInput/index.web.d.ts +46 -0
- package/TextInput/index.web.js.map +7 -0
- package/Unpurge/index.js +78 -0
- package/Unpurge/index.js.map +2 -2
- package/WarningText/index.js +7 -12
- package/WarningText/index.js.map +2 -2
- package/WarningTextAssistive/index.d.ts +15 -0
- package/WarningTextAssistive/index.js +23 -0
- package/WarningTextAssistive/index.js.map +7 -0
- package/WarningTextAssistive/package.json +6 -0
- package/cjs/Base/compat/Input/CheckboxInput.native/index.js +66 -0
- package/cjs/Base/compat/Input/CheckboxInput.native.js.map +7 -0
- package/cjs/Base/compat/Input/RadioInput.native/index.js +65 -0
- package/cjs/Base/compat/Input/RadioInput.native.js.map +7 -0
- package/cjs/Base/compat/Input/StringInput.native/index.js +129 -0
- package/cjs/Base/compat/Input/StringInput.native.js.map +7 -0
- package/cjs/Base/compat/Input/index.native/index.js +55 -0
- package/cjs/Base/compat/Input/index.native.js.map +7 -0
- package/cjs/Base/compat/button.native/index.js +81 -0
- package/cjs/Base/compat/button.native.js.map +7 -0
- package/cjs/Base/compat/details.native/index.js +65 -0
- package/cjs/Base/compat/details.native.js.map +7 -0
- package/cjs/Base/compat/li.native/index.js +42 -0
- package/cjs/Base/compat/li.native.js.map +7 -0
- package/cjs/Base/compat/ol.native/index.js +66 -0
- package/cjs/Base/compat/ol.native.js.map +7 -0
- package/cjs/Base/index.js +5 -99
- package/cjs/Base/index.js.map +3 -3
- package/cjs/Base/index.native/index.js +193 -0
- package/cjs/Base/index.native.js.map +7 -0
- package/cjs/Base/index.web/index.js +137 -0
- package/cjs/Base/index.web.js.map +7 -0
- package/cjs/Base/mapping.native/index.js +67 -0
- package/cjs/Base/mapping.native.js.map +7 -0
- package/cjs/Base/utils/index.js +119 -0
- package/cjs/Base/utils.js.map +7 -0
- package/cjs/Base/wrap.native/index.js +97 -0
- package/cjs/Base/wrap.native.js.map +7 -0
- package/cjs/CallToAction/index.js +1 -1
- package/cjs/CallToAction/index.js.map +2 -2
- package/cjs/Card/index.js +2 -1
- package/cjs/Card/index.js.map +2 -2
- package/cjs/CheckboxItem/index.js +4 -16
- package/cjs/CheckboxItem/index.js.map +3 -3
- package/cjs/CheckboxItemInput/index.js +40 -0
- package/cjs/CheckboxItemInput/index.js.map +7 -0
- package/cjs/CheckboxItemInput/index.native/index.js +53 -0
- package/cjs/CheckboxItemInput/index.native.js.map +7 -0
- package/cjs/CheckboxItemInput/index.web/index.js +59 -0
- package/cjs/CheckboxItemInput/index.web.js.map +7 -0
- package/cjs/Chip/index.js +2 -1
- package/cjs/Chip/index.js.map +2 -2
- package/cjs/CodeBlockContainer/index.js +2 -3
- package/cjs/CodeBlockContainer/index.js.map +2 -2
- package/cjs/CodeBlockContent/index.js +3 -2
- package/cjs/CodeBlockContent/index.js.map +2 -2
- package/cjs/CodeBlockHeader/index.js +1 -3
- package/cjs/CodeBlockHeader/index.js.map +2 -2
- package/cjs/CopyToClipboardContainer/index.js +5 -41
- package/cjs/CopyToClipboardContainer/index.js.map +3 -3
- package/cjs/CopyToClipboardContainer/index.web/index.js +77 -0
- package/cjs/CopyToClipboardContainer/index.web.js.map +7 -0
- package/cjs/CopyToClipboardMessage/index.js +5 -22
- package/cjs/CopyToClipboardMessage/index.js.map +3 -3
- package/cjs/CopyToClipboardMessage/index.native/index.js +51 -0
- package/cjs/CopyToClipboardMessage/index.native.js.map +7 -0
- package/cjs/CopyToClipboardMessage/index.web/index.js +57 -0
- package/cjs/CopyToClipboardMessage/index.web.js.map +7 -0
- package/cjs/DateInputItem/index.js +5 -42
- package/cjs/DateInputItem/index.js.map +3 -3
- package/cjs/DateInputItem/index.native/index.js +50 -0
- package/cjs/DateInputItem/index.native.js.map +7 -0
- package/cjs/DateInputItem/index.web/index.js +65 -0
- package/cjs/DateInputItem/index.web.js.map +7 -0
- package/cjs/Details/index.js +5 -23
- package/cjs/Details/index.js.map +3 -3
- package/cjs/Details/index.native/index.js +50 -0
- package/cjs/Details/index.native.js.map +7 -0
- package/cjs/Details/index.web/index.js +58 -0
- package/cjs/Details/index.web.js.map +7 -0
- package/cjs/FieldsetLegend/index.js +1 -4
- package/cjs/FieldsetLegend/index.js.map +2 -2
- package/cjs/LabelTitle/index.js +2 -4
- package/cjs/LabelTitle/index.js.map +2 -2
- package/cjs/NavListItemActionContainer/index.js +5 -21
- package/cjs/NavListItemActionContainer/index.js.map +3 -3
- package/cjs/NavListItemActionContainer/index.native/index.js +50 -0
- package/cjs/NavListItemActionContainer/index.native.js.map +7 -0
- package/cjs/NavListItemActionContainer/index.web/index.js +56 -0
- package/cjs/NavListItemActionContainer/index.web.js.map +7 -0
- package/cjs/NotificationBannerLink/index.js +5 -20
- package/cjs/NotificationBannerLink/index.js.map +3 -3
- package/cjs/NotificationBannerLink/index.native/index.js +49 -0
- package/cjs/NotificationBannerLink/index.native.js.map +7 -0
- package/cjs/NotificationBannerLink/index.web/index.js +55 -0
- package/cjs/NotificationBannerLink/index.web.js.map +7 -0
- package/cjs/PhaseBanner/index.js +2 -1
- package/cjs/PhaseBanner/index.js.map +2 -2
- package/cjs/PhaseBannerTag/index.js +1 -1
- package/cjs/PhaseBannerTag/index.js.map +1 -1
- package/cjs/PhaseBannerText/index.js +1 -1
- package/cjs/PhaseBannerText/index.js.map +2 -2
- package/cjs/RadioItem/index.js +2 -1
- package/cjs/RadioItem/index.js.map +3 -3
- package/cjs/SummaryList/index.js.map +2 -2
- package/cjs/SummaryListItemKey/index.js +5 -2
- package/cjs/SummaryListItemKey/index.js.map +2 -2
- package/cjs/TextArea/index.js +5 -28
- package/cjs/TextArea/index.js.map +3 -3
- package/cjs/TextArea/index.native/index.js +49 -0
- package/cjs/TextArea/index.native.js.map +7 -0
- package/cjs/TextArea/index.web/index.js +63 -0
- package/cjs/TextArea/index.web.js.map +7 -0
- package/cjs/TextInput/index.js +5 -41
- package/cjs/TextInput/index.js.map +3 -3
- package/cjs/TextInput/index.native/index.js +52 -0
- package/cjs/TextInput/index.native.js.map +7 -0
- package/cjs/TextInput/index.web/index.js +76 -0
- package/cjs/TextInput/index.web.js.map +7 -0
- package/cjs/Unpurge/index.js +78 -0
- package/cjs/Unpurge/index.js.map +2 -2
- package/cjs/WarningText/index.js +7 -12
- package/cjs/WarningText/index.js.map +2 -2
- package/cjs/WarningTextAssistive/index.js +56 -0
- package/cjs/WarningTextAssistive/index.js.map +7 -0
- package/cjs/index.js +5 -1
- package/cjs/index.js.map +2 -2
- package/cjs/lazy/index.js +12 -10
- package/cjs/lazy.js.map +2 -2
- package/cjs/registry/index.js +27 -1
- package/cjs/registry.js.map +2 -2
- package/cjs/utils/extend.native/index.js +47 -0
- package/cjs/utils/extend.native.js.map +7 -0
- package/index.d.ts +2 -0
- package/index.js +3 -1
- package/index.js.map +2 -2
- package/lazy/index.js +12 -10
- package/lazy.d.ts +219 -217
- package/lazy.js.map +2 -2
- package/package.json +21 -4
- package/registry/index.js +27 -1
- package/registry.d.ts +13 -0
- package/registry.js.map +2 -2
- package/src/Base/compat/Input/CheckboxInput.native.tsx +40 -0
- package/src/Base/compat/Input/RadioInput.native.tsx +39 -0
- package/src/Base/compat/Input/StringInput.native.tsx +115 -0
- package/src/Base/compat/Input/index.native.tsx +28 -0
- package/src/Base/compat/button.native.tsx +53 -0
- package/src/Base/compat/details.native.tsx +68 -0
- package/src/Base/compat/li.native.tsx +11 -0
- package/src/Base/compat/ol.native.tsx +41 -0
- package/src/Base/index.native.tsx +185 -0
- package/src/Base/index.tsx +2 -257
- package/src/Base/index.web.tsx +259 -0
- package/src/Base/mapping.native.tsx +41 -0
- package/src/Base/utils.ts +84 -0
- package/src/Base/wrap.native.tsx +94 -0
- package/src/CallToAction/index.tsx +2 -2
- package/src/Card/index.tsx +3 -2
- package/src/CheckboxItem/index.tsx +4 -14
- package/src/CheckboxItemInput/index.native.tsx +17 -0
- package/src/CheckboxItemInput/index.tsx +2 -0
- package/src/CheckboxItemInput/index.web.tsx +34 -0
- package/src/Chip/index.tsx +2 -2
- package/src/CodeBlockContainer/index.tsx +3 -16
- package/src/CodeBlockContent/index.tsx +5 -4
- package/src/CodeBlockHeader/index.tsx +2 -4
- package/src/CopyToClipboardContainer/index.tsx +2 -74
- package/src/CopyToClipboardContainer/index.web.tsx +75 -0
- package/src/CopyToClipboardMessage/index.native.tsx +21 -0
- package/src/CopyToClipboardMessage/index.tsx +2 -41
- package/src/CopyToClipboardMessage/index.web.tsx +41 -0
- package/src/DateInputItem/index.native.tsx +12 -0
- package/src/DateInputItem/index.tsx +2 -64
- package/src/DateInputItem/index.web.tsx +53 -0
- package/src/Details/index.native.tsx +14 -0
- package/src/Details/index.tsx +2 -27
- package/src/Details/index.web.tsx +27 -0
- package/src/FieldsetLegend/index.tsx +1 -4
- package/src/LabelTitle/index.tsx +2 -4
- package/src/NavListItemActionContainer/index.native.tsx +18 -0
- package/src/NavListItemActionContainer/index.tsx +2 -28
- package/src/NavListItemActionContainer/index.web.tsx +28 -0
- package/src/NotificationBannerLink/index.native.tsx +22 -0
- package/src/NotificationBannerLink/index.tsx +2 -28
- package/src/NotificationBannerLink/index.web.tsx +28 -0
- package/src/PhaseBanner/index.tsx +2 -2
- package/src/PhaseBannerTag/index.tsx +3 -3
- package/src/PhaseBannerText/__snapshots__/index.test.tsx.snap +1 -1
- package/src/PhaseBannerText/index.tsx +1 -1
- package/src/RadioItem/index.tsx +2 -2
- package/src/SummaryList/index.tsx +7 -5
- package/src/SummaryListItemKey/index.tsx +24 -2
- package/src/TextArea/index.native.tsx +11 -0
- package/src/TextArea/index.tsx +2 -50
- package/src/TextArea/index.web.tsx +50 -0
- package/src/TextInput/index.native.tsx +15 -0
- package/src/TextInput/index.tsx +2 -87
- package/src/TextInput/index.web.tsx +87 -0
- package/src/Unpurge/index.tsx +78 -0
- package/src/WarningText/index.tsx +12 -15
- package/src/WarningTextAssistive/index.tsx +37 -0
- package/src/index.ts +2 -0
- package/src/lazy.js +12 -10
- package/src/registry.js +28 -2
- package/src/utils/extend.native.tsx +36 -0
- package/utils/extend.native/index.js +14 -0
- package/utils/extend.native/package.json +6 -0
- package/utils/extend.native.d.ts +23 -0
- package/utils/extend.native.js.map +7 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/PhaseBannerText/index.tsx"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface PhaseBannerTextProps extends BaseProps<'span'> { }\n/**\n * PhaseBannerText is used inside the PhaseBanner component.\n * It requires a text with more details about the phase of the service (ex. \"This is a new service\").\n * This components is optional\n */\nexport const PhaseBannerText = React.forwardRef<\n HTMLSpanElement,\n PhaseBannerTextProps\n>(function PhaseBannerText({ className, children, ...props }, ref) {\n return (\n <Base\n as=\"span\"\n ref={ref}\n className={clsx(className, {\n 'ds-phase-
|
|
5
|
-
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AAQzB,MAAM,kBAAkB,MAAM,WAGnC,SAASA,iBAAgB,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,KAAK;AACjE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,IAAG;AAAA,MACH;AAAA,MACA,WAAW,KAAK,WAAW;AAAA,QACzB,
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface PhaseBannerTextProps extends BaseProps<'span'> { }\n/**\n * PhaseBannerText is used inside the PhaseBanner component.\n * It requires a text with more details about the phase of the service (ex. \"This is a new service\").\n * This components is optional\n */\nexport const PhaseBannerText = React.forwardRef<\n HTMLSpanElement,\n PhaseBannerTextProps\n>(function PhaseBannerText({ className, children, ...props }, ref) {\n return (\n <Base\n as=\"span\"\n ref={ref}\n className={clsx(className, {\n 'ds-phase-banner__message': true,\n })}\n {...props}\n >\n {children}\n </Base>\n );\n});\n\nexport default PhaseBannerText;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AAQzB,MAAM,kBAAkB,MAAM,WAGnC,SAASA,iBAAgB,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,KAAK;AACjE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,IAAG;AAAA,MACH;AAAA,MACA,WAAW,KAAK,WAAW;AAAA,QACzB,4BAA4B;AAAA,MAC9B,CAAC;AAAA,MACA,GAAG;AAAA;AAAA,IAEH;AAAA,EACH;AAEJ,CAAC;AAED,IAAO,0BAAQ;",
|
|
6
6
|
"names": ["PhaseBannerText"]
|
|
7
7
|
}
|
package/RadioItem/index.js
CHANGED
|
@@ -14,8 +14,9 @@ const RadioItem = React.forwardRef(
|
|
|
14
14
|
...props
|
|
15
15
|
}, ref) {
|
|
16
16
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, dividerText && /* @__PURE__ */ React.createElement(ChoiceDividerText, null, dividerText), /* @__PURE__ */ React.createElement(
|
|
17
|
-
|
|
17
|
+
Base,
|
|
18
18
|
{
|
|
19
|
+
as: "div",
|
|
19
20
|
className: clsx(className, {
|
|
20
21
|
"ds-radios__item": true
|
|
21
22
|
})
|
package/RadioItem/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/RadioItem/index.tsx"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\nimport ChoiceDividerText from '@digigov/react-core/ChoiceDividerText';\nimport LabelContainer from '@digigov/react-core/LabelContainer';\n\nexport interface RadioItemProps extends BaseProps<'input'> {\n /**\n * dividerText is optional.\n * Add this prop to add a choice dividerText on top of a radio item.\n * The string is the text that it will appear above this radio item.\n */\n dividerText?: string;\n}\n/**\n * RadioItem component is used for display radio buttons.\n * RadioItem component must be included inside Radio component, as a children component.\n */\nexport const RadioItem = React.forwardRef<HTMLInputElement, RadioItemProps>(\n function RadioItem(\n {\n dividerText,\n name,\n value,\n className,\n disabled = false,\n children,\n ...props\n },\n ref\n ) {\n return (\n <>\n {dividerText && <ChoiceDividerText>{dividerText}</ChoiceDividerText>}\n <div\n className={clsx(className, {\n 'ds-radios__item': true,\n })}\n >\n <LabelContainer\n className={clsx({\n 'ds-radios__label': true,\n 'ds-radios__label--disabled': disabled,\n })}\n >\n {children}\n <Base\n as=\"input\"\n ref={ref}\n type=\"radio\"\n name={name}\n value={value}\n className={clsx({\n 'ds-radios__input': true,\n })}\n disabled={disabled}\n {...props}\n />\n </LabelContainer>\n </
|
|
5
|
-
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AAChC,OAAO,uBAAuB;AAC9B,OAAO,oBAAoB;AAcpB,MAAM,YAAY,MAAM;AAAA,EAC7B,SAASA,WACP;AAAA,IACE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,GAAG;AAAA,EACL,GACA,KACA;AACA,WACE,0DACG,eAAe,oCAAC,yBAAmB,WAAY,GAChD;AAAA,MAAC;AAAA;AAAA,
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\nimport ChoiceDividerText from '@digigov/react-core/ChoiceDividerText';\nimport LabelContainer from '@digigov/react-core/LabelContainer';\n\nexport interface RadioItemProps extends BaseProps<'input'> {\n /**\n * dividerText is optional.\n * Add this prop to add a choice dividerText on top of a radio item.\n * The string is the text that it will appear above this radio item.\n */\n dividerText?: string;\n}\n/**\n * RadioItem component is used for display radio buttons.\n * RadioItem component must be included inside Radio component, as a children component.\n */\nexport const RadioItem = React.forwardRef<HTMLInputElement, RadioItemProps>(\n function RadioItem(\n {\n dividerText,\n name,\n value,\n className,\n disabled = false,\n children,\n ...props\n },\n ref\n ) {\n return (\n <>\n {dividerText && <ChoiceDividerText>{dividerText}</ChoiceDividerText>}\n <Base as='div'\n className={clsx(className, {\n 'ds-radios__item': true,\n })}\n >\n <LabelContainer\n className={clsx({\n 'ds-radios__label': true,\n 'ds-radios__label--disabled': disabled,\n })}\n >\n {children}\n <Base\n as=\"input\"\n ref={ref}\n type=\"radio\"\n name={name}\n value={value}\n className={clsx({\n 'ds-radios__input': true,\n })}\n disabled={disabled}\n {...props}\n />\n </LabelContainer>\n </Base>\n </>\n );\n }\n);\n\nexport default RadioItem;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AAChC,OAAO,uBAAuB;AAC9B,OAAO,oBAAoB;AAcpB,MAAM,YAAY,MAAM;AAAA,EAC7B,SAASA,WACP;AAAA,IACE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,GAAG;AAAA,EACL,GACA,KACA;AACA,WACE,0DACG,eAAe,oCAAC,yBAAmB,WAAY,GAChD;AAAA,MAAC;AAAA;AAAA,QAAK,IAAG;AAAA,QACP,WAAW,KAAK,WAAW;AAAA,UACzB,mBAAmB;AAAA,QACrB,CAAC;AAAA;AAAA,MAED;AAAA,QAAC;AAAA;AAAA,UACC,WAAW,KAAK;AAAA,YACd,oBAAoB;AAAA,YACpB,8BAA8B;AAAA,UAChC,CAAC;AAAA;AAAA,QAEA;AAAA,QACD;AAAA,UAAC;AAAA;AAAA,YACC,IAAG;AAAA,YACH;AAAA,YACA,MAAK;AAAA,YACL;AAAA,YACA;AAAA,YACA,WAAW,KAAK;AAAA,cACd,oBAAoB;AAAA,YACtB,CAAC;AAAA,YACD;AAAA,YACC,GAAG;AAAA;AAAA,QACN;AAAA,MACF;AAAA,IACF,CACF;AAAA,EAEJ;AACF;AAEA,IAAO,oBAAQ;",
|
|
6
6
|
"names": ["RadioItem"]
|
|
7
7
|
}
|
package/SummaryList/index.d.ts
CHANGED
|
@@ -21,7 +21,7 @@ export interface SummaryListProps extends BaseProps<'dl'> {
|
|
|
21
21
|
noLastBorder?: boolean;
|
|
22
22
|
}
|
|
23
23
|
/**
|
|
24
|
-
* SummaryList used as a table with summary
|
|
24
|
+
* SummaryList used as a table with summary information.
|
|
25
25
|
* It must contain a list of SummaryListItem components.
|
|
26
26
|
*/
|
|
27
27
|
export declare const SummaryList: React.ForwardRefExoticComponent<Omit<SummaryListProps, "ref"> & React.RefAttributes<HTMLDListElement>>;
|
package/SummaryList/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/SummaryList/index.tsx"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface SummaryListProps extends BaseProps<'dl'> {\n /**\n * border is optional.\n * By default, SummaryList has borders. You can remove borders by using border prop.\n * By default is true\n * @value true\n * @value false\n * @default true\n */\n border?: boolean;\n /**\n * noLastBorder is optional.\n * By default, SummaryList has borders. You can remove last border by using noLastBorder prop.\n * By default is true\n * @value true\n * @value false\n * @default false\n */\n noLastBorder?: boolean
|
|
5
|
-
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface SummaryListProps extends BaseProps<'dl'> {\n /**\n * border is optional.\n * By default, SummaryList has borders. You can remove borders by using border prop.\n * By default is true\n * @value true\n * @value false\n * @default true\n */\n border?: boolean;\n /**\n * noLastBorder is optional.\n * By default, SummaryList has borders. You can remove last border by using noLastBorder prop.\n * By default is true\n * @value true\n * @value false\n * @default false\n */\n noLastBorder?: boolean;\n}\n/**\n * SummaryList used as a table with summary information.\n * It must contain a list of SummaryListItem components.\n */\nexport const SummaryList = React.forwardRef<HTMLDListElement, SummaryListProps>(\n function SummaryList(\n { className, noLastBorder = false, border = true, children, ...props },\n ref\n ) {\n return (\n <Base\n as=\"dl\"\n ref={ref}\n className={clsx(className, {\n 'ds-summary-list': true,\n 'ds-summary-list--no-border': !border,\n 'ds-summary-list--no-last-border': noLastBorder,\n })}\n {...props}\n >\n {children}\n </Base>\n );\n }\n);\n\nexport default SummaryList;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AA0BzB,MAAM,cAAc,MAAM;AAAA,EAC/B,SAASA,aACP,EAAE,WAAW,eAAe,OAAO,SAAS,MAAM,UAAU,GAAG,MAAM,GACrE,KACA;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,IAAG;AAAA,QACH;AAAA,QACA,WAAW,KAAK,WAAW;AAAA,UACzB,mBAAmB;AAAA,UACnB,8BAA8B,CAAC;AAAA,UAC/B,mCAAmC;AAAA,QACrC,CAAC;AAAA,QACA,GAAG;AAAA;AAAA,MAEH;AAAA,IACH;AAAA,EAEJ;AACF;AAEA,IAAO,sBAAQ;",
|
|
6
6
|
"names": ["SummaryList"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,21 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BaseProps } from '@digigov/react-core/Base';
|
|
3
3
|
export interface SummaryListItemKeyProps extends BaseProps<'dt'> {
|
|
4
|
+
/**
|
|
5
|
+
* sm shows the width of the key column for small screens.
|
|
6
|
+
* @default 3
|
|
7
|
+
*/
|
|
8
|
+
sm?: WidthValues;
|
|
9
|
+
/**
|
|
10
|
+
* md shows the width of the key column for medium screens.
|
|
11
|
+
*/
|
|
12
|
+
md?: WidthValues;
|
|
13
|
+
/**
|
|
14
|
+
* lg shows the width of the key column for large screens.
|
|
15
|
+
*/
|
|
16
|
+
lg?: WidthValues;
|
|
4
17
|
}
|
|
18
|
+
export type WidthValues = 3 | 4 | 5 | 6 | 7 | 8 | 9;
|
|
5
19
|
/**
|
|
6
20
|
* SummaryListItemKey is used within the SummaryListItem component.
|
|
7
21
|
* In this column we place the key information for the row (ex. "Name", "Address", etc).
|
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import clsx from "clsx";
|
|
3
3
|
import Base from "@digigov/react-core/Base";
|
|
4
|
-
const SummaryListItemKey = React.forwardRef(function SummaryListItemKey2({ className, children, ...props }, ref) {
|
|
4
|
+
const SummaryListItemKey = React.forwardRef(function SummaryListItemKey2({ sm = 3, md, lg, className, children, ...props }, ref) {
|
|
5
5
|
return /* @__PURE__ */ React.createElement(
|
|
6
6
|
Base,
|
|
7
7
|
{
|
|
8
8
|
as: "dt",
|
|
9
9
|
ref,
|
|
10
10
|
className: clsx(className, {
|
|
11
|
-
"ds-summary-list__key": true
|
|
11
|
+
"ds-summary-list__key": true,
|
|
12
|
+
[`ds-summary-list__key--sm-${sm}`]: sm !== void 0,
|
|
13
|
+
[`ds-summary-list__key--md-${md}`]: md !== void 0,
|
|
14
|
+
[`ds-summary-list__key--lg-${lg}`]: lg !== void 0
|
|
12
15
|
}),
|
|
13
16
|
...props
|
|
14
17
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/SummaryListItemKey/index.tsx"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface SummaryListItemKeyProps extends BaseProps<'dt'> { }\n/**\n * SummaryListItemKey is used within the SummaryListItem component.\n * In this column we place the key information for the row (ex. \"Name\", \"Address\", etc).\n */\nexport const SummaryListItemKey = React.forwardRef<\n HTMLElement,\n SummaryListItemKeyProps\n>(function SummaryListItemKey({ className, children, ...props }
|
|
5
|
-
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface SummaryListItemKeyProps extends BaseProps<'dt'> {\n /**\n * sm shows the width of the key column for small screens.\n * @default 3\n */\n sm?: WidthValues;\n /**\n * md shows the width of the key column for medium screens.\n */\n md?: WidthValues;\n /**\n * lg shows the width of the key column for large screens.\n */\n lg?: WidthValues;\n}\n\nexport type WidthValues = 3 | 4 | 5 | 6 | 7 | 8 | 9;\n/**\n * SummaryListItemKey is used within the SummaryListItem component.\n * In this column we place the key information for the row (ex. \"Name\", \"Address\", etc).\n */\nexport const SummaryListItemKey = React.forwardRef<\n HTMLElement,\n SummaryListItemKeyProps\n>(function SummaryListItemKey(\n { sm = 3, md, lg, className, children, ...props },\n ref\n) {\n return (\n <Base\n as=\"dt\"\n ref={ref}\n className={clsx(className, {\n 'ds-summary-list__key': true,\n [`ds-summary-list__key--sm-${sm}`]: sm !== undefined,\n [`ds-summary-list__key--md-${md}`]: md !== undefined,\n [`ds-summary-list__key--lg-${lg}`]: lg !== undefined,\n })}\n {...props}\n >\n {children}\n </Base>\n );\n});\n\nexport default SummaryListItemKey;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AAuBzB,MAAM,qBAAqB,MAAM,WAGtC,SAASA,oBACT,EAAE,KAAK,GAAG,IAAI,IAAI,WAAW,UAAU,GAAG,MAAM,GAChD,KACA;AACA,SACE;AAAA,IAAC;AAAA;AAAA,MACC,IAAG;AAAA,MACH;AAAA,MACA,WAAW,KAAK,WAAW;AAAA,QACzB,wBAAwB;AAAA,QACxB,CAAC,4BAA4B,EAAE,EAAE,GAAG,OAAO;AAAA,QAC3C,CAAC,4BAA4B,EAAE,EAAE,GAAG,OAAO;AAAA,QAC3C,CAAC,4BAA4B,EAAE,EAAE,GAAG,OAAO;AAAA,MAC7C,CAAC;AAAA,MACA,GAAG;AAAA;AAAA,IAEH;AAAA,EACH;AAEJ,CAAC;AAED,IAAO,6BAAQ;",
|
|
6
6
|
"names": ["SummaryListItemKey"]
|
|
7
7
|
}
|
package/TextArea/index.d.ts
CHANGED
|
@@ -1,24 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export interface TextAreaProps extends BaseProps<'textarea'> {
|
|
4
|
-
/**
|
|
5
|
-
* error is optional. The default value is false.
|
|
6
|
-
* Use this prop when there is an error at the input.
|
|
7
|
-
* @value true
|
|
8
|
-
* @value false
|
|
9
|
-
*/
|
|
10
|
-
error?: boolean;
|
|
11
|
-
/**
|
|
12
|
-
* dense is optional.
|
|
13
|
-
* @value true TextArea will be dense.
|
|
14
|
-
* @value false
|
|
15
|
-
* @default false
|
|
16
|
-
*/
|
|
17
|
-
dense?: boolean;
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* Textarea component is used when you need to let users enter an
|
|
21
|
-
* amount of text that’s longer than a single line.
|
|
22
|
-
*/
|
|
23
|
-
export declare const TextArea: React.ForwardRefExoticComponent<Omit<TextAreaProps, "ref"> & React.RefAttributes<HTMLTextAreaElement>>;
|
|
24
|
-
export default TextArea;
|
|
1
|
+
export * from '@digigov/react-core/TextArea/index.web';
|
|
2
|
+
export { default as default } from '@digigov/react-core/TextArea/index.web';
|
package/TextArea/index.js
CHANGED
|
@@ -1,30 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import Base from "@digigov/react-core/Base";
|
|
4
|
-
const TextArea = React.forwardRef(
|
|
5
|
-
function TextArea2({ name, rows, error, dense, className, children, ...props }, ref) {
|
|
6
|
-
const defaultRows = dense ? 3 : 6;
|
|
7
|
-
return /* @__PURE__ */ React.createElement(
|
|
8
|
-
Base,
|
|
9
|
-
{
|
|
10
|
-
as: "textarea",
|
|
11
|
-
name,
|
|
12
|
-
rows: rows || defaultRows,
|
|
13
|
-
ref,
|
|
14
|
-
className: clsx(className, {
|
|
15
|
-
"ds-textarea": true,
|
|
16
|
-
"ds-textarea--dense": dense,
|
|
17
|
-
"ds-input--error": error
|
|
18
|
-
}),
|
|
19
|
-
...props
|
|
20
|
-
},
|
|
21
|
-
children
|
|
22
|
-
);
|
|
23
|
-
}
|
|
24
|
-
);
|
|
25
|
-
var TextArea_default = TextArea;
|
|
1
|
+
export * from "@digigov/react-core/TextArea/index.web";
|
|
2
|
+
import { default as default2 } from "@digigov/react-core/TextArea/index.web";
|
|
26
3
|
export {
|
|
27
|
-
|
|
28
|
-
TextArea_default as default
|
|
4
|
+
default2 as default
|
|
29
5
|
};
|
|
30
6
|
//# sourceMappingURL=index.js.map
|
package/TextArea/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/TextArea/index.tsx"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": ["
|
|
4
|
+
"sourcesContent": ["export * from '@digigov/react-core/TextArea/index.web';\nexport {default as default} from '@digigov/react-core/TextArea/index.web';"],
|
|
5
|
+
"mappings": "AAAA,cAAc;AACd,SAAmB,WAAXA,gBAAyB;",
|
|
6
|
+
"names": ["default"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import clsx from "clsx";
|
|
2
|
+
import CoreTextArea from "@digigov/react-core/TextArea/index.web";
|
|
3
|
+
import extend from "@digigov/react-core/utils/extend.native";
|
|
4
|
+
const TextArea = extend(CoreTextArea, ({ className, ...props }) => ({
|
|
5
|
+
...props,
|
|
6
|
+
multiline: true,
|
|
7
|
+
className: clsx(className, {
|
|
8
|
+
"ds-textarea__wrapper": true
|
|
9
|
+
})
|
|
10
|
+
}));
|
|
11
|
+
var index_native_default = TextArea;
|
|
12
|
+
export {
|
|
13
|
+
TextArea,
|
|
14
|
+
index_native_default as default
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=index.native.js.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const TextArea: import("react").ForwardRefExoticComponent<Omit<Omit<import("@digigov/react-core/TextArea/index.web").TextAreaProps, "ref"> & import("react").RefAttributes<HTMLTextAreaElement> & {
|
|
2
|
+
className?: string;
|
|
3
|
+
}, "ref"> & import("react").RefAttributes<unknown>>;
|
|
4
|
+
export default TextArea;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/TextArea/index.native.tsx"],
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport CoreTextArea from '@digigov/react-core/TextArea/index.web';\nimport extend from '@digigov/react-core/utils/extend.native';\nexport const TextArea = extend(CoreTextArea, ({ className, ...props }) => ({\n ...props,\n multiline: true,\n className: clsx(className, {\n 'ds-textarea__wrapper': true,\n }),\n}));\nexport default TextArea;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,UAAU;AACjB,OAAO,kBAAkB;AACzB,OAAO,YAAY;AACZ,MAAM,WAAW,OAAO,cAAc,CAAC,EAAE,WAAW,GAAG,MAAM,OAAO;AAAA,EACzE,GAAG;AAAA,EACH,WAAW;AAAA,EACX,WAAW,KAAK,WAAW;AAAA,IACzB,wBAAwB;AAAA,EAC1B,CAAC;AACH,EAAE;AACF,IAAO,uBAAQ;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import clsx from "clsx";
|
|
3
|
+
import Base from "@digigov/react-core/Base";
|
|
4
|
+
const TextArea = React.forwardRef(
|
|
5
|
+
function TextArea2({ name, rows, error, dense, className, children, ...props }, ref) {
|
|
6
|
+
const defaultRows = dense ? 3 : 6;
|
|
7
|
+
return /* @__PURE__ */ React.createElement(
|
|
8
|
+
Base,
|
|
9
|
+
{
|
|
10
|
+
as: "textarea",
|
|
11
|
+
name,
|
|
12
|
+
rows: rows || defaultRows,
|
|
13
|
+
ref,
|
|
14
|
+
className: clsx(className, {
|
|
15
|
+
"ds-textarea": true,
|
|
16
|
+
"ds-textarea--dense": dense,
|
|
17
|
+
"ds-input--error": error
|
|
18
|
+
}),
|
|
19
|
+
...props
|
|
20
|
+
},
|
|
21
|
+
children
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
var index_web_default = TextArea;
|
|
26
|
+
export {
|
|
27
|
+
TextArea,
|
|
28
|
+
index_web_default as default
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=index.web.js.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { BaseProps } from '@digigov/react-core/Base';
|
|
3
|
+
export interface TextAreaProps extends BaseProps<'textarea'> {
|
|
4
|
+
/**
|
|
5
|
+
* error is optional. The default value is false.
|
|
6
|
+
* Use this prop when there is an error at the input.
|
|
7
|
+
* @value true
|
|
8
|
+
* @value false
|
|
9
|
+
*/
|
|
10
|
+
error?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* dense is optional.
|
|
13
|
+
* @value true TextArea will be dense.
|
|
14
|
+
* @value false
|
|
15
|
+
* @default false
|
|
16
|
+
*/
|
|
17
|
+
dense?: boolean;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Textarea component is used when you need to let users enter an
|
|
21
|
+
* amount of text that’s longer than a single line.
|
|
22
|
+
*/
|
|
23
|
+
export declare const TextArea: React.ForwardRefExoticComponent<Omit<TextAreaProps, "ref"> & React.RefAttributes<HTMLTextAreaElement>>;
|
|
24
|
+
export default TextArea;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/TextArea/index.web.tsx"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface TextAreaProps extends BaseProps<'textarea'> {\n /**\n * error is optional. The default value is false.\n * Use this prop when there is an error at the input.\n * @value true\n * @value false\n */\n error?: boolean;\n /**\n * dense is optional.\n * @value true TextArea will be dense.\n * @value false\n * @default false\n */\n dense?: boolean;\n}\n/**\n * Textarea component is used when you need to let users enter an\n * amount of text that\u2019s longer than a single line.\n */\nexport const TextArea = React.forwardRef<HTMLTextAreaElement, TextAreaProps>(\n function TextArea(\n { name, rows, error, dense, className, children, ...props },\n ref\n ) {\n const defaultRows = dense ? 3 : 6;\n return (\n <Base\n as=\"textarea\"\n name={name}\n rows={rows || defaultRows}\n ref={ref}\n className={clsx(className, {\n 'ds-textarea': true,\n 'ds-textarea--dense': dense,\n 'ds-input--error': error,\n })}\n {...props}\n >\n {children}\n </Base>\n );\n }\n);\n\nexport default TextArea;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AAsBzB,MAAM,WAAW,MAAM;AAAA,EAC5B,SAASA,UACP,EAAE,MAAM,MAAM,OAAO,OAAO,WAAW,UAAU,GAAG,MAAM,GAC1D,KACA;AACA,UAAM,cAAc,QAAQ,IAAI;AAChC,WACE;AAAA,MAAC;AAAA;AAAA,QACC,IAAG;AAAA,QACH;AAAA,QACA,MAAM,QAAQ;AAAA,QACd;AAAA,QACA,WAAW,KAAK,WAAW;AAAA,UACzB,eAAe;AAAA,UACf,sBAAsB;AAAA,UACtB,mBAAmB;AAAA,QACrB,CAAC;AAAA,QACA,GAAG;AAAA;AAAA,MAEH;AAAA,IACH;AAAA,EAEJ;AACF;AAEA,IAAO,oBAAQ;",
|
|
6
|
+
"names": ["TextArea"]
|
|
7
|
+
}
|
package/TextInput/index.d.ts
CHANGED
|
@@ -1,46 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export interface TextInputProps extends BaseProps<'input'> {
|
|
4
|
-
/**
|
|
5
|
-
* maxWidth is optional.
|
|
6
|
-
* @value '2-char';
|
|
7
|
-
* @value '3-char';
|
|
8
|
-
* @value '4-char';
|
|
9
|
-
* @value '5-char';
|
|
10
|
-
* @value '10-char';
|
|
11
|
-
* @value '20-char';
|
|
12
|
-
*/
|
|
13
|
-
maxWidth?: '2-char' | '3-char' | '4-char' | '5-char' | '10-char' | '20-char';
|
|
14
|
-
/**
|
|
15
|
-
* width is optional.
|
|
16
|
-
* Use width prop to define a custom width in your component.
|
|
17
|
-
* @value '25%';
|
|
18
|
-
* @value '33.3%';
|
|
19
|
-
* @value '50%';
|
|
20
|
-
* @value '66.6%';
|
|
21
|
-
* @value '75%';
|
|
22
|
-
* @value '100%';
|
|
23
|
-
* @value 'full';
|
|
24
|
-
*/
|
|
25
|
-
width?: '25%' | '33.3%' | '50%' | '66.6%' | '75%' | '100%' | 'full';
|
|
26
|
-
/**
|
|
27
|
-
* error is optional. The default value is false.
|
|
28
|
-
* Use this prop when there is an error at the input.
|
|
29
|
-
* @value true
|
|
30
|
-
* @value false
|
|
31
|
-
*/
|
|
32
|
-
error?: boolean;
|
|
33
|
-
/**
|
|
34
|
-
* dense is optional.
|
|
35
|
-
* @value true TextInput will be dense.
|
|
36
|
-
* @value false
|
|
37
|
-
* @default false
|
|
38
|
-
*/
|
|
39
|
-
dense?: boolean;
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* TextInput component when you need to let users enter text that’s no
|
|
43
|
-
* longer than a single line, such as their name or phone number.
|
|
44
|
-
*/
|
|
45
|
-
export declare const TextInput: React.ForwardRefExoticComponent<Omit<TextInputProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
46
|
-
export default TextInput;
|
|
1
|
+
export * from '@digigov/react-core/TextInput/index.web';
|
|
2
|
+
export { default as default } from '@digigov/react-core/TextInput/index.web';
|
package/TextInput/index.js
CHANGED
|
@@ -1,43 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import Base from "@digigov/react-core/Base";
|
|
4
|
-
const TextInput = React.forwardRef(
|
|
5
|
-
function TextInput2({
|
|
6
|
-
type = "text",
|
|
7
|
-
maxWidth,
|
|
8
|
-
width,
|
|
9
|
-
error,
|
|
10
|
-
dense,
|
|
11
|
-
className,
|
|
12
|
-
children,
|
|
13
|
-
...props
|
|
14
|
-
}, ref) {
|
|
15
|
-
return /* @__PURE__ */ React.createElement(
|
|
16
|
-
Base,
|
|
17
|
-
{
|
|
18
|
-
as: "input",
|
|
19
|
-
type,
|
|
20
|
-
ref,
|
|
21
|
-
className: clsx(className, {
|
|
22
|
-
"ds-input": true,
|
|
23
|
-
"ds-input--error": error,
|
|
24
|
-
"ds-input--dense": dense,
|
|
25
|
-
[`ds-input--width-${maxWidth}`]: maxWidth !== void 0,
|
|
26
|
-
"ds-!-width-one-quarter": width === "25%",
|
|
27
|
-
"ds-!-width-one-third": width === "33.3%",
|
|
28
|
-
"ds-!-width-one-half": width === "50%",
|
|
29
|
-
"ds-!-width-two-thirds": width === "66.6%",
|
|
30
|
-
"ds-!-width-three-quarters": width === "75%"
|
|
31
|
-
}),
|
|
32
|
-
...props
|
|
33
|
-
},
|
|
34
|
-
children
|
|
35
|
-
);
|
|
36
|
-
}
|
|
37
|
-
);
|
|
38
|
-
var TextInput_default = TextInput;
|
|
1
|
+
export * from "@digigov/react-core/TextInput/index.web";
|
|
2
|
+
import { default as default2 } from "@digigov/react-core/TextInput/index.web";
|
|
39
3
|
export {
|
|
40
|
-
|
|
41
|
-
TextInput_default as default
|
|
4
|
+
default2 as default
|
|
42
5
|
};
|
|
43
6
|
//# sourceMappingURL=index.js.map
|
package/TextInput/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/TextInput/index.tsx"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": ["
|
|
4
|
+
"sourcesContent": ["export * from '@digigov/react-core/TextInput/index.web';\nexport { default as default } from '@digigov/react-core/TextInput/index.web';"],
|
|
5
|
+
"mappings": "AAAA,cAAc;AACd,SAAoB,WAAXA,gBAA0B;",
|
|
6
|
+
"names": ["default"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import extend from "@digigov/react-core/utils/extend.native";
|
|
2
|
+
import CoreTextInput from "@digigov/react-core/TextInput/index.web";
|
|
3
|
+
import clsx from "clsx";
|
|
4
|
+
const TextInput = extend(CoreTextInput, ({ className, ...props }) => {
|
|
5
|
+
return {
|
|
6
|
+
...props,
|
|
7
|
+
className: clsx(className, {
|
|
8
|
+
"ds-input__wrapper": props.maxWidth === void 0,
|
|
9
|
+
"ds-input--disabled": props.disabled,
|
|
10
|
+
[`ds-input--width-${props.maxWidth}__wrapper`]: props.maxWidth !== void 0
|
|
11
|
+
})
|
|
12
|
+
};
|
|
13
|
+
});
|
|
14
|
+
var index_native_default = TextInput;
|
|
15
|
+
export {
|
|
16
|
+
TextInput,
|
|
17
|
+
index_native_default as default
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=index.native.js.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const TextInput: import("react").ForwardRefExoticComponent<Omit<Omit<import("@digigov/react-core/TextInput/index.web").TextInputProps, "ref"> & import("react").RefAttributes<HTMLInputElement> & {
|
|
2
|
+
className?: string;
|
|
3
|
+
}, "ref"> & import("react").RefAttributes<unknown>>;
|
|
4
|
+
export default TextInput;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/TextInput/index.native.tsx"],
|
|
4
|
+
"sourcesContent": ["import extend from '@digigov/react-core/utils/extend.native';\nimport CoreTextInput from '@digigov/react-core/TextInput/index.web';\nimport clsx from 'clsx';\nexport const TextInput = extend(CoreTextInput, ({ className, ...props }) => {\n return {\n ...props,\n className: clsx(className, {\n 'ds-input__wrapper': props.maxWidth === undefined,\n 'ds-input--disabled': props.disabled,\n [`ds-input--width-${props.maxWidth}__wrapper`]:\n props.maxWidth !== undefined,\n }),\n };\n});\nexport default TextInput;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,YAAY;AACnB,OAAO,mBAAmB;AAC1B,OAAO,UAAU;AACV,MAAM,YAAY,OAAO,eAAe,CAAC,EAAE,WAAW,GAAG,MAAM,MAAM;AAC1E,SAAO;AAAA,IACL,GAAG;AAAA,IACH,WAAW,KAAK,WAAW;AAAA,MACzB,qBAAqB,MAAM,aAAa;AAAA,MACxC,sBAAsB,MAAM;AAAA,MAC5B,CAAC,mBAAmB,MAAM,QAAQ,WAAW,GAC3C,MAAM,aAAa;AAAA,IACvB,CAAC;AAAA,EACH;AACF,CAAC;AACD,IAAO,uBAAQ;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import clsx from "clsx";
|
|
3
|
+
import Base from "@digigov/react-core/Base";
|
|
4
|
+
const TextInput = React.forwardRef(
|
|
5
|
+
function TextInput2({
|
|
6
|
+
type = "text",
|
|
7
|
+
maxWidth,
|
|
8
|
+
width,
|
|
9
|
+
error,
|
|
10
|
+
dense,
|
|
11
|
+
className,
|
|
12
|
+
children,
|
|
13
|
+
...props
|
|
14
|
+
}, ref) {
|
|
15
|
+
return /* @__PURE__ */ React.createElement(
|
|
16
|
+
Base,
|
|
17
|
+
{
|
|
18
|
+
as: "input",
|
|
19
|
+
type,
|
|
20
|
+
ref,
|
|
21
|
+
className: clsx(className, {
|
|
22
|
+
"ds-input": true,
|
|
23
|
+
"ds-input--error": error,
|
|
24
|
+
"ds-input--dense": dense,
|
|
25
|
+
[`ds-input--width-${maxWidth}`]: maxWidth !== void 0,
|
|
26
|
+
"ds-!-width-one-quarter": width === "25%",
|
|
27
|
+
"ds-!-width-one-third": width === "33.3%",
|
|
28
|
+
"ds-!-width-one-half": width === "50%",
|
|
29
|
+
"ds-!-width-two-thirds": width === "66.6%",
|
|
30
|
+
"ds-!-width-three-quarters": width === "75%"
|
|
31
|
+
}),
|
|
32
|
+
...props
|
|
33
|
+
},
|
|
34
|
+
children
|
|
35
|
+
);
|
|
36
|
+
}
|
|
37
|
+
);
|
|
38
|
+
var index_web_default = TextInput;
|
|
39
|
+
export {
|
|
40
|
+
TextInput,
|
|
41
|
+
index_web_default as default
|
|
42
|
+
};
|
|
43
|
+
//# sourceMappingURL=index.web.js.map
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { BaseProps } from '@digigov/react-core/Base';
|
|
3
|
+
export interface TextInputProps extends BaseProps<'input'> {
|
|
4
|
+
/**
|
|
5
|
+
* maxWidth is optional.
|
|
6
|
+
* @value '2-char';
|
|
7
|
+
* @value '3-char';
|
|
8
|
+
* @value '4-char';
|
|
9
|
+
* @value '5-char';
|
|
10
|
+
* @value '10-char';
|
|
11
|
+
* @value '20-char';
|
|
12
|
+
*/
|
|
13
|
+
maxWidth?: '2-char' | '3-char' | '4-char' | '5-char' | '10-char' | '20-char';
|
|
14
|
+
/**
|
|
15
|
+
* width is optional.
|
|
16
|
+
* Use width prop to define a custom width in your component.
|
|
17
|
+
* @value '25%';
|
|
18
|
+
* @value '33.3%';
|
|
19
|
+
* @value '50%';
|
|
20
|
+
* @value '66.6%';
|
|
21
|
+
* @value '75%';
|
|
22
|
+
* @value '100%';
|
|
23
|
+
* @value 'full';
|
|
24
|
+
*/
|
|
25
|
+
width?: '25%' | '33.3%' | '50%' | '66.6%' | '75%' | '100%' | 'full';
|
|
26
|
+
/**
|
|
27
|
+
* error is optional. The default value is false.
|
|
28
|
+
* Use this prop when there is an error at the input.
|
|
29
|
+
* @value true
|
|
30
|
+
* @value false
|
|
31
|
+
*/
|
|
32
|
+
error?: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* dense is optional.
|
|
35
|
+
* @value true TextInput will be dense.
|
|
36
|
+
* @value false
|
|
37
|
+
* @default false
|
|
38
|
+
*/
|
|
39
|
+
dense?: boolean;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* TextInput component when you need to let users enter text that’s no
|
|
43
|
+
* longer than a single line, such as their name or phone number.
|
|
44
|
+
*/
|
|
45
|
+
export declare const TextInput: React.ForwardRefExoticComponent<Omit<TextInputProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
46
|
+
export default TextInput;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/TextInput/index.web.tsx"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport clsx from 'clsx';\nimport Base, { BaseProps } from '@digigov/react-core/Base';\n\nexport interface TextInputProps extends BaseProps<'input'> {\n /**\n * maxWidth is optional.\n * @value '2-char';\n * @value '3-char';\n * @value '4-char';\n * @value '5-char';\n * @value '10-char';\n * @value '20-char';\n */\n maxWidth?: '2-char' | '3-char' | '4-char' | '5-char' | '10-char' | '20-char';\n\n /**\n * width is optional.\n * Use width prop to define a custom width in your component.\n * @value '25%';\n * @value '33.3%';\n * @value '50%';\n * @value '66.6%';\n * @value '75%';\n * @value '100%';\n * @value 'full';\n */\n width?: '25%' | '33.3%' | '50%' | '66.6%' | '75%' | '100%' | 'full';\n\n /**\n * error is optional. The default value is false.\n * Use this prop when there is an error at the input.\n * @value true\n * @value false\n */\n error?: boolean;\n /**\n * dense is optional.\n * @value true TextInput will be dense.\n * @value false\n * @default false\n */\n dense?: boolean;\n}\n/**\n * TextInput component when you need to let users enter text that\u2019s no\n * longer than a single line, such as their name or phone number.\n */\nexport const TextInput = React.forwardRef<HTMLInputElement, TextInputProps>(\n function TextInput(\n {\n type = 'text',\n maxWidth,\n width,\n error,\n dense,\n className,\n children,\n ...props\n },\n ref\n ) {\n return (\n <Base\n as=\"input\"\n type={type}\n ref={ref}\n className={clsx(className, {\n 'ds-input': true,\n 'ds-input--error': error,\n 'ds-input--dense': dense,\n [`ds-input--width-${maxWidth}`]: maxWidth !== undefined,\n 'ds-!-width-one-quarter': width === '25%',\n 'ds-!-width-one-third': width === '33.3%',\n 'ds-!-width-one-half': width === '50%',\n 'ds-!-width-two-thirds': width === '66.6%',\n 'ds-!-width-three-quarters': width === '75%',\n })}\n {...props}\n >\n {children}\n </Base>\n );\n }\n);\n\nexport default TextInput;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB,OAAO,UAAyB;AA8CzB,MAAM,YAAY,MAAM;AAAA,EAC7B,SAASA,WACP;AAAA,IACE,OAAO;AAAA,IACP;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,GAAG;AAAA,EACL,GACA,KACA;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,IAAG;AAAA,QACH;AAAA,QACA;AAAA,QACA,WAAW,KAAK,WAAW;AAAA,UACzB,YAAY;AAAA,UACZ,mBAAmB;AAAA,UACnB,mBAAmB;AAAA,UACnB,CAAC,mBAAmB,QAAQ,EAAE,GAAG,aAAa;AAAA,UAC9C,0BAA0B,UAAU;AAAA,UACpC,wBAAwB,UAAU;AAAA,UAClC,uBAAuB,UAAU;AAAA,UACjC,yBAAyB,UAAU;AAAA,UACnC,6BAA6B,UAAU;AAAA,QACzC,CAAC;AAAA,QACA,GAAG;AAAA;AAAA,MAEH;AAAA,IACH;AAAA,EAEJ;AACF;AAEA,IAAO,oBAAQ;",
|
|
6
|
+
"names": ["TextInput"]
|
|
7
|
+
}
|