todo: textfield, 但是不是 textarea 而是自定义的输入框

This commit is contained in:
CrescentLeaf
2025-11-21 22:34:27 +08:00
parent cbdccfb5a7
commit 095b454539

View File

@@ -0,0 +1,18 @@
import * as React from 'react'
import { $, TextField } from "mdui"
interface Args extends React.HTMLAttributes<TextField & HTMLElement> {
}
export default function TextFieldCustom({ ...prop }: Args) {
// deno-lint-ignore no-explicit-any
const textField = React.useRef<any>(null)
React.useEffect(() => {
const shadow = (textField.current as TextField).shadowRoot
// $(shadow).find('textarea')
})
return <mdui-text-field {...prop} ref={textField}></mdui-text-field>
}