@plesk/ui-library 3.28.1 → 3.28.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/cjs/components/Button/Button.js +13 -6
- package/cjs/components/List/List.js +1 -6
- package/cjs/components/index.js +10 -1
- package/cjs/index.js +1 -1
- package/dist/plesk-ui-library-rtl.css.map +1 -1
- package/dist/plesk-ui-library.css.map +1 -1
- package/dist/plesk-ui-library.js +25 -14
- package/dist/plesk-ui-library.js.map +1 -1
- package/dist/plesk-ui-library.min.js +2 -2
- package/dist/plesk-ui-library.min.js.map +1 -1
- package/esm/components/Button/Button.js +14 -7
- package/esm/components/List/List.js +1 -6
- package/esm/components/index.js +2 -1
- package/esm/index.js +1 -1
- package/package.json +1 -1
- package/styleguide/build/bundle.699238d9.js +2 -0
- package/styleguide/build/{bundle.fa6ff17e.js.LICENSE.txt → bundle.699238d9.js.LICENSE.txt} +0 -0
- package/styleguide/index.html +2 -2
- package/types/src/components/Form/Form.d.ts +3 -54
- package/types/src/components/Form/types.d.ts +4 -4
- package/types/src/components/FormFieldPassword/FormFieldPassword.d.ts +2 -2
- package/types/src/components/index.d.ts +1 -0
- package/styleguide/build/bundle.fa6ff17e.js +0 -2
|
@@ -95,7 +95,7 @@ const renderCaret = ({
|
|
|
95
95
|
*/
|
|
96
96
|
|
|
97
97
|
|
|
98
|
-
const Button = ({
|
|
98
|
+
const Button = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
99
99
|
baseClassName,
|
|
100
100
|
className,
|
|
101
101
|
component: Tag,
|
|
@@ -113,7 +113,7 @@ const Button = ({
|
|
|
113
113
|
arrow,
|
|
114
114
|
disabled,
|
|
115
115
|
...props
|
|
116
|
-
}) => {
|
|
116
|
+
}, ref) => {
|
|
117
117
|
const [selectedState, setSelectedState] = (0, _react.useState)(false);
|
|
118
118
|
|
|
119
119
|
const handleToggle = () => {
|
|
@@ -169,6 +169,7 @@ const Button = ({
|
|
|
169
169
|
const hasAriaDisabled = Tag === 'button' && disabled && tooltip;
|
|
170
170
|
|
|
171
171
|
let button = /*#__PURE__*/_react.default.createElement(Tag, (0, _extends2.default)({
|
|
172
|
+
ref: ref,
|
|
172
173
|
className: (0, _classnames.default)(baseClassName, {
|
|
173
174
|
[`${baseClassName}--${size}`]: size,
|
|
174
175
|
[`${baseClassName}--${intent}`]: intent && !ghost,
|
|
@@ -208,8 +209,8 @@ const Button = ({
|
|
|
208
209
|
}
|
|
209
210
|
|
|
210
211
|
return button;
|
|
211
|
-
};
|
|
212
|
-
|
|
212
|
+
});
|
|
213
|
+
Button.displayName = 'Button';
|
|
213
214
|
Button.propTypes = {
|
|
214
215
|
/**
|
|
215
216
|
* Button size.
|
|
@@ -303,7 +304,12 @@ Button.propTypes = {
|
|
|
303
304
|
/**
|
|
304
305
|
* @ignore
|
|
305
306
|
*/
|
|
306
|
-
baseClassName: _propTypes.default.string
|
|
307
|
+
baseClassName: _propTypes.default.string,
|
|
308
|
+
|
|
309
|
+
/**
|
|
310
|
+
* @ignore
|
|
311
|
+
*/
|
|
312
|
+
onClick: _propTypes.default.func
|
|
307
313
|
};
|
|
308
314
|
Button.defaultProps = {
|
|
309
315
|
size: undefined,
|
|
@@ -321,7 +327,8 @@ Button.defaultProps = {
|
|
|
321
327
|
component: 'button',
|
|
322
328
|
className: undefined,
|
|
323
329
|
baseClassName: `${_constants.CLS_PREFIX}button`,
|
|
324
|
-
arrow: undefined
|
|
330
|
+
arrow: undefined,
|
|
331
|
+
onClick: undefined
|
|
325
332
|
};
|
|
326
333
|
var _default = Button;
|
|
327
334
|
exports.default = _default;
|
|
@@ -892,14 +892,9 @@ class List extends _react.Component {
|
|
|
892
892
|
|
|
893
893
|
if (totalRows && /*#__PURE__*/(0, _react.isValidElement)(pagination)) {
|
|
894
894
|
const {
|
|
895
|
-
itemsPerPageOptions = _Pagination.ITEMS_PER_PAGE_OPTIONS
|
|
896
|
-
itemsPerPage
|
|
895
|
+
itemsPerPageOptions = _Pagination.ITEMS_PER_PAGE_OPTIONS
|
|
897
896
|
} = pagination.props;
|
|
898
897
|
|
|
899
|
-
if (Number.isInteger(itemsPerPage)) {
|
|
900
|
-
return totalRows > itemsPerPage;
|
|
901
|
-
}
|
|
902
|
-
|
|
903
898
|
if (Array.isArray(itemsPerPageOptions)) {
|
|
904
899
|
const numericOptions = itemsPerPageOptions.filter(v => Number(v) === v);
|
|
905
900
|
|
package/cjs/components/index.js
CHANGED
|
@@ -89,7 +89,8 @@ var _exportNames = {
|
|
|
89
89
|
Tour: true,
|
|
90
90
|
Translate: true,
|
|
91
91
|
Link: true,
|
|
92
|
-
Skeleton: true
|
|
92
|
+
Skeleton: true,
|
|
93
|
+
PortalContext: true
|
|
93
94
|
};
|
|
94
95
|
Object.defineProperty(exports, "Action", {
|
|
95
96
|
enumerable: true,
|
|
@@ -433,6 +434,12 @@ Object.defineProperty(exports, "Popover", {
|
|
|
433
434
|
return _Popover.default;
|
|
434
435
|
}
|
|
435
436
|
});
|
|
437
|
+
Object.defineProperty(exports, "PortalContext", {
|
|
438
|
+
enumerable: true,
|
|
439
|
+
get: function () {
|
|
440
|
+
return _Layer.PortalContext;
|
|
441
|
+
}
|
|
442
|
+
});
|
|
436
443
|
Object.defineProperty(exports, "Progress", {
|
|
437
444
|
enumerable: true,
|
|
438
445
|
get: function () {
|
|
@@ -956,6 +963,8 @@ Object.keys(_Skeleton).forEach(function (key) {
|
|
|
956
963
|
});
|
|
957
964
|
});
|
|
958
965
|
|
|
966
|
+
var _Layer = require("./Layer");
|
|
967
|
+
|
|
959
968
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
960
969
|
|
|
961
970
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
package/cjs/index.js
CHANGED