Skip to content

Commit fe22a32

Browse files
committed
fix(typescript): renamed types
1 parent 5bfe732 commit fe22a32

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

docs/src/components/content-container.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ The appropriate HTML element for the page structure is determined based on the `
1919
## Properties
2020

2121
```ts
22-
type Props = {
22+
type ContentContainerProps = {
2323
tag?: string;
2424
rootTags?: string[];
2525
contentTags?: string[];

docs/src/components/content-headline.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ The deeper the nesting, the smaller the heading.
2121
## Properties
2222

2323
```ts
24-
type Props = {
24+
type ContentHeadlineProps = {
2525
tag: string;
2626
debug: boolean;
2727
};

src/ContentContainer.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
import { defineComponent, h, inject, provide, type ComponentOptions } from 'vue';
22
import useContentContainer from './useContentContainer';
33

4-
export type Props = {
4+
export type ContentContainerProps = {
55
tag?: string;
66
rootTags?: string[];
77
contentTags?: string[];
88
level?: number;
99
debug?: boolean;
1010
};
1111

12-
export type Context = Props & {
12+
export type ContentContainerContext = ContentContainerProps & {
1313
parentLevel: number;
1414
currentLevel: number;
1515
currentTag: string;
@@ -46,13 +46,13 @@ const ContentContainer = defineComponent({
4646
}
4747
},
4848

49-
setup(props: Props) {
49+
setup(props: ContentContainerProps) {
5050
const { parentLevel, currentLevel, currentTag } = useContentContainer(props);
5151
provide('semanticStructure_debug', props.debug);
5252
return { parentLevel, currentLevel, currentTag };
5353
},
5454

55-
render(this: Context & ComponentOptions) {
55+
render(this: ContentContainerContext & ComponentOptions) {
5656
const { currentTag, parentLevel, currentLevel } = this;
5757

5858
return h(
@@ -73,7 +73,7 @@ const ContentContainer = defineComponent({
7373
}
7474
});
7575

76-
const getDebugAttrs = (context: Context) => {
76+
const getDebugAttrs = (context: ContentContainerContext) => {
7777
if (context.debug) {
7878
return {
7979
'data-current-tag': context.currentTag,

src/ContentHeadline.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
import { defineComponent, h, inject, type ComponentOptions } from 'vue';
22
import useContentHeadline from './useContentHeadline';
33

4-
export type Props = {
4+
export type ContentHeadlineProps = {
55
tag: string;
66
debug: boolean;
77
};
88

9-
export type Context = Props & {
9+
export type ContentHeadlineContext = ContentHeadlineProps & {
1010
parentLevel: number;
1111
currentLevel: number;
1212
currentTag: string;
@@ -32,7 +32,7 @@ const ContentHeadline = defineComponent({
3232
return { parentLevel, currentLevel, currentTag };
3333
},
3434

35-
render(this: Context & ComponentOptions) {
35+
render(this: ContentHeadlineContext & ComponentOptions) {
3636
const { currentTag, currentLevel } = this;
3737
return h(
3838
currentTag,
@@ -51,7 +51,7 @@ const ContentHeadline = defineComponent({
5151
}
5252
});
5353

54-
const getDebugAttrs = (context: Context) => {
54+
const getDebugAttrs = (context: ContentHeadlineContext) => {
5555
if (context.debug) {
5656
return {
5757
'data-current-tag': context.currentTag,

0 commit comments

Comments
 (0)