UNPKG

@awcrotwell/motion

Version:

Motion allows you to build reactive, real-time frontend UI components in your Amber application using pure Crystal that are reusable, testable & encapsulated. For brevity, we will call them MotionComponents.

30 lines (29 loc) 1.17 kB
import BindingManager from './BindingManager'; import Component from './Component'; export default class AttributeTracker { attribute: string; createManager: Function; _managers: Map<HTMLElement, BindingManager | Component>; _attributeSelector: string; _mutationObserver: MutationObserver; constructor(attribute: string, createManager: Function); attachRoot(element: HTMLElement): void; shutdown(): void; getManager(element: HTMLElement): HTMLElement; _detect(element: HTMLElement): void; _update(element: HTMLElement): void; _remove(element: HTMLElement): void; _processMutation(mutation: any): void; _processChildListMutation({ removedNodes, addedNodes }: { removedNodes: any; addedNodes: any; }): void; _processAttributesMutation({ target }: { target: any; }): void; _processAttributeUpdateToTracked(element: HTMLElement): void; _processAttributeUpdateToUntracked(element: HTMLElement): void; _forEachMatchingIn(nodes: any, callback: Function): void; _forEachMatchingUnder(node: any, callback: Function): void; _errorBoundry(callback: Function): void; }