[wp-trac] [WordPress Trac] #29022: Screen reader text (and link title) isn't updated when plugin update count is updated

WordPress Trac noreply at wordpress.org
Sun Aug 3 16:24:31 UTC 2014


#29022: Screen reader text (and link title) isn't updated when plugin update count
is updated
-------------------------+-------------------------------------------------
 Reporter:  pento        |       Owner:
     Type:  defect       |      Status:  new
  (bug)                  |   Milestone:  Awaiting Review
 Priority:  normal       |     Version:  3.9
Component:               |  Resolution:
  Upgrade/Install        |     Focuses:  accessibility, javascript,
 Severity:  minor        |  administration
 Keywords:  has-patch    |
  dev-feedback           |
-------------------------+-------------------------------------------------

Comment (by adamsilverstein):

 Thanks for the detailed feedback! That all makes sense... i think we are
 getting closer :)

 I knew there was something wrong with the translation approach, couldn't
 remember why so thanks for explaining that detail.

 Will work on an updated patch!



 Replying to [comment:9 pento]:
 > attachment:29022.diff is closer to what I had in mind. There are a few
 changes that it'll need:
 >
 > The strings need to keep the `%d` (ie, "%d Plugin Updates"). Some
 languages will move the number to a different location in the string, so
 we can't just do a string concat in the JS. Instead, we can search and
 replace the `%d`, like what already happens in
 [https://core.trac.wordpress.org/browser/trunk/src/wp-admin/js/nav-
 menu.js?rev=28707#L456 nav-menu.js].
 >
 > Because the strings are used in `update.js`, not `plugin-install.js`,
 the `$scripts->localize()` should be for `install`.
 >
 > Instead of including the numbers in a hidden span, they can also be
 included as part of the `$scripts->localize()` call. This is the standard
 method for passing this kind of data.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/29022#comment:10>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list