Browse Source

docs: 文档修改

Ymm0008 3 years ago
parent
commit
53d0312b30

+ 2 - 4
src/packages/__VUE/collapse/demo.vue

@@ -124,10 +124,6 @@ const initTranslate = () =>
     }
   });
 export default createDemo({
-  components: {
-    Notice,
-    Follow
-  },
   setup(props, context) {
     initTranslate();
     const data = reactive({
@@ -146,6 +142,8 @@ export default createDemo({
       console.log(`点击了name是${name}的面板`);
     };
     return {
+      Notice,
+      Follow,
       translate,
       change,
       ...toRefs(data)

+ 2 - 4
src/packages/__VUE/collapse/doc.en-US.md

@@ -127,10 +127,6 @@ Set custom icons through icon and rotate to set the rotation angle of icons
 import { reactive, ref, toRefs } from 'vue';
 import { Notice, Follow } from '@nutui/icons-vue';
 export default {
-  components: {
-    Notice,
-    Follow
-  },
   setup() {
     const activeName = ref(1);
     const title = reactive({
@@ -140,6 +136,8 @@ export default {
     return {
       activeName,
       ...toRefs(title),
+      Notice,
+      Follow
     };
   }
 }

+ 2 - 4
src/packages/__VUE/collapse/doc.md

@@ -126,10 +126,6 @@ export default {
 import { reactive, ref, toRefs } from 'vue';
 import { Notice, Follow } from '@nutui/icons-vue';
 export default {
-  components: {
-    Notice,
-    Follow
-  },
   setup() {
     const activeName = ref(1);
     const title = reactive({
@@ -139,6 +135,8 @@ export default {
     return {
       activeName,
       ...toRefs(title),
+      Notice,
+      Follow
     };
   }
 }