MoonCatWalkmain.tsx6 matches
40}
4142function parseGoal(x: number, y: number, goalX: number, goalY: number) {
43const parsed: { x: number; y: number; animation: AnimationLabel } = {
44x: x,
92}
9394function VirtualPet({ spriteNum }: { spriteNum: number }) {
95const [petState, setPetState] = useState<PetState>({
96behavior: "idle",
173174useEffect(() => {
175function handleMouseMove(e) {
176const now = Date.now();
177if (now - mousePos.current.moveTime > 2000) {
202useEffect(() => {
203let ignore = false;
204function doTick() {
205if (ignore) return;
206tick();
229}
230231function client() {
232const root = document.getElementById("root");
233if (root) {
241}
242243export default async function server(req: Request): Promise<Response> {
244const pathSegment = new URL(req.url).pathname.split("/")[1];
245const spriteNum = pathSegment && /^\d+$/.test(pathSegment)
serveAudiomain.tsx1 match
1export default async function serveAudio(req: Request): Promise<Response> {
2const { blob } = await import("https://esm.town/v/std/blob");
3
RobotBackupCallGraphmain.tsx15 matches
2import { thisWebURL } from "https://esm.town/v/stevekrouse/thisWebURL?v=2";
34export default async function server(req: Request): Promise<Response> {
5// Handle GET requests
6if (req.method === "GET") {
288layout: {
289name: 'preset',
290positions: function(node) {
291return { x: 0, y: 0 }; // Initial positions, will be overwritten
292}
297});
298299// Custom layout function
300function customLayout() {
301const mainGraph = cy.elements().not('#isolated, #isolated > node');
302const isolatedGraph = cy.getElementById('isolated');
349350// Add event listeners for highlighting
351cy.on('mouseover', 'node', function(e) {
352const node = e.target;
353highlightNodeChildrenAndParents(node);
354});
355356cy.on('mouseout', 'node', function(e) {
357unhighlightAll();
358});
359360cy.on('click', 'node', function(e) {
361const node = e.target;
362if (node.hasClass('highlighted') || node.hasClass('parent-highlighted')) {
368});
369370function highlightNodeChildrenAndParents(node) {
371const children = node.outgoers();
372const parents = node.incomers();
376}
377378function unhighlightAll() {
379cy.elements().removeClass('highlighted');
380cy.elements().removeClass('parent-highlighted');
529let match;
530while ((match = callRegex.exec(line)) !== null) {
531const calledFunction = match[1].toLowerCase();
532relationships.get(caller).add(calledFunction);
533allNodes.add(calledFunction);
534}
535});
545546const edges = [];
547relationships.forEach((calledFunctions, file) => {
548calledFunctions.forEach(calledFunction => {
549edges.push({
550data: {
551source: file,
552target: calledFunction,
553},
554});
welcomingPinkAlligatormain.tsx9 matches
4import { createRoot } from "https://esm.sh/react-dom/client";
56function debounce(func: Function, wait: number) {
7let timeout: number | undefined;
8return function executedFunction(...args: any[]) {
9const later = () => {
10clearTimeout(timeout);
16}
1718function App() {
19const [prompt, setPrompt] = useState("Generate a colorful gradient shader");
20const [code, setCode] = useState(`
79}, [code, debouncedRenderShader, retryCount]);
8081async function handleSubmit(e: React.FormEvent, shaderErrorMessage?: string) {
82if (e) e.preventDefault();
83setLoading(true);
149}
150151function client() {
152createRoot(document.getElementById("root")!).render(<App />);
153}
157}
158159function renderShader(canvas: HTMLCanvasElement, fragmentShaderSource: string, time: number) {
160const gl = canvas.getContext("webgl");
161if (!gl) {
171`;
172173function createShader(gl: WebGLRenderingContext, type: number, source: string) {
174const shader = gl.createShader(type);
175if (!shader) return null;
240}
241242function extractGLSLCode(text: string): string {
243const glslMatch = text.match(/```glsl\n([\s\S]*?)\n```/);
244return glslMatch
247}
248249export default async function server(req: Request): Promise<Response> {
250if (req.method === "POST") {
251const client = new Cerebras();
dailyDadJokemain.tsx1 match
2import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON";
34export async function dailyDadJoke() {
5let { setup, punchline } = await fetchJSON("https://official-joke-api.appspot.com/random_joke");
6return email({
isMyWebsiteDownmain.tsx1 match
6);
78export async function uptimeCheck(url: string) {
9let ok = true;
10let reason: string;
vttThumbMakermain.tsx6 matches
20export default app.fetch;
2122function html() {
23/*
24<!DOCTYPE html>
83}
8485function css() {
86/*
87body {
218}
219220function js() {
221/*
222const fileInput = document.getElementById('fileInput');
242let thumbnailMetadata;
243244function updateUI() {
245generateBtn.disabled = files.length === 0;
246thumbWidth.disabled = keepAspectRatio.checked;
247}
248249function resetToStep1() {
250thumbnailOptions.style.display = 'block';
251renderOptions.style.display = 'none';
377});
378379function getImage(file) {
380return new Promise((resolve) => {
381const url = URL.createObjectURL(file);
seamlessBlushSwallowmain.tsx9 matches
4import { createRoot } from "https://esm.sh/react-dom/client";
56function debounce(func: Function, wait: number) {
7let timeout: number | undefined;
8return function executedFunction(...args: any[]) {
9const later = () => {
10clearTimeout(timeout);
16}
1718function App() {
19const [prompt, setPrompt] = useState("Generate a colorful gradient shader");
20const [code, setCode] = useState(`
61}, [code, debouncedRenderShader]);
6263async function handleSubmit(e: React.FormEvent) {
64e.preventDefault();
65setLoading(true);
121}
122123function client() {
124createRoot(document.getElementById("root")!).render(<App />);
125}
129}
130131function renderShader(canvas: HTMLCanvasElement, fragmentShaderSource: string, time: number) {
132const gl = canvas.getContext("webgl");
133if (!gl) {
143`;
144145function createShader(gl: WebGLRenderingContext, type: number, source: string) {
146const shader = gl.createShader(type);
147if (!shader) return null;
218}
219220function extractGLSLCode(text: string): string {
221const glslMatch = text.match(/```glsl\n([\s\S]*?)\n```/);
222return glslMatch
225}
226227export default async function server(req: Request): Promise<Response> {
228if (req.method === "POST") {
229const anthropic = new Anthropic();
welcomingPinkAlligatormain.tsx9 matches
4import { createRoot } from "https://esm.sh/react-dom/client";
56function debounce(func: Function, wait: number) {
7let timeout: number | undefined;
8return function executedFunction(...args: any[]) {
9const later = () => {
10clearTimeout(timeout);
16}
1718function App() {
19const [prompt, setPrompt] = useState("Generate a colorful gradient shader");
20const [code, setCode] = useState(`
79}, [code, debouncedRenderShader, retryCount]);
8081async function handleSubmit(e: React.FormEvent, shaderErrorMessage?: string) {
82if (e) e.preventDefault();
83setLoading(true);
149}
150151function client() {
152createRoot(document.getElementById("root")!).render(<App />);
153}
157}
158159function renderShader(canvas: HTMLCanvasElement, fragmentShaderSource: string, time: number) {
160const gl = canvas.getContext("webgl");
161if (!gl) {
171`;
172173function createShader(gl: WebGLRenderingContext, type: number, source: string) {
174const shader = gl.createShader(type);
175if (!shader) return null;
240}
241242function extractGLSLCode(text: string): string {
243const glslMatch = text.match(/```glsl\n([\s\S]*?)\n```/);
244return glslMatch
247}
248249export default async function server(req: Request): Promise<Response> {
250if (req.method === "POST") {
251const client = new Cerebras();
welcomingPinkAlligatormain.tsx9 matches
4import { createRoot } from "https://esm.sh/react-dom/client";
56function debounce(func: Function, wait: number) {
7let timeout: number | undefined;
8return function executedFunction(...args: any[]) {
9const later = () => {
10clearTimeout(timeout);
16}
1718function App() {
19const [prompt, setPrompt] = useState("Generate a colorful gradient shader");
20const [code, setCode] = useState(`
79}, [code, debouncedRenderShader, retryCount]);
8081async function handleSubmit(e: React.FormEvent, shaderErrorMessage?: string) {
82if (e) e.preventDefault();
83setLoading(true);
149}
150151function client() {
152createRoot(document.getElementById("root")!).render(<App />);
153}
157}
158159function renderShader(canvas: HTMLCanvasElement, fragmentShaderSource: string, time: number) {
160const gl = canvas.getContext("webgl");
161if (!gl) {
171`;
172173function createShader(gl: WebGLRenderingContext, type: number, source: string) {
174const shader = gl.createShader(type);
175if (!shader) return null;
240}
241242function extractGLSLCode(text: string): string {
243const glslMatch = text.match(/```glsl\n([\s\S]*?)\n```/);
244return glslMatch
247}
248249export default async function server(req: Request): Promise<Response> {
250if (req.method === "POST") {
251const client = new Cerebras();