Compare commits

...

18 Commits

Author SHA1 Message Date
0683378e39 2.1.1 2025-01-09 00:33:46 +01:00
25a813d35f fix(themamanager): Fixed automatic global theme change subscription for background updates. 2025-01-09 00:33:46 +01:00
916fd48858 2.1.0 2025-01-09 00:24:17 +01:00
90bb1eb432 feat(themeManager): Exposed method to enable automatic global theme change. 2025-01-09 00:24:17 +01:00
126e0fc900 2.0.65 2024-10-21 17:25:08 +02:00
a20b321bb0 fix(ThemeManager): Refactor ThemeManager class to separate global style setting logic 2024-10-21 17:25:08 +02:00
33721f86ab 2.0.64 2024-10-06 23:37:21 +02:00
987c821eed fix(pluginexports): Add missing import for smartrouter in pluginexports. 2024-10-06 23:37:21 +02:00
b0bed44810 2.0.63 2024-10-06 23:31:45 +02:00
0a7da5132d fix(dependencies): Update @push.rocks/smartrouter to version ^1.3.2 for better compatibility 2024-10-06 23:31:44 +02:00
b0bb8e9e2b 2.0.62 2024-10-06 21:42:11 +02:00
1f346e24db fix(dependencies): Update dependencies to resolve potential issues and improve stability 2024-10-06 21:42:10 +02:00
c34cca7eb6 2.0.61 2024-10-04 15:28:01 +02:00
15e58fbf5d fix(core): Correct import statement for SweetScroll. 2024-10-04 15:28:01 +02:00
2383e6ec21 2.0.60 2024-10-02 17:49:28 +02:00
5820bf81f6 fix(dependencies): Update dependencies to latest versions 2024-10-02 17:49:27 +02:00
9c6cfa3603 2.0.59 2024-10-02 15:45:46 +02:00
cc934a9c0e fix(core): Refactor plugin exports to improve modularity 2024-10-02 15:45:45 +02:00
7 changed files with 4037 additions and 874 deletions

View File

@ -1,5 +1,56 @@
# Changelog
## 2025-01-09 - 2.1.1 - fix(themamanager)
Fixed automatic global theme change subscription for background updates.
- Corrected the logic for updating the document's background color upon theme changes using themeObservable subscription.
## 2025-01-09 - 2.1.0 - feat(themeManager)
Exposed method to enable automatic global theme change.
- Enable easier application of dark and bright themes by exposing a method.
- Updated devDependencies and dependencies in package.json to latest versions.
## 2024-10-21 - 2.0.65 - fix(ThemeManager)
Refactor ThemeManager class to separate global style setting logic
- Moved logic to set global styles into a dedicated function setGlobalStylesOnPurpose in ThemeManager.
## 2024-10-06 - 2.0.64 - fix(pluginexports)
Add missing import for smartrouter in pluginexports.
- Fixed a missing import for smartrouter in ts/domtools.pluginexports.ts.
## 2024-10-06 - 2.0.63 - fix(dependencies)
Update @push.rocks/smartrouter to version ^1.3.2 for better compatibility
- Updated @push.rocks/smartrouter from version ^1.2.1 to ^1.3.2 in package.json.
## 2024-10-06 - 2.0.62 - fix(dependencies)
Update dependencies to resolve potential issues and improve stability
## 2024-10-04 - 2.0.61 - fix(core)
Correct import statement for SweetScroll.
- Fix import syntax for SweetScroll in domtools.pluginexports.ts
## 2024-10-02 - 2.0.60 - fix(dependencies)
Update dependencies to latest versions
- Bump @git.zone/tsbuild version from 2.1.82 to 2.1.84
- Bump @push.rocks/tapbundle version from 5.0.23 to 5.3.0
- Bump @types/node version from 20.14.9 to 22.7.4
- Bump @api.global/typedrequest version from 3.0.30 to 3.0.32
- Bump @push.rocks/smartstate version from 2.0.17 to 2.0.18
- Bump lit version from 3.1.4 to 3.2.0
## 2024-10-02 - 2.0.59 - fix(core)
Refactor plugin exports to improve modularity
- Refactored the plugin exports to be more modular and organized.
- Replaced redundant plugin object definition in ts/index.ts with a simpler import and export pattern.
## 2024-07-01 - 2.0.58 - fix(dependencies)
Update dependencies and correct font family in styles

View File

