MCPcopy Create free account
hub / github.com/adobe/react-spectrum / constructor

Method constructor

packages/react-aria/src/dnd/DragManager.ts:180–192  ·  view source on GitHub ↗
(target: DragTarget, stringFormatter: LocalizedStringFormatter)

Source from the content-addressed store, hash-verified

178 private initialFocused: boolean;
179
180 constructor(target: DragTarget, stringFormatter: LocalizedStringFormatter) {
181 this.dragTarget = target;
182 this.stringFormatter = stringFormatter;
183
184 this.onKeyDown = this.onKeyDown.bind(this);
185 this.onKeyUp = this.onKeyUp.bind(this);
186 this.onFocus = this.onFocus.bind(this);
187 this.onBlur = this.onBlur.bind(this);
188 this.onClick = this.onClick.bind(this);
189 this.onPointerDown = this.onPointerDown.bind(this);
190 this.cancelEvent = this.cancelEvent.bind(this);
191 this.initialFocused = false;
192 }
193
194 setup(): void {
195 document.addEventListener('keydown', this.onKeyDown, true);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected