@gravitee/ui-particles-angular 4.11.1-302-breadcrumb-2caef66 → 4.11.1-302-breadcrumb-6e72b91

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (21) hide show
  1. package/bundles/gravitee-ui-particles-angular.umd.js +25 -80
  2. package/bundles/gravitee-ui-particles-angular.umd.js.map +1 -1
  3. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb-item/gio-breadcrumb-item.directive.js +28 -0
  4. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb.component.js +16 -16
  5. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb.module.js +5 -6
  6. package/esm2015/lib/gio-breadcrumb/index.js +2 -5
  7. package/fesm2015/gravitee-ui-particles-angular.js +24 -91
  8. package/fesm2015/gravitee-ui-particles-angular.js.map +1 -1
  9. package/lib/gio-breadcrumb/gio-breadcrumb-item/gio-breadcrumb-item.directive.d.ts +5 -0
  10. package/lib/gio-breadcrumb/gio-breadcrumb.component.d.ts +6 -7
  11. package/lib/gio-breadcrumb/gio-breadcrumb.module.d.ts +4 -5
  12. package/lib/gio-breadcrumb/index.d.ts +1 -4
  13. package/package.json +1 -1
  14. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb-item/GioBreadcrumbItem.js +0 -2
  15. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb-item/GioBreadcrumbItemDynamicComponent.js +0 -2
  16. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb-item/gio-breadcrumb-dynamic-item.directive.js +0 -31
  17. package/esm2015/lib/gio-breadcrumb/gio-breadcrumb-item/gio-breadcrumb-item.component.js +0 -71
  18. package/lib/gio-breadcrumb/gio-breadcrumb-item/GioBreadcrumbItem.d.ts +0 -8
  19. package/lib/gio-breadcrumb/gio-breadcrumb-item/GioBreadcrumbItemDynamicComponent.d.ts +0 -3
  20. package/lib/gio-breadcrumb/gio-breadcrumb-item/gio-breadcrumb-dynamic-item.directive.d.ts +0 -8
  21. package/lib/gio-breadcrumb/gio-breadcrumb-item/gio-breadcrumb-item.component.d.ts +0 -16
@@ -3509,77 +3509,19 @@
3509
3509
  * See the License for the specific language governing permissions and
3510
3510
  * limitations under the License.
3511
3511
  */
