Blame view

examples/routers/tag.vue 872 Bytes
382c000c   梁灏   Tag add type prop...
1
  <template>
456daf34   梁灏   support Tag
2
      <div>
dc39cc31   daiyanze   Feature: Checkabl...
3
4
          <Tag v-for="item in count" :key="item" :name="item" type="border" color="yellow" @on-close="close" @on-check="check" closable>标签{{ item + 1 }}</Tag>
          <Tag v-for="item in count" :key="item" :name="item" type="border" color="yellow" @on-close="close" @on-check="check" closable checkable>标签{{ 1 - item }}</Tag>
ec4117cb   梁灏   tag add prop: name
5
          <Button icon="ios-plus-empty" type="dashed" size="small" @click="count += 1">添加标签</Button>
456daf34   梁灏   support Tag
6
      </div>
382c000c   梁灏   Tag add type prop...
7
8
  </template>
  <script>
382c000c   梁灏   Tag add type prop...
9
      export default {
3e855e34   梁灏   fixed #46
10
11
          data () {
              return {
ec4117cb   梁灏   tag add prop: name
12
                  count: 3
dc39cc31   daiyanze   Feature: Checkabl...
13
              };
3c01d81a   梁灏   fixed Modal bug,w...
14
15
          },
          methods: {
ec4117cb   梁灏   tag add prop: name
16
17
18
              close (e, name) {
                  console.log(e);
                  console.log(name);
dc39cc31   daiyanze   Feature: Checkabl...
19
20
21
22
              },
              check (e, name) {
                  console.log(e);
                  console.log(name);
3e855e34   梁灏   fixed #46
23
24
              }
          }
dc39cc31   daiyanze   Feature: Checkabl...
25
      };
382c000c   梁灏   Tag add type prop...
26
  </script>