zydx-plus 1.0.4 → 1.0.6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zydx-plus",
3
- "version": "1.0.4",
3
+ "version": "1.0.6",
4
4
  "description": "Vue.js",
5
5
  "main": "src/index.js",
6
6
  "files": [
@@ -20,7 +20,7 @@
20
20
  "license": "MIT",
21
21
  "author": "",
22
22
  "peerDependencies": {
23
- "vue": "^2.5.17"
23
+ "vue": "^3.2.13"
24
24
  },
25
25
  "devDependencies": {
26
26
  "@vue/component-compiler-utils": "^2.6.0",
@@ -6,13 +6,16 @@
6
6
  <div class="tip-title">{{ title }}</div>
7
7
  </div>
8
8
  <div class="tip-boxContent">
9
- <div>
10
- <div class="tip-title2" :style="{'text-align': (middle)? 'center': 'left' }">{{ promptContent }}</div>
9
+ <div class="tap-p">
10
+ <div class="tip-title2" v-if="type === 'text'" :style="{'text-align': (middle)? 'center': 'left' }" v-html="promptContent"></div>
11
+ <div class="tip-img" v-if="type === 'img'">
12
+ <img :src="url" />
13
+ </div>
11
14
  </div>
12
15
  </div>
13
16
  <div class="tip-btnBox">
14
17
  <div @click="submit">确认</div>
15
- <div @click="cancel">取消</div>
18
+ <div v-if="cancelShow" @click="cancel">取消</div>
16
19
  </div>
17
20
  </div>
18
21
  </div>
@@ -23,6 +26,14 @@
23
26
  export default {
24
27
  name: 'zydx-tip-box',
25
28
  props: {
29
+ type: { // 弹窗的提示标题
30
+ type: String,
31
+ default: 'text'
32
+ },
33
+ url: { // 弹窗的提示标题
34
+ type: String,
35
+ default: ''
36
+ },
26
37
  title: { // 弹窗的提示标题
27
38
  type: String,
28
39
  default: '提示'
@@ -34,6 +45,10 @@ export default {
34
45
  middle: { // 弹窗中间的文字内容是居中 还是居左 默认居中
35
46
  type: Boolean,
36
47
  default: true
48
+ },
49
+ cancelShow: {
50
+ type: Boolean,
51
+ default: true
37
52
  }
38
53
  },
39
54
  data () {
@@ -75,3 +75,13 @@ font-size: 12px;
75
75
  padding-left: 2px;
76
76
  margin-left: -10px!important;
77
77
  }
78
+ .tap-p{
79
+ text-align: center;
80
+ }
81
+ .tip-img{
82
+ width: 70%;
83
+ display: inline-block;
84
+ }
85
+ .tip-img>img{
86
+ width: 100%;
87
+ }
package/src/index.js CHANGED
@@ -15,7 +15,7 @@ if (typeof window !== 'undefined' && window.Vue) {
15
15
  }
16
16
 
17
17
  export default {
18
- version: '1.0.4',
18
+ version: '1.0.6',
19
19
  install,
20
20
  tipBox
21
21
  };