Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Toolbar plurality issue when only a single capture #372

Closed
machawk1 opened this issue Feb 4, 2018 · 5 comments
Closed

Toolbar plurality issue when only a single capture #372

machawk1 opened this issue Feb 4, 2018 · 5 comments

Comments

@machawk1
Copy link
Contributor

machawk1 commented Feb 4, 2018

If only one capture exists for a URI-R, the web UI toolbar states, "1 captures", an incorrect plurality.
screen shot 2018-02-04 at 12 00 29 am

This stems from wayback-webapp/src/main/webapp/WEB-INF/replay/Toolbar.jsp reading ToolBar.numCapturesTitle from wayback-webapp/src/main/resources/WaybackUI.properties and providing a formatted value that does not affect the "captures" literal of the formatted string.

OpenWayback 2.3.2

@anjackson
Copy link
Member

anjackson commented Feb 5, 2018

Hm, I find ChoiceFormat a bit confusing, but it would seem the syntax we need for this is:

ToolBar.numCapturesText={0} {0,choice,0#captures|1#capture|1<captures} 

n.b. I've not had a chance to test this yet.

@ldko
Copy link
Member

ldko commented Feb 5, 2018

Hi @machawk1 , thanks for reporting the issue. Do you want to submit a PR to fix this?

@machawk1
Copy link
Contributor Author

machawk1 commented Feb 5, 2018

That fix works for me, @anjackson.

screen shot 2018-02-05 at 11 47 52 am

screen shot 2018-02-05 at 11 53 47 am

I'll submit a PR, @ldko .

@machawk1
Copy link
Contributor Author

machawk1 commented Feb 5, 2018

PR submitted as #373. /cc @ldko

@ldko ldko closed this as completed in 7f49807 Feb 5, 2018
ldko added a commit that referenced this issue Feb 5, 2018
@ldko
Copy link
Member

ldko commented Feb 5, 2018

Thanks @machawk1 and @anjackson !

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

No branches or pull requests

3 participants