1import { r as reactExports, j as jsxRuntimeExports, a1 as classnames, bs as PropTypes, _ as useBootstrapPrefix } from "./index-ByBBMRkj.js"; 2const propTypes = { 3 /** 4 * Specify whether the feedback is for valid or invalid fields 5 * 6 * @type {('valid'|'invalid')} 7 */ 8 type: PropTypes.string, 9 /** Display feedback as a tooltip. */ 10 tooltip: PropTypes.bool, 11 as: PropTypes.elementType 12}; 13const Feedback = /* @__PURE__ */ reactExports.forwardRef( 14 // Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595 15 ({ 16 as: Component = "div", 17 className, 18 type = "valid", 19 tooltip = false, 20 ...props 21 }, ref) => /* @__PURE__ */ jsxRuntimeExports.jsx(Component, { 22 ...props, 23 ref, 24 className: classnames(className, `${type}-${tooltip ? "tooltip" : "feedback"}`) 25 }) 26); 27Feedback.displayName = "Feedback"; 28Feedback.propTypes = propTypes; 29const FormContext = /* @__PURE__ */ reactExports.createContext({}); 30const FormCheckInput = /* @__PURE__ */ reactExports.forwardRef(({ 31 id, 32 bsPrefix, 33 className, 34 type = "checkbox", 35 isValid = false, 36 isInvalid = false, 37 // Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595 38 as: Component = "input", 39 ...props 40}, ref) => { 41 const { 42 controlId 43 } = reactExports.useContext(FormContext); 44 bsPrefix = useBootstrapPrefix(bsPrefix, "form-check-input"); 45 return /* @__PURE__ */ jsxRuntimeExports.jsx(Component, { 46 ...props, 47 ref, 48 type, 49 id: id || controlId, 50 className: classnames(className, bsPrefix, isValid && "is-valid", isInvalid && "is-invalid") 51 }); 52}); 53FormCheckInput.displayName = "FormCheckInput"; 54const FormControl = /* @__PURE__ */ reactExports.forwardRef(({ 55 bsPrefix, 56 type, 57 size, 58 htmlSize, 59 id, 60 className, 61 isValid = false, 62 isInvalid = false, 63 plaintext, 64 readOnly, 65 // Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595 66 as: Component = "input", 67 ...props 68}, ref) => { 69 const { 70 controlId 71 } = reactExports.useContext(FormContext); 72 bsPrefix = useBootstrapPrefix(bsPrefix, "form-control"); 73 let classes; 74 if (plaintext) { 75 classes = { 76 [`${bsPrefix}-plaintext`]: true 77 }; 78 } else { 79 classes = { 80 [bsPrefix]: true, 81 [`${bsPrefix}-${size}`]: size 82 }; 83 } 84 return /* @__PURE__ */ jsxRuntimeExports.jsx(Component, { 85 ...props, 86 type, 87 size: htmlSize, 88 ref, 89 readOnly, 90 id: id || controlId, 91 className: classnames(className, classes, isValid && `is-valid`, isInvalid && `is-invalid`, type === "color" && `${bsPrefix}-color`) 92 }); 93}); 94FormControl.displayName = "FormControl"; 95const FormControl$1 = Object.assign(FormControl, { 96 Feedback 97}); 98export { 99 FormControl$1 as F, 100 FormCheckInput as a, 101 FormContext as b, 102 Feedback as c 103};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.