This commit is contained in:
louiscklaw
2025-05-08 17:19:43 +08:00
parent 7105bc85e3
commit 5640d4d4f6
46 changed files with 520 additions and 268 deletions

View File

@@ -25,12 +25,12 @@ export const StudentsSelectionContext = React.createContext<StudentsSelectionCon
interface StudentsSelectionProviderProps {
children: React.ReactNode;
customers: Student[];
students: Student[];
}
export function StudentsSelectionProvider({
children,
customers = [],
students: customers = [],
}: StudentsSelectionProviderProps): React.JSX.Element {
const customerIds = React.useMemo(() => customers.map((customer) => customer.id), [customers]);
const selection = useSelection(customerIds);