import * as i0 from '@angular/core';
import { inject, DestroyRef, ElementRef, ContentChildren, HostBinding, Input, ChangeDetectionStrategy, ViewEncapsulation, Component, NgModule } from '@angular/core';
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
import { FD_LINK_COMPONENT } from '@fundamental-ngx/core/link';
import { startWith } from 'rxjs/operators';

class ObjectIdentifierComponent {
    constructor() {
        /** Whether the title should be bolded */
        this.bold = false;
        /** Whether the title is medium size */
        this.medium = false;
        /** @hidden */
        this.objectIdentifierClass = true;
        /** An RxJS Subject that will kill the data stream upon component’s destruction (for unsubscribing)  */
        this._destroyRef = inject(DestroyRef);
    }
    /** @hidden */
    ngAfterContentInit() {
        this._listenOnLinkQueryChange();
    }
    /** @hidden */
    _listenOnLinkQueryChange() {
        this.linkComponents.changes
            .pipe(startWith(0), takeUntilDestroyed(this._destroyRef))
            .subscribe(() => this.linkComponents.forEach((link) => this._addIdentifierClass(link)));
    }
    /** @hidden */
    _addIdentifierClass(link) {
        link.nativeElement.classList.add('fd-object-identifier__link');
    }
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: ObjectIdentifierComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
    static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.3", type: ObjectIdentifierComponent, isStandalone: true, selector: "fd-object-identifier", inputs: { description: "description", bold: "bold", medium: "medium" }, host: { properties: { "class.fd-object-identifier--medium": "this.medium", "class.fd-object-identifier": "this.objectIdentifierClass" } }, queries: [{ propertyName: "linkComponents", predicate: FD_LINK_COMPONENT, read: ElementRef }], ngImport: i0, template: `
        <p class="fd-object-identifier__title" [class.fd-object-identifier__title--bold]="bold">
            <ng-content></ng-content>
        </p>
        @if (description) {
            <p class="fd-object-identifier__text">
                {{ description }}
            </p>
        }
    `, isInline: true, styles: [".fd-object-identifier .fd-object-identifier__link{font-size:inherit;font-weight:inherit}.fd-object-identifier__title{border:0;-webkit-box-sizing:border-box;box-sizing:border-box;color:var(--sapTextColor);color:var(--sapList_TextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-size:var(--sapFontLargeSize);font-weight:400;forced-color-adjust:none;line-height:normal;margin-block:0;margin-inline:0;padding-block:0;padding-inline:0}.fd-object-identifier__title:after,.fd-object-identifier__title:before{-webkit-box-sizing:inherit;box-sizing:inherit;font-size:inherit}.fd-object-identifier__title--bold{font-weight:700}.fd-object-identifier__text{border:0;-webkit-box-sizing:border-box;box-sizing:border-box;color:var(--sapTextColor);color:var(--sapContent_LabelColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:normal;margin-block:0;margin-inline:0;margin-top:.5rem;padding-block:0;padding-inline:0}.fd-object-identifier__text:after,.fd-object-identifier__text:before{-webkit-box-sizing:inherit;box-sizing:inherit;font-size:inherit}.fd-object-identifier--medium .fd-object-identifier__title{font-size:var(--sapFontSize)}\n/*! Bundled license information:\n\nfundamental-styles/dist/object-identifier.css:\n  (*!\n   * Fundamental Library Styles v0.40.1\n   * Copyright (c) 2025 SAP SE or an SAP affiliate company.\n   * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n   *)\n*/\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: ObjectIdentifierComponent, decorators: [{
            type: Component,
            args: [{ selector: 'fd-object-identifier', template: `
        <p class="fd-object-identifier__title" [class.fd-object-identifier__title--bold]="bold">
            <ng-content></ng-content>
        </p>
        @if (description) {
            <p class="fd-object-identifier__text">
                {{ description }}
            </p>
        }
    `, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, imports: [], styles: [".fd-object-identifier .fd-object-identifier__link{font-size:inherit;font-weight:inherit}.fd-object-identifier__title{border:0;-webkit-box-sizing:border-box;box-sizing:border-box;color:var(--sapTextColor);color:var(--sapList_TextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-size:var(--sapFontLargeSize);font-weight:400;forced-color-adjust:none;line-height:normal;margin-block:0;margin-inline:0;padding-block:0;padding-inline:0}.fd-object-identifier__title:after,.fd-object-identifier__title:before{-webkit-box-sizing:inherit;box-sizing:inherit;font-size:inherit}.fd-object-identifier__title--bold{font-weight:700}.fd-object-identifier__text{border:0;-webkit-box-sizing:border-box;box-sizing:border-box;color:var(--sapTextColor);color:var(--sapContent_LabelColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:normal;margin-block:0;margin-inline:0;margin-top:.5rem;padding-block:0;padding-inline:0}.fd-object-identifier__text:after,.fd-object-identifier__text:before{-webkit-box-sizing:inherit;box-sizing:inherit;font-size:inherit}.fd-object-identifier--medium .fd-object-identifier__title{font-size:var(--sapFontSize)}\n/*! Bundled license information:\n\nfundamental-styles/dist/object-identifier.css:\n  (*!\n   * Fundamental Library Styles v0.40.1\n   * Copyright (c) 2025 SAP SE or an SAP affiliate company.\n   * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n   *)\n*/\n"] }]
        }], propDecorators: { description: [{
                type: Input
            }], bold: [{
                type: Input
            }], medium: [{
                type: Input
            }, {
                type: HostBinding,
                args: ['class.fd-object-identifier--medium']
            }], objectIdentifierClass: [{
                type: HostBinding,
                args: ['class.fd-object-identifier']
            }], linkComponents: [{
                type: ContentChildren,
                args: [FD_LINK_COMPONENT, { read: ElementRef }]
            }] } });

/**
 * @deprecated
 * Use direct import of `ObjectIdentifierComponent`.
 */
class ObjectIdentifierModule {
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: ObjectIdentifierModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
    static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.3", ngImport: i0, type: ObjectIdentifierModule, imports: [ObjectIdentifierComponent], exports: [ObjectIdentifierComponent] }); }
    static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: ObjectIdentifierModule }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.3", ngImport: i0, type: ObjectIdentifierModule, decorators: [{
            type: NgModule,
            args: [{
                    imports: [ObjectIdentifierComponent],
                    exports: [ObjectIdentifierComponent]
                }]
        }] });

/**
 * Generated bundle index. Do not edit.
 */

export { ObjectIdentifierComponent, ObjectIdentifierModule };
//# sourceMappingURL=fundamental-ngx-core-object-identifier.mjs.map
