Skip to content
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 website/docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export type EditUrlButton = {
href: string;
};

const commonDocsOptions = {
const commonDocsOptions: PluginContentDocs.Options = {
breadcrumbs: false,
showLastUpdateAuthor: false,
showLastUpdateTime: true,
Expand Down
2 changes: 1 addition & 1 deletion website/src/components/Home/Platforms/FoxFact.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import React from 'react';

function FoxFact({className}) {
function FoxFact({className}: {className: string}) {
return (
<svg
width={167}
Expand Down
2 changes: 1 addition & 1 deletion website/src/components/Home/Section/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import React from 'react';

import styles from './styles.module.css';

function Section({children}) {
function Section({children}: React.PropsWithChildren) {
return (
<div className={styles.wrapper}>
<div className={styles.container}>{children}</div>
Expand Down
16 changes: 10 additions & 6 deletions website/src/pages/showcase.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@ import type users from '../../showcase.json';
import IconExternalLink from '../theme/Icon/ExternalLink';
import ThemedImage from '@theme/ThemedImage';

const renderApp = (app, i) => <AppBox app={app} key={`app-${app.name}-${i}`} />;
type UserAppType = (typeof users)[keyof typeof users][number];

const renderApp = (app: UserAppType, i: number) => (
<AppBox app={app} key={`app-${app.name}-${i}`} />
);

function Section({
children,
Expand All @@ -22,7 +26,7 @@ function Section({
return <section className={`Section ${background}`}>{children}</section>;
}

const AppBox = ({app}) => {
const AppBox = ({app}: {app: UserAppType}) => {
const imgSource = useBaseUrl(
app.icon.startsWith('http') ? app.icon : 'img/showcase/' + app.icon
);
Expand All @@ -38,7 +42,7 @@ const AppBox = ({app}) => {
<h3>{app.name}</h3>
{renderLinks(app)}
</div>
{app.infoLink && (
{'infoTitle' in app && app.infoLink && (
<a
className="articleButton"
href={app.infoLink}
Expand All @@ -53,7 +57,7 @@ const AppBox = ({app}) => {
);
};

const renderLinks = app => {
const renderLinks = (app: UserAppType) => {
const links = [
app.linkAppStore ? (
<a key="ios" href={app.linkAppStore} target="_blank">
Expand All @@ -65,12 +69,12 @@ const renderLinks = app => {
Android
</a>
) : null,
app.linkDesktop ? (
'linkDesktop' in app && app.linkDesktop ? (
<a key="desktop" href={app.linkDesktop} target="_blank">
Desktop
</a>
) : null,
app.linkMetaQuest ? (
'linkMetaQuest' in app && app.linkMetaQuest ? (
<a key="quest" href={app.linkMetaQuest} target="_blank">
Meta&nbsp;Quest
</a>
Expand Down