2025-02-27 01:26:48 +00:00
|
|
|
import ToolOptionGroups from '@components/options/ToolOptionGroups';
|
|
|
|
|
import { GetGroupsType } from '@components/options/ToolOptions';
|
|
|
|
|
import React from 'react';
|
2024-06-24 20:09:16 -07:00
|
|
|
|
2025-02-27 01:47:44 +00:00
|
|
|
export default function ExampleOptions<T>({
|
2025-02-27 01:26:48 +00:00
|
|
|
options,
|
|
|
|
|
getGroups
|
2024-06-24 20:09:16 -07:00
|
|
|
}: {
|
2025-02-27 01:26:48 +00:00
|
|
|
options: T;
|
2025-03-08 06:43:11 +00:00
|
|
|
getGroups: GetGroupsType<T> | null;
|
2024-06-24 20:09:16 -07:00
|
|
|
}) {
|
2025-02-27 01:47:44 +00:00
|
|
|
return (
|
|
|
|
|
<ToolOptionGroups
|
|
|
|
|
// @ts-ignore
|
2025-03-08 06:43:11 +00:00
|
|
|
groups={getGroups?.({ values: options }) ?? []}
|
2025-02-27 01:47:44 +00:00
|
|
|
vertical
|
|
|
|
|
/>
|
|
|
|
|
);
|
2024-06-24 20:09:16 -07:00
|
|
|
}
|