@ojiepermana/angular-theme 22.0.27
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/fesm2022/ojiepermana-angular-theme-layout-services.mjs +364 -0
- package/fesm2022/ojiepermana-angular-theme-layout-services.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-theme-layout-types.mjs +32 -0
- package/fesm2022/ojiepermana-angular-theme-layout-types.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-theme-layout.mjs +574 -0
- package/fesm2022/ojiepermana-angular-theme-layout.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-theme-page.mjs +510 -0
- package/fesm2022/ojiepermana-angular-theme-page.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-theme-styles.mjs +244 -0
- package/fesm2022/ojiepermana-angular-theme-styles.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-theme.mjs +11 -0
- package/fesm2022/ojiepermana-angular-theme.mjs.map +1 -0
- package/layout/README.md +471 -0
- package/package.json +60 -0
- package/page/README.md +239 -0
- package/styles/README.md +28 -0
- package/styles/css/index.css +9 -0
- package/styles/css/seasonal/base/components.css +129 -0
- package/styles/css/seasonal/base/package.css +6 -0
- package/styles/css/seasonal/base/tailwind.css +144 -0
- package/styles/css/seasonal/base/theme.css +287 -0
- package/styles/css/seasonal/base/tokens.css +152 -0
- package/styles/css/seasonal/ied/package.css +4 -0
- package/styles/css/seasonal/ied/theme.css +78 -0
- package/styles/css/seasonal/imlek/components.css +87 -0
- package/styles/css/seasonal/imlek/package.css +6 -0
- package/styles/css/seasonal/imlek/tailwind.css +144 -0
- package/styles/css/seasonal/imlek/theme.css +95 -0
- package/styles/css/seasonal/imlek/tokens.css +152 -0
- package/styles/css/seasonal/index.css +6 -0
- package/styles/css/seasonal/natal/package.css +4 -0
- package/styles/css/seasonal/natal/theme.css +78 -0
- package/styles/css/seasonal/new-year/package.css +4 -0
- package/styles/css/seasonal/new-year/theme.css +78 -0
- package/styles/css/seasonal/ramadhan/package.css +4 -0
- package/styles/css/seasonal/ramadhan/theme.css +78 -0
- package/types/ojiepermana-angular-theme-layout-services.d.ts +120 -0
- package/types/ojiepermana-angular-theme-layout-types.d.ts +33 -0
- package/types/ojiepermana-angular-theme-layout.d.ts +117 -0
- package/types/ojiepermana-angular-theme-page.d.ts +168 -0
- package/types/ojiepermana-angular-theme-styles.d.ts +89 -0
- package/types/ojiepermana-angular-theme.d.ts +2 -0
|
@@ -0,0 +1,574 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { inject, input, computed, DestroyRef, Component, effect, ChangeDetectionStrategy, contentChild } from '@angular/core';
|
|
3
|
+
import { cn } from '@ojiepermana/angular-component/utils';
|
|
4
|
+
import { LayoutLoadingService, LayoutService } from '@ojiepermana/angular-theme/layout/services';
|
|
5
|
+
export { LAYOUT_LOADING_HIDE_DELAY_MS, LAYOUT_LOADING_INITIAL_PROGRESS, LAYOUT_LOADING_SKIP, LAYOUT_LOADING_TRICKLE_CEILING, LAYOUT_LOADING_TRICKLE_INTERVAL_MS, LayoutLoadingService, LayoutService, layoutLoadingInterceptor } from '@ojiepermana/angular-theme/layout/services';
|
|
6
|
+
import { LAYOUT_DEFAULT_SURFACE, LAYOUT_DEFAULT_STYLE, LAYOUT_DEFAULT_WIDTH } from '@ojiepermana/angular-theme/layout/types';
|
|
7
|
+
export { LAYOUT_APPEARANCE_STORAGE_KEY, LAYOUT_DEFAULT_STYLE, LAYOUT_DEFAULT_SURFACE, LAYOUT_DEFAULT_TYPE, LAYOUT_DEFAULT_WIDTH, LAYOUT_STYLES, LAYOUT_STYLE_STORAGE_KEY, LAYOUT_SURFACES, LAYOUT_SURFACE_STORAGE_KEY, LAYOUT_TYPES, LAYOUT_TYPE_STORAGE_KEY, LAYOUT_WIDTHS, LAYOUT_WIDTH_STORAGE_KEY, isUiLayoutStyle, isUiLayoutSurface, isUiLayoutType, isUiLayoutWidth } from '@ojiepermana/angular-theme/layout/types';
|
|
8
|
+
import { NavigationContainerComponent } from '@ojiepermana/angular-navigation';
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Garis progres tipis di tepi atas browser yang bergerak dari kiri ke kanan.
|
|
12
|
+
* Dirender otomatis oleh `Layout` dan dikendalikan `LayoutLoadingService`,
|
|
13
|
+
* sehingga aktif sendiri saat navigasi halaman atau pemuatan data berjalan.
|
|
14
|
+
*
|
|
15
|
+
* Boleh juga dipasang langsung di root aplikasi agar bar sudah tampil sejak
|
|
16
|
+
* navigasi awal; instance tambahan di dalam `Layout` otomatis inert sehingga
|
|
17
|
+
* garis tidak pernah dirender ganda.
|
|
18
|
+
*/
|
|
19
|
+
class LayoutLoadingComponent {
|
|
20
|
+
loading = inject(LayoutLoadingService);
|
|
21
|
+
hostId = this.loading.registerHost();
|
|
22
|
+
class = input('', /* @ts-ignore */
|
|
23
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
24
|
+
ariaLabel = input('Memuat halaman', /* @ts-ignore */
|
|
25
|
+
...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
26
|
+
isPrimary = computed(() => this.loading.primaryHostId() === this.hostId, /* @ts-ignore */
|
|
27
|
+
...(ngDevMode ? [{ debugName: "isPrimary" }] : /* istanbul ignore next */ []));
|
|
28
|
+
state = computed(() => {
|
|
29
|
+
if (!this.isPrimary()) {
|
|
30
|
+
return 'inert';
|
|
31
|
+
}
|
|
32
|
+
return this.loading.active() ? 'active' : 'idle';
|
|
33
|
+
}, /* @ts-ignore */
|
|
34
|
+
...(ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []));
|
|
35
|
+
hostClasses = computed(() => cn('pointer-events-none fixed inset-x-0 top-0 z-50 block h-0.5', this.class()), /* @ts-ignore */
|
|
36
|
+
...(ngDevMode ? [{ debugName: "hostClasses" }] : /* istanbul ignore next */ []));
|
|
37
|
+
roundedProgress = computed(() => Math.round(this.loading.progress()), /* @ts-ignore */
|
|
38
|
+
...(ngDevMode ? [{ debugName: "roundedProgress" }] : /* istanbul ignore next */ []));
|
|
39
|
+
constructor() {
|
|
40
|
+
inject(DestroyRef).onDestroy(() => this.loading.unregisterHost(this.hostId));
|
|
41
|
+
}
|
|
42
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutLoadingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
43
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.2", type: LayoutLoadingComponent, isStandalone: true, selector: "LayoutLoading", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "hostClasses()", "attr.data-state": "state()" } }, ngImport: i0, template: `
|
|
44
|
+
@if (isPrimary() && loading.active()) {
|
|
45
|
+
<div
|
|
46
|
+
role="progressbar"
|
|
47
|
+
data-layout-loading-track
|
|
48
|
+
class="h-full w-full"
|
|
49
|
+
[attr.aria-label]="ariaLabel()"
|
|
50
|
+
aria-valuemin="0"
|
|
51
|
+
aria-valuemax="100"
|
|
52
|
+
[attr.aria-valuenow]="roundedProgress()">
|
|
53
|
+
<div
|
|
54
|
+
data-layout-loading-bar
|
|
55
|
+
class="h-full rounded-r-full bg-primary transition-[width] duration-200 ease-out"
|
|
56
|
+
[style.width.%]="loading.progress()"></div>
|
|
57
|
+
</div>
|
|
58
|
+
}
|
|
59
|
+
`, isInline: true });
|
|
60
|
+
}
|
|
61
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutLoadingComponent, decorators: [{
|
|
62
|
+
type: Component,
|
|
63
|
+
args: [{
|
|
64
|
+
selector: 'LayoutLoading',
|
|
65
|
+
host: {
|
|
66
|
+
'[class]': 'hostClasses()',
|
|
67
|
+
'[attr.data-state]': 'state()',
|
|
68
|
+
},
|
|
69
|
+
template: `
|
|
70
|
+
@if (isPrimary() && loading.active()) {
|
|
71
|
+
<div
|
|
72
|
+
role="progressbar"
|
|
73
|
+
data-layout-loading-track
|
|
74
|
+
class="h-full w-full"
|
|
75
|
+
[attr.aria-label]="ariaLabel()"
|
|
76
|
+
aria-valuemin="0"
|
|
77
|
+
aria-valuemax="100"
|
|
78
|
+
[attr.aria-valuenow]="roundedProgress()">
|
|
79
|
+
<div
|
|
80
|
+
data-layout-loading-bar
|
|
81
|
+
class="h-full rounded-r-full bg-primary transition-[width] duration-200 ease-out"
|
|
82
|
+
[style.width.%]="loading.progress()"></div>
|
|
83
|
+
</div>
|
|
84
|
+
}
|
|
85
|
+
`,
|
|
86
|
+
}]
|
|
87
|
+
}], ctorParameters: () => [], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }] } });
|
|
88
|
+
|
|
89
|
+
class LayoutComponent {
|
|
90
|
+
layout = inject(LayoutService);
|
|
91
|
+
surface = input(null, /* @ts-ignore */
|
|
92
|
+
...(ngDevMode ? [{ debugName: "surface" }] : /* istanbul ignore next */ []));
|
|
93
|
+
appearance = input(null, /* @ts-ignore */
|
|
94
|
+
...(ngDevMode ? [{ debugName: "appearance" }] : /* istanbul ignore next */ []));
|
|
95
|
+
layoutStyleAttribute = input(null, { ...(ngDevMode ? { debugName: "layoutStyleAttribute" } : /* istanbul ignore next */ {}), alias: 'layout-style' });
|
|
96
|
+
width = input(null, /* @ts-ignore */
|
|
97
|
+
...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ []));
|
|
98
|
+
class = input('', /* @ts-ignore */
|
|
99
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
100
|
+
appearanceInput = computed(() => this.appearance() ?? this.layoutStyleAttribute(), /* @ts-ignore */
|
|
101
|
+
...(ngDevMode ? [{ debugName: "appearanceInput" }] : /* istanbul ignore next */ []));
|
|
102
|
+
resolvedSurface = computed(() => this.surface() ?? this.layout.surface(), /* @ts-ignore */
|
|
103
|
+
...(ngDevMode ? [{ debugName: "resolvedSurface" }] : /* istanbul ignore next */ []));
|
|
104
|
+
resolvedAppearance = computed(() => this.appearanceInput() ?? this.layout.appearance(), /* @ts-ignore */
|
|
105
|
+
...(ngDevMode ? [{ debugName: "resolvedAppearance" }] : /* istanbul ignore next */ []));
|
|
106
|
+
resolvedStyle = computed(() => this.layout.appearance(), /* @ts-ignore */
|
|
107
|
+
...(ngDevMode ? [{ debugName: "resolvedStyle" }] : /* istanbul ignore next */ []));
|
|
108
|
+
resolvedWidth = computed(() => this.width() ?? this.layout.width(), /* @ts-ignore */
|
|
109
|
+
...(ngDevMode ? [{ debugName: "resolvedWidth" }] : /* istanbul ignore next */ []));
|
|
110
|
+
isBorderRail = computed(() => this.resolvedAppearance() === 'border-rail', /* @ts-ignore */
|
|
111
|
+
...(ngDevMode ? [{ debugName: "isBorderRail" }] : /* istanbul ignore next */ []));
|
|
112
|
+
isFluidFrame = computed(() => this.resolvedWidth() === 'fluid' && this.layout.type() === 'fluid', /* @ts-ignore */
|
|
113
|
+
...(ngDevMode ? [{ debugName: "isFluidFrame" }] : /* istanbul ignore next */ []));
|
|
114
|
+
showsInsetRails = computed(() => {
|
|
115
|
+
const layoutType = this.layout.type();
|
|
116
|
+
return this.isBorderRail() && (layoutType === 'horizontal' || layoutType === 'vertical');
|
|
117
|
+
}, /* @ts-ignore */
|
|
118
|
+
...(ngDevMode ? [{ debugName: "showsInsetRails" }] : /* istanbul ignore next */ []));
|
|
119
|
+
frameStageClasses = computed(() => cn('relative grid min-h-0 min-w-0 grid-cols-1 grid-rows-1', this.frameSizeClasses()), /* @ts-ignore */
|
|
120
|
+
...(ngDevMode ? [{ debugName: "frameStageClasses" }] : /* istanbul ignore next */ []));
|
|
121
|
+
railAnchorClasses = computed(() => 'relative h-full min-h-0 w-full min-w-0', /* @ts-ignore */
|
|
122
|
+
...(ngDevMode ? [{ debugName: "railAnchorClasses" }] : /* istanbul ignore next */ []));
|
|
123
|
+
contentShellClasses = computed(() => cn('relative z-10 min-h-0 min-w-0', this.isFluidFrame() ? 'h-auto w-auto max-h-full max-w-full' : 'h-full w-full', this.isBorderRail() ? 'overflow-visible' : 'overflow-hidden'), /* @ts-ignore */
|
|
124
|
+
...(ngDevMode ? [{ debugName: "contentShellClasses" }] : /* istanbul ignore next */ []));
|
|
125
|
+
hostClasses = computed(() => cn('relative isolate h-dvh w-full min-w-0 box-border overflow-hidden text-foreground', this.isFluidFrame() ? 'grid place-items-center' : 'block', this.surfaceClasses(), this.widthPaddingClasses(), this.class()), /* @ts-ignore */
|
|
126
|
+
...(ngDevMode ? [{ debugName: "hostClasses" }] : /* istanbul ignore next */ []));
|
|
127
|
+
frameClasses = computed(() => cn('relative min-h-0 min-w-0 border-border bg-background/55 backdrop-blur-xs', this.frameSizeClasses(), this.isBorderRail() ? 'overflow-visible border-[1.5px]' : 'overflow-hidden border'), /* @ts-ignore */
|
|
128
|
+
...(ngDevMode ? [{ debugName: "frameClasses" }] : /* istanbul ignore next */ []));
|
|
129
|
+
frameLayerClasses = computed(() => cn('col-start-1 row-start-1', this.frameClasses()), /* @ts-ignore */
|
|
130
|
+
...(ngDevMode ? [{ debugName: "frameLayerClasses" }] : /* istanbul ignore next */ []));
|
|
131
|
+
constructor() {
|
|
132
|
+
effect(() => {
|
|
133
|
+
const surface = this.surface();
|
|
134
|
+
if (surface !== null) {
|
|
135
|
+
this.layout.setSurface(surface, { persist: false });
|
|
136
|
+
}
|
|
137
|
+
else {
|
|
138
|
+
this.layout.registerSurface(LAYOUT_DEFAULT_SURFACE);
|
|
139
|
+
}
|
|
140
|
+
const appearance = this.appearanceInput();
|
|
141
|
+
if (appearance !== null) {
|
|
142
|
+
this.layout.setAppearance(appearance, { persist: false });
|
|
143
|
+
}
|
|
144
|
+
else {
|
|
145
|
+
this.layout.registerAppearance(LAYOUT_DEFAULT_STYLE);
|
|
146
|
+
}
|
|
147
|
+
const width = this.width();
|
|
148
|
+
if (width !== null) {
|
|
149
|
+
this.layout.setWidth(width, { persist: false });
|
|
150
|
+
}
|
|
151
|
+
else {
|
|
152
|
+
this.layout.registerWidth(LAYOUT_DEFAULT_WIDTH);
|
|
153
|
+
}
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
surfaceClasses() {
|
|
157
|
+
switch (this.resolvedSurface()) {
|
|
158
|
+
case 'grid':
|
|
159
|
+
return '[--layout-grid-size:2rem] bg-background bg-[linear-gradient(hsl(var(--layout-grid-line)/var(--layout-grid-line-opacity))_1px,transparent_1px),linear-gradient(to_right,hsl(var(--layout-grid-line)/var(--layout-grid-line-opacity))_1px,transparent_1px)] bg-position-[center_center] bg-size-[var(--layout-grid-size)_var(--layout-grid-size)]';
|
|
160
|
+
case 'honeycome':
|
|
161
|
+
return 'bg-background bg-[radial-gradient(circle_at_0_0,hsl(var(--layout-grid-line)/var(--layout-grid-dot-opacity))_1px,transparent_1.5px)] bg-position-[center_center] bg-size-[1.25rem_1.25rem]';
|
|
162
|
+
case 'line-vertical':
|
|
163
|
+
return 'bg-background bg-[linear-gradient(to_right,hsl(var(--layout-grid-line)/var(--layout-grid-dot-opacity))_1px,transparent_1px)] bg-position-[center_center] bg-size-[2rem_2rem]';
|
|
164
|
+
case 'line-horizontal':
|
|
165
|
+
return 'bg-background bg-[linear-gradient(hsl(var(--layout-grid-line)/var(--layout-grid-dot-opacity))_1px,transparent_1px)] bg-position-[center_center] bg-size-[2rem_2rem]';
|
|
166
|
+
default:
|
|
167
|
+
return 'bg-background';
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
widthPaddingClasses() {
|
|
171
|
+
switch (this.resolvedWidth()) {
|
|
172
|
+
case 'wide':
|
|
173
|
+
return 'p-4 lg:p-12';
|
|
174
|
+
case 'container':
|
|
175
|
+
return 'p-4 lg:px-0 lg:py-16';
|
|
176
|
+
case 'fluid':
|
|
177
|
+
return 'p-4 sm:p-6 lg:p-8';
|
|
178
|
+
default:
|
|
179
|
+
return 'p-4';
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
frameSizeClasses() {
|
|
183
|
+
if (this.isFluidFrame()) {
|
|
184
|
+
return 'h-auto w-auto max-h-full max-w-full';
|
|
185
|
+
}
|
|
186
|
+
return this.resolvedWidth() === 'container' ? 'h-full w-full lg:container lg:mx-auto' : 'h-full w-full';
|
|
187
|
+
}
|
|
188
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
189
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.2", type: LayoutComponent, isStandalone: true, selector: "Layout", inputs: { surface: { classPropertyName: "surface", publicName: "surface", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, layoutStyleAttribute: { classPropertyName: "layoutStyleAttribute", publicName: "layout-style", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "hostClasses()", "attr.data-surface": "resolvedSurface()", "attr.data-layout-appearance": "resolvedAppearance()", "attr.data-layout-style": "resolvedStyle()", "attr.data-layout-width": "resolvedWidth()", "attr.data-layout-type": "layout.type()" } }, ngImport: i0, template: `
|
|
190
|
+
<LayoutLoading />
|
|
191
|
+
|
|
192
|
+
<div data-layout-stage [class]="frameStageClasses()">
|
|
193
|
+
@if (isBorderRail()) {
|
|
194
|
+
<div
|
|
195
|
+
aria-hidden="true"
|
|
196
|
+
data-layout-rail
|
|
197
|
+
class="pointer-events-none col-start-1 row-start-1 z-0 overflow-visible">
|
|
198
|
+
<div data-layout-rail-anchor [class]="railAnchorClasses()">
|
|
199
|
+
<div
|
|
200
|
+
data-layout-rail-top-left-horizontal
|
|
201
|
+
class="absolute top-0 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
202
|
+
<div
|
|
203
|
+
data-layout-rail-top-left-vertical
|
|
204
|
+
class="absolute bottom-full left-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
205
|
+
<div
|
|
206
|
+
data-layout-rail-top-right-horizontal
|
|
207
|
+
class="absolute top-0 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
208
|
+
<div
|
|
209
|
+
data-layout-rail-top-right-vertical
|
|
210
|
+
class="absolute bottom-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
211
|
+
<div
|
|
212
|
+
data-layout-rail-bottom-left-horizontal
|
|
213
|
+
class="absolute bottom-0 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
214
|
+
<div
|
|
215
|
+
data-layout-rail-bottom-left-vertical
|
|
216
|
+
class="absolute top-full left-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
217
|
+
<div
|
|
218
|
+
data-layout-rail-bottom-right-horizontal
|
|
219
|
+
class="absolute bottom-0 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
220
|
+
<div
|
|
221
|
+
data-layout-rail-bottom-right-vertical
|
|
222
|
+
class="absolute top-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
223
|
+
|
|
224
|
+
@if (showsInsetRails()) {
|
|
225
|
+
<div data-layout-horizontal-top-rail class="absolute inset-x-0 top-12 h-[1.5px] bg-border"></div>
|
|
226
|
+
<div
|
|
227
|
+
data-layout-horizontal-top-left-extension
|
|
228
|
+
class="absolute top-12 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
229
|
+
<div
|
|
230
|
+
data-layout-horizontal-top-right-extension
|
|
231
|
+
class="absolute top-12 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
232
|
+
<div data-layout-horizontal-bottom-rail class="absolute inset-x-0 bottom-12 h-[1.5px] bg-border"></div>
|
|
233
|
+
<div
|
|
234
|
+
data-layout-horizontal-bottom-left-extension
|
|
235
|
+
class="absolute bottom-12 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
236
|
+
<div
|
|
237
|
+
data-layout-horizontal-bottom-right-extension
|
|
238
|
+
class="absolute bottom-12 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
239
|
+
|
|
240
|
+
<div data-layout-vertical-left-rail class="absolute inset-y-0 -left-4 w-[1.5px] bg-border"></div>
|
|
241
|
+
<div
|
|
242
|
+
data-layout-vertical-left-top-extension
|
|
243
|
+
class="absolute bottom-full -left-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
244
|
+
<div
|
|
245
|
+
data-layout-vertical-left-bottom-extension
|
|
246
|
+
class="absolute top-full -left-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
247
|
+
<div data-layout-vertical-right-rail class="absolute inset-y-0 -right-4 w-[1.5px] bg-border"></div>
|
|
248
|
+
<div
|
|
249
|
+
data-layout-vertical-right-top-extension
|
|
250
|
+
class="absolute bottom-full -right-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
251
|
+
<div
|
|
252
|
+
data-layout-vertical-right-bottom-extension
|
|
253
|
+
class="absolute top-full -right-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
254
|
+
}
|
|
255
|
+
</div>
|
|
256
|
+
</div>
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
<div data-layout-frame [class]="frameLayerClasses()">
|
|
260
|
+
<div [class]="contentShellClasses()">
|
|
261
|
+
<ng-content />
|
|
262
|
+
</div>
|
|
263
|
+
</div>
|
|
264
|
+
</div>
|
|
265
|
+
`, isInline: true, dependencies: [{ kind: "component", type: LayoutLoadingComponent, selector: "LayoutLoading", inputs: ["class", "ariaLabel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
266
|
+
}
|
|
267
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutComponent, decorators: [{
|
|
268
|
+
type: Component,
|
|
269
|
+
args: [{
|
|
270
|
+
selector: 'Layout',
|
|
271
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
272
|
+
imports: [LayoutLoadingComponent],
|
|
273
|
+
host: {
|
|
274
|
+
'[class]': 'hostClasses()',
|
|
275
|
+
'[attr.data-surface]': 'resolvedSurface()',
|
|
276
|
+
'[attr.data-layout-appearance]': 'resolvedAppearance()',
|
|
277
|
+
'[attr.data-layout-style]': 'resolvedStyle()',
|
|
278
|
+
'[attr.data-layout-width]': 'resolvedWidth()',
|
|
279
|
+
'[attr.data-layout-type]': 'layout.type()',
|
|
280
|
+
},
|
|
281
|
+
template: `
|
|
282
|
+
<LayoutLoading />
|
|
283
|
+
|
|
284
|
+
<div data-layout-stage [class]="frameStageClasses()">
|
|
285
|
+
@if (isBorderRail()) {
|
|
286
|
+
<div
|
|
287
|
+
aria-hidden="true"
|
|
288
|
+
data-layout-rail
|
|
289
|
+
class="pointer-events-none col-start-1 row-start-1 z-0 overflow-visible">
|
|
290
|
+
<div data-layout-rail-anchor [class]="railAnchorClasses()">
|
|
291
|
+
<div
|
|
292
|
+
data-layout-rail-top-left-horizontal
|
|
293
|
+
class="absolute top-0 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
294
|
+
<div
|
|
295
|
+
data-layout-rail-top-left-vertical
|
|
296
|
+
class="absolute bottom-full left-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
297
|
+
<div
|
|
298
|
+
data-layout-rail-top-right-horizontal
|
|
299
|
+
class="absolute top-0 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
300
|
+
<div
|
|
301
|
+
data-layout-rail-top-right-vertical
|
|
302
|
+
class="absolute bottom-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
303
|
+
<div
|
|
304
|
+
data-layout-rail-bottom-left-horizontal
|
|
305
|
+
class="absolute bottom-0 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
306
|
+
<div
|
|
307
|
+
data-layout-rail-bottom-left-vertical
|
|
308
|
+
class="absolute top-full left-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
309
|
+
<div
|
|
310
|
+
data-layout-rail-bottom-right-horizontal
|
|
311
|
+
class="absolute bottom-0 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
312
|
+
<div
|
|
313
|
+
data-layout-rail-bottom-right-vertical
|
|
314
|
+
class="absolute top-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
315
|
+
|
|
316
|
+
@if (showsInsetRails()) {
|
|
317
|
+
<div data-layout-horizontal-top-rail class="absolute inset-x-0 top-12 h-[1.5px] bg-border"></div>
|
|
318
|
+
<div
|
|
319
|
+
data-layout-horizontal-top-left-extension
|
|
320
|
+
class="absolute top-12 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
321
|
+
<div
|
|
322
|
+
data-layout-horizontal-top-right-extension
|
|
323
|
+
class="absolute top-12 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
324
|
+
<div data-layout-horizontal-bottom-rail class="absolute inset-x-0 bottom-12 h-[1.5px] bg-border"></div>
|
|
325
|
+
<div
|
|
326
|
+
data-layout-horizontal-bottom-left-extension
|
|
327
|
+
class="absolute bottom-12 right-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
328
|
+
<div
|
|
329
|
+
data-layout-horizontal-bottom-right-extension
|
|
330
|
+
class="absolute bottom-12 left-full h-[1.5px] w-[calc((100vw-100%)/2)] bg-border"></div>
|
|
331
|
+
|
|
332
|
+
<div data-layout-vertical-left-rail class="absolute inset-y-0 -left-4 w-[1.5px] bg-border"></div>
|
|
333
|
+
<div
|
|
334
|
+
data-layout-vertical-left-top-extension
|
|
335
|
+
class="absolute bottom-full -left-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
336
|
+
<div
|
|
337
|
+
data-layout-vertical-left-bottom-extension
|
|
338
|
+
class="absolute top-full -left-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
339
|
+
<div data-layout-vertical-right-rail class="absolute inset-y-0 -right-4 w-[1.5px] bg-border"></div>
|
|
340
|
+
<div
|
|
341
|
+
data-layout-vertical-right-top-extension
|
|
342
|
+
class="absolute bottom-full -right-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
343
|
+
<div
|
|
344
|
+
data-layout-vertical-right-bottom-extension
|
|
345
|
+
class="absolute top-full -right-4 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
346
|
+
}
|
|
347
|
+
</div>
|
|
348
|
+
</div>
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
<div data-layout-frame [class]="frameLayerClasses()">
|
|
352
|
+
<div [class]="contentShellClasses()">
|
|
353
|
+
<ng-content />
|
|
354
|
+
</div>
|
|
355
|
+
</div>
|
|
356
|
+
</div>
|
|
357
|
+
`,
|
|
358
|
+
}]
|
|
359
|
+
}], ctorParameters: () => [], propDecorators: { surface: [{ type: i0.Input, args: [{ isSignal: true, alias: "surface", required: false }] }], appearance: [{ type: i0.Input, args: [{ isSignal: true, alias: "appearance", required: false }] }], layoutStyleAttribute: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout-style", required: false }] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
360
|
+
|
|
361
|
+
class LayoutVerticalComponent {
|
|
362
|
+
layout = inject(LayoutService);
|
|
363
|
+
class = input('', /* @ts-ignore */
|
|
364
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
365
|
+
classes = computed(() => cn('grid h-full min-h-0 w-full min-w-0 grid-cols-[auto_minmax(0,1fr)]', this.layout.appearance() === 'border-rail' ? 'overflow-visible' : 'overflow-hidden', this.class()), /* @ts-ignore */
|
|
366
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
367
|
+
constructor() {
|
|
368
|
+
this.layout.setType('vertical', { persist: false });
|
|
369
|
+
}
|
|
370
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutVerticalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
371
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: LayoutVerticalComponent, isStandalone: true, selector: "LayoutVertical", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-layout-type": "vertical" }, properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
372
|
+
}
|
|
373
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutVerticalComponent, decorators: [{
|
|
374
|
+
type: Component,
|
|
375
|
+
args: [{
|
|
376
|
+
selector: 'LayoutVertical',
|
|
377
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
378
|
+
host: {
|
|
379
|
+
'[class]': 'classes()',
|
|
380
|
+
'data-layout-type': 'vertical',
|
|
381
|
+
},
|
|
382
|
+
template: `<ng-content />`,
|
|
383
|
+
}]
|
|
384
|
+
}], ctorParameters: () => [], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
385
|
+
|
|
386
|
+
class LayoutHorizontalComponent {
|
|
387
|
+
layout = inject(LayoutService);
|
|
388
|
+
class = input('', /* @ts-ignore */
|
|
389
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
390
|
+
classes = computed(() => cn('flex h-full min-h-0 w-full min-w-0 flex-col overflow-hidden', this.class()), /* @ts-ignore */
|
|
391
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
392
|
+
constructor() {
|
|
393
|
+
this.layout.setType('horizontal', { persist: false });
|
|
394
|
+
}
|
|
395
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutHorizontalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
396
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: LayoutHorizontalComponent, isStandalone: true, selector: "LayoutHorizontal", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-layout-type": "horizontal" }, properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
397
|
+
}
|
|
398
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutHorizontalComponent, decorators: [{
|
|
399
|
+
type: Component,
|
|
400
|
+
args: [{
|
|
401
|
+
selector: 'LayoutHorizontal',
|
|
402
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
403
|
+
host: {
|
|
404
|
+
'[class]': 'classes()',
|
|
405
|
+
'data-layout-type': 'horizontal',
|
|
406
|
+
},
|
|
407
|
+
template: `<ng-content />`,
|
|
408
|
+
}]
|
|
409
|
+
}], ctorParameters: () => [], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
410
|
+
|
|
411
|
+
class LayoutEmptyComponent {
|
|
412
|
+
layout = inject(LayoutService);
|
|
413
|
+
class = input('', /* @ts-ignore */
|
|
414
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
415
|
+
classes = computed(() => cn('h-full min-h-0 w-full min-w-0 overflow-hidden', this.class()), /* @ts-ignore */
|
|
416
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
417
|
+
constructor() {
|
|
418
|
+
this.layout.setType('empty', { persist: false });
|
|
419
|
+
}
|
|
420
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutEmptyComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
421
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: LayoutEmptyComponent, isStandalone: true, selector: "LayoutEmpty", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-layout-type": "empty" }, properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
422
|
+
}
|
|
423
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutEmptyComponent, decorators: [{
|
|
424
|
+
type: Component,
|
|
425
|
+
args: [{
|
|
426
|
+
selector: 'LayoutEmpty',
|
|
427
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
428
|
+
host: {
|
|
429
|
+
'[class]': 'classes()',
|
|
430
|
+
'data-layout-type': 'empty',
|
|
431
|
+
},
|
|
432
|
+
template: `<ng-content />`,
|
|
433
|
+
}]
|
|
434
|
+
}], ctorParameters: () => [], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
435
|
+
|
|
436
|
+
class LayoutFluidComponent {
|
|
437
|
+
layout = inject(LayoutService);
|
|
438
|
+
class = input('', /* @ts-ignore */
|
|
439
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
440
|
+
classes = computed(() => cn('grid min-h-0 min-w-0 place-items-center overflow-auto', this.layout.width() === 'fluid' ? 'h-auto w-auto max-h-full max-w-full' : 'h-full w-full', this.class()), /* @ts-ignore */
|
|
441
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
442
|
+
constructor() {
|
|
443
|
+
this.layout.setType('fluid', { persist: false });
|
|
444
|
+
}
|
|
445
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutFluidComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
446
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: LayoutFluidComponent, isStandalone: true, selector: "LayoutFluid", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-layout-type": "fluid" }, properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
447
|
+
}
|
|
448
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutFluidComponent, decorators: [{
|
|
449
|
+
type: Component,
|
|
450
|
+
args: [{
|
|
451
|
+
selector: 'LayoutFluid',
|
|
452
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
453
|
+
host: {
|
|
454
|
+
'[class]': 'classes()',
|
|
455
|
+
'data-layout-type': 'fluid',
|
|
456
|
+
},
|
|
457
|
+
template: `<ng-content />`,
|
|
458
|
+
}]
|
|
459
|
+
}], ctorParameters: () => [], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
460
|
+
|
|
461
|
+
class LayoutNavigationComponent {
|
|
462
|
+
layout = inject(LayoutService);
|
|
463
|
+
projectedNav = contentChild(NavigationContainerComponent, /* @ts-ignore */
|
|
464
|
+
...(ngDevMode ? [{ debugName: "projectedNav" }] : /* istanbul ignore next */ []));
|
|
465
|
+
ariaLabel = input('Layout navigation', /* @ts-ignore */
|
|
466
|
+
...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
467
|
+
railOffset = input(null, /* @ts-ignore */
|
|
468
|
+
...(ngDevMode ? [{ debugName: "railOffset" }] : /* istanbul ignore next */ []));
|
|
469
|
+
class = input('', /* @ts-ignore */
|
|
470
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
471
|
+
showsVerticalRail = computed(() => this.layout.type() === 'vertical' && this.layout.appearance() === 'border-rail', /* @ts-ignore */
|
|
472
|
+
...(ngDevMode ? [{ debugName: "showsVerticalRail" }] : /* istanbul ignore next */ []));
|
|
473
|
+
resolvedRailOffset = computed(() => this.railOffset() ?? this.projectedNav()?.previewRailOffset() ?? '0px', /* @ts-ignore */
|
|
474
|
+
...(ngDevMode ? [{ debugName: "resolvedRailOffset" }] : /* istanbul ignore next */ []));
|
|
475
|
+
railTransform = computed(() => `translateX(${this.resolvedRailOffset()})`, /* @ts-ignore */
|
|
476
|
+
...(ngDevMode ? [{ debugName: "railTransform" }] : /* istanbul ignore next */ []));
|
|
477
|
+
classes = computed(() => {
|
|
478
|
+
const layoutType = this.layout.type();
|
|
479
|
+
return cn('relative block min-h-0 min-w-0', layoutType === 'horizontal' && 'h-12 min-h-12 w-full shrink-0 overflow-visible',
|
|
480
|
+
// overflow-visible: clipping diatur host <Navigation>; overlay nav (aside
|
|
481
|
+
// drawer dockbar, preview rail) keluar dari kolom w-16 dan overflow-hidden
|
|
482
|
+
// di sini ikut ter-scroll oleh focus scroll-into-view sehingga rail hilang.
|
|
483
|
+
layoutType === 'vertical' && 'h-full w-max max-w-full shrink-0 overflow-visible', layoutType === 'empty' && 'hidden', this.class());
|
|
484
|
+
}, /* @ts-ignore */
|
|
485
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
486
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutNavigationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
487
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.2", type: LayoutNavigationComponent, isStandalone: true, selector: "LayoutNavigation", inputs: { ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, railOffset: { classPropertyName: "railOffset", publicName: "railOffset", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "navigation" }, properties: { "class": "classes()", "attr.aria-label": "ariaLabel() || null", "attr.data-layout-type": "layout.type()", "attr.data-layout-appearance": "layout.appearance()", "attr.data-layout-style": "layout.appearance()", "attr.data-layout-nav-rail-offset": "resolvedRailOffset()" } }, queries: [{ propertyName: "projectedNav", first: true, predicate: NavigationContainerComponent, descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
488
|
+
@if (showsVerticalRail()) {
|
|
489
|
+
<div
|
|
490
|
+
aria-hidden="true"
|
|
491
|
+
data-layout-nav-rail
|
|
492
|
+
class="pointer-events-none absolute inset-y-0 right-0 z-20 w-[1.5px] transition-transform duration-300 ease-[cubic-bezier(0.22,1,0.36,1)] motion-reduce:transition-none"
|
|
493
|
+
[style.transform]="railTransform()">
|
|
494
|
+
<div data-layout-nav-rail-line class="absolute inset-y-0 right-0 w-[1.5px] bg-border"></div>
|
|
495
|
+
<div
|
|
496
|
+
data-layout-nav-rail-top
|
|
497
|
+
class="absolute bottom-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
498
|
+
<div
|
|
499
|
+
data-layout-nav-rail-bottom
|
|
500
|
+
class="absolute top-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
501
|
+
</div>
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
<ng-content />
|
|
505
|
+
`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
506
|
+
}
|
|
507
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutNavigationComponent, decorators: [{
|
|
508
|
+
type: Component,
|
|
509
|
+
args: [{
|
|
510
|
+
selector: 'LayoutNavigation',
|
|
511
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
512
|
+
host: {
|
|
513
|
+
'[class]': 'classes()',
|
|
514
|
+
role: 'navigation',
|
|
515
|
+
'[attr.aria-label]': 'ariaLabel() || null',
|
|
516
|
+
'[attr.data-layout-type]': 'layout.type()',
|
|
517
|
+
'[attr.data-layout-appearance]': 'layout.appearance()',
|
|
518
|
+
'[attr.data-layout-style]': 'layout.appearance()',
|
|
519
|
+
'[attr.data-layout-nav-rail-offset]': 'resolvedRailOffset()',
|
|
520
|
+
},
|
|
521
|
+
template: `
|
|
522
|
+
@if (showsVerticalRail()) {
|
|
523
|
+
<div
|
|
524
|
+
aria-hidden="true"
|
|
525
|
+
data-layout-nav-rail
|
|
526
|
+
class="pointer-events-none absolute inset-y-0 right-0 z-20 w-[1.5px] transition-transform duration-300 ease-[cubic-bezier(0.22,1,0.36,1)] motion-reduce:transition-none"
|
|
527
|
+
[style.transform]="railTransform()">
|
|
528
|
+
<div data-layout-nav-rail-line class="absolute inset-y-0 right-0 w-[1.5px] bg-border"></div>
|
|
529
|
+
<div
|
|
530
|
+
data-layout-nav-rail-top
|
|
531
|
+
class="absolute bottom-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
532
|
+
<div
|
|
533
|
+
data-layout-nav-rail-bottom
|
|
534
|
+
class="absolute top-full right-0 h-[calc((100dvh-100%)/2)] w-[1.5px] bg-border"></div>
|
|
535
|
+
</div>
|
|
536
|
+
}
|
|
537
|
+
|
|
538
|
+
<ng-content />
|
|
539
|
+
`,
|
|
540
|
+
}]
|
|
541
|
+
}], propDecorators: { projectedNav: [{ type: i0.ContentChild, args: [i0.forwardRef(() => NavigationContainerComponent), { isSignal: true }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], railOffset: [{ type: i0.Input, args: [{ isSignal: true, alias: "railOffset", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
542
|
+
|
|
543
|
+
class LayoutContentComponent {
|
|
544
|
+
layout = inject(LayoutService);
|
|
545
|
+
class = input('', /* @ts-ignore */
|
|
546
|
+
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
547
|
+
classes = computed(() => {
|
|
548
|
+
const layoutType = this.layout.type();
|
|
549
|
+
return cn('block min-h-0 min-w-0 overflow-auto', layoutType === 'horizontal' && 'flex-1', layoutType === 'vertical' && 'h-full', layoutType === 'empty' && 'h-full w-full', this.layout.width() === 'container' && 'w-full lg:container lg:mx-auto', this.class());
|
|
550
|
+
}, /* @ts-ignore */
|
|
551
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
552
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
553
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: LayoutContentComponent, isStandalone: true, selector: "LayoutContent", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-layout-type": "layout.type()", "attr.data-layout-width": "layout.width()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
554
|
+
}
|
|
555
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: LayoutContentComponent, decorators: [{
|
|
556
|
+
type: Component,
|
|
557
|
+
args: [{
|
|
558
|
+
selector: 'LayoutContent',
|
|
559
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
560
|
+
host: {
|
|
561
|
+
'[class]': 'classes()',
|
|
562
|
+
'[attr.data-layout-type]': 'layout.type()',
|
|
563
|
+
'[attr.data-layout-width]': 'layout.width()',
|
|
564
|
+
},
|
|
565
|
+
template: `<ng-content />`,
|
|
566
|
+
}]
|
|
567
|
+
}], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
568
|
+
|
|
569
|
+
/**
|
|
570
|
+
* Generated bundle index. Do not edit.
|
|
571
|
+
*/
|
|
572
|
+
|
|
573
|
+
export { LayoutComponent, LayoutContentComponent, LayoutEmptyComponent, LayoutFluidComponent, LayoutHorizontalComponent, LayoutLoadingComponent, LayoutNavigationComponent, LayoutVerticalComponent };
|
|
574
|
+
//# sourceMappingURL=ojiepermana-angular-theme-layout.mjs.map
|