@inseefr/lunatic 2.7.21 → 3.0.0-rc.10
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/lib/components/CheckboxBoolean/CheckboxBoolean.js +65 -0
- package/lib/components/CheckboxBoolean/CheckboxBoolean.spec.js +71 -0
- package/lib/components/CheckboxGroup/CheckboxGroup.js +51 -0
- package/lib/components/CheckboxGroup/CheckboxGroup.scss +13 -0
- package/lib/components/CheckboxGroup/CustomCheckboxGroup.js +44 -0
- package/lib/components/CheckboxGroup/CustomCheckboxGroup.spec.js +46 -0
- package/lib/components/CheckboxOne/CheckboxOne.js +38 -0
- package/lib/components/CheckboxOne/CheckboxOne.spec.js +53 -0
- package/lib/components/Datepicker/Datepicker.js +161 -0
- package/lib/components/Datepicker/Datepicker.spec.js +92 -0
- package/lib/components/Datepicker/__snapshots__/Datepicker.spec.tsx.snap +166 -0
- package/lib/components/Dropdown/Dropdown.js +63 -0
- package/lib/components/Dropdown/Dropdown.spec.js +49 -0
- package/lib/components/Dropdown/__snapshots__/Dropdown.spec.tsx.snap +85 -0
- package/lib/components/Dropdown/helpers.js +94 -0
- package/lib/components/Dropdown/renderer/SimpleLabelRenderer.js +34 -0
- package/lib/components/Dropdown/renderer/SimpleOptionRenderer.js +40 -0
- package/lib/components/Duration/Duration.js +104 -0
- package/lib/components/FilterDescription/FilterDescription.js +17 -0
- package/lib/components/FilterDescription/FilterDescription.spec.js +21 -0
- package/lib/components/Input/Input.js +79 -0
- package/lib/components/Input/Input.spec.js +84 -0
- package/lib/components/InputNumber/InputNumber.js +80 -0
- package/lib/components/InputNumber/InputNumber.spec.js +113 -0
- package/lib/components/InputNumber/InputNumberThousand.js +55 -0
- package/lib/components/InputNumber/__snapshots__/InputNumber.spec.tsx.snap +40 -0
- package/lib/components/Loop/Loop.js +130 -0
- package/lib/components/LunaticComponents.js +129 -0
- package/lib/components/PairwiseLinks/PairwiseLinks.js +54 -0
- package/lib/components/Question/Question.js +54 -0
- package/lib/components/Radio/Radio.js +41 -0
- package/lib/components/RosterForLoop/RosterForLoop.js +135 -0
- package/lib/components/RosterForLoop/RosterForLoop.spec.js +46 -0
- package/lib/components/Roundabout/CustomRoundabout.js +67 -0
- package/lib/components/Roundabout/Roundabout.js +35 -0
- package/lib/components/Roundabout/RoundaboutItButton.js +76 -0
- package/lib/components/Roundabout/RoundaboutItButton.spec.js +101 -0
- package/lib/components/Roundabout/RoundaboutRedirect.js +21 -0
- package/lib/components/Roundabout/extra.js +44 -0
- package/lib/components/Roundabout/redirect.spec.js +17 -0
- package/lib/components/Roundabout/roundabout.spec.js +71 -0
- package/lib/components/Sequence/Sequence.js +32 -0
- package/lib/components/Subsequence/Subsequence.js +27 -0
- package/lib/components/Subsequence/Subsequence.spec.js +59 -0
- package/lib/components/Suggester/CustomSuggester.js +122 -0
- package/lib/components/Suggester/Suggester.js +140 -0
- package/lib/components/Suggester/Suggester.scss +170 -0
- package/lib/components/Suggester/SuggesterNotification.js +60 -0
- package/lib/components/Suggester/SuggesterStatus.js +46 -0
- package/lib/components/Suggester/helpers.js +50 -0
- package/lib/components/Summary/Summary.js +116 -0
- package/lib/components/Switch/Switch.js +107 -0
- package/lib/components/Table/Table.js +65 -0
- package/lib/components/Textarea/Textarea.js +79 -0
- package/lib/components/Textarea/Textarea.spec.js +46 -0
- package/lib/components/library.js +53 -0
- package/lib/components/shared/Button/Button.js +45 -0
- package/lib/components/shared/Button/Button.spec.js +85 -0
- package/lib/components/shared/Button/IconButton.js +32 -0
- package/lib/components/shared/Button/IconButton.scss +33 -0
- package/lib/components/shared/Button/IconButton.spec.js +101 -0
- package/lib/components/shared/Checkbox/CheckboxOption.js +72 -0
- package/lib/components/shared/Checkbox/CheckboxOption.spec.js +69 -0
- package/lib/components/shared/Combobox/Combobox.js +208 -0
- package/lib/components/shared/Combobox/Combobox.stories.js +109 -0
- package/lib/components/shared/Combobox/ComboboxContainer.js +27 -0
- package/lib/components/shared/Combobox/ComboboxContainer.spec.js +43 -0
- package/lib/components/shared/Combobox/ComboboxContent.js +62 -0
- package/lib/components/shared/Combobox/ComboboxContentBox.js +22 -0
- package/lib/components/shared/Combobox/Panel/ComboboxOption.js +42 -0
- package/lib/components/shared/Combobox/Panel/ComboboxOption.spec.js +63 -0
- package/lib/components/shared/Combobox/Panel/ComboboxOptionContainer.js +56 -0
- package/lib/components/shared/Combobox/Panel/ComboboxOptionContainer.spec.js +26 -0
- package/lib/components/shared/Combobox/Panel/ComboboxPanel.js +44 -0
- package/lib/components/shared/Combobox/Panel/ComboboxPanel.spec.js +110 -0
- package/lib/components/shared/Combobox/Panel/ComboboxPanelContainer.js +26 -0
- package/lib/components/shared/Combobox/Panel/ComboboxPanelContainer.spec.js +57 -0
- package/lib/components/shared/Combobox/Selection/ComboboxClearButton.js +49 -0
- package/lib/components/shared/Combobox/Selection/ComboboxClearButton.spec.js +122 -0
- package/lib/components/shared/Combobox/Selection/ComboboxInput.js +57 -0
- package/lib/components/shared/Combobox/Selection/ComboboxLabelSelection.js +46 -0
- package/lib/components/shared/Combobox/Selection/ComboboxLabelSelection.spec.js +41 -0
- package/lib/components/shared/Combobox/Selection/ComboboxSelection.js +68 -0
- package/lib/components/shared/Combobox/Selection/ComboboxSelection.spec.js +68 -0
- package/lib/components/shared/Combobox/Selection/__snapshots__/ComboboxSelection.spec.tsx.snap +76 -0
- package/lib/components/shared/Combobox/index.js +1 -0
- package/lib/components/shared/ComponentErrors/ComponentErrors.js +50 -0
- package/lib/components/shared/ComponentErrors/ComponentErrors.spec.js +44 -0
- package/lib/components/shared/ComponentWrapper.js +68 -0
- package/lib/components/shared/Declarations/Declarations.js +46 -0
- package/lib/components/shared/Declarations/Declarations.spec.js +77 -0
- package/lib/components/shared/Fieldset/Fieldset.js +43 -0
- package/lib/components/shared/Fieldset/Fieldset.spec.js +37 -0
- package/lib/components/shared/HOC/slottableComponent.js +51 -0
- package/lib/components/shared/Icons/icon-props.js +5 -0
- package/lib/components/shared/Icons/index.js +75 -0
- package/lib/components/shared/Icons/lunatic-icon.js +17 -0
- package/lib/components/shared/Label/Label.js +35 -0
- package/lib/components/shared/Label/Label.spec.js +45 -0
- package/lib/components/shared/LabelDescription.js +21 -0
- package/lib/components/shared/MDLabel/MDLabel.js +45 -0
- package/lib/components/shared/MDLabel/MDLabel.spec.js +103 -0
- package/lib/components/shared/MDLabel/MDLabelLink.js +75 -0
- package/lib/components/shared/MDLabel/RouterLink.js +27 -0
- package/lib/components/shared/MDLabel/generateUniqueId.js +1 -0
- package/lib/components/shared/Missing/Missing.js +84 -0
- package/lib/components/shared/Missing/Missing.spec.js +81 -0
- package/lib/components/shared/ModalControls/ModalControls.js +84 -0
- package/lib/components/shared/ModalControls/ModalControls.spec.js +69 -0
- package/lib/components/shared/Notification.js +29 -0
- package/lib/components/shared/Radio/RadioGroup.js +67 -0
- package/lib/components/shared/Radio/RadioOption.js +116 -0
- package/lib/components/shared/Radio/RadioOption.spec.js +87 -0
- package/lib/components/shared/Table/Table.js +22 -0
- package/lib/components/shared/Table/Table.spec.js +23 -0
- package/lib/components/shared/Table/TableHeader.js +38 -0
- package/lib/components/shared/Table/Tbody.js +21 -0
- package/lib/components/shared/Table/Tbody.spec.js +32 -0
- package/lib/components/shared/Table/Td.js +27 -0
- package/lib/components/shared/Table/Td.spec.js +41 -0
- package/lib/components/shared/Table/Th.js +26 -0
- package/lib/components/shared/Table/Th.spec.js +44 -0
- package/lib/components/shared/Table/Thead.js +21 -0
- package/lib/components/shared/Table/Thead.spec.js +29 -0
- package/lib/components/shared/Table/Tr.js +22 -0
- package/lib/components/shared/Table/Tr.spec.js +39 -0
- package/lib/components/shared/Table/index.js +54 -0
- package/lib/components/shared/VariableStatus/VariableStatus.js +72 -0
- package/lib/components/shared/VariableStatus/VariableStatus.scss +39 -0
- package/lib/components/shared/VariableStatus/VariableStatus.spec.js +24 -0
- package/lib/components/shared/suggester-loader-widget/dragger/dragger.js +84 -0
- package/lib/components/shared/suggester-loader-widget/is-network/is-network.js +52 -0
- package/lib/components/shared/suggester-loader-widget/loader-row.js +103 -0
- package/lib/components/shared/suggester-loader-widget/loader.js +132 -0
- package/lib/components/shared/suggester-loader-widget/widget.js +133 -0
- package/lib/constants/indexedDBStore.js +24 -0
- package/lib/css/components/Button.scss +24 -0
- package/lib/css/components/CheckboxGroup.scss +13 -0
- package/lib/css/components/CheckboxOne.scss +19 -0
- package/lib/css/components/CheckboxOption.scss +19 -0
- package/lib/css/components/Combobox.scss +206 -0
- package/lib/css/components/ComponentErrors.scss +5 -0
- package/lib/css/components/Datepicker.scss +19 -0
- package/lib/css/components/Declarations.scss +42 -0
- package/lib/css/components/Dragger.scss +8 -0
- package/lib/css/components/Dropdown.scss +38 -0
- package/lib/css/components/Duration.scss +9 -0
- package/lib/css/components/Fieldset.scss +5 -0
- package/lib/css/components/IconButton.scss +38 -0
- package/lib/css/components/Input.scss +42 -0
- package/lib/css/components/InputNumber.scss +11 -0
- package/lib/css/components/Label.scss +6 -0
- package/lib/css/components/Missing.scss +27 -0
- package/lib/css/components/ModalControls.scss +48 -0
- package/lib/css/components/RadioGroup.scss +21 -0
- package/lib/css/components/RosterForLoop.scss +39 -0
- package/lib/css/components/Roundabout.scss +13 -0
- package/lib/css/components/Sequence.scss +10 -0
- package/lib/css/components/Suggester.scss +170 -0
- package/lib/css/components/SuggesterWidget.scss +176 -0
- package/lib/css/components/Table.scss +27 -0
- package/lib/css/components/Textarea.scss +8 -0
- package/lib/css/components/VariableStatus.scss +36 -0
- package/lib/css/main.scss +181 -0
- package/lib/hooks/useDocumentEvent.js +23 -0
- package/lib/hooks/useListKeyboardHandler.js +24 -0
- package/lib/hooks/useSuggesterInfo.js +69 -0
- package/lib/index.js +24 -25
- package/lib/main.css +1063 -0
- package/lib/main.css.map +1 -0
- package/lib/src/components/CheckboxBoolean/CheckboxBoolean.d.ts +11 -0
- package/lib/src/components/CheckboxGroup/CheckboxGroup.d.ts +11 -0
- package/lib/src/components/CheckboxGroup/CustomCheckboxGroup.d.ts +13 -0
- package/lib/src/components/CheckboxOne/CheckboxOne.d.ts +5 -0
- package/lib/src/components/Datepicker/Datepicker.d.ts +10 -0
- package/lib/src/components/Dropdown/Dropdown.d.ts +10 -0
- package/lib/src/components/Dropdown/helpers.d.ts +19 -0
- package/lib/src/components/Dropdown/renderer/SimpleLabelRenderer.d.ts +8 -0
- package/lib/src/components/Dropdown/renderer/SimpleOptionRenderer.d.ts +7 -0
- package/lib/src/components/Duration/Duration.d.ts +10 -0
- package/lib/src/components/FilterDescription/FilterDescription.d.ts +7 -0
- package/lib/src/components/Input/Input.d.ts +10 -0
- package/lib/src/components/InputNumber/InputNumber.d.ts +10 -0
- package/lib/src/components/InputNumber/InputNumberThousand.d.ts +14 -0
- package/lib/src/components/Loop/Loop.d.ts +15 -0
- package/lib/src/components/LunaticComponents.d.ts +25 -0
- package/lib/src/components/Question/Question.d.ts +9 -0
- package/lib/src/components/Radio/Radio.d.ts +12 -0
- package/lib/src/components/RosterForLoop/RosterForLoop.d.ts +5 -0
- package/lib/src/components/Roundabout/CustomRoundabout.d.ts +15 -0
- package/lib/src/components/Roundabout/Roundabout.d.ts +5 -0
- package/lib/src/components/Roundabout/RoundaboutItButton.d.ts +11 -0
- package/lib/src/components/Roundabout/RoundaboutRedirect.d.ts +6 -0
- package/lib/src/components/Roundabout/extra.d.ts +14 -0
- package/lib/src/components/Sequence/Sequence.d.ts +2 -0
- package/lib/src/components/Subsequence/Subsequence.d.ts +2 -0
- package/lib/src/components/Suggester/CustomSuggester.d.ts +29 -0
- package/lib/src/components/Suggester/Suggester.d.ts +2 -0
- package/lib/src/components/Suggester/SuggesterNotification.d.ts +10 -0
- package/lib/src/components/Suggester/SuggesterStatus.d.ts +23 -0
- package/lib/src/components/Suggester/SuggesterType.d.ts +6 -0
- package/lib/src/components/Suggester/helpers.d.ts +6 -0
- package/lib/src/components/Summary/Summary.d.ts +25 -0
- package/lib/src/components/Switch/Switch.d.ts +19 -0
- package/lib/src/components/Table/Table.d.ts +2 -0
- package/lib/src/components/Textarea/Textarea.d.ts +10 -0
- package/lib/src/components/library.d.ts +94 -0
- package/lib/src/components/shared/Button/Button.d.ts +11 -0
- package/lib/src/components/shared/Button/IconButton.d.ts +6 -0
- package/lib/src/components/shared/Checkbox/CheckboxOption.d.ts +14 -0
- package/lib/src/components/shared/Combobox/Combobox.d.ts +21 -0
- package/lib/src/components/shared/Combobox/Combobox.stories.d.ts +6 -0
- package/lib/src/components/shared/Combobox/ComboboxContainer.d.ts +11 -0
- package/lib/src/components/shared/Combobox/ComboboxContent.d.ts +10 -0
- package/lib/src/components/shared/Combobox/ComboboxContentBox.d.ts +7 -0
- package/lib/src/components/shared/Combobox/ComboboxType.d.ts +50 -0
- package/lib/src/components/shared/Combobox/Panel/ComboboxOption.d.ts +8 -0
- package/lib/src/components/shared/Combobox/Panel/ComboboxOptionContainer.d.ts +8 -0
- package/lib/src/components/shared/Combobox/Panel/ComboboxPanel.d.ts +5 -0
- package/lib/src/components/shared/Combobox/Panel/ComboboxPanelContainer.d.ts +8 -0
- package/lib/src/components/shared/Combobox/Selection/ComboboxClearButton.d.ts +9 -0
- package/lib/src/components/shared/Combobox/Selection/ComboboxInput.d.ts +10 -0
- package/lib/src/components/shared/Combobox/Selection/ComboboxLabelSelection.d.ts +11 -0
- package/lib/src/components/shared/Combobox/Selection/ComboboxSelection.d.ts +6 -0
- package/lib/src/components/shared/Combobox/index.d.ts +0 -0
- package/lib/src/components/shared/ComponentErrors/ComponentErrors.d.ts +14 -0
- package/lib/src/components/shared/ComponentWrapper.d.ts +26 -0
- package/lib/src/components/shared/Declarations/Declarations.d.ts +16 -0
- package/lib/src/components/shared/Fieldset/Fieldset.d.ts +9 -0
- package/lib/src/components/shared/HOC/slottableComponent.d.ts +105 -0
- package/lib/src/components/shared/Icons/index.d.ts +10 -0
- package/lib/src/components/shared/Icons/lunatic-icon.d.ts +4 -0
- package/lib/src/components/shared/Label/Label.d.ts +10 -0
- package/lib/src/components/shared/LabelDescription.d.ts +7 -0
- package/lib/src/components/shared/MDLabel/MDLabel.d.ts +7 -0
- package/lib/src/components/shared/MDLabel/MDLabelLink.d.ts +8 -0
- package/lib/src/components/shared/MDLabel/RouterLink.d.ts +6 -0
- package/lib/src/components/shared/MDLabel/generateUniqueId.d.ts +0 -0
- package/lib/src/components/shared/Missing/Missing.d.ts +13 -0
- package/lib/src/components/shared/ModalControls/ModalControls.d.ts +10 -0
- package/lib/src/components/shared/Notification.d.ts +8 -0
- package/lib/src/components/shared/Radio/RadioGroup.d.ts +22 -0
- package/lib/src/components/shared/Radio/RadioOption.d.ts +22 -0
- package/lib/src/components/shared/Table/Table.d.ts +7 -0
- package/lib/src/components/shared/Table/TableHeader.d.ts +2 -0
- package/lib/src/components/shared/Table/Tbody.d.ts +7 -0
- package/lib/src/components/shared/Table/Td.d.ts +11 -0
- package/lib/src/components/shared/Table/Th.d.ts +11 -0
- package/lib/src/components/shared/Table/Thead.d.ts +7 -0
- package/lib/src/components/shared/Table/Tr.d.ts +8 -0
- package/lib/src/components/shared/Table/index.d.ts +7 -0
- package/lib/src/components/shared/VariableStatus/VariableStatus.d.ts +6 -0
- package/lib/src/components/shared/suggester-loader-widget/dragger/dragger.d.ts +16 -0
- package/lib/src/components/shared/suggester-loader-widget/loader-row.d.ts +11 -0
- package/lib/src/components/shared/suggester-loader-widget/loader.d.ts +13 -0
- package/lib/src/components/shared/suggester-loader-widget/widget.d.ts +15 -0
- package/lib/src/components/type.d.ts +21 -36
- package/lib/src/constants/indexedDBStore.d.ts +21 -0
- package/lib/src/hooks/use-track-changes.d.ts +9 -1
- package/lib/src/hooks/useDocumentEvent.d.ts +2 -0
- package/lib/src/hooks/useListKeyboardHandler.d.ts +9 -0
- package/lib/src/hooks/useSuggesterInfo.d.ts +9 -0
- package/lib/src/i18n/index.d.ts +2 -2
- package/lib/src/i18n/inputNumberProps.d.ts +1 -1
- package/lib/src/index.d.ts +5 -3
- package/lib/src/use-lunatic/commons/fill-components/fill-component-required.d.ts +106 -91
- package/lib/src/use-lunatic/commons/fill-components/fill-from-state.d.ts +87 -132
- package/lib/src/use-lunatic/commons/fill-components/fill-iterations.d.ts +47 -44
- package/lib/src/use-lunatic/commons/fill-components/fill-specific-expression.d.ts +158 -182
- package/lib/src/use-lunatic/commons/use-components-from-state.d.ts +1 -1
- package/lib/src/use-lunatic/commons/variables/lunatic-variables-store.d.ts +2 -4
- package/lib/src/use-lunatic/lunatic-context.d.ts +1 -4
- package/lib/src/use-lunatic/replace-component-sequence.d.ts +22 -6
- package/lib/src/use-lunatic/type-source.d.ts +55 -53
- package/lib/src/use-lunatic/type.d.ts +4 -4
- package/lib/src/use-lunatic/use-lunatic.d.ts +81 -80
- package/lib/src/utils/store-tools/index.d.ts +1 -1
- package/lib/src/utils/variables.d.ts +10 -2
- package/lib/stories/behaviour/others/test.stories.js +1 -1
- package/lib/stories/behaviour/slots.stories.js +64 -0
- package/lib/stories/checkbox-group/checkbox-group.stories.js +1 -6
- package/lib/stories/checkbox-group/sourceLoop.json +1 -1
- package/lib/stories/date-picker/datepicker.stories.js +2 -3
- package/lib/stories/disabled/source.json +1 -1
- package/lib/stories/loop/loop.stories.js +1 -1
- package/lib/stories/loop/roster-for-loop.stories.js +1 -1
- package/lib/stories/loop/source-roster.json +2 -2
- package/lib/stories/markdown/markdown.stories.js +1 -1
- package/lib/stories/pairwise/pairwise-links.stories.js +1 -9
- package/lib/stories/sequence/sequence.stories.js +1 -1
- package/lib/stories/suggester/fakeReferentiel.json +12 -0
- package/lib/stories/suggester/source-option-responses.json +145 -0
- package/lib/stories/suggester/source.json +0 -1
- package/lib/stories/suggester/suggester-workers.stories.js +5 -5
- package/lib/stories/suggester/suggester.stories.js +45 -7
- package/lib/stories/switch/switch.stories.js +1 -6
- package/lib/stories/table/table.stories.js +1 -11
- package/lib/stories/utils/orchestrator.js +28 -30
- package/lib/use-lunatic/commons/fill-components/fill-specific-expression.js +0 -1
- package/lib/use-lunatic/commons/page.js +0 -5
- package/lib/use-lunatic/commons/variables/lunatic-variables-store.js +2 -28
- package/lib/use-lunatic/lunatic-context.js +2 -10
- package/lib/use-lunatic/reducer/reduce-on-init.js +2 -2
- package/lib/use-lunatic/replace-component-sequence.js +2 -3
- package/lib/use-lunatic/use-lunatic.js +1 -4
- package/lib/use-lunatic/use-lunatic.test.js +12 -37
- package/lib/utils/idb-tools/open-or-create-db.js +4 -4
- package/lib/utils/store-tools/clear-store-data.js +2 -2
- package/lib/utils/store-tools/clear-store-info.js +2 -2
- package/lib/utils/store-tools/create/create.js +2 -2
- package/lib/utils/store-tools/create/update-store-info.js +3 -3
- package/lib/utils/store-tools/get-store-count.js +3 -3
- package/lib/utils/store-tools/index.js +1 -1
- package/lib/utils/store-tools/initStore.js +4 -4
- package/lib/utils/store-tools/open-or-create-store.js +4 -4
- package/lib/utils/suggester-workers/append-to-index/append.js +2 -2
- package/lib/utils/suggester-workers/searching/search-in-index.js +2 -2
- package/lib/utils/suggester-workers/searching/searching.js +5 -5
- package/package.json +3 -6
- package/workers-release/lunatic-append-worker-0.3.0.js +1 -1
- package/workers-release/lunatic-append-worker-0.3.0.js.LICENSE.txt +0 -10
- package/workers-release/lunatic-search-worker-0.3.0.js +1 -1
- package/workers-release/lunatic-search-worker-0.3.0.js.LICENSE.txt +0 -10
- package/lib/components/button/index.js +0 -13
- package/lib/components/button/lunatic-button.js +0 -46
- package/lib/components/button/lunatic-button.spec.js +0 -87
- package/lib/components/checkbox/checkbox-boolean/html/checkbox-boolean.js +0 -34
- package/lib/components/checkbox/checkbox-boolean/html/checkbox-boolean.spec.js +0 -60
- package/lib/components/checkbox/checkbox-boolean/index.js +0 -13
- package/lib/components/checkbox/checkbox-boolean/lunatic-checkbox-boolean.js +0 -58
- package/lib/components/checkbox/checkbox-group/checkbox-group-content.js +0 -34
- package/lib/components/checkbox/checkbox-group/html/checkbox-group-content.js +0 -41
- package/lib/components/checkbox/checkbox-group/html/checkbox-group-content.spec.js +0 -44
- package/lib/components/checkbox/checkbox-group/html/checkbox-group.js +0 -33
- package/lib/components/checkbox/checkbox-group/html/checkbox-group.scss +0 -12
- package/lib/components/checkbox/checkbox-group/index.js +0 -13
- package/lib/components/checkbox/checkbox-group/lunatic-checkbox-group.js +0 -71
- package/lib/components/checkbox/checkbox-one/html/checkbox-one.js +0 -34
- package/lib/components/checkbox/checkbox-one/html/checkbox-one.spec.js +0 -46
- package/lib/components/checkbox/checkbox-one/index.js +0 -13
- package/lib/components/checkbox/checkbox-one/lunatic-checkbox-one.js +0 -61
- package/lib/components/checkbox/commons/checkbox-option.js +0 -72
- package/lib/components/checkbox/commons/checkbox-option.spec.js +0 -70
- package/lib/components/checkbox/commons/index.js +0 -13
- package/lib/components/checkbox/index.js +0 -27
- package/lib/components/commons/components/combo-box/combo-box-container.js +0 -28
- package/lib/components/commons/components/combo-box/combo-box-container.spec.js +0 -45
- package/lib/components/commons/components/combo-box/combo-box-content-box.js +0 -24
- package/lib/components/commons/components/combo-box/combo-box-content.js +0 -64
- package/lib/components/commons/components/combo-box/combo-box.js +0 -207
- package/lib/components/commons/components/combo-box/combo-box.stories.js +0 -110
- package/lib/components/commons/components/combo-box/index.js +0 -13
- package/lib/components/commons/components/combo-box/panel/combo-box-option.js +0 -43
- package/lib/components/commons/components/combo-box/panel/combo-box-option.spec.js +0 -65
- package/lib/components/commons/components/combo-box/panel/option-container.js +0 -56
- package/lib/components/commons/components/combo-box/panel/option-container.spec.js +0 -26
- package/lib/components/commons/components/combo-box/panel/panel-container.js +0 -27
- package/lib/components/commons/components/combo-box/panel/panel-container.spec.js +0 -58
- package/lib/components/commons/components/combo-box/panel/panel.js +0 -42
- package/lib/components/commons/components/combo-box/panel/panel.spec.js +0 -110
- package/lib/components/commons/components/combo-box/selection/LabelOrInput.js +0 -56
- package/lib/components/commons/components/combo-box/selection/LabelOrInput.spec.js +0 -21
- package/lib/components/commons/components/combo-box/selection/__snapshots__/selection.spec.tsx.snap +0 -84
- package/lib/components/commons/components/combo-box/selection/clear-button.js +0 -49
- package/lib/components/commons/components/combo-box/selection/clear-button.spec.js +0 -122
- package/lib/components/commons/components/combo-box/selection/combo-box-label-selection.js +0 -49
- package/lib/components/commons/components/combo-box/selection/combo-box-label-selection.spec.js +0 -43
- package/lib/components/commons/components/combo-box/selection/input.js +0 -57
- package/lib/components/commons/components/combo-box/selection/label-selection.js +0 -30
- package/lib/components/commons/components/combo-box/selection/label-selection.spec.js +0 -41
- package/lib/components/commons/components/combo-box/selection/selection-container.js +0 -36
- package/lib/components/commons/components/combo-box/selection/selection-container.spec.js +0 -52
- package/lib/components/commons/components/combo-box/selection/selection.js +0 -53
- package/lib/components/commons/components/combo-box/selection/selection.spec.js +0 -68
- package/lib/components/commons/components/description.js +0 -52
- package/lib/components/commons/components/description.spec.js +0 -45
- package/lib/components/commons/components/dragger/dragger.js +0 -84
- package/lib/components/commons/components/errors/errors.js +0 -50
- package/lib/components/commons/components/errors/errors.spec.js +0 -45
- package/lib/components/commons/components/errors/index.js +0 -13
- package/lib/components/commons/components/fab/fab.js +0 -34
- package/lib/components/commons/components/fab/fab.scss +0 -32
- package/lib/components/commons/components/fab/fab.spec.js +0 -101
- package/lib/components/commons/components/fab/index.js +0 -13
- package/lib/components/commons/components/field-container/field-container.js +0 -26
- package/lib/components/commons/components/field-container/filed-container.spec.js +0 -37
- package/lib/components/commons/components/field-container/index.js +0 -13
- package/lib/components/commons/components/fieldset.js +0 -28
- package/lib/components/commons/components/fieldset.spec.js +0 -51
- package/lib/components/commons/components/html-table/index.js +0 -47
- package/lib/components/commons/components/html-table/table.js +0 -23
- package/lib/components/commons/components/html-table/table.spec.js +0 -23
- package/lib/components/commons/components/html-table/tbody.js +0 -21
- package/lib/components/commons/components/html-table/tbody.spec.js +0 -32
- package/lib/components/commons/components/html-table/td.js +0 -27
- package/lib/components/commons/components/html-table/td.spec.js +0 -41
- package/lib/components/commons/components/html-table/th.js +0 -26
- package/lib/components/commons/components/html-table/th.spec.js +0 -44
- package/lib/components/commons/components/html-table/thead.js +0 -21
- package/lib/components/commons/components/html-table/thead.spec.js +0 -29
- package/lib/components/commons/components/html-table/tr.js +0 -22
- package/lib/components/commons/components/html-table/tr.spec.js +0 -39
- package/lib/components/commons/components/is-network/is-network.js +0 -52
- package/lib/components/commons/components/label/index.js +0 -13
- package/lib/components/commons/components/label/label.js +0 -34
- package/lib/components/commons/components/label/label.spec.js +0 -77
- package/lib/components/commons/components/lunatic-component-with-label.js +0 -66
- package/lib/components/commons/components/lunatic-component-without-label.js +0 -59
- package/lib/components/commons/components/md-label/generateUniqueId.js +0 -11
- package/lib/components/commons/components/md-label/index.js +0 -13
- package/lib/components/commons/components/md-label/link.js +0 -71
- package/lib/components/commons/components/md-label/md-label.js +0 -46
- package/lib/components/commons/components/md-label/md-label.spec.js +0 -103
- package/lib/components/commons/components/md-label/router-link.js +0 -29
- package/lib/components/commons/components/missing/index.js +0 -13
- package/lib/components/commons/components/missing/missing.js +0 -88
- package/lib/components/commons/components/missing/missing.spec.js +0 -81
- package/lib/components/commons/components/nothing-to-display.js +0 -15
- package/lib/components/commons/components/nothing-to-display.spec.js +0 -15
- package/lib/components/commons/components/orchestrated-component.js +0 -40
- package/lib/components/commons/components/variable-status/img/index.js +0 -20
- package/lib/components/commons/components/variable-status/index.js +0 -13
- package/lib/components/commons/components/variable-status/variable-status.js +0 -88
- package/lib/components/commons/components/variable-status/variable-status.scss +0 -39
- package/lib/components/commons/components/variable-status/variable-status.spec.js +0 -24
- package/lib/components/commons/create-customizable-field.js +0 -28
- package/lib/components/commons/icons/index.js +0 -75
- package/lib/components/commons/icons/lunatic-icon.js +0 -18
- package/lib/components/commons/index.js +0 -96
- package/lib/components/commons/safety-label.js +0 -24
- package/lib/components/commons/use-document-add-event-listener.js +0 -23
- package/lib/components/commons/use-on-handle-change.js +0 -18
- package/lib/components/commons/use-on-handle-change.spec.js +0 -50
- package/lib/components/commons/use-options-keydown.js +0 -22
- package/lib/components/component-set/html/__snapshots__/component-set.spec.tsx.snap +0 -126
- package/lib/components/component-set/html/component-set-legend.js +0 -28
- package/lib/components/component-set/html/component-set-wrapper.js +0 -15
- package/lib/components/component-set/html/component-set.js +0 -28
- package/lib/components/component-set/html/component-set.spec.js +0 -91
- package/lib/components/component-set/lunatic-component-set.js +0 -56
- package/lib/components/datepicker/html/__snapshots__/datepicker.spec.tsx.snap +0 -229
- package/lib/components/datepicker/html/datepicker.js +0 -136
- package/lib/components/datepicker/html/datepicker.spec.js +0 -86
- package/lib/components/datepicker/index.js +0 -13
- package/lib/components/datepicker/lunatic-datepicker.js +0 -63
- package/lib/components/declarations/declaration.js +0 -21
- package/lib/components/declarations/declaration.spec.js +0 -30
- package/lib/components/declarations/declarations-after-text.js +0 -23
- package/lib/components/declarations/declarations-before-text.js +0 -23
- package/lib/components/declarations/declarations-detachable.js +0 -23
- package/lib/components/declarations/declarations.js +0 -42
- package/lib/components/declarations/declarations.spec.js +0 -78
- package/lib/components/declarations/index.js +0 -43
- package/lib/components/dropdown/html/__snapshots__/dropdown.spec.tsx.snap +0 -85
- package/lib/components/dropdown/html/dropdown-simple/dropdown-simple.js +0 -39
- package/lib/components/dropdown/html/dropdown-simple/index.js +0 -13
- package/lib/components/dropdown/html/dropdown-simple/simple-label-renderer.js +0 -35
- package/lib/components/dropdown/html/dropdown-simple/simple-option-renderer.js +0 -42
- package/lib/components/dropdown/html/dropdown-writable/dropdown-writable.js +0 -60
- package/lib/components/dropdown/html/dropdown-writable/filter-tools/filter-options.js +0 -28
- package/lib/components/dropdown/html/dropdown-writable/filter-tools/filter-options.spec.js +0 -106
- package/lib/components/dropdown/html/dropdown-writable/filter-tools/get-label.js +0 -24
- package/lib/components/dropdown/html/dropdown-writable/filter-tools/letters-matching.js +0 -28
- package/lib/components/dropdown/html/dropdown-writable/filter-tools/match.js +0 -21
- package/lib/components/dropdown/html/dropdown-writable/filter-tools/prepare-prefix.js +0 -15
- package/lib/components/dropdown/html/dropdown-writable/index.js +0 -13
- package/lib/components/dropdown/html/dropdown-writable/writable-label-renderer.js +0 -39
- package/lib/components/dropdown/html/dropdown-writable/writable-option-renderer.js +0 -143
- package/lib/components/dropdown/html/dropdown.js +0 -52
- package/lib/components/dropdown/html/dropdown.spec.js +0 -48
- package/lib/components/dropdown/index.js +0 -13
- package/lib/components/dropdown/lunatic-dropdown.js +0 -62
- package/lib/components/duration/duration.js +0 -53
- package/lib/components/duration/durationInput.js +0 -77
- package/lib/components/duration/index.js +0 -13
- package/lib/components/filter-description/component.js +0 -19
- package/lib/components/filter-description/component.spec.js +0 -23
- package/lib/components/filter-description/index.js +0 -13
- package/lib/components/index.js +0 -223
- package/lib/components/input/html/input.js +0 -57
- package/lib/components/input/html/input.spec.js +0 -81
- package/lib/components/input/index.js +0 -13
- package/lib/components/input/lunatic-input.js +0 -59
- package/lib/components/input-number/html/__snapshots__/input-number.spec.tsx.snap +0 -42
- package/lib/components/input-number/html/input-number-thousand.js +0 -56
- package/lib/components/input-number/html/input-number.js +0 -58
- package/lib/components/input-number/html/input-number.spec.js +0 -119
- package/lib/components/input-number/index.js +0 -13
- package/lib/components/input-number/lunatic-input-number.js +0 -63
- package/lib/components/loop/block-for-loop.js +0 -111
- package/lib/components/loop/loop-button.js +0 -19
- package/lib/components/loop/loop-header.js +0 -30
- package/lib/components/loop/loop.js +0 -36
- package/lib/components/loop/roster-for-loop/roster-for-loop.js +0 -162
- package/lib/components/loop/roster-for-loop/roster-for-loop.spec.js +0 -46
- package/lib/components/lunatic-components.js +0 -105
- package/lib/components/modal/html/modal.js +0 -59
- package/lib/components/modal/html/modal.scss +0 -26
- package/lib/components/modal/index.js +0 -13
- package/lib/components/modal/lunatic-modal.js +0 -61
- package/lib/components/modal-controls/close-or-skip.js +0 -38
- package/lib/components/modal-controls/close-or-skip.spec.js +0 -36
- package/lib/components/modal-controls/index.js +0 -13
- package/lib/components/modal-controls/modal-container.js +0 -21
- package/lib/components/modal-controls/modal-container.spec.js +0 -23
- package/lib/components/modal-controls/modal-controls.js +0 -73
- package/lib/components/modal-controls/modal-controls.spec.js +0 -70
- package/lib/components/pairwise-links/pairwise-links.js +0 -57
- package/lib/components/question/Question.js +0 -49
- package/lib/components/question/index.js +0 -16
- package/lib/components/question-explication/html/question-explication.js +0 -51
- package/lib/components/question-explication/html/question-explication.scss +0 -35
- package/lib/components/question-explication/index.js +0 -13
- package/lib/components/question-explication/lunatic-question-explication.js +0 -31
- package/lib/components/question-explication/question-explication.spec.js +0 -49
- package/lib/components/questions/index.js +0 -20
- package/lib/components/questions/question-context.js +0 -34
- package/lib/components/questions/question-context.scss +0 -10
- package/lib/components/questions/question-information.js +0 -34
- package/lib/components/questions/question-information.scss +0 -19
- package/lib/components/radio/html/radio-group-content.js +0 -53
- package/lib/components/radio/html/radio-group-content.spec.js +0 -99
- package/lib/components/radio/html/radio-group.js +0 -45
- package/lib/components/radio/html/radio-option.js +0 -115
- package/lib/components/radio/html/radio-option.spec.js +0 -88
- package/lib/components/radio/index.js +0 -13
- package/lib/components/radio/lunatic-radio-group.js +0 -66
- package/lib/components/roundabout/components/roundabout-container.js +0 -19
- package/lib/components/roundabout/components/roundabout-container.spec.js +0 -23
- package/lib/components/roundabout/components/roundabout-it-button.js +0 -77
- package/lib/components/roundabout/components/roundabout-it-button.spec.js +0 -102
- package/lib/components/roundabout/components/roundabout-it-container.js +0 -18
- package/lib/components/roundabout/components/roundabout-it-container.spec.js +0 -23
- package/lib/components/roundabout/components/roundabout-it-title.js +0 -16
- package/lib/components/roundabout/components/roundabout-it-title.spec.js +0 -18
- package/lib/components/roundabout/components/roundabout-label.js +0 -16
- package/lib/components/roundabout/components/roundabout-label.spec.js +0 -18
- package/lib/components/roundabout/components/roundabout-pending.js +0 -17
- package/lib/components/roundabout/components/roundabout-pending.spec.js +0 -15
- package/lib/components/roundabout/index.js +0 -13
- package/lib/components/roundabout/lunatic-roundabout.js +0 -37
- package/lib/components/roundabout/redirect.js +0 -22
- package/lib/components/roundabout/redirect.spec.js +0 -19
- package/lib/components/roundabout/roundabout.js +0 -73
- package/lib/components/roundabout/roundabout.spec.js +0 -71
- package/lib/components/sequence/html/sequence.js +0 -28
- package/lib/components/sequence/index.js +0 -13
- package/lib/components/sequence/lunatic-sequence.js +0 -30
- package/lib/components/sequence/sequence.spec.js +0 -75
- package/lib/components/subsequence/index.js +0 -13
- package/lib/components/subsequence/subsequence.js +0 -32
- package/lib/components/subsequence/subsequence.spec.js +0 -80
- package/lib/components/suggester/find-best-label/find-best-label.js +0 -49
- package/lib/components/suggester/find-best-label/index.js +0 -13
- package/lib/components/suggester/html/default-style.scss +0 -170
- package/lib/components/suggester/html/notification.js +0 -29
- package/lib/components/suggester/html/suggester.js +0 -121
- package/lib/components/suggester/idb-suggester/check-store.js +0 -112
- package/lib/components/suggester/idb-suggester/idb-suggester.js +0 -75
- package/lib/components/suggester/idb-suggester/index.js +0 -12
- package/lib/components/suggester/idb-suggester/suggester-notification.js +0 -60
- package/lib/components/suggester/idb-suggester/suggester-status.js +0 -48
- package/lib/components/suggester/index.js +0 -13
- package/lib/components/suggester/lunatic-suggester.js +0 -72
- package/lib/components/suggester/searching/create-searching.js +0 -51
- package/lib/components/suggester/searching/index.js +0 -13
- package/lib/components/suggester-loader-widget/loader-row.js +0 -103
- package/lib/components/suggester-loader-widget/loader.js +0 -132
- package/lib/components/suggester-loader-widget/widget.js +0 -134
- package/lib/components/summary/html/summary-container.js +0 -14
- package/lib/components/summary/html/summary-responses.js +0 -56
- package/lib/components/summary/html/summary-title.js +0 -19
- package/lib/components/summary/index.js +0 -12
- package/lib/components/summary/lunatic-summary.js +0 -103
- package/lib/components/switch/html/switch.js +0 -71
- package/lib/components/switch/index.js +0 -13
- package/lib/components/switch/lunatic-switch.js +0 -63
- package/lib/components/table/lunatic-table.js +0 -72
- package/lib/components/table/table-header.js +0 -36
- package/lib/components/textarea/html/textarea.js +0 -54
- package/lib/components/textarea/html/textarea.spec.js +0 -38
- package/lib/components/textarea/index.js +0 -13
- package/lib/components/textarea/lunatic-textarea.js +0 -77
- package/lib/src/components/button/index.d.ts +0 -1
- package/lib/src/components/button/lunatic-button.d.ts +0 -12
- package/lib/src/components/checkbox/checkbox-boolean/html/checkbox-boolean.d.ts +0 -13
- package/lib/src/components/checkbox/checkbox-boolean/index.d.ts +0 -1
- package/lib/src/components/checkbox/checkbox-boolean/lunatic-checkbox-boolean.d.ts +0 -8
- package/lib/src/components/checkbox/checkbox-group/checkbox-group-content.d.ts +0 -8
- package/lib/src/components/checkbox/checkbox-group/html/checkbox-group-content.d.ts +0 -9
- package/lib/src/components/checkbox/checkbox-group/html/checkbox-group.d.ts +0 -14
- package/lib/src/components/checkbox/checkbox-group/index.d.ts +0 -1
- package/lib/src/components/checkbox/checkbox-group/lunatic-checkbox-group.d.ts +0 -11
- package/lib/src/components/checkbox/checkbox-one/html/checkbox-one.d.ts +0 -5
- package/lib/src/components/checkbox/checkbox-one/index.d.ts +0 -1
- package/lib/src/components/checkbox/checkbox-one/lunatic-checkbox-one.d.ts +0 -3
- package/lib/src/components/checkbox/commons/checkbox-option.d.ts +0 -16
- package/lib/src/components/checkbox/commons/index.d.ts +0 -1
- package/lib/src/components/checkbox/index.d.ts +0 -3
- package/lib/src/components/commons/components/combo-box/combo-box-container.d.ts +0 -11
- package/lib/src/components/commons/components/combo-box/combo-box-content-box.d.ts +0 -8
- package/lib/src/components/commons/components/combo-box/combo-box-content.d.ts +0 -10
- package/lib/src/components/commons/components/combo-box/combo-box.d.ts +0 -23
- package/lib/src/components/commons/components/combo-box/combo-box.stories.d.ts +0 -6
- package/lib/src/components/commons/components/combo-box/combo-box.type.d.ts +0 -8
- package/lib/src/components/commons/components/combo-box/index.d.ts +0 -1
- package/lib/src/components/commons/components/combo-box/panel/combo-box-option.d.ts +0 -8
- package/lib/src/components/commons/components/combo-box/panel/option-container.d.ts +0 -8
- package/lib/src/components/commons/components/combo-box/panel/panel-container.d.ts +0 -8
- package/lib/src/components/commons/components/combo-box/panel/panel.d.ts +0 -20
- package/lib/src/components/commons/components/combo-box/selection/LabelOrInput.d.ts +0 -18
- package/lib/src/components/commons/components/combo-box/selection/clear-button.d.ts +0 -9
- package/lib/src/components/commons/components/combo-box/selection/combo-box-label-selection.d.ts +0 -11
- package/lib/src/components/commons/components/combo-box/selection/input.d.ts +0 -11
- package/lib/src/components/commons/components/combo-box/selection/label-selection.d.ts +0 -21
- package/lib/src/components/commons/components/combo-box/selection/selection-container.d.ts +0 -11
- package/lib/src/components/commons/components/combo-box/selection/selection.d.ts +0 -13
- package/lib/src/components/commons/components/description.d.ts +0 -22
- package/lib/src/components/commons/components/dragger/dragger.d.ts +0 -17
- package/lib/src/components/commons/components/errors/errors.d.ts +0 -11
- package/lib/src/components/commons/components/errors/index.d.ts +0 -1
- package/lib/src/components/commons/components/fab/fab.d.ts +0 -7
- package/lib/src/components/commons/components/fab/index.d.ts +0 -1
- package/lib/src/components/commons/components/field-container/field-container.d.ts +0 -6
- package/lib/src/components/commons/components/field-container/index.d.ts +0 -1
- package/lib/src/components/commons/components/fieldset.d.ts +0 -13
- package/lib/src/components/commons/components/html-table/index.d.ts +0 -6
- package/lib/src/components/commons/components/html-table/table.d.ts +0 -8
- package/lib/src/components/commons/components/html-table/tbody.d.ts +0 -7
- package/lib/src/components/commons/components/html-table/td.d.ts +0 -11
- package/lib/src/components/commons/components/html-table/th.d.ts +0 -11
- package/lib/src/components/commons/components/html-table/thead.d.ts +0 -7
- package/lib/src/components/commons/components/html-table/tr.d.ts +0 -8
- package/lib/src/components/commons/components/label/index.d.ts +0 -1
- package/lib/src/components/commons/components/label/label.d.ts +0 -14
- package/lib/src/components/commons/components/lunatic-component-with-label.d.ts +0 -12
- package/lib/src/components/commons/components/lunatic-component-without-label.d.ts +0 -12
- package/lib/src/components/commons/components/md-label/generateUniqueId.d.ts +0 -1
- package/lib/src/components/commons/components/md-label/index.d.ts +0 -1
- package/lib/src/components/commons/components/md-label/link.d.ts +0 -7
- package/lib/src/components/commons/components/md-label/md-label.d.ts +0 -7
- package/lib/src/components/commons/components/md-label/router-link.d.ts +0 -6
- package/lib/src/components/commons/components/missing/index.d.ts +0 -1
- package/lib/src/components/commons/components/missing/missing.d.ts +0 -14
- package/lib/src/components/commons/components/nothing-to-display.d.ts +0 -2
- package/lib/src/components/commons/components/orchestrated-component.d.ts +0 -8
- package/lib/src/components/commons/components/variable-status/img/index.d.ts +0 -2
- package/lib/src/components/commons/components/variable-status/index.d.ts +0 -1
- package/lib/src/components/commons/components/variable-status/variable-status.d.ts +0 -16
- package/lib/src/components/commons/create-customizable-field.d.ts +0 -3
- package/lib/src/components/commons/icons/index.d.ts +0 -10
- package/lib/src/components/commons/icons/lunatic-icon.d.ts +0 -5
- package/lib/src/components/commons/index.d.ts +0 -13
- package/lib/src/components/commons/safety-label.d.ts +0 -3
- package/lib/src/components/commons/use-document-add-event-listener.d.ts +0 -2
- package/lib/src/components/commons/use-on-handle-change.d.ts +0 -12
- package/lib/src/components/commons/use-options-keydown.d.ts +0 -7
- package/lib/src/components/component-set/html/component-set-legend.d.ts +0 -8
- package/lib/src/components/component-set/html/component-set-wrapper.d.ts +0 -6
- package/lib/src/components/component-set/html/component-set.d.ts +0 -10
- package/lib/src/components/component-set/lunatic-component-set.d.ts +0 -3
- package/lib/src/components/datepicker/html/datepicker.d.ts +0 -18
- package/lib/src/components/datepicker/index.d.ts +0 -1
- package/lib/src/components/datepicker/lunatic-datepicker.d.ts +0 -10
- package/lib/src/components/declarations/declaration.d.ts +0 -6
- package/lib/src/components/declarations/declarations-after-text.d.ts +0 -4
- package/lib/src/components/declarations/declarations-before-text.d.ts +0 -4
- package/lib/src/components/declarations/declarations-detachable.d.ts +0 -4
- package/lib/src/components/declarations/declarations.d.ts +0 -15
- package/lib/src/components/declarations/index.d.ts +0 -4
- package/lib/src/components/dropdown/html/dropdown-simple/dropdown-simple.d.ts +0 -3
- package/lib/src/components/dropdown/html/dropdown-simple/index.d.ts +0 -1
- package/lib/src/components/dropdown/html/dropdown-simple/simple-label-renderer.d.ts +0 -8
- package/lib/src/components/dropdown/html/dropdown-simple/simple-option-renderer.d.ts +0 -7
- package/lib/src/components/dropdown/html/dropdown-writable/dropdown-writable.d.ts +0 -17
- package/lib/src/components/dropdown/html/dropdown-writable/filter-tools/filter-options.d.ts +0 -6
- package/lib/src/components/dropdown/html/dropdown-writable/filter-tools/get-label.d.ts +0 -9
- package/lib/src/components/dropdown/html/dropdown-writable/filter-tools/letters-matching.d.ts +0 -2
- package/lib/src/components/dropdown/html/dropdown-writable/filter-tools/match.d.ts +0 -2
- package/lib/src/components/dropdown/html/dropdown-writable/filter-tools/prepare-prefix.d.ts +0 -2
- package/lib/src/components/dropdown/html/dropdown-writable/index.d.ts +0 -1
- package/lib/src/components/dropdown/html/dropdown-writable/writable-label-renderer.d.ts +0 -8
- package/lib/src/components/dropdown/html/dropdown-writable/writable-option-renderer.d.ts +0 -8
- package/lib/src/components/dropdown/html/dropdown.d.ts +0 -12
- package/lib/src/components/dropdown/html/dropdown.spec.d.ts +0 -1
- package/lib/src/components/dropdown/index.d.ts +0 -1
- package/lib/src/components/dropdown/lunatic-dropdown.d.ts +0 -3
- package/lib/src/components/duration/duration.d.ts +0 -4
- package/lib/src/components/duration/durationInput.d.ts +0 -11
- package/lib/src/components/duration/index.d.ts +0 -1
- package/lib/src/components/filter-description/component.d.ts +0 -7
- package/lib/src/components/filter-description/component.spec.d.ts +0 -1
- package/lib/src/components/filter-description/index.d.ts +0 -1
- package/lib/src/components/index.d.ts +0 -31
- package/lib/src/components/input/html/input.d.ts +0 -17
- package/lib/src/components/input/html/input.spec.d.ts +0 -1
- package/lib/src/components/input/index.d.ts +0 -1
- package/lib/src/components/input/lunatic-input.d.ts +0 -3
- package/lib/src/components/input-number/html/input-number-thousand.d.ts +0 -14
- package/lib/src/components/input-number/html/input-number.d.ts +0 -20
- package/lib/src/components/input-number/html/input-number.spec.d.ts +0 -1
- package/lib/src/components/input-number/index.d.ts +0 -1
- package/lib/src/components/input-number/lunatic-input-number.d.ts +0 -3
- package/lib/src/components/loop/block-for-loop.d.ts +0 -22
- package/lib/src/components/loop/loop-button.d.ts +0 -7
- package/lib/src/components/loop/loop-header.d.ts +0 -9
- package/lib/src/components/loop/loop.d.ts +0 -2
- package/lib/src/components/loop/roster-for-loop/roster-for-loop.d.ts +0 -23
- package/lib/src/components/loop/roster-for-loop/roster-for-loop.spec.d.ts +0 -1
- package/lib/src/components/lunatic-components.d.ts +0 -23
- package/lib/src/components/modal/html/modal.d.ts +0 -11
- package/lib/src/components/modal/index.d.ts +0 -1
- package/lib/src/components/modal/lunatic-modal.d.ts +0 -3
- package/lib/src/components/modal-controls/close-or-skip.d.ts +0 -8
- package/lib/src/components/modal-controls/close-or-skip.spec.d.ts +0 -1
- package/lib/src/components/modal-controls/index.d.ts +0 -1
- package/lib/src/components/modal-controls/modal-container.d.ts +0 -3
- package/lib/src/components/modal-controls/modal-container.spec.d.ts +0 -1
- package/lib/src/components/modal-controls/modal-controls.d.ts +0 -11
- package/lib/src/components/modal-controls/modal-controls.spec.d.ts +0 -1
- package/lib/src/components/question/Question.d.ts +0 -7
- package/lib/src/components/question/index.d.ts +0 -1
- package/lib/src/components/question-explication/html/question-explication.d.ts +0 -7
- package/lib/src/components/question-explication/index.d.ts +0 -1
- package/lib/src/components/question-explication/lunatic-question-explication.d.ts +0 -3
- package/lib/src/components/question-explication/question-explication.spec.d.ts +0 -1
- package/lib/src/components/questions/index.d.ts +0 -2
- package/lib/src/components/questions/question-context.d.ts +0 -4
- package/lib/src/components/questions/question-information.d.ts +0 -4
- package/lib/src/components/radio/html/radio-group-content.d.ts +0 -19
- package/lib/src/components/radio/html/radio-group-content.spec.d.ts +0 -1
- package/lib/src/components/radio/html/radio-group.d.ts +0 -23
- package/lib/src/components/radio/html/radio-option.d.ts +0 -23
- package/lib/src/components/radio/html/radio-option.spec.d.ts +0 -1
- package/lib/src/components/radio/index.d.ts +0 -1
- package/lib/src/components/radio/lunatic-radio-group.d.ts +0 -13
- package/lib/src/components/roundabout/components/roundabout-container.d.ts +0 -6
- package/lib/src/components/roundabout/components/roundabout-container.spec.d.ts +0 -1
- package/lib/src/components/roundabout/components/roundabout-it-button.d.ts +0 -11
- package/lib/src/components/roundabout/components/roundabout-it-button.spec.d.ts +0 -1
- package/lib/src/components/roundabout/components/roundabout-it-container.d.ts +0 -5
- package/lib/src/components/roundabout/components/roundabout-it-container.spec.d.ts +0 -1
- package/lib/src/components/roundabout/components/roundabout-it-title.d.ts +0 -5
- package/lib/src/components/roundabout/components/roundabout-it-title.spec.d.ts +0 -1
- package/lib/src/components/roundabout/components/roundabout-label.d.ts +0 -5
- package/lib/src/components/roundabout/components/roundabout-label.spec.d.ts +0 -1
- package/lib/src/components/roundabout/components/roundabout-pending.d.ts +0 -3
- package/lib/src/components/roundabout/components/roundabout-pending.spec.d.ts +0 -1
- package/lib/src/components/roundabout/index.d.ts +0 -1
- package/lib/src/components/roundabout/lunatic-roundabout.d.ts +0 -6
- package/lib/src/components/roundabout/redirect.d.ts +0 -6
- package/lib/src/components/roundabout/roundabout.d.ts +0 -15
- package/lib/src/components/sequence/html/sequence.d.ts +0 -5
- package/lib/src/components/sequence/index.d.ts +0 -1
- package/lib/src/components/sequence/lunatic-sequence.d.ts +0 -3
- package/lib/src/components/sequence/sequence.spec.d.ts +0 -1
- package/lib/src/components/subsequence/index.d.ts +0 -1
- package/lib/src/components/subsequence/subsequence.d.ts +0 -3
- package/lib/src/components/subsequence/subsequence.spec.d.ts +0 -1
- package/lib/src/components/suggester/find-best-label/find-best-label.d.ts +0 -2
- package/lib/src/components/suggester/find-best-label/index.d.ts +0 -1
- package/lib/src/components/suggester/html/notification.d.ts +0 -8
- package/lib/src/components/suggester/html/suggester.d.ts +0 -27
- package/lib/src/components/suggester/idb-suggester/check-store.d.ts +0 -11
- package/lib/src/components/suggester/idb-suggester/idb-suggester.d.ts +0 -9
- package/lib/src/components/suggester/idb-suggester/index.d.ts +0 -1
- package/lib/src/components/suggester/idb-suggester/suggester-notification.d.ts +0 -10
- package/lib/src/components/suggester/idb-suggester/suggester-status.d.ts +0 -23
- package/lib/src/components/suggester/index.d.ts +0 -1
- package/lib/src/components/suggester/lunatic-suggester.d.ts +0 -3
- package/lib/src/components/suggester/searching/create-searching.d.ts +0 -7
- package/lib/src/components/suggester/searching/index.d.ts +0 -1
- package/lib/src/components/suggester-loader-widget/loader-row.d.ts +0 -11
- package/lib/src/components/suggester-loader-widget/loader.d.ts +0 -13
- package/lib/src/components/suggester-loader-widget/widget.d.ts +0 -16
- package/lib/src/components/summary/html/summary-container.d.ts +0 -2
- package/lib/src/components/summary/html/summary-responses.d.ts +0 -14
- package/lib/src/components/summary/html/summary-title.d.ts +0 -5
- package/lib/src/components/summary/index.d.ts +0 -1
- package/lib/src/components/summary/lunatic-summary.d.ts +0 -8
- package/lib/src/components/switch/html/switch.d.ts +0 -18
- package/lib/src/components/switch/index.d.ts +0 -1
- package/lib/src/components/switch/lunatic-switch.d.ts +0 -3
- package/lib/src/components/table/lunatic-table.d.ts +0 -3
- package/lib/src/components/table/table-header.d.ts +0 -11
- package/lib/src/components/textarea/html/textarea.d.ts +0 -19
- package/lib/src/components/textarea/html/textarea.spec.d.ts +0 -1
- package/lib/src/components/textarea/index.d.ts +0 -1
- package/lib/src/components/textarea/lunatic-textarea.d.ts +0 -18
- package/lib/src/use-lunatic/reducer/reduce-go-next-page.spec.d.ts +0 -1
- package/lib/src/use-lunatic/reducer/reduce-go-previous-page.spec.d.ts +0 -1
- package/lib/src/utils/store-tools/constantes.d.ts +0 -21
- package/lib/stories/checkbox-group/sourceComponentset.json +0 -424
- package/lib/stories/component-set/component-set.stories.js +0 -53
- package/lib/stories/component-set/data-loop.json +0 -18
- package/lib/stories/component-set/data-roundabout.json +0 -25
- package/lib/stories/component-set/data.json +0 -25
- package/lib/stories/component-set/source-loop.json +0 -308
- package/lib/stories/component-set/source-roundabout.json +0 -434
- package/lib/stories/component-set/source.json +0 -113
- package/lib/stories/custom-mui/checkbox-boolean-mui.js +0 -31
- package/lib/stories/custom-mui/checkbox-group-mui.js +0 -67
- package/lib/stories/custom-mui/checkbox-one-mui.js +0 -15
- package/lib/stories/custom-mui/index.js +0 -111
- package/lib/stories/custom-mui/input-mui.js +0 -51
- package/lib/stories/custom-mui/input-number-mui.js +0 -39
- package/lib/stories/custom-mui/radio-mui.js +0 -61
- package/lib/stories/custom-mui/suggester-mui/index.js +0 -13
- package/lib/stories/custom-mui/suggester-mui/suggester-mui.js +0 -301
- package/lib/stories/custom-mui/switch-mui.js +0 -46
- package/lib/stories/custom-mui/table-mui.js +0 -27
- package/lib/stories/custom-mui/tbody-mui.js +0 -22
- package/lib/stories/custom-mui/td-mui.js +0 -24
- package/lib/stories/custom-mui/textarea-mui.js +0 -42
- package/lib/stories/custom-mui/th-mui.js +0 -23
- package/lib/stories/custom-mui/thead-mui.js +0 -22
- package/lib/stories/custom-mui/tr-mui.js +0 -32
- package/lib/stories/modal/modal.stories.js +0 -32
- package/lib/stories/modal/source.json +0 -97
- package/lib/stories/pairwise/source-componentset.json +0 -292
- package/lib/stories/question-context/question-context.stories.js +0 -31
- package/lib/stories/question-context/source.json +0 -13
- package/lib/stories/question-explication/question-explication.stories.js +0 -31
- package/lib/stories/question-explication/source.json +0 -17
- package/lib/stories/question-information/question-information.stories.js +0 -32
- package/lib/stories/question-information/source.json +0 -14
- package/lib/stories/suggester/source-component-set.json +0 -113
- package/lib/tests/utils/lunatic.d.ts +0 -25
- package/lib/use-lunatic/reducer/reduce-go-next-page.spec.js +0 -13
- package/lib/use-lunatic/reducer/reduce-go-previous-page.spec.js +0 -14
- package/lib/utils/store-tools/constantes.js +0 -24
- /package/lib/components/{checkbox/checkbox-one/html/checkbox-one.scss → CheckboxOne/CheckboxOne.scss} +0 -0
- /package/lib/components/{datepicker/html/datepicker.scss → Datepicker/Datepicker.scss} +0 -0
- /package/lib/components/{datepicker/html → Datepicker}/DatepickerField.js +0 -0
- /package/lib/components/{dropdown/html/dropdown.scss → Dropdown/Dropdown.scss} +0 -0
- /package/lib/components/{duration/duration.scss → Duration/Duration.scss} +0 -0
- /package/lib/components/{duration → Duration}/durationUtils.js +0 -0
- /package/lib/components/{duration → Duration}/formatDuration.js +0 -0
- /package/lib/components/{duration → Duration}/formatDuration.spec.js +0 -0
- /package/lib/components/{duration → Duration}/getDurationFromValue.js +0 -0
- /package/lib/components/{input/html/input.scss → Input/Input.scss} +0 -0
- /package/lib/components/{input/html/__snapshots__/input.spec.tsx.snap → Input/__snapshots__/Input.spec.tsx.snap} +0 -0
- /package/lib/components/{input-number/html/input-number.scss → InputNumber/InputNumber.scss} +0 -0
- /package/lib/components/{loop → Loop}/constant.js +0 -0
- /package/lib/components/{radio/radio.scss → Radio/Radio.scss} +0 -0
- /package/lib/components/{loop/roster-for-loop/roster.scss → RosterForLoop/RosterForLoop.scss} +0 -0
- /package/lib/components/{loop/roster-for-loop/__snapshots__/roster-for-loop.spec.tsx.snap → RosterForLoop/__snapshots__/RosterForLoop.spec.tsx.snap} +0 -0
- /package/lib/components/{roundabout/components/roundabout.scss → Roundabout/Roundabout.scss} +0 -0
- /package/lib/components/{sequence/html/sequence.scss → Sequence/Sequence.scss} +0 -0
- /package/lib/components/{commons/components/combo-box/combo-box.type.js → Suggester/SuggesterType.js} +0 -0
- /package/lib/components/{suggester/html → Suggester/icons}/alert-icon.svg +0 -0
- /package/lib/components/{suggester/html → Suggester/icons}/wait-icon.svg +0 -0
- /package/lib/components/{suggester/html → Suggester/icons}/warn-icon.svg +0 -0
- /package/lib/components/{switch/html → Switch}/switch.scss +0 -0
- /package/lib/components/{textarea/html/textarea.scss → Textarea/Textarea.scss} +0 -0
- /package/lib/components/{textarea/html/__snapshots__/textarea.spec.tsx.snap → Textarea/__snapshots__/Textarea.spec.tsx.snap} +0 -0
- /package/lib/components/{button/button.scss → shared/Button/Button.scss} +0 -0
- /package/lib/components/{button/__snapshots__/lunatic-button.spec.tsx.snap → shared/Button/__snapshots__/Button.spec.tsx.snap} +0 -0
- /package/lib/components/{checkbox/commons/checkbox-option.scss → shared/Checkbox/CheckboxOption.scss} +0 -0
- /package/lib/components/{checkbox/commons → shared/Checkbox}/getShortcutKey.js +0 -0
- /package/lib/components/{commons/components/combo-box/combo-box.scss → shared/Combobox/Combobox.scss} +0 -0
- /package/lib/components/{commons/icons/icon-props.js → shared/Combobox/ComboboxType.js} +0 -0
- /package/lib/components/{commons/components/combo-box/keyboard-key-codes.js → shared/Combobox/constants.js} +0 -0
- /package/lib/components/{commons/components/errors/errors.scss → shared/ComponentErrors/ComponentErrors.scss} +0 -0
- /package/lib/components/{declarations/declarations.scss → shared/Declarations/Declarations.scss} +0 -0
- /package/lib/components/{commons/components/fieldset.scss → shared/Fieldset/Fieldset.scss} +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/checkbox-checked-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/checkbox-unchecked-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/closed-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/cross-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/load-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/lunatic-icon.scss +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/network-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/on-drag-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/opened-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/radio-checked-icon.js +0 -0
- /package/lib/components/{commons/icons → shared/Icons}/radio-unchecked-icon.js +0 -0
- /package/lib/components/{commons/components/label/label.scss → shared/Label/Label.scss} +0 -0
- /package/lib/components/{commons/components/missing/missing.scss → shared/Missing/Missing.scss} +0 -0
- /package/lib/components/{modal-controls/modal-controls.scss → shared/ModalControls/ModalControls.scss} +0 -0
- /package/lib/components/{radio/html/radio-group.scss → shared/Radio/RadioGroup.scss} +0 -0
- /package/lib/components/{commons/components/html-table/table.scss → shared/Table/Table.scss} +0 -0
- /package/lib/components/{commons/components/variable-status/img → shared/VariableStatus/icons}/edited.png +0 -0
- /package/lib/components/{commons/components/variable-status/img → shared/VariableStatus/icons}/forced.png +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/dragger/dragger.scss +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/dragger/dragger.spec.js +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/dragger/index.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/index.js +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/is-network/index.js +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/is-network/is-network.spec.js +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/is-network/use-online-status.js +0 -0
- /package/lib/components/{commons/components → shared/suggester-loader-widget}/is-network/use-online-status.spec.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/progress.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/tools/action-tool.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/tools/index.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/tools/tools.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/widget-container.js +0 -0
- /package/lib/components/{suggester-loader-widget → shared/suggester-loader-widget}/widget.scss +0 -0
- /package/lib/src/components/{button/lunatic-button.spec.d.ts → CheckboxBoolean/CheckboxBoolean.spec.d.ts} +0 -0
- /package/lib/src/components/{checkbox/checkbox-boolean/html/checkbox-boolean.spec.d.ts → CheckboxGroup/CustomCheckboxGroup.spec.d.ts} +0 -0
- /package/lib/src/components/{checkbox/checkbox-group/html/checkbox-group-content.spec.d.ts → CheckboxOne/CheckboxOne.spec.d.ts} +0 -0
- /package/lib/src/components/{checkbox/checkbox-one/html/checkbox-one.spec.d.ts → Datepicker/Datepicker.spec.d.ts} +0 -0
- /package/lib/src/components/{datepicker/html → Datepicker}/DatepickerField.d.ts +0 -0
- /package/lib/src/components/{checkbox/commons/checkbox-option.spec.d.ts → Dropdown/Dropdown.spec.d.ts} +0 -0
- /package/lib/src/components/{duration → Duration}/durationUtils.d.ts +0 -0
- /package/lib/src/components/{duration → Duration}/formatDuration.d.ts +0 -0
- /package/lib/src/components/{duration → Duration}/formatDuration.spec.d.ts +0 -0
- /package/lib/src/components/{duration → Duration}/getDurationFromValue.d.ts +0 -0
- /package/lib/src/components/{commons/components/combo-box/combo-box-container.spec.d.ts → FilterDescription/FilterDescription.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/panel/combo-box-option.spec.d.ts → Input/Input.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/panel/option-container.spec.d.ts → InputNumber/InputNumber.spec.d.ts} +0 -0
- /package/lib/src/components/{loop → Loop}/constant.d.ts +0 -0
- /package/lib/src/components/{pairwise-links/pairwise-links.d.ts → PairwiseLinks/PairwiseLinks.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/panel/panel-container.spec.d.ts → RosterForLoop/RosterForLoop.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/panel/panel.spec.d.ts → Roundabout/RoundaboutItButton.spec.d.ts} +0 -0
- /package/lib/src/components/{roundabout → Roundabout}/redirect.spec.d.ts +0 -0
- /package/lib/src/components/{roundabout → Roundabout}/roundabout.spec.d.ts +0 -0
- /package/lib/src/components/{commons/components/combo-box/selection/LabelOrInput.spec.d.ts → Subsequence/Subsequence.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/selection/clear-button.spec.d.ts → Textarea/Textarea.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/selection/combo-box-label-selection.spec.d.ts → shared/Button/Button.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/selection/label-selection.spec.d.ts → shared/Button/IconButton.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/selection/selection-container.spec.d.ts → shared/Checkbox/CheckboxOption.spec.d.ts} +0 -0
- /package/lib/src/components/{checkbox/commons → shared/Checkbox}/getShortcutKey.d.ts +0 -0
- /package/lib/src/components/{commons/components/combo-box/selection/selection.spec.d.ts → shared/Combobox/ComboboxContainer.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/description.spec.d.ts → shared/Combobox/Panel/ComboboxOption.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/dragger/dragger.spec.d.ts → shared/Combobox/Panel/ComboboxOptionContainer.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/errors/errors.spec.d.ts → shared/Combobox/Panel/ComboboxPanel.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/fab/fab.spec.d.ts → shared/Combobox/Panel/ComboboxPanelContainer.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/field-container/filed-container.spec.d.ts → shared/Combobox/Selection/ComboboxClearButton.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/fieldset.spec.d.ts → shared/Combobox/Selection/ComboboxLabelSelection.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/html-table/table.spec.d.ts → shared/Combobox/Selection/ComboboxSelection.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/combo-box/keyboard-key-codes.d.ts → shared/Combobox/constants.d.ts} +0 -0
- /package/lib/src/components/{commons/components/html-table/tbody.spec.d.ts → shared/ComponentErrors/ComponentErrors.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/html-table/td.spec.d.ts → shared/Declarations/Declarations.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/html-table/th.spec.d.ts → shared/Fieldset/Fieldset.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/checkbox-checked-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/checkbox-unchecked-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/closed-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/cross-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/icon-props.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/load-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/network-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/on-drag-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/opened-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/radio-checked-icon.d.ts +0 -0
- /package/lib/src/components/{commons/icons → shared/Icons}/radio-unchecked-icon.d.ts +0 -0
- /package/lib/src/components/{commons/components/html-table/thead.spec.d.ts → shared/Label/Label.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/html-table/tr.spec.d.ts → shared/MDLabel/MDLabel.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/is-network/is-network.spec.d.ts → shared/Missing/Missing.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/is-network/use-online-status.spec.d.ts → shared/ModalControls/ModalControls.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/label/label.spec.d.ts → shared/Radio/RadioOption.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/md-label/md-label.spec.d.ts → shared/Table/Table.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/missing/missing.spec.d.ts → shared/Table/Tbody.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/nothing-to-display.spec.d.ts → shared/Table/Td.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components/variable-status/variable-status.spec.d.ts → shared/Table/Th.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/use-on-handle-change.spec.d.ts → shared/Table/Thead.spec.d.ts} +0 -0
- /package/lib/src/components/{component-set/html/component-set.spec.d.ts → shared/Table/Tr.spec.d.ts} +0 -0
- /package/lib/src/components/{datepicker/html/datepicker.spec.d.ts → shared/VariableStatus/VariableStatus.spec.d.ts} +0 -0
- /package/lib/src/components/{declarations/declaration.spec.d.ts → shared/suggester-loader-widget/dragger/dragger.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components → shared/suggester-loader-widget}/dragger/index.d.ts +0 -0
- /package/lib/src/components/{suggester-loader-widget → shared/suggester-loader-widget}/index.d.ts +0 -0
- /package/lib/src/components/{commons/components → shared/suggester-loader-widget}/is-network/index.d.ts +0 -0
- /package/lib/src/components/{commons/components → shared/suggester-loader-widget}/is-network/is-network.d.ts +0 -0
- /package/lib/src/components/{declarations/declarations.spec.d.ts → shared/suggester-loader-widget/is-network/is-network.spec.d.ts} +0 -0
- /package/lib/src/components/{commons/components → shared/suggester-loader-widget}/is-network/use-online-status.d.ts +0 -0
- /package/lib/src/components/{dropdown/html/dropdown-writable/filter-tools/filter-options.spec.d.ts → shared/suggester-loader-widget/is-network/use-online-status.spec.d.ts} +0 -0
- /package/lib/src/components/{suggester-loader-widget → shared/suggester-loader-widget}/progress.d.ts +0 -0
- /package/lib/src/components/{suggester-loader-widget → shared/suggester-loader-widget}/tools/action-tool.d.ts +0 -0
- /package/lib/src/components/{suggester-loader-widget → shared/suggester-loader-widget}/tools/index.d.ts +0 -0
- /package/lib/src/components/{suggester-loader-widget → shared/suggester-loader-widget}/tools/tools.d.ts +0 -0
- /package/lib/src/components/{suggester-loader-widget → shared/suggester-loader-widget}/widget-container.d.ts +0 -0
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
// Vitest Snapshot v1
|
|
2
|
+
|
|
3
|
+
exports[`Datepicker > should render properly with format YYYY 1`] = `
|
|
4
|
+
<div>
|
|
5
|
+
<div
|
|
6
|
+
class="lunatic-input"
|
|
7
|
+
>
|
|
8
|
+
<div
|
|
9
|
+
class="lunaticDatepickerFields"
|
|
10
|
+
>
|
|
11
|
+
<div
|
|
12
|
+
class="lunaticDatepickerField lunaticDatepickerFieldLarge"
|
|
13
|
+
>
|
|
14
|
+
<label
|
|
15
|
+
for="datepickeryear"
|
|
16
|
+
>
|
|
17
|
+
Année
|
|
18
|
+
<span
|
|
19
|
+
class="lunaticDatepickerHint"
|
|
20
|
+
>
|
|
21
|
+
Exemple: 2023
|
|
22
|
+
</span>
|
|
23
|
+
</label>
|
|
24
|
+
<input
|
|
25
|
+
id="datepickeryear"
|
|
26
|
+
max="9999"
|
|
27
|
+
min="1"
|
|
28
|
+
type="number"
|
|
29
|
+
value="1999"
|
|
30
|
+
/>
|
|
31
|
+
</div>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
</div>
|
|
35
|
+
`;
|
|
36
|
+
|
|
37
|
+
exports[`Datepicker > should render properly with format YYYY-MM 1`] = `
|
|
38
|
+
<div>
|
|
39
|
+
<div
|
|
40
|
+
class="lunatic-input"
|
|
41
|
+
>
|
|
42
|
+
<div
|
|
43
|
+
class="lunaticDatepickerFields"
|
|
44
|
+
>
|
|
45
|
+
<div
|
|
46
|
+
class="lunaticDatepickerField"
|
|
47
|
+
>
|
|
48
|
+
<label
|
|
49
|
+
for="datepickermonth"
|
|
50
|
+
>
|
|
51
|
+
Mois
|
|
52
|
+
<span
|
|
53
|
+
class="lunaticDatepickerHint"
|
|
54
|
+
>
|
|
55
|
+
Exemple: 07
|
|
56
|
+
</span>
|
|
57
|
+
</label>
|
|
58
|
+
<input
|
|
59
|
+
id="datepickermonth"
|
|
60
|
+
max="12"
|
|
61
|
+
min="1"
|
|
62
|
+
type="number"
|
|
63
|
+
value="1"
|
|
64
|
+
/>
|
|
65
|
+
</div>
|
|
66
|
+
<div
|
|
67
|
+
class="lunaticDatepickerField lunaticDatepickerFieldLarge"
|
|
68
|
+
>
|
|
69
|
+
<label
|
|
70
|
+
for="datepickeryear"
|
|
71
|
+
>
|
|
72
|
+
Année
|
|
73
|
+
<span
|
|
74
|
+
class="lunaticDatepickerHint"
|
|
75
|
+
>
|
|
76
|
+
Exemple: 2023
|
|
77
|
+
</span>
|
|
78
|
+
</label>
|
|
79
|
+
<input
|
|
80
|
+
id="datepickeryear"
|
|
81
|
+
max="9999"
|
|
82
|
+
min="1"
|
|
83
|
+
type="number"
|
|
84
|
+
value="1999"
|
|
85
|
+
/>
|
|
86
|
+
</div>
|
|
87
|
+
</div>
|
|
88
|
+
</div>
|
|
89
|
+
</div>
|
|
90
|
+
`;
|
|
91
|
+
|
|
92
|
+
exports[`Datepicker > should render properly with format YYYY-MM-DD 1`] = `
|
|
93
|
+
<div>
|
|
94
|
+
<div
|
|
95
|
+
class="lunatic-input"
|
|
96
|
+
>
|
|
97
|
+
<div
|
|
98
|
+
class="lunaticDatepickerFields"
|
|
99
|
+
>
|
|
100
|
+
<div
|
|
101
|
+
class="lunaticDatepickerField"
|
|
102
|
+
>
|
|
103
|
+
<label
|
|
104
|
+
for="datepickerday"
|
|
105
|
+
>
|
|
106
|
+
Jour
|
|
107
|
+
<span
|
|
108
|
+
class="lunaticDatepickerHint"
|
|
109
|
+
>
|
|
110
|
+
Exemple: 14
|
|
111
|
+
</span>
|
|
112
|
+
</label>
|
|
113
|
+
<input
|
|
114
|
+
id="datepickerday"
|
|
115
|
+
max="31"
|
|
116
|
+
min="1"
|
|
117
|
+
type="number"
|
|
118
|
+
value="1"
|
|
119
|
+
/>
|
|
120
|
+
</div>
|
|
121
|
+
<div
|
|
122
|
+
class="lunaticDatepickerField"
|
|
123
|
+
>
|
|
124
|
+
<label
|
|
125
|
+
for="datepickermonth"
|
|
126
|
+
>
|
|
127
|
+
Mois
|
|
128
|
+
<span
|
|
129
|
+
class="lunaticDatepickerHint"
|
|
130
|
+
>
|
|
131
|
+
Exemple: 07
|
|
132
|
+
</span>
|
|
133
|
+
</label>
|
|
134
|
+
<input
|
|
135
|
+
id="datepickermonth"
|
|
136
|
+
max="12"
|
|
137
|
+
min="1"
|
|
138
|
+
type="number"
|
|
139
|
+
value="1"
|
|
140
|
+
/>
|
|
141
|
+
</div>
|
|
142
|
+
<div
|
|
143
|
+
class="lunaticDatepickerField lunaticDatepickerFieldLarge"
|
|
144
|
+
>
|
|
145
|
+
<label
|
|
146
|
+
for="datepickeryear"
|
|
147
|
+
>
|
|
148
|
+
Année
|
|
149
|
+
<span
|
|
150
|
+
class="lunaticDatepickerHint"
|
|
151
|
+
>
|
|
152
|
+
Exemple: 2023
|
|
153
|
+
</span>
|
|
154
|
+
</label>
|
|
155
|
+
<input
|
|
156
|
+
id="datepickeryear"
|
|
157
|
+
max="9999"
|
|
158
|
+
min="1"
|
|
159
|
+
type="number"
|
|
160
|
+
value="1999"
|
|
161
|
+
/>
|
|
162
|
+
</div>
|
|
163
|
+
</div>
|
|
164
|
+
</div>
|
|
165
|
+
</div>
|
|
166
|
+
`;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.CustomDropdown = void 0;
|
|
8
|
+
exports.Dropdown = Dropdown;
|
|
9
|
+
var _ComponentErrors = require("../shared/ComponentErrors/ComponentErrors");
|
|
10
|
+
var _slottableComponent = require("../shared/HOC/slottableComponent");
|
|
11
|
+
var _SimpleOptionRenderer = require("./renderer/SimpleOptionRenderer");
|
|
12
|
+
var _SimpleLabelRenderer = require("./renderer/SimpleLabelRenderer");
|
|
13
|
+
var _Combobox = require("../shared/Combobox/Combobox");
|
|
14
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
15
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
16
|
+
var _excluded = ["handleChange", "response", "errors"];
|
|
17
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
18
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
19
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
20
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
21
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
22
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
23
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
24
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
25
|
+
function Dropdown(_ref) {
|
|
26
|
+
var handleChange = _ref.handleChange,
|
|
27
|
+
response = _ref.response,
|
|
28
|
+
errors = _ref.errors,
|
|
29
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
30
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(CustomDropdown, _objectSpread(_objectSpread({}, props), {}, {
|
|
31
|
+
onChange: function onChange(v) {
|
|
32
|
+
return handleChange(response, v);
|
|
33
|
+
},
|
|
34
|
+
errors: (0, _ComponentErrors.getComponentErrors)(errors, props.id)
|
|
35
|
+
}));
|
|
36
|
+
}
|
|
37
|
+
var CustomDropdown = exports.CustomDropdown = (0, _slottableComponent.slottableComponent)('Dropdown', function (props) {
|
|
38
|
+
var id = props.id,
|
|
39
|
+
disabled = props.disabled,
|
|
40
|
+
options = props.options,
|
|
41
|
+
className = props.className,
|
|
42
|
+
value = props.value,
|
|
43
|
+
description = props.description,
|
|
44
|
+
label = props.label,
|
|
45
|
+
errors = props.errors,
|
|
46
|
+
onChange = props.onChange,
|
|
47
|
+
readOnly = props.readOnly;
|
|
48
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Combobox.Combobox, {
|
|
49
|
+
id: id,
|
|
50
|
+
className: (0, _classnames["default"])(className, 'lunatic-dropdown'),
|
|
51
|
+
disabled: disabled,
|
|
52
|
+
readOnly: readOnly,
|
|
53
|
+
options: options,
|
|
54
|
+
editable: false,
|
|
55
|
+
onSelect: onChange,
|
|
56
|
+
optionRenderer: _SimpleOptionRenderer.SimpleOptionRenderer,
|
|
57
|
+
labelRenderer: _SimpleLabelRenderer.SimpleLabelRenderer,
|
|
58
|
+
value: value,
|
|
59
|
+
label: label,
|
|
60
|
+
errors: errors,
|
|
61
|
+
description: description
|
|
62
|
+
});
|
|
63
|
+
});
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _react = require("@testing-library/react");
|
|
4
|
+
var _vitest = require("vitest");
|
|
5
|
+
var _Dropdown = require("./Dropdown");
|
|
6
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
7
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
8
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
9
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
10
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
11
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
12
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
13
|
+
(0, _vitest.describe)('Dropdown', function () {
|
|
14
|
+
var mockOnSelect = _vitest.vi.fn();
|
|
15
|
+
var baseProps = {
|
|
16
|
+
value: 'toto',
|
|
17
|
+
id: 'dropdown',
|
|
18
|
+
'aria-labelledby': 'dropdown',
|
|
19
|
+
options: [{
|
|
20
|
+
value: 'toto',
|
|
21
|
+
description: 'toto',
|
|
22
|
+
label: 'toto'
|
|
23
|
+
}],
|
|
24
|
+
response: {
|
|
25
|
+
name: 'demo'
|
|
26
|
+
},
|
|
27
|
+
handleChange: mockOnSelect
|
|
28
|
+
};
|
|
29
|
+
(0, _vitest.beforeEach)(function () {
|
|
30
|
+
mockOnSelect.mockClear();
|
|
31
|
+
});
|
|
32
|
+
(0, _vitest.it)('renders without crashing', function () {
|
|
33
|
+
var _render = (0, _react.render)( /*#__PURE__*/(0, _jsxRuntime.jsx)(_Dropdown.Dropdown, _objectSpread({}, baseProps))),
|
|
34
|
+
container = _render.container;
|
|
35
|
+
(0, _vitest.expect)(container).toMatchSnapshot();
|
|
36
|
+
});
|
|
37
|
+
(0, _vitest.it)('should handle readOnly', function () {
|
|
38
|
+
var _render2 = (0, _react.render)( /*#__PURE__*/(0, _jsxRuntime.jsx)(_Dropdown.Dropdown, _objectSpread(_objectSpread({}, baseProps), {}, {
|
|
39
|
+
readOnly: true
|
|
40
|
+
}))),
|
|
41
|
+
container = _render2.container;
|
|
42
|
+
(0, _vitest.expect)(container).toMatchSnapshot();
|
|
43
|
+
var selection = container.querySelector('.lunatic-combo-box-content');
|
|
44
|
+
selection.focus();
|
|
45
|
+
(0, _vitest.expect)(selection).toHaveFocus();
|
|
46
|
+
var span = selection === null || selection === void 0 ? void 0 : selection.querySelector('span');
|
|
47
|
+
(0, _vitest.expect)(span).toHaveTextContent('toto');
|
|
48
|
+
});
|
|
49
|
+
});
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
// Vitest Snapshot v1
|
|
2
|
+
|
|
3
|
+
exports[`Dropdown > renders without crashing 1`] = `
|
|
4
|
+
<div>
|
|
5
|
+
<div
|
|
6
|
+
class="lunatic-dropdown lunatic-combo-box-container lunatic-suggester-default-style lunatic-suggester-default-style default-style"
|
|
7
|
+
id="lunatic-combo-box-container-dropdown"
|
|
8
|
+
>
|
|
9
|
+
<div
|
|
10
|
+
class="lunatic-combo-box"
|
|
11
|
+
>
|
|
12
|
+
<div
|
|
13
|
+
class="lunatic-combo-box-content"
|
|
14
|
+
tabindex="0"
|
|
15
|
+
>
|
|
16
|
+
<div
|
|
17
|
+
aria-autocomplete="list"
|
|
18
|
+
aria-controls="todo"
|
|
19
|
+
aria-expanded="false"
|
|
20
|
+
aria-haspopup="listbox"
|
|
21
|
+
aria-labelledby="label-dropdown"
|
|
22
|
+
aria-owns="dropdown"
|
|
23
|
+
class="lunatic-combo-box-selection"
|
|
24
|
+
id="dropdown"
|
|
25
|
+
role="combobox"
|
|
26
|
+
>
|
|
27
|
+
<span
|
|
28
|
+
class="selection"
|
|
29
|
+
>
|
|
30
|
+
toto
|
|
31
|
+
</span>
|
|
32
|
+
</div>
|
|
33
|
+
<ul
|
|
34
|
+
aria-label="suggestions"
|
|
35
|
+
class="lunatic-combo-box-panel"
|
|
36
|
+
id="lunatic-combo-box-panel-dropdown-list"
|
|
37
|
+
role="listbox"
|
|
38
|
+
/>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
`;
|
|
44
|
+
|
|
45
|
+
exports[`Dropdown > should handle readOnly 1`] = `
|
|
46
|
+
<div>
|
|
47
|
+
<div
|
|
48
|
+
class="lunatic-dropdown lunatic-combo-box-container lunatic-suggester-default-style lunatic-suggester-default-style default-style"
|
|
49
|
+
id="lunatic-combo-box-container-dropdown"
|
|
50
|
+
>
|
|
51
|
+
<div
|
|
52
|
+
class="lunatic-combo-box"
|
|
53
|
+
>
|
|
54
|
+
<div
|
|
55
|
+
class="lunatic-combo-box-content"
|
|
56
|
+
tabindex="0"
|
|
57
|
+
>
|
|
58
|
+
<div
|
|
59
|
+
aria-autocomplete="list"
|
|
60
|
+
aria-controls="todo"
|
|
61
|
+
aria-expanded="false"
|
|
62
|
+
aria-haspopup="listbox"
|
|
63
|
+
aria-labelledby="label-dropdown"
|
|
64
|
+
aria-owns="dropdown"
|
|
65
|
+
class="lunatic-combo-box-selection"
|
|
66
|
+
id="dropdown"
|
|
67
|
+
role="combobox"
|
|
68
|
+
>
|
|
69
|
+
<span
|
|
70
|
+
class="selection"
|
|
71
|
+
>
|
|
72
|
+
toto
|
|
73
|
+
</span>
|
|
74
|
+
</div>
|
|
75
|
+
<ul
|
|
76
|
+
aria-label="suggestions"
|
|
77
|
+
class="lunatic-combo-box-panel"
|
|
78
|
+
id="lunatic-combo-box-panel-dropdown-list"
|
|
79
|
+
role="listbox"
|
|
80
|
+
/>
|
|
81
|
+
</div>
|
|
82
|
+
</div>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
`;
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.filterOptions = filterOptions;
|
|
7
|
+
exports.labelToString = labelToString;
|
|
8
|
+
exports.lettersMatching = lettersMatching;
|
|
9
|
+
exports.preparePrefix = preparePrefix;
|
|
10
|
+
var _removeAccents = _interopRequireDefault(require("remove-accents"));
|
|
11
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
12
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
13
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
14
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
15
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
16
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
17
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
18
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
19
|
+
/**
|
|
20
|
+
* Filters an array of options based on a search prefix.
|
|
21
|
+
**/
|
|
22
|
+
function filterOptions(options, prefix) {
|
|
23
|
+
if (!prefix || prefix.length === 0) {
|
|
24
|
+
return options;
|
|
25
|
+
}
|
|
26
|
+
return options.map(function (option) {
|
|
27
|
+
return {
|
|
28
|
+
option: option,
|
|
29
|
+
score: matchScore(option.search || labelToString(option.label), prefix)
|
|
30
|
+
};
|
|
31
|
+
}).filter(function (option) {
|
|
32
|
+
return option.score >= 0.6;
|
|
33
|
+
}).sort(function (a, b) {
|
|
34
|
+
return b.score - a.score;
|
|
35
|
+
}).map(function (o) {
|
|
36
|
+
return o.option;
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Extract string content from the variable received
|
|
42
|
+
*/
|
|
43
|
+
function labelToString(label) {
|
|
44
|
+
if (label && _typeof(label) === 'object' && 'props' in label) {
|
|
45
|
+
var props = label.props;
|
|
46
|
+
var _ref = props,
|
|
47
|
+
expression = _ref.expression;
|
|
48
|
+
return "".concat(expression);
|
|
49
|
+
}
|
|
50
|
+
return "".concat(label);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Finds letters in a label that match a given prefix.
|
|
55
|
+
**/
|
|
56
|
+
function lettersMatching(label) {
|
|
57
|
+
var prefix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
58
|
+
var pref = prefix.split('');
|
|
59
|
+
var pos = -1;
|
|
60
|
+
var clean = preparePrefix(label);
|
|
61
|
+
return clean.split('').reduce(function (a, c) {
|
|
62
|
+
if (pos < pref.length && pref[pos + 1] === c) {
|
|
63
|
+
pos++;
|
|
64
|
+
return [].concat(_toConsumableArray(a), [c]);
|
|
65
|
+
}
|
|
66
|
+
return a;
|
|
67
|
+
}, []);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* Calculates a score for matching a label against a prefix.
|
|
72
|
+
**/
|
|
73
|
+
function matchScore(label, prefix) {
|
|
74
|
+
var pref = prefix.split('');
|
|
75
|
+
var pos = -1;
|
|
76
|
+
var clean = preparePrefix(label);
|
|
77
|
+
return clean.split('').reduce(function (a, c, idx) {
|
|
78
|
+
if (pos < pref.length && pref[pos + 1] === c) {
|
|
79
|
+
pos++;
|
|
80
|
+
return a + 1;
|
|
81
|
+
}
|
|
82
|
+
return a / (idx * 0.0001 + 1);
|
|
83
|
+
}, 0) / prefix.length;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* Sanitize a prefix for search
|
|
88
|
+
*/
|
|
89
|
+
function preparePrefix(prefix) {
|
|
90
|
+
if (typeof prefix === 'string') {
|
|
91
|
+
return (0, _removeAccents["default"])(prefix.toLowerCase()).replace(/[- ']/g, '');
|
|
92
|
+
}
|
|
93
|
+
return '';
|
|
94
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.SimpleLabelRenderer = SimpleLabelRenderer;
|
|
7
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
8
|
+
function getContent(option, search) {
|
|
9
|
+
if (option) {
|
|
10
|
+
var value = option.value,
|
|
11
|
+
label = option.label;
|
|
12
|
+
return label || value;
|
|
13
|
+
}
|
|
14
|
+
if (search !== null && search !== void 0 && search.trim().length) {
|
|
15
|
+
return search;
|
|
16
|
+
}
|
|
17
|
+
return null;
|
|
18
|
+
}
|
|
19
|
+
function SimpleLabelRenderer(_ref) {
|
|
20
|
+
var option = _ref.option,
|
|
21
|
+
placeholder = _ref.placeholder,
|
|
22
|
+
search = _ref.search;
|
|
23
|
+
var content = getContent(option, search);
|
|
24
|
+
if (content) {
|
|
25
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
26
|
+
className: "selection",
|
|
27
|
+
children: content
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
31
|
+
className: "placeholder",
|
|
32
|
+
children: placeholder
|
|
33
|
+
});
|
|
34
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.SimpleOptionRenderer = SimpleOptionRenderer;
|
|
7
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
8
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
9
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
10
|
+
function SimpleOptionRenderer(_ref) {
|
|
11
|
+
var option = _ref.option,
|
|
12
|
+
selected = _ref.selected;
|
|
13
|
+
var value = option.value,
|
|
14
|
+
label = option.label;
|
|
15
|
+
if (label && typeof label === 'string' && label.length) {
|
|
16
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
17
|
+
className: (0, _classnames["default"])('lunatic-dropdown-option', {
|
|
18
|
+
selected: selected
|
|
19
|
+
}),
|
|
20
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
21
|
+
className: "id",
|
|
22
|
+
children: value
|
|
23
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
24
|
+
children: "\xA0\u2014\xA0"
|
|
25
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
26
|
+
className: "label",
|
|
27
|
+
children: label
|
|
28
|
+
})]
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
32
|
+
className: (0, _classnames["default"])('lunatic-dropdown-option', {
|
|
33
|
+
selected: selected
|
|
34
|
+
}),
|
|
35
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
36
|
+
className: "id",
|
|
37
|
+
children: label
|
|
38
|
+
})
|
|
39
|
+
});
|
|
40
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.CustomDuration = void 0;
|
|
8
|
+
exports.Duration = Duration;
|
|
9
|
+
var _react = require("react");
|
|
10
|
+
var _getDurationFromValue = require("./getDurationFromValue");
|
|
11
|
+
var _durationUtils = require("./durationUtils");
|
|
12
|
+
var _formatDuration = require("./formatDuration");
|
|
13
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
14
|
+
var _object = require("../../utils/object");
|
|
15
|
+
var _slottableComponent = require("../shared/HOC/slottableComponent");
|
|
16
|
+
var _ComponentErrors = require("../shared/ComponentErrors/ComponentErrors");
|
|
17
|
+
var _Declarations = require("../shared/Declarations/Declarations");
|
|
18
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
19
|
+
var _excluded = ["handleChange", "response", "errors"];
|
|
20
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
21
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
22
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
23
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
24
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
25
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
26
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
27
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
28
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
29
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
30
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
31
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
32
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
33
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
34
|
+
function Duration(_ref) {
|
|
35
|
+
var handleChange = _ref.handleChange,
|
|
36
|
+
response = _ref.response,
|
|
37
|
+
errors = _ref.errors,
|
|
38
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
39
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(CustomDuration, _objectSpread(_objectSpread({}, props), {}, {
|
|
40
|
+
onChange: function onChange(v) {
|
|
41
|
+
return handleChange(response, v);
|
|
42
|
+
},
|
|
43
|
+
errors: (0, _ComponentErrors.getComponentErrors)(errors, props.id)
|
|
44
|
+
}));
|
|
45
|
+
}
|
|
46
|
+
var CustomDuration = exports.CustomDuration = (0, _slottableComponent.slottableComponent)('Duration', function (props) {
|
|
47
|
+
var errors = props.errors,
|
|
48
|
+
value = props.value,
|
|
49
|
+
label = props.label,
|
|
50
|
+
format = props.format,
|
|
51
|
+
onChange = props.onChange,
|
|
52
|
+
declarations = props.declarations,
|
|
53
|
+
id = props.id;
|
|
54
|
+
// We need to keep an internal state since one field can be empty (null value in duration)
|
|
55
|
+
// but we still send "0" and we don't want the field to display "0"
|
|
56
|
+
var _useState = (0, _react.useState)((0, _getDurationFromValue.getDurationFromValue)(value, format)),
|
|
57
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
58
|
+
duration = _useState2[0],
|
|
59
|
+
setDuration = _useState2[1];
|
|
60
|
+
|
|
61
|
+
// Generate handler for a specific unit field (year, month...)
|
|
62
|
+
var changeHandler = function changeHandler(unit) {
|
|
63
|
+
return function (e) {
|
|
64
|
+
if (!e.target.checkValidity()) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
var fieldValue = (0, _durationUtils.clampDuration)(Number.isNaN(e.target.valueAsNumber) ? null : e.target.valueAsNumber, unit);
|
|
68
|
+
var newDuration = _objectSpread(_objectSpread({}, duration), {}, _defineProperty({}, unit, fieldValue));
|
|
69
|
+
onChange((0, _formatDuration.formatDuration)(newDuration));
|
|
70
|
+
setDuration(newDuration);
|
|
71
|
+
};
|
|
72
|
+
};
|
|
73
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("fieldset", {
|
|
74
|
+
className: (0, _classnames["default"])('lunatic-input'),
|
|
75
|
+
children: [label && /*#__PURE__*/(0, _jsxRuntime.jsx)("legend", {
|
|
76
|
+
children: label
|
|
77
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_Declarations.Declarations, {
|
|
78
|
+
type: "AFTER_QUESTION_TEXT",
|
|
79
|
+
declarations: declarations,
|
|
80
|
+
id: id
|
|
81
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
82
|
+
className: "duration-fields",
|
|
83
|
+
children: (0, _object.objectKeys)(duration).map(function (unit) {
|
|
84
|
+
var _duration$unit;
|
|
85
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
86
|
+
className: "duration-field",
|
|
87
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("label", {
|
|
88
|
+
htmlFor: "".concat(unit, "Input"),
|
|
89
|
+
className: "input-label",
|
|
90
|
+
children: _durationUtils.labelByUnit[unit]
|
|
91
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("input", _objectSpread({
|
|
92
|
+
id: "".concat(unit, "Input"),
|
|
93
|
+
type: "number",
|
|
94
|
+
value: (_duration$unit = duration[unit]) !== null && _duration$unit !== void 0 ? _duration$unit : '',
|
|
95
|
+
className: "input-field",
|
|
96
|
+
onChange: changeHandler(unit)
|
|
97
|
+
}, _durationUtils.propsByUnit[unit]))]
|
|
98
|
+
}, unit);
|
|
99
|
+
})
|
|
100
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ComponentErrors.ComponentErrors, {
|
|
101
|
+
errors: errors
|
|
102
|
+
})]
|
|
103
|
+
});
|
|
104
|
+
});
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.FilterDescription = void 0;
|
|
7
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
8
|
+
var FilterDescription = exports.FilterDescription = function FilterDescription(_ref) {
|
|
9
|
+
var id = _ref.id,
|
|
10
|
+
label = _ref.label;
|
|
11
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
12
|
+
id: "filter-description-".concat(id),
|
|
13
|
+
"aria-label": "filter-description",
|
|
14
|
+
className: "filter-description-lunatic",
|
|
15
|
+
children: label
|
|
16
|
+
});
|
|
17
|
+
};
|