carbon-components-svelte/types/Popover/PopoverContent.svelte.d.ts
Gregor Wassmann e00c956a66 feat(v11): Tooltip
Refactor `Tooltip` to use `Popover` component internally.

**Breaking changes**

- `direction` is replaced by additional `align` options.
- `hideIcon` property is removed.

**Limitations**

- The reference implementaiton uses the trigger content instead of the tooltip content as primary slot. This is not considered in this refactoring since it would be too big of a change.
- Instead of `TooltipFooter` a new `Toggletip` component would be required which is not included in this patch.
2023-10-07 16:44:24 +02:00

30 lines
617 B
TypeScript

import type { SvelteComponentTyped } from "svelte";
import type { SvelteHTMLElements } from "svelte/elements";
type RestProps = SvelteHTMLElements["span"];
export interface PopoverContentProps extends RestProps {
/**
* @default null
*/
className?: undefined;
/**
* @default {}
*/
contentProps?: {};
/**
* Obtain a reference to the popover content HTML element
* @default null
*/
ref?: null | HTMLSpanElement;
[key: `data-${string}`]: any;
}
export default class PopoverContent extends SvelteComponentTyped<
PopoverContentProps,
Record<string, any>,
{ default: {} }
> {}