reeshuai opened a new issue #16780:
URL: https://github.com/apache/echarts/issues/16780


   ### Version
   
   5.3.1
   
   ### Link to Minimal Reproduction
   
   _No response_
   
   ### Steps to Reproduce
   
   1. we use vue2 and echarts5.3.1.
   2.  echarts options:
      option: {
           tooltip: {
             trigger: 'item'
           },
           legend: {
             left: 'center',
             bottom: '2%',
             icon: 'circle',
             itemGap: 10,
             orient: 'horizontal',
             formatter: function (name) {
               const str = name.split(' ')
               return str[0] + ':¥' + str[1]
             }
           },
           series: [
             {
               top: 'middle',
               left: 'center',
               type: 'pie',
               radius: ['20%', '40%'],
               width: 390,
               height: 390,
               itemStyle: {
                 borderRadius: 0,
                 borderColor: '#fff',
                 borderWidth: 1
               },
               label: {
                 show: true,
                 color: '#404040',
                 fontWeight: 400,
                 fontFamily: 'PinFangSC',
                 fontSize: 14,
                 formatter: (item) => {
                   return item.name.split(' ')[0]
                 }
               },
               labelLine: {
                 show: true,
                 length: 15,
                 length2: 10
               },
               emphasis: {
                 scale: true,
                 scaleSize: 10,
                 itemStyle: {
                   shadowBlur: 10,
                   shadowOffsetX: 0,
                   shadowColor: 'rgba(0, 0, 0, 0.5)'
                 }
               },
               data: [],
               tooltip: {
                 valueFormatter: (item) => {}
               }
             }
           ]
         },
        
   
   ### Current Behavior
   
   The following issues occur just on iPhone (ios 14.4),other phones and 
browsers run without problems
   
   
![image](https://user-images.githubusercontent.com/6622313/160970906-fee9953e-69fb-4df4-88a1-6d6838f880f3.png)
   
   
   
   ### Expected Behavior
   
   
![image](https://user-images.githubusercontent.com/6622313/160970906-fee9953e-69fb-4df4-88a1-6d6838f880f3.png)
   
   ### Environment
   
   ```markdown
   - OS:iphone ios 14.4
   - Browser: safari
   - Framework:
   ```
   
   
   ### Any additional comments?
   
   I guess there is a problem with the compiled code. It should be a 
compatibility problem after compiling the code, but I don't know how to fix it.
   
   
   source code:
    node_modules\echarts\lib\model\Global.js
   
              // PENDING Global as parent ?
               var extraOpt = extend({
                 componentIndex: index
               }, resultItem.keyInfo);
               componentModel = new ComponentModelClass(newCmptOption, this, 
this, extraOpt); // Assign `keyInfo`
   
               extend(componentModel, extraOpt);
   
   
   compiled code:
   
               var i = g.a.getClass(o, e.keyInfo.subType, !("series" === o));
                           console.log("mainType:", o, "subType:", 
e.keyInfo.subType, "!isSeriesType:", !("series" === o), "ComponentModelClass:", 
i);
                           if (!i) return;
                           if ("tooltip" === o) {
                               if (a) return;
                               a = !0
                           }
                           n && n.constructor === i ? (n.name = e.keyInfo.name, 
n.mergeOption(r, this), n.optionUpdated(r, !1)) : (n = new i(r, this, this, i = 
Object(h.m)({
                               componentIndex: t
                           },
                           e.keyInfo)), Object(h.m)(n, i), e.brandNew && 
(n.__requireNewView = !0), n.init(r, this, this), n.optionUpdated(null, !0))
   
   there may be incompatible code: 
   
          (n = new i(r, this, this, i = Object(h.m)({componentIndex: 
t},e.keyInfo))
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to