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

Function updateZ

src/chart/custom/CustomView.ts:583–606  ·  view source on GitHub ↗
(
    el: Element,
    elOption: CustomElementOption,
    seriesModel: CustomSeriesModel
)

Source from the content-addressed store, hash-verified

581}
582
583function updateZ(
584 el: Element,
585 elOption: CustomElementOption,
586 seriesModel: CustomSeriesModel
587): void {
588 // Group not support textContent and not support z yet.
589 if (el.isGroup) {
590 return;
591 }
592
593 const elDisplayable = el as Displayable;
594 const currentZ = seriesModel.currentZ;
595 const currentZLevel = seriesModel.currentZLevel;
596 // Always erase.
597 elDisplayable.z = currentZ;
598 elDisplayable.zlevel = currentZLevel;
599 // z2 must not be null/undefined, otherwise sort error may occur.
600 const optZ2 = (elOption as CustomDisplayableOption).z2;
601 optZ2 != null && (elDisplayable.z2 = optZ2 || 0);
602
603 for (let i = 0; i < STATES.length; i++) {
604 updateZForEachState(elDisplayable, elOption, STATES[i]);
605 }
606}
607
608function updateZForEachState(
609 elDisplayable: Displayable,

Callers 1

doCreateOrUpdateElFunction · 0.70

Calls 1

updateZForEachStateFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…