@ojiepermana/angular-theme 22.0.35 → 22.0.41
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/README.md +54 -22
- package/fesm2022/ojiepermana-angular-theme-layout-wrapper.mjs +74 -20
- package/fesm2022/ojiepermana-angular-theme-layout.mjs +14 -2
- package/fesm2022/ojiepermana-angular-theme-page.mjs +251 -101
- package/fesm2022/ojiepermana-angular-theme-styles.mjs +375 -53
- package/layout/README.md +21 -19
- package/package.json +3 -3
- package/page/README.md +53 -15
- package/styles/README.md +18 -3
- package/styles/css/{seasonal/base → base}/tailwind.css +9 -5
- package/styles/css/{seasonal/base → base}/theme.css +27 -52
- package/styles/css/{seasonal/base → base}/tokens.css +62 -44
- package/styles/css/color/amber.css +52 -0
- package/styles/css/color/blue.css +52 -0
- package/styles/css/color/brand.css +16 -0
- package/styles/css/color/cyan.css +52 -0
- package/styles/css/color/emerald.css +52 -0
- package/styles/css/color/fuchsia.css +52 -0
- package/styles/css/color/green.css +52 -0
- package/styles/css/color/index.css +19 -0
- package/styles/css/color/indigo.css +52 -0
- package/styles/css/color/lime.css +52 -0
- package/styles/css/color/orange.css +52 -0
- package/styles/css/color/pink.css +52 -0
- package/styles/css/color/purple.css +52 -0
- package/styles/css/color/red.css +52 -0
- package/styles/css/color/rose.css +52 -0
- package/styles/css/color/sky.css +52 -0
- package/styles/css/color/teal.css +52 -0
- package/styles/css/color/violet.css +52 -0
- package/styles/css/color/yellow.css +52 -0
- package/styles/css/index.css +15 -6
- package/styles/css/neutral/gray.css +36 -0
- package/styles/css/neutral/index.css +11 -0
- package/styles/css/neutral/mauve.css +36 -0
- package/styles/css/neutral/mist.css +36 -0
- package/styles/css/neutral/neutral.css +36 -0
- package/styles/css/neutral/olive.css +36 -0
- package/styles/css/neutral/slate.css +36 -0
- package/styles/css/neutral/stone.css +36 -0
- package/styles/css/neutral/taupe.css +36 -0
- package/styles/css/neutral/zinc.css +36 -0
- package/styles/css/radius/index.css +29 -0
- package/styles/css/space/index.css +24 -0
- package/types/ojiepermana-angular-theme-layout-wrapper.d.ts +43 -10
- package/types/ojiepermana-angular-theme-layout.d.ts +1 -0
- package/types/ojiepermana-angular-theme-page.d.ts +88 -36
- package/types/ojiepermana-angular-theme-styles.d.ts +169 -37
- package/styles/css/seasonal/ied/package.css +0 -4
- package/styles/css/seasonal/ied/theme.css +0 -78
- package/styles/css/seasonal/imlek/components.css +0 -87
- package/styles/css/seasonal/imlek/package.css +0 -6
- package/styles/css/seasonal/imlek/tailwind.css +0 -144
- package/styles/css/seasonal/imlek/theme.css +0 -95
- package/styles/css/seasonal/imlek/tokens.css +0 -152
- package/styles/css/seasonal/index.css +0 -6
- package/styles/css/seasonal/natal/package.css +0 -4
- package/styles/css/seasonal/natal/theme.css +0 -78
- package/styles/css/seasonal/new-year/package.css +0 -4
- package/styles/css/seasonal/new-year/theme.css +0 -78
- package/styles/css/seasonal/ramadhan/package.css +0 -4
- package/styles/css/seasonal/ramadhan/theme.css +0 -78
- /package/styles/css/{seasonal/base → base}/components.css +0 -0
- /package/styles/css/{seasonal/base → base}/package.css +0 -0
|
@@ -22,6 +22,22 @@ interface UserIdentity {
|
|
|
22
22
|
readonly email: string;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
+
/**
|
|
26
|
+
* Registry identitas brand/user yang dipublikasikan shell (mis. `LayoutWrapperDefault`).
|
|
27
|
+
* Surface lain — seperti apps-launcher di `Page` — membacanya agar menampilkan brand/user
|
|
28
|
+
* yang sama dengan flyout nav tanpa menerima input langsung.
|
|
29
|
+
*/
|
|
30
|
+
declare class LayoutIdentityService {
|
|
31
|
+
private readonly brandState;
|
|
32
|
+
private readonly userState;
|
|
33
|
+
readonly brand: _angular_core.Signal<BrandIdentity | null>;
|
|
34
|
+
readonly user: _angular_core.Signal<UserIdentity | null>;
|
|
35
|
+
setBrand(brand: BrandIdentity | null): void;
|
|
36
|
+
setUser(user: UserIdentity | null): void;
|
|
37
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LayoutIdentityService, never>;
|
|
38
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<LayoutIdentityService>;
|
|
39
|
+
}
|
|
40
|
+
|
|
25
41
|
/**
|
|
26
42
|
* Slot brand untuk `<NavigationHeader>`: inisial/logo + judul. Murni input-driven.
|
|
27
43
|
*
|
|
@@ -69,10 +85,15 @@ declare class LayoutUser {
|
|
|
69
85
|
declare class LayoutNavSidebar {
|
|
70
86
|
readonly brand: _angular_core.InputSignal<BrandIdentity>;
|
|
71
87
|
readonly user: _angular_core.InputSignal<UserIdentity>;
|
|
72
|
-
/** Appearance dari shell (`[appearance]`);
|
|
88
|
+
/** Appearance dari shell (`[appearance]`); menentukan ketebalan border pemisah. */
|
|
73
89
|
readonly appearance: _angular_core.InputSignal<"flat" | "border-rail">;
|
|
74
|
-
|
|
75
|
-
|
|
90
|
+
protected readonly isBorderRail: _angular_core.Signal<boolean>;
|
|
91
|
+
/** Border kanan pemisah; ketebalan ikut appearance: `border-rail` 1.5px, `flat` 1px. */
|
|
92
|
+
protected readonly shellClass: _angular_core.Signal<"border-r-[1.5px] border-border" | "border-r border-border">;
|
|
93
|
+
/** Header divider menebal jadi 1.5px di `border-rail` (selaras nav/shell); `flat` pakai default. */
|
|
94
|
+
protected readonly headerClass: _angular_core.Signal<"border-b-[1.5px] border-border" | "">;
|
|
95
|
+
/** Footer divider menebal jadi 1.5px di `border-rail`; `px-3` tetap dipertahankan. */
|
|
96
|
+
protected readonly footerClass: _angular_core.Signal<"px-3 border-t-[1.5px] border-border" | "px-3">;
|
|
76
97
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LayoutNavSidebar, never>;
|
|
77
98
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LayoutNavSidebar, "LayoutNavSidebar", never, { "brand": { "alias": "brand"; "required": true; "isSignal": true; }; "user": { "alias": "user"; "required": true; "isSignal": true; }; "appearance": { "alias": "appearance"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
78
99
|
}
|
|
@@ -84,10 +105,15 @@ declare class LayoutNavSidebar {
|
|
|
84
105
|
declare class LayoutNavDockbar {
|
|
85
106
|
readonly brand: _angular_core.InputSignal<BrandIdentity>;
|
|
86
107
|
readonly user: _angular_core.InputSignal<UserIdentity>;
|
|
87
|
-
/** Appearance dari shell (`[appearance]`);
|
|
108
|
+
/** Appearance dari shell (`[appearance]`); menentukan ketebalan border pemisah. */
|
|
88
109
|
readonly appearance: _angular_core.InputSignal<"flat" | "border-rail">;
|
|
89
|
-
|
|
90
|
-
|
|
110
|
+
protected readonly isBorderRail: _angular_core.Signal<boolean>;
|
|
111
|
+
/** Border kanan pemisah; ketebalan ikut appearance: `border-rail` 1.5px, `flat` 1px. */
|
|
112
|
+
protected readonly shellClass: _angular_core.Signal<"border-r-[1.5px] border-border" | "border-r border-border">;
|
|
113
|
+
/** Header divider menebal jadi 1.5px di `border-rail` (selaras nav/shell); `flat` pakai default. */
|
|
114
|
+
protected readonly headerClass: _angular_core.Signal<"border-b-[1.5px] border-border" | "">;
|
|
115
|
+
/** Footer divider menebal jadi 1.5px di `border-rail`; `px-3` tetap dipertahankan. */
|
|
116
|
+
protected readonly footerClass: _angular_core.Signal<"px-3 border-t-[1.5px] border-border" | "px-3">;
|
|
91
117
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LayoutNavDockbar, never>;
|
|
92
118
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LayoutNavDockbar, "LayoutNavDockbar", never, { "brand": { "alias": "brand"; "required": true; "isSignal": true; }; "user": { "alias": "user"; "required": true; "isSignal": true; }; "appearance": { "alias": "appearance"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
93
119
|
}
|
|
@@ -167,17 +193,24 @@ declare class LayoutWrapperDefault {
|
|
|
167
193
|
readonly brand: _angular_core.InputSignal<BrandIdentity>;
|
|
168
194
|
/** Identitas user. */
|
|
169
195
|
readonly user: _angular_core.InputSignal<UserIdentity>;
|
|
196
|
+
private readonly identity;
|
|
197
|
+
constructor();
|
|
198
|
+
/**
|
|
199
|
+
* Kelas `<LayoutContent>` yang diatur consumer (mis. padding). Default kosong —
|
|
200
|
+
* library tidak lagi memaksa `p-6`; consumer/`<Page>` yang menentukan spacing.
|
|
201
|
+
*/
|
|
202
|
+
readonly contentClassInput: _angular_core.InputSignal<string>;
|
|
170
203
|
/** Wrapper layout & nilai `<Layout [layout-type]>`: navbar/flyout = horizontal, sisanya vertical. */
|
|
171
204
|
protected readonly effectiveLayoutType: _angular_core.Signal<"fluid" | "vertical" | "horizontal" | "empty">;
|
|
172
205
|
/** Tipe nav di dalam `#body`: `empty`/`fluid` → `brand` (header-only); selain itu `nav-type`. */
|
|
173
206
|
protected readonly navKind: _angular_core.Signal<NavKind>;
|
|
174
207
|
/** Lebar host `<Navigation>`: penuh-tinggi (vertical) atau penuh-lebar (horizontal). */
|
|
175
208
|
protected readonly navClass: _angular_core.Signal<"w-full" | "h-full">;
|
|
176
|
-
/** Kelas `<LayoutContent>`: `fluid` membatasi lebar & memusatkan;
|
|
177
|
-
protected readonly contentClass: _angular_core.Signal<
|
|
209
|
+
/** Kelas `<LayoutContent>`: `fluid` membatasi lebar & memusatkan; padding diserahkan ke consumer. */
|
|
210
|
+
protected readonly contentClass: _angular_core.Signal<string>;
|
|
178
211
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LayoutWrapperDefault, never>;
|
|
179
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LayoutWrapperDefault, "LayoutWrapperDefault", never, { "surface": { "alias": "surface"; "required": false; "isSignal": true; }; "appearance": { "alias": "layout-appearance"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "layoutType": { "alias": "layout-type"; "required": false; "isSignal": true; }; "navType": { "alias": "nav-type"; "required": false; "isSignal": true; }; "data": { "alias": "data"; "required": true; "isSignal": true; }; "brand": { "alias": "brand"; "required": true; "isSignal": true; }; "user": { "alias": "user"; "required": true; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
212
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LayoutWrapperDefault, "LayoutWrapperDefault", never, { "surface": { "alias": "surface"; "required": false; "isSignal": true; }; "appearance": { "alias": "layout-appearance"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "layoutType": { "alias": "layout-type"; "required": false; "isSignal": true; }; "navType": { "alias": "nav-type"; "required": false; "isSignal": true; }; "data": { "alias": "data"; "required": true; "isSignal": true; }; "brand": { "alias": "brand"; "required": true; "isSignal": true; }; "user": { "alias": "user"; "required": true; "isSignal": true; }; "contentClassInput": { "alias": "content-class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
180
213
|
}
|
|
181
214
|
|
|
182
|
-
export { LayoutBrand, LayoutNavDockbar, LayoutNavFlyout, LayoutNavMinimal, LayoutNavNavbar, LayoutNavSidebar, LayoutUser, LayoutWrapperDefault };
|
|
215
|
+
export { LayoutBrand, LayoutIdentityService, LayoutNavDockbar, LayoutNavFlyout, LayoutNavMinimal, LayoutNavNavbar, LayoutNavSidebar, LayoutUser, LayoutWrapperDefault };
|
|
183
216
|
export type { BrandIdentity, UserIdentity };
|
|
@@ -23,6 +23,7 @@ declare class LayoutComponent {
|
|
|
23
23
|
protected readonly resolvedType: _angular_core.Signal<"fluid" | "vertical" | "horizontal" | "empty">;
|
|
24
24
|
protected readonly isBorderRail: _angular_core.Signal<boolean>;
|
|
25
25
|
protected readonly isFluidFrame: _angular_core.Signal<boolean>;
|
|
26
|
+
protected readonly isFullFlat: _angular_core.Signal<boolean>;
|
|
26
27
|
protected readonly showsInsetRails: _angular_core.Signal<boolean>;
|
|
27
28
|
protected readonly frameStageClasses: _angular_core.Signal<string>;
|
|
28
29
|
protected readonly railAnchorClasses: _angular_core.Signal<string>;
|
|
@@ -1,31 +1,78 @@
|
|
|
1
|
+
import * as _ojiepermana_angular_theme_layout_wrapper from '@ojiepermana/angular-theme/layout/wrapper';
|
|
2
|
+
import * as _ojiepermana_angular_navigation_service from '@ojiepermana/angular-navigation/service';
|
|
1
3
|
import * as _angular_core from '@angular/core';
|
|
2
4
|
|
|
5
|
+
declare class PageHeaderComponent {
|
|
6
|
+
private readonly page;
|
|
7
|
+
readonly class: _angular_core.InputSignal<string>;
|
|
8
|
+
protected readonly resolvedHeight: _angular_core.Signal<"auto" | "fix">;
|
|
9
|
+
protected readonly isBorderRail: _angular_core.Signal<boolean>;
|
|
10
|
+
/** Saat tombol apps mengambang di atas header, sisakan ruang kanan agar isi header tidak tertimpa. */
|
|
11
|
+
protected readonly reservesAppsLauncher: _angular_core.Signal<boolean>;
|
|
12
|
+
/** Lebar tombol apps (h-9 w-9 = 36px) + offset kanan (right-2 = 8px) + jarak aman; `null` = tak memesan. */
|
|
13
|
+
protected readonly appsLauncherReservePadding: _angular_core.Signal<"3.5rem" | null>;
|
|
14
|
+
protected readonly classes: _angular_core.Signal<string>;
|
|
15
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageHeaderComponent, never>;
|
|
16
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageHeaderComponent, "PageHeader", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
17
|
+
}
|
|
18
|
+
declare class PageContentComponent {
|
|
19
|
+
private readonly page;
|
|
20
|
+
readonly class: _angular_core.InputSignal<string>;
|
|
21
|
+
protected readonly resolvedScroll: _angular_core.Signal<"content" | "page">;
|
|
22
|
+
protected readonly classes: _angular_core.Signal<string>;
|
|
23
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageContentComponent, never>;
|
|
24
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageContentComponent, "PageContent", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
25
|
+
}
|
|
26
|
+
declare class PageDashboardComponent {
|
|
27
|
+
private readonly page;
|
|
28
|
+
readonly class: _angular_core.InputSignal<string>;
|
|
29
|
+
protected readonly resolvedScroll: _angular_core.Signal<"content" | "page">;
|
|
30
|
+
protected readonly classes: _angular_core.Signal<string>;
|
|
31
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageDashboardComponent, never>;
|
|
32
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageDashboardComponent, "PageDashboard", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
33
|
+
}
|
|
34
|
+
declare class PageFooterComponent {
|
|
35
|
+
private readonly page;
|
|
36
|
+
readonly class: _angular_core.InputSignal<string>;
|
|
37
|
+
protected readonly resolvedHeight: _angular_core.Signal<"auto" | "fix">;
|
|
38
|
+
protected readonly isBorderRail: _angular_core.Signal<boolean>;
|
|
39
|
+
protected readonly classes: _angular_core.Signal<string>;
|
|
40
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageFooterComponent, never>;
|
|
41
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageFooterComponent, "PageFooter", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
42
|
+
}
|
|
43
|
+
|
|
3
44
|
declare const PAGE_VARIANTS: readonly ["stacked", "side"];
|
|
4
45
|
declare const PAGE_SIDE_POSITIONS: readonly ["left", "right"];
|
|
5
46
|
declare const PAGE_SIDE_MODES: readonly ["sticky", "drawer", "overlay"];
|
|
6
47
|
declare const PAGE_SCROLL_VALUES: readonly ["content", "page"];
|
|
7
48
|
declare const PAGE_HEIGHT_VALUES: readonly ["auto", "fix"];
|
|
49
|
+
/** Visual appearance shared with the layout/navigation axes — unifies borders. */
|
|
50
|
+
declare const PAGE_APPEARANCES: readonly ["flat", "border-rail"];
|
|
8
51
|
type PageVariant = (typeof PAGE_VARIANTS)[number];
|
|
9
52
|
type PageSidePosition = (typeof PAGE_SIDE_POSITIONS)[number];
|
|
10
53
|
type PageSideMode = (typeof PAGE_SIDE_MODES)[number];
|
|
11
54
|
type PageScroll = (typeof PAGE_SCROLL_VALUES)[number];
|
|
12
55
|
type PageHeight = (typeof PAGE_HEIGHT_VALUES)[number];
|
|
56
|
+
type PageAppearance = (typeof PAGE_APPEARANCES)[number];
|
|
13
57
|
declare const PAGE_DEFAULT_VARIANT: PageVariant;
|
|
14
58
|
declare const PAGE_DEFAULT_SIDE_POSITION: PageSidePosition;
|
|
15
59
|
declare const PAGE_DEFAULT_SIDE_MODE: PageSideMode;
|
|
16
60
|
declare const PAGE_DEFAULT_SCROLL: PageScroll;
|
|
17
61
|
declare const PAGE_DEFAULT_HEIGHT: PageHeight;
|
|
62
|
+
declare const PAGE_DEFAULT_APPEARANCE: PageAppearance;
|
|
18
63
|
declare const PAGE_DEFAULT_SIDE_WIDTH = "16rem";
|
|
19
64
|
declare function isUiPageVariant(value: string | null): value is PageVariant;
|
|
20
65
|
declare function isUiPageSidePosition(value: string | null): value is PageSidePosition;
|
|
21
66
|
declare function isUiPageSideMode(value: string | null): value is PageSideMode;
|
|
22
67
|
declare function isUiPageScroll(value: string | null): value is PageScroll;
|
|
23
68
|
declare function isUiPageHeight(value: string | null): value is PageHeight;
|
|
69
|
+
declare function isUiPageAppearance(value: string | null): value is PageAppearance;
|
|
24
70
|
|
|
25
71
|
declare class PageStateService {
|
|
26
72
|
private readonly variantState;
|
|
27
73
|
private readonly heightState;
|
|
28
74
|
private readonly scrollState;
|
|
75
|
+
private readonly appearanceState;
|
|
29
76
|
private readonly positionState;
|
|
30
77
|
private readonly sideModeState;
|
|
31
78
|
private readonly internalSideOpenState;
|
|
@@ -34,15 +81,19 @@ declare class PageStateService {
|
|
|
34
81
|
private readonly sideIdState;
|
|
35
82
|
private readonly sideOpenRequestState;
|
|
36
83
|
private readonly sideOpenRequestVersionState;
|
|
84
|
+
/** Aktif saat apps-launcher mengambang di atas `PageHeader`; header memesan ruang kanan agar isinya tidak tertimpa. */
|
|
85
|
+
private readonly appsLauncherReserveState;
|
|
37
86
|
readonly variant: _angular_core.Signal<"stacked" | "side">;
|
|
38
87
|
readonly height: _angular_core.Signal<"auto" | "fix">;
|
|
39
88
|
readonly scroll: _angular_core.Signal<"content" | "page">;
|
|
89
|
+
readonly appearance: _angular_core.Signal<"flat" | "border-rail">;
|
|
40
90
|
readonly position: _angular_core.Signal<"left" | "right">;
|
|
41
91
|
readonly sideMode: _angular_core.Signal<"sticky" | "drawer" | "overlay">;
|
|
42
92
|
readonly sideWidth: _angular_core.Signal<string>;
|
|
43
93
|
readonly sideId: _angular_core.Signal<string | null>;
|
|
44
94
|
readonly sideOpenRequest: _angular_core.Signal<boolean | null>;
|
|
45
95
|
readonly sideOpenRequestVersion: _angular_core.Signal<number>;
|
|
96
|
+
readonly appsLauncherReserve: _angular_core.Signal<boolean>;
|
|
46
97
|
readonly sideOpen: _angular_core.Signal<boolean>;
|
|
47
98
|
readonly isSideInteractive: _angular_core.Signal<boolean>;
|
|
48
99
|
readonly isSideVisible: _angular_core.Signal<boolean>;
|
|
@@ -50,6 +101,7 @@ declare class PageStateService {
|
|
|
50
101
|
variant: PageVariant;
|
|
51
102
|
height: PageHeight;
|
|
52
103
|
scroll: PageScroll;
|
|
104
|
+
appearance: PageAppearance;
|
|
53
105
|
position: PageSidePosition;
|
|
54
106
|
sideMode: PageSideMode;
|
|
55
107
|
sideWidth: string;
|
|
@@ -60,6 +112,7 @@ declare class PageStateService {
|
|
|
60
112
|
width: string;
|
|
61
113
|
id: string;
|
|
62
114
|
}): void;
|
|
115
|
+
setAppsLauncherReserve(reserve: boolean): void;
|
|
63
116
|
setControlledSideOpen(open: boolean | null): void;
|
|
64
117
|
setSideOpen(open: boolean): void;
|
|
65
118
|
openSide(): boolean;
|
|
@@ -95,28 +148,60 @@ declare class PageSideComponent {
|
|
|
95
148
|
|
|
96
149
|
declare class PageComponent {
|
|
97
150
|
protected readonly page: PageStateService;
|
|
151
|
+
private readonly layout;
|
|
152
|
+
private readonly navigation;
|
|
153
|
+
private readonly identity;
|
|
98
154
|
protected readonly projectedSide: _angular_core.Signal<PageSideComponent | undefined>;
|
|
155
|
+
protected readonly projectedHeader: _angular_core.Signal<PageHeaderComponent | undefined>;
|
|
99
156
|
readonly variant: _angular_core.InputSignal<"stacked" | "side">;
|
|
100
157
|
readonly height: _angular_core.InputSignal<"auto" | "fix">;
|
|
101
158
|
readonly scroll: _angular_core.InputSignal<"content" | "page">;
|
|
159
|
+
/** Visual appearance shared with the layout (`flat | border-rail`); unifies header/footer borders. */
|
|
160
|
+
readonly appearance: _angular_core.InputSignal<"flat" | "border-rail">;
|
|
102
161
|
readonly position: _angular_core.InputSignal<"left" | "right">;
|
|
103
162
|
readonly sideMode: _angular_core.InputSignal<"sticky" | "drawer" | "overlay">;
|
|
104
163
|
readonly sideOpen: _angular_core.InputSignal<boolean | null>;
|
|
105
164
|
readonly sideWidth: _angular_core.InputSignal<string>;
|
|
106
165
|
readonly class: _angular_core.InputSignal<string>;
|
|
107
166
|
readonly sideOpenChange: _angular_core.OutputEmitterRef<boolean>;
|
|
167
|
+
/** Saat layout `empty`, munculkan tombol apps (flyout main navigation) di pojok kanan-atas. Set `false` untuk menonaktifkan. */
|
|
168
|
+
readonly appsLauncher: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
169
|
+
/** Id navigasi yang disurface oleh apps-launcher (default `main`). */
|
|
170
|
+
readonly appsNavId: _angular_core.InputSignal<string>;
|
|
171
|
+
/** Ikon Material untuk tombol apps-launcher. */
|
|
172
|
+
readonly appsIcon: _angular_core.InputSignal<string>;
|
|
173
|
+
/** Label/aria-label tombol apps-launcher (tombol icon-only). */
|
|
174
|
+
readonly appsLabel: _angular_core.InputSignal<string>;
|
|
175
|
+
/** Id unik untuk instance `<Navigation>` apps-launcher; tak boleh memakai id `main` (akan bentrok `claimId`). */
|
|
176
|
+
protected readonly launcherNavId: string;
|
|
108
177
|
protected readonly resolvedPosition: _angular_core.Signal<"left" | "right">;
|
|
109
178
|
protected readonly resolvedSideMode: _angular_core.Signal<"sticky" | "drawer" | "overlay">;
|
|
110
179
|
protected readonly isLeftSide: _angular_core.Signal<boolean>;
|
|
111
180
|
protected readonly isRightSide: _angular_core.Signal<boolean>;
|
|
112
181
|
protected readonly showsOverlayBackdrop: _angular_core.Signal<boolean>;
|
|
182
|
+
/** Signal data untuk id yang dipilih; di-recompute hanya saat `appsNavId` berubah. */
|
|
183
|
+
private readonly appsNavSource;
|
|
184
|
+
protected readonly appsNavData: _angular_core.Signal<readonly _ojiepermana_angular_navigation_service.NavigationItem[]>;
|
|
185
|
+
/** Apps-launcher hanya muncul di layout `empty`, saat diaktifkan, dan saat nav target punya data. */
|
|
186
|
+
protected readonly showsAppsLauncher: _angular_core.Signal<boolean>;
|
|
187
|
+
/**
|
|
188
|
+
* Host `<Navigation>` launcher di-absolute ke pojok kanan-atas (hanya membungkus tombol trigger;
|
|
189
|
+
* panel flyout tetap membentang selebar `Page` lewat pengukuran container). Saat ada `PageHeader`,
|
|
190
|
+
* tombol menyatu di dalam pita header (offset rapat); tanpa header, mengambang di atas konten.
|
|
191
|
+
*/
|
|
192
|
+
protected readonly appsLauncherHostClass: _angular_core.Signal<string>;
|
|
193
|
+
/** Appearance flyout mengikuti layout (seperti shell flyout); fallback ke appearance `Page`. */
|
|
194
|
+
protected readonly appsLauncherAppearance: _angular_core.Signal<"flat" | "border-rail">;
|
|
195
|
+
/** Brand/user untuk header & footer flyout — sama seperti shell flyout; `null` saat tak ada shell. */
|
|
196
|
+
protected readonly appsBrand: _angular_core.Signal<_ojiepermana_angular_theme_layout_wrapper.BrandIdentity | null>;
|
|
197
|
+
protected readonly appsUser: _angular_core.Signal<_ojiepermana_angular_theme_layout_wrapper.UserIdentity | null>;
|
|
113
198
|
protected readonly hostClasses: _angular_core.Signal<string>;
|
|
114
199
|
protected readonly shellClasses: _angular_core.Signal<string>;
|
|
115
200
|
protected readonly bodyClasses: _angular_core.Signal<string>;
|
|
116
201
|
constructor();
|
|
117
202
|
protected handleBackdropClick(): void;
|
|
118
203
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageComponent, never>;
|
|
119
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageComponent, "Page", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "scroll": { "alias": "scroll"; "required": false; "isSignal": true; }; "position": { "alias": "position"; "required": false; "isSignal": true; }; "sideMode": { "alias": "sideMode"; "required": false; "isSignal": true; }; "sideOpen": { "alias": "sideOpen"; "required": false; "isSignal": true; }; "sideWidth": { "alias": "sideWidth"; "required": false; "isSignal": true; }; "class": { "alias": "class"; "required": false; "isSignal": true; }; }, { "sideOpenChange": "sideOpenChange"; }, ["projectedSide"], ["PageHeader", "PageSideToggle", "PageSide", "PageContent, PageDashboard", "PageFooter"], true, never>;
|
|
204
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageComponent, "Page", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "scroll": { "alias": "scroll"; "required": false; "isSignal": true; }; "appearance": { "alias": "appearance"; "required": false; "isSignal": true; }; "position": { "alias": "position"; "required": false; "isSignal": true; }; "sideMode": { "alias": "sideMode"; "required": false; "isSignal": true; }; "sideOpen": { "alias": "sideOpen"; "required": false; "isSignal": true; }; "sideWidth": { "alias": "sideWidth"; "required": false; "isSignal": true; }; "class": { "alias": "class"; "required": false; "isSignal": true; }; "appsLauncher": { "alias": "appsLauncher"; "required": false; "isSignal": true; }; "appsNavId": { "alias": "appsNavId"; "required": false; "isSignal": true; }; "appsIcon": { "alias": "appsIcon"; "required": false; "isSignal": true; }; "appsLabel": { "alias": "appsLabel"; "required": false; "isSignal": true; }; }, { "sideOpenChange": "sideOpenChange"; }, ["projectedSide", "projectedHeader"], ["PageHeader", "PageSideToggle", "PageSide", "PageContent, PageDashboard", "PageFooter"], true, never>;
|
|
120
205
|
}
|
|
121
206
|
|
|
122
207
|
declare class PageSideToggleComponent {
|
|
@@ -131,38 +216,5 @@ declare class PageSideToggleComponent {
|
|
|
131
216
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageSideToggleComponent, "PageSideToggle", never, { "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "class": { "alias": "class"; "required": false; "isSignal": true; }; }, { "toggled": "toggled"; }, never, ["*"], true, never>;
|
|
132
217
|
}
|
|
133
218
|
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
readonly class: _angular_core.InputSignal<string>;
|
|
137
|
-
protected readonly resolvedHeight: _angular_core.Signal<"auto" | "fix">;
|
|
138
|
-
protected readonly classes: _angular_core.Signal<string>;
|
|
139
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageHeaderComponent, never>;
|
|
140
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageHeaderComponent, "PageHeader", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
141
|
-
}
|
|
142
|
-
declare class PageContentComponent {
|
|
143
|
-
private readonly page;
|
|
144
|
-
readonly class: _angular_core.InputSignal<string>;
|
|
145
|
-
protected readonly resolvedScroll: _angular_core.Signal<"content" | "page">;
|
|
146
|
-
protected readonly classes: _angular_core.Signal<string>;
|
|
147
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageContentComponent, never>;
|
|
148
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageContentComponent, "PageContent", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
149
|
-
}
|
|
150
|
-
declare class PageDashboardComponent {
|
|
151
|
-
private readonly page;
|
|
152
|
-
readonly class: _angular_core.InputSignal<string>;
|
|
153
|
-
protected readonly resolvedScroll: _angular_core.Signal<"content" | "page">;
|
|
154
|
-
protected readonly classes: _angular_core.Signal<string>;
|
|
155
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageDashboardComponent, never>;
|
|
156
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageDashboardComponent, "PageDashboard", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
157
|
-
}
|
|
158
|
-
declare class PageFooterComponent {
|
|
159
|
-
private readonly page;
|
|
160
|
-
readonly class: _angular_core.InputSignal<string>;
|
|
161
|
-
protected readonly resolvedHeight: _angular_core.Signal<"auto" | "fix">;
|
|
162
|
-
protected readonly classes: _angular_core.Signal<string>;
|
|
163
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PageFooterComponent, never>;
|
|
164
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PageFooterComponent, "PageFooter", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
export { PAGE_DEFAULT_HEIGHT, PAGE_DEFAULT_SCROLL, PAGE_DEFAULT_SIDE_MODE, PAGE_DEFAULT_SIDE_POSITION, PAGE_DEFAULT_SIDE_WIDTH, PAGE_DEFAULT_VARIANT, PAGE_HEIGHT_VALUES, PAGE_SCROLL_VALUES, PAGE_SIDE_MODES, PAGE_SIDE_POSITIONS, PAGE_VARIANTS, PageComponent, PageContentComponent, PageDashboardComponent, PageFooterComponent, PageHeaderComponent, PageSideComponent, PageSideToggleComponent, isUiPageHeight, isUiPageScroll, isUiPageSideMode, isUiPageSidePosition, isUiPageVariant };
|
|
168
|
-
export type { PageHeight, PageScroll, PageSideMode, PageSidePosition, PageVariant };
|
|
219
|
+
export { PAGE_APPEARANCES, PAGE_DEFAULT_APPEARANCE, PAGE_DEFAULT_HEIGHT, PAGE_DEFAULT_SCROLL, PAGE_DEFAULT_SIDE_MODE, PAGE_DEFAULT_SIDE_POSITION, PAGE_DEFAULT_SIDE_WIDTH, PAGE_DEFAULT_VARIANT, PAGE_HEIGHT_VALUES, PAGE_SCROLL_VALUES, PAGE_SIDE_MODES, PAGE_SIDE_POSITIONS, PAGE_VARIANTS, PageComponent, PageContentComponent, PageDashboardComponent, PageFooterComponent, PageHeaderComponent, PageSideComponent, PageSideToggleComponent, isUiPageAppearance, isUiPageHeight, isUiPageScroll, isUiPageSideMode, isUiPageSidePosition, isUiPageVariant };
|
|
220
|
+
export type { PageAppearance, PageHeight, PageScroll, PageSideMode, PageSidePosition, PageVariant };
|
|
@@ -1,21 +1,59 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
2
|
import { InjectionToken, EnvironmentProviders } from '@angular/core';
|
|
3
3
|
|
|
4
4
|
declare const THEME_MODES: readonly ["light", "dark", "system"];
|
|
5
5
|
declare const RESOLVED_THEME_MODES: readonly ["light", "dark"];
|
|
6
|
-
|
|
6
|
+
/**
|
|
7
|
+
* FluxUI-style accent palettes (axis `theme-color`). `base` = core theme (no
|
|
8
|
+
* override); `brand` = the consumer's `--brand` color. Others re-tint the full
|
|
9
|
+
* palette. Order mirrors the FluxUI accent picker (base…rose) + `brand`.
|
|
10
|
+
*/
|
|
11
|
+
declare const THEME_COLORS: readonly ["base", "red", "orange", "amber", "yellow", "lime", "green", "emerald", "teal", "cyan", "sky", "blue", "indigo", "violet", "purple", "fuchsia", "pink", "rose", "brand"];
|
|
12
|
+
/**
|
|
13
|
+
* Neutral (gray) families (axis `theme-neutral`). `base` = core theme neutrals.
|
|
14
|
+
* Overrides only the gray family, composing with any accent.
|
|
15
|
+
*/
|
|
16
|
+
declare const THEME_NEUTRALS: readonly ["base", "slate", "gray", "zinc", "neutral", "stone", "mauve", "olive", "mist", "taupe"];
|
|
17
|
+
/**
|
|
18
|
+
* Corner radius presets (axis `theme-radius`). Each drives the single
|
|
19
|
+
* `--radius-base` knob; the whole `--radius-*` scale + `rounded-*` utilities
|
|
20
|
+
* follow. `md` = the 0.625rem default; `full` is the pill extreme.
|
|
21
|
+
*/
|
|
22
|
+
declare const THEME_RADII: readonly ["none", "sm", "md", "lg", "xl", "full"];
|
|
23
|
+
/**
|
|
24
|
+
* Spacing density presets (axis `theme-space`). Each drives the single
|
|
25
|
+
* `--spacing-base` knob; every `p-*`/`m-*`/`gap-*`/`w-*`/`h-*` utility follows.
|
|
26
|
+
* `normal` = the 0.25rem default (no-op baseline).
|
|
27
|
+
*/
|
|
28
|
+
declare const THEME_SPACES: readonly ["compact", "normal", "relaxed", "spacious"];
|
|
7
29
|
type ThemeMode = (typeof THEME_MODES)[number];
|
|
8
30
|
type ResolvedThemeMode = (typeof RESOLVED_THEME_MODES)[number];
|
|
9
|
-
type
|
|
31
|
+
type ThemeColor = (typeof THEME_COLORS)[number];
|
|
32
|
+
type ThemeNeutral = (typeof THEME_NEUTRALS)[number];
|
|
33
|
+
type ThemeRadius = (typeof THEME_RADII)[number];
|
|
34
|
+
type ThemeSpace = (typeof THEME_SPACES)[number];
|
|
10
35
|
declare const DEFAULT_THEME_MODE: ThemeMode;
|
|
11
|
-
declare const
|
|
36
|
+
declare const DEFAULT_THEME_COLOR: ThemeColor;
|
|
37
|
+
declare const DEFAULT_THEME_NEUTRAL: ThemeNeutral;
|
|
38
|
+
declare const DEFAULT_THEME_RADIUS: ThemeRadius;
|
|
39
|
+
declare const DEFAULT_THEME_SPACE: ThemeSpace;
|
|
12
40
|
declare const THEME_MODE_STORAGE_KEY = "theme-mode";
|
|
13
|
-
declare const
|
|
41
|
+
declare const THEME_COLOR_STORAGE_KEY = "theme-color";
|
|
42
|
+
declare const THEME_NEUTRAL_STORAGE_KEY = "theme-neutral";
|
|
43
|
+
declare const THEME_BRAND_STORAGE_KEY = "theme-brand";
|
|
44
|
+
declare const THEME_RADIUS_STORAGE_KEY = "theme-radius";
|
|
45
|
+
declare const THEME_SPACE_STORAGE_KEY = "theme-space";
|
|
14
46
|
declare function isThemeMode(value: string | null | undefined): value is ThemeMode;
|
|
15
47
|
declare function isResolvedThemeMode(value: string | null | undefined): value is ResolvedThemeMode;
|
|
16
|
-
declare function
|
|
48
|
+
declare function isThemeColor(value: string | null | undefined): value is ThemeColor;
|
|
49
|
+
declare function isThemeNeutral(value: string | null | undefined): value is ThemeNeutral;
|
|
50
|
+
declare function isThemeRadius(value: string | null | undefined): value is ThemeRadius;
|
|
51
|
+
declare function isThemeSpace(value: string | null | undefined): value is ThemeSpace;
|
|
17
52
|
declare function normalizeThemeMode(value: string | null | undefined): ThemeMode;
|
|
18
|
-
declare function
|
|
53
|
+
declare function normalizeThemeColor(value: string | null | undefined): ThemeColor;
|
|
54
|
+
declare function normalizeThemeNeutral(value: string | null | undefined): ThemeNeutral;
|
|
55
|
+
declare function normalizeThemeRadius(value: string | null | undefined): ThemeRadius;
|
|
56
|
+
declare function normalizeThemeSpace(value: string | null | undefined): ThemeSpace;
|
|
19
57
|
|
|
20
58
|
interface ThemeIconOptions {
|
|
21
59
|
/**
|
|
@@ -28,19 +66,30 @@ interface ThemeIconOptions {
|
|
|
28
66
|
*/
|
|
29
67
|
readonly materialSymbols?: boolean;
|
|
30
68
|
}
|
|
69
|
+
/** Consumer brand color. HSL triplets `H S% L%` consumed by `hsl(var(--brand))`. */
|
|
70
|
+
interface ThemeBrandOptions {
|
|
71
|
+
/** Brand color, e.g. `'221 83% 53%'`. */
|
|
72
|
+
readonly color: string;
|
|
73
|
+
/** Foreground on solid brand fills. Defaults to white. */
|
|
74
|
+
readonly foreground?: string;
|
|
75
|
+
}
|
|
31
76
|
interface ThemeOptions {
|
|
32
77
|
readonly mode?: ThemeMode;
|
|
33
|
-
|
|
34
|
-
readonly
|
|
78
|
+
/** Initial accent palette (`theme-color`). Persisted choice wins over this. */
|
|
79
|
+
readonly color?: ThemeColor;
|
|
80
|
+
/** Initial neutral family (`theme-neutral`). Persisted choice wins over this. */
|
|
81
|
+
readonly neutral?: ThemeNeutral;
|
|
82
|
+
/** Initial corner radius preset (`theme-radius`). Persisted choice wins over this. */
|
|
83
|
+
readonly radius?: ThemeRadius;
|
|
84
|
+
/** Initial spacing density preset (`theme-space`). Persisted choice wins over this. */
|
|
85
|
+
readonly space?: ThemeSpace;
|
|
35
86
|
/**
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
* loading happens — the app is expected to bundle season CSS itself.
|
|
40
|
-
*
|
|
41
|
-
* Contoh: `(season) => '/themes/seasonal/' + season + '/package.css'`
|
|
87
|
+
* Consumer brand color → `--brand` / `bg-brand`, and the `brand` accent preset.
|
|
88
|
+
* Pass an HSL triplet string, or `{ color, foreground }`. Persisted/runtime
|
|
89
|
+
* changes (ThemeBrandService.setBrand) win over this default.
|
|
42
90
|
*/
|
|
43
|
-
readonly
|
|
91
|
+
readonly brand?: string | ThemeBrandOptions;
|
|
92
|
+
readonly icons?: ThemeIconOptions;
|
|
44
93
|
}
|
|
45
94
|
declare const THEME_OPTIONS: InjectionToken<Readonly<ThemeOptions>>;
|
|
46
95
|
|
|
@@ -50,9 +99,9 @@ declare class ThemeModeService {
|
|
|
50
99
|
private readonly options;
|
|
51
100
|
private readonly modeState;
|
|
52
101
|
private readonly systemPrefersDark;
|
|
53
|
-
readonly mode:
|
|
54
|
-
readonly resolvedMode:
|
|
55
|
-
readonly isDark:
|
|
102
|
+
readonly mode: i0.Signal<"light" | "dark" | "system">;
|
|
103
|
+
readonly resolvedMode: i0.Signal<"light" | "dark">;
|
|
104
|
+
readonly isDark: i0.Signal<boolean>;
|
|
56
105
|
constructor();
|
|
57
106
|
setMode(mode: ThemeMode): void;
|
|
58
107
|
toggle(): void;
|
|
@@ -65,33 +114,116 @@ declare class ThemeModeService {
|
|
|
65
114
|
private storage;
|
|
66
115
|
private readStorage;
|
|
67
116
|
private writeStorage;
|
|
68
|
-
static ɵfac:
|
|
69
|
-
static ɵprov:
|
|
117
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ThemeModeService, never>;
|
|
118
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ThemeModeService>;
|
|
70
119
|
}
|
|
71
120
|
|
|
72
121
|
declare function provideUiTheme(options?: ThemeOptions): EnvironmentProviders;
|
|
73
122
|
|
|
74
|
-
|
|
123
|
+
/**
|
|
124
|
+
* Drives the two FluxUI-style color axes:
|
|
125
|
+
* - accent → `<html theme-color>` (full tinted palette per color)
|
|
126
|
+
* - neutral → `<html theme-neutral>` (gray family only)
|
|
127
|
+
*
|
|
128
|
+
* Both persist to localStorage and seed from `provideUiTheme({ color, neutral })`
|
|
129
|
+
* (a persisted choice wins over the configured default). `base` on either axis
|
|
130
|
+
* means "no override" — the core base theme applies.
|
|
131
|
+
*/
|
|
132
|
+
declare class ThemeColorService {
|
|
75
133
|
private readonly documentRef;
|
|
76
134
|
private readonly options;
|
|
77
|
-
private readonly
|
|
78
|
-
readonly
|
|
135
|
+
private readonly colorState;
|
|
136
|
+
private readonly neutralState;
|
|
137
|
+
readonly color: i0.Signal<"base" | "red" | "orange" | "amber" | "yellow" | "lime" | "green" | "emerald" | "teal" | "cyan" | "sky" | "blue" | "indigo" | "violet" | "purple" | "fuchsia" | "pink" | "rose" | "brand">;
|
|
138
|
+
readonly neutral: i0.Signal<"base" | "slate" | "gray" | "zinc" | "neutral" | "stone" | "mauve" | "olive" | "mist" | "taupe">;
|
|
79
139
|
constructor();
|
|
80
|
-
|
|
140
|
+
setColor(color: ThemeColor): void;
|
|
141
|
+
setNeutral(neutral: ThemeNeutral): void;
|
|
81
142
|
private ensureDefaults;
|
|
82
|
-
private
|
|
83
|
-
private applySeasonAttribute;
|
|
84
|
-
/**
|
|
85
|
-
* Lazily loads the active season's stylesheet via `<link>` when the app
|
|
86
|
-
* configured `seasonalCssUrl`, so only base CSS ships in the main bundle.
|
|
87
|
-
*/
|
|
88
|
-
private ensureSeasonStylesheet;
|
|
143
|
+
private applyAttribute;
|
|
89
144
|
private storage;
|
|
90
145
|
private readStorage;
|
|
91
|
-
private
|
|
92
|
-
static ɵfac:
|
|
93
|
-
static ɵprov:
|
|
146
|
+
private persist;
|
|
147
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ThemeColorService, never>;
|
|
148
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ThemeColorService>;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/** Resolved brand color. Both fields are HSL triplets `H S% L%`. */
|
|
152
|
+
interface ThemeBrand {
|
|
153
|
+
readonly color: string;
|
|
154
|
+
readonly foreground: string;
|
|
155
|
+
}
|
|
156
|
+
/**
|
|
157
|
+
* Consumer-configurable brand color. Writes `--brand` / `--brand-foreground` as
|
|
158
|
+
* inline custom properties on `<html>` so `bg-brand` / `text-brand-foreground`
|
|
159
|
+
* and the `theme-color='brand'` accent preset resolve to it.
|
|
160
|
+
*
|
|
161
|
+
* Default comes from `provideUiTheme({ brand })`; `setBrand()` overrides at
|
|
162
|
+
* runtime and persists. When unset, `--brand` falls back to `var(--primary)`.
|
|
163
|
+
*/
|
|
164
|
+
declare class ThemeBrandService {
|
|
165
|
+
private readonly documentRef;
|
|
166
|
+
private readonly options;
|
|
167
|
+
private readonly brandState;
|
|
168
|
+
readonly brand: i0.Signal<ThemeBrand | null>;
|
|
169
|
+
constructor();
|
|
170
|
+
/** Set the brand color. `color`/`foreground` are HSL triplets (e.g. `'221 83% 53%'`). */
|
|
171
|
+
setBrand(color: string, foreground?: string): void;
|
|
172
|
+
/** Clear the consumer brand → `--brand` falls back to `var(--primary)`. */
|
|
173
|
+
clearBrand(): void;
|
|
174
|
+
private ensureDefaults;
|
|
175
|
+
private normalizeOption;
|
|
176
|
+
private applyBrand;
|
|
177
|
+
private storage;
|
|
178
|
+
private readStoredBrand;
|
|
179
|
+
private persist;
|
|
180
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ThemeBrandService, never>;
|
|
181
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ThemeBrandService>;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
/**
|
|
185
|
+
* Corner radius axis. Writes `<html theme-radius>`; each preset CSS sets the
|
|
186
|
+
* single `--radius-base` knob so the whole `--radius-*` scale + `rounded-*`
|
|
187
|
+
* utilities rescale. Persists to localStorage and seeds from
|
|
188
|
+
* `provideUiTheme({ radius })` (a persisted choice wins over the default).
|
|
189
|
+
*/
|
|
190
|
+
declare class ThemeRadiusService {
|
|
191
|
+
private readonly documentRef;
|
|
192
|
+
private readonly options;
|
|
193
|
+
private readonly radiusState;
|
|
194
|
+
readonly radius: i0.Signal<"none" | "sm" | "md" | "lg" | "xl" | "full">;
|
|
195
|
+
readonly radiusPx: i0.Signal<0 | 6 | 10 | 14 | 20 | 9999>;
|
|
196
|
+
constructor();
|
|
197
|
+
setRadius(radius: ThemeRadius): void;
|
|
198
|
+
private ensureDefaults;
|
|
199
|
+
private storage;
|
|
200
|
+
private readStorage;
|
|
201
|
+
private persist;
|
|
202
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ThemeRadiusService, never>;
|
|
203
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ThemeRadiusService>;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
/**
|
|
207
|
+
* Spacing density axis. Writes `<html theme-space>`; each preset CSS sets the
|
|
208
|
+
* single `--spacing-base` knob, which Tailwind's `--spacing` derives from, so
|
|
209
|
+
* every `p-*`/`m-*`/`gap-*`/`w-*`/`h-*` utility rescales. Persists to
|
|
210
|
+
* localStorage and seeds from `provideUiTheme({ space })` (a persisted choice
|
|
211
|
+
* wins over the default).
|
|
212
|
+
*/
|
|
213
|
+
declare class ThemeSpaceService {
|
|
214
|
+
private readonly documentRef;
|
|
215
|
+
private readonly options;
|
|
216
|
+
private readonly spaceState;
|
|
217
|
+
readonly space: i0.Signal<"compact" | "normal" | "relaxed" | "spacious">;
|
|
218
|
+
constructor();
|
|
219
|
+
setSpace(space: ThemeSpace): void;
|
|
220
|
+
private ensureDefaults;
|
|
221
|
+
private storage;
|
|
222
|
+
private readStorage;
|
|
223
|
+
private persist;
|
|
224
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ThemeSpaceService, never>;
|
|
225
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ThemeSpaceService>;
|
|
94
226
|
}
|
|
95
227
|
|
|
96
|
-
export { DEFAULT_THEME_MODE,
|
|
97
|
-
export type { ResolvedThemeMode, ThemeIconOptions, ThemeMode, ThemeOptions,
|
|
228
|
+
export { DEFAULT_THEME_COLOR, DEFAULT_THEME_MODE, DEFAULT_THEME_NEUTRAL, DEFAULT_THEME_RADIUS, DEFAULT_THEME_SPACE, RESOLVED_THEME_MODES, THEME_BRAND_STORAGE_KEY, THEME_COLORS, THEME_COLOR_STORAGE_KEY, THEME_MODES, THEME_MODE_STORAGE_KEY, THEME_NEUTRALS, THEME_NEUTRAL_STORAGE_KEY, THEME_OPTIONS, THEME_RADII, THEME_RADIUS_STORAGE_KEY, THEME_SPACES, THEME_SPACE_STORAGE_KEY, ThemeBrandService, ThemeColorService, ThemeModeService, ThemeRadiusService, ThemeSpaceService, isResolvedThemeMode, isThemeColor, isThemeMode, isThemeNeutral, isThemeRadius, isThemeSpace, normalizeThemeColor, normalizeThemeMode, normalizeThemeNeutral, normalizeThemeRadius, normalizeThemeSpace, provideUiTheme };
|
|
229
|
+
export type { ResolvedThemeMode, ThemeBrand, ThemeBrandOptions, ThemeColor, ThemeIconOptions, ThemeMode, ThemeNeutral, ThemeOptions, ThemeRadius, ThemeSpace };
|