3512
- var GioBreadcrumbDynamicItemDirective = /** @class */ (function () {
3513
- function GioBreadcrumbDynamicItemDirective(viewContainerRef) {
3514
- this.viewContainerRef = viewContainerRef;
3512
+ var GioBreadcrumbItemDirective = /** @class */ (function () {
3513
+ function GioBreadcrumbItemDirective() {
3515
3514
  }
3516
- return GioBreadcrumbDynamicItemDirective;
3515
+ return GioBreadcrumbItemDirective;
3517
3516
  }());
3518
- GioBreadcrumbDynamicItemDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbDynamicItemDirective, deps: [{ token: i0__namespace.ViewContainerRef }], target: i0__namespace.ɵɵFactoryTarget.Directive });
3519
- GioBreadcrumbDynamicItemDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.15", type: GioBreadcrumbDynamicItemDirective, selector: "[gioBreadcrumbDynamicHost]", ngImport: i0__namespace });
3520
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbDynamicItemDirective, decorators: [{
3517
+ GioBreadcrumbItemDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbItemDirective, deps: [], target: i0__namespace.ɵɵFactoryTarget.Directive });
3518
+ GioBreadcrumbItemDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.15", type: GioBreadcrumbItemDirective, selector: "[gio-breadcrumb-item]", ngImport: i0__namespace });
3519
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbItemDirective, decorators: [{
3521
3520
  type: i0.Directive,
3522
3521
  args: [{
3523
- selector: '[gioBreadcrumbDynamicHost]',
3522
+ selector: '[gio-breadcrumb-item]',
3524
3523
  }]
3525
- }], ctorParameters: function () { return [{ type: i0__namespace.ViewContainerRef }]; } });
3526
-
3527
- var GioBreadcrumbItemComponent = /** @class */ (function () {
3528
- function GioBreadcrumbItemComponent(componentFactoryResolver) {
3529
- this.componentFactoryResolver = componentFactoryResolver;
3530
- this.active = false;
3531
- this.itemClicked = new i0.EventEmitter();
3532
- }
3533
- GioBreadcrumbItemComponent.prototype.onItemClick = function (breadcrumbItem) {
3534
- this.itemClicked.emit(breadcrumbItem.targetRoute);
3535
- };
3536
- GioBreadcrumbItemComponent.prototype.loadComponent = function (breadcrumbItem) {
3537
- var _a;
3538
- if (breadcrumbItem.component && this.breadcrumbDynamicHost) {
3539
- var breadcrumbDynamicComponentComponentFactory = this.componentFactoryResolver.resolveComponentFactory(breadcrumbItem.component);
3540
- var viewContainerRef = this.breadcrumbDynamicHost.viewContainerRef;
3541
- viewContainerRef.clear();
3542
- var componentRef_1 = viewContainerRef.createComponent(breadcrumbDynamicComponentComponentFactory);
3543
- Object.entries(((_a = breadcrumbItem.data) === null || _a === void 0 ? void 0 : _a.nativeElement) || {}).forEach(function (_b) {
3544
- var _c = __read(_b, 2), attribute = _c[0], attributeValue = _c[1];
3545
- componentRef_1.location.nativeElement[attribute] = attributeValue;
3546
- });
3547
- Object.entries(breadcrumbItem.data || {})
3548
- .filter(function (_b) {
3549
- var _c = __read(_b, 1), key = _c[0];
3550
- return key != 'nativeElement';
3551
- })
3552
- .forEach(function (_b) {
3553
- var _c = __read(_b, 2), property = _c[0], propertyValue = _c[1];
3554
- componentRef_1.instance[property] = propertyValue;
3555
- });
3556
- }
3557
- };
3558
- GioBreadcrumbItemComponent.prototype.ngAfterViewInit = function () {
3559
- if (this.breadcrumbItem) {
3560
- this.loadComponent(this.breadcrumbItem);
3561
- }
3562
- };
3563
- return GioBreadcrumbItemComponent;
3564
- }());
3565
- GioBreadcrumbItemComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbItemComponent, deps: [{ token: i0__namespace.ComponentFactoryResolver }], target: i0__namespace.ɵɵFactoryTarget.Component });
3566
- GioBreadcrumbItemComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: GioBreadcrumbItemComponent, selector: "gio-breadcrumb-item", inputs: { breadcrumbItem: "breadcrumbItem", active: "active" }, outputs: { itemClicked: "itemClicked" }, viewQueries: [{ propertyName: "breadcrumbDynamicHost", first: true, predicate: GioBreadcrumbDynamicItemDirective, descendants: true, static: true }], ngImport: i0__namespace, template: "<!--\n\n Copyright (C) 2022 The Gravitee team (http://gravitee.io)\n\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n<a\n *ngIf=\"breadcrumbItem?.displayName\"\n (click)=\"onItemClick(breadcrumbItem)\"\n class=\"api-navigation-breadcrumb__link\"\n [class.active]=\"active\"\n >{{ breadcrumbItem?.displayName }}</a\n>\n<ng-template gioBreadcrumbDynamicHost></ng-template>\n", directives: [{ type: i2__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: GioBreadcrumbDynamicItemDirective, selector: "[gioBreadcrumbDynamicHost]" }] });
3567
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbItemComponent, decorators: [{
3568
- type: i0.Component,
3569
- args: [{
3570
- selector: 'gio-breadcrumb-item',
3571
- templateUrl: './gio-breadcrumb-item.component.html',
3572
- }]
3573
- }], ctorParameters: function () { return [{ type: i0__namespace.ComponentFactoryResolver }]; }, propDecorators: { breadcrumbItem: [{
3574
- type: i0.Input
3575
- }], active: [{
3576
- type: i0.Input
3577
- }], itemClicked: [{
3578
- type: i0.Output
3579
- }], breadcrumbDynamicHost: [{
3580
- type: i0.ViewChild,
3581
- args: [GioBreadcrumbDynamicItemDirective, { static: true }]
3582
- }] } });
3524
+ }] });
3583
3525
 
