@grazziotin/react-components 1.0.0 → 1.0.2
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/README.md +55 -1
- package/dist/components/Dialog/Dialog.stories.d.ts +9 -0
- package/dist/components/Dialog/Dialog.stories.js +80 -0
- package/dist/components/Dialog/index.d.ts +12 -0
- package/dist/components/Dialog/index.js +10 -0
- package/dist/components/Filter/Filter.stories.d.ts +8 -0
- package/dist/components/Filter/Filter.stories.js +85 -0
- package/dist/components/Filter/components/FiltroCard.d.ts +3 -0
- package/dist/components/Filter/components/FiltroCard.js +13 -0
- package/dist/components/Filter/components/Filtros.d.ts +3 -0
- package/dist/components/Filter/components/Filtros.js +59 -0
- package/dist/components/Filter/components/InputSelect.d.ts +3 -0
- package/dist/components/Filter/components/InputSelect.js +13 -0
- package/dist/components/Filter/index.d.ts +10 -0
- package/dist/components/Filter/index.js +20 -0
- package/dist/components/Filter/utils/interface.d.ts +76 -0
- package/dist/components/Filter/utils/interface.js +1 -0
- package/dist/components/Inputs/Input/Input.stories.d.ts +13 -0
- package/dist/components/Inputs/Input/Input.stories.js +99 -0
- package/dist/components/Inputs/InputSelectMultiple/index.d.ts +22 -0
- package/dist/components/Inputs/InputSelectMultiple/index.js +38 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +1 -2
- package/dist/index.js.LICENSE.txt +1 -20
- package/dist/theme.css +500 -0
- package/package.json +42 -165
- package/.editorconfig +0 -13
- package/.eslintignore +0 -3
- package/.eslintrc.json +0 -16
- package/.prettierrc +0 -6
- package/.vscode/settings.json +0 -18
- package/src/components/Inputs/Input/constants.ts +0 -25
- package/src/components/Inputs/Input/index.tsx +0 -94
- package/src/env.d.ts +0 -16
- package/src/functions/mascaras/index.ts +0 -432
- package/src/hooks/index.ts +0 -60
- package/src/index.tsx +0 -2
- package/src/lib/utils.ts +0 -6
- package/src/styles/sx.ts +0 -148
- package/tailwind.config.js +0 -234
- package/tsconfig.json +0 -37
- package/webpack.config.js +0 -32
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
13
|
+
var t = {};
|
|
14
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
15
|
+
t[p] = s[p];
|
|
16
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
17
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
18
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
19
|
+
t[p[i]] = s[p[i]];
|
|
20
|
+
}
|
|
21
|
+
return t;
|
|
22
|
+
};
|
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
24
|
+
import Autocomplete from '@mui/material/Autocomplete';
|
|
25
|
+
import { sxTextField } from 'src/styles/sx';
|
|
26
|
+
import Input from '../Input';
|
|
27
|
+
/**
|
|
28
|
+
* Componente de selects múltiplos, serve para quando temos listas grandes para tratar.
|
|
29
|
+
* @version 1.5.0
|
|
30
|
+
* @ViniciusCLoeblein
|
|
31
|
+
*/
|
|
32
|
+
function InputSelectMultiple(_a) {
|
|
33
|
+
var className = _a.className, textFieldProps = _a.textFieldProps, optionLabel = _a.optionLabel, _b = _a.disablePortal, disablePortal = _b === void 0 ? true : _b, rest = __rest(_a, ["className", "textFieldProps", "optionLabel", "disablePortal"]);
|
|
34
|
+
return (_jsx("div", { className: className, children: _jsx(Autocomplete, __assign({ disablePortal: disablePortal, sx: sxTextField, filterSelectedOptions: true, getOptionLabel: function (data) {
|
|
35
|
+
return typeof data !== 'string' ? optionLabel(data) : 'Não há dados';
|
|
36
|
+
} }, rest, { renderInput: function (params) { return _jsx(Input, __assign({}, params, textFieldProps)); } })) }));
|
|
37
|
+
}
|
|
38
|
+
export default InputSelectMultiple;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,8 @@
|
|
|
1
1
|
export { default as Input } from './components/Inputs/Input';
|
|
2
2
|
export type { InputProps } from './components/Inputs/Input';
|
|
3
|
+
export { default as InputSelectMultiple } from './components/Inputs/InputSelectMultiple';
|
|
4
|
+
export type { InputSelectMultipleProps, CustomAutocompleteProps, } from './components/Inputs/InputSelectMultiple';
|
|
5
|
+
export { default as Dialog } from './components/Dialog';
|
|
6
|
+
export type { DialogProps } from './components/Dialog';
|
|
7
|
+
export { default as Filtro } from './components/Filter';
|
|
8
|
+
export type { FiltroProps, CsvProps, InputSelectOption, InputSelectProps, } from './components/Filter';
|