underpost 3.2.4 → 3.2.8

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.
Files changed (141) hide show
  1. package/.github/workflows/release.cd.yml +1 -2
  2. package/CHANGELOG.md +268 -1
  3. package/CLI-HELP.md +26 -13
  4. package/Dockerfile +0 -4
  5. package/README.md +3 -3
  6. package/bin/build.js +13 -3
  7. package/bin/deploy.js +570 -1
  8. package/bin/file.js +5 -0
  9. package/conf.js +11 -2
  10. package/jsconfig.json +1 -1
  11. package/manifests/cronjobs/dd-cron/dd-cron-backup.yaml +2 -3
  12. package/manifests/cronjobs/dd-cron/dd-cron-dns.yaml +2 -3
  13. package/manifests/deployment/dd-default-development/deployment.yaml +2 -6
  14. package/manifests/deployment/dd-test-development/deployment.yaml +136 -66
  15. package/manifests/deployment/dd-test-development/proxy.yaml +41 -5
  16. package/package.json +20 -11
  17. package/src/api/core/core.controller.js +10 -10
  18. package/src/api/core/core.service.js +10 -10
  19. package/src/api/default/default.controller.js +10 -10
  20. package/src/api/default/default.service.js +10 -10
  21. package/src/api/document/document.controller.js +12 -12
  22. package/src/api/document/document.model.js +10 -16
  23. package/src/api/file/file.controller.js +8 -8
  24. package/src/api/file/file.model.js +10 -10
  25. package/src/api/file/file.service.js +36 -36
  26. package/src/api/test/test.controller.js +8 -8
  27. package/src/api/test/test.service.js +8 -8
  28. package/src/api/user/guest.service.js +99 -0
  29. package/src/api/user/user.controller.js +6 -6
  30. package/src/api/user/user.model.js +8 -13
  31. package/src/api/user/user.service.js +3 -20
  32. package/src/cli/deploy.js +33 -30
  33. package/src/cli/fs.js +62 -5
  34. package/src/cli/image.js +43 -1
  35. package/src/cli/index.js +5 -1
  36. package/src/cli/release.js +58 -2
  37. package/src/cli/repository.js +35 -3
  38. package/src/cli/run.js +304 -38
  39. package/src/cli/ssh.js +1 -1
  40. package/src/cli/static.js +43 -115
  41. package/src/client/Default.index.js +21 -33
  42. package/src/client/components/core/404.js +4 -4
  43. package/src/client/components/core/500.js +4 -4
  44. package/src/client/components/core/Account.js +73 -60
  45. package/src/client/components/core/AgGrid.js +23 -33
  46. package/src/client/components/core/Alert.js +12 -13
  47. package/src/client/components/core/AppStore.js +1 -1
  48. package/src/client/components/core/Auth.js +20 -32
  49. package/src/client/components/core/Badge.js +7 -13
  50. package/src/client/components/core/BtnIcon.js +15 -17
  51. package/src/client/components/core/CalendarCore.js +42 -63
  52. package/src/client/components/core/Chat.js +13 -15
  53. package/src/client/components/core/ClientEvents.js +87 -0
  54. package/src/client/components/core/ColorPaletteElement.js +309 -0
  55. package/src/client/components/core/Content.js +17 -14
  56. package/src/client/components/core/Css.js +15 -71
  57. package/src/client/components/core/CssCore.js +12 -16
  58. package/src/client/components/core/D3Chart.js +4 -4
  59. package/src/client/components/core/Docs.js +60 -59
  60. package/src/client/components/core/DropDown.js +69 -91
  61. package/src/client/components/core/EventBus.js +92 -0
  62. package/src/client/components/core/EventsUI.js +14 -17
  63. package/src/client/components/core/FileExplorer.js +102 -234
  64. package/src/client/components/core/FullScreen.js +47 -75
  65. package/src/client/components/core/Input.js +24 -69
  66. package/src/client/components/core/Keyboard.js +25 -18
  67. package/src/client/components/core/KeyboardAvoidance.js +145 -0
  68. package/src/client/components/core/LoadingAnimation.js +25 -31
  69. package/src/client/components/core/LogIn.js +41 -41
  70. package/src/client/components/core/LogOut.js +23 -14
  71. package/src/client/components/core/Modal.js +397 -176
  72. package/src/client/components/core/NotificationManager.js +14 -18
  73. package/src/client/components/core/Panel.js +54 -50
  74. package/src/client/components/core/PanelForm.js +25 -125
  75. package/src/client/components/core/Polyhedron.js +110 -214
  76. package/src/client/components/core/PublicProfile.js +39 -32
  77. package/src/client/components/core/Recover.js +52 -48
  78. package/src/client/components/core/Responsive.js +88 -32
  79. package/src/client/components/core/RichText.js +9 -18
  80. package/src/client/components/core/Router.js +24 -3
  81. package/src/client/components/core/SearchBox.js +37 -37
  82. package/src/client/components/core/SignUp.js +39 -30
  83. package/src/client/components/core/SocketIo.js +31 -2
  84. package/src/client/components/core/SocketIoHandler.js +6 -6
  85. package/src/client/components/core/ToggleSwitch.js +8 -20
  86. package/src/client/components/core/ToolTip.js +5 -17
  87. package/src/client/components/core/Translate.js +56 -59
  88. package/src/client/components/core/Validator.js +26 -16
  89. package/src/client/components/core/Wallet.js +15 -26
  90. package/src/client/components/core/Worker.js +140 -25
  91. package/src/client/components/core/windowGetDimensions.js +7 -7
  92. package/src/client/components/default/{MenuDefault.js → AppShellDefault.js} +87 -87
  93. package/src/client/components/default/CssDefault.js +12 -12
  94. package/src/client/components/default/LogInDefault.js +6 -4
  95. package/src/client/components/default/LogOutDefault.js +6 -4
  96. package/src/client/components/default/RouterDefault.js +47 -0
  97. package/src/client/components/default/SettingsDefault.js +4 -4
  98. package/src/client/components/default/SignUpDefault.js +6 -4
  99. package/src/client/components/default/TranslateDefault.js +3 -3
  100. package/src/client/services/core/core.service.js +17 -49
  101. package/src/client/services/default/default.management.js +139 -242
  102. package/src/client/services/default/default.service.js +10 -16
  103. package/src/client/services/document/document.service.js +14 -19
  104. package/src/client/services/file/file.service.js +8 -13
  105. package/src/client/services/test/test.service.js +8 -13
  106. package/src/client/services/user/guest.service.js +79 -0
  107. package/src/client/services/user/user.management.js +5 -5
  108. package/src/client/services/user/user.service.js +14 -20
  109. package/src/client/ssr/body/404.js +3 -3
  110. package/src/client/ssr/body/500.js +3 -3
  111. package/src/client/ssr/body/CacheControl.js +5 -2
  112. package/src/client/ssr/body/DefaultSplashScreen.js +19 -12
  113. package/src/client/ssr/mailer/DefaultRecoverEmail.js +19 -20
  114. package/src/client/ssr/mailer/DefaultVerifyEmail.js +15 -16
  115. package/src/client/ssr/offline/Maintenance.js +12 -11
  116. package/src/client/ssr/offline/NoNetworkConnection.js +3 -3
  117. package/src/client/ssr/pages/Test.js +2 -2
  118. package/src/client/sw/core.sw.js +212 -0
  119. package/src/index.js +1 -1
  120. package/src/runtime/express/Dockerfile +4 -4
  121. package/src/runtime/lampp/Dockerfile +8 -7
  122. package/src/runtime/wp/Dockerfile +11 -17
  123. package/src/server/backup.js +1 -2
  124. package/src/server/client-build-docs.js +45 -46
  125. package/src/server/client-build.js +334 -60
  126. package/src/server/client-formatted.js +47 -16
  127. package/src/server/conf.js +29 -13
  128. package/src/server/cron.js +6 -8
  129. package/src/server/dns.js +2 -1
  130. package/src/server/ipfs-client.js +232 -91
  131. package/src/server/process.js +13 -27
  132. package/src/server/start.js +6 -3
  133. package/src/server/valkey.js +134 -235
  134. package/tsconfig.docs.json +15 -0
  135. package/typedoc.json +20 -0
  136. package/jsdoc.json +0 -52
  137. package/src/client/components/core/ColorPalette.js +0 -5267
  138. package/src/client/components/core/JoyStick.js +0 -80
  139. package/src/client/components/default/RoutesDefault.js +0 -49
  140. package/src/client/sw/default.sw.js +0 -127
  141. package/src/client/sw/template.sw.js +0 -84
