-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ee3cd5f
commit 1515782
Showing
53 changed files
with
297 additions
and
384 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
--- | ||
hero: | ||
title: Readme <b>Generator</b> | ||
description: Generate an aesthetically pleasing product README through intelligent methods | ||
title: Readme <b>Wizard</b> | ||
description: Generate lobe style product README by MAGIC ~ 🪄 | ||
--- | ||
|
||
<code src="./index.tsx" inline></code> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,10 @@ | ||
import { ReadmeHero } from '@lobehub/readme-generator'; | ||
import { Center } from 'react-layout-kit'; | ||
|
||
export default () => { | ||
return <Center gap={16}></Center>; | ||
return ( | ||
<Center gap={16} style={{ marginTop: '-8em', maxWidth: 960 }}> | ||
<ReadmeHero /> | ||
</Center> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,14 +5,4 @@ title: Credits | |
order: 6 | ||
--- | ||
|
||
## Generator | ||
|
||
<br/> | ||
|
||
<code src="./index.tsx" inline></code> | ||
|
||
<br/> | ||
|
||
## Feedback | ||
|
||
<br/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,32 @@ | ||
import { memo } from 'react'; | ||
import { useControls, useCreateStore } from '@lobehub/ui'; | ||
import { memo, useMemo, useState } from 'react'; | ||
|
||
import MarkdownEditor from '@/components/MarkdownEditor'; | ||
import MarkdownStorybook from '@/components/MarkdownStorybook'; | ||
import { creditsSample } from '@/const/sample'; | ||
import MarkdownEditor from '@/features/MarkdownEditor'; | ||
import { addBackToTop } from '@/utils/addBackTopTop'; | ||
import { genMarkdownCredits } from '@/services/genMarkdownCredits'; | ||
|
||
const controls = { | ||
/* eslint-disable sort-keys-fix/sort-keys-fix */ | ||
title: 'Links', | ||
backToTop: true, | ||
/* eslint-enable */ | ||
}; | ||
|
||
const Credits = memo(() => { | ||
return <MarkdownEditor>{addBackToTop([creditsSample, '']).join('\n\n')}</MarkdownEditor>; | ||
const [value, setValue] = useState(creditsSample); | ||
const store = useCreateStore(); | ||
|
||
const options = useControls(controls, { store }); | ||
|
||
const md = useMemo(() => genMarkdownCredits(options, value), [value, options]); | ||
|
||
return ( | ||
<> | ||
<MarkdownEditor onChange={setValue} value={value} /> | ||
<MarkdownStorybook levaStore={store}>{md.join('\n\n')}</MarkdownStorybook> | ||
</> | ||
); | ||
}); | ||
|
||
export default Credits; |
Oops, something went wrong.