Enable more react pages (#19935)
* enable more react landing pages * move nextjs page logic to separate middleware * enable codespaces landing page + fixes * enable /education * enable /admin * use pathToRegexp to match routes for react rendering * run lint * fix: typo in url * update sidebar test
This commit is contained in:
@@ -4,6 +4,7 @@ import { ArrowRightIcon, SearchIcon } from '@primer/octicons-react'
|
||||
import { useProductLandingContext } from 'components/context/ProductLandingContext'
|
||||
import { useTranslation } from 'components/hooks/useTranslation'
|
||||
import { CodeExampleCard } from 'components/landing/CodeExampleCard'
|
||||
import { Link } from 'components/Link'
|
||||
|
||||
const PAGE_SIZE = 6
|
||||
export const CodeExamples = () => {
|
||||
@@ -60,19 +61,19 @@ export const CodeExamples = () => {
|
||||
)}
|
||||
|
||||
{isSearching && searchResults.length === 0 && (
|
||||
<div className="d-none py-4 text-center color-text-secondary font-mktg">
|
||||
<div className="py-4 text-center color-text-secondary font-mktg">
|
||||
<div className="mb-3">
|
||||
<SearchIcon size={24} />{' '}
|
||||
</div>
|
||||
<h3 className="text-normal">
|
||||
{t('sorry')} <strong className="js-filter-card-value"></strong>
|
||||
{t('sorry')} <strong>{search}</strong>
|
||||
</h3>
|
||||
<p className="my-3 f4">
|
||||
{t('no_example')} <br /> {t('try_another')}
|
||||
</p>
|
||||
<a href="https://github.com/github/docs/blob/main/data/variables/discussions_community_examples.yml">
|
||||
{t('add_your_community')} <ArrowRightIcon />
|
||||
</a>
|
||||
<Link href="https://github.com/github/docs/blob/main/data/variables/actions_code_examples.yml">
|
||||
{t('learn')} <ArrowRightIcon />
|
||||
</Link>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user