@ojiepermana/angular 0.0.2

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 (51) hide show
  1. package/README.md +237 -0
  2. package/fesm2022/ojiepermana-angular-internal.mjs +58 -0
  3. package/fesm2022/ojiepermana-angular-internal.mjs.map +1 -0
  4. package/fesm2022/ojiepermana-angular-layout.mjs +471 -0
  5. package/fesm2022/ojiepermana-angular-layout.mjs.map +1 -0
  6. package/fesm2022/ojiepermana-angular-shell.mjs +14 -0
  7. package/fesm2022/ojiepermana-angular-shell.mjs.map +1 -0
  8. package/fesm2022/ojiepermana-angular-theme-component.mjs +249 -0
  9. package/fesm2022/ojiepermana-angular-theme-component.mjs.map +1 -0
  10. package/fesm2022/ojiepermana-angular-theme-directive.mjs +29 -0
  11. package/fesm2022/ojiepermana-angular-theme-directive.mjs.map +1 -0
  12. package/fesm2022/ojiepermana-angular-theme-service.mjs +243 -0
  13. package/fesm2022/ojiepermana-angular-theme-service.mjs.map +1 -0
  14. package/fesm2022/ojiepermana-angular-theme.mjs +6 -0
  15. package/fesm2022/ojiepermana-angular-theme.mjs.map +1 -0
  16. package/fesm2022/ojiepermana-angular.mjs +6 -0
  17. package/fesm2022/ojiepermana-angular.mjs.map +1 -0
  18. package/layout/README.md +143 -0
  19. package/layout/styles/index.css +157 -0
  20. package/package.json +59 -0
  21. package/shell/README.md +37 -0
  22. package/styles/index.css +2 -0
  23. package/styles/resets.css +22 -0
  24. package/theme/README.md +382 -0
  25. package/theme/styles/adapters/material-ui/index.css +210 -0
  26. package/theme/styles/index.css +8 -0
  27. package/theme/styles/layout/index.css +1 -0
  28. package/theme/styles/modes/dark.css +84 -0
  29. package/theme/styles/presets/colors/blue.css +10 -0
  30. package/theme/styles/presets/colors/brand.css +11 -0
  31. package/theme/styles/presets/colors/cyan.css +10 -0
  32. package/theme/styles/presets/colors/green.css +10 -0
  33. package/theme/styles/presets/colors/index.css +7 -0
  34. package/theme/styles/presets/colors/orange.css +10 -0
  35. package/theme/styles/presets/colors/purple.css +10 -0
  36. package/theme/styles/presets/colors/red.css +10 -0
  37. package/theme/styles/presets/styles/flat.css +30 -0
  38. package/theme/styles/presets/styles/glass.css +34 -0
  39. package/theme/styles/presets/styles/index.css +2 -0
  40. package/theme/styles/roles/index.css +49 -0
  41. package/theme/styles/tokens/foundation.css +139 -0
  42. package/theme/styles/tokens/semantic.css +87 -0
  43. package/theme/styles/utilities/index.css +88 -0
  44. package/types/ojiepermana-angular-internal.d.ts +26 -0
  45. package/types/ojiepermana-angular-layout.d.ts +90 -0
  46. package/types/ojiepermana-angular-shell.d.ts +12 -0
  47. package/types/ojiepermana-angular-theme-component.d.ts +46 -0
  48. package/types/ojiepermana-angular-theme-directive.d.ts +10 -0
  49. package/types/ojiepermana-angular-theme-service.d.ts +68 -0
  50. package/types/ojiepermana-angular-theme.d.ts +2 -0
  51. package/types/ojiepermana-angular.d.ts +2 -0
