March 8, 2016

Multisite Focused Changes in 4.5

Howdy! The 4.5 release cycle was relatively quiet for multisite, though we still managed to knock out a few good things. The following is a brief rundown of each, full details can be found in the full list of multisite focused changes for 4.5. 💫

Introduce WP_Site

The global $current_blog has always been used as a way to store the properties in a stdClass object of the current site during bootstrap. With the introduction of WP_Site, we add some definition and have a more proper object to pass around. Sweet.

Take a look at ms-settings.php if you are using a custom sunrise.php to populate the $current_blog global. We now create a WP_Site object from the existing $current_blog if it has been populated elsewhere. This is a backward compatible change, though should be tested wherever your code interacts with $current_blog, especially if anything has been done to extend its structure.

This last paragraph may sound familiar to you because I copied it from the notes on the work we did in the 4.4 release to add WP_Network as an object. In future releases, we’ll continue to build these out with query classes as well.

See #32450 for all the details.

New Actions and Filters

  • network_user_new_form fires at the end of the network’s Add New User form. #15389
  • network_site_new_form fires at the end of the network’s Add New Site form. #34739
  • network_allowed_themes and site_allowed_themes allow for more granular filtering of the themes allowed for a site. The legacy allowed_themes will continue to do its job. #28436
  • pre_network_site_pre_created_user fires right before a new user is created during the Add New Site process if one does not already exist. #33631

Other interesting things

  • Use a usermeta key rather than a site option keyed to the user ID when a user changes their email address and confirmation is needed. #23358
  • In subdomain installations, if a user attempted to login to a site they did not have access to on the network, they would be shown an access denied message with a list of authorized sites. This differed from the behavior in subdirectory installs, where the user would be redirected to either their profile page or the dashboard of their primary site. In 4.5, the subdomain behavior now matches the subdirectory behavior. #30598
  • The performance of wp_upload_dir() has been improved, specifically via persistent cache. This isn’t necessarily multisite related, though you should probably be familiar with the change. #34359
  • Show the home URL rather than siteurl in site-info.php and use the text “Site Address (URL)” for consistency with the similar site in single site. #35632
  • Provide an “Edit user” link after adding a new user to a site or network. #35705 😻

And that’s about it. There may still be some bug fixing in the next week or so, but only if you get out there and test trunk against your plugins, themes, and crazy configurations. Have at it!



Multisite Focused Changes in 4.5 by Jeremy Felt was originally posted at https://make.wordpress.org/core/2016/03/09/multisite-focused-changes-in-4-5/

Link modal (wpLink) changes in WordPress 4.5

There is a new and improved inline links dialog in the Visual Editor, see #33301. When the users type in the URL field, it uses jQuery UI Autocomplete to search for local posts and pages.

The old modal dialog (a.k.a. wpLink) is still used for “Advanced” link options. It was simplified, the infinite scrolling bottom part was removed. Now this dialog also uses UI Autocomplete on the URL field to search for posts and pages. That makes it consistent with the inline dialog and leaves more space for plugins that want to add additional settings in it.

If your plugin uses or extends wpLink, please test it now to confirm all is working properly.



Link modal (wpLink) changes in WordPress 4.5 by Andrew Ozz was originally posted at https://make.wordpress.org/core/2016/03/08/link-modal-wplink-changes-in-wordpress-4-5/

Enhanced Script Loader in WordPress 4.5

This post summarizes some of the changes to the script loader and script/style dependencies in WordPress 4.5.

Individual stylesheets instead of wp-admin.min.css

Ticket: #35229

Currently, WordPress generates and ships relatively large 235KB wp-admin.min.css and wp-admin-rtl.min.css files which are created from source files which we also ship.
With WordPress 4.5 we stop generating these files and instead rely upon load-styles.php to combine them. This removes the requirement from shipping for commits such as [35896] 510KB of CSS. Instead, we only have to ship the 4 dashboard.css files which are around 72KB.

For plugin authors nothing should change because the script loader takes care of the new dependency for the wp-admin handle. Also, wp-admin.* files are still generated for compatibility purposes, however, they only include the @import() lines.

Breaking Change: If your plugin or theme is still using the deprecated media functionality please note that in [36869] the style handle was changed from media to media-deprecated.

HTTP ETag header for load-scripts.php and load-styles.php

Ticket: #28722

Both loaders for script and style concatenation are now sending an ETag header which includes the value of $wp_version. This improves performance since browsers won’t re-download the scripts and styles when they send the HTTP_IF_NONE_MATCH header and there was no change in $wp_version. ⚡️

wp_add_inline_script()

Ticket: #14853

For quite some time wp_add_inline_style() has been available to add extra CSS styles to a registered stylesheet. Now there’s an equivalent function to do the same for inline JavaScript. wp_add_inline_script() can be used to add extra scripts either before or after a registered script using the optional third $position argument.

For example, the following code can be used to easily add Typekit’s JavaScript to your theme:

function mytheme_enqueue_typekit() {
   wp_enqueue_script( 'mytheme-typekit', 'https://use.typekit.net/<typekit-id>.js', array(), '1.0' );
   wp_add_inline_script( 'mytheme-typekit', 'try{Typekit.load({ async: true });}catch(e){}' );
}
add_action( 'wp_enqueue_scripts', 'mytheme_enqueue_typekit' );

