2021-12-17 13:47:59 +00:00
|
|
|
---
|
|
|
|
export interface Props extends Record<any, any> {
|
|
|
|
level?: number | string;
|
|
|
|
role?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
const { level, role, ...props } = {
|
|
|
|
...Astro.props,
|
2022-08-26 14:16:17 +00:00
|
|
|
};
|
2021-12-17 13:47:59 +00:00
|
|
|
|
2022-08-06 04:39:26 +00:00
|
|
|
props.role = role || 'heading';
|
|
|
|
props['aria-level'] = level || '1';
|
2021-12-17 13:47:59 +00:00
|
|
|
---
|
2021-12-22 21:11:05 +00:00
|
|
|
|
2021-12-17 13:47:59 +00:00
|
|
|
<h {...props}><slot /></h>
|