MCPcopy Index your code
hub / github.com/ampproject/amphtml / completeCollapse

Method completeCollapse

src/service/resource.js:541–555  ·  view source on GitHub ↗

* Completes collapse: ensures that the element is `display:none` and * updates layout box.

()

Source from the content-addressed store, hash-verified

539 * updates layout box.
540 */
541 completeCollapse() {
542 toggle(this.element, false);
543 this.layoutBox_ = layoutRectLtwh(
544 this.layoutBox_.left,
545 this.layoutBox_.top,
546 0,
547 0
548 );
549 this.isFixed_ = false;
550 this.element.updateLayoutBox(this.getLayoutBox());
551 const owner = this.getOwner();
552 if (owner) {
553 owner.collapsedCallback(this.element);
554 }
555 }
556
557 /**
558 * Completes expand: ensures that the element is not `display:none` and

Callers 5

test-resource.jsFile · 0.80
attemptCollapseMethod · 0.80
collapseElementMethod · 0.80
attemptCollapseMethod · 0.80
collapseElementMethod · 0.80

Calls 6

getLayoutBoxMethod · 0.95
getOwnerMethod · 0.95
toggleFunction · 0.90
layoutRectLtwhFunction · 0.90
updateLayoutBoxMethod · 0.80
collapsedCallbackMethod · 0.45

Tested by

no test coverage detected