linear-react-components-ui 1.1.24-beta.4 → 1.1.25-rc.1
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/@types/ColorStyles.d.ts +1 -2
- package/lib/@types/Position.d.ts +1 -2
- package/lib/assets/styles/calendar.scss +137 -32
- package/lib/assets/styles/colorpicker.scss +6 -1
- package/lib/assets/styles/colors.scss +12 -48
- package/lib/assets/styles/file.scss +8 -0
- package/lib/assets/styles/table.scss +6 -0
- package/lib/buttons/ActivateButton.d.ts +0 -1
- package/lib/buttons/AddButton.d.ts +0 -1
- package/lib/buttons/Button.d.ts +0 -1
- package/lib/buttons/CancelButton.d.ts +0 -1
- package/lib/buttons/DangerButton.d.ts +0 -1
- package/lib/buttons/DefaultButton.d.ts +0 -1
- package/lib/buttons/DefaultButton.js +17 -32
- package/lib/buttons/DestroyButton.d.ts +0 -1
- package/lib/buttons/EditButton.d.ts +0 -1
- package/lib/buttons/InactivateButton.d.ts +0 -1
- package/lib/buttons/InfoButton.d.ts +0 -1
- package/lib/buttons/PrimaryButton.d.ts +0 -1
- package/lib/buttons/RestoreButton.d.ts +0 -1
- package/lib/buttons/SaveButton.d.ts +0 -1
- package/lib/buttons/SuccessButton.d.ts +0 -1
- package/lib/buttons/WarningButton.d.ts +0 -1
- package/lib/buttons/index.d.ts +0 -1
- package/lib/buttons/split_button/index.d.ts +0 -1
- package/lib/buttons/types.d.ts +5 -2
- package/lib/calendar/base/index.js +113 -40
- package/lib/dialog/base/index.js +2 -2
- package/lib/form/Field.d.ts +1 -1
- package/lib/form/FieldArray.d.ts +1 -1
- package/lib/form/FieldNumber.d.ts +1 -1
- package/lib/form/FieldPeriod.d.ts +1 -1
- package/lib/form/helpers.d.ts +1 -1
- package/lib/form/index.d.ts +1 -1
- package/lib/form/types.d.ts +1 -1
- package/lib/form/withFieldHOC.d.ts +1 -1
- package/lib/form/withFormSecurity.d.ts +1 -1
- package/lib/icons/helper.d.ts +0 -20
- package/lib/icons/helper.js +0 -20
- package/lib/icons/index.d.ts +6 -4
- package/lib/icons/index.js +9 -14
- package/lib/icons/types.d.ts +6 -3
- package/lib/index.d.ts +0 -1
- package/lib/inputs/base/InputTextBase.d.ts +1 -1
- package/lib/inputs/base/InputTextBase.js +8 -18
- package/lib/inputs/base/Label.d.ts +14 -0
- package/lib/inputs/base/Label.js +35 -0
- package/lib/inputs/base/helpers.d.ts +1 -1
- package/lib/inputs/base/types.d.ts +17 -6
- package/lib/inputs/color/index.js +1 -1
- package/lib/inputs/color/types.d.ts +1 -1
- package/lib/inputs/date/Dialog.d.ts +1 -1
- package/lib/inputs/date/Dropdown.d.ts +1 -1
- package/lib/inputs/date/index.d.ts +1 -1
- package/lib/inputs/date/types.d.ts +2 -2
- package/lib/inputs/errorMessage/index.d.ts +1 -1
- package/lib/inputs/file/DefaultFile.d.ts +1 -1
- package/lib/inputs/file/DefaultFile.js +27 -27
- package/lib/inputs/file/DragDropFile.d.ts +1 -1
- package/lib/inputs/file/File.d.ts +1 -1
- package/lib/inputs/file/File.js +1 -0
- package/lib/inputs/file/FileButtonSettings.d.ts +1 -1
- package/lib/inputs/file/FileButtonSettings.js +0 -1
- package/lib/inputs/file/helpers.d.ts +1 -1
- package/lib/inputs/file/index.d.ts +1 -1
- package/lib/inputs/file/types.d.ts +1 -1
- package/lib/inputs/inputHOC.d.ts +1 -1
- package/lib/inputs/mask/BaseMask.d.ts +1 -1
- package/lib/inputs/mask/Cnpj.d.ts +1 -1
- package/lib/inputs/mask/Cpf.d.ts +1 -1
- package/lib/inputs/mask/Phone.d.ts +1 -1
- package/lib/inputs/mask/ZipCode.d.ts +1 -1
- package/lib/inputs/mask/helpers.d.ts +1 -1
- package/lib/inputs/mask/index.d.ts +1 -1
- package/lib/inputs/mask/types.d.ts +2 -2
- package/lib/inputs/multiSelect/ActionButtons.d.ts +1 -1
- package/lib/inputs/multiSelect/Dropdown.d.ts +1 -1
- package/lib/inputs/multiSelect/helper.d.ts +1 -1
- package/lib/inputs/multiSelect/index.d.ts +1 -1
- package/lib/inputs/multiSelect/types.d.ts +2 -2
- package/lib/inputs/number/BaseNumber.d.ts +1 -1
- package/lib/inputs/number/Currency.d.ts +1 -1
- package/lib/inputs/number/Decimal.d.ts +1 -1
- package/lib/inputs/number/index.d.ts +1 -1
- package/lib/inputs/number/types.d.ts +3 -3
- package/lib/inputs/period/Dialog.d.ts +1 -1
- package/lib/inputs/period/Dropdown.d.ts +1 -1
- package/lib/inputs/period/PeriodList.d.ts +1 -1
- package/lib/inputs/period/helper.d.ts +1 -1
- package/lib/inputs/period/index.d.ts +1 -1
- package/lib/inputs/period/index.js +10 -8
- package/lib/inputs/period/types.d.ts +5 -2
- package/lib/inputs/search/index.d.ts +1 -1
- package/lib/inputs/search/index.js +6 -2
- package/lib/inputs/select/ActionButtons.d.ts +1 -1
- package/lib/inputs/select/Dropdown.d.ts +1 -1
- package/lib/inputs/select/helper.d.ts +1 -1
- package/lib/inputs/select/index.d.ts +1 -1
- package/lib/inputs/select/multiple/Selecteds.d.ts +1 -1
- package/lib/inputs/select/multiple/index.d.ts +1 -1
- package/lib/inputs/select/simple/index.d.ts +1 -1
- package/lib/inputs/select/types.d.ts +1 -1
- package/lib/inputs/text/index.d.ts +1 -1
- package/lib/inputs/text/types.d.ts +3 -2
- package/lib/inputs/textarea/index.d.ts +1 -1
- package/lib/inputs/textarea/types.d.ts +1 -1
- package/lib/inputs/types.d.ts +2 -1
- package/lib/internals/types.d.ts +17 -1
- package/lib/internals/withTooltip.d.ts +12 -0
- package/lib/internals/withTooltip.js +172 -0
- package/lib/labels/DangerLabel.d.ts +0 -1
- package/lib/labels/DefaultLabel.d.ts +5 -3
- package/lib/labels/DefaultLabel.js +7 -15
- package/lib/labels/InfoLabel.d.ts +0 -1
- package/lib/labels/PrimaryLabel.d.ts +0 -1
- package/lib/labels/SuccessLabel.d.ts +0 -1
- package/lib/labels/WarningLabel.d.ts +0 -1
- package/lib/labels/index.d.ts +2 -3
- package/lib/labels/types.d.ts +5 -2
- package/lib/list/Header.d.ts +0 -1
- package/lib/list/Item.d.ts +5 -3
- package/lib/list/Item.js +12 -17
- package/lib/list/helpers.d.ts +0 -1
- package/lib/list/index.d.ts +0 -1
- package/lib/list/types.d.ts +6 -4
- package/lib/menus/sidenav/ExpandMenu.d.ts +2 -2
- package/lib/menus/sidenav/MenuLink.d.ts +7 -4
- package/lib/menus/sidenav/MenuLink.js +11 -20
- package/lib/menus/sidenav/NavMenuGroup.d.ts +2 -2
- package/lib/menus/sidenav/NavMenuItem.d.ts +7 -4
- package/lib/menus/sidenav/NavMenuItem.js +12 -16
- package/lib/menus/sidenav/NavSubMenuItem.d.ts +2 -2
- package/lib/menus/sidenav/helpers.d.ts +2 -2
- package/lib/menus/sidenav/index.d.ts +2 -2
- package/lib/menus/sidenav/popup_menu_search/EmptyList.d.ts +2 -2
- package/lib/menus/sidenav/popup_menu_search/index.d.ts +2 -2
- package/lib/menus/sidenav/types.d.ts +6 -6
- package/lib/popover/PopoverText.js +2 -11
- package/lib/popover/index.js +0 -1
- package/lib/popover/types.d.ts +0 -1
- package/lib/table/index.js +18 -8
- package/lib/table/types.d.ts +1 -0
- package/lib/textContent/index.d.ts +11 -6
- package/lib/textContent/index.js +11 -20
- package/lib/tooltip/index.d.ts +3 -4
- package/lib/tooltip/index.js +53 -36
- package/lib/tooltip/types.d.ts +3 -25
- package/package.json +2 -3
- package/lib/BaseMask-0c14ef51.d.ts +0 -24
- package/lib/Cnpj-bde01dd0.d.ts +0 -18
- package/lib/Cpf-3fa496ad.d.ts +0 -18
- package/lib/Phone-2bb0b397.d.ts +0 -18
- package/lib/ZipCode-09460e18.d.ts +0 -13
- package/lib/assets/styles/checkbox2.scss +0 -199
- package/lib/assets/styles/datepicker2.scss +0 -338
- package/lib/assets/styles/numberfield.scss +0 -18
- package/lib/assets/styles/radiofield.scss +0 -185
- package/lib/assets/styles/selectfield.scss +0 -409
- package/lib/assets/styles/slot.scss +0 -34
- package/lib/assets/styles/textfield.scss +0 -147
- package/lib/calendar/base/Day.d.ts +0 -8
- package/lib/calendar/base/Day.js +0 -36
- package/lib/calendar/base/Month.d.ts +0 -8
- package/lib/calendar/base/Month.js +0 -39
- package/lib/calendar/base/Week.d.ts +0 -8
- package/lib/calendar/base/Week.js +0 -35
- package/lib/form2/helpers.d.ts +0 -8
- package/lib/form2/helpers.js +0 -41
- package/lib/form2/index.d.ts +0 -9
- package/lib/form2/index.js +0 -36
- package/lib/form2/types.d.ts +0 -125
- package/lib/form2/types.js +0 -5
- package/lib/form2/useForm/index.d.ts +0 -5
- package/lib/form2/useForm/index.js +0 -202
- package/lib/index-368f781f.d.ts +0 -15
- package/lib/index-3b70931d.d.ts +0 -44
- package/lib/index-789dd9a5.d.ts +0 -41
- package/lib/index-7ad68789.d.ts +0 -15
- package/lib/index-9e576346.d.ts +0 -23
- package/lib/index-c512803d.d.ts +0 -23
- package/lib/index-c9247c1f.d.ts +0 -15
- package/lib/index-ecafc8c6.d.ts +0 -30
- package/lib/inputs2/checkboxfield/index.d.ts +0 -7
- package/lib/inputs2/checkboxfield/index.js +0 -146
- package/lib/inputs2/colorfield/index.d.ts +0 -9
- package/lib/inputs2/colorfield/index.js +0 -119
- package/lib/inputs2/date/base/constants.d.ts +0 -7
- package/lib/inputs2/date/base/constants.js +0 -43
- package/lib/inputs2/date/base/index.d.ts +0 -12
- package/lib/inputs2/date/base/index.js +0 -179
- package/lib/inputs2/date/datefield/calendarbox.d.ts +0 -7
- package/lib/inputs2/date/datefield/calendarbox.js +0 -115
- package/lib/inputs2/date/datefield/context.d.ts +0 -14
- package/lib/inputs2/date/datefield/context.js +0 -15
- package/lib/inputs2/date/datefield/index.d.ts +0 -10
- package/lib/inputs2/date/datefield/index.js +0 -336
- package/lib/inputs2/date/datefield/triggers.d.ts +0 -8
- package/lib/inputs2/date/datefield/triggers.js +0 -47
- package/lib/inputs2/date/datefield/types.d.ts +0 -63
- package/lib/inputs2/date/datefield/types.js +0 -5
- package/lib/inputs2/date/dateperiodfield/calendarbox.d.ts +0 -7
- package/lib/inputs2/date/dateperiodfield/calendarbox.js +0 -136
- package/lib/inputs2/date/dateperiodfield/context.d.ts +0 -14
- package/lib/inputs2/date/dateperiodfield/context.js +0 -17
- package/lib/inputs2/date/dateperiodfield/index.d.ts +0 -10
- package/lib/inputs2/date/dateperiodfield/index.js +0 -593
- package/lib/inputs2/date/dateperiodfield/triggers.d.ts +0 -6
- package/lib/inputs2/date/dateperiodfield/triggers.js +0 -120
- package/lib/inputs2/date/dateperiodfield/types.d.ts +0 -101
- package/lib/inputs2/date/dateperiodfield/types.js +0 -19
- package/lib/inputs2/date/helpers.d.ts +0 -21
- package/lib/inputs2/date/helpers.js +0 -62
- package/lib/inputs2/date/types.d.ts +0 -60
- package/lib/inputs2/date/types.js +0 -19
- package/lib/inputs2/index.d.ts +0 -32
- package/lib/inputs2/index.js +0 -34
- package/lib/inputs2/mask/BaseMask.d.ts +0 -10
- package/lib/inputs2/mask/BaseMask.js +0 -95
- package/lib/inputs2/mask/Cnpj.d.ts +0 -11
- package/lib/inputs2/mask/Cnpj.js +0 -57
- package/lib/inputs2/mask/Cpf.d.ts +0 -11
- package/lib/inputs2/mask/Cpf.js +0 -53
- package/lib/inputs2/mask/Phone.d.ts +0 -11
- package/lib/inputs2/mask/Phone.js +0 -26
- package/lib/inputs2/mask/ZipCode.d.ts +0 -11
- package/lib/inputs2/mask/ZipCode.js +0 -23
- package/lib/inputs2/mask/helpers.d.ts +0 -4
- package/lib/inputs2/mask/helpers.js +0 -57
- package/lib/inputs2/numberfield/currency.d.ts +0 -13
- package/lib/inputs2/numberfield/currency.js +0 -91
- package/lib/inputs2/numberfield/decimal.d.ts +0 -13
- package/lib/inputs2/numberfield/decimal.js +0 -85
- package/lib/inputs2/numberfield/helpers.d.ts +0 -30
- package/lib/inputs2/numberfield/helpers.js +0 -53
- package/lib/inputs2/numberfield/index.d.ts +0 -12
- package/lib/inputs2/numberfield/index.js +0 -104
- package/lib/inputs2/numberfield/types.d.ts +0 -36
- package/lib/inputs2/numberfield/types.js +0 -5
- package/lib/inputs2/radiofield/index.d.ts +0 -9
- package/lib/inputs2/radiofield/index.js +0 -143
- package/lib/inputs2/radiofield/types.d.ts +0 -33
- package/lib/inputs2/radiofield/types.js +0 -5
- package/lib/inputs2/selectfield/context.d.ts +0 -38
- package/lib/inputs2/selectfield/context.js +0 -15
- package/lib/inputs2/selectfield/helpers.d.ts +0 -6
- package/lib/inputs2/selectfield/helpers.js +0 -25
- package/lib/inputs2/selectfield/index.d.ts +0 -10
- package/lib/inputs2/selectfield/index.js +0 -491
- package/lib/inputs2/selectfield/item.d.ts +0 -11
- package/lib/inputs2/selectfield/item.js +0 -85
- package/lib/inputs2/selectfield/listbox.d.ts +0 -7
- package/lib/inputs2/selectfield/listbox.js +0 -103
- package/lib/inputs2/selectfield/search.d.ts +0 -7
- package/lib/inputs2/selectfield/search.js +0 -71
- package/lib/inputs2/selectfield/selections.d.ts +0 -10
- package/lib/inputs2/selectfield/selections.js +0 -86
- package/lib/inputs2/selectfield/triggers.d.ts +0 -8
- package/lib/inputs2/selectfield/triggers.js +0 -100
- package/lib/inputs2/selectfield/types.d.ts +0 -54
- package/lib/inputs2/selectfield/types.js +0 -21
- package/lib/inputs2/slot/index.d.ts +0 -14
- package/lib/inputs2/slot/index.js +0 -47
- package/lib/inputs2/textfield/index.d.ts +0 -8
- package/lib/inputs2/textfield/index.js +0 -159
- package/lib/tooltip/TooltipContent.d.ts +0 -7
- package/lib/tooltip/TooltipContent.js +0 -65
- package/lib/tooltip/useTooltip.d.ts +0 -30
- package/lib/tooltip/useTooltip.js +0 -128
package/lib/table/index.js
CHANGED
|
@@ -44,7 +44,7 @@ var _RowColumn = _interopRequireDefault(require("./RowColumn"));
|
|
|
44
44
|
require("../assets/styles/table.scss");
|
|
45
45
|
var _helpers = _interopRequireDefault(require("./helpers"));
|
|
46
46
|
const _excluded = ["children"],
|
|
47
|
-
_excluded2 = ["onColClick", "onRowClick", "bodyScrollable", "vertical", "skeletonize", "strict", "skeletonHeight", "skeletonInHeader", "skeletonInRows", "selectedRowId"];
|
|
47
|
+
_excluded2 = ["onColClick", "onRowClick", "bodyScrollable", "vertical", "skeletonize", "strict", "skeletonHeight", "skeletonInHeader", "skeletonInRows", "selectedRowId", "allowHorizontalScroll"];
|
|
48
48
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
49
49
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
50
50
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
@@ -87,7 +87,8 @@ const Table = _ref2 => {
|
|
|
87
87
|
skeletonHeight,
|
|
88
88
|
skeletonInHeader,
|
|
89
89
|
skeletonInRows,
|
|
90
|
-
selectedRowId: selectedRowIdFromProps
|
|
90
|
+
selectedRowId: selectedRowIdFromProps,
|
|
91
|
+
allowHorizontalScroll = false
|
|
91
92
|
} = props,
|
|
92
93
|
rest = _objectWithoutProperties(props, _excluded2);
|
|
93
94
|
const [selectedRowId, setSelectedRowId] = (0, _react.useState)(selectedRowIdFromProps);
|
|
@@ -120,6 +121,20 @@ const Table = _ref2 => {
|
|
|
120
121
|
columnsWidth,
|
|
121
122
|
handlerSetColumnsCount
|
|
122
123
|
}), [bodyContainerRef, bodyScrollWidth, selectedRowId, vertical, skeletonize, skeletonHeight, skeletonInHeader, skeletonInRows, strict, columnsCount, handleSelectRow, onColClick, onRowClick, handlerSetColumnsWidth, columnsWidth, handlerSetColumnsCount]);
|
|
124
|
+
const getTableComponent = () => {
|
|
125
|
+
const tableComponent = /*#__PURE__*/_react.default.createElement(_react.Fragment, null, /*#__PURE__*/_react.default.createElement("table", _extends({
|
|
126
|
+
style: {
|
|
127
|
+
contain: strict ? 'strict' : 'size style'
|
|
128
|
+
},
|
|
129
|
+
className: getClass(props)
|
|
130
|
+
}, rest), children));
|
|
131
|
+
if (allowHorizontalScroll) {
|
|
132
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
|
133
|
+
className: "horizontal-scroll-container"
|
|
134
|
+
}, tableComponent);
|
|
135
|
+
}
|
|
136
|
+
return tableComponent;
|
|
137
|
+
};
|
|
123
138
|
const contextValues = (0, _react.useMemo)(() => getContextValues(), [getContextValues]);
|
|
124
139
|
(0, _react.useEffect)(() => {
|
|
125
140
|
if (bodyScrollable && bodyContainerRef && bodyContainerRef.current) {
|
|
@@ -138,11 +153,6 @@ const Table = _ref2 => {
|
|
|
138
153
|
value: contextValues
|
|
139
154
|
}, bodyScrollable ? /*#__PURE__*/_react.default.createElement("div", {
|
|
140
155
|
className: getClass(props)
|
|
141
|
-
}, children) :
|
|
142
|
-
style: {
|
|
143
|
-
contain: strict ? 'strict' : 'size style'
|
|
144
|
-
},
|
|
145
|
-
className: getClass(props)
|
|
146
|
-
}, rest), children));
|
|
156
|
+
}, children) : getTableComponent());
|
|
147
157
|
};
|
|
148
158
|
var _default = exports.default = Table;
|
package/lib/table/types.d.ts
CHANGED
|
@@ -18,6 +18,7 @@ interface ITableProps extends TableHTMLAttributes<HTMLTableElement> {
|
|
|
18
18
|
skeletonInRows?: number;
|
|
19
19
|
skeletonInHeader?: boolean;
|
|
20
20
|
skeletonHeight?: number;
|
|
21
|
+
allowHorizontalScroll?: boolean;
|
|
21
22
|
}
|
|
22
23
|
interface ITableHeaderProps extends ComponentProps<'th'> {
|
|
23
24
|
children?: ReactNode;
|
|
@@ -1,17 +1,22 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
2
|
-
import {
|
|
1
|
+
import React__default, { MutableRefObject } from 'react';
|
|
2
|
+
import { WithTooltipProps } from '../internals/types.js';
|
|
3
|
+
import '../@types/PermissionAttr.js';
|
|
3
4
|
import '../@types/Position.js';
|
|
4
5
|
|
|
5
|
-
interface TextContentProps extends React__default.HTMLAttributes<HTMLElement>,
|
|
6
|
+
interface TextContentProps extends React__default.HTMLAttributes<HTMLElement>, WithTooltipProps {
|
|
6
7
|
as?: 'span' | 'strong' | 'p';
|
|
7
8
|
label?: string | string[];
|
|
8
9
|
styleForLabel?: object;
|
|
9
10
|
labelUppercase?: boolean;
|
|
10
11
|
required?: boolean;
|
|
11
12
|
disabled?: boolean;
|
|
13
|
+
targetRef?: (ref: HTMLSpanElement | null) => void;
|
|
14
|
+
labelRef?: MutableRefObject<HTMLSpanElement | null>;
|
|
12
15
|
onHoverLabel?: (e: React__default.MouseEvent<HTMLSpanElement, MouseEvent>) => void;
|
|
13
|
-
errorMessage?: string;
|
|
14
16
|
}
|
|
15
|
-
declare const
|
|
17
|
+
declare const _default: {
|
|
18
|
+
(props: TextContentProps & React__default.RefAttributes<HTMLElement>): JSX.Element;
|
|
19
|
+
displayName: string;
|
|
20
|
+
};
|
|
16
21
|
|
|
17
|
-
export {
|
|
22
|
+
export { _default as default };
|
package/lib/textContent/index.js
CHANGED
|
@@ -6,8 +6,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _react = _interopRequireWildcard(require("react"));
|
|
8
8
|
require("../assets/styles/textContent.scss");
|
|
9
|
-
var
|
|
10
|
-
|
|
9
|
+
var _withTooltip = _interopRequireDefault(require("../internals/withTooltip"));
|
|
10
|
+
var _lodash = _interopRequireDefault(require("lodash"));
|
|
11
|
+
const _excluded = ["as", "children", "className", "styleForLabel", "onHoverLabel"];
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
13
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
12
14
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
13
15
|
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
@@ -19,29 +21,18 @@ const TextContent = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
|
|
|
19
21
|
children,
|
|
20
22
|
className,
|
|
21
23
|
styleForLabel,
|
|
22
|
-
onHoverLabel
|
|
23
|
-
tooltip,
|
|
24
|
-
tooltipPosition,
|
|
25
|
-
tooltipWidth,
|
|
26
|
-
errorMessage,
|
|
27
|
-
labelUppercase: __
|
|
24
|
+
onHoverLabel
|
|
28
25
|
} = _ref,
|
|
29
26
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
30
|
-
const
|
|
31
|
-
|
|
32
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
33
|
-
ref:
|
|
27
|
+
const typedRef = ref;
|
|
28
|
+
const restProps = _lodash.default.omit(props, ['tooltipWidth', 'tooltip', 'tooltipPosition', 'labelUppercase']);
|
|
29
|
+
return /*#__PURE__*/_react.default.createElement(Comp, _extends({
|
|
30
|
+
ref: typedRef,
|
|
34
31
|
style: styleForLabel,
|
|
35
32
|
className: `text-content-component ${className}`,
|
|
36
33
|
"data-textcontent": Comp,
|
|
37
34
|
onMouseEnter: onHoverLabel
|
|
38
|
-
},
|
|
39
|
-
targetRef: compRef,
|
|
40
|
-
text: tooltip,
|
|
41
|
-
position: tooltipPosition,
|
|
42
|
-
width: tooltipWidth,
|
|
43
|
-
textError: errorMessage
|
|
44
|
-
}));
|
|
35
|
+
}, restProps), children);
|
|
45
36
|
});
|
|
46
37
|
TextContent.displayName = 'TextContent';
|
|
47
|
-
var _default = exports.default = TextContent;
|
|
38
|
+
var _default = exports.default = (0, _withTooltip.default)(TextContent);
|
package/lib/tooltip/index.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
+
import React__default from 'react';
|
|
1
2
|
import { ITooltipProps } from './types.js';
|
|
2
|
-
import 'react';
|
|
3
|
-
import '../@types/Position.js';
|
|
4
3
|
|
|
5
|
-
declare
|
|
4
|
+
declare const Tooltip: ({ text, textError, tooltipRef, style, tooltipDimensions, className, handlerSetDimensions, }: ITooltipProps) => React__default.ReactPortal;
|
|
6
5
|
|
|
7
|
-
export { Tooltip
|
|
6
|
+
export { Tooltip as default };
|
package/lib/tooltip/index.js
CHANGED
|
@@ -3,44 +3,61 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
7
|
-
var _react =
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactDom = _interopRequireDefault(require("react-dom"));
|
|
9
|
+
var uuid = _interopRequireWildcard(require("uuid"));
|
|
10
|
+
require("../assets/styles/tooltip.scss");
|
|
11
11
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
-
function
|
|
13
|
-
function
|
|
14
|
-
|
|
15
|
-
function Tooltip(_ref) {
|
|
12
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
13
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
14
|
+
const Tooltip = _ref => {
|
|
16
15
|
let {
|
|
17
16
|
text,
|
|
18
17
|
textError,
|
|
19
|
-
|
|
20
|
-
style,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
position = 'bottom',
|
|
25
|
-
onDeniedText
|
|
18
|
+
tooltipRef,
|
|
19
|
+
style = '',
|
|
20
|
+
tooltipDimensions,
|
|
21
|
+
className = 'bottom',
|
|
22
|
+
handlerSetDimensions = () => {}
|
|
26
23
|
} = _ref;
|
|
27
|
-
const
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
24
|
+
const tooltipComponent = (0, _react.useRef)(document.createElement('div'));
|
|
25
|
+
(0, _react.useEffect)(() => {
|
|
26
|
+
tooltipComponent.current.id = `tooltip-${uuid.v1()}`;
|
|
27
|
+
tooltipComponent.current.className = `tooltip-component ${className} `;
|
|
28
|
+
tooltipComponent.current.dataset.testid = 'tooltip-component';
|
|
29
|
+
tooltipComponent.current.style.cssText = style;
|
|
30
|
+
document.body.appendChild(tooltipComponent.current);
|
|
31
|
+
const tooltipEl = document.querySelector(`div#${tooltipComponent.current.id}`);
|
|
32
|
+
let widthDimension = tooltipEl?.offsetWidth;
|
|
33
|
+
const heightDimension = tooltipEl?.offsetHeight;
|
|
34
|
+
if (tooltipDimensions && tooltipDimensions.width) {
|
|
35
|
+
widthDimension = tooltipDimensions.width;
|
|
36
|
+
}
|
|
37
|
+
handlerSetDimensions({
|
|
38
|
+
width: widthDimension,
|
|
39
|
+
height: Number(heightDimension)
|
|
40
|
+
});
|
|
41
|
+
// eslint-disable-next-line no-param-reassign
|
|
42
|
+
if (tooltipRef) {
|
|
43
|
+
tooltipRef.current = tooltipEl;
|
|
44
|
+
}
|
|
45
|
+
return () => {
|
|
46
|
+
document.body.removeChild(tooltipComponent.current);
|
|
47
|
+
};
|
|
48
|
+
}, []);
|
|
49
|
+
(0, _react.useEffect)(() => {
|
|
50
|
+
tooltipComponent.current.className = `tooltip-component ${className} `;
|
|
51
|
+
}, [className]);
|
|
52
|
+
(0, _react.useEffect)(() => {
|
|
53
|
+
tooltipComponent.current.style.cssText = style;
|
|
54
|
+
}, [style]);
|
|
55
|
+
(0, _react.useEffect)(() => {
|
|
56
|
+
tooltipComponent.current.className = textError ? `tooltip-error tooltip-component ${className}` : `tooltip-component ${className}`;
|
|
57
|
+
}, [textError]);
|
|
58
|
+
const getTooltipContent = () => /*#__PURE__*/_react.default.createElement("div", {
|
|
59
|
+
className: "tooltipcontent"
|
|
60
|
+
}, textError || text);
|
|
61
|
+
return /*#__PURE__*/_reactDom.default.createPortal(getTooltipContent(), tooltipComponent.current);
|
|
62
|
+
};
|
|
63
|
+
var _default = exports.default = Tooltip;
|
package/lib/tooltip/types.d.ts
CHANGED
|
@@ -1,39 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Position } from '../@types/Position.js';
|
|
1
|
+
import { MutableRefObject } from 'react';
|
|
3
2
|
|
|
4
3
|
type Dimensions = {
|
|
5
4
|
width: number | string;
|
|
6
5
|
height: number;
|
|
7
6
|
};
|
|
8
7
|
interface ITooltipProps {
|
|
9
|
-
targetRef: RefObject<HTMLElement>;
|
|
10
8
|
text?: string;
|
|
11
|
-
|
|
12
|
-
style?: CSSProperties;
|
|
9
|
+
style?: string;
|
|
13
10
|
className?: string;
|
|
14
|
-
width?: string | number;
|
|
15
|
-
space?: number;
|
|
16
|
-
position?: Exclude<Position, 'center'>;
|
|
17
|
-
onDeniedText?: string;
|
|
18
|
-
}
|
|
19
|
-
interface ITooltipContentProps {
|
|
20
11
|
tooltipRef?: MutableRefObject<HTMLElement | null>;
|
|
21
|
-
text?: string;
|
|
22
|
-
style?: string;
|
|
23
|
-
styleForContent?: CSSProperties;
|
|
24
|
-
classNameForContent?: string;
|
|
25
|
-
width?: string | number;
|
|
26
|
-
space?: number;
|
|
27
|
-
tooltip?: string;
|
|
28
|
-
position?: Exclude<Position, 'center'>;
|
|
29
12
|
handlerSetDimensions?: ({ width, height }: Dimensions) => void;
|
|
30
13
|
tooltipDimensions?: Dimensions;
|
|
31
14
|
textError?: string;
|
|
32
15
|
}
|
|
33
|
-
interface ITooltipCommonProps {
|
|
34
|
-
tooltip?: string;
|
|
35
|
-
tooltipWidth?: string | number;
|
|
36
|
-
tooltipPosition?: Exclude<Position, 'center'>;
|
|
37
|
-
}
|
|
38
16
|
|
|
39
|
-
export {
|
|
17
|
+
export { ITooltipProps };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "linear-react-components-ui",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.25-rc.1",
|
|
4
4
|
"description": "Linear Sistemas ReactJs Components",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib/index.cjs",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"moment": "2.30.1",
|
|
55
55
|
"prop-types": "15.8.1",
|
|
56
56
|
"react-dev-utils": "12.0.0",
|
|
57
|
-
"react-imask": "7.6.1",
|
|
57
|
+
"react-imask": "^7.6.1",
|
|
58
58
|
"react-router-dom": "6.21.3",
|
|
59
59
|
"react-syntax-highlighter": "15.5.0",
|
|
60
60
|
"semver": "7.5.4",
|
|
@@ -68,7 +68,6 @@
|
|
|
68
68
|
"@babel/preset-env": "7.20.2",
|
|
69
69
|
"@babel/preset-react": "7.18.6",
|
|
70
70
|
"@babel/preset-typescript": "7.23.3",
|
|
71
|
-
"@faker-js/faker": "9.8.0",
|
|
72
71
|
"@svgr/webpack": "8.1.0",
|
|
73
72
|
"@swc/core": "1.4.13",
|
|
74
73
|
"@testing-library/dom": "10.4.0",
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
2
|
-
import { T as TextFieldInputProps } from './index-3b70931d.js';
|
|
3
|
-
import { FactoryOpts } from 'imask';
|
|
4
|
-
|
|
5
|
-
interface MaskFieldProps extends TextFieldInputProps {
|
|
6
|
-
maskOptions?: FactoryOpts;
|
|
7
|
-
onAccept?: (value: string) => void;
|
|
8
|
-
onComplete?: (value: string, maskRef: any, e?: InputEvent) => void;
|
|
9
|
-
onChange?: (e: React__default.ChangeEvent<HTMLInputElement>) => void;
|
|
10
|
-
autoCompleteMask?: string;
|
|
11
|
-
value?: string;
|
|
12
|
-
}
|
|
13
|
-
declare const Input: React__default.ForwardRefExoticComponent<MaskFieldProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
14
|
-
|
|
15
|
-
declare const BaseMask_Input: typeof Input;
|
|
16
|
-
type BaseMask_MaskFieldProps = MaskFieldProps;
|
|
17
|
-
declare namespace BaseMask {
|
|
18
|
-
export {
|
|
19
|
-
BaseMask_Input as Input,
|
|
20
|
-
BaseMask_MaskFieldProps as MaskFieldProps,
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export { BaseMask as B, Input as I, MaskFieldProps as M };
|
package/lib/Cnpj-bde01dd0.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
2
|
-
import { M as MaskFieldProps } from './BaseMask-0c14ef51.js';
|
|
3
|
-
|
|
4
|
-
interface CnpjFieldProps extends MaskFieldProps {
|
|
5
|
-
onValidate?: (errors: string[]) => void;
|
|
6
|
-
}
|
|
7
|
-
declare const Input: React__default.ForwardRefExoticComponent<CnpjFieldProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
8
|
-
|
|
9
|
-
type Cnpj_CnpjFieldProps = CnpjFieldProps;
|
|
10
|
-
declare const Cnpj_Input: typeof Input;
|
|
11
|
-
declare namespace Cnpj {
|
|
12
|
-
export {
|
|
13
|
-
Cnpj_CnpjFieldProps as CnpjFieldProps,
|
|
14
|
-
Cnpj_Input as Input,
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export { Cnpj as C, Input as I, CnpjFieldProps as a };
|
package/lib/Cpf-3fa496ad.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
2
|
-
import { M as MaskFieldProps } from './BaseMask-0c14ef51.js';
|
|
3
|
-
|
|
4
|
-
interface CpfFieldProps extends MaskFieldProps {
|
|
5
|
-
onValidate?: (errors: string[]) => void;
|
|
6
|
-
}
|
|
7
|
-
declare const Input: React__default.ForwardRefExoticComponent<CpfFieldProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
8
|
-
|
|
9
|
-
type Cpf_CpfFieldProps = CpfFieldProps;
|
|
10
|
-
declare const Cpf_Input: typeof Input;
|
|
11
|
-
declare namespace Cpf {
|
|
12
|
-
export {
|
|
13
|
-
Cpf_CpfFieldProps as CpfFieldProps,
|
|
14
|
-
Cpf_Input as Input,
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export { Cpf as C, Input as I, CpfFieldProps as a };
|
package/lib/Phone-2bb0b397.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
2
|
-
import { M as MaskFieldProps } from './BaseMask-0c14ef51.js';
|
|
3
|
-
|
|
4
|
-
interface PhoneFieldProps extends MaskFieldProps {
|
|
5
|
-
isCellphone?: boolean;
|
|
6
|
-
}
|
|
7
|
-
declare const Input: React__default.ForwardRefExoticComponent<PhoneFieldProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
8
|
-
|
|
9
|
-
declare const Phone_Input: typeof Input;
|
|
10
|
-
type Phone_PhoneFieldProps = PhoneFieldProps;
|
|
11
|
-
declare namespace Phone {
|
|
12
|
-
export {
|
|
13
|
-
Phone_Input as Input,
|
|
14
|
-
Phone_PhoneFieldProps as PhoneFieldProps,
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export { Input as I, Phone as P, PhoneFieldProps as a };
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
2
|
-
import { M as MaskFieldProps } from './BaseMask-0c14ef51.js';
|
|
3
|
-
|
|
4
|
-
declare const Input: React__default.ForwardRefExoticComponent<MaskFieldProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
5
|
-
|
|
6
|
-
declare const ZipCode_Input: typeof Input;
|
|
7
|
-
declare namespace ZipCode {
|
|
8
|
-
export {
|
|
9
|
-
ZipCode_Input as Input,
|
|
10
|
-
};
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export { Input as I, ZipCode as Z };
|
|
@@ -1,199 +0,0 @@
|
|
|
1
|
-
@import "commons.scss";
|
|
2
|
-
@import "colors.scss";
|
|
3
|
-
@import "effects.scss";
|
|
4
|
-
@import "fonts.scss";
|
|
5
|
-
|
|
6
|
-
/* Chrome, Safari, Edge, Opera */
|
|
7
|
-
input::-webkit-outer-spin-button,
|
|
8
|
-
input::-webkit-inner-spin-button {
|
|
9
|
-
-webkit-appearance: none;
|
|
10
|
-
margin: 0;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.checkbox-field-root {
|
|
14
|
-
display: flex;
|
|
15
|
-
flex-direction: column;
|
|
16
|
-
text-align: start;
|
|
17
|
-
.container {
|
|
18
|
-
display: flex;
|
|
19
|
-
flex-direction: row;
|
|
20
|
-
justify-content: flex-start;
|
|
21
|
-
align-items: center;
|
|
22
|
-
text-align: start;
|
|
23
|
-
gap: 6px;
|
|
24
|
-
width: 100%;
|
|
25
|
-
height: 28px;
|
|
26
|
-
margin: 0;
|
|
27
|
-
padding: 0;
|
|
28
|
-
&[data-state-skeletonize=true] {
|
|
29
|
-
@extend %skeleton-component;
|
|
30
|
-
color: transparent;
|
|
31
|
-
background-color: transparent;
|
|
32
|
-
}
|
|
33
|
-
.input-root {
|
|
34
|
-
position: relative;
|
|
35
|
-
display: flex;
|
|
36
|
-
align-items: center;
|
|
37
|
-
justify-content: center;
|
|
38
|
-
.input {
|
|
39
|
-
@extend %component-fonts;
|
|
40
|
-
position: relative;
|
|
41
|
-
padding: 6px;
|
|
42
|
-
font-size: 0.875rem;
|
|
43
|
-
line-height: 0.875rem;
|
|
44
|
-
border: 1px solid $component-border-color;
|
|
45
|
-
background: $font-color-second left top no-repeat;
|
|
46
|
-
cursor: pointer;
|
|
47
|
-
vertical-align: middle;
|
|
48
|
-
transition: background-color 0.1s, border-color 0.1s;
|
|
49
|
-
flex-shrink: 0;
|
|
50
|
-
appearance: none;
|
|
51
|
-
-webkit-appearance: none;
|
|
52
|
-
-moz-appearance: none;
|
|
53
|
-
&:focus, &:hover {
|
|
54
|
-
transition: box-shadow 0.2s;
|
|
55
|
-
}
|
|
56
|
-
&:checked {
|
|
57
|
-
border-color: $default-actived-color;
|
|
58
|
-
}
|
|
59
|
-
&[data-state-rounded=true] {
|
|
60
|
-
border-radius: 2px;
|
|
61
|
-
}
|
|
62
|
-
&[data-state-variant=default] {
|
|
63
|
-
&:checked {
|
|
64
|
-
background-color: $checked-effect;
|
|
65
|
-
}
|
|
66
|
-
&:focus, &:hover, &[data-state-in-focus-select-field=true] {
|
|
67
|
-
box-shadow: 0 0 0 2px $checked-effect;
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
&[data-state-variant=secondary] {
|
|
71
|
-
&:checked {
|
|
72
|
-
background-color: $font-selected-color;
|
|
73
|
-
}
|
|
74
|
-
&:focus, &:hover, &[data-state-in-focus-select-field=true] {
|
|
75
|
-
box-shadow: 0 0 0 2px $font-selected-color;
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
&[data-state-size=small] {
|
|
79
|
-
width: 14px;
|
|
80
|
-
height: 14px;
|
|
81
|
-
}
|
|
82
|
-
&[data-state-size=default] {
|
|
83
|
-
width: 18px;
|
|
84
|
-
height: 18px;
|
|
85
|
-
}
|
|
86
|
-
&[data-state-size=medium] {
|
|
87
|
-
width: 20px;
|
|
88
|
-
height: 20px;
|
|
89
|
-
}
|
|
90
|
-
&[data-state-size=large] {
|
|
91
|
-
width: 22px;
|
|
92
|
-
height: 22px;
|
|
93
|
-
}
|
|
94
|
-
&[data-state-read-only=true], &[data-state-read-only=true]:checked {
|
|
95
|
-
cursor: default;
|
|
96
|
-
pointer-events: none;
|
|
97
|
-
border-color: $font-color-disabled;
|
|
98
|
-
background-color: $input-read-only-bg-color;
|
|
99
|
-
}
|
|
100
|
-
&:disabled, &:disabled:checked {
|
|
101
|
-
border-color: $font-color-disabled;
|
|
102
|
-
background-color: $input-disabled-bg-color;
|
|
103
|
-
cursor: not-allowed;
|
|
104
|
-
pointer-events: none;
|
|
105
|
-
transition: color 450ms cubic-bezier(0.23, 1, 0.32, 1) 0ms;
|
|
106
|
-
}
|
|
107
|
-
&[data-state-skeletonize=true] {
|
|
108
|
-
border: none !important;
|
|
109
|
-
color: transparent !important;
|
|
110
|
-
background-color: transparent !important;
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
.checkmark {
|
|
114
|
-
display: block;
|
|
115
|
-
position: absolute;
|
|
116
|
-
margin: 0;
|
|
117
|
-
opacity: 0;
|
|
118
|
-
visibility: hidden;
|
|
119
|
-
transition: opacity 0.1s, visibility 0.1s;
|
|
120
|
-
pointer-events: none;
|
|
121
|
-
fill: $font-color-second;
|
|
122
|
-
}
|
|
123
|
-
&:has(input:checked) {
|
|
124
|
-
.checkmark {
|
|
125
|
-
opacity: 1;
|
|
126
|
-
visibility: initial;
|
|
127
|
-
width: 75%;
|
|
128
|
-
height: 75%;
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
&:has(input[data-state-read-only=true]) {
|
|
132
|
-
.checkmark {
|
|
133
|
-
fill: $font-color-disabled;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
&:has(input:disabled) {
|
|
137
|
-
.checkmark {
|
|
138
|
-
fill: $font-color-disabled;
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
&:has(input[data-state-skeletonize=true]) {
|
|
142
|
-
.checkmark {
|
|
143
|
-
fill: transparent !important;
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
.label {
|
|
148
|
-
@extend %input-label;
|
|
149
|
-
font-size: 0.875rem;
|
|
150
|
-
line-height: normal;
|
|
151
|
-
color: $font-color-default;
|
|
152
|
-
overflow: hidden;
|
|
153
|
-
text-overflow: ellipsis;
|
|
154
|
-
white-space: nowrap;
|
|
155
|
-
&[data-state-input-required=true]::after {
|
|
156
|
-
content: "*";
|
|
157
|
-
color: $font-color-default;
|
|
158
|
-
}
|
|
159
|
-
&[data-state-uppercase=true] {
|
|
160
|
-
text-transform: uppercase;
|
|
161
|
-
}
|
|
162
|
-
&[data-state-required-label=true] {
|
|
163
|
-
color: $error-color;
|
|
164
|
-
font-weight: 600;
|
|
165
|
-
font-size: 0.875rem;
|
|
166
|
-
margin-left: 1px;
|
|
167
|
-
}
|
|
168
|
-
&[data-state-skeletonize=true] {
|
|
169
|
-
color: transparent;
|
|
170
|
-
}
|
|
171
|
-
&[data-state-read-only=true], &[data-state-disabled=true] {
|
|
172
|
-
cursor: default;
|
|
173
|
-
pointer-events: none;
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
>button {
|
|
177
|
-
width: 20px;
|
|
178
|
-
height: auto;
|
|
179
|
-
margin: 0px !important;
|
|
180
|
-
}
|
|
181
|
-
}
|
|
182
|
-
.hint {
|
|
183
|
-
span {
|
|
184
|
-
display: inline-block;
|
|
185
|
-
width: 100%;
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
.error {
|
|
189
|
-
width: 100%;
|
|
190
|
-
color: $error-color;
|
|
191
|
-
margin-top: 5px;
|
|
192
|
-
font-size: 0.8125rem;
|
|
193
|
-
line-height: 0.8125rem;
|
|
194
|
-
&[data-state-skeletonize=true] {
|
|
195
|
-
@extend %skeleton-component;
|
|
196
|
-
color: transparent;
|
|
197
|
-
}
|
|
198
|
-
}
|
|
199
|
-
}
|