Which results in:

<script type='text/javascript' src='https://use.typekit.net/<typekit-id>.js?ver=1.0'></script>
<script type='text/javascript'>
try{Typekit.load({ async: true });}catch(e){}
</script>

Scripts/Styles with “alias” handles

Ticket: #35643, #25247, #35229

Alias handles are handles without a $src parameter. Those can be used to group dependencies, like core is doing for jQuery[36550] changes how those handles are loaded, more specifically, they are no longer skipped early in WP_Dependencies.

Now, inline styles and scripts attached to alias handles will do something important — get printed out. This change was required by the switch to an alias handle for wp-admin to provide backwards compatibility for plugins which are adding inline styles to the wp-admin handle.

Support for scripts with dependencies in different groups

Ticket: #35873, #35873

Scripts can be registered in two groups: head or footer. Previously, dependencies of registered scripts were moved to the header, even when the script that depends on them is loaded in the footer. This was fixed in [36871]. The changeset includes some expressive tests to demonstrate how complex dependencies, like “grandchild” dependencies, can be enqueued.

Last, but not least, WP_Dependencies, WP_Styles, and WP_Scripts are now fully documented. 📘

Thanks to @abiralneupane, @atimmer, @dd32, @gitlost, @ocean90, @sebastian.pisula, @sergej.mueller, @stephenharris, and @swissspidy for their contributions!



Enhanced Script Loader in WordPress 4.5 by Dominik Schilling (ocean90) was originally posted at https://make.wordpress.org/core/2016/03/08/enhanced-script-loader-in-wordpress-4-5/

March 7, 2016

Changes to the Term Edit Page in WordPress 4.5

Up until recently, the term list table and the term edit form in the admin shared the same page: wp-admin/edit-tags.php. This is inconsistent compared to how the post list table and the editor are split up between wp-admin/edit.php and wp-admin/post.php.

As was reported in #34988, this inconsistency led to some problems when screen options belonging to the list table were shown on the term edit page. This was changed in [36308] by introducing wp-admin/term.php 💪🏽.

What this means for developers

First of all, you’ll notice that the links to edit a single term now look like example.com/wp-admin/term.php?tag_ID=123. (previously: example.com/wp-admin/edit-tags.php?action=edit&taxonomy=post_tag&tag_ID=127). That’s not a big deal actually, but it leads to some changes under the hood:

If you’re specifically targeting the term edit form in your plugin, $pagenow changes from edit-tags.php to term.php. The screen base (returned by get_current_screen()) changes from edit-tags to term as well. That’s it 🙂

What to look for

If you want to specifically enqueue scripts and styles on the term edit page, you should hook to load-term.php instead of load-edit-tags.php. That way you won’t unnecessarily load assets on the wrong screen.

Besides that, everything stays the same 😇. If you do however find any quirks related to this change, do not hesitate to leave a comment on this post or the relevant ticket: #34988



Changes to the Term Edit Page in WordPress 4.5 by Pascal Birchler was originally posted at https://make.wordpress.org/core/2016/03/07/changes-to-the-term-edit-page-in-wordpress-4-5/

Video: How to Make a Wedding Site in WordPress



WPBeginner - WordPress Tutorials originally appeared at http://www.youtube.com/watch?v=rqekQfU2RNs

March 6, 2016

Reactions

What are Reactions?

If you’ve used Slack or Thefacebook recently, you’ll have noticed a new way of interacting and providing feedback – emoji reactions. It works much the same way as a Like button, but provides a wider range of reactions, so readers can give more nuanced feedback, without needing to go to the effort of leaving a comment. This also allows for readers to provide the same level of interaction in situations where a “Like” is an inappropriate message to send, as Eric Meyer describes in his post about Inadvertent Algorithmic Cruelty.

What does it do?

The reactions plugin currently has the following features:

  • Allows for reactions to posts
  • REST API endpoints for storing and retrieving reactions
  • An exceedingly ugly emoji selector

What is still being worked on?

Pretty much everything!

In its current state, the plugin is mostly a proof of concept, in need of significant work improving edge cases, design and User Experience.

Your first step is to install the plugin, as well as the WP-API plugin (the WP-API plugin is currently a requirement to avoid code duplication, that will likely be re-evaluated based on when each plugin might be merged into Core).

Please report any issues on the Github repository, or drop in the #feature-reactions channel in Slack to ask questions or give feedback. It’s also where we have our weekly chats, on Wednesday 23:00 UTC. Thank you!



Reactions by Gary Pendergast was originally posted at https://make.wordpress.org/core/2016/03/07/reactions/

March 4, 2016

Release Process Checklists

The release process is complex and beyond one person. Releasing is an intricate dance that we haven’t been sufficiently capturing. Knowledge siloed in heads needs to be committed to public, institutional memory. The upcoming 4.5 release is an opportunity to capture every step of the dance so that we can iterate process, automate away lingering drudgery, and improve our cognitive net for the stressful task of releasing to 25%. I like using checklists in this cognitive net. They relieve anxiety, make process transparent, and help teams flow during stress. We already have a couple release checklists. We can build on those while adopting a little checklist culture in a manner empathetic to developers and flow. Pitch:

