@social-mail/social-mail-client 1.8.363 → 1.8.365

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@social-mail/social-mail-client",
3
- "version": "1.8.363",
3
+ "version": "1.8.365",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -1,9 +1,7 @@
1
+ import { UMD } from "@web-atoms/core/dist/core/types";
1
2
  import { AtomControl } from "@web-atoms/core/dist/web/controls/AtomControl";
2
3
  import type { Chart as C1, ChartData, ChartTypeRegistry } from "chart.js";
3
4
 
4
-
5
- let scriptInstalled:Promise<void>;
6
-
7
5
  declare let Chart;
8
6
 
9
7
  export default abstract class ChartControl extends AtomControl {
@@ -14,10 +12,10 @@ export default abstract class ChartControl extends AtomControl {
14
12
 
15
13
  constructor(app, e) {
16
14
  super(app,e);
17
- scriptInstalled ??= app.installScript(`https://cdn.jsdelivr.net/npm/chart.js@4.5.0/dist/chart.umd.min.js`);
18
15
 
19
16
  this.runAfterInit(() => this.app.runAsync(async () => {
20
- await scriptInstalled;
17
+ const m = await UMD.import("https://cdn.jsdelivr.net/npm/chart.js@4.5.0/dist/chart.umd.min.js" as any) as any;
18
+ Chart = m.Chart;
21
19
  await this.init();
22
20
  }));
23
21