Skip to content

Commit 887cc5a

Browse files
authored
docs(Tooltip): fix inaccurate data-state (#1361)
1 parent 182dd42 commit 887cc5a

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { default as TooltipStateDataAttr } from "./tooltip-state-data-attr.md";
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```ts
2+
"delayed-open" | "instant-open" | "closed";
3+
```

docs/src/lib/content/api-reference/tooltip.api.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,14 @@ import {
3131
} from "$lib/content/api-reference/helpers.js";
3232
import * as C from "$lib/content/constants.js";
3333
import type { APISchema } from "$lib/types/index.js";
34+
import { TooltipStateDataAttr } from "./extended-types/tooltip/index.js";
3435

3536
const openClosedDataAttr = createEnumDataAttr({
3637
name: "state",
37-
description: "Whether the tooltip is open or closed.",
38-
options: ["open", "closed"],
38+
description:
39+
"Whether/how the tooltip is open or closed. When open, if there is a delay, the value will be 'delayed-open', otherwise it will be 'instant-open'. When closed, the value will be 'closed'.",
40+
options: ["delayed-open", "instant-open", "closed"],
41+
definition: TooltipStateDataAttr,
3942
});
4043

4144
const delayDuration = createNumberProp({

0 commit comments

Comments
 (0)