6341962de4
* fix(web): better touch device detection * variable name
14 lines
299 B
TypeScript
14 lines
299 B
TypeScript
import { MediaQuery } from 'svelte/reactivity';
|
|
|
|
const pointerCoarse = new MediaQuery('pointer:coarse');
|
|
const maxMd = new MediaQuery('max-width: 767px');
|
|
|
|
export const mobileDevice = {
|
|
get pointerCoarse() {
|
|
return pointerCoarse.current;
|
|
},
|
|
get maxMd() {
|
|
return maxMd.current;
|
|
},
|
|
};
|