Checklist cool tricks

Checklists…

  • distribute power.
  • push power of decision making to the periphery.
  • provide a cognitive net.
  • make the minimum necessary steps explicit.
  • make sure simple steps are not missed.
  • make sure people talk.
  • capture and shape real flow.
  • inspire flow in emergencies and sustain it through the quotidian.
  • capture flow between teams.
  • encourage a shared culture around flow.
  • accessibly capture institutional memory in the context of flow.

Attributes of a good checklist

What makes a good checklist? Checklist shouldn’t be about just checking boxes. Instead of being a chore and an admonishing finger, checklists should fit and assist real flow. The Checklist Manifesto offers these suggestions. Ideally, checklists…

  • are not lengthy.
  • have clear, concise objectives.
  • define a clear pause point at which the checklist is supposed to be used.
  • have fewer than ten items per pause point.
  • fit the flow of the work.
  • continually update as living documents.

See this checklist for checklists and this example checklist for more.

Stuff to checklist

The major release checklist attempts to use pause points and follow the suggestions above. The major and minor release checklists are pretty rough and incomplete and overlap with each other. These and the things to keep in mind list need love and unification with help from developers who are in the release flow and handling controls on the release train.

about.php is…quite the process. It needs the oxygenating powers of a checklist.

Checklist Feature plugin merges.

Checklist bundled theme releases so stuff like this makes it into institutional memory.

Beta and RC releases.

Plenty of other stuff. 🙂

Start by capturing. As we walk 4.5 release flows, capture.

Selected quotes from The Checklist Manifesto

Checklists supply a set of checks to ensure the stupid but critical stuff is not overlooked, and they supply another set of checks to ensure people talk and coordinate and accept responsibility while nonetheless being left the power to manage the nuances and unpredictabilities the best they know how.

In a complex environment, experts are up against two main difficulties. The first is the fallibility of human memory and attention, especially when it comes to mundane, routine matters that are easily overlooked under the strain of more pressing events.

Faulty memory and distraction are a particular danger in what engineers call all-or-none processes: whether running to the store to buy ingredients for a cake, preparing an airplane for takeoff, or evaluating a sick person in the hospital, if you miss just one key thing, you might as well not have made the effort at all.

Checklists seem to provide protection against such failures. They remind us of the minimum necessary steps and make them explicit. They not only offer the possibility of verification but also instill a kind of discipline of higher performance.

Checklists, he found, established a higher standard of baseline performance.

Four generations after the first aviation checklists went into use, a lesson is emerging: checklists seem able to defend anyone, even the experienced, against failure in many more tasks than we realized. They provide a kind of cognitive net. They catch mental flaws inherent in all of us—flaws of memory and attention and thoroughness. And because they do, they raise wide, unexpected possibilities.

All were amenable, as a result, to what engineers call “forcing functions”: relatively straightforward solutions that force the necessary behavior—solutions like checklists.

We are besieged by simple problems.

And the question of when to follow one’s judgment and when to follow protocol is central to doing the job well—or to doing anything else that is hard.

Pinned to the left-hand wall opposite the construction schedule was another butcher-block-size sheet almost identical in form, except this one, O’Sullivan said, was called a “submittal schedule.” It was also a checklist, but it didn’t specify construction tasks; it specified communication tasks. For the way the project managers dealt with the unexpected and the uncertain was by making sure the experts spoke to one another—on X date regarding Y process. The experts could make their individual judgments, but they had to do so as part of a team that took one another’s concerns into account, discussed unplanned developments, and agreed on the way forward. While no one could anticipate all the problems, they could foresee where and when they might occur. The checklist therefore detailed who had to talk to whom, by which date, and about what aspect of construction—who had to share (or “submit”) particular kinds of information before the next steps could proceed.

The assumption was that anything could go wrong, anything could get missed. What? Who knows? That’s the nature of complexity. But it was also assumed that, if you got the right people together and had them take a moment to talk things over as a team rather than as individuals, serious problems could be identified and averted. So the submittal schedule made them talk.

the major advance in the science of construction over the last few decades has been the perfection of tracking and communication.

They trust instead in one set of checklists to make sure that simple steps are not missed or skipped and in another set to make sure that everyone talks through and resolves all the hard and unexpected problems.

There is a particularly tantalizing aspect to the building industry’s strategy for getting things right in complex situations: it’s that it gives people power. In response to risk, most authorities tend to centralize power and decision making.

The philosophy is that you push the power of decision making out to the periphery and away from the center. You give people the room to adapt, based on their experience and expertise. All you ask is that they talk to one another and take responsibility. That is what works.

In other words, to handle this complex situation, they did not issue instructions. Conditions were too unpredictable and constantly changing. They worked on making sure people talked.

No, the real lesson is that under conditions of true complexity—where the knowledge required exceeds that of any individual and unpredictability reigns—efforts to dictate every step from the center will fail. People need room to act and adapt. Yet they cannot succeed as isolated individuals, either—that is anarchy. Instead, they require a seemingly contradictory mix of freedom and expectation—expectation to coordinate, for example, and also to measure progress toward common goals.

More remarkably, they had learned to codify that understanding into simple checklists. They had made the reliable management of complexity a routine. That routine requires balancing a number of virtues: freedom and discipline, craft and protocol, specialized ability and group collaboration. And for checklists to help achieve that balance, they have to take two almost opposing forms. They supply a set of checks to ensure the stupid but critical stuff is not overlooked, and they supply another set of checks to ensure people talk and coordinate and accept responsibility while nonetheless being left the power to manage the nuances and unpredictabilities the best they know how.

“David Lee Roth had a checklist!” I yelled at the radio.

“following the recipe is essential to making food of consistent quality over time.”

All the examples, I noticed, had a few attributes in common: They involved simple interventions—a vaccine, the removal of a pump handle. The effects were carefully measured. And the interventions proved to have widely transmissible benefits—what business types would term a large ROI (return on investment) or what Archimedes would have called, merely, leverage.

Plain soap was leverage.

The secret, he pointed out to me, was that the soap was more than soap. It was a behavior-change delivery vehicle.

“Global multinational corporations are really focused on having a good consumer experience, which sometimes public health people are not.”

bringing them a gift rather than wagging a finger.

Could a checklist be our soap for surgical care—simple, cheap, effective, and transmissible?

He also did something curious: he designed a little metal tent stenciled with the phrase Cleared for Takeoff and arranged for it to be placed in the surgical instrument kits. The metal tent was six inches long, just long enough to cover a scalpel, and the nurses were asked to set it over the scalpel when laying out the instruments before a case. This served as a reminder to run the checklist before making the incision. Just as important, it also made clear that the surgeon could not start the operation until the nurse gave the okay and removed the tent, a subtle cultural shift. Even a modest checklist had the effect of distributing power.

He explained that his hospital had completed a feasibility trial using a much broader, twenty-one-item surgical checklist. They had tried to design it, he said, to catch a whole span of potential errors in surgical care. Their checklist had staff verbally confirm with one another that antibiotics had been given, that blood was available if required, that critical scans and test results needed for the operation were on hand, that any special instruments required were ready, and so on.

The checklist also included what they called a “team briefing.” The team members were supposed to stop and take a moment simply to talk with one another before proceeding—about how long the surgeon expected the operation to take, how much blood loss everyone should be prepared for, whether the patient had any risks or concerns the team should know about.

But however embarrassing it may be for us to admit, researchers have observed that team members are commonly not all aware of a given patient’s risks, or the problems they need to be ready for, or why the surgeon is doing the operation. In one survey of three hundred staff members as they exited the operating room following a case, one out of eight reported that they were not even sure about where the incision would be until the operation started.

“That’s not my problem” is possibly the worst thing people can think, whether they are starting an operation, taxiing an airplane full of passengers down a runway, or building a thousand-foot-tall skyscraper. But in medicine, we see it all the time. I’ve seen it in my own operating room.

They can each be technical masters at what they do. That’s what we train them to be, and that alone can take years. But the evidence suggests we need them to see their job not just as performing their isolated set of tasks well but also as helping the group get the best possible results. This requires finding a way to ensure that the group lets nothing fall between the cracks and also adapts as a team to whatever problems might arise.

Their insistence that people talk to one another about each case, at least just for a minute before starting, was basically a strategy to foster teamwork—a kind of team huddle, as it were. So was another step that these checklists employed, one that was quite unusual in my experience: surgical staff members were expected to stop and make sure that everyone knew one another’s names.

The investigators at Johns Hopkins and elsewhere had also observed that when nurses were given a chance to say their names and mention concerns at the beginning of a case, they were more likely to note problems and offer solutions. The researchers called it an “activation phenomenon.” Giving people a chance to say something at the start seemed to activate their sense of participation and responsibility and their willingness to speak up.

You must define a clear pause point at which the checklist is supposed to be used (unless the moment is obvious, like when a warning light goes on or an engine fails). You must decide whether you want a DO-CONFIRM checklist or a READ-DO checklist. With a DO-CONFIRM checklist, he said, team members perform their jobs from memory and experience, often separately. But then they stop. They pause to run the checklist and confirm that everything that was supposed to be done was done. With a READ-DO checklist, on the other hand, people carry out the tasks as they check them off—it’s more like a recipe. So for any new checklist created from scratch, you have to pick the type that makes the most sense for the situation.

The checklist cannot be lengthy. A rule of thumb some use is to keep it to between five and nine items, which is the limit of working memory. Boorman didn’t think one had to be religious on this point.

However much thought we might put in, a checklist has to be tested in the real world, which is inevitably more complicated than expected. First drafts always fall apart, he said, and one needs to study how, make changes, and keep testing until the checklist works consistently.

It is common to misconceive how checklists function in complex lines of work. They are not comprehensive how-to guides, whether for building a skyscraper or getting a plane out of trouble. They are quick and simple tools aimed to buttress the skills of expert professionals.

In aviation, there is a reason the “pilot not flying” starts the checklist, someone pointed out. The “pilot flying” can be distracted by flight tasks and liable to skip a checklist. Moreover, dispersing the responsibility sends the message that everyone—not just the captain—is responsible for the overall well-being of the flight and should have the power to question the process.

