From 6cadeba44f0eccce5af738bf34626aa8c2a4152f Mon Sep 17 00:00:00 2001 From: 梁灏 Date: Thu, 9 Mar 2017 22:21:54 +0800 Subject: [PATCH] support Message --- CHANGE.md | 7 ++++++- README.md | 2 +- examples/app.vue | 1 + examples/main.js | 4 ++++ examples/routers/message.vue | 44 ++++++++++---------------------------------- src/components/base/notification/index.js | 4 ++-- src/components/base/notification/notice.vue | 24 +++++++++++++----------- src/components/base/notification/notification.vue | 23 +++++++++++++---------- src/components/message/index.js | 10 +++++----- src/components/table/table-body.vue | 1 + src/index.js | 6 +++--- 11 files changed, 59 insertions(+), 67 deletions(-) diff --git a/CHANGE.md b/CHANGE.md index d71c88c..8e98294 100644 --- a/CHANGE.md +++ b/CHANGE.md @@ -50,4 +50,9 @@ class 改为 className ### LoadingBar 部分 prop 移至 data ### Modal -visible 改为 value,使用 v-model,style 改为 styles,$Modal 的关闭有改动,建议后面在纯 html 模式下测试 \ No newline at end of file +visible 改为 value,使用 v-model,style 改为 styles,$Modal 的关闭有改动,建议后面在纯 html 模式下测试 +### Table +i-table 改为 Table +### Message +notice.vue 的 key 改为了 name,style 改为 styles +notification.vue 的 key 改为了 name,style 改为 styles \ No newline at end of file diff --git a/README.md b/README.md index db181d4..f6e26f7 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,7 @@ - [x] Form - [x] Alert - [x] Card -- [ ] Message +- [x] Message - [ ] Notice - [x] Modal - [x] Progress diff --git a/examples/app.vue b/examples/app.vue index aee4fbe..f823786 100644 --- a/examples/app.vue +++ b/examples/app.vue @@ -52,6 +52,7 @@ li + li { border-left: solid 1px #bbb; padding-left: 10px; margin-left: 10px; }
  • Table
  • LoadingBar
  • Modal
  • +
  • Message
  • diff --git a/examples/main.js b/examples/main.js index 1971bf5..6e71b73 100644 --- a/examples/main.js +++ b/examples/main.js @@ -172,6 +172,10 @@ const router = new VueRouter({ { path: '/modal', component: require('./routers/modal.vue') + }, + { + path: '/message', + component: require('./routers/message.vue') } ] }); diff --git a/examples/routers/message.vue b/examples/routers/message.vue index 012292c..1112b0f 100644 --- a/examples/routers/message.vue +++ b/examples/routers/message.vue @@ -1,44 +1,20 @@ diff --git a/src/components/base/notification/index.js b/src/components/base/notification/index.js index 2bd5c4b..4193c0e 100644 --- a/src/components/base/notification/index.js +++ b/src/components/base/notification/index.js @@ -24,8 +24,8 @@ Notification.newInstance = properties => { notice (noticeProps) { notification.add(noticeProps); }, - remove (key) { - notification.close(key); + remove (name) { + notification.close(name); }, component: notification, destroy () { diff --git a/src/components/base/notification/notice.vue b/src/components/base/notification/notice.vue index c360afc..7739662 100644 --- a/src/components/base/notification/notice.vue +++ b/src/components/base/notification/notice.vue @@ -1,10 +1,12 @@