docs: update showcase images; remove GraphQL Code Generator site (#6231)

* Showcase: Update images

* Showcase: Remove sites that are not working, and have not been working since yesterday.

* Suspected no longer using docusaurus (please confirm)

* Revert "Showcase: Remove sites that are not working, and have not been working since yesterday."

This reverts commit c963f120e9.

* add notices

* test screen resolution

* all of them

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
This commit is contained in:
Nayan Patel 2022-01-07 08:35:46 +00:00 committed by GitHub
parent e4eaac07f2
commit 1c7b0d1353
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
28 changed files with 14 additions and 11 deletions

View file

@ -9,6 +9,8 @@
import sharp from 'sharp'; import sharp from 'sharp';
import fs from 'fs/promises'; import fs from 'fs/promises';
import path from 'path'; import path from 'path';
// eslint-disable-next-line import/no-extraneous-dependencies
import imageSize from 'image-size';
const allImages = ( const allImages = (
await fs.readdir(new URL('../../website/src/data/showcase', import.meta.url)) await fs.readdir(new URL('../../website/src/data/showcase', import.meta.url))
@ -23,6 +25,12 @@ await Promise.all(
`../../website/src/data/showcase/${img}`, `../../website/src/data/showcase/${img}`,
import.meta.url, import.meta.url,
).pathname; ).pathname;
const {width, height} = imageSize(imgPath);
if (width === 640 && height === 320) {
// Do not emit if no resized. Important because we
// can't guarantee idempotency during resize -> optimization
return;
}
const data = await sharp(imgPath) const data = await sharp(imgPath)
.resize(640, 320, {fit: 'cover', position: 'top'}) .resize(640, 320, {fit: 'cover', position: 'top'})
.png() .png()

View file

@ -100,6 +100,7 @@
"eslint-plugin-react-hooks": "^4.3.0", "eslint-plugin-react-hooks": "^4.3.0",
"glob": "^7.1.6", "glob": "^7.1.6",
"husky": "^5.0.9", "husky": "^5.0.9",
"image-size": "^1.0.0",
"is-ci": "^3.0.0", "is-ci": "^3.0.0",
"jest": "^26.6.3", "jest": "^26.6.3",
"lerna": "^3.22.1", "lerna": "^3.22.1",

View file

@ -73,7 +73,6 @@
"@types/jest": "^26.0.20", "@types/jest": "^26.0.20",
"cross-env": "^7.0.3", "cross-env": "^7.0.3",
"fs-extra": "^10.0.0", "fs-extra": "^10.0.0",
"image-size": "^1.0.0",
"raw-loader": "^4.0.2" "raw-loader": "^4.0.2"
} }
} }

View file

@ -11,6 +11,7 @@ import {Joi} from '@docusaurus/utils-validation';
import fs from 'fs-extra'; import fs from 'fs-extra';
import path from 'path'; import path from 'path';
// eslint-disable-next-line import/no-extraneous-dependencies
import imageSize from 'image-size'; import imageSize from 'image-size';
declare global { declare global {

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

After

Width:  |  Height:  |  Size: 33 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 38 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 31 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.5 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 71 KiB

After

Width:  |  Height:  |  Size: 73 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 54 KiB

After

Width:  |  Height:  |  Size: 74 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 59 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 29 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 35 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 71 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 31 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 25 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 33 KiB

Before After
Before After

View file

@ -181,6 +181,7 @@ const Users: User[] = [
source: 'https://github.com/algolia/docsearch-website', source: 'https://github.com/algolia/docsearch-website',
tags: ['favorite', 'opensource', 'product'], tags: ['favorite', 'opensource', 'product'],
}, },
// TODO site unavailable on 12/31/2021
{ {
title: 'Amphora Data', title: 'Amphora Data',
description: 'Connecting the worlds real-time information', description: 'Connecting the worlds real-time information',
@ -233,6 +234,7 @@ const Users: User[] = [
source: 'https://gitlab.com/aweframework/awe', source: 'https://gitlab.com/aweframework/awe',
tags: ['opensource', 'i18n', 'versioning'], tags: ['opensource', 'i18n', 'versioning'],
}, },
// TODO site unavailable on 12/31/2021
{ {
title: 'Axioms', title: 'Axioms',
description: 'Axioms Developer Hub and Documentation Portal', description: 'Axioms Developer Hub and Documentation Portal',
@ -633,15 +635,6 @@ const Users: User[] = [
source: 'https://github.com/gotenberg/gotenberg.dev', source: 'https://github.com/gotenberg/gotenberg.dev',
tags: ['opensource', 'versioning'], tags: ['opensource', 'versioning'],
}, },
{
title: 'GraphQL Code Generator',
description:
'Generate code from your GraphQL schema and operations with a simple CLI',
preview: require('./showcase/graphql-codegen.png'),
website: 'https://graphql-code-generator.com/',
source: 'https://github.com/dotansimha/graphql-code-generator',
tags: ['favorite', 'opensource', 'design'],
},
{ {
title: 'GraphQL Inspector', title: 'GraphQL Inspector',
description: 'An open-source tool to help you work with GraphQL', description: 'An open-source tool to help you work with GraphQL',
@ -1470,7 +1463,7 @@ const Users: User[] = [
title: 'Supabase', title: 'Supabase',
description: 'Open Source Realtime and RESTful APIs for Postgres', description: 'Open Source Realtime and RESTful APIs for Postgres',
preview: require('./showcase/supabase.png'), preview: require('./showcase/supabase.png'),
website: 'https://www.supabase.io/', website: 'https://www.supabase.io/docs',
source: 'https://github.com/supabase/monorepo', source: 'https://github.com/supabase/monorepo',
tags: ['opensource', 'favorite', 'design', 'large', 'product'], tags: ['opensource', 'favorite', 'design', 'large', 'product'],
}, },
@ -1626,6 +1619,7 @@ const Users: User[] = [
source: 'https://github.com/webiny/docs.webiny.com', source: 'https://github.com/webiny/docs.webiny.com',
tags: ['opensource', 'product'], tags: ['opensource', 'product'],
}, },
// TODO site unavailable on 12/31/2021
{ {
title: 'Wisdom', title: 'Wisdom',
description: 'Session replay web analytics with open data SQL/S3 access.', description: 'Session replay web analytics with open data SQL/S3 access.',