import React from 'react'; import type { AsElementType, OtherHTMLAttributes, Renderable } from '@instructure/shared-types'; import type { Spacing, WithStyleProps, ComponentStyle } from '@instructure/emotion'; import type { NewComponentTypes } from '@instructure/ui-themes'; type HeadingLevel = U; type HeadingOwnProps = { /** * transforms heading into an `ai` variant */ aiVariant?: 'stacked' | 'horizontal' | 'iconOnly'; /** * The text content of the Heading */ children?: React.ReactNode; /** * Add a top- or bottom-border to the Heading */ border?: 'none' | 'top' | 'bottom'; /** * The font color to render, NOTE: `ai` color is deprecated. Use the `aiVariant` prop instead */ color?: 'primary' | 'secondary' | 'primary-inverse' | 'secondary-inverse' | 'inherit' | 'primary-on' | 'secondary-on' | 'ai'; /** * The level of the heading in the DOM: h1 is largest; h6 is smallest. */ level?: HeadingLevel<'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'> | 'reset'; /** * What DOM element is output is determined in the following order: * 1. (deprecated) If `variant` is set, then use the `level` prop, if that's * not set use `

`-`

` based on the `variant` prop's value * 2. The value of the `as` prop * 3. The value of the `level` prop * 4. `

` */ as?: AsElementType; /** * Valid values are `0`, `none`, `auto`, `xxx-small`, `xx-small`, `x-small`, * `small`, `medium`, `large`, `x-large`, `xx-large`. Apply these values via * familiar CSS-like shorthand. For example: `margin="small auto large"`. */ margin?: Spacing; /** * Provides a ref to the underlying HTML element */ elementRef?: (element: Element | null) => void; /** * An icon, or function that returns an icon that gets displayed before the text. */ renderIcon?: Renderable; /** * Sets appearance of the heading. Will also set its heading level, if not * specified by the `level` prop (deprecated, not recommended!) */ variant?: 'titlePageDesktop' | 'titlePageMobile' | 'titleSection' | 'titleCardSection' | 'titleModule' | 'titleCardLarge' | 'titleCardRegular' | 'titleCardMini' | 'label' | 'labelInline'; }; type PropKeys = keyof HeadingOwnProps; type AllowedPropKeys = Readonly>; type HeadingProps = HeadingOwnProps & WithStyleProps, HeadingStyle> & OtherHTMLAttributes; type HeadingStyle = ComponentStyle<'heading' | 'igniteAI' | 'igniteAIStacked' | 'igniteAIHorizontal' | 'withIcon'>; declare const allowedProps: AllowedPropKeys; export type { HeadingProps, HeadingStyle }; export { allowedProps }; //# sourceMappingURL=props.d.ts.map