@seelen-ui/lib 2.3.6 → 2.4.1-next.20250825015552

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 (537) hide show
  1. package/esm/constants/mod.d.ts +17 -9
  2. package/esm/constants/mod.d.ts.map +1 -1
  3. package/esm/constants/mod.js +6 -4
  4. package/esm/handlers/commands.d.ts +17 -8
  5. package/esm/handlers/commands.d.ts.map +1 -1
  6. package/esm/handlers/commands.js +17 -8
  7. package/esm/handlers/events.d.ts +3 -5
  8. package/esm/handlers/events.d.ts.map +1 -1
  9. package/esm/handlers/events.js +3 -5
  10. package/esm/lib.d.ts +1 -1
  11. package/esm/lib.d.ts.map +1 -1
  12. package/esm/lib.js +1 -1
  13. package/esm/resource/mod.d.ts +6 -0
  14. package/esm/resource/mod.d.ts.map +1 -0
  15. package/esm/state/icon_pack.d.ts +23 -52
  16. package/esm/state/icon_pack.d.ts.map +1 -1
  17. package/esm/state/icon_pack.js +137 -131
  18. package/esm/state/mod.d.ts +2 -1
  19. package/esm/state/mod.d.ts.map +1 -1
  20. package/esm/state/mod.js +1 -0
  21. package/esm/state/plugin/mod.d.ts +1 -1
  22. package/esm/state/plugin/mod.d.ts.map +1 -1
  23. package/esm/state/settings/mod.d.ts +6 -5
  24. package/esm/state/settings/mod.d.ts.map +1 -1
  25. package/esm/state/settings/mod.js +5 -8
  26. package/esm/state/settings/settings_by_monitor.d.ts +1 -4
  27. package/esm/state/settings/settings_by_monitor.d.ts.map +1 -1
  28. package/esm/state/settings/settings_by_monitor.js +0 -8
  29. package/esm/state/settings_by_app.d.ts +1 -1
  30. package/esm/state/settings_by_app.d.ts.map +1 -1
  31. package/esm/state/theme/mod.d.ts +19 -3
  32. package/esm/state/theme/mod.d.ts.map +1 -1
  33. package/esm/state/theme/mod.js +96 -0
  34. package/esm/state/wallpaper/mod.d.ts +15 -0
  35. package/esm/state/wallpaper/mod.d.ts.map +1 -0
  36. package/esm/state/wallpaper/mod.js +31 -0
  37. package/esm/state/weg_items.d.ts +6 -9
  38. package/esm/state/weg_items.d.ts.map +1 -1
  39. package/esm/state/weg_items.js +9 -17
  40. package/esm/state/widget/mod.d.ts +9 -4
  41. package/esm/state/widget/mod.d.ts.map +1 -1
  42. package/esm/state/widget/mod.js +31 -12
  43. package/esm/state/wm_layout.d.ts +4 -5
  44. package/esm/state/wm_layout.d.ts.map +1 -1
  45. package/esm/state/wm_layout.js +3 -8
  46. package/esm/system_state/bluetooth/mod.d.ts +2 -2
  47. package/esm/system_state/bluetooth/mod.d.ts.map +1 -1
  48. package/esm/system_state/language.d.ts +1 -1
  49. package/esm/system_state/language.d.ts.map +1 -1
  50. package/esm/system_state/monitors.d.ts +1 -1
  51. package/esm/system_state/monitors.d.ts.map +1 -1
  52. package/esm/system_state/ui_colors.d.ts +1 -1
  53. package/esm/system_state/ui_colors.d.ts.map +1 -1
  54. package/esm/system_state/ui_colors.js +8 -2
  55. package/esm/system_state/user.d.ts +1 -1
  56. package/esm/system_state/user.d.ts.map +1 -1
  57. package/esm/types/CssVariableName.d.ts +5 -0
  58. package/esm/types/CssVariableName.d.ts.map +1 -0
  59. package/esm/types/CustomIconPackEntry.d.ts +16 -0
  60. package/esm/types/CustomIconPackEntry.d.ts.map +1 -0
  61. package/esm/types/DesktopWorkspace.d.ts +5 -0
  62. package/esm/types/DesktopWorkspace.d.ts.map +1 -1
  63. package/esm/types/FocusedApp.d.ts +4 -0
  64. package/esm/types/FocusedApp.d.ts.map +1 -1
  65. package/esm/types/FocusedApp.js +0 -1
  66. package/esm/types/Icon.d.ts +17 -10
  67. package/esm/types/Icon.d.ts.map +1 -1
  68. package/esm/types/IconPack.d.ts +7 -19
  69. package/esm/types/IconPack.d.ts.map +1 -1
  70. package/esm/types/IconPackEntry.d.ts +11 -0
  71. package/esm/types/IconPackEntry.d.ts.map +1 -0
  72. package/esm/types/IconPackId.d.ts +3 -0
  73. package/esm/types/IconPackId.d.ts.map +1 -1
  74. package/esm/types/MediaPlayer.d.ts +2 -0
  75. package/esm/types/MediaPlayer.d.ts.map +1 -1
  76. package/esm/types/MediaPlayerTimeline.d.ts +24 -0
  77. package/esm/types/MediaPlayerTimeline.d.ts.map +1 -0
  78. package/esm/types/MixBlendMode.d.ts +2 -0
  79. package/esm/types/MixBlendMode.d.ts.map +1 -0
  80. package/esm/types/MonitorConfiguration.d.ts +0 -5
  81. package/esm/types/MonitorConfiguration.d.ts.map +1 -1
  82. package/esm/types/MonitorId.d.ts +2 -0
  83. package/esm/types/MonitorId.d.ts.map +1 -0
  84. package/esm/types/MonitorSettingsByWidget.d.ts +1 -10
  85. package/esm/types/MonitorSettingsByWidget.d.ts.map +1 -1
  86. package/esm/types/ObjectFit.d.ts +2 -0
  87. package/esm/types/ObjectFit.d.ts.map +1 -0
  88. package/esm/types/ObjectPosition.d.ts +2 -0
  89. package/esm/types/ObjectPosition.d.ts.map +1 -0
  90. package/esm/types/PhysicalMonitor.d.ts +2 -1
  91. package/esm/types/PhysicalMonitor.d.ts.map +1 -1
  92. package/esm/types/PlaybackSpeed.d.ts +2 -0
  93. package/esm/types/PlaybackSpeed.d.ts.map +1 -0
  94. package/esm/types/PluginId.d.ts +3 -0
  95. package/esm/types/PluginId.d.ts.map +1 -1
  96. package/esm/types/Resource.d.ts +35 -3
  97. package/esm/types/Resource.d.ts.map +1 -1
  98. package/esm/types/ResourceAttribute.d.ts +2 -0
  99. package/esm/types/ResourceAttribute.d.ts.map +1 -0
  100. package/esm/types/ResourceId.d.ts +4 -2
  101. package/esm/types/ResourceId.d.ts.map +1 -1
  102. package/esm/types/ResourceMetadata.d.ts +2 -6
  103. package/esm/types/ResourceMetadata.d.ts.map +1 -1
  104. package/esm/types/SeelenCommandArgument.d.ts +43 -18
  105. package/esm/types/SeelenCommandArgument.d.ts.map +1 -1
  106. package/esm/types/SeelenCommandClosePopupArgs.d.ts +4 -0
  107. package/esm/types/SeelenCommandClosePopupArgs.d.ts.map +1 -0
  108. package/esm/types/SeelenCommandClosePopupArgs.js +2 -0
  109. package/esm/types/SeelenCommandCreatePopupArgs.d.ts +5 -0
  110. package/esm/types/SeelenCommandCreatePopupArgs.d.ts.map +1 -0
  111. package/esm/types/SeelenCommandRemoveResourceArgs.d.ts +7 -0
  112. package/esm/types/SeelenCommandRemoveResourceArgs.d.ts.map +1 -0
  113. package/esm/types/SeelenCommandRequestToUserInputShortcutArgs.d.ts +4 -0
  114. package/esm/types/SeelenCommandRequestToUserInputShortcutArgs.d.ts.map +1 -0
  115. package/esm/types/SeelenCommandRequestToUserInputShortcutArgs.js +2 -0
  116. package/esm/types/SeelenCommandReturn.d.ts +38 -16
  117. package/esm/types/SeelenCommandReturn.d.ts.map +1 -1
  118. package/esm/types/SeelenCommandSetNativeShellWallpaperArgs.d.ts +4 -0
  119. package/esm/types/SeelenCommandSetNativeShellWallpaperArgs.d.ts.map +1 -0
  120. package/esm/types/SeelenCommandSetNativeShellWallpaperArgs.js +2 -0
  121. package/esm/types/SeelenCommandStateGetWegItemsArgs.d.ts +5 -0
  122. package/esm/types/SeelenCommandStateGetWegItemsArgs.d.ts.map +1 -0
  123. package/esm/types/SeelenCommandStateSetCustomIconPackArgs.d.ts +5 -0
  124. package/esm/types/SeelenCommandStateSetCustomIconPackArgs.d.ts.map +1 -0
  125. package/esm/types/SeelenCommandSwitchWorkspaceArgs.d.ts +2 -0
  126. package/esm/types/SeelenCommandSwitchWorkspaceArgs.d.ts.map +1 -1
  127. package/esm/types/SeelenCommandSwitchWorkspaceArgs.js +0 -1
  128. package/esm/types/SeelenCommandUpdatePopupArgs.d.ts +6 -0
  129. package/esm/types/SeelenCommandUpdatePopupArgs.d.ts.map +1 -0
  130. package/esm/types/SeelenEventPayload.d.ts +10 -14
  131. package/esm/types/SeelenEventPayload.d.ts.map +1 -1
  132. package/esm/types/SeelenWallSettings.d.ts +5 -2
  133. package/esm/types/SeelenWallSettings.d.ts.map +1 -1
  134. package/esm/types/SeelenWegSettings.d.ts +4 -0
  135. package/esm/types/SeelenWegSettings.d.ts.map +1 -1
  136. package/esm/types/Settings.d.ts +23 -16
  137. package/esm/types/Settings.d.ts.map +1 -1
  138. package/esm/types/SettingsByWidget.d.ts +19 -3
  139. package/esm/types/SettingsByWidget.d.ts.map +1 -1
  140. package/esm/types/SharedIconPackEntry.d.ts +12 -0
  141. package/esm/types/SharedIconPackEntry.d.ts.map +1 -0
  142. package/esm/types/SluHotkey.d.ts +8 -0
  143. package/esm/types/SluHotkey.d.ts.map +1 -0
  144. package/esm/types/SluHotkeyAction.d.ts +84 -0
  145. package/esm/types/SluHotkeyAction.d.ts.map +1 -0
  146. package/esm/types/SluHotkeyAction.js +2 -0
  147. package/esm/types/SluPopupConfig.d.ts +2 -0
  148. package/esm/types/SluPopupConfig.d.ts.map +1 -1
  149. package/esm/types/SluShortcutsSettings.d.ts +6 -0
  150. package/esm/types/SluShortcutsSettings.d.ts.map +1 -0
  151. package/esm/types/Theme.d.ts +5 -0
  152. package/esm/types/Theme.d.ts.map +1 -1
  153. package/esm/types/ThemeConfigDefinition.d.ts +6 -0
  154. package/esm/types/ThemeConfigDefinition.d.ts.map +1 -0
  155. package/esm/types/ThemeConfigGroup.d.ts +7 -0
  156. package/esm/types/ThemeConfigGroup.d.ts.map +1 -0
  157. package/esm/types/ThemeConfigGroup.js +1 -0
  158. package/esm/types/ThemeId.d.ts +3 -0
  159. package/esm/types/ThemeId.d.ts.map +1 -1
  160. package/esm/types/ThemeSettings.d.ts +5 -0
  161. package/esm/types/ThemeSettings.d.ts.map +1 -0
  162. package/esm/types/ThemeSettings.js +1 -0
  163. package/esm/types/ThemeSettingsDefinition.d.ts +2 -2
  164. package/esm/types/ThemeSettingsDefinition.d.ts.map +1 -1
  165. package/esm/types/ThemeVariable.d.ts +16 -2
  166. package/esm/types/ThemeVariable.d.ts.map +1 -1
  167. package/esm/types/ThemeVariableWithUnit.d.ts +11 -2
  168. package/esm/types/ThemeVariableWithUnit.d.ts.map +1 -1
  169. package/esm/types/ThirdPartyPlugin.d.ts +2 -2
  170. package/esm/types/ThirdPartyPlugin.d.ts.map +1 -1
  171. package/esm/types/ThirdPartyWidgetSettings.d.ts +1 -1
  172. package/esm/types/ThirdPartyWidgetSettings.d.ts.map +1 -1
  173. package/esm/types/UniqueIconPackEntry.d.ts +24 -0
  174. package/esm/types/UniqueIconPackEntry.d.ts.map +1 -0
  175. package/esm/types/UniqueIconPackEntry.js +1 -0
  176. package/esm/types/VirtualDesktopMonitor.d.ts +9 -0
  177. package/esm/types/VirtualDesktopMonitor.d.ts.map +1 -0
  178. package/esm/types/VirtualDesktopMonitor.js +1 -0
  179. package/esm/types/VirtualDesktops.d.ts +15 -0
  180. package/esm/types/VirtualDesktops.d.ts.map +1 -0
  181. package/esm/types/VirtualDesktops.js +1 -0
  182. package/esm/types/Wallpaper.d.ts +11 -0
  183. package/esm/types/Wallpaper.d.ts.map +1 -0
  184. package/esm/types/Wallpaper.js +1 -0
  185. package/esm/types/WallpaperId.d.ts +6 -0
  186. package/esm/types/WallpaperId.d.ts.map +1 -0
  187. package/esm/types/WallpaperId.js +1 -0
  188. package/esm/types/WallpaperInstanceSettings.d.ts +45 -0
  189. package/esm/types/WallpaperInstanceSettings.d.ts.map +1 -0
  190. package/esm/types/WallpaperInstanceSettings.js +1 -0
  191. package/esm/types/WidgetId.d.ts +3 -0
  192. package/esm/types/WidgetId.d.ts.map +1 -1
  193. package/esm/types/WindowManagerLayout.d.ts +1 -2
  194. package/esm/types/WindowManagerLayout.d.ts.map +1 -1
  195. package/esm/types/WmNode.d.ts +40 -15
  196. package/esm/types/WmNode.d.ts.map +1 -1
  197. package/esm/types/WmNodeKind.d.ts +2 -0
  198. package/esm/types/WmNodeKind.d.ts.map +1 -0
  199. package/esm/types/WmNodeKind.js +2 -0
  200. package/esm/types/WmNodeLifetime.d.ts +2 -0
  201. package/esm/types/WmNodeLifetime.d.ts.map +1 -0
  202. package/esm/types/WmNodeLifetime.js +2 -0
  203. package/esm/types/mod.d.ts +215 -201
  204. package/esm/types/mod.d.ts.map +1 -1
  205. package/esm/types/mod.js +215 -201
  206. package/esm/utils/Wrapper.d.ts +3 -0
  207. package/esm/utils/Wrapper.d.ts.map +1 -0
  208. package/esm/utils/Wrapper.js +5 -0
  209. package/package.json +6 -6
  210. package/script/constants/mod.d.ts +17 -9
  211. package/script/constants/mod.d.ts.map +1 -1
  212. package/script/constants/mod.js +6 -4
  213. package/script/handlers/commands.d.ts +17 -8
  214. package/script/handlers/commands.d.ts.map +1 -1
  215. package/script/handlers/commands.js +17 -8
  216. package/script/handlers/events.d.ts +3 -5
  217. package/script/handlers/events.d.ts.map +1 -1
  218. package/script/handlers/events.js +3 -5
  219. package/script/lib.d.ts +1 -1
  220. package/script/lib.d.ts.map +1 -1
  221. package/script/lib.js +1 -1
  222. package/script/resource/mod.d.ts +6 -0
  223. package/script/resource/mod.d.ts.map +1 -0
  224. package/script/state/icon_pack.d.ts +23 -52
  225. package/script/state/icon_pack.d.ts.map +1 -1
  226. package/script/state/icon_pack.js +137 -131
  227. package/script/state/mod.d.ts +2 -1
  228. package/script/state/mod.d.ts.map +1 -1
  229. package/script/state/mod.js +1 -0
  230. package/script/state/plugin/mod.d.ts +1 -1
  231. package/script/state/plugin/mod.d.ts.map +1 -1
  232. package/script/state/settings/mod.d.ts +6 -5
  233. package/script/state/settings/mod.d.ts.map +1 -1
  234. package/script/state/settings/mod.js +5 -9
  235. package/script/state/settings/settings_by_monitor.d.ts +1 -4
  236. package/script/state/settings/settings_by_monitor.d.ts.map +1 -1
  237. package/script/state/settings/settings_by_monitor.js +1 -9
  238. package/script/state/settings_by_app.d.ts +1 -1
  239. package/script/state/settings_by_app.d.ts.map +1 -1
  240. package/script/state/theme/mod.d.ts +19 -3
  241. package/script/state/theme/mod.d.ts.map +1 -1
  242. package/script/state/theme/mod.js +100 -1
  243. package/script/state/wallpaper/mod.d.ts +15 -0
  244. package/script/state/wallpaper/mod.d.ts.map +1 -0
  245. package/script/state/wallpaper/mod.js +36 -0
  246. package/script/state/weg_items.d.ts +6 -9
  247. package/script/state/weg_items.d.ts.map +1 -1
  248. package/script/state/weg_items.js +7 -15
  249. package/script/state/widget/mod.d.ts +9 -4
  250. package/script/state/widget/mod.d.ts.map +1 -1
  251. package/script/state/widget/mod.js +31 -12
  252. package/script/state/wm_layout.d.ts +4 -5
  253. package/script/state/wm_layout.d.ts.map +1 -1
  254. package/script/state/wm_layout.js +5 -11
  255. package/script/system_state/bluetooth/mod.d.ts +2 -2
  256. package/script/system_state/bluetooth/mod.d.ts.map +1 -1
  257. package/script/system_state/language.d.ts +1 -1
  258. package/script/system_state/language.d.ts.map +1 -1
  259. package/script/system_state/monitors.d.ts +1 -1
  260. package/script/system_state/monitors.d.ts.map +1 -1
  261. package/script/system_state/ui_colors.d.ts +1 -1
  262. package/script/system_state/ui_colors.d.ts.map +1 -1
  263. package/script/system_state/ui_colors.js +8 -2
  264. package/script/system_state/user.d.ts +1 -1
  265. package/script/system_state/user.d.ts.map +1 -1
  266. package/script/types/CssVariableName.d.ts +5 -0
  267. package/script/types/CssVariableName.d.ts.map +1 -0
  268. package/script/types/CustomIconPackEntry.d.ts +16 -0
  269. package/script/types/CustomIconPackEntry.d.ts.map +1 -0
  270. package/script/types/DesktopWorkspace.d.ts +5 -0
  271. package/script/types/DesktopWorkspace.d.ts.map +1 -1
  272. package/script/types/FocusedApp.d.ts +4 -0
  273. package/script/types/FocusedApp.d.ts.map +1 -1
  274. package/script/types/FocusedApp.js +0 -1
  275. package/script/types/Icon.d.ts +17 -10
  276. package/script/types/Icon.d.ts.map +1 -1
  277. package/script/types/IconPack.d.ts +7 -19
  278. package/script/types/IconPack.d.ts.map +1 -1
  279. package/script/types/IconPackEntry.d.ts +11 -0
  280. package/script/types/IconPackEntry.d.ts.map +1 -0
  281. package/script/types/IconPackId.d.ts +3 -0
  282. package/script/types/IconPackId.d.ts.map +1 -1
  283. package/script/types/MediaPlayer.d.ts +2 -0
  284. package/script/types/MediaPlayer.d.ts.map +1 -1
  285. package/script/types/MediaPlayerTimeline.d.ts +24 -0
  286. package/script/types/MediaPlayerTimeline.d.ts.map +1 -0
  287. package/script/types/MixBlendMode.d.ts +2 -0
  288. package/script/types/MixBlendMode.d.ts.map +1 -0
  289. package/script/types/MonitorConfiguration.d.ts +0 -5
  290. package/script/types/MonitorConfiguration.d.ts.map +1 -1
  291. package/script/types/MonitorId.d.ts +2 -0
  292. package/script/types/MonitorId.d.ts.map +1 -0
  293. package/script/types/MonitorSettingsByWidget.d.ts +1 -10
  294. package/script/types/MonitorSettingsByWidget.d.ts.map +1 -1
  295. package/script/types/ObjectFit.d.ts +2 -0
  296. package/script/types/ObjectFit.d.ts.map +1 -0
  297. package/script/types/ObjectPosition.d.ts +2 -0
  298. package/script/types/ObjectPosition.d.ts.map +1 -0
  299. package/script/types/PhysicalMonitor.d.ts +2 -1
  300. package/script/types/PhysicalMonitor.d.ts.map +1 -1
  301. package/script/types/PlaybackSpeed.d.ts +2 -0
  302. package/script/types/PlaybackSpeed.d.ts.map +1 -0
  303. package/script/types/PluginId.d.ts +3 -0
  304. package/script/types/PluginId.d.ts.map +1 -1
  305. package/script/types/Resource.d.ts +35 -3
  306. package/script/types/Resource.d.ts.map +1 -1
  307. package/script/types/ResourceAttribute.d.ts +2 -0
  308. package/script/types/ResourceAttribute.d.ts.map +1 -0
  309. package/script/types/ResourceId.d.ts +4 -2
  310. package/script/types/ResourceId.d.ts.map +1 -1
  311. package/script/types/ResourceMetadata.d.ts +2 -6
  312. package/script/types/ResourceMetadata.d.ts.map +1 -1
  313. package/script/types/SeelenCommandArgument.d.ts +43 -18
  314. package/script/types/SeelenCommandArgument.d.ts.map +1 -1
  315. package/script/types/SeelenCommandClosePopupArgs.d.ts +4 -0
  316. package/script/types/SeelenCommandClosePopupArgs.d.ts.map +1 -0
  317. package/script/types/SeelenCommandClosePopupArgs.js +3 -0
  318. package/script/types/SeelenCommandCreatePopupArgs.d.ts +5 -0
  319. package/script/types/SeelenCommandCreatePopupArgs.d.ts.map +1 -0
  320. package/script/types/SeelenCommandRemoveResourceArgs.d.ts +7 -0
  321. package/script/types/SeelenCommandRemoveResourceArgs.d.ts.map +1 -0
  322. package/script/types/SeelenCommandRequestToUserInputShortcutArgs.d.ts +4 -0
  323. package/script/types/SeelenCommandRequestToUserInputShortcutArgs.d.ts.map +1 -0
  324. package/script/types/SeelenCommandRequestToUserInputShortcutArgs.js +3 -0
  325. package/script/types/SeelenCommandReturn.d.ts +38 -16
  326. package/script/types/SeelenCommandReturn.d.ts.map +1 -1
  327. package/script/types/SeelenCommandSetNativeShellWallpaperArgs.d.ts +4 -0
  328. package/script/types/SeelenCommandSetNativeShellWallpaperArgs.d.ts.map +1 -0
  329. package/script/types/SeelenCommandSetNativeShellWallpaperArgs.js +3 -0
  330. package/script/types/SeelenCommandStateGetWegItemsArgs.d.ts +5 -0
  331. package/script/types/SeelenCommandStateGetWegItemsArgs.d.ts.map +1 -0
  332. package/script/types/SeelenCommandStateSetCustomIconPackArgs.d.ts +5 -0
  333. package/script/types/SeelenCommandStateSetCustomIconPackArgs.d.ts.map +1 -0
  334. package/script/types/SeelenCommandSwitchWorkspaceArgs.d.ts +2 -0
  335. package/script/types/SeelenCommandSwitchWorkspaceArgs.d.ts.map +1 -1
  336. package/script/types/SeelenCommandSwitchWorkspaceArgs.js +0 -1
  337. package/script/types/SeelenCommandUpdatePopupArgs.d.ts +6 -0
  338. package/script/types/SeelenCommandUpdatePopupArgs.d.ts.map +1 -0
  339. package/script/types/SeelenEventPayload.d.ts +10 -14
  340. package/script/types/SeelenEventPayload.d.ts.map +1 -1
  341. package/script/types/SeelenWallSettings.d.ts +5 -2
  342. package/script/types/SeelenWallSettings.d.ts.map +1 -1
  343. package/script/types/SeelenWegSettings.d.ts +4 -0
  344. package/script/types/SeelenWegSettings.d.ts.map +1 -1
  345. package/script/types/Settings.d.ts +23 -16
  346. package/script/types/Settings.d.ts.map +1 -1
  347. package/script/types/SettingsByWidget.d.ts +19 -3
  348. package/script/types/SettingsByWidget.d.ts.map +1 -1
  349. package/script/types/SharedIconPackEntry.d.ts +12 -0
  350. package/script/types/SharedIconPackEntry.d.ts.map +1 -0
  351. package/script/types/SluHotkey.d.ts +8 -0
  352. package/script/types/SluHotkey.d.ts.map +1 -0
  353. package/script/types/SluHotkeyAction.d.ts +84 -0
  354. package/script/types/SluHotkeyAction.d.ts.map +1 -0
  355. package/script/types/SluHotkeyAction.js +3 -0
  356. package/script/types/SluPopupConfig.d.ts +2 -0
  357. package/script/types/SluPopupConfig.d.ts.map +1 -1
  358. package/script/types/SluShortcutsSettings.d.ts +6 -0
  359. package/script/types/SluShortcutsSettings.d.ts.map +1 -0
  360. package/script/types/Theme.d.ts +5 -0
  361. package/script/types/Theme.d.ts.map +1 -1
  362. package/script/types/ThemeConfigDefinition.d.ts +6 -0
  363. package/script/types/ThemeConfigDefinition.d.ts.map +1 -0
  364. package/script/types/ThemeConfigGroup.d.ts +7 -0
  365. package/script/types/ThemeConfigGroup.d.ts.map +1 -0
  366. package/script/types/ThemeConfigGroup.js +2 -0
  367. package/script/types/ThemeId.d.ts +3 -0
  368. package/script/types/ThemeId.d.ts.map +1 -1
  369. package/script/types/ThemeSettings.d.ts +5 -0
  370. package/script/types/ThemeSettings.d.ts.map +1 -0
  371. package/script/types/ThemeSettings.js +2 -0
  372. package/script/types/ThemeSettingsDefinition.d.ts +2 -2
  373. package/script/types/ThemeSettingsDefinition.d.ts.map +1 -1
  374. package/script/types/ThemeVariable.d.ts +16 -2
  375. package/script/types/ThemeVariable.d.ts.map +1 -1
  376. package/script/types/ThemeVariableWithUnit.d.ts +11 -2
  377. package/script/types/ThemeVariableWithUnit.d.ts.map +1 -1
  378. package/script/types/ThirdPartyPlugin.d.ts +2 -2
  379. package/script/types/ThirdPartyPlugin.d.ts.map +1 -1
  380. package/script/types/ThirdPartyWidgetSettings.d.ts +1 -1
  381. package/script/types/ThirdPartyWidgetSettings.d.ts.map +1 -1
  382. package/script/types/UniqueIconPackEntry.d.ts +24 -0
  383. package/script/types/UniqueIconPackEntry.d.ts.map +1 -0
  384. package/script/types/UniqueIconPackEntry.js +2 -0
  385. package/script/types/VirtualDesktopMonitor.d.ts +9 -0
  386. package/script/types/VirtualDesktopMonitor.d.ts.map +1 -0
  387. package/script/types/VirtualDesktopMonitor.js +2 -0
  388. package/script/types/VirtualDesktops.d.ts +15 -0
  389. package/script/types/VirtualDesktops.d.ts.map +1 -0
  390. package/script/types/VirtualDesktops.js +2 -0
  391. package/script/types/Wallpaper.d.ts +11 -0
  392. package/script/types/Wallpaper.d.ts.map +1 -0
  393. package/script/types/Wallpaper.js +2 -0
  394. package/script/types/WallpaperId.d.ts +6 -0
  395. package/script/types/WallpaperId.d.ts.map +1 -0
  396. package/script/types/WallpaperId.js +2 -0
  397. package/script/types/WallpaperInstanceSettings.d.ts +45 -0
  398. package/script/types/WallpaperInstanceSettings.d.ts.map +1 -0
  399. package/script/types/WallpaperInstanceSettings.js +2 -0
  400. package/script/types/WidgetId.d.ts +3 -0
  401. package/script/types/WidgetId.d.ts.map +1 -1
  402. package/script/types/WindowManagerLayout.d.ts +1 -2
  403. package/script/types/WindowManagerLayout.d.ts.map +1 -1
  404. package/script/types/WmNode.d.ts +40 -15
  405. package/script/types/WmNode.d.ts.map +1 -1
  406. package/script/types/WmNodeKind.d.ts +2 -0
  407. package/script/types/WmNodeKind.d.ts.map +1 -0
  408. package/script/types/WmNodeKind.js +3 -0
  409. package/script/types/WmNodeLifetime.d.ts +2 -0
  410. package/script/types/WmNodeLifetime.d.ts.map +1 -0
  411. package/script/types/WmNodeLifetime.js +3 -0
  412. package/script/types/mod.d.ts +215 -201
  413. package/script/types/mod.d.ts.map +1 -1
  414. package/script/types/mod.js +215 -201
  415. package/script/utils/Wrapper.d.ts +3 -0
  416. package/script/utils/Wrapper.d.ts.map +1 -0
  417. package/script/utils/Wrapper.js +8 -0
  418. package/esm/resource.d.ts +0 -6
  419. package/esm/resource.d.ts.map +0 -1
  420. package/esm/types/AhkVar.d.ts +0 -7
  421. package/esm/types/AhkVar.d.ts.map +0 -1
  422. package/esm/types/AhkVarList.d.ts +0 -64
  423. package/esm/types/AhkVarList.d.ts.map +0 -1
  424. package/esm/types/FancyToolbarSettingsByMonitor.d.ts +0 -4
  425. package/esm/types/FancyToolbarSettingsByMonitor.d.ts.map +0 -1
  426. package/esm/types/NoFallbackBehavior.d.ts +0 -2
  427. package/esm/types/NoFallbackBehavior.d.ts.map +0 -1
  428. package/esm/types/NodeSubtype.d.ts +0 -2
  429. package/esm/types/NodeSubtype.d.ts.map +0 -1
  430. package/esm/types/SeelenCommandStateSetWallpaperArgs.d.ts +0 -4
  431. package/esm/types/SeelenCommandStateSetWallpaperArgs.d.ts.map +0 -1
  432. package/esm/types/SeelenWallSettingsByMonitor.d.ts +0 -6
  433. package/esm/types/SeelenWallSettingsByMonitor.d.ts.map +0 -1
  434. package/esm/types/SeelenWallWallpaper.d.ts +0 -5
  435. package/esm/types/SeelenWallWallpaper.d.ts.map +0 -1
  436. package/esm/types/SeelenWegSettingsByMonitor.d.ts +0 -8
  437. package/esm/types/SeelenWegSettingsByMonitor.d.ts.map +0 -1
  438. package/esm/types/VirtualDesktopStrategy.d.ts +0 -2
  439. package/esm/types/VirtualDesktopStrategy.d.ts.map +0 -1
  440. package/esm/types/WindowManagerSettingsByMonitor.d.ts +0 -9
  441. package/esm/types/WindowManagerSettingsByMonitor.d.ts.map +0 -1
  442. package/esm/types/WmFallbackNode.d.ts +0 -25
  443. package/esm/types/WmFallbackNode.d.ts.map +0 -1
  444. package/esm/types/WmHorizontalNode.d.ts +0 -19
  445. package/esm/types/WmHorizontalNode.d.ts.map +0 -1
  446. package/esm/types/WmLeafNode.d.ts +0 -21
  447. package/esm/types/WmLeafNode.d.ts.map +0 -1
  448. package/esm/types/WmStackNode.d.ts +0 -25
  449. package/esm/types/WmStackNode.d.ts.map +0 -1
  450. package/esm/types/WmVerticalNode.d.ts +0 -19
  451. package/esm/types/WmVerticalNode.d.ts.map +0 -1
  452. package/esm/types/WorkspaceConfiguration.d.ts +0 -8
  453. package/esm/types/WorkspaceConfiguration.d.ts.map +0 -1
  454. package/esm/types/WorkspaceIdentifier.d.ts +0 -6
  455. package/esm/types/WorkspaceIdentifier.d.ts.map +0 -1
  456. package/esm/types/WorkspaceIdentifierType.d.ts +0 -2
  457. package/esm/types/WorkspaceIdentifierType.d.ts.map +0 -1
  458. package/script/resource.d.ts +0 -6
  459. package/script/resource.d.ts.map +0 -1
  460. package/script/types/AhkVar.d.ts +0 -7
  461. package/script/types/AhkVar.d.ts.map +0 -1
  462. package/script/types/AhkVarList.d.ts +0 -64
  463. package/script/types/AhkVarList.d.ts.map +0 -1
  464. package/script/types/FancyToolbarSettingsByMonitor.d.ts +0 -4
  465. package/script/types/FancyToolbarSettingsByMonitor.d.ts.map +0 -1
  466. package/script/types/NoFallbackBehavior.d.ts +0 -2
  467. package/script/types/NoFallbackBehavior.d.ts.map +0 -1
  468. package/script/types/NodeSubtype.d.ts +0 -2
  469. package/script/types/NodeSubtype.d.ts.map +0 -1
  470. package/script/types/SeelenCommandStateSetWallpaperArgs.d.ts +0 -4
  471. package/script/types/SeelenCommandStateSetWallpaperArgs.d.ts.map +0 -1
  472. package/script/types/SeelenWallSettingsByMonitor.d.ts +0 -6
  473. package/script/types/SeelenWallSettingsByMonitor.d.ts.map +0 -1
  474. package/script/types/SeelenWallWallpaper.d.ts +0 -5
  475. package/script/types/SeelenWallWallpaper.d.ts.map +0 -1
  476. package/script/types/SeelenWegSettingsByMonitor.d.ts +0 -8
  477. package/script/types/SeelenWegSettingsByMonitor.d.ts.map +0 -1
  478. package/script/types/VirtualDesktopStrategy.d.ts +0 -2
  479. package/script/types/VirtualDesktopStrategy.d.ts.map +0 -1
  480. package/script/types/WindowManagerSettingsByMonitor.d.ts +0 -9
  481. package/script/types/WindowManagerSettingsByMonitor.d.ts.map +0 -1
  482. package/script/types/WmFallbackNode.d.ts +0 -25
  483. package/script/types/WmFallbackNode.d.ts.map +0 -1
  484. package/script/types/WmHorizontalNode.d.ts +0 -19
  485. package/script/types/WmHorizontalNode.d.ts.map +0 -1
  486. package/script/types/WmLeafNode.d.ts +0 -21
  487. package/script/types/WmLeafNode.d.ts.map +0 -1
  488. package/script/types/WmStackNode.d.ts +0 -25
  489. package/script/types/WmStackNode.d.ts.map +0 -1
  490. package/script/types/WmVerticalNode.d.ts +0 -19
  491. package/script/types/WmVerticalNode.d.ts.map +0 -1
  492. package/script/types/WorkspaceConfiguration.d.ts +0 -8
  493. package/script/types/WorkspaceConfiguration.d.ts.map +0 -1
  494. package/script/types/WorkspaceIdentifier.d.ts +0 -6
  495. package/script/types/WorkspaceIdentifier.d.ts.map +0 -1
  496. package/script/types/WorkspaceIdentifierType.d.ts +0 -2
  497. package/script/types/WorkspaceIdentifierType.d.ts.map +0 -1
  498. /package/esm/{resource.js → resource/mod.js} +0 -0
  499. /package/esm/types/{AhkVar.js → CssVariableName.js} +0 -0
  500. /package/esm/types/{AhkVarList.js → CustomIconPackEntry.js} +0 -0
  501. /package/esm/types/{SeelenWallSettingsByMonitor.js → IconPackEntry.js} +0 -0
  502. /package/esm/types/{FancyToolbarSettingsByMonitor.js → MediaPlayerTimeline.js} +0 -0
  503. /package/esm/types/{NoFallbackBehavior.js → MixBlendMode.js} +0 -0
  504. /package/esm/types/{NodeSubtype.js → MonitorId.js} +0 -0
  505. /package/esm/types/{SeelenCommandStateSetWallpaperArgs.js → ObjectFit.js} +0 -0
  506. /package/esm/types/{SeelenWallWallpaper.js → ObjectPosition.js} +0 -0
  507. /package/esm/types/{VirtualDesktopStrategy.js → PlaybackSpeed.js} +0 -0
  508. /package/esm/types/{WorkspaceIdentifierType.js → ResourceAttribute.js} +0 -0
  509. /package/esm/types/{SeelenWegSettingsByMonitor.js → SeelenCommandCreatePopupArgs.js} +0 -0
  510. /package/esm/types/{WindowManagerSettingsByMonitor.js → SeelenCommandRemoveResourceArgs.js} +0 -0
  511. /package/esm/types/{WmFallbackNode.js → SeelenCommandStateGetWegItemsArgs.js} +0 -0
  512. /package/esm/types/{WmHorizontalNode.js → SeelenCommandStateSetCustomIconPackArgs.js} +0 -0
  513. /package/esm/types/{WmLeafNode.js → SeelenCommandUpdatePopupArgs.js} +0 -0
  514. /package/esm/types/{WmStackNode.js → SharedIconPackEntry.js} +0 -0
  515. /package/esm/types/{WmVerticalNode.js → SluHotkey.js} +0 -0
  516. /package/esm/types/{WorkspaceConfiguration.js → SluShortcutsSettings.js} +0 -0
  517. /package/esm/types/{WorkspaceIdentifier.js → ThemeConfigDefinition.js} +0 -0
  518. /package/script/{resource.js → resource/mod.js} +0 -0
  519. /package/script/types/{AhkVar.js → CssVariableName.js} +0 -0
  520. /package/script/types/{AhkVarList.js → CustomIconPackEntry.js} +0 -0
  521. /package/script/types/{SeelenWallSettingsByMonitor.js → IconPackEntry.js} +0 -0
  522. /package/script/types/{FancyToolbarSettingsByMonitor.js → MediaPlayerTimeline.js} +0 -0
  523. /package/script/types/{NoFallbackBehavior.js → MixBlendMode.js} +0 -0
  524. /package/script/types/{NodeSubtype.js → MonitorId.js} +0 -0
  525. /package/script/types/{SeelenCommandStateSetWallpaperArgs.js → ObjectFit.js} +0 -0
  526. /package/script/types/{SeelenWallWallpaper.js → ObjectPosition.js} +0 -0
  527. /package/script/types/{VirtualDesktopStrategy.js → PlaybackSpeed.js} +0 -0
  528. /package/script/types/{WorkspaceIdentifierType.js → ResourceAttribute.js} +0 -0
  529. /package/script/types/{SeelenWegSettingsByMonitor.js → SeelenCommandCreatePopupArgs.js} +0 -0
  530. /package/script/types/{WindowManagerSettingsByMonitor.js → SeelenCommandRemoveResourceArgs.js} +0 -0
  531. /package/script/types/{WmFallbackNode.js → SeelenCommandStateGetWegItemsArgs.js} +0 -0
  532. /package/script/types/{WmHorizontalNode.js → SeelenCommandStateSetCustomIconPackArgs.js} +0 -0
  533. /package/script/types/{WmLeafNode.js → SeelenCommandUpdatePopupArgs.js} +0 -0
  534. /package/script/types/{WmStackNode.js → SharedIconPackEntry.js} +0 -0
  535. /package/script/types/{WmVerticalNode.js → SluHotkey.js} +0 -0
  536. /package/script/types/{WorkspaceConfiguration.js → SluShortcutsSettings.js} +0 -0
  537. /package/script/types/{WorkspaceIdentifier.js → ThemeConfigDefinition.js} +0 -0
