@ifsworld/granite-components 16.0.0 → 16.1.0-beta.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/fesm2022/ifsworld-granite-components.mjs +82 -10
- package/fesm2022/ifsworld-granite-components.mjs.map +1 -1
- package/index.d.ts +1 -0
- package/lib/menu/menu-base.d.ts +8 -2
- package/lib/menu/menu-custom-template.directive.d.ts +14 -0
- package/lib/menu/menu.module.d.ts +6 -5
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -17,6 +17,7 @@ export * from './lib/menu/divider.directive';
|
|
|
17
17
|
export * from './lib/menu/title.directive';
|
|
18
18
|
export * from './lib/menu/menu-touch-close.component';
|
|
19
19
|
export * from './lib/menu/menu-touch-title.component';
|
|
20
|
+
export * from './lib/menu/menu-custom-template.directive';
|
|
20
21
|
export * from './lib/icon/icon.module';
|
|
21
22
|
export * from './lib/icon/icon.component';
|
|
22
23
|
export * from './lib/toggle-switch/toggle-switch.module';
|
package/lib/menu/menu-base.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ import { ClientInputInterface, ClientOutputInterface } from '../core/client-envi
|
|
|
7
7
|
import { GraniteMenuItemComponent } from './menu-item.component';
|
|
8
8
|
import { ClosedEventType, OpenedEventType, GraniteMenuPanelInterface } from './menu-panel';
|
|
9
9
|
import { MenuPositionX, MenuPositionY } from './menu-positions';
|
|
10
|
+
import { GraniteMenuCustomTemplateDirective } from './menu-custom-template.directive';
|
|
10
11
|
import * as i0 from "@angular/core";
|
|
11
12
|
/** Menu panel animation states */
|
|
12
13
|
type TransformMenuStates = 'void' | 'enter' | 'enter-from-below' | 'below-with-delay' | 'below' | 'pan' | 'hide' | 'pan-hidden';
|
|
@@ -61,6 +62,11 @@ export declare class _MenuBaseComponent implements AfterContentInit, OnDestroy,
|
|
|
61
62
|
* Event emitted when the menu is opened
|
|
62
63
|
*/
|
|
63
64
|
readonly opened: EventEmitter<OpenedEventType>;
|
|
65
|
+
/**
|
|
66
|
+
* Reference to the custom template directive if present
|
|
67
|
+
*/
|
|
68
|
+
customTemplate: GraniteMenuCustomTemplateDirective;
|
|
69
|
+
preventParentClose: boolean;
|
|
64
70
|
/**
|
|
65
71
|
* Used for locating the panel in tests and setting the aria-control attribute
|
|
66
72
|
* for the menu trigger.
|
|
@@ -173,7 +179,7 @@ export declare class _MenuBaseComponent implements AfterContentInit, OnDestroy,
|
|
|
173
179
|
* Handle click on the menu by emitting on the `closed` emitter
|
|
174
180
|
* with a `click` reason
|
|
175
181
|
*/
|
|
176
|
-
_handleClick(): void;
|
|
182
|
+
_handleClick(event?: Event): void;
|
|
177
183
|
/**
|
|
178
184
|
* Handle click on the close button by emitting on the `closed` emitter
|
|
179
185
|
* without any particular reason
|
|
@@ -200,6 +206,6 @@ export declare class _MenuBaseComponent implements AfterContentInit, OnDestroy,
|
|
|
200
206
|
*/
|
|
201
207
|
private _updateDirectDescendants;
|
|
202
208
|
static ɵfac: i0.ɵɵFactoryDeclaration<_MenuBaseComponent, never>;
|
|
203
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<_MenuBaseComponent, never, never, { "xPosition": { "alias": "xPosition"; "required": false; }; "yPosition": { "alias": "yPosition"; "required": false; }; "title": { "alias": "title"; "required": false; }; "closeLabel": { "alias": "closeLabel"; "required": false; }; "openOnHover": { "alias": "openOnHover"; "required": false; }; "scrollStrategy": { "alias": "scrollStrategy"; "required": false; }; "styles": { "alias": "styles"; "required": false; }; "touchStyles": { "alias": "touchStyles"; "required": false; }; }, { "closed": "closed"; "opened": "opened"; }, ["_allItems"], never, true, never>;
|
|
209
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<_MenuBaseComponent, never, never, { "xPosition": { "alias": "xPosition"; "required": false; }; "yPosition": { "alias": "yPosition"; "required": false; }; "title": { "alias": "title"; "required": false; }; "closeLabel": { "alias": "closeLabel"; "required": false; }; "openOnHover": { "alias": "openOnHover"; "required": false; }; "scrollStrategy": { "alias": "scrollStrategy"; "required": false; }; "styles": { "alias": "styles"; "required": false; }; "touchStyles": { "alias": "touchStyles"; "required": false; }; "preventParentClose": { "alias": "preventParentClose"; "required": false; }; }, { "closed": "closed"; "opened": "opened"; }, ["customTemplate", "_allItems"], never, true, never>;
|
|
204
210
|
}
|
|
205
211
|
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ElementRef } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* Directive to mark an element as a custom template area within a menu.
|
|
5
|
+
* This allows inserting custom content (dropdowns, inputs, etc.) anywhere
|
|
6
|
+
* within the menu, maintaining the natural DOM order.
|
|
7
|
+
*/
|
|
8
|
+
export declare class GraniteMenuCustomTemplateDirective {
|
|
9
|
+
private _elementRef;
|
|
10
|
+
constructor(_elementRef: ElementRef<HTMLElement>);
|
|
11
|
+
_handleEvent(event: Event): void;
|
|
12
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<GraniteMenuCustomTemplateDirective, never>;
|
|
13
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<GraniteMenuCustomTemplateDirective, "[graniteMenuCustomTemplate]", ["graniteMenuCustomTemplate"], {}, {}, never, never, false, never>;
|
|
14
|
+
}
|
|
@@ -6,12 +6,13 @@ import * as i4 from "./menu-touch-close.component";
|
|
|
6
6
|
import * as i5 from "./menu-touch-title.component";
|
|
7
7
|
import * as i6 from "./divider.directive";
|
|
8
8
|
import * as i7 from "./title.directive";
|
|
9
|
-
import * as i8 from "
|
|
10
|
-
import * as i9 from "@angular/
|
|
11
|
-
import * as i10 from "@angular/cdk/
|
|
12
|
-
import * as i11 from "
|
|
9
|
+
import * as i8 from "./menu-custom-template.directive";
|
|
10
|
+
import * as i9 from "@angular/common";
|
|
11
|
+
import * as i10 from "@angular/cdk/overlay";
|
|
12
|
+
import * as i11 from "@angular/cdk/portal";
|
|
13
|
+
import * as i12 from "../icon/icon.module";
|
|
13
14
|
export declare class GraniteMenuModule {
|
|
14
15
|
static ɵfac: i0.ɵɵFactoryDeclaration<GraniteMenuModule, never>;
|
|
15
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<GraniteMenuModule, [typeof i1.GraniteMenuComponent, typeof i2.GraniteMenuItemComponent, typeof i3.GraniteMenuTriggerForDirective, typeof i4.GraniteMenuTouchCloseComponent, typeof i5.GraniteMenuTouchTitleItemComponent, typeof i6.GraniteDividerDirective, typeof i7.GraniteTitleDirective], [typeof
|
|
16
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<GraniteMenuModule, [typeof i1.GraniteMenuComponent, typeof i2.GraniteMenuItemComponent, typeof i3.GraniteMenuTriggerForDirective, typeof i4.GraniteMenuTouchCloseComponent, typeof i5.GraniteMenuTouchTitleItemComponent, typeof i6.GraniteDividerDirective, typeof i7.GraniteTitleDirective, typeof i8.GraniteMenuCustomTemplateDirective], [typeof i9.CommonModule, typeof i10.OverlayModule, typeof i11.PortalModule, typeof i12.GraniteIconModule], [typeof i1.GraniteMenuComponent, typeof i2.GraniteMenuItemComponent, typeof i3.GraniteMenuTriggerForDirective, typeof i4.GraniteMenuTouchCloseComponent, typeof i5.GraniteMenuTouchTitleItemComponent, typeof i6.GraniteDividerDirective, typeof i7.GraniteTitleDirective, typeof i8.GraniteMenuCustomTemplateDirective]>;
|
|
16
17
|
static ɵinj: i0.ɵɵInjectorDeclaration<GraniteMenuModule>;
|
|
17
18
|
}
|