๐จ Palette: ๋ฃจํธ ๋๋ ํ ๋ฆฌ ์ด๋ฆ Fallback ์ถ๊ฐ - #273
Conversation
|
๐ Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a ๐ emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
There was a problem hiding this comment.
Pull request overview
This PR improves the generated directory listing HTML so that when File.getName() is empty (notably for filesystem root directories), the page <title> and <h1> fall back to using the directoryโs absolutePath, improving context for users (including screen reader users).
Changes:
- Add
dirNameToDisplayfallback (nameโabsolutePathwhen empty) and use it for<title>/<h1>inprocess_dir. - Add a unit test covering the empty-name fallback behavior.
- Document the learned rule and action in
.jules/palette.md.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/main/kotlin/html4tree/main.kt | Adds a display-name fallback for empty directory names and applies it to <title>/<h1>. |
| src/test/kotlin/html4tree/MainTest.kt | Adds a regression test validating the fallback behavior when getName() returns "". |
| .jules/palette.md | Documents the root-directory empty-name behavior and the recommended fallback approach. |
๐ก Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ${cssContent} </style> | ||
| """ | ||
|
|
||
| val dirNameToDisplay = curr_dir.getName().ifEmpty { curr_dir.absolutePath } |
|
Closing as superseded by draft canonical #364. The same absolute-path fallback for filesystem roots is retained there under a bounded post-#363 accessibility contract. #364 must still centralize one escaped display label, prove root and ordinary generated pages, add APA 7 doctoring and changelog, and pass fresh exact-head quality/security checks plus independent approval. No evidence from this duplicate head is reused. |
Understood. Acknowledging that this work is now superseded by #364 and stopping work on this task. |
๐ก What (์ถ๊ฐ๋ ๊ธฐ๋ฅ)
File.getName()์ด ๋น ๋ฌธ์์ด์ ๋ฐํํ๋ ๊ฒฝ์ฐ,absolutePath๋ฅผ Fallback์ผ๋ก ์ฌ์ฉํ์ฌ<title>๋ฐ<h1>๋ฅผ ์์ฑํ๋๋ก ๋ณ๊ฒฝํ์ต๋๋ค.๐ฏ Why (ํด๊ฒฐํ ์ฌ์ฉ์ ๋ฌธ์ )
<title>๋ฐ<h1>์์๊ฐ ์์ ํ ๋น์ด ์์ด, ์ฌ์ฉ์(ํนํ ์คํฌ๋ฆฐ ๋ฆฌ๋ ์ฌ์ฉ์)๊ฐ ํ์ฌ ์์น๋ฅผ ํ์ ํ๊ธฐ ์ด๋ ค์ ์ต๋๋ค.๐ธ Before/After
<title></title>,<h1></h1>(๋ฃจํธ ๋๋ ํ ๋ฆฌ์ ๊ฒฝ์ฐ)<title>/</title>,<h1>/</h1>๋ฑabsolutePath๋ฅผ ํ์.โฟ Accessibility (์ ๊ทผ์ฑ ๊ฐ์ ์ฌํญ)
PR created automatically by Jules for task 3259555537994780888 started by @seonghobae