Merge pull request #5882 from apple502j/move-faq-url

Move FAQ page to /faq
This commit is contained in:
Sarah Otts 2021-10-12 16:34:41 -04:00 committed by GitHub
commit c30252a4ed
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 17 additions and 11 deletions

View file

@ -138,7 +138,7 @@ const Footer = props => (
</a> </a>
</dd> </dd>
<dd> <dd>
<a href="/info/faq"> <a href="/faq">
<FormattedMessage id="general.faq" /> <FormattedMessage id="general.faq" />
</a> </a>
</dd> </dd>

View file

@ -151,8 +151,8 @@
}, },
{ {
"name": "faq", "name": "faq",
"pattern": "^/info/faq/?(\\?.*)?$", "pattern": "^/faq/?(\\?.*)?$",
"routeAlias": "/info/(cards|credits|faq)/?$", "routeAlias": "/faq",
"view": "faq/faq", "view": "faq/faq",
"title": "FAQ" "title": "FAQ"
}, },
@ -384,6 +384,12 @@
"routeAlias": "/info/(cards|credits|faq|donate)/?$", "routeAlias": "/info/(cards|credits|faq|donate)/?$",
"redirect" : "/credits" "redirect" : "/credits"
}, },
{
"name" : "faq-redirect",
"pattern": "^/info/faq/?$",
"routeAlias": "/info/(cards|credits|faq|donate)/?$",
"redirect" : "/faq"
},
{ {
"name": "donate-redirect", "name": "donate-redirect",
"pattern": "^/info/donate/?", "pattern": "^/info/donate/?",

View file

@ -175,7 +175,7 @@ const About = () => (
<a href="/ideas"><FormattedMessage id="about.learnMoreHelp" /></a> <a href="/ideas"><FormattedMessage id="about.learnMoreHelp" /></a>
</li> </li>
<li> <li>
<a href="/info/faq"><FormattedMessage id="about.learnMoreFaq" /></a> <a href="/faq"><FormattedMessage id="about.learnMoreFaq" /></a>
</li> </li>
<li> <li>
<a href="/parents"><FormattedMessage id="about.learnMoreParents" /></a> <a href="/parents"><FormattedMessage id="about.learnMoreParents" /></a>

View file

@ -57,7 +57,7 @@ class ContactUs extends React.Component {
<p><FormattedMessage <p><FormattedMessage
id="contactUs.faqInfo" id="contactUs.faqInfo"
values={{faqLink: ( values={{faqLink: (
<a href="/info/faq"><FormattedMessage id="contactUs.faqLinkText" /></a> <a href="/faq"><FormattedMessage id="contactUs.faqLinkText" /></a>
)}} )}}
/></p> /></p>
<h3> <h3>
@ -115,7 +115,7 @@ class ContactUs extends React.Component {
<nav> <nav>
<ol> <ol>
<li className="nav-header"><FormattedMessage id="contactUs.findHelp" /></li> <li className="nav-header"><FormattedMessage id="contactUs.findHelp" /></li>
<li><a href="/info/faq"><FormattedMessage id="contactUs.faqLinkText" /></a></li> <li><a href="/faq"><FormattedMessage id="contactUs.faqLinkText" /></a></li>
</ol> </ol>
</nav> </nav>
{this.state.showForm && ( {this.state.showForm && (

View file

@ -114,7 +114,7 @@ const Landing = () => (
id="parents.faqMoreAndAsk" id="parents.faqMoreAndAsk"
values={{ values={{
faqPage: ( faqPage: (
<a href="/info/faq"> <a href="/faq">
<FormattedMessage <FormattedMessage
id="parents.faqLinkText" id="parents.faqLinkText"
/> />

View file

@ -35,7 +35,7 @@ const UnsupportedBrowser = () => (
faqLink: ( faqLink: (
<a <a
className="faq-link" className="faq-link"
href="/info/faq" href="/faq"
> >
<FormattedMessage id="general.faq" /> <FormattedMessage id="general.faq" />
</a> </a>

View file

@ -389,7 +389,7 @@ class SplashPresentation extends React.Component { // eslint-disable-line react/
> >
Confirm your email Confirm your email
</a>{' '}to enable sharing.{' '} </a>{' '}to enable sharing.{' '}
<a href="/info/faq/#accounts"> <a href="/faq/#accounts">
Having trouble? Having trouble?
</a> </a>
</DropdownBanner>, </DropdownBanner>,

View file

@ -265,7 +265,7 @@ const Terms = () => (
</p> </p>
<p> <p>
5.3 The source code for Scratch 1.4 is available for download and subject 5.3 The source code for Scratch 1.4 is available for download and subject
to the copyright notice as indicated on the <a href="/info/faq">Scratch FAQ</a> to the copyright notice as indicated on the <a href="/faq">Scratch FAQ</a>
{' '}page. {' '}page.
</p> </p>
<p> <p>

View file

@ -95,7 +95,7 @@ describe('www-integration footer links', () => {
await clickText('FAQ'); await clickText('FAQ');
let url = await driver.getCurrentUrl(); let url = await driver.getCurrentUrl();
let pathname = (new URL(url)).pathname; let pathname = (new URL(url)).pathname;
expect(pathname).toMatch(/^\/info\/faq\/?$/); expect(pathname).toMatch(/^\/faq\/?$/);
}); });
test('click Download link', async () => { test('click Download link', async () => {