@@ -4,7 +4,6 @@ exports.IconPackManager = exports.IconPackList = void 0;
4
4
  const List_js_1 = require("../utils/List.js");
5
5
  const State_js_1 = require("../utils/State.js");
6
6
  const mod_js_1 = require("../handlers/mod.js");
7
- const api_1 = require("@tauri-apps/api");
8
7
  const mod_js_2 = require("./settings/mod.js");
9
8
  const core_1 = require("@tauri-apps/api/core");
10
9
  class IconPackList extends List_js_1.List {
@@ -20,42 +19,50 @@ exports.IconPackList = IconPackList;
20
19
  * Class helper to allow easy use of icon packs
21
20
  */
22
21
  class IconPackManager {
23
- iconPackPath;
24
- _iconPacks;
25
- _actives;
22
+ _availableIconPacks;
23
+ _activeIconPackIds;
26
24
  callbacks = new Set();
27
- unlistenerSettings = null;
28
- unlistenerIcons = null;
29
- static resolveIcon(parent, icon) {
30
- if (typeof icon === 'string') {
31
- return `${parent}\\${icon}`;
32
- }
33
- return {
34
- light: `${parent}\\${icon.light}`,
35
- dark: `${parent}\\${icon.dark}`,
36
- mask: icon.mask ? `${parent}\\${icon.mask}` : null,
37
- };
25
+ unlisteners = [];
26
+ isListeningForChanges = false;
27
+ /// list of active icon packs and fully resolved paths
28
+ activeIconPacks = [];
29
+ constructor(_availableIconPacks, _activeIconPackIds) {
30
+ this._availableIconPacks = _availableIconPacks;
31
+ this._activeIconPackIds = _activeIconPackIds;
38
32
  }
39
- static resolveIconAsSrc(icon) {
40
- if (typeof icon === 'string') {
41
- return (0, core_1.convertFileSrc)(icon);
42
- }
43
- return {
44
- light: (0, core_1.convertFileSrc)(icon.light),
45
- dark: (0, core_1.convertFileSrc)(icon.dark),
46
- mask: icon.mask ? (0, core_1.convertFileSrc)(icon.mask) : null,
47
- };
33
+ get iconPacks() {
34
+ return this._availableIconPacks;
48
35
  }
49
- constructor(iconPackPath, _iconPacks, _actives) {
50
- this.iconPackPath = iconPackPath;
51
- this._iconPacks = _iconPacks;
52
- this._actives = _actives;
36
+ get activeIconPackIds() {
37
+ return this._activeIconPackIds;
53
38
  }
54
- get iconPacks() {
55
- return this._iconPacks;
39
+ resolveAvailableIcons() {
40
+ for (const pack of this._availableIconPacks) {
41
+ const path = `${pack.metadata.path}`;
42
+ if (pack.missing) {
43
+ pack.missing = resolveIcon(path, pack.missing);
44
+ }
45
+ for (const entry of pack.entries) {
46
+ if (entry.type === 'unique') {
47
+ entry.path = entry.path?.toLowerCase() || null;
48
+ }
49
+ if (entry.type === 'shared') {
50
+ entry.extension = entry.extension.toLowerCase();
51
+ }
52
+ if (entry.icon) {
53
+ entry.icon = resolveIcon(path, entry.icon);
54
+ }
55
+ }
56
+ }
56
57
  }
57
- get actives() {
58
- return this._actives;
58
+ cacheActiveIconPacks() {
59
+ this.activeIconPacks = [];
60
+ for (const key of this._activeIconPackIds.toReversed()) {
61
+ const pack = this._availableIconPacks.find((p) => p.id === key);
62
+ if (pack) {
63
+ this.activeIconPacks.push(pack);
64
+ }
65
+ }
59
66
  }
60
67
  /**
61
68
  * Creates an instance of IconPackManager. This intance will be updated when
@@ -64,7 +71,9 @@ class IconPackManager {
64
71
  * @returns A new instance of IconPackManager
65
72
  */
66
73
  static async create() {
67
- const instance = new IconPackManager(await api_1.path.resolve(await api_1.path.appDataDir(), 'icons'), await IconPackList.getAsync(), (await mod_js_2.Settings.getAsync()).inner.iconPacks);
74
+ const instance = new IconPackManager((await IconPackList.getAsync()).asArray(), (await mod_js_2.Settings.getAsync()).inner.activeIconPacks);
75
+ instance.resolveAvailableIcons();
76
+ instance.cacheActiveIconPacks();
68
77
  return instance;
69
78
  }
70
79
  /**
@@ -100,21 +109,27 @@ class IconPackManager {
100
109
  */
101
110
  async onChange(cb) {
102
111
  this.callbacks.add(cb);
103
- if (!this.unlistenerIcons && !this.unlistenerSettings) {
104
- this.unlistenerIcons = await IconPackList.onChange((list) => {
105
- this._iconPacks = list;
112
+ if (!this.isListeningForChanges) {
113
+ this.isListeningForChanges = true;
114
+ const unlistenerIcons = await IconPackList.onChange((list) => {
115
+ this._availableIconPacks = JSON.parse(JSON.stringify(list.all()));
116
+ this.resolveAvailableIcons();
117
+ this.cacheActiveIconPacks();
106
118
  this.callbacks.forEach((cb) => cb());
107
119
  });
108
- this.unlistenerSettings = await mod_js_2.Settings.onChange((settings) => {
109
- this._actives = settings.inner.iconPacks;
120
+ const unlistenerSettings = await mod_js_2.Settings.onChange((settings) => {
121
+ this._activeIconPackIds = settings.inner.activeIconPacks;
122
+ this.cacheActiveIconPacks();
110
123
  this.callbacks.forEach((cb) => cb());
111
124
  });
125
+ this.unlisteners = [unlistenerIcons, unlistenerSettings];
112
126
  }
113
127
  return () => {
114
128
  this.callbacks.delete(cb);
115
129
  if (this.callbacks.size === 0) {
116
- this.unlistenerIcons?.();
117
- this.unlistenerSettings?.();
130
+ this.unlisteners.forEach((unlisten) => unlisten());
131
+ this.unlisteners = [];
132
+ this.isListeningForChanges = false;
118
133
  }
119
134
  };
120
135
  }
@@ -123,11 +138,9 @@ class IconPackManager {
123
138
  *
124
139
  * The search for icons follows this priority order:
125
140
  * 1. UMID (App User Model Id)
126
- * 2. Full path or filename (for executable files like .exe or .lnk)
127
- * 3. File extension (for non-executable files like .png, .jpg, .txt)
128
- *
129
- * Icon packs are searched in the order of their priority. An icon from a higher-priority pack
130
- * will override an icon from a lower-priority pack, even if the latter matches the search criteria.
141
+ * 2. Full path
142
+ * 3. Filename (this is only used to match executable files like .exe)
143
+ * 4. Extension
131
144
  *
132
145
  * @param {Object} args - Arguments for retrieving the icon path.
133
146
  * @param {string} [args.path] - The full path to the app or file.
@@ -145,102 +158,78 @@ class IconPackManager {
145
158
  * umid: "Seelen.SeelenUI_p6yyn03m1894e!App"
146
159
  * });
147
160
  */
148
- getIconPath({ path, umid }) {
161
+ getIconPath(args) {
162
+ const { path, umid, __seen = new Set() } = args;
149
163
  // If neither path nor UMID is provided, return null
150
164
  if (!path && !umid) {
151
165
  return null;
152
166
  }
153
- // Create an ordered list of icon packs based on their priority
154
- const orderedPacks = [];
155
- for (const active of this.actives.toReversed()) {
156
- const pack = this._iconPacks.asArray().find((p) => p.metadata.filename === active);
157
- if (pack) {
158
- orderedPacks.push(pack);
159
- }
160
- }
161
- // Search by UMID first (highest priority)
162
- if (umid) {
163
- for (const pack of orderedPacks) {
164
- const icon = pack.apps[umid];
165
- if (icon) {
166
- return IconPackManager.resolveIcon(`${this.iconPackPath}\\${pack.metadata.filename}`, icon);
167
- }
167
+ const lowerPath = path?.toLowerCase();
168
+ const extension = lowerPath?.split('.').pop();
169
+ for (const pack of this.activeIconPacks) {
170
+ let entry;
171
+ if (umid) {
172
+ entry = pack.entries.find((e) => e.type === 'unique' && !!e.umid && e.umid === umid);
168
173
  }
169
- }
170
- // If no UMID is provided, search by path
171
- if (!path) {
172
- return null;
173
- }
174
- const lowercasedPath = path.toLowerCase();
175
- const isExecutable = lowercasedPath.endsWith('.exe') || lowercasedPath.endsWith('.lnk');
176
- // For non-executable files, search by file extension
177
- if (!isExecutable) {
178
- const extension = lowercasedPath.split('.').pop();
179
- if (!extension) {
180
- return null;
174
+ if (!entry && lowerPath) {
175
+ entry = pack.entries.find((e) => {
176
+ if (e.type !== 'unique' || !e.path) {
177
+ return false;
178
+ }
179
+ if (e.path === lowerPath) {
180
+ return true;
181
+ }
182
+ // only search for filename in case of executable files
183
+ if (extension === 'exe') {
184
+ const filename = lowerPath.split('\\').pop();
185
+ if (filename && e.path.endsWith(filename)) {
186
+ return true;
187
+ }
188
+ }
189
+ return false;
190
+ });
181
191
  }
182
- for (const pack of orderedPacks) {
183
- const icon = pack.files[extension];
184
- if (icon) {
185
- return IconPackManager.resolveIcon(`${this.iconPackPath}\\${pack.metadata.filename}`, icon);
192
+ if (entry) {
193
+ if (entry.redirect) {
194
+ // break circular references
195
+ if (__seen.has(entry.redirect)) {
196
+ return null;
197
+ }
198
+ __seen.add(entry.redirect);
199
+ return this.getIconPath({ path: entry.redirect, __seen });
200
+ }
201
+ if (entry.icon) {
202
+ return entry.icon;
186
203
  }
187
204
  }
188
- return null;
189
205
  }
190
- // For executable files, search by full path or filename
191
- const filename = path.split(/[/\\]/g).pop();
192
- if (!filename) {
206
+ // search by file extension
207
+ if (!extension) {
193
208
  return null;
194
209
  }
195
- for (const pack of orderedPacks) {
196
- const icon = pack.apps[path] || pack.apps[filename];
210
+ for (const pack of this.activeIconPacks) {
211
+ const icon = pack.entries.find((e) => {
212
+ return e.type === 'shared' && e.extension === extension;
213
+ });
197
214
  if (icon) {
198
- return IconPackManager.resolveIcon(`${this.iconPackPath}\\${pack.metadata.filename}`, icon);
215
+ return icon.icon;
199
216
  }
200
217
  }
201
218
  // If no icon is found in any icon pack, return null
202
219
  return null;
203
220
  }
204
- /**
205
- * Returns the icon Url/Src for an app or file. If no icon is available, returns `null`.
206
- *
207
- * The search for icons follows this priority order:
208
- * 1. UMID (App User Model Id)
209
- * 2. Full path or filename (for executable files like .exe or .lnk)
210
- * 3. File extension (for non-executable files like .png, .jpg, .txt)
211
- *
212
- * Icon packs are searched in the order of their priority. An icon from a higher-priority pack
213
- * will override an icon from a lower-priority pack, even if the latter matches the search criteria.
214
- *
215
- * @param {Object} args - Arguments for retrieving the icon path.
216
- * @param {string} [args.path] - The full path to the app or file.
217
- * @param {string} [args.umid] - The UMID of the app.
218
- * @returns {string | null} - The path to the icon, or `null` if no icon is found.
219
- *
220
- * @example
221
- * // Example 1: Get icon by full path
222
- * const iconSrc = instance.getIconPath({
223
- * path: "C:\\Program Files\\Steam\\steam.exe"
224
- * });
225
- *
226
- * // Example 2: Get icon by UMID
227
- * const iconSrc = instance.getIconPath({
228
- * umid: "Seelen.SeelenUI_p6yyn03m1894e!App"
229
- * });
230
- */
231
221
  getIcon({ path, umid }) {
232
222
  const iconPath = this.getIconPath({ path, umid });
233
- return iconPath ? IconPackManager.resolveIconAsSrc(iconPath) : null;
223
+ return iconPath ? resolveAsSrc(iconPath) : null;
234
224
  }
235
225
  /**
236
226
  * Will return the special missing icon path from the highest priority icon pack.
237
227
  * If no icon pack haves a missing icon, will return null.
238
228
  */
239
229
  getMissingIconPath() {
240
- for (const active of this.actives.toReversed()) {
241
- const pack = this.iconPacks.asArray().find((p) => p.metadata.filename === active);
242
- if (pack && pack.missing) {
243
- return IconPackManager.resolveIcon(`${this.iconPackPath}\\${pack.metadata.filename}`, pack.missing);
230
+ for (const pack of this.activeIconPacks) {
231
+ if (pack.missing) {
232
+ return pack.missing;
244
233
  }
245
234
  }
246
235
  return null;
@@ -251,33 +240,32 @@ class IconPackManager {
251
240
  */
252
241
  getMissingIcon() {
253
242
  const iconPath = this.getMissingIconPath();
254
- return iconPath ? IconPackManager.resolveIconAsSrc(iconPath) : null;
243
+ return iconPath ? resolveAsSrc(iconPath) : null;
255
244
  }
256
245
  /**
257
- * Will return the specifit icon path from the highest priority icon pack.
246
+ * Will return the specific icon path from the highest priority icon pack.
258
247
  * If no icon pack haves the searched icon, will return null.
259
248
  */
260
- getSpecificIconPath(name) {
261
- for (const active of this.actives.toReversed()) {
262
- const pack = this.iconPacks.asArray().find((p) => p.metadata.filename === active);
263
- const icon = pack?.specific[name];
264
- if (icon) {
265
- return IconPackManager.resolveIcon(`${this.iconPackPath}\\${pack.metadata.filename}`, icon);
249
+ getCustomIconPath(name) {
250
+ for (const pack of this.activeIconPacks) {
251
+ const entry = pack.entries.find((e) => e.type === 'custom' && e.key === name);
252
+ if (entry) {
253
+ return entry.icon;
266
254
  }
267
255
  }
268
256
  return null;
269
257
  }
270
258
  /**
271
- * Will return the specifit icon SRC from the highest priority icon pack.
259
+ * Will return the specific icon SRC from the highest priority icon pack.
272
260
  * If no icon pack haves the searched icon, will return null.
273
261
  */
274
- getSpecificIcon(name) {
275
- const iconPath = this.getSpecificIconPath(name);
276
- return iconPath ? IconPackManager.resolveIconAsSrc(iconPath) : null;
262
+ getCustomIcon(name) {
263
+ const iconPath = this.getCustomIconPath(name);
264
+ return iconPath ? resolveAsSrc(iconPath) : null;
277
265
  }
278
266
  /**
279
- * Return the icon Path for an app or file, in case of no icon available will return `null`.\
280
- * This method doesn't take in care icon packs, just extracts the inherited icon into system's icon pack.
267
+ * This method doesn't take in care icon packs, just extracts the inherited icon into system's icon pack
268
+ * if it's not already there.
281
269
  *
282
270
  * @param filePath The path to the app could be umid o full path
283
271
  * @example
@@ -288,7 +276,7 @@ class IconPackManager {
288
276
  * umid: "Seelen.SeelenUI_p6yyn03m1894e!App"
289
277
  * });
290
278
  */
291
- static extractIcon(obj) {
279
+ static requestIconExtraction(obj) {
292
280
  return (0, mod_js_1.invoke)(mod_js_1.SeelenCommand.GetIcon, obj);
293
281
  }
294
282
  /**
@@ -300,3 +288,21 @@ class IconPackManager {
300
288
  }
301
289
  }
302
290
  exports.IconPackManager = IconPackManager;
291
+ function resolveIcon(parent, icon) {
292
+ return {
293
+ base: icon.base ? `${parent}\\${icon.base}` : null,
294
+ light: icon.light ? `${parent}\\${icon.light}` : null,
295
+ dark: icon.dark ? `${parent}\\${icon.dark}` : null,
296
+ mask: icon.mask ? `${parent}\\${icon.mask}` : null,
297
+ isAproximatelySquare: icon.isAproximatelySquare,
298
+ };
299
+ }
300
+ function resolveAsSrc(icon) {
301
+ return {
302
+ base: icon.base ? (0, core_1.convertFileSrc)(icon.base) : null,
303
+ light: icon.light ? (0, core_1.convertFileSrc)(icon.light) : null,
304
+ dark: icon.dark ? (0, core_1.convertFileSrc)(icon.dark) : null,
305
+ mask: icon.mask ? (0, core_1.convertFileSrc)(icon.mask) : null,
306
+ isAproximatelySquare: icon.isAproximatelySquare,
307
+ };
308
+ }
@@ -11,10 +11,11 @@ export * from './icon_pack.js';
11
11
  export * from './plugin/mod.js';
12
12
  export * from './widget/mod.js';
13
13
  export * from './profile.js';
14
+ export * from './wallpaper/mod.js';
14
15
  export declare class LauncherHistory {
15
16
  inner: ILauncherHistory;
16
17
  constructor(inner: ILauncherHistory);
17
18
  static getAsync(): Promise<LauncherHistory>;
18
- static onChange(cb: (user: LauncherHistory) => void): Promise<UnSubscriber>;
19
+ static onChange(cb: (payload: LauncherHistory) => void): Promise<UnSubscriber>;
19
20
  }
20
21
  //# sourceMappingURL=mod.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../src/state/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEnF,OAAO,KAAK,EAAE,eAAe,IAAI,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAE3E,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mCAAmC,CAAC;AAClD,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAE7B,qBAAa,eAAe;IACP,KAAK,EAAE,gBAAgB;gBAAvB,KAAK,EAAE,gBAAgB;IAE1C,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,eAAe,CAAC;IAI3C,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,eAAe,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;CAG5E"}
1
+ {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../src/state/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEnF,OAAO,KAAK,EAAE,eAAe,IAAI,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAE3E,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mCAAmC,CAAC;AAClD,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AAEnC,qBAAa,eAAe;IACP,KAAK,EAAE,gBAAgB;gBAAvB,KAAK,EAAE,gBAAgB;IAE1C,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,eAAe,CAAC;IAI3C,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,OAAO,EAAE,eAAe,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;CAG/E"}
@@ -28,6 +28,7 @@ __exportStar(require("./icon_pack.js"), exports);
28
28
  __exportStar(require("./plugin/mod.js"), exports);
29
29
  __exportStar(require("./widget/mod.js"), exports);
30
30
  __exportStar(require("./profile.js"), exports);
31
+ __exportStar(require("./wallpaper/mod.js"), exports);
31
32
  class LauncherHistory {
32
33
  inner;
33
34
  constructor(inner) {
@@ -3,7 +3,7 @@ import { List } from '../../utils/List.js';
3
3
  import type { Plugin } from '../../types/mod.js';
4
4
  export declare class PluginList extends List<Plugin> {
5
5
  static getAsync(): Promise<PluginList>;
6
- static onChange(cb: (user: PluginList) => void): Promise<UnSubscriber>;
6
+ static onChange(cb: (payload: PluginList) => void): Promise<UnSubscriber>;
7
7
  forCurrentWidget(): Plugin[];
8
8
  }
9
9
  //# sourceMappingURL=mod.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../src/state/plugin/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAE3C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAGjD,qBAAa,UAAW,SAAQ,IAAI,CAAC,MAAM,CAAC;IAC1C,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,UAAU,CAAC;IAItC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,UAAU,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;IAItE,gBAAgB,IAAI,MAAM,EAAE;CAI7B"}
1
+ {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../src/state/plugin/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAE3C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAGjD,qBAAa,UAAW,SAAQ,IAAI,CAAC,MAAM,CAAC;IAC1C,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,UAAU,CAAC;IAItC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,OAAO,EAAE,UAAU,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;IAIzE,gBAAgB,IAAI,MAAM,EAAE;CAI7B"}
@@ -1,12 +1,14 @@
1
1
  import { type UnSubscriber } from '../../handlers/mod.js';
2
- import type { FancyToolbarSettings, FancyToolbarSide, HideMode, SeelenLauncherMonitor, SeelenLauncherSettings, SeelenWallSettings, SeelenWegMode, SeelenWegSettings, SeelenWegSide, Settings as ISettings, ThirdPartyWidgetSettings, UpdateChannel, VirtualDesktopStrategy, WindowManagerSettings } from '../../types/mod.js';
2
+ import type { FancyToolbarSettings, FancyToolbarSide, HideMode, SeelenLauncherMonitor, SeelenLauncherSettings, SeelenWallSettings, SeelenWegMode, SeelenWegSettings, SeelenWegSide, Settings as ISettings, ThirdPartyWidgetSettings, UpdateChannel, WindowManagerSettings } from '../../types/mod.js';
3
3
  import type { Enum } from '../../utils/enums.js';
4
+ export interface Settings extends ISettings {
5
+ }
4
6
  export declare class Settings {
5
7
  inner: ISettings;
6
8
  constructor(inner: ISettings);
7
9
  static default(): Promise<Settings>;
8
10
  static getAsync(): Promise<Settings>;
9
- static onChange(cb: (user: Settings) => void): Promise<UnSubscriber>;
11
+ static onChange(cb: (payload: Settings) => void): Promise<UnSubscriber>;
10
12
  static loadCustom(path: string): Promise<Settings>;
11
13
  /**
12
14
  * Returns the settings for the current widget, taking in care of the replicas
@@ -16,7 +18,7 @@ export declare class Settings {
16
18
  * - the instance patch settings (if apply)
17
19
  * - the monitor patch settings (if apply)
18
20
  */
19
- getCurrentWidgetConfig(): Promise<ThirdPartyWidgetSettings>;
21
+ getCurrentWidgetConfig(): ThirdPartyWidgetSettings;
20
22
  private getBundledWidgetConfig;
21
23
  get fancyToolbar(): FancyToolbarSettings;
22
24
  get seelenweg(): SeelenWegSettings;
@@ -27,12 +29,11 @@ export declare class Settings {
27
29
  save(): Promise<void>;
28
30
  }
29
31
  declare const FancyToolbarSide: Enum<FancyToolbarSide>;
30
- declare const VirtualDesktopStrategy: Enum<VirtualDesktopStrategy>;
31
32
  declare const SeelenWegMode: Enum<SeelenWegMode>;
32
33
  declare const HideMode: Enum<HideMode>;
33
34
  declare const SeelenWegSide: Enum<SeelenWegSide>;
34
35
  declare const SeelenLauncherMonitor: Enum<SeelenLauncherMonitor>;
35
36
  declare const UpdateChannel: Enum<UpdateChannel>;
36
- export { FancyToolbarSide, HideMode, SeelenLauncherMonitor, SeelenWegMode, SeelenWegSide, UpdateChannel, VirtualDesktopStrategy, };
37
+ export { FancyToolbarSide, HideMode, SeelenLauncherMonitor, SeelenWegMode, SeelenWegSide, UpdateChannel };
37
38
  export * from './settings_by_monitor.js';
38
39
  //# sourceMappingURL=mod.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../src/state/settings/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAEtF,OAAO,KAAK,EACV,oBAAoB,EACpB,gBAAgB,EAChB,QAAQ,EACR,qBAAqB,EACrB,sBAAsB,EACtB,kBAAkB,EAClB,aAAa,EACb,iBAAiB,EACjB,aAAa,EACb,QAAQ,IAAI,SAAS,EACrB,wBAAwB,EACxB,aAAa,EACb,sBAAsB,EAEtB,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAWjD,qBAAa,QAAQ;IACA,KAAK,EAAE,SAAS;gBAAhB,KAAK,EAAE,SAAS;IAEnC,MAAM,CAAC,OAAO,IAAI,OAAO,CAAC,QAAQ,CAAC;IAInC,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,QAAQ,CAAC;IAIpC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;IAIpE,MAAM,CAAC,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC;IAIlD;;;;;;;OAOG;IACG,sBAAsB,IAAI,OAAO,CAAC,wBAAwB,CAAC;IAkBjE,OAAO,CAAC,sBAAsB;IAM9B,IAAI,YAAY,IAAI,oBAAoB,CAEvC;IAED,IAAI,SAAS,IAAI,iBAAiB,CAEjC;IAED,IAAI,aAAa,IAAI,qBAAqB,CAEzC;IAED,IAAI,QAAQ,IAAI,sBAAsB,CAErC;IAED,IAAI,IAAI,IAAI,kBAAkB,CAE7B;IAED,sCAAsC;IACtC,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAGtB;AAMD,QAAA,MAAM,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,CAG5C,CAAC;AAEF,QAAA,MAAM,sBAAsB,EAAE,IAAI,CAAC,sBAAsB,CAGxD,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,IAAI,CAAC,aAAa,CAGtC,CAAC;AAEF,QAAA,MAAM,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAI5B,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,IAAI,CAAC,aAAa,CAKtC,CAAC;AAEF,QAAA,MAAM,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,CAGtD,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,IAAI,CAAC,aAAa,CAItC,CAAC;AAEF,OAAO,EACL,gBAAgB,EAChB,QAAQ,EACR,qBAAqB,EACrB,aAAa,EACb,aAAa,EACb,aAAa,EACb,sBAAsB,GACvB,CAAC;AAEF,cAAc,0BAA0B,CAAC"}
1
+ {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../src/state/settings/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAEtF,OAAO,KAAK,EACV,oBAAoB,EACpB,gBAAgB,EAChB,QAAQ,EACR,qBAAqB,EACrB,sBAAsB,EACtB,kBAAkB,EAClB,aAAa,EACb,iBAAiB,EACjB,aAAa,EACb,QAAQ,IAAI,SAAS,EACrB,wBAAwB,EACxB,aAAa,EAEb,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAWjD,MAAM,WAAW,QAAS,SAAQ,SAAS;CAAG;AAC9C,qBAAa,QAAQ;IACA,KAAK,EAAE,SAAS;gBAAhB,KAAK,EAAE,SAAS;IAInC,MAAM,CAAC,OAAO,IAAI,OAAO,CAAC,QAAQ,CAAC;IAInC,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,QAAQ,CAAC;IAIpC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,OAAO,EAAE,QAAQ,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;IAIvE,MAAM,CAAC,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC;IAIlD;;;;;;;OAOG;IACH,sBAAsB,IAAI,wBAAwB;IAkBlD,OAAO,CAAC,sBAAsB;IAM9B,IAAI,YAAY,IAAI,oBAAoB,CAEvC;IAED,IAAI,SAAS,IAAI,iBAAiB,CAEjC;IAED,IAAI,aAAa,IAAI,qBAAqB,CAEzC;IAED,IAAI,QAAQ,IAAI,sBAAsB,CAErC;IAED,IAAI,IAAI,IAAI,kBAAkB,CAE7B;IAED,sCAAsC;IACtC,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAGtB;AAMD,QAAA,MAAM,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,CAG5C,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,IAAI,CAAC,aAAa,CAGtC,CAAC;AAEF,QAAA,MAAM,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAI5B,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,IAAI,CAAC,aAAa,CAKtC,CAAC;AAEF,QAAA,MAAM,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,CAGtD,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,IAAI,CAAC,aAAa,CAItC,CAAC;AAEF,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,qBAAqB,EAAE,aAAa,EAAE,aAAa,EAAE,aAAa,EAAE,CAAC;AAE1G,cAAc,0BAA0B,CAAC"}
@@ -14,7 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.VirtualDesktopStrategy = exports.UpdateChannel = exports.SeelenWegSide = exports.SeelenWegMode = exports.SeelenLauncherMonitor = exports.HideMode = exports.FancyToolbarSide = exports.Settings = void 0;
17
+ exports.UpdateChannel = exports.SeelenWegSide = exports.SeelenWegMode = exports.SeelenLauncherMonitor = exports.HideMode = exports.FancyToolbarSide = exports.Settings = void 0;
18
18
  const mod_js_1 = require("../../handlers/mod.js");
19
19
  const State_js_1 = require("../../utils/State.js");
20
20
  const mod_js_2 = require("../../handlers/mod.js");
@@ -23,6 +23,7 @@ class Settings {
23
23
  inner;
24
24
  constructor(inner) {
25
25
  this.inner = inner;
26
+ Object.assign(this, this.inner);
26
27
  }
27
28
  static default() {
28
29
  return (0, State_js_1.newFromInvoke)(this, mod_js_1.SeelenCommand.StateGetDefaultSettings);
@@ -44,13 +45,13 @@ class Settings {
44
45
  * - the instance patch settings (if apply)
45
46
  * - the monitor patch settings (if apply)
46
47
  */
47
- async getCurrentWidgetConfig() {
48
- const currentWidget = await mod_js_3.Widget.getCurrentAsync();
48
+ getCurrentWidgetConfig() {
49
+ const currentWidget = mod_js_3.Widget.getCurrent();
49
50
  const widgetId = currentWidget.id;
50
51
  const { monitorId, instanceId } = currentWidget.decoded;
51
52
  const root = this.inner.byWidget[widgetId];
52
53
  const instance = instanceId ? root?.$instances?.[instanceId] : undefined;
53
- const monitor = monitorId ? this.inner.monitorsV2[monitorId]?.byWidget[widgetId] : undefined;
54
+ const monitor = monitorId ? this.inner.monitorsV3[monitorId]?.byWidget[widgetId] : undefined;
54
55
  return {
55
56
  ...currentWidget.getDefaultConfig(),
56
57
  ...(root || {}),
@@ -93,11 +94,6 @@ const FancyToolbarSide = {
93
94
  Bottom: 'Bottom',
94
95
  };
95
96
  exports.FancyToolbarSide = FancyToolbarSide;
96
- const VirtualDesktopStrategy = {
97
- Native: 'Native',
98
- Seelen: 'Seelen',
99
- };
100
- exports.VirtualDesktopStrategy = VirtualDesktopStrategy;
101
97
  const SeelenWegMode = {
102
98
  FullWidth: 'FullWidth',
103
99
  MinContent: 'MinContent',
@@ -1,10 +1,7 @@
1
- import type { MonitorConfiguration as IMonitorConfiguration, WorkspaceIdentifierType } from '../../types/mod.js';
2
- import type { Enum } from '../../utils/enums.js';
1
+ import type { MonitorConfiguration as IMonitorConfiguration } from '../../types/mod.js';
3
2
  export declare class MonitorConfiguration {
4
3
  inner: IMonitorConfiguration;
5
4
  constructor(inner: IMonitorConfiguration);
6
5
  static default(): Promise<MonitorConfiguration>;
7
6
  }
8
- declare const WorkspaceIdentifierType: Enum<WorkspaceIdentifierType>;
9
- export { WorkspaceIdentifierType };
10
7
  //# sourceMappingURL=settings_by_monitor.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"settings_by_monitor.d.ts","sourceRoot":"","sources":["../../../src/state/settings/settings_by_monitor.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,IAAI,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAEjH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAEjD,qBAAa,oBAAoB;IACZ,KAAK,EAAE,qBAAqB;gBAA5B,KAAK,EAAE,qBAAqB;IAE/C,MAAM,CAAC,OAAO,IAAI,OAAO,CAAC,oBAAoB,CAAC;CAGhD;AAMD,QAAA,MAAM,uBAAuB,EAAE,IAAI,CAAC,uBAAuB,CAG1D,CAAC;AAEF,OAAO,EAAE,uBAAuB,EAAE,CAAC"}
1
+ {"version":3,"file":"settings_by_monitor.d.ts","sourceRoot":"","sources":["../../../src/state/settings/settings_by_monitor.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,IAAI,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAGxF,qBAAa,oBAAoB;IACZ,KAAK,EAAE,qBAAqB;gBAA5B,KAAK,EAAE,qBAAqB;IAE/C,MAAM,CAAC,OAAO,IAAI,OAAO,CAAC,oBAAoB,CAAC;CAGhD"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.WorkspaceIdentifierType = exports.MonitorConfiguration = void 0;
3
+ exports.MonitorConfiguration = void 0;
4
4
  const mod_js_1 = require("../../handlers/mod.js");
5
5
  const State_js_1 = require("../../utils/State.js");
6
6
  class MonitorConfiguration {
@@ -13,11 +13,3 @@ class MonitorConfiguration {
13
13
  }
14
14
  }
15
15
  exports.MonitorConfiguration = MonitorConfiguration;
16
- // =================================================================================
17
- // From here some enums as helpers like @seelen-ui/types only contains types
18
- // =================================================================================
19
- const WorkspaceIdentifierType = {
20
- Name: 'Name',
21
- Index: 'Index',
22
- };
23
- exports.WorkspaceIdentifierType = WorkspaceIdentifierType;
@@ -4,7 +4,7 @@ import { type UnSubscriber } from '../handlers/mod.js';
4
4
  import type { Enum } from '../utils/enums.js';
5
5
  export declare class AppConfigurationList extends List<AppConfig> {
6
6
  static getAsync(): Promise<AppConfigurationList>;
7
- static onChange(cb: (user: AppConfigurationList) => void): Promise<UnSubscriber>;
7
+ static onChange(cb: (payload: AppConfigurationList) => void): Promise<UnSubscriber>;
8
8
  }
9
9
  declare const AppExtraFlag: Enum<AppExtraFlag>;
10
10
  declare const AppIdentifierType: Enum<AppIdentifierType>;
@@ -1 +1 @@
1
- {"version":3,"file":"settings_by_app.d.ts","sourceRoot":"","sources":["../../src/state/settings_by_app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACpG,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AACxC,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAGnF,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAE9C,qBAAa,oBAAqB,SAAQ,IAAI,CAAC,SAAS,CAAC;IACvD,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,oBAAoB,CAAC;IAIhD,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,oBAAoB,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;CAGjF;AAMD,QAAA,MAAM,YAAY,EAAE,IAAI,CAAC,YAAY,CAMpC,CAAC;AAEF,QAAA,MAAM,iBAAiB,EAAE,IAAI,CAAC,iBAAiB,CAK9C,CAAC;AAEF,QAAA,MAAM,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,CAM5C,CAAC;AAEF,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,CAAC"}
1
+ {"version":3,"file":"settings_by_app.d.ts","sourceRoot":"","sources":["../../src/state/settings_by_app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACpG,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AACxC,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAGnF,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAE9C,qBAAa,oBAAqB,SAAQ,IAAI,CAAC,SAAS,CAAC;IACvD,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,oBAAoB,CAAC;IAIhD,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,OAAO,EAAE,oBAAoB,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;CAGpF;AAMD,QAAA,MAAM,YAAY,EAAE,IAAI,CAAC,YAAY,CAMpC,CAAC;AAEF,QAAA,MAAM,iBAAiB,EAAE,IAAI,CAAC,iBAAiB,CAK9C,CAAC;AAEF,QAAA,MAAM,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,CAM5C,CAAC;AAEF,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,CAAC"}
@@ -1,8 +1,24 @@
1
- import type { Theme } from '../../types/mod.js';
1
+ import type { ResourceId, Settings as ISettings, Theme as ITheme, ThemeId, ThemeVariableDefinition } from '../../types/mod.js';
2
2
  import { type UnSubscriber } from '../../handlers/mod.js';
3
3
  import { List } from '../../utils/List.js';
4
- export declare class ThemeList extends List<Theme> {
4
+ export declare class ThemeList extends List<ITheme> {
5
5
  static getAsync(): Promise<ThemeList>;
6
- static onChange(cb: (user: ThemeList) => void): Promise<UnSubscriber>;
6
+ static onChange(cb: (payload: ThemeList) => void): Promise<UnSubscriber>;
7
+ applyToDocument(activeIds: ThemeId[], variables: ISettings['byTheme']): void;
7
8
  }
9
+ export interface Theme extends ITheme {
10
+ }
11
+ export declare class Theme {
12
+ constructor(plain: ITheme);
13
+ forEachVariableDefinition(cb: (def: ThemeVariableDefinition) => void): void;
14
+ /** Will add the styles targeting the current widget id */
15
+ applyToDocument(varValues?: ISettings['byTheme'][ResourceId]): void;
16
+ removeFromDocument(): void;
17
+ }
18
+ export declare function removeAllThemeStyles(): void;
19
+ /**
20
+ * This will apply the active themes for this widget, and automatically update
21
+ * when the themes or settings change. Also will add the systehm ui colors to the document.
22
+ */
23
+ export declare function startThemingTool(): Promise<void>;
8
24
  //# sourceMappingURL=mod.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../src/state/theme/mod.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAG3C,qBAAa,SAAU,SAAQ,IAAI,CAAC,KAAK,CAAC;IACxC,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,SAAS,CAAC;IAIrC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,SAAS,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;CAGtE"}
1
+ {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../src/state/theme/mod.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,QAAQ,IAAI,SAAS,EACrB,KAAK,IAAI,MAAM,EAEf,OAAO,EACP,uBAAuB,EACxB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAA8B,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAM3C,qBAAa,SAAU,SAAQ,IAAI,CAAC,MAAM,CAAC;IACzC,MAAM,CAAC,QAAQ,IAAI,OAAO,CAAC,SAAS,CAAC;IAIrC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC,OAAO,EAAE,SAAS,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC;IAIxE,eAAe,CAAC,SAAS,EAAE,OAAO,EAAE,EAAE,SAAS,EAAE,SAAS,CAAC,SAAS,CAAC,GAAG,IAAI;CAe7E;AAED,MAAM,WAAW,KAAM,SAAQ,MAAM;CAAG;AAExC,qBAAa,KAAK;gBACJ,KAAK,EAAE,MAAM;IAIzB,yBAAyB,CAAC,EAAE,EAAE,CAAC,GAAG,EAAE,uBAAuB,KAAK,IAAI,GAAG,IAAI;IAI3E,0DAA0D;IAC1D,eAAe,CAAC,SAAS,GAAE,SAAS,CAAC,SAAS,CAAC,CAAC,UAAU,CAAM,GAAG,IAAI;IAkCvE,kBAAkB,IAAI,IAAI;CAG3B;AAgBD,wBAAgB,oBAAoB,IAAI,IAAI,CAK3C;AAED;;;GAGG;AACH,wBAAsB,gBAAgB,IAAI,OAAO,CAAC,IAAI,CAAC,CAkBtD"}