plataforma-fundacao-componentes 2.25.8 → 2.25.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/dist/components/button/Button.stories.d.ts +31 -32
- package/dist/components/buttonFileUpload/ButtonFileUpload.d.ts +19 -9
- package/dist/components/buttonFileUpload/ButtonFileUpload.stories.d.ts +9 -10
- package/dist/components/checkbox/Checkbox.d.ts +1 -0
- package/dist/components/datePicker/components/datePickerCalendar/DatePickerCalendar.d.ts +1 -0
- package/dist/components/dropdownMenu/DropdownMenu.d.ts +5 -7
- package/dist/components/fileUpload/FileUpload.d.ts +2 -2
- package/dist/components/table/components/TableUpperHeader/TableUpperHeader.d.ts +1 -1
- package/dist/hooks/useOutsideClick/useOutsideClick.d.ts +3 -1
- package/dist/index.css +79 -79
- package/dist/index.d.ts +1 -1
- package/dist/index.js +116 -118
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +119 -121
- package/dist/index.modern.js.map +1 -1
- package/dist/libraries/{BlobFileTypes.d.ts → FileTypes.d.ts} +15 -12
- package/dist/libraries/IconButtonTheme.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React$1, { useMemo, useState, useEffect, memo, useRef, useLayoutEffect,
|
|
1
|
+
import React$1, { useMemo, useState, useEffect, memo, useCallback, useRef, useLayoutEffect, createRef, Fragment as Fragment$1, forwardRef, useImperativeHandle } from 'react';
|
|
2
2
|
import { CSSTransition, TransitionGroup } from 'react-transition-group';
|
|
3
3
|
import { Chart } from 'chart.js';
|
|
4
4
|
import moment from 'moment';
|
|
@@ -4805,52 +4805,55 @@ Button.defaultProps = {
|
|
|
4805
4805
|
};
|
|
4806
4806
|
var Button$1 = memo(Button);
|
|
4807
4807
|
|
|
4808
|
-
var
|
|
4809
|
-
(function (
|
|
4810
|
-
|
|
4811
|
-
|
|
4812
|
-
|
|
4813
|
-
|
|
4814
|
-
|
|
4815
|
-
|
|
4816
|
-
|
|
4817
|
-
|
|
4818
|
-
|
|
4819
|
-
|
|
4820
|
-
|
|
4821
|
-
|
|
4822
|
-
|
|
4823
|
-
|
|
4824
|
-
|
|
4825
|
-
|
|
4826
|
-
|
|
4808
|
+
var FileTypes;
|
|
4809
|
+
(function (FileTypes) {
|
|
4810
|
+
FileTypes["ALL_IMAGES"] = "image/*";
|
|
4811
|
+
FileTypes["AVI"] = ".avi";
|
|
4812
|
+
FileTypes["DOC"] = ".doc";
|
|
4813
|
+
FileTypes["DOCX"] = ".docx";
|
|
4814
|
+
FileTypes["GIF"] = ".gif";
|
|
4815
|
+
FileTypes["JPEG"] = ".jpeg";
|
|
4816
|
+
FileTypes["JPG"] = ".jpg";
|
|
4817
|
+
FileTypes["MP4"] = ".mp4";
|
|
4818
|
+
FileTypes["PDF"] = ".pdf";
|
|
4819
|
+
FileTypes["PNG"] = ".png";
|
|
4820
|
+
FileTypes["PPT"] = ".ppt";
|
|
4821
|
+
FileTypes["PPTX"] = ".pptx";
|
|
4822
|
+
FileTypes["ODT"] = ".odt";
|
|
4823
|
+
FileTypes["SVG"] = ".svg";
|
|
4824
|
+
FileTypes["WMV"] = ".wmv";
|
|
4825
|
+
FileTypes["XLS"] = ".xls";
|
|
4826
|
+
FileTypes["XLSX"] = ".xlsx";
|
|
4827
|
+
FileTypes["ZIP"] = ".zip";
|
|
4828
|
+
FileTypes["RAR"] = ".rar";
|
|
4829
|
+
})(FileTypes || (FileTypes = {}));
|
|
4827
4830
|
var ImageTypes;
|
|
4828
4831
|
(function (ImageTypes) {
|
|
4829
|
-
ImageTypes["PNG"] = ".png";
|
|
4830
4832
|
ImageTypes["GIF"] = ".gif";
|
|
4831
|
-
ImageTypes["JPG"] = ".jpg";
|
|
4832
4833
|
ImageTypes["JPEG"] = ".jpeg";
|
|
4834
|
+
ImageTypes["JPG"] = ".jpg";
|
|
4835
|
+
ImageTypes["PNG"] = ".png";
|
|
4833
4836
|
})(ImageTypes || (ImageTypes = {}));
|
|
4834
4837
|
|
|
4835
4838
|
var rootClassName$1H = 'component-button-file-upload';
|
|
4836
4839
|
function ButtonFileUpload(props) {
|
|
4837
|
-
var
|
|
4838
|
-
|
|
4839
|
-
var isAllowedFileType = function
|
|
4840
|
+
var _props$inputProps;
|
|
4841
|
+
var id = useMemo(getUniqueKey, []);
|
|
4842
|
+
var isAllowedFileType = useCallback(function (fileName) {
|
|
4840
4843
|
var extension = fileName.replace(/^(.)*(\..+)$/, '$2').toLowerCase();
|
|
4841
4844
|
if (props.allowedFileTypes && props.allowedFileTypes.length) {
|
|
4842
4845
|
if (props.allowedFileTypes.indexOf(extension) > -1) {
|
|
4843
4846
|
return true;
|
|
4844
|
-
} else if (props.allowedFileTypes.indexOf(
|
|
4847
|
+
} else if (props.allowedFileTypes.indexOf(FileTypes.ALL_IMAGES) > -1 && Object.values(ImageTypes).indexOf(extension) > -1) {
|
|
4845
4848
|
return true;
|
|
4846
4849
|
} else {
|
|
4847
4850
|
return false;
|
|
4848
4851
|
}
|
|
4849
4852
|
}
|
|
4850
4853
|
return true;
|
|
4851
|
-
};
|
|
4852
|
-
var
|
|
4853
|
-
|
|
4854
|
+
}, [props.allowedFileTypes]);
|
|
4855
|
+
var buttonProps = useMemo(function () {
|
|
4856
|
+
return _extends({
|
|
4854
4857
|
theme: props.theme,
|
|
4855
4858
|
onClick: function onClick() {
|
|
4856
4859
|
var hiddenInput = document.querySelector("#" + id + " input");
|
|
@@ -4862,12 +4865,12 @@ function ButtonFileUpload(props) {
|
|
|
4862
4865
|
leftIcon: props.leftIcon,
|
|
4863
4866
|
w100: props.w100
|
|
4864
4867
|
}, props.buttonProps);
|
|
4865
|
-
|
|
4866
|
-
};
|
|
4868
|
+
}, [id, props.buttonProps, props.disabled, props.leftIcon, props.theme, props.w100]);
|
|
4867
4869
|
return React$1.createElement("div", {
|
|
4868
4870
|
className: getMergedClassNames([rootClassName$1H, props.w100 ? 'w100' : '']),
|
|
4869
4871
|
id: id
|
|
4870
|
-
}, React$1.createElement("input", {
|
|
4872
|
+
}, React$1.createElement("input", Object.assign({
|
|
4873
|
+
hidden: true,
|
|
4871
4874
|
type: 'file',
|
|
4872
4875
|
accept: props.allowedFileTypes ? Array(props.allowedFileTypes).join(', ') : undefined,
|
|
4873
4876
|
tabIndex: -1,
|
|
@@ -4882,9 +4885,11 @@ function ButtonFileUpload(props) {
|
|
|
4882
4885
|
return !props.allowedFileTypes || !props.allowedFileTypes.length || isAllowedFileType(file.name);
|
|
4883
4886
|
});
|
|
4884
4887
|
if (props.multiple) {
|
|
4885
|
-
|
|
4888
|
+
var _props$onChange;
|
|
4889
|
+
(_props$onChange = props.onChange) === null || _props$onChange === void 0 ? void 0 : _props$onChange.call(props, filteredFiles);
|
|
4886
4890
|
} else {
|
|
4887
|
-
|
|
4891
|
+
var _props$onChange2;
|
|
4892
|
+
(_props$onChange2 = props.onChange) === null || _props$onChange2 === void 0 ? void 0 : _props$onChange2.call(props, filteredFiles[0]);
|
|
4888
4893
|
}
|
|
4889
4894
|
var hiddenInput = document.querySelector("#" + id + " input");
|
|
4890
4895
|
if (hiddenInput) {
|
|
@@ -4892,7 +4897,7 @@ function ButtonFileUpload(props) {
|
|
|
4892
4897
|
}
|
|
4893
4898
|
},
|
|
4894
4899
|
multiple: props.multiple
|
|
4895
|
-
}), React$1.createElement(Button$1, Object.assign({},
|
|
4900
|
+
}, (_props$inputProps = props.inputProps) != null ? _props$inputProps : {})), React$1.createElement(Button$1, Object.assign({}, buttonProps), props.label));
|
|
4896
4901
|
}
|
|
4897
4902
|
ButtonFileUpload.defaultProps = {
|
|
4898
4903
|
label: 'Escolher arquivo',
|
|
@@ -7305,7 +7310,7 @@ function DatePickerCalendar(props) {
|
|
|
7305
7310
|
},
|
|
7306
7311
|
key: index,
|
|
7307
7312
|
className: getMergedClassNames(['day', day.getFullYear() === today.getFullYear() && day.getMonth() === today.getMonth() && day.getDate() === today.getDate() ? 'today' : '', props.value && day.getFullYear() === ((_stringToDate = stringToDate(props.value)) === null || _stringToDate === void 0 ? void 0 : _stringToDate.getFullYear()) && day.getMonth() === ((_stringToDate2 = stringToDate(props.value)) === null || _stringToDate2 === void 0 ? void 0 : _stringToDate2.getMonth()) && day.getDate() === ((_stringToDate3 = stringToDate(props.value)) === null || _stringToDate3 === void 0 ? void 0 : _stringToDate3.getDate()) ? 'selected' : '']),
|
|
7308
|
-
disabled: day.getMonth() !== month
|
|
7313
|
+
disabled: day.getMonth() !== month || props.disabled
|
|
7309
7314
|
}, day.getDate());
|
|
7310
7315
|
})))));
|
|
7311
7316
|
}
|
|
@@ -7415,6 +7420,7 @@ function DatePicker(props) {
|
|
|
7415
7420
|
}
|
|
7416
7421
|
}
|
|
7417
7422
|
}) : undefined, React$1.createElement(IconButton$1, {
|
|
7423
|
+
disabled: props.disabled,
|
|
7418
7424
|
icon: React$1.createElement(CalendarIcon, null),
|
|
7419
7425
|
onClick: function onClick() {
|
|
7420
7426
|
setOpened(!opened);
|
|
@@ -7429,6 +7435,7 @@ function DatePicker(props) {
|
|
|
7429
7435
|
className: rootClassName$1W + "-panel"
|
|
7430
7436
|
}, React$1.createElement(DatePickerCalendar$1, {
|
|
7431
7437
|
language: props.language,
|
|
7438
|
+
disabled: props.disabled,
|
|
7432
7439
|
value: value,
|
|
7433
7440
|
onChange: function onChange(date) {
|
|
7434
7441
|
setValue(date);
|
|
@@ -7522,14 +7529,54 @@ function DropdownItem(props) {
|
|
|
7522
7529
|
}
|
|
7523
7530
|
var DropdownItem$1 = memo(DropdownItem);
|
|
7524
7531
|
|
|
7532
|
+
function useOutsideClick(refs, handler, options) {
|
|
7533
|
+
var _options3;
|
|
7534
|
+
if (options === void 0) {
|
|
7535
|
+
options = {
|
|
7536
|
+
events: ['mouseup', 'touchstart']
|
|
7537
|
+
};
|
|
7538
|
+
}
|
|
7539
|
+
var handleClickOutside = useCallback(function (e) {
|
|
7540
|
+
var isInside = refs.some(function (r) {
|
|
7541
|
+
return (r === null || r === void 0 ? void 0 : r.current) && r.current.contains(e.target);
|
|
7542
|
+
});
|
|
7543
|
+
handler(isInside);
|
|
7544
|
+
}, [handler, refs]);
|
|
7545
|
+
useEffect(function () {
|
|
7546
|
+
var _options;
|
|
7547
|
+
(_options = options) === null || _options === void 0 ? void 0 : _options.events.forEach(function (evt) {
|
|
7548
|
+
document.addEventListener(evt, handleClickOutside);
|
|
7549
|
+
});
|
|
7550
|
+
return function () {
|
|
7551
|
+
var _options2;
|
|
7552
|
+
(_options2 = options) === null || _options2 === void 0 ? void 0 : _options2.events.forEach(function (evt) {
|
|
7553
|
+
document.removeEventListener(evt, handleClickOutside);
|
|
7554
|
+
});
|
|
7555
|
+
};
|
|
7556
|
+
}, [refs, handler, handleClickOutside, (_options3 = options) === null || _options3 === void 0 ? void 0 : _options3.events]);
|
|
7557
|
+
}
|
|
7558
|
+
|
|
7559
|
+
var _excluded = ["opened", "setOpened", "content", "closeOnEsc", "closeOnOutClick", "children", "panelProps"];
|
|
7525
7560
|
var rootClassName$1Z = 'component-dropdown-menu';
|
|
7526
|
-
function DropdownMenu(
|
|
7561
|
+
function DropdownMenu(_ref) {
|
|
7562
|
+
var _panelProps$className;
|
|
7563
|
+
var opened = _ref.opened,
|
|
7564
|
+
setOpened = _ref.setOpened,
|
|
7565
|
+
content = _ref.content,
|
|
7566
|
+
closeOnEsc = _ref.closeOnEsc,
|
|
7567
|
+
closeOnOutClick = _ref.closeOnOutClick,
|
|
7568
|
+
children = _ref.children,
|
|
7569
|
+
_ref$panelProps = _ref.panelProps,
|
|
7570
|
+
panelProps = _ref$panelProps === void 0 ? {} : _ref$panelProps,
|
|
7571
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
7527
7572
|
var id = useMemo(function () {
|
|
7528
7573
|
return props.id ? props.id : getUniqueKey();
|
|
7529
7574
|
}, [props.id]);
|
|
7530
7575
|
var _useState = useState(null),
|
|
7531
7576
|
inter = _useState[0],
|
|
7532
7577
|
setInter = _useState[1];
|
|
7578
|
+
var wrapperRef = createRef();
|
|
7579
|
+
var panelRef = createRef();
|
|
7533
7580
|
var interRef = useRef(inter);
|
|
7534
7581
|
interRef.current = inter;
|
|
7535
7582
|
useEffect(function () {
|
|
@@ -7563,7 +7610,7 @@ function DropdownMenu(props) {
|
|
|
7563
7610
|
}
|
|
7564
7611
|
}
|
|
7565
7612
|
};
|
|
7566
|
-
if (
|
|
7613
|
+
if (opened) {
|
|
7567
7614
|
position();
|
|
7568
7615
|
var _inter = setInterval(position, 100);
|
|
7569
7616
|
setInter(_inter);
|
|
@@ -7574,72 +7621,46 @@ function DropdownMenu(props) {
|
|
|
7574
7621
|
setInter(null);
|
|
7575
7622
|
}
|
|
7576
7623
|
};
|
|
7577
|
-
}, [
|
|
7624
|
+
}, [opened]);
|
|
7625
|
+
useOutsideClick([wrapperRef], function (isInside) {
|
|
7626
|
+
if (closeOnOutClick && !isInside) {
|
|
7627
|
+
setOpened(false);
|
|
7628
|
+
}
|
|
7629
|
+
});
|
|
7578
7630
|
useEffect(function () {
|
|
7579
|
-
var onHandleClick = function onHandleClick(evt) {
|
|
7580
|
-
if (evt.path) {
|
|
7581
|
-
if (document.querySelector("#" + id + " ." + rootClassName$1Z + "-panel-fade-enter-done") && !evt.path.includes(document.querySelector("#" + id))) props.setOpened(false);
|
|
7582
|
-
} else {
|
|
7583
|
-
var aux = evt.target;
|
|
7584
|
-
var deveFechar = true;
|
|
7585
|
-
while (aux && aux.id !== 'root') {
|
|
7586
|
-
if (aux && aux.id && aux.id === id && aux.classList.contains(rootClassName$1Z)) {
|
|
7587
|
-
deveFechar = false;
|
|
7588
|
-
break;
|
|
7589
|
-
}
|
|
7590
|
-
aux = aux.parentElement;
|
|
7591
|
-
}
|
|
7592
|
-
if (deveFechar) {
|
|
7593
|
-
props.setOpened(false);
|
|
7594
|
-
}
|
|
7595
|
-
}
|
|
7596
|
-
};
|
|
7597
7631
|
var onEscPress = function onEscPress(evt) {
|
|
7598
7632
|
if (evt.key === 'Escape') {
|
|
7599
|
-
|
|
7633
|
+
setOpened(false);
|
|
7600
7634
|
}
|
|
7601
7635
|
};
|
|
7602
|
-
if (
|
|
7603
|
-
if (
|
|
7604
|
-
document.addEventListener('mousedown', onHandleClick);
|
|
7605
|
-
} else {
|
|
7606
|
-
document.removeEventListener('mousedown', onHandleClick);
|
|
7607
|
-
}
|
|
7608
|
-
}
|
|
7609
|
-
if (props.closeOnEsc) {
|
|
7610
|
-
if (props.opened) {
|
|
7636
|
+
if (closeOnEsc) {
|
|
7637
|
+
if (opened) {
|
|
7611
7638
|
document.addEventListener('keyup', onEscPress);
|
|
7612
7639
|
} else {
|
|
7613
7640
|
document.removeEventListener('keyup', onEscPress);
|
|
7614
7641
|
}
|
|
7615
7642
|
}
|
|
7616
7643
|
return function () {
|
|
7617
|
-
document.removeEventListener('click', onHandleClick);
|
|
7618
7644
|
document.removeEventListener('keyup', onEscPress);
|
|
7619
7645
|
};
|
|
7620
|
-
}, [
|
|
7621
|
-
|
|
7622
|
-
|
|
7623
|
-
|
|
7624
|
-
|
|
7625
|
-
|
|
7626
|
-
|
|
7627
|
-
delete p.setOpened;
|
|
7628
|
-
delete p.content;
|
|
7629
|
-
delete p.closeOnOutClick;
|
|
7630
|
-
delete p.closeOnEsc;
|
|
7631
|
-
return p;
|
|
7632
|
-
};
|
|
7633
|
-
return React$1.createElement("div", Object.assign({}, getProps()), React$1.createElement("div", {
|
|
7646
|
+
}, [opened]);
|
|
7647
|
+
return React$1.createElement("div", Object.assign({
|
|
7648
|
+
ref: wrapperRef
|
|
7649
|
+
}, props, {
|
|
7650
|
+
id: id,
|
|
7651
|
+
className: [rootClassName$1Z, props.className || ''].join(' ')
|
|
7652
|
+
}), React$1.createElement("div", {
|
|
7634
7653
|
className: rootClassName$1Z + "-children"
|
|
7635
|
-
},
|
|
7636
|
-
"in":
|
|
7654
|
+
}, children), React$1.createElement(CSSTransition, {
|
|
7655
|
+
"in": opened,
|
|
7637
7656
|
timeout: 300,
|
|
7638
7657
|
classNames: rootClassName$1Z + "-panel-fade",
|
|
7639
7658
|
unmountOnExit: true
|
|
7640
|
-
}, React$1.createElement("div", {
|
|
7641
|
-
|
|
7642
|
-
},
|
|
7659
|
+
}, React$1.createElement("div", Object.assign({
|
|
7660
|
+
ref: panelRef
|
|
7661
|
+
}, panelProps, {
|
|
7662
|
+
className: [rootClassName$1Z + "-panel scroll-white", (_panelProps$className = panelProps === null || panelProps === void 0 ? void 0 : panelProps.className) != null ? _panelProps$className : ''].join(' ')
|
|
7663
|
+
}), content)));
|
|
7643
7664
|
}
|
|
7644
7665
|
DropdownMenu.defaultProps = {
|
|
7645
7666
|
closeOnOutClick: true,
|
|
@@ -8024,7 +8045,7 @@ function FileUpload(props) {
|
|
|
8024
8045
|
if (props.allowedFileTypes && props.allowedFileTypes.length) {
|
|
8025
8046
|
if (props.allowedFileTypes.indexOf(extension) > -1) {
|
|
8026
8047
|
return true;
|
|
8027
|
-
} else if (props.allowedFileTypes.indexOf(
|
|
8048
|
+
} else if (props.allowedFileTypes.indexOf(FileTypes.ALL_IMAGES) > -1 && Object.values(ImageTypes).indexOf(extension) > -1) {
|
|
8028
8049
|
return true;
|
|
8029
8050
|
} else {
|
|
8030
8051
|
return false;
|
|
@@ -9088,7 +9109,7 @@ function Paginator(props) {
|
|
|
9088
9109
|
}
|
|
9089
9110
|
Paginator.defaultProps = {};
|
|
9090
9111
|
|
|
9091
|
-
var _excluded = ["boundaryCount", "count", "currentPage", "disabled", "hideNextButton", "hidePrevButton", "onChange", "page", "siblingCount", "maxLength"];
|
|
9112
|
+
var _excluded$1 = ["boundaryCount", "count", "currentPage", "disabled", "hideNextButton", "hidePrevButton", "onChange", "page", "siblingCount", "maxLength"];
|
|
9092
9113
|
function usePagination(props) {
|
|
9093
9114
|
if (props === void 0) {
|
|
9094
9115
|
props = {};
|
|
@@ -9111,7 +9132,7 @@ function usePagination(props) {
|
|
|
9111
9132
|
_props$siblingCount = _props.siblingCount,
|
|
9112
9133
|
siblingCount = _props$siblingCount === void 0 ? 1 : _props$siblingCount,
|
|
9113
9134
|
maxLength = _props.maxLength,
|
|
9114
|
-
other = _objectWithoutPropertiesLoose(_props, _excluded);
|
|
9135
|
+
other = _objectWithoutPropertiesLoose(_props, _excluded$1);
|
|
9115
9136
|
var isControlledRef = useRef(pageProp !== undefined);
|
|
9116
9137
|
var _useState = useState(currentPage),
|
|
9117
9138
|
pageCurrent = _useState[0],
|
|
@@ -9250,7 +9271,7 @@ function useScreenSize() {
|
|
|
9250
9271
|
return value;
|
|
9251
9272
|
}
|
|
9252
9273
|
|
|
9253
|
-
var _excluded$
|
|
9274
|
+
var _excluded$2 = ["page", "type", "selected"];
|
|
9254
9275
|
var rootClassName$2k = 'pagination-component';
|
|
9255
9276
|
var Pagination = function Pagination(props) {
|
|
9256
9277
|
var screenSize = useScreenSize();
|
|
@@ -9374,7 +9395,7 @@ var Pagination = function Pagination(props) {
|
|
|
9374
9395
|
var page = _ref2.page,
|
|
9375
9396
|
type = _ref2.type,
|
|
9376
9397
|
selected = _ref2.selected,
|
|
9377
|
-
item = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
9398
|
+
item = _objectWithoutPropertiesLoose(_ref2, _excluded$2);
|
|
9378
9399
|
var children = null;
|
|
9379
9400
|
if (type === 'start-ellipsis' || type === 'end-ellipsis') {
|
|
9380
9401
|
children = React$1.createElement("li", {
|
|
@@ -9687,30 +9708,6 @@ function Chip(props) {
|
|
|
9687
9708
|
}
|
|
9688
9709
|
var Chip$1 = memo(Chip);
|
|
9689
9710
|
|
|
9690
|
-
function useOutsideClick(refs, handler) {
|
|
9691
|
-
var handleClickOutside = useCallback(function (e) {
|
|
9692
|
-
if (refs && 'current' in refs && refs.current) {
|
|
9693
|
-
var isInside = Array.isArray(refs.current) ? refs.current.some(function (element) {
|
|
9694
|
-
return !!element && element.contains(e.target);
|
|
9695
|
-
}) : !!refs && !!refs.current && refs.current.contains(e.target);
|
|
9696
|
-
handler(isInside);
|
|
9697
|
-
} else {
|
|
9698
|
-
var _isInside = Array.isArray(refs) && refs.some(function (element) {
|
|
9699
|
-
return !!element && !!element.current && element.current.contains(e.target);
|
|
9700
|
-
});
|
|
9701
|
-
handler(_isInside);
|
|
9702
|
-
}
|
|
9703
|
-
}, [handler, refs]);
|
|
9704
|
-
useEffect(function () {
|
|
9705
|
-
document.addEventListener('mouseup', handleClickOutside);
|
|
9706
|
-
document.addEventListener('touchstart', handleClickOutside);
|
|
9707
|
-
return function () {
|
|
9708
|
-
document.removeEventListener('mouseup', handleClickOutside);
|
|
9709
|
-
document.removeEventListener('touchstart', handleClickOutside);
|
|
9710
|
-
};
|
|
9711
|
-
}, [refs, handler, handleClickOutside]);
|
|
9712
|
-
}
|
|
9713
|
-
|
|
9714
9711
|
var rootClassName$2p = 'component-search';
|
|
9715
9712
|
function Search(props) {
|
|
9716
9713
|
var _wrapperRef$current;
|
|
@@ -9733,11 +9730,11 @@ function Search(props) {
|
|
|
9733
9730
|
var _useState7 = useState(false),
|
|
9734
9731
|
showResults = _useState7[0],
|
|
9735
9732
|
setShowResults = _useState7[1];
|
|
9736
|
-
var wrapperRef =
|
|
9733
|
+
var wrapperRef = createRef();
|
|
9737
9734
|
var handleClickOutside = function handleClickOutside(e) {
|
|
9738
9735
|
if (!e) setShowResults(false);
|
|
9739
9736
|
};
|
|
9740
|
-
useOutsideClick(wrapperRef, handleClickOutside);
|
|
9737
|
+
useOutsideClick([wrapperRef], handleClickOutside);
|
|
9741
9738
|
var onEsc = function onEsc(evt) {
|
|
9742
9739
|
if (evt.key === 'Escape') {
|
|
9743
9740
|
setShowResults(false);
|
|
@@ -11170,13 +11167,13 @@ TextEditorColorPicker.defaultProps = {
|
|
|
11170
11167
|
onChange: function onChange() {}
|
|
11171
11168
|
};
|
|
11172
11169
|
|
|
11173
|
-
var _excluded$
|
|
11170
|
+
var _excluded$3 = ["icon", "active"];
|
|
11174
11171
|
var rootClassName$2B = 'text-editor-header-button';
|
|
11175
11172
|
function TextEditorHeaderButton(_ref) {
|
|
11176
11173
|
var _props$className;
|
|
11177
11174
|
var icon = _ref.icon,
|
|
11178
11175
|
active = _ref.active,
|
|
11179
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
11176
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$3);
|
|
11180
11177
|
return React$1.createElement("button", Object.assign({
|
|
11181
11178
|
className: getMergedClassNames([rootClassName$2B, active ? 'active' : '', (_props$className = props.className) != null ? _props$className : ''])
|
|
11182
11179
|
}, props), icon);
|
|
@@ -44340,6 +44337,7 @@ var IconButtonType;
|
|
|
44340
44337
|
(function (IconButtonType) {
|
|
44341
44338
|
IconButtonType["Primary"] = "primary";
|
|
44342
44339
|
IconButtonType["Secondary"] = "secondary";
|
|
44340
|
+
IconButtonType["Gray"] = "gray";
|
|
44343
44341
|
IconButtonType["Dark"] = "dark";
|
|
44344
44342
|
IconButtonType["Blue"] = "blue";
|
|
44345
44343
|
})(IconButtonType || (IconButtonType = {}));
|
|
@@ -44370,5 +44368,5 @@ var getStatusClassName = function getStatusClassName(status) {
|
|
|
44370
44368
|
};
|
|
44371
44369
|
var STATUS_PAUTA = [STATUS_PAUTA_BLOQUEADA, STATUS_PAUTA_LIBERADA, STATUS_PAUTA_ENCERRADA];
|
|
44372
44370
|
|
|
44373
|
-
export { ATMIcon, Accordion, AconteceuIcon, ActionCard$1 as ActionCard, ActionCardThemes, ActionsColumn, AddAssemblyIcon, AddIcon as AddCircleIcon, AddIcon, AgencyIcon, AlertModal, AlignCenterIcon, AlignJustifyIcon, AlignLeftIcon, AlignRightIcon, AnimatedLink$1 as AnimatedLink, ArrowLeftIcon, ArrowRightIcon, AssembleiasIcon, BackOfficeIcon, Banner, BarChartIcon, BeeIcon, BigBlockButton, BigPlayIcon,
|
|
44371
|
+
export { ATMIcon, Accordion, AconteceuIcon, ActionCard$1 as ActionCard, ActionCardThemes, ActionsColumn, AddAssemblyIcon, AddIcon as AddCircleIcon, AddIcon, AgencyIcon, AlertModal, AlignCenterIcon, AlignJustifyIcon, AlignLeftIcon, AlignRightIcon, AnimatedLink$1 as AnimatedLink, ArrowLeftIcon, ArrowRightIcon, AssembleiasIcon, BackOfficeIcon, Banner, BarChartIcon, BeeIcon, BigBlockButton, BigPlayIcon, BoldIcon, BottomNavigation$1 as BottomNavigation, BreadCrumb, Button$1 as Button, ButtonFileUpload$1 as ButtonFileUpload, ButtonThemes, Calendar$1 as Calendar, CalendarCheckIcon, CalendarEvent$1 as CalendarEvent, CalendarIcon, Card, CardTypes, CardsIcon, Carousel, CarouselPersona$1 as CarouselPersona, CarouselTouchFrendly$1 as CarouselTouchFrendly, CataventoVerde, CheckCircleIcon, CheckIcon, Checkbox$1 as Checkbox, CheckboxThemes, ChequeIcon, ChevronArrowDownIcon, ChevronArrowLeftIcon, ChevronArrowRightIcon, Chip$1 as Chip, CircleArrowLeft, CircleArrowRight, ClockIcon, CloseIcon, CloudDownloadIcon, CloudUploadIcon, Col$1 as Col, Collapse$1 as Collapse, ComitesIcon, ComunidadeIcon, ConfirmModal, Container$1 as Container, ControlLabel$1 as ControlLabel, ControlLabelPosition, CopyIcon, CreditIcon, CrescerIcon, CrescerLogo, DatePicker$1 as DatePicker, DestructiveModal, DevicePlusIcon, Doughnut$1 as Doughnut, DoughnutSquare, DownloadIcon, DraggableIcon, DropdownItem$1 as DropdownItem, DropdownMenu, DropdownSelector$1 as DropdownSelector, EditIcon, ElementPaginator$1 as ElementPaginator, Etapas$1 as Etapas, Etiqueta, EtiquetasStyle, EvidenciasIcon, ExclamationIcon, ExitIconArrowLeft, ExitIconArrowRight, EyeIcon, FUNDACAO_LOGO_BRANCO, FUNDACAO_LOGO_VERDE, FileLoader, FilePlusIcon, FileTypes, FileUpload, FilesIcon, FilterIcon, FloatingPanel$1 as FloatingPanel, FontColorIcon, FontIcon, FooterSicredi$1 as FooterSicredi, FormacaoIcon, FormattedText, FullHeightContainer$1 as FullHeightContainer, FundacaoLogo, FundacaoLogoTheme, FundoSocialIcon, GlobeIcon, GraduationIcon, HEADER_SEPARATOR_PRIMARY, HEADER_SEPARATOR_SECONDARY, HamburgerIcon, HandUpIcon, Header$1 as Header, HeaderSeparator, HeaderType, HomeIcon, HourEvents$1 as HourEvents, IconButton$1 as IconButton, IconButtonType, ImageTypes, Information, InformationIcon, InlineMonthPicker$1 as InlineMonthPicker, Input$1 as Input, InputArea$1 as InputArea, InvestimentIcon, ItalicIcon, ItemDropdownDownload$1 as ItemDropdownDownload, LeftControlWithLabel as LeftCheckboxWithLabel, LeftControlWithLabel, LinkIcon, LinksUteisIcon, ListDotIcon, ListIcon, LoaderIcon, LocalIcon, LockIcon, Menu$1 as Menu, MenuItem, MessageIcon, Modal, ModalManager, ModalSizes, MoneyByMonth, MoneyFileIcon, MoneyMonthLineChart, NavigatorWithMouse, NotebookIcon, Notification, NotificationPosition, NotificationType, OptionsIcon, PageSubTitle, PageTitle, Pagination, Paginator, ParticipantesIcon, PaymentIcon, PercentLoaderIcon, PhonePlusIcon, PieChartIcon, PlayIcon, PreviaVideo$1 as PreviaVideo, PrintIcon, QRCode$1 as QRCode, QRCodeIcon, QRCodeWhatsapp, RadioButton$1 as RadioButton, RadioButtonType, RedoIcon, RefreshIcon, Row$1 as Row, STATUS_PAUTA, STATUS_PAUTA_BLOQUEADA, STATUS_PAUTA_ENCERRADA, STATUS_PAUTA_LIBERADA, ScrollArrowOverflow$1 as ScrollArrowOverflow, Search$1 as Search, SearchIcon, Select$1 as Select, SettingsIcon, SicrediLogo, SicrediLogoTheme, SquaresIcon, SustentabilidadeIcon, Switch, Table, TableActions, TableFileNameAndAction$1 as TableFileNameAndAction, TableWithOverflow$1 as TableWithOverflow, Tabs$1 as Tabs, TextEditor, ThreeDotsLoader, ThumbsUpIcon, TimesCircleIcon, Title, Toast, ToastManager, ToastTypes, Tooltip, TooltipManager, TooltipPosition, TopLoader, TransferenciaIcon, TrashIcon, TrianguloInferior, TwoFileIcon, TypedTable, UnderlineIcon, UndoIcon, UserIcon, VideoModal, VideoPlayer, WebsiteIcon, getStatusClassName, stringToReactElement, useCallbackedState, useCarouselBehaviour, useControlledTimer, useDraggableContainer, useDropOpened, useHTMLShare, useModalManager, useOutsideClick, usePagination, useProgressiveCount, usePublicMenuList, useScreenSize, useScrollTo, useStorageState, useTimeElapsed, useToastManager, useValidatedState };
|
|
44374
44372
|
//# sourceMappingURL=index.modern.js.map
|