Ovilia commented on code in PR #20969:
URL: https://github.com/apache/echarts/pull/20969#discussion_r2142038553


##########
src/component/toolbox/feature/DataView.ts:
##########
@@ -375,7 +378,11 @@ class DataView extends 
ToolboxFeature<ToolboxDataViewFeatureOption> {
         const blockMetaList = result.meta;
 
         const buttonContainer = document.createElement('div');
-        buttonContainer.style.cssText = 
'position:absolute;bottom:5px;left:0;right:0';
+        buttonContainer.style.cssText = 'position:absolute;top:' + 
model.get('buttonPosition').top
+                                        + ';left:' + 
model.get('buttonPosition').left
+                                        + ';right:' + 
model.get('buttonPosition').right
+                                        + ';bottom:' + 
model.get('buttonPosition').bottom
+                                        + ';';

Review Comment:
   It's better to save `model.get('buttonPosition')` and add default values 
when not defined.
   
   ```js
   const buttonPosition = model.get('buttonPosition') || {};
   ```
   
   Please also fix the indent to be smaller.



##########
test/area-large-dataView.html:
##########
@@ -0,0 +1,167 @@
+<!DOCTYPE html>

Review Comment:
   It doesn't seem necessary to add this new file. You make change the option 
in the `dataview.html`.



-- 
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