Fix attempt 2 for #260. Owner: button must be fully static on click; attempt 1's min-width pin enlarged buttons by up to 0.64px (Math.ceil of a fractional width) and leaked the pin after restore.
Approach: .swapbtn pattern as QA guidance specified. The label and the checkmark stack in one grid cell (inline-grid, both children grid-area 1/1, checkmark visibility:hidden until .ok), so feedback is a pure classList toggle and no width pinning exists at all. Applied to paste-view Copy/Link (paste.html + paste.js copyFeedback) and the /new result-box copy button (new.js).
Verified locally with CDP bounding-box probes on a test build:
Paste view #copy-btn: width/x identical before/during/after at 1400x900 (76.421875px) and 375x812 (52.359375px, the exact case attempt 1 failed); Link and Wrap neighbors static; checkmark visibility=visible during feedback.
/new result copy button: width 44.953125px static across click at both widths, checkmark visible, btn.style.minWidth empty.
Fix attempt 2 for #260. Owner: button must be fully static on click; attempt 1's min-width pin enlarged buttons by up to 0.64px (Math.ceil of a fractional width) and leaked the pin after restore.
Approach: .swapbtn pattern as QA guidance specified. The label and the checkmark stack in one grid cell (inline-grid, both children grid-area 1/1, checkmark visibility:hidden until .ok), so feedback is a pure classList toggle and no width pinning exists at all. Applied to paste-view Copy/Link (paste.html + paste.js copyFeedback) and the /new result-box copy button (new.js).
Verified locally with CDP bounding-box probes on a test build:
- Paste view #copy-btn: width/x identical before/during/after at 1400x900 (76.421875px) and 375x812 (52.359375px, the exact case attempt 1 failed); Link and Wrap neighbors static; checkmark visibility=visible during feedback.
- /new result copy button: width 44.953125px static across click at both widths, checkmark visible, btn.style.minWidth empty.
- go build + go test ./... pass.
Ref #260
Label and checkmark stack in one grid cell (inline-grid, grid-area 1/1,
checkmark visibility-hidden until .ok), so the button width is static by
construction across the click. Replaces the min-width pin from fix attempt
1, which enlarged buttons by up to 0.64px (ceil of fractional width) and
leaked the pin after restore.
Applies to paste-view Copy/Link (paste.html + paste.js copyFeedback) and
the /new result-box copy button (new.js). Verified with CDP bounding-box
probes: Copy width/x identical before/during/after at 1400x900 and
375x812 (including the previously failing 52.36px mobile case), Link
button static, checkmark visible during feedback, no minWidth pin set.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Fix attempt 2 for #260. Owner: button must be fully static on click; attempt 1's min-width pin enlarged buttons by up to 0.64px (Math.ceil of a fractional width) and leaked the pin after restore.
Approach: .swapbtn pattern as QA guidance specified. The label and the checkmark stack in one grid cell (inline-grid, both children grid-area 1/1, checkmark visibility:hidden until .ok), so feedback is a pure classList toggle and no width pinning exists at all. Applied to paste-view Copy/Link (paste.html + paste.js copyFeedback) and the /new result-box copy button (new.js).
Verified locally with CDP bounding-box probes on a test build:
Ref #260
Pull request closed