Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add Seven-innovation-base to showcase #7144

Merged
merged 8 commits into from
Apr 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion admin/scripts/image-resize.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ await Promise.all(
new URL(`../../website/src/data/showcase/${img}`, import.meta.url),
);
const {width, height} = imageSize(imgPath);
if (width === 640 && height === 320) {
if (width === 640 && height === 320 && imgPath.endsWith('.png')) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's the purpose of this new condition?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We normalize JPEG images to PNG, but if an image has 640×320 dimensions it will be ignored and stay as JPEG.

// Do not emit if not resized. Important because we can't guarantee
// idempotency during resize -> optimization
return;
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions website/src/data/users.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1617,6 +1617,14 @@ const Users: User[] = [
source: 'https://github.com/sciwp/docs',
tags: ['opensource'],
},
{
title: 'Seven-innovation-base official website',
description: 'About seven-innovation-base',
preview: require('./showcase/seven-innovation-base.png'),
website: 'https://七院创新基地.cn',
source: 'https://github.com/seven-innovation-base/official-website',
tags: ['opensource', 'personal'],
},
{
title: 'Single SPA',
description: 'A javascript router for front-end microservices',
Expand Down