@recursyve/nice-ui-kit.v2 13.2.0-beta.109 → 13.2.0-beta.111
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/esm2020/lib/components/assets-carousel/assets-carousel.component.mjs +16 -11
- package/esm2020/lib/components/navigation/directives/show-hint.directive.mjs +164 -0
- package/esm2020/lib/components/navigation/navigation.module.mjs +9 -3
- package/esm2020/lib/components/navigation/navigation.types.mjs +1 -1
- package/esm2020/lib/components/navigation/pipes/should-show-hint.pipe.mjs +32 -0
- package/esm2020/lib/components/navigation/providers/hint.resolver.mjs +3 -0
- package/esm2020/lib/components/navigation/vertical/components/basic/basic.component.mjs +6 -4
- package/esm2020/lib/components/navigation/vertical/components/collapsable/collapsable.component.mjs +5 -4
- package/fesm2015/recursyve-nice-ui-kit.v2.mjs +210 -17
- package/fesm2015/recursyve-nice-ui-kit.v2.mjs.map +1 -1
- package/fesm2020/recursyve-nice-ui-kit.v2.mjs +209 -17
- package/fesm2020/recursyve-nice-ui-kit.v2.mjs.map +1 -1
- package/lib/components/assets-carousel/assets-carousel.component.d.ts +2 -1
- package/lib/components/navigation/directives/show-hint.directive.d.ts +34 -0
- package/lib/components/navigation/navigation.module.d.ts +12 -10
- package/lib/components/navigation/navigation.types.d.ts +6 -0
- package/lib/components/navigation/pipes/should-show-hint.pipe.d.ts +12 -0
- package/lib/components/navigation/providers/hint.resolver.d.ts +4 -0
- package/package.json +1 -1
- package/src/lib/components/assets-carousel/assets-carousel.theme.scss +15 -7
- package/src/lib/components/navigation/vertical/styles/appearances/default.theme.scss +38 -0
|
@@ -49,6 +49,7 @@ export declare class NiceAssetsCarouselComponent implements ControlValueAccessor
|
|
|
49
49
|
accept: string[];
|
|
50
50
|
customActions: NiceAssetsCarouselActions[];
|
|
51
51
|
multipleUpload: boolean;
|
|
52
|
+
visiblePreviewAsset: number;
|
|
52
53
|
showAddAssetContainer: boolean;
|
|
53
54
|
activeChange: EventEmitter<number>;
|
|
54
55
|
removedAsset: EventEmitter<NiceAssets>;
|
|
@@ -75,5 +76,5 @@ export declare class NiceAssetsCarouselComponent implements ControlValueAccessor
|
|
|
75
76
|
clickCustom(action: NiceAssetsCarouselActions): void;
|
|
76
77
|
startSyncVideo(): Promise<void>;
|
|
77
78
|
static ɵfac: i0.ɵɵFactoryDeclaration<NiceAssetsCarouselComponent, [{ optional: true; }]>;
|
|
78
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<NiceAssetsCarouselComponent, "nice-assets-carousel", never, { "color": "color"; "edit": "edit"; "accept": "accept"; "customActions": "customActions"; "multipleUpload": "multipleUpload"; "showAddAssetContainer": "showAddAssetContainer"; "assets": "assets"; }, { "activeChange": "activeChange"; "removedAsset": "removedAsset"; }, never, never>;
|
|
79
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NiceAssetsCarouselComponent, "nice-assets-carousel", never, { "color": "color"; "edit": "edit"; "accept": "accept"; "customActions": "customActions"; "multipleUpload": "multipleUpload"; "visiblePreviewAsset": "visiblePreviewAsset"; "showAddAssetContainer": "showAddAssetContainer"; "assets": "assets"; }, { "activeChange": "activeChange"; "removedAsset": "removedAsset"; }, never, never>;
|
|
79
80
|
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { Overlay } from "@angular/cdk/overlay";
|
|
2
|
+
import { Platform } from "@angular/cdk/platform";
|
|
3
|
+
import { AfterViewInit, ElementRef, NgZone, OnDestroy, ViewContainerRef } from "@angular/core";
|
|
4
|
+
import { NiceNavigationItem } from "../navigation.types";
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
export declare class NiceShowHintDirective implements AfterViewInit, OnDestroy {
|
|
7
|
+
private _overlay;
|
|
8
|
+
private _elementRef;
|
|
9
|
+
private _viewContainerRef;
|
|
10
|
+
private _ngZone;
|
|
11
|
+
private _platform;
|
|
12
|
+
shouldShow: boolean;
|
|
13
|
+
item: NiceNavigationItem;
|
|
14
|
+
private _pointerExitEventsInitialized;
|
|
15
|
+
private _portal;
|
|
16
|
+
private _hintInstance;
|
|
17
|
+
private _overlayRef;
|
|
18
|
+
private readonly _passiveListeners;
|
|
19
|
+
private readonly unsubscribeAll$;
|
|
20
|
+
constructor(_overlay: Overlay, _elementRef: ElementRef<HTMLElement>, _viewContainerRef: ViewContainerRef, _ngZone: NgZone, _platform: Platform);
|
|
21
|
+
ngAfterViewInit(): void;
|
|
22
|
+
ngOnDestroy(): void;
|
|
23
|
+
show(): void;
|
|
24
|
+
hide(): void;
|
|
25
|
+
private _createOverlay;
|
|
26
|
+
private _detach;
|
|
27
|
+
private _isHintVisible;
|
|
28
|
+
private _setupPointerEnterEventsIfNeeded;
|
|
29
|
+
private _setupPointerExitEventsIfNeeded;
|
|
30
|
+
private _platformSupportsMouseEvents;
|
|
31
|
+
private _addListeners;
|
|
32
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NiceShowHintDirective, never>;
|
|
33
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<NiceShowHintDirective, "[niceShowHint]", never, { "shouldShow": "shouldShow"; "item": "item"; }, {}, never>;
|
|
34
|
+
}
|
|
@@ -12,17 +12,19 @@ import * as i10 from "./vertical/components/divider/divider.component";
|
|
|
12
12
|
import * as i11 from "./vertical/components/group/group.component";
|
|
13
13
|
import * as i12 from "./vertical/components/spacer/spacer.component";
|
|
14
14
|
import * as i13 from "./vertical/vertical.component";
|
|
15
|
-
import * as i14 from "
|
|
16
|
-
import * as i15 from "
|
|
17
|
-
import * as i16 from "@angular/
|
|
18
|
-
import * as i17 from "@angular/
|
|
19
|
-
import * as i18 from "@angular/material/
|
|
20
|
-
import * as i19 from "@angular/material/
|
|
21
|
-
import * as i20 from "@angular/material/
|
|
22
|
-
import * as i21 from "
|
|
23
|
-
import * as i22 from "@
|
|
15
|
+
import * as i14 from "./pipes/should-show-hint.pipe";
|
|
16
|
+
import * as i15 from "./directives/show-hint.directive";
|
|
17
|
+
import * as i16 from "@angular/common";
|
|
18
|
+
import * as i17 from "@angular/router";
|
|
19
|
+
import * as i18 from "@angular/material/button";
|
|
20
|
+
import * as i19 from "@angular/material/divider";
|
|
21
|
+
import * as i20 from "@angular/material/icon";
|
|
22
|
+
import * as i21 from "@angular/material/menu";
|
|
23
|
+
import * as i22 from "@angular/material/tooltip";
|
|
24
|
+
import * as i23 from "../../directives/scrollbar/scrollbar.module";
|
|
25
|
+
import * as i24 from "@ngx-translate/core";
|
|
24
26
|
export declare class NiceNavigationModule {
|
|
25
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<NiceNavigationModule, never>;
|
|
26
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<NiceNavigationModule, [typeof i1.NiceNavigationComponent, typeof i2.NiceHorizontalNavigationBasicItemComponent, typeof i3.NiceHorizontalNavigationBranchItemComponent, typeof i4.NiceHorizontalNavigationDividerItemComponent, typeof i5.NiceHorizontalNavigationSpacerItemComponent, typeof i6.NiceHorizontalNavigationComponent, typeof i7.NiceVerticalNavigationAsideItemComponent, typeof i8.NiceVerticalNavigationBasicItemComponent, typeof i9.NiceVerticalNavigationCollapsableItemComponent, typeof i10.NiceVerticalNavigationDividerItemComponent, typeof i11.NiceVerticalNavigationGroupItemComponent, typeof i12.NiceVerticalNavigationSpacerItemComponent, typeof i13.NiceVerticalNavigationComponent], [typeof
|
|
28
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<NiceNavigationModule, [typeof i1.NiceNavigationComponent, typeof i2.NiceHorizontalNavigationBasicItemComponent, typeof i3.NiceHorizontalNavigationBranchItemComponent, typeof i4.NiceHorizontalNavigationDividerItemComponent, typeof i5.NiceHorizontalNavigationSpacerItemComponent, typeof i6.NiceHorizontalNavigationComponent, typeof i7.NiceVerticalNavigationAsideItemComponent, typeof i8.NiceVerticalNavigationBasicItemComponent, typeof i9.NiceVerticalNavigationCollapsableItemComponent, typeof i10.NiceVerticalNavigationDividerItemComponent, typeof i11.NiceVerticalNavigationGroupItemComponent, typeof i12.NiceVerticalNavigationSpacerItemComponent, typeof i13.NiceVerticalNavigationComponent, typeof i14.NiceShouldShowHintPipe, typeof i15.NiceShowHintDirective], [typeof i16.CommonModule, typeof i17.RouterModule, typeof i18.MatButtonModule, typeof i19.MatDividerModule, typeof i20.MatIconModule, typeof i21.MatMenuModule, typeof i22.MatTooltipModule, typeof i23.NiceScrollbarModule, typeof i24.TranslateModule], [typeof i6.NiceHorizontalNavigationComponent, typeof i13.NiceVerticalNavigationComponent]>;
|
|
27
29
|
static ɵinj: i0.ɵɵInjectorDeclaration<NiceNavigationModule>;
|
|
28
30
|
}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { Type } from "@angular/core";
|
|
2
|
+
import { NavigationHintResolver } from "./providers/hint.resolver";
|
|
1
3
|
export declare type IconType = "fontawesome" | "material" | "svg";
|
|
2
4
|
export interface NiceNavigationItem {
|
|
3
5
|
id?: string;
|
|
@@ -28,6 +30,10 @@ export interface NiceNavigationItem {
|
|
|
28
30
|
};
|
|
29
31
|
children?: NiceNavigationItem[];
|
|
30
32
|
meta?: any;
|
|
33
|
+
hint?: {
|
|
34
|
+
resolver: Type<NavigationHintResolver>;
|
|
35
|
+
component: Type<any>;
|
|
36
|
+
};
|
|
31
37
|
}
|
|
32
38
|
export declare type NiceVerticalNavigationAppearance = "default" | "compact" | "dense" | "thin";
|
|
33
39
|
export declare type NiceVerticalNavigationMode = "over" | "side";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Injector, PipeTransform } from "@angular/core";
|
|
2
|
+
import { Observable } from "rxjs";
|
|
3
|
+
import { NiceNavigationItem } from "../navigation.types";
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export declare class NiceShouldShowHintPipe implements PipeTransform {
|
|
6
|
+
private injector;
|
|
7
|
+
constructor(injector: Injector);
|
|
8
|
+
transform(value: NiceNavigationItem | NiceNavigationItem[]): Observable<boolean>;
|
|
9
|
+
private transformHint;
|
|
10
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NiceShouldShowHintPipe, never>;
|
|
11
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<NiceShouldShowHintPipe, "niceShouldShowHint">;
|
|
12
|
+
}
|
package/package.json
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
@use "../../nice.utils" as nice;
|
|
2
2
|
|
|
3
|
+
/* Variables */
|
|
4
|
+
:root {
|
|
5
|
+
--nice-assets-carousel-asset-width: 90px;
|
|
6
|
+
--nice-assets-carousel-asset-height: 60px;
|
|
7
|
+
--nice-assets-carousel-asset-gap: 0.75rem;
|
|
8
|
+
}
|
|
9
|
+
|
|
3
10
|
@mixin nice-assets-carousel-theme($theme) {
|
|
4
11
|
nice-assets-carousel {
|
|
5
12
|
.carousel-container {
|
|
@@ -50,6 +57,7 @@
|
|
|
50
57
|
.asset-list {
|
|
51
58
|
@apply flex flex-row;
|
|
52
59
|
|
|
60
|
+
gap: var(--nice-assets-carousel-asset-gap);
|
|
53
61
|
transition: transform 500ms cubic-bezier(0.35, 0, 0.25, 1);
|
|
54
62
|
}
|
|
55
63
|
}
|
|
@@ -64,7 +72,7 @@
|
|
|
64
72
|
}
|
|
65
73
|
|
|
66
74
|
image, img, video {
|
|
67
|
-
@apply w-full h-full select-none object-cover
|
|
75
|
+
@apply w-full h-full select-none object-cover;
|
|
68
76
|
}
|
|
69
77
|
|
|
70
78
|
.action-button {
|
|
@@ -131,8 +139,8 @@
|
|
|
131
139
|
.add-asset-container {
|
|
132
140
|
@apply bg-default z-50 cursor-pointer select-none mr-3;
|
|
133
141
|
|
|
134
|
-
min-width:
|
|
135
|
-
min-height:
|
|
142
|
+
min-width: var(--nice-assets-carousel-asset-width);
|
|
143
|
+
min-height: var(--nice-assets-carousel-asset-height);
|
|
136
144
|
|
|
137
145
|
.add-asset {
|
|
138
146
|
@apply h-full w-full flex justify-center items-center border border-white border-solid rounded;
|
|
@@ -144,13 +152,13 @@
|
|
|
144
152
|
}
|
|
145
153
|
|
|
146
154
|
.asset {
|
|
147
|
-
width:
|
|
148
|
-
height:
|
|
155
|
+
width: var(--nice-assets-carousel-asset-width);
|
|
156
|
+
height: var(--nice-assets-carousel-asset-height);
|
|
149
157
|
|
|
150
|
-
@apply rounded
|
|
158
|
+
@apply rounded cursor-pointer overflow-hidden border border-transparent;
|
|
151
159
|
|
|
152
160
|
&.active {
|
|
153
|
-
@apply border
|
|
161
|
+
@apply border-opacity-100 #{!important};
|
|
154
162
|
|
|
155
163
|
&.primary {
|
|
156
164
|
@apply border-primary;
|
|
@@ -240,6 +240,14 @@
|
|
|
240
240
|
opacity: 0.4;
|
|
241
241
|
}
|
|
242
242
|
|
|
243
|
+
.nice-vertical-navigation-item-icon-wrapper {
|
|
244
|
+
position: relative;
|
|
245
|
+
|
|
246
|
+
.nice-vertical-navigation-hint {
|
|
247
|
+
display: none;
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
|
|
243
251
|
.nice-vertical-navigation-item-icon {
|
|
244
252
|
margin-right: 16px;
|
|
245
253
|
|
|
@@ -254,6 +262,20 @@
|
|
|
254
262
|
}
|
|
255
263
|
|
|
256
264
|
.nice-vertical-navigation-item-title-wrapper {
|
|
265
|
+
.nice-vertical-navigation-item-title {
|
|
266
|
+
position: relative;
|
|
267
|
+
|
|
268
|
+
span {
|
|
269
|
+
padding: 16px;
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
.nice-vertical-navigation-hint {
|
|
274
|
+
width: 8px;
|
|
275
|
+
height: 8px;
|
|
276
|
+
top: -4px;
|
|
277
|
+
right: 4px
|
|
278
|
+
}
|
|
257
279
|
|
|
258
280
|
.nice-vertical-navigation-item-subtitle {
|
|
259
281
|
font-size: 11px;
|
|
@@ -481,6 +503,9 @@
|
|
|
481
503
|
nice-vertical-navigation-basic-item,
|
|
482
504
|
nice-vertical-navigation-collapsable-item,
|
|
483
505
|
nice-vertical-navigation-group-item {
|
|
506
|
+
.nice-vertical-navigation-hint {
|
|
507
|
+
@apply absolute h-2 w-2 rounded-full bg-accent;
|
|
508
|
+
}
|
|
484
509
|
|
|
485
510
|
.nice-vertical-navigation-item-wrapper {
|
|
486
511
|
|
|
@@ -602,4 +627,17 @@
|
|
|
602
627
|
}
|
|
603
628
|
}
|
|
604
629
|
}
|
|
630
|
+
|
|
631
|
+
nice-vertical-navigation {
|
|
632
|
+
&.nice-vertical-navigation-appearance-dense:not(.nice-vertical-navigation-hover) {
|
|
633
|
+
.nice-vertical-navigation-hint {
|
|
634
|
+
display: block !important;
|
|
635
|
+
|
|
636
|
+
width: 8px;
|
|
637
|
+
height: 8px;
|
|
638
|
+
top: -4px;
|
|
639
|
+
right: 8px
|
|
640
|
+
}
|
|
641
|
+
}
|
|
642
|
+
}
|
|
605
643
|
}
|