@instructure/platform-rubrics 3.0.1 → 3.1.0

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.
Files changed (42) hide show
  1. package/dist/_internal/RubricAssignment/hooks/useAssignmentRubric.d.ts +1 -0
  2. package/dist/_internal/RubricAssignment/hooks/useAssignmentRubric.d.ts.map +1 -1
  3. package/dist/_internal/RubricAssignment/hooks/useAssignmentRubricState.d.ts +1 -0
  4. package/dist/_internal/RubricAssignment/hooks/useAssignmentRubricState.d.ts.map +1 -1
  5. package/dist/_internal/RubricForm/components/RubricGeneratorNutritionFacts.d.ts.map +1 -0
  6. package/dist/_internal/ViewRubrics/useRubricsQuery.d.ts.map +1 -1
  7. package/dist/_internal/ViewRubrics/useViewRubrics.d.ts.map +1 -1
  8. package/dist/_internal/constants/i18n.d.ts +14 -0
  9. package/dist/_internal/constants/i18n.d.ts.map +1 -1
  10. package/dist/_internal/utils/i18n.d.ts +14 -0
  11. package/dist/_internal/utils/i18n.d.ts.map +1 -1
  12. package/dist/canvas.js +4752 -8509
  13. package/dist/chunks/{errorPage-CYyehhNJ.js → errorPage-B145UIKY.js} +51 -37
  14. package/dist/chunks/useAssignmentRubricState-Cha3tHoC.js +8508 -0
  15. package/dist/foundation/RubricAssignmentBuilder/RubricAssignmentBuilder.d.ts +28 -0
  16. package/dist/foundation/RubricAssignmentBuilder/RubricAssignmentBuilder.d.ts.map +1 -0
  17. package/dist/foundation/RubricBuilder/RubricBuilder.d.ts.map +1 -1
  18. package/dist/foundation/RubricBuilder/components/CriteriaSection.d.ts +3 -1
  19. package/dist/foundation/RubricBuilder/components/CriteriaSection.d.ts.map +1 -1
  20. package/dist/foundation/RubricBuilder/components/generator/GenerateCriteriaForm.d.ts +14 -0
  21. package/dist/foundation/RubricBuilder/components/generator/GenerateCriteriaForm.d.ts.map +1 -0
  22. package/dist/foundation/RubricBuilder/components/generator/GeneratedCriteriaFeedback.d.ts +8 -0
  23. package/dist/foundation/RubricBuilder/components/generator/GeneratedCriteriaFeedback.d.ts.map +1 -0
  24. package/dist/foundation/RubricBuilder/components/generator/GeneratedCriteriaSummary.d.ts +11 -0
  25. package/dist/foundation/RubricBuilder/components/generator/GeneratedCriteriaSummary.d.ts.map +1 -0
  26. package/dist/foundation/RubricBuilder/components/generator/RegenerateCriteriaModal.d.ts +7 -0
  27. package/dist/foundation/RubricBuilder/components/generator/RegenerateCriteriaModal.d.ts.map +1 -0
  28. package/dist/foundation/RubricBuilder/components/generator/RubricGeneratorPanel.d.ts +9 -0
  29. package/dist/foundation/RubricBuilder/components/generator/RubricGeneratorPanel.d.ts.map +1 -0
  30. package/dist/foundation/RubricBuilder/components/generator/RubricGeneratorStatus.d.ts +9 -0
  31. package/dist/foundation/RubricBuilder/components/generator/RubricGeneratorStatus.d.ts.map +1 -0
  32. package/dist/foundation/RubricBuilder/useCriteriaGenerator.d.ts +44 -0
  33. package/dist/foundation/RubricBuilder/useCriteriaGenerator.d.ts.map +1 -0
  34. package/dist/foundation/index.d.ts +2 -0
  35. package/dist/foundation/index.d.ts.map +1 -1
  36. package/dist/foundation.js +1110 -512
  37. package/dist/index.js +1 -1
  38. package/locales/en.json +14 -0
  39. package/package.json +2 -2
  40. package/dist/canvas/RubricForm/components/AIGeneratedCriteria/RubricGeneratorNutritionFacts.d.ts.map +0 -1
  41. package/dist/chunks/ErrorShip-COgM3wMV.js +0 -4726
  42. /package/dist/{canvas/RubricForm/components/AIGeneratedCriteria → _internal/RubricForm/components}/RubricGeneratorNutritionFacts.d.ts +0 -0