3584
3526
  /*
3585
3527
  * Copyright (C) 2022 The Gravitee team (http://gravitee.io)
@@ -3598,27 +3540,31 @@
3598
3540
  */
3599
3541
  var GioBreadcrumbComponent = /** @class */ (function () {
3600
3542
  function GioBreadcrumbComponent() {
3601
- this.breadcrumbItems = [];
3602
- this.itemClicked = new i0.EventEmitter();
3603
3543
  }
3604
- GioBreadcrumbComponent.prototype.onItemClicked = function ($event) {
3605
- this.itemClicked.emit($event);
3544
+ GioBreadcrumbComponent.prototype.ngAfterViewInit = function () {
3545
+ // console.log('after view', this.itemDirectives);
3546
+ //
3547
+ // this.itemDirectives.forEach(itemDirective => {
3548
+ // });
3549
+ //
3550
+ // this.itemDirectives.changes.subscribe(or => {
3551
+ // });
3606
3552
  };
3607
3553
  return GioBreadcrumbComponent;
3608
3554
  }());
3609
3555
  GioBreadcrumbComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbComponent, deps: [], target: i0__namespace.ɵɵFactoryTarget.Component });
3610
- GioBreadcrumbComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: GioBreadcrumbComponent, selector: "gio-breadcrumb", inputs: { breadcrumbItems: "breadcrumbItems" }, outputs: { itemClicked: "itemClicked" }, ngImport: i0__namespace, template: "<!--\n\n Copyright (C) 2022 The Gravitee team (http://gravitee.io)\n\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n<div class=\"gio-breadcrumb\">\n <span *ngFor=\"let breadcrumbItem of this.breadcrumbItems; index as breadcrumbItemIndex\" class=\"gio-breadcrumb__content\">\n <gio-breadcrumb-item [breadcrumbItem]=\"breadcrumbItem\" (itemClicked)=\"onItemClicked($event)\"></gio-breadcrumb-item>\n <mat-icon\n *ngIf=\"breadcrumbItemIndex < this.breadcrumbItems.length - 1\"\n svgIcon=\"gio:nav-arrow-right\"\n class=\"gio-breadcrumb__icon\"\n ></mat-icon>\n </span>\n</div>\n", styles: [".gio-breadcrumb{display:flex;align-items:center;margin:2px}.gio-breadcrumb__content{display:flex;align-items:center;color:#606274}.gio-breadcrumb__content:last-child{font-weight:bold}.gio-breadcrumb__icon{width:12px;height:12px;margin:0 6px;color:#bbbcc4;line-height:12px}\n"], components: [{ type: GioBreadcrumbItemComponent, selector: "gio-breadcrumb-item", inputs: ["breadcrumbItem", "active"], outputs: ["itemClicked"] }, { type: i1__namespace$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i2__namespace$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
3556
+ GioBreadcrumbComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: GioBreadcrumbComponent, selector: "gio-breadcrumb", queries: [{ propertyName: "itemDirectives", predicate: GioBreadcrumbItemDirective }], ngImport: i0__namespace, template: "<!--\n\n Copyright (C) 2022 The Gravitee team (http://gravitee.io)\n\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n<!--<div class=\"gio-breadcrumb\">-->\n<!-- <span *ngFor=\"let breadcrumbItem of this.breadcrumbItems; index as breadcrumbItemIndex\" class=\"gio-breadcrumb__content\">-->\n<!-- <gio-breadcrumb-item [breadcrumbItem]=\"breadcrumbItem\" (itemClicked)=\"onItemClicked($event)\"></gio-breadcrumb-item>-->\n<!-- <mat-icon-->\n<!-- *ngIf=\"breadcrumbItemIndex < this.breadcrumbItems.length - 1\"-->\n<!-- svgIcon=\"gio:nav-arrow-right\"-->\n<!-- class=\"gio-breadcrumb__icon\"-->\n<!-- ></mat-icon>-->\n<!-- </span>-->\n<!--</div>-->\n<div class=\"gio-breadcrumb\">\n <!-- <ng-container *ngFor=\"let item of itemDirectives\">-->\n <!-- <ng-container *ngTemplateOutlet=\"item\" ></ng-container>-->\n <!-- </ng-container>-->\n <ng-content></ng-content>\n</div>\n", styles: [".gio-breadcrumb{display:flex;align-items:center;margin:2px}.gio-breadcrumb__content{display:flex;align-items:center;color:#606274}.gio-breadcrumb__content:last-child{font-weight:bold}.gio-breadcrumb__icon{width:12px;height:12px;margin:0 6px;color:#bbbcc4;line-height:12px}\n"], encapsulation: i0__namespace.ViewEncapsulation.None });
3611
3557
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbComponent, decorators: [{
3612
3558
  type: i0.Component,
3613
3559
  args: [{
3614
3560
  selector: 'gio-breadcrumb',
3615
3561
  templateUrl: './gio-breadcrumb.component.html',
3616
3562
  styleUrls: ['./gio-breadcrumb.component.scss'],
3563
+ encapsulation: i0.ViewEncapsulation.None,
3617
3564
  }]
3618
- }], propDecorators: { breadcrumbItems: [{
3619
- type: i0.Input
3620
- }], itemClicked: [{
3621
- type: i0.Output
3565
+ }], propDecorators: { itemDirectives: [{
3566
+ type: i0.ContentChildren,
3567
+ args: [GioBreadcrumbItemDirective]
3622
3568
  }] } });
