@@ -72,213 +72,3 @@ export abstract class LeafComponentBaseScreen<
7272 throw new Error ( 'Please sub class implement.' ) ;
7373 }
7474}
75-
76- // interface State extends StateBase {}
77-
78- // export function LeafComponentScreenFactory(
79- // params: any
80- // ): LeafComponentBaseScreen<StateBase> {
81- // return new (class s extends LeafComponentBaseScreen<State> {
82- // public static route = 'SendMessageScreen';
83- // protected static TAG = 'SendMessageScreen';
84- // constructor(props: { navigation: any }) {
85- // super(props);
86- // }
87- // componentDidMount(): void {
88- // super.componentDidMount();
89- // }
90- // componentWillUnmount(): void {
91- // super.componentWillUnmount();
92- // }
93- // render(): ReactNode {
94- // const { sendResult } = this.state;
95- // return (
96- // <View style={styleValues.containerColumn}>
97- // <View style={styleValues.containerColumn}>
98- // <Text style={styleValues.textTipStyle}>result: {sendResult}</Text>
99- // </View>
100- // </View>
101- // );
102- // }
103- // })({ navigation: params });
104- // }
105-
106- // type ssss<S extends StateBase> = LeafComponentBaseScreen<S>;
107-
108- // export function LeafComponentScreenFactory2<S extends StateBase>(): Promise<
109- // LeafComponentBaseScreen<S>
110- // > {
111- // const s = `class s extends LeafComponentBaseScreen<S> {
112- // public static route = 'SendMessageScreen';
113- // protected static TAG = 'SendMessageScreen';
114- // constructor(props: { navigation: any }) {
115- // super(props);
116- // }
117- // componentDidMount(): void {
118- // super.componentDidMount();
119- // }
120- // componentWillUnmount(): void {
121- // super.componentWillUnmount();
122- // }
123- // render(): ReactNode {
124- // const { sendResult } = this.state;
125- // return (
126- // <View style={styleValues.containerColumn}>
127- // <View style={styleValues.containerColumn}>
128- // <Text style={styleValues.textTipStyle}>result: {sendResult}</Text>
129- // </View>
130- // </View>
131- // );
132- // }
133- // };`;
134- // // eslint-disable-next-line no-eval
135- // return eval(s);
136- // }
137-
138- // class TestExportClass {
139- // value: any;
140- // constructor(props: { navigation: any }) {
141- // this.value = props.navigation;
142- // }
143- // }
144-
145- // export function LeafComponentScreenFactory3(): TestExportClass {
146- // return new TestExportClass({ navigation: 's' });
147- // }
148-
149- // export function LeafComponentScreenFactory4<S extends StateBase>(props: {
150- // navigation: any;
151- // }): React.Component<{ navigation: any }, S> {
152- // return new (class s extends React.Component<{ navigation: any }, S> {
153- // public static route = 'SendMessageScreen';
154- // protected static TAG = 'SendMessageScreen';
155- // constructor(props: { navigation: any }) {
156- // super(props);
157- // }
158- // componentDidMount(): void {}
159- // componentWillUnmount(): void {}
160- // render(): ReactNode {
161- // const { sendResult } = this.state;
162- // return (
163- // <View style={styleValues.containerColumn}>
164- // <View style={styleValues.containerColumn}>
165- // <Text style={styleValues.textTipStyle}>result: {sendResult}</Text>
166- // </View>
167- // </View>
168- // );
169- // }
170- // })(props);
171- // }
172-
173- // export function LeafComponentScreenFactory5<S extends StateBase>(props: {
174- // navigation: any;
175- // }): React.Component<{ navigation: any }, S> {
176- // return new (class s extends React.Component<{ navigation: any }, S> {
177- // public static route = 'SendMessageScreen';
178- // protected static TAG = 'SendMessageScreen';
179- // constructor(props: { navigation: any }) {
180- // super(props);
181- // }
182- // componentDidMount(): void {}
183- // componentWillUnmount(): void {}
184- // render(): ReactNode {
185- // const { sendResult } = this.state;
186- // return (
187- // <View style={styleValues.containerColumn}>
188- // <View style={styleValues.containerColumn}>
189- // <Text style={styleValues.textTipStyle}>result: {sendResult}</Text>
190- // </View>
191- // </View>
192- // );
193- // }
194- // })(props);
195- // }
196-
197- // type ParamsType = {
198- // props: {
199- // navigation: any;
200- // };
201- // };
202-
203- // export const LeafComponentScreenFactory6: LeafComponentType = (props: {
204- // navigation: any;
205- // }): any => {
206- // class _s<P extends { navigation: any }, S> extends React.Component<P, S, any> {
207- // public static route = 'LoginAndLogoutScreen';
208- // private static TAG = 'LoginAndLogoutScreen';
209- // navigation: any;
210-
211- // constructor(_props: P) {
212- // super(_props);
213- // this.navigation = props.navigation;
214- // }
215-
216- // render(): ReactNode {
217- // return (
218- // <View style={styleValues.containerColumn}>
219- // <View style={styleValues.containerRow}>
220- // <Text style={styleValues.textStyle}>UseName: </Text>
221- // </View>
222- // </View>
223- // );
224- // }
225- // }
226-
227- // class _ss<P extends { navigation: any }, S = any>
228- // implements React.ComponentClass<P, S>
229- // {
230- // component: _s<P, S>;
231- // constructor(_props: P, _context?: any) {
232- // this.component = new _s(_props);
233- // }
234- // // new (props: P, context?: any): React.Component<P, S>;
235- // propTypes?: React.WeakValidationMap<P> | undefined;
236- // contextType?: React.Context<any> | undefined;
237- // contextTypes?: ValidationMap<any> | undefined;
238- // childContextTypes?: ValidationMap<any> | undefined;
239- // defaultProps?: Partial<P> | undefined;
240- // displayName?: string | undefined;
241- // getDerivedStateFromProps?: React.GetDerivedStateFromProps<P, S> | undefined;
242- // getDerivedStateFromError?: React.GetDerivedStateFromError<P, S> | undefined;
243- // }
244- // return new _ss(props);
245- // };
246-
247- // const ReactComponent2: React.ComponentClass<{
248- // navigation: any;
249- // }> = class extends React.Component<{ navigation: any }, any> {
250- // static displayName = 'ReactComponent2';
251- // public static route = 'ReactComponent2';
252- // render(): ReactNode {
253- // return (
254- // <View style={styleValues.containerColumn}>
255- // <View style={styleValues.containerRow}>
256- // <Text style={styleValues.textStyle}>UseName: </Text>
257- // </View>
258- // </View>
259- // );
260- // }
261- // };
262-
263- // export const LeafComponentScreenFactory7: LeafComponentType = ReactComponent2;
264-
265- // export function LeafComponentScreenFactory8(): React.ComponentClass {
266- // const ret: React.ComponentClass = class extends React.React.Component {
267- // static displayName = 'ReactComponent2';
268- // public static route = 'ReactComponent2';
269- // // new (props: {}, context?: any): React.Component<{}, any, any>
270- // render(): ReactNode {
271- // return (
272- // <View style={styleValues.containerColumn}>
273- // <View style={styleValues.containerRow}>
274- // <Text style={styleValues.textStyle}>UseName: </Text>
275- // </View>
276- // </View>
277- // );
278- // }
279- // };
280- // return ret;
281- // }
282-
283- // export const ReactComponent3: React.ComponentClass =
284- // LeafComponentScreenFactory8();
0 commit comments