@univerjs/core 0.7.0-beta.0 → 0.7.0-nightly.202504301607
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/index.js +1 -1
- package/lib/es/facade.js +1 -0
- package/lib/es/index.js +5 -3
- package/lib/facade.js +1 -0
- package/lib/index.js +5 -3
- package/lib/types/facade/f-univer.d.ts +1 -0
- package/lib/types/services/theme/theme.service.d.ts +1 -1
- package/lib/types/shared/color/color.d.ts +7 -1
- package/lib/types/types/enum/theme-color-type.d.ts +5 -0
- package/lib/umd/index.js +1 -1
- package/package.json +2 -2
- package/LICENSE +0 -176
package/lib/es/facade.js
CHANGED
package/lib/es/index.js
CHANGED
|
@@ -13929,7 +13929,7 @@ class r_ extends re {
|
|
|
13929
13929
|
this._error$.next({ errorKey: n });
|
|
13930
13930
|
}
|
|
13931
13931
|
}
|
|
13932
|
-
const s_ = "0.7.0-
|
|
13932
|
+
const s_ = "0.7.0-nightly.202504301607", i_ = {
|
|
13933
13933
|
version: s_
|
|
13934
13934
|
};
|
|
13935
13935
|
function o_(t = "", e = Hr.ZH_CN, n = "") {
|
|
@@ -16460,7 +16460,6 @@ class j_ extends re {
|
|
|
16460
16460
|
class Ka extends re {
|
|
16461
16461
|
constructor() {
|
|
16462
16462
|
super();
|
|
16463
|
-
C(this, "_darkMode");
|
|
16464
16463
|
C(this, "_darkMode$", new oe(!1));
|
|
16465
16464
|
C(this, "darkMode$", this._darkMode$.asObservable());
|
|
16466
16465
|
C(this, "_currentTheme");
|
|
@@ -16470,6 +16469,9 @@ class Ka extends re {
|
|
|
16470
16469
|
this._currentTheme$.complete(), this._darkMode$.complete();
|
|
16471
16470
|
}));
|
|
16472
16471
|
}
|
|
16472
|
+
get darkMode() {
|
|
16473
|
+
return this._darkMode$.getValue();
|
|
16474
|
+
}
|
|
16473
16475
|
getCurrentTheme() {
|
|
16474
16476
|
if (!this._currentTheme)
|
|
16475
16477
|
throw new Error("[ThemeService]: current theme is not set!");
|
|
@@ -16479,7 +16481,7 @@ class Ka extends re {
|
|
|
16479
16481
|
this._currentTheme = n, this._currentTheme$.next(n);
|
|
16480
16482
|
}
|
|
16481
16483
|
setDarkMode(n) {
|
|
16482
|
-
this._darkMode
|
|
16484
|
+
this._darkMode$.next(n);
|
|
16483
16485
|
}
|
|
16484
16486
|
}
|
|
16485
16487
|
var W_ = Object.getOwnPropertyDescriptor, Y_ = (t, e, n, r) => {
|
package/lib/facade.js
CHANGED
package/lib/index.js
CHANGED
|
@@ -13929,7 +13929,7 @@ class r_ extends re {
|
|
|
13929
13929
|
this._error$.next({ errorKey: n });
|
|
13930
13930
|
}
|
|
13931
13931
|
}
|
|
13932
|
-
const s_ = "0.7.0-
|
|
13932
|
+
const s_ = "0.7.0-nightly.202504301607", i_ = {
|
|
13933
13933
|
version: s_
|
|
13934
13934
|
};
|
|
13935
13935
|
function o_(t = "", e = Hr.ZH_CN, n = "") {
|
|
@@ -16460,7 +16460,6 @@ class j_ extends re {
|
|
|
16460
16460
|
class Ka extends re {
|
|
16461
16461
|
constructor() {
|
|
16462
16462
|
super();
|
|
16463
|
-
C(this, "_darkMode");
|
|
16464
16463
|
C(this, "_darkMode$", new oe(!1));
|
|
16465
16464
|
C(this, "darkMode$", this._darkMode$.asObservable());
|
|
16466
16465
|
C(this, "_currentTheme");
|
|
@@ -16470,6 +16469,9 @@ class Ka extends re {
|
|
|
16470
16469
|
this._currentTheme$.complete(), this._darkMode$.complete();
|
|
16471
16470
|
}));
|
|
16472
16471
|
}
|
|
16472
|
+
get darkMode() {
|
|
16473
|
+
return this._darkMode$.getValue();
|
|
16474
|
+
}
|
|
16473
16475
|
getCurrentTheme() {
|
|
16474
16476
|
if (!this._currentTheme)
|
|
16475
16477
|
throw new Error("[ThemeService]: current theme is not set!");
|
|
@@ -16479,7 +16481,7 @@ class Ka extends re {
|
|
|
16479
16481
|
this._currentTheme = n, this._currentTheme$.next(n);
|
|
16480
16482
|
}
|
|
16481
16483
|
setDarkMode(n) {
|
|
16482
|
-
this._darkMode
|
|
16484
|
+
this._darkMode$.next(n);
|
|
16483
16485
|
}
|
|
16484
16486
|
}
|
|
16485
16487
|
var W_ = Object.getOwnPropertyDescriptor, Y_ = (t, e, n, r) => {
|
|
@@ -4,9 +4,9 @@ export interface IStyleSheet {
|
|
|
4
4
|
[key: string]: string;
|
|
5
5
|
}
|
|
6
6
|
export declare class ThemeService extends Disposable {
|
|
7
|
-
private _darkMode;
|
|
8
7
|
private readonly _darkMode$;
|
|
9
8
|
readonly darkMode$: Observable<boolean>;
|
|
9
|
+
get darkMode(): boolean;
|
|
10
10
|
private _currentTheme;
|
|
11
11
|
private readonly _currentTheme$;
|
|
12
12
|
readonly currentTheme$: Observable<IStyleSheet>;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
import { ColorType, ThemeColors, ThemeColorType } from '../../types/enum';
|
|
2
1
|
import { Nullable } from '../types';
|
|
2
|
+
import { ColorType, ThemeColors, ThemeColorType } from '../../types/enum';
|
|
3
|
+
/**
|
|
4
|
+
* @deprecated
|
|
5
|
+
*/
|
|
3
6
|
export declare class ColorBuilder {
|
|
4
7
|
private _themeValue;
|
|
5
8
|
private _themeColors;
|
|
@@ -16,6 +19,9 @@ export declare class ColorBuilder {
|
|
|
16
19
|
setThemeColor(theme: ThemeColorType): ColorBuilder;
|
|
17
20
|
getColorType(): ColorType;
|
|
18
21
|
}
|
|
22
|
+
/**
|
|
23
|
+
* @deprecated
|
|
24
|
+
*/
|
|
19
25
|
export declare class Color {
|
|
20
26
|
protected _builder: ColorBuilder;
|
|
21
27
|
constructor(builder: ColorBuilder);
|
|
@@ -15,6 +15,8 @@
|
|
|
15
15
|
*/
|
|
16
16
|
/**
|
|
17
17
|
* Theme color type enum
|
|
18
|
+
*
|
|
19
|
+
* @deprecated
|
|
18
20
|
*/
|
|
19
21
|
export declare enum ThemeColorType {
|
|
20
22
|
/**
|
|
@@ -39,6 +41,9 @@ export declare enum ThemeColorType {
|
|
|
39
41
|
HYPERLINK = 10,
|
|
40
42
|
FOLLOWED_HYPERLINK = 11
|
|
41
43
|
}
|
|
44
|
+
/**
|
|
45
|
+
* @deprecated
|
|
46
|
+
*/
|
|
42
47
|
export declare enum ThemeColors {
|
|
43
48
|
OFFICE = "Office",
|
|
44
49
|
OFFICE_2007_2010 = "Office 2007-2010",
|