An inherent tension exists between brevity and effectiveness.

We surmised that improved communication was the key. Spot surveys of random staff members coming out of surgery after the checklist was in effect did indeed report a significant increase in the level of communication. There was also a notable correlation between teamwork scores and results for patients—the greater the improvement in teamwork, the greater the drop in complications.

Even the most expert among us can gain from searching out the patterns of mistakes and failures and putting a few checks in place. But will we do it?

Just ticking boxes is not the ultimate goal here. Embracing a culture of teamwork and discipline is.

Yet we should also be ready to accept the virtues of regimentation.

“When surgeons make sure to wash their hands or to talk to everyone on the team”—he’d seen the surgery checklist—“they improve their outcomes with no increase in skill. That’s what we are doing when we use the checklist.”

The fear people have about the idea of adherence to protocol is rigidity. They imagine mindless automatons, heads down in a checklist, incapable of looking out their windshield and coping with the real world in front of them. But what you find, when a checklist is well made, is exactly the opposite. The checklist gets the dumb stuff out of the way, the routines your brain shouldn’t have to occupy itself with (Are the elevator controls set? Did the patient get her antibiotics on time? Did the managers sell all their shares? Is everyone on the same page here?), and lets it rise above to focus on the hard stuff (Where should we land?).

But step one on the list is the most fascinating. It is simply: FLY THE AIRPLANE. Because pilots sometimes become so desperate trying to restart their engine, so crushed by the cognitive overload of thinking through what could have gone wrong, they forget this most basic task. FLY THE AIRPLANE. This isn’t rigidity. This is making sure everyone has their best shot at survival.

All learned occupations have a definition of professionalism, a code of conduct. It is where they spell out their ideals and duties. The codes are sometimes stated, sometimes just understood. But they all have at least three common elements. First is an expectation of selflessness: that we who accept responsibility for others—whether we are doctors, lawyers, teachers, public authorities, soldiers, or pilots—will place the needs and concerns of those who depend on us above our own. Second is an expectation of skill: that we will aim for excellence in our knowledge and expertise. Third is an expectation of trustworthiness: that we will be responsible in our personal behavior toward our charges. Aviators, however, add a fourth expectation, discipline: discipline in following prudent procedure and in functioning with others. This is a concept almost entirely outside the lexicon of most professions, including my own. In medicine, we hold up “autonomy” as a professional lodestar, a principle that stands in direct opposition to discipline. But in a world in which success now requires large enterprises, teams of clinicians, high-risk technologies, and knowledge that outstrips any one person’s abilities, individual autonomy hardly seems the ideal we should aim for. It has the ring more of protectionism than of excellence. The closest our professional codes come to articulating the goal is an occasional plea for “collegiality.” What is needed, however, isn’t just that people working together be nice to each other. It is discipline.

Airline manufacturers put a publication date on all their checklists, and there is a reason why—they are expected to change with time.

One essential characteristic of modern life is that we all depend on systems—on assemblages of people or technologies or both—and among our most profound difficulties is making them work.

“Anyone who understands systems will know immediately that optimizing parts is not a good route to system excellence,”

When we look closely, we recognize the same balls being dropped over and over, even by those of great ability and determination. We know the patterns. We see the costs. It’s time to try something else. Try a checklist.

In the spring of 2007, as soon as our surgery checklist began taking form, I began using it in my own operations. I did so not because I thought it was needed but because I wanted to make sure it was really usable. Also, I did not want to be a hypocrite.

Just as powerful, though, was the effect that the routine of the checklist—the discipline—had on us. Of all the people in the room as we started that operation—the anesthesiologist, the nurse anesthetist, the surgery resident, the scrub nurse, the circulating nurse, the medical student—I had worked with only two before, and I knew only the resident well. But as we went around the room introducing ourselves—“Atul Gawande, surgeon.” “Rich Bafford, surgery resident.” “Sue Marchand, nurse”—you could feel the room snapping to attention.

WordPress Checklists

Checklist Resources



Release Process Checklists by Ryan Boren was originally posted at https://make.wordpress.org/core/2016/03/04/release-process-checklists/

March 3, 2016

Core Dev chat notes for March 2

Agenda

Schedule, Updates.

Schedule

Reminder of the 4.5 release schedule:

  • Beta 2 March 2nd.
  • Beta 3 March 9th.
  • RC1 on March 23rd.
  • 4.5 release on April 12th.

At the time of this posting, there are 104 active tickets slated for the 4.5 release. Now is a great time to get involved by testing the beta and assisting with the remaining tickets.

