diff --git a/website/src/repl/Footer.jsx b/website/src/repl/Footer.jsx index 28939c03..522b2f8d 100644 --- a/website/src/repl/Footer.jsx +++ b/website/src/repl/Footer.jsx @@ -76,7 +76,7 @@ export function Footer({ context }) { - + {activeFooter !== '' && ( setActiveFooter('')} className="text-foreground" aria-label="Close Panel"> @@ -89,113 +89,11 @@ export function Footer({ context }) { className="text-white font-mono text-sm h-[360px] flex-none overflow-auto max-w-full relative" ref={footerContent} > - {activeFooter === 'intro' && ( - - - 🌀 welcome - - - You have found strudel, a new live coding platform to write dynamic - music pieces in the browser! It is free and open-source and made for beginners and experts alike. To get - started: - - - 1. hit play - 2. change something{' '} - - 3. hit update - - If you don't like what you hear, try shuffle! - - - To learn more about what this all means, check out the{' '} - - interactive tutorial - - . Also feel free to join the{' '} - - tidalcycles discord channel - {' '} - to ask any questions, give feedback or just say hello. - - about - - strudel is a JavaScript version of{' '} - - tidalcycles - - , which is a popular live coding language for music, written in Haskell. You can find the source code at{' '} - - github - - . Please consider to{' '} - - support this project - {' '} - to ensure ongoing development 💖 - - - )} - {activeFooter === 'console' && ( - - {log.map((l, i) => { - const message = linkify(l.message); - return ( - - - {l.count ? ` (${l.count})` : ''} - - ); - })} - - )} - {activeFooter === 'samples' && ( - - {loadedSamples.length} banks loaded: - {loadedSamples.map(([name, samples]) => ( - {}}> - {' '} - {name}( - {Array.isArray(samples) - ? samples.length - : typeof samples === 'object' - ? Object.values(samples).length - : 1} - ){' '} - - ))} - - )} + {activeFooter === 'intro' && } + {activeFooter === 'console' && } + {activeFooter === 'samples' && } {activeFooter === 'reference' && } - {activeFooter === 'theme' && ( - - {Object.entries(themes).map(([k, t]) => ( - { - setTheme(k); - document.dispatchEvent( - new CustomEvent('strudel-theme', { - detail: k, - }), - ); - }} - > - {k} - - {themeColors(t).map((c, i) => ( - - ))} - - - ))} - - )} + {activeFooter === 'settings' && } )} @@ -226,3 +124,118 @@ function linkify(inputText) { return replacedText; } + +function WelcomeTab() { + return ( + + + 🌀 welcome + + + You have found strudel, a new live coding platform to write dynamic music + pieces in the browser! It is free and open-source and made for beginners and experts alike. To get started: + + + 1. hit play - 2. change something -{' '} + 3. hit update + + If you don't like what you hear, try shuffle! + + + To learn more about what this all means, check out the{' '} + + interactive tutorial + + . Also feel free to join the{' '} + + tidalcycles discord channel + {' '} + to ask any questions, give feedback or just say hello. + + about + + strudel is a JavaScript version of{' '} + + tidalcycles + + , which is a popular live coding language for music, written in Haskell. You can find the source code at{' '} + + github + + . Please consider to{' '} + + support this project + {' '} + to ensure ongoing development 💖 + + + ); +} + +function ConsoleTab({ log }) { + return ( + + {log.map((l, i) => { + const message = linkify(l.message); + return ( + + + {l.count ? ` (${l.count})` : ''} + + ); + })} + + ); +} + +function SamplesTab() { + return ( + + {loadedSamples.length} banks loaded: + {loadedSamples.map(([name, samples]) => ( + {}}> + {' '} + {name}( + {Array.isArray(samples) ? samples.length : typeof samples === 'object' ? Object.values(samples).length : 1}){' '} + + ))} + + ); +} +function SettingsTab({ theme, setTheme }) { + /*{ + console.log('vim mode toggle', checked) + }}/>*/ + + return ( + + {Object.entries(themes).map(([k, t]) => ( + { + setTheme(k); + document.dispatchEvent( + new CustomEvent('strudel-theme', { + detail: k, + }), + ); + }} + > + {k} + + {themeColors(t).map((c, i) => ( + + ))} + + + ))} + + ); +}
- You have found strudel, a new live coding platform to write dynamic - music pieces in the browser! It is free and open-source and made for beginners and experts alike. To get - started: - - - 1. hit play - 2. change something{' '} - - 3. hit update - - If you don't like what you hear, try shuffle! -
- To learn more about what this all means, check out the{' '} - - interactive tutorial - - . Also feel free to join the{' '} - - tidalcycles discord channel - {' '} - to ask any questions, give feedback or just say hello. -
- strudel is a JavaScript version of{' '} - - tidalcycles - - , which is a popular live coding language for music, written in Haskell. You can find the source code at{' '} - - github - - . Please consider to{' '} - - support this project - {' '} - to ensure ongoing development 💖 -
+ You have found strudel, a new live coding platform to write dynamic music + pieces in the browser! It is free and open-source and made for beginners and experts alike. To get started: + + + 1. hit play - 2. change something -{' '} + 3. hit update + + If you don't like what you hear, try shuffle! +
+ To learn more about what this all means, check out the{' '} + + interactive tutorial + + . Also feel free to join the{' '} + + tidalcycles discord channel + {' '} + to ask any questions, give feedback or just say hello. +
+ strudel is a JavaScript version of{' '} + + tidalcycles + + , which is a popular live coding language for music, written in Haskell. You can find the source code at{' '} + + github + + . Please consider to{' '} + + support this project + {' '} + to ensure ongoing development 💖 +