@@ -5,16 +5,13 @@ import { Modal } from './Modal.js';
5
5
  import { Translate } from './Translate.js';
6
6
  import { append, htmls, s, sa } from './VanillaJs.js';
7
7
  import { getProxyPath } from './Router.js';
8
-
9
8
  let ThemesScope = [];
10
-
11
9
  // https://css.github.io/csso/csso.html
12
10
  // https://www.fontspace.com/
13
11
  // https://www.1001fonts.com/
14
-
15
- const Css = {
12
+ class Css {
16
13
  // Menu button container transition styles
17
- menuButtonContainer: () => css`
14
+ static menuButtonContainer = () => css`
18
15
  .main-btn-menu {
19
16
  transition: all 0.2s ease-in-out;
20
17
  position: relative;
@@ -44,9 +41,8 @@ const Css = {
44
41
  width: 80%;
45
42
  background: currentColor;
46
43
  }
47
- `,
48
-
49
- loadThemes: async function (themes = []) {
44
+ `;
45
+ static async loadThemes(themes = []) {
50
46
  ThemesScope = [];
51
47
  for (const themeOptions of themes) addTheme(themeOptions);
52
48
  // if (!ThemesScope.find((t) => t.dark)) addTheme(CssCoreDark);
@@ -58,31 +54,29 @@ const Css = {
58
54
  const localStorageTheme = localStorage.getItem('_theme');
59
55
  if (localStorageTheme && Themes[localStorageTheme]) {
60
56
  const themeOption = ThemesScope.find((t) => t.theme === localStorageTheme);
61
- if (themeOption) return await this.Init(themeOption);
57
+ if (themeOption) return await Css.instance(themeOption);
62
58
  }
63
- await this.Init();
64
- },
65
- Init: async function (options) {
59
+ await Css.instance();
60
+ }
61
+ static async instance(options) {
66
62
  if (!options) options = ThemesScope[0];
67
63
  const { theme } = options;
68
-
69
64
  // Inject menu button container styles
70
65
  const styleId = 'menu-btn-container-styles';
71
66
  if (!document.getElementById(styleId)) {
72
67
  const style = document.createElement('style');
73
68
  style.id = styleId;
74
- style.textContent = this.menuButtonContainer();
69
+ style.textContent = Css.menuButtonContainer();
75
70
  document.head.appendChild(style);
76
71
  }
77
-
78
72
  return await Themes[theme](options);
79
- },
80
- RenderSetting: async function () {
73
+ }
74
+ static async RenderSetting() {
81
75
  return html` <div class="in section-mp">
82
- ${await DropDown.Render({
76
+ ${await DropDown.instance({
83
77
  id: 'settings-theme',
84
78
  value: Css.currentTheme,
85
- label: html`${Translate.Render('theme')}`,
79
+ label: html`${Translate.instance('theme')}`,
86
80
  data: ThemesScope.map((themeOption) => {
87
81
  return {
88
82
  display: html`<i class="fa-solid fa-brush"></i> ${themeOption.theme}`,
@@ -92,9 +86,8 @@ const Css = {
92
86
  }),
93
87
  })}
94
88
  </div>`;
95
- },
96
- };
97
-
89
+ }
90
+ }
98
91
  const barLabels = (options) => {
99
92
  return {
100
93
  img: {
@@ -135,7 +128,6 @@ const barLabels = (options) => {
135
128
  },
136
129
  };
137
130
  };
138
-
139
131
  const barConfig = (options) => {
140
132
  const { barButtonsIconTheme } = options;
141
133
  return {
@@ -163,7 +155,6 @@ const barConfig = (options) => {
163
155
  },
164
156
  };
165
157
  };
166
-
167
158
  const renderDefaultWindowsModalButtonContent = (options) => {
168
159
  const { barButtonsIconTheme, htmlRender } = options;
169
160
  const barConfigInstance = barConfig(options);
@@ -177,16 +168,13 @@ const renderDefaultWindowsModalButtonContent = (options) => {
177
168
  });
178
169
  return { barConfig: barConfigInstance };
179
170
  };
180
-
181
171
  let darkTheme = true;
182
172
  const ThemeEvents = {};
183
173
  const TriggerThemeEvents = () => {
184
174
  localStorage.setItem('_theme', Css.currentTheme);
185
175
  Object.keys(ThemeEvents).map((keyEvent) => ThemeEvents[keyEvent]());
186
176
  };
187
-
188
177
  const Themes = {};
189
-
190
178
  const addTheme = (options) => {
191
179
  ThemesScope.push(options);
192
180
  Themes[options.theme] = async (barOptions) => {
@@ -213,7 +201,6 @@ const addTheme = (options) => {
213
201
  };
214
202
  };
215
203
  };
216
-
217
204
  const borderChar = (px, color, selectors, hover = false) => {
218
205
  if (selectors) {
219
206
  return selectors
@@ -284,7 +271,6 @@ const renderMediaQuery = (mediaData) => {
284
271
  .join('')}
285
272
  `;
286
273
  };
287
-
288
274
  const renderStatus = (status, options) => {
289
275
  switch (status) {
290
276
  case 'success':
@@ -303,9 +289,7 @@ const renderStatus = (status, options) => {
303
289
  return html``;
304
290
  }
305
291
  };
306
-
307
292
  const dynamicColTokens = {};
308
-
309
293
  const dynamicCol = (options = { containerSelector: '', id: '', type: '', limit: 900 }) => {
310
294
  const { containerSelector, id } = options;
311
295
  const limitCol = options?.limit ? options.limit : 900;
@@ -339,7 +323,6 @@ const dynamicCol = (options = { containerSelector: '', id: '', type: '', limit:
339
323
  `,
340
324
  );
341
325
  break;
342
-
343
326
  case 'search-inputs':
344
327
  if (s(`.${containerSelector}`).offsetWidth < limitCol)
345
328
  htmls(
@@ -369,7 +352,6 @@ const dynamicCol = (options = { containerSelector: '', id: '', type: '', limit:
369
352
  `,
370
353
  );
371
354
  break;
372
-
373
355
  default:
374
356
  if (s(`.${containerSelector}`).offsetWidth < 900)
375
357
  htmls(
@@ -404,7 +386,6 @@ const dynamicCol = (options = { containerSelector: '', id: '', type: '', limit:
404
386
  });
405
387
  return html` <style class="style-${id}-col"></style>`;
406
388
  };
407
-
408
389
  const renderBubbleDialog = async function (
409
390
  options = {
410
391
  id: '',
@@ -435,7 +416,6 @@ const renderBubbleDialog = async function (
435
416
  left: 57%;
436
417
  `;
437
418
  break;
438
-
439
419
  default:
440
420
  break;
441
421
  }
@@ -476,7 +456,6 @@ const renderBubbleDialog = async function (
476
456
  ${await html()}
477
457
  </div>`;
478
458
  };
479
-
480
459
  const typeWriter = async function ({ id, html, seconds, endHideBlink, container }) {
481
460
  if (!seconds) seconds = 2;
482
461
  return new Promise((resolve) => {
@@ -533,7 +512,6 @@ const typeWriter = async function ({ id, html, seconds, endHideBlink, container
533
512
  }, seconds * 1000);
534
513
  });
535
514
  };
536
-
537
515
  const renderCssAttr = (options) =>
538
516
  `${
539
517
  options && options.style
@@ -542,12 +520,10 @@ const renderCssAttr = (options) =>
542
520
  .join(`\n`)
543
521
  : ''
544
522
  }`;
545
-
546
523
  const renderStyleTag = (styleSelector = 'style-abc', selector, options) =>
547
524
  html`<style class="${styleSelector}">
548
525
  ${selector} { ${renderCssAttr(options)} }
549
526
  </style>`;
550
-
551
527
  function getTranslate3d(el) {
552
528
  const values = el.style.transform.split(/\w+\(|\);?/);
553
529
  if (!values[1] || !values[1].length) {
@@ -555,7 +531,6 @@ function getTranslate3d(el) {
555
531
  }
556
532
  return values[1].split(/,\s?/g);
557
533
  }
558
-
559
534
  const dashRange = ({ selector, color }) => {
560
535
  return html`
561
536
  <style>
@@ -653,7 +628,6 @@ const triangle = {
653
628
  ></div>`;
654
629
  },
655
630
  };
656
-
657
631
  const getSectionsStringData = (offsetWidth, text) => {
658
632
  const sectionsIndex = [];
659
633
  const everyXChar = parseInt(offsetWidth / 4);
@@ -662,7 +636,6 @@ const getSectionsStringData = (offsetWidth, text) => {
662
636
  .map((t) => splitEveryXChar(t + '.', everyXChar, ['.', ' ']))
663
637
  .flat()
664
638
  .filter((p) => p !== '.' && p.trim());
665
-
666
639
  let currentIndex = [0];
667
640
  let pi = -1;
668
641
  for (const p of phraseArray) {
@@ -680,7 +653,6 @@ const getSectionsStringData = (offsetWidth, text) => {
680
653
  }
681
654
  return { phraseArray, sectionsIndex };
682
655
  };
683
-
684
656
  const typeWriteSectionsString = ({ container, phraseArray, rangeArraySectionIndex }) =>
685
657
  new Promise((resolve) => {
686
658
  let cumulativeSeconds = 0;
@@ -704,9 +676,7 @@ const typeWriteSectionsString = ({ container, phraseArray, rangeArraySectionInde
704
676
  cumulativeSeconds += seconds;
705
677
  }
706
678
  });
707
-
708
679
  const cssBrowserCodes = ['webkit', 'moz', 'ms', 'o'];
709
-
710
680
  const scrollBarLightRender = () => {
711
681
  return cssBrowserCodes
712
682
  .map(
@@ -744,28 +714,22 @@ const scrollBarLightRender = () => {
744
714
  )
745
715
  .join('');
746
716
  };
747
-
748
717
  // adjustHex: supports #RGB #RGBA #RRGGBB #RRGGBBAA
749
718
  // preserves alpha channel if present (does not modify it)
750
719
  // usage: adjustHex('#24FBFFFF', 0.1)
751
-
752
720
  function adjustHex(hex, factor = 0.1, options = {}) {
753
721
  if (typeof hex !== 'string') throw new TypeError('hex must be a string');
754
722
  if (typeof factor !== 'number') throw new TypeError('factor must be a number');
755
-
756
723
  // normalize factor: allow -100..100 or -1..1
757
724
  if (factor > 1 && factor <= 100) factor = factor / 100;
758
725
  if (factor < -1 && factor >= -100) factor = factor / 100;
759
726
  factor = Math.max(-1, Math.min(1, factor));
760
-
761
727
  const mode = options.mode === 'hsl' ? 'hsl' : 'mix';
762
-
763
728
  // normalize hex: accept 3,4,6,8 (with or without #)
764
729
  let h = hex.replace(/^#/, '').trim();
765
730
  if (![3, 4, 6, 8].includes(h.length)) {
766
731
  throw new Error('Invalid hex format — expected 3, 4, 6 or 8 hex digits');
767
732
  }
768
-
769
733
  // expand shorthand (#RGB or #RGBA -> #RRGGBB or #RRGGBBAA)
770
734
  if (h.length === 3 || h.length === 4) {
771
735
  h = h
@@ -773,22 +737,17 @@ function adjustHex(hex, factor = 0.1, options = {}) {
773
737
  .map((c) => c + c)
774
738
  .join('');
775
739
  }
776
-
777
740
  const hasAlpha = h.length === 8;
778
-
779
741
  const r = parseInt(h.slice(0, 2), 16);
780
742
  const g = parseInt(h.slice(2, 4), 16);
781
743
  const b = parseInt(h.slice(4, 6), 16);
782
744
  const a = hasAlpha ? parseInt(h.slice(6, 8), 16) : null; // keep alpha as-is if present
783
-
784
745
  const clamp = (v, a0 = 0, z = 255) => Math.max(a0, Math.min(z, v));
785
-
786
746
  const rgbToHex = (rr, gg, bb, aa = null) => {
787
747
  const parts = [rr, gg, bb].map((v) => Math.round(v).toString(16).padStart(2, '0'));
788
748
  if (aa !== null) parts.push(Math.round(aa).toString(16).padStart(2, '0'));
789
749
  return '#' + parts.join('').toLowerCase();
790
750
  };
791
-
792
751
  if (mode === 'mix') {
793
752
  // positive: mix toward white (255); negative: mix toward black (0)
794
753
  const mixChannel = (c) => {
@@ -799,7 +758,6 @@ function adjustHex(hex, factor = 0.1, options = {}) {
799
758
  return clamp(Math.round(c * (1 - aFactor)));
800
759
  }
801
760
  };
802
-
803
761
  const rr = mixChannel(r);
804
762
  const gg = mixChannel(g);
805
763
  const bb = mixChannel(b);
@@ -833,7 +791,6 @@ function adjustHex(hex, factor = 0.1, options = {}) {
833
791
  }
834
792
  return { h, s, l };
835
793
  };
836
-
837
794
  const hslToRgb = (h, s, l) => {
838
795
  let r, g, b;
839
796
  if (s === 0) {
@@ -855,7 +812,6 @@ function adjustHex(hex, factor = 0.1, options = {}) {
855
812
  }
856
813
  return { r: r * 255, g: g * 255, b: b * 255 };
857
814
  };
858
-
859
815
  const { h: hh, s: ss, l: ll } = rgbToHsl(r, g, b);
860
816
  // add factor to lightness (factor already normalized -1..1)
861
817
  let newL = ll + factor;
@@ -864,13 +820,11 @@ function adjustHex(hex, factor = 0.1, options = {}) {
864
820
  return rgbToHex(r2, g2, b2, a);
865
821
  }
866
822
  }
867
-
868
823
  // Examples (uncomment to test):
869
824
  // console.log(adjustHex('#24FBFFFF', 0.1)); // accepts 8-digit input
870
825
  // console.log(adjustHex('#24FBFF', 0.1)); // 6-digit
871
826
  // console.log(adjustHex('#4bf', -0.2)); // 3-digit
872
827
  // console.log(adjustHex('#4bf8', -0.2)); // 4-digit (with alpha)
873
-
874
828
  // Convenience helpers:
875
829
  function lightenHex(hex, percentOr01 = 0.1, options = {}) {
876
830
  return adjustHex(hex, Math.abs(percentOr01), options);
@@ -878,7 +832,6 @@ function lightenHex(hex, percentOr01 = 0.1, options = {}) {
878
832
  function darkenHex(hex, percentOr01 = 0.1, options = {}) {
879
833
  return adjustHex(hex, -Math.abs(percentOr01), options);
880
834
  }
881
-
882
835
  const subThemeManager = {
883
836
  render: async function () {
884
837
  if (darkTheme && this.renderDark) {
@@ -947,7 +900,6 @@ const subThemeManager = {
947
900
  };
948
901
  },
949
902
  };
950
-
951
903
  const scrollBarDarkRender = () => {
952
904
  return cssBrowserCodes
953
905
  .map(
@@ -986,7 +938,6 @@ const scrollBarDarkRender = () => {
986
938
  )
987
939
  .join('');
988
940
  };
989
-
990
941
  const renderWave = ({ id }) => {
991
942
  return html`
992
943
  <style>
@@ -1071,7 +1022,6 @@ const renderWave = ({ id }) => {
1071
1022
  </div>
1072
1023
  `;
1073
1024
  };
1074
-
1075
1025
  const cssTokensEffect = {};
1076
1026
  const cssTokensContainer = {};
1077
1027
  const cssEffect = async (containerSelector, event) => {
@@ -1100,7 +1050,6 @@ const cssEffect = async (containerSelector, event) => {
1100
1050
  delete cssTokensEffect[id];
1101
1051
  }, 600);
1102
1052
  };
1103
-
1104
1053
  const imageShimmer = () =>
1105
1054
  html`<div
1106
1055
  class="abs center ssr-shimmer-search-box"
@@ -1125,10 +1074,8 @@ const imageShimmer = () =>
1125
1074
  <i class="fa-solid fa-photo-film"></i>
1126
1075
  </div>
1127
1076
  </div>`;
1128
-
1129
1077
  const renderChessPattern = (patternSize = 20) =>
1130
1078
  `background: repeating-conic-gradient(#808080 0 25%, #0000 0 50%) 50% / ${patternSize}px ${patternSize}px`;
1131
-
1132
1079
  const extractBackgroundImageUrl = (element) => {
1133
1080
  const style = window.getComputedStyle(element);
1134
1081
  const imageString = style.backgroundImage;
@@ -1138,15 +1085,12 @@ const extractBackgroundImageUrl = (element) => {
1138
1085
  if (!foundUrl) return null;
1139
1086
  return foundUrl;
1140
1087
  };
1141
-
1142
1088
  const simpleIconsRender = (selector) => {
1143
1089
  sa(selector).forEach((el) => {
1144
1090
  el.src = `https://cdn.simpleicons.org/coveralls/${rgbToHex(window.getComputedStyle(s('html')).color)}`;
1145
1091
  });
1146
1092
  };
1147
-
1148
1093
  const styleFactory = (payload, plain = '') => `style="${renderCssAttr({ style: payload })} ${plain}"`;
1149
-
1150
1094
  export {
1151
1095
  Css,
1152
1096
  Themes,
@@ -3,7 +3,6 @@ import { borderChar, boxShadow, scrollBarDarkRender, scrollBarLightRender } from
3
3
  import { LoadingAnimation } from './LoadingAnimation.js';
4
4
  import { append, s } from './VanillaJs.js';
5
5
  import { getProxyPath } from './Router.js';
6
-
7
6
  const CssCommonCore = async () => {
8
7
  if (!s(`.fa-link`))
9
8
  append(
@@ -239,11 +238,10 @@ const CssCommonCore = async () => {
239
238
  ${boxShadow({ selector: '.account-profile-image' })}
240
239
  <div class="ag-grid-style"></div>`;
241
240
  };
242
-
243
- const CssCoreDark = {
244
- theme: 'core-dark',
245
- dark: true,
246
- render: async () =>
241
+ class CssCoreDark {
242
+ static theme = 'core-dark';
243
+ static dark = true;
244
+ static render = async () =>
247
245
  (await CssCommonCore()) +
248
246
  html`
249
247
  <style>
@@ -552,13 +550,12 @@ const CssCoreDark = {
552
550
  }
553
551
  </style>
554
552
  ${scrollBarDarkRender()} ${borderChar(1, 'black', ['.main-body-btn-container'])}
555
- `,
556
- };
557
-
558
- const CssCoreLight = {
559
- theme: 'core-light',
560
- dark: false,
561
- render: async () =>
553
+ `;
554
+ }
555
+ class CssCoreLight {
556
+ static theme = 'core-light';
557
+ static dark = false;
558
+ static render = async () =>
562
559
  (await CssCommonCore()) +
563
560
  html`
564
561
  <style>
@@ -879,7 +876,6 @@ const CssCoreLight = {
879
876
  }
880
877
  </style>
881
878
  ${scrollBarLightRender()} ${borderChar(1, 'white', ['.main-body-btn-container'])}
882
- `,
883
- };
884
-
879
+ `;
880
+ }
885
881
  export { CssCoreDark, CssCoreLight };
@@ -2,8 +2,8 @@ import { connectedScatterplotChart } from '../chart/connectedScatterplotChart.js
2
2
 
3
3
  // https://takanori-fujiwara.github.io/d3-gallery-javascript/
4
4
 
5
- const D3Chart = {
6
- Render: async function () {
5
+ class D3Chart {
6
+ static async instance() {
7
7
  setTimeout(async () => {
8
8
  const driving = await d3.csv('/data/driving.csv', d3.autoType);
9
9
 
@@ -38,7 +38,7 @@ const D3Chart = {
38
38
  <div class="in chart-container"></div>
39
39
  <div class="in chart-panel"></div>
40
40
  `;
41
- },
42
- };
41
+ }
42
+ }
43
43
 
44
44
  export { D3Chart };