viking7982 commented on code in PR #18436:
URL: https://github.com/apache/echarts/pull/18436#discussion_r1155450463
##########
src/component/tooltip/TooltipHTMLContent.ts:
##########
@@ -350,7 +361,7 @@ class TooltipHTMLContent {
update(tooltipModel: Model<TooltipOption>) {
// FIXME
// Move this logic to ec main?
- const container = this._container;
+ const container = this._api.getDom();
Review Comment:
> Can you explain why you changed the `_container` to `api.getDom()`? I
think it should be unchanged.
Previously, the `_container` was the container of the echart canvas. But now
we change it to the container of tooltip.
In my mind, these code are perpose to change the style of the echart
container to `position: relative`. After that, the absoluted position tooltip
element can have correct position inside the container.
However, after we change its meaning. The `_container` can be some custom
element outside of the echarts. It could be danger if we change the style of
that element.
--
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]