Skip to content

Commit 26b0f44

Browse files
authored
Merge pull request #420 from api-platform/staging
MEP
2 parents 862ce91 + a92d754 commit 26b0f44

File tree

11 files changed

+61
-52
lines changed

11 files changed

+61
-52
lines changed

.github/workflows/deploy.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,9 @@ jobs:
123123
--set=pwa.image.repository=eu.gcr.io/${{ secrets.gke-project }}/website/pwa \
124124
--set=pwa.image.tag=${{ inputs.docker-images-version }} \
125125
--set=pwa.image.pullPolicy=Always \
126-
--set=pwa.resources.requests.cpu=200m \
127-
--set=pwa.resources.requests.memory=700Mi \
126+
--set=pwa.resources.requests.cpu=500m \
127+
--set=pwa.resources.requests.memory=1400Mi \
128+
--set=pwa.resources.limits.memory=1400Mi \
128129
--set=bucket.s3Upstream=storage.googleapis.com \
129130
--set=bucket.s3Name=api-platform-website-v3 \
130131
--set=service.type=NodePort \
@@ -167,8 +168,9 @@ jobs:
167168
--set=pwa.image.repository=eu.gcr.io/${{ secrets.gke-project }}/website/pwa \
168169
--set=pwa.image.tag=${{ inputs.docker-images-version }} \
169170
--set=pwa.image.pullPolicy=Always \
170-
--set=pwa.resources.requests.cpu=200m \
171-
--set=pwa.resources.requests.memory=700Mi \
171+
--set=pwa.resources.requests.cpu=500m \
172+
--set=pwa.resources.requests.memory=1400Mi \
173+
--set=pwa.resources.limits.memory=1400Mi \
172174
--set=php.corsAllowOrigin="^$(echo "${{ join(fromJSON(env.CORS), '|') }}" | sed 's/\./\\./g')$" \
173175
--set=github.key=${{ secrets.gh-key }} \
174176
--set=next.rootUrl=${{ env.URL }} \

helm/api-platform/values.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,10 @@ pwa:
2727
tag: ""
2828
resources:
2929
requests:
30-
memory: 700Mi
31-
cpu: 250m
30+
memory: 1400Mi
31+
cpu: 500m
32+
limits:
33+
memory: 1400Mi
3234

3335

3436
next:

pwa/app/(common)/community/contributors/page.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ export async function generateMetadata(): Promise<Metadata> {
2121
};
2222
}
2323

24+
export const revalidate = 86400; // revalidate the contributors ranking every day
25+
2426
export default async function Page() {
2527
const contributors = await getAllContributors();
2628
return (

pwa/app/(common)/components/timeline/CodeBlock.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ export default function CodeBlock({ title, children }: CodeBlockProps) {
2222
return (
2323
<div
2424
ref={animation}
25-
className="dark bg-blue-black dark:bg-blue-darkest rounded-2xl p-6 w-full flex flex-col shadow-xl my-4 | sm:my-8 md:absolute md:right-[calc(100%+3rem)] md:w-full md:max-w-lg md:my-0"
25+
className="dark text-left bg-blue-black dark:bg-blue-darkest rounded-2xl p-6 w-full flex flex-col shadow-xl my-4 | sm:my-8 md:absolute md:right-[calc(100%+3rem)] md:w-full md:max-w-lg md:my-0"
2626
>
2727
<div className="flex flew-row items-center gap-2">
2828
<div className="rounded-full w-3 h-3 bg-[#ed6a5d]" />

pwa/app/(common)/components/timeline/Install.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
```bash
2-
gh repo create template api-platform/api-platform my-api
2+
gh repo create --clone --template api-platform/api-platform my-api --public # or --private
33
cd my-api
44
docker compose up
55
open https://localhost

pwa/app/(common)/not-found.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ export default async function NotFound() {
55
return (
66
<div
77
className={classNames(
8-
"h-screen pt-16 bg-blue text-white flex flex-col items-center justify-center md:flex-row",
8+
"h-screen pt-16 bg-blue-light text-white flex flex-col items-center justify-center md:flex-row after:absolute after:w-full after:h-80 after:top-full after:left-0 after:bg-blue-light",
99
"dark:text-blue-black"
1010
)}
1111
>

pwa/components/docs/MobileSidebar.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export default function MobileSideBar({
5252
/>
5353
</svg>
5454
</button>
55-
<div className="pl-4 flex flex-row gap-1 items-center justify-center leading-none text-sm font-light text-text-secondary">
55+
<div className="pl-4 flex flex-row gap-1 items-center justify-center leading-none text-sm font-light text-text-secondary dark:text-white/70">
5656
{breadCrumbs.map((docLink, index) => (
5757
<Fragment key={docLink.title}>
5858
{docLink.link ? (
@@ -67,7 +67,7 @@ export default function MobileSideBar({
6767
<span
6868
className={`${
6969
index === breadCrumbs.length - 1 &&
70-
"font-bold text-text-primary text-ellipsis whitespace-nowrap overflow-hidden"
70+
"font-bold text-text-primary text-ellipsis whitespace-nowrap overflow-hidden dark:text-white/50"
7171
}`}
7272
>
7373
{docLink.title}

pwa/i18n/dictionaries/fr.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
"or_follow_us": "ou suivez-nous sur nos réseaux",
147147
"partners": { "title": "Nos <strong>partenaires</strong>" },
148148
"pricing": {
149-
"certificate_needed": "Un justificafif sera demandé",
149+
"certificate_needed": "Un justificatif sera demandé",
150150
"conference": {
151151
"offers": {
152152
"on_site": "Billet 2 jours",

pwa/middleware.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ function getLocale(request: NextRequest): string | undefined {
1111
// Use negotiator and intl-localematcher to get best locale
1212
const languages = new Negotiator({ headers: negotiatorHeaders }).languages();
1313
const locales = [...i18n.locales];
14-
return matchLocale(languages, locales, i18n.defaultLocale);
14+
const locale = matchLocale(languages, locales, i18n.defaultLocale);
15+
return ([...i18n.locales] as string[]).includes(locale)
16+
? locale
17+
: i18n.defaultLocale;
1518
}
1619

1720
export async function middleware(request: NextRequest) {

pwa/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"marked": "^5.0.4",
2929
"marked-highlight": "^2.0.1",
3030
"negotiator": "^0.6.3",
31-
"next": "13.4.7-canary.1",
31+
"next": "13.4.8-canary.8",
3232
"next-themes": "npm:@wits/next-themes@^0.2.16",
3333
"octokit": "^2.0.19",
3434
"prettier": "^2.8.8",

0 commit comments

Comments
 (0)