extra & variant fixes

This commit is contained in:
2026-01-14 14:36:32 +03:00
parent 5c7e64b17c
commit e95411460f
6 changed files with 274 additions and 102 deletions

View File

@@ -5,9 +5,14 @@ interface ProCheckboxGroupsProps {
options: any[];
value?: string[];
onChange?: (values: string[]) => void;
showPrice?: boolean;
}
const ProCheckboxGroups = ({ options, ...props }: ProCheckboxGroupsProps) => {
const ProCheckboxGroups = ({
options,
showPrice,
...props
}: ProCheckboxGroupsProps) => {
return (
<Checkbox.Group
{...props}
@@ -15,7 +20,7 @@ const ProCheckboxGroups = ({ options, ...props }: ProCheckboxGroupsProps) => {
width: "100%",
}}
>
<Space direction="vertical" style={{ width: "100%" }}>
<Space orientation="vertical" style={{ width: "100%" }}>
{options.map((option: any) => (
<Checkbox
key={option.value}
@@ -38,7 +43,9 @@ const ProCheckboxGroups = ({ options, ...props }: ProCheckboxGroupsProps) => {
>
{option.label}
</ProText>
<ProText style={{ fontSize: "1rem" }}>{option.price}</ProText>
{showPrice && (
<ProText style={{ fontSize: "1rem" }}>{option.price}</ProText>
)}
</div>
</Checkbox>
))}