@khanacademy/math-input 0.6.7 → 0.7.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.
Files changed (132) hide show
  1. package/.eslintrc.js +1 -0
  2. package/CHANGELOG.md +12 -0
  3. package/dist/components/common-style.d.ts +21 -0
  4. package/dist/components/common-style.js.flow +27 -0
  5. package/dist/components/input/cursor-contexts.d.ts +19 -0
  6. package/dist/components/input/cursor-contexts.js.flow +32 -0
  7. package/dist/components/input/cursor-handle.d.ts +25 -0
  8. package/dist/components/input/cursor-handle.js.flow +28 -0
  9. package/dist/components/input/math-input.d.ts +128 -0
  10. package/dist/components/input/math-input.js.flow +152 -0
  11. package/dist/components/keypad/button-assets.d.ts +6 -0
  12. package/dist/components/keypad/button-assets.js.flow +12 -0
  13. package/dist/components/keypad/button.d.ts +14 -0
  14. package/dist/components/keypad/button.js.flow +19 -0
  15. package/dist/components/keypad/index.d.ts +15 -0
  16. package/dist/components/keypad/index.js.flow +22 -0
  17. package/dist/components/keypad/keypad-page-items.d.ts +24 -0
  18. package/dist/components/keypad/keypad-page-items.js.flow +30 -0
  19. package/dist/components/keypad/numeric-input-page.d.ts +8 -0
  20. package/dist/components/keypad/numeric-input-page.js.flow +13 -0
  21. package/dist/components/keypad/pre-algebra-page.d.ts +8 -0
  22. package/dist/components/keypad/pre-algebra-page.js.flow +13 -0
  23. package/dist/components/keypad/trigonometry-page.d.ts +8 -0
  24. package/dist/components/keypad/trigonometry-page.js.flow +15 -0
  25. package/dist/components/provided-keypad.d.ts +23 -0
  26. package/dist/components/provided-keypad.js.flow +32 -0
  27. package/dist/components/tabbar/icons.d.ts +7 -0
  28. package/dist/components/tabbar/icons.js.flow +13 -0
  29. package/dist/components/tabbar/item.d.ts +14 -0
  30. package/dist/components/tabbar/item.js.flow +20 -0
  31. package/dist/components/tabbar/tabbar.d.ts +14 -0
  32. package/dist/components/tabbar/tabbar.js.flow +20 -0
  33. package/{src/components/tabbar/types.js → dist/components/tabbar/types.d.ts} +0 -2
  34. package/dist/components/tabbar/types.js.flow +7 -0
  35. package/dist/components/z-indexes.d.ts +7 -0
  36. package/dist/components/z-indexes.js.flow +13 -0
  37. package/dist/consts.d.ts +51 -0
  38. package/dist/consts.js.flow +66 -0
  39. package/dist/data/key-configs.d.ts +7 -0
  40. package/dist/data/key-configs.js.flow +13 -0
  41. package/dist/data/keys.d.ts +57 -0
  42. package/dist/data/keys.js.flow +112 -0
  43. package/dist/es/index.js +2275 -2781
  44. package/dist/es/index.js.map +1 -1
  45. package/dist/fake-react-native-web/index.d.ts +10 -0
  46. package/dist/fake-react-native-web/index.js.flow +8 -0
  47. package/dist/fake-react-native-web/text.d.ts +12 -0
  48. package/dist/fake-react-native-web/text.js.flow +18 -0
  49. package/dist/fake-react-native-web/view.d.ts +22 -0
  50. package/dist/fake-react-native-web/view.js.flow +28 -0
  51. package/dist/index.d.ts +14 -2
  52. package/dist/index.js +2309 -2744
  53. package/dist/index.js.flow +20 -2
  54. package/dist/index.js.map +1 -1
  55. package/dist/store/index.d.ts +1 -0
  56. package/dist/store/index.js.flow +7 -0
  57. package/dist/utils.d.ts +1 -0
  58. package/dist/utils.js.flow +7 -0
  59. package/package.json +13 -11
  60. package/src/components/__tests__/gesture-state-machine_test.js +1 -1
  61. package/src/components/__tests__/node-manager_test.js +1 -1
  62. package/src/components/__tests__/two-page-keypad_test.js +1 -1
  63. package/src/components/app.js +2 -2
  64. package/src/components/{common-style.js → common-style.ts} +0 -1
  65. package/src/components/compute-layout-parameters.js +2 -2
  66. package/src/components/corner-decal.js +2 -2
  67. package/src/components/echo-manager.js +5 -5
  68. package/src/components/empty-keypad-button.js +3 -3
  69. package/src/components/expression-keypad.js +10 -10
  70. package/src/components/fraction-keypad.js +9 -9
  71. package/src/components/gesture-manager.js +3 -3
  72. package/src/components/icon.js +6 -6
  73. package/src/components/iconography/down.js +1 -1
  74. package/src/components/iconography/index.js +41 -41
  75. package/src/components/iconography/left.js +1 -1
  76. package/src/components/iconography/right.js +1 -1
  77. package/src/components/iconography/up.js +1 -1
  78. package/src/components/input/__tests__/context-tracking_test.js +4 -4
  79. package/src/components/input/__tests__/mathquill_test.js +3 -3
  80. package/src/components/input/__tests__/{math-wrapper.jsx → test-math-wrapper.jsx} +1 -1
  81. package/src/components/input/{cursor-contexts.js → cursor-contexts.ts} +7 -14
  82. package/src/components/input/{cursor-handle.js → cursor-handle.tsx} +22 -22
  83. package/src/components/input/{math-input.js → math-input.tsx} +186 -117
  84. package/src/components/input/math-wrapper.js +5 -5
  85. package/src/components/input/scroll-into-view.js +1 -1
  86. package/src/components/keypad/{button-assets.js → button-assets.tsx} +5 -4
  87. package/src/components/keypad/button.stories.js +1 -1
  88. package/src/components/keypad/{button.js → button.tsx} +9 -9
  89. package/src/components/keypad/{index.js → index.tsx} +16 -15
  90. package/src/components/keypad/{keypad-page-items.js → keypad-page-items.tsx} +24 -39
  91. package/src/components/keypad/{keypad-pages.stories.js → keypad-pages.stories.tsx} +6 -8
  92. package/src/components/keypad/{keypad.stories.js → keypad.stories.tsx} +3 -5
  93. package/src/components/keypad/{numeric-input-page.js → numeric-input-page.tsx} +6 -7
  94. package/src/components/keypad/{pre-algebra-page.js → pre-algebra-page.tsx} +7 -8
  95. package/src/components/keypad/{trigonometry-page.js → trigonometry-page.tsx} +6 -7
  96. package/src/components/keypad-button.js +7 -11
  97. package/src/components/keypad-container.js +10 -14
  98. package/src/components/keypad.js +5 -5
  99. package/src/components/many-keypad-button.js +6 -6
  100. package/src/components/math-icon.js +3 -3
  101. package/src/components/multi-symbol-grid.js +6 -6
  102. package/src/components/multi-symbol-popover.js +5 -5
  103. package/src/components/navigation-pad.js +6 -6
  104. package/src/components/popover-manager.js +3 -3
  105. package/src/components/prop-types.js +3 -3
  106. package/src/components/{provided-keypad.js → provided-keypad.tsx} +16 -14
  107. package/src/components/styles.js +1 -1
  108. package/src/components/svg-icon.js +1 -1
  109. package/src/components/tabbar/__tests__/tabbar_test.js +1 -1
  110. package/src/components/tabbar/{icons.js → icons.tsx} +7 -12
  111. package/src/components/tabbar/{item.js → item.tsx} +6 -8
  112. package/src/components/tabbar/tabbar.stories.js +2 -2
  113. package/src/components/tabbar/{tabbar.js → tabbar.tsx} +6 -8
  114. package/src/components/tabbar/types.ts +1 -0
  115. package/src/components/text-icon.js +3 -3
  116. package/src/components/touchable-keypad-button.js +5 -5
  117. package/src/components/two-page-keypad.js +5 -5
  118. package/src/components/{z-indexes.js → z-indexes.ts} +0 -1
  119. package/src/{consts.js → consts.ts} +22 -27
  120. package/src/data/{key-configs.js → key-configs.ts} +7 -8
  121. package/src/data/{keys.js → keys.ts} +7 -13
  122. package/src/demo.js +1 -1
  123. package/src/fake-react-native-web/{index.js → index.ts} +2 -3
  124. package/src/fake-react-native-web/{text.js → text.tsx} +7 -9
  125. package/src/fake-react-native-web/{view.js → view.tsx} +15 -17
  126. package/src/{index.js → index.ts} +9 -10
  127. package/src/native-app.js +3 -3
  128. package/src/store/{index.js → index.ts} +63 -34
  129. package/src/{utils.js → utils.ts} +1 -2
  130. package/tsconfig.json +9 -0
  131. package/tsconfig.tsbuildinfo +1 -0
  132. /package/dist/{strings.js → strings} +0 -0
