intelicoreact 1.6.23 → 1.6.24
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/dist/Atomic/FormElements/ActionAlert/ActionAlert.js +98 -1
- package/dist/Atomic/FormElements/AdvancedStatus/AdvancedStatus.js +48 -1
- package/dist/Atomic/FormElements/Calendar/Calendar.js +249 -1
- package/dist/Atomic/FormElements/Calendar/Calendar.props.js +4 -1
- package/dist/Atomic/FormElements/CheckboxInput/CheckboxInput.js +65 -1
- package/dist/Atomic/FormElements/CheckboxesLine/CheckboxesLine.js +52 -1
- package/dist/Atomic/FormElements/Datepicker/Datepicker.js +424 -1
- package/dist/Atomic/FormElements/Datepicker/Datepicker.props.js +4 -1
- package/dist/Atomic/FormElements/Datepicker/components/DatepickerCalendar.js +173 -1
- package/dist/Atomic/FormElements/Datepicker/components/DatepickerCalendar.props.js +4 -1
- package/dist/Atomic/FormElements/Dropdown/Dropdown.js +735 -1
- package/dist/Atomic/FormElements/Dropdown/components/DropdownLoader.js +20 -1
- package/dist/Atomic/FormElements/DropdownLiveSearch/DropdownLiveSearch.js +529 -1
- package/dist/Atomic/FormElements/FileLoader/FileLoader.js +94 -1
- package/dist/Atomic/FormElements/FileLoader/partial/LoadZone.js +105 -1
- package/dist/Atomic/FormElements/FileLoader/partial/LoadedContent.js +67 -1
- package/dist/Atomic/FormElements/FileLoaderDescription/FileLoaderDescription.js +247 -1
- package/dist/Atomic/FormElements/FileLoaderLocal/FileLoaderLocal.js +160 -1
- package/dist/Atomic/FormElements/FileLoaderLocalGroup/FileLoaderLocalGroup.js +193 -1
- package/dist/Atomic/FormElements/FormattedRawSSN/FormattedRawSSN.js +135 -1
- package/dist/Atomic/FormElements/FormattedRawSSN/FormattedRawSSN_old.js +116 -1
- package/dist/Atomic/FormElements/Input/Input.js +467 -1
- package/dist/Atomic/FormElements/InputCalendar/InputCalendar.js +161 -1
- package/dist/Atomic/FormElements/InputColor/InputColor.js +64 -1
- package/dist/Atomic/FormElements/InputCurrency/InputCurrency.js +200 -1
- package/dist/Atomic/FormElements/InputDateRange/InputDateRange.js +354 -1
- package/dist/Atomic/FormElements/InputDateRange/components/DateInput.js +71 -1
- package/dist/Atomic/FormElements/InputDateRange/components/Datepicker.js +693 -1
- package/dist/Atomic/FormElements/InputDateRange/components/OpenedPart.js +254 -1
- package/dist/Atomic/FormElements/InputDateRange/components/SelectItem.js +32 -1
- package/dist/Atomic/FormElements/InputDateRange/dependencies.js +200 -1
- package/dist/Atomic/FormElements/InputLink/InputLink.js +99 -1
- package/dist/Atomic/FormElements/InputMask/InputCarretPosition.js +37 -1
- package/dist/Atomic/FormElements/InputMask/InputMask.js +1214 -1
- package/dist/Atomic/FormElements/InputMask/config.js +15 -1
- package/dist/Atomic/FormElements/InputMask/functions.js +58 -1
- package/dist/Atomic/FormElements/InputMask2/InputMask2.js +674 -1
- package/dist/Atomic/FormElements/InputMask2/config.js +15 -1
- package/dist/Atomic/FormElements/InputMask2/functions.js +58 -1
- package/dist/Atomic/FormElements/InputMask3/InputMask3.js +766 -1
- package/dist/Atomic/FormElements/InputMask3/config.js +15 -1
- package/dist/Atomic/FormElements/InputMask3/functions.js +58 -1
- package/dist/Atomic/FormElements/InputWithAction/InputWithAction.js +114 -1
- package/dist/Atomic/FormElements/InputsRow/InputsRow.js +140 -1
- package/dist/Atomic/FormElements/Label/Label.js +87 -1
- package/dist/Atomic/FormElements/MobileCalendar/MobileCalendar.js +506 -1
- package/dist/Atomic/FormElements/MultiSelect/MultiSelect.js +45 -1
- package/dist/Atomic/FormElements/NumericInput/NumericInput.js +331 -1
- package/dist/Atomic/FormElements/RadioGroup/RadioGroup.js +66 -1
- package/dist/Atomic/FormElements/RadioGroupWithInput/RadioGroupWithInput.js +80 -1
- package/dist/Atomic/FormElements/RadioInput/RadioInput.js +57 -1
- package/dist/Atomic/FormElements/RadioRowSwitcher/RadioRowSwitcher.js +54 -1
- package/dist/Atomic/FormElements/RangeCalendar/RangeCalendar.js +183 -1
- package/dist/Atomic/FormElements/RangeInputs/RangeInputs.js +222 -1
- package/dist/Atomic/FormElements/RangeList/RangeList.js +175 -1
- package/dist/Atomic/FormElements/RangeList/partial/RangeListRow.js +43 -1
- package/dist/Atomic/FormElements/RangeSlider/RangeSlider.js +443 -1
- package/dist/Atomic/FormElements/RangeSlider2/RangeSlider2.js +858 -1
- package/dist/Atomic/FormElements/SwitchableRow/SwitchableRow.js +39 -1
- package/dist/Atomic/FormElements/Switcher/Switcher.js +59 -1
- package/dist/Atomic/FormElements/SwitcherCheckbox/SwitcherCheckbox.js +50 -1
- package/dist/Atomic/FormElements/SwitcherHide/SwitcherHide.js +44 -1
- package/dist/Atomic/FormElements/SwitcherRadio/SwitcherRadio.js +100 -1
- package/dist/Atomic/FormElements/SwitcherRange/SwitcherRange.js +52 -1
- package/dist/Atomic/FormElements/SwitcherRangeList/SwitcherRangeList.js +64 -1
- package/dist/Atomic/FormElements/SwitcherTagsDropdown/SwitcherTagsDropdown.js +170 -1
- package/dist/Atomic/FormElements/SwitcherTagsDropdown/partial/States.js +202 -1
- package/dist/Atomic/FormElements/SwitcherTextarea/SwitcherTextarea.js +67 -1
- package/dist/Atomic/FormElements/TagListToDropdown/TagListToDropdown.js +115 -1
- package/dist/Atomic/FormElements/TagsDropdown/TagsDropdown.js +1110 -1
- package/dist/Atomic/FormElements/Text/Text.js +125 -1
- package/dist/Atomic/FormElements/TextSwitcher/TextSwitcher.js +49 -1
- package/dist/Atomic/FormElements/Textarea/Textarea.js +80 -1
- package/dist/Atomic/FormElements/TieredCheckboxes/TieredCheckboxes.js +176 -1
- package/dist/Atomic/FormElements/TieredCheckboxes/partial/AccordionWithCheckbox.js +62 -1
- package/dist/Atomic/FormElements/TimeRange/TimeRange.js +119 -1
- package/dist/Atomic/FormElements/UserContacts/UserContacts.js +188 -1
- package/dist/Atomic/FormElements/VariantsListRadio/VariantsListRadio.js +83 -1
- package/dist/Atomic/FormElements/VariantsListRadio/partials/VariantsListRadioItem.js +82 -1
- package/dist/Atomic/FormElements/WidgetPseudoTable/WidgetPseudoTable.js +101 -1
- package/dist/Atomic/FormElements/WidgetPseudoTable/partial/constructor.js +29 -1
- package/dist/Atomic/FormElements/WidgetWithSwitchableRows/WidgetWithSwitchableRows.js +113 -1
- package/dist/Atomic/FormElements/WidgetWithSwitchableRows/partial/constructor.js +30 -1
- package/dist/Atomic/Layout/Header/Header.js +85 -1
- package/dist/Atomic/Layout/Spinner/Spinner.js +44 -1
- package/dist/Atomic/UI/Accordion/Accordion.js +108 -1
- package/dist/Atomic/UI/Accordion/AccordionItem.js +176 -1
- package/dist/Atomic/UI/AccordionTable/AccordionTable.js +238 -1
- package/dist/Atomic/UI/AccordionText/AccordionText.js +69 -1
- package/dist/Atomic/UI/AdvancedTag/AdvTag.js +207 -1
- package/dist/Atomic/UI/AdvancedTag/AdvancedTags.js +56 -1
- package/dist/Atomic/UI/Alert/Alert.js +72 -1
- package/dist/Atomic/UI/Arrow/Arrow.js +132 -1
- package/dist/Atomic/UI/Box/Box.js +52 -1
- package/dist/Atomic/UI/Button/Button.js +47 -1
- package/dist/Atomic/UI/ButtonsBar/ButtonsBar.js +72 -1
- package/dist/Atomic/UI/Chart/Chart.js +172 -1
- package/dist/Atomic/UI/Chart/partial/Chart.constants.js +95 -1
- package/dist/Atomic/UI/Chart/partial/ChartTypeSwitcherIcon/ChartTypeSwitcherIcon.js +80 -1
- package/dist/Atomic/UI/Chart/partial/datasetSetters.js +188 -1
- package/dist/Atomic/UI/Chart/partial/optionsConstructor.js +335 -1
- package/dist/Atomic/UI/Chart/partial/optionsSetters.js +43 -1
- package/dist/Atomic/UI/Chart/partial/utils.js +60 -1
- package/dist/Atomic/UI/CircleProgressBar/CircleProgressBar.js +109 -1
- package/dist/Atomic/UI/DateTime/DateTime.js +57 -1
- package/dist/Atomic/UI/DebugContainer/DebugContainer.js +44 -1
- package/dist/Atomic/UI/DebugContainer/useDebugContainer.js +15 -1
- package/dist/Atomic/UI/DoubleString/DoubleString.js +102 -1
- package/dist/Atomic/UI/DynamicIcon/DynamicIcon.js +70 -1
- package/dist/Atomic/UI/ExampleChartIntegration/ExampleChartIntegration.js +221 -1
- package/dist/Atomic/UI/ExampleChartIntegration/partial/utils.js +106 -1
- package/dist/Atomic/UI/Hint/Hint.js +256 -1
- package/dist/Atomic/UI/Hint/partials/_utils.js +64 -1
- package/dist/Atomic/UI/Modal/Modal.js +179 -1
- package/dist/Atomic/UI/Modal/ModalHOC.js +97 -1
- package/dist/Atomic/UI/Modal/partials/ModalFooter.js +71 -1
- package/dist/Atomic/UI/Modal/partials/ModalTitle.js +110 -1
- package/dist/Atomic/UI/Modal/partials/useMobileModal.js +192 -1
- package/dist/Atomic/UI/MonoAccordion/MonoAccordion._test.js +75 -1
- package/dist/Atomic/UI/MonoAccordion/MonoAccordion.js +80 -1
- package/dist/Atomic/UI/NavLine/NavLine.js +317 -1
- package/dist/Atomic/UI/PageTitle/PageTitle.js +77 -1
- package/dist/Atomic/UI/PieChart/PieChart.js +42 -1
- package/dist/Atomic/UI/Price/Price.js +31 -1
- package/dist/Atomic/UI/PriceRange/PriceRange.js +44 -1
- package/dist/Atomic/UI/ProgressLine/ProgressLine.js +98 -1
- package/dist/Atomic/UI/Status/Status.js +67 -1
- package/dist/Atomic/UI/Table/Partials/TdCell.js +87 -1
- package/dist/Atomic/UI/Table/Partials/TdHeader.js +38 -1
- package/dist/Atomic/UI/Table/Partials/TdRow.js +99 -1
- package/dist/Atomic/UI/Table/Partials/TdTitle.js +52 -1
- package/dist/Atomic/UI/Table/Table.js +63 -1
- package/dist/Atomic/UI/Table/TdTypes/TdActions.js +80 -1
- package/dist/Atomic/UI/Table/TdTypes/TdPriority.js +28 -1
- package/dist/Atomic/UI/Table/TdTypes/TdRange.js +13 -1
- package/dist/Atomic/UI/Table/TdTypes/TdWeight.js +53 -1
- package/dist/Atomic/UI/Tag/Tag.js +167 -1
- package/dist/Atomic/UI/TagList/TagList.js +251 -1
- package/dist/Atomic/UI/UserBox/UserBox.js +86 -1
- package/dist/Atomic/UI/WizardStepper/constructor.js +84 -1
- package/dist/Atomic/UI/WizardStepper/index.js +3 -1
- package/dist/Atomic/UI/WizardStepper/ui/StateIcon/StateIcon.js +37 -1
- package/dist/Atomic/UI/WizardStepper/ui/StateIcon/index.js +3 -1
- package/dist/Atomic/UI/WizardStepper/ui/StepRow/StepRow.js +61 -1
- package/dist/Atomic/UI/WizardStepper/ui/StepRow/index.js +3 -1
- package/dist/Atomic/UI/WizardStepper/ui/StepWrapper/StepWrapper.js +39 -1
- package/dist/Atomic/UI/WizardStepper/ui/StepWrapper/index.js +3 -1
- package/dist/Atomic/UI/WizardStepper/ui/icons.js +49 -1
- package/dist/Atomic/UI/WizardStepper/ui/index.js +3 -1
- package/dist/Classes/AbortableFetch.js +454 -1
- package/dist/Classes/AnimatedHandler.js +47 -1
- package/dist/Classes/RESTAPI/index.js +228 -1
- package/dist/Classes/RESTAPI/partials/AbortableFetch.js +457 -1
- package/dist/Classes/RESTAPI/partials/ApiBase.js +48 -1
- package/dist/Classes/RESTAPI/partials/ApiRequestCreators.js +112 -1
- package/dist/Classes/RESTAPI/partials/ApiUtils.js +189 -1
- package/dist/Classes/RESTAPI/partials/CredentialsProcessing.js +252 -1
- package/dist/Classes/RESTAPI/partials/Utils.js +92 -1
- package/dist/Classes/RESTAPI/partials/_outerDependencies.js +3 -1
- package/dist/Classes/RESTAPI/partials/_utils.js +197 -1
- package/dist/Constants/index.constants.js +78 -1
- package/dist/Functions/Portal.js +22 -1
- package/dist/Functions/customEventListener.js +96 -1
- package/dist/Functions/dateTime.js +149 -1
- package/dist/Functions/fieldValueFormatters.js +405 -1
- package/dist/Functions/guards/assertions.js +294 -1
- package/dist/Functions/guards/safeValue.js +75 -1
- package/dist/Functions/guards/typeGuards.js +373 -1
- package/dist/Functions/hooks/useFormFieldsChangesManager.js +95 -1
- package/dist/Functions/locale/createTranslator.js +32 -1
- package/dist/Functions/operations.js +130 -1
- package/dist/Functions/presets/inputMaskPresets.js +170 -1
- package/dist/Functions/presets/inputPresets.js +60 -1
- package/dist/Functions/presets/mobileKeyboardTypesPresets.js +45 -1
- package/dist/Functions/schemas.js +31 -1
- package/dist/Functions/useBodyScrollLock.js +17 -1
- package/dist/Functions/useClickOutside.js +15 -1
- package/dist/Functions/useDebounce.js +17 -1
- package/dist/Functions/useFieldFocus.js +84 -1
- package/dist/Functions/useFormTools/form-drivers/ArrayWithObjects.js +39 -1
- package/dist/Functions/useFormTools/form-drivers/ObjectWithIterableObjects.js +159 -1
- package/dist/Functions/useFormTools/form-drivers/ObjectWithNamedKeyObjects.js +78 -1
- package/dist/Functions/useFormTools/functions/General.js +134 -1
- package/dist/Functions/useFormTools/functions/RenderFields.js +111 -1
- package/dist/Functions/useFormTools/functions/usePrevious.js +12 -1
- package/dist/Functions/useFormTools/index.js +778 -1
- package/dist/Functions/useInputHighlightError.js +67 -1
- package/dist/Functions/useIsMobile/useIsMobile.js +33 -1
- package/dist/Functions/useKeyPress/useHandleKeyPress.js +52 -1
- package/dist/Functions/useKeyPress/useKeyPress.js +52 -1
- package/dist/Functions/useLocalStorage.js +34 -1
- package/dist/Functions/useLocationParams.js +27 -1
- package/dist/Functions/useMediaQuery.js +17 -1
- package/dist/Functions/useMetaInfo.js +43 -1
- package/dist/Functions/useMouseUpOutside.js +16 -1
- package/dist/Functions/useOnlineStatus.js +29 -1
- package/dist/Functions/usePasswordChecker.js +110 -1
- package/dist/Functions/usePrevious.js +12 -1
- package/dist/Functions/useResize.js +31 -1
- package/dist/Functions/useScrollTo.js +17 -1
- package/dist/Functions/useToggle.js +17 -1
- package/dist/Functions/utils.js +522 -1
- package/dist/Langs.js +168 -1
- package/dist/Molecular/CustomIcons/components/AffiliateNetworks.js +21 -1
- package/dist/Molecular/CustomIcons/components/AlertCircle.js +23 -1
- package/dist/Molecular/CustomIcons/components/AppStore.js +29 -1
- package/dist/Molecular/CustomIcons/components/Arrow.js +32 -1
- package/dist/Molecular/CustomIcons/components/ArrowDown.js +17 -1
- package/dist/Molecular/CustomIcons/components/ArrowLeft.js +22 -1
- package/dist/Molecular/CustomIcons/components/ArrowRight.js +22 -1
- package/dist/Molecular/CustomIcons/components/ArrowUp.js +17 -1
- package/dist/Molecular/CustomIcons/components/Bell.js +15 -1
- package/dist/Molecular/CustomIcons/components/Button.js +12 -1
- package/dist/Molecular/CustomIcons/components/Campaigns.js +16 -1
- package/dist/Molecular/CustomIcons/components/Check.js +14 -1
- package/dist/Molecular/CustomIcons/components/Check2.js +12 -1
- package/dist/Molecular/CustomIcons/components/ChevronDown.js +12 -1
- package/dist/Molecular/CustomIcons/components/ChevronDownDisabled.js +11 -1
- package/dist/Molecular/CustomIcons/components/ChevronLeft.js +11 -1
- package/dist/Molecular/CustomIcons/components/ChevronRight.js +11 -1
- package/dist/Molecular/CustomIcons/components/ChevronUp.js +11 -1
- package/dist/Molecular/CustomIcons/components/ChevronUpDown.js +27 -1
- package/dist/Molecular/CustomIcons/components/Close.js +14 -1
- package/dist/Molecular/CustomIcons/components/ColumnsOrder.js +17 -1
- package/dist/Molecular/CustomIcons/components/Delete.js +16 -1
- package/dist/Molecular/CustomIcons/components/Edit.js +15 -1
- package/dist/Molecular/CustomIcons/components/Email.js +31 -1
- package/dist/Molecular/CustomIcons/components/FinturfLogo.js +18 -1
- package/dist/Molecular/CustomIcons/components/FinturfLogo2.js +35 -1
- package/dist/Molecular/CustomIcons/components/Flows.js +15 -1
- package/dist/Molecular/CustomIcons/components/Gift.js +25 -1
- package/dist/Molecular/CustomIcons/components/GoogleAuth.js +29 -1
- package/dist/Molecular/CustomIcons/components/GooglePlay.js +29 -1
- package/dist/Molecular/CustomIcons/components/HelpCircle.js +19 -1
- package/dist/Molecular/CustomIcons/components/HelpCircle2.js +20 -1
- package/dist/Molecular/CustomIcons/components/HelpCircleFilled.js +19 -1
- package/dist/Molecular/CustomIcons/components/Home.js +16 -1
- package/dist/Molecular/CustomIcons/components/Home2.js +22 -1
- package/dist/Molecular/CustomIcons/components/Key.js +23 -1
- package/dist/Molecular/CustomIcons/components/Landers.js +20 -1
- package/dist/Molecular/CustomIcons/components/Lock.js +15 -1
- package/dist/Molecular/CustomIcons/components/Mail.js +26 -1
- package/dist/Molecular/CustomIcons/components/Mastercard.js +73 -1
- package/dist/Molecular/CustomIcons/components/Minus.js +25 -1
- package/dist/Molecular/CustomIcons/components/Offers.js +16 -1
- package/dist/Molecular/CustomIcons/components/Pause.js +28 -1
- package/dist/Molecular/CustomIcons/components/PayPal.js +41 -1
- package/dist/Molecular/CustomIcons/components/PayPalLightLarge.js +28 -1
- package/dist/Molecular/CustomIcons/components/Phone.js +30 -1
- package/dist/Molecular/CustomIcons/components/Play.js +25 -1
- package/dist/Molecular/CustomIcons/components/Plus.js +25 -1
- package/dist/Molecular/CustomIcons/components/Profile.js +16 -1
- package/dist/Molecular/CustomIcons/components/QRCode.js +29 -1
- package/dist/Molecular/CustomIcons/components/Rectangle.js +12 -1
- package/dist/Molecular/CustomIcons/components/Revert.js +13 -1
- package/dist/Molecular/CustomIcons/components/Star.js +14 -1
- package/dist/Molecular/CustomIcons/components/Star2.js +16 -1
- package/dist/Molecular/CustomIcons/components/TrafficSources.js +14 -1
- package/dist/Molecular/CustomIcons/components/Trash.js +15 -1
- package/dist/Molecular/CustomIcons/components/TrashRed.js +15 -1
- package/dist/Molecular/CustomIcons/components/Triggers.js +15 -1
- package/dist/Molecular/CustomIcons/components/User.js +25 -1
- package/dist/Molecular/CustomIcons/components/Visa.js +31 -1
- package/dist/Molecular/CustomIcons/components/X.js +12 -1
- package/dist/Molecular/CustomIcons/index.js +61 -1
- package/dist/Molecular/FormElement/FormElement.js +54 -1
- package/dist/Molecular/FormWithDependOn/FormWithDependOn.js +184 -1
- package/dist/Molecular/FormWithDependOn/partials/_utils.js +53 -1
- package/dist/Molecular/InputAddress/InputAddress.js +626 -1
- package/dist/Molecular/InputPassword/InputPassword.js +48 -1
- package/dist/index.js +104 -1
- package/package.json +1 -1
- package/dist/Atomic/FormElements/SwitcherTagsDropdown/SwitcherTagsDropdown.d.ts +0 -16
- package/dist/Atomic/FormElements/TagListToDropdown/TagListToDropdown.d.ts +0 -9
- package/dist/Atomic/FormElements/TagsDropdown/TagsDropdown.d.ts +0 -5
- package/dist/Atomic/FormElements/TagsDropdown/TagsDropdown.interface.d.ts +0 -78
- package/dist/Atomic/FormElements/TagsDropdown/TagsDropdown.interface.js +0 -1
- package/dist/Atomic/FormElements/TagsDropdown/TagsDropdown.interface.js.map +0 -1
- package/dist/Atomic/FormElements/TagsDropdown/TagsDropdown.js.map +0 -1
|
@@ -1 +1,98 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "default", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _default;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
13
|
+
const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
|
|
14
|
+
const _Button = /*#__PURE__*/ _interop_require_default(require("../../UI/Button/Button"));
|
|
15
|
+
require("./ActionAlert.scss");
|
|
16
|
+
function _interop_require_default(obj) {
|
|
17
|
+
return obj && obj.__esModule ? obj : {
|
|
18
|
+
default: obj
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
22
|
+
if (typeof WeakMap !== "function") return null;
|
|
23
|
+
var cacheBabelInterop = new WeakMap();
|
|
24
|
+
var cacheNodeInterop = new WeakMap();
|
|
25
|
+
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
26
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
27
|
+
})(nodeInterop);
|
|
28
|
+
}
|
|
29
|
+
function _interop_require_wildcard(obj, nodeInterop) {
|
|
30
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
31
|
+
return obj;
|
|
32
|
+
}
|
|
33
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
34
|
+
return {
|
|
35
|
+
default: obj
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
39
|
+
if (cache && cache.has(obj)) {
|
|
40
|
+
return cache.get(obj);
|
|
41
|
+
}
|
|
42
|
+
var newObj = {
|
|
43
|
+
__proto__: null
|
|
44
|
+
};
|
|
45
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
46
|
+
for(var key in obj){
|
|
47
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
48
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
49
|
+
if (desc && (desc.get || desc.set)) {
|
|
50
|
+
Object.defineProperty(newObj, key, desc);
|
|
51
|
+
} else {
|
|
52
|
+
newObj[key] = obj[key];
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
newObj.default = obj;
|
|
57
|
+
if (cache) {
|
|
58
|
+
cache.set(obj, newObj);
|
|
59
|
+
}
|
|
60
|
+
return newObj;
|
|
61
|
+
}
|
|
62
|
+
const ActionAlert = ({ message, className, buttonsClassName, date, noButtons, children, variant = 'default', testId = 'alert', buttons })=>{
|
|
63
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
64
|
+
role: "alert",
|
|
65
|
+
"data-testid": testId,
|
|
66
|
+
className: (0, _classnames.default)(`action-alert action-alert--${variant}`, className),
|
|
67
|
+
children: [
|
|
68
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
69
|
+
className: "action-alert__message-box",
|
|
70
|
+
children: [
|
|
71
|
+
date && /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
72
|
+
className: "action-alert__time",
|
|
73
|
+
children: date
|
|
74
|
+
}),
|
|
75
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
76
|
+
className: "action-alert__message",
|
|
77
|
+
children: message || children
|
|
78
|
+
})
|
|
79
|
+
]
|
|
80
|
+
}),
|
|
81
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
82
|
+
className: buttonsClassName,
|
|
83
|
+
children: typeof buttons !== 'undefined' && (buttons === null || buttons === void 0 ? void 0 : buttons.length) > 0 && !noButtons && buttons.map((item)=>/*#__PURE__*/ (0, _react.createElement)(_Button.default, {
|
|
84
|
+
style: {
|
|
85
|
+
backgroundColor: item.buttonColor,
|
|
86
|
+
borderColor: item.buttonColor
|
|
87
|
+
},
|
|
88
|
+
className: "ml5",
|
|
89
|
+
label: item.buttonLabel,
|
|
90
|
+
...item,
|
|
91
|
+
onClick: item.onClick,
|
|
92
|
+
key: item.key
|
|
93
|
+
}))
|
|
94
|
+
})
|
|
95
|
+
]
|
|
96
|
+
});
|
|
97
|
+
};
|
|
98
|
+
const _default = ActionAlert;
|
|
@@ -1 +1,48 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "default", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _default;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
|
|
13
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
14
|
+
const _Status = /*#__PURE__*/ _interop_require_default(require("../../UI/Status/Status"));
|
|
15
|
+
const _TextSwitcher = /*#__PURE__*/ _interop_require_default(require("../TextSwitcher/TextSwitcher"));
|
|
16
|
+
require("./AdvancedStatus.scss");
|
|
17
|
+
function _interop_require_default(obj) {
|
|
18
|
+
return obj && obj.__esModule ? obj : {
|
|
19
|
+
default: obj
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
const RC = 'advanced-status';
|
|
23
|
+
const AdvancedStatus = ({ onChange, inactiveText, activeText, value, disabled = false, isPrimary = false, primaryStatusText, className, testId = RC, ...props })=>{
|
|
24
|
+
const isUndefined = value === undefined || value === null;
|
|
25
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
26
|
+
...props,
|
|
27
|
+
"data-testid": testId,
|
|
28
|
+
className: (0, _classnames.default)(RC, {
|
|
29
|
+
'advanced-status_undefined': isUndefined,
|
|
30
|
+
'advanced-status_disabled': disabled
|
|
31
|
+
}, className),
|
|
32
|
+
children: [
|
|
33
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_TextSwitcher.default, {
|
|
34
|
+
onChange: onChange,
|
|
35
|
+
isActive: value || false,
|
|
36
|
+
inactiveText: inactiveText,
|
|
37
|
+
activeText: activeText,
|
|
38
|
+
className: "advanced-status__switcher"
|
|
39
|
+
}),
|
|
40
|
+
isPrimary && /*#__PURE__*/ (0, _jsxruntime.jsx)(_Status.default, {
|
|
41
|
+
className: "advanced-status__status",
|
|
42
|
+
status: "warning",
|
|
43
|
+
children: primaryStatusText
|
|
44
|
+
})
|
|
45
|
+
]
|
|
46
|
+
});
|
|
47
|
+
};
|
|
48
|
+
const _default = AdvancedStatus;
|
|
@@ -1 +1,249 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "default", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _default;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
|
|
13
|
+
const _moment = /*#__PURE__*/ _interop_require_default(require("moment"));
|
|
14
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
15
|
+
const _reactfeather = require("react-feather");
|
|
16
|
+
const _reactinputmask = /*#__PURE__*/ _interop_require_default(require("react-input-mask"));
|
|
17
|
+
require("./Calendar.scss");
|
|
18
|
+
function _interop_require_default(obj) {
|
|
19
|
+
return obj && obj.__esModule ? obj : {
|
|
20
|
+
default: obj
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
24
|
+
if (typeof WeakMap !== "function") return null;
|
|
25
|
+
var cacheBabelInterop = new WeakMap();
|
|
26
|
+
var cacheNodeInterop = new WeakMap();
|
|
27
|
+
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
28
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
29
|
+
})(nodeInterop);
|
|
30
|
+
}
|
|
31
|
+
function _interop_require_wildcard(obj, nodeInterop) {
|
|
32
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
33
|
+
return obj;
|
|
34
|
+
}
|
|
35
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
36
|
+
return {
|
|
37
|
+
default: obj
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
41
|
+
if (cache && cache.has(obj)) {
|
|
42
|
+
return cache.get(obj);
|
|
43
|
+
}
|
|
44
|
+
var newObj = {
|
|
45
|
+
__proto__: null
|
|
46
|
+
};
|
|
47
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
48
|
+
for(var key in obj){
|
|
49
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
50
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
51
|
+
if (desc && (desc.get || desc.set)) {
|
|
52
|
+
Object.defineProperty(newObj, key, desc);
|
|
53
|
+
} else {
|
|
54
|
+
newObj[key] = obj[key];
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
newObj.default = obj;
|
|
59
|
+
if (cache) {
|
|
60
|
+
cache.set(obj, newObj);
|
|
61
|
+
}
|
|
62
|
+
return newObj;
|
|
63
|
+
}
|
|
64
|
+
const CN = 'calendar';
|
|
65
|
+
const paramsDefault = {};
|
|
66
|
+
const dateDefault = (0, _moment.default)().format('L');
|
|
67
|
+
const Calendar = ({ date = dateDefault, setDate, setIsOpened, className, isListTop, allowPrev = true, allowNext = true, params = paramsDefault, testId = CN })=>{
|
|
68
|
+
if (!setDate || !setIsOpened) {
|
|
69
|
+
throw new Error('Required props setDate and setIsOpened must be provided to Calendar component');
|
|
70
|
+
}
|
|
71
|
+
const { minDate, maxDate, momentMinDate, momentMaxDate, isDontLimitFuture } = params;
|
|
72
|
+
const [days, setDays] = (0, _react.useState)({});
|
|
73
|
+
const [showDate, setShowDate] = (0, _react.useState)(date);
|
|
74
|
+
const [isChangeYear, setIsChangeYear] = (0, _react.useState)(false);
|
|
75
|
+
const [inputYearValue, setInputYearValue] = (0, _react.useState)((0, _moment.default)(showDate).format('YYYY'));
|
|
76
|
+
const yearInputRef = (0, _react.useRef)(null);
|
|
77
|
+
const selectedDay = (0, _moment.default)(showDate);
|
|
78
|
+
const isError = 'Invalid date';
|
|
79
|
+
const showMonth = (0, _react.useMemo)(()=>(0, _moment.default)(showDate).format('MMM'), [
|
|
80
|
+
showDate
|
|
81
|
+
]);
|
|
82
|
+
const showYear = (0, _react.useMemo)(()=>(0, _moment.default)(showDate).format('YYYY'), [
|
|
83
|
+
showDate
|
|
84
|
+
]);
|
|
85
|
+
const isShovPrevArrow = allowPrev && !(minDate && (0, _moment.default)(showDate).startOf('month').isSameOrBefore(momentMinDate, 'months'));
|
|
86
|
+
const isShovNextArrow = allowNext && (isDontLimitFuture || !(0, _moment.default)(showDate).startOf('month').isSameOrAfter(maxDate ? momentMaxDate : (0, _moment.default)().add(1, 'day').startOf('day'), 'months'));
|
|
87
|
+
(0, _react.useEffect)(()=>{
|
|
88
|
+
const result = {};
|
|
89
|
+
const day = selectedDay.startOf('month');
|
|
90
|
+
const daysInMonth = day.daysInMonth();
|
|
91
|
+
for(let d = 0; d < daysInMonth; d += 1){
|
|
92
|
+
let week = day.week();
|
|
93
|
+
if (day.month() === 11 && week === 1) week = 53;
|
|
94
|
+
if (day.month() === 0 && week === 53) week = 0;
|
|
95
|
+
if (!Object.prototype.hasOwnProperty.call(result, week)) {
|
|
96
|
+
result[week] = {};
|
|
97
|
+
}
|
|
98
|
+
result[week][day.weekday()] = {
|
|
99
|
+
date: day.toDate()
|
|
100
|
+
};
|
|
101
|
+
day.add(1, 'd');
|
|
102
|
+
}
|
|
103
|
+
setDays(result);
|
|
104
|
+
}, [
|
|
105
|
+
showDate
|
|
106
|
+
]);
|
|
107
|
+
const renderDay = (week, dayOfWeek)=>{
|
|
108
|
+
var _days_week;
|
|
109
|
+
const day = (_days_week = days[week]) === null || _days_week === void 0 ? void 0 : _days_week[dayOfWeek];
|
|
110
|
+
if (!day) return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
111
|
+
className: "calendar__day"
|
|
112
|
+
});
|
|
113
|
+
const isFutureDay = day && !isDontLimitFuture && maxDate ? (0, _moment.default)(day.date).isAfter(momentMaxDate || (0, _moment.default)().add(1, 'days'), 'day') : (0, _moment.default)(day.date).isAfter((0, _moment.default)(), 'day');
|
|
114
|
+
const isBeforeDay = day && (0, _moment.default)(day.date).isBefore(momentMinDate || '', 'day');
|
|
115
|
+
const classNames = (0, _classnames.default)('calendar__day', {
|
|
116
|
+
'calendar__day--clickable': day
|
|
117
|
+
}, {
|
|
118
|
+
'calendar__day--disabled': !isDontLimitFuture && isFutureDay
|
|
119
|
+
}, {
|
|
120
|
+
'calendar__day--disabled': isBeforeDay
|
|
121
|
+
}, {
|
|
122
|
+
'calendar__day--selected': (0, _moment.default)(date).format() === (0, _moment.default)(day.date).format()
|
|
123
|
+
});
|
|
124
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
125
|
+
className: classNames,
|
|
126
|
+
onClick: day && (isDontLimitFuture || !isFutureDay) ? ()=>{
|
|
127
|
+
setDate((0, _moment.default)(day.date).format('L'));
|
|
128
|
+
setIsOpened(false);
|
|
129
|
+
} : undefined,
|
|
130
|
+
children: day && day.date.getDate()
|
|
131
|
+
}, `${week}_${dayOfWeek}`);
|
|
132
|
+
};
|
|
133
|
+
const handlePrev = ()=>{
|
|
134
|
+
setShowDate((0, _moment.default)(showDate).subtract(1, 'month').format('L'));
|
|
135
|
+
};
|
|
136
|
+
const handleNext = ()=>{
|
|
137
|
+
setShowDate((0, _moment.default)(showDate).add(1, 'month').format('L'));
|
|
138
|
+
};
|
|
139
|
+
const closeYearInput = ()=>{
|
|
140
|
+
const newDate = (()=>{
|
|
141
|
+
const dateArr = showDate.split('/');
|
|
142
|
+
dateArr[2] = inputYearValue;
|
|
143
|
+
return (0, _moment.default)(dateArr.join('/')).format('MM/DD/YYYY') === isError ? showDate : (0, _moment.default)(dateArr.join('/')).format('MM/DD/YYYY');
|
|
144
|
+
})();
|
|
145
|
+
let resultDate = newDate;
|
|
146
|
+
if (minDate && (0, _moment.default)(minDate) > (0, _moment.default)(newDate)) resultDate = (0, _moment.default)(showDate).format('MM/DD/YYYY');
|
|
147
|
+
else if (maxDate && (0, _moment.default)(maxDate) < (0, _moment.default)(newDate)) resultDate = (0, _moment.default)(showDate).format('MM/DD/YYYY');
|
|
148
|
+
setIsChangeYear(false);
|
|
149
|
+
setShowDate(resultDate);
|
|
150
|
+
setInputYearValue(resultDate);
|
|
151
|
+
};
|
|
152
|
+
(0, _react.useEffect)(()=>{
|
|
153
|
+
let timeoutId;
|
|
154
|
+
if (isChangeYear && yearInputRef.current) {
|
|
155
|
+
const input = yearInputRef.current.querySelector('input');
|
|
156
|
+
if (input) {
|
|
157
|
+
setInputYearValue(showYear);
|
|
158
|
+
timeoutId = setTimeout(()=>{
|
|
159
|
+
input.focus();
|
|
160
|
+
input.select();
|
|
161
|
+
}, 0);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
return ()=>{
|
|
165
|
+
clearTimeout(timeoutId);
|
|
166
|
+
};
|
|
167
|
+
}, [
|
|
168
|
+
isChangeYear,
|
|
169
|
+
showYear
|
|
170
|
+
]);
|
|
171
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
172
|
+
"data-testid": testId,
|
|
173
|
+
className: (0, _classnames.default)(CN, className, {
|
|
174
|
+
'calendar_list-top': isListTop
|
|
175
|
+
}),
|
|
176
|
+
children: [
|
|
177
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
178
|
+
className: "calendar-header",
|
|
179
|
+
children: [
|
|
180
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
181
|
+
className: "calendar-header__prev",
|
|
182
|
+
"data-testid": `${testId}-prev-arrow`,
|
|
183
|
+
children: isShovPrevArrow && /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
184
|
+
onClick: handlePrev,
|
|
185
|
+
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_reactfeather.ChevronLeft, {})
|
|
186
|
+
})
|
|
187
|
+
}),
|
|
188
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
189
|
+
className: (0, _classnames.default)('calendar-header__title'),
|
|
190
|
+
ref: yearInputRef,
|
|
191
|
+
children: [
|
|
192
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
|
193
|
+
className: "calendar-header__title-month",
|
|
194
|
+
children: `${showMonth} `
|
|
195
|
+
}),
|
|
196
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
|
197
|
+
className: (0, _classnames.default)('calendar-header__title-year', {
|
|
198
|
+
'calendar-header__title-year_change-mode': isChangeYear
|
|
199
|
+
}),
|
|
200
|
+
onClick: ()=>setIsChangeYear(true),
|
|
201
|
+
children: isChangeYear ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_reactinputmask.default, {
|
|
202
|
+
className: "calendar-header__title-year-change-input",
|
|
203
|
+
value: inputYearValue,
|
|
204
|
+
mask: "9999",
|
|
205
|
+
onBlur: closeYearInput,
|
|
206
|
+
onKeyUp: (e)=>{
|
|
207
|
+
if (e.key === 'Escape') setIsChangeYear(false);
|
|
208
|
+
if (e.key === 'Enter') closeYearInput();
|
|
209
|
+
},
|
|
210
|
+
onChange: (e)=>setInputYearValue(e.target.value)
|
|
211
|
+
}) : showYear
|
|
212
|
+
})
|
|
213
|
+
]
|
|
214
|
+
}),
|
|
215
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
216
|
+
"data-testid": `${testId}-next-arrow`,
|
|
217
|
+
className: "calendar-header__next",
|
|
218
|
+
children: isShovNextArrow && /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
219
|
+
onClick: handleNext,
|
|
220
|
+
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_reactfeather.ChevronRight, {})
|
|
221
|
+
})
|
|
222
|
+
})
|
|
223
|
+
]
|
|
224
|
+
}),
|
|
225
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
226
|
+
className: "calendar__week",
|
|
227
|
+
children: [
|
|
228
|
+
...Array.from({
|
|
229
|
+
length: 7
|
|
230
|
+
}).keys()
|
|
231
|
+
].map((dayOfWeek)=>/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
232
|
+
className: "calendar__day calendar__day--title",
|
|
233
|
+
children: (0, _moment.default)().weekday(dayOfWeek).format('dd')
|
|
234
|
+
}, `day-of-week_${dayOfWeek}`))
|
|
235
|
+
}),
|
|
236
|
+
Object.keys(days).map((week, index)=>/*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
237
|
+
className: "calendar__week",
|
|
238
|
+
children: [
|
|
239
|
+
...Array.from({
|
|
240
|
+
length: 7
|
|
241
|
+
}).keys()
|
|
242
|
+
].map((dayOfWeek)=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_react.default.Fragment, {
|
|
243
|
+
children: renderDay(Number(week), dayOfWeek)
|
|
244
|
+
}, `calendar-day--${dayOfWeek}`))
|
|
245
|
+
}, `week_${index}`))
|
|
246
|
+
]
|
|
247
|
+
});
|
|
248
|
+
};
|
|
249
|
+
const _default = Calendar;
|
|
@@ -1 +1,65 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "default", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _default;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
|
|
13
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
14
|
+
require("./CheckboxInput.scss");
|
|
15
|
+
function _interop_require_default(obj) {
|
|
16
|
+
return obj && obj.__esModule ? obj : {
|
|
17
|
+
default: obj
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
const RC = 'checkbox-input';
|
|
21
|
+
const attrsOfNativeInputDefault = {};
|
|
22
|
+
const CheckboxInput = ({ label, id, value, onChange, disabled, className, isStark, testId = RC, attributesOfNativeInput = attrsOfNativeInputDefault, ...props })=>{
|
|
23
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)("label", {
|
|
24
|
+
"data-testid": testId,
|
|
25
|
+
className: (0, _classnames.default)(RC, className, {
|
|
26
|
+
[`checkbox-input_disabled`]: disabled
|
|
27
|
+
}),
|
|
28
|
+
htmlFor: id === null || id === void 0 ? void 0 : id.toString(),
|
|
29
|
+
children: [
|
|
30
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)("div", {
|
|
31
|
+
className: (0, _classnames.default)(`checkbox-input__input`, {
|
|
32
|
+
[`checkbox-input__input_checked`]: value,
|
|
33
|
+
[`checkbox-input__input_indeterminate`]: isStark
|
|
34
|
+
}),
|
|
35
|
+
children: [
|
|
36
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("input", {
|
|
37
|
+
...id ? {
|
|
38
|
+
'id': id.toString(),
|
|
39
|
+
'data-id': id
|
|
40
|
+
} : {},
|
|
41
|
+
type: "checkbox",
|
|
42
|
+
className: "checkbox-input__checkbox",
|
|
43
|
+
onChange: (e)=>onChange(!value, e),
|
|
44
|
+
checked: value !== null && value !== void 0 ? value : false,
|
|
45
|
+
disabled: disabled,
|
|
46
|
+
ref: (elem)=>{
|
|
47
|
+
if (elem) elem.indeterminate = !!isStark;
|
|
48
|
+
},
|
|
49
|
+
"data-testid": `${testId}-input`,
|
|
50
|
+
...attributesOfNativeInput,
|
|
51
|
+
...props
|
|
52
|
+
}),
|
|
53
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)("span", {
|
|
54
|
+
className: "checkbox-input__mark"
|
|
55
|
+
})
|
|
56
|
+
]
|
|
57
|
+
}),
|
|
58
|
+
label && /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
59
|
+
className: "checkbox-input__label",
|
|
60
|
+
children: label
|
|
61
|
+
})
|
|
62
|
+
]
|
|
63
|
+
});
|
|
64
|
+
};
|
|
65
|
+
const _default = CheckboxInput;
|
|
@@ -1 +1,52 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "default", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _default;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
|
|
13
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
14
|
+
const _CheckboxInput = /*#__PURE__*/ _interop_require_default(require("../CheckboxInput/CheckboxInput"));
|
|
15
|
+
require("./CheckboxesLine.scss");
|
|
16
|
+
function _interop_require_default(obj) {
|
|
17
|
+
return obj && obj.__esModule ? obj : {
|
|
18
|
+
default: obj
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
const RC = 'checkboxes-line';
|
|
22
|
+
const CheckboxesLine = (props)=>{
|
|
23
|
+
const { field, onChange } = props;
|
|
24
|
+
const { items, value, disabled, isPositionColumn, className, testId = RC } = field !== null && field !== void 0 ? field : props || {};
|
|
25
|
+
const handleChange = (val, id)=>{
|
|
26
|
+
onChange(val ? [
|
|
27
|
+
...value || [],
|
|
28
|
+
id
|
|
29
|
+
] : [
|
|
30
|
+
...(value === null || value === void 0 ? void 0 : value.filter((el)=>el !== id)) || []
|
|
31
|
+
]);
|
|
32
|
+
};
|
|
33
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
|
|
34
|
+
"data-testid": RC,
|
|
35
|
+
className: (0, _classnames.default)(RC, {
|
|
36
|
+
[`${RC}_column`]: isPositionColumn
|
|
37
|
+
}, className),
|
|
38
|
+
children: (items === null || items === void 0 ? void 0 : items.map((item)=>{
|
|
39
|
+
var _value_includes;
|
|
40
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_CheckboxInput.default, {
|
|
41
|
+
testId: (item === null || item === void 0 ? void 0 : item.testId) || testId,
|
|
42
|
+
id: item.id,
|
|
43
|
+
className: `${RC}__checkbox-input`,
|
|
44
|
+
label: item.label,
|
|
45
|
+
value: (value === null || value === void 0 ? void 0 : (_value_includes = value.includes) === null || _value_includes === void 0 ? void 0 : _value_includes.call(value, item.id)) || false,
|
|
46
|
+
onChange: (val)=>handleChange(val, item.id),
|
|
47
|
+
disabled: disabled || item.disabled
|
|
48
|
+
}, item.label);
|
|
49
|
+
})) || null
|
|
50
|
+
});
|
|
51
|
+
};
|
|
52
|
+
const _default = CheckboxesLine;
|