@redhat-cloud-services/frontend-components 3.7.6 → 3.8.0
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/AsyncComponent/index.d.ts +1 -0
- package/AsyncComponent/index.js.map +1 -1
- package/Input/Input.d.ts +13 -22
- package/Input/Input.js +1 -12
- package/Input/Input.js.map +1 -1
- package/Input/LabeledInput.d.ts +3 -16
- package/Input/LabeledInput.js +0 -7
- package/Input/LabeledInput.js.map +1 -1
- package/Input/index.d.ts +5 -2
- package/Input/index.js +12 -0
- package/Input/index.js.map +1 -1
- package/Inventory/TagWithDialog.d.ts +4 -2
- package/Inventory/TagWithDialog.js +17 -19
- package/Inventory/TagWithDialog.js.map +1 -1
- package/Inventory/index.d.ts +1 -0
- package/Inventory/index.js +11 -0
- package/Inventory/index.js.map +1 -1
- package/LongTextTooltip/LongTextTooltip.d.ts +9 -24
- package/LongTextTooltip/LongTextTooltip.js +5 -42
- package/LongTextTooltip/LongTextTooltip.js.map +1 -1
- package/LongTextTooltip/index.d.ts +3 -2
- package/LongTextTooltip/index.js +11 -0
- package/LongTextTooltip/index.js.map +1 -1
- package/NotConnected/NotConnected.d.ts +7 -21
- package/NotConnected/NotConnected.js +1 -12
- package/NotConnected/NotConnected.js.map +1 -1
- package/NotConnected/index.d.ts +3 -1
- package/NotConnected/index.js +11 -0
- package/NotConnected/index.js.map +1 -1
- package/Ouia/Ouia.d.ts +15 -0
- package/Ouia/Ouia.js +32 -0
- package/Ouia/Ouia.js.map +1 -0
- package/Ouia/WithOuia.d.ts +9 -0
- package/Ouia/WithOuia.js +34 -0
- package/Ouia/WithOuia.js.map +1 -0
- package/Ouia/index.d.ts +3 -0
- package/Ouia/index.js +13 -0
- package/Ouia/index.js.map +1 -0
- package/Ouia/package.json +1 -0
- package/Ouia/useOuia.d.ts +7 -0
- package/Ouia/useOuia.js +13 -0
- package/Ouia/useOuia.js.map +1 -0
- package/Reboot/Reboot.d.ts +7 -12
- package/Reboot/Reboot.js +0 -5
- package/Reboot/Reboot.js.map +1 -1
- package/Reboot/index.d.ts +3 -1
- package/Reboot/index.js +11 -0
- package/Reboot/index.js.map +1 -1
- package/SimpleTableFilter/SimpleTableFilter.d.ts +22 -46
- package/SimpleTableFilter/SimpleTableFilter.js +26 -91
- package/SimpleTableFilter/SimpleTableFilter.js.map +1 -1
- package/SimpleTableFilter/index.d.ts +3 -1
- package/SimpleTableFilter/index.js +11 -0
- package/SimpleTableFilter/index.js.map +1 -1
- package/esm/AsyncComponent/index.js.map +1 -1
- package/esm/Input/Input.js +1 -12
- package/esm/Input/Input.js.map +1 -1
- package/esm/Input/LabeledInput.js +0 -7
- package/esm/Input/LabeledInput.js.map +1 -1
- package/esm/Input/index.js +2 -0
- package/esm/Input/index.js.map +1 -1
- package/esm/Inventory/TagWithDialog.js +17 -19
- package/esm/Inventory/TagWithDialog.js.map +1 -1
- package/esm/Inventory/index.js +1 -0
- package/esm/Inventory/index.js.map +1 -1
- package/esm/LongTextTooltip/LongTextTooltip.js +6 -43
- package/esm/LongTextTooltip/LongTextTooltip.js.map +1 -1
- package/esm/LongTextTooltip/index.js +1 -0
- package/esm/LongTextTooltip/index.js.map +1 -1
- package/esm/NotConnected/NotConnected.js +1 -12
- package/esm/NotConnected/NotConnected.js.map +1 -1
- package/esm/NotConnected/index.js +1 -0
- package/esm/NotConnected/index.js.map +1 -1
- package/esm/Ouia/Ouia.js +27 -0
- package/esm/Ouia/Ouia.js.map +1 -0
- package/esm/Ouia/WithOuia.js +29 -0
- package/esm/Ouia/WithOuia.js.map +1 -0
- package/esm/Ouia/index.js +4 -0
- package/esm/Ouia/index.js.map +1 -0
- package/esm/Ouia/useOuia.js +11 -0
- package/esm/Ouia/useOuia.js.map +1 -0
- package/esm/Reboot/Reboot.js +0 -5
- package/esm/Reboot/Reboot.js.map +1 -1
- package/esm/Reboot/index.js +1 -0
- package/esm/Reboot/index.js.map +1 -1
- package/esm/SimpleTableFilter/SimpleTableFilter.js +27 -89
- package/esm/SimpleTableFilter/SimpleTableFilter.js.map +1 -1
- package/esm/SimpleTableFilter/index.js +1 -0
- package/esm/SimpleTableFilter/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,18 +1,3 @@
|
|
|
1
|
-
var __extends = (this && this.__extends) || (function () {
|
|
2
|
-
var extendStatics = function (d, b) {
|
|
3
|
-
extendStatics = Object.setPrototypeOf ||
|
|
4
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
6
|
-
return extendStatics(d, b);
|
|
7
|
-
};
|
|
8
|
-
return function (d, b) {
|
|
9
|
-
if (typeof b !== "function" && b !== null)
|
|
10
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
11
|
-
extendStatics(d, b);
|
|
12
|
-
function __() { this.constructor = d; }
|
|
13
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
|
-
};
|
|
15
|
-
})();
|
|
16
1
|
var __assign = (this && this.__assign) || function () {
|
|
17
2
|
__assign = Object.assign || function(t) {
|
|
18
3
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
@@ -35,35 +20,13 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
35
20
|
}
|
|
36
21
|
return t;
|
|
37
22
|
};
|
|
38
|
-
import { Tooltip } from '@patternfly/react-core';
|
|
39
|
-
import propTypes from 'prop-types';
|
|
23
|
+
import { Tooltip, TooltipPosition } from '@patternfly/react-core';
|
|
40
24
|
import React from 'react';
|
|
41
|
-
var LongTextTooltip =
|
|
42
|
-
|
|
43
|
-
function
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
LongTextTooltip.prototype.truncate = function (str, max) {
|
|
47
|
-
return str.length > max ? str.substr(0, max - 1) + '…' : str;
|
|
48
|
-
};
|
|
49
|
-
LongTextTooltip.prototype.render = function () {
|
|
50
|
-
var _a = this.props, content = _a.content, maxLength = _a.maxLength, tooltipMaxWidth = _a.tooltipMaxWidth, tooltipPosition = _a.tooltipPosition, rest = __rest(_a, ["content", "maxLength", "tooltipMaxWidth", "tooltipPosition"]);
|
|
51
|
-
return (React.createElement(React.Fragment, null, content.length > maxLength ? (React.createElement(Tooltip, __assign({ maxWidth: tooltipMaxWidth, position: tooltipPosition, content: React.createElement("div", null, content) }, rest),
|
|
52
|
-
React.createElement("div", null, this.truncate(content, maxLength)))) : (React.createElement("span", null, content))));
|
|
53
|
-
};
|
|
54
|
-
return LongTextTooltip;
|
|
55
|
-
}(React.Component));
|
|
56
|
-
LongTextTooltip.defaultProps = {
|
|
57
|
-
content: '',
|
|
58
|
-
maxLength: Infinity,
|
|
59
|
-
tooltipPosition: 'top',
|
|
60
|
-
tooltipMaxWidth: '50vw',
|
|
61
|
-
};
|
|
62
|
-
LongTextTooltip.propTypes = {
|
|
63
|
-
content: propTypes.string,
|
|
64
|
-
maxLength: propTypes.number,
|
|
65
|
-
tooltipPosition: propTypes.string,
|
|
66
|
-
tooltipMaxWidth: propTypes.string,
|
|
25
|
+
var LongTextTooltip = function (_a) {
|
|
26
|
+
var _b = _a.content, content = _b === void 0 ? '' : _b, _c = _a.maxLength, maxLength = _c === void 0 ? Infinity : _c, _d = _a.tooltipMaxWidth, tooltipMaxWidth = _d === void 0 ? '50vw' : _d, _e = _a.tooltipPosition, tooltipPosition = _e === void 0 ? TooltipPosition.top : _e, rest = __rest(_a, ["content", "maxLength", "tooltipMaxWidth", "tooltipPosition"]);
|
|
27
|
+
var truncate = function (str, max) { return (str.length > max ? str.substr(0, max - 1) + '…' : str); };
|
|
28
|
+
return content.length > maxLength ? (React.createElement(Tooltip, __assign({ maxWidth: tooltipMaxWidth, position: tooltipPosition, content: React.createElement("div", null, content) }, rest),
|
|
29
|
+
React.createElement("div", null, truncate(content, maxLength)))) : (React.createElement("span", null, content));
|
|
67
30
|
};
|
|
68
31
|
export default LongTextTooltip;
|
|
69
32
|
//# sourceMappingURL=LongTextTooltip.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LongTextTooltip.js","sourceRoot":"","sources":["../../src/LongTextTooltip/LongTextTooltip.
|
|
1
|
+
{"version":3,"file":"LongTextTooltip.js","sourceRoot":"","sources":["../../src/LongTextTooltip/LongTextTooltip.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,OAAO,EAAE,eAAe,EAAgB,MAAM,wBAAwB,CAAC;AAChF,OAAO,KAAK,MAAM,OAAO,CAAC;AAS1B,IAAM,eAAe,GAAmC,UAAC,EAMxD;IALC,IAAA,eAAY,EAAZ,OAAO,mBAAG,EAAE,KAAA,EACZ,iBAAoB,EAApB,SAAS,mBAAG,QAAQ,KAAA,EACpB,uBAAwB,EAAxB,eAAe,mBAAG,MAAM,KAAA,EACxB,uBAAqC,EAArC,eAAe,mBAAG,eAAe,CAAC,GAAG,KAAA,EAClC,IAAI,cALgD,8DAMxD,CADQ;IAEP,IAAM,QAAQ,GAAG,UAAC,GAAW,EAAE,GAAW,IAAK,OAAA,CAAC,GAAG,CAAC,MAAM,GAAG,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,EAAE,GAAG,GAAG,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,EAAvD,CAAuD,CAAC;IAEvG,OAAO,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC,CAAC,CAClC,oBAAC,OAAO,aAAC,QAAQ,EAAE,eAAe,EAAE,QAAQ,EAAE,eAAe,EAAE,OAAO,EAAE,iCAAM,OAAO,CAAO,IAAM,IAAI;QACpG,iCAAM,QAAQ,CAAC,OAAO,EAAE,SAAS,CAAC,CAAO,CACjC,CACX,CAAC,CAAC,CAAC,CACF,kCAAO,OAAO,CAAQ,CACvB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/LongTextTooltip/index.
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/LongTextTooltip/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAClE,cAAc,mBAAmB,CAAC"}
|
|
@@ -1,24 +1,13 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import propTypes from 'prop-types';
|
|
3
2
|
import { EmptyState, EmptyStateIcon, EmptyStateBody, Title, Button } from '@patternfly/react-core';
|
|
4
3
|
import { DisconnectedIcon } from '@patternfly/react-icons';
|
|
5
4
|
var NotConnected = function (_a) {
|
|
6
|
-
var
|
|
5
|
+
var _b = _a.titleText, titleText = _b === void 0 ? 'This system isn’t connected to Insights yet' : _b, _c = _a.bodyText, bodyText = _c === void 0 ? 'To get started, activate the Insights client for this system.' : _c, _d = _a.buttonText, buttonText = _d === void 0 ? 'Learn how to activate the Insights client' : _d;
|
|
7
6
|
return (React.createElement(EmptyState, null,
|
|
8
7
|
React.createElement(EmptyStateIcon, { icon: DisconnectedIcon }),
|
|
9
8
|
React.createElement(Title, { headingLevel: "h5", size: "lg" }, titleText),
|
|
10
9
|
React.createElement(EmptyStateBody, null, bodyText),
|
|
11
10
|
React.createElement(Button, { variant: "primary", component: "a", href: "http://access.redhat.com/products/cloud_management_services_for_rhel#getstarted", target: "_blank", rel: "noopener noreferrer", className: "pf-u-mt-lg" }, buttonText)));
|
|
12
11
|
};
|
|
13
|
-
NotConnected.propTypes = {
|
|
14
|
-
titleText: propTypes.node,
|
|
15
|
-
bodyText: propTypes.node,
|
|
16
|
-
buttonText: propTypes.node,
|
|
17
|
-
};
|
|
18
|
-
NotConnected.defaultProps = {
|
|
19
|
-
titleText: 'This system isn’t connected to Insights yet',
|
|
20
|
-
bodyText: 'To get started, activate the Insights client for this system.',
|
|
21
|
-
buttonText: 'Learn how to activate the Insights client',
|
|
22
|
-
};
|
|
23
12
|
export default NotConnected;
|
|
24
13
|
//# sourceMappingURL=NotConnected.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotConnected.js","sourceRoot":"","sources":["../../src/NotConnected/NotConnected.
|
|
1
|
+
{"version":3,"file":"NotConnected.js","sourceRoot":"","sources":["../../src/NotConnected/NotConnected.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AACnG,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAQ3D,IAAM,YAAY,GAAgC,UAAC,EAIlD;QAHC,iBAAyD,EAAzD,SAAS,mBAAG,6CAA6C,KAAA,EACzD,gBAA0E,EAA1E,QAAQ,mBAAG,+DAA+D,KAAA,EAC1E,kBAAwD,EAAxD,UAAU,mBAAG,2CAA2C,KAAA;IACpD,OAAA,CACJ,oBAAC,UAAU;QACT,oBAAC,cAAc,IAAC,IAAI,EAAE,gBAAgB,GAAI;QAC1C,oBAAC,KAAK,IAAC,YAAY,EAAC,IAAI,EAAC,IAAI,EAAC,IAAI,IAC/B,SAAS,CACJ;QACR,oBAAC,cAAc,QAAE,QAAQ,CAAkB;QAC3C,oBAAC,MAAM,IACL,OAAO,EAAC,SAAS,EACjB,SAAS,EAAC,GAAG,EACb,IAAI,EAAC,iFAAiF,EACtF,MAAM,EAAC,QAAQ,EACf,GAAG,EAAC,qBAAqB,EACzB,SAAS,EAAC,YAAY,IAErB,UAAU,CACJ,CACE,CACd;AAlBK,CAkBL,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/NotConnected/index.
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/NotConnected/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AACzC,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACzD,cAAc,gBAAgB,CAAC"}
|
package/esm/Ouia/Ouia.js
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
2
|
+
var t = {};
|
|
3
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
4
|
+
t[p] = s[p];
|
|
5
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
+
t[p[i]] = s[p[i]];
|
|
9
|
+
}
|
|
10
|
+
return t;
|
|
11
|
+
};
|
|
12
|
+
export var withoutOuiaProps = function (props) {
|
|
13
|
+
var ouiaId = props.ouiaId, ouiaSafe = props.ouiaSafe, rest = __rest(props, ["ouiaId", "ouiaSafe"]);
|
|
14
|
+
return rest;
|
|
15
|
+
};
|
|
16
|
+
export var makeOuiaAttributes = function (params) {
|
|
17
|
+
var _a;
|
|
18
|
+
var ouiaData = {
|
|
19
|
+
'data-ouia-component-type': params.fullType,
|
|
20
|
+
'data-ouia-safe': (_a = params.ouiaSafe) !== null && _a !== void 0 ? _a : true,
|
|
21
|
+
};
|
|
22
|
+
if (params.ouiaId) {
|
|
23
|
+
ouiaData['data-ouia-component-id'] = params.ouiaId;
|
|
24
|
+
}
|
|
25
|
+
return ouiaData;
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=Ouia.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Ouia.js","sourceRoot":"","sources":["../../src/Ouia/Ouia.ts"],"names":[],"mappings":";;;;;;;;;;;AAyBA,MAAM,CAAC,IAAM,gBAAgB,GAAG,UAAsB,KAAQ;IACpD,IAAA,MAAM,GAAwB,KAAK,OAA7B,EAAE,QAAQ,GAAc,KAAK,SAAnB,EAAK,IAAI,UAAK,KAAK,EAArC,sBAA6B,CAAF,CAAW;IAC5C,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAEF,MAAM,CAAC,IAAM,kBAAkB,GAAG,UAAC,MAAkB;;IACnD,IAAM,QAAQ,GAAuB;QACnC,0BAA0B,EAAE,MAAM,CAAC,QAAQ;QAC3C,gBAAgB,EAAE,MAAA,MAAM,CAAC,QAAQ,mCAAI,IAAI;KAC1C,CAAC;IAEF,IAAI,MAAM,CAAC,MAAM,EAAE;QACjB,QAAQ,CAAC,wBAAwB,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC;KACpD;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
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
|
+
import React from 'react';
|
|
13
|
+
import { makeOuiaAttributes } from './Ouia';
|
|
14
|
+
var WithOuia = function (Component, params) {
|
|
15
|
+
var type = typeof params === 'string' ? params : params.module ? "".concat(params.module, "/").concat(params.type) : params.type;
|
|
16
|
+
var InnerComponent = typeof params !== 'string' && params.InnerComponent !== undefined ? params.InnerComponent : 'div';
|
|
17
|
+
var withOuia = function (props) {
|
|
18
|
+
var ouiaData = makeOuiaAttributes({
|
|
19
|
+
fullType: type,
|
|
20
|
+
ouiaId: props.ouiaId,
|
|
21
|
+
ouiaSafe: props.ouiaSafe,
|
|
22
|
+
});
|
|
23
|
+
return (React.createElement(InnerComponent, __assign({}, ouiaData),
|
|
24
|
+
React.createElement(Component, __assign({}, props), props.children)));
|
|
25
|
+
};
|
|
26
|
+
return withOuia;
|
|
27
|
+
};
|
|
28
|
+
export default WithOuia;
|
|
29
|
+
//# sourceMappingURL=WithOuia.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WithOuia.js","sourceRoot":"","sources":["../../src/Ouia/WithOuia.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAiC,kBAAkB,EAAE,MAAM,QAAQ,CAAC;AAoB3E,IAAM,QAAQ,GAAG,UAAK,SAAiC,EAAE,MAAsB;IAC7E,IAAM,IAAI,GAAG,OAAO,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,UAAG,MAAM,CAAC,MAAM,cAAI,MAAM,CAAC,IAAI,CAAE,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC;IACnH,IAAM,cAAc,GAAG,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,CAAC,cAAc,KAAK,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC,KAAK,CAAC;IAEzH,IAAM,QAAQ,GAAuC,UAAC,KAAK;QACzD,IAAM,QAAQ,GAAG,kBAAkB,CAAC;YAClC,QAAQ,EAAE,IAAI;YACd,MAAM,EAAE,KAAK,CAAC,MAAM;YACpB,QAAQ,EAAE,KAAK,CAAC,QAAQ;SACzB,CAAC,CAAC;QAEH,OAAO,CACL,oBAAC,cAAc,eAAK,QAAQ;YAC1B,oBAAC,SAAS,eAAK,KAAK,GAAG,KAAK,CAAC,QAAQ,CAAa,CACnC,CAClB,CAAC;IACJ,CAAC,CAAC;IAEF,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Ouia/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiC,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AACzE,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAkB,MAAM,YAAY,CAAC;AACjE,OAAO,EAAE,OAAO,IAAI,OAAO,EAAiB,MAAM,WAAW,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { makeOuiaAttributes } from './Ouia';
|
|
2
|
+
var useOuia = function (ouiaParams) {
|
|
3
|
+
var type = ouiaParams.module !== undefined ? "".concat(ouiaParams.module, "/").concat(ouiaParams.type) : ouiaParams.type;
|
|
4
|
+
return makeOuiaAttributes({
|
|
5
|
+
fullType: type,
|
|
6
|
+
ouiaId: ouiaParams.ouiaId,
|
|
7
|
+
ouiaSafe: ouiaParams.ouiaSafe,
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
export default useOuia;
|
|
11
|
+
//# sourceMappingURL=useOuia.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useOuia.js","sourceRoot":"","sources":["../../src/Ouia/useOuia.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAiC,MAAM,QAAQ,CAAC;AAe3E,IAAM,OAAO,GAAG,UAAC,UAAyB;IACxC,IAAM,IAAI,GAAG,UAAU,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,UAAG,UAAU,CAAC,MAAM,cAAI,UAAU,CAAC,IAAI,CAAE,CAAC,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC;IAE3G,OAAO,kBAAkB,CAAC;QACxB,QAAQ,EAAE,IAAI;QACd,MAAM,EAAE,UAAU,CAAC,MAAM;QACzB,QAAQ,EAAE,UAAU,CAAC,QAAQ;KAC9B,CAAC,CAAC;AACL,CAAC,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
package/esm/Reboot/Reboot.js
CHANGED
|
@@ -21,7 +21,6 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
21
21
|
return t;
|
|
22
22
|
};
|
|
23
23
|
import React from 'react';
|
|
24
|
-
import propTypes from 'prop-types';
|
|
25
24
|
import classNames from 'classnames';
|
|
26
25
|
import { RebootingIcon } from '@patternfly/react-icons';
|
|
27
26
|
import '../Reboot/reboot.css';
|
|
@@ -34,8 +33,4 @@ var Reboot = function (_a) {
|
|
|
34
33
|
React.createElement("span", null, "Reboot required")));
|
|
35
34
|
};
|
|
36
35
|
export default Reboot;
|
|
37
|
-
Reboot.propTypes = {
|
|
38
|
-
className: propTypes.string,
|
|
39
|
-
red: propTypes.bool,
|
|
40
|
-
};
|
|
41
36
|
//# sourceMappingURL=Reboot.js.map
|
package/esm/Reboot/Reboot.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Reboot.js","sourceRoot":"","sources":["../../src/Reboot/Reboot.
|
|
1
|
+
{"version":3,"file":"Reboot.js","sourceRoot":"","sources":["../../src/Reboot/Reboot.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,UAAU,MAAM,YAAY,CAAC;AACpC,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAExD,OAAO,eAAe,CAAC;AAOvB,IAAM,MAAM,GAA0B,UAAC,EAA4B;;IAA1B,IAAA,GAAG,SAAA,EAAE,SAAS,eAAA,EAAK,KAAK,cAA1B,oBAA4B,CAAF;IAC/D,IAAM,iBAAiB,GAAG,UAAU,CAAC,cAAc,YAAI,GAAC,WAAW,IAAG,GAAG,OAAI,SAAS,CAAC,CAAC;IAExF,OAAO,CACL,uCAAM,SAAS,EAAE,iBAAiB,IAAM,KAAK;QAC3C,oBAAC,aAAa,OAAG;QACjB,oDAA4B,CACvB,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
package/esm/Reboot/index.js
CHANGED
package/esm/Reboot/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Reboot/index.
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Reboot/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACnC,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,UAAU,CAAC;AAC7C,cAAc,UAAU,CAAC"}
|
|
@@ -1,18 +1,3 @@
|
|
|
1
|
-
var __extends = (this && this.__extends) || (function () {
|
|
2
|
-
var extendStatics = function (d, b) {
|
|
3
|
-
extendStatics = Object.setPrototypeOf ||
|
|
4
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
6
|
-
return extendStatics(d, b);
|
|
7
|
-
};
|
|
8
|
-
return function (d, b) {
|
|
9
|
-
if (typeof b !== "function" && b !== null)
|
|
10
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
11
|
-
extendStatics(d, b);
|
|
12
|
-
function __() { this.constructor = d; }
|
|
13
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
|
-
};
|
|
15
|
-
})();
|
|
16
1
|
var __assign = (this && this.__assign) || function () {
|
|
17
2
|
__assign = Object.assign || function(t) {
|
|
18
3
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
@@ -35,85 +20,38 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
35
20
|
}
|
|
36
21
|
return t;
|
|
37
22
|
};
|
|
38
|
-
import React, {
|
|
39
|
-
import PropTypes from 'prop-types';
|
|
23
|
+
import React, { useState } from 'react';
|
|
40
24
|
import { Button, ButtonVariant, Dropdown, DropdownToggle, DropdownItem } from '@patternfly/react-core';
|
|
41
25
|
import { Input } from '../Input';
|
|
42
26
|
import { SearchIcon } from '@patternfly/react-icons';
|
|
43
27
|
import '../SimpleTableFilter/simple-table-filter.css';
|
|
44
|
-
var SimpleFilter =
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
isOpen: isOpen,
|
|
55
|
-
});
|
|
56
|
-
};
|
|
57
|
-
_this.onInputChange = function (event) {
|
|
58
|
-
_this.setState({ activeFilter: event.target.value });
|
|
59
|
-
_this.props.onFilterChange(event.target.value, _this.state.selected);
|
|
60
|
-
};
|
|
61
|
-
_this.onFilterSubmit = function () {
|
|
62
|
-
_this.props.onButtonClick(_this.state.activeFilter, _this.state.selected);
|
|
63
|
-
};
|
|
64
|
-
_this.onFilterSelect = function (event, oneItem) {
|
|
65
|
-
_this.setState({
|
|
66
|
-
selected: oneItem,
|
|
67
|
-
});
|
|
68
|
-
_this.props.onOptionSelect(event, oneItem);
|
|
69
|
-
};
|
|
70
|
-
_this.onSelect = function () {
|
|
71
|
-
_this.setState({
|
|
72
|
-
isOpen: false,
|
|
73
|
-
});
|
|
74
|
-
};
|
|
75
|
-
return _this;
|
|
76
|
-
}
|
|
77
|
-
SimpleFilter.prototype.render = function () {
|
|
78
|
-
var _this = this;
|
|
79
|
-
var _a = this.props, placeholder = _a.placeholder, buttonTitle = _a.buttonTitle, className = _a.className, onButtonClick = _a.onButtonClick, onOptionSelect = _a.onOptionSelect, onFilterChange = _a.onFilterChange, options = _a.options, searchIcon = _a.searchIcon, widgetId = _a.widgetId, props = __rest(_a, ["placeholder", "buttonTitle", "className", "onButtonClick", "onOptionSelect", "onFilterChange", "options", "searchIcon", "widgetId"]);
|
|
80
|
-
var _b = this.state, isOpen = _b.isOpen, selected = _b.selected;
|
|
81
|
-
var dropdownItems = options &&
|
|
82
|
-
options.items &&
|
|
83
|
-
options.items.map(function (oneItem) { return (React.createElement(DropdownItem, { component: "button", key: oneItem.value, onClick: function (event) { return _this.onFilterSelect(event, oneItem); }, "data-key": oneItem.value }, oneItem.title)); });
|
|
84
|
-
return (React.createElement("div", __assign({ className: "pf-c-input-group ins-c-filter ".concat(!buttonTitle ? 'ins-u-no-title' : '', " ").concat(className) }, props),
|
|
85
|
-
options && (React.createElement(Dropdown, { onSelect: this.onSelect, isOpen: isOpen, toggle: React.createElement(DropdownToggle, { onToggle: this.onToggle }, (selected && selected.title) || options.title || 'Dropdown'), dropdownItems: dropdownItems })),
|
|
86
|
-
React.createElement(Input, { placeholder: placeholder, onKeyPress: function (event) { return event.key === 'Enter' && _this.onInputChange(event); }, "widget-id": widgetId, onChange: this.onInputChange }),
|
|
87
|
-
!buttonTitle && searchIcon && React.createElement(SearchIcon, { size: "sm", className: "ins-c-search-icon" }),
|
|
88
|
-
buttonTitle && (React.createElement(Button, { variant: ButtonVariant.secondary, action: "filter", onClick: this.onFilterSubmit }, buttonTitle))));
|
|
28
|
+
var SimpleFilter = function (_a) {
|
|
29
|
+
var options = _a.options, widgetId = _a.widgetId, _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.placeholder, placeholder = _c === void 0 ? 'Search items' : _c, _d = _a.buttonTitle, buttonTitle = _d === void 0 ? 'Filter' : _d, _e = _a.onButtonClick, onButtonClick = _e === void 0 ? function () { return undefined; } : _e, _f = _a.onFilterChange, onFilterChange = _f === void 0 ? function () { return undefined; } : _f, _g = _a.onOptionSelect, onOptionSelect = _g === void 0 ? function () { return undefined; } : _g, _h = _a.searchIcon, searchIcon = _h === void 0 ? true : _h, props = __rest(_a, ["options", "widgetId", "className", "placeholder", "buttonTitle", "onButtonClick", "onFilterChange", "onOptionSelect", "searchIcon"]);
|
|
30
|
+
var _j = useState(''), activeFilter = _j[0], setActiveFilter = _j[1];
|
|
31
|
+
var _k = useState(false), isOpen = _k[0], setIsOpen = _k[1];
|
|
32
|
+
var _l = useState(), selected = _l[0], setSelected = _l[1];
|
|
33
|
+
var onToggle = function (isOpen) { return setIsOpen(isOpen); };
|
|
34
|
+
var onInputChange = function (event) {
|
|
35
|
+
var _a;
|
|
36
|
+
setActiveFilter((_a = event.target) === null || _a === void 0 ? void 0 : _a.value);
|
|
37
|
+
onFilterChange(event.target.value, selected);
|
|
89
38
|
};
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
items
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
})),
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
onOptionSelect: PropTypes.func,
|
|
107
|
-
searchIcon: PropTypes.bool,
|
|
108
|
-
};
|
|
109
|
-
SimpleFilter.defaultProps = {
|
|
110
|
-
className: '',
|
|
111
|
-
placeholder: 'Search items',
|
|
112
|
-
buttonTitle: 'Filter',
|
|
113
|
-
onButtonClick: function () { return undefined; },
|
|
114
|
-
onFilterChange: function () { return undefined; },
|
|
115
|
-
onOptionSelect: function () { return undefined; },
|
|
116
|
-
searchIcon: true,
|
|
39
|
+
var onFilterSubmit = function () {
|
|
40
|
+
onButtonClick(activeFilter, selected);
|
|
41
|
+
};
|
|
42
|
+
var onFilterSelect = function (event, oneItem) {
|
|
43
|
+
setSelected(oneItem);
|
|
44
|
+
onOptionSelect(event, oneItem);
|
|
45
|
+
};
|
|
46
|
+
var onSelect = function () { return setIsOpen(false); };
|
|
47
|
+
var dropdownItems = options &&
|
|
48
|
+
options.items &&
|
|
49
|
+
options.items.map(function (oneItem) { return (React.createElement(DropdownItem, { component: "button", key: oneItem.value, onClick: function (event) { return onFilterSelect(event, oneItem); }, "data-key": oneItem.value }, oneItem.title)); });
|
|
50
|
+
return (React.createElement("div", __assign({ className: "pf-c-input-group ins-c-filter ".concat(!buttonTitle ? 'ins-u-no-title' : '', " ").concat(className) }, props),
|
|
51
|
+
options && (React.createElement(Dropdown, { onSelect: onSelect, isOpen: isOpen, toggle: React.createElement(DropdownToggle, { onToggle: onToggle }, (selected && selected.title) || options.title || 'Dropdown'), dropdownItems: dropdownItems })),
|
|
52
|
+
React.createElement(Input, { placeholder: placeholder, onKeyPress: function (event) { return event.key === 'Enter' && onInputChange(event); }, "widget-id": widgetId, onChange: function (event) { return onInputChange(event); } }),
|
|
53
|
+
!buttonTitle && searchIcon && React.createElement(SearchIcon, { size: "sm", className: "ins-c-search-icon" }),
|
|
54
|
+
buttonTitle && (React.createElement(Button, { variant: ButtonVariant.secondary, action: "filter", onClick: onFilterSubmit }, buttonTitle))));
|
|
117
55
|
};
|
|
118
56
|
export default SimpleFilter;
|
|
119
57
|
//# sourceMappingURL=SimpleTableFilter.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SimpleTableFilter.js","sourceRoot":"","sources":["../../src/SimpleTableFilter/SimpleTableFilter.
|
|
1
|
+
{"version":3,"file":"SimpleTableFilter.js","sourceRoot":"","sources":["../../src/SimpleTableFilter/SimpleTableFilter.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,QAAQ,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACvG,OAAO,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AACjC,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,4BAA4B,CAAC;AAwBpC,IAAM,YAAY,GAAgC,UAAC,EAWlD;IAVC,IAAA,OAAO,aAAA,EACP,QAAQ,cAAA,EACR,iBAAc,EAAd,SAAS,mBA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AAC,MAAM,IAAC,OAAO,EAAE,aAAa,CAAC,SAAS,EAAE,MAAM,EAAC,QAAQ,EAAC,OAAO,EAAE,cAAc,IAC9E,WAAW,CACL,CACV,CACG,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/SimpleTableFilter/index.
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/SimpleTableFilter/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACnE,cAAc,qBAAqB,CAAC"}
|