Skip to content

Commit bb07ec6

Browse files
committed
[benc/remove-json-mode-toggle] Update comments to be slightly closer to correct
1 parent 0fab6b1 commit bb07ec6

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

packages/perseus-editor/src/editor-page.tsx

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ type Props = {
3434
answerArea?: PerseusAnswerArea | null; // related to the question,
3535
// TODO(CP-4838): Should this be a required prop?
3636
contentPaths?: ReadonlyArray<string>;
37-
/** "Power user" mode. Shows the raw JSON of the question. */
38-
developerMode: boolean;
3937
hints?: ReadonlyArray<Hint>; // related to the question,
4038
/** A function which takes a file object (guaranteed to be an image) and
4139
* a callback, then calls the callback with the url where the image
@@ -45,11 +43,22 @@ type Props = {
4543
imageUploader?: ImageUploader;
4644
/** The content ID of the AssessmentItem being edited. */
4745
itemId: string;
48-
/** Whether the question is displaying as JSON or if it is
49-
* showing the editor itself with the rendering
50-
* Only used in the perseus demos. Consider removing.
46+
/**
47+
* If both jsonMode and developerMode are true, an editable text box with
48+
* the item JSON is displayed. If either jsonMode or developerMode is
49+
* false, the regular editor GUI is hidden.
50+
*
51+
* @see {@linkcode Props.developerMode}
5152
*/
5253
jsonMode: boolean;
54+
/**
55+
* If both jsonMode and developerMode are true, an editable text box with
56+
* the item JSON is displayed. If either jsonMode or developerMode is
57+
* false, the regular editor GUI is hidden.
58+
*
59+
* @see {@linkcode Props.jsonMode}
60+
*/
61+
developerMode: boolean;
5362
/** A function which is called with the new JSON blob of content. */
5463
onChange: ChangeHandler;
5564
/** A function which is called when the preview device changes. */

0 commit comments

Comments
 (0)