@@ -0,0 +1,46 @@
1
+ import * as i0 from '@angular/core';
2
+ import * as _ojiepermana_angular_theme_service from '@ojiepermana/angular/theme/service';
3
+ import { ThemeService } from '@ojiepermana/angular/theme/service';
4
+
5
+ declare class StyleSwitcherComponent {
6
+ protected readonly theme: ThemeService;
7
+ protected readonly label: i0.Signal<"Glass style enabled" | "Glass style disabled">;
8
+ protected toggle(): void;
9
+ static ɵfac: i0.ɵɵFactoryDeclaration<StyleSwitcherComponent, never>;
10
+ static ɵcmp: i0.ɵɵComponentDeclaration<StyleSwitcherComponent, "style-switcher", never, {}, {}, never, never, true, never>;
11
+ }
12
+
13
+ declare class ColorPickerComponent {
14
+ protected readonly theme: ThemeService;
15
+ protected readonly colors: i0.Signal<readonly _ojiepermana_angular_theme_service.ThemeColorOption[]>;
16
+ static ɵfac: i0.ɵɵFactoryDeclaration<ColorPickerComponent, never>;
17
+ static ɵcmp: i0.ɵɵComponentDeclaration<ColorPickerComponent, "color-picker", never, {}, {}, never, never, true, never>;
18
+ }
19
+
20
+ declare class SchemeSwitcherComponent {
21
+ protected readonly theme: ThemeService;
22
+ protected readonly options: ({
23
+ value: "light";
24
+ label: string;
25
+ } | {
26
+ value: "dark";
27
+ label: string;
28
+ } | {
29
+ value: "system";
30
+ label: string;
31
+ })[];
32
+ protected readonly currentOption: i0.Signal<{
33
+ value: "light";
34
+ label: string;
35
+ } | {
36
+ value: "dark";
37
+ label: string;
38
+ } | {
39
+ value: "system";
40
+ label: string;
41
+ }>;
42
+ static ɵfac: i0.ɵɵFactoryDeclaration<SchemeSwitcherComponent, never>;
43
+ static ɵcmp: i0.ɵɵComponentDeclaration<SchemeSwitcherComponent, "scheme-switcher", never, {}, {}, never, never, true, never>;
44
+ }
45
+
46
+ export { ColorPickerComponent, SchemeSwitcherComponent, StyleSwitcherComponent };
@@ -0,0 +1,10 @@
1
+ import { ThemeService } from '@ojiepermana/angular/theme/service';
2
+ import * as i0 from '@angular/core';
3
+
4
+ declare class ThemeHostDirective {
5
+ protected readonly theme: ThemeService;
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<ThemeHostDirective, never>;
7
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ThemeHostDirective, "[ngtThemeHost]", never, {}, {}, never, never, true, never>;
8
+ }
9
+
10
+ export { ThemeHostDirective };
@@ -0,0 +1,68 @@
1
+ import * as _angular_core from '@angular/core';
2
+ import { EnvironmentProviders, InjectionToken } from '@angular/core';
3
+
4
+ declare const THEME_SCHEMES: readonly ["light", "dark", "system"];
5
+ type ThemeScheme = (typeof THEME_SCHEMES)[number];
6
+ declare const THEME_COLORS: readonly ["brand", "blue", "green", "red", "cyan", "purple", "orange"];
7
+ type ThemeColor = (typeof THEME_COLORS)[number];
8
+ declare const THEME_STYLES: readonly ["flat", "glass"];
9
+ type ThemeStyle = (typeof THEME_STYLES)[number];
10
+ interface ThemeColorOption {
11
+ readonly value: ThemeColor;
12
+ readonly label: string;
13
+ }
14
+ type ThemeColorLabels = Partial<Record<ThemeColor, string>>;
15
+ interface NgThemeConfig {
16
+ defaultScheme: ThemeScheme;
17
+ defaultColor: ThemeColor;
18
+ defaultStyle: ThemeStyle;
19
+ colors?: readonly ThemeColor[];
20
+ colorLabels?: ThemeColorLabels;
21
+ }
22
+
23
+ declare class ThemeService {
24
+ private readonly config;
25
+ private readonly document;
26
+ private readonly destroyRef;
27
+ private readonly isBrowser;
28
+ private readonly storage;
29
+ private readonly mediaQuery;
30
+ private readonly systemPrefersDark;
31
+ private readonly availableColorOptions;
32
+ readonly scheme: _angular_core.WritableSignal<"light" | "dark" | "system">;
33
+ readonly color: _angular_core.WritableSignal<"brand" | "blue" | "green" | "red" | "cyan" | "purple" | "orange">;
34
+ readonly style: _angular_core.WritableSignal<"flat" | "glass">;
35
+ readonly colorOptions: _angular_core.Signal<readonly ThemeColorOption[]>;
36
+ readonly resolvedScheme: _angular_core.Signal<"light" | "dark">;
37
+ constructor();
38
+ /**
39
+ * Updates the selected theme scheme and persists the choice for future sessions.
40
+ */
41
+ setScheme(value: ThemeScheme): void;
42
+ /**
43
+ * Updates the active theme color when it is part of the configured preset list.
44
+ */
45
+ setColor(value: ThemeColor): void;
46
+ /**
47
+ * Updates the active style preset and persists it to local storage.
48
+ */
49
+ setStyle(value: ThemeStyle): void;
50
+ /**
51
+ * Cycles the scheme through light, dark, and system while keeping the DOM contract in sync.
52
+ */
53
+ toggleScheme(): void;
54
+ /**
55
+ * Clears persisted theme state and restores the configured defaults for all theme axes.
56
+ */
57
+ reset(): void;
58
+ private applyToDOM;
59
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<ThemeService, never>;
60
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<ThemeService>;
61
+ }
62
+
63
+ declare function provideNgTheme(config?: Partial<NgThemeConfig>): EnvironmentProviders;
64
+
65
+ declare const NG_THEME_CONFIG: InjectionToken<NgThemeConfig>;
66
+
67
+ export { NG_THEME_CONFIG, ThemeService, provideNgTheme };
68
+ export type { NgThemeConfig, ThemeColor, ThemeColorLabels, ThemeColorOption, ThemeScheme, ThemeStyle };
@@ -0,0 +1,2 @@
1
+
2
+ export { };
@@ -0,0 +1,2 @@
1
+
2
+ export { };