MCPcopy Index your code
hub / github.com/ionic-team/ionic-framework / removeActivated

Function removeActivated

core/src/utils/tap-click/index.ts:104–120  ·  view source on GitHub ↗
(smooth: boolean)

Source from the content-addressed store, hash-verified

102 };
103
104 const removeActivated = (smooth: boolean) => {
105 removeRipple();
106 const active = activatableEle;
107 if (!active) {
108 return;
109 }
110 const time = CLEAR_STATE_DEFERS - Date.now() + lastActivated;
111 if (smooth && time > 0 && !isInstant(active)) {
112 const deferId = setTimeout(() => {
113 active.classList.remove(ACTIVATED);
114 clearDefers.delete(active);
115 }, CLEAR_STATE_DEFERS);
116 clearDefers.set(active, deferId);
117 } else {
118 active.classList.remove(ACTIVATED);
119 }
120 };
121
122 doc.addEventListener('ionGestureCaptured', cancelActive);
123

Callers 2

cancelActiveFunction · 0.85
setActivatedElementFunction · 0.85

Calls 3

isInstantFunction · 0.85
setMethod · 0.80
removeRippleFunction · 0.70

Tested by

no test coverage detected