@ojiepermana/angular 0.1.0 → 0.1.1
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 +8 -5
- package/fesm2022/ojiepermana-angular-internal.mjs +16 -0
- package/fesm2022/ojiepermana-angular-internal.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-layout.mjs +44 -41
- package/fesm2022/ojiepermana-angular-layout.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-navigation-horizontal.mjs +198 -262
- package/fesm2022/ojiepermana-angular-navigation-horizontal.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-navigation-vertical.mjs +123 -44
- package/fesm2022/ojiepermana-angular-navigation-vertical.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-navigation.mjs +326 -30
- package/fesm2022/ojiepermana-angular-navigation.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-shell.mjs +6 -1
- package/fesm2022/ojiepermana-angular-shell.mjs.map +1 -1
- package/layout/README.md +3 -3
- package/{theme/styles/layout → layout/src/component/horizontal}/horizontal.css +38 -17
- package/{theme/styles/layout → layout/src/component/vertical}/vertical.css +7 -7
- package/{theme/styles/layout/index.css → layout/src/layout.css} +0 -3
- package/navigation/README.md +91 -5
- package/navigation/horizontal/README.md +49 -0
- package/navigation/vertical/README.md +0 -0
- package/package.json +1 -1
- package/shell/README.md +5 -1
- package/styles/index.css +1 -1
- package/theme/README.md +2 -2
- package/types/ojiepermana-angular-internal.d.ts +1 -0
- package/types/ojiepermana-angular-layout.d.ts +1 -1
- package/types/ojiepermana-angular-navigation-horizontal.d.ts +26 -22
- package/types/ojiepermana-angular-navigation-vertical.d.ts +24 -22
- package/types/ojiepermana-angular-navigation.d.ts +55 -9
- package/types/ojiepermana-angular-shell.d.ts +2 -0
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
:host {
|
|
2
2
|
display: block;
|
|
3
3
|
block-size: 100dvh;
|
|
4
4
|
min-block-size: 100dvh;
|
|
5
5
|
overflow: hidden;
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
:host > layout {
|
|
9
9
|
display: block;
|
|
10
10
|
block-size: 100dvh;
|
|
11
11
|
min-block-size: 100dvh;
|
|
@@ -16,7 +16,7 @@ horizontal[data-layout-mode='horizontal'] > layout {
|
|
|
16
16
|
transition: var(--ngt-chrome-transition);
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
:host > layout > :is(content, shell-content) {
|
|
20
20
|
display: flex;
|
|
21
21
|
flex-direction: column;
|
|
22
22
|
inline-size: min(100%, var(--layout-shell-max-width));
|
|
@@ -34,8 +34,9 @@ horizontal[data-layout-mode='horizontal'] > layout > :is(content, shell-content)
|
|
|
34
34
|
transition: var(--ngt-shell-transition);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
-
|
|
37
|
+
:host > layout > :is(content, shell-content) > header {
|
|
38
38
|
display: var(--layout-header-display);
|
|
39
|
+
grid-template-areas: 'brand navigation action';
|
|
39
40
|
grid-template-columns: auto minmax(0, 1fr) auto;
|
|
40
41
|
align-items: center;
|
|
41
42
|
gap: 1rem;
|
|
@@ -47,32 +48,46 @@ horizontal[data-layout-mode='horizontal'] > layout > :is(content, shell-content)
|
|
|
47
48
|
transition: var(--ngt-chrome-transition);
|
|
48
49
|
}
|
|
49
50
|
|
|
50
|
-
|
|
51
|
-
|
|
51
|
+
:host > layout > :is(content, shell-content) > header > brand,
|
|
52
|
+
:host > layout > :is(content, shell-content) > header > action {
|
|
52
53
|
display: flex;
|
|
53
54
|
min-inline-size: 0;
|
|
54
55
|
align-items: center;
|
|
55
56
|
}
|
|
56
57
|
|
|
57
|
-
|
|
58
|
+
:host > layout > :is(content, shell-content) > header > brand {
|
|
59
|
+
grid-area: brand;
|
|
58
60
|
justify-content: flex-start;
|
|
61
|
+
justify-self: start;
|
|
59
62
|
}
|
|
60
63
|
|
|
61
|
-
|
|
64
|
+
:host > layout > :is(content, shell-content) > header > navigation {
|
|
65
|
+
grid-area: navigation;
|
|
62
66
|
display: flex;
|
|
67
|
+
inline-size: 100%;
|
|
63
68
|
min-inline-size: 0;
|
|
64
69
|
align-items: center;
|
|
70
|
+
justify-self: stretch;
|
|
65
71
|
justify-content: center;
|
|
66
72
|
gap: 0.75rem;
|
|
67
73
|
flex-wrap: wrap;
|
|
68
74
|
}
|
|
69
75
|
|
|
70
|
-
|
|
76
|
+
:host > layout > :is(content, shell-content) > header > navigation > .layout-horizontal-navigation-slot {
|
|
77
|
+
flex: 0 1 auto;
|
|
78
|
+
display: block;
|
|
79
|
+
min-inline-size: 0;
|
|
80
|
+
max-inline-size: 100%;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
:host > layout > :is(content, shell-content) > header > action {
|
|
84
|
+
grid-area: action;
|
|
71
85
|
justify-content: flex-end;
|
|
86
|
+
justify-self: end;
|
|
72
87
|
gap: 0.5rem;
|
|
73
88
|
}
|
|
74
89
|
|
|
75
|
-
|
|
90
|
+
:host > layout > :is(content, shell-content) > main {
|
|
76
91
|
flex: 1 1 auto;
|
|
77
92
|
block-size: 100%;
|
|
78
93
|
min-inline-size: 0;
|
|
@@ -87,23 +102,29 @@ horizontal[data-layout-mode='horizontal'] > layout > :is(content, shell-content)
|
|
|
87
102
|
}
|
|
88
103
|
|
|
89
104
|
@media (max-width: 60rem) {
|
|
90
|
-
|
|
105
|
+
:host > layout > :is(content, shell-content) > header {
|
|
106
|
+
grid-template-areas:
|
|
107
|
+
'brand action'
|
|
108
|
+
'navigation navigation';
|
|
91
109
|
grid-template-columns: minmax(0, 1fr) auto;
|
|
92
110
|
align-items: flex-start;
|
|
93
111
|
}
|
|
94
112
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
justify-content: flex-start;
|
|
113
|
+
:host > layout > :is(content, shell-content) > header > navigation {
|
|
114
|
+
justify-content: center;
|
|
98
115
|
}
|
|
99
116
|
}
|
|
100
117
|
|
|
101
118
|
@media (max-width: 40rem) {
|
|
102
|
-
|
|
119
|
+
:host > layout > :is(content, shell-content) > header {
|
|
120
|
+
grid-template-areas:
|
|
121
|
+
'brand'
|
|
122
|
+
'navigation'
|
|
123
|
+
'action';
|
|
103
124
|
grid-template-columns: 1fr;
|
|
104
125
|
}
|
|
105
126
|
|
|
106
|
-
|
|
107
|
-
justify-content: flex-
|
|
127
|
+
:host > layout > :is(content, shell-content) > header > action {
|
|
128
|
+
justify-content: flex-end;
|
|
108
129
|
}
|
|
109
130
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
:host {
|
|
2
2
|
display: block;
|
|
3
3
|
block-size: 100dvh;
|
|
4
4
|
min-block-size: 100dvh;
|
|
5
5
|
overflow: hidden;
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
:host > layout {
|
|
9
9
|
display: block;
|
|
10
10
|
block-size: 100dvh;
|
|
11
11
|
min-block-size: 100dvh;
|
|
@@ -16,7 +16,7 @@ vertical[data-layout-mode='vertical'] > layout {
|
|
|
16
16
|
transition: var(--ngt-chrome-transition);
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
:host > layout > :is(content, shell-content) {
|
|
20
20
|
display: flex;
|
|
21
21
|
flex-direction: column;
|
|
22
22
|
inline-size: min(100%, var(--layout-shell-max-width));
|
|
@@ -34,7 +34,7 @@ vertical[data-layout-mode='vertical'] > layout > :is(content, shell-content) {
|
|
|
34
34
|
transition: var(--ngt-shell-transition);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
-
|
|
37
|
+
:host > layout > :is(content, shell-content) > aside {
|
|
38
38
|
display: var(--layout-sidebar-display);
|
|
39
39
|
flex-direction: column;
|
|
40
40
|
inline-size: 100%;
|
|
@@ -46,7 +46,7 @@ vertical[data-layout-mode='vertical'] > layout > :is(content, shell-content) > a
|
|
|
46
46
|
transition: var(--ngt-chrome-transition);
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
|
|
49
|
+
:host > layout > :is(content, shell-content) > main {
|
|
50
50
|
flex: 1 1 auto;
|
|
51
51
|
block-size: 100%;
|
|
52
52
|
min-inline-size: 0;
|
|
@@ -61,11 +61,11 @@ vertical[data-layout-mode='vertical'] > layout > :is(content, shell-content) > m
|
|
|
61
61
|
}
|
|
62
62
|
|
|
63
63
|
@media (min-width: 48rem) {
|
|
64
|
-
|
|
64
|
+
:host > layout > :is(content, shell-content) {
|
|
65
65
|
flex-direction: row;
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
|
|
68
|
+
:host > layout > :is(content, shell-content) > aside {
|
|
69
69
|
flex: 0 0 var(--layout-sidebar-width);
|
|
70
70
|
inline-size: var(--layout-sidebar-width);
|
|
71
71
|
min-inline-size: var(--layout-sidebar-width);
|
package/navigation/README.md
CHANGED
|
@@ -4,9 +4,9 @@ Navigation for `@ojiepermana/angular` is split into three secondary entry points
|
|
|
4
4
|
|
|
5
5
|
## Entry Points
|
|
6
6
|
|
|
7
|
-
- `@ojiepermana/angular/navigation` exposes the navigation item model, utility helpers, and `
|
|
7
|
+
- `@ojiepermana/angular/navigation` exposes the navigation item model, utility helpers, `NavigationService`, and `NavigationPreferencesService`.
|
|
8
8
|
- `@ojiepermana/angular/navigation/vertical` exposes the vertical navigation container variants and vertical item components.
|
|
9
|
-
- `@ojiepermana/angular/navigation/horizontal` exposes the horizontal navigation
|
|
9
|
+
- `@ojiepermana/angular/navigation/horizontal` exposes the horizontal navigation variants and branch item component.
|
|
10
10
|
|
|
11
11
|
Do not import consumer code from `@ojiepermana/angular/internal` or from source file paths under this folder. Those paths are implementation details and are not part of the public contract.
|
|
12
12
|
|
|
@@ -16,6 +16,49 @@ Do not import consumer code from `@ojiepermana/angular/internal` or from source
|
|
|
16
16
|
- Import `@ojiepermana/angular/styles/index.css` in the consuming application so the shared theme tokens are available.
|
|
17
17
|
- Use Lucide icon names or aliases in `NavigationItem.icon`. The navigation components resolve icons through `@lucide/angular`.
|
|
18
18
|
|
|
19
|
+
## Source Layout
|
|
20
|
+
|
|
21
|
+
```text
|
|
22
|
+
navigation/
|
|
23
|
+
├── data/
|
|
24
|
+
│ └── demo-navigation.data.ts
|
|
25
|
+
├── state/
|
|
26
|
+
│ ├── navigation.service.ts
|
|
27
|
+
│ ├── navigation.type.ts
|
|
28
|
+
│ └── navigation.utils.ts
|
|
29
|
+
├── horizontal/
|
|
30
|
+
│ ├── core/
|
|
31
|
+
│ │ ├── horizontal-navigation.base.ts
|
|
32
|
+
│ │ └── horizontal-navigation.shared.ts
|
|
33
|
+
│ ├── default/
|
|
34
|
+
│ │ ├── default.ts
|
|
35
|
+
│ │ ├── default.css
|
|
36
|
+
│ │ └── README.md
|
|
37
|
+
│ ├── mega/
|
|
38
|
+
│ │ ├── mega.ts
|
|
39
|
+
│ │ ├── mega.css
|
|
40
|
+
│ │ └── README.md
|
|
41
|
+
│ └── types/
|
|
42
|
+
│ ├── index.ts
|
|
43
|
+
│ ├── branch.ts
|
|
44
|
+
│ └── branch/
|
|
45
|
+
│ ├── branch.ts
|
|
46
|
+
│ └── README.md
|
|
47
|
+
├── shared/
|
|
48
|
+
│ ├── content/
|
|
49
|
+
│ └── tree/
|
|
50
|
+
└── vertical/
|
|
51
|
+
├── core/
|
|
52
|
+
│ ├── vertical-navigation.base.ts
|
|
53
|
+
│ └── vertical-navigation.shared.ts
|
|
54
|
+
├── default/
|
|
55
|
+
│ ├── default.ts
|
|
56
|
+
│ └── default.css
|
|
57
|
+
├── collapsible/
|
|
58
|
+
│ └── collapsible.ts
|
|
59
|
+
└── types/
|
|
60
|
+
```
|
|
61
|
+
|
|
19
62
|
## Quick Start
|
|
20
63
|
|
|
21
64
|
### 1. Define a navigation tree
|
|
@@ -83,9 +126,7 @@ export class ShellNavigationComponent {
|
|
|
83
126
|
Vertical variants use these selectors:
|
|
84
127
|
|
|
85
128
|
- `<vertical-navigation>` for the default width and density.
|
|
86
|
-
- `<vertical-navigation-
|
|
87
|
-
- `<vertical-navigation-dense>` for a denser layout.
|
|
88
|
-
- `<vertical-navigation-thin>` for the thin icon-first layout.
|
|
129
|
+
- `<vertical-navigation-collapsible>` for the upcoming collapsible variant contract. It currently reuses the default layout.
|
|
89
130
|
|
|
90
131
|
All vertical variants share the same public API surface inherited from the base component, including `navigation`, `opened`, `mode`, `position`, `autoCollapse`, `inner`, `transparentOverlay`, and the `openedChanged` output.
|
|
91
132
|
|
|
@@ -115,6 +156,11 @@ export class TopNavigationComponent {
|
|
|
115
156
|
}
|
|
116
157
|
```
|
|
117
158
|
|
|
159
|
+
Horizontal variants use these selectors:
|
|
160
|
+
|
|
161
|
+
- `<horizontal-navigation>` for the default horizontal layout.
|
|
162
|
+
- `<horizontal-navigation-mega>` for a roomier mega-style horizontal layout.
|
|
163
|
+
|
|
118
164
|
### 4. Optionally mirror the tree into `NavigationService`
|
|
119
165
|
|
|
120
166
|
`NavigationService` is useful when other parts of the application need lookup helpers, active item state, or expanded item state. Vertical navigation renders from its `navigation` input. Horizontal navigation renders from its `navigation` input first, and falls back to the service only when the input array is empty.
|
|
@@ -183,6 +229,45 @@ Mutation and lookup methods:
|
|
|
183
229
|
- `expandItem()`, `collapseItem()`, `toggleItemExpanded()`, and `clearExpandedItems()`
|
|
184
230
|
- `getNavigation()`, `getActiveItem()`, `getFlatNavigation()`, `getItem()`, and `getItemParent()`
|
|
185
231
|
|
|
232
|
+
`activeItemId` and `expandedItemIds` now persist automatically through `NavigationPreferencesService`, while `NavigationService` stays focused on the navigation tree and lookup helpers.
|
|
233
|
+
|
|
234
|
+
## Navigation Preferences Service
|
|
235
|
+
|
|
236
|
+
`NavigationPreferencesService` is provided in root and stores persisted navigation preferences separately from the navigation tree itself.
|
|
237
|
+
|
|
238
|
+
`provideNgNavigation()` configures the defaults that are used before any persisted browser state exists.
|
|
239
|
+
|
|
240
|
+
Readonly state:
|
|
241
|
+
|
|
242
|
+
- `horizontalVariant`
|
|
243
|
+
- `verticalAppearance`
|
|
244
|
+
- `activeItemId`
|
|
245
|
+
- `expandedItemIds`
|
|
246
|
+
|
|
247
|
+
Mutation methods:
|
|
248
|
+
|
|
249
|
+
- `setHorizontalVariant()`
|
|
250
|
+
- `setVerticalAppearance()`
|
|
251
|
+
- `setActiveItem()` and `clearActiveItem()`
|
|
252
|
+
- `setExpandedItemIds()`, `expandItem()`, `collapseItem()`, `toggleExpandedItem()`, and `clearExpandedItems()`
|
|
253
|
+
- `syncWithNavigation()` and `reset()`
|
|
254
|
+
|
|
255
|
+
Persisted flat localStorage keys:
|
|
256
|
+
|
|
257
|
+
- `navigation-horizontal-variant`
|
|
258
|
+
- `navigation-vertical-appearance`
|
|
259
|
+
- `navigation-active-item`
|
|
260
|
+
- `navigation-expanded-items`
|
|
261
|
+
|
|
262
|
+
Legacy `ng-navigation:v1:vertical-appearance`, `ng-navigation:v1:active-item`, and `ng-navigation:v1:expanded-items` entries migrate automatically when they are read.
|
|
263
|
+
|
|
264
|
+
Use `horizontalVariant()` to choose which horizontal variant component to render in the consumer app, and `verticalAppearance()` to choose which vertical variant component to render.
|
|
265
|
+
|
|
266
|
+
Default provider config fields:
|
|
267
|
+
|
|
268
|
+
- `defaultHorizontalVariant`
|
|
269
|
+
- `defaultVerticalVariant`
|
|
270
|
+
|
|
186
271
|
## Styling Notes
|
|
187
272
|
|
|
188
273
|
- Pass Tailwind utility classes or other class names through the item `classes` and `badge.classes` fields when you need local visual overrides.
|
|
@@ -210,6 +295,7 @@ Mutation and lookup methods:
|
|
|
210
295
|
## Notes For Contributors
|
|
211
296
|
|
|
212
297
|
- Keep `@ojiepermana/angular/navigation` focused on the item model, helpers, and `NavigationService`.
|
|
298
|
+
- Keep navigation persistence and UI preferences in `NavigationPreferencesService` instead of storing the full navigation tree in browser storage.
|
|
213
299
|
- Keep render components in `@ojiepermana/angular/navigation/vertical` and `@ojiepermana/angular/navigation/horizontal`.
|
|
214
300
|
- Move shared implementation helpers behind `@ojiepermana/angular/internal` instead of reaching across entry point boundaries with relative imports.
|
|
215
301
|
- Treat `projects/library/navigation/shared` as a local compatibility layer for tests and source organization, not as consumer API.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Horizontal Navigation
|
|
2
|
+
|
|
3
|
+
The horizontal entrypoint exposes shared top-bar navigation variants for `@ojiepermana/angular`.
|
|
4
|
+
|
|
5
|
+
## Public Imports
|
|
6
|
+
|
|
7
|
+
```ts
|
|
8
|
+
import { HorizontalNavigation, HorizontalNavigationMegaComponent } from '@ojiepermana/angular/navigation/horizontal';
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Variants
|
|
12
|
+
|
|
13
|
+
- `HorizontalNavigation` renders the default selector `<horizontal-navigation>`.
|
|
14
|
+
- `HorizontalNavigationMegaComponent` renders the mega selector `<horizontal-navigation-mega>`.
|
|
15
|
+
|
|
16
|
+
## Source Layout
|
|
17
|
+
|
|
18
|
+
```text
|
|
19
|
+
horizontal/
|
|
20
|
+
├── core/
|
|
21
|
+
│ ├── horizontal-navigation.base.ts
|
|
22
|
+
│ └── horizontal-navigation.shared.ts
|
|
23
|
+
├── default/
|
|
24
|
+
│ ├── default.ts
|
|
25
|
+
│ ├── default.css
|
|
26
|
+
│ └── README.md
|
|
27
|
+
├── mega/
|
|
28
|
+
│ ├── mega.ts
|
|
29
|
+
│ ├── mega.css
|
|
30
|
+
│ └── README.md
|
|
31
|
+
├── types/
|
|
32
|
+
│ ├── index.ts
|
|
33
|
+
│ ├── README.md
|
|
34
|
+
│ ├── branch.ts
|
|
35
|
+
│ └── branch/
|
|
36
|
+
│ ├── branch.ts
|
|
37
|
+
│ └── README.md
|
|
38
|
+
├── horizontal.ts
|
|
39
|
+
├── index.ts
|
|
40
|
+
├── ng-package.json
|
|
41
|
+
└── public-api.ts
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## Notes
|
|
45
|
+
|
|
46
|
+
- `core/` contains variant-agnostic logic and template composition.
|
|
47
|
+
- `default/` and `mega/` contain variant-specific components and styles.
|
|
48
|
+
- `types/` contains reusable branch rendering primitives shared by all horizontal variants.
|
|
49
|
+
- `horizontal.ts` remains a compatibility barrel that points to the default variant implementation.
|
|
File without changes
|
package/package.json
CHANGED
package/shell/README.md
CHANGED
|
@@ -29,9 +29,13 @@ export const appConfig: ApplicationConfig = {
|
|
|
29
29
|
defaultMode: 'vertical',
|
|
30
30
|
defaultContainer: 'boxed',
|
|
31
31
|
},
|
|
32
|
+
navigation: {
|
|
33
|
+
defaultHorizontalVariant: 'default',
|
|
34
|
+
defaultVerticalVariant: 'default',
|
|
35
|
+
},
|
|
32
36
|
}),
|
|
33
37
|
],
|
|
34
38
|
};
|
|
35
39
|
```
|
|
36
40
|
|
|
37
|
-
`provideNgShell()` is a convenience wrapper over `provideNgTheme()` and `
|
|
41
|
+
`provideNgShell()` is a convenience wrapper over `provideNgTheme()`, `provideNgLayout()`, and `provideNgNavigation()`. It does not introduce a separate runtime state layer.
|
package/styles/index.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
@import '../theme/styles/index.css';
|
|
2
|
-
@import '../
|
|
2
|
+
@import '../layout/src/layout.css';
|
package/theme/README.md
CHANGED
|
@@ -188,9 +188,9 @@ It imports the current structure in this order:
|
|
|
188
188
|
- `utilities/index.css`
|
|
189
189
|
- `adapters/material-ui/index.css`
|
|
190
190
|
|
|
191
|
-
Layout selectors now live in `projects/library/layout/
|
|
191
|
+
Layout-wide selectors now live in `projects/library/layout/src/layout.css` inside this workspace.
|
|
192
192
|
|
|
193
|
-
For applications that consume the published package, use the aggregate bundle at `projects/library/styles/index.css` in this workspace or `@ojiepermana/angular/styles/index.css` from the published package. The aggregate bundle imports theme first, then layout.
|
|
193
|
+
For applications that consume the published package, use the aggregate bundle at `projects/library/styles/index.css` in this workspace or `@ojiepermana/angular/styles/index.css` from the published package. The aggregate bundle imports theme first, then the layout-wide selectors. Horizontal and vertical shell CSS are loaded by their respective layout components.
|
|
194
194
|
|
|
195
195
|
Application-level resets are intentionally opt-in. If a consumer wants them, import `projects/library/styles/resets.css` in this workspace or `@ojiepermana/angular/styles/resets.css` from the published package in addition to the aggregate bundle.
|
|
196
196
|
|
|
@@ -21,6 +21,7 @@ declare class LocalStorageStateAdapter<Axis extends string> {
|
|
|
21
21
|
constructor(config: LocalStorageStateAdapterConfig<Axis>);
|
|
22
22
|
clear(axis: Axis): void;
|
|
23
23
|
persist(axis: Axis, value: string): void;
|
|
24
|
+
readValue(axis: Axis): string | null;
|
|
24
25
|
read<T extends string>(axis: Axis, fallback: T, isValid: (value: string) => value is T): T;
|
|
25
26
|
private key;
|
|
26
27
|
private legacyKey;
|
|
@@ -43,7 +43,7 @@ declare class LayoutHostDirective {
|
|
|
43
43
|
|
|
44
44
|
declare class LayoutHorizontalComponent {
|
|
45
45
|
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutHorizontalComponent, never>;
|
|
46
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutHorizontalComponent, "horizontal", never, {}, {}, never, ["[
|
|
46
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutHorizontalComponent, "horizontal", never, {}, {}, never, ["[brand]", "[navigation]", "[action]"], true, never>;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
declare class LayoutVerticalComponent {
|
|
@@ -12,6 +12,7 @@ declare class HorizontalNavigationBranchItem {
|
|
|
12
12
|
item: _angular_core.InputSignal<NavigationItem>;
|
|
13
13
|
menuItem: _angular_core.InputSignal<boolean>;
|
|
14
14
|
nested: _angular_core.InputSignal<boolean>;
|
|
15
|
+
variant: _angular_core.InputSignal<HorizontalNavigationVariant>;
|
|
15
16
|
itemClicked: _angular_core.OutputEmitterRef<NavigationItem>;
|
|
16
17
|
branchOpened: _angular_core.OutputEmitterRef<HorizontalNavigationBranchItem>;
|
|
17
18
|
branchClosed: _angular_core.OutputEmitterRef<HorizontalNavigationBranchItem>;
|
|
@@ -23,7 +24,7 @@ declare class HorizontalNavigationBranchItem {
|
|
|
23
24
|
readonly treeShouldRenderItemFn: typeof shouldRenderNavigationItem;
|
|
24
25
|
readonly treeHasChildrenFn: typeof hasNavigationChildren;
|
|
25
26
|
readonly treeResolveParentKeyFn: typeof getNavigationTreePathKey;
|
|
26
|
-
readonly menuPanelClass: _angular_core.Signal<
|
|
27
|
+
readonly menuPanelClass: _angular_core.Signal<string>;
|
|
27
28
|
hasChildren(item: NavigationItem): boolean;
|
|
28
29
|
shouldRenderItem(item: NavigationItem): boolean;
|
|
29
30
|
trackByFn(index: number, item: NavigationItem): string | number;
|
|
@@ -40,38 +41,41 @@ declare class HorizontalNavigationBranchItem {
|
|
|
40
41
|
closeMenu(): void;
|
|
41
42
|
private _syncRootTriggerWidth;
|
|
42
43
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<HorizontalNavigationBranchItem, never>;
|
|
43
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<HorizontalNavigationBranchItem, "horizontal-navigation-branch-item", never, { "item": { "alias": "item"; "required": true; "isSignal": true; }; "menuItem": { "alias": "menuItem"; "required": false; "isSignal": true; }; "nested": { "alias": "nested"; "required": false; "isSignal": true; }; }, { "itemClicked": "itemClicked"; "branchOpened": "branchOpened"; "branchClosed": "branchClosed"; }, never, never, true, never>;
|
|
44
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<HorizontalNavigationBranchItem, "horizontal-navigation-branch-item", never, { "item": { "alias": "item"; "required": true; "isSignal": true; }; "menuItem": { "alias": "menuItem"; "required": false; "isSignal": true; }; "nested": { "alias": "nested"; "required": false; "isSignal": true; }; "variant": { "alias": "variant"; "required": false; "isSignal": true; }; }, { "itemClicked": "itemClicked"; "branchOpened": "branchOpened"; "branchClosed": "branchClosed"; }, never, never, true, never>;
|
|
44
45
|
}
|
|
45
46
|
|
|
46
|
-
|
|
47
|
-
|
|
47
|
+
type HorizontalNavigationVariant = 'default' | 'mega';
|
|
48
|
+
declare abstract class HorizontalNavigationBaseComponent {
|
|
49
|
+
abstract readonly variant: HorizontalNavigationVariant;
|
|
50
|
+
private readonly _navigationService;
|
|
48
51
|
private _activeRootBranch;
|
|
49
|
-
name: _angular_core.InputSignal<string>;
|
|
50
|
-
navigation: _angular_core.InputSignal<NavigationItem[]>;
|
|
51
|
-
itemClicked: _angular_core.OutputEmitterRef<NavigationItem>;
|
|
52
|
-
navigationData: _angular_core.Signal<NavigationItem[]>;
|
|
53
|
-
|
|
54
|
-
* Handle item click
|
|
55
|
-
*/
|
|
52
|
+
readonly name: _angular_core.InputSignal<string>;
|
|
53
|
+
readonly navigation: _angular_core.InputSignal<NavigationItem[]>;
|
|
54
|
+
readonly itemClicked: _angular_core.OutputEmitterRef<NavigationItem>;
|
|
55
|
+
readonly navigationData: _angular_core.Signal<NavigationItem[]>;
|
|
56
|
+
isMegaVariant(): boolean;
|
|
56
57
|
onItemClicked(item: NavigationItem): void;
|
|
57
58
|
onRootBranchOpened(branch: HorizontalNavigationBranchItem): void;
|
|
58
59
|
onRootBranchClosed(branch: HorizontalNavigationBranchItem): void;
|
|
59
60
|
shouldRenderItem(item: NavigationItem): boolean;
|
|
60
61
|
hasChildren(item: NavigationItem): boolean;
|
|
61
|
-
/**
|
|
62
|
-
* Get flat navigation for utility purposes
|
|
63
|
-
*/
|
|
64
62
|
getFlatNavigation(): NavigationItem[];
|
|
65
|
-
/**
|
|
66
|
-
* Get navigation item by ID
|
|
67
|
-
*/
|
|
68
63
|
getItem(id: string): NavigationItem | null;
|
|
69
|
-
/**
|
|
70
|
-
* Get navigation item parent by ID
|
|
71
|
-
*/
|
|
72
64
|
getItemParent(id: string): NavigationItem[] | NavigationItem | null;
|
|
65
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<HorizontalNavigationBaseComponent, never>;
|
|
66
|
+
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<HorizontalNavigationBaseComponent, never, never, { "name": { "alias": "name"; "required": false; "isSignal": true; }; "navigation": { "alias": "navigation"; "required": false; "isSignal": true; }; }, { "itemClicked": "itemClicked"; }, never, never, true, never>;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
declare class HorizontalNavigation extends HorizontalNavigationBaseComponent {
|
|
70
|
+
readonly variant: "default";
|
|
73
71
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<HorizontalNavigation, never>;
|
|
74
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<HorizontalNavigation, "horizontal-navigation", never, {
|
|
72
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<HorizontalNavigation, "horizontal-navigation", never, {}, {}, never, never, true, never>;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
declare class HorizontalNavigationMegaComponent extends HorizontalNavigationBaseComponent {
|
|
76
|
+
readonly variant: "mega";
|
|
77
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<HorizontalNavigationMegaComponent, never>;
|
|
78
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<HorizontalNavigationMegaComponent, "horizontal-navigation-mega", never, {}, {}, never, never, true, never>;
|
|
75
79
|
}
|
|
76
80
|
|
|
77
|
-
export { HorizontalNavigation, HorizontalNavigationBranchItem };
|
|
81
|
+
export { HorizontalNavigation, HorizontalNavigationBranchItem, HorizontalNavigationMegaComponent };
|
|
@@ -79,28 +79,27 @@ declare class VerticalNavigationDefaultComponent extends VerticalNavigationBaseC
|
|
|
79
79
|
static ɵcmp: i0.ɵɵComponentDeclaration<VerticalNavigationDefaultComponent, "vertical-navigation", ["verticalNavigationDefault"], { "appearance": { "alias": "appearance"; "required": false; }; }, {}, never, ["[verticalNavigationHeader]", "[verticalNavigationContentHeader]", "[verticalNavigationContentFooter]", "[verticalNavigationFooter]"], true, never>;
|
|
80
80
|
}
|
|
81
81
|
|
|
82
|
-
declare class
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
appearance: VerticalNavigationAppearance;
|
|
86
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<VerticalNavigationCompactComponent, never>;
|
|
87
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<VerticalNavigationCompactComponent, "vertical-navigation-compact", ["verticalNavigationCompact"], { "appearance": { "alias": "appearance"; "required": false; }; }, {}, never, ["[verticalNavigationHeader]", "[verticalNavigationContentHeader]", "[verticalNavigationContentFooter]", "[verticalNavigationFooter]"], true, never>;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
declare class VerticalNavigationDenseComponent extends VerticalNavigationBaseComponent implements OnChanges, OnInit, AfterViewInit, OnDestroy {
|
|
91
|
-
protected _componentPrefix: string;
|
|
92
|
-
protected _asideWrapperClass: string;
|
|
93
|
-
appearance: VerticalNavigationAppearance;
|
|
94
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<VerticalNavigationDenseComponent, never>;
|
|
95
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<VerticalNavigationDenseComponent, "vertical-navigation-dense", ["verticalNavigationDense"], { "appearance": { "alias": "appearance"; "required": false; }; }, {}, never, ["[verticalNavigationHeader]", "[verticalNavigationContentHeader]", "[verticalNavigationContentFooter]", "[verticalNavigationFooter]"], true, never>;
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
declare class VerticalNavigationThinComponent extends VerticalNavigationBaseComponent implements OnChanges, OnInit, AfterViewInit, OnDestroy {
|
|
99
|
-
protected _componentPrefix: string;
|
|
100
|
-
protected _asideWrapperClass: string;
|
|
82
|
+
declare class VerticalNavigationCollapsibleComponent {
|
|
83
|
+
private navigationComponent?;
|
|
84
|
+
autoCollapse: boolean;
|
|
101
85
|
appearance: VerticalNavigationAppearance;
|
|
102
|
-
|
|
103
|
-
|
|
86
|
+
inner: boolean;
|
|
87
|
+
mode: VerticalNavigationMode;
|
|
88
|
+
navigation: NavigationItem[];
|
|
89
|
+
opened: boolean;
|
|
90
|
+
position: VerticalNavigationPosition;
|
|
91
|
+
transparentOverlay: boolean;
|
|
92
|
+
readonly appearanceChanged: EventEmitter<VerticalNavigationAppearance>;
|
|
93
|
+
readonly modeChanged: EventEmitter<VerticalNavigationMode>;
|
|
94
|
+
readonly openedChanged: EventEmitter<boolean>;
|
|
95
|
+
readonly positionChanged: EventEmitter<VerticalNavigationPosition>;
|
|
96
|
+
protected readonly renderedAppearance: VerticalNavigationAppearance;
|
|
97
|
+
refresh(): void;
|
|
98
|
+
open(): void;
|
|
99
|
+
close(): void;
|
|
100
|
+
toggle(): void;
|
|
101
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<VerticalNavigationCollapsibleComponent, never>;
|
|
102
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<VerticalNavigationCollapsibleComponent, "vertical-navigation-collapsible", ["verticalNavigationCollapsible"], { "autoCollapse": { "alias": "autoCollapse"; "required": false; }; "appearance": { "alias": "appearance"; "required": false; }; "inner": { "alias": "inner"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "navigation": { "alias": "navigation"; "required": false; }; "opened": { "alias": "opened"; "required": false; }; "position": { "alias": "position"; "required": false; }; "transparentOverlay": { "alias": "transparentOverlay"; "required": false; }; }, { "appearanceChanged": "appearanceChanged"; "modeChanged": "modeChanged"; "openedChanged": "openedChanged"; "positionChanged": "positionChanged"; }, never, ["[verticalNavigationHeader]", "[verticalNavigationContentHeader]", "[verticalNavigationContentFooter]", "[verticalNavigationFooter]"], true, never>;
|
|
104
103
|
}
|
|
105
104
|
|
|
106
105
|
declare class VerticalNavigationAsideItemComponent implements OnChanges, OnInit, OnDestroy {
|
|
@@ -150,6 +149,7 @@ declare class VerticalNavigationAsideItemComponent implements OnChanges, OnInit,
|
|
|
150
149
|
declare class VerticalNavigationBasicItemComponent implements OnInit, OnDestroy {
|
|
151
150
|
private _changeDetectorRef;
|
|
152
151
|
private _navigationComponent;
|
|
152
|
+
private _navigationService;
|
|
153
153
|
item: NavigationBasicItem;
|
|
154
154
|
isActiveMatchOptions: IsActiveMatchOptions;
|
|
155
155
|
private _unsubscribeAll;
|
|
@@ -162,6 +162,7 @@ declare class VerticalNavigationBasicItemComponent implements OnInit, OnDestroy
|
|
|
162
162
|
*/
|
|
163
163
|
ngOnDestroy(): void;
|
|
164
164
|
hasAction(): boolean;
|
|
165
|
+
markActive(): void;
|
|
165
166
|
triggerAction(): void;
|
|
166
167
|
static ɵfac: i0.ɵɵFactoryDeclaration<VerticalNavigationBasicItemComponent, never>;
|
|
167
168
|
static ɵcmp: i0.ɵɵComponentDeclaration<VerticalNavigationBasicItemComponent, "vertical-navigation-basic-item", never, { "item": { "alias": "item"; "required": false; }; }, {}, never, never, true, never>;
|
|
@@ -211,6 +212,7 @@ declare class VerticalNavigationCollapsableItemComponent implements OnInit, OnDe
|
|
|
211
212
|
* Check if the given item has the given url in one of its children
|
|
212
213
|
*/
|
|
213
214
|
private _hasActiveChild;
|
|
215
|
+
private _shouldExpand;
|
|
214
216
|
/**
|
|
215
217
|
* Check if this is a children of the given item
|
|
216
218
|
*/
|
|
@@ -257,4 +259,4 @@ declare class VerticalNavigationSpacerItemComponent {
|
|
|
257
259
|
static ɵcmp: i0.ɵɵComponentDeclaration<VerticalNavigationSpacerItemComponent, "vertical-navigation-spacer-item", never, {}, {}, never, never, true, never>;
|
|
258
260
|
}
|
|
259
261
|
|
|
260
|
-
export { VerticalNavigationAsideItemComponent, VerticalNavigationBasicItemComponent, VerticalNavigationCollapsableItemComponent,
|
|
262
|
+
export { VerticalNavigationAsideItemComponent, VerticalNavigationBasicItemComponent, VerticalNavigationCollapsableItemComponent, VerticalNavigationCollapsibleComponent, VerticalNavigationDefaultComponent, VerticalNavigationDividerItemComponent, VerticalNavigationGroupItemComponent, VerticalNavigationSpacerItemComponent };
|