-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Remove unused util $.fn.focusNextInputField
#9180
Conversation
dd78577
to
c35172e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @RayBB! The changes to the excerpts
template are causing errors on the book edit page. Switching from string interpolation to string concatenation should fix things.
@@ -66,7 +66,7 @@ | |||
{{excerpt}} | |||
<br /> | |||
<i> | |||
{{cond(pages, "From page " + pages + ".", "")}} | |||
{{pages ? `From page ${pages}.` : "";}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is causing an error on the edit page. I think that the template parser is having issues with the $
character. Escaping the character (\$
) led to some new errors in my browser's console output.
It's probably best to switch back to old-fashioned string concatenation for this case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jimchamp good catch... it is fixed as you suggested!
Howdy folks, I've been thinking about this one and I think it might be best for us to close this. Even if we remove the places where our jsdef code uses e.g. |
To clarify, here is what I mean by jsdef using these files: openlibrary/openlibrary/templates/subjects.html Lines 84 to 91 in 1860c25
The |
@cdrini thanks for replying. Should we also keep Do we need to keep the |
|
@cdrini sounds good to me. I've pushed code with a comment about this and removing |
$.fn.focusNextInputField
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm! Tested on testing (the only place I can think where this might apply is the "add one?" link for description, which focusses on the description box; still works!) + can't find any references to that method.
Closes #9179
Technical
Testing
Did a fulltext search of the code and these aren't used anywhere I can see but a second check would be good.
Removes one unused piece of code and adds a comment about why we want to keep the rest.
Screenshot
Stakeholders