Updates

  • @karmatosed wanted to bring up a couple of things re: core themes
    • Site logos… we need to decide when to get the current version into the .org repository.
    • @iamtakashi has a patch to add site logo support to Twenty Fifteen and doesn’t believe it belongs in Twenty Fourteen  (#35969, #35944).
    • @davidakennedy We will time the updating of core themes with the release.
  • @azaozz or @iseulde updated on the editor work:
    • New features need testing.
    • Going to push fix for Paste as Text Modal Should be Dismiss-able (#28612), fix just became doable with change in TinyMCE.
    • Deciding no paste shortcuts @iseulde pointed out the problem is you would not be able to undo them like the other shortcuts.
  • @jorbin posted about field guide posts for the release  in the slack channel. @obenland pointed out we also need a field guide post about custom/site logos.
  • @obenland brought up some tickets about the site logo feature:
    • Should site logo should be called `logo` or `site-logo`: decided on `custom-logo` to match other core naming. (#35945).
    • Requesting UX feedback on Reconsider site logo control placement in customizer (#35942) and Site Icon: refine the new UI introduced in 4.5 (#35943).

Read the full meeting logs on Slack.



Core Dev chat notes for March 2 by Adam Silverstein was originally posted at https://make.wordpress.org/core/2016/03/03/core-dev-chat-notes-for-march-2/

March 2, 2016

Week in Core, Feb. 23-Mar 1 2016

Welcome back the latest issue of Week in Core, covering changes [36672-36800]. Here are the highlights:

  • 128 commits
  • 52 contributors
  • 115 tickets created
  • 19 tickets reopened
  • 135 tickets closed

Ticket numbers based on trac timeline for the period above.

Note: If you want to help write the next WordPress Core Weekly summary, check out the schedule over at make/docs and get in touch in the #core-weekly-update Slack channel.

Code Changes

Accessibility

  • improve accessibility of the Dashboard “Recent Comments” widget. [36683] #35392

Comments

Customize

  • Use selective refresh to preview changes to site title and tagline in core themes. Fixes #33738. [36797] #27355, #33738
  • Fix PHP notice when calling WP_Customize_Control::json() inside content_template() method. See #29572. [36776] #35926, #29572
  • Allow button_labels to be overridden in $args passed to WP_Customize_Media_Control and WP_Customize_Image_Control. [36769] #33755, #35542
  • Introduce Logo support for themes. See #33755. [36698] #33755
  • Allow controls to be registered without any associated settings. Fixes #35926. [36689] #27355, #35926
  • Introduce customize_nav_menu_searched_items filter for modifying results of nav menu item searches. [36676] #34947
  • Fix nav menu item search after Backbone update. [36675] #34350

Docs

  • Correct filter reference in pre_get_avatar filter description. [36800] #36031
  • Correct _n_noop() and _nx_noop() descriptions to use third-person singular verbs. [36765] #35961
  • Improve a variety of DocBlocks in wp-includes/deprecated.php. [36763] #32246
  • Add missing parameter and return descriptions to the DocBlock for the deprecated default_topic_count_text(). [36760] #32246
  • Add missing parameter and return documentation to the DocBlock for the deprecated _search_terms_tidy(). [36759] #32246
  • Add missing documentation for the &$post parameter in the DocBlock for the deprecated _get_post_ancestors(). [36758] #32246
  • Add missing documentation for the $fp parameter to the DocBlock for the deprecated debug_fclose(). [36757] #32246
  • Add missing parameter documentation to the DocBlock for the deprecated debug_fwrite(). [36756] #32246
  • Add missing parameter and return documentation to the DocBlock for the deprecated debug_fopen(). [36755] #32246
  • Add missing documentation for the $wp_admin_bar parameter in the DocBlock for the deprecated wp_admin_bar_dashboard_view_site_menu(). [36754] #32246
  • Add missing documentation for the $title parameter in the DocBlock for the deprecated parent_post_rel_link(). [36753] #32246
  • Remove a duplicate parameter notation in the DocBlock for the deprecated the_editor() function. [36748] #32246
  • Update the @deprecated tag comment for wp-includes/embed-template.php to reference the correct file path following [36693]. [36746] #34561
  • Add a missing summary, @access tag, and parameter documentation to the DocBlock for WP_Customize_Filter_Setting::update(). [36745] #32246
  • Improve inline docs for WP_Dependencies, WP_Styles, and WP_Scripts. [36744] #35964
  • Fix two typos in return descriptions for WP_Theme private usort() methods. [36739] #32246
  • Add missing parameter and return notations in the DocBlock for WP_Theme::_name_sort_i18n(). [36738] #32246
  • Add missing parameter and return notations in the DocBlock for WP_Theme::_name_sort(). [36737] #32246
  • Add a missing description for the &$themes parameter in the DocBlock for WP_Theme::sort_by_name(). [36736] #32246
  • Correctly document parameters in the hook doc for the get_meta_sql filter as individual parameters rather than an array. [36735] #35962
  • Add missing parameter and return descriptions to the DocBlock for WP_Theme::__isset(). [36734] #32246
  • Add missing @since tags to WP_Styles properties/methods. [36733] #35964
  • In WP_Dependencies add a changelog entry for the $group parameter. [36732] #35964
  • In WP_Dependencies add a changelog entry to methods which were moved from WP_Scripts to WP_Dependencies. [36731] #35964
  • Document properties of WP_Scripts and add missing @since tags. [36730] #35964
  • Use correct @since tags for script enqueue functions. See #35964. [36729] #35964
  • Add missing @param and @return notations to the DocBlock for WP_Feed_Cache_Transient::save(). [36728] #32246
  • Use the correct variable name for the $post_ID parameter in the DocBlock for wp_add_trashed_suffix_to_post_name_for_trashed_posts(). [36727] #11863, #32246
  • Standardize summaries for two new internal functions used to handle suffixing trashed posts […] and a notation of private access to each. [36726] #11863, #32246
  • Add some missing @param notations to various DocBlocks in wp-includes/ms-deprecated.php. [36725] #32246
  • Add a missing @param entry for the $user_login parameter in the DocBlock for the deprecated is_site_admin() function. [36724] #32246
  • Add a missing @param entry for the $len parameter in the DocBlock for the deprecated generate_random_password() function. [36723] #32246
  • Correct the possible return types for WP_Dependencies::query(). [36713] #32246
  • Improve the description of the get_object_taxonomies() function. Uncertainty has no place in documentation. [36712] #32246
  • Use a third-person singular verb in the DocBlock summary for wp_add_inline_script(), introduced in [36633]. [36707] #14853, #32246
  • Standardize DocBlocks for two new WP_Scripts methods, add_inline_script() and print_inline_script(), introduced in [36633]. [36706] #14853, #32246
  • Make a few syntactical improvements to the DocBlock for _wp_get_current_user(), introduced in [36651]. [36705] #19615, #32246
  • Add an inline @see tag to link up the plugins_loaded hook in the description for the customize_loaded_components filter. [36687] #32246

Editor

  • Remove an unused JavaScript variable so the JS lint tests pass. [36751] #33301

Embeds

  • Use a more accessible way to initially hide the iframe. This [36708] #35894
  • Update embed template paths and messages in tests, missed in [36693]. [36694] #34561
  • Introduce embed templates into the template hierarchy via theme-compat. [36693] #34561

External Libraries

Formatting

  • In sanitize_title_with_dashes(), convert `,&ndash, and&mdash` HTML entities to hyphens on save. [36775] #31790

Forms

  • Swap “Submit” button label for “Enter” on password-protected pages. [36685] #35042

HTTP API

  • Add the missing 1xx HTTP response codes as constants of the WP_Http class, and add tests to ensure all available response codes are covered. [36749] #36294

I18N

  • Move the aria-label text in comment_form() to a separate string for easier translation. Add translator comments. [36794] #36014
  • Remove HTML tags from translatable string in wp-admin/includes/dashboard.php. [36793] #36013
  • Remove ` tags from translatable string in wp-admin/network/site-new.php`. [36773] #35994
  • Remove ` tag from translatable string in wp-includes/class-wp-customize-manager.php`. [36772] #35992
  • Remove ` tag from translatable string in wp-admin/network/site-new.php`. [36771] #35989
  • Remove HTML tags from translatable strings in wp-admin/network/themes.php. [36770] #35988
  • Fix placeholders and add translator comments after [36695]. [36697] #35705
  • Move the “Caution:” prefix to a separate string in wp-admin/includes/network.php. [36690] #35674

I18N Tools

L10n

Link Manager

  • Fix usage of translation functions after [35998].

Mail

Media

  • JSHint for wp-playlist.js. File was added to the watchlist in [36780]. [36783] #35984
  • Add support for minified versions of wp-playlist.js, wp-mediaelement.js and wp-mediaelement.css. [36780] #35984
  • Correct “Exception” typo in WP_Image_Editor_Imagick::strip_meta(). Exceptions are caught better if they’re not excpeted. [36742] #33642
  • Optimize Imagick settings for quality and filesize. [36700] #33642, #30402, #28634
  • Fix broken delete/trash functionality in the library after [36546]. [36681] #34350

Multisite

  • Provide an “Edit user” link after adding a new user [36695] #35705
  • Use “Site Address (URL)” in site-new.php. [36684] #35934
  • Show the main site’s domain and path in site-info.php [36682] #35632
  • Switch to a usermeta key for email confirmation. [36679] #23358

Posts

  • Add tests for the cascading fallback behavior of several ‘public’-related arguments in register_post_type(). [36768] #35985
  • Rename the $args parameter in get_post_types_by_support() to $feature for better self-documentation. [36704] #34010, #32246

REST API

Rewrite Rules

  • Ensure url_to_postid() operates as expected when it’s used in the context of another site within a Multisite network that uses mixed URL schemes. [36750] #35531

Spelling

  • Standardize on “front end”/”back end” (noun) and “front-end”/”back-end” (adjective). [36709] #34887

Taxonomy

  • Improve ‘offset’ calculation when querying for hierarchical terms. [36691] #8832, #35935

Tests

  • Add unit tests for number_format_i18n(). [36795] #36029
  • Use markTestSkipped() to skip a multisite-only test. [36791] #36016
  • Ensure that user __unset() tests make assertions. [36790] #36016
  • Remove erroneous return in date_query test. Introduced in [34989]. [36789] #36016
  • mbstring.func_overload test should be skipped properly. This avoids PHPUnit notices related to “risky” tests. [36788] #36016
  • Remove tests related to wp_*_post_meta() functions. [36787] #21767, #36016
  • Make sure that test_wp_mail_break_it() makes an assertion. Let’s make what is possibly the oddest test in WordPress even a bit odder. See #36016. [36786] #36016
  • setExpectedDeprecated and setExpectedIncorrectUsage tests should make assertions. Introduced in [31306]. [36785] #36016
  • More specific test for a bad callback in WP_Customize_Partial test. [36784] #27355, #36016
  • Remove test related to deprecated Customizer export_preview_data() method. The method was gutted and deprecated in [36586], so there’s no reason to keep the test. [36782] #36016
  • Put an assertion in test_nonexistent_array() test. [36779] #36016
  • Make sure an assertion takes place in ‘visited’ test for get_category_parents(). [36778] #36016
  • Ad a unit test for bool_from_yn(). [36764] #35972
  • Don’t modify global state before checking whether to skip get_locale() tests. Introduced in [36740]. [36741] #35965
  • Add tests for get_locale(). [36740] #35965
  • Remove (or at least reduce) the need to reset common $_SERVER variables before assertions or between tests, by introducing a method which automatically resets them during test setup. [36721] #35954
  • Correct some more tests which were using example.org instead of WP_TESTS_DOMAIN. [36717] #34000
  • Move some assertions in HTTPS related tests, so failures that occur before the environment reset don’t result in a contaminated test environment. [36711] #35954
  • Unify the initialisation of $_SERVER variables during test bootstrap. This abstracts the (re-)initialisation into a function that can be used inside of tests too, before assertions are performed. [36715] #35954

TinyMCE

TinyMCE inline link dialog

  • Fix running wpLink without tinymce.js and the TinyMCE plugin without wplink.js. Do not show the Advanced button in the inline link dialog when wpLink is not loaded. [36777] #33301
  • Fix in IE (again). Remove setting/getting placeholders, pass the link node instead. In the inline dialog: when the selected text looks like URL or email, pre-fill the URL field with it (same as in the modal). Fix setting the name of the main button in the modal: Add Link or Update. In the modal when clicking Update remove the link if the URL field is empty. That matches the inline dialog behaviour. Otherwise the modal remains open, nothing happens when clicking the Update button there. [36747] #33301
  • Fix applying the changes when pressing the Enter key in Firefox. [36743] #33301
  • Make sure the inline dialog is not showing under the advanced modal. Fix checking if the link node contains text. Fix undo levels so all actions can be undone and redone. [36716] #33301
  • Reset the inline dialog when canceling the advanced modal. If there is a link it should be on the first stage: follow/preview link. Fix tabbing in the inline edit dialog. [36703] #33301
  • Remove the bottom half of the (old) modal and add autocomplete on the URL field. Disable the inline edit dialog in old IE (7, 8 and 9). Use only the modal there. Fix in IE10 and 11. Fix (most?) remaining edge cases. Fix focusing the inline dialog, the modal and the editor. [36677] #33301

TinyMCE textpattern

  • Horizontal line is translated, Horizontal rule is not. [36762] #33300
  • Add description of the new patterns to the Shortcuts help modal. Fix the layout a bit and make the patterns in two columns. Disable the textpatterns plugin in IE < 9. [36761] #33300
  • fix error when inserting “ if the new paragraph is not direct child of the body. [36720] #33300
  • Use editor.once instead of storing into variables. Add pattern for hr. [36719] #33300

Upgrade

  • Bump db version for upgrade_450() in upgrade_all(). [36686] #23358

Props

Thanks to @adamsilverstein, @afercia, @Ankit, @azaozz, @bhubbard, @boonebgorges, @borgesbruno, @celloexpressions, @chetanchauhan, @codex-m, @danielbachhuber, @dnewton, @DrewAPicture, @eliorivero, @enejb, @flixos90, @Gupta, @henrywright, @imath, @iseulde, @jeherve, @jeremyfelt, @joemcgill, @johnbillion, @jorbin, @K, @karmatosed, @kovshenin, @kwight, @maweder, @melchoyce, @MikeHansenMe, @mikeschroder, @obenland, @obrienlabs, @ocean90, @pbearne, @pento, @polevaultweb, @rachelbaker, @ramiy, @realloc, @rmccue, @ryan, @samhotchkiss, @SergeyBiryukov, @sudar, @swissspidy, @thewanderingbrit, @TimothyBlynJacobs, @westonruter, and @zinigor for their contributions!



Week in Core, Feb. 23-Mar 1 2016 by Grant Palin was originally posted at https://make.wordpress.org/core/2016/03/02/week-in-core-feb-23-mar-1-2016/

March 1, 2016

Dev Meeting and 4.5 Beta 2

A couple quick notes on Wednesday’s dev meeting (March 2, 2016 at 2100 UTC).

Meeting

I’ll be en-route during part of the meeting, so @adamsilverstein will be heading things up for tomorrow’s chat. If you have anything you’d like added to the agenda (I’ve passed on notes for those who have contacted me already), feel free to leave a comment on this post.

Beta 2

Committers and focus leads, please commit what you’d like to land in Beta 2, and prepare any tickets you’d like feedback on for the chat. The plan is to release the beta a couple hours after dev chat, when I’m back on the ground, evening PST. Leave a comment here or message me directly if there are any particular changes you’d like highlighted in the beta post.



Dev Meeting and 4.5 Beta 2 by Mike Schroder was originally posted at https://make.wordpress.org/core/2016/03/02/dev-meeting-and-45-beta-2/