mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-19 14:53:50 +02:00
use vueuse
This commit is contained in:
@@ -97,7 +97,8 @@
|
|||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { Copy, Download, RefreshCcw, RotateCcw, RotateCw, X, ZoomIn, ZoomOut } from 'lucide-vue-next';
|
import { Copy, Download, RefreshCcw, RotateCcw, RotateCw, X, ZoomIn, ZoomOut } from 'lucide-vue-next';
|
||||||
import { computed, onBeforeUnmount, onMounted, ref, watch } from 'vue';
|
import { useEventListener } from '@vueuse/core';
|
||||||
|
import { computed, onBeforeUnmount, ref, watch } from 'vue';
|
||||||
import { DialogContent as RekaDialogContent, DialogOverlay as RekaDialogOverlay, DialogPortal } from 'reka-ui';
|
import { DialogContent as RekaDialogContent, DialogOverlay as RekaDialogOverlay, DialogPortal } from 'reka-ui';
|
||||||
import { Button } from '@/components/ui/button';
|
import { Button } from '@/components/ui/button';
|
||||||
import { Dialog } from '@/components/ui/dialog';
|
import { Dialog } from '@/components/ui/dialog';
|
||||||
@@ -285,8 +286,7 @@
|
|||||||
else if (e.key.toLowerCase() === 'r') rotateCW();
|
else if (e.key.toLowerCase() === 'r') rotateCW();
|
||||||
else if (e.key === '0') resetTransform();
|
else if (e.key === '0') resetTransform();
|
||||||
}
|
}
|
||||||
onMounted(() => window.addEventListener('keydown', onKeydown));
|
useEventListener(window, 'keydown', onKeydown);
|
||||||
onBeforeUnmount(() => window.removeEventListener('keydown', onKeydown));
|
|
||||||
|
|
||||||
async function copyImageToClipboard(url) {
|
async function copyImageToClipboard(url) {
|
||||||
if (!url) return;
|
if (!url) return;
|
||||||
|
|||||||
@@ -2,7 +2,8 @@
|
|||||||
<span>{{ text }}</span>
|
<span>{{ text }}</span>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import { computed, onBeforeUnmount, onMounted, ref } from 'vue';
|
import { useNow } from '@vueuse/core';
|
||||||
|
import { computed } from 'vue';
|
||||||
|
|
||||||
import { timeToText } from '../shared/utils';
|
import { timeToText } from '../shared/utils';
|
||||||
|
|
||||||
@@ -13,18 +14,8 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
const now = ref(Date.now());
|
const now = useNow({ interval: 15000 });
|
||||||
const text = computed(() => {
|
const text = computed(() => {
|
||||||
return props.epoch ? timeToText(now.value - props.epoch) : '-';
|
return props.epoch ? timeToText(now.value - props.epoch) : '-';
|
||||||
});
|
});
|
||||||
|
|
||||||
let timerId = null;
|
|
||||||
onMounted(() => {
|
|
||||||
timerId = setInterval(() => {
|
|
||||||
now.value = Date.now();
|
|
||||||
}, 15000);
|
|
||||||
});
|
|
||||||
onBeforeUnmount(() => {
|
|
||||||
clearInterval(timerId);
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import { computed, onMounted, onUnmounted, ref, watch } from 'vue';
|
import { useEventListener } from '@vueuse/core';
|
||||||
|
import { computed, ref, watch } from 'vue';
|
||||||
|
|
||||||
import configRepository from '../../../services/config';
|
import configRepository from '../../../services/config';
|
||||||
import {
|
import {
|
||||||
@@ -312,25 +313,11 @@ export function useNavLayout({
|
|||||||
await loadNavMenuConfig();
|
await loadNavMenuConfig();
|
||||||
};
|
};
|
||||||
|
|
||||||
onMounted(() => {
|
useEventListener(
|
||||||
if (typeof window === 'undefined') {
|
typeof window !== 'undefined' ? window : undefined,
|
||||||
return;
|
NAV_LAYOUT_UPDATED_EVENT,
|
||||||
}
|
handleExternalNavLayoutUpdate
|
||||||
window.addEventListener(
|
);
|
||||||
NAV_LAYOUT_UPDATED_EVENT,
|
|
||||||
handleExternalNavLayoutUpdate
|
|
||||||
);
|
|
||||||
});
|
|
||||||
|
|
||||||
onUnmounted(() => {
|
|
||||||
if (typeof window === 'undefined') {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
window.removeEventListener(
|
|
||||||
NAV_LAYOUT_UPDATED_EVENT,
|
|
||||||
handleExternalNavLayoutUpdate
|
|
||||||
);
|
|
||||||
});
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
navLayout,
|
navLayout,
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import { computed, onMounted, onUnmounted, ref } from 'vue';
|
import { useEventListener } from '@vueuse/core';
|
||||||
|
import { computed, ref } from 'vue';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
import { toast } from 'vue-sonner';
|
import { toast } from 'vue-sonner';
|
||||||
|
|
||||||
@@ -243,22 +244,11 @@ export function useToolNavPinning() {
|
|||||||
dispatchNavLayoutUpdated();
|
dispatchNavLayoutUpdated();
|
||||||
};
|
};
|
||||||
|
|
||||||
onMounted(() => {
|
useEventListener(
|
||||||
if (typeof window === 'undefined') {
|
typeof window !== 'undefined' ? window : undefined,
|
||||||
return;
|
NAV_LAYOUT_UPDATED_EVENT,
|
||||||
}
|
refreshPinnedState
|
||||||
window.addEventListener(NAV_LAYOUT_UPDATED_EVENT, refreshPinnedState);
|
);
|
||||||
});
|
|
||||||
|
|
||||||
onUnmounted(() => {
|
|
||||||
if (typeof window === 'undefined') {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
window.removeEventListener(
|
|
||||||
NAV_LAYOUT_UPDATED_EVENT,
|
|
||||||
refreshPinnedState
|
|
||||||
);
|
|
||||||
});
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
pinnedToolKeys: computed(() => pinnedToolKeysRef.value),
|
pinnedToolKeys: computed(() => pinnedToolKeysRef.value),
|
||||||
|
|||||||
@@ -244,6 +244,7 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
defineOptions({ name: 'ChartsMutual' });
|
defineOptions({ name: 'ChartsMutual' });
|
||||||
|
|
||||||
|
import { useLocalStorage } from '@vueuse/core';
|
||||||
import { computed, nextTick, onBeforeUnmount, onMounted, reactive, ref, watch } from 'vue';
|
import { computed, nextTick, onBeforeUnmount, onMounted, reactive, ref, watch } from 'vue';
|
||||||
import { Sheet, SheetContent, SheetHeader, SheetTitle, SheetTrigger } from '@/components/ui/sheet';
|
import { Sheet, SheetContent, SheetHeader, SheetTitle, SheetTrigger } from '@/components/ui/sheet';
|
||||||
import { Field, FieldContent, FieldGroup, FieldLabel } from '@/components/ui/field';
|
import { Field, FieldContent, FieldGroup, FieldLabel } from '@/components/ui/field';
|
||||||
@@ -516,24 +517,9 @@
|
|||||||
const selectedFriendId = ref(null);
|
const selectedFriendId = ref(null);
|
||||||
|
|
||||||
const EXCLUDED_FRIENDS_KEY = 'VRCX_MutualGraphExcludedFriends';
|
const EXCLUDED_FRIENDS_KEY = 'VRCX_MutualGraphExcludedFriends';
|
||||||
const excludedFriendIds = ref(loadExcludedFriends());
|
const excludedFriendIds = useLocalStorage(EXCLUDED_FRIENDS_KEY, []);
|
||||||
|
|
||||||
function loadExcludedFriends() {
|
|
||||||
try {
|
|
||||||
const stored = localStorage.getItem(EXCLUDED_FRIENDS_KEY);
|
|
||||||
if (stored) return JSON.parse(stored);
|
|
||||||
} catch {
|
|
||||||
/* ignore */
|
|
||||||
}
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
|
|
||||||
function saveExcludedFriends() {
|
|
||||||
localStorage.setItem(EXCLUDED_FRIENDS_KEY, JSON.stringify(excludedFriendIds.value));
|
|
||||||
}
|
|
||||||
|
|
||||||
watch(excludedFriendIds, async () => {
|
watch(excludedFriendIds, async () => {
|
||||||
saveExcludedFriends();
|
|
||||||
if (lastMutualMap) {
|
if (lastMutualMap) {
|
||||||
try {
|
try {
|
||||||
await applyGraph(lastMutualMap);
|
await applyGraph(lastMutualMap);
|
||||||
|
|||||||
@@ -2,10 +2,10 @@ import {
|
|||||||
computed,
|
computed,
|
||||||
nextTick,
|
nextTick,
|
||||||
onBeforeMount,
|
onBeforeMount,
|
||||||
onBeforeUnmount,
|
|
||||||
ref,
|
ref,
|
||||||
watch
|
watch
|
||||||
} from 'vue';
|
} from 'vue';
|
||||||
|
import { useResizeObserver } from '@vueuse/core';
|
||||||
|
|
||||||
import configRepository from '../../../services/config.js';
|
import configRepository from '../../../services/config.js';
|
||||||
|
|
||||||
@@ -58,9 +58,6 @@ export function useFavoritesCardScaling(options = {}) {
|
|||||||
const containerRef = ref(null);
|
const containerRef = ref(null);
|
||||||
const containerWidth = ref(0);
|
const containerWidth = ref(0);
|
||||||
|
|
||||||
let resizeObserver;
|
|
||||||
let cleanupWindowResize;
|
|
||||||
|
|
||||||
const updateContainerWidth = (el = containerRef.value) => {
|
const updateContainerWidth = (el = containerRef.value) => {
|
||||||
const element = el ?? containerRef.value;
|
const element = el ?? containerRef.value;
|
||||||
if (!element) {
|
if (!element) {
|
||||||
@@ -73,17 +70,6 @@ export function useFavoritesCardScaling(options = {}) {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
const disconnectResizeObserver = () => {
|
|
||||||
if (resizeObserver) {
|
|
||||||
resizeObserver.disconnect();
|
|
||||||
resizeObserver = undefined;
|
|
||||||
}
|
|
||||||
if (cleanupWindowResize) {
|
|
||||||
cleanupWindowResize();
|
|
||||||
cleanupWindowResize = undefined;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
const cardScale = computed({
|
const cardScale = computed({
|
||||||
get: () => cardScaleBase.value,
|
get: () => cardScaleBase.value,
|
||||||
set: (value) => {
|
set: (value) => {
|
||||||
@@ -212,46 +198,21 @@ export function useFavoritesCardScaling(options = {}) {
|
|||||||
watch(
|
watch(
|
||||||
containerRef,
|
containerRef,
|
||||||
(element) => {
|
(element) => {
|
||||||
disconnectResizeObserver();
|
|
||||||
if (!element) {
|
if (!element) {
|
||||||
containerWidth.value = 0;
|
containerWidth.value = 0;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
nextTick(() => updateContainerWidth(element));
|
nextTick(() => updateContainerWidth(element));
|
||||||
|
|
||||||
if (typeof ResizeObserver !== 'undefined') {
|
|
||||||
const observedElement = element;
|
|
||||||
resizeObserver = new ResizeObserver((entries) => {
|
|
||||||
if (!entries?.length) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const [entry] = entries;
|
|
||||||
const width =
|
|
||||||
entry.contentRect?.width ??
|
|
||||||
observedElement?.clientWidth ??
|
|
||||||
0;
|
|
||||||
containerWidth.value = Math.max(width, 0);
|
|
||||||
});
|
|
||||||
resizeObserver.observe(element);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (typeof window !== 'undefined') {
|
|
||||||
const handleResize = () => updateContainerWidth(element);
|
|
||||||
window.addEventListener('resize', handleResize, {
|
|
||||||
passive: true
|
|
||||||
});
|
|
||||||
cleanupWindowResize = () => {
|
|
||||||
window.removeEventListener('resize', handleResize);
|
|
||||||
};
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
{ immediate: true }
|
{ immediate: true }
|
||||||
);
|
);
|
||||||
|
|
||||||
onBeforeUnmount(() => {
|
useResizeObserver(containerRef, (entries) => {
|
||||||
disconnectResizeObserver();
|
const [entry] = entries;
|
||||||
|
const width =
|
||||||
|
entry?.contentRect?.width ?? containerRef.value?.clientWidth ?? 0;
|
||||||
|
containerWidth.value = Math.max(width, 0);
|
||||||
});
|
});
|
||||||
|
|
||||||
onBeforeMount(async () => {
|
onBeforeMount(async () => {
|
||||||
|
|||||||
@@ -138,7 +138,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { computed, nextTick, onBeforeMount, onBeforeUnmount, onMounted, reactive, ref, watch } from 'vue';
|
import { useResizeObserver } from '@vueuse/core';
|
||||||
|
import { computed, nextTick, onBeforeMount, onMounted, reactive, ref, watch } from 'vue';
|
||||||
import { ChevronDown, Loader2, Settings } from 'lucide-vue-next';
|
import { ChevronDown, Loader2, Settings } from 'lucide-vue-next';
|
||||||
import { Field, FieldContent, FieldLabel } from '@/components/ui/field';
|
import { Field, FieldContent, FieldLabel } from '@/components/ui/field';
|
||||||
import { Tabs, TabsList, TabsTrigger } from '@/components/ui/tabs';
|
import { Tabs, TabsList, TabsTrigger } from '@/components/ui/tabs';
|
||||||
@@ -262,8 +263,6 @@
|
|||||||
const gridWidth = ref(0);
|
const gridWidth = ref(0);
|
||||||
let measureScheduled = false;
|
let measureScheduled = false;
|
||||||
let pendingGridWidthUpdate = false;
|
let pendingGridWidthUpdate = false;
|
||||||
let resizeObserver;
|
|
||||||
let cleanupResize;
|
|
||||||
|
|
||||||
const updateGridWidth = () => {
|
const updateGridWidth = () => {
|
||||||
const wrap = scrollbarRef.value;
|
const wrap = scrollbarRef.value;
|
||||||
@@ -275,45 +274,19 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
const setupResizeHandling = () => {
|
const setupResizeHandling = () => {
|
||||||
if (cleanupResize) {
|
|
||||||
cleanupResize();
|
|
||||||
cleanupResize = undefined;
|
|
||||||
}
|
|
||||||
|
|
||||||
const wrap = scrollbarRef.value;
|
const wrap = scrollbarRef.value;
|
||||||
if (!wrap) {
|
if (!wrap) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
updateGridWidth();
|
updateGridWidth();
|
||||||
|
|
||||||
if (typeof ResizeObserver !== 'undefined') {
|
|
||||||
resizeObserver = new ResizeObserver((entries) => {
|
|
||||||
if (!entries || entries.length === 0) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const [entry] = entries;
|
|
||||||
gridWidth.value = entry.contentRect?.width ?? wrap.clientWidth ?? 0;
|
|
||||||
});
|
|
||||||
resizeObserver.observe(wrap);
|
|
||||||
cleanupResize = () => {
|
|
||||||
resizeObserver?.disconnect();
|
|
||||||
resizeObserver = undefined;
|
|
||||||
};
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (typeof window !== 'undefined') {
|
|
||||||
const handleResize = () => {
|
|
||||||
updateGridWidth();
|
|
||||||
};
|
|
||||||
window.addEventListener('resize', handleResize, { passive: true });
|
|
||||||
cleanupResize = () => {
|
|
||||||
window.removeEventListener('resize', handleResize);
|
|
||||||
};
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
useResizeObserver(scrollbarRef, (entries) => {
|
||||||
|
const [entry] = entries;
|
||||||
|
gridWidth.value = entry?.contentRect?.width ?? scrollbarRef.value?.clientWidth ?? 0;
|
||||||
|
});
|
||||||
|
|
||||||
const normalizedSearchTerm = computed(() => searchTerm.value.trim().toLowerCase());
|
const normalizedSearchTerm = computed(() => searchTerm.value.trim().toLowerCase());
|
||||||
|
|
||||||
const toEntries = (list = [], instanceId) =>
|
const toEntries = (list = [], instanceId) =>
|
||||||
@@ -905,13 +878,6 @@
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
onBeforeUnmount(() => {
|
|
||||||
if (cleanupResize) {
|
|
||||||
cleanupResize();
|
|
||||||
cleanupResize = undefined;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -2,10 +2,10 @@ import {
|
|||||||
computed,
|
computed,
|
||||||
nextTick,
|
nextTick,
|
||||||
onBeforeMount,
|
onBeforeMount,
|
||||||
onBeforeUnmount,
|
|
||||||
ref,
|
ref,
|
||||||
watch
|
watch
|
||||||
} from 'vue';
|
} from 'vue';
|
||||||
|
import { useResizeObserver } from '@vueuse/core';
|
||||||
|
|
||||||
import configRepository from '../../../services/config.js';
|
import configRepository from '../../../services/config.js';
|
||||||
|
|
||||||
@@ -47,9 +47,6 @@ export function useAvatarCardGrid(options = {}) {
|
|||||||
const gridContainerRef = ref(null);
|
const gridContainerRef = ref(null);
|
||||||
const containerWidth = ref(0);
|
const containerWidth = ref(0);
|
||||||
|
|
||||||
let resizeObserver;
|
|
||||||
let cleanupResize;
|
|
||||||
|
|
||||||
const updateContainerWidth = (el) => {
|
const updateContainerWidth = (el) => {
|
||||||
const element = el ?? gridContainerRef.value;
|
const element = el ?? gridContainerRef.value;
|
||||||
if (!element) {
|
if (!element) {
|
||||||
@@ -62,17 +59,6 @@ export function useAvatarCardGrid(options = {}) {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
const disconnectResize = () => {
|
|
||||||
if (resizeObserver) {
|
|
||||||
resizeObserver.disconnect();
|
|
||||||
resizeObserver = undefined;
|
|
||||||
}
|
|
||||||
if (cleanupResize) {
|
|
||||||
cleanupResize();
|
|
||||||
cleanupResize = undefined;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
const cardScale = computed({
|
const cardScale = computed({
|
||||||
get: () => cardScaleBase.value,
|
get: () => cardScaleBase.value,
|
||||||
set: (value) => {
|
set: (value) => {
|
||||||
@@ -207,39 +193,22 @@ export function useAvatarCardGrid(options = {}) {
|
|||||||
watch(
|
watch(
|
||||||
gridContainerRef,
|
gridContainerRef,
|
||||||
(element) => {
|
(element) => {
|
||||||
disconnectResize();
|
|
||||||
if (!element) {
|
if (!element) {
|
||||||
containerWidth.value = 0;
|
containerWidth.value = 0;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
nextTick(() => updateContainerWidth(element));
|
nextTick(() => updateContainerWidth(element));
|
||||||
|
|
||||||
if (typeof ResizeObserver !== 'undefined') {
|
|
||||||
resizeObserver = new ResizeObserver((entries) => {
|
|
||||||
if (!entries?.length) return;
|
|
||||||
const [entry] = entries;
|
|
||||||
containerWidth.value = Math.max(
|
|
||||||
entry.contentRect?.width ?? element.clientWidth ?? 0,
|
|
||||||
0
|
|
||||||
);
|
|
||||||
});
|
|
||||||
resizeObserver.observe(element);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (typeof window !== 'undefined') {
|
|
||||||
const handleResize = () => updateContainerWidth(element);
|
|
||||||
window.addEventListener('resize', handleResize, {
|
|
||||||
passive: true
|
|
||||||
});
|
|
||||||
cleanupResize = () =>
|
|
||||||
window.removeEventListener('resize', handleResize);
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
{ immediate: true }
|
{ immediate: true }
|
||||||
);
|
);
|
||||||
|
|
||||||
onBeforeUnmount(() => disconnectResize());
|
useResizeObserver(gridContainerRef, (entries) => {
|
||||||
|
const [entry] = entries;
|
||||||
|
containerWidth.value = Math.max(
|
||||||
|
entry?.contentRect?.width ?? gridContainerRef.value?.clientWidth ?? 0,
|
||||||
|
0
|
||||||
|
);
|
||||||
|
});
|
||||||
|
|
||||||
onBeforeMount(async () => {
|
onBeforeMount(async () => {
|
||||||
try {
|
try {
|
||||||
|
|||||||
@@ -148,7 +148,8 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
import { Select, SelectContent, SelectGroup, SelectItem, SelectTrigger, SelectValue } from '@/components/ui/select';
|
import { Select, SelectContent, SelectGroup, SelectItem, SelectTrigger, SelectValue } from '@/components/ui/select';
|
||||||
import { Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious } from '@/components/ui/carousel';
|
import { Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious } from '@/components/ui/carousel';
|
||||||
import { onBeforeUnmount, onMounted, reactive, ref } from 'vue';
|
import { useEventListener } from '@vueuse/core';
|
||||||
|
import { onMounted, reactive, ref } from 'vue';
|
||||||
import { useGalleryStore, useUserStore, useVrcxStore } from '@/stores';
|
import { useGalleryStore, useUserStore, useVrcxStore } from '@/stores';
|
||||||
import { ArrowLeft } from 'lucide-vue-next';
|
import { ArrowLeft } from 'lucide-vue-next';
|
||||||
import { Badge } from '@/components/ui/badge';
|
import { Badge } from '@/components/ui/badge';
|
||||||
@@ -198,11 +199,6 @@
|
|||||||
if (!screenshotMetadataDialog.metadata.filePath) {
|
if (!screenshotMetadataDialog.metadata.filePath) {
|
||||||
getAndDisplayLastScreenshot();
|
getAndDisplayLastScreenshot();
|
||||||
}
|
}
|
||||||
window.addEventListener('keyup', handleComponentKeyup);
|
|
||||||
});
|
|
||||||
|
|
||||||
onBeforeUnmount(() => {
|
|
||||||
window.removeEventListener('keyup', handleComponentKeyup);
|
|
||||||
});
|
});
|
||||||
|
|
||||||
const handleComponentKeyup = (event) => {
|
const handleComponentKeyup = (event) => {
|
||||||
@@ -220,6 +216,9 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
useEventListener(window, 'keyup', handleComponentKeyup);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user