You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: develop-docs/frontend/component-library.mdx
+4-111Lines changed: 4 additions & 111 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,123 +23,16 @@ Stories is a custom docs framework served under the `/stories` path inside the m
23
23
-**Dev Access**<br />
24
24
Whether you are using `pnpm dev-ui` to start a development server, or `sentry devserver` to spin up all the services locally, you can access Stories by logging in and changing the path from `/issues/` (the default landing page) to `/stories/`.
25
25
26
+
## Contributing to Stories
27
+
28
+
For information on how to contribute to Stories, please see the [Contributing](https://sentry.sentry.io/stories/core/contributing/) section of the Stories documentation.
29
+
26
30
## Ownership
27
31
28
32
Stories for core components are owned by the Design Engineering team. Stories for general components are not nessicarily maintained by the original author or team of that component—if you are reading a story and notice a mistake or omission, consider it an opportunity to leave the docs in better shape than you found them!
29
33
30
34
The Design Engineering team is always available in the `#discuss-design-engineering` channel on Slack for questions or general feedback.
31
35
32
-
## Creating new Stories
33
-
34
-
### Using `.mdx`
35
-
36
-
The easiest way to document a single component is to create an `.mdx` file next to the component. For a new `myButton` component, the file can be named `index.mdx` or `myButton.mdx`.
37
-
38
-
```
39
-
components/
40
-
└── myButton/
41
-
├── index.tsx
42
-
└── index.mdx
43
-
```
44
-
45
-
The file can include the following frontmatter fields.
46
-
47
-
```yaml
48
-
---
49
-
title: My Button
50
-
description: MyButton is a clickable element that triggers an action.
51
-
source: 'sentry/components/myButton'
52
-
# optionally include links to figma, js, and a11y resources:
Components can include autogenerated API documentation using our [custom type-loader](https://github.com/getsentry/sentry/blob/master/static/app/stories/type-loader.ts) and exporting an object named `types`. The [inline loader syntax](https://rspack.rs/api/loader-api/inline) is weird, but it works.
A wrapper component to help demonstrate what the component looks like when the parent size is different or changing.<br />
113
-
By default uses `display:flex; overflow: hidden;` which can test responsive components well. Can also be set to `display: block; overflow: auto;`.<br />
Awrappercomponenttoisolatechildrenfromthecurrentthemeusedonthepage. Allowsquicklytogglinganexamplebetween<code>light</code>/<code>dark</code> without changing the whole screen (useful at night when you want most things in dark mode).<br/>
All code for the stories framework is built and maintained by Sentry's Design Engineering team. However, this tool is for all of us, so contributions are welcome! If you have ideas to improve the experience of discovering, reading, writing, or organizing stories, please share in the `#discuss-design-engineering` channel on Slack.
0 commit comments