This commit is contained in:
dwelle
2026-02-23 22:58:14 +01:00
parent 2e5bf3bb51
commit 966cd35b08
4 changed files with 5 additions and 9 deletions
-4
View File
@@ -1,4 +0,0 @@
module.exports = {
"*.{js,ts,tsx}": ["oxlint --fix", "oxfmt --write"],
"*.{css,scss,json,md,html,yml}": ["oxfmt --write"],
};
@@ -1,4 +1,3 @@
// oxlint-disable typescript/no-misused-spread
import { import {
pointCenter, pointCenter,
pointFrom, pointFrom,
-1
View File
@@ -1,4 +1,3 @@
// oxlint-disable typescript/no-misused-spread
import clsx from "clsx"; import clsx from "clsx";
import throttle from "lodash.throttle"; import throttle from "lodash.throttle";
import React, { useContext } from "react"; import React, { useContext } from "react";
@@ -10,9 +10,11 @@ export class ExcalidrawFontFace {
private static readonly ASSETS_FALLBACK_URL = `https://esm.sh/${ private static readonly ASSETS_FALLBACK_URL = `https://esm.sh/${
import.meta.env.PKG_NAME import.meta.env.PKG_NAME
? `${import.meta.env.PKG_NAME}@${import.meta.env.PKG_VERSION}` // is provided during package build ? // is provided during package build
: "@excalidraw/excalidraw" `${import.meta.env.PKG_NAME}@${import.meta.env.PKG_VERSION}`
}/dist/prod/`; // fallback to the latest package version (i.e. for app) : // fallback to the latest package version (i.e. for app)
"@excalidraw/excalidraw"
}/dist/prod/`;
constructor(family: string, uri: string, descriptors?: FontFaceDescriptors) { constructor(family: string, uri: string, descriptors?: FontFaceDescriptors) {
this.urls = ExcalidrawFontFace.createUrls(uri); this.urls = ExcalidrawFontFace.createUrls(uri);