Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Slot placeholder for VTextarea #20886

Open
frederikheld opened this issue Jan 20, 2025 · 0 comments
Open

[Feature Request] Slot placeholder for VTextarea #20886

frederikheld opened this issue Jan 20, 2025 · 0 comments

Comments

@frederikheld
Copy link
Contributor

Problem to solve

v-textarea has a template slot for label which is useful to customize the label.

My current use case is to have a smooth transition if the label changes based on previous user input:

<v-textarea v-model="inputMessage">
  <template #label>
    <v-fade-transition mode="out-in">
      <div :key="inputMessageLabel">{{ inputMessageLabel }}</div>
    </v-fade-transition>
  </template>
</v-textarea>

inputMessageLabel changes based on previous user input.

This is cool, but that type of changing message would better be placed as a placeholder. Unfortunately I can't use a transition in the placeholder like I'm doing here, because there's no slot for it.

Proposed solution

Have a slot for placeholder that works analog to the slot for label

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants