Rework menu to use elements.

This commit is contained in:
Dermot Duffy
2021-10-07 21:15:10 -07:00
parent c1f00d7e14
commit 4f8e21a0b0
6 changed files with 303 additions and 130 deletions
+2 -4
View File
@@ -7,10 +7,8 @@ import {
} from 'custom-card-helpers/dist/types';
import { fireEvent } from 'custom-card-helpers';
const isTouch =
'ontouchstart' in window ||
navigator.maxTouchPoints > 0 ||
navigator.msMaxTouchPoints > 0;
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const isTouch = 'ontouchstart' in window || navigator.maxTouchPoints > 0 || (navigator as any).msMaxTouchPoints > 0;
interface ActionHandler extends HTMLElement {
holdTime: number;