forked from excalidraw/excalidraw
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
0.17.6-2 (Assistant copied to assets)
- Loading branch information
Showing
7 changed files
with
114 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,31 +4,31 @@ | |
|
||
@font-face { | ||
font-family: "Assistant"; | ||
src: url(../woff2/Assistant/Assistant-Regular.woff2) format("woff2"); | ||
src: url(https://unpkg.com/@zsviczian/[email protected]/dist/excalidraw-assets/Assistant-Regular.woff2) format("woff2"); | ||
font-weight: 400; | ||
style: normal; | ||
display: swap; | ||
} | ||
|
||
@font-face { | ||
font-family: "Assistant"; | ||
src: url(../woff2/Assistant/Assistant-Medium.woff2) format("woff2"); | ||
src: url(https://unpkg.com/@zsviczian/[email protected]/dist/excalidraw-assets/Assistant-Medium.woff2) format("woff2"); | ||
font-weight: 500; | ||
style: normal; | ||
display: swap; | ||
} | ||
|
||
@font-face { | ||
font-family: "Assistant"; | ||
src: url(../woff2/Assistant/Assistant-SemiBold.woff2) format("woff2"); | ||
src: url(https://unpkg.com/@zsviczian/[email protected]/dist/excalidraw-assets/Assistant-SemiBold.woff2) format("woff2"); | ||
font-weight: 600; | ||
style: normal; | ||
display: swap; | ||
} | ||
|
||
@font-face { | ||
font-family: "Assistant"; | ||
src: url(../woff2/Assistant/Assistant-Bold.woff2) format("woff2"); | ||
src: url(https://unpkg.com/@zsviczian/[email protected]/dist/excalidraw-assets/Assistant-Bold.woff2) format("woff2"); | ||
font-weight: 700; | ||
style: normal; | ||
display: swap; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -137,16 +137,13 @@ export async function loadSceneFonts(elements: NonDeletedExcalidrawElement[]): P | |
await Fonts.loadFontFaces(fontFamilies); | ||
} | ||
|
||
export async function fetchFontFromVault(url: string | URL): Promise<ArrayBuffer|undefined|string> { | ||
export async function fetchFontFromVault(url: string | URL): Promise<ArrayBuffer|undefined> { | ||
if(typeof url === "string" && !url.startsWith("data") && url.endsWith(".woff2")) { | ||
const filename = decodeURIComponent(url.substring(url.lastIndexOf("/")+1)); | ||
const arrayBuffer = hostPlugin.loadFontFromFile(filename) | ||
if(arrayBuffer) { | ||
return arrayBuffer; | ||
} | ||
if (["Assistant-Regular.woff2", "Assistant-Medium.woff2", "Assistant-SemiBold.woff2", "Assistant-Bold.woff2"].includes(filename)) { | ||
return "https://unpkg.com/@zsviczian/[email protected]/dist/excalidraw-assets/" + filename; | ||
} | ||
} | ||
return; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2751,6 +2751,11 @@ | |
resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.27.8.tgz#6667fac16c436b5434a387a34dedb013198f6e6e" | ||
integrity sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA== | ||
|
||
"@sindresorhus/merge-streams@^2.1.0": | ||
version "2.3.0" | ||
resolved "https://registry.yarnpkg.com/@sindresorhus/merge-streams/-/merge-streams-2.3.0.tgz#719df7fb41766bc143369eaa0dd56d8dc87c9958" | ||
integrity sha512-LtoMMhxAlorcGhmFYI+LhPgbPZCkgP6ra1YL604EeF6U98pLlQ3iWIGMdWSC+vWmPBWBNgmDBAhnAobLROJmwg== | ||
|
||
"@sitespeed.io/tracium@^0.3.3": | ||
version "0.3.3" | ||
resolved "https://registry.yarnpkg.com/@sitespeed.io/tracium/-/tracium-0.3.3.tgz#b497a4a8d5837db1fd9e3053c99b78f6c0e1f53b" | ||
|
@@ -4783,6 +4788,18 @@ [email protected]: | |
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.6.0.tgz#2798b04b071b0ecbff0dbb62a505a8efa4e19051" | ||
integrity sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw== | ||
|
||
[email protected]: | ||
version "12.0.2" | ||
resolved "https://registry.yarnpkg.com/copy-webpack-plugin/-/copy-webpack-plugin-12.0.2.tgz#935e57b8e6183c82f95bd937df658a59f6a2da28" | ||
integrity sha512-SNwdBeHyII+rWvee/bTnAYyO8vfVdcSTud4EIb6jcZ8inLeWucJE0DnxXQBjlQ5zlteuuvooGQy3LIyGxhvlOA== | ||
dependencies: | ||
fast-glob "^3.3.2" | ||
glob-parent "^6.0.1" | ||
globby "^14.0.0" | ||
normalize-path "^3.0.0" | ||
schema-utils "^4.2.0" | ||
serialize-javascript "^6.0.2" | ||
|
||
core-js-compat@^3.31.0, core-js-compat@^3.37.1, core-js-compat@^3.38.0: | ||
version "3.38.1" | ||
resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.38.1.tgz#2bc7a298746ca5a7bcb9c164bcb120f2ebc09a09" | ||
|
@@ -6434,6 +6451,13 @@ glob-parent@^5.1.2, glob-parent@~5.1.2: | |
dependencies: | ||
is-glob "^4.0.1" | ||
|
||
glob-parent@^6.0.1: | ||
version "6.0.2" | ||
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-6.0.2.tgz#6d237d99083950c79290f24c7642a3de9a28f9e3" | ||
integrity sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A== | ||
dependencies: | ||
is-glob "^4.0.3" | ||
|
||
glob-to-regexp@^0.4.1: | ||
version "0.4.1" | ||
resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e" | ||
|
@@ -6500,6 +6524,18 @@ globby@^11.1.0: | |
merge2 "^1.4.1" | ||
slash "^3.0.0" | ||
|
||
globby@^14.0.0: | ||
version "14.0.2" | ||
resolved "https://registry.yarnpkg.com/globby/-/globby-14.0.2.tgz#06554a54ccfe9264e5a9ff8eded46aa1e306482f" | ||
integrity sha512-s3Fq41ZVh7vbbe2PN3nrW7yC7U7MFVc5c98/iTl9c2GawNMKx/J648KQRW6WKkuU8GIbbh2IXfIRQjOZnXcTnw== | ||
dependencies: | ||
"@sindresorhus/merge-streams" "^2.1.0" | ||
fast-glob "^3.3.2" | ||
ignore "^5.2.4" | ||
path-type "^5.0.0" | ||
slash "^5.1.0" | ||
unicorn-magic "^0.1.0" | ||
|
||
glur@^1.1.2: | ||
version "1.1.2" | ||
resolved "https://registry.yarnpkg.com/glur/-/glur-1.1.2.tgz#f20ea36db103bfc292343921f1f91e83c3467689" | ||
|
@@ -6797,7 +6833,7 @@ ignore@^4.0.6: | |
resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" | ||
integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== | ||
|
||
ignore@^5.2.0: | ||
ignore@^5.2.0, ignore@^5.2.4: | ||
version "5.3.2" | ||
resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.3.2.tgz#3cd40e729f3643fd87cb04e50bf0eb722bc596f5" | ||
integrity sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g== | ||
|
@@ -8318,6 +8354,11 @@ path-type@^4.0.0: | |
resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" | ||
integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== | ||
|
||
path-type@^5.0.0: | ||
version "5.0.0" | ||
resolved "https://registry.yarnpkg.com/path-type/-/path-type-5.0.0.tgz#14b01ed7aea7ddf9c7c3f46181d4d04f9c785bb8" | ||
integrity sha512-5HviZNaZcfqP95rwpv+1HDgUamezbqdSYTyzjTvwtJSnIH+3vnbmWsItli8OFEndS984VT55M3jduxZbX351gg== | ||
|
||
pathe@^0.2.0: | ||
version "0.2.0" | ||
resolved "https://registry.yarnpkg.com/pathe/-/pathe-0.2.0.tgz#30fd7bbe0a0d91f0e60bae621f5d19e9e225c339" | ||
|
@@ -9196,7 +9237,7 @@ schema-utils@^3.0.0, schema-utils@^3.1.0, schema-utils@^3.1.1, schema-utils@^3.2 | |
ajv "^6.12.5" | ||
ajv-keywords "^3.5.2" | ||
|
||
schema-utils@^4.0.0: | ||
schema-utils@^4.0.0, schema-utils@^4.2.0: | ||
version "4.2.0" | ||
resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.2.0.tgz#70d7c93e153a273a805801882ebd3bff20d89c8b" | ||
integrity sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw== | ||
|
@@ -9260,7 +9301,7 @@ [email protected]: | |
range-parser "~1.2.1" | ||
statuses "2.0.1" | ||
|
||
serialize-javascript@^6.0.0, serialize-javascript@^6.0.1: | ||
serialize-javascript@^6.0.0, serialize-javascript@^6.0.1, serialize-javascript@^6.0.2: | ||
version "6.0.2" | ||
resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-6.0.2.tgz#defa1e055c83bf6d59ea805d8da862254eb6a6c2" | ||
integrity sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g== | ||
|
@@ -9401,6 +9442,11 @@ slash@^3.0.0: | |
resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" | ||
integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== | ||
|
||
slash@^5.1.0: | ||
version "5.1.0" | ||
resolved "https://registry.yarnpkg.com/slash/-/slash-5.1.0.tgz#be3adddcdf09ac38eebe8dcdc7b1a57a75b095ce" | ||
integrity sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg== | ||
|
||
slice-ansi@^3.0.0: | ||
version "3.0.0" | ||
resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-3.0.0.tgz#31ddc10930a1b7e0b67b08c96c2f49b77a789787" | ||
|
@@ -10175,6 +10221,11 @@ unicode-property-aliases-ecmascript@^2.0.0: | |
resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-2.1.0.tgz#43d41e3be698bd493ef911077c9b131f827e8ccd" | ||
integrity sha512-6t3foTQI9qne+OZoVQB/8x8rk2k1eVy1gRXhV3oFQ5T6R1dqQ1xtin3XqSlx3+ATBkliTaR/hHyJBm+LVPNM8w== | ||
|
||
unicorn-magic@^0.1.0: | ||
version "0.1.0" | ||
resolved "https://registry.yarnpkg.com/unicorn-magic/-/unicorn-magic-0.1.0.tgz#1bb9a51c823aaf9d73a8bfcd3d1a23dde94b0ce4" | ||
integrity sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ== | ||
|
||
union@~0.5.0: | ||
version "0.5.0" | ||
resolved "https://registry.yarnpkg.com/union/-/union-0.5.0.tgz#b2c11be84f60538537b846edb9ba266ba0090075" | ||
|