@patternfly/react-core 4.168.9 → 4.169.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/CHANGELOG.md +44 -0
- package/dist/esm/components/AboutModal/AboutModal.d.ts +2 -0
- package/dist/esm/components/AboutModal/AboutModal.d.ts.map +1 -1
- package/dist/esm/components/AboutModal/AboutModal.js.map +1 -1
- package/dist/esm/components/AboutModal/AboutModalContainer.d.ts +2 -0
- package/dist/esm/components/AboutModal/AboutModalContainer.d.ts.map +1 -1
- package/dist/esm/components/AboutModal/AboutModalContainer.js +2 -2
- package/dist/esm/components/AboutModal/AboutModalContainer.js.map +1 -1
- package/dist/esm/components/Banner/Banner.d.ts +1 -1
- package/dist/esm/components/Banner/Banner.d.ts.map +1 -1
- package/dist/esm/components/Banner/Banner.js +5 -1
- package/dist/esm/components/Banner/Banner.js.map +1 -1
- package/dist/esm/components/Dropdown/DropdownGroup.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/DropdownGroup.js +10 -6
- package/dist/esm/components/Dropdown/DropdownGroup.js.map +1 -1
- package/dist/esm/components/TextInput/TextInput.d.ts +1 -0
- package/dist/esm/components/TextInput/TextInput.d.ts.map +1 -1
- package/dist/esm/components/TextInput/TextInput.js +6 -7
- package/dist/esm/components/TextInput/TextInput.js.map +1 -1
- package/dist/esm/helpers/index.d.ts +1 -0
- package/dist/esm/helpers/index.d.ts.map +1 -1
- package/dist/esm/helpers/index.js +1 -0
- package/dist/esm/helpers/index.js.map +1 -1
- package/dist/esm/helpers/resizeObserver.d.ts +62 -0
- package/dist/esm/helpers/resizeObserver.d.ts.map +1 -0
- package/dist/esm/helpers/resizeObserver.js +89 -0
- package/dist/esm/helpers/resizeObserver.js.map +1 -0
- package/dist/js/components/AboutModal/AboutModal.d.ts +2 -0
- package/dist/js/components/AboutModal/AboutModal.d.ts.map +1 -1
- package/dist/js/components/AboutModal/AboutModal.js.map +1 -1
- package/dist/js/components/AboutModal/AboutModalContainer.d.ts +2 -0
- package/dist/js/components/AboutModal/AboutModalContainer.d.ts.map +1 -1
- package/dist/js/components/AboutModal/AboutModalContainer.js +2 -2
- package/dist/js/components/AboutModal/AboutModalContainer.js.map +1 -1
- package/dist/js/components/Banner/Banner.d.ts +1 -1
- package/dist/js/components/Banner/Banner.d.ts.map +1 -1
- package/dist/js/components/Banner/Banner.js +4 -1
- package/dist/js/components/Banner/Banner.js.map +1 -1
- package/dist/js/components/Dropdown/DropdownGroup.d.ts.map +1 -1
- package/dist/js/components/Dropdown/DropdownGroup.js +9 -6
- package/dist/js/components/Dropdown/DropdownGroup.js.map +1 -1
- package/dist/js/components/TextInput/TextInput.d.ts +1 -0
- package/dist/js/components/TextInput/TextInput.d.ts.map +1 -1
- package/dist/js/components/TextInput/TextInput.js +5 -6
- package/dist/js/components/TextInput/TextInput.js.map +1 -1
- package/dist/js/helpers/index.d.ts +1 -0
- package/dist/js/helpers/index.d.ts.map +1 -1
- package/dist/js/helpers/index.js +1 -0
- package/dist/js/helpers/index.js.map +1 -1
- package/dist/js/helpers/resizeObserver.d.ts +62 -0
- package/dist/js/helpers/resizeObserver.d.ts.map +1 -0
- package/dist/js/helpers/resizeObserver.js +93 -0
- package/dist/js/helpers/resizeObserver.js.map +1 -0
- package/dist/umd/react-core.js +108 -15
- package/dist/umd/react-core.min.js +3 -3
- package/package.json +5 -5
- package/src/components/AboutModal/AboutModal.tsx +2 -0
- package/src/components/AboutModal/AboutModalContainer.tsx +8 -1
- package/src/components/Banner/Banner.tsx +4 -2
- package/src/components/Banner/__tests__/__snapshots__/Banner.test.tsx.snap +6 -0
- package/src/components/Dropdown/DropdownGroup.tsx +3 -2
- package/src/components/TextInput/TextInput.tsx +6 -7
- package/src/helpers/index.ts +1 -0
- package/src/helpers/resizeObserver.tsx +90 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropdownGroup.d.ts","sourceRoot":"","sources":["../../../../src/components/Dropdown/DropdownGroup.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,MAAM,WAAW,kBAAmB,SAAQ,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,EAAE,OAAO,CAAC;IACxF,8BAA8B;IAC9B,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,4DAA4D;IAC5D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,kBAAkB;IAClB,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACzB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,iBAAiB,CAAC,kBAAkB,
|
|
1
|
+
{"version":3,"file":"DropdownGroup.d.ts","sourceRoot":"","sources":["../../../../src/components/Dropdown/DropdownGroup.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,MAAM,WAAW,kBAAmB,SAAQ,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,EAAE,OAAO,CAAC;IACxF,8BAA8B;IAC9B,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,4DAA4D;IAC5D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,kBAAkB;IAClB,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACzB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,iBAAiB,CAAC,kBAAkB,CAqBrE,CAAC"}
|
|
@@ -5,12 +5,15 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
const React = tslib_1.__importStar(require("react"));
|
|
6
6
|
const react_styles_1 = require("@patternfly/react-styles");
|
|
7
7
|
const dropdownConstants_1 = require("./dropdownConstants");
|
|
8
|
-
const DropdownGroup = (
|
|
9
|
-
|
|
10
|
-
return (React.createElement(
|
|
11
|
-
|
|
12
|
-
React.createElement(
|
|
13
|
-
}))
|
|
8
|
+
const DropdownGroup = (_a) => {
|
|
9
|
+
var { children = null, className = '', label = '' } = _a, props = tslib_1.__rest(_a, ["children", "className", "label"]);
|
|
10
|
+
return (React.createElement(dropdownConstants_1.DropdownContext.Consumer, null, ({ sectionClass, sectionTitleClass, sectionComponent }) => {
|
|
11
|
+
const SectionComponent = sectionComponent;
|
|
12
|
+
return (React.createElement(SectionComponent, Object.assign({ className: react_styles_1.css(sectionClass, className) }, props),
|
|
13
|
+
label && (React.createElement("h1", { className: react_styles_1.css(sectionTitleClass), "aria-hidden": true }, label)),
|
|
14
|
+
React.createElement("ul", { role: "none" }, children)));
|
|
15
|
+
}));
|
|
16
|
+
};
|
|
14
17
|
exports.DropdownGroup = DropdownGroup;
|
|
15
18
|
exports.DropdownGroup.displayName = 'DropdownGroup';
|
|
16
19
|
//# sourceMappingURL=DropdownGroup.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropdownGroup.js","sourceRoot":"","sources":["../../../../src/components/Dropdown/DropdownGroup.tsx"],"names":[],"mappings":";;;;AAAA,qDAA+B;AAC/B,2DAA+C;AAC/C,2DAAsD;AAW/C,MAAM,aAAa,GAAgD,CAAC,EACzE,QAAQ,GAAG,IAAI,EACf,SAAS,GAAG,EAAE,EACd,KAAK,GAAG,EAAE,
|
|
1
|
+
{"version":3,"file":"DropdownGroup.js","sourceRoot":"","sources":["../../../../src/components/Dropdown/DropdownGroup.tsx"],"names":[],"mappings":";;;;AAAA,qDAA+B;AAC/B,2DAA+C;AAC/C,2DAAsD;AAW/C,MAAM,aAAa,GAAgD,CAAC,EAKtD,EAAE,EAAE;QALkD,EACzE,QAAQ,GAAG,IAAI,EACf,SAAS,GAAG,EAAE,EACd,KAAK,GAAG,EAAE,OAES,EADhB,KAAK,sBAJiE,kCAK1E,CADS;IACgB,OAAA,CACxB,oBAAC,mCAAe,CAAC,QAAQ,QACtB,CAAC,EAAE,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,EAAE,EAAE;QACzD,MAAM,gBAAgB,GAAG,gBAAuB,CAAC;QACjD,OAAO,CACL,oBAAC,gBAAgB,kBAAC,SAAS,EAAE,kBAAG,CAAC,YAAY,EAAE,SAAS,CAAC,IAAM,KAAK;YACjE,KAAK,IAAI,CACR,4BAAI,SAAS,EAAE,kBAAG,CAAC,iBAAiB,CAAC,yBAClC,KAAK,CACH,CACN;YACD,4BAAI,IAAI,EAAC,MAAM,IAAE,QAAQ,CAAM,CACd,CACpB,CAAC;IACJ,CAAC,CACwB,CAC5B,CAAA;CAAA,CAAC;AArBW,QAAA,aAAa,iBAqBxB;AACF,qBAAa,CAAC,WAAW,GAAG,eAAe,CAAC"}
|
|
@@ -57,6 +57,7 @@ export declare class TextInputBase extends React.Component<TextInputProps, TextI
|
|
|
57
57
|
static displayName: string;
|
|
58
58
|
static defaultProps: TextInputProps;
|
|
59
59
|
inputRef: React.RefObject<HTMLInputElement>;
|
|
60
|
+
observer: any;
|
|
60
61
|
constructor(props: TextInputProps);
|
|
61
62
|
handleChange: (event: React.FormEvent<HTMLInputElement>) => void;
|
|
62
63
|
componentDidMount(): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../src/components/TextInput/TextInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,OAAO,EAAkC,SAAS,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../src/components/TextInput/TextInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,OAAO,EAAkC,SAAS,EAAE,MAAM,eAAe,CAAC;AAG1E,oBAAY,cAAc;IACxB,IAAI,SAAS;IACb,IAAI,SAAS;IACb,aAAa,mBAAmB;IAChC,KAAK,UAAU;IACf,KAAK,UAAU;IACf,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,MAAM,WAAW;IACjB,GAAG,QAAQ;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ACnB,WAAW,CAAC,EAAE,UAAU,GAAG,OAAO,GAAG,QAAQ,CAAC;IAC9C,6DAA6D;IAC7D,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,wEAAwE;IACxE,oBAAoB,CAAC,EAAE,MAAM,CAAC;CAC/B;AAED,UAAU,cAAc;IACtB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,qBAAa,aAAc,SAAQ,KAAK,CAAC,SAAS,CAAC,cAAc,EAAE,cAAc,CAAC;IAChF,MAAM,CAAC,WAAW,SAAmB;IACrC,MAAM,CAAC,YAAY,EAAE,cAAc,CAWjC;IACF,QAAQ,oCAAuC;IAC/C,QAAQ,EAAE,GAAG,CAAY;gBAEb,KAAK,EAAE,cAAc;IAWjC,YAAY,UAAW,MAAM,SAAS,CAAC,gBAAgB,CAAC,UAItD;IAEF,iBAAiB;IAQjB,oBAAoB;IAMpB,YAAY,aAKV;IAEF,WAAW,aAMT;IAEF,OAAO,WAAY,GAAG,UAMpB;IAEF,MAAM,WAAY,GAAG,UAMnB;IAEF,MAAM;CA0DP;AAED,eAAO,MAAM,SAAS,yFAEpB,CAAC"}
|
|
@@ -8,6 +8,7 @@ const react_styles_1 = require("@patternfly/react-styles");
|
|
|
8
8
|
const constants_1 = require("../../helpers/constants");
|
|
9
9
|
const util_1 = require("../../helpers/util");
|
|
10
10
|
const helpers_1 = require("../../helpers");
|
|
11
|
+
const resizeObserver_1 = require("../../helpers/resizeObserver");
|
|
11
12
|
var TextInputTypes;
|
|
12
13
|
(function (TextInputTypes) {
|
|
13
14
|
TextInputTypes["text"] = "text";
|
|
@@ -26,6 +27,7 @@ class TextInputBase extends React.Component {
|
|
|
26
27
|
constructor(props) {
|
|
27
28
|
super(props);
|
|
28
29
|
this.inputRef = React.createRef();
|
|
30
|
+
this.observer = () => { };
|
|
29
31
|
this.handleChange = (event) => {
|
|
30
32
|
if (this.props.onChange) {
|
|
31
33
|
this.props.onChange(event.currentTarget.value, event);
|
|
@@ -68,17 +70,14 @@ class TextInputBase extends React.Component {
|
|
|
68
70
|
}
|
|
69
71
|
componentDidMount() {
|
|
70
72
|
if (this.props.isLeftTruncated) {
|
|
73
|
+
const inputRef = this.props.innerRef || this.inputRef;
|
|
74
|
+
this.observer = resizeObserver_1.getResizeObserver(inputRef.current, this.handleResize);
|
|
71
75
|
this.handleResize();
|
|
72
|
-
if (util_1.canUseDOM) {
|
|
73
|
-
window.addEventListener('resize', util_1.debounce(this.handleResize, 250));
|
|
74
|
-
}
|
|
75
76
|
}
|
|
76
77
|
}
|
|
77
78
|
componentWillUnmount() {
|
|
78
79
|
if (this.props.isLeftTruncated) {
|
|
79
|
-
|
|
80
|
-
window.removeEventListener('resize', util_1.debounce(this.handleResize, 250));
|
|
81
|
-
}
|
|
80
|
+
this.observer();
|
|
82
81
|
}
|
|
83
82
|
}
|
|
84
83
|
render() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextInput.js","sourceRoot":"","sources":["../../../../src/components/TextInput/TextInput.tsx"],"names":[],"mappings":";;;;AAAA,qDAA+B;AAC/B,4HAAsF;AACtF,2DAA+C;AAC/C,uDAA2D;AAC3D,
|
|
1
|
+
{"version":3,"file":"TextInput.js","sourceRoot":"","sources":["../../../../src/components/TextInput/TextInput.tsx"],"names":[],"mappings":";;;;AAAA,qDAA+B;AAC/B,4HAAsF;AACtF,2DAA+C;AAC/C,uDAA2D;AAC3D,6CAA8C;AAC9C,2CAA0E;AAC1E,iEAAiE;AAEjE,IAAY,cAYX;AAZD,WAAY,cAAc;IACxB,+BAAa,CAAA;IACb,+BAAa,CAAA;IACb,kDAAgC,CAAA;IAChC,iCAAe,CAAA;IACf,iCAAe,CAAA;IACf,mCAAiB,CAAA;IACjB,uCAAqB,CAAA;IACrB,mCAAiB,CAAA;IACjB,6BAAW,CAAA;IACX,+BAAa,CAAA;IACb,6BAAW,CAAA;AACb,CAAC,EAZW,cAAc,GAAd,sBAAc,KAAd,sBAAc,QAYzB;AAyDD,MAAa,aAA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e,EAAE,CAAC,EACvE,sBAAY,CAAC,iBAAS,CAAC,WAAW,EAAE,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,QAAQ,CAAC,EACzG,CACH,CAAC;IACJ,CAAC;;AAxIH,sCAyIC;AAxIQ,yBAAW,GAAG,eAAe,CAAC;AAC9B,0BAAY,GAAmB;IACpC,YAAY,EAAE,IAAI;IAClB,SAAS,EAAE,EAAE;IACb,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE,SAAwD;IACnE,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,KAAK;IACjB,IAAI,EAAE,cAAc,CAAC,IAAI;IACzB,eAAe,EAAE,KAAK;IACtB,QAAQ,EAAE,GAAQ,EAAE,CAAC,SAAS;IAC9B,QAAQ,EAAE,IAAI;CACf,CAAC;AA8HS,QAAA,SAAS,GAAG,KAAK,CAAC,UAAU,CAAC,CAAC,KAAqB,EAAE,GAAgC,EAAE,EAAE,CAAC,CACrG,oBAAC,aAAa,oBAAK,KAAK,IAAE,QAAQ,EAAE,GAAkC,IAAI,CAC3E,CAAC,CAAC;AACH,iBAAS,CAAC,WAAW,GAAG,WAAW,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AACxC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,QAAQ,CAAC;AACvB,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AACxC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,QAAQ,CAAC;AACvB,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC"}
|
package/dist/js/helpers/index.js
CHANGED
|
@@ -11,4 +11,5 @@ tslib_1.__exportStar(require("./util"), exports);
|
|
|
11
11
|
tslib_1.__exportStar(require("./Popper/Popper"), exports);
|
|
12
12
|
tslib_1.__exportStar(require("./useIsomorphicLayout"), exports);
|
|
13
13
|
tslib_1.__exportStar(require("./KeyboardHandler"), exports);
|
|
14
|
+
tslib_1.__exportStar(require("./resizeObserver"), exports);
|
|
14
15
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/helpers/index.ts"],"names":[],"mappings":";;;AAAA,sDAA4B;AAC5B,gEAAsC;AACtC,kEAAwC;AACxC,0DAAgC;AAChC,sDAA4B;AAC5B,sDAA4B;AAC5B,iDAAuB;AACvB,0DAAgC;AAChC,gEAAsC;AACtC,4DAAkC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/helpers/index.ts"],"names":[],"mappings":";;;AAAA,sDAA4B;AAC5B,gEAAsC;AACtC,kEAAwC;AACxC,0DAAgC;AAChC,sDAA4B;AAC5B,sDAA4B;AAC5B,iDAAuB;AACvB,0DAAgC;AAChC,gEAAsC;AACtC,4DAAkC;AAClC,2DAAiC"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This function creates a ResizeObserver used to handle resize events for the given containerRef. If ResizeObserver
|
|
3
|
+
* or the given containerRef are not available, a window resize event listener is used by default.
|
|
4
|
+
*
|
|
5
|
+
* Example 1:
|
|
6
|
+
*
|
|
7
|
+
* private containerRef = React.createRef<HTMLDivElement>();
|
|
8
|
+
* private observer: any = () => {};
|
|
9
|
+
*
|
|
10
|
+
* public componentDidMount() {
|
|
11
|
+
* this.observer = getResizeObserver(this.containerRef.current, this.handleResize);
|
|
12
|
+
* }
|
|
13
|
+
*
|
|
14
|
+
* public componentWillUnmount() {
|
|
15
|
+
* this.observer();
|
|
16
|
+
* }
|
|
17
|
+
*
|
|
18
|
+
* private handleResize = () => {
|
|
19
|
+
* if (this.containerRef.current && this.containerRef.current.clientWidth) {
|
|
20
|
+
* this.setState({ width: this.containerRef.current.clientWidth });
|
|
21
|
+
* }
|
|
22
|
+
* };
|
|
23
|
+
*
|
|
24
|
+
* public render() {
|
|
25
|
+
* return (
|
|
26
|
+
* <div ref={this.containerRef} >
|
|
27
|
+
* <Chart width={this.state.width} ... />
|
|
28
|
+
* </div>
|
|
29
|
+
* );
|
|
30
|
+
* }
|
|
31
|
+
*
|
|
32
|
+
* Example 2:
|
|
33
|
+
*
|
|
34
|
+
* private inputRef = React.createRef<HTMLInputElement>();
|
|
35
|
+
* private observer: any = () => {};
|
|
36
|
+
*
|
|
37
|
+
* public componentDidMount() {
|
|
38
|
+
* this.observer = getResizeObserver(this.inputRef.current, this.handleResize);
|
|
39
|
+
* }
|
|
40
|
+
*
|
|
41
|
+
* public componentWillUnmount() {
|
|
42
|
+
* this.observer();
|
|
43
|
+
* }
|
|
44
|
+
*
|
|
45
|
+
* private handleResize = () => {
|
|
46
|
+
* if (this.inputRef.current) {
|
|
47
|
+
* trimLeft(inputRef.current, String(this.props.value));
|
|
48
|
+
* }
|
|
49
|
+
* };
|
|
50
|
+
*
|
|
51
|
+
* public render() {
|
|
52
|
+
* return (
|
|
53
|
+
* <input ref={this.inputRef} ... />
|
|
54
|
+
* );
|
|
55
|
+
* }
|
|
56
|
+
*
|
|
57
|
+
* @param {Element} containerRefElement The container reference to observe
|
|
58
|
+
* @param {Function} handleResize The function to call for resize events
|
|
59
|
+
* @return {Function} The function used to unobserve resize events
|
|
60
|
+
*/
|
|
61
|
+
export declare const getResizeObserver: (containerRefElement: Element, handleResize: () => void) => () => void;
|
|
62
|
+
//# sourceMappingURL=resizeObserver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resizeObserver.d.ts","sourceRoot":"","sources":["../../../src/helpers/resizeObserver.tsx"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2DG;AACH,eAAO,MAAM,iBAAiB,wBAAyB,OAAO,gBAAgB,MAAM,IAAI,eA2BvF,CAAC"}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getResizeObserver = void 0;
|
|
4
|
+
const util_1 = require("./util");
|
|
5
|
+
/**
|
|
6
|
+
* This function creates a ResizeObserver used to handle resize events for the given containerRef. If ResizeObserver
|
|
7
|
+
* or the given containerRef are not available, a window resize event listener is used by default.
|
|
8
|
+
*
|
|
9
|
+
* Example 1:
|
|
10
|
+
*
|
|
11
|
+
* private containerRef = React.createRef<HTMLDivElement>();
|
|
12
|
+
* private observer: any = () => {};
|
|
13
|
+
*
|
|
14
|
+
* public componentDidMount() {
|
|
15
|
+
* this.observer = getResizeObserver(this.containerRef.current, this.handleResize);
|
|
16
|
+
* }
|
|
17
|
+
*
|
|
18
|
+
* public componentWillUnmount() {
|
|
19
|
+
* this.observer();
|
|
20
|
+
* }
|
|
21
|
+
*
|
|
22
|
+
* private handleResize = () => {
|
|
23
|
+
* if (this.containerRef.current && this.containerRef.current.clientWidth) {
|
|
24
|
+
* this.setState({ width: this.containerRef.current.clientWidth });
|
|
25
|
+
* }
|
|
26
|
+
* };
|
|
27
|
+
*
|
|
28
|
+
* public render() {
|
|
29
|
+
* return (
|
|
30
|
+
* <div ref={this.containerRef} >
|
|
31
|
+
* <Chart width={this.state.width} ... />
|
|
32
|
+
* </div>
|
|
33
|
+
* );
|
|
34
|
+
* }
|
|
35
|
+
*
|
|
36
|
+
* Example 2:
|
|
37
|
+
*
|
|
38
|
+
* private inputRef = React.createRef<HTMLInputElement>();
|
|
39
|
+
* private observer: any = () => {};
|
|
40
|
+
*
|
|
41
|
+
* public componentDidMount() {
|
|
42
|
+
* this.observer = getResizeObserver(this.inputRef.current, this.handleResize);
|
|
43
|
+
* }
|
|
44
|
+
*
|
|
45
|
+
* public componentWillUnmount() {
|
|
46
|
+
* this.observer();
|
|
47
|
+
* }
|
|
48
|
+
*
|
|
49
|
+
* private handleResize = () => {
|
|
50
|
+
* if (this.inputRef.current) {
|
|
51
|
+
* trimLeft(inputRef.current, String(this.props.value));
|
|
52
|
+
* }
|
|
53
|
+
* };
|
|
54
|
+
*
|
|
55
|
+
* public render() {
|
|
56
|
+
* return (
|
|
57
|
+
* <input ref={this.inputRef} ... />
|
|
58
|
+
* );
|
|
59
|
+
* }
|
|
60
|
+
*
|
|
61
|
+
* @param {Element} containerRefElement The container reference to observe
|
|
62
|
+
* @param {Function} handleResize The function to call for resize events
|
|
63
|
+
* @return {Function} The function used to unobserve resize events
|
|
64
|
+
*/
|
|
65
|
+
const getResizeObserver = (containerRefElement, handleResize) => {
|
|
66
|
+
let unobserve;
|
|
67
|
+
if (util_1.canUseDOM) {
|
|
68
|
+
const { ResizeObserver } = window;
|
|
69
|
+
if (containerRefElement && ResizeObserver) {
|
|
70
|
+
const resizeObserver = new ResizeObserver((entries) => {
|
|
71
|
+
// Wrap resize function in requestAnimationFrame to avoid "ResizeObserver loop limit exceeded" errors
|
|
72
|
+
window.requestAnimationFrame(() => {
|
|
73
|
+
if (Array.isArray(entries) && entries.length > 0) {
|
|
74
|
+
handleResize();
|
|
75
|
+
}
|
|
76
|
+
});
|
|
77
|
+
});
|
|
78
|
+
resizeObserver.observe(containerRefElement);
|
|
79
|
+
unobserve = () => resizeObserver.unobserve(containerRefElement);
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
window.addEventListener('resize', handleResize);
|
|
83
|
+
unobserve = () => window.removeEventListener('resize', handleResize);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
return () => {
|
|
87
|
+
if (unobserve) {
|
|
88
|
+
unobserve();
|
|
89
|
+
}
|
|
90
|
+
};
|
|
91
|
+
};
|
|
92
|
+
exports.getResizeObserver = getResizeObserver;
|
|
93
|
+
//# sourceMappingURL=resizeObserver.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resizeObserver.js","sourceRoot":"","sources":["../../../src/helpers/resizeObserver.tsx"],"names":[],"mappings":";;;AAAA,iCAAmC;AAEnC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2DG;AACI,MAAM,iBAAiB,GAAG,CAAC,mBAA4B,EAAE,YAAwB,EAAE,EAAE;IAC1F,IAAI,SAAc,CAAC;IAEnB,IAAI,gBAAS,EAAE;QACb,MAAM,EAAE,cAAc,EAAE,GAAG,MAAa,CAAC;QAEzC,IAAI,mBAAmB,IAAI,cAAc,EAAE;YACzC,MAAM,cAAc,GAAG,IAAI,cAAc,CAAC,CAAC,OAAY,EAAE,EAAE;gBACzD,qGAAqG;gBACrG,MAAM,CAAC,qBAAqB,CAAC,GAAG,EAAE;oBAChC,IAAI,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE;wBAChD,YAAY,EAAE,CAAC;qBAChB;gBACH,CAAC,CAAC,CAAC;YACL,CAAC,CAAC,CAAC;YACH,cAAc,CAAC,OAAO,CAAC,mBAAmB,CAAC,CAAC;YAC5C,SAAS,GAAG,GAAG,EAAE,CAAC,cAAc,CAAC,SAAS,CAAC,mBAAmB,CAAC,CAAC;SACjE;aAAM;YACL,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;YAChD,SAAS,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;SACtE;KACF;IACD,OAAO,GAAG,EAAE;QACV,IAAI,SAAS,EAAE;YACb,SAAS,EAAE,CAAC;SACb;IACH,CAAC,CAAC;AACJ,CAAC,CAAC;AA3BW,QAAA,iBAAiB,qBA2B5B"}
|
package/dist/umd/react-core.js
CHANGED
|
@@ -3308,6 +3308,94 @@
|
|
|
3308
3308
|
noSpaceHandling: false
|
|
3309
3309
|
};
|
|
3310
3310
|
|
|
3311
|
+
/**
|
|
3312
|
+
* This function creates a ResizeObserver used to handle resize events for the given containerRef. If ResizeObserver
|
|
3313
|
+
* or the given containerRef are not available, a window resize event listener is used by default.
|
|
3314
|
+
*
|
|
3315
|
+
* Example 1:
|
|
3316
|
+
*
|
|
3317
|
+
* private containerRef = React.createRef<HTMLDivElement>();
|
|
3318
|
+
* private observer: any = () => {};
|
|
3319
|
+
*
|
|
3320
|
+
* public componentDidMount() {
|
|
3321
|
+
* this.observer = getResizeObserver(this.containerRef.current, this.handleResize);
|
|
3322
|
+
* }
|
|
3323
|
+
*
|
|
3324
|
+
* public componentWillUnmount() {
|
|
3325
|
+
* this.observer();
|
|
3326
|
+
* }
|
|
3327
|
+
*
|
|
3328
|
+
* private handleResize = () => {
|
|
3329
|
+
* if (this.containerRef.current && this.containerRef.current.clientWidth) {
|
|
3330
|
+
* this.setState({ width: this.containerRef.current.clientWidth });
|
|
3331
|
+
* }
|
|
3332
|
+
* };
|
|
3333
|
+
*
|
|
3334
|
+
* public render() {
|
|
3335
|
+
* return (
|
|
3336
|
+
* <div ref={this.containerRef} >
|
|
3337
|
+
* <Chart width={this.state.width} ... />
|
|
3338
|
+
* </div>
|
|
3339
|
+
* );
|
|
3340
|
+
* }
|
|
3341
|
+
*
|
|
3342
|
+
* Example 2:
|
|
3343
|
+
*
|
|
3344
|
+
* private inputRef = React.createRef<HTMLInputElement>();
|
|
3345
|
+
* private observer: any = () => {};
|
|
3346
|
+
*
|
|
3347
|
+
* public componentDidMount() {
|
|
3348
|
+
* this.observer = getResizeObserver(this.inputRef.current, this.handleResize);
|
|
3349
|
+
* }
|
|
3350
|
+
*
|
|
3351
|
+
* public componentWillUnmount() {
|
|
3352
|
+
* this.observer();
|
|
3353
|
+
* }
|
|
3354
|
+
*
|
|
3355
|
+
* private handleResize = () => {
|
|
3356
|
+
* if (this.inputRef.current) {
|
|
3357
|
+
* trimLeft(inputRef.current, String(this.props.value));
|
|
3358
|
+
* }
|
|
3359
|
+
* };
|
|
3360
|
+
*
|
|
3361
|
+
* public render() {
|
|
3362
|
+
* return (
|
|
3363
|
+
* <input ref={this.inputRef} ... />
|
|
3364
|
+
* );
|
|
3365
|
+
* }
|
|
3366
|
+
*
|
|
3367
|
+
* @param {Element} containerRefElement The container reference to observe
|
|
3368
|
+
* @param {Function} handleResize The function to call for resize events
|
|
3369
|
+
* @return {Function} The function used to unobserve resize events
|
|
3370
|
+
*/
|
|
3371
|
+
const getResizeObserver = (containerRefElement, handleResize) => {
|
|
3372
|
+
let unobserve;
|
|
3373
|
+
if (canUseDOM) {
|
|
3374
|
+
const { ResizeObserver } = window;
|
|
3375
|
+
if (containerRefElement && ResizeObserver) {
|
|
3376
|
+
const resizeObserver = new ResizeObserver((entries) => {
|
|
3377
|
+
// Wrap resize function in requestAnimationFrame to avoid "ResizeObserver loop limit exceeded" errors
|
|
3378
|
+
window.requestAnimationFrame(() => {
|
|
3379
|
+
if (Array.isArray(entries) && entries.length > 0) {
|
|
3380
|
+
handleResize();
|
|
3381
|
+
}
|
|
3382
|
+
});
|
|
3383
|
+
});
|
|
3384
|
+
resizeObserver.observe(containerRefElement);
|
|
3385
|
+
unobserve = () => resizeObserver.unobserve(containerRefElement);
|
|
3386
|
+
}
|
|
3387
|
+
else {
|
|
3388
|
+
window.addEventListener('resize', handleResize);
|
|
3389
|
+
unobserve = () => window.removeEventListener('resize', handleResize);
|
|
3390
|
+
}
|
|
3391
|
+
}
|
|
3392
|
+
return () => {
|
|
3393
|
+
if (unobserve) {
|
|
3394
|
+
unobserve();
|
|
3395
|
+
}
|
|
3396
|
+
};
|
|
3397
|
+
};
|
|
3398
|
+
|
|
3311
3399
|
var _default$1n = {
|
|
3312
3400
|
"bullseye": "pf-l-bullseye"
|
|
3313
3401
|
};
|
|
@@ -3637,12 +3725,12 @@
|
|
|
3637
3725
|
Backdrop.displayName = 'Backdrop';
|
|
3638
3726
|
|
|
3639
3727
|
const AboutModalContainer = (_a) => {
|
|
3640
|
-
var { children, className = '', isOpen = false, onClose = () => undefined, productName = '', trademark, brandImageSrc, brandImageAlt, backgroundImageSrc, closeButtonAriaLabel, aboutModalBoxHeaderId, aboutModalBoxContentId } = _a, props = __rest$1(_a, ["children", "className", "isOpen", "onClose", "productName", "trademark", "brandImageSrc", "brandImageAlt", "backgroundImageSrc", "closeButtonAriaLabel", "aboutModalBoxHeaderId", "aboutModalBoxContentId"]);
|
|
3728
|
+
var { children, className = '', isOpen = false, onClose = () => undefined, productName = '', trademark, brandImageSrc, brandImageAlt, backgroundImageSrc, closeButtonAriaLabel, aboutModalBoxHeaderId, aboutModalBoxContentId, disableFocusTrap = false } = _a, props = __rest$1(_a, ["children", "className", "isOpen", "onClose", "productName", "trademark", "brandImageSrc", "brandImageAlt", "backgroundImageSrc", "closeButtonAriaLabel", "aboutModalBoxHeaderId", "aboutModalBoxContentId", "disableFocusTrap"]);
|
|
3641
3729
|
if (!isOpen) {
|
|
3642
3730
|
return null;
|
|
3643
3731
|
}
|
|
3644
3732
|
return (React__namespace.createElement(Backdrop, null,
|
|
3645
|
-
React__namespace.createElement(FocusTrap, { focusTrapOptions: { clickOutsideDeactivates: true }, className: css(_default$1n.bullseye) },
|
|
3733
|
+
React__namespace.createElement(FocusTrap, { active: !disableFocusTrap, focusTrapOptions: { clickOutsideDeactivates: true }, className: css(_default$1n.bullseye) },
|
|
3646
3734
|
React__namespace.createElement(AboutModalBox, { className: className, "aria-labelledby": aboutModalBoxHeaderId, "aria-describedby": aboutModalBoxContentId },
|
|
3647
3735
|
React__namespace.createElement(AboutModalBoxBrand, { src: brandImageSrc, alt: brandImageAlt }),
|
|
3648
3736
|
React__namespace.createElement(AboutModalBoxCloseButton, { "aria-label": closeButtonAriaLabel, onClose: onClose }),
|
|
@@ -4653,12 +4741,15 @@
|
|
|
4653
4741
|
};
|
|
4654
4742
|
Dropdown.displayName = 'Dropdown';
|
|
4655
4743
|
|
|
4656
|
-
const DropdownGroup = (
|
|
4657
|
-
|
|
4658
|
-
return (React__namespace.createElement(
|
|
4659
|
-
|
|
4660
|
-
React__namespace.createElement(
|
|
4661
|
-
|
|
4744
|
+
const DropdownGroup = (_a) => {
|
|
4745
|
+
var { children = null, className = '', label = '' } = _a, props = __rest$1(_a, ["children", "className", "label"]);
|
|
4746
|
+
return (React__namespace.createElement(DropdownContext.Consumer, null, ({ sectionClass, sectionTitleClass, sectionComponent }) => {
|
|
4747
|
+
const SectionComponent = sectionComponent;
|
|
4748
|
+
return (React__namespace.createElement(SectionComponent, Object.assign({ className: css(sectionClass, className) }, props),
|
|
4749
|
+
label && (React__namespace.createElement("h1", { className: css(sectionTitleClass), "aria-hidden": true }, label)),
|
|
4750
|
+
React__namespace.createElement("ul", { role: "none" }, children)));
|
|
4751
|
+
}));
|
|
4752
|
+
};
|
|
4662
4753
|
DropdownGroup.displayName = 'DropdownGroup';
|
|
4663
4754
|
|
|
4664
4755
|
class InternalDropdownItem extends React__namespace.Component {
|
|
@@ -5529,7 +5620,10 @@
|
|
|
5529
5620
|
}
|
|
5530
5621
|
};
|
|
5531
5622
|
|
|
5532
|
-
const Banner = (
|
|
5623
|
+
const Banner = (_a) => {
|
|
5624
|
+
var { children, className, variant = 'default', isSticky = false } = _a, props = __rest$1(_a, ["children", "className", "variant", "isSticky"]);
|
|
5625
|
+
return (React__namespace.createElement("div", Object.assign({ className: css(_default$13.banner, _default$13.modifiers[variant], isSticky && _default$13.modifiers.sticky, className) }, props), children));
|
|
5626
|
+
};
|
|
5533
5627
|
Banner.displayName = 'Banner';
|
|
5534
5628
|
|
|
5535
5629
|
const Brand = (_a) => {
|
|
@@ -5616,6 +5710,7 @@
|
|
|
5616
5710
|
constructor(props) {
|
|
5617
5711
|
super(props);
|
|
5618
5712
|
this.inputRef = React__namespace.createRef();
|
|
5713
|
+
this.observer = () => { };
|
|
5619
5714
|
this.handleChange = (event) => {
|
|
5620
5715
|
if (this.props.onChange) {
|
|
5621
5716
|
this.props.onChange(event.currentTarget.value, event);
|
|
@@ -5658,17 +5753,14 @@
|
|
|
5658
5753
|
}
|
|
5659
5754
|
componentDidMount() {
|
|
5660
5755
|
if (this.props.isLeftTruncated) {
|
|
5756
|
+
const inputRef = this.props.innerRef || this.inputRef;
|
|
5757
|
+
this.observer = getResizeObserver(inputRef.current, this.handleResize);
|
|
5661
5758
|
this.handleResize();
|
|
5662
|
-
if (canUseDOM) {
|
|
5663
|
-
window.addEventListener('resize', debounce$1(this.handleResize, 250));
|
|
5664
|
-
}
|
|
5665
5759
|
}
|
|
5666
5760
|
}
|
|
5667
5761
|
componentWillUnmount() {
|
|
5668
5762
|
if (this.props.isLeftTruncated) {
|
|
5669
|
-
|
|
5670
|
-
window.removeEventListener('resize', debounce$1(this.handleResize, 250));
|
|
5671
|
-
}
|
|
5763
|
+
this.observer();
|
|
5672
5764
|
}
|
|
5673
5765
|
}
|
|
5674
5766
|
render() {
|
|
@@ -20658,6 +20750,7 @@
|
|
|
20658
20750
|
exports.getNextIndex = getNextIndex;
|
|
20659
20751
|
exports.getOUIAProps = getOUIAProps;
|
|
20660
20752
|
exports.getOpacityTransition = getOpacityTransition;
|
|
20753
|
+
exports.getResizeObserver = getResizeObserver;
|
|
20661
20754
|
exports.getTextWidth = getTextWidth;
|
|
20662
20755
|
exports.getUniqueId = getUniqueId;
|
|
20663
20756
|
exports.globalBreakpoints = globalBreakpoints;
|