소스 검색

MessageBox: swap 'message' and 'title' when called with 'this.$msgbox' (#1067)

杨奕 8 년 전
부모
커밋
238f8625b1
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      packages/message-box/src/main.js

+ 2 - 2
packages/message-box/src/main.js

@@ -109,10 +109,10 @@ const showNextMsg = () => {
 const MessageBox = function(options, callback) {
   if (typeof options === 'string') {
     options = {
-      title: options
+      message: options
     };
     if (arguments[1]) {
-      options.message = arguments[1];
+      options.title = arguments[1];
     }
     if (arguments[2]) {
       options.type = arguments[2];