Page MenuHomePhabricator

TextArea: Set up value prop via v-model
Closed, ResolvedPublic


This task covers using v-model to allow the parent component to pass in a value for the TextArea, which will be automatically updated when the user changes the value within the <textarea> element.

Check out:

  • Vue docs on v-model
  • This article that inspired our solution for managing data passed between parent and child components

Acceptance criteria

  • A new modelValue prop has been added to the TextArea component (see TextInput.vue for an example)
  • The TextAreaDemo has been updated to set up a value ref, pass it into the TextArea component, and display the dynamic value (see TextInputDemo for an example)

Related Objects

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
AnneT changed the task status from Open to In Progress.Apr 5 2023, 3:07 PM
AnneT assigned this task to lwatson.
Restricted Application triaged this task as High priority. · View Herald TranscriptApr 5 2023, 3:07 PM

Change 906633 had a related patch set uploaded (by LWatson; author: LWatson):

[design/codex@main] TextArea: Set up value prop via v-model

Change 906633 merged by jenkins-bot:

[design/codex@main] TextArea: Set up modelValue prop via v-model

lwatson updated the task description. (Show Details)

Change 907988 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/core@master] Update Codex from v0.8.0 to v0.9.0

Change 907988 merged by jenkins-bot:

[mediawiki/core@master] Update Codex from v0.8.0 to v0.9.0

Test wiki created on Patch demo by KHarlan (WMF) using patch(es) linked to this task: