balmjs / balm-ui

:diamonds: A modular and customizable UI library based on Material Design and Vue
https://material.balmjs.com
MIT License
505 stars 31 forks source link

Feature requests - inputs #97

Open siloam opened 2 years ago

siloam commented 2 years ago
  1. A way to provide masks for textfields
  2. A way to hide spinners (arrows) for number fields
elf-mouse commented 2 years ago

About request loading, I prefer to use global masks, like this:

<div>
  <app-layout>
    Your template
  </app-layout>
  <loading-layout v-if="$store.isLoading"></loading-layout>
</div>
siloam commented 2 years ago

I ment input masks. It's a way to control input. Sometimes formating and pre-validation of data is needed,

rodrigobraga commented 1 year ago

Hi guys, is it possible using something like maska with BalmUI?

rodrigobraga commented 1 year ago

@siloam @elf-mouse I am trying the sample below without success. Do you have any idea to solve this?

<template>

    <ui-textfield
      v-model="model"
      :attrs="{ 'v-maska': '', 'data-maska': '#####-###'}"
      required
      maxlength="9">
        Example
      </ui-textfield>

</template>

<script>

import { vMaska } from "maska"

export default {

  directives: { maska: vMaska },

  data () {
    return {
        model: null
    }
  }
}
</script>
elf-mouse commented 1 year ago

Hi @rodrigobraga , you can use maska like this:

rodrigobraga commented 1 year ago

@elf-mouse Thanks!