@xyd-js/storybook 0.0.1-xyd.10 → 0.0.1-xyd.12
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/.storybook/main.ts +8 -9
- package/.storybook/styles.css +0 -5
- package/CHANGELOG.md +24 -0
- package/package.json +7 -8
- package/src/__fixtures__/atlas-index/package-index.mdx +194 -0
- package/src/{content → __fixtures__}/atlas-index/wip1.mdx +3 -3
- package/src/__fixtures__/example-source-uniform.ts +41 -0
- package/src/{content → __fixtures__}/hello-world.mdx +1 -1
- package/src/components/{DemoWireframe.tsx → DemoDocs.tsx} +1 -1
- package/src/decorators/DocsTemplate.tsx +23 -0
- package/src/docs/atlas/Atlas.stories.tsx +27 -18
- package/src/docs/components/coder/CodeSample.stories.tsx +6 -3
- package/src/docs/components/writer/Badge.stories.tsx +1 -2
- package/src/docs/components/writer/GuideCard.stories.tsx +2 -3
- package/src/docs/components/writer/Table.stories.tsx +22 -58
- package/src/docs/components/writer/Tabs.stories.tsx +55 -0
- package/src/docs/components/writer/TocCard.stories.tsx +30 -0
- package/src/docs/components/writer/UnderlineNav.stories.tsx +114 -0
- package/src/docs/components/writer/Update.stories.tsx +91 -0
- package/src/docs/components/writer/VideoGuide.stories.tsx +17 -0
- package/src/docs/themes/TODO.md +1 -0
- package/src/docs/themes/themes-designsystem.stories.tsx +3 -2
- package/src/docs/themes/themes.stories.tsx +6 -2
- package/src/docs/ui/Sidebar.stories.tsx +8 -2
- package/storybook-static/assets/Atlas.stories-CERP-lKH.js +153 -0
- package/storybook-static/assets/Badge.stories-DakswLpg.js +6 -0
- package/storybook-static/assets/Breadcrumbs.stories-wdrli8P8.js +21 -0
- package/storybook-static/assets/{Button.stories-BaoDkNl6.js → Button.stories-DnfjGLtF.js} +2 -2
- package/storybook-static/assets/CTABanner-DLG0_gv8-1gNhmGHe.js +4 -0
- package/storybook-static/assets/{CTABanner.stories-DeIwzLSu.js → CTABanner.stories-CmBj9U2A.js} +1 -1
- package/storybook-static/assets/Callout.stories-rp4kMO8N.js +16 -0
- package/storybook-static/assets/{CodeSample.stories-npLtCIKw.js → CodeSample.stories-R6WeHzql.js} +1 -1
- package/storybook-static/assets/CodeSample.stories-prKrGyG7.js +22 -0
- package/storybook-static/assets/Color-YHDXOIA2-D4kH6-fL.js +1 -0
- package/storybook-static/assets/DocsRenderer-CFRXHY34-DczdxYfS.js +575 -0
- package/storybook-static/assets/{GuideCard.stories-R-2HMLEF.js → GuideCard.stories-D2fmdhxW.js} +2 -2
- package/storybook-static/assets/Heading.stories-BwtFnfuE.js +40 -0
- package/storybook-static/assets/Icons-CaV53C2x.js +1 -0
- package/storybook-static/assets/Nav.stories-DOdsEXEe.js +13 -0
- package/storybook-static/assets/NavLinks.stories-v2TFSIgK.js +19 -0
- package/storybook-static/assets/Pre.stories-bsCA3tqM.js +11 -0
- package/storybook-static/assets/Sidebar.stories-Bo8NQxnh.js +9 -0
- package/storybook-static/assets/Steps.stories-CuIyGdUg.js +16 -0
- package/storybook-static/assets/SubNav.stories-gbx99ZSe.js +19 -0
- package/storybook-static/assets/Table.stories-B4EyLt9m.js +38 -0
- package/storybook-static/assets/Tabs.stories-CBSgQj02.js +42 -0
- package/storybook-static/assets/TocCard.stories-BgvJ6BbB.js +7 -0
- package/storybook-static/assets/UnderlineNav.stories-CBzxJ_ET.js +96 -0
- package/storybook-static/assets/Update-D5e_yqty-DsN8mVwO.js +33 -0
- package/storybook-static/assets/Update.stories-FtwGebQp.js +56 -0
- package/storybook-static/assets/VideoGuide.stories-BRSeChyH.js +3 -0
- package/storybook-static/assets/__vite-browser-external-FmFgRqLi.js +1 -0
- package/storybook-static/assets/_rollupPluginBabelHelpers-CiqSP2w--CY8sTQTJ.js +4 -0
- package/storybook-static/assets/{copy-C0mF-zfo.js → browser.esm-BWgQ7tuZ.js} +12 -12
- package/storybook-static/assets/chunk-NL6KNZEE-BC1iDMSp.js +3 -0
- package/storybook-static/assets/content-CLSEZPMe.js +8 -0
- package/storybook-static/assets/{entry-preview-VSbqQKti.js → entry-preview-BQ1RV56y.js} +2 -2
- package/storybook-static/assets/{entry-preview-docs-B1zb5AAd.js → entry-preview-docs-CxQPtM_Y.js} +1 -1
- package/storybook-static/assets/iframe-B1jb8VLQ.js +211 -0
- package/storybook-static/assets/{index-Ci6h_Amb.js → index-Bd6o6BX5.js} +2 -2
- package/storybook-static/assets/index-BsiG4v0x.js +3 -0
- package/storybook-static/assets/index-CXQShRbs.js +8 -0
- package/storybook-static/assets/index-CXwkSlW-.js +1 -0
- package/storybook-static/assets/index-CzKwSnp0.js +9 -0
- package/storybook-static/assets/index-D_kTjGoR.js +9 -0
- package/storybook-static/assets/index-DgnBCu_c.js +1 -0
- package/storybook-static/assets/{index-BxVt_j7t.js → index-H0MBf5rE.js} +1 -1
- package/storybook-static/assets/jsx-runtime-D_zvdyIk.js +9 -0
- package/storybook-static/assets/layouts-Jper_Qis.js +1 -0
- package/storybook-static/assets/preview-BBHl5jls.css +1 -0
- package/storybook-static/assets/preview-D6WjBDEw.js +2 -0
- package/storybook-static/assets/{preview-ik5anPOD.js → preview-N1j9pG9L.js} +1 -1
- package/storybook-static/assets/react-18-Tf4JhPOR.js +25 -0
- package/storybook-static/assets/test-utils-BaXAOqRT.js +9 -0
- package/storybook-static/assets/themes-designsystem.stories-COcmw0uR.js +11 -0
- package/storybook-static/assets/themes.stories-PoLDJGzT.js +41 -0
- package/storybook-static/assets/writer-2j4DdIYZ.js +1 -0
- package/storybook-static/iframe.html +1 -1
- package/storybook-static/index.html +1 -1
- package/storybook-static/index.json +1 -1
- package/storybook-static/project.json +1 -1
- package/storybook-static/sb-addons/chromatic-com-storybook-10/manager-bundle.js +15 -15
- package/storybook-static/sb-addons/docs-12/manager-bundle.js +34 -34
- package/storybook-static/sb-addons/essentials-actions-4/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/essentials-backgrounds-5/manager-bundle.js +8 -8
- package/storybook-static/sb-addons/essentials-controls-3/manager-bundle.js +8 -8
- package/storybook-static/sb-addons/essentials-measure-8/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/essentials-outline-9/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/essentials-toolbars-7/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/essentials-viewport-6/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/interactions-11/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/links-2/manager-bundle.js +1 -1
- package/storybook-static/sb-addons/onboarding-1/manager-bundle.js +5 -5
- package/storybook-static/sb-addons/storybook-core-core-server-presets-0/common-manager-bundle.js +1 -1
- package/storybook-static/sb-manager/globals-module-info.js +1 -0
- package/storybook-static/sb-manager/globals-runtime.js +10372 -9836
- package/storybook-static/sb-manager/runtime.js +119 -119
- package/tsconfig.json +17 -0
- package/vite.config.ts +1 -1
- package/src/content/atlas-index/package-index.mdx +0 -192
- package/src/docs/atlas/AtlasIndex.stories.tsx +0 -130
- package/storybook-static/assets/Atlas.stories-BJDXANWf.js +0 -252
- package/storybook-static/assets/AtlasIndex.stories-C-4vZswz.js +0 -41
- package/storybook-static/assets/Badge.stories-DSo7Lasr.js +0 -6
- package/storybook-static/assets/Breadcrumbs.stories-APB9UDIU.js +0 -21
- package/storybook-static/assets/CTABanner-n3vc4xW5-VHHsd4-C.js +0 -4
- package/storybook-static/assets/Callout.stories-ESozWgIi.js +0 -16
- package/storybook-static/assets/CodeSample-Dkob5gWa-CI-Jdg_T-FUmAtsNF.js +0 -9
- package/storybook-static/assets/CodeSample.stories-DNLDwmyz.js +0 -22
- package/storybook-static/assets/Color-YHDXOIA2-D-wdyPVE.js +0 -1
- package/storybook-static/assets/DocsRenderer-CFRXHY34-CIYeQ6fu.js +0 -575
- package/storybook-static/assets/Heading.stories-CHw8GXC6.js +0 -40
- package/storybook-static/assets/Nav.stories-BeFIh2Vg.js +0 -13
- package/storybook-static/assets/NavLinks.stories-DxWAb2TV.js +0 -19
- package/storybook-static/assets/Pre.stories-CR1zlLen.js +0 -11
- package/storybook-static/assets/Sidebar.stories-B-5LyJIe.js +0 -9
- package/storybook-static/assets/Steps.stories-Bg2orGdz.js +0 -16
- package/storybook-static/assets/SubNav.stories-B1aQLvvq.js +0 -19
- package/storybook-static/assets/Table.stories-DxxdJGx9.js +0 -72
- package/storybook-static/assets/UnderlineNav-9lJPvnIp-I5-GGpts.js +0 -48
- package/storybook-static/assets/_rollupPluginBabelHelpers-C8nLsqZ7-DyHbsKhl.js +0 -4
- package/storybook-static/assets/chevron-right-B9VhLASW.js +0 -31
- package/storybook-static/assets/chunk-K6AXKMTT-BnQROexa.js +0 -12
- package/storybook-static/assets/content-C0yN9Wvw.js +0 -22
- package/storybook-static/assets/iframe-3uG_AAyK.js +0 -211
- package/storybook-static/assets/index-0nua7n0t.js +0 -1
- package/storybook-static/assets/index-B7gF9TUu.js +0 -9
- package/storybook-static/assets/index-C2_NlWRN.js +0 -8
- package/storybook-static/assets/index-D1ZprCIH.js +0 -9
- package/storybook-static/assets/index-po7oPx12.js +0 -16
- package/storybook-static/assets/jsx-runtime-BjG_zV1W.js +0 -9
- package/storybook-static/assets/layouts-CzEI4S2T.js +0 -26
- package/storybook-static/assets/preview-BDbHSxwO.css +0 -1
- package/storybook-static/assets/preview-BLZCCP69.js +0 -2
- package/storybook-static/assets/react-18-BsB9_d4u.js +0 -25
- package/storybook-static/assets/test-utils-LZCCjomP.js +0 -9
- package/storybook-static/assets/themes-designsystem.stories-DsoSBFrP.js +0 -11
- package/storybook-static/assets/themes.stories-CGSgiZ_W.js +0 -41
- package/storybook-static/assets/writer-DhJZ-Wpq.js +0 -4
- /package/src/{content → __fixtures__}/Icons.tsx +0 -0
- /package/src/{content → __fixtures__}/atlas-index.mdx +0 -0
- /package/src/{content → __fixtures__}/code-sample.mdx +0 -0
- /package/storybook-static/assets/{preview-ChdjpSTW.js → preview-ppqJ5XSc.js} +0 -0
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
import React, {useState, useEffect} from 'react';
|
|
2
|
-
import type {Meta} from '@storybook/react';
|
|
3
|
-
|
|
4
|
-
import {Reference} from '@xyd-js/uniform';
|
|
5
|
-
import {
|
|
6
|
-
CodeSample,
|
|
7
|
-
} from '@xyd-js/components/coder';
|
|
8
|
-
import {
|
|
9
|
-
TableV2
|
|
10
|
-
} from "@xyd-js/components/writer";
|
|
11
|
-
import {LayoutPrimary} from "@xyd-js/components/layouts";
|
|
12
|
-
import getContentComponents from "@xyd-js/components/content"
|
|
13
|
-
import {AtlasIndex} from "@xyd-js/atlas/atlas-index"
|
|
14
|
-
|
|
15
|
-
import PackageIndexWip1Content from "../../content/atlas-index/wip1.mdx"
|
|
16
|
-
|
|
17
|
-
import {
|
|
18
|
-
DemoNavbar,
|
|
19
|
-
DemoSubNav,
|
|
20
|
-
DemoSidebar,
|
|
21
|
-
DemoContent,
|
|
22
|
-
DemoTOC
|
|
23
|
-
} from "../../components/DemoWireframe";
|
|
24
|
-
|
|
25
|
-
export default {
|
|
26
|
-
title: 'Atlas/AtlasIndex',
|
|
27
|
-
component: AtlasIndex,
|
|
28
|
-
} as Meta;
|
|
29
|
-
|
|
30
|
-
const contentComponents = getContentComponents()
|
|
31
|
-
|
|
32
|
-
const Content = {
|
|
33
|
-
Text: contentComponents.p,
|
|
34
|
-
Details: contentComponents.Details,
|
|
35
|
-
IconQuote: contentComponents.IconQuote,
|
|
36
|
-
Code: contentComponents.code,
|
|
37
|
-
Heading1: contentComponents.h1,
|
|
38
|
-
Heading2: contentComponents.h2,
|
|
39
|
-
Container: contentComponents.Content,
|
|
40
|
-
CodeSample: contentComponents.CodeSample
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export const Default = () => {
|
|
44
|
-
return <LayoutPrimary
|
|
45
|
-
header={<DemoNavbar/>}
|
|
46
|
-
subheader={<DemoSubNav/>}
|
|
47
|
-
aside={<DemoSidebar/>}
|
|
48
|
-
content={<>
|
|
49
|
-
{/*<FakeContent/>*/}
|
|
50
|
-
<AtlasIndex data={exampleUniform}/>
|
|
51
|
-
</>}
|
|
52
|
-
contentNav={<DemoTOC/>}
|
|
53
|
-
layoutSize="large"
|
|
54
|
-
/>
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
function FakeContent() {
|
|
58
|
-
return <DemoContent breadcrumbs={false}>
|
|
59
|
-
{<PackageIndexWip1Content components={{
|
|
60
|
-
...contentComponents,
|
|
61
|
-
pre: Pre,
|
|
62
|
-
TableV2
|
|
63
|
-
}}/>}
|
|
64
|
-
</DemoContent>
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
function Pre({children, ...rest}: { children: React.ReactNode }) {
|
|
68
|
-
const codeElement = children as any
|
|
69
|
-
if (!children) {
|
|
70
|
-
return null
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
const {className, children: codeChildren} = codeElement.props;
|
|
74
|
-
const language = className?.replace('language-', '') || '';
|
|
75
|
-
const codeContent = codeChildren || '';
|
|
76
|
-
|
|
77
|
-
return <CodeSample
|
|
78
|
-
name={language}
|
|
79
|
-
description={""}
|
|
80
|
-
codeblocks={[
|
|
81
|
-
{
|
|
82
|
-
value: codeContent,
|
|
83
|
-
lang: language,
|
|
84
|
-
meta: language,
|
|
85
|
-
}
|
|
86
|
-
]}
|
|
87
|
-
size="full"
|
|
88
|
-
kind="secondary"
|
|
89
|
-
/>
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
const exampleUniform = {
|
|
93
|
-
"title": "Function gqlSchemaToReferences",
|
|
94
|
-
"canonical": "fn-gqlSchemaToReferences",
|
|
95
|
-
"description": "Converts a GraphQL schema file to references.\n",
|
|
96
|
-
"context": {
|
|
97
|
-
"fileName": "index.ts",
|
|
98
|
-
"fileFullPath": "src/index.ts",
|
|
99
|
-
"line": 48,
|
|
100
|
-
"col": 16,
|
|
101
|
-
"signatureText": "export function gqlSchemaToReferences(schemaLocation: string): Promise<[\n]>;",
|
|
102
|
-
"sourcecode": "export function gqlSchemaToReferences(\n schemaLocation: string\n): Promise<[]> {\n if (schemaLocation.endsWith(\".graphql\")) {\n return Promise.resolve([])\n }\n\n return Promise.resolve([])\n}",
|
|
103
|
-
"package": "@xyd-sources-examples/package-a"
|
|
104
|
-
},
|
|
105
|
-
"examples": {
|
|
106
|
-
"groups": []
|
|
107
|
-
},
|
|
108
|
-
"definitions": [
|
|
109
|
-
{
|
|
110
|
-
"title": "Returns",
|
|
111
|
-
"properties": [
|
|
112
|
-
{
|
|
113
|
-
"name": "",
|
|
114
|
-
"type": "<Promise>",
|
|
115
|
-
"description": "references\n"
|
|
116
|
-
}
|
|
117
|
-
]
|
|
118
|
-
},
|
|
119
|
-
{
|
|
120
|
-
"title": "Parameters",
|
|
121
|
-
"properties": [
|
|
122
|
-
{
|
|
123
|
-
"name": "schemaLocation",
|
|
124
|
-
"type": "string",
|
|
125
|
-
"description": "The location of the schema file.\n"
|
|
126
|
-
}
|
|
127
|
-
]
|
|
128
|
-
}
|
|
129
|
-
]
|
|
130
|
-
} as Reference
|