therufa / mdi-vue

Material design icons for vue.js
https://www.npmjs.com/package/mdi-vue
MIT License
88 stars 13 forks source link

Can't style icons with :class attribute #43

Closed robertfausk closed 3 years ago

robertfausk commented 4 years ago

I'm unable to style an icon by passing a :class to the component.

<template>
  <div>
    <circle-icon 
      :class="{'active': true}" 
    />
  </div>
</template>

The resulting <span> will not include "active".

This seems to be related to #30

TomerPacific commented 4 years ago

@therufa , I'd like to help (if it is still needed). Some guidance will be appreciated.

therufa commented 4 years ago

hi @TomerPacific , thanks for the interest in the project. The issue is rather small, so I believe that something like :class="data.staticClass || ''" is missing on the component template next to where attributes are bound to the component.

TomerPacific commented 3 years ago

@therufa , thanks for that clarification. I have made the change and have opened a PR.

Also, would you mind adding the hacktoberfest-accepted label to this issue and PR?