From a65c55e46345160cedabec5fa7e9f03038dea466 Mon Sep 17 00:00:00 2001 From: Roland Date: Sun, 2 Aug 2026 19:46:41 -0600 Subject: [PATCH] review: record why make-directory is wider than rename Acting on the review of #628. No bugs; one suggestion and one nit, and the suggestion is answered with a measurement rather than a change. The review asked whether MakeDirectoryModal should drop back to `small`, on the grounds that its body -- a path, one field and a button -- is the same shape as RenameModal's, which is `small`. The shapes are the same; the content is not. Rename shows a RELATIVE path, make-directory shows the absolute one including the media directory, and a bare `
` is `white-space: pre`, so it scrolls out of
sight rather than wrapping.

Measured in the browser at both widths: 440px holds 42 characters, 620px holds 61.
`/media/wrolpi/videos/Practical Engineering/Season 2024/` is 55.  So an ordinary
channel-and-season path is unreadable at 440 and fits at 620, which is exactly
the condition the review set for keeping it.  The dev tree hides this -- its
paths are around 22 characters and fit either way.

Both `large` call sites now carry the audit comment the other three had, which
was the nit.  Make-directory's records the measurement, because it does read like
an inconsistency beside rename and the next person to notice should see the
numbers before narrowing it back.

1134 jest / 64 suites (--maxWorkers=2; see the previous commit), clean build.
---
 app/src/components/FileBrowser.js | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/app/src/components/FileBrowser.js b/app/src/components/FileBrowser.js
index 1c6ca81b..f4434bde 100644
--- a/app/src/components/FileBrowser.js
+++ b/app/src/components/FileBrowser.js
@@ -711,6 +711,11 @@ export function MoveModal({open, paths, onClose, onSubmit}) {
         {destination ? fileCell(destination + '/' + pathName(i)) : fileCell(pathName(i))}
     );
 
+    /*
+     * Audited: `large` (620px).  This dialog holds a DirectorySearch and a two-column
+     * Source/Destination table of every path being moved, which is the densest content
+     * of the five FileBrowser modals.
+     */
     return ` is `white-space: pre`, so it scrolls rather
+     * than wraps.  Measured in the browser: 440px holds 42 characters and 620px holds
+     * 61.  `/media/wrolpi/videos/Practical Engineering/Season 2024/` is 55, so an
+     * ordinary channel-and-season path scrolls out of sight at 440 and fits at 620.
+     *
+     * Written out because it reads like an inconsistency next to rename, and the next
+     * person to notice that should see the measurement before narrowing it back.
+     */
     return 
         Make Directory