nb-button-prev-next
This is a prev/next button component for Vue.js 3+.
Look at the console to see the triggered event
Installation
Yarn
yarn add @vlalg-nimbus/nb-buttons
Usage
Vue 3
import { createApp } from 'vue'
import App from './App.vue'
import NbButtonsComponents from '@vlalg-nimbus/nb-buttons'
import "@vlalg-nimbus/nb-buttons/dist/style.css";
const app = createApp(App)
app.use(NbButtonsComponents)
app.mount('#app')
To use, simply call the component, in this case it will be NbButtonPrevNext or nb-button-prev-next.
Mode 1
<template>
  <NbButtonPrevNext />
</template>
Preview & Playground
Select the component you want to edit/test
Loading Sandbox...
Props
Items with an (*) mean they are required
| name | Value type | Default | Description | 
|---|---|---|---|
| nbId (*) | String | Sets the id attribute to differentiate from other components | |
| colorPrimary | String | 'tomato' | Defines the primary color (background). Accepts Color name and Hex | 
| colorSecondary | String | 'blue' | Defines the secondary color (background). Accepts Color name and Hex | 
| textColor | String | '#ffffff' | Defines the text color. Accepts Color name and Hex | 
| textColorHover | String | 'yellow' | Defines the text color on hover. Accepts Color name and Hex | 
| paddingX | Number | 1 | Defines button content padding-left and padding-right. | 
| paddingY | Number | 10 | Defines button content padding-top and padding-button. | 
| marginBetween | Number | 2 | Defines margin between buttons. | 
| borderRadius | Number | 6 | Defines border-radius. | 
| disabled | Boolean | false | Defines if the button is disabled | 
| showPreview | Boolean | true | Defines if show the preview button | 
| showNext | Boolean | true | Defines if show the next button | 
| disabledPreview | Boolean | false | Defines if the preview button is disabled | 
| disabledNext | Boolean | false | Defines if the next button is disabled | 
| fontFamily | String | "'Lato', sans-serif" | Defines the font-family | 
| fontSize | String | '1.6em' | Defines the font-size | 
| fontWeight | Number | 400 | Defines the font-weight | 
Events
| name | Return type | Description | 
|---|---|---|
| clicked | nothing | Fired when the button is clicked, returns nothing. | 
Slot
The component has a slot called content where the content that will be manipulated must be passed. It has a default text (Default Text) in case the content does not pass through the slot.
<template>
  <NbButtonPrevNext
    :nb-id="'nb-button-prev-next-one'"
    :display="'b'"
  >
    <template #text>
      Default Text
    </template>
  </NbButtonPrevNext>
</template>
Table of Contents
