UNPKG

@carbon/react

Version:

React components for the Carbon Design System

43 lines (41 loc) 1.52 kB
/** * Copyright IBM Corp. 2016, 2026 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ const require_runtime = require("../../_virtual/_rolldown/runtime.js"); const require_usePrefix = require("../../internal/usePrefix.js"); const require_Form = require("../Form/Form.js"); const require_FormContext = require("./FormContext.js"); let classnames = require("classnames"); classnames = require_runtime.__toESM(classnames); let react = require("react"); react = require_runtime.__toESM(react); let prop_types = require("prop-types"); prop_types = require_runtime.__toESM(prop_types); let react_jsx_runtime = require("react/jsx-runtime"); //#region src/components/FluidForm/FluidForm.tsx /** * Copyright IBM Corp. 2016, 2025 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ const FluidForm = ({ className, children, ...other }) => { const classNames = (0, classnames.default)(`${require_usePrefix.usePrefix()}--form--fluid`, className); return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_FormContext.FormContext.Provider, { value: { isFluid: true }, children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Form.default, { className: classNames, ...other, children }) }); }; FluidForm.propTypes = { children: prop_types.default.node, className: prop_types.default.string }; //#endregion exports.default = FluidForm;