Restructure help dialog (#484)

- restructured help dialog
- moved isMac function to editor util
- added notice to CHANGELOG.md

Co-authored-by: Erik Michelson <github@erik.michelson.eu>
Co-authored-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de>
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
Philip Molares 2020-08-26 18:49:46 +02:00 committed by GitHub
parent c95a7e0fba
commit dfdc652503
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 422 additions and 368 deletions

View file

@ -47,6 +47,7 @@
- Use [Twemoji](https://twemoji.twitter.com/) as icon font - Use [Twemoji](https://twemoji.twitter.com/) as icon font
- The `[name=...]`, `[time=...]` and `[color=...]` tags may now be used anywhere in the document and not just inside of blockquotes and lists. - The `[name=...]`, `[time=...]` and `[color=...]` tags may now be used anywhere in the document and not just inside of blockquotes and lists.
- The <i class="fa fa-picture-o"/> (add image) and <i class="fa fa-link"/> (add link) toolbar buttons, put selected links directly in the `()` instead of the `[]` part of the generated markdown - The <i class="fa fa-picture-o"/> (add image) and <i class="fa fa-link"/> (add link) toolbar buttons, put selected links directly in the `()` instead of the `[]` part of the generated markdown
- The help dialog has multiple tabs, and is a bit more organized.
--- ---

View file

@ -143,6 +143,20 @@
"placeholder": "← Start by entering a title here\n===\nVisit the features page if you don't know what to do.\nHappy hacking :)", "placeholder": "← Start by entering a title here\n===\nVisit the features page if you don't know what to do.\nHappy hacking :)",
"invalidYaml": "The yaml-header is invalid. See <0></0> for more information.", "invalidYaml": "The yaml-header is invalid. See <0></0> for more information.",
"help": { "help": {
"shortcuts": {
"title": "Shortcuts",
"bold": "Make selection bold",
"italic": "Make selection italic",
"underline": "Underline selection",
"strikethrough": "Strike selection through",
"mark": "Mark selection",
"view": "Show only View",
"both": "Show View and Edit",
"edit": "Show only Edit"
},
"links": {
"title": "Links"
},
"contacts": { "contacts": {
"title": "Contacts", "title": "Contacts",
"community": "Join the community", "community": "Join the community",
@ -161,9 +175,7 @@
"example": "Example", "example": "Example",
"syntax": "Syntax", "syntax": "Syntax",
"exampleAlert": "This is an alert area.", "exampleAlert": "This is an alert area.",
"underlinedText": "Underlined text", "highlightedText": "Highlight"
"highlightedText": "Highlighted text",
"externalService": "Externals"
} }
}, },
"error": { "error": {

View file

@ -13,7 +13,7 @@ import { SyncScrollButton } from './sync-scroll-button/sync-scroll-button'
import { EditorPathParams } from '../editor' import { EditorPathParams } from '../editor'
import { DarkModeButton } from './dark-mode-button' import { DarkModeButton } from './dark-mode-button'
import { EditorViewMode } from './editor-view-mode' import { EditorViewMode } from './editor-view-mode'
import { HelpButton } from './help-button' import { HelpButton } from './help-button/help-button'
import { NavbarBranding } from './navbar-branding' import { NavbarBranding } from './navbar-branding'
export const AppBar: React.FC = () => { export const AppBar: React.FC = () => {

View file

@ -1,291 +0,0 @@
import React, { Fragment, useState } from 'react'
import { Button, Card, Col, Modal, Row, Table } from 'react-bootstrap'
import { Trans, useTranslation } from 'react-i18next'
import { ForkAwesomeIcon } from '../../common/fork-awesome/fork-awesome-icon'
import { TranslatedExternalLink } from '../../common/links/translated-external-link'
export const HelpButton: React.FC = () => {
const { t } = useTranslation()
const [show, setShow] = useState(false)
const handleShow = () => setShow(true)
const handleClose = () => setShow(false)
return (
<Fragment>
<Button title={t('editor.documentBar.help')} className="ml-2 text-secondary" size="sm" variant="outline-light"
onClick={handleShow}>
<ForkAwesomeIcon icon="question-circle"/>
</Button>
<Modal show={show} onHide={handleClose} animation={true} className="text-dark" size='lg'>
<Modal.Header closeButton>
<Modal.Title>
<ForkAwesomeIcon icon="question-circle"/> <Trans i18nKey={'editor.documentBar.help'}/>
</Modal.Title>
</Modal.Header>
<Modal.Body className="text-dark">
<Row>
<Col lg={4}>
<Card>
<Card.Header><Trans i18nKey='editor.help.contacts.title'/></Card.Header>
<Card.Body>
<Card.Text>
<ul className="list-unstyled">
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.community'
href='https://community.codimd.org/'
icon='users'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.meetUsOn'
i18nOption={{ service: 'Matrix' }}
href='https://riot.im/app/#/room/#codimd:matrix.org'
icon='hashtag'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.reportIssue'
href='https://github.com/codimd/server/issues'
icon='tag'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.helpTranslating'
href='https://translate.codimd.org/'
icon='language'
className='text-primary'
/>
</li>
</ul>
</Card.Text>
</Card.Body>
</Card>
<br/>
<Card>
<Card.Header><Trans i18nKey='editor.help.documents.title'/></Card.Header>
<Card.Body>
<Card.Text>
<ul className="list-unstyled">
<li>
<TranslatedExternalLink
i18nKey='editor.help.documents.features'
href='/n/features'
icon='dot-circle-o'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.documents.yamlMetadata'
href='/n/yaml-data'
icon='dot-circle-o'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.documents.slideExample'
href='https://github.com/codimd/server/issues'
icon='dot-circle-o'
className='text-primary'
/>
</li>
</ul>
</Card.Text>
</Card.Body>
</Card>
</Col>
<Col lg={8}>
<Card>
<Card.Header><Trans i18nKey='editor.help.cheatsheet.title'/></Card.Header>
<Card.Body>
<Card.Text>
<Table className="table-condensed table-cheatsheet">
<thead>
<tr>
<td><Trans i18nKey='editor.help.cheatsheet.example'/></td>
<td><Trans i18nKey='editor.help.cheatsheet.syntax'/></td>
</tr>
</thead>
<tbody className="markdown-body"
style={{ fontFamily: 'inherit', fontSize: '14px', padding: 0, maxWidth: 'inherit' }}>
<tr>
<td><Trans i18nKey='editor.editorToolbar.header'/></td>
<td>
<pre># <Trans i18nKey='editor.editorToolbar.header'/></pre>
</td>
</tr>
<tr>
<td>
<ul>
<li><Trans i18nKey='editor.editorToolbar.unorderedList'/></li>
</ul>
</td>
<td>
<pre>- <Trans i18nKey='editor.editorToolbar.unorderedList'/></pre>
</td>
</tr>
<tr>
<td>
<ol>
<li><Trans i18nKey='editor.editorToolbar.orderedList'/></li>
</ol>
</td>
<td>
<pre>1. <Trans i18nKey='editor.editorToolbar.orderedList'/></pre>
</td>
</tr>
<tr>
<td>
<ul>
<li className="task-list-item">
<input type="checkbox" className="task-list-item-checkbox" disabled={false}/>
<label><Trans i18nKey='editor.editorToolbar.checkList'/></label>
</li>
</ul>
</td>
<td>
<pre>- [ ] <Trans i18nKey='editor.editorToolbar.checkList'/></pre>
</td>
</tr>
<tr>
<td>
<blockquote><Trans i18nKey='editor.editorToolbar.blockquote'/></blockquote>
</td>
<td>
<pre>{'>'} <Trans i18nKey='editor.editorToolbar.blockquote'/></pre>
</td>
</tr>
<tr>
<td><strong><Trans i18nKey='editor.editorToolbar.bold'/></strong></td>
<td>
<pre>**<Trans i18nKey='editor.editorToolbar.bold'/>**</pre>
</td>
</tr>
<tr>
<td><i><Trans i18nKey='editor.editorToolbar.italic'/></i></td>
<td>
<pre>*<Trans i18nKey='editor.editorToolbar.italic'/>*</pre>
</td>
</tr>
<tr>
<td><s><Trans i18nKey='editor.editorToolbar.strikethrough'/></s></td>
<td>
<pre>~~<Trans i18nKey='editor.editorToolbar.strikethrough'/>~~</pre>
</td>
</tr>
<tr>
<td>19<sup>th</sup></td>
<td>
<pre>19^th^</pre>
</td>
</tr>
<tr>
<td>H<sub>2</sub>O</td>
<td>
<pre>H~2~O</pre>
</td>
</tr>
<tr>
<td>
<ins><Trans i18nKey='editor.help.cheatsheet.underlinedText'/></ins>
</td>
<td>
<pre>++<Trans i18nKey='editor.help.cheatsheet.underlinedText'/>++</pre>
</td>
</tr>
<tr>
<td>
<mark><Trans i18nKey='editor.help.cheatsheet.highlightedText'/></mark>
</td>
<td>
<pre>==<Trans i18nKey='editor.help.cheatsheet.highlightedText'/>==</pre>
</td>
</tr>
<tr>
<td><a href='https://example.com'><Trans i18nKey='editor.editorToolbar.link'/></a></td>
<td>
<pre>[link text](https://example.com)</pre>
</td>
</tr>
<tr>
<td><Trans i18nKey='editor.editorToolbar.image'/></td>
<td>
<pre>![image alt](https:// "title")</pre>
</td>
</tr>
<tr>
<td><code><Trans i18nKey='editor.editorToolbar.code'/></code></td>
<td>
<pre>`<Trans i18nKey='editor.editorToolbar.code'/>`</pre>
</td>
</tr>
<tr>
<td>
<pre style={{ border: 'none !important' }}>
<code className="javascript hljs">
<div className="wrapper">
<div className="gutter linenumber">
<span data-linenumber="1"/>
</div>
<div className="code">
<span className="hljs-keyword">var</span> x = <span className="hljs-number">5</span>;
</div>
</div>
</code>
</pre>
</td>
<td>
<pre>```javascript<br/>var x = 5;<br/>```</pre>
</td>
</tr>
<tr>
<td><img alt=":smile:" className="emoji" src="./build/emojify.js/dist/images/basic/smile.png"
title=":smile:"/></td>
<td>
<pre>:smile:</pre>
</td>
</tr>
<tr>
<td>Extern</td>
<td>
<pre>{'{'}%youtube youtube_id %{'}'}</pre>
</td>
</tr>
<tr>
<td>L<sup>a</sup>T<sub>e</sub>X</td>
<td>
<pre>$L^aT_eX$</pre>
</td>
</tr>
<tr>
<td>
<div className="alert alert-info">
<p>
<Trans i18nKey='editor.help.cheatsheet.exampleAlert'/>
</p>
</div>
</td>
<td>
<pre>:::info<br/><Trans i18nKey='editor.help.cheatsheet.exampleAlert'/><br/>:::</pre>
</td>
</tr>
</tbody>
</Table>
</Card.Text>
</Card.Body>
</Card>
</Col>
</Row>
</Modal.Body>
</Modal>
</Fragment>
)
}

View file

@ -0,0 +1,3 @@
.table-cheatsheet > tr > td {
vertical-align: middle !important;
}

View file

@ -0,0 +1,61 @@
import React from 'react'
import { Table } from 'react-bootstrap'
import { Trans, useTranslation } from 'react-i18next'
import { MarkdownRenderer } from '../../../markdown-renderer/markdown-renderer'
import { HighlightedCode } from '../../../markdown-renderer/replace-components/highlighted-fence/highlighted-code/highlighted-code'
import './cheatsheet.scss'
export const Cheatsheet: React.FC = () => {
const { t } = useTranslation()
const codes = [
`**${t('editor.editorToolbar.bold')}**`,
`*${t('editor.editorToolbar.italic')}*`,
`++${t('editor.editorToolbar.underline')}++`,
`~~${t('editor.editorToolbar.strikethrough')}~~`,
'H~2~O',
'19^th^',
`==${t('editor.help.cheatsheet.highlightedText')}==`,
`# ${t('editor.editorToolbar.header')}`,
`\`${t('editor.editorToolbar.code')}\``,
'```javascript=\nvar x = 5;\n```',
`> ${t('editor.editorToolbar.blockquote')}`,
`- ${t('editor.editorToolbar.unorderedList')}`,
`1. ${t('editor.editorToolbar.orderedList')}`,
`- [ ] ${t('editor.editorToolbar.checkList')}`,
`[${t('editor.editorToolbar.link')}](https://example.com)`,
`![${t('editor.editorToolbar.image')}](/icons/mstile-70x70.png)`,
':smile:',
`:::info\n${t('editor.help.cheatsheet.exampleAlert')}\n:::`
]
return (
<Table className="table-condensed table-cheatsheet">
<thead>
<tr>
<th><Trans i18nKey='editor.help.cheatsheet.example'/></th>
<th><Trans i18nKey='editor.help.cheatsheet.syntax'/></th>
</tr>
</thead>
<tbody>
{codes.map((code, key) => {
return (
<tr key={key}>
<td>
<MarkdownRenderer
content={code}
wide={false}
onTocChange={() => false}
onMetaDataChange={() => false}
onFirstHeadingChange={() => false}
onLineMarkerPositionChanged={() => false}
/>
</td>
<td>
<HighlightedCode code={code} wrapLines={true} startLineNumber={1} language={'markdown'}/>
</td>
</tr>
)
})}
</tbody>
</Table>
)
}

View file

@ -0,0 +1,72 @@
import React, { Fragment, useState } from 'react'
import { Button, Modal } from 'react-bootstrap'
import { Trans, useTranslation } from 'react-i18next'
import { ForkAwesomeIcon } from '../../../common/fork-awesome/fork-awesome-icon'
import { Cheatsheet } from './cheatsheet'
import { Links } from './links'
import { Shortcut } from './shortcuts'
enum HelpTabStatus {
Cheatsheet='cheatsheet.title',
Shortcuts='shortcuts.title',
Links='links.title'
}
export const HelpButton: React.FC = () => {
const { t } = useTranslation()
const [show, setShow] = useState(false)
const [tab, setTab] = useState<HelpTabStatus>(HelpTabStatus.Cheatsheet)
const tabContent = (): React.ReactElement => {
switch (tab) {
case HelpTabStatus.Cheatsheet:
return (<Cheatsheet/>)
case HelpTabStatus.Shortcuts:
return (<Shortcut/>)
case HelpTabStatus.Links:
return (<Links/>)
}
}
return (
<Fragment>
<Button title={t('editor.documentBar.help')} className="ml-2 text-secondary" size="sm" variant="outline-light"
onClick={() => setShow(true)}>
<ForkAwesomeIcon icon="question-circle"/>
</Button>
<Modal show={show} onHide={() => setShow(false)} animation={true} className="text-dark" size='xl'>
<Modal.Header closeButton>
<Modal.Title>
<ForkAwesomeIcon icon="question-circle"/> <Trans i18nKey={'editor.documentBar.help'}/> <Trans i18nKey={`editor.help.${tab}`}/>
</Modal.Title>
</Modal.Header>
<Modal.Body className="text-dark">
<ul className='nav nav-tabs'>
<li className='nav-item'>
<button className={`nav-link ${tab === HelpTabStatus.Cheatsheet ? 'active' : ''}`}
onClick={() => setTab(HelpTabStatus.Cheatsheet)}
>
<Trans i18nKey={'editor.help.cheatsheet.title'}/>
</button>
</li>
<li className='nav-item'>
<button className={`nav-link ${tab === HelpTabStatus.Shortcuts ? 'active' : ''}`}
onClick={() => setTab(HelpTabStatus.Shortcuts)}
>
<Trans i18nKey={'editor.help.shortcuts.title'}/>
</button>
</li>
<li className='nav-item'>
<button className={`nav-link ${tab === HelpTabStatus.Links ? 'active' : ''}`}
onClick={() => setTab(HelpTabStatus.Links)}
>
<Trans i18nKey={'editor.help.links.title'}/>
</button>
</li>
</ul>
{tabContent()}
</Modal.Body>
</Modal>
</Fragment>
)
}

View file

@ -0,0 +1,84 @@
import React from 'react'
import { Col, Row } from 'react-bootstrap'
import { Trans, useTranslation } from 'react-i18next'
import { TranslatedExternalLink } from '../../../common/links/translated-external-link'
import { TranslatedInternalLink } from '../../../common/links/translated-internal-link'
export const Links: React.FC = () => {
useTranslation()
return (
<Row className={'justify-content-center pt-4'}>
<Col lg={4}>
<h3><Trans i18nKey='editor.help.contacts.title'/></h3>
<div>
<ul className="list-unstyled">
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.community'
href='https://community.codimd.org/'
icon='users'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.meetUsOn'
i18nOption={{ service: 'Matrix' }}
href='https://riot.im/app/#/room/#codimd:matrix.org'
icon='hashtag'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.reportIssue'
href='https://github.com/codimd/server/issues'
icon='tag'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.contacts.helpTranslating'
href='https://translate.codimd.org/'
icon='language'
className='text-primary'
/>
</li>
</ul>
</div>
</Col>
<Col lg={4}>
<h3><Trans i18nKey='editor.help.documents.title'/></h3>
<div>
<ul className="list-unstyled">
<li>
<TranslatedInternalLink
i18nKey='editor.help.documents.features'
href='/n/features'
icon='dot-circle-o'
className='text-primary'
/>
</li>
<li>
<TranslatedInternalLink
i18nKey='editor.help.documents.yamlMetadata'
href='/n/yaml-data'
icon='dot-circle-o'
className='text-primary'
/>
</li>
<li>
<TranslatedExternalLink
i18nKey='editor.help.documents.slideExample'
href='https://github.com/codimd/server/issues'
icon='dot-circle-o'
className='text-primary'
/>
</li>
</ul>
</div>
</Col>
</Row>
)
}

View file

@ -0,0 +1,44 @@
import React from 'react'
import { Card, ListGroup, Row } from 'react-bootstrap'
import { Trans } from 'react-i18next'
import { isMac } from '../../utils'
export const Shortcut: React.FC = () => {
const modifierKey = isMac ? <kbd>Cmd</kbd> : <kbd>Ctrl</kbd>
const shortcutMap: {[category: string]: { [functionName: string]: JSX.Element[] }} = {
'View Mode': {
'editor.help.shortcuts.view': [modifierKey, <> + </>, <kbd>Alt</kbd>, <> + </>, <kbd>V</kbd>],
'editor.help.shortcuts.both': [modifierKey, <> + </>, <kbd>Alt</kbd>, <> + </>, <kbd>B</kbd>],
'editor.help.shortcuts.edit': [modifierKey, <> + </>, <kbd>Alt</kbd>, <> + </>, <kbd>E</kbd>]
},
Editor: {
'editor.help.shortcuts.bold': [modifierKey, <> + </>, <kbd>B</kbd>],
'editor.help.shortcuts.italic': [modifierKey, <> + </>, <kbd>I</kbd>],
'editor.help.shortcuts.underline': [modifierKey, <> + </>, <kbd>U</kbd>],
'editor.help.shortcuts.strikethrough': [modifierKey, <> + </>, <kbd>D</kbd>],
'editor.help.shortcuts.mark': [modifierKey, <> + </>, <kbd>M</kbd>]
}
}
return (
<Row className={'justify-content-center pt-4'}>
{Object.keys(shortcutMap).map(category => {
return (
<Card className={'m-2 w-50'}>
<Card.Header>{category}</Card.Header>
<ListGroup variant="flush">
{Object.entries(shortcutMap[category]).map(([functionName, shortcut]) => {
return (
<ListGroup.Item className={'d-flex justify-content-between'}>
<span><Trans i18nKey={functionName}/></span>
<span>{shortcut}</span>
</ListGroup.Item>
)
})}
</ListGroup>
</Card>)
})
}
</Row>
)
}

View file

@ -82,7 +82,7 @@ export const DocumentRenderPane: React.FC<DocumentRenderPaneProps & ScrollProps>
ref={renderer} onScroll={userScroll} onMouseEnter={onMakeScrollSource} > ref={renderer} onScroll={userScroll} onMouseEnter={onMakeScrollSource} >
<div className={'col-md'}/> <div className={'col-md'}/>
<MarkdownRenderer <MarkdownRenderer
className={'flex-fill'} className={'flex-fill mb-3'}
content={content} content={content}
wide={wide} wide={wide}
onTocChange={(tocAst) => setTocAst(tocAst)} onTocChange={(tocAst) => setTocAst(tocAst)}

View file

@ -1,4 +1,5 @@
import CodeMirror, { Editor, KeyMap, Pass } from 'codemirror' import CodeMirror, { Editor, KeyMap, Pass } from 'codemirror'
import { isMac } from '../utils'
import { import {
makeSelectionBold, makeSelectionBold,
makeSelectionItalic, makeSelectionItalic,
@ -7,8 +8,6 @@ import {
underlineSelection underlineSelection
} from './tool-bar/utils/toolbarButtonUtils' } from './tool-bar/utils/toolbarButtonUtils'
const isMac = navigator.platform.toLowerCase().includes('mac')
const isVim = (keyMapName?: string) => (keyMapName?.substr(0, 3) === 'vim') const isVim = (keyMapName?: string) => (keyMapName?.substr(0, 3) === 'vim')
const f10 = (editor: Editor): void | typeof Pass => editor.setOption('fullScreen', !editor.getOption('fullScreen')) const f10 = (editor: Editor): void | typeof Pass => editor.setOption('fullScreen', !editor.getOption('fullScreen'))

View file

@ -0,0 +1 @@
export const isMac = navigator.platform.toLowerCase().includes('mac')

View file

@ -26,8 +26,8 @@ import { Alert } from 'react-bootstrap'
import ReactHtmlParser, { convertNodeToElement, Transform } from 'react-html-parser' import ReactHtmlParser, { convertNodeToElement, Transform } from 'react-html-parser'
import { Trans } from 'react-i18next' import { Trans } from 'react-i18next'
import MathJaxReact from 'react-mathjax' import MathJaxReact from 'react-mathjax'
import useResizeObserver from 'use-resize-observer'
import { useSelector } from 'react-redux' import { useSelector } from 'react-redux'
import useResizeObserver from 'use-resize-observer'
import { TocAst } from '../../external-types/markdown-it-toc-done-right/interface' import { TocAst } from '../../external-types/markdown-it-toc-done-right/interface'
import { ApplicationState } from '../../redux' import { ApplicationState } from '../../redux'
import { InternalLink } from '../common/links/internal-link' import { InternalLink } from '../common/links/internal-link'
@ -37,6 +37,7 @@ import { slugify } from '../editor/table-of-contents/table-of-contents'
import { RawYAMLMetadata, YAMLMetaData } from '../editor/yaml-metadata/yaml-metadata' import { RawYAMLMetadata, YAMLMetaData } from '../editor/yaml-metadata/yaml-metadata'
import { createRenderContainer, validAlertLevels } from './container-plugins/alert' import { createRenderContainer, validAlertLevels } from './container-plugins/alert'
import { highlightedCode } from './markdown-it-plugins/highlighted-code' import { highlightedCode } from './markdown-it-plugins/highlighted-code'
import { lineNumberMarker } from './markdown-it-plugins/line-number-marker'
import { linkifyExtra } from './markdown-it-plugins/linkify-extra' import { linkifyExtra } from './markdown-it-plugins/linkify-extra'
import { MarkdownItParserDebugger } from './markdown-it-plugins/parser-debugger' import { MarkdownItParserDebugger } from './markdown-it-plugins/parser-debugger'
import { plantumlError } from './markdown-it-plugins/plantuml-error' import { plantumlError } from './markdown-it-plugins/plantuml-error'
@ -66,7 +67,6 @@ import { QuoteOptionsReplacer } from './replace-components/quote-options/quote-o
import { TocReplacer } from './replace-components/toc/toc-replacer' import { TocReplacer } from './replace-components/toc/toc-replacer'
import { VimeoReplacer } from './replace-components/vimeo/vimeo-replacer' import { VimeoReplacer } from './replace-components/vimeo/vimeo-replacer'
import { YoutubeReplacer } from './replace-components/youtube/youtube-replacer' import { YoutubeReplacer } from './replace-components/youtube/youtube-replacer'
import { lineNumberMarker } from './markdown-it-plugins/line-number-marker'
export interface LineMarkerPosition { export interface LineMarkerPosition {
line: number line: number
@ -123,6 +123,7 @@ export const MarkdownRenderer: React.FC<MarkdownRendererProps> = ({ content, onM
const calculateLineMarkerPositions = useCallback(() => { const calculateLineMarkerPositions = useCallback(() => {
if (documentElement.current && onLineMarkerPositionChanged) { if (documentElement.current && onLineMarkerPositionChanged) {
// noinspection CssInvalidHtmlTagReference
const lineMarkers: NodeListOf<HTMLDivElement> = documentElement.current.querySelectorAll('codimd-linemarker') const lineMarkers: NodeListOf<HTMLDivElement> = documentElement.current.querySelectorAll('codimd-linemarker')
const lineMarkerPositions: LineMarkerPosition[] = Array.from(lineMarkers).map((marker) => { const lineMarkerPositions: LineMarkerPosition[] = Array.from(lineMarkers).map((marker) => {
return { return {
@ -327,7 +328,7 @@ export const MarkdownRenderer: React.FC<MarkdownRendererProps> = ({ content, onM
}, [content, markdownIt, onMetaDataChange]) }, [content, markdownIt, onMetaDataChange])
return ( return (
<div className={'bg-light flex-fill pb-5'}> <div className={'bg-light flex-fill'}>
<div className={`markdown-body ${className || ''} d-flex flex-column align-items-center ${wide ? 'wider' : ''}`} ref={documentElement}> <div className={`markdown-body ${className || ''} d-flex flex-column align-items-center ${wide ? 'wider' : ''}`} ref={documentElement}>
<ShowIf condition={yamlError}> <ShowIf condition={yamlError}>
<Alert variant='warning' dir='auto'> <Alert variant='warning' dir='auto'>

View file

@ -2,7 +2,7 @@
@import '../../../../../../node_modules/highlight.js/styles/github-gist.css'; @import '../../../../../../node_modules/highlight.js/styles/github-gist.css';
} }
.markdown-body pre code.hljs { .markdown-body code.hljs {
padding: 16px; padding: 16px;
display: grid; display: grid;

199
yarn.lock
View file

@ -48,15 +48,15 @@
source-map "^0.5.0" source-map "^0.5.0"
"@babel/core@^7.1.0", "@babel/core@^7.4.5": "@babel/core@^7.1.0", "@babel/core@^7.4.5":
version "7.11.1" version "7.11.4"
resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.11.1.tgz#2c55b604e73a40dc21b0e52650b11c65cf276643" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.11.4.tgz#4301dfdfafa01eeb97f1896c5501a3f0655d4229"
integrity sha512-XqF7F6FWQdKGGWAzGELL+aCO1p+lRY5Tj5/tbT3St1G8NaH70jhhDIKknIZaDans0OQBG5wRAldROLHSt44BgQ== integrity sha512-5deljj5HlqRXN+5oJTY7Zs37iH3z3b++KjiKtIsJy1NrjOOVSEaJHEetLBhyu0aQOSNNZ/0IuEAan9GzRuDXHg==
dependencies: dependencies:
"@babel/code-frame" "^7.10.4" "@babel/code-frame" "^7.10.4"
"@babel/generator" "^7.11.0" "@babel/generator" "^7.11.4"
"@babel/helper-module-transforms" "^7.11.0" "@babel/helper-module-transforms" "^7.11.0"
"@babel/helpers" "^7.10.4" "@babel/helpers" "^7.10.4"
"@babel/parser" "^7.11.1" "@babel/parser" "^7.11.4"
"@babel/template" "^7.10.4" "@babel/template" "^7.10.4"
"@babel/traverse" "^7.11.0" "@babel/traverse" "^7.11.0"
"@babel/types" "^7.11.0" "@babel/types" "^7.11.0"
@ -69,10 +69,10 @@
semver "^5.4.1" semver "^5.4.1"
source-map "^0.5.0" source-map "^0.5.0"
"@babel/generator@^7.11.0", "@babel/generator@^7.4.0", "@babel/generator@^7.9.0": "@babel/generator@^7.11.0", "@babel/generator@^7.11.4", "@babel/generator@^7.4.0", "@babel/generator@^7.9.0":
version "7.11.0" version "7.11.4"
resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.11.0.tgz#4b90c78d8c12825024568cbe83ee6c9af193585c" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.11.4.tgz#1ec7eec00defba5d6f83e50e3ee72ae2fee482be"
integrity sha512-fEm3Uzw7Mc9Xi//qU20cBKatTfs2aOtKqmvy/Vm7RkJEGFQ4xc9myCfbXxqK//ZS8MR/ciOHw6meGASJuKmDfQ== integrity sha512-Rn26vueFx0eOoz7iifCN2UHT6rGtnkSGWSoDRIy8jZN3B91PzeSULbswfLoOWuTuAcNwpG/mxy+uCTDnZ9Mp1g==
dependencies: dependencies:
"@babel/types" "^7.11.0" "@babel/types" "^7.11.0"
jsesc "^2.5.1" jsesc "^2.5.1"
@ -152,11 +152,10 @@
lodash "^4.17.19" lodash "^4.17.19"
"@babel/helper-explode-assignable-expression@^7.10.4": "@babel/helper-explode-assignable-expression@^7.10.4":
version "7.10.4" version "7.11.4"
resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.10.4.tgz#40a1cd917bff1288f699a94a75b37a1a2dbd8c7c" resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.11.4.tgz#2d8e3470252cc17aba917ede7803d4a7a276a41b"
integrity sha512-4K71RyRQNPRrR85sr5QY4X3VwG4wtVoXZB9+L3r1Gp38DhELyHCtovqydRi7c1Ovb17eRGiQ/FD5s8JdU0Uy5A== integrity sha512-ux9hm3zR4WV1Y3xXxXkdG/0gxF9nvI0YVmKVhvK9AfMoaQkemL3sJpXw+Xbz65azo8qJiEz2XVDUpK3KYhH3ZQ==
dependencies: dependencies:
"@babel/traverse" "^7.10.4"
"@babel/types" "^7.10.4" "@babel/types" "^7.10.4"
"@babel/helper-function-name@^7.10.4": "@babel/helper-function-name@^7.10.4":
@ -229,14 +228,13 @@
lodash "^4.17.19" lodash "^4.17.19"
"@babel/helper-remap-async-to-generator@^7.10.4": "@babel/helper-remap-async-to-generator@^7.10.4":
version "7.10.4" version "7.11.4"
resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.10.4.tgz#fce8bea4e9690bbe923056ded21e54b4e8b68ed5" resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.11.4.tgz#4474ea9f7438f18575e30b0cac784045b402a12d"
integrity sha512-86Lsr6NNw3qTNl+TBcF1oRZMaVzJtbWTyTko+CQL/tvNvcGYEFKbLXDPxtW0HKk3McNOk4KzY55itGWCAGK5tg== integrity sha512-tR5vJ/vBa9wFy3m5LLv2faapJLnDFxNWff2SAYkSE4rLUdbp7CdObYFgI7wK4T/Mj4UzpjPwzR8Pzmr5m7MHGA==
dependencies: dependencies:
"@babel/helper-annotate-as-pure" "^7.10.4" "@babel/helper-annotate-as-pure" "^7.10.4"
"@babel/helper-wrap-function" "^7.10.4" "@babel/helper-wrap-function" "^7.10.4"
"@babel/template" "^7.10.4" "@babel/template" "^7.10.4"
"@babel/traverse" "^7.10.4"
"@babel/types" "^7.10.4" "@babel/types" "^7.10.4"
"@babel/helper-replace-supers@^7.10.4": "@babel/helper-replace-supers@^7.10.4":
@ -304,10 +302,10 @@
chalk "^2.0.0" chalk "^2.0.0"
js-tokens "^4.0.0" js-tokens "^4.0.0"
"@babel/parser@^7.1.0", "@babel/parser@^7.10.4", "@babel/parser@^7.11.0", "@babel/parser@^7.11.1", "@babel/parser@^7.4.3", "@babel/parser@^7.7.0", "@babel/parser@^7.9.0": "@babel/parser@^7.1.0", "@babel/parser@^7.10.4", "@babel/parser@^7.11.0", "@babel/parser@^7.11.4", "@babel/parser@^7.4.3", "@babel/parser@^7.7.0", "@babel/parser@^7.9.0":
version "7.11.3" version "7.11.4"
resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.11.3.tgz#9e1eae46738bcd08e23e867bab43e7b95299a8f9" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.11.4.tgz#6fa1a118b8b0d80d0267b719213dc947e88cc0ca"
integrity sha512-REo8xv7+sDxkKvoxEywIdsNFiZLybwdI7hcT5uEPyQrSMB4YQ973BfC9OOrD/81MaIjh6UxdulIQXkjmiH3PcA== integrity sha512-MggwidiH+E9j5Sh8pbrX5sJvMcsqS5o+7iB42M9/k0CD63MjYbdP4nhSh7uB5wnv2/RVzTZFTxzF/kIa5mrCqA==
"@babel/plugin-proposal-async-generator-functions@^7.10.4", "@babel/plugin-proposal-async-generator-functions@^7.8.3": "@babel/plugin-proposal-async-generator-functions@^7.10.4", "@babel/plugin-proposal-async-generator-functions@^7.8.3":
version "7.10.5" version "7.10.5"
@ -1411,6 +1409,17 @@
"@types/yargs" "^15.0.0" "@types/yargs" "^15.0.0"
chalk "^3.0.0" chalk "^3.0.0"
"@jest/types@^26.3.0":
version "26.3.0"
resolved "https://registry.yarnpkg.com/@jest/types/-/types-26.3.0.tgz#97627bf4bdb72c55346eef98e3b3f7ddc4941f71"
integrity sha512-BDPG23U0qDeAvU4f99haztXwdAg3hz4El95LkAM+tHAqqhiVzRpEGHHU8EDxT/AnxOrA65YjLBwDahdJ9pTLJQ==
dependencies:
"@types/istanbul-lib-coverage" "^2.0.0"
"@types/istanbul-reports" "^3.0.0"
"@types/node" "*"
"@types/yargs" "^15.0.0"
chalk "^4.0.0"
"@mrmlnc/readdir-enhanced@^2.2.1": "@mrmlnc/readdir-enhanced@^2.2.1":
version "2.2.1" version "2.2.1"
resolved "https://registry.yarnpkg.com/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz#524af240d1a360527b730475ecfa1344aa540dde" resolved "https://registry.yarnpkg.com/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz#524af240d1a360527b730475ecfa1344aa540dde"
@ -1562,15 +1571,15 @@
"@types/testing-library__cypress" "^5.0.6" "@types/testing-library__cypress" "^5.0.6"
"@testing-library/dom@^7.11.0": "@testing-library/dom@^7.11.0":
version "7.22.2" version "7.22.6"
resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-7.22.2.tgz#6deaa828500993cc94bdd62875c251b5b5b70d69" resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-7.22.6.tgz#a9466c564e9cccb56175ad2ff471aa4ba43ef0b7"
integrity sha512-taxURh+4Lwr//uC1Eghat95aMnTlI4G4ETosnZK0wliwHWdutLDVKIvHXAOYdXGdzrBAy1wNhSGmNBbZ72ml4g== integrity sha512-8703SWfapsEMwG10/c8AV7qK33zyy0NMDs0SbX9uEZnHWnxaNA5SnODuWS1PvFEjoNjBxfoxVZtw6uQAXO7tJw==
dependencies: dependencies:
"@babel/runtime" "^7.10.3" "@babel/runtime" "^7.10.3"
"@types/aria-query" "^4.2.0" "@types/aria-query" "^4.2.0"
aria-query "^4.2.2" aria-query "^4.2.2"
dom-accessibility-api "^0.5.0" dom-accessibility-api "^0.5.1"
pretty-format "^25.5.0" pretty-format "^26.4.2"
"@testing-library/dom@^7.22.2", "@testing-library/dom@^7.22.3": "@testing-library/dom@^7.22.2", "@testing-library/dom@^7.22.3":
version "7.22.3" version "7.22.3"
@ -1761,6 +1770,13 @@
"@types/istanbul-lib-coverage" "*" "@types/istanbul-lib-coverage" "*"
"@types/istanbul-lib-report" "*" "@types/istanbul-lib-report" "*"
"@types/istanbul-reports@^3.0.0":
version "3.0.0"
resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-3.0.0.tgz#508b13aa344fa4976234e75dddcc34925737d821"
integrity sha512-nwKNbvnwJ2/mndE9ItP/zc2TCzw6uuodnF4EHYWD+gCQDVBuRQL5UzbZD0/ezy1iKsFU2ZQiDqg4M9dN4+wZgA==
dependencies:
"@types/istanbul-lib-report" "*"
"@types/jest@*", "@types/jest@26.0.10": "@types/jest@*", "@types/jest@26.0.10":
version "26.0.10" version "26.0.10"
resolved "https://registry.yarnpkg.com/@types/jest/-/jest-26.0.10.tgz#8faf7e9756c033c39014ae76a7329efea00ea607" resolved "https://registry.yarnpkg.com/@types/jest/-/jest-26.0.10.tgz#8faf7e9756c033c39014ae76a7329efea00ea607"
@ -1934,7 +1950,15 @@
dependencies: dependencies:
"@types/react" "*" "@types/react" "*"
"@types/react@*", "@types/react@16.9.46", "@types/react@^16.9.11", "@types/react@^16.9.35": "@types/react@*", "@types/react@^16.9.11", "@types/react@^16.9.35":
version "16.9.47"
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.47.tgz#fb092936f0b56425f874d0ff1b08051fdf70c1ba"
integrity sha512-dAJO4VbrjYqTUwFiQqAKjLyHHl4RSTNnRyPdX3p16MPbDKvow51wxATUPxoe2QsiXNMEYrOjc2S6s92VjG+1VQ==
dependencies:
"@types/prop-types" "*"
csstype "^3.0.2"
"@types/react@16.9.46":
version "16.9.46" version "16.9.46"
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.46.tgz#f0326cd7adceda74148baa9bff6e918632f5069e" resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.46.tgz#f0326cd7adceda74148baa9bff6e918632f5069e"
integrity sha512-dbHzO3aAq1lB3jRQuNpuZ/mnu+CdD3H0WVaaBQA8LTT3S33xhVBUj232T8M3tAhSWJs/D/UqORYUlJNl/8VQZg== integrity sha512-dbHzO3aAq1lB3jRQuNpuZ/mnu+CdD3H0WVaaBQA8LTT3S33xhVBUj232T8M3tAhSWJs/D/UqORYUlJNl/8VQZg==
@ -2350,9 +2374,9 @@ adjust-sourcemap-loader@2.0.0:
regex-parser "2.2.10" regex-parser "2.2.10"
aggregate-error@^3.0.0: aggregate-error@^3.0.0:
version "3.0.1" version "3.1.0"
resolved "https://registry.yarnpkg.com/aggregate-error/-/aggregate-error-3.0.1.tgz#db2fe7246e536f40d9b5442a39e117d7dd6a24e0" resolved "https://registry.yarnpkg.com/aggregate-error/-/aggregate-error-3.1.0.tgz#92670ff50f5359bdb7a3e0d40d0ec30c5737687a"
integrity sha512-quoaXsZ9/BLNae5yiNoUz+Nhkwz83GhWwtYFglcjEQB2NDHCIpApbqXxIFnm4Pq/Nvhrsq5sYJFyohrrxnTGAA== integrity sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==
dependencies: dependencies:
clean-stack "^2.0.0" clean-stack "^2.0.0"
indent-string "^4.0.0" indent-string "^4.0.0"
@ -3337,9 +3361,9 @@ caniuse-api@^3.0.0:
lodash.uniq "^4.5.0" lodash.uniq "^4.5.0"
caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30001035, caniuse-lite@^1.0.30001109, caniuse-lite@^1.0.30001111: caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30001035, caniuse-lite@^1.0.30001109, caniuse-lite@^1.0.30001111:
version "1.0.30001116" version "1.0.30001118"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001116.tgz#f3a3dea347f9294a3bdc4292309039cc84117fb8" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001118.tgz#116a9a670e5264aec895207f5e918129174c6f62"
integrity sha512-f2lcYnmAI5Mst9+g0nkMIznFGsArRmZ0qU+dnq8l91hymdc2J3SFbiPhOJEeDqC1vtE8nc1qNQyklzB8veJefQ== integrity sha512-RNKPLojZo74a0cP7jFMidQI7nvLER40HgNfgKQEJ2PFm225L0ectUungNQoK3Xk3StQcFbpBPNEvoWD59436Hg==
capture-exit@^2.0.0: capture-exit@^2.0.0:
version "2.0.0" version "2.0.0"
@ -4208,9 +4232,9 @@ csstype@^2.5.5:
integrity sha512-ul26pfSQTZW8dcOnD2iiJssfXw0gdNVX9IJDH/X3K5DGPfj+fUYe3kB+swUY6BF3oZDxaID3AJt+9/ojSAE05A== integrity sha512-ul26pfSQTZW8dcOnD2iiJssfXw0gdNVX9IJDH/X3K5DGPfj+fUYe3kB+swUY6BF3oZDxaID3AJt+9/ojSAE05A==
csstype@^3.0.2: csstype@^3.0.2:
version "3.0.2" version "3.0.3"
resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.0.2.tgz#ee5ff8f208c8cd613b389f7b222c9801ca62b3f7" resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.0.3.tgz#2b410bbeba38ba9633353aff34b05d9755d065f8"
integrity sha512-ofovWglpqoqbfLNOTBNZLSbMuGrblAf1efvvArGKOZMBrIoJeu5UsAipQolkijtyQx5MtAzT/J9IHj/CEY1mJw== integrity sha512-jPl+wbWPOWJ7SXsWyqGRk3lGecbar0Cb0OvZF/r/ZU011R4YqiRehgkQ9p4eQfo9DSDLqLL3wHwfxeJiuIsNag==
currently-unhandled@^0.4.1: currently-unhandled@^0.4.1:
version "0.4.1" version "0.4.1"
@ -4535,10 +4559,15 @@ doctrine@^3.0.0:
dependencies: dependencies:
esutils "^2.0.2" esutils "^2.0.2"
dom-accessibility-api@^0.5.0: dom-accessibility-api@^0.5.1:
version "0.5.0" version "0.5.1"
resolved "https://registry.yarnpkg.com/dom-accessibility-api/-/dom-accessibility-api-0.5.0.tgz#fddffd04e178796e241436c3f21be2f89c91afac" resolved "https://registry.yarnpkg.com/dom-accessibility-api/-/dom-accessibility-api-0.5.1.tgz#152f5e88583d900977119223e3e76c2d93d23830"
integrity sha512-eCVf9n4Ni5UQAFc2+fqfMPHdtiX7DA0rLakXgNBZfXNJzEbNo3MQIYd+zdYpFBqAaGYVrkd8leNSLGPrG4ODmA== integrity sha512-8DhtmKTYWXNpPiL/QOszbnkAbCGuPz9ieVwDrmWM1rNx4KRI3zqmvKANAD1PJdvvov3+eq1BPLXQkYTpqTrWng==
dom-accessibility-api@^0.5.1:
version "0.5.1"
resolved "https://registry.yarnpkg.com/dom-accessibility-api/-/dom-accessibility-api-0.5.1.tgz#152f5e88583d900977119223e3e76c2d93d23830"
integrity sha512-8DhtmKTYWXNpPiL/QOszbnkAbCGuPz9ieVwDrmWM1rNx4KRI3zqmvKANAD1PJdvvov3+eq1BPLXQkYTpqTrWng==
dom-accessibility-api@^0.5.1: dom-accessibility-api@^0.5.1:
version "0.5.1" version "0.5.1"
@ -4677,9 +4706,9 @@ ee-first@1.1.1:
integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=
electron-to-chromium@^1.3.378, electron-to-chromium@^1.3.523: electron-to-chromium@^1.3.378, electron-to-chromium@^1.3.523:
version "1.3.539" version "1.3.549"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.539.tgz#9952fb0bf3fb4295282e7df35f6e7a2a8b89d3fd" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.549.tgz#bf500c8eb75a7286a895e34f41aa144384ac613b"
integrity sha512-rM0LWDIstdqfaRUADZetNrL6+zd/0NBmavbMEhBXgc2u/CC1d1GaDyN5hho29fFvBiOVFwrSWZkzmNcZnCEDog== integrity sha512-q09qZdginlqDH3+Y1P6ch5UDTW8nZ1ijwMkxFs15J/DAWOwqolIx8HZH1UP0vReByBigk/dPlU22xS1MaZ+kpQ==
elegant-spinner@^1.0.1: elegant-spinner@^1.0.1:
version "1.0.1" version "1.0.1"
@ -4801,6 +4830,24 @@ es-abstract@^1.17.0, es-abstract@^1.17.0-next.1, es-abstract@^1.17.2, es-abstrac
string.prototype.trimend "^1.0.1" string.prototype.trimend "^1.0.1"
string.prototype.trimstart "^1.0.1" string.prototype.trimstart "^1.0.1"
es-abstract@^1.18.0-next.0:
version "1.18.0-next.0"
resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.18.0-next.0.tgz#b302834927e624d8e5837ed48224291f2c66e6fc"
integrity sha512-elZXTZXKn51hUBdJjSZGYRujuzilgXo8vSPQzjGYXLvSlGiCo8VO8ZGV3kjo9a0WNJJ57hENagwbtlRuHuzkcQ==
dependencies:
es-to-primitive "^1.2.1"
function-bind "^1.1.1"
has "^1.0.3"
has-symbols "^1.0.1"
is-callable "^1.2.0"
is-negative-zero "^2.0.0"
is-regex "^1.1.1"
object-inspect "^1.8.0"
object-keys "^1.1.1"
object.assign "^4.1.0"
string.prototype.trimend "^1.0.1"
string.prototype.trimstart "^1.0.1"
es-get-iterator@^1.1.0: es-get-iterator@^1.1.0:
version "1.1.0" version "1.1.0"
resolved "https://registry.yarnpkg.com/es-get-iterator/-/es-get-iterator-1.1.0.tgz#bb98ad9d6d63b31aacdc8f89d5d0ee57bcb5b4c8" resolved "https://registry.yarnpkg.com/es-get-iterator/-/es-get-iterator-1.1.0.tgz#bb98ad9d6d63b31aacdc8f89d5d0ee57bcb5b4c8"
@ -5201,9 +5248,9 @@ eventemitter2@^6.4.2:
integrity sha512-t0A2msp6BzOf+QAcI6z9XMktLj52OjGQg+8SJH6v5+3uxNpWYRR3wQmfA+6xtMU9kOC59qk9licus5dYcrYkMQ== integrity sha512-t0A2msp6BzOf+QAcI6z9XMktLj52OjGQg+8SJH6v5+3uxNpWYRR3wQmfA+6xtMU9kOC59qk9licus5dYcrYkMQ==
eventemitter3@^4.0.0: eventemitter3@^4.0.0:
version "4.0.4" version "4.0.6"
resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.4.tgz#b5463ace635a083d018bdc7c917b4c5f10a85384" resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.6.tgz#1258f6fa51b4908aadc2cd624fcd6e64f99f49d6"
integrity sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ== integrity sha512-s3GJL04SQoM+gn2c14oyqxvZ3Pcq7cduSDqy3sBFXx6UPSUmgVYwQM9zwkTn9je0lrfg0gHEwR42pF3Q2dCQkQ==
events@^3.0.0: events@^3.0.0:
version "3.2.0" version "3.2.0"
@ -6831,6 +6878,11 @@ is-map@^2.0.1:
resolved "https://registry.yarnpkg.com/is-map/-/is-map-2.0.1.tgz#520dafc4307bb8ebc33b813de5ce7c9400d644a1" resolved "https://registry.yarnpkg.com/is-map/-/is-map-2.0.1.tgz#520dafc4307bb8ebc33b813de5ce7c9400d644a1"
integrity sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw== integrity sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==
is-negative-zero@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.0.tgz#9553b121b0fac28869da9ed459e20c7543788461"
integrity sha1-lVOxIbD6wohp2p7UWeIMdUN4hGE=
is-number-object@^1.0.3: is-number-object@^1.0.3:
version "1.0.4" version "1.0.4"
resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.4.tgz#36ac95e741cf18b283fc1ddf5e83da798e3ec197" resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.4.tgz#36ac95e741cf18b283fc1ddf5e83da798e3ec197"
@ -6906,7 +6958,7 @@ is-promise@^2.1.0:
resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1" resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1"
integrity sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ== integrity sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==
is-regex@^1.0.4, is-regex@^1.0.5, is-regex@^1.1.0: is-regex@^1.0.4, is-regex@^1.0.5, is-regex@^1.1.0, is-regex@^1.1.1:
version "1.1.1" version "1.1.1"
resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.1.tgz#c6f98aacc546f6cec5468a07b7b153ab564a57b9" resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.1.tgz#c6f98aacc546f6cec5468a07b7b153ab564a57b9"
integrity sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg== integrity sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==
@ -7605,6 +7657,11 @@ json-parse-better-errors@^1.0.1, json-parse-better-errors@^1.0.2:
resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9"
integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==
json-parse-even-better-errors@^2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.0.tgz#371873c5ffa44304a6ba12419bcfa95f404ae081"
integrity sha512-o3aP+RsWDJZayj1SbHNQAI8x0v3T3SKiGoZlNYfbUP1S3omJQ6i9CnqADqkSPaOAxwua4/1YWx5CM7oiChJt2Q==
json-schema-traverse@^0.4.1: json-schema-traverse@^0.4.1:
version "0.4.1" version "0.4.1"
resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660"
@ -8021,9 +8078,9 @@ log-update@^2.3.0:
wrap-ansi "^3.0.1" wrap-ansi "^3.0.1"
loglevel@^1.6.8: loglevel@^1.6.8:
version "1.6.8" version "1.7.0"
resolved "https://registry.yarnpkg.com/loglevel/-/loglevel-1.6.8.tgz#8a25fb75d092230ecd4457270d80b54e28011171" resolved "https://registry.yarnpkg.com/loglevel/-/loglevel-1.7.0.tgz#728166855a740d59d38db01cf46f042caa041bb0"
integrity sha512-bsU7+gc9AJ2SqpzxwU3+1fedl8zAntbtC5XYlt3s2j1hJcn2PsXSmgN8TaLG/J1/2mod4+cE/3vNL70/c1RNCA== integrity sha512-i2sY04nal5jDcagM3FMfG++T69GEEM8CYuOfeOIvmXzOIcwE9a/CJPR0MFM97pYMj/u10lzz7/zd7+qwhrBTqQ==
loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.2.0, loose-envify@^1.3.1, loose-envify@^1.4.0: loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.2.0, loose-envify@^1.3.1, loose-envify@^1.4.0:
version "1.4.0" version "1.4.0"
@ -8825,7 +8882,7 @@ object-hash@^2.0.1:
resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-2.0.3.tgz#d12db044e03cd2ca3d77c0570d87225b02e1e6ea" resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-2.0.3.tgz#d12db044e03cd2ca3d77c0570d87225b02e1e6ea"
integrity sha512-JPKn0GMu+Fa3zt3Bmr66JhokJU5BaNBIh4ZeTlaCBzrBsOeXzwcKKAK1tbLiPKgvwmPXsDvvLHoWh5Bm7ofIYg== integrity sha512-JPKn0GMu+Fa3zt3Bmr66JhokJU5BaNBIh4ZeTlaCBzrBsOeXzwcKKAK1tbLiPKgvwmPXsDvvLHoWh5Bm7ofIYg==
object-inspect@^1.7.0: object-inspect@^1.7.0, object-inspect@^1.8.0:
version "1.8.0" version "1.8.0"
resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.8.0.tgz#df807e5ecf53a609cc6bfe93eac3cc7be5b3a9d0" resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.8.0.tgz#df807e5ecf53a609cc6bfe93eac3cc7be5b3a9d0"
integrity sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA== integrity sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==
@ -8953,9 +9010,9 @@ onetime@^5.1.0:
mimic-fn "^2.1.0" mimic-fn "^2.1.0"
open@^7.0.2: open@^7.0.2:
version "7.1.0" version "7.2.0"
resolved "https://registry.yarnpkg.com/open/-/open-7.1.0.tgz#68865f7d3cb238520fa1225a63cf28bcf8368a1c" resolved "https://registry.yarnpkg.com/open/-/open-7.2.0.tgz#212959bd7b0ce2e8e3676adc76e3cf2f0a2498b4"
integrity sha512-lLPI5KgOwEYCDKXf4np7y1PBEkj7HYIyP2DY8mVDRnx0VIIu6bNrRB0R66TuO7Mack6EnTNLm4uvcl1UoklTpA== integrity sha512-4HeyhxCvBTI5uBePsAdi55C5fmqnWZ2e2MlmvWi5KW5tdH5rxoiv/aMtbeVxKZc3eWkT1GymMnLG8XC4Rq4TDQ==
dependencies: dependencies:
is-docker "^2.0.0" is-docker "^2.0.0"
is-wsl "^2.1.1" is-wsl "^2.1.1"
@ -9164,13 +9221,13 @@ parse-json@^4.0.0:
json-parse-better-errors "^1.0.1" json-parse-better-errors "^1.0.1"
parse-json@^5.0.0: parse-json@^5.0.0:
version "5.0.1" version "5.1.0"
resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.0.1.tgz#7cfe35c1ccd641bce3981467e6c2ece61b3b3878" resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.1.0.tgz#f96088cdf24a8faa9aea9a009f2d9d942c999646"
integrity sha512-ztoZ4/DYeXQq4E21v169sC8qWINGpcosGv9XhTDvg9/hWvx/zrFkc9BiWxR58OJLHGk28j5BL0SDLeV2WmFZlQ== integrity sha512-+mi/lmVVNKFNVyLXV31ERiy2CY5E1/F6QtJFEzoChPRwwngMNXRDQ9GJ5WdE2Z2P4AujsOi0/+2qHID68KwfIQ==
dependencies: dependencies:
"@babel/code-frame" "^7.0.0" "@babel/code-frame" "^7.0.0"
error-ex "^1.3.1" error-ex "^1.3.1"
json-parse-better-errors "^1.0.1" json-parse-even-better-errors "^2.3.0"
lines-and-columns "^1.1.6" lines-and-columns "^1.1.6"
parse5@4.0.0: parse5@4.0.0:
@ -10123,6 +10180,16 @@ pretty-format@^25.2.1, pretty-format@^25.5.0:
ansi-styles "^4.0.0" ansi-styles "^4.0.0"
react-is "^16.12.0" react-is "^16.12.0"
pretty-format@^26.4.2:
version "26.4.2"
resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-26.4.2.tgz#d081d032b398e801e2012af2df1214ef75a81237"
integrity sha512-zK6Gd8zDsEiVydOCGLkoBoZuqv8VTiHyAbKznXe/gaph/DAeZOmit9yMfgIz5adIgAMMs5XfoYSwAX3jcCO1tA==
dependencies:
"@jest/types" "^26.3.0"
ansi-regex "^5.0.0"
ansi-styles "^4.0.0"
react-is "^16.12.0"
process-nextick-args@~2.0.0: process-nextick-args@~2.0.0:
version "2.0.1" version "2.0.1"
resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2"
@ -11487,12 +11554,12 @@ shellwords@^0.1.1:
integrity sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww== integrity sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==
side-channel@^1.0.2: side-channel@^1.0.2:
version "1.0.2" version "1.0.3"
resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.2.tgz#df5d1abadb4e4bf4af1cd8852bf132d2f7876947" resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.3.tgz#cdc46b057550bbab63706210838df5d4c19519c3"
integrity sha512-7rL9YlPHg7Ancea1S96Pa8/QWb4BtXL/TZvS6B8XFetGBeuhAsfmUspK6DokBeZ64+Kj9TCNRD/30pVz1BvQNA== integrity sha512-A6+ByhlLkksFoUepsGxfj5x1gTSrs+OydsRptUxeNCabQpCFUvcwIczgOigI8vhY/OJCnPnyE9rGiwgvr9cS1g==
dependencies: dependencies:
es-abstract "^1.17.0-next.1" es-abstract "^1.18.0-next.0"
object-inspect "^1.7.0" object-inspect "^1.8.0"
signal-exit@^3.0.0, signal-exit@^3.0.2: signal-exit@^3.0.0, signal-exit@^3.0.2:
version "3.0.3" version "3.0.3"
@ -12457,9 +12524,9 @@ type@^1.0.1:
integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg== integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==
type@^2.0.0: type@^2.0.0:
version "2.0.0" version "2.1.0"
resolved "https://registry.yarnpkg.com/type/-/type-2.0.0.tgz#5f16ff6ef2eb44f260494dae271033b29c09a9c3" resolved "https://registry.yarnpkg.com/type/-/type-2.1.0.tgz#9bdc22c648cf8cf86dd23d32336a41cfb6475e3f"
integrity sha512-KBt58xCHry4Cejnc2ISQAF7QY+ORngsWfxezO68+12hKV6lQY8P/psIkcbjeHWn7MqcgciWJyCCevFMJdIXpow== integrity sha512-G9absDWvhAWCV2gmF1zKud3OyC61nZDwWvBL2DApaVFogI07CprggiQAOOjvp2NRjYWFzPyu7vwtDrQFq8jeSA==
typed-styles@^0.0.7: typed-styles@^0.0.7:
version "0.0.7" version "0.0.7"