@@ -1,13 +1,13 @@
1
1
  import { jsx as l } from "react/jsx-runtime";
2
2
  import s, { createContext as C, useContext as b, useMemo as R } from "react";
3
3
  import { createErrorReporter as g, GenericErrorPage as f, NotFoundPage as v } from "@instructure/platform-generic-error-page";
4
- const S = {
4
+ const L = {
5
5
  cancel: "Cancel",
6
6
  close: "Close",
7
7
  delete: "Delete",
8
8
  duplicate: "Duplicate",
9
9
  edit: "Edit"
10
- }, L = {
10
+ }, S = {
11
11
  warningModalExitButton: "Exit",
12
12
  warningModalHeader: "Warning",
13
13
  warningModalMessage: "You are about to exit the rubric editor. Any unsaved changes will be lost."
@@ -25,13 +25,13 @@ const S = {
25
25
  }, y = {
26
26
  pointsPossibleAbbreviated: "%{possible} pts",
27
27
  pointsPossibleRange: "%{possible} to >%{min} pts"
28
- }, M = {
28
+ }, A = {
29
29
  ratingScaleBelow: "Below",
30
30
  ratingScaleExceeds: "Exceeds",
31
31
  ratingScaleMastery: "Mastery",
32
32
  ratingScaleNear: "Near",
33
33
  ratingScaleNoEvidence: "No Evidence"
34
- }, A = {
34
+ }, M = {
35
35
  rubricSaveSuccess: "Rubric saved successfully"
36
36
  }, T = {
37
37
  rubricFormCannotUpdate: "Rubrics cannot be modified once they have been used in more than one place. Any saved changes will create a new rubric.",
@@ -59,17 +59,17 @@ const S = {
59
59
  scoringTypeScored: "Scored",
60
60
  scoringTypeSelectLabel: "Scoring",
61
61
  scoringTypeUnscored: "Unscored"
62
- }, E = {
62
+ }, B = {
63
63
  hideOutcomeResultsLabel: "Don't post to Learning Mastery Gradebook",
64
64
  hideScoreTotalLabel: "Hide rubric score total from students",
65
65
  useForGradingLabel: "Use this rubric for assignment grading"
66
- }, B = {
66
+ }, E = {
67
67
  confirmToContinueHeader: "Confirm to continue",
68
68
  gradingHistoryWarning: "This rubric has already been used for grading. Saving changes may alter student scores or grading history. Are you sure you want to proceed?"
69
- }, I = {
69
+ }, N = {
70
70
  saveConfirmModalLabel: "Rubric Save Confirmation Dialog",
71
71
  saveConfirmModalSave: "Save"
72
- }, N = {
72
+ }, I = {
73
73
  editConfirmModalConfirm: "Confirm",
74
74
  editConfirmModalLabel: "Edit Confirm Modal"
75
75
  }, H = {
@@ -108,7 +108,7 @@ const S = {
108
108
  errorPageWhatHappened: "What happened?",
109
109
  errorPageYourEmailAddress: "Your Email Address",
110
110
  rubricErrorPageCategory: "Edit Rubric Error Page"
111
- }, U = {
111
+ }, G = {
112
112
  criterionModalCreateTitle: "Create New Criterion",
113
113
  criterionModalEditTitle: "Edit Criterion",
114
114
  criterionModalEnableRange: "Enable Range",
@@ -118,12 +118,12 @@ const S = {
118
118
  criterionModalPointsPossible: "Points Possible",
119
119
  criterionModalRatingScaleHeading: "Rating Scale",
120
120
  criterionModalSaveCriterion: "Save Criterion"
121
- }, W = {
121
+ }, U = {
122
122
  criterionLongDescriptionLabel: "Criterion Description",
123
123
  criterionLongDescriptionPlaceholder: "Enter the description",
124
124
  criterionNameLabel: "Criterion Name",
125
125
  criterionNamePlaceholder: "Enter the name"
126
- }, G = {
126
+ }, W = {
127
127
  pointRangeLabel: "Point Range",
128
128
  pointsLabel: "Points",
129
129
  rangeStartPrefix: ">%{rangeStart} to ",
@@ -386,7 +386,7 @@ const S = {
386
386
  rubricTablePointsHeader: "Total Points",
387
387
  rubricTableSelectRubricLabel: "Select %{title}",
388
388
  rubricTableSortByLabel: "Sort by"
389
- }, Se = {
389
+ }, Le = {
390
390
  viewRubricsArchivedTabLabel: "Archived",
391
391
  viewRubricsArchiveError: "Error Archiving Rubric",
392
392
  viewRubricsArchiveSuccess: "Rubric archived successfully",
@@ -402,7 +402,7 @@ const S = {
402
402
  viewRubricsSavedTabLabel: "Saved",
403
403
  viewRubricsUnarchiveError: "Error Un-Archiving Rubric",
404
404
  viewRubricsUnarchiveSuccess: "Rubric un-archived successfully"
405
- }, Le = {
405
+ }, Se = {
406
406
  importFailuresModalFileListHeader: "The import failed for the following file(s):",
407
407
  importFailuresModalHeading: "Import Failed",
408
408
  importFailuresModalLabel: "Import Failures",
@@ -437,12 +437,12 @@ const S = {
437
437
  rubricAssignmentSelfAssessmentInfoText: "This toggle will be disabled if the due date has passed OR there have already been self-assessments made on this assignment OR if the assignment is a group assignment.",
438
438
  rubricAssignmentSelfAssessmentLabel: "Enable self assessment",
439
439
  rubricAssignmentSelfAssessmentUpdateError: "Failed to update self assessment settings"
440
- }, Me = {
440
+ }, Ae = {
441
441
  rubricSearchTrayHeading: "Find Rubric",
442
442
  rubricSearchTrayInputLabel: "search rubrics input",
443
443
  rubricSearchTrayInputPlaceholder: "Search rubrics",
444
444
  rubricSearchTrayLabel: "Rubric Search Tray"
445
- }, Ae = {
445
+ }, Me = {
446
446
  rubricContextSelectAccountPrefix: "Account",
447
447
  rubricContextSelectCoursePrefix: "Course",
448
448
  rubricContextSelectEmptyHeading: "No Rubrics Found",
@@ -460,7 +460,7 @@ const S = {
460
460
  }, Fe = {
461
461
  rubricCreateModalCreateHeader: "Create Rubric",
462
462
  rubricCreateModalEditHeader: "Edit Rubric"
463
- }, Ee = {
463
+ }, Be = {
464
464
  rubricAssignmentContainerAddError: "Failed to add rubric to assignment",
465
465
  rubricAssignmentContainerAddSuccess: "Rubric added to assignment",
466
466
  rubricAssignmentContainerCreateRubric: "Create Rubric",
@@ -471,7 +471,7 @@ const S = {
471
471
  rubricAssignmentContainerPreviewRubric: "Preview Rubric",
472
472
  rubricAssignmentContainerReplaceRubric: "Replace Rubric",
473
473
  rubricAssignmentContainerUnlinkRubric: "Unlink Rubric"
474
- }, Be = {
474
+ }, Ee = {
475
475
  rubricBuilderAddCriterion: "Add criterion",
476
476
  rubricBuilderAddCriterionError: "Add at least one criterion.",
477
477
  rubricBuilderAddRatingLevel: "Add rating level",
@@ -505,6 +505,20 @@ const S = {
505
505
  rubricBuilderExpandCriterion: "Expand %{name}",
506
506
  rubricBuilderFeedbackLabel: "Feedback",
507
507
  rubricBuilderFeedbackWrittenOnly: "Written only",
508
+ rubricBuilderGeneratorAdded: {
509
+ one: "%{count} criterion added",
510
+ other: "%{count} criteria added"
511
+ },
512
+ rubricBuilderGeneratorAdditionalLabel: "Additional information",
513
+ rubricBuilderGeneratorCriteriaCountLabel: "Number of criteria",
514
+ rubricBuilderGeneratorDifficultyLabel: "Level of difficulty",
515
+ rubricBuilderGeneratorDoneHeading: "Criteria generated",
516
+ rubricBuilderGeneratorGenerate: "Generate",
517
+ rubricBuilderGeneratorGenerating: "Generating criteria",
518
+ rubricBuilderGeneratorRatingCountLabel: "Number of ratings",
519
+ rubricBuilderGeneratorRegenerated: "Criteria regenerated",
520
+ rubricBuilderGeneratorStandardLabel: "Standard or outcome information",
521
+ rubricBuilderGeneratorToggle: "Rubric generator",
508
522
  rubricBuilderKeepEditing: "Keep editing",
509
523
  rubricBuilderNameLabel: "Rubric name",
510
524
  rubricBuilderPointRangeLabel: "Point range",
@@ -522,27 +536,27 @@ const S = {
522
536
  rubricBuilderSave: "Save",
523
537
  rubricBuilderWrittenFeedback: "Written feedback"
524
538
  }, c = {
525
- ...S,
526
539
  ...L,
540
+ ...S,
527
541
  ...w,
528
542
  ...y,
529
- ...M,
530
543
  ...A,
544
+ ...M,
531
545
  ...T,
532
546
  ...P,
533
547
  ...D,
534
548
  ...F,
535
- ...E,
536
549
  ...B,
537
- ...I,
550
+ ...E,
538
551
  ...N,
552
+ ...I,
539
553
  ...H,
540
554
  ...k,
541
555
  ...x,
542
556
  ...O,
557
+ ...G,
543
558
  ...U,
544
559
  ...W,
545
- ...G,
546
560
  ...V,
547
561
  ...j,
548
562
  ...q,
@@ -576,18 +590,18 @@ const S = {
576
590
  ...Re,
577
591
  ...fe,
578
592
  ...ve,
579
- ...Se,
593
+ ...Le,
580
594
  ...we,
581
595
  ...ye,
582
- ...Me,
583
596
  ...Ae,
597
+ ...Me,
584
598
  ...Te,
585
599
  ...Pe,
586
600
  ...De,
587
601
  ...Fe,
588
- ...Ee,
589
- ...Le,
590
- ...Be
602
+ ...Be,
603
+ ...Se,
604
+ ...Ee
591
605
  }, m = s.createContext(
592
606
  void 0
593
607
  );
@@ -596,16 +610,16 @@ function Ye() {
596
610
  if (!e)
597
611
  throw new Error("useTranslations must be used within TranslationsProvider");
598
612
  const r = s.useCallback(
599
- (t) => Ie(t, e.translate),
613
+ (t) => Ne(t, e.translate),
600
614
  [e.translate]
601
615
  );
602
616
  return { ...e, resolveToken: r };
603
617
  }
604
- const Ie = (e, r) => {
618
+ const Ne = (e, r) => {
605
619
  if (typeof e == "string") return r(e);
606
620
  const { key: t, count: i, vars: a } = e;
607
621
  return i !== void 0 ? r(t, { count: i, ...a }) : r(t, a);
608
- }, Ne = (e) => (r, t) => {
622
+ }, Ie = (e) => (r, t) => {
609
623
  const i = e[r];
610
624
  let a;
611
625
  if (typeof i == "object" && "one" in i && "other" in i) {
@@ -614,7 +628,7 @@ const Ie = (e, r) => {
614
628
  } else
615
629
  a = i || r;
616
630
  return t ? a.replace(/%\{([^}]+)}/g, (n, o) => o in t ? String(t[o]) : n) : a;
617
- }, He = Ne(c), ze = Object.fromEntries(
631
+ }, He = Ie(c), ze = Object.fromEntries(
618
632
  Object.keys(c).map((e) => [
619
633
  e,
620
634
  (r) => He(e, r)
@@ -642,21 +656,21 @@ function Xe() {
642
656
  throw new Error("useTranslationBridge must be used within RubricsTranslationsScope");
643
657
  return e;
644
658
  }
645
- const Oe = 8, Ue = 8, We = {
659
+ const Oe = 8, Ge = 8, Ue = {
646
660
  rubricCriterionRange: !1,
647
661
  gradingRubricsPagination: !1,
648
662
  rubricSelfAssessmentEnabled: !1,
649
663
  outcomeExtraCreditEnabled: !1,
650
664
  aiRubricsEnabled: !1
651
- }, Ge = {
665
+ }, We = {
652
666
  aiRubricsMaxCriterionCount: Oe,
653
- aiRubricsMaxRatingCount: Ue
667
+ aiRubricsMaxRatingCount: Ge
654
668
  }, Ve = {
655
669
  courseId: void 0,
656
670
  accountId: void 0,
657
671
  rootOutcomeGroupId: void 0,
658
- ...We,
659
- ...Ge
672
+ ...Ue,
673
+ ...We
660
674
  }, d = C(Ve);
661
675
  function u(e) {
662
676
  return e ? Object.fromEntries(
@@ -745,7 +759,7 @@ function tr(e) {
745
759
  export {
746
760
  Oe as D,
747
761
  Ke as R,
748
- Ue as a,
762
+ Ge as a,
749
763
  tr as b,
750
764
  er as c,
751
765
  ze as d,