plataforma-fundacao-componentes 2.23.19 → 2.23.20
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/chip/Chip.d.ts +1 -0
- package/dist/components/menu/Menu.d.ts +1 -0
- package/dist/components/menu/Menu.stories.d.ts +12 -13
- package/dist/components/menu/components/menuItem/MenuItem.d.ts +1 -1
- package/dist/components/row/Row.d.ts +1 -0
- package/dist/index.css +10 -3
- package/dist/index.js +45 -36
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +45 -36
- package/dist/index.modern.js.map +1 -1
- package/dist/libraries/EtiquetasThemes.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare const _default: {
|
|
3
|
+
title: string;
|
|
4
|
+
};
|
|
5
5
|
export default _default;
|
|
6
|
-
export
|
|
7
|
-
export
|
|
8
|
-
export
|
|
9
|
-
export
|
|
10
|
-
export
|
|
11
|
-
export
|
|
12
|
-
export
|
|
13
|
-
export
|
|
14
|
-
import Menu from "./Menu";
|
|
6
|
+
export declare const Normal: () => JSX.Element;
|
|
7
|
+
export declare const WithSemiHeader: () => JSX.Element;
|
|
8
|
+
export declare const ProgramsAndCollapse: () => JSX.Element;
|
|
9
|
+
export declare const ShortOnMD: () => JSX.Element;
|
|
10
|
+
export declare const OpenOnClick: () => JSX.Element;
|
|
11
|
+
export declare const HamburgerMenuGreen: () => JSX.Element;
|
|
12
|
+
export declare const HamburgerMenuWhite: () => JSX.Element;
|
|
13
|
+
export declare const HamburgerMenuAndLoading: () => JSX.Element;
|
package/dist/index.css
CHANGED
|
@@ -2623,12 +2623,12 @@ h5 {
|
|
|
2623
2623
|
.component-checkbox-classic {
|
|
2624
2624
|
border-radius: 0;
|
|
2625
2625
|
background-color: rgba(0, 0, 0, 0);
|
|
2626
|
-
border:
|
|
2626
|
+
border: 1px solid #3fa110; }
|
|
2627
2627
|
.component-checkbox-classic::after {
|
|
2628
2628
|
content: '';
|
|
2629
2629
|
position: absolute;
|
|
2630
|
-
width:
|
|
2631
|
-
height:
|
|
2630
|
+
width: 12px;
|
|
2631
|
+
height: 12px;
|
|
2632
2632
|
background-color: rgba(0, 0, 0, 0);
|
|
2633
2633
|
transition: background-color 0.3s ease; }
|
|
2634
2634
|
.component-checkbox-classic:disabled, .component-checkbox-classic[aria-disabled='true'] {
|
|
@@ -5156,6 +5156,11 @@ max-width 100% 540px 720px 960px 1140px
|
|
|
5156
5156
|
color: #2b517b;
|
|
5157
5157
|
border-color: #2b517b; }
|
|
5158
5158
|
|
|
5159
|
+
.component-etiqueta.outline-dark {
|
|
5160
|
+
background-color: rgba(0, 0, 0, 0);
|
|
5161
|
+
color: #323c32;
|
|
5162
|
+
border-color: #323c32; }
|
|
5163
|
+
|
|
5159
5164
|
.component-etiqueta.outline-warning-dark {
|
|
5160
5165
|
background-color: rgba(0, 0, 0, 0);
|
|
5161
5166
|
color: #765f00;
|
|
@@ -5501,6 +5506,8 @@ max-width 100% 540px 720px 960px 1140px
|
|
|
5501
5506
|
.component-row.centralized {
|
|
5502
5507
|
justify-content: center;
|
|
5503
5508
|
align-items: center; }
|
|
5509
|
+
.component-row.column {
|
|
5510
|
+
flex-direction: column; }
|
|
5504
5511
|
|
|
5505
5512
|
:export {
|
|
5506
5513
|
widthXs: 575.98px;
|
package/dist/index.js
CHANGED
|
@@ -9175,6 +9175,7 @@ var Etapas$1 = React.memo(Etapas);
|
|
|
9175
9175
|
EtiquetasStyle["Cancelado"] = "cancelado";
|
|
9176
9176
|
EtiquetasStyle["OutlinePrimary"] = "outline-primary";
|
|
9177
9177
|
EtiquetasStyle["OutlineDanger"] = "outline-danger";
|
|
9178
|
+
EtiquetasStyle["OutlineDark"] = "outline-dark";
|
|
9178
9179
|
EtiquetasStyle["OutlineBlue"] = "outline-blue";
|
|
9179
9180
|
EtiquetasStyle["OutlineWarningDark"] = "outline-warning-dark";
|
|
9180
9181
|
})(exports.EtiquetasStyle || (exports.EtiquetasStyle = {}));
|
|
@@ -9396,10 +9397,11 @@ var rootClassName$2g = 'component-row';
|
|
|
9396
9397
|
function Row(props) {
|
|
9397
9398
|
var getProps = function getProps() {
|
|
9398
9399
|
var p = _extends({}, props, {
|
|
9399
|
-
className: getMergedClassNames([rootClassName$2g, props.centralized ? 'centralized' : '', props.className])
|
|
9400
|
+
className: getMergedClassNames([rootClassName$2g, props.centralized ? 'centralized' : '', props.columnDirection ? 'column' : '', props.className])
|
|
9400
9401
|
});
|
|
9401
9402
|
|
|
9402
9403
|
delete p.centralized;
|
|
9404
|
+
delete p.columnDirection;
|
|
9403
9405
|
return p;
|
|
9404
9406
|
};
|
|
9405
9407
|
|
|
@@ -10075,6 +10077,10 @@ MenuItem.defaultProps = {
|
|
|
10075
10077
|
var rootClassName$2t = 'component-menu';
|
|
10076
10078
|
var timeout;
|
|
10077
10079
|
|
|
10080
|
+
var format = function format(s) {
|
|
10081
|
+
return getStringWithoutSpecialChar(s).trim().toLowerCase();
|
|
10082
|
+
};
|
|
10083
|
+
|
|
10078
10084
|
function Menu(props) {
|
|
10079
10085
|
var _useState = React.useState(false),
|
|
10080
10086
|
opened = _useState[0],
|
|
@@ -10127,10 +10133,10 @@ function Menu(props) {
|
|
|
10127
10133
|
className: getMergedClassNames([rootClassName$2t, 'scroll-white', props.className, props.shortOnMD ? rootClassName$2t + "-short-on-md" : '', props.openOnClick ? rootClassName$2t + "-open-on-click" : '', props.hamburgerMenu ? rootClassName$2t + "-hamburger-menu" : '', (props.openOnClick || props.hamburgerMenu) && (props.opened !== undefined ? openedOrNot(props.opened) : openedOrNot(opened))])
|
|
10128
10134
|
});
|
|
10129
10135
|
|
|
10136
|
+
delete p.loading;
|
|
10130
10137
|
delete p.openOnClick;
|
|
10131
10138
|
delete p.shortOnMD;
|
|
10132
10139
|
delete p.items;
|
|
10133
|
-
delete p.icon;
|
|
10134
10140
|
delete p.opened;
|
|
10135
10141
|
delete p.setOpened;
|
|
10136
10142
|
delete p.hamburgerMenu;
|
|
@@ -10148,35 +10154,20 @@ function Menu(props) {
|
|
|
10148
10154
|
}, 300);
|
|
10149
10155
|
}
|
|
10150
10156
|
}, [opened, props.opened]);
|
|
10151
|
-
|
|
10152
|
-
|
|
10153
|
-
|
|
10154
|
-
return
|
|
10155
|
-
|
|
10156
|
-
if (!it) return [];
|
|
10157
|
-
|
|
10158
|
-
if (props.buscar && buscarValue) {
|
|
10159
|
-
return it.filter(function (item) {
|
|
10160
|
-
if (getStringWithoutSpecialChar(item.label).trim().toLowerCase().match(getStringWithoutSpecialChar(buscarValue).trim().toLowerCase())) {
|
|
10161
|
-
return true;
|
|
10162
|
-
}
|
|
10163
|
-
|
|
10164
|
-
if (item.subList && Array.from(item.subList).some(function (subItem) {
|
|
10165
|
-
return getStringWithoutSpecialChar(subItem.label).trim().toLowerCase().match(getStringWithoutSpecialChar(buscarValue).trim().toLowerCase());
|
|
10166
|
-
})) {
|
|
10167
|
-
item.subList = Array.from(item.subList).filter(function (subItem) {
|
|
10168
|
-
return getStringWithoutSpecialChar(subItem.label).trim().toLowerCase().match(getStringWithoutSpecialChar(buscarValue).trim().toLowerCase());
|
|
10169
|
-
});
|
|
10170
|
-
return true;
|
|
10171
|
-
}
|
|
10172
|
-
|
|
10173
|
-
return false;
|
|
10157
|
+
var itens = React.useMemo(function () {
|
|
10158
|
+
if (!props.items) return [];
|
|
10159
|
+
return props.items.filter(function (it) {
|
|
10160
|
+
return !buscarValue || !format(buscarValue) || it.label && format(it.label).includes(format(buscarValue)) || it.subList && it.subList.some(function (subItem) {
|
|
10161
|
+
return subItem.label && format(subItem.label).includes(format(buscarValue));
|
|
10174
10162
|
});
|
|
10175
|
-
}
|
|
10176
|
-
|
|
10177
|
-
|
|
10178
|
-
|
|
10179
|
-
|
|
10163
|
+
}).map(function (it) {
|
|
10164
|
+
return !it.subList || !it.subList.length ? it : _extends({}, it, {
|
|
10165
|
+
subList: it.subList.filter(function (subItem) {
|
|
10166
|
+
return !buscarValue || !format(buscarValue) || it.label && format(it.label).includes(format(buscarValue)) || subItem.label && format(subItem.label).includes(format(buscarValue));
|
|
10167
|
+
})
|
|
10168
|
+
});
|
|
10169
|
+
});
|
|
10170
|
+
}, [buscarValue, props.items]);
|
|
10180
10171
|
return React__default.createElement(React__default.Fragment, null, React__default.createElement("div", Object.assign({}, getProps()), props.hamburgerMenu && React__default.createElement(IconButton$1, {
|
|
10181
10172
|
className: rootClassName$2t + "-close-button",
|
|
10182
10173
|
icon: React__default.createElement(CloseIcon, null),
|
|
@@ -10186,9 +10177,20 @@ function Menu(props) {
|
|
|
10186
10177
|
}
|
|
10187
10178
|
}), React__default.createElement("div", {
|
|
10188
10179
|
className: rootClassName$2t + "-logo"
|
|
10189
|
-
}, props.logo),
|
|
10180
|
+
}, props.logo), React__default.createElement(Collapse$1, {
|
|
10181
|
+
animateOpacity: true,
|
|
10182
|
+
opened: props.loading
|
|
10183
|
+
}, React__default.createElement(Col$1, {
|
|
10184
|
+
centralized: true
|
|
10185
|
+
}, React__default.createElement(ThreeDotsLoader, {
|
|
10186
|
+
size: 2
|
|
10187
|
+
}))), React__default.createElement(Collapse$1, {
|
|
10188
|
+
animateOpacity: true,
|
|
10189
|
+
opened: props.buscar && !props.loading
|
|
10190
|
+
}, React__default.createElement("div", {
|
|
10190
10191
|
className: rootClassName$2t + "-buscar"
|
|
10191
10192
|
}, React__default.createElement(Input$1, {
|
|
10193
|
+
disabled: props.loading || !props.buscar,
|
|
10192
10194
|
id: 'buscar-menu',
|
|
10193
10195
|
placeholder: 'Buscar',
|
|
10194
10196
|
value: buscarValue,
|
|
@@ -10198,9 +10200,12 @@ function Menu(props) {
|
|
|
10198
10200
|
rightObject: React__default.createElement(IconButton$1, {
|
|
10199
10201
|
icon: React__default.createElement(SearchIcon, null)
|
|
10200
10202
|
})
|
|
10201
|
-
}))
|
|
10203
|
+
}))), React__default.createElement(Collapse$1, {
|
|
10204
|
+
animateOpacity: true,
|
|
10205
|
+
opened: itens.length > 0
|
|
10206
|
+
}, React__default.createElement("div", {
|
|
10202
10207
|
className: rootClassName$2t + "-items"
|
|
10203
|
-
},
|
|
10208
|
+
}, itens.map(function (it, index) {
|
|
10204
10209
|
return React__default.createElement("div", {
|
|
10205
10210
|
className: rootClassName$2t + "-it",
|
|
10206
10211
|
key: index
|
|
@@ -10208,7 +10213,7 @@ function Menu(props) {
|
|
|
10208
10213
|
buscar: props.buscar,
|
|
10209
10214
|
buscarValue: buscarValue
|
|
10210
10215
|
})));
|
|
10211
|
-
})
|
|
10216
|
+
})))), React__default.createElement(React__default.Fragment, null, props.openOnClick && React__default.createElement("button", {
|
|
10212
10217
|
className: rootClassName$2t + "-toggle " + (opened ? rootClassName$2t + "-opened" : ''),
|
|
10213
10218
|
onClick: function onClick() {
|
|
10214
10219
|
setOpened(!opened);
|
|
@@ -40690,7 +40695,7 @@ function Chip(props) {
|
|
|
40690
40695
|
return React__default.createElement("div", {
|
|
40691
40696
|
className: useMergedClassNames([rootClassName$3b, props.w100 ? 'w100' : '', props.allClickable ? 'all-clickable' : '']),
|
|
40692
40697
|
onClick: function onClick() {
|
|
40693
|
-
if (props.allClickable && typeof props.onClick === 'function') {
|
|
40698
|
+
if (!props.disabled && props.allClickable && typeof props.onClick === 'function') {
|
|
40694
40699
|
props.onClick();
|
|
40695
40700
|
}
|
|
40696
40701
|
}
|
|
@@ -40698,7 +40703,11 @@ function Chip(props) {
|
|
|
40698
40703
|
className: 'nunito'
|
|
40699
40704
|
}, props.label), React__default.createElement("div", {
|
|
40700
40705
|
className: rootClassName$3b + "-button",
|
|
40701
|
-
onClick:
|
|
40706
|
+
onClick: function onClick() {
|
|
40707
|
+
if (!props.disabled && typeof props.onClick === 'function') {
|
|
40708
|
+
props.onClick();
|
|
40709
|
+
}
|
|
40710
|
+
}
|
|
40702
40711
|
}, React__default.createElement(TimesCircleIcon, null)));
|
|
40703
40712
|
}
|
|
40704
40713
|
|