import { h } from './index-b153bfd0.js';
import { g as getIconPath } from './assets-manager-7d6fc08f.js';
import './mer-animated-dots-7cbae6ef.js';
import 'lit';
import 'lit/directives/when.js';
import 'lit/directives/if-defined.js';

// Stencil
const INSERTED_ICON = getIconPath({
    category: "system",
    name: "add",
    colorType: "success"
});
const EDITED_ICON = getIconPath({
    category: "system",
    name: "edit",
    colorType: "warning"
});
const DELETED_ICON = getIconPath({
    category: "system",
    name: "substract",
    colorType: "error"
});
const WARNING_ICON = getIconPath({
    category: "system",
    name: "warning",
    colorType: "warning"
});
/**
 * Renders a visual indicator (icon and label) for a given object state.
 *
 * This helper function maps a fixed set of object states to corresponding icons
 *
 * Supported states:
 * - "inserted": Displays a green "add" icon.
 * - "modified": Displays a yellow "edit" icon.
 * - "deleted": Displays a red "subtract" icon.
 * - "conflicted": Displays a yellow "warning" icon.
 *
 * @param {ObjectState} objectState - The current state of the object.
 * @returns {HTMLChImageElement} A span element containing the corresponding icon and state label.
 */
const renderObjectStateWithIcon = (objectState) => {
    let icon;
    switch (objectState) {
        case "inserted":
            icon = INSERTED_ICON;
            break;
        case "modified":
            icon = EDITED_ICON;
            break;
        case "deleted":
            icon = DELETED_ICON;
            break;
        case "conflicted":
            icon = WARNING_ICON;
            break;
    }
    return (h("span", { class: "custom-icon-text-wrapper" },
        h("ch-image", { class: "icon-m", src: icon }),
        `${objectState.charAt(0).toUpperCase() + objectState.slice(1)}`));
};
/**
 * Renders a GeneXus object type as a span element containing its icon and name.
 *
 * @param {ObjectType} objectType - The GeneXus object type to render, including its `icon` and `name` properties.
 * @returns {JSX.Element} A span element with the object's icon and label.
 */
const renderObjectTypeWithIcon = (objectType) => {
    // bring changes
    const icon = objectType.icon;
    return (h("span", { class: "custom-icon-text-wrapper" },
        h("ch-image", { class: "icon-m", src: icon }),
        `${objectType.name}`));
};

const ALL_VALUE = "All";
const CSS_SELECTORS = {
    HEADER: "header spacing-body-inline spacing-body-block-start",
    HEADER_DETAILS: "header__details",
    FILTER: "filter",
    MAIN: "main spacing-body",
    GRID_CELL_DESCRIPTION: "tabular-grid-cell-description-custom-selector"
};
const ICONS = {
    add: getIconPath({
        category: "system",
        name: "add",
        colorType: "on-surface"
    }),
    edit: getIconPath({
        category: "system",
        name: "edit",
        colorType: "on-surface"
    }),
    error: getIconPath({
        category: "system",
        name: "error",
        colorType: "error"
    }),
    filter: getIconPath({
        category: "window-tools",
        name: "filter",
        colorType: "interactive"
    }),
    filterWithConditions: getIconPath({
        category: "window-tools",
        name: "filter-conditions",
        colorType: "interactive"
    }),
    info: getIconPath({
        category: "system",
        name: "information",
        colorType: "on-surface"
    }),
    refresh: getIconPath({
        category: "gemini-tools",
        name: "reset",
        colorType: "interactive"
    }),
    search: getIconPath({
        category: "system",
        name: "search",
        colorType: "on-surface"
    }),
    success: getIconPath({
        category: "system",
        name: "check",
        colorType: "success"
    }),
    substract: getIconPath({
        category: "system",
        name: "substract",
        colorType: "on-surface"
    }),
    warning: getIconPath({
        category: "system",
        name: "warning",
        colorType: "warning"
    })
};

export { ALL_VALUE as A, CSS_SELECTORS as C, ICONS as I, renderObjectStateWithIcon as a, renderObjectTypeWithIcon as r };

//# sourceMappingURL=constants-ae6a35f5.js.map