# QuantitySelector

Component with input to choose numeric values and describe quantity.

# Most common usage scenario

  <SfQuantitySelector v-model="value" :min="min" />

import { SfQuantitySelector } from "@storefront-ui/vue";

export default {
  components: {
  data() {
    return {
      value: 1,
      min: 1

# Props

  • qty

    • Quantity
    • type: number|string
    • defaultValue: 1
  • min

    • Minimum quantity
    • type: number
    • defaultValue: 1

# Slots


# Events

  • input

# CSS modifiers


# SCSS variables

$quantity-selector__width: 1.875rem !default;
$quantity-selector__height: 1.6875rem !default;
$quantity-selector__width-desktop: 3.125rem !default;

You can override SCSS variable values bound to this component in sfui.scss in the root of your project.

# Partials

If you want to customize this component even more you can use its partials for limitless customization.

<template lang="html" src="@storefront-ui/vue/src/components/atoms/SfQuantitySelector/SfQuantitySelector.html"></template>
<script src="@storefront-ui/vue/src/components/atoms/SfQuantitySelector/SfQuantitySelector.js"></script>
<style lang="scss">
@import "~@storefront-ui/shared/styles/components/SfQuantitySelector.scss";

You can read about using component partials here

# Play with this component

See all available configurations and play with this component on Storybook.