Skip to content

PascalHesselink/vue-timeout-button

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TimeoutButton

Vue timeout button

example

Installation

npm install vue-timeout-button
import VueTimeoutButton from 'vue-timeout-button';

Vue.use(VueTimeoutButton);

Examples

Simple:

<TimeoutButton class="red-button"
               @click="submitButton"
               duration="2">
      Submit
</TimeoutButton>

Advanced:

<TimeoutButton class="red-button"
               @click="submitButton"
               @interrupting="clickedWhile"
               @completed="buttonCompleted"
               duration="3.5"
               loading-text="Loading...">
      Submit
</TimeoutButton>

Example style of the button

.red-button {
    padding          : 24px 24px;
    background-color : #e74c3c;
    color            : #fff;
    font-weight      : 700;
    width            : 200px;
    text-align       : center;
}

.red-button:focus {
    outline : none;
}

.red-button.loading {
    cursor : default;
}

Badges


pascalhesselink.nl  ·  GitHub PascalHesselink

About

TimeoutButton component for Vue

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published