-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c235ed5
commit 65b3f80
Showing
14 changed files
with
117 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,11 @@ | |
"tasks": { | ||
// The task to automatically generate `./src/celestial.ts` | ||
"bind": "deno run -A ./bindings/_tools/generate/mod.ts && deno fmt", | ||
"test": "deno test -A --trace-ops" | ||
"test": "deno test -A --trace-ops", | ||
"www": "cd docs && pyro dev" | ||
}, | ||
"compilerOptions": { | ||
"jsx": "react-jsx", | ||
"jsxImportSource": "https://esm.sh/[email protected]" | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
title: 3.1 - Binaries | ||
title: Binaries | ||
description: How Astral deals with binaries | ||
index: 0 | ||
--- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
title: 2.2 - Bindings | ||
title: Bindings | ||
description: How Astral generates bindings | ||
index: 1 | ||
--- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
title: 3 - Advanced | ||
title: Advanced | ||
description: Advanced topics for Astral | ||
index: 2 | ||
--- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
docs/pages/examples/evaluate.md → docs/pages/guides/evaluate.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
docs/pages/examples/navigation.md → docs/pages/guides/navigation.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
docs/pages/examples/screenshot.md → docs/pages/guides/screenshot.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
import { ensureDirSync } from "https://deno.land/[email protected]/fs/ensure_dir.ts"; | ||
import { launch } from "../../mod.ts"; | ||
import { type PageProps } from "https://deno.land/x/[email protected]/page.ts"; | ||
import { ensureFileSync } from "https://deno.land/[email protected]/fs/ensure_file.ts"; | ||
|
||
export const config = { | ||
title: "Showcase", | ||
description: "A small showcase for projects that use Astral!", | ||
}; | ||
|
||
interface Project { | ||
title: string; | ||
description: string; | ||
source: string; | ||
} | ||
|
||
const projects: Project[] = [ | ||
{ | ||
title: "Manuscript Marauder", | ||
description: "Download manuscripts using a proxy", | ||
source: "https://github.com/rnbguy/manuscript-marauder", | ||
}, | ||
]; | ||
|
||
export default function Page(props: PageProps) { | ||
return ( | ||
<div class="flex flex-col items-center min-h-screen bg-white dark:bg-dark dark:text-white"> | ||
{props.header} | ||
<div class="flex-grow py-8 w-full flex flex-col items-center"> | ||
<div class="text-center flex flex-col items-center gap-4"> | ||
<h2 class="font-bold text-3xl">Astral Project Showcase</h2> | ||
<p class="text-gray-500 dark:text-gray-400"> | ||
List of projects people are building with Astral | ||
</p> | ||
<a | ||
class="rounded px-8 py-2 bg-purple-500 text-white w-max font-semibold text-sm" | ||
href="https://github.com/lino-levan/astral/issues/new" | ||
> | ||
🙏 Please add your project | ||
</a> | ||
</div> | ||
<div class="max-w-screen-xl pt-8 px-8 flex flex-wrap gap-8 justify-center"> | ||
{projects.map((project) => ( | ||
<div class="w-72 bg-white dark:bg-black shadow-lg rounded-lg overflow-hidden"> | ||
<a href={project.source}> | ||
<img | ||
class="w-full h-36" | ||
src={`/showcase${new URL(project.source).pathname}.png`} | ||
/> | ||
</a> | ||
<div class="p-4 border-t-2 dark:border-gray-500"> | ||
<a | ||
href={project.source} | ||
class="text-purple-600 dark:text-purple-500 font-semibold hover:underline" | ||
> | ||
{project.title} | ||
</a> | ||
<p class="text-gray-800 dark:text-gray-300"> | ||
{project.description} | ||
</p> | ||
</div> | ||
</div> | ||
))} | ||
</div> | ||
</div> | ||
{props.footer} | ||
</div> | ||
); | ||
} | ||
|
||
// let's boot astral and download some stuff :) | ||
if (import.meta.main) { | ||
const browser = await launch(); | ||
const page = await browser.newPage(); | ||
|
||
for (const project of projects) { | ||
await page.goto(project.source); | ||
const screenshot = await page.screenshot(); | ||
const path = `./docs/static/showcase${ | ||
new URL(project.source).pathname | ||
}.png`; | ||
ensureFileSync(path); | ||
|
||
Deno.writeFileSync(path, screenshot); | ||
} | ||
|
||
await browser.close(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.