Browse Source

Merge branch 'test' of https://git.yishihui.com/DeNet/de-net into test

zhangwei 3 years ago
parent
commit
ce57f4ab3d
1 changed files with 5 additions and 2 deletions
  1. 5 2
      src/view/components/give-dialog.vue

+ 5 - 2
src/view/components/give-dialog.vue

@@ -509,9 +509,12 @@ const selectCurrency = (params) => {
 
 const calcDomZoom = () => {
     nextTick(() => {
+        let maxWidth = 68;
         var textWidth = document.querySelector('.text').offsetWidth;
-        var scale = 68 / textWidth;
-        document.querySelector('.text').style.zoom = scale;
+        if(textWidth > 68) {
+            var scale = maxWidth / textWidth;
+            document.querySelector('.text').style.zoom = scale;
+        }
     }) 
 }