antoniandre / wave-ui

A UI framework for Vue.js 3 (and 2) with only the bright side. ☀️
https://antoniandre.github.io/wave-ui
MIT License
549 stars 40 forks source link

Handles on sliders are huge. #98

Closed SerbianLastName closed 1 year ago

SerbianLastName commented 1 year ago

Handles on sliders are huge. 2022-12-15 (4)

Hard at work on a super important project, but for some reason the handles on my sliders are huge.

Not sure what's going on.

antoniandre commented 1 year ago

Not sure what's going on on your screenshot. I don't think you need to share the content of your project. But if you want some help please share at least your code and a reproduction example with some decent content so I can help you. Also that looks like a CSS override. Btw, you can easily create a reproduction example with the edit on Codepen button.

SerbianLastName commented 1 year ago

Only CSS I'm using is whatever is auto-generated with a new Vite/Vue project.

:root {
  font-family: Inter, Avenir, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;

  color-scheme: light;
  color: #064475;
  background-color: #ffffff;

  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}

a {
  font-weight: 500;
  color: #646cff;
  text-decoration: inherit;
}
a:hover {
  color: #535bf2;
}

body {
  margin: 0;
  display: flex;
  place-items: center;
  min-width: 320px;
  min-height: 100vh;
}

h1 {
  font-size: 3.2em;
  line-height: 1.1;
}

button {
  border-radius: 8px;
  border: 1px solid transparent;
  padding: 0.6em 1.2em;
  font-size: 1em;
  font-weight: 500;
  font-family: inherit;
  background-color: #1a1a1a;
  cursor: pointer;
  transition: border-color 0.25s;
}
button:hover {
  border-color: #646cff;
}
button:focus,
button:focus-visible {
  outline: 4px auto -webkit-focus-ring-color;
}

.card {
  padding: 2em;
}

#app {
  max-width: 1280px;
  margin: 0 auto;
  padding: 2rem;
  text-align: center;
}

@media (prefers-color-scheme: light) {
  :root {
    color: #213547;
    background-color: #ffffff;
  }
  a:hover {
    color: #747bff;
  }
  button {
    background-color: #f9f9f9;
  }
}

<w-slider v-model="my.model" :min="400" :max="1000" label-left="Label Name" />

Any variation of the w-slider ends up with huge handles. It doesn't matter where the sliders are (in a flexbox, in a card, all by itself, etc) or what settings I'm using, handles are always huge.

antoniandre commented 1 year ago

I can't reproduce in documentation or in all the external demos Codepen, Stackblitz, other projects. The problem may come from something in your particular project. Please reopen with a testable demo if not solved. Thanks

lcsd commented 11 months ago

Dear Antoni, same problem here BUT I found a WorkAround.
The size of the w-slider thumb-button is controlled by the button class is this sample CSS auto-generated with all new Vite/Vue project:
Somehow, this button {... font-size: 1em; ...} is cascading into de w-slider
I simply put in the not scoped style clouse in my App.vue main SFC and this controls the size of the thumb-button
...
Hope to hear from you soon with a better solution. Hugs, Luiz.