@ -1,6 +1,6 @@
{
"name": "@design.estate/dees-domtools",
"version": "2.0.58",
"version": "2.1.1",
"private": false,
"description": "A package providing tools to simplify complex CSS structures and web development tasks, featuring TypeScript support and integration with various web technologies.",
"main": "dist_ts/index.js",
@ -15,29 +15,29 @@
"buildDocs": "tsdoc"
},
"devDependencies": {
"@git.zone/tsbuild": "^2.1.82",
"@git.zone/tsbundle": "^2.0.15",
"@git.zone/tsbuild": "^2.2.0",
"@git.zone/tsbundle": "^2.1.0",
"@git.zone/tstest": "^1.0.90",
"@push.rocks/tapbundle": "^5.0.23",
"@types/node": "^20.14.9"
"@push.rocks/tapbundle": "^5.5.4",
"@types/node": "^22.10.5"
},
"dependencies": {
"@api.global/typedrequest": "^3.0.30",
"@api.global/typedrequest": "^3.1.10",
"@design.estate/dees-comms": "^1.0.27",
"@push.rocks/lik": "^6.0.15",
"@push.rocks/lik": "^6.1.0",
"@push.rocks/smartdelay": "^3.0.5",
"@push.rocks/smartjson": "^5.0.20",
"@push.rocks/smartmarkdown": "^3.0.3",
"@push.rocks/smartpromise": "^4.0.4",
"@push.rocks/smartrouter": "^1.0.16",
"@push.rocks/smartpromise": "^4.1.0",
"@push.rocks/smartrouter": "^1.3.2",
"@push.rocks/smartrx": "^3.0.7",
"@push.rocks/smartstate": "^2.0.17",
"@push.rocks/smartstate": "^2.0.19",
"@push.rocks/smartstring": "^4.0.15",
"@push.rocks/smarturl": "^3.0.6",
"@push.rocks/smarturl": "^3.1.0",
"@push.rocks/webrequest": "^3.0.37",
"@push.rocks/websetup": "^3.0.19",
"@push.rocks/webstore": "^2.0.20",
"lit": "^3.1.4",
"lit": "^3.2.1",
"sweet-scroll": "^4.0.0"
},
"files": [

4785
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

View File

@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@design.estate/dees-domtools',
version: '2.0.58',
version: '2.1.1',
description: 'A package providing tools to simplify complex CSS structures and web development tasks, featuring TypeScript support and integration with various web technologies.'
}

View File

@ -21,10 +21,17 @@ export class ThemeManager {
this.updateAllConnectedElements();
}
private async updateAllConnectedElements() {
public async enableAutomaticGlobalThemeChange() {
if (document.body && document.body.style) {
document.body.style.background = this.goBrightBoolean ? '#fff' : '#000';
this.themeObservable.subscribe({
next: (goBright) => {
document.body.style.background = goBright ? '#fff' : '#000';
}
});
}
}
private async updateAllConnectedElements() {
this.themeObservable.next(this.goBrightBoolean);
}

View File

@ -0,0 +1,23 @@
import * as smartdelay from '@push.rocks/smartdelay';
import * as smartmarkdown from '@push.rocks/smartmarkdown';
import * as smartpromise from '@push.rocks/smartpromise';
import SweetScroll from 'sweet-scroll';
import * as smartstate from '@push.rocks/smartstate';
import * as smartrouter from '@push.rocks/smartrouter';
import * as smartrx from '@push.rocks/smartrx';
import * as smartstring from '@push.rocks/smartstring';
import * as smarturl from '@push.rocks/smarturl';
import * as typedrequest from '@api.global/typedrequest';
export {
smartdelay,
smartmarkdown,
smartpromise,
SweetScroll,
smartstate,
smartrouter,
smartrx,
smartstring,
smarturl,
typedrequest
};

View File

@ -9,19 +9,8 @@ export { DomTools, type IDomToolsContructorOptions } from './domtools.classes.do
export { TypedRequest } from '@api.global/typedrequest';
export { type IWebSetupConstructorOptions } from '@push.rocks/websetup';
import * as allPlugins from './domtools.plugins.js';
export const plugins = {
smartdelay: allPlugins.smartdelay,
smartmarkdown: allPlugins.smartmarkdown,
smartpromise: allPlugins.smartpromise,
SweetScroll: allPlugins.SweetScroll,
smartstate: allPlugins.smartstate,
smartrx: allPlugins.smartrx,
smartstring: allPlugins.smartstring,
smarturl: allPlugins.smarturl,
typedrequest: allPlugins.typedrequest,
};
import * as plugins from './domtools.pluginexports.js';
export { plugins };
// type exports
import type { rxjs } from '@push.rocks/smartrx';