Tests
All checks were successful
Lint / lint (push) Successful in 11s

This commit is contained in:
Julien Valverdé
2025-08-07 22:29:52 +02:00
parent c158cdef19
commit 8e4bcfe59d

View File

@@ -1,16 +1,20 @@
import { TextField } from "@radix-ui/themes" import { TextField } from "@radix-ui/themes"
import { Effect } from "effect" import { Effect } from "effect"
import { Component } from "effect-fc" import { Component } from "effect-fc"
import { Hooks } from "effect-fc/hooks" import { useInput } from "effect-fc/hooks"
import { JSX } from "react" import { JSX } from "react"
export namespace TextInput { export namespace TextInput {
export interface Props<A, R> extends Hooks.useInput.Options<A, R>, TextField.RootProps {} export interface Props<A, R> extends useInput.Options<A, R>, TextField.RootProps {}
} }
export class TextInput extends Component.make(Effect.fnUntraced(function* TextInput <A, R>(props: TextInput.Props<A, R>) { export class TextInput extends Component.make(
Effect.fnUntraced(function* TextInput <A, R>(props: TextInput.Props<A, R>) {
const input = yield* useInput(props)
return <></> return <></>
})).pipe( })
).pipe(
Component.withFunctionComponentSignature<<A, R>(props: TextInput.Props<A, R>) => JSX.Element>() Component.withFunctionComponentSignature<<A, R>(props: TextInput.Props<A, R>) => JSX.Element>()
) {} ) {}
TextInput["~Error"]