@khanacademy/perseus-editor 35.2.0 → 35.2.2

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.
@@ -0,0 +1,19 @@
1
+ /**
2
+ * A wrapper around info-tip/info-tip.jsx that can be rendered on the
3
+ * server without causing a checksum mismatch on the client.
4
+ * (RCSS generates classnames with a randomSuffix, which ensures that any
5
+ * two sets of generated classnames will not match.)
6
+ */
7
+ import * as React from "react";
8
+ import InfoTipBase from "./info-tip-base";
9
+ import type { PropsFor } from "@khanacademy/wonder-blocks-core";
10
+ type Props = PropsFor<typeof InfoTipBase>;
11
+ type State = {
12
+ didMount: boolean;
13
+ };
14
+ declare class InfoTip extends React.Component<Props, State> {
15
+ state: State;
16
+ componentDidMount(): void;
17
+ render(): React.ReactNode;
18
+ }
19
+ export default InfoTip;
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ type Props = {
3
+ children: React.ReactNode;
4
+ };
5
+ declare const InfoTipBase: (props: Props) => React.JSX.Element;
6
+ export default InfoTipBase;
@@ -0,0 +1,15 @@
1
+ import * as React from "react";
2
+ declare class TextListEditor extends React.Component<any, any> {
3
+ static propTypes: {
4
+ options: any;
5
+ layout: any;
6
+ onChange: any;
7
+ };
8
+ static defaultProps: any;
9
+ state: any;
10
+ UNSAFE_componentWillReceiveProps(nextProps: any): void;
11
+ onChange: (arg1: number, arg2: React.ChangeEvent<HTMLInputElement>) => void;
12
+ onKeyDown: (arg1: number, arg2: React.KeyboardEvent) => void;
13
+ render(): React.ReactNode;
14
+ }
15
+ export default TextListEditor;
@@ -25,7 +25,7 @@ declare class WidgetEditor extends React.Component<WidgetEditorProps, WidgetEdit
25
25
  _handleAlignmentChange: (newAlignment: Alignment) => void;
26
26
  getSaveWarnings: () => any;
27
27
  serialize: () => {
28
- type: "categorizer" | "iframe" | "table" | "video" | "image" | "radio" | "cs-program" | "definition" | "group" | "dropdown" | "explanation" | "expression" | "free-response" | "grapher" | "graded-group-set" | "graded-group" | "input-number" | "interaction" | "interactive-graph" | "label-image" | "matcher" | "matrix" | "measurer" | "number-line" | "numeric-input" | "orderer" | "phet-simulation" | "python-program" | "plotter" | "sorter" | "mock-widget" | "deprecated-standin";
28
+ type: "image" | "radio" | "categorizer" | "iframe" | "table" | "video" | "definition" | "group" | "cs-program" | "dropdown" | "explanation" | "expression" | "free-response" | "grapher" | "graded-group-set" | "graded-group" | "input-number" | "interaction" | "interactive-graph" | "label-image" | "matcher" | "matrix" | "measurer" | "number-line" | "numeric-input" | "orderer" | "phet-simulation" | "python-program" | "plotter" | "sorter" | "mock-widget" | "deprecated-standin";
29
29
  alignment: string | undefined;
30
30
  static: boolean | undefined;
31
31
  graded: boolean | undefined;
@@ -101,6 +101,7 @@ declare class EditorPage extends React.Component<Props, State> {
101
101
  */
102
102
  serialize(): PerseusItem;
103
103
  handleChange: (toChange: OnChangeParams) => void;
104
+ handleEditorChange: (newProps: Partial<PerseusRenderer>) => void;
104
105
  changeJSON: (newJson: PerseusItem) => void;
105
106
  render(): React.ReactNode;
106
107
  }