@khanacademy/perseus-editor 13.0.1 → 13.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.
- package/dist/content-preview.d.ts +22 -0
- package/dist/es/index.js +15 -23
- package/dist/es/index.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/widgets/interactive-graph-editor.d.ts +2 -92
- package/package.json +36 -35
|
@@ -3,97 +3,7 @@ import * as React from "react";
|
|
|
3
3
|
import type { PerseusImageBackground, PerseusInteractiveGraphWidgetOptions, APIOptionsWithDefaults, LockedFigure } from "@khanacademy/perseus";
|
|
4
4
|
import type { PropsFor } from "@khanacademy/wonder-blocks-core";
|
|
5
5
|
declare const InteractiveGraph: {
|
|
6
|
-
new (props:
|
|
7
|
-
widgetId: string;
|
|
8
|
-
alignment: string | null | undefined;
|
|
9
|
-
static: boolean | null | undefined;
|
|
10
|
-
problemNum: number | null | undefined;
|
|
11
|
-
apiOptions: Readonly<Readonly<{
|
|
12
|
-
isArticle?: boolean | undefined;
|
|
13
|
-
onInputError?: ((widgetId: any, value: string, message?: string | null | undefined) => unknown) | undefined;
|
|
14
|
-
onFocusChange?: ((newFocusPath: import("@khanacademy/perseus").FocusPath, oldFocusPath: import("@khanacademy/perseus").FocusPath, keypadHeight?: number | undefined, focusedElement?: HTMLElement | undefined) => unknown) | undefined;
|
|
15
|
-
GroupMetadataEditor?: React.ComponentType<any> | undefined;
|
|
16
|
-
showAlignmentOptions?: boolean | undefined;
|
|
17
|
-
readOnly?: boolean | undefined;
|
|
18
|
-
answerableCallback?: ((arg1: boolean) => unknown) | undefined;
|
|
19
|
-
getAnotherHint?: (() => unknown) | undefined;
|
|
20
|
-
interactionCallback?: ((widgetData: {
|
|
21
|
-
[widgetId: string]: any;
|
|
22
|
-
}) => void) | undefined;
|
|
23
|
-
groupAnnotator?: ((groupNumber: number, widgetId: string) => React.ReactNode) | undefined;
|
|
24
|
-
imagePlaceholder?: React.ReactNode;
|
|
25
|
-
widgetPlaceholder?: React.ReactNode;
|
|
26
|
-
baseElements?: {
|
|
27
|
-
Link: React.ComponentType<any>;
|
|
28
|
-
} | undefined;
|
|
29
|
-
imagePreloader?: ((dimensions: import("../../../perseus/src/types").Dimensions) => React.ReactNode) | undefined;
|
|
30
|
-
trackInteraction?: ((args: {
|
|
31
|
-
type: string;
|
|
32
|
-
id: string;
|
|
33
|
-
correct?: boolean | undefined;
|
|
34
|
-
} & Partial<import("../../../perseus/src/types").TrackingGradedGroupExtraArguments> & Partial<import("../../../perseus/src/types").TrackingSequenceExtraArguments>) => void) | undefined;
|
|
35
|
-
customKeypad?: boolean | undefined;
|
|
36
|
-
nativeKeypadProxy?: ((blur: () => void) => import("@khanacademy/math-input").KeypadAPI) | undefined;
|
|
37
|
-
isMobile?: boolean | undefined;
|
|
38
|
-
setDrawingAreaAvailable?: ((arg1: boolean) => unknown) | undefined;
|
|
39
|
-
hintProgressColor?: string | undefined;
|
|
40
|
-
canScrollPage?: boolean | undefined;
|
|
41
|
-
crossOutEnabled?: boolean | undefined;
|
|
42
|
-
editorChangeDelay?: number | undefined;
|
|
43
|
-
flags?: {
|
|
44
|
-
mafs?: false | ({
|
|
45
|
-
circle?: boolean | undefined;
|
|
46
|
-
polygon?: boolean | undefined;
|
|
47
|
-
linear?: boolean | undefined;
|
|
48
|
-
quadratic?: boolean | undefined;
|
|
49
|
-
sinusoid?: boolean | undefined;
|
|
50
|
-
point?: boolean | undefined;
|
|
51
|
-
ray?: boolean | undefined;
|
|
52
|
-
segment?: boolean | undefined;
|
|
53
|
-
angle?: boolean | undefined;
|
|
54
|
-
"linear-system"?: boolean | undefined;
|
|
55
|
-
"unlimited-point"?: boolean | undefined;
|
|
56
|
-
} & {
|
|
57
|
-
"interactive-graph-locked-features-m2b"?: boolean | undefined;
|
|
58
|
-
"interactive-graph-locked-features-labels"?: boolean | undefined;
|
|
59
|
-
} & {
|
|
60
|
-
"start-coords-ui-phase-1"?: boolean | undefined;
|
|
61
|
-
"start-coords-ui-phase-2"?: boolean | undefined;
|
|
62
|
-
"start-coords-ui-point"?: boolean | undefined;
|
|
63
|
-
"start-coords-ui-polygon"?: boolean | undefined;
|
|
64
|
-
"start-coords-ui-angle"?: boolean | undefined;
|
|
65
|
-
}) | undefined;
|
|
66
|
-
} | undefined;
|
|
67
|
-
onWidgetStartProps?: ((widgets: import("@khanacademy/perseus").PerseusWidgetsMap) => void) | undefined;
|
|
68
|
-
}> & {
|
|
69
|
-
GroupMetadataEditor: NonNullable<React.ComponentType<any> | undefined>;
|
|
70
|
-
baseElements: {
|
|
71
|
-
Link: React.ComponentType<any>;
|
|
72
|
-
};
|
|
73
|
-
canScrollPage: NonNullable<boolean | undefined>;
|
|
74
|
-
crossOutEnabled: NonNullable<boolean | undefined>;
|
|
75
|
-
editorChangeDelay: number;
|
|
76
|
-
groupAnnotator: (groupNumber: number, widgetId: string) => React.ReactNode;
|
|
77
|
-
isArticle: NonNullable<boolean | undefined>;
|
|
78
|
-
isMobile: NonNullable<boolean | undefined>;
|
|
79
|
-
onFocusChange: (newFocusPath: import("@khanacademy/perseus").FocusPath, oldFocusPath: import("@khanacademy/perseus").FocusPath, keypadHeight?: number | undefined, focusedElement?: HTMLElement | undefined) => unknown;
|
|
80
|
-
onInputError: (widgetId: any, value: string, message?: string | null | undefined) => unknown;
|
|
81
|
-
readOnly: NonNullable<boolean | undefined>;
|
|
82
|
-
setDrawingAreaAvailable: (arg1: boolean) => unknown;
|
|
83
|
-
showAlignmentOptions: NonNullable<boolean | undefined>;
|
|
84
|
-
}>;
|
|
85
|
-
keypadElement?: any;
|
|
86
|
-
questionCompleted?: boolean | undefined;
|
|
87
|
-
onFocus: (blurPath: import("@khanacademy/perseus").FocusPath) => void;
|
|
88
|
-
onBlur: (blurPath: import("@khanacademy/perseus").FocusPath) => void;
|
|
89
|
-
findWidgets: (arg1: import("../../../perseus/src/types").FilterCriterion) => readonly any[];
|
|
90
|
-
reviewModeRubric: import("../../../perseus/src/widgets/interactive-graph").Rubric;
|
|
91
|
-
onChange: import("@khanacademy/perseus").ChangeHandler;
|
|
92
|
-
trackInteraction: (extraData?: Empty | undefined) => void;
|
|
93
|
-
isLastUsedWidget: boolean;
|
|
94
|
-
linterContext: import("@khanacademy/perseus-linter").LinterContextProps;
|
|
95
|
-
containerSizeClass: SizingUtils.SizeClass;
|
|
96
|
-
}) | Readonly<PerseusInteractiveGraphWidgetOptions & {
|
|
6
|
+
new (props: PerseusInteractiveGraphWidgetOptions & {
|
|
97
7
|
widgetId: string;
|
|
98
8
|
alignment: string | null | undefined;
|
|
99
9
|
static: boolean | null | undefined;
|
|
@@ -183,7 +93,7 @@ declare const InteractiveGraph: {
|
|
|
183
93
|
isLastUsedWidget: boolean;
|
|
184
94
|
linterContext: import("@khanacademy/perseus-linter").LinterContextProps;
|
|
185
95
|
containerSizeClass: SizingUtils.SizeClass;
|
|
186
|
-
}
|
|
96
|
+
}): {
|
|
187
97
|
legacyGraphRef: React.RefObject<{
|
|
188
98
|
context: {
|
|
189
99
|
strings: import("../../../perseus/src/strings").PerseusStrings;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Perseus editors",
|
|
4
4
|
"author": "Khan Academy",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "13.0
|
|
6
|
+
"version": "13.1.0",
|
|
7
7
|
"publishConfig": {
|
|
8
8
|
"access": "public"
|
|
9
9
|
},
|
|
@@ -35,26 +35,27 @@
|
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@khanacademy/kas": "^0.3.12",
|
|
38
|
+
"@khanacademy/keypad-context": "^1.0.1",
|
|
38
39
|
"@khanacademy/kmath": "^0.1.13",
|
|
39
|
-
"@khanacademy/math-input": "^21.0.
|
|
40
|
-
"@khanacademy/perseus": "^31.0
|
|
40
|
+
"@khanacademy/math-input": "^21.0.2",
|
|
41
|
+
"@khanacademy/perseus": "^31.1.0",
|
|
41
42
|
"@khanacademy/perseus-core": "1.5.0"
|
|
42
43
|
},
|
|
43
44
|
"devDependencies": {
|
|
44
|
-
"@khanacademy/wonder-blocks-accordion": "1.3.
|
|
45
|
-
"@khanacademy/wonder-blocks-banner": "3.
|
|
46
|
-
"@khanacademy/wonder-blocks-button": "6.3.
|
|
47
|
-
"@khanacademy/wonder-blocks-clickable": "4.2.
|
|
48
|
-
"@khanacademy/wonder-blocks-core": "6.4.
|
|
49
|
-
"@khanacademy/wonder-blocks-dropdown": "5.
|
|
50
|
-
"@khanacademy/wonder-blocks-form": "
|
|
51
|
-
"@khanacademy/wonder-blocks-icon": "4.1.
|
|
52
|
-
"@khanacademy/wonder-blocks-icon-button": "5.
|
|
53
|
-
"@khanacademy/wonder-blocks-switch": "1.1.
|
|
54
|
-
"@khanacademy/wonder-blocks-timing": "5.0.
|
|
55
|
-
"@khanacademy/wonder-blocks-tokens": "
|
|
56
|
-
"@khanacademy/wonder-blocks-tooltip": "2.
|
|
57
|
-
"@khanacademy/wonder-blocks-typography": "2.1.
|
|
45
|
+
"@khanacademy/wonder-blocks-accordion": "1.3.6",
|
|
46
|
+
"@khanacademy/wonder-blocks-banner": "3.1.7",
|
|
47
|
+
"@khanacademy/wonder-blocks-button": "6.3.8",
|
|
48
|
+
"@khanacademy/wonder-blocks-clickable": "4.2.6",
|
|
49
|
+
"@khanacademy/wonder-blocks-core": "6.4.3",
|
|
50
|
+
"@khanacademy/wonder-blocks-dropdown": "5.4.5",
|
|
51
|
+
"@khanacademy/wonder-blocks-form": "4.9.0",
|
|
52
|
+
"@khanacademy/wonder-blocks-icon": "4.1.3",
|
|
53
|
+
"@khanacademy/wonder-blocks-icon-button": "5.3.4",
|
|
54
|
+
"@khanacademy/wonder-blocks-switch": "1.1.20",
|
|
55
|
+
"@khanacademy/wonder-blocks-timing": "5.0.1",
|
|
56
|
+
"@khanacademy/wonder-blocks-tokens": "2.0.0",
|
|
57
|
+
"@khanacademy/wonder-blocks-tooltip": "2.4.0",
|
|
58
|
+
"@khanacademy/wonder-blocks-typography": "2.1.14",
|
|
58
59
|
"@khanacademy/wonder-stuff-core": "1.5.2",
|
|
59
60
|
"@phosphor-icons/core": "^2.0.2",
|
|
60
61
|
"aphrodite": "^1.2.5",
|
|
@@ -64,25 +65,25 @@
|
|
|
64
65
|
"katex": "0.11.1",
|
|
65
66
|
"perseus-build-settings": "^0.4.1",
|
|
66
67
|
"prop-types": "15.6.1",
|
|
67
|
-
"react": "
|
|
68
|
-
"react-dom": "
|
|
68
|
+
"react": "^18.2.0",
|
|
69
|
+
"react-dom": "^18.2.0",
|
|
69
70
|
"underscore": "^1.4.4"
|
|
70
71
|
},
|
|
71
72
|
"peerDependencies": {
|
|
72
|
-
"@khanacademy/wonder-blocks-accordion": "1.3.
|
|
73
|
-
"@khanacademy/wonder-blocks-banner": "3.
|
|
74
|
-
"@khanacademy/wonder-blocks-button": "6.3.
|
|
75
|
-
"@khanacademy/wonder-blocks-clickable": "4.2.
|
|
76
|
-
"@khanacademy/wonder-blocks-core": "6.4.
|
|
77
|
-
"@khanacademy/wonder-blocks-dropdown": "5.
|
|
78
|
-
"@khanacademy/wonder-blocks-form": "
|
|
79
|
-
"@khanacademy/wonder-blocks-icon": "4.1.
|
|
80
|
-
"@khanacademy/wonder-blocks-icon-button": "5.
|
|
81
|
-
"@khanacademy/wonder-blocks-switch": "1.1.
|
|
82
|
-
"@khanacademy/wonder-blocks-timing": "5.0.
|
|
83
|
-
"@khanacademy/wonder-blocks-tokens": "
|
|
84
|
-
"@khanacademy/wonder-blocks-tooltip": "2.
|
|
85
|
-
"@khanacademy/wonder-blocks-typography": "2.1.
|
|
73
|
+
"@khanacademy/wonder-blocks-accordion": "1.3.6",
|
|
74
|
+
"@khanacademy/wonder-blocks-banner": "3.1.7",
|
|
75
|
+
"@khanacademy/wonder-blocks-button": "6.3.8",
|
|
76
|
+
"@khanacademy/wonder-blocks-clickable": "4.2.6",
|
|
77
|
+
"@khanacademy/wonder-blocks-core": "6.4.3",
|
|
78
|
+
"@khanacademy/wonder-blocks-dropdown": "5.4.5",
|
|
79
|
+
"@khanacademy/wonder-blocks-form": "4.9.0",
|
|
80
|
+
"@khanacademy/wonder-blocks-icon": "4.1.3",
|
|
81
|
+
"@khanacademy/wonder-blocks-icon-button": "5.3.4",
|
|
82
|
+
"@khanacademy/wonder-blocks-switch": "1.1.20",
|
|
83
|
+
"@khanacademy/wonder-blocks-timing": "5.0.1",
|
|
84
|
+
"@khanacademy/wonder-blocks-tokens": "2.0.0",
|
|
85
|
+
"@khanacademy/wonder-blocks-tooltip": "2.4.0",
|
|
86
|
+
"@khanacademy/wonder-blocks-typography": "2.1.14",
|
|
86
87
|
"@khanacademy/wonder-stuff-core": "1.5.2",
|
|
87
88
|
"@phosphor-icons/core": "^2.0.2",
|
|
88
89
|
"aphrodite": "^1.2.5",
|
|
@@ -90,8 +91,8 @@
|
|
|
90
91
|
"create-react-class": "15.6.3",
|
|
91
92
|
"jquery": "^2.1.1",
|
|
92
93
|
"prop-types": "15.6.1",
|
|
93
|
-
"react": "
|
|
94
|
-
"react-dom": "
|
|
94
|
+
"react": "^18.2.0",
|
|
95
|
+
"react-dom": "^18.2.0",
|
|
95
96
|
"underscore": "^1.4.4"
|
|
96
97
|
},
|
|
97
98
|
"keywords": []
|