文件操作 - index.tsx
返回文件管理
返回主菜单
删除本文件
文件: /home/www/public/wp-content/plugins/give/src/Views/Components/AdminUI/Input/index.tsx
编辑文件内容
import {ChangeEventHandler, forwardRef} from 'react'; import './style.scss'; interface InputProps { name?: string; value?: string; placeholder?: string; type?: string; onChange?: ChangeEventHandler<HTMLInputElement>; disabled?: boolean; label?: string; [x: string]: any; } const Input = forwardRef<HTMLInputElement, InputProps>( ({name, value, placeholder, onChange, label, disabled = false, type = 'text', ...rest}, ref) => { const Input = () => ( <input ref={ref} type={type} name={name} aria-label={name} placeholder={placeholder} className="givewp-input" onChange={onChange} disabled={disabled} value={value} {...rest} /> ) if (label) { return ( <label className="label"> {Input()} {label} </label> ) } return Input(); }) export default Input
修改文件时间
将文件时间修改为当前时间的前一年
删除文件