@khanacademy/perseus 69.0.0 → 69.0.1
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/es/index.css +4 -6
- package/dist/es/index.css.map +1 -1
- package/dist/es/index.js +5 -5
- package/dist/es/index.js.map +1 -1
- package/dist/index.css +4 -6
- package/dist/index.css.map +1 -1
- package/dist/index.js +5 -5
- package/dist/index.js.map +1 -1
- package/dist/server-item-renderer.d.ts +1 -1
- package/dist/widgets/expression/expression.d.ts +2 -2
- package/dist/widgets/grapher/grapher.d.ts +1 -1
- package/dist/widgets/interactive-graphs/graphs/components/angle-indicators.d.ts +1 -1
- package/dist/widgets/interactive-graphs/graphs/utils.d.ts +5 -0
- package/dist/widgets/interactive-graphs/interactive-graph.d.ts +1 -1
- package/dist/widgets/mock-widgets/mock-widget.d.ts +1 -1
- package/dist/widgets/number-line/number-line.d.ts +2 -12
- package/dist/widgets/numeric-input/numeric-input.class.d.ts +1 -1
- package/dist/widgets/numeric-input/numeric-input.d.ts +1 -1
- package/dist/widgets/plotter/plotter.d.ts +1 -1
- package/dist/widgets/radio/radio.ff.d.ts +1 -1
- package/dist/widgets/table/table.d.ts +1 -1
- package/package.json +11 -9
|
@@ -148,7 +148,7 @@ declare const _default: React.ForwardRefExoticComponent<Omit<Pick<SharedRenderer
|
|
|
148
148
|
hintProgressColor?: string;
|
|
149
149
|
canScrollPage?: boolean;
|
|
150
150
|
editorChangeDelay?: number;
|
|
151
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
151
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
152
152
|
}> | undefined;
|
|
153
153
|
linterContext?: PerseusLinter.LinterContextProps | undefined;
|
|
154
154
|
onRendered?: ((isRendered: boolean) => void) | undefined;
|
|
@@ -101,7 +101,7 @@ export declare class Expression extends React.Component<Props> implements Widget
|
|
|
101
101
|
hintProgressColor?: string;
|
|
102
102
|
canScrollPage?: boolean;
|
|
103
103
|
editorChangeDelay?: number;
|
|
104
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
104
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
105
105
|
}> & {
|
|
106
106
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
107
107
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -193,7 +193,7 @@ declare const _default: {
|
|
|
193
193
|
hintProgressColor?: string;
|
|
194
194
|
canScrollPage?: boolean;
|
|
195
195
|
editorChangeDelay?: number;
|
|
196
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
196
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
197
197
|
}> & {
|
|
198
198
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
199
199
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -92,7 +92,7 @@ declare class Grapher extends React.Component<Props> implements Widget {
|
|
|
92
92
|
hintProgressColor?: string;
|
|
93
93
|
canScrollPage?: boolean;
|
|
94
94
|
editorChangeDelay?: number;
|
|
95
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
95
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
96
96
|
}> & {
|
|
97
97
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
98
98
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -37,5 +37,5 @@ export declare const shouldDrawArcOutside: (midpoint: vec.Vector2, vertex: vec.V
|
|
|
37
37
|
* if the endpoints are clockwise itself - this has to be checked by the
|
|
38
38
|
* caller. This is because of edge cases involving concave polygons.
|
|
39
39
|
*/
|
|
40
|
-
export declare function
|
|
40
|
+
export declare function isConcavePolygonVertex(centerPoint: vec.Vector2, clockwiseEndpoints: [vec.Vector2, vec.Vector2]): boolean;
|
|
41
41
|
export {};
|
|
@@ -31,3 +31,8 @@ export declare function getSideLengthsFromPoints(points: Coord[], i: number, isP
|
|
|
31
31
|
* exact side length or the approximate side length.
|
|
32
32
|
*/
|
|
33
33
|
export declare function getPolygonSideString(sideLength: number, pointIndex: number, strings: PerseusStrings, locale: string): string;
|
|
34
|
+
/**
|
|
35
|
+
* Calculate an appropriate radius for angle arcs based on the graph range.
|
|
36
|
+
* The radius scales with the range so it's visible at all graph sizes.
|
|
37
|
+
*/
|
|
38
|
+
export declare function calculateScaledRadius(range: [Interval, Interval]): number;
|
|
@@ -193,7 +193,7 @@ declare class InteractiveGraph extends React.Component<Props, State> {
|
|
|
193
193
|
hintProgressColor?: string;
|
|
194
194
|
canScrollPage?: boolean;
|
|
195
195
|
editorChangeDelay?: number;
|
|
196
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
196
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
197
197
|
}> & {
|
|
198
198
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
199
199
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -76,7 +76,7 @@ declare class MockWidgetComponent extends React.Component<Props> implements Widg
|
|
|
76
76
|
hintProgressColor?: string;
|
|
77
77
|
canScrollPage?: boolean;
|
|
78
78
|
editorChangeDelay?: number;
|
|
79
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
79
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
80
80
|
}> & {
|
|
81
81
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
82
82
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -6,17 +6,7 @@ import type { PerseusNumberLineUserInput, PerseusNumberLineWidgetOptions, Number
|
|
|
6
6
|
/**
|
|
7
7
|
* The type of `this.props` inside the NumberLine widget.
|
|
8
8
|
*/
|
|
9
|
-
type Props = WidgetProps<
|
|
10
|
-
range: number[];
|
|
11
|
-
labelRange: Array<number | null>;
|
|
12
|
-
labelStyle: string;
|
|
13
|
-
labelTicks: boolean;
|
|
14
|
-
divisionRange: number[];
|
|
15
|
-
snapDivisions: number;
|
|
16
|
-
isTickCtrl: boolean;
|
|
17
|
-
isInequality: boolean;
|
|
18
|
-
showTooltips?: boolean;
|
|
19
|
-
}, PerseusNumberLineUserInput>;
|
|
9
|
+
type Props = WidgetProps<PerseusNumberLineWidgetOptions, PerseusNumberLineUserInput>;
|
|
20
10
|
type CalculatedProps = Props & {
|
|
21
11
|
tickStep: number;
|
|
22
12
|
};
|
|
@@ -77,7 +67,7 @@ declare class NumberLine extends React.Component<Props, State> implements Widget
|
|
|
77
67
|
*/
|
|
78
68
|
getSerializedState(): {
|
|
79
69
|
alignment: string | null | undefined;
|
|
80
|
-
static: boolean
|
|
70
|
+
static: boolean;
|
|
81
71
|
range: number[];
|
|
82
72
|
labelRange: (number | null)[];
|
|
83
73
|
labelStyle: string;
|
|
@@ -83,7 +83,7 @@ export declare class NumericInput extends React.Component<NumericInputProps> imp
|
|
|
83
83
|
hintProgressColor?: string;
|
|
84
84
|
canScrollPage?: boolean;
|
|
85
85
|
editorChangeDelay?: number;
|
|
86
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
86
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
87
87
|
}> & {
|
|
88
88
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
89
89
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -41,7 +41,7 @@ export declare const NumericInputComponent: React.ForwardRefExoticComponent<impo
|
|
|
41
41
|
hintProgressColor?: string;
|
|
42
42
|
canScrollPage?: boolean;
|
|
43
43
|
editorChangeDelay?: number;
|
|
44
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
44
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
45
45
|
}> & {
|
|
46
46
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
47
47
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -130,7 +130,7 @@ export declare class Plotter extends React.Component<Props, State> implements Wi
|
|
|
130
130
|
hintProgressColor?: string;
|
|
131
131
|
canScrollPage?: boolean;
|
|
132
132
|
editorChangeDelay?: number;
|
|
133
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
133
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
134
134
|
}> & {
|
|
135
135
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
136
136
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -77,7 +77,7 @@ declare class Radio extends RadioOld {
|
|
|
77
77
|
hintProgressColor?: string;
|
|
78
78
|
canScrollPage?: boolean;
|
|
79
79
|
editorChangeDelay?: number;
|
|
80
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
80
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
81
81
|
}> & {
|
|
82
82
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
83
83
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
|
@@ -86,7 +86,7 @@ declare class Table extends React.Component<Props> implements Widget {
|
|
|
86
86
|
hintProgressColor?: string;
|
|
87
87
|
canScrollPage?: boolean;
|
|
88
88
|
editorChangeDelay?: number;
|
|
89
|
-
flags?: Record<"new-radio-widget", boolean>;
|
|
89
|
+
flags?: Record<"new-radio-widget" | "image-widget-upgrade", boolean>;
|
|
90
90
|
}> & {
|
|
91
91
|
baseElements: NonNullable<import("../..").APIOptions["baseElements"]>;
|
|
92
92
|
canScrollPage: NonNullable<import("../..").APIOptions["canScrollPage"]>;
|
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": "69.0.
|
|
6
|
+
"version": "69.0.1",
|
|
7
7
|
"publishConfig": {
|
|
8
8
|
"access": "public"
|
|
9
9
|
},
|
|
@@ -42,13 +42,13 @@
|
|
|
42
42
|
"tiny-invariant": "1.3.1",
|
|
43
43
|
"uuid": "^10.0.0",
|
|
44
44
|
"@khanacademy/kas": "2.1.0",
|
|
45
|
-
"@khanacademy/keypad-context": "3.2.
|
|
46
|
-
"@khanacademy/
|
|
47
|
-
"@khanacademy/
|
|
48
|
-
"@khanacademy/perseus-
|
|
49
|
-
"@khanacademy/perseus-score": "7.7.
|
|
45
|
+
"@khanacademy/keypad-context": "3.2.5",
|
|
46
|
+
"@khanacademy/kmath": "2.2.5",
|
|
47
|
+
"@khanacademy/math-input": "26.2.5",
|
|
48
|
+
"@khanacademy/perseus-core": "19.0.3",
|
|
49
|
+
"@khanacademy/perseus-score": "7.7.5",
|
|
50
|
+
"@khanacademy/perseus-linter": "4.3.5",
|
|
50
51
|
"@khanacademy/perseus-utils": "2.1.0",
|
|
51
|
-
"@khanacademy/kmath": "2.2.4",
|
|
52
52
|
"@khanacademy/pure-markdown": "2.2.0",
|
|
53
53
|
"@khanacademy/simple-markdown": "2.1.0"
|
|
54
54
|
},
|
|
@@ -65,6 +65,7 @@
|
|
|
65
65
|
"@khanacademy/wonder-blocks-labeled-field": "4.0.5",
|
|
66
66
|
"@khanacademy/wonder-blocks-layout": "3.1.36",
|
|
67
67
|
"@khanacademy/wonder-blocks-link": "9.2.3",
|
|
68
|
+
"@khanacademy/wonder-blocks-modal": "8.3.1",
|
|
68
69
|
"@khanacademy/wonder-blocks-pill": "3.1.40",
|
|
69
70
|
"@khanacademy/wonder-blocks-popover": "6.1.32",
|
|
70
71
|
"@khanacademy/wonder-blocks-progress-spinner": "3.1.36",
|
|
@@ -86,8 +87,8 @@
|
|
|
86
87
|
"react-dom": "18.2.0",
|
|
87
88
|
"react-popper": "^2.2.5",
|
|
88
89
|
"underscore": "1.4.4",
|
|
89
|
-
"
|
|
90
|
-
"
|
|
90
|
+
"perseus-build-settings": "0.9.0",
|
|
91
|
+
"raphael": "1.5.4"
|
|
91
92
|
},
|
|
92
93
|
"peerDependencies": {
|
|
93
94
|
"@khanacademy/wonder-blocks-banner": "^4.4.0",
|
|
@@ -102,6 +103,7 @@
|
|
|
102
103
|
"@khanacademy/wonder-blocks-labeled-field": "^4.0.5",
|
|
103
104
|
"@khanacademy/wonder-blocks-layout": "^3.1.36",
|
|
104
105
|
"@khanacademy/wonder-blocks-link": "^9.2.3",
|
|
106
|
+
"@khanacademy/wonder-blocks-modal": "^8.3.1",
|
|
105
107
|
"@khanacademy/wonder-blocks-pill": "^3.1.40",
|
|
106
108
|
"@khanacademy/wonder-blocks-popover": "^6.1.32",
|
|
107
109
|
"@khanacademy/wonder-blocks-progress-spinner": "^3.1.36",
|