Remove unused method

pull/146/head
Cory LaViska 2020-07-24 09:27:11 -04:00
rodzic 3e0f174052
commit 91a023e564
1 zmienionych plików z 0 dodań i 17 usunięć

Wyświetl plik

@ -131,7 +131,6 @@ export class ColorPicker {
this.handleAlphaInput = this.handleAlphaInput.bind(this);
this.handleAlphaKeyDown = this.handleAlphaKeyDown.bind(this);
this.handleCopy = this.handleCopy.bind(this);
this.handleDocumentKeyDown = this.handleDocumentKeyDown.bind(this);
this.handleDocumentMouseDown = this.handleDocumentMouseDown.bind(this);
this.handleDrag = this.handleDrag.bind(this);
this.handleDropdownAfterHide = this.handleDropdownAfterHide.bind(this);
@ -362,22 +361,6 @@ export class ColorPicker {
}
}
handleDocumentKeyDown(event: KeyboardEvent) {
// Close when pressing escape or tab
if (event.key === 'Escape') {
this.dropdown.hide();
}
// Close when tabbing out of the color picker
if (event.key === 'Tab') {
setTimeout(() => {
if (document.activeElement && document.activeElement.closest('sl-color-picker') !== this.host) {
this.dropdown.hide();
}
});
}
}
handleDocumentMouseDown(event: MouseEvent) {
const target = event.target as HTMLElement;