@@ -1,4 +1,3 @@
1
- // @flow
2
1
  import Clickable from "@khanacademy/wonder-blocks-clickable";
3
2
  import Color from "@khanacademy/wonder-blocks-color";
4
3
  import {View} from "@khanacademy/wonder-blocks-core";
@@ -6,6 +5,7 @@ import {StyleSheet} from "aphrodite";
6
5
  import * as React from "react";
7
6
 
8
7
  import type {StyleType} from "@khanacademy/wonder-blocks-core";
8
+ // @ts-expect-error [FEI-5003] - TS2305 - Module '"react"' has no exported member 'Node'.
9
9
  import type {Node} from "React";
10
10
 
11
11
  const styles = StyleSheet.create({
@@ -60,16 +60,16 @@ const styles = StyleSheet.create({
60
60
  },
61
61
  });
62
62
 
63
- type Props = {|
64
- onPress: () => void,
65
- children: Node,
66
- style?: StyleType,
67
- tintColor?: string,
68
- |};
63
+ type Props = {
64
+ onPress: () => void;
65
+ children: Node;
66
+ style?: StyleType;
67
+ tintColor?: string;
68
+ };
69
69
 
70
- type State = {};
70
+ type State = Record<any, any>;
71
71
  export default class Button extends React.Component<Props, State> {
72
- render(): React.Node {
72
+ render(): React.ReactNode {
73
73
  const {onPress, children, style, tintColor} = this.props;
74
74
  return (
75
75
  <View style={style}>
@@ -1,25 +1,24 @@
1
- //@flow
2
1
  import {View} from "@khanacademy/wonder-blocks-core";
3
2
  import * as React from "react";
4
3
 
5
- import Tabbar from "../tabbar/tabbar.js";
4
+ import Tabbar from "../tabbar/tabbar";
6
5
 
7
- import NumericInputPage from "./numeric-input-page.js";
8
- import PreAlgebraPage from "./pre-algebra-page.js";
9
- import TrigonometryPage from "./trigonometry-page.js";
6
+ import NumericInputPage from "./numeric-input-page";
7
+ import PreAlgebraPage from "./pre-algebra-page";
8
+ import TrigonometryPage from "./trigonometry-page";
10
9
 
11
- import type {TabbarItemType} from "../tabbar/types.js";
10
+ import type {TabbarItemType} from "../tabbar/types";
12
11
 
13
- type Props = {|
14
- onClickKey: (keyConfig: string) => void,
15
- preAlgebra: boolean,
16
- trigonometry: boolean,
17
- |};
12
+ type Props = {
13
+ onClickKey: (keyConfig: string) => void;
14
+ preAlgebra: boolean;
15
+ trigonometry: boolean;
16
+ };
18
17
  type State = {
19
- selectedPage: TabbarItemType,
18
+ selectedPage: TabbarItemType;
20
19
  };
21
20
 
22
- function allPages(props: Props): Array<TabbarItemType> {
21
+ const allPages: React.FC<Props> = function (props): React.ReactElement {
23
22
  const pages: Array<TabbarItemType> = ["Numbers"];
24
23
 
25
24
  if (props.preAlgebra) {
@@ -28,14 +27,15 @@ function allPages(props: Props): Array<TabbarItemType> {
28
27
  if (props.trigonometry) {
29
28
  pages.push("Geometry");
30
29
  }
30
+ // @ts-expect-error [FEI-5003] - TS2739 - Type 'TabbarItemType[]' is missing the following properties from type 'ReactElement<any, string | JSXElementConstructor<any>>': type, props, key
31
31
  return pages;
32
- }
32
+ };
33
33
 
34
34
  export default class PreAlgebraKeypad extends React.Component<Props, State> {
35
35
  state: State = {
36
36
  selectedPage: "Numbers",
37
37
  };
38
- render(): React.Node {
38
+ render(): React.ReactNode {
39
39
  const {selectedPage} = this.state;
40
40
  const {onClickKey} = this.props;
41
41
 
@@ -44,6 +44,7 @@ export default class PreAlgebraKeypad extends React.Component<Props, State> {
44
44
  return (
45
45
  <View>
46
46
  <Tabbar
47
+ // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
47
48
  items={availablePages}
48
49
  onSelect={(tabbarItem: TabbarItemType) => {
49
50
  this.setState({selectedPage: tabbarItem});
@@ -1,19 +1,17 @@
1
- // @flow
2
1
  import {View} from "@khanacademy/wonder-blocks-core";
3
2
  import * as React from "react";
4
3
 
5
- import ButtonAsset from "./button-assets.js";
6
- import Button from "./button.js";
4
+ import Button from "./button";
5
+ import ButtonAsset from "./button-assets";
7
6
 
8
- import type {KeyConfig} from "../../data/key-configs.js";
7
+ import type {KeyConfig} from "../../data/key-configs";
9
8
  import type {StyleType} from "@khanacademy/wonder-blocks-core";
9
+ // @ts-expect-error [FEI-5003] - TS2305 - Module '"react"' has no exported member 'Node'.
10
10
  import type {Node} from "React";
11
11
 
12
- export const KeypadPageContainer = ({
13
- children,
14
- }: {
15
- children: Node,
16
- }): React.Node => (
12
+ export const KeypadPageContainer: React.FC<{
13
+ children: Node;
14
+ }> = ({children}): React.ReactElement => (
17
15
  <View
18
16
  style={{
19
17
  backgroundColor: "#DBDCDD",
@@ -29,17 +27,12 @@ export const KeypadPageContainer = ({
29
27
  </View>
30
28
  );
31
29
 
32
- export const KeypadButton = ({
33
- keyConfig,
34
- onClickKey,
35
- tintColor,
36
- style,
37
- }: {
38
- keyConfig: KeyConfig,
39
- tintColor?: string,
40
- style?: StyleType,
41
- onClickKey: (keyConfig: string) => void,
42
- }): React.Node => (
30
+ export const KeypadButton: React.FC<{
31
+ keyConfig: KeyConfig;
32
+ tintColor?: string;
33
+ style?: StyleType;
34
+ onClickKey: (keyConfig: string) => void;
35
+ }> = ({keyConfig, onClickKey, tintColor, style}): React.ReactElement => (
43
36
  <Button
44
37
  onPress={() => onClickKey(keyConfig.id)}
45
38
  tintColor={tintColor}
@@ -49,15 +42,11 @@ export const KeypadButton = ({
49
42
  </Button>
50
43
  );
51
44
 
52
- export const SecondaryKeypadButton = ({
53
- keyConfig,
54
- onClickKey,
55
- style,
56
- }: {
57
- keyConfig: KeyConfig,
58
- style?: any,
59
- onClickKey: (keyConfig: string) => void,
60
- }): React.Node => (
45
+ export const SecondaryKeypadButton: React.FC<{
46
+ keyConfig: KeyConfig;
47
+ style?: any;
48
+ onClickKey: (keyConfig: string) => void;
49
+ }> = ({keyConfig, onClickKey, style}): React.ReactElement => (
61
50
  <KeypadButton
62
51
  keyConfig={keyConfig}
63
52
  onClickKey={onClickKey}
@@ -66,15 +55,11 @@ export const SecondaryKeypadButton = ({
66
55
  />
67
56
  );
68
57
 
69
- export const KeypadActionButton = ({
70
- keyConfig,
71
- onClickKey,
72
- style,
73
- }: {
74
- keyConfig: KeyConfig,
75
- style?: any,
76
- onClickKey: (keyConfig: string) => void,
77
- }): React.Node => (
58
+ export const KeypadActionButton: React.FC<{
59
+ keyConfig: KeyConfig;
60
+ style?: any;
61
+ onClickKey: (keyConfig: string) => void;
62
+ }> = ({keyConfig, onClickKey, style}): React.ReactElement => (
78
63
  <KeypadButton
79
64
  keyConfig={keyConfig}
80
65
  onClickKey={onClickKey}
@@ -83,7 +68,7 @@ export const KeypadActionButton = ({
83
68
  />
84
69
  );
85
70
 
86
- export const PlaceHolderButton = (): React.Node => (
71
+ export const PlaceHolderButton = (): React.ReactElement => (
87
72
  <View
88
73
  style={{
89
74
  height: "100%",
@@ -1,12 +1,10 @@
1
- //@flow
2
-
3
1
  import {action} from "@storybook/addon-actions";
4
2
  import {withKnobs} from "@storybook/addon-knobs";
5
3
  import * as React from "react";
6
4
 
7
- import NumericInputPage from "./numeric-input-page.js";
8
- import PrealgebraInputPage from "./pre-algebra-page.js";
9
- import TrigonometryInputPage from "./trigonometry-page.js";
5
+ import NumericInputPage from "./numeric-input-page";
6
+ import PrealgebraInputPage from "./pre-algebra-page";
7
+ import TrigonometryInputPage from "./trigonometry-page";
10
8
 
11
9
  export default {
12
10
  title: "Keypad pages",
@@ -19,14 +17,14 @@ export default {
19
17
  },
20
18
  };
21
19
 
22
- export const NumericInput = (): React.Node => (
20
+ export const NumericInput = (): React.ReactElement => (
23
21
  <NumericInputPage onClickKey={action("onClickKey")} />
24
22
  );
25
23
 
26
- export const PreAlgebraInput = (): React.Node => (
24
+ export const PreAlgebraInput = (): React.ReactElement => (
27
25
  <PrealgebraInputPage onClickKey={action("onClickKey")} />
28
26
  );
29
27
 
30
- export const TrigonometryInput = (): React.Node => (
28
+ export const TrigonometryInput = (): React.ReactElement => (
31
29
  <TrigonometryInputPage onClickKey={action("onClickKey")} />
32
30
  );
@@ -1,11 +1,9 @@
1
- //@flow
2
-
3
1
  import {action} from "@storybook/addon-actions";
4
2
  import {withKnobs} from "@storybook/addon-knobs";
5
3
  import {INITIAL_VIEWPORTS} from "@storybook/addon-viewport";
6
4
  import * as React from "react";
7
5
 
8
- import Keypad from "./index.js";
6
+ import Keypad from "./index";
9
7
 
10
8
  export default {
11
9
  title: "Full Keypad",
@@ -18,7 +16,7 @@ export default {
18
16
  },
19
17
  };
20
18
 
21
- export const PreAlgebra = (): React.Node => (
19
+ export const PreAlgebra = (): React.ReactElement => (
22
20
  <Keypad
23
21
  onClickKey={action("onClickKey")}
24
22
  preAlgebra={true}
@@ -26,7 +24,7 @@ export const PreAlgebra = (): React.Node => (
26
24
  />
27
25
  );
28
26
 
29
- export const Trigonometry = (): React.Node => (
27
+ export const Trigonometry = (): React.ReactElement => (
30
28
  <Keypad
31
29
  onClickKey={action("onClickKey")}
32
30
  preAlgebra={true}
@@ -1,21 +1,20 @@
1
- // @flow
2
1
  import * as React from "react";
3
2
 
4
- import Keys from "../../data/key-configs.js";
3
+ import Keys from "../../data/key-configs";
5
4
 
6
5
  import {
7
6
  KeypadPageContainer,
8
7
  KeypadButton,
9
8
  SecondaryKeypadButton,
10
9
  KeypadActionButton,
11
- } from "./keypad-page-items.js";
10
+ } from "./keypad-page-items";
12
11
 
13
- type Props = {|
14
- onClickKey: (keyConfig: string) => void,
15
- |};
12
+ type Props = {
13
+ onClickKey: (keyConfig: string) => void;
14
+ };
16
15
 
17
16
  export default class NumericInputPage extends React.Component<Props> {
18
- render(): React.Node {
17
+ render(): React.ReactNode {
19
18
  const {onClickKey} = this.props;
20
19
  return (
21
20
  <KeypadPageContainer>
@@ -1,21 +1,20 @@
1
- // @flow
2
1
  import * as React from "react";
3
2
 
4
- import Keys from "../../data/key-configs.js";
3
+ import Keys from "../../data/key-configs";
5
4
 
6
5
  import {
7
6
  KeypadPageContainer,
8
7
  SecondaryKeypadButton,
9
8
  KeypadActionButton,
10
9
  PlaceHolderButton,
11
- } from "./keypad-page-items.js";
10
+ } from "./keypad-page-items";
12
11
 
13
- type Props = {|
14
- onClickKey: (keyConfig: string) => void,
15
- |};
12
+ type Props = {
13
+ onClickKey: (keyConfig: string) => void;
14
+ };
16
15
 
17
- export default class NumericInputPage extends React.Component<Props> {
18
- render(): React.Node {
16
+ export default class PreAlgebraPage extends React.Component<Props> {
17
+ render(): React.ReactNode {
19
18
  const {onClickKey} = this.props;
20
19
  return (
21
20
  <KeypadPageContainer>
@@ -1,20 +1,19 @@
1
- // @flow
2
1
  import * as React from "react";
3
2
 
4
- import Keys from "../../data/key-configs.js";
3
+ import Keys from "../../data/key-configs";
5
4
 
6
5
  import {
7
6
  KeypadPageContainer,
8
7
  SecondaryKeypadButton,
9
8
  KeypadActionButton,
10
- } from "./keypad-page-items.js";
9
+ } from "./keypad-page-items";
11
10
 
12
- type Props = {|
13
- onClickKey: (keyConfig: string) => void,
14
- |};
11
+ type Props = {
12
+ onClickKey: (keyConfig: string) => void;
13
+ };
15
14
 
16
15
  export default class TrigonometryInputPage extends React.Component<Props> {
17
- render(): React.Node {
16
+ render(): React.ReactNode {
18
17
  const {onClickKey} = this.props;
19
18
  return (
20
19
  <KeypadPageContainer>
@@ -7,8 +7,8 @@ import PropTypes from "prop-types";
7
7
  import * as React from "react";
8
8
  import {connect} from "react-redux";
9
9
 
10
- import {KeyTypes, BorderDirections, BorderStyles} from "../consts.js";
11
- import {View} from "../fake-react-native-web/index.js";
10
+ import {KeyTypes, BorderDirections, BorderStyles} from "../consts";
11
+ import {View} from "../fake-react-native-web/index";
12
12
 
13
13
  import {
14
14
  wonderBlocksBlue,
@@ -19,15 +19,11 @@ import {
19
19
  operatorGrey,
20
20
  controlGrey,
21
21
  emptyGrey,
22
- } from "./common-style.js";
23
- import CornerDecal from "./corner-decal.js";
24
- import Icon from "./icon.js";
25
- import MultiSymbolGrid from "./multi-symbol-grid.js";
26
- import {
27
- bordersPropType,
28
- iconPropType,
29
- keyConfigPropType,
30
- } from "./prop-types.js";
22
+ } from "./common-style";
23
+ import CornerDecal from "./corner-decal";
24
+ import Icon from "./icon";
25
+ import MultiSymbolGrid from "./multi-symbol-grid";
26
+ import {bordersPropType, iconPropType, keyConfigPropType} from "./prop-types";
31
27
 
32
28
  // eslint-disable-next-line react/no-unsafe
33
29
  class KeypadButton extends React.PureComponent {
@@ -3,22 +3,22 @@ import PropTypes from "prop-types";
3
3
  import * as React from "react";
4
4
  import {connect} from "react-redux";
5
5
 
6
- import {setPageSize} from "../actions/index.js";
7
- import {KeypadTypes, LayoutModes} from "../consts.js";
8
- import {View} from "../fake-react-native-web/index.js";
6
+ import {setPageSize} from "../actions/index";
7
+ import {KeypadTypes, LayoutModes} from "../consts";
8
+ import {View} from "../fake-react-native-web/index";
9
9
 
10
10
  import {
11
11
  innerBorderColor,
12
12
  innerBorderStyle,
13
13
  innerBorderWidthPx,
14
14
  compactKeypadBorderRadiusPx,
15
- } from "./common-style.js";
16
- import ExpressionKeypad from "./expression-keypad.js";
17
- import FractionKeypad from "./fraction-keypad.js";
18
- import NavigationPad from "./navigation-pad.js";
19
- import {keyIdPropType} from "./prop-types.js";
20
- import Styles from "./styles.js";
21
- import * as zIndexes from "./z-indexes.js";
15
+ } from "./common-style";
16
+ import ExpressionKeypad from "./expression-keypad";
17
+ import FractionKeypad from "./fraction-keypad";
18
+ import NavigationPad from "./navigation-pad";
19
+ import {keyIdPropType} from "./prop-types";
20
+ import Styles from "./styles";
21
+ import * as zIndexes from "./z-indexes";
22
22
 
23
23
  const {row, centered, fullWidth} = Styles;
24
24
 
@@ -270,14 +270,10 @@ const inlineStyles = {
270
270
  },
271
271
 
272
272
  hidden: {
273
- msTransform: "translate3d(0, 100%, 0)",
274
- WebkitTransform: "translate3d(0, 100%, 0)",
275
273
  transform: "translate3d(0, 100%, 0)",
276
274
  },
277
275
 
278
276
  active: {
279
- msTransform: "translate3d(0, 0, 0)",
280
- WebkitTransform: "translate3d(0, 0, 0)",
281
277
  transform: "translate3d(0, 0, 0)",
282
278
  },
283
279
  };
@@ -8,12 +8,12 @@ import * as React from "react";
8
8
  import ReactDOM from "react-dom";
9
9
  import {connect} from "react-redux";
10
10
 
11
- import {removeEcho} from "../actions/index.js";
12
- import {View} from "../fake-react-native-web/index.js";
11
+ import {removeEcho} from "../actions/index";
12
+ import {View} from "../fake-react-native-web/index";
13
13
 
14
- import EchoManager from "./echo-manager.js";
15
- import PopoverManager from "./popover-manager.js";
16
- import {echoPropType, popoverPropType} from "./prop-types.js";
14
+ import EchoManager from "./echo-manager";
15
+ import PopoverManager from "./popover-manager";
16
+ import {echoPropType, popoverPropType} from "./prop-types";
17
17
 
18
18
  // eslint-disable-next-line react/no-unsafe
19
19
  class Keypad extends React.Component {
@@ -6,13 +6,13 @@
6
6
  import PropTypes from "prop-types";
7
7
  import * as React from "react";
8
8
 
9
- import {KeyTypes} from "../consts.js";
10
- import KeyConfigs from "../data/key-configs.js";
11
- import Keys from "../data/keys.js";
9
+ import {KeyTypes} from "../consts";
10
+ import KeyConfigs from "../data/key-configs";
11
+ import Keys from "../data/keys";
12
12
 
13
- import EmptyKeypadButton from "./empty-keypad-button.js";
14
- import {keyIdPropType} from "./prop-types.js";
15
- import TouchableKeypadButton from "./touchable-keypad-button.js";
13
+ import EmptyKeypadButton from "./empty-keypad-button";
14
+ import {keyIdPropType} from "./prop-types";
15
+ import TouchableKeypadButton from "./touchable-keypad-button";
16
16
 
17
17
  class ManyKeypadButton extends React.Component {
18
18
  static propTypes = {
@@ -8,10 +8,10 @@ import PropTypes from "prop-types";
8
8
  import * as React from "react";
9
9
  import ReactDOM from "react-dom";
10
10
 
11
- import {View} from "../fake-react-native-web/index.js";
11
+ import {View} from "../fake-react-native-web/index";
12
12
 
13
- import {iconSizeHeightPx, iconSizeWidthPx} from "./common-style.js";
14
- import Styles from "./styles.js";
13
+ import {iconSizeHeightPx, iconSizeWidthPx} from "./common-style";
14
+ import Styles from "./styles";
15
15
 
16
16
  const {row, centered} = Styles;
17
17
 
@@ -7,13 +7,13 @@ import {StyleSheet} from "aphrodite";
7
7
  import PropTypes from "prop-types";
8
8
  import * as React from "react";
9
9
 
10
- import {IconTypes} from "../consts.js";
11
- import {View} from "../fake-react-native-web/index.js";
10
+ import {IconTypes} from "../consts";
11
+ import {View} from "../fake-react-native-web/index";
12
12
 
13
- import {iconSizeHeightPx, iconSizeWidthPx} from "./common-style.js";
14
- import Icon from "./icon.js";
15
- import {iconPropType} from "./prop-types.js";
16
- import Styles from "./styles.js";
13
+ import {iconSizeHeightPx, iconSizeWidthPx} from "./common-style";
14
+ import Icon from "./icon";
15
+ import {iconPropType} from "./prop-types";
16
+ import Styles from "./styles";
17
17
 
18
18
  const {row, column, centered, fullWidth} = Styles;
19
19
 
@@ -6,12 +6,12 @@ import {StyleSheet} from "aphrodite";
6
6
  import PropTypes from "prop-types";
7
7
  import * as React from "react";
8
8
 
9
- import {BorderStyles} from "../consts.js";
10
- import {View} from "../fake-react-native-web/index.js";
9
+ import {BorderStyles} from "../consts";
10
+ import {View} from "../fake-react-native-web/index";
11
11
 
12
- import {keyConfigPropType} from "./prop-types.js";
13
- import TouchableKeypadButton from "./touchable-keypad-button.js";
14
- import * as zIndexes from "./z-indexes.js";
12
+ import {keyConfigPropType} from "./prop-types";
13
+ import TouchableKeypadButton from "./touchable-keypad-button";
14
+ import * as zIndexes from "./z-indexes";
15
15
 
16
16
  class MultiSymbolPopover extends React.Component {
17
17
  static propTypes = {
@@ -7,18 +7,18 @@ import {StyleSheet} from "aphrodite";
7
7
  import PropTypes from "prop-types";
8
8
  import * as React from "react";
9
9
 
10
- import {BorderStyles} from "../consts.js";
11
- import KeyConfigs from "../data/key-configs.js";
12
- import {View} from "../fake-react-native-web/index.js";
10
+ import {BorderStyles} from "../consts";
11
+ import KeyConfigs from "../data/key-configs";
12
+ import {View} from "../fake-react-native-web/index";
13
13
 
14
14
  import {
15
15
  navigationPadWidthPx,
16
16
  controlGrey,
17
17
  valueGrey,
18
18
  offBlack16,
19
- } from "./common-style.js";
20
- import Styles from "./styles.js";
21
- import TouchableKeypadButton from "./touchable-keypad-button.js";
19
+ } from "./common-style";
20
+ import Styles from "./styles";
21
+ import TouchableKeypadButton from "./touchable-keypad-button";
22
22
 
23
23
  const {row, column, centered, stretch, roundedTopLeft} = Styles;
24
24
 
@@ -7,14 +7,14 @@ import PropTypes from "prop-types";
7
7
  import * as React from "react";
8
8
  import {CSSTransition} from "react-transition-group";
9
9
 
10
- import KeyConfigs from "../data/key-configs.js";
10
+ import KeyConfigs from "../data/key-configs";
11
11
 
12
- import MultiSymbolPopover from "./multi-symbol-popover.js";
12
+ import MultiSymbolPopover from "./multi-symbol-popover";
13
13
  import {
14
14
  boundingBoxPropType,
15
15
  keyConfigPropType,
16
16
  popoverPropType,
17
- } from "./prop-types.js";
17
+ } from "./prop-types";
18
18
 
19
19
  // NOTE(charlie): These must be kept in sync with the transition durations and
20
20
  // classnames specified in popover.less.
@@ -10,10 +10,10 @@ import {
10
10
  IconTypes,
11
11
  KeyTypes,
12
12
  KeypadTypes,
13
- } from "../consts.js";
14
- import KeyConfigs from "../data/key-configs.js";
13
+ } from "../consts";
14
+ import KeyConfigs from "../data/key-configs";
15
15
 
16
- import * as CursorContexts from "./input/cursor-contexts.js";
16
+ import * as CursorContexts from "./input/cursor-contexts";
17
17
 
18
18
  export const iconPropType = PropTypes.shape({
19
19
  type: PropTypes.oneOf(Object.keys(IconTypes)).isRequired,