@@ -7,12 +7,15 @@ export interface CFormLabelProps extends HTMLAttributes<HTMLLabelElement> {
77 * A string of all className you want applied to the component. [docs]
88 */
99 className ?: string
10- classNameParent ?: string
10+ /**
11+ * A string of all className you want to be applied to the component, and override standard className value. [docs]
12+ */
13+ customClassName ?: string
1114}
1215
1316export const CFormLabel = forwardRef < HTMLLabelElement , CFormLabelProps > (
14- ( { children, className, classNameParent , ...rest } , ref ) => {
15- const _className = classNameParent ? classNameParent : classNames ( 'form-label' , className )
17+ ( { children, className, customClassName , ...rest } , ref ) => {
18+ const _className = customClassName ? customClassName : classNames ( 'form-label' , className )
1619 return (
1720 < label className = { _className } { ...rest } ref = { ref } >
1821 { children }
@@ -24,7 +27,7 @@ export const CFormLabel = forwardRef<HTMLLabelElement, CFormLabelProps>(
2427CFormLabel . propTypes = {
2528 children : PropTypes . node ,
2629 className : PropTypes . string ,
27- classNameParent : PropTypes . string ,
30+ customClassName : PropTypes . string ,
2831}
2932
3033CFormLabel . displayName = 'CFormLabel'
0 commit comments