@office-iss/react-native-win32 0.71.0 → 0.71.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.
- package/.flowconfig +1 -0
- package/CHANGELOG.json +12667 -12652
- package/CHANGELOG.md +23 -15
- package/Libraries/Components/Button/ButtonWin32.Props.d.ts +2 -2
- package/Libraries/Components/Button/ButtonWin32.d.ts +1 -1
- package/Libraries/Components/Button/ButtonWin32.js +6 -4
- package/Libraries/Components/Button/ButtonWin32.js.map +1 -1
- package/Libraries/Components/Pressable/Pressable.win32.js +0 -1
- package/Libraries/Components/Text/TextWin32.Props.d.ts +3 -9
- package/Libraries/Components/Text/TextWin32.Props.js.map +1 -1
- package/Libraries/Components/Text/TextWin32.d.ts +1 -1
- package/Libraries/Components/Text/TextWin32.js.map +1 -1
- package/Libraries/Components/TextInput/TextInput.Types.win32.d.ts +9 -9
- package/Libraries/Components/TextInput/TextInput.win32.js +1150 -154
- package/Libraries/Components/Touchable/Tests/TouchableWin32Test.js +4 -4
- package/Libraries/Components/Touchable/Tests/TouchableWin32Test.js.map +1 -1
- package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.d.ts +119 -16
- package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.js +99 -24
- package/Libraries/Components/Touchable/TouchableWin32.Props.d.ts +2 -2
- package/Libraries/Components/Touchable/TouchableWin32.Props.js.map +1 -1
- package/Libraries/Components/Touchable/TouchableWin32.Types.d.ts +9 -9
- package/Libraries/Components/Touchable/TouchableWin32.js +5 -6
- package/Libraries/Components/Touchable/TouchableWin32.js.map +1 -1
- package/Libraries/Components/View/ReactNativeViewAttributes.win32.js +29 -10
- package/Libraries/Components/View/Tests/ViewWin32Test.js +31 -51
- package/Libraries/Components/View/Tests/ViewWin32Test.js.map +1 -1
- package/Libraries/Components/View/ViewAccessibility.win32.d.ts +527 -0
- package/Libraries/Components/View/ViewAccessibility.win32.js +178 -0
- package/Libraries/Components/View/ViewPropTypes.win32.d.ts +372 -0
- package/Libraries/Components/View/ViewPropTypes.win32.js +23 -0
- package/Libraries/Components/View/ViewWin32.d.ts +30 -12
- package/Libraries/Components/View/ViewWin32.js +161 -71
- package/Libraries/Image/Image.win32.js +0 -1
- package/Libraries/Pressability/Pressability.win32.js +2 -2
- package/Libraries/Utilities/AcessibilityMapping.win32.js +156 -0
- package/Libraries/__tests__/ButtonWin32-test.js +1 -1
- package/Libraries/platform-types.d.ts +7 -13
- package/index.win32.js +1 -1
- package/jest.config.js +2 -4
- package/overrides.json +38 -8
- package/package.json +5 -5
- package/src/Libraries/Components/Button/ButtonWin32.tsx +8 -8
- package/src/Libraries/Components/Text/TextWin32.Props.ts +2 -15
- package/src/Libraries/Components/Text/TextWin32.tsx +6 -2
- package/src/Libraries/Components/Touchable/Tests/TouchableWin32Test.tsx +5 -5
- package/src/Libraries/Components/Touchable/TouchableNativeFeedback.win32.d.ts +119 -0
- package/src/Libraries/Components/Touchable/TouchableWin32.Props.tsx +1 -1
- package/src/Libraries/Components/Touchable/TouchableWin32.tsx +6 -7
- package/src/Libraries/Components/View/Tests/ViewWin32Test.tsx +28 -52
- package/src/Libraries/Components/View/ViewAccessibility.win32.d.ts +527 -0
- package/src/Libraries/Components/View/ViewPropTypes.win32.d.ts +372 -0
- package/src/Libraries/Components/View/ViewWin32.d.ts +30 -0
- package/src/Libraries/platform-types.d.ts +7 -13
- package/types/modules/BatchedBridge.d.ts +32 -0
- package/types/modules/Codegen.d.ts +74 -0
- package/types/modules/Devtools.d.ts +31 -0
- package/types/modules/LaunchScreen.d.ts +18 -0
- package/types/modules/globals.d.ts +577 -0
- package/types/private/TimerMixin.d.ts +19 -0
- package/types/private/Utilities.d.ts +10 -0
- package/types/public/DeprecatedPropertiesAlias.d.ts +205 -0
- package/types/public/Insets.d.ts +15 -0
- package/types/public/ReactNativeRenderer.d.ts +149 -0
- package/types/public/ReactNativeTypes.d.ts +143 -0
- package/Libraries/Components/TextInput/TextInput.win32.d.ts +0 -68
- package/Libraries/Components/TextInput/TextInput.win32.js.map +0 -1
- package/Libraries/Components/Touchable/TouchableNativeFeedback.Props.d.ts +0 -7
- package/Libraries/Components/Touchable/TouchableNativeFeedback.Props.js +0 -3
- package/Libraries/Components/Touchable/TouchableNativeFeedback.Props.js.map +0 -1
- package/Libraries/Components/Touchable/TouchableNativeFeedback.win32.js.map +0 -1
- package/Libraries/Components/View/ViewWin32.Props.d.ts +0 -174
- package/Libraries/Components/View/ViewWin32.Props.js +0 -11
- package/Libraries/Components/View/ViewWin32.Props.js.map +0 -1
- package/Libraries/Components/View/ViewWin32.js.map +0 -1
- package/src/Libraries/Components/TextInput/TextInput.win32.tsx +0 -217
- package/src/Libraries/Components/Touchable/TouchableNativeFeedback.Props.ts +0 -9
- package/src/Libraries/Components/Touchable/TouchableNativeFeedback.win32.tsx +0 -27
- package/src/Libraries/Components/View/ViewWin32.Props.ts +0 -281
- package/src/Libraries/Components/View/ViewWin32.tsx +0 -119
package/CHANGELOG.md
CHANGED
|
@@ -1,17 +1,25 @@
|
|
|
1
|
-
# Change Log - @office-iss/react-native-win32
|
|
2
|
-
|
|
3
|
-
This log was last generated on Mon,
|
|
4
|
-
|
|
5
|
-
<!-- Start content -->
|
|
6
|
-
|
|
7
|
-
## 0.71.
|
|
8
|
-
|
|
9
|
-
Mon,
|
|
10
|
-
|
|
11
|
-
### Patches
|
|
12
|
-
|
|
13
|
-
-
|
|
14
|
-
|
|
1
|
+
# Change Log - @office-iss/react-native-win32
|
|
2
|
+
|
|
3
|
+
This log was last generated on Mon, 13 Feb 2023 16:16:01 GMT and should not be manually modified.
|
|
4
|
+
|
|
5
|
+
<!-- Start content -->
|
|
6
|
+
|
|
7
|
+
## 0.71.1
|
|
8
|
+
|
|
9
|
+
Mon, 13 Feb 2023 16:16:01 GMT
|
|
10
|
+
|
|
11
|
+
### Patches
|
|
12
|
+
|
|
13
|
+
- Fix react-native-win32 typescript definitions (30809111+acoates-ms@users.noreply.github.com)
|
|
14
|
+
|
|
15
|
+
## 0.71.0
|
|
16
|
+
|
|
17
|
+
Mon, 23 Jan 2023 16:16:57 GMT
|
|
18
|
+
|
|
19
|
+
### Patches
|
|
20
|
+
|
|
21
|
+
- Promote 0.71 to latest (34109996+chiaramooney@users.noreply.github.com)
|
|
22
|
+
|
|
15
23
|
## 0.71.0-preview.2
|
|
16
24
|
|
|
17
25
|
Mon, 19 Dec 2022 16:14:52 GMT
|
|
@@ -4810,4 +4818,4 @@ Mon, 01 May 2017 19:28:16 GMT
|
|
|
4810
4818
|
|
|
4811
4819
|
### Patches
|
|
4812
4820
|
|
|
4813
|
-
- Move @office-iss/react-native to 0.40.1 to fix build
|
|
4821
|
+
- Move @office-iss/react-native to 0.40.1 to fix build
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import RN = require('react-native');
|
|
2
|
-
|
|
3
|
-
export
|
|
2
|
+
type Omit<T, K> = Pick<T, Exclude<keyof T, keyof K>>;
|
|
3
|
+
export type ButtonWin32OmitStyles = RN.TextStyleIOS & RN.TextStyleAndroid;
|
|
4
4
|
export interface IButtonWin32Style extends Omit<RN.TextStyle, ButtonWin32OmitStyles> {
|
|
5
5
|
}
|
|
6
6
|
export interface IButtonWin32Props extends RN.ButtonProps {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import RN = require('react-native');
|
|
3
|
-
import { IButtonWin32Props } from './ButtonWin32.Props';
|
|
3
|
+
import type { IButtonWin32Props } from './ButtonWin32.Props';
|
|
4
4
|
interface IButtonWin32State {
|
|
5
5
|
accessibilityState: RN.AccessibilityState;
|
|
6
6
|
}
|
|
@@ -5,8 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ButtonWin32 = void 0;
|
|
7
7
|
const react_1 = __importDefault(require("react"));
|
|
8
|
-
const
|
|
9
|
-
const TextWin32_1 = require("../Text/TextWin32");
|
|
8
|
+
const RN = require("react-native");
|
|
10
9
|
var SelectState;
|
|
11
10
|
(function (SelectState) {
|
|
12
11
|
SelectState[SelectState["NotSelected"] = 0] = "NotSelected";
|
|
@@ -65,6 +64,7 @@ class ButtonWin32 extends react_1.default.Component {
|
|
|
65
64
|
onBlur: this._onBlur,
|
|
66
65
|
onMouseEnter: this.props.onMouseEnter,
|
|
67
66
|
onMouseLeave: this.props.onMouseLeave,
|
|
67
|
+
// @ts-ignore
|
|
68
68
|
onTouchStart: this.props.onTouchStart,
|
|
69
69
|
onTouchEnd: this._onTouchEnd,
|
|
70
70
|
testID: this.props.testID,
|
|
@@ -76,8 +76,10 @@ class ButtonWin32 extends react_1.default.Component {
|
|
|
76
76
|
if (this.props.color) {
|
|
77
77
|
textProps.style = { color: this.props.color };
|
|
78
78
|
}
|
|
79
|
-
return (
|
|
80
|
-
|
|
79
|
+
return (
|
|
80
|
+
// @ts-ignore
|
|
81
|
+
react_1.default.createElement(RN.ViewWin32, { ...viewProps },
|
|
82
|
+
react_1.default.createElement(RN.TextWin32, { ...textProps }, this.props.title)));
|
|
81
83
|
}
|
|
82
84
|
}
|
|
83
85
|
exports.ButtonWin32 = ButtonWin32;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonWin32.js","sourceRoot":"","sources":["../../../src/Libraries/Components/Button/ButtonWin32.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAAyB;
|
|
1
|
+
{"version":3,"file":"ButtonWin32.js","sourceRoot":"","sources":["../../../src/Libraries/Components/Button/ButtonWin32.tsx"],"names":[],"mappings":"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","sourcesContent":["import React from 'react'\nimport RN = require('react-native');\nimport type { IViewWin32Props } from '../View/ViewPropTypes.win32';\nimport type { ITextWin32Props } from '../Text/TextWin32.Props';\nimport type { IButtonWin32Props } from './ButtonWin32.Props';\n\nconst enum SelectState {\n NotSelected,\n Selected\n}\n\ninterface IButtonWin32State {\n accessibilityState: RN.AccessibilityState;\n}\n\n/**\n * React-native <Button> control with additional Win32-specific functionality.\n */\nexport class ButtonWin32 extends React.Component<IButtonWin32Props, IButtonWin32State> {\n constructor(props: IButtonWin32Props) {\n super(props);\n this.state = this._makeState(SelectState.NotSelected);\n }\n\n public render() {\n const viewProps: IViewWin32Props = {\n accessible: true,\n accessibilityLabel: this.props.accessibilityLabel || this.props.title,\n accessibilityRole: 'button',\n accessibilityState: this.state.accessibilityState,\n focusable: true,\n onFocus: this._onFocus,\n onBlur: this._onBlur,\n onMouseEnter: this.props.onMouseEnter,\n onMouseLeave: this.props.onMouseLeave,\n // @ts-ignore\n onTouchStart: this.props.onTouchStart,\n onTouchEnd: this._onTouchEnd,\n testID: this.props.testID,\n style: this.props.style as RN.StyleProp<RN.ViewStyle>,\n };\n\n const textProps: ITextWin32Props = {\n textStyle: 'None',\n };\n if (this.props.color) {\n textProps.style = { color: this.props.color };\n }\n\n return (\n // @ts-ignore\n <RN.ViewWin32 {...viewProps}>\n <RN.TextWin32 {...textProps}>{this.props.title}</RN.TextWin32>\n </RN.ViewWin32>\n );\n }\n\n private readonly _makeState = (select: SelectState): IButtonWin32State => {\n return {\n accessibilityState: {\n disabled: this.props.disabled,\n selected: select === SelectState.Selected,\n },\n };\n };\n\n private readonly _setState = (select: SelectState): void => {\n const state = this._makeState(select);\n this.setState(state);\n };\n\n private readonly _onFocus = (): void => {\n this._setState(SelectState.Selected);\n if (this.props.onFocus) {\n this.props.onFocus();\n }\n };\n\n private readonly _onBlur = (): void => {\n this._setState(SelectState.NotSelected);\n if (this.props.onBlur) {\n this.props.onBlur();\n }\n };\n\n private readonly _onTouchEnd = (event: RN.GestureResponderEvent): void => {\n if (!this.props.disabled) {\n if (this.props.onPress) {\n this.props.onPress(event);\n }\n }\n if (this.props.onTouchEnd) {\n this.props.onTouchEnd(event);\n }\n };\n}\n"]}
|
|
@@ -35,7 +35,6 @@ import * as React from 'react';
|
|
|
35
35
|
import {useImperativeHandle, useMemo, useRef, useState} from 'react';
|
|
36
36
|
import type {HandledKeyboardEvent} from '../../Components/View/ViewPropTypes';
|
|
37
37
|
import View from '../View/View';
|
|
38
|
-
import TextInputState from '../TextInput/TextInputState';
|
|
39
38
|
|
|
40
39
|
type ViewStyleProp = $ElementType<React.ElementConfig<typeof View>, 'style'>;
|
|
41
40
|
|
|
@@ -1,15 +1,10 @@
|
|
|
1
1
|
import RN = require('react-native');
|
|
2
|
-
import {
|
|
3
|
-
declare type Omit<T, K> = Pick<T, Exclude<keyof T, keyof K>>;
|
|
4
|
-
export declare type TextWin32OmitTypes = Omit<RN.TextPropsAndroid, SharedTextPropsAndroidandWin32> & RN.TextPropsIOS & RN.AccessibilityPropsAndroid & Omit<RN.AccessibilityPropsIOS, SharedAccessibilityPropsIOSandWin32> & OmittedAccessibilityPropsWin32;
|
|
5
|
-
export declare type SharedTextPropsAndroidandWin32 = {
|
|
6
|
-
selectable?: boolean;
|
|
7
|
-
};
|
|
2
|
+
import type { IKeyboardEvent, IHandledKeyboardEvent } from '../View/ViewPropTypes.win32';
|
|
8
3
|
/**
|
|
9
4
|
* Role-based text style names.
|
|
10
5
|
*/
|
|
11
|
-
export
|
|
12
|
-
export interface ITextWin32Props extends
|
|
6
|
+
export type TextWin32TextStyle = 'None' | 'SmallStandard' | 'SmallSecondary' | 'MediumStandard' | 'MediumSecondary' | 'MediumApp' | 'MediumBold' | 'MediumBoldApp' | 'LargeStandard' | 'LargePlusStandard' | 'ExtraLargeStandard' | 'HugeStandard';
|
|
7
|
+
export interface ITextWin32Props extends RN.TextProps {
|
|
13
8
|
onKeyDown?: (args: IKeyboardEvent) => void;
|
|
14
9
|
onKeyDownCapture?: (args: IKeyboardEvent) => void;
|
|
15
10
|
onKeyUp?: (args: IKeyboardEvent) => void;
|
|
@@ -66,4 +61,3 @@ export interface ITextWin32Props extends Omit<RN.TextProps, TextWin32OmitTypes>,
|
|
|
66
61
|
/** Tooltip displayed on mouse hover of this element */
|
|
67
62
|
tooltip?: string;
|
|
68
63
|
}
|
|
69
|
-
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextWin32.Props.js","sourceRoot":"","sources":["../../../src/Libraries/Components/Text/TextWin32.Props.ts"],"names":[],"mappings":"","sourcesContent":["import RN = require('react-native');\nimport {
|
|
1
|
+
{"version":3,"file":"TextWin32.Props.js","sourceRoot":"","sources":["../../../src/Libraries/Components/Text/TextWin32.Props.ts"],"names":[],"mappings":"","sourcesContent":["import RN = require('react-native');\nimport type { IKeyboardEvent, IHandledKeyboardEvent } from '../View/ViewPropTypes.win32';\n\n/**\n * Role-based text style names.\n */\nexport type TextWin32TextStyle =\n | 'None'\n | 'SmallStandard'\n | 'SmallSecondary'\n | 'MediumStandard'\n | 'MediumSecondary'\n | 'MediumApp'\n | 'MediumBold'\n | 'MediumBoldApp'\n | 'LargeStandard'\n | 'LargePlusStandard'\n | 'ExtraLargeStandard'\n | 'HugeStandard';\n\nexport interface ITextWin32Props extends RN.TextProps {\n onKeyDown?: (args: IKeyboardEvent) => void;\n onKeyDownCapture?: (args: IKeyboardEvent) => void;\n onKeyUp?: (args: IKeyboardEvent) => void;\n onKeyUpCapture?: (args: IKeyboardEvent) => void;\n\n keyDownEvents?: IHandledKeyboardEvent[];\n keyUpEvents?: IHandledKeyboardEvent[];\n\n /** Enables a focusable label with copyability but without character selectability (property:selectable) */\n focusable?: boolean;\n\n /**\n * The onBlur event occurs when an element loses focus. The opposite of onBlur is onFocus. Note that in React\n * Native, unlike in the web, the onBlur event bubbles (similar to onFocusOut in the web).\n *\n * `ev.target === ev.currentTarget` when the focus is being lost from this component.\n * `ev.target !== ev.currentTarget` when the focus is being lost from a descendant.\n */\n onBlur?: (ev: RN.NativeSyntheticEvent<{}>) => void;\n /**\n * The onBlur event occurs when an element loses focus. The opposite of onBlur is onFocus. Note that in React\n * Native, unlike in the web, the onBlur event bubbles (similar to onFocusOut in the web).\n *\n * `ev.target === ev.currentTarget` when the focus is being lost from this component.\n * `ev.target !== ev.currentTarget` when the focus is being lost from a descendant.\n */\n onBlurCapture?: (ev: RN.NativeSyntheticEvent<{}>) => void;\n /**\n * The onFocus event occurs when an element gets focus. The opposite of onFocus is onBlur. Note that in React\n * Native, unlike in the web, the onFocus event bubbles (similar to onFocusIn in the web).\n *\n * `ev.target === ev.currentTarget` when the focus is being lost from this component.\n * `ev.target !== ev.currentTarget` when the focus is being lost from a descendant.\n */\n onFocus?: (ev: RN.NativeSyntheticEvent<{}>) => void;\n /**\n * The onFocus event occurs when an element gets focus. The opposite of onFocus is onBlur. Note that in React\n * Native, unlike in the web, the onFocus event bubbles (similar to onFocusIn in the web).\n *\n * `ev.target === ev.currentTarget` when the focus is being lost from this component.\n * `ev.target !== ev.currentTarget` when the focus is being lost from a descendant.\n */\n onFocusCapture?: (ev: RN.NativeSyntheticEvent<{}>) => void;\n \n /**\n * Role-based styling of the text control. The styles applied include\n * font face, size, weight and color. These styles take precedence over\n * the `style` property.\n *\n * @remarks\n * The default value is `MediumStandard`.\n *\n * When set to `None`, role-based styling is disabled.\n *\n * @deprecated Use `style` instead.\n */\n textStyle?: TextWin32TextStyle;\n\n /** Tooltip displayed on mouse hover of this element */\n tooltip?: string;\n}\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ITextWin32Props } from './TextWin32.Props';
|
|
2
|
+
import type { ITextWin32Props } from './TextWin32.Props';
|
|
3
3
|
export declare class TextWin32 extends React.Component<ITextWin32Props, {}> {
|
|
4
4
|
constructor(props: ITextWin32Props);
|
|
5
5
|
render(): JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextWin32.js","sourceRoot":"","sources":["../../../src/Libraries/Components/Text/TextWin32.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAAyB;AACzB,mCAAoC;
|
|
1
|
+
{"version":3,"file":"TextWin32.js","sourceRoot":"","sources":["../../../src/Libraries/Components/Text/TextWin32.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAAyB;AACzB,mCAAoC;AAepC,MAAa,SAAU,SAAQ,eAAK,CAAC,SAA8B;IACjE,YAAY,KAAsB;QAChC,KAAK,CAAC,KAAK,CAAC,CAAC;IACf,CAAC;IAEM,MAAM;QACX,OAAO,8BAAC,EAAE,CAAC,IAAI,OAAM,IAAI,CAAC,KAAwB,GAAI,CAAC;IACzD,CAAC;CACF;AARD,8BAQC","sourcesContent":["import React from 'react'\nimport RN = require('react-native');\nimport type { ITextWin32Props } from './TextWin32.Props';\n\n/**\n * All of TOrigin except Key from TUse\n */\ntype UseFrom<TOrigin, TUse, Key extends keyof TUse> = Pick<TOrigin, Exclude<keyof TOrigin, Key>> & Pick<TUse, Key>;\n\n/**\n * React-native <Text> control with additional Win32-specific functionality.\n */\n\ntype InnerViewProps = UseFrom<ITextWin32Props, RN.TextProps, 'accessibilityRole'> &\n UseFrom<ITextWin32Props, RN.TextProps, 'accessibilityState'> &\n UseFrom<ITextWin32Props, RN.TextProps, 'accessibilityActions'>;\nexport class TextWin32 extends React.Component<ITextWin32Props, {}> {\n constructor(props: ITextWin32Props) {\n super(props);\n }\n\n public render() {\n return <RN.Text {...(this.props as InnerViewProps)} />;\n }\n}\n"]}
|
|
@@ -4,7 +4,7 @@ interface IChangePayload {
|
|
|
4
4
|
target: number;
|
|
5
5
|
text: string;
|
|
6
6
|
}
|
|
7
|
-
export
|
|
7
|
+
export type IChangeEvent = NativeSyntheticEvent<Readonly<IChangePayload>>;
|
|
8
8
|
interface IRange {
|
|
9
9
|
start: number;
|
|
10
10
|
end: number;
|
|
@@ -16,7 +16,7 @@ interface ITextInputPayload {
|
|
|
16
16
|
target: number;
|
|
17
17
|
text: number;
|
|
18
18
|
}
|
|
19
|
-
export
|
|
19
|
+
export type ITextInputevent = NativeSyntheticEvent<Readonly<ITextInputPayload>>;
|
|
20
20
|
interface IContentSize {
|
|
21
21
|
width: number;
|
|
22
22
|
height: number;
|
|
@@ -25,27 +25,27 @@ interface IContentSizeChangePayload {
|
|
|
25
25
|
target: number;
|
|
26
26
|
contentSize: Readonly<IContentSize>;
|
|
27
27
|
}
|
|
28
|
-
export
|
|
29
|
-
export
|
|
30
|
-
export
|
|
28
|
+
export type IContentSizeChangeEvent = NativeSyntheticEvent<Readonly<IContentSizeChangePayload>>;
|
|
29
|
+
export type IBlurEvent = NativeSyntheticEvent<Readonly<TextInputFocusEventData>>;
|
|
30
|
+
export type IFocusEvent = NativeSyntheticEvent<Readonly<TextInputFocusEventData>>;
|
|
31
31
|
export interface ISelection extends IRange {
|
|
32
32
|
}
|
|
33
33
|
interface ISelectionPayload {
|
|
34
34
|
selection: ISelection;
|
|
35
35
|
target: number;
|
|
36
36
|
}
|
|
37
|
-
export
|
|
37
|
+
export type ISelectionChangeEvent = NativeSyntheticEvent<Readonly<ISelectionPayload>>;
|
|
38
38
|
interface IKeyPressPayload {
|
|
39
39
|
key: string;
|
|
40
40
|
target?: number;
|
|
41
41
|
eventCount?: number;
|
|
42
42
|
}
|
|
43
|
-
export
|
|
43
|
+
export type IKeyPressEvent = NativeSyntheticEvent<Readonly<IKeyPressPayload>>;
|
|
44
44
|
interface IEditingPayload {
|
|
45
45
|
eventCount: number;
|
|
46
46
|
text: string;
|
|
47
47
|
target: number;
|
|
48
48
|
}
|
|
49
|
-
export
|
|
50
|
-
export
|
|
49
|
+
export type IEditingEvent = NativeSyntheticEvent<Readonly<IEditingPayload>>;
|
|
50
|
+
export type IPasswordRules = string;
|
|
51
51
|
export {};
|