diff --git "a/\346\233\276\345\251\267/6.4day Vue\344\272\213\344\273\266\345\244\204\347\220\206.md" "b/\346\233\276\345\251\267/6.4day Vue\344\272\213\344\273\266\345\244\204\347\220\206.md" new file mode 100644 index 0000000000000000000000000000000000000000..4e69820c84d05f8434525897cc82f625883ea526 --- /dev/null +++ "b/\346\233\276\345\251\267/6.4day Vue\344\272\213\344\273\266\345\244\204\347\220\206.md" @@ -0,0 +1,44 @@ +# 事件处理 +## 监听事件(v-on) +![](./img/26.png) +![](./img/27.png) + +## 事件处理方法(v-on) +``` +v-on接受一个需要调用的方法, 得在 methods 对象中定义方法 +``` +![](./img/28.png) + +## 内联处理器中的方法 +![](./img/29.png) + +## 事件修饰符 +``` +.stop +.prevent +.capture +.self +.once +.passive + + + + +
+ + + + + +
+ + + +
...
+ + + +
...
+‼v-on:click.prevent.self 会阻止所有的点击,而 v-on:click.self.prevent 只会阻止对元素自身的点击。 +``` + diff --git "a/\346\233\276\345\251\267/6.5day \350\241\250\345\215\225\350\276\223\345\205\245\347\273\221\345\256\232and\345\234\250\347\273\204\344\273\266\344\270\212\344\275\277\347\224\250v-model.md" "b/\346\233\276\345\251\267/6.5day \350\241\250\345\215\225\350\276\223\345\205\245\347\273\221\345\256\232and\345\234\250\347\273\204\344\273\266\344\270\212\344\275\277\347\224\250v-model.md" new file mode 100644 index 0000000000000000000000000000000000000000..4f59096ecde56d53c89d829e4c6350cf09cf394f --- /dev/null +++ "b/\346\233\276\345\251\267/6.5day \350\241\250\345\215\225\350\276\223\345\205\245\347\273\221\345\256\232and\345\234\250\347\273\204\344\273\266\344\270\212\344\275\277\347\224\250v-model.md" @@ -0,0 +1,17 @@ +# 表单输入绑定 +## 文本框输入绑定 +![](./img/30.png) + +## 文本域输入绑定 +![](./img/31.png) + +## 复选框 +![](./img/32.png) +![](./img/33.png) + +``` +多个复选框绑定到用一个数组 +``` +![](./img/33.png) +![](./img/34.png) + diff --git "a/\346\233\276\345\251\267/img/26.png" "b/\346\233\276\345\251\267/img/26.png" new file mode 100644 index 0000000000000000000000000000000000000000..4bfe3c8a71fac682fd759a109e4deef73d0216c6 Binary files /dev/null and "b/\346\233\276\345\251\267/img/26.png" differ diff --git "a/\346\233\276\345\251\267/img/27.png" "b/\346\233\276\345\251\267/img/27.png" new file mode 100644 index 0000000000000000000000000000000000000000..454a6d7dc4a15d2e299270bab9616dc2eb977ea8 Binary files /dev/null and "b/\346\233\276\345\251\267/img/27.png" differ diff --git "a/\346\233\276\345\251\267/img/28.png" "b/\346\233\276\345\251\267/img/28.png" new file mode 100644 index 0000000000000000000000000000000000000000..7031e49051d387568c70015b9b6624d8dc2cd778 Binary files /dev/null and "b/\346\233\276\345\251\267/img/28.png" differ diff --git "a/\346\233\276\345\251\267/img/29.png" "b/\346\233\276\345\251\267/img/29.png" new file mode 100644 index 0000000000000000000000000000000000000000..b829af9382df2d72040062b5e40cf1e5a66034e4 Binary files /dev/null and "b/\346\233\276\345\251\267/img/29.png" differ diff --git "a/\346\233\276\345\251\267/img/30.png" "b/\346\233\276\345\251\267/img/30.png" new file mode 100644 index 0000000000000000000000000000000000000000..f0c5e1afcbfdfdaaf3fa3d43d47d993e4c65f49b Binary files /dev/null and "b/\346\233\276\345\251\267/img/30.png" differ diff --git "a/\346\233\276\345\251\267/img/31.png" "b/\346\233\276\345\251\267/img/31.png" new file mode 100644 index 0000000000000000000000000000000000000000..d8b95a6e856b6cdd1fbd28a2d50f9caa167e9b04 Binary files /dev/null and "b/\346\233\276\345\251\267/img/31.png" differ diff --git "a/\346\233\276\345\251\267/img/32.png" "b/\346\233\276\345\251\267/img/32.png" new file mode 100644 index 0000000000000000000000000000000000000000..a0495dae0223d30fda099848c6793fb927f6dda3 Binary files /dev/null and "b/\346\233\276\345\251\267/img/32.png" differ diff --git "a/\346\233\276\345\251\267/img/33.png" "b/\346\233\276\345\251\267/img/33.png" new file mode 100644 index 0000000000000000000000000000000000000000..c19aa034452534d08ff341de81fb3b2e51fe7a4c Binary files /dev/null and "b/\346\233\276\345\251\267/img/33.png" differ diff --git "a/\346\233\276\345\251\267/img/34.png" "b/\346\233\276\345\251\267/img/34.png" new file mode 100644 index 0000000000000000000000000000000000000000..eebd5c5aac6b2c13f604e6c315625ece8efcf233 Binary files /dev/null and "b/\346\233\276\345\251\267/img/34.png" differ diff --git "a/\346\233\276\345\251\267/img/35.png" "b/\346\233\276\345\251\267/img/35.png" new file mode 100644 index 0000000000000000000000000000000000000000..9ef239708c45e92cc076f5acad9bd036c4b5bda7 Binary files /dev/null and "b/\346\233\276\345\251\267/img/35.png" differ diff --git "a/\346\233\276\345\251\267/index.html" "b/\346\233\276\345\251\267/index.html" deleted file mode 100644 index 3f282b8ee645e2390de77ddfa70abe4b4a6811a6..0000000000000000000000000000000000000000 --- "a/\346\233\276\345\251\267/index.html" +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - Vue实例 - - - - -
- - - -
- - - - - - \ No newline at end of file