feat: 拖拽表格

This commit is contained in:
kailong321200875
2023-07-20 16:37:18 +08:00
parent cfb3b3a5ce
commit b69b8ed1bd
18 changed files with 254 additions and 29 deletions

View File

@@ -103,3 +103,8 @@ export const isUrl = (path: string): boolean => {
export const isDark = (): boolean => {
return window.matchMedia('(prefers-color-scheme: dark)').matches
}
// 是否是图片链接
export const isImgPath = (path: string): boolean => {
return /(https?:\/\/|data:image\/).*?\.(png|jpg|jpeg|gif|svg|webp|ico)/gi.test(path)
}