UNPKG

1.64 kBJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3exports.FormFieldGroupToggle = void 0;
4const tslib_1 = require("tslib");
5const React = tslib_1.__importStar(require("react"));
6const form_1 = tslib_1.__importDefault(require("@patternfly/react-styles/css/components/Form/form"));
7const react_styles_1 = require("@patternfly/react-styles");
8const angle_right_icon_1 = tslib_1.__importDefault(require('@patternfly/react-icons/dist/js/icons/angle-right-icon'));
9const Button_1 = require("../Button");
10const FormFieldGroupToggle = (_a) => {
11 var { className, onToggle, isExpanded, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledby, toggleId } = _a, props = tslib_1.__rest(_a, ["className", "onToggle", "isExpanded", 'aria-label', 'aria-labelledby', "toggleId"]);
12 return (React.createElement("div", Object.assign({ className: react_styles_1.css(form_1.default.formFieldGroupToggle, className) }, props),
13 React.createElement("div", { className: react_styles_1.css(form_1.default.formFieldGroupToggleButton) },
14 React.createElement(Button_1.Button, { variant: "plain", "aria-label": ariaLabel, onClick: onToggle, "aria-expanded": isExpanded, "aria-labelledby": ariaLabelledby, id: toggleId },
15 React.createElement("span", { className: react_styles_1.css(form_1.default.formFieldGroupToggleIcon) },
16 React.createElement(angle_right_icon_1.default, { "aria-hidden": "true" }))))));
17};
18exports.FormFieldGroupToggle = FormFieldGroupToggle;
19exports.FormFieldGroupToggle.displayName = 'FormFieldGroupToggle';
20//# sourceMappingURL=FormFieldGroupToggle.js.map
\No newline at end of file