mirror of https://github.com/portainer/portainer
fix(forms): increase-click-area-for-expandable-form-section EE-3314 (#7007)
* fix(forms): increase click area for form sectionpull/6977/merge
parent
9b58c2e466
commit
aea62723c0
@ -1,5 +1,22 @@
|
|||||||
import { PropsWithChildren } from 'react';
|
import { PropsWithChildren } from 'react';
|
||||||
|
|
||||||
export function FormSectionTitle({ children }: PropsWithChildren<unknown>) {
|
interface Props {
|
||||||
|
htmlFor?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function FormSectionTitle({
|
||||||
|
children,
|
||||||
|
htmlFor,
|
||||||
|
}: PropsWithChildren<Props>) {
|
||||||
|
if (htmlFor) {
|
||||||
|
return (
|
||||||
|
<label
|
||||||
|
htmlFor={htmlFor}
|
||||||
|
className="col-sm-12 form-section-title cursor-pointer"
|
||||||
|
>
|
||||||
|
{children}
|
||||||
|
</label>
|
||||||
|
);
|
||||||
|
}
|
||||||
return <div className="col-sm-12 form-section-title">{children}</div>;
|
return <div className="col-sm-12 form-section-title">{children}</div>;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in new issue