Show the script by default, with the option to hide it
2 changed files+7−7
scripts/browser-test.mjsmodified+1−1View file
@@ -157,7 +157,7 @@ try {
157157 check('16 roots drawn in the complex plane', roots === 16, `${roots} roots`)
158158
159159 // ── swapping the method changes the verdict ────────────────────────────
160- // the editor starts collapsed; the method dropdown lives inside it
160+ // the editor is open by default, but reopen it if a stored preference hid it
161161 console.log('\nEqual weights: the counter-example')
162162 await page.evaluate(() => document.querySelector('.editor-strip')?.click())
163163 await page.waitForSelector('.script-head select', { timeout: 10000 })
src/App.tsxmodified+6−6View file
@@ -32,13 +32,13 @@ export default function App() {
3232 const [script, setScript] = useState(() => DEFAULT_METHOD.source)
3333 const [dirty, setDirty] = useState(false)
3434 const [tab, setTab] = useState<TabId>('interpolant')
35- // The editor is the point of the app for a reader of the paper, but a wall of
36- // MATLAB for anyone else, so it starts collapsed and the choice persists.
35+ // The editor is the point of the app, so it starts open; anyone who would
36+ // rather have the plots alone can hide it, and that choice persists.
3737 const [editorOpen, setEditorOpen] = useState(() => {
3838 try {
39- return localStorage.getItem('br-editor-open') === '1'
39+ return localStorage.getItem('br-editor-open') !== '0'
4040 } catch {
41- return false
41+ return true
4242 }
4343 })
4444 useEffect(() => {
@@ -198,8 +198,8 @@ export default function App() {
198198 <a href="https://doi.org/10.1007/s00211-007-0093-y" target="_blank" rel="noreferrer">
199199 Numer. Math. <b>107</b> (2007) 315–331
200200 </a>
201- . Every plot is computed live by a short MATLAB script you can open and edit; it runs in
202- your browser through{' '}
201+ . Every plot is computed live by the short MATLAB script on the left, which you can
202+ edit; it runs in your browser through{' '}
203203 <a href="https://numbl.org" target="_blank" rel="noreferrer">
204204 numbl
205205 </a>