diff --git a/docs/src/theme/DocCard/assets/amiss.png b/docs/src/theme/DocCard/assets/amiss.png new file mode 100644 index 000000000..662d3d889 Binary files /dev/null and b/docs/src/theme/DocCard/assets/amiss.png differ diff --git a/docs/src/theme/DocCard/assets/azure.png b/docs/src/theme/DocCard/assets/azure.png new file mode 100644 index 000000000..df6f6cd8b Binary files /dev/null and b/docs/src/theme/DocCard/assets/azure.png differ diff --git a/docs/src/theme/DocCard/assets/broken.png b/docs/src/theme/DocCard/assets/broken.png new file mode 100644 index 000000000..d669db2b3 Binary files /dev/null and b/docs/src/theme/DocCard/assets/broken.png differ diff --git a/docs/src/theme/DocCard/assets/continueint.png b/docs/src/theme/DocCard/assets/continueint.png new file mode 100644 index 000000000..8421c8407 Binary files /dev/null and b/docs/src/theme/DocCard/assets/continueint.png differ diff --git a/docs/src/theme/DocCard/assets/denied.png b/docs/src/theme/DocCard/assets/denied.png new file mode 100644 index 000000000..0f41f4a29 Binary files /dev/null and b/docs/src/theme/DocCard/assets/denied.png differ diff --git a/docs/src/theme/DocCard/assets/discord.png b/docs/src/theme/DocCard/assets/discord.png new file mode 100644 index 000000000..e545b3fcf Binary files /dev/null and b/docs/src/theme/DocCard/assets/discord.png differ diff --git a/docs/src/theme/DocCard/assets/engine.png b/docs/src/theme/DocCard/assets/engine.png new file mode 100644 index 000000000..a18faa1ce Binary files /dev/null and b/docs/src/theme/DocCard/assets/engine.png differ diff --git a/docs/src/theme/DocCard/assets/gpu.png b/docs/src/theme/DocCard/assets/gpu.png new file mode 100644 index 000000000..83e357d74 Binary files /dev/null and b/docs/src/theme/DocCard/assets/gpu.png differ diff --git a/docs/src/theme/DocCard/assets/import.png b/docs/src/theme/DocCard/assets/import.png new file mode 100644 index 000000000..c1995e091 Binary files /dev/null and b/docs/src/theme/DocCard/assets/import.png differ diff --git a/docs/src/theme/DocCard/assets/issue.png b/docs/src/theme/DocCard/assets/issue.png new file mode 100644 index 000000000..6658fcd47 Binary files /dev/null and b/docs/src/theme/DocCard/assets/issue.png differ diff --git a/docs/src/theme/DocCard/assets/manual.png b/docs/src/theme/DocCard/assets/manual.png new file mode 100644 index 000000000..1d74b4cad Binary files /dev/null and b/docs/src/theme/DocCard/assets/manual.png differ diff --git a/docs/src/theme/DocCard/assets/openinter.png b/docs/src/theme/DocCard/assets/openinter.png new file mode 100644 index 000000000..955f7cfb9 Binary files /dev/null and b/docs/src/theme/DocCard/assets/openinter.png differ diff --git a/docs/src/theme/DocCard/assets/openrouter.png b/docs/src/theme/DocCard/assets/openrouter.png new file mode 100644 index 000000000..17090d2b2 Binary files /dev/null and b/docs/src/theme/DocCard/assets/openrouter.png differ diff --git a/docs/src/theme/DocCard/assets/raycast.png b/docs/src/theme/DocCard/assets/raycast.png new file mode 100644 index 000000000..88a20d3ec Binary files /dev/null and b/docs/src/theme/DocCard/assets/raycast.png differ diff --git a/docs/src/theme/DocCard/assets/remote.png b/docs/src/theme/DocCard/assets/remote.png new file mode 100644 index 000000000..a52cbf46a Binary files /dev/null and b/docs/src/theme/DocCard/assets/remote.png differ diff --git a/docs/src/theme/DocCard/assets/setup.png b/docs/src/theme/DocCard/assets/setup.png new file mode 100644 index 000000000..a230704dc Binary files /dev/null and b/docs/src/theme/DocCard/assets/setup.png differ diff --git a/docs/src/theme/DocCard/assets/token.png b/docs/src/theme/DocCard/assets/token.png new file mode 100644 index 000000000..6de7d942b Binary files /dev/null and b/docs/src/theme/DocCard/assets/token.png differ diff --git a/docs/src/theme/DocCard/assets/v0.2.0.png b/docs/src/theme/DocCard/assets/v0.2.0.png new file mode 100644 index 000000000..a08219e02 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.2.0.png differ diff --git a/docs/src/theme/DocCard/assets/v0.2.1.png b/docs/src/theme/DocCard/assets/v0.2.1.png new file mode 100644 index 000000000..2883bf8e8 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.2.1.png differ diff --git a/docs/src/theme/DocCard/assets/v0.2.2.png b/docs/src/theme/DocCard/assets/v0.2.2.png new file mode 100644 index 000000000..f510e58ec Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.2.2.png differ diff --git a/docs/src/theme/DocCard/assets/v0.2.3.png b/docs/src/theme/DocCard/assets/v0.2.3.png new file mode 100644 index 000000000..92312d4a0 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.2.3.png differ diff --git a/docs/src/theme/DocCard/assets/v0.3.0.png b/docs/src/theme/DocCard/assets/v0.3.0.png new file mode 100644 index 000000000..0f86d3596 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.3.0.png differ diff --git a/docs/src/theme/DocCard/assets/v0.3.1.png b/docs/src/theme/DocCard/assets/v0.3.1.png new file mode 100644 index 000000000..9721c42b6 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.3.1.png differ diff --git a/docs/src/theme/DocCard/assets/v0.3.2.png b/docs/src/theme/DocCard/assets/v0.3.2.png new file mode 100644 index 000000000..ba8b0cdc8 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.3.2.png differ diff --git a/docs/src/theme/DocCard/assets/v0.3.3.png b/docs/src/theme/DocCard/assets/v0.3.3.png new file mode 100644 index 000000000..ab7131077 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.3.3.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.0.png b/docs/src/theme/DocCard/assets/v0.4.0.png new file mode 100644 index 000000000..7b474aee7 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.0.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.1.png b/docs/src/theme/DocCard/assets/v0.4.1.png new file mode 100644 index 000000000..7b3935045 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.1.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.2.png b/docs/src/theme/DocCard/assets/v0.4.2.png new file mode 100644 index 000000000..390dd3acf Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.2.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.3.png b/docs/src/theme/DocCard/assets/v0.4.3.png new file mode 100644 index 000000000..61add950b Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.3.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.4.png b/docs/src/theme/DocCard/assets/v0.4.4.png new file mode 100644 index 000000000..1989a47d3 Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.4.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.5.png b/docs/src/theme/DocCard/assets/v0.4.5.png new file mode 100644 index 000000000..677b548ea Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.5.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.6.png b/docs/src/theme/DocCard/assets/v0.4.6.png new file mode 100644 index 000000000..5f31b48ec Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.6.png differ diff --git a/docs/src/theme/DocCard/assets/v0.4.7.png b/docs/src/theme/DocCard/assets/v0.4.7.png new file mode 100644 index 000000000..e5f09c00d Binary files /dev/null and b/docs/src/theme/DocCard/assets/v0.4.7.png differ diff --git a/docs/src/theme/DocCard/index.js b/docs/src/theme/DocCard/index.js new file mode 100644 index 000000000..2a0a1b525 --- /dev/null +++ b/docs/src/theme/DocCard/index.js @@ -0,0 +1,190 @@ +import React from 'react'; +import clsx from 'clsx'; +import Link from '@docusaurus/Link'; +import { + findFirstSidebarItemLink, + useDocById, +} from '@docusaurus/theme-common/internal'; +import isInternalUrl from '@docusaurus/isInternalUrl'; +import {translate} from '@docusaurus/Translate'; +import Heading from '@theme/Heading'; +import styles from './styles.module.css'; +import engine from './assets/engine.png'; +import remote from './assets/remote.png'; +import manual from './assets/manual.png'; +import v047 from './assets/v0.4.7.png'; +import v046 from './assets/v0.4.6.png'; +import v045 from './assets/v0.4.5.png'; +import v044 from './assets/v0.4.4.png'; +import v043 from './assets/v0.4.3.png'; +import v042 from './assets/v0.4.2.png'; +import v041 from './assets/v0.4.1.png'; +import v040 from './assets/v0.4.0.png'; +import v033 from './assets/v0.3.3.png'; +import v032 from './assets/v0.3.2.png'; +import v031 from './assets/v0.3.1.png'; +import v030 from './assets/v0.3.0.png'; +import v023 from './assets/v0.2.3.png'; +import v022 from './assets/v0.2.2.png'; +import v021 from './assets/v0.2.1.png'; +import v020 from './assets/v0.2.0.png'; +import setup from './assets/setup.png'; +import importex from './assets/import.png'; +import continueint from './assets/continueint.png'; +import discord from './assets/discord.png'; +import raycast from './assets/raycast.png'; +import azure from './assets/azure.png'; +import openinter from './assets/openinter.png'; +import openrouter from './assets/openrouter.png'; +import denied from './assets/denied.png'; +import token from './assets/token.png'; +import issue from './assets/issue.png'; +import amiss from './assets/amiss.png'; +import broken from './assets/broken.png'; +import gpu from './assets/gpu.png'; +function CardContainer({href, children}) { + return ( + + {children} + + ); +} +function CardLayout({href, icon, title, description}) { + return ( + + + {icon} {title} + + {description && ( +

+ {description} +

+ )} +
+ ); +} +function CardCategory({item}) { + const href = findFirstSidebarItemLink(item); + // Unexpected: categories that don't have a link have been filtered upfront + if (!href) { + return null; + } + return ( + + ); +} +function CardLink({item}) { + // const icon = isInternalUrl(item.href) ? '📄️' : '🔗'; + const icon = (item.label === "Customize Engine Settings") ? ( + Logo + ) : (item.label === "Remote Server Integration") ? ( + Logo + ) : (item.label === "Manual Import") ? ( + Logo + ) : (item.label === "v0.4.7") ? ( + Logo + ) : (item.label === "v0.4.6") ? ( + Logo + ) : (item.label === "v0.4.5") ? ( + Logo + ) : (item.label === "v0.4.4") ? ( + Logo + ) : (item.label === "v0.4.3") ? ( + Logo + ) : (item.label === "v0.4.2") ? ( + Logo + ) : (item.label === "v0.4.1") ? ( + Logo + ) : (item.label === "v0.4.0") ? ( + Logo + ) : (item.label === "v0.3.3") ? ( + Logo + ) : (item.label === "v0.3.2") ? ( + Logo + ) : (item.label === "v0.3.1") ? ( + Logo + ) : (item.label === "v0.3.0") ? ( + Logo + ) : (item.label === "v0.2.3") ? ( + Logo + ) : (item.label === "v0.2.2") ? ( + Logo + ) : (item.label === "v0.2.1") ? ( + Logo + ) : (item.label === "v0.2.0") ? ( + Logo + ) : (item.label === "Extension Setup") ? ( + Logo + ) : (item.label === "Import Extensions") ? ( + Logo + ) : (item.label === "Continue Integration") ? ( + Logo + ) : (item.label === "OpenRouter") ? ( + Logo + ) : (item.label === "Azure OpenAI") ? ( + Logo + ) : (item.label === "Raycast") ? ( + Logo + ) : (item.label === "Discord") ? ( + Logo + ) : (item.label === "Open Interpreter") ? ( + Logo + ) : (item.label === "Permission Denied") ? ( + Logo + ) : (item.label === "Unexpected Token") ? ( + Logo + ) : (item.label === "Undefined Issue") ? ( + Logo + ) : (item.label === "Something's Amiss") ? ( + Logo + ) : (item.label === "Broken Build") ? ( + Logo + ) : (item.label === "Jan not using GPU") ? ( + Logo + ) : ( + // If not "Customize Engine Settings", use default icon + '📄️' + ); + const doc = useDocById(item.docId ?? undefined); + return ( + + ); +} +export default function DocCard({item}) { + switch (item.type) { + case 'link': + return ; + case 'category': + return ; + default: + throw new Error(`unknown item type ${JSON.stringify(item)}`); + } +} diff --git a/docs/src/theme/DocCard/styles.module.css b/docs/src/theme/DocCard/styles.module.css new file mode 100644 index 000000000..6868fd436 --- /dev/null +++ b/docs/src/theme/DocCard/styles.module.css @@ -0,0 +1,30 @@ +.cardContainer { + --ifm-link-color: var(--ifm-color-emphasis-800); + --ifm-link-hover-color: var(--ifm-color-emphasis-700); + --ifm-link-hover-decoration: none; + + box-shadow: 0 1.5px 3px 0 rgb(0 0 0 / 15%); + border: 1px solid var(--ifm-color-emphasis-200); + transition: all var(--ifm-transition-fast) ease; + transition-property: border, box-shadow; + height: 150px; +} + +.cardContainer:hover { + border-color: var(--ifm-color-primary); + box-shadow: 0 3px 6px 0 rgb(0 0 0 / 20%); +} + +.cardContainer *:last-child { + margin-bottom: 0; +} + +.cardTitle { + font-size: 1.2rem; + display: flex; + align-items: center; +} + +.cardDescription { + font-size: 0.8rem; +}