Skip to content

Commit

Permalink
Merge branch 'feature/client-validation' into tb/LEMS-2440/iframe-sep…
Browse files Browse the repository at this point in the history
…arate-answers-from-user-input
  • Loading branch information
Myranae committed Dec 17, 2024
2 parents d1e5b22 + 0464a76 commit 70571d9
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
5 changes: 5 additions & 0 deletions .changeset/fifty-laws-hear.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@khanacademy/perseus": patch
---

Remove unused CS Program rubric type
7 changes: 0 additions & 7 deletions packages/perseus/src/validation.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,6 @@ export type PerseusCategorizerValidationData = {
items: ReadonlyArray<string>;
};

// TODO(LEMS-2440): Can possibly be removed during 2440?
// This is not used for grading at all. The only place it is used is to define
// Props type in cs-program.tsx, but RenderProps already contains WidgetOptions
// and is already included in the Props type.
export type PerseusCSProgramRubric = Empty;

export type PerseusCSProgramUserInput = {
status: UserInputStatus;
message: string | null;
Expand Down Expand Up @@ -235,7 +229,6 @@ export type PerseusTableUserInput = ReadonlyArray<ReadonlyArray<string>>;

export type Rubric =
| PerseusCategorizerScoringData
| PerseusCSProgramRubric
| PerseusDropdownRubric
| PerseusExpressionRubric
| PerseusGroupRubric
Expand Down
7 changes: 2 additions & 5 deletions packages/perseus/src/widgets/cs-program/cs-program.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,14 @@ import scoreCSProgram from "./score-cs-program";

import type {PerseusCSProgramWidgetOptions} from "../../perseus-types";
import type {Widget, WidgetExports, WidgetProps} from "../../types";
import type {
PerseusCSProgramRubric,
PerseusCSProgramUserInput,
} from "../../validation.types";
import type {PerseusCSProgramUserInput} from "../../validation.types";
import type {UnsupportedWidgetPromptJSON} from "../../widget-ai-utils/unsupported-widget";

const {updateQueryString} = Util;

type RenderProps = PerseusCSProgramWidgetOptions & PerseusCSProgramUserInput;

type Props = WidgetProps<RenderProps, PerseusCSProgramRubric>;
type Props = WidgetProps<RenderProps>;

type DefaultProps = {
showEditor: Props["showEditor"];
Expand Down

0 comments on commit 70571d9

Please sign in to comment.