var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
import { MelodicComponent } from '@melodicdev/core';
import { activityFeedItemTemplate } from './activity-feed-item.template.js';
import { activityFeedItemStyles } from './activity-feed-item.styles.js';
const INDICATOR_PRESETS = new Set(['success', 'warning', 'error', 'primary', 'gray']);
/**
 * ml-activity-feed-item - Individual activity entry within a feed
 *
 * @example
 * ```html
 * <ml-activity-feed-item name="Jane Doe" timestamp="2 hours ago" avatar-initials="JD">
 *   Updated the project status
 * </ml-activity-feed-item>
 * ```
 *
 * @slot default - Activity description
 * @slot avatar - Custom avatar or icon (replaces default ml-avatar)
 * @slot content - Extra content below the description
 */
let ActivityFeedItemComponent = class ActivityFeedItemComponent {
    constructor() {
        /** User display name */
        this.name = '';
        /** Timestamp text */
        this.timestamp = '';
        /** Avatar image source */
        this['avatar-src'] = '';
        /** Avatar initials fallback */
        this['avatar-initials'] = '';
        /** Avatar size */
        this['avatar-size'] = 'sm';
        /** Subtitle text (e.g. @handle) */
        this.subtitle = '';
        /** Show indicator dot */
        this.indicator = false;
        /** Indicator dot color — preset name or any CSS color value */
        this['indicator-color'] = 'gray';
    }
    /** Whether the indicator-color is a preset name */
    get isPresetColor() {
        return INDICATOR_PRESETS.has(this['indicator-color']);
    }
    /** Check if avatar slot has content */
    get hasAvatarSlot() {
        return this.elementRef?.querySelector('[slot="avatar"]') !== null;
    }
    /** Check if content slot has content */
    get hasContentSlot() {
        return this.elementRef?.querySelector('[slot="content"]') !== null;
    }
};
ActivityFeedItemComponent = __decorate([
    MelodicComponent({
        selector: 'ml-activity-feed-item',
        template: activityFeedItemTemplate,
        styles: activityFeedItemStyles,
        attributes: ['name', 'timestamp', 'avatar-src', 'avatar-initials', 'avatar-size', 'subtitle', 'indicator', 'indicator-color']
    })
], ActivityFeedItemComponent);
export { ActivityFeedItemComponent };
