evui 2.1.2 → 2.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/2.evui.min.js +1 -1
- package/dist/3.evui.min.js +1 -1
- package/dist/4.evui.min.js +1 -1
- package/dist/evui.min.js +2 -2
- package/dist/evui.min.js.gz +0 -0
- package/dist/evui.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/message-box/index.js +6 -2
- package/src/components/message-box/message-box.js +7 -6
- package/src/components/message-box/message-box.vue +0 -8
- package/src/index.js +5 -2
package/package.json
CHANGED
|
@@ -1,13 +1,8 @@
|
|
|
1
1
|
import Vue from 'vue';
|
|
2
2
|
import MessageBoxVue from './message-box.vue';
|
|
3
3
|
|
|
4
|
-
const MsgVue = Vue.extend(MessageBoxVue);
|
|
5
|
-
|
|
6
|
-
const root = document.createElement('div');
|
|
7
|
-
root.classList.add('ev-message-box-root');
|
|
8
|
-
document.body.appendChild(root);
|
|
9
|
-
|
|
10
4
|
let instance;
|
|
5
|
+
|
|
11
6
|
export default function messageBox(options = {}) {
|
|
12
7
|
const dataOptions = Object.assign(
|
|
13
8
|
{
|
|
@@ -20,12 +15,18 @@ export default function messageBox(options = {}) {
|
|
|
20
15
|
);
|
|
21
16
|
|
|
22
17
|
if (!instance) {
|
|
18
|
+
const MsgVue = Vue.extend(MessageBoxVue);
|
|
23
19
|
instance = new MsgVue({
|
|
24
20
|
data: dataOptions,
|
|
25
21
|
});
|
|
26
22
|
instance.$mount();
|
|
23
|
+
|
|
24
|
+
const root = document.createElement('div');
|
|
25
|
+
root.classList.add('ev-message-box-root');
|
|
26
|
+
document.body.appendChild(root);
|
|
27
27
|
root.appendChild(instance.$el);
|
|
28
28
|
}
|
|
29
|
+
|
|
29
30
|
Object.assign(instance._data, dataOptions);
|
|
30
31
|
instance.visible = true;
|
|
31
32
|
}
|
|
@@ -73,15 +73,7 @@
|
|
|
73
73
|
</template>
|
|
74
74
|
|
|
75
75
|
<script type="text/babel">
|
|
76
|
-
import EvButton from '@/components/button/button';
|
|
77
|
-
import EvIcon from '@/components/icon/icon';
|
|
78
|
-
|
|
79
76
|
export default {
|
|
80
|
-
name: 'EvMessageBox',
|
|
81
|
-
components: {
|
|
82
|
-
EvButton,
|
|
83
|
-
EvIcon,
|
|
84
|
-
},
|
|
85
77
|
data() {
|
|
86
78
|
return {
|
|
87
79
|
type: 'info',
|
package/src/index.js
CHANGED
|
@@ -27,7 +27,10 @@ import EvMarkdown from './components/markdown';
|
|
|
27
27
|
import EvGrid from './components/grid/grid';
|
|
28
28
|
import EvMessage from './components/message/index';
|
|
29
29
|
import EvNotification from './components/notification/index';
|
|
30
|
-
import
|
|
30
|
+
import {
|
|
31
|
+
MessageBox as EvMessageBox,
|
|
32
|
+
MessageBoxFn,
|
|
33
|
+
} from './components/message-box/index';
|
|
31
34
|
|
|
32
35
|
const components = {
|
|
33
36
|
EvButton,
|
|
@@ -76,7 +79,7 @@ const install = function (Vue) {
|
|
|
76
79
|
});
|
|
77
80
|
|
|
78
81
|
Vue.prototype.$message = EvMessage;
|
|
79
|
-
Vue.prototype.$messagebox =
|
|
82
|
+
Vue.prototype.$messagebox = MessageBoxFn;
|
|
80
83
|
Vue.prototype.$notify = EvNotification;
|
|
81
84
|
};
|
|
82
85
|
|