@indigina/ui-kit 1.1.238 → 1.1.239
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.
|
@@ -4962,6 +4962,7 @@ class KitProfileMenuComponent {
|
|
|
4962
4962
|
this.KitSvgIcon = KitSvgIcon;
|
|
4963
4963
|
this.KitPopupAlignHorizontal = KitPopupAlignHorizontal;
|
|
4964
4964
|
this.KitSvgIconType = KitSvgIconType;
|
|
4965
|
+
this.popupIsOpen = signal(false, ...(ngDevMode ? [{ debugName: "popupIsOpen" }] : []));
|
|
4965
4966
|
}
|
|
4966
4967
|
onClick(item) {
|
|
4967
4968
|
item?.action && item.action();
|
|
@@ -4980,7 +4981,7 @@ class KitProfileMenuComponent {
|
|
|
4980
4981
|
});
|
|
4981
4982
|
}
|
|
4982
4983
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: KitProfileMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
4983
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.3", type: KitProfileMenuComponent, isStandalone: true, selector: "kit-profile-menu", inputs: { menuItems: "menuItems", userName: "userName", companyName: "companyName", avatarImageSrc: "avatarImageSrc" }, viewQueries: [{ propertyName: "popup", first: true, predicate: ["popup"], descendants: true }], ngImport: i0, template: "<div class=\"profile-menu\">\n <button #menuButton\n class=\"menu-button\"\n [class.active]=\"
|
|
4984
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.3", type: KitProfileMenuComponent, isStandalone: true, selector: "kit-profile-menu", inputs: { menuItems: "menuItems", userName: "userName", companyName: "companyName", avatarImageSrc: "avatarImageSrc" }, viewQueries: [{ propertyName: "popup", first: true, predicate: ["popup"], descendants: true }], ngImport: i0, template: "<div class=\"profile-menu\">\n <button #menuButton\n class=\"menu-button\"\n [class.active]=\"popupIsOpen()\"\n (click)=\"toggle()\">\n <kit-avatar [size]=\"KitAvatarSize.LARGE\"\n [name]=\"userName\"\n [imageSrc]=\"avatarImageSrc\"\n ></kit-avatar>\n <kit-svg-icon class=\"menu-button-icon\"\n [icon]=\"KitSvgIcon.CARET_DOWN\"\n ></kit-svg-icon>\n </button>\n\n <kit-popup #popup\n popupClass=\"menu-popup\"\n [anchor]=\"menuButton\"\n [content]=\"content\"\n (onOpen)=\"popupIsOpen.set(true)\"\n (onClose)=\"popupIsOpen.set(false)\">\n </kit-popup>\n</div>\n\n<ng-template #content>\n <div class=\"popup-content\">\n <div class=\"popup-header\">\n <kit-avatar class=\"popup-header-avatar\"\n [name]=\"userName\"\n [size]=\"KitAvatarSize.LARGE\"\n [imageSrc]=\"avatarImageSrc\"\n ></kit-avatar>\n <div class=\"popup-header-details\">\n @if (userName) {\n <div class=\"popup-header-name\">{{ userName }}</div>\n }\n @if (companyName) {\n <div class=\"popup-header-company\">{{ companyName }}</div>\n }\n </div>\n </div>\n <div class=\"popup-menu\">\n @for (item of menuItems; track item) {\n <a class=\"menu-item\"\n [ngClass]=\"item.cssClass\"\n [routerLink]=\"item.link\"\n (click)=\"onClick(item)\">\n @if (item.icon) {\n <kit-svg-icon class=\"menu-item-icon\"\n [icon]=\"item.icon\"\n [ngClass]=\"item?.iconType ?? KitSvgIconType.FILL\"\n ></kit-svg-icon>\n }\n <span class=\"menu-item-text\">{{ item.title }}</span>\n </a>\n }\n </div>\n </div>\n</ng-template>\n", styles: [".profile-menu .menu-button{display:flex;align-items:center;gap:14px;padding:0;border:none;background:none;cursor:pointer}.profile-menu .menu-button-icon{display:block;width:20px;height:20px}.profile-menu .menu-button ::ng-deep .kit-badge-content{top:4px;right:5px;border-color:var(--ui-kit-color-white)}.profile-menu .menu-button.active .menu-button-icon{transform:rotate(180deg)}::ng-deep .kit-popup.menu-popup{padding:0}::ng-deep .kit-popup.menu-popup .popup-content{display:flex;flex-direction:column;gap:4px;padding:8px 4px;width:280px}::ng-deep .kit-popup.menu-popup .popup-header{display:flex;align-items:center;gap:14px;padding:6px 12px}::ng-deep .kit-popup.menu-popup .popup-header-details{min-width:0;font-size:14px}::ng-deep .kit-popup.menu-popup .popup-header-name{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}::ng-deep .kit-popup.menu-popup .popup-menu{display:flex;flex-direction:column;gap:4px}::ng-deep .kit-popup.menu-popup .menu-item{display:flex;align-items:center;gap:8px;padding:6px 12px;color:var(--ui-kit-color-grey-10);border-radius:4px;text-decoration:none;cursor:pointer}::ng-deep .kit-popup.menu-popup .menu-item:hover{color:var(--ui-kit-color-main);background:var(--ui-kit-color-grey-13)}::ng-deep .kit-popup.menu-popup .menu-item-icon{display:block;width:18px;height:18px}::ng-deep .kit-popup.menu-popup .menu-item-icon.stroke{fill:none;stroke:var(--ui-kit-color-main)}::ng-deep .kit-popup.menu-popup .menu-item-icon.fill{stroke:none;fill:var(--ui-kit-color-main)}::ng-deep .kit-popup.menu-popup .menu-item-text{font-size:14px;font-weight:400}::ng-deep .kit-popup.menu-popup .k-popup{padding:0}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: KitAvatarModule }, { kind: "component", type: KitAvatarComponent, selector: "kit-avatar", inputs: ["name", "imageSrc", "size"] }, { kind: "component", type: KitPopupComponent, selector: "kit-popup", inputs: ["anchor", "content", "closeOnOutsideClick", "showFooter", "cancelButtonLabel", "applyButtonLabel", "isApplyButtonDisabled", "positionMode", "popupClass", "closePopupOnCancel", "extraInsideSelectors"], outputs: ["onCancel", "onApply", "onOpen", "onClose"] }, { kind: "ngmodule", type: KitSvgIconModule }, { kind: "component", type: KitSvgIconComponent, selector: "kit-svg-icon", inputs: ["icon", "iconClass"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
4984
4985
|
}
|
|
4985
4986
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: KitProfileMenuComponent, decorators: [{
|
|
4986
4987
|
type: Component,
|
|
@@ -4990,7 +4991,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImpor
|
|
|
4990
4991
|
KitPopupComponent,
|
|
4991
4992
|
KitSvgIconModule,
|
|
4992
4993
|
RouterLink,
|
|
4993
|
-
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"profile-menu\">\n <button #menuButton\n class=\"menu-button\"\n [class.active]=\"
|
|
4994
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"profile-menu\">\n <button #menuButton\n class=\"menu-button\"\n [class.active]=\"popupIsOpen()\"\n (click)=\"toggle()\">\n <kit-avatar [size]=\"KitAvatarSize.LARGE\"\n [name]=\"userName\"\n [imageSrc]=\"avatarImageSrc\"\n ></kit-avatar>\n <kit-svg-icon class=\"menu-button-icon\"\n [icon]=\"KitSvgIcon.CARET_DOWN\"\n ></kit-svg-icon>\n </button>\n\n <kit-popup #popup\n popupClass=\"menu-popup\"\n [anchor]=\"menuButton\"\n [content]=\"content\"\n (onOpen)=\"popupIsOpen.set(true)\"\n (onClose)=\"popupIsOpen.set(false)\">\n </kit-popup>\n</div>\n\n<ng-template #content>\n <div class=\"popup-content\">\n <div class=\"popup-header\">\n <kit-avatar class=\"popup-header-avatar\"\n [name]=\"userName\"\n [size]=\"KitAvatarSize.LARGE\"\n [imageSrc]=\"avatarImageSrc\"\n ></kit-avatar>\n <div class=\"popup-header-details\">\n @if (userName) {\n <div class=\"popup-header-name\">{{ userName }}</div>\n }\n @if (companyName) {\n <div class=\"popup-header-company\">{{ companyName }}</div>\n }\n </div>\n </div>\n <div class=\"popup-menu\">\n @for (item of menuItems; track item) {\n <a class=\"menu-item\"\n [ngClass]=\"item.cssClass\"\n [routerLink]=\"item.link\"\n (click)=\"onClick(item)\">\n @if (item.icon) {\n <kit-svg-icon class=\"menu-item-icon\"\n [icon]=\"item.icon\"\n [ngClass]=\"item?.iconType ?? KitSvgIconType.FILL\"\n ></kit-svg-icon>\n }\n <span class=\"menu-item-text\">{{ item.title }}</span>\n </a>\n }\n </div>\n </div>\n</ng-template>\n", styles: [".profile-menu .menu-button{display:flex;align-items:center;gap:14px;padding:0;border:none;background:none;cursor:pointer}.profile-menu .menu-button-icon{display:block;width:20px;height:20px}.profile-menu .menu-button ::ng-deep .kit-badge-content{top:4px;right:5px;border-color:var(--ui-kit-color-white)}.profile-menu .menu-button.active .menu-button-icon{transform:rotate(180deg)}::ng-deep .kit-popup.menu-popup{padding:0}::ng-deep .kit-popup.menu-popup .popup-content{display:flex;flex-direction:column;gap:4px;padding:8px 4px;width:280px}::ng-deep .kit-popup.menu-popup .popup-header{display:flex;align-items:center;gap:14px;padding:6px 12px}::ng-deep .kit-popup.menu-popup .popup-header-details{min-width:0;font-size:14px}::ng-deep .kit-popup.menu-popup .popup-header-name{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}::ng-deep .kit-popup.menu-popup .popup-menu{display:flex;flex-direction:column;gap:4px}::ng-deep .kit-popup.menu-popup .menu-item{display:flex;align-items:center;gap:8px;padding:6px 12px;color:var(--ui-kit-color-grey-10);border-radius:4px;text-decoration:none;cursor:pointer}::ng-deep .kit-popup.menu-popup .menu-item:hover{color:var(--ui-kit-color-main);background:var(--ui-kit-color-grey-13)}::ng-deep .kit-popup.menu-popup .menu-item-icon{display:block;width:18px;height:18px}::ng-deep .kit-popup.menu-popup .menu-item-icon.stroke{fill:none;stroke:var(--ui-kit-color-main)}::ng-deep .kit-popup.menu-popup .menu-item-icon.fill{stroke:none;fill:var(--ui-kit-color-main)}::ng-deep .kit-popup.menu-popup .menu-item-text{font-size:14px;font-weight:400}::ng-deep .kit-popup.menu-popup .k-popup{padding:0}\n"] }]
|
|
4994
4995
|
}], propDecorators: { menuItems: [{
|
|
4995
4996
|
type: Input
|
|
4996
4997
|
}], userName: [{
|