Skip to content

Commit

Permalink
docs: apply standard design to annotation storybook (#1061)
Browse files Browse the repository at this point in the history
The story for annotation missed the standard design. Applying it makes it more beautiful.
  • Loading branch information
ronnyroeller committed Aug 16, 2021
1 parent 163533d commit 2099532
Showing 1 changed file with 9 additions and 5 deletions.
@@ -1,3 +1,5 @@
import 'remirror/styles/all.css';

import { FC, useEffect, useMemo, useState } from 'react';
import { uniqueId } from 'remirror';
import {
Expand Down Expand Up @@ -66,7 +68,7 @@ const Popup: FC = () => {
};

const SmallEditor: FC = () => {
const { getRootProps, setContent, commands, helpers } = useRemirrorContext({
const { setContent, commands, helpers } = useRemirrorContext({
autoUpdate: true,
});

Expand Down Expand Up @@ -106,7 +108,7 @@ const SmallEditor: FC = () => {

return (
<div>
<div {...getRootProps()} />
<EditorComponent />
<Popup />
<div>Annotations:</div>
<pre>{JSON.stringify(helpers.getAnnotations(), null, ' ')}</pre>
Expand All @@ -118,9 +120,11 @@ export const Basic = () => {
const { manager } = useRemirror({ extensions: () => [new AnnotationExtension()] });

return (
<Remirror manager={manager}>
<SmallEditor />
</Remirror>
<ThemeProvider>
<Remirror manager={manager}>
<SmallEditor />
</Remirror>
</ThemeProvider>
);
};

Expand Down

1 comment on commit 2099532

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 Published on https://remirror.io as production
🚀 Deployed on https://611aaa15a47942008dad453a--remirror.netlify.app

Please sign in to comment.