Skip to content

fix(one-page): show a picked note's whole name in the file picker on phones - #2112

Merged
chhoumann merged 1 commit into
masterfrom
fix/2106-phone-file-chip
Oct 1, 2026
Merged

chhoumann merged 1 commit into
masterfrom
fix/2106-phone-file-chip

Conversation

@chhoumann

@chhoumann chhoumann commented Oct 1, 2026 •

Copy link
Copy Markdown
Owner

On a phone, a note picked in the one-page form's file picker now shows its whole name. Before, the chip's × took the chip's width and the name was cut to "Ada …" or "M…". Since #2099 every one-page Capture to a folder, tag or property uses this picker.

Before After
Light before after
Dark before after

Obsidian 1.13.7, dev:mobile on at 390x844, a Capture to People/ with one-page input on. Desktop is unchanged.

How

Obsidian's .is-phone .modal .setting-item-control button:not(.clickable-icon) sets width: 100%, and .is-phone .modal .setting-item-control button adds padding: 10px. Both outrank .quickAddModal .qa-onepage-file-picker__remove. One rule with the same specificity, loaded after Obsidian's, puts back the remove button's 1.4rem width and zero padding on phones.

Tests

  • tests/e2e/one-page-capture-target.test.ts: under phone host styles, the chip shows "Mercury" uncut and the × is 22 px wide. On master it fails with cut: true and a 62 px ×.
  • pnpm run build-with-lint, pnpm run test (6599 passed), .agents/run-e2e (396 passed, 24 Templater-only skipped).

Release / migration

None.

Fixes #2106

Note

Fix one-page file picker remove-button width on phones

Adds a phone-scoped CSS rule for the quick-add modal's selected-note remove button. It sets a fixed 1.4rem width and removes padding so the button no longer inherits the modal setting-control sizing. This frees horizontal space so the picked note's full name shows in the file picker.

Macroscope summarized db56fce.

Summary by CodeRabbit

  • Bug Fixes
    • Improved the one-page capture target picker on phones: the remove button now has a consistent width and no extra padding, helping the selected note chip display without clipping.

…phones

Obsidian stretches every button in a phone modal's setting control to full
width, so the chip's remove button took the chip and cut the note's name to
a few letters. Since #2099 every one-page Capture to field shows this chip.

Fixes #2106
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-01T10:38:26.738670Z db56fce PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: 0cde211f-3dd7-4bad-862e-c30adf732df6

📥 Commits

Reviewing files that changed from the base of the PR and between fcb315d and db56fce.

📒 Files selected for processing (2)
  • src/styles.css
  • tests/e2e/one-page-capture-target.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 5 remain after this review.


📝 Walkthrough

Walkthrough

The phone-specific stylesheet sets a fixed width and zero padding for the one-page file-picker remove button. An end-to-end test checks that the picked note name displays and that the button is 22 pixels wide.

Changes

Phone file-picker chip

Layer / File(s) Summary
Phone chip sizing and validation
src/styles.css, tests/e2e/one-page-capture-target.test.ts
The phone-specific style sets the remove button width to 1.4rem and padding to 0. The test checks that “Mercury” displays without clipping and that the remove button is 22 pixels wide. It also cancels the modal and restores the original body classes.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix · Severity of issue fixed: Low

Merge Risk: ⚪ Minimal · up to db56f

The change is narrowly scoped to phone file-picker presentation and includes targeted layout coverage. No merge-blocking issue is established.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: showing the full picked note name in the one-page file picker on phones.
Linked Issues check ✅ Passed Issue #2106 requires the one-page file-picker chip to show the picked note name and a small remove control on phones. src/styles.css sets .qa-onepage-file-picker__remove to 1.4rem width and zero…
Out of Scope Changes check ✅ Passed The pull request changes only the phone-specific remove-button CSS and adds a regression test for the one-page capture-target picker. Both changes directly support issue #2106. No unrelated product be…
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

A rabbit checks the chip at night
“Mercury” fits, the name reads right
A little × now keeps its space
The phone test checks the button’s place
Then hops away, content and bright

Comment @coderabbitai help to get the list of available commands.

@chhoumann
chhoumann merged commit 001a342 into master Oct 1, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Phone: a picked note in the one-page file picker shows only its first letters

1 participant