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

fix(VFileInput): use internalArrayValue #8371

Merged
merged 2 commits into from
Aug 8, 2019
Merged

Conversation

MajesticPotatoe
Copy link
Member

Description

Fix for v-file-input error: this.internalValue.forEach is not a function when using selection slot without the multiple prop

Motivation and Context

fixes #8351

How Has This Been Tested?

visually

Markup:

<template>
  <v-container grid-list-md>
    <v-file-input
      v-model="files"
      label="Single File"
      placeholder="Select File"
      outlined
    >
      <template v-slot:selection="{ text }">
        <v-chip
          label
          small
        >
          {{ text }}
        </v-chip>
      </template>
    </v-file-input>
    <v-file-input
      v-model="filesMultiple"
      label="Multiple Files"
      placeholder="Select Files"
      outlined
      multiple
    >
      <template v-slot:selection="{ text }">
        <v-chip
          label
          small
        >
          {{ text }}
        </v-chip>
      </template>
    </v-file-input>
  </v-container>
</template>

<script>
  export default {
    data: () => ({
      files: null,
      filesMultiple: [],
    }),
  }
</script>

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Improvement/refactoring (non-breaking change that doesn't add any features but makes things better)

Checklist:

  • The PR title is no longer than 64 characters.
  • The PR is submitted to the correct branch (master for bug fixes and documentation updates, dev for new features and breaking changes).
  • My code follows the code style of this project.
  • I've added relevant changes to the documentation (applies to new features and breaking changes in core library)
  • I've added new examples to the kitchen (applies to new features and breaking changes in core library)

@dsseng dsseng merged commit 359125d into master Aug 8, 2019
@dsseng dsseng deleted the fix/file-input-#8351 branch August 8, 2019 04:53
@lock lock bot locked as resolved and limited conversation to collaborators Sep 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug Report] File inputs component does not support Named Slots
2 participants