mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-11-05 06:50:28 +03:00
Add code block language header and improve styles (#2403)
Some checks failed
Deploy to Netlify (dev) / Deploy to Netlify (push) Has been cancelled
Some checks failed
Deploy to Netlify (dev) / Deploy to Netlify (push) Has been cancelled
* add code block language header and improve styles * improve codeblock fallback text * move floating expand button to code block header * reduce code font size
This commit is contained in:
parent
d8d4714370
commit
31942b1114
3 changed files with 123 additions and 99 deletions
|
|
@ -157,12 +157,12 @@ export function RenderElement({ attributes, element, children }: RenderElementPr
|
|||
<Text as="pre" className={css.CodeBlock} {...attributes}>
|
||||
<Scroll
|
||||
direction="Horizontal"
|
||||
variant="Secondary"
|
||||
variant="SurfaceVariant"
|
||||
size="300"
|
||||
visibility="Hover"
|
||||
hideTrack
|
||||
>
|
||||
<div className={css.CodeBlockInternal()}>{children}</div>
|
||||
<div className={css.CodeBlockInternal}>{children}</div>
|
||||
</Scroll>
|
||||
</Text>
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue