@storybook/addon-links 10.5.2 → 10.6.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +12 -11
- package/dist/preview.d.ts +3 -2
- package/dist/react/index.d.ts +18 -17
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { ComponentTitle, StoryName, StoryId, StoryKind } from 'storybook/internal/types';
|
|
1
|
+
import { ComponentTitle, StoryId, StoryKind, StoryName } from "storybook/internal/types";
|
|
3
2
|
|
|
3
|
+
//#region code/addons/links/.dts-emit/code/addons/links/src/utils.d.ts
|
|
4
4
|
interface ParamsId {
|
|
5
|
-
|
|
5
|
+
storyId: StoryId;
|
|
6
6
|
}
|
|
7
7
|
interface ParamsCombo {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
kind?: StoryKind;
|
|
9
|
+
title?: ComponentTitle;
|
|
10
|
+
story?: StoryName;
|
|
11
|
+
name?: StoryName;
|
|
12
12
|
}
|
|
13
13
|
declare const navigate: (params: ParamsId | ParamsCombo) => void;
|
|
14
14
|
declare const hrefTo: (title: ComponentTitle, name: StoryName) => Promise<string>;
|
|
15
15
|
declare const linkTo: (idOrTitle: string | ((...args: any[]) => string), nameInput?: string | ((...args: any[]) => string)) => (...args: any[]) => void;
|
|
16
16
|
declare const withLinks: (...args: any) => any;
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
17
|
+
//#endregion
|
|
18
|
+
//#region code/addons/links/.dts-emit/code/addons/links/src/index.d.ts
|
|
19
|
+
declare function _default(): import("storybook/internal/csf").PreviewAddon<import("storybook/internal/csf").AddonTypes>;
|
|
20
|
+
//#endregion
|
|
21
|
+
export { _default as default, hrefTo, linkTo, navigate, withLinks };
|
package/dist/preview.d.ts
CHANGED
package/dist/react/index.d.ts
CHANGED
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { ComponentTitle, StoryKind, StoryName } from "storybook/internal/types";
|
|
2
|
+
import React, { PureComponent, ReactNode } from "react";
|
|
3
3
|
|
|
4
|
+
//#region code/addons/links/.dts-emit/code/addons/links/src/react/components/link.d.ts
|
|
4
5
|
interface Props {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
kind?: StoryKind;
|
|
7
|
+
title?: ComponentTitle;
|
|
8
|
+
story?: StoryName;
|
|
9
|
+
name?: StoryName;
|
|
10
|
+
children: ReactNode;
|
|
10
11
|
}
|
|
11
12
|
interface State {
|
|
12
|
-
|
|
13
|
+
href: string;
|
|
13
14
|
}
|
|
14
15
|
declare class LinkTo extends PureComponent<Props, State> {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
16
|
+
static defaultProps: Props;
|
|
17
|
+
state: State;
|
|
18
|
+
componentDidMount(): void;
|
|
19
|
+
componentDidUpdate(prevProps: Props): void;
|
|
20
|
+
updateHref: () => Promise<void>;
|
|
21
|
+
handleClick: () => void;
|
|
22
|
+
render(): React.JSX.Element;
|
|
22
23
|
}
|
|
23
|
-
|
|
24
|
-
export { LinkTo as default };
|
|
24
|
+
//#endregion
|
|
25
|
+
export { LinkTo as default };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/addon-links",
|
|
3
|
-
"version": "10.
|
|
3
|
+
"version": "10.6.0-alpha.1",
|
|
4
4
|
"description": "Storybook Links: Link stories together to build demos and prototypes with your UI components",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook",
|
|
@@ -56,12 +56,12 @@
|
|
|
56
56
|
"@storybook/global": "^5.0.0"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
-
"typescript": "^
|
|
59
|
+
"typescript": "^6.0.3"
|
|
60
60
|
},
|
|
61
61
|
"peerDependencies": {
|
|
62
62
|
"@types/react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
|
|
63
63
|
"react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
|
|
64
|
-
"storybook": "^10.
|
|
64
|
+
"storybook": "^10.6.0-alpha.1"
|
|
65
65
|
},
|
|
66
66
|
"peerDependenciesMeta": {
|
|
67
67
|
"@types/react": {
|