Commit Graph

10 Commits

Author SHA1 Message Date
Andrew Ozz
bac1ada04d Quick/Bulk Edit: Fix undefined error when initializing UI Autocomplete 1.12.1 on non-existing element and then attempting to use the autocomplete instance.
Example: `jQuery( '#nonexisting' ).autocomplete().autocomplete( 'instance' ).something`.

Props _luigi, sabernhardt, donmhico, azaozz.
Fixes #51872.
Built from https://develop.svn.wordpress.org/trunk@49703


git-svn-id: http://core.svn.wordpress.org/trunk@49426 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-11-28 12:46:05 +00:00
Dominik Schilling
3d95a45675 I18N: Use wp.i18n for translatable strings in wp-admin/js/tags-box.js and wp-admin/js/tags-suggest.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50579.
Built from https://develop.svn.wordpress.org/trunk@48350


git-svn-id: http://core.svn.wordpress.org/trunk@48119 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 21:00:03 +00:00
Sergey Biryukov
49007e52bc Build/Test Tools: Add banner to RTL CSS and minified JS files.
Patches occasionally come in on generated files. We should be kind to new contributors and give them a hint that these files are auto-generated.

This is a follow-up to [41271], which added the banner to minified CSS files.

Fixes #48424. See #30666.
Built from https://develop.svn.wordpress.org/trunk@46589


git-svn-id: http://core.svn.wordpress.org/trunk@46386 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-26 00:17:07 +00:00
Aaron Jorbin
0e21d32900 Build/Test: Bump devDependencies for WordPress 5.3
This upgrades a number of devDependencies.  Some of these include changes to how the tasks are configured.

Uglify: There are deprecated options from 2.x to 4.x, see: https://github.com/gruntjs/grunt-contrib-uglify#options

Autoprefixer: Browserslist now warns when passing in the browser list, so that is put into package.json

As with most changes to uglify, this changes every minified JS file.

Fixes #48203.



Built from https://develop.svn.wordpress.org/trunk@46408


git-svn-id: http://core.svn.wordpress.org/trunk@46206 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-05 19:49:10 +00:00
Andrea Fercia
4ead9880b0 Accessibility: Make the Tags meta box better support Input Method Editor (IME) converters.
Also, restores the keyboard interaction behavior prior to [41988] by requesting one single Enter key press to add a tag.

Props ryanshoover, miyauchi.
Fixes #45371.

Built from https://develop.svn.wordpress.org/trunk@45227


git-svn-id: http://core.svn.wordpress.org/trunk@45036 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-17 07:18:51 +00:00
desrosj
6fbf4ceaea REST API: Restore use of wp_ajax_ajax_tag_search() for tag search.
This solution does not work with custom taxonomies in the current state.

Reverts [42614,42619,42737].

Props danielbachhuber.
See #38922.
Built from https://develop.svn.wordpress.org/trunk@44537


git-svn-id: http://core.svn.wordpress.org/trunk@44368 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-10 02:37:51 +00:00
Adam Silverstein
86434ebca4 Taxonomy: Use REST API for ajax tag search.
Deprecate wp_ajax_ajax_tag_search and switch to using the REST API when searching tags in the tags meta box.

Props nacin, chriscct7, afercia, swissspidy, jnylen0, rmccue, ryelle.
Fixes #38922.


Built from https://develop.svn.wordpress.org/trunk@42614


git-svn-id: http://core.svn.wordpress.org/trunk@42443 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-01-30 00:17:31 +00:00
Andrea Fercia
35d8daf000 Quick/Bulk Edit: Fix the Tag suggestions position on the Bulk Edit textarea.
Always passes the complete `position` object to the jQuery autocomplete widget.
Also checks if an autocomplete instance already exists on the Bulk Edit textarea.

Props davidbenton.
Fixes #40242.

Built from https://develop.svn.wordpress.org/trunk@40357


git-svn-id: http://core.svn.wordpress.org/trunk@40264 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-03-31 16:35:45 +00:00
Andrea Fercia
5c555e5d10 Accessibility: Improve the Tags meta box accessibility.
- changes the "X" links in buttons, improves their color contrast ratio and focus style
- adds screen reader text "Remove item: + tagname"
- uses `wp.a11y.speak()` to give screen reader users feedback when adding/removing tags
- makes the `tagcloud-link` toggle a button, with an `aria-expanded` attribute to indicate the tag cloud collapsed/expanded state
- changes colors for the autocomplete highlighted option in order to have a better color contrast ratio
- reduces the font size for the autocomplete on Press This
- removes CSS related to the old `suggest.js` from Press This

Props joedolson, cgrymala, azaozz, afercia.
Fixes #27555.

Built from https://develop.svn.wordpress.org/trunk@38880


git-svn-id: http://core.svn.wordpress.org/trunk@38823 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-10-23 18:16:42 +00:00
Andrew Ozz
d91da52588 Accessible Tags autocomplete:
- Replace suggest.js with UI Autocomplete.
- Use the same settings like in the editor link toolbar.
- Abstract it and add in a new file, tags-suggest.js. Then make it a dependency for the Tags postbox(es) and Quick and Bulk Edit.
- Add `data-wp-taxonomy` on all input elements to improve handling in the UI for custom taxonomies.

Props afercia, azaozz.
See #33902.
Built from https://develop.svn.wordpress.org/trunk@38797


git-svn-id: http://core.svn.wordpress.org/trunk@38740 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-10-14 22:40:28 +00:00