Skip to content

Commit

Permalink
Fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
benchristel committed Jan 11, 2024
1 parent 507684f commit 4dc7ffc
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export const expressionItemWithAnswer = (answer: string): PerseusItem => {
},
{major: 1, minor: 0},
);
}
};

export const expressionItem2: PerseusItem = createItemJson(
{
Expand Down
3 changes: 1 addition & 2 deletions packages/perseus/src/widgets/__tests__/expression.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import {
expressionItem3,
expressionItem3Options,
expressionItemWithAnswer,
expressionItemWithSin,
} from "../__testdata__/expression.testdata";
import {Expression} from "../expression";

Expand Down Expand Up @@ -209,7 +208,7 @@ describe("Expression Widget", function () {
const item = expressionItemWithAnswer("sin(sin(x))");
assertCorrect(item, "sen(sen(x))");
});
})
});

describe("analytics", () => {
const assertKeypadVersion = (
Expand Down
4 changes: 2 additions & 2 deletions packages/perseus/src/widgets/expression.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@ const anglicizeOperators = (tex: string): string => {
// To ensure that answers in various languages are graded correctly, we
// convert operators to their Englishy forms.
return tex.replace(/\\operatorname{sen}/g, "\\sin ");
}
};

const normalizeTex = (tex: string): string => {
return anglicizeOperators(insertBraces(tex));
}
};

const deriveKeypadVersion = (apiOptions: APIOptions) => {
// We can derive which version of the keypad is in use. This is
Expand Down

0 comments on commit 4dc7ffc

Please sign in to comment.