fb9c9f98db
Coming back to LIBRARY froze the screen for a second and a half. It was not the tree — the tree has been up in under a hundred milliseconds all along. It was the strip: it made a `<button>`, an `<img>` and an object URL for every frame the open node held, and an object URL costs about a tenth of a millisecond, which is a second of blocked main thread on a roll of twenty thousand. Six and a half thousand tiles were built for pictures nobody had scrolled to. The strip now draws the run under its viewport and `STRIP_KEEP` tiles either side of it, measured from `scrollLeft` and the client width on scroll and on resize. Two spacers stand in for the runs that are not drawn, each as wide as the tiles it replaces, so the scrollbar still measures the shelf rather than the window: the sum is the same `140n − 8` in every case. The frame on the stage is given its URL wherever it sits, since the stage is not the strip. Measured against a seeded roll of 19998 frames: the first tile 1816ms → 663ms on a cold visit and 1728ms → 681ms coming back from the studio; the long tasks 1302ms across five of them → 184ms across one. Tiles drawn 6666 → 18, with the scrollbar unmoved (the far end draws the far frames, and the frame on the stage keeps its picture once its tile is out of the window). The wall is the other view and still holds every frame on purpose; it is the one list left that builds a card per frame.