MCPcopy Index your code
hub / github.com/apache/echarts / removeElementWithFadeOut

Function removeElementWithFadeOut

src/animation/basicTransition.ts:303–324  ·  view source on GitHub ↗
(
    el: Element,
    animatableModel?: Model<AnimationOptionMixin>,
    dataIndex?: number
)

Source from the content-addressed store, hash-verified

301}
302
303export function removeElementWithFadeOut(
304 el: Element,
305 animatableModel?: Model<AnimationOptionMixin>,
306 dataIndex?: number
307) {
308 function doRemove() {
309 el.parent && el.parent.remove(el);
310 }
311 // Hide label and labelLine first
312 // TODO Also use fade out animation?
313 if (!el.isGroup) {
314 fadeOutDisplayable(el as Displayable, animatableModel, dataIndex, doRemove);
315 }
316 else {
317 (el as Group).traverse(function (disp: Displayable) {
318 if (!disp.isGroup) {
319 // Can invoke doRemove multiple times.
320 fadeOutDisplayable(disp as Displayable, animatableModel, dataIndex, doRemove);
321 }
322 });
323 }
324}
325
326/**
327 * Save old style for style transition in universalTransition module.

Callers 2

_renderNormalMethod · 0.85
_clearMethod · 0.85

Calls 1

fadeOutDisplayableFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…