pyloid 0.22.0.dev3__tar.gz → 0.22.0.dev4__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pyloid
3
- Version: 0.22.0.dev3
3
+ Version: 0.22.0.dev4
4
4
  Summary:
5
5
  Author: aesthetics-of-record
6
6
  Author-email: 111675679+aesthetics-of-record@users.noreply.github.com
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "pyloid"
3
- version = "0.22.0-dev3"
3
+ version = "0.22.0-dev4"
4
4
  description = ""
5
5
  authors = ["aesthetics-of-record <111675679+aesthetics-of-record@users.noreply.github.com>"]
6
6
  readme = "README.md"
@@ -538,19 +538,23 @@ class _BrowserWindow:
538
538
  });
539
539
 
540
540
  function updateTheme(theme) {
541
- document.documentElement.setAttribute(
542
- 'data-pyloid-theme',
543
- theme
544
- );
541
+ if (typeof document !== 'undefined') {
542
+ document.documentElement.setAttribute(
543
+ 'data-pyloid-theme',
544
+ theme
545
+ );
546
+ }
545
547
  }
546
548
 
547
549
  // 테마 변경 이벤트 리스너
548
- document.addEventListener('themeChange', (e) => {
549
- console.log('themeChange event received:', e);
550
- updateTheme(e.detail.theme);
551
- });
552
-
553
- updateTheme('%s');
550
+ if (typeof document !== 'undefined') {
551
+ document.addEventListener('themeChange', (e) => {
552
+ console.log('themeChange event received:', e);
553
+ updateTheme(e.detail.theme);
554
+ });
555
+
556
+ updateTheme('%s');
557
+ }
554
558
 
555
559
 
556
560
  // Dispatch a custom event to signal that the initialization is ready
File without changes
File without changes