3623
3569
 
3624
3570
  /*
@@ -3642,14 +3588,14 @@
3642
3588
  return GioBreadcrumbModule;
3643
3589
  }());
3644
3590
  GioBreadcrumbModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
3645
- GioBreadcrumbModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbModule, declarations: [GioBreadcrumbComponent, GioBreadcrumbDynamicItemDirective, GioBreadcrumbItemComponent], imports: [i2$1.CommonModule, GioIconsModule], exports: [GioBreadcrumbComponent, GioBreadcrumbDynamicItemDirective, GioBreadcrumbItemComponent] });
3591
+ GioBreadcrumbModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbModule, declarations: [GioBreadcrumbComponent, GioBreadcrumbItemDirective], imports: [i2$1.CommonModule, GioIconsModule], exports: [GioBreadcrumbComponent, GioBreadcrumbItemDirective] });
3646
3592
  GioBreadcrumbModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbModule, imports: [[i2$1.CommonModule, GioIconsModule]] });
3647
3593
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0__namespace, type: GioBreadcrumbModule, decorators: [{
3648
3594
  type: i0.NgModule,
3649
3595
  args: [{
3650
3596
  imports: [i2$1.CommonModule, GioIconsModule],
3651
- declarations: [GioBreadcrumbComponent, GioBreadcrumbDynamicItemDirective, GioBreadcrumbItemComponent],
3652
- exports: [GioBreadcrumbComponent, GioBreadcrumbDynamicItemDirective, GioBreadcrumbItemComponent],
3597
+ declarations: [GioBreadcrumbComponent, GioBreadcrumbItemDirective],
3598
+ exports: [GioBreadcrumbComponent, GioBreadcrumbItemDirective],
3653
3599
  entryComponents: [GioBreadcrumbComponent],
3654
3600
  }]
3655
3601
  }] });
@@ -3717,8 +3663,7 @@
3717
3663
  exports.GioBannerSuccessComponent = GioBannerSuccessComponent;
3718
3664
  exports.GioBannerWarningComponent = GioBannerWarningComponent;
3719
3665
  exports.GioBreadcrumbComponent = GioBreadcrumbComponent;
3720
- exports.GioBreadcrumbDynamicItemDirective = GioBreadcrumbDynamicItemDirective;
3721
- exports.GioBreadcrumbItemComponent = GioBreadcrumbItemComponent;
3666
+ exports.GioBreadcrumbItemDirective = GioBreadcrumbItemDirective;
3722
3667
  exports.GioBreadcrumbModule = GioBreadcrumbModule;
3723
3668
  exports.GioConfirmAndValidateDialogComponent = GioConfirmAndValidateDialogComponent;
3724
3669
  exports.GioConfirmAndValidateDialogHarness = GioConfirmAndValidateDialogHarness;