chore: upgrade i18next 26, prettier 3, fontsource-variable, domhandler 6, lint-staged 17
- i18next 23->26 + react-i18next 15->17 - prettier 2->3, reformat all files - replace @fontsource/inter with @fontsource-variable/inter 5, update import path - domhandler 5->6 (aligns with transitive deps) - lint-staged 16->17
This commit is contained in:
@@ -13,7 +13,7 @@ export const editableActiveElement = (): boolean =>
|
||||
|
||||
export const isIntersectingScrollView = (
|
||||
scrollElement: HTMLElement,
|
||||
childElement: HTMLElement
|
||||
childElement: HTMLElement,
|
||||
): boolean => {
|
||||
const scrollTop = scrollElement.offsetTop + scrollElement.scrollTop;
|
||||
const scrollBottom = scrollTop + scrollElement.offsetHeight;
|
||||
@@ -38,7 +38,7 @@ export const isInScrollView = (scrollElement: HTMLElement, childElement: HTMLEle
|
||||
|
||||
export const canFitInScrollView = (
|
||||
scrollElement: HTMLElement,
|
||||
childElement: HTMLElement
|
||||
childElement: HTMLElement,
|
||||
): boolean => childElement.offsetHeight < scrollElement.offsetHeight;
|
||||
|
||||
export type FilesOrFile<T extends boolean | undefined = undefined> = T extends true ? File[] : File;
|
||||
@@ -56,7 +56,7 @@ export const getFilesFromFileList = (fileList: FileList): File[] => {
|
||||
|
||||
export const selectFile = <M extends boolean | undefined = undefined>(
|
||||
accept: string,
|
||||
multiple?: M
|
||||
multiple?: M,
|
||||
): Promise<FilesOrFile<M> | undefined> =>
|
||||
new Promise((resolve) => {
|
||||
const input = document.createElement('input');
|
||||
@@ -147,7 +147,7 @@ export const getThumbnail = (
|
||||
img: HTMLImageElement | SVGImageElement | HTMLVideoElement,
|
||||
width: number,
|
||||
height: number,
|
||||
thumbnailMimeType?: string
|
||||
thumbnailMimeType?: string,
|
||||
): Promise<Blob | undefined> =>
|
||||
new Promise((resolve) => {
|
||||
const canvas = document.createElement('canvas');
|
||||
|
||||
Reference in New Issue
Block a user