mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-15 06:33:55 +01:00
Update in-product doc links to point to docs.overleaf.com (#35184)
* update doc links to point to docs.overleaf.com instead of the old learn wiki * fix broken link to LaTeX positioning wiki article in figure modal help * point figure positioning help link to the docs.overleaf.com page * point figure/table label help links to specific anchors on the captioning-and-referencing-figures doc page * point figure modal error-help link to the graphicx-loading doc page * normalize target/rel on docs.overleaf.com links opened in a new tab * open figure modal and SSO help links in a new tab now that they point off-site * add eslint rule enforcing rel=noopener noreferrer on docs.overleaf.com links * extend require-rel-for-docs-links to also check OLButton * add lint script catching missing rel on docs.overleaf.com links in pug templates * fix require-rel-for-docs-links autofix crash on valueless rel attribute Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * add regression test for require-rel-for-docs-links valueless-rel autofix * revert `target=_blank` on figure modal and SSO help links --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> GitOrigin-RevId: b6111341e1080fd7e4b42f6a1a18c27ea0fd7d8c
This commit is contained in:
committed by
Copybot
co-authored by
Copilot Autofix powered by AI
parent
5698ef16b3
commit
f30c23cacc
+7
-7
@@ -1,11 +1,11 @@
|
||||
import { FC } from 'react'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
|
||||
const LearnWikiLink: FC<React.PropsWithChildren<{ article: string }>> = ({
|
||||
article,
|
||||
const LearnWikiLink: FC<React.PropsWithChildren<{ href: string }>> = ({
|
||||
href,
|
||||
children,
|
||||
}) => {
|
||||
return <a href={`/learn/latex/${article}`}>{children}</a>
|
||||
return <a href={href}>{children}</a>
|
||||
}
|
||||
|
||||
export const FigureModalHelp = () => {
|
||||
@@ -24,7 +24,7 @@ export const FigureModalHelp = () => {
|
||||
// eslint-disable-next-line react/jsx-key
|
||||
<code />,
|
||||
// eslint-disable-next-line react/jsx-key
|
||||
<LearnWikiLink article="Inserting_Images#Labels_and_cross-references" />,
|
||||
<LearnWikiLink href="https://docs.overleaf.com/writing-and-editing/inserting-images/captioning-and-referencing-figures#captioning-labeling-and-referencing" />,
|
||||
]}
|
||||
/>
|
||||
</p>
|
||||
@@ -35,7 +35,7 @@ export const FigureModalHelp = () => {
|
||||
i18nKey="there_are_lots_of_options_to_edit_and_customize_your_figures"
|
||||
components={[
|
||||
// eslint-disable-next-line react/jsx-key
|
||||
<LearnWikiLink article="Inserting_Images" />,
|
||||
<LearnWikiLink href="https://docs.overleaf.com/writing-and-editing/inserting-images" />,
|
||||
]}
|
||||
/>
|
||||
</p>
|
||||
@@ -46,7 +46,7 @@ export const FigureModalHelp = () => {
|
||||
i18nKey="latex_places_figures_according_to_a_special_algorithm"
|
||||
components={[
|
||||
// eslint-disable-next-line react/jsx-key
|
||||
<LearnWikiLink article="Positioning_images_and_tables" />,
|
||||
<LearnWikiLink href="https://docs.overleaf.com/writing-and-editing/inserting-images/positioning-figures" />,
|
||||
]}
|
||||
/>
|
||||
</p>
|
||||
@@ -59,7 +59,7 @@ export const FigureModalHelp = () => {
|
||||
// eslint-disable-next-line react/jsx-key
|
||||
<code />,
|
||||
// eslint-disable-next-line react/jsx-key
|
||||
<LearnWikiLink article="Inserting_Images" />,
|
||||
<LearnWikiLink href="https://docs.overleaf.com/writing-and-editing/inserting-images/latex-code-for-including-images-in-your-document" />,
|
||||
]}
|
||||
/>
|
||||
</p>
|
||||
|
||||
+2
-2
@@ -74,9 +74,9 @@ export const TableGeneratorHelpModal = () => {
|
||||
<code />,
|
||||
// eslint-disable-next-line react/jsx-key, jsx-a11y/anchor-has-content
|
||||
<a
|
||||
href="https://www.overleaf.com/learn/latex/Inserting_Images#Labels_and_cross-references"
|
||||
href="https://docs.overleaf.com/writing-and-editing/inserting-images/captioning-and-referencing-figures#labels-and-cross-references"
|
||||
target="_blank"
|
||||
rel="noopener"
|
||||
rel="noopener noreferrer"
|
||||
/>,
|
||||
]}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user