@khanacademy/perseus 71.5.0 → 72.0.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.
@@ -118,15 +118,14 @@ declare const _default: React.ForwardRefExoticComponent<Omit<Pick<SharedRenderer
118
118
  apiOptions?: Readonly<{
119
119
  isArticle?: boolean;
120
120
  onFocusChange?: (newFocusPath: FocusPath, oldFocusPath: FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
121
- GroupMetadataEditor?: React.ComponentType<any>;
122
121
  showAlignmentOptions?: boolean;
123
122
  readOnly?: boolean;
123
+ editingDisabled?: boolean;
124
124
  answerableCallback?: (arg1: boolean) => unknown;
125
125
  getAnotherHint?: () => unknown;
126
126
  interactionCallback?: (widgetData: {
127
127
  [widgetId: string]: any;
128
128
  }) => void;
129
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
130
129
  imagePlaceholder?: React.ReactNode;
131
130
  widgetPlaceholder?: React.ReactNode;
132
131
  baseElements?: {
package/dist/types.d.ts CHANGED
@@ -90,7 +90,6 @@ export type ChangeHandler = (arg1: {
90
90
  }, callback?: () => void, silent?: boolean) => unknown;
91
91
  export type ImageUploader = (file: File, callback: (url: string) => unknown) => unknown;
92
92
  export type Path = ReadonlyArray<string>;
93
- type StubTagEditorType = any;
94
93
  type TrackInteractionArgs = {
95
94
  type: string;
96
95
  id: string;
@@ -109,29 +108,22 @@ export type GenerateUrlArgs = {
109
108
  export type APIOptions = Readonly<{
110
109
  isArticle?: boolean;
111
110
  onFocusChange?: (newFocusPath: FocusPath, oldFocusPath: FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
112
- /**
113
- * @deprecated - metadata is no longer used by the Group widget
114
- */
115
- GroupMetadataEditor?: React.ComponentType<StubTagEditorType>;
116
111
  showAlignmentOptions?: boolean;
117
112
  /**
118
113
  * A boolean that indicates whether the associated problem has been
119
114
  * answered correctly and should no longer be interactive.
120
115
  */
121
116
  readOnly?: boolean;
117
+ /**
118
+ * A boolean that indicates whether the editor interface should be
119
+ * disabled, preventing content creators from making changes.
120
+ */
121
+ editingDisabled?: boolean;
122
122
  answerableCallback?: (arg1: boolean) => unknown;
123
123
  getAnotherHint?: () => unknown;
124
124
  interactionCallback?: (widgetData: {
125
125
  [widgetId: string]: any;
126
126
  }) => void;
127
- /**
128
- * A function that takes in the relative problem number (starts at
129
- * 0 and is incremented for each group widget), and the ID of the
130
- * group widget, then returns a react component that will be added
131
- * immediately above the renderer in the group widget. If the
132
- * function returns null, no annotation will be added.
133
- */
134
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
135
127
  /**
136
128
  * If imagePlaceholder is set, Perseus will render the placeholder instead
137
129
  * of the image node.
@@ -323,10 +315,10 @@ export type APIOptionsWithDefaults = Readonly<APIOptions & {
323
315
  baseElements: NonNullable<APIOptions["baseElements"]>;
324
316
  canScrollPage: NonNullable<APIOptions["canScrollPage"]>;
325
317
  editorChangeDelay: NonNullable<APIOptions["editorChangeDelay"]>;
326
- groupAnnotator: NonNullable<APIOptions["groupAnnotator"]>;
327
318
  isArticle: NonNullable<APIOptions["isArticle"]>;
328
319
  isMobile: NonNullable<APIOptions["isMobile"]>;
329
320
  isMobileApp: NonNullable<APIOptions["isMobileApp"]>;
321
+ editingDisabled: NonNullable<APIOptions["editingDisabled"]>;
330
322
  onFocusChange: NonNullable<APIOptions["onFocusChange"]>;
331
323
  readOnly: NonNullable<APIOptions["readOnly"]>;
332
324
  setDrawingAreaAvailable: NonNullable<APIOptions["setDrawingAreaAvailable"]>;
@@ -70,15 +70,14 @@ export declare class Expression extends React.Component<Props> implements Widget
70
70
  apiOptions: Readonly<Readonly<{
71
71
  isArticle?: boolean;
72
72
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
73
- GroupMetadataEditor?: React.ComponentType<any>;
74
73
  showAlignmentOptions?: boolean;
75
74
  readOnly?: boolean;
75
+ editingDisabled?: boolean;
76
76
  answerableCallback?: (arg1: boolean) => unknown;
77
77
  getAnotherHint?: () => unknown;
78
78
  interactionCallback?: (widgetData: {
79
79
  [widgetId: string]: any;
80
80
  }) => void;
81
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
82
81
  imagePlaceholder?: React.ReactNode;
83
82
  widgetPlaceholder?: React.ReactNode;
84
83
  baseElements?: {
@@ -105,10 +104,10 @@ export declare class Expression extends React.Component<Props> implements Widget
105
104
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
106
105
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
107
106
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
108
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
109
107
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
110
108
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
111
109
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
110
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
112
111
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
113
112
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
114
113
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -155,15 +154,14 @@ declare const _default: {
155
154
  apiOptions: Readonly<Readonly<{
156
155
  isArticle?: boolean;
157
156
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
158
- GroupMetadataEditor?: React.ComponentType<any>;
159
157
  showAlignmentOptions?: boolean;
160
158
  readOnly?: boolean;
159
+ editingDisabled?: boolean;
161
160
  answerableCallback?: (arg1: boolean) => unknown;
162
161
  getAnotherHint?: () => unknown;
163
162
  interactionCallback?: (widgetData: {
164
163
  [widgetId: string]: any;
165
164
  }) => void;
166
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
167
165
  imagePlaceholder?: React.ReactNode;
168
166
  widgetPlaceholder?: React.ReactNode;
169
167
  baseElements?: {
@@ -190,10 +188,10 @@ declare const _default: {
190
188
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
191
189
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
192
190
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
193
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
194
191
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
195
192
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
196
193
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
194
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
197
195
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
198
196
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
199
197
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -227,15 +225,14 @@ declare const _default: {
227
225
  apiOptions?: Readonly<Readonly<{
228
226
  isArticle?: boolean;
229
227
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
230
- GroupMetadataEditor?: React.ComponentType<any>;
231
228
  showAlignmentOptions?: boolean;
232
229
  readOnly?: boolean;
230
+ editingDisabled?: boolean;
233
231
  answerableCallback?: (arg1: boolean) => unknown;
234
232
  getAnotherHint?: () => unknown;
235
233
  interactionCallback?: (widgetData: {
236
234
  [widgetId: string]: any;
237
235
  }) => void;
238
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
239
236
  imagePlaceholder?: React.ReactNode;
240
237
  widgetPlaceholder?: React.ReactNode;
241
238
  baseElements?: {
@@ -262,10 +259,10 @@ declare const _default: {
262
259
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
263
260
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
264
261
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
265
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
266
262
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
267
263
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
268
264
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
265
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
269
266
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
270
267
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
271
268
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -61,15 +61,14 @@ declare class Grapher extends React.Component<Props> implements Widget {
61
61
  apiOptions: Readonly<Readonly<{
62
62
  isArticle?: boolean;
63
63
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
64
- GroupMetadataEditor?: React.ComponentType<any>;
65
64
  showAlignmentOptions?: boolean;
66
65
  readOnly?: boolean;
66
+ editingDisabled?: boolean;
67
67
  answerableCallback?: (arg1: boolean) => unknown;
68
68
  getAnotherHint?: () => unknown;
69
69
  interactionCallback?: (widgetData: {
70
70
  [widgetId: string]: any;
71
71
  }) => void;
72
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
73
72
  imagePlaceholder?: React.ReactNode;
74
73
  widgetPlaceholder?: React.ReactNode;
75
74
  baseElements?: {
@@ -96,10 +95,10 @@ declare class Grapher extends React.Component<Props> implements Widget {
96
95
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
97
96
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
98
97
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
99
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
100
98
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
101
99
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
102
100
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
101
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
103
102
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
104
103
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
105
104
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -162,15 +162,14 @@ declare class InteractiveGraph extends React.Component<Props, State> {
162
162
  apiOptions: Readonly<Readonly<{
163
163
  isArticle?: boolean;
164
164
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
165
- GroupMetadataEditor?: React.ComponentType<any>;
166
165
  showAlignmentOptions?: boolean;
167
166
  readOnly?: boolean;
167
+ editingDisabled?: boolean;
168
168
  answerableCallback?: (arg1: boolean) => unknown;
169
169
  getAnotherHint?: () => unknown;
170
170
  interactionCallback?: (widgetData: {
171
171
  [widgetId: string]: any;
172
172
  }) => void;
173
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
174
173
  imagePlaceholder?: React.ReactNode;
175
174
  widgetPlaceholder?: React.ReactNode;
176
175
  baseElements?: {
@@ -197,10 +196,10 @@ declare class InteractiveGraph extends React.Component<Props, State> {
197
196
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
198
197
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
199
198
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
200
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
201
199
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
202
200
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
203
201
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
202
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
204
203
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
205
204
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
206
205
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -121,15 +121,14 @@ declare const _default: {
121
121
  apiOptions: Readonly<Readonly<{
122
122
  isArticle?: boolean;
123
123
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
124
- GroupMetadataEditor?: React.ComponentType<any>;
125
124
  showAlignmentOptions?: boolean;
126
125
  readOnly?: boolean;
126
+ editingDisabled?: boolean;
127
127
  answerableCallback?: (arg1: boolean) => unknown;
128
128
  getAnotherHint?: () => unknown;
129
129
  interactionCallback?: (widgetData: {
130
130
  [widgetId: string]: any;
131
131
  }) => void;
132
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
133
132
  imagePlaceholder?: React.ReactNode;
134
133
  widgetPlaceholder?: React.ReactNode;
135
134
  baseElements?: {
@@ -156,10 +155,10 @@ declare const _default: {
156
155
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
157
156
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
158
157
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
159
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
160
158
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
161
159
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
162
160
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
161
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
163
162
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
164
163
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
165
164
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -45,15 +45,14 @@ declare class MockWidgetComponent extends React.Component<Props> implements Widg
45
45
  apiOptions: Readonly<Readonly<{
46
46
  isArticle?: boolean;
47
47
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
48
- GroupMetadataEditor?: React.ComponentType<any>;
49
48
  showAlignmentOptions?: boolean;
50
49
  readOnly?: boolean;
50
+ editingDisabled?: boolean;
51
51
  answerableCallback?: (arg1: boolean) => unknown;
52
52
  getAnotherHint?: () => unknown;
53
53
  interactionCallback?: (widgetData: {
54
54
  [widgetId: string]: any;
55
55
  }) => void;
56
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
57
56
  imagePlaceholder?: React.ReactNode;
58
57
  widgetPlaceholder?: React.ReactNode;
59
58
  baseElements?: {
@@ -80,10 +79,10 @@ declare class MockWidgetComponent extends React.Component<Props> implements Widg
80
79
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
81
80
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
82
81
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
83
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
84
82
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
85
83
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
86
84
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
85
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
87
86
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
88
87
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
89
88
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -52,15 +52,14 @@ export declare class NumericInput extends React.Component<NumericInputProps> imp
52
52
  apiOptions: Readonly<Readonly<{
53
53
  isArticle?: boolean;
54
54
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
55
- GroupMetadataEditor?: React.ComponentType<any>;
56
55
  showAlignmentOptions?: boolean;
57
56
  readOnly?: boolean;
57
+ editingDisabled?: boolean;
58
58
  answerableCallback?: (arg1: boolean) => unknown;
59
59
  getAnotherHint?: () => unknown;
60
60
  interactionCallback?: (widgetData: {
61
61
  [widgetId: string]: any;
62
62
  }) => void;
63
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
64
63
  imagePlaceholder?: React.ReactNode;
65
64
  widgetPlaceholder?: React.ReactNode;
66
65
  baseElements?: {
@@ -87,10 +86,10 @@ export declare class NumericInput extends React.Component<NumericInputProps> imp
87
86
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
88
87
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
89
88
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
90
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
91
89
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
92
90
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
93
91
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
92
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
94
93
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
95
94
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
96
95
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -15,15 +15,14 @@ export declare const NumericInputComponent: React.ForwardRefExoticComponent<impo
15
15
  apiOptions: Readonly<Readonly<{
16
16
  isArticle?: boolean;
17
17
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
18
- GroupMetadataEditor?: React.ComponentType<any>;
19
18
  showAlignmentOptions?: boolean;
20
19
  readOnly?: boolean;
20
+ editingDisabled?: boolean;
21
21
  answerableCallback?: (arg1: boolean) => unknown;
22
22
  getAnotherHint?: () => unknown;
23
23
  interactionCallback?: (widgetData: {
24
24
  [widgetId: string]: any;
25
25
  }) => void;
26
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
27
26
  imagePlaceholder?: React.ReactNode;
28
27
  widgetPlaceholder?: React.ReactNode;
29
28
  baseElements?: {
@@ -50,10 +49,10 @@ export declare const NumericInputComponent: React.ForwardRefExoticComponent<impo
50
49
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
51
50
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
52
51
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
53
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
54
52
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
55
53
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
56
54
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
55
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
57
56
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
58
57
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
59
58
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -76,15 +75,14 @@ export declare const NumericInputComponent: React.ForwardRefExoticComponent<impo
76
75
  apiOptions: NonNullable<Readonly<Readonly<{
77
76
  isArticle?: boolean;
78
77
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
79
- GroupMetadataEditor?: React.ComponentType<any>;
80
78
  showAlignmentOptions?: boolean;
81
79
  readOnly?: boolean;
80
+ editingDisabled?: boolean;
82
81
  answerableCallback?: (arg1: boolean) => unknown;
83
82
  getAnotherHint?: () => unknown;
84
83
  interactionCallback?: (widgetData: {
85
84
  [widgetId: string]: any;
86
85
  }) => void;
87
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
88
86
  imagePlaceholder?: React.ReactNode;
89
87
  widgetPlaceholder?: React.ReactNode;
90
88
  baseElements?: {
@@ -111,10 +109,10 @@ export declare const NumericInputComponent: React.ForwardRefExoticComponent<impo
111
109
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
112
110
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
113
111
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
114
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
115
112
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
116
113
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
117
114
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
115
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
118
116
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
119
117
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
120
118
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -99,15 +99,14 @@ declare class Plotter extends React.Component<Props, State> implements Widget {
99
99
  apiOptions: Readonly<Readonly<{
100
100
  isArticle?: boolean;
101
101
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
102
- GroupMetadataEditor?: React.ComponentType<any>;
103
102
  showAlignmentOptions?: boolean;
104
103
  readOnly?: boolean;
104
+ editingDisabled?: boolean;
105
105
  answerableCallback?: (arg1: boolean) => unknown;
106
106
  getAnotherHint?: () => unknown;
107
107
  interactionCallback?: (widgetData: {
108
108
  [widgetId: string]: any;
109
109
  }) => void;
110
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
111
110
  imagePlaceholder?: React.ReactNode;
112
111
  widgetPlaceholder?: React.ReactNode;
113
112
  baseElements?: {
@@ -134,10 +133,10 @@ declare class Plotter extends React.Component<Props, State> implements Widget {
134
133
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
135
134
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
136
135
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
137
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
138
136
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
139
137
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
140
138
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
139
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
141
140
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
142
141
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
143
142
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -48,15 +48,14 @@ declare const Radio: React.ForwardRefExoticComponent<RadioProps & {
48
48
  apiOptions: Readonly<Readonly<{
49
49
  isArticle?: boolean;
50
50
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
51
- GroupMetadataEditor?: React.ComponentType<any>;
52
51
  showAlignmentOptions?: boolean;
53
52
  readOnly?: boolean;
53
+ editingDisabled?: boolean;
54
54
  answerableCallback?: (arg1: boolean) => unknown;
55
55
  getAnotherHint?: () => unknown;
56
56
  interactionCallback?: (widgetData: {
57
57
  [widgetId: string]: any;
58
58
  }) => void;
59
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
60
59
  imagePlaceholder?: React.ReactNode;
61
60
  widgetPlaceholder?: React.ReactNode;
62
61
  baseElements?: {
@@ -83,10 +82,10 @@ declare const Radio: React.ForwardRefExoticComponent<RadioProps & {
83
82
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
84
83
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
85
84
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
86
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
87
85
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
88
86
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
89
87
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
88
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
90
89
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
91
90
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
92
91
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -47,15 +47,14 @@ declare class Radio extends RadioOld {
47
47
  apiOptions: Readonly<Readonly<{
48
48
  isArticle?: boolean;
49
49
  onFocusChange?: (newFocusPath: import("../..").FocusPath, oldFocusPath: import("../..").FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
50
- GroupMetadataEditor?: React.ComponentType<any>;
51
50
  showAlignmentOptions?: boolean;
52
51
  readOnly?: boolean;
52
+ editingDisabled?: boolean;
53
53
  answerableCallback?: (arg1: boolean) => unknown;
54
54
  getAnotherHint?: () => unknown;
55
55
  interactionCallback?: (widgetData: {
56
56
  [widgetId: string]: any;
57
57
  }) => void;
58
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
59
58
  imagePlaceholder?: React.ReactNode;
60
59
  widgetPlaceholder?: React.ReactNode;
61
60
  baseElements?: {
@@ -82,10 +81,10 @@ declare class Radio extends RadioOld {
82
81
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
83
82
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
84
83
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
85
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
86
84
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
87
85
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
88
86
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
87
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
89
88
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
90
89
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
91
90
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
@@ -53,15 +53,14 @@ declare class Table extends React.Component<Props> implements Widget {
53
53
  apiOptions: Readonly<Readonly<{
54
54
  isArticle?: boolean;
55
55
  onFocusChange?: (newFocusPath: FocusPath, oldFocusPath: FocusPath, keypadHeight?: number, focusedElement?: HTMLElement) => unknown;
56
- GroupMetadataEditor?: React.ComponentType<any>;
57
56
  showAlignmentOptions?: boolean;
58
57
  readOnly?: boolean;
58
+ editingDisabled?: boolean;
59
59
  answerableCallback?: (arg1: boolean) => unknown;
60
60
  getAnotherHint?: () => unknown;
61
61
  interactionCallback?: (widgetData: {
62
62
  [widgetId: string]: any;
63
63
  }) => void;
64
- groupAnnotator?: (groupNumber: number, widgetId: string) => React.ReactNode;
65
64
  imagePlaceholder?: React.ReactNode;
66
65
  widgetPlaceholder?: React.ReactNode;
67
66
  baseElements?: {
@@ -88,10 +87,10 @@ declare class Table extends React.Component<Props> implements Widget {
88
87
  baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
89
88
  canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
90
89
  editorChangeDelay: NonNullable<import("../..").APIOptions["editorChangeDelay"]>;
91
- groupAnnotator: NonNullable<import("../..").APIOptions["groupAnnotator"]>;
92
90
  isArticle: NonNullable<import("../..").APIOptions["isArticle"]>;
93
91
  isMobile: NonNullable<import("../..").APIOptions["isMobile"]>;
94
92
  isMobileApp: NonNullable<import("../..").APIOptions["isMobileApp"]>;
93
+ editingDisabled: NonNullable<import("../..").APIOptions["editingDisabled"]>;
95
94
  onFocusChange: NonNullable<import("../..").APIOptions["onFocusChange"]>;
96
95
  readOnly: NonNullable<import("../..").APIOptions["readOnly"]>;
97
96
  setDrawingAreaAvailable: NonNullable<import("../..").APIOptions["setDrawingAreaAvailable"]>;
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Core Perseus API (includes renderers and widgets)",
4
4
  "author": "Khan Academy",
5
5
  "license": "MIT",
6
- "version": "71.5.0",
6
+ "version": "72.0.0",
7
7
  "publishConfig": {
8
8
  "access": "public"
9
9
  },
@@ -44,13 +44,13 @@
44
44
  "@khanacademy/kas": "2.1.3",
45
45
  "@khanacademy/keypad-context": "3.2.15",
46
46
  "@khanacademy/kmath": "2.2.15",
47
+ "@khanacademy/perseus-core": "20.1.3",
47
48
  "@khanacademy/math-input": "26.2.17",
48
49
  "@khanacademy/perseus-linter": "4.4.5",
49
50
  "@khanacademy/perseus-score": "8.0.4",
50
51
  "@khanacademy/perseus-utils": "2.1.1",
51
52
  "@khanacademy/pure-markdown": "2.2.1",
52
- "@khanacademy/simple-markdown": "2.1.1",
53
- "@khanacademy/perseus-core": "20.1.3"
53
+ "@khanacademy/simple-markdown": "2.1.1"
54
54
  },
55
55
  "devDependencies": {
56
56
  "@khanacademy/wonder-blocks-announcer": "1.0.4",
@@ -88,8 +88,8 @@
88
88
  "react-dom": "18.2.0",
89
89
  "react-popper": "^2.2.5",
90
90
  "underscore": "1.4.4",
91
- "raphael": "1.5.4",
92
- "perseus-build-settings": "0.9.0"
91
+ "perseus-build-settings": "0.9.0",
92
+ "raphael": "1.5.4"
93
93
  },
94
94
  "peerDependencies": {
95
95
  "@khanacademy/wonder-blocks-announcer": "^1.0.4",
@@ -1,24 +0,0 @@
1
- import * as React from "react";
2
- /**
3
- * Stub Tag Editor.
4
- *
5
- * This is stupidly used by Perseus Zero because I didn't implement
6
- * the <TagEditor> for Perseus Zero (since everyone wants me to
7
- * delete it anyways).
8
- *
9
- * This is a small wrapper for a TextListEditor that allows us to
10
- * edit raw Tag ID strings in perseus zero (please don't use this).
11
- *
12
- * It also gives a nicer interface for the group metadata editor
13
- * in local demo mode.
14
- */
15
- declare class StubTagEditor extends React.Component<any> {
16
- static propTypes: {
17
- value: any;
18
- onChange: any;
19
- showTitle: any;
20
- };
21
- static defaultProps: any;
22
- render(): React.ReactNode;
23
- }
24
- export default StubTagEditor;