@formulaxjs/kity-runtime 0.2.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -813,14 +813,11 @@ var FontInstallerModule = class {
813
813
  count += 1;
814
814
  fontInfo.meta.src = resolveFontSource(this.fonts, this.resource, fontInfo.meta.src);
815
815
  this.createFontStyle(fontInfo);
816
- preloadFont(this.doc, fontInfo).then(() => {
817
- applyFonts(this.doc, fontInfo);
818
- }).catch(() => void 0).finally(() => {
819
- count -= 1;
820
- if (count === 0) {
821
- complete(this.doc, callback);
822
- }
823
- });
816
+ applyFonts(this.doc, fontInfo);
817
+ count -= 1;
818
+ if (count === 0) {
819
+ complete(this.doc, callback);
820
+ }
824
821
  });
825
822
  },
826
823
  createFontStyle: function(fontInfo) {
@@ -831,13 +828,6 @@ var FontInstallerModule = class {
831
828
  this.doc.head.appendChild(stylesheet);
832
829
  }
833
830
  });
834
- function preloadFont(doc, fontInfo) {
835
- const view = doc.defaultView ?? window;
836
- if (view.fetch) {
837
- return view.fetch(fontInfo.meta.src, { method: "GET" }).then(() => void 0);
838
- }
839
- return Promise.resolve();
840
- }
841
831
  function resolveFontSource(fonts, resourceBase, originalSrc) {
842
832
  const directMatch = fonts[originalSrc];
843
833
  if (directMatch) {
@@ -5471,4 +5461,4 @@ export {
5471
5461
  install_default as default,
5472
5462
  installLegacyKityFormulaRuntime
5473
5463
  };
5474
- //# sourceMappingURL=install-ARHGHFNJ.js.map
5464
+ //# sourceMappingURL=install-WDCVVIMM.js.map