Start sharing components as a team!Share components as a team!Join Bit to build your applications faster.Get Started Free

step

v1.1.32arrow_drop_down
v1.1.32
STATUS
Passing
DOWNLOADS
25
LICENSE
MIT
VISIBILITY
Public
PUBLISHED
A year ago
SIZE
969 B
1 contributor
Install step as a package?
Copied
npm i @bit/myliang.fish-ui.step
Set Bit as a scoped registryLearn more
npm config set '@bit:registry' https://node.bit.dev
Files
Step.vue
40 Lines(40 sloc)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<template>
  <div :class="classObject">
    <i :class="iClassObject">{{ this.icon ? '' : index }}</i>
    <div class="content">
      <div class="title">{{ title }}</div>
      <div class="description" v-if="description">{{ description }}</div>
    </div>
  </div>
</template>
<script>
  export default {
    name: 'fish-step',
    props: {
      icon: { type: String },
      title: { type: String, required: true },
      description: { type: String },
      active: { type: Boolean, default: false },
      disabled: { type: Boolean, default: false }
    },
    data () {
      return {
        index: 9
      }
    },
    computed: {
      classObject () {
        return [
          'fish step',
          { 'active': this.active },
          { 'disabled': this.disabled }
        ]
      },
      iClassObject () {
        return [
          this.icon ? 'icon ' + this.icon : ''
        ]
      }
    }
  }
</script>