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

[Bug Report][3.3.10] When setting Blueprints, the v-btn text color is the same as the v-app-bar color so that the text or icon cannot be seen. #17883

Closed
regchiu opened this issue Jul 27, 2023 · 4 comments
Assignees
Labels
E: blueprints T: bug Functionality that does not work as intended/expected
Milestone

Comments

@regchiu
Copy link

regchiu commented Jul 27, 2023

Environment

Vuetify Version: 3.3.10
Vue Version: 3.3.4
Browsers: Chrome 114.0.0.0
OS: Mac OS 10.15.7

Steps to reproduce

  1. Apply Blueprints.
  2. v-app-bar set color="primary" then add v-btn to v-app-bar slot.

Expected Behavior

The v-btn content should be visible.

Actual Behavior

The v-btn content is not visible.

Reproduction Link

https://play.vuetifyjs.com/#...

@regchiu regchiu changed the title [Bug Report][3.3.10] In Material Design 3, the v-btn text color is the same as the v-app-bar color so that the text or icon cannot be seen. [Bug Report][3.3.10] In Material Design 1/2/3, the v-btn text color is the same as the v-app-bar color so that the text or icon cannot be seen. Jul 27, 2023
@regchiu regchiu changed the title [Bug Report][3.3.10] In Material Design 1/2/3, the v-btn text color is the same as the v-app-bar color so that the text or icon cannot be seen. [Bug Report][3.3.10] When setting Blueprints, the v-btn text color is the same as the v-app-bar color so that the text or icon cannot be seen. Jul 27, 2023
@websitevirtuoso
Copy link
Contributor

=)))

Everything working.
By default v-btn doesn't have any color and this is expected behavour in vuetify3.
here working example

<template>
  <v-app>
    <v-app-bar color="primary" title="App bar">
      <template #append>
        <v-avatar>
          <v-avatar color="white">
            <span class="text-h5">LY</span>
          </v-avatar>
        </v-avatar>
        <span class="pa-4 text-subtitle-1">Levi Yeh</span>
        <v-btn color="teal" icon="mdi-dots-vertical"></v-btn>
      </template>
    </v-app-bar>
  </v-app>
</template>

<script setup>
  import { ref } from 'vue'

  const msg = ref('Hello World!')
</script>

Set color to your v-btn

In my project I had the same issue and fixed it via config we can pass default values

defaults: {
    VInput: {
      variant: 'outlined',
      density: 'compact',
    },
    VTextField: {
      variant: 'outlined',
      density: 'compact',
    },
    VTextFieldMini: {
      variant: 'outlined',
      density: 'compact',
      VInput: {
        VField: {
          style: [{ '--v-field-input-padding-top': '8px', '--v-field-padding-bottom': 0 }],
        },
      },
    },
    VSelect: {
      variant: 'outlined',
      density: 'compact',
    },
    VAutocomplete: {
      variant: 'outlined',
      density: 'compact',
    },
    VCombobox: {
      variant: 'outlined',
      density: 'compact',
      VChip: {
        density: 'comfortable',
      },
    },
    VTextarea: {
      variant: 'outlined',
    },
    VCheckbox: {
      color: 'primary',
    },
    VPagination: {
      color: 'primary',
    },
    VCard: { elevation: '3' },
    VCardActions: { VBtn: { variant: 'flat' } },
  },

@websitevirtuoso
Copy link
Contributor

I hope it will help. so this can be closed

@KaelWD KaelWD added T: bug Functionality that does not work as intended/expected E: blueprints labels Jul 27, 2023
@KaelWD KaelWD added this to the v3.3.x milestone Jul 27, 2023
@KaelWD KaelWD self-assigned this Jul 27, 2023
@KaelWD KaelWD closed this as completed in dfbf561 Jul 27, 2023
@colewerner
Copy link

colewerner commented Jan 28, 2024

Fwiw the background colors in my v-btn inside of a v-app-bar weren't working the same way that they did in vuetify 2 and I had to change it from:

<v-btn color="white" class="text-primary"

to

<v-btn class="text-primary bg-white"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E: blueprints T: bug Functionality that does not work as intended/expected
Projects
None yet
Development

No branches or pull requests

4 participants