@thanh01.pmt/interactive-quiz-kit 1.0.77 → 1.0.79

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -77411,194 +77411,200 @@ function LearningObjectiveManager({
77411
77411
  console.log("[LO Manager] No valid records to import.");
77412
77412
  }
77413
77413
  };
77414
- return /* @__PURE__ */ React119__namespace.default.createElement(Card, null, /* @__PURE__ */ React119__namespace.default.createElement(CardHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(CardTitle, { className: "flex justify-between items-center" }, /* @__PURE__ */ React119__namespace.default.createElement("span", { className: "flex items-center" }, /* @__PURE__ */ React119__namespace.default.createElement(Lightbulb, { className: "mr-2 h-5 w-5 text-primary" }), " ", "Manage Learning Objectives"), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "flex items-center gap-2" }, onBulkAdd && /* @__PURE__ */ React119__namespace.default.createElement(
77415
- MetadataImportControls,
77416
- {
77417
- metadataName: "Learning Objectives",
77418
- onImport: handleImport
77419
- }
77420
- ), /* @__PURE__ */ React119__namespace.default.createElement(Button, { onClick: handleAddItem, size: "sm" }, /* @__PURE__ */ React119__namespace.default.createElement(CirclePlus, { className: "mr-2 h-4 w-4" }), " Add Learning Objective")))), /* @__PURE__ */ React119__namespace.default.createElement(CardContent, null, isLoading ? /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "flex justify-center items-center h-32" }, /* @__PURE__ */ React119__namespace.default.createElement(LoaderCircle, { className: "h-8 w-8 animate-spin text-primary" })) : items.length === 0 ? /* @__PURE__ */ React119__namespace.default.createElement("p", { className: "text-center text-muted-foreground py-4" }, "No Learning Objectives found.") : /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "overflow-x-auto" }, /* @__PURE__ */ React119__namespace.default.createElement(Table2, null, /* @__PURE__ */ React119__namespace.default.createElement(TableHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(TableRow, null, /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Code"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Name"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Subject"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Topic"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, { className: "text-right w-[120px]" }, "Actions"))), /* @__PURE__ */ React119__namespace.default.createElement(TableBody, null, items.map((item) => /* @__PURE__ */ React119__namespace.default.createElement(TableRow, { key: item.id }, /* @__PURE__ */ React119__namespace.default.createElement(TableCell, { className: "font-mono text-xs" }, item.code), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, { className: "font-medium" }, item.name), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, null, item.subject || item.subjectCode), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, null, item.topic || item.topicCode), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, { className: "text-right" }, /* @__PURE__ */ React119__namespace.default.createElement(
77421
- Button,
77422
- {
77423
- variant: "ghost",
77424
- size: "icon",
77425
- onClick: () => handleEditItem(item),
77426
- className: "mr-2"
77427
- },
77428
- /* @__PURE__ */ React119__namespace.default.createElement(PenLine, { className: "h-4 w-4" })
77429
- ), /* @__PURE__ */ React119__namespace.default.createElement(
77430
- Button,
77431
- {
77432
- variant: "ghost",
77433
- size: "icon",
77434
- onClick: () => handleDeleteItem(item),
77435
- className: "text-destructive hover:text-destructive"
77436
- },
77437
- /* @__PURE__ */ React119__namespace.default.createElement(Trash2, { className: "h-4 w-4" })
77438
- ))))))), /* @__PURE__ */ React119__namespace.default.createElement(Dialog2, { open: isDialogOpen, onOpenChange: setIsDialogOpen }, /* @__PURE__ */ React119__namespace.default.createElement(DialogContent2, { className: "sm:max-w-2xl max-h-[90vh] overflow-y-auto" }, /* @__PURE__ */ React119__namespace.default.createElement(DialogHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(DialogTitle2, null, currentItem ? "Edit Learning Objective" : "Add New Learning Objective")), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid gap-4 py-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "code" }, "Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77439
- Input,
77440
- {
77441
- id: "code",
77442
- value: formState.code || "",
77443
- onChange: (e2) => handleFormChange(
77444
- "code",
77445
- e2.target.value.toUpperCase()
77446
- ),
77447
- disabled: !!currentItem
77448
- }
77449
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "name" }, "Name (Description)"), /* @__PURE__ */ React119__namespace.default.createElement(
77450
- Input,
77451
- {
77452
- id: "name",
77453
- value: formState.name || "",
77454
- onChange: (e2) => handleFormChange(
77455
- "name",
77456
- e2.target.value
77457
- )
77458
- }
77459
- ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "subject" }, "Subject Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77460
- Input,
77461
- {
77462
- id: "subject",
77463
- value: formState.subject || "",
77464
- onChange: (e2) => handleFormChange(
77465
- "subject",
77466
- e2.target.value
77467
- )
77468
- }
77469
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "subjectCode" }, "Subject Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77470
- EditableCombobox,
77471
- {
77472
- options: subjects.map((s2) => ({
77473
- value: s2.code,
77474
- label: s2.name
77475
- })),
77476
- value: formState.subjectCode || "",
77477
- onChange: (val) => handleFormChange("subjectCode", val),
77478
- placeholder: "Select a subject..."
77479
- }
77480
- ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "category" }, "Category Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77481
- Input,
77482
- {
77483
- id: "category",
77484
- value: formState.category || "",
77485
- onChange: (e2) => handleFormChange(
77486
- "category",
77487
- e2.target.value
77488
- )
77489
- }
77490
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "categoryCode" }, "Category Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77491
- Input,
77492
- {
77493
- id: "categoryCode",
77494
- value: formState.categoryCode || "",
77495
- onChange: (e2) => handleFormChange(
77496
- "categoryCode",
77497
- e2.target.value
77498
- )
77499
- }
77500
- ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "topic" }, "Topic Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77501
- Input,
77502
- {
77503
- id: "topic",
77504
- value: formState.topic || "",
77505
- onChange: (e2) => handleFormChange(
77506
- "topic",
77507
- e2.target.value
77508
- )
77509
- }
77510
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "topicCode" }, "Topic Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77511
- Input,
77512
- {
77513
- id: "topicCode",
77514
- value: formState.topicCode || "",
77515
- onChange: (e2) => handleFormChange(
77516
- "topicCode",
77517
- e2.target.value
77518
- )
77519
- }
77520
- ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "grade" }, "Grade Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77521
- Input,
77522
- {
77523
- id: "grade",
77524
- value: formState.grade || "",
77525
- onChange: (e2) => handleFormChange(
77526
- "grade",
77527
- e2.target.value
77528
- )
77529
- }
77530
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "gradeCode" }, "Grade Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77531
- Input,
77532
- {
77533
- id: "gradeCode",
77534
- value: formState.gradeCode || "",
77535
- onChange: (e2) => handleFormChange(
77536
- "gradeCode",
77537
- e2.target.value
77538
- )
77539
- }
77540
- ))), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "keywords" }, "Keywords (comma-separated)"), /* @__PURE__ */ React119__namespace.default.createElement(
77541
- Textarea,
77542
- {
77543
- id: "keywords",
77544
- value: formState.keywords?.join(", ") || "",
77545
- onChange: (e2) => handleFormChange(
77546
- "keywords",
77547
- e2.target.value.split(",").map((s2) => s2.trim())
77548
- )
77549
- }
77550
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "stemElements" }, "STEM Elements (comma-separated)"), /* @__PURE__ */ React119__namespace.default.createElement(
77551
- Textarea,
77552
- {
77553
- id: "stemElements",
77554
- value: formState.stemElements?.join(", ") || "",
77555
- onChange: (e2) => handleFormChange(
77556
- "stemElements",
77557
- e2.target.value.split(",").map((s2) => s2.trim())
77558
- )
77559
- }
77560
- )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "bloomLevelsGuideline" }, "Bloom's Guideline (comma-separated)"), /* @__PURE__ */ React119__namespace.default.createElement(
77561
- Textarea,
77562
- {
77563
- id: "bloomLevelsGuideline",
77564
- value: formState.bloomLevelsGuideline?.join(
77565
- ", "
77566
- ) || "",
77567
- onChange: (e2) => handleFormChange(
77568
- "bloomLevelsGuideline",
77569
- e2.target.value.split(",").map((s2) => s2.trim())
77570
- )
77571
- }
77572
- ))), /* @__PURE__ */ React119__namespace.default.createElement(DialogFooter, null, /* @__PURE__ */ React119__namespace.default.createElement(
77573
- Button,
77574
- {
77575
- type: "button",
77576
- variant: "outline",
77577
- onClick: () => setIsDialogOpen(false),
77578
- disabled: isPending
77579
- },
77580
- "Cancel"
77581
- ), /* @__PURE__ */ React119__namespace.default.createElement(
77582
- Button,
77583
- {
77584
- type: "submit",
77585
- onClick: handleSubmit,
77586
- disabled: isPending || !formState.name?.trim() || !formState.code?.trim()
77587
- },
77588
- isPending && /* @__PURE__ */ React119__namespace.default.createElement(LoaderCircle, { className: "mr-2 h-4 w-4 animate-spin" }),
77589
- " ",
77590
- "Save"
77591
- )))), /* @__PURE__ */ React119__namespace.default.createElement(AlertDialog2, { open: isAlertOpen, onOpenChange: setIsAlertOpen }, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogContent2, null, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogTitle2, null, "Are you sure?"), /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogDescription2, null, 'This will permanently delete "', itemToDelete?.name, '".')), /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogFooter, null, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogCancel2, { disabled: isPending }, "Cancel"), /* @__PURE__ */ React119__namespace.default.createElement(
77592
- AlertDialogAction2,
77593
- {
77594
- onClick: confirmDelete,
77595
- disabled: isPending,
77596
- className: "bg-destructive hover:bg-destructive/90"
77597
- },
77598
- isPending && /* @__PURE__ */ React119__namespace.default.createElement(LoaderCircle, { className: "mr-2 h-4 w-4 animate-spin" }),
77599
- " ",
77600
- "Delete"
77601
- ))))));
77414
+ return (
77415
+ // --- START: FIX ---
77416
+ /* @__PURE__ */ React119__namespace.default.createElement(Card, { className: "flex flex-col h-full" }, /* @__PURE__ */ React119__namespace.default.createElement(CardHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(CardTitle, { className: "flex justify-between items-center" }, /* @__PURE__ */ React119__namespace.default.createElement("span", { className: "flex items-center" }, /* @__PURE__ */ React119__namespace.default.createElement(Lightbulb, { className: "mr-2 h-5 w-5 text-primary" }), " ", "Manage Learning Objectives"), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "flex items-center gap-2" }, onBulkAdd && /* @__PURE__ */ React119__namespace.default.createElement(
77417
+ MetadataImportControls,
77418
+ {
77419
+ metadataName: "Learning Objectives",
77420
+ onImport: handleImport
77421
+ }
77422
+ ), /* @__PURE__ */ React119__namespace.default.createElement(Button, { onClick: handleAddItem, size: "sm" }, /* @__PURE__ */ React119__namespace.default.createElement(CirclePlus, { className: "mr-2 h-4 w-4" }), " Add Learning Objective")))), /* @__PURE__ */ React119__namespace.default.createElement(CardContent, { className: "flex-1 flex flex-col min-h-0" }, isLoading ? /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "flex justify-center items-center h-full" }, /* @__PURE__ */ React119__namespace.default.createElement(LoaderCircle, { className: "h-8 w-8 animate-spin text-primary" })) : items.length === 0 ? /* @__PURE__ */ React119__namespace.default.createElement("p", { className: "text-center text-muted-foreground py-4" }, "No Learning Objectives found.") : (
77423
+ // --- START: FIX ---
77424
+ /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "flex-1 relative border rounded-md" }, /* @__PURE__ */ React119__namespace.default.createElement(ScrollArea2, { className: "absolute inset-0" }, /* @__PURE__ */ React119__namespace.default.createElement(Table2, null, /* @__PURE__ */ React119__namespace.default.createElement(TableHeader, { className: "sticky top-0 bg-card z-10" }, /* @__PURE__ */ React119__namespace.default.createElement(TableRow, null, /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Code"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Name"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Subject"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, null, "Topic"), /* @__PURE__ */ React119__namespace.default.createElement(TableHead, { className: "text-right w-[120px]" }, "Actions"))), /* @__PURE__ */ React119__namespace.default.createElement(TableBody, null, items.map((item) => /* @__PURE__ */ React119__namespace.default.createElement(TableRow, { key: item.id }, /* @__PURE__ */ React119__namespace.default.createElement(TableCell, { className: "font-mono text-xs" }, item.code), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, { className: "font-medium" }, item.name), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, null, item.subject || item.subjectCode), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, null, item.topic || item.topicCode), /* @__PURE__ */ React119__namespace.default.createElement(TableCell, { className: "text-right" }, /* @__PURE__ */ React119__namespace.default.createElement(
77425
+ Button,
77426
+ {
77427
+ variant: "ghost",
77428
+ size: "icon",
77429
+ onClick: () => handleEditItem(item),
77430
+ className: "mr-2"
77431
+ },
77432
+ /* @__PURE__ */ React119__namespace.default.createElement(PenLine, { className: "h-4 w-4" })
77433
+ ), /* @__PURE__ */ React119__namespace.default.createElement(
77434
+ Button,
77435
+ {
77436
+ variant: "ghost",
77437
+ size: "icon",
77438
+ onClick: () => handleDeleteItem(item),
77439
+ className: "text-destructive hover:text-destructive"
77440
+ },
77441
+ /* @__PURE__ */ React119__namespace.default.createElement(Trash2, { className: "h-4 w-4" })
77442
+ ))))))))
77443
+ ), /* @__PURE__ */ React119__namespace.default.createElement(Dialog2, { open: isDialogOpen, onOpenChange: setIsDialogOpen }, /* @__PURE__ */ React119__namespace.default.createElement(DialogContent2, { className: "sm:max-w-2xl max-h-[90vh] overflow-y-auto" }, /* @__PURE__ */ React119__namespace.default.createElement(DialogHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(DialogTitle2, null, currentItem ? "Edit Learning Objective" : "Add New Learning Objective")), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid gap-4 py-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "code" }, "Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77444
+ Input,
77445
+ {
77446
+ id: "code",
77447
+ value: formState.code || "",
77448
+ onChange: (e2) => handleFormChange(
77449
+ "code",
77450
+ e2.target.value.toUpperCase()
77451
+ ),
77452
+ disabled: !!currentItem
77453
+ }
77454
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "name" }, "Name (Description)"), /* @__PURE__ */ React119__namespace.default.createElement(
77455
+ Input,
77456
+ {
77457
+ id: "name",
77458
+ value: formState.name || "",
77459
+ onChange: (e2) => handleFormChange(
77460
+ "name",
77461
+ e2.target.value
77462
+ )
77463
+ }
77464
+ ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "subject" }, "Subject Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77465
+ Input,
77466
+ {
77467
+ id: "subject",
77468
+ value: formState.subject || "",
77469
+ onChange: (e2) => handleFormChange(
77470
+ "subject",
77471
+ e2.target.value
77472
+ )
77473
+ }
77474
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "subjectCode" }, "Subject Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77475
+ EditableCombobox,
77476
+ {
77477
+ options: subjects.map((s2) => ({
77478
+ value: s2.code,
77479
+ label: s2.name
77480
+ })),
77481
+ value: formState.subjectCode || "",
77482
+ onChange: (val) => handleFormChange("subjectCode", val),
77483
+ placeholder: "Select a subject..."
77484
+ }
77485
+ ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "category" }, "Category Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77486
+ Input,
77487
+ {
77488
+ id: "category",
77489
+ value: formState.category || "",
77490
+ onChange: (e2) => handleFormChange(
77491
+ "category",
77492
+ e2.target.value
77493
+ )
77494
+ }
77495
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "categoryCode" }, "Category Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77496
+ Input,
77497
+ {
77498
+ id: "categoryCode",
77499
+ value: formState.categoryCode || "",
77500
+ onChange: (e2) => handleFormChange(
77501
+ "categoryCode",
77502
+ e2.target.value
77503
+ )
77504
+ }
77505
+ ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "topic" }, "Topic Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77506
+ Input,
77507
+ {
77508
+ id: "topic",
77509
+ value: formState.topic || "",
77510
+ onChange: (e2) => handleFormChange(
77511
+ "topic",
77512
+ e2.target.value
77513
+ )
77514
+ }
77515
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "topicCode" }, "Topic Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77516
+ Input,
77517
+ {
77518
+ id: "topicCode",
77519
+ value: formState.topicCode || "",
77520
+ onChange: (e2) => handleFormChange(
77521
+ "topicCode",
77522
+ e2.target.value
77523
+ )
77524
+ }
77525
+ ))), /* @__PURE__ */ React119__namespace.default.createElement("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4" }, /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "grade" }, "Grade Name"), /* @__PURE__ */ React119__namespace.default.createElement(
77526
+ Input,
77527
+ {
77528
+ id: "grade",
77529
+ value: formState.grade || "",
77530
+ onChange: (e2) => handleFormChange(
77531
+ "grade",
77532
+ e2.target.value
77533
+ )
77534
+ }
77535
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "gradeCode" }, "Grade Code"), /* @__PURE__ */ React119__namespace.default.createElement(
77536
+ Input,
77537
+ {
77538
+ id: "gradeCode",
77539
+ value: formState.gradeCode || "",
77540
+ onChange: (e2) => handleFormChange(
77541
+ "gradeCode",
77542
+ e2.target.value
77543
+ )
77544
+ }
77545
+ ))), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "keywords" }, "Keywords (comma-separated)"), /* @__PURE__ */ React119__namespace.default.createElement(
77546
+ Textarea,
77547
+ {
77548
+ id: "keywords",
77549
+ value: formState.keywords?.join(", ") || "",
77550
+ onChange: (e2) => handleFormChange(
77551
+ "keywords",
77552
+ e2.target.value.split(",").map((s2) => s2.trim())
77553
+ )
77554
+ }
77555
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "stemElements" }, "STEM Elements (comma-separated)"), /* @__PURE__ */ React119__namespace.default.createElement(
77556
+ Textarea,
77557
+ {
77558
+ id: "stemElements",
77559
+ value: formState.stemElements?.join(", ") || "",
77560
+ onChange: (e2) => handleFormChange(
77561
+ "stemElements",
77562
+ e2.target.value.split(",").map((s2) => s2.trim())
77563
+ )
77564
+ }
77565
+ )), /* @__PURE__ */ React119__namespace.default.createElement("div", null, /* @__PURE__ */ React119__namespace.default.createElement(Label2, { htmlFor: "bloomLevelsGuideline" }, "Bloom's Guideline (comma-separated)"), /* @__PURE__ */ React119__namespace.default.createElement(
77566
+ Textarea,
77567
+ {
77568
+ id: "bloomLevelsGuideline",
77569
+ value: formState.bloomLevelsGuideline?.join(
77570
+ ", "
77571
+ ) || "",
77572
+ onChange: (e2) => handleFormChange(
77573
+ "bloomLevelsGuideline",
77574
+ e2.target.value.split(",").map((s2) => s2.trim())
77575
+ )
77576
+ }
77577
+ ))), /* @__PURE__ */ React119__namespace.default.createElement(DialogFooter, null, /* @__PURE__ */ React119__namespace.default.createElement(
77578
+ Button,
77579
+ {
77580
+ type: "button",
77581
+ variant: "outline",
77582
+ onClick: () => setIsDialogOpen(false),
77583
+ disabled: isPending
77584
+ },
77585
+ "Cancel"
77586
+ ), /* @__PURE__ */ React119__namespace.default.createElement(
77587
+ Button,
77588
+ {
77589
+ type: "submit",
77590
+ onClick: handleSubmit,
77591
+ disabled: isPending || !formState.name?.trim() || !formState.code?.trim()
77592
+ },
77593
+ isPending && /* @__PURE__ */ React119__namespace.default.createElement(LoaderCircle, { className: "mr-2 h-4 w-4 animate-spin" }),
77594
+ " ",
77595
+ "Save"
77596
+ )))), /* @__PURE__ */ React119__namespace.default.createElement(AlertDialog2, { open: isAlertOpen, onOpenChange: setIsAlertOpen }, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogContent2, null, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogHeader, null, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogTitle2, null, "Are you sure?"), /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogDescription2, null, 'This will permanently delete "', itemToDelete?.name, '".')), /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogFooter, null, /* @__PURE__ */ React119__namespace.default.createElement(AlertDialogCancel2, { disabled: isPending }, "Cancel"), /* @__PURE__ */ React119__namespace.default.createElement(
77597
+ AlertDialogAction2,
77598
+ {
77599
+ onClick: confirmDelete,
77600
+ disabled: isPending,
77601
+ className: "bg-destructive hover:bg-destructive/90"
77602
+ },
77603
+ isPending && /* @__PURE__ */ React119__namespace.default.createElement(LoaderCircle, { className: "mr-2 h-4 w-4 animate-spin" }),
77604
+ " ",
77605
+ "Delete"
77606
+ ))))))
77607
+ );
77602
77608
  }
77603
77609
 
77604
77610
  // src/react-ui/components/metadata/ContextManager.tsx