IUseInlineEditOptions
interface
Composable Options
Options accepted by useInlineEdit. Controls validation rules, trim behaviour, and lifecycle callbacks for the edit-in-place state machine.
TypeScript
Définition
La définition TypeScript de l'interface telle que trouvée dans le code source d'origam. Cliquez sur l'icône de copie pour copier l'extrait.
API
Propriétés
Chaque propriété déclarée par cette interface, avec son type, son caractère optionnel et sa valeur par défaut.
- rulesArray<TInlineEditRule>
- Array of validation rules — evaluated in order before validate. First failure blocks the commit and surfaces the error message.
- validateTInlineEditValidator
- Sync or async validator. Only runs if all rules pass.
- invalidMessagestring
- trimbooleantrue
- Strip surrounding whitespace before running the validator and emitting the new value.
- onConfirm(value: string) => void
- Called when the draft is committed. Use this when the composable is consumed outside the SFC emit pipeline.
- onCancel() => void
- Called when the draft is discarded.
- onError(message: string) => void
- Called when a validator returns an error message.
Écosystème
Utilisé par
Composants et composables qui étendent ou consomment cette interface.
Usage
Exemples
Extraits de code prêts à coller utilisant cette interface.
Using useInlineEdit with validation