import { _ as __rest } from './tslib.es6-ab63fd84.js';
import React__default from 'react';
import { useMantineTheme } from '@mantine/core';
import { T as Text } from './index-d0a1200e.js';

/**
 * @deprecated Consider to use import { Title } from '@mantine/core'
 * if need to use custom tag, use Text from mantine instead
 */
const Heading = (_a) => {
    var { as, tag, color, fontWeight, dataEventCategory, dataEventAction, dataEventLabel } = _a, rest = __rest(_a, ["as", "tag", "color", "fontWeight", "dataEventCategory", "dataEventAction", "dataEventLabel"]);
    const asTag = as || tag;
    const theme = useMantineTheme();
    return (React__default.createElement(Text, Object.assign({ as: asTag, color: color || theme.colors.gray[8], "data-event-category": dataEventCategory, "data-event-action": dataEventAction, "data-event-label": dataEventLabel, weight: fontWeight === 'semibold' ? 'semiBold' : 'bold', size: tag, "data-size": tag, "data-font-weight": fontWeight || undefined }, rest)));
};

export { Heading as H };
