@patternfly/react-core 4.250.4 → 4.250.6
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 +19 -0
- package/dist/esm/next/components/Dropdown/Dropdown.d.ts +3 -1
- package/dist/esm/next/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/esm/next/components/Dropdown/Dropdown.js +4 -3
- package/dist/esm/next/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/js/next/components/Dropdown/Dropdown.d.ts +3 -1
- package/dist/js/next/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/js/next/components/Dropdown/Dropdown.js +4 -4
- package/dist/js/next/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/umd/react-core.min.css +124 -124
- package/package.json +2 -2
- package/src/components/Title/__tests__/Title.test.tsx +156 -22
- package/src/components/Title/__tests__/__snapshots__/Title.test.tsx.snap +4 -69
- package/src/next/components/Dropdown/Dropdown.tsx +9 -2
- package/src/next/components/Dropdown/examples/DropdownBasic.tsx +0 -2
- package/src/next/components/Dropdown/examples/DropdownWithDescriptions.tsx +0 -2
- package/src/next/components/Dropdown/examples/DropdownWithGroups.tsx +0 -2
- package/src/next/components/Dropdown/examples/DropdownWithKebabToggle.tsx +0 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,25 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [4.250.6](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@4.250.5...@patternfly/react-core@4.250.6) (2022-10-12)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @patternfly/react-core
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
## [4.250.5](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@4.250.4...@patternfly/react-core@4.250.5) (2022-10-12)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
|
|
19
|
+
* **Dropdown next:** Add support for forward ref and updated docs. ([#8142](https://github.com/patternfly/patternfly-react/issues/8142)) ([423dd67](https://github.com/patternfly/patternfly-react/commit/423dd67d0d81910e195722d07a3de3340eba4443))
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
6
25
|
## [4.250.4](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@4.250.3...@patternfly/react-core@4.250.4) (2022-10-12)
|
|
7
26
|
|
|
8
27
|
**Note:** Version bump only for package @patternfly/react-core
|
|
@@ -20,6 +20,8 @@ export interface DropdownProps extends MenuProps {
|
|
|
20
20
|
isScrollable?: boolean;
|
|
21
21
|
/** Min width of the menu. */
|
|
22
22
|
minWidth?: string;
|
|
23
|
+
/** @hide Forwarded ref */
|
|
24
|
+
innerRef?: React.Ref<any>;
|
|
23
25
|
}
|
|
24
|
-
export declare const Dropdown: React.
|
|
26
|
+
export declare const Dropdown: React.ForwardRefExoticComponent<DropdownProps & React.RefAttributes<any>>;
|
|
25
27
|
//# sourceMappingURL=Dropdown.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dropdown.d.ts","sourceRoot":"","sources":["../../../../../src/next/components/Dropdown/Dropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAqB,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAGxE,MAAM,WAAW,aAAc,SAAQ,SAAS;IAC9C,oDAAoD;IACpD,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,mDAAmD;IACnD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,2EAA2E;IAC3E,MAAM,EAAE,CAAC,SAAS,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,KAAK,CAAC,SAAS,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IACzC,oEAAoE;IACpE,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,kDAAkD;IAClD,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,6BAA6B;IAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;CAC3B;AA2FD,eAAO,MAAM,QAAQ,2EAEnB,CAAC"}
|
|
@@ -3,12 +3,12 @@ import React from 'react';
|
|
|
3
3
|
import { css } from '@patternfly/react-styles';
|
|
4
4
|
import { Menu, MenuContent } from '../../../components/Menu';
|
|
5
5
|
import { Popper } from '../../../helpers/Popper/Popper';
|
|
6
|
-
|
|
7
|
-
var { children, className, onSelect, isOpen, toggle, onOpenChange, isPlain, isScrollable, minWidth } = _a, props = __rest(_a, ["children", "className", "onSelect", "isOpen", "toggle", "onOpenChange", "isPlain", "isScrollable", "minWidth"]);
|
|
6
|
+
const DropdownBase = (_a) => {
|
|
7
|
+
var { children, className, onSelect, isOpen, toggle, onOpenChange, isPlain, isScrollable, minWidth, innerRef } = _a, props = __rest(_a, ["children", "className", "onSelect", "isOpen", "toggle", "onOpenChange", "isPlain", "isScrollable", "minWidth", "innerRef"]);
|
|
8
8
|
const localMenuRef = React.useRef();
|
|
9
9
|
const toggleRef = React.useRef();
|
|
10
10
|
const containerRef = React.useRef();
|
|
11
|
-
const menuRef =
|
|
11
|
+
const menuRef = innerRef || localMenuRef;
|
|
12
12
|
React.useEffect(() => {
|
|
13
13
|
const handleMenuKeys = (event) => {
|
|
14
14
|
var _a, _b, _c, _d;
|
|
@@ -55,5 +55,6 @@ export const Dropdown = (_a) => {
|
|
|
55
55
|
return (React.createElement("div", { ref: containerRef },
|
|
56
56
|
React.createElement(Popper, { trigger: toggle(toggleRef), removeFindDomNode: true, popper: menu, appendTo: containerRef.current || undefined, isVisible: isOpen })));
|
|
57
57
|
};
|
|
58
|
+
export const Dropdown = React.forwardRef((props, ref) => (React.createElement(DropdownBase, Object.assign({ innerRef: ref }, props))));
|
|
58
59
|
Dropdown.displayName = 'Dropdown';
|
|
59
60
|
//# sourceMappingURL=Dropdown.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dropdown.js","sourceRoot":"","sources":["../../../../../src/next/components/Dropdown/Dropdown.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,EAAE,IAAI,EAAE,WAAW,EAAa,MAAM,0BAA0B,CAAC;AACxE,OAAO,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;
|
|
1
|
+
{"version":3,"file":"Dropdown.js","sourceRoot":"","sources":["../../../../../src/next/components/Dropdown/Dropdown.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,EAAE,IAAI,EAAE,WAAW,EAAa,MAAM,0BAA0B,CAAC;AACxE,OAAO,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;AA0BxD,MAAM,YAAY,GAA2C,CAAC,EAY9C,EAAE,EAAE;QAZ0C,EAC5D,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,MAAM,EACN,MAAM,EACN,YAAY,EACZ,OAAO,EACP,YAAY,EACZ,QAAQ,EACR,QAAQ,OAEM,EADX,KAAK,cAXoD,4HAY7D,CADS;IAER,MAAM,YAAY,GAAG,KAAK,CAAC,MAAM,EAAkB,CAAC;IACpD,MAAM,SAAS,GAAG,KAAK,CAAC,MAAM,EAAqB,CAAC;IACpD,MAAM,YAAY,GAAG,KAAK,CAAC,MAAM,EAAkB,CAAC;IAEpD,MAAM,OAAO,GAAI,QAA4C,IAAI,YAAY,CAAC;IAC9E,KAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACnB,MAAM,cAA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K,EAAI,CAC3C,CAAC,CAAC;AACH,QAAQ,CAAC,WAAW,GAAG,UAAU,CAAC"}
|
|
@@ -20,6 +20,8 @@ export interface DropdownProps extends MenuProps {
|
|
|
20
20
|
isScrollable?: boolean;
|
|
21
21
|
/** Min width of the menu. */
|
|
22
22
|
minWidth?: string;
|
|
23
|
+
/** @hide Forwarded ref */
|
|
24
|
+
innerRef?: React.Ref<any>;
|
|
23
25
|
}
|
|
24
|
-
export declare const Dropdown: React.
|
|
26
|
+
export declare const Dropdown: React.ForwardRefExoticComponent<DropdownProps & React.RefAttributes<any>>;
|
|
25
27
|
//# sourceMappingURL=Dropdown.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dropdown.d.ts","sourceRoot":"","sources":["../../../../../src/next/components/Dropdown/Dropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAqB,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAGxE,MAAM,WAAW,aAAc,SAAQ,SAAS;IAC9C,oDAAoD;IACpD,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,mDAAmD;IACnD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,2EAA2E;IAC3E,MAAM,EAAE,CAAC,SAAS,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,KAAK,CAAC,SAAS,CAAC;IAC7D,yCAAyC;IACzC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,uDAAuD;IACvD,QAAQ,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,KAAK,IAAI,CAAC;IAC7F;yFACqF;IACrF,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;IACzC,oEAAoE;IACpE,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,kDAAkD;IAClD,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,6BAA6B;IAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"Dropdown.d.ts","sourceRoot":"","sources":["../../../../../src/next/components/Dropdown/Dropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAqB,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAGxE,MAAM,WAAW,aAAc,SAAQ,SAAS;IAC9C,oDAAoD;IACpD,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,mDAAmD;IACnD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,2EAA2E;IAC3E,MAAM,EAAE,CAAC,SAAS,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,KAAK,CAAC,SAAS,CAAC;IAC7D,yCAAyC;IACzC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,uDAAuD;IACvD,QAAQ,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,KAAK,IAAI,CAAC;IAC7F;yFACqF;IACrF,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;IACzC,oEAAoE;IACpE,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,kDAAkD;IAClD,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,6BAA6B;IAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;CAC3B;AA2FD,eAAO,MAAM,QAAQ,2EAEnB,CAAC"}
|
|
@@ -6,12 +6,12 @@ const react_1 = tslib_1.__importDefault(require("react"));
|
|
|
6
6
|
const react_styles_1 = require("@patternfly/react-styles");
|
|
7
7
|
const Menu_1 = require("../../../components/Menu");
|
|
8
8
|
const Popper_1 = require("../../../helpers/Popper/Popper");
|
|
9
|
-
const
|
|
10
|
-
var { children, className, onSelect, isOpen, toggle, onOpenChange, isPlain, isScrollable, minWidth } = _a, props = tslib_1.__rest(_a, ["children", "className", "onSelect", "isOpen", "toggle", "onOpenChange", "isPlain", "isScrollable", "minWidth"]);
|
|
9
|
+
const DropdownBase = (_a) => {
|
|
10
|
+
var { children, className, onSelect, isOpen, toggle, onOpenChange, isPlain, isScrollable, minWidth, innerRef } = _a, props = tslib_1.__rest(_a, ["children", "className", "onSelect", "isOpen", "toggle", "onOpenChange", "isPlain", "isScrollable", "minWidth", "innerRef"]);
|
|
11
11
|
const localMenuRef = react_1.default.useRef();
|
|
12
12
|
const toggleRef = react_1.default.useRef();
|
|
13
13
|
const containerRef = react_1.default.useRef();
|
|
14
|
-
const menuRef =
|
|
14
|
+
const menuRef = innerRef || localMenuRef;
|
|
15
15
|
react_1.default.useEffect(() => {
|
|
16
16
|
const handleMenuKeys = (event) => {
|
|
17
17
|
var _a, _b, _c, _d;
|
|
@@ -58,6 +58,6 @@ const Dropdown = (_a) => {
|
|
|
58
58
|
return (react_1.default.createElement("div", { ref: containerRef },
|
|
59
59
|
react_1.default.createElement(Popper_1.Popper, { trigger: toggle(toggleRef), removeFindDomNode: true, popper: menu, appendTo: containerRef.current || undefined, isVisible: isOpen })));
|
|
60
60
|
};
|
|
61
|
-
exports.Dropdown =
|
|
61
|
+
exports.Dropdown = react_1.default.forwardRef((props, ref) => (react_1.default.createElement(DropdownBase, Object.assign({ innerRef: ref }, props))));
|
|
62
62
|
exports.Dropdown.displayName = 'Dropdown';
|
|
63
63
|
//# sourceMappingURL=Dropdown.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dropdown.js","sourceRoot":"","sources":["../../../../../src/next/components/Dropdown/Dropdown.tsx"],"names":[],"m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AE,OAAO,EACZ,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,CAAC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC,EACpD,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,YAAY,IACtB,CAAC,QAAQ,IAAI;QACf,KAAK,EAAE;YACL,uBAAuB,EAAE,QAAQ;SACX;KACzB,CAAC,EACE,KAAK;QAET,8BAAC,kBAAW,QAAE,QAAQ,CAAe,CAChC,CACR,CAAC;IACF,OAAO,CACL,uCAAK,GAAG,EAAE,YAAY;QACpB,8BAAC,eAAM,IACL,OAAO,EAAE,MAAM,CAAC,SAAS,CAAC,EAC1B,iBAAiB,QACjB,MAAM,EAAE,IAAI,EACZ,QAAQ,EAAE,YAAY,CAAC,OAAO,IAAI,SAAS,EAC3C,SAAS,EAAE,MAAM,GACjB,CACE,CACP,CAAC;AACJ,CAAC,CAAC;AAEW,QAAA,QAAQ,GAAG,eAAK,CAAC,UAAU,CAAC,CAAC,KAAoB,EAAE,GAAmB,EAAE,EAAE,CAAC,CACtF,8BAAC,YAAY,kBAAC,QAAQ,EAAE,GAAG,IAAM,KAAK,EAAI,CAC3C,CAAC,CAAC;AACH,gBAAQ,CAAC,WAAW,GAAG,UAAU,CAAC"}
|
|
@@ -1585,6 +1585,55 @@ textarea.pf-c-form-control {
|
|
|
1585
1585
|
box-shadow: var(--pf-c-back-to-top--c-button--BoxShadow);
|
|
1586
1586
|
}
|
|
1587
1587
|
|
|
1588
|
+
.pf-c-background-image {
|
|
1589
|
+
--pf-c-background-image--BackgroundColor: var(--pf-global--BackgroundColor--dark-100);
|
|
1590
|
+
--pf-c-background-image--BackgroundImage: url("../../assets/images/pfbg_576.jpg");
|
|
1591
|
+
--pf-c-background-image--BackgroundImage-2x: url("../../assets/images/pfbg_576@2x.jpg");
|
|
1592
|
+
--pf-c-background-image--BackgroundImage--sm: url("../../assets/images/pfbg_768.jpg");
|
|
1593
|
+
--pf-c-background-image--BackgroundImage--sm-2x: url("../../assets/images/pfbg_768@2x.jpg");
|
|
1594
|
+
--pf-c-background-image--BackgroundImage--lg: url("../../assets/images/pfbg_2000.jpg");
|
|
1595
|
+
--pf-c-background-image--Filter: url("#image_overlay");
|
|
1596
|
+
}
|
|
1597
|
+
|
|
1598
|
+
.pf-c-background-image::before {
|
|
1599
|
+
position: fixed;
|
|
1600
|
+
top: 0;
|
|
1601
|
+
left: 0;
|
|
1602
|
+
z-index: -1;
|
|
1603
|
+
width: 100%;
|
|
1604
|
+
height: 100%;
|
|
1605
|
+
content: "";
|
|
1606
|
+
background-color: var(--pf-c-background-image--BackgroundColor);
|
|
1607
|
+
background-image: var(--pf-c-background-image--BackgroundImage);
|
|
1608
|
+
filter: var(--pf-c-background-image--Filter);
|
|
1609
|
+
background-repeat: no-repeat;
|
|
1610
|
+
background-size: cover;
|
|
1611
|
+
}
|
|
1612
|
+
|
|
1613
|
+
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
|
|
1614
|
+
.pf-c-background-image::before {
|
|
1615
|
+
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage-2x);
|
|
1616
|
+
}
|
|
1617
|
+
}
|
|
1618
|
+
@media (min-width: 576px) {
|
|
1619
|
+
.pf-c-background-image::before {
|
|
1620
|
+
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage--sm);
|
|
1621
|
+
}
|
|
1622
|
+
}
|
|
1623
|
+
@media (min-width: 576px) and (-webkit-min-device-pixel-ratio: 2), (min-width: 576px) and (min-resolution: 192dpi) {
|
|
1624
|
+
.pf-c-background-image::before {
|
|
1625
|
+
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage--sm-2x);
|
|
1626
|
+
}
|
|
1627
|
+
}
|
|
1628
|
+
@media (min-width: 992px) {
|
|
1629
|
+
.pf-c-background-image::before {
|
|
1630
|
+
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage--lg);
|
|
1631
|
+
}
|
|
1632
|
+
}
|
|
1633
|
+
.pf-c-background-image__filter {
|
|
1634
|
+
display: block;
|
|
1635
|
+
}
|
|
1636
|
+
|
|
1588
1637
|
.pf-c-badge {
|
|
1589
1638
|
--pf-c-badge--BorderRadius: var(--pf-global--BorderRadius--lg);
|
|
1590
1639
|
--pf-c-badge--FontSize: var(--pf-global--FontSize--xs);
|
|
@@ -1802,55 +1851,6 @@ textarea.pf-c-form-control {
|
|
|
1802
1851
|
color: var(--pf-global--palette--black-900);
|
|
1803
1852
|
}
|
|
1804
1853
|
|
|
1805
|
-
.pf-c-background-image {
|
|
1806
|
-
--pf-c-background-image--BackgroundColor: var(--pf-global--BackgroundColor--dark-100);
|
|
1807
|
-
--pf-c-background-image--BackgroundImage: url("../../assets/images/pfbg_576.jpg");
|
|
1808
|
-
--pf-c-background-image--BackgroundImage-2x: url("../../assets/images/pfbg_576@2x.jpg");
|
|
1809
|
-
--pf-c-background-image--BackgroundImage--sm: url("../../assets/images/pfbg_768.jpg");
|
|
1810
|
-
--pf-c-background-image--BackgroundImage--sm-2x: url("../../assets/images/pfbg_768@2x.jpg");
|
|
1811
|
-
--pf-c-background-image--BackgroundImage--lg: url("../../assets/images/pfbg_2000.jpg");
|
|
1812
|
-
--pf-c-background-image--Filter: url("#image_overlay");
|
|
1813
|
-
}
|
|
1814
|
-
|
|
1815
|
-
.pf-c-background-image::before {
|
|
1816
|
-
position: fixed;
|
|
1817
|
-
top: 0;
|
|
1818
|
-
left: 0;
|
|
1819
|
-
z-index: -1;
|
|
1820
|
-
width: 100%;
|
|
1821
|
-
height: 100%;
|
|
1822
|
-
content: "";
|
|
1823
|
-
background-color: var(--pf-c-background-image--BackgroundColor);
|
|
1824
|
-
background-image: var(--pf-c-background-image--BackgroundImage);
|
|
1825
|
-
filter: var(--pf-c-background-image--Filter);
|
|
1826
|
-
background-repeat: no-repeat;
|
|
1827
|
-
background-size: cover;
|
|
1828
|
-
}
|
|
1829
|
-
|
|
1830
|
-
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
|
|
1831
|
-
.pf-c-background-image::before {
|
|
1832
|
-
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage-2x);
|
|
1833
|
-
}
|
|
1834
|
-
}
|
|
1835
|
-
@media (min-width: 576px) {
|
|
1836
|
-
.pf-c-background-image::before {
|
|
1837
|
-
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage--sm);
|
|
1838
|
-
}
|
|
1839
|
-
}
|
|
1840
|
-
@media (min-width: 576px) and (-webkit-min-device-pixel-ratio: 2), (min-width: 576px) and (min-resolution: 192dpi) {
|
|
1841
|
-
.pf-c-background-image::before {
|
|
1842
|
-
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage--sm-2x);
|
|
1843
|
-
}
|
|
1844
|
-
}
|
|
1845
|
-
@media (min-width: 992px) {
|
|
1846
|
-
.pf-c-background-image::before {
|
|
1847
|
-
--pf-c-background-image--BackgroundImage: var(--pf-c-background-image--BackgroundImage--lg);
|
|
1848
|
-
}
|
|
1849
|
-
}
|
|
1850
|
-
.pf-c-background-image__filter {
|
|
1851
|
-
display: block;
|
|
1852
|
-
}
|
|
1853
|
-
|
|
1854
1854
|
.pf-c-brand {
|
|
1855
1855
|
--pf-c-brand--Width: auto;
|
|
1856
1856
|
--pf-c-brand--Height: auto;
|
|
@@ -8488,6 +8488,81 @@ label.pf-c-check, .pf-c-check__label,
|
|
|
8488
8488
|
font-size: var(--pf-global--FontSize--lg);
|
|
8489
8489
|
}
|
|
8490
8490
|
|
|
8491
|
+
.pf-c-file-upload {
|
|
8492
|
+
--pf-c-file-upload--m-loading__file-details--before--BackgroundColor: var(--pf-global--BackgroundColor--100);
|
|
8493
|
+
--pf-c-file-upload--m-loading__file-details--before--Left: var(--pf-global--BorderWidth--sm);
|
|
8494
|
+
--pf-c-file-upload--m-loading__file-details--before--Right: var(--pf-global--BorderWidth--sm);
|
|
8495
|
+
--pf-c-file-upload--m-loading__file-details--before--Bottom: var(--pf-global--BorderWidth--sm);
|
|
8496
|
+
--pf-c-file-upload--m-drag-hover--before--BorderWidth: var(--pf-global--BorderWidth--sm);
|
|
8497
|
+
--pf-c-file-upload--m-drag-hover--before--BorderColor: var(--pf-global--primary-color--100);
|
|
8498
|
+
--pf-c-file-upload--m-drag-hover--before--ZIndex: var(--pf-global--ZIndex--xs);
|
|
8499
|
+
--pf-c-file-upload--m-drag-hover--after--BackgroundColor: var(--pf-global--primary-color--100);
|
|
8500
|
+
--pf-c-file-upload--m-drag-hover--after--Opacity: .1;
|
|
8501
|
+
--pf-c-file-upload__file-details__c-form-control--MinHeight: calc(var(--pf-global--spacer--3xl) * 2);
|
|
8502
|
+
--pf-c-file-upload__file-select__c-button--m-control--OutlineOffset: calc(-1 * var(--pf-global--spacer--xs));
|
|
8503
|
+
position: relative;
|
|
8504
|
+
display: flex;
|
|
8505
|
+
flex-direction: column;
|
|
8506
|
+
}
|
|
8507
|
+
|
|
8508
|
+
.pf-c-file-upload.pf-m-drag-hover::before {
|
|
8509
|
+
position: absolute;
|
|
8510
|
+
top: 0;
|
|
8511
|
+
right: 0;
|
|
8512
|
+
bottom: 0;
|
|
8513
|
+
left: 0;
|
|
8514
|
+
z-index: var(--pf-c-file-upload--m-drag-hover--before--ZIndex);
|
|
8515
|
+
content: "";
|
|
8516
|
+
border: var(--pf-c-file-upload--m-drag-hover--before--BorderWidth) solid var(--pf-c-file-upload--m-drag-hover--before--BorderColor);
|
|
8517
|
+
}
|
|
8518
|
+
|
|
8519
|
+
.pf-c-file-upload.pf-m-drag-hover::after {
|
|
8520
|
+
position: absolute;
|
|
8521
|
+
top: 0;
|
|
8522
|
+
right: 0;
|
|
8523
|
+
bottom: 0;
|
|
8524
|
+
left: 0;
|
|
8525
|
+
content: "";
|
|
8526
|
+
background-color: var(--pf-c-file-upload--m-drag-hover--after--BackgroundColor);
|
|
8527
|
+
opacity: var(--pf-c-file-upload--m-drag-hover--after--Opacity);
|
|
8528
|
+
}
|
|
8529
|
+
|
|
8530
|
+
.pf-c-file-upload.pf-m-loading .pf-c-file-upload__file-details {
|
|
8531
|
+
position: relative;
|
|
8532
|
+
}
|
|
8533
|
+
|
|
8534
|
+
.pf-c-file-upload.pf-m-loading .pf-c-file-upload__file-details::before {
|
|
8535
|
+
position: absolute;
|
|
8536
|
+
top: 0;
|
|
8537
|
+
right: var(--pf-c-file-upload--m-loading__file-details--before--Left);
|
|
8538
|
+
bottom: var(--pf-c-file-upload--m-loading__file-details--before--Left);
|
|
8539
|
+
left: var(--pf-c-file-upload--m-loading__file-details--before--Left);
|
|
8540
|
+
content: "";
|
|
8541
|
+
background-color: var(--pf-c-file-upload--m-loading__file-details--before--BackgroundColor);
|
|
8542
|
+
}
|
|
8543
|
+
|
|
8544
|
+
.pf-c-file-upload__file-select .pf-c-button.pf-m-control {
|
|
8545
|
+
outline-offset: var(--pf-c-file-upload__file-select__c-button--m-control--OutlineOffset);
|
|
8546
|
+
}
|
|
8547
|
+
|
|
8548
|
+
.pf-c-file-upload__file-details {
|
|
8549
|
+
position: relative;
|
|
8550
|
+
display: flex;
|
|
8551
|
+
}
|
|
8552
|
+
|
|
8553
|
+
.pf-c-file-upload__file-details .pf-c-form-control {
|
|
8554
|
+
flex: 1 1 auto;
|
|
8555
|
+
min-height: var(--pf-c-file-upload__file-details__c-form-control--MinHeight);
|
|
8556
|
+
border-top: 0;
|
|
8557
|
+
}
|
|
8558
|
+
|
|
8559
|
+
.pf-c-file-upload__file-details-spinner {
|
|
8560
|
+
position: absolute;
|
|
8561
|
+
top: 50%;
|
|
8562
|
+
left: 50%;
|
|
8563
|
+
transform: translate(-50%, -50%);
|
|
8564
|
+
}
|
|
8565
|
+
|
|
8491
8566
|
.pf-c-expandable-section {
|
|
8492
8567
|
--pf-c-expandable-section__toggle--PaddingTop: var(--pf-global--spacer--form-element);
|
|
8493
8568
|
--pf-c-expandable-section__toggle--PaddingRight: var(--pf-global--spacer--md);
|
|
@@ -8635,81 +8710,6 @@ label.pf-c-check, .pf-c-check__label,
|
|
|
8635
8710
|
font-weight: var(--pf-global--FontWeight--semi-bold);
|
|
8636
8711
|
}
|
|
8637
8712
|
|
|
8638
|
-
.pf-c-file-upload {
|
|
8639
|
-
--pf-c-file-upload--m-loading__file-details--before--BackgroundColor: var(--pf-global--BackgroundColor--100);
|
|
8640
|
-
--pf-c-file-upload--m-loading__file-details--before--Left: var(--pf-global--BorderWidth--sm);
|
|
8641
|
-
--pf-c-file-upload--m-loading__file-details--before--Right: var(--pf-global--BorderWidth--sm);
|
|
8642
|
-
--pf-c-file-upload--m-loading__file-details--before--Bottom: var(--pf-global--BorderWidth--sm);
|
|
8643
|
-
--pf-c-file-upload--m-drag-hover--before--BorderWidth: var(--pf-global--BorderWidth--sm);
|
|
8644
|
-
--pf-c-file-upload--m-drag-hover--before--BorderColor: var(--pf-global--primary-color--100);
|
|
8645
|
-
--pf-c-file-upload--m-drag-hover--before--ZIndex: var(--pf-global--ZIndex--xs);
|
|
8646
|
-
--pf-c-file-upload--m-drag-hover--after--BackgroundColor: var(--pf-global--primary-color--100);
|
|
8647
|
-
--pf-c-file-upload--m-drag-hover--after--Opacity: .1;
|
|
8648
|
-
--pf-c-file-upload__file-details__c-form-control--MinHeight: calc(var(--pf-global--spacer--3xl) * 2);
|
|
8649
|
-
--pf-c-file-upload__file-select__c-button--m-control--OutlineOffset: calc(-1 * var(--pf-global--spacer--xs));
|
|
8650
|
-
position: relative;
|
|
8651
|
-
display: flex;
|
|
8652
|
-
flex-direction: column;
|
|
8653
|
-
}
|
|
8654
|
-
|
|
8655
|
-
.pf-c-file-upload.pf-m-drag-hover::before {
|
|
8656
|
-
position: absolute;
|
|
8657
|
-
top: 0;
|
|
8658
|
-
right: 0;
|
|
8659
|
-
bottom: 0;
|
|
8660
|
-
left: 0;
|
|
8661
|
-
z-index: var(--pf-c-file-upload--m-drag-hover--before--ZIndex);
|
|
8662
|
-
content: "";
|
|
8663
|
-
border: var(--pf-c-file-upload--m-drag-hover--before--BorderWidth) solid var(--pf-c-file-upload--m-drag-hover--before--BorderColor);
|
|
8664
|
-
}
|
|
8665
|
-
|
|
8666
|
-
.pf-c-file-upload.pf-m-drag-hover::after {
|
|
8667
|
-
position: absolute;
|
|
8668
|
-
top: 0;
|
|
8669
|
-
right: 0;
|
|
8670
|
-
bottom: 0;
|
|
8671
|
-
left: 0;
|
|
8672
|
-
content: "";
|
|
8673
|
-
background-color: var(--pf-c-file-upload--m-drag-hover--after--BackgroundColor);
|
|
8674
|
-
opacity: var(--pf-c-file-upload--m-drag-hover--after--Opacity);
|
|
8675
|
-
}
|
|
8676
|
-
|
|
8677
|
-
.pf-c-file-upload.pf-m-loading .pf-c-file-upload__file-details {
|
|
8678
|
-
position: relative;
|
|
8679
|
-
}
|
|
8680
|
-
|
|
8681
|
-
.pf-c-file-upload.pf-m-loading .pf-c-file-upload__file-details::before {
|
|
8682
|
-
position: absolute;
|
|
8683
|
-
top: 0;
|
|
8684
|
-
right: var(--pf-c-file-upload--m-loading__file-details--before--Left);
|
|
8685
|
-
bottom: var(--pf-c-file-upload--m-loading__file-details--before--Left);
|
|
8686
|
-
left: var(--pf-c-file-upload--m-loading__file-details--before--Left);
|
|
8687
|
-
content: "";
|
|
8688
|
-
background-color: var(--pf-c-file-upload--m-loading__file-details--before--BackgroundColor);
|
|
8689
|
-
}
|
|
8690
|
-
|
|
8691
|
-
.pf-c-file-upload__file-select .pf-c-button.pf-m-control {
|
|
8692
|
-
outline-offset: var(--pf-c-file-upload__file-select__c-button--m-control--OutlineOffset);
|
|
8693
|
-
}
|
|
8694
|
-
|
|
8695
|
-
.pf-c-file-upload__file-details {
|
|
8696
|
-
position: relative;
|
|
8697
|
-
display: flex;
|
|
8698
|
-
}
|
|
8699
|
-
|
|
8700
|
-
.pf-c-file-upload__file-details .pf-c-form-control {
|
|
8701
|
-
flex: 1 1 auto;
|
|
8702
|
-
min-height: var(--pf-c-file-upload__file-details__c-form-control--MinHeight);
|
|
8703
|
-
border-top: 0;
|
|
8704
|
-
}
|
|
8705
|
-
|
|
8706
|
-
.pf-c-file-upload__file-details-spinner {
|
|
8707
|
-
position: absolute;
|
|
8708
|
-
top: 50%;
|
|
8709
|
-
left: 50%;
|
|
8710
|
-
transform: translate(-50%, -50%);
|
|
8711
|
-
}
|
|
8712
|
-
|
|
8713
8713
|
.pf-c-form {
|
|
8714
8714
|
--pf-c-form--GridGap: var(--pf-global--gutter--md);
|
|
8715
8715
|
--pf-c-form__group--m-action--MarginTop: var(--pf-global--spacer--xl);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@patternfly/react-core",
|
|
3
|
-
"version": "4.250.
|
|
3
|
+
"version": "4.250.6",
|
|
4
4
|
"description": "This library provides a set of common React components for use with the PatternFly reference implementation.",
|
|
5
5
|
"main": "dist/js/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
@@ -70,5 +70,5 @@
|
|
|
70
70
|
"react": "^16.8 || ^17 || ^18",
|
|
71
71
|
"react-dom": "^16.8 || ^17 || ^18"
|
|
72
72
|
},
|
|
73
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "8aa9e38c43fdc298079458ee719ae8e06bf791e2"
|
|
74
74
|
}
|
|
@@ -1,25 +1,159 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { render, screen } from '@testing-library/react';
|
|
3
|
-
import { Title
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
3
|
+
import { Title } from '../Title';
|
|
4
|
+
|
|
5
|
+
test('Renders without children', () => {
|
|
6
|
+
render(
|
|
7
|
+
<div data-testid="title">
|
|
8
|
+
<Title headingLevel="h1" />
|
|
9
|
+
</div>
|
|
10
|
+
);
|
|
11
|
+
expect(screen.getByTestId('title').firstChild).toBeVisible();
|
|
12
|
+
});
|
|
13
|
+
|
|
14
|
+
test('Renders children', () => {
|
|
15
|
+
render(<Title headingLevel="h1">Test</Title>);
|
|
16
|
+
expect(screen.getByText('Test')).toBeVisible();
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
test('Renders with the pf-c-title', () => {
|
|
20
|
+
render(<Title headingLevel="h1">Test</Title>);
|
|
21
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-c-title');
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
test('Renders with only the class pf-c-title and the heading level modifier class pf-m-2xl by default', () => {
|
|
25
|
+
render(<Title headingLevel="h1">Test</Title>);
|
|
26
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-c-title pf-m-2xl', { exact: true });
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
test('Renders with custom class name when className prop is passed', () => {
|
|
30
|
+
render(
|
|
31
|
+
<Title headingLevel="h1" className="test-class">
|
|
32
|
+
Test
|
|
33
|
+
</Title>
|
|
34
|
+
);
|
|
35
|
+
expect(screen.getByRole('heading')).toHaveClass('test-class');
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
test('Renders with class name pf-m-2xl by default when "h1" is passed as heading level', () => {
|
|
39
|
+
render(<Title headingLevel="h1">Test</Title>);
|
|
40
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-2xl');
|
|
41
|
+
});
|
|
42
|
+
|
|
43
|
+
test('Renders with class name pf-m-xl by default when "h2" is passed as heading level', () => {
|
|
44
|
+
render(<Title headingLevel="h2">Test</Title>);
|
|
45
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-xl');
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
test('Renders with class name pf-m-lg by default when "h3" is passed as heading level', () => {
|
|
49
|
+
render(<Title headingLevel="h3">Test</Title>);
|
|
50
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-lg');
|
|
51
|
+
});
|
|
52
|
+
|
|
53
|
+
test('Renders with class name pf-m-md by default when "h4" is passed as heading level', () => {
|
|
54
|
+
render(<Title headingLevel="h4">Test</Title>);
|
|
55
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-md');
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
test('Renders with class name pf-m-md by default when "h5" is passed as heading level', () => {
|
|
59
|
+
render(<Title headingLevel="h5">Test</Title>);
|
|
60
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-md');
|
|
61
|
+
});
|
|
62
|
+
|
|
63
|
+
test('Renders with class name pf-m-md by default when "h6" is passed as heading level', () => {
|
|
64
|
+
render(<Title headingLevel="h6">Test</Title>);
|
|
65
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-md');
|
|
66
|
+
});
|
|
67
|
+
|
|
68
|
+
test('Renders with class name pf-m-md when "md" is passed as title size', () => {
|
|
69
|
+
render(
|
|
70
|
+
<Title headingLevel="h1" size="md">
|
|
71
|
+
Test
|
|
72
|
+
</Title>
|
|
73
|
+
);
|
|
74
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-md');
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
test('Renders with class name pf-m-lg when "lg" is passed as title size', () => {
|
|
78
|
+
render(
|
|
79
|
+
<Title headingLevel="h1" size="lg">
|
|
80
|
+
Test
|
|
81
|
+
</Title>
|
|
82
|
+
);
|
|
83
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-lg');
|
|
84
|
+
});
|
|
85
|
+
|
|
86
|
+
test('Renders with class name pf-m-xl when "xl" is passed as title size', () => {
|
|
87
|
+
render(
|
|
88
|
+
<Title headingLevel="h1" size="xl">
|
|
89
|
+
Test
|
|
90
|
+
</Title>
|
|
91
|
+
);
|
|
92
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-xl');
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
test('Renders with class name pf-m-2xl when "2xl" is passed as title size', () => {
|
|
96
|
+
render(
|
|
97
|
+
<Title headingLevel="h1" size="2xl">
|
|
98
|
+
Test
|
|
99
|
+
</Title>
|
|
100
|
+
);
|
|
101
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-2xl');
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
test('Renders with class name pf-m-3xl when "3xl" is passed as title size', () => {
|
|
105
|
+
render(
|
|
106
|
+
<Title headingLevel="h1" size="3xl">
|
|
107
|
+
Test
|
|
108
|
+
</Title>
|
|
109
|
+
);
|
|
110
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-3xl');
|
|
111
|
+
});
|
|
112
|
+
|
|
113
|
+
test('Renders with class name pf-m-4xl when "4xl" is passed as title size', () => {
|
|
114
|
+
render(
|
|
115
|
+
<Title headingLevel="h1" size="4xl">
|
|
116
|
+
Test
|
|
117
|
+
</Title>
|
|
118
|
+
);
|
|
119
|
+
expect(screen.getByRole('heading')).toHaveClass('pf-m-4xl');
|
|
120
|
+
});
|
|
121
|
+
|
|
122
|
+
test('Renders with tag name "h1" when "h1" is passed as heading level', () => {
|
|
123
|
+
render(<Title headingLevel="h1">Test</Title>);
|
|
124
|
+
expect(screen.getByRole('heading', { level: 1 })).toBeVisible();
|
|
125
|
+
});
|
|
126
|
+
|
|
127
|
+
test('Renders with tag name "h2" when "h2" is passed as heading level', () => {
|
|
128
|
+
render(<Title headingLevel="h2">Test</Title>);
|
|
129
|
+
expect(screen.getByRole('heading', { level: 2 })).toBeVisible();
|
|
130
|
+
});
|
|
131
|
+
|
|
132
|
+
test('Renders with tag name "h3" when "h3" is passed as heading level', () => {
|
|
133
|
+
render(<Title headingLevel="h3">Test</Title>);
|
|
134
|
+
expect(screen.getByRole('heading', { level: 3 })).toBeVisible();
|
|
135
|
+
});
|
|
136
|
+
|
|
137
|
+
test('Renders with tag name "h4" when "h4" is passed as heading level', () => {
|
|
138
|
+
render(<Title headingLevel="h4">Test</Title>);
|
|
139
|
+
expect(screen.getByRole('heading', { level: 4 })).toBeVisible();
|
|
140
|
+
});
|
|
141
|
+
|
|
142
|
+
test('Renders with tag name "h5" when "h5" is passed as heading level', () => {
|
|
143
|
+
render(<Title headingLevel="h5">Test</Title>);
|
|
144
|
+
expect(screen.getByRole('heading', { level: 5 })).toBeVisible();
|
|
145
|
+
});
|
|
146
|
+
|
|
147
|
+
test('Renders with tag name "h6" when "h6" is passed as heading level', () => {
|
|
148
|
+
render(<Title headingLevel="h6">Test</Title>);
|
|
149
|
+
expect(screen.getByRole('heading', { level: 6 })).toBeVisible();
|
|
150
|
+
});
|
|
151
|
+
|
|
152
|
+
test('Matches the snapshot', () => {
|
|
153
|
+
const { asFragment } = render(
|
|
154
|
+
<Title data-ouia-component-id="ouia-id" headingLevel="h1">
|
|
155
|
+
Test
|
|
156
|
+
</Title>
|
|
157
|
+
);
|
|
158
|
+
expect(asFragment()).toMatchSnapshot();
|
|
25
159
|
});
|
|
@@ -1,79 +1,14 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`
|
|
3
|
+
exports[`Matches the snapshot 1`] = `
|
|
4
4
|
<DocumentFragment>
|
|
5
5
|
<h1
|
|
6
6
|
class="pf-c-title pf-m-2xl"
|
|
7
|
-
data-ouia-component-id="
|
|
7
|
+
data-ouia-component-id="ouia-id"
|
|
8
8
|
data-ouia-component-type="PF4/Title"
|
|
9
9
|
data-ouia-safe="true"
|
|
10
10
|
>
|
|
11
|
-
|
|
11
|
+
Test
|
|
12
12
|
</h1>
|
|
13
13
|
</DocumentFragment>
|
|
14
|
-
`;
|
|
15
|
-
|
|
16
|
-
exports[`Title 3xl Title 1`] = `
|
|
17
|
-
<DocumentFragment>
|
|
18
|
-
<h1
|
|
19
|
-
class="pf-c-title pf-m-3xl"
|
|
20
|
-
data-ouia-component-id="OUIA-Generated-Title-5"
|
|
21
|
-
data-ouia-component-type="PF4/Title"
|
|
22
|
-
data-ouia-safe="true"
|
|
23
|
-
>
|
|
24
|
-
3xl Title
|
|
25
|
-
</h1>
|
|
26
|
-
</DocumentFragment>
|
|
27
|
-
`;
|
|
28
|
-
|
|
29
|
-
exports[`Title 4xl Title 1`] = `
|
|
30
|
-
<DocumentFragment>
|
|
31
|
-
<h1
|
|
32
|
-
class="pf-c-title pf-m-4xl"
|
|
33
|
-
data-ouia-component-id="OUIA-Generated-Title-6"
|
|
34
|
-
data-ouia-component-type="PF4/Title"
|
|
35
|
-
data-ouia-safe="true"
|
|
36
|
-
>
|
|
37
|
-
4xl Title
|
|
38
|
-
</h1>
|
|
39
|
-
</DocumentFragment>
|
|
40
|
-
`;
|
|
41
|
-
|
|
42
|
-
exports[`Title lg Title 1`] = `
|
|
43
|
-
<DocumentFragment>
|
|
44
|
-
<h1
|
|
45
|
-
class="pf-c-title pf-m-lg"
|
|
46
|
-
data-ouia-component-id="OUIA-Generated-Title-2"
|
|
47
|
-
data-ouia-component-type="PF4/Title"
|
|
48
|
-
data-ouia-safe="true"
|
|
49
|
-
>
|
|
50
|
-
lg Title
|
|
51
|
-
</h1>
|
|
52
|
-
</DocumentFragment>
|
|
53
|
-
`;
|
|
54
|
-
|
|
55
|
-
exports[`Title md Title 1`] = `
|
|
56
|
-
<DocumentFragment>
|
|
57
|
-
<h1
|
|
58
|
-
class="pf-c-title pf-m-md"
|
|
59
|
-
data-ouia-component-id="OUIA-Generated-Title-1"
|
|
60
|
-
data-ouia-component-type="PF4/Title"
|
|
61
|
-
data-ouia-safe="true"
|
|
62
|
-
>
|
|
63
|
-
md Title
|
|
64
|
-
</h1>
|
|
65
|
-
</DocumentFragment>
|
|
66
|
-
`;
|
|
67
|
-
|
|
68
|
-
exports[`Title xl Title 1`] = `
|
|
69
|
-
<DocumentFragment>
|
|
70
|
-
<h1
|
|
71
|
-
class="pf-c-title pf-m-xl"
|
|
72
|
-
data-ouia-component-id="OUIA-Generated-Title-3"
|
|
73
|
-
data-ouia-component-type="PF4/Title"
|
|
74
|
-
data-ouia-safe="true"
|
|
75
|
-
>
|
|
76
|
-
xl Title
|
|
77
|
-
</h1>
|
|
78
|
-
</DocumentFragment>
|
|
79
|
-
`;
|
|
14
|
+
`;
|
|
@@ -23,9 +23,11 @@ export interface DropdownProps extends MenuProps {
|
|
|
23
23
|
isScrollable?: boolean;
|
|
24
24
|
/** Min width of the menu. */
|
|
25
25
|
minWidth?: string;
|
|
26
|
+
/** @hide Forwarded ref */
|
|
27
|
+
innerRef?: React.Ref<any>;
|
|
26
28
|
}
|
|
27
29
|
|
|
28
|
-
|
|
30
|
+
const DropdownBase: React.FunctionComponent<DropdownProps> = ({
|
|
29
31
|
children,
|
|
30
32
|
className,
|
|
31
33
|
onSelect,
|
|
@@ -35,13 +37,14 @@ export const Dropdown: React.FunctionComponent<DropdownProps> = ({
|
|
|
35
37
|
isPlain,
|
|
36
38
|
isScrollable,
|
|
37
39
|
minWidth,
|
|
40
|
+
innerRef,
|
|
38
41
|
...props
|
|
39
42
|
}: DropdownProps) => {
|
|
40
43
|
const localMenuRef = React.useRef<HTMLDivElement>();
|
|
41
44
|
const toggleRef = React.useRef<HTMLButtonElement>();
|
|
42
45
|
const containerRef = React.useRef<HTMLDivElement>();
|
|
43
46
|
|
|
44
|
-
const menuRef = (
|
|
47
|
+
const menuRef = (innerRef as React.RefObject<HTMLDivElement>) || localMenuRef;
|
|
45
48
|
React.useEffect(() => {
|
|
46
49
|
const handleMenuKeys = (event: KeyboardEvent) => {
|
|
47
50
|
if (!isOpen && toggleRef.current?.contains(event.target as Node)) {
|
|
@@ -112,4 +115,8 @@ export const Dropdown: React.FunctionComponent<DropdownProps> = ({
|
|
|
112
115
|
</div>
|
|
113
116
|
);
|
|
114
117
|
};
|
|
118
|
+
|
|
119
|
+
export const Dropdown = React.forwardRef((props: DropdownProps, ref: React.Ref<any>) => (
|
|
120
|
+
<DropdownBase innerRef={ref} {...props} />
|
|
121
|
+
));
|
|
115
122
|
Dropdown.displayName = 'Dropdown';
|
|
@@ -4,7 +4,6 @@ import { Divider, MenuToggle } from '@patternfly/react-core';
|
|
|
4
4
|
|
|
5
5
|
export const DropdownBasic: React.FunctionComponent = () => {
|
|
6
6
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
7
|
-
const menuRef = React.useRef<HTMLDivElement>(null);
|
|
8
7
|
|
|
9
8
|
const onToggleClick = () => {
|
|
10
9
|
setIsOpen(!isOpen);
|
|
@@ -18,7 +17,6 @@ export const DropdownBasic: React.FunctionComponent = () => {
|
|
|
18
17
|
|
|
19
18
|
return (
|
|
20
19
|
<Dropdown
|
|
21
|
-
innerRef={menuRef}
|
|
22
20
|
isOpen={isOpen}
|
|
23
21
|
onSelect={onSelect}
|
|
24
22
|
onOpenChange={isOpen => setIsOpen(isOpen)}
|
|
@@ -4,7 +4,6 @@ import { MenuToggle } from '@patternfly/react-core';
|
|
|
4
4
|
|
|
5
5
|
export const DropdownWithDescriptions: React.FunctionComponent = () => {
|
|
6
6
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
7
|
-
const menuRef = React.useRef<HTMLDivElement>(null);
|
|
8
7
|
|
|
9
8
|
const onToggleClick = () => {
|
|
10
9
|
setIsOpen(!isOpen);
|
|
@@ -18,7 +17,6 @@ export const DropdownWithDescriptions: React.FunctionComponent = () => {
|
|
|
18
17
|
|
|
19
18
|
return (
|
|
20
19
|
<Dropdown
|
|
21
|
-
innerRef={menuRef}
|
|
22
20
|
isOpen={isOpen}
|
|
23
21
|
onSelect={onSelect}
|
|
24
22
|
minWidth="150px"
|
|
@@ -4,7 +4,6 @@ import { MenuToggle, Divider } from '@patternfly/react-core';
|
|
|
4
4
|
|
|
5
5
|
export const DropdownWithGroups: React.FunctionComponent = () => {
|
|
6
6
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
7
|
-
const menuRef = React.useRef<HTMLDivElement>(null);
|
|
8
7
|
|
|
9
8
|
const onToggleClick = () => {
|
|
10
9
|
setIsOpen(!isOpen);
|
|
@@ -18,7 +17,6 @@ export const DropdownWithGroups: React.FunctionComponent = () => {
|
|
|
18
17
|
|
|
19
18
|
return (
|
|
20
19
|
<Dropdown
|
|
21
|
-
innerRef={menuRef}
|
|
22
20
|
isOpen={isOpen}
|
|
23
21
|
onSelect={onSelect}
|
|
24
22
|
onOpenChange={isOpen => setIsOpen(isOpen)}
|
|
@@ -5,7 +5,6 @@ import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-ico
|
|
|
5
5
|
|
|
6
6
|
export const DropdownWithKebab: React.FunctionComponent = () => {
|
|
7
7
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
8
|
-
const menuRef = React.useRef<HTMLDivElement>(null);
|
|
9
8
|
|
|
10
9
|
const onToggleClick = () => {
|
|
11
10
|
setIsOpen(!isOpen);
|
|
@@ -19,7 +18,6 @@ export const DropdownWithKebab: React.FunctionComponent = () => {
|
|
|
19
18
|
|
|
20
19
|
return (
|
|
21
20
|
<Dropdown
|
|
22
|
-
innerRef={menuRef}
|
|
23
21
|
isOpen={isOpen}
|
|
24
22
|
onSelect={onSelect}
|
|
25
23
|
minWidth="150px"
|