vimium icon indicating copy to clipboard operation
vimium copied to clipboard

Center align "Save changes" button label in Options

Open breadtk opened this issue 4 months ago • 2 comments

Description

Within the Options page, the #save button is displayed as "No changes" (10 chars) on load. When onUpdated() is called in pages/options.js, it turns into "Save changes" (12 chars). This commit ensures that the update label is appropriately centered, even if that means less padding on left/right, as opposed to having more padding on left/right in the fixed size button.

breadtk avatar Aug 30 '25 01:08 breadtk

I think the preferred way to do this might be to remove the width property from the #save styles. That would mean that the button size can change though, so it depends on preference. However, this problem is likely to happen again in the future since the Add Rule button, and potentially other buttons, also share the #save style. It might be better just let them set their own width to avoid accidentally letting the text overflow. We could also use a min-width instead, and then future accidentally longer text wouldn't overflow.

UncleSnail avatar Nov 11 '25 21:11 UncleSnail

I'm fine either way.

@ilya / @philc - Do you folks have a preference either way?

breadtk avatar Nov 17 '25 16:11 breadtk