Compare commits
89 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dde4da7b79 | ||
|
|
0d6d8d811d | ||
|
|
65e9d7950e | ||
|
|
8564a4a082 | ||
|
|
affa0e3fe7 | ||
|
|
b1801b170f | ||
|
|
e79a7394a5 | ||
|
|
69586ea627 | ||
|
|
4d267bf158 | ||
|
|
b9b627e24f | ||
|
|
66eb5e3992 | ||
|
|
cdb1418a32 | ||
|
|
6de8b73ae1 | ||
|
|
7f47548f35 | ||
|
|
88cb968e00 | ||
|
|
ac28cd61cf | ||
|
|
124bbbc653 | ||
|
|
5892579440 | ||
|
|
04602bccd8 | ||
|
|
01a575e1b0 | ||
|
|
ba7ae64a3c | ||
|
|
916a395691 | ||
|
|
b1cb849975 | ||
|
|
9371029a12 | ||
|
|
d6e61b10b5 | ||
|
|
0aef0d4b97 | ||
|
|
315b0d8efe | ||
|
|
f524de858c | ||
|
|
9c716931a3 | ||
|
|
ca7629305c | ||
|
|
0df80b099e | ||
|
|
bef4964cc3 | ||
|
|
061b316605 | ||
|
|
ee57ce6745 | ||
|
|
0b53ca170a | ||
|
|
f4bc98cc1d | ||
|
|
94aa7baeb2 | ||
|
|
0e494b043d | ||
|
|
176bfb2694 | ||
|
|
9940eb5493 | ||
|
|
f105803f14 | ||
|
|
21095bb883 | ||
|
|
ed38a616b1 | ||
|
|
298af5bcf2 | ||
|
|
6559bdf187 | ||
|
|
39710dcb5a | ||
|
|
070403f1c7 | ||
|
|
498a6acb14 | ||
|
|
59a3c2199c | ||
|
|
fe76b0206d | ||
|
|
b5b4d771ae | ||
|
|
6863424407 | ||
|
|
3769f76ca6 | ||
|
|
f6edca7a9e | ||
|
|
b1f105e400 | ||
|
|
639b5f6ed8 | ||
|
|
6c98f19ad2 | ||
|
|
319971e3ed | ||
|
|
7bb7707e9d | ||
|
|
081d0ebbc8 | ||
|
|
b250096446 | ||
|
|
1963afa5ff | ||
|
|
47fdbd4add | ||
|
|
a5c8e5caa3 | ||
|
|
6793aad486 | ||
|
|
f0001b7423 | ||
|
|
1c7d7b7c15 | ||
|
|
3941885dc0 | ||
|
|
f18b19bac9 | ||
|
|
f2dc2970ba | ||
|
|
c04ce8198b | ||
|
|
7296f063d7 | ||
|
|
197fe91d39 | ||
|
|
9016ffbafa | ||
|
|
934d7cf523 | ||
|
|
a3ff44115b | ||
|
|
86d55bcfeb | ||
|
|
74ee7ba44a | ||
|
|
a69b052f3f | ||
|
|
ad1bdb7e98 | ||
|
|
b28946e62c | ||
|
|
cb0da304a4 | ||
|
|
fcfa34bd6c | ||
|
|
02b1ba4744 | ||
|
|
e052467e89 | ||
|
|
e92c6a2817 | ||
|
|
f4f66b96b1 | ||
|
|
26ba67787c | ||
|
|
f165c75d01 |
@@ -1,6 +1,6 @@
|
||||
WordPress - Web publishing software
|
||||
|
||||
Copyright 2011-2019 by the contributors
|
||||
Copyright 2011-2018 by the contributors
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
||||
@@ -175,15 +175,6 @@ if ( is_network_admin() )
|
||||
|
||||
$admin_body_class .= ' no-customize-support no-svg';
|
||||
|
||||
if ( $current_screen->is_block_editor() ) {
|
||||
// Default to is-fullscreen-mode to avoid jumps in the UI.
|
||||
$admin_body_class .= ' block-editor-page is-fullscreen-mode wp-embed-responsive';
|
||||
|
||||
if ( current_theme_supports( 'editor-styles' ) && current_theme_supports( 'dark-editor-style' ) ) {
|
||||
$admin_body_class .= ' is-dark-theme';
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</head>
|
||||
<?php
|
||||
|
||||
@@ -20,7 +20,7 @@ include( ABSPATH . 'wp-admin/admin-header.php' );
|
||||
|
||||
<h1><?php printf( __( 'Welcome to WordPress %s' ), $display_version ); ?></h1>
|
||||
|
||||
<p class="about-text"><?php printf( __( 'Thank you for updating to the latest version! WordPress %s introduces a robust new content creation experience.' ), $display_version ); ?></p>
|
||||
<p class="about-text"><?php printf( __( 'Thank you for updating to the latest version! WordPress %s will smooth your design workflow and keep you safe from coding errors.' ), $display_version ); ?></p>
|
||||
|
||||
<div class="wp-badge"><?php printf( __( 'Version %s' ), $display_version ); ?></div>
|
||||
|
||||
|
||||
@@ -40,38 +40,17 @@
|
||||
.about-wrap hr {
|
||||
border: 0;
|
||||
height: 0;
|
||||
margin: 3em 0 0;
|
||||
margin: 0;
|
||||
border-top: 1px solid rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.about-wrap img {
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
max-width: 100%;
|
||||
height: auto;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.about-wrap figure {
|
||||
position: relative;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section figure img {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.about-wrap figcaption {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
padding: 40px 10px 15px;
|
||||
overflow: auto;
|
||||
box-sizing: border-box;
|
||||
background: linear-gradient(0deg,rgba(0,0,0,.7),rgba(0,0,0,.3) 60%,transparent);
|
||||
font-weight: 600;
|
||||
text-shadow: 0px 0px 5px rgba(0,0,0,.75);
|
||||
}
|
||||
|
||||
.about-wrap .jetpack-video-wrapper {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
@@ -153,19 +132,25 @@
|
||||
color: #23282d;
|
||||
}
|
||||
|
||||
.about-wrap .changelog h2 {
|
||||
font-size: 1.4em;
|
||||
font-weight: 600;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.about-wrap .changelog h3 {
|
||||
margin: 1.33em 0;
|
||||
font-size: 1em;
|
||||
line-height: inherit;
|
||||
color: #23282d;
|
||||
}
|
||||
|
||||
.about-wrap code,
|
||||
.about-wrap ol li p {
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.about-wrap figcaption {
|
||||
font-size: 13px;
|
||||
text-align: center;
|
||||
color: white;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.about-wrap .about-description,
|
||||
.about-wrap .about-text {
|
||||
margin-top: 1.4em;
|
||||
@@ -176,20 +161,23 @@
|
||||
|
||||
.about-wrap .about-text {
|
||||
margin: 1em 0 1em 200px;
|
||||
min-height: 60px;
|
||||
color: #555d66;
|
||||
}
|
||||
|
||||
/* 1.2 - Structure */
|
||||
|
||||
.about-wrap [class$="-col"] {
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-pack: justify;
|
||||
justify-content: space-between;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section.one-col {
|
||||
margin: 0 auto;
|
||||
max-width: 680px;
|
||||
max-width: 700px;
|
||||
}
|
||||
|
||||
.about-wrap .inline-svg img {
|
||||
@@ -203,6 +191,7 @@
|
||||
}
|
||||
|
||||
.about-wrap [class$="-col"] .col {
|
||||
-webkit-box-flex: 1;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
@@ -211,35 +200,13 @@
|
||||
max-width: 47%;
|
||||
}
|
||||
|
||||
.about-wrap .three-col,
|
||||
.about-wrap .four-col {
|
||||
margin: auto;
|
||||
max-width: 1020px;
|
||||
}
|
||||
|
||||
.about-wrap .three-col .col {
|
||||
-webkit-align-self: flex-start;
|
||||
align-self: flex-start;
|
||||
min-width: 31%;
|
||||
max-width: 31%;
|
||||
}
|
||||
|
||||
.about-wrap .four-col .col {
|
||||
align-self: flex-start;
|
||||
min-width: 23%;
|
||||
max-width: 23%;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section.eight-col .col {
|
||||
align-self: flex-start;
|
||||
margin-top: 6px;
|
||||
min-width: 12%;
|
||||
max-width: 12%;
|
||||
}
|
||||
|
||||
.about-wrap .one-col img {
|
||||
margin: 1em 0 2em;
|
||||
}
|
||||
|
||||
.about-wrap .two-col img {
|
||||
margin-bottom: 1.5em;
|
||||
}
|
||||
@@ -252,18 +219,6 @@
|
||||
background: transparent; /* Hide loading.gif */
|
||||
}
|
||||
|
||||
.about-wrap video {
|
||||
margin: 1.5em auto;
|
||||
}
|
||||
|
||||
.about-wrap .cta {
|
||||
text-align: center;
|
||||
}
|
||||
.about-wrap .cta .button {
|
||||
margin: 0 auto 5px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/* 1.3 - Point Releases */
|
||||
|
||||
.about-wrap .point-releases {
|
||||
@@ -304,7 +259,9 @@
|
||||
}
|
||||
|
||||
.about-wrap .two-col-text {
|
||||
-webkit-column-count: 2;
|
||||
column-count: 2;
|
||||
-webkit-column-gap: 40px;
|
||||
column-gap: 40px;
|
||||
}
|
||||
|
||||
@@ -317,10 +274,6 @@
|
||||
margin-bottom: 3em;
|
||||
}
|
||||
|
||||
.about-wrap .under-the-hood img + h3 {
|
||||
margin-top: 1.25em;
|
||||
}
|
||||
|
||||
/* 2.2 - Structure */
|
||||
|
||||
.about-wrap .headline-feature.feature-video {
|
||||
@@ -347,6 +300,7 @@
|
||||
|
||||
.about-wrap .feature-section {
|
||||
overflow: hidden;
|
||||
padding: 0 0 40px;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section.no-heading {
|
||||
@@ -357,6 +311,10 @@
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section img {
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
|
||||
.about-wrap .embed-container {
|
||||
text-align: center;
|
||||
}
|
||||
@@ -394,6 +352,92 @@
|
||||
padding: 0 5px;
|
||||
}
|
||||
|
||||
/* 2.3 Floating Header Layout */
|
||||
|
||||
.about-wrap .floating-header-section {
|
||||
display: -ms-grid;
|
||||
display: grid;
|
||||
grid-gap: 0 60px;
|
||||
-ms-grid-columns: 5fr 11fr;
|
||||
grid-template-columns: 5fr 11fr;
|
||||
max-width: 1020px;
|
||||
margin: 0 auto 120px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-header {
|
||||
-ms-grid-column: 1;
|
||||
grid-column: 1;
|
||||
position: relative;
|
||||
min-width: 230px;
|
||||
max-width: 300px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section h2 {
|
||||
margin: 0;
|
||||
text-align: right;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-content {
|
||||
-ms-grid-column: 2;
|
||||
grid-column: 2;
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-pack: justify;
|
||||
justify-content: space-between;
|
||||
-webkit-box-align: start;
|
||||
align-items: flex-start;
|
||||
-webkit-box-orient: horizontal;
|
||||
-webkit-box-direction: normal;
|
||||
flex-flow: row wrap;
|
||||
-webkit-box-flex: 2;
|
||||
flex-grow: 2;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-item {
|
||||
-webkit-box-flex: 1;
|
||||
flex-grow: 1;
|
||||
max-width: calc(50% - 30px);
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-item:nth-child(1),
|
||||
.about-wrap .floating-header-section .section-item:nth-child(2) {
|
||||
margin-bottom: 60px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-item:nth-child(1):nth-last-child(2),
|
||||
.about-wrap .floating-header-section .section-item:nth-child(2):nth-last-child(1) {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-header {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title h2 {
|
||||
position: static;
|
||||
margin-bottom: 60px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-content {
|
||||
-webkit-box-pack: start;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-item {
|
||||
max-width: 300px;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-item + .section-item {
|
||||
margin-right: 60px;
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------------------
|
||||
3.0 - Credits & Freedoms Pages
|
||||
------------------------------------------------------------------------------*/
|
||||
@@ -481,21 +525,6 @@
|
||||
margin: 0.6em 0;
|
||||
}
|
||||
|
||||
.freedoms-php .about-wrap .col .freedoms-image {
|
||||
background-image: url('https://s.w.org/wp-content/themes/pub/wporg-main/images/freedoms-2x.png');
|
||||
background-size: 100%;
|
||||
padding-top: 100%;
|
||||
}
|
||||
.freedoms-php .about-wrap .col:nth-of-type(2) .freedoms-image {
|
||||
background-position: 100% 34%;
|
||||
}
|
||||
.freedoms-php .about-wrap .col:nth-of-type(3) .freedoms-image {
|
||||
background-position: 100% 66%;
|
||||
}
|
||||
.freedoms-php .about-wrap .col:nth-of-type(4) .freedoms-image {
|
||||
background-position: 100% 100%;
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------------------
|
||||
4.0 - Media Queries
|
||||
------------------------------------------------------------------------------*/
|
||||
@@ -519,36 +548,20 @@
|
||||
|
||||
@media screen and (max-width: 782px) {
|
||||
.about-wrap .two-col-text {
|
||||
-webkit-column-count: 1;
|
||||
column-count: 1;
|
||||
}
|
||||
|
||||
.about-wrap .two-col .col,
|
||||
.about-wrap .three-col .col,
|
||||
.about-wrap .four-col .col {
|
||||
.about-wrap .three-col .col {
|
||||
min-width: 48% !important;
|
||||
}
|
||||
|
||||
.about-wrap .eight-col .col {
|
||||
min-width: 24% !important;
|
||||
}
|
||||
|
||||
.about-wrap .three-col img,
|
||||
.about-wrap .four-col img,
|
||||
.about-wrap .eight-col img {
|
||||
.about-wrap .three-col img {
|
||||
display: block;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.about-wrap figcaption {
|
||||
position: relative;
|
||||
margin-top: 10px;
|
||||
margin-bottom: 15px;
|
||||
padding: 0;
|
||||
background: none;
|
||||
color: #40464D;
|
||||
text-shadow: none;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section {
|
||||
display: block;
|
||||
}
|
||||
@@ -585,21 +598,11 @@
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section .col {
|
||||
margin-top: 1em;
|
||||
}
|
||||
|
||||
.about-wrap .two-col .col,
|
||||
.about-wrap .three-col .col,
|
||||
.about-wrap .three-col .col {
|
||||
min-width: 100% !important;
|
||||
}
|
||||
|
||||
.about-wrap .eight-col .col {
|
||||
min-width: 48% !important;
|
||||
}
|
||||
|
||||
.about-wrap .under-the-hood.four-col .col,
|
||||
.about-wrap .under-the-hood.three-col .col,
|
||||
.about-wrap .under-the-hood.two-col .col,
|
||||
.about-wrap .under-the-hood.one-col .col {
|
||||
@@ -612,8 +615,9 @@
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.about-wrap .under-the-hood img + h3 {
|
||||
margin-top: 1.25em;
|
||||
.about-wrap .under-the-hood:nth-of-type(2n) h3,
|
||||
.about-wrap .under-the-hood:nth-of-type(3n) h3 {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section {
|
||||
|
||||
2
wp-admin/css/about-rtl.min.css
vendored
@@ -40,38 +40,17 @@
|
||||
.about-wrap hr {
|
||||
border: 0;
|
||||
height: 0;
|
||||
margin: 3em 0 0;
|
||||
margin: 0;
|
||||
border-top: 1px solid rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.about-wrap img {
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
max-width: 100%;
|
||||
height: auto;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.about-wrap figure {
|
||||
position: relative;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section figure img {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.about-wrap figcaption {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
padding: 40px 10px 15px;
|
||||
overflow: auto;
|
||||
box-sizing: border-box;
|
||||
background: linear-gradient(0deg,rgba(0,0,0,.7),rgba(0,0,0,.3) 60%,transparent);
|
||||
font-weight: 600;
|
||||
text-shadow: 0px 0px 5px rgba(0,0,0,.75);
|
||||
}
|
||||
|
||||
.about-wrap .jetpack-video-wrapper {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
@@ -153,19 +132,25 @@
|
||||
color: #23282d;
|
||||
}
|
||||
|
||||
.about-wrap .changelog h2 {
|
||||
font-size: 1.4em;
|
||||
font-weight: 600;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.about-wrap .changelog h3 {
|
||||
margin: 1.33em 0;
|
||||
font-size: 1em;
|
||||
line-height: inherit;
|
||||
color: #23282d;
|
||||
}
|
||||
|
||||
.about-wrap code,
|
||||
.about-wrap ol li p {
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.about-wrap figcaption {
|
||||
font-size: 13px;
|
||||
text-align: center;
|
||||
color: white;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.about-wrap .about-description,
|
||||
.about-wrap .about-text {
|
||||
margin-top: 1.4em;
|
||||
@@ -176,20 +161,23 @@
|
||||
|
||||
.about-wrap .about-text {
|
||||
margin: 1em 200px 1em 0;
|
||||
min-height: 60px;
|
||||
color: #555d66;
|
||||
}
|
||||
|
||||
/* 1.2 - Structure */
|
||||
|
||||
.about-wrap [class$="-col"] {
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-pack: justify;
|
||||
justify-content: space-between;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section.one-col {
|
||||
margin: 0 auto;
|
||||
max-width: 680px;
|
||||
max-width: 700px;
|
||||
}
|
||||
|
||||
.about-wrap .inline-svg img {
|
||||
@@ -203,6 +191,7 @@
|
||||
}
|
||||
|
||||
.about-wrap [class$="-col"] .col {
|
||||
-webkit-box-flex: 1;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
@@ -211,35 +200,13 @@
|
||||
max-width: 47%;
|
||||
}
|
||||
|
||||
.about-wrap .three-col,
|
||||
.about-wrap .four-col {
|
||||
margin: auto;
|
||||
max-width: 1020px;
|
||||
}
|
||||
|
||||
.about-wrap .three-col .col {
|
||||
-webkit-align-self: flex-start;
|
||||
align-self: flex-start;
|
||||
min-width: 31%;
|
||||
max-width: 31%;
|
||||
}
|
||||
|
||||
.about-wrap .four-col .col {
|
||||
align-self: flex-start;
|
||||
min-width: 23%;
|
||||
max-width: 23%;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section.eight-col .col {
|
||||
align-self: flex-start;
|
||||
margin-top: 6px;
|
||||
min-width: 12%;
|
||||
max-width: 12%;
|
||||
}
|
||||
|
||||
.about-wrap .one-col img {
|
||||
margin: 1em 0 2em;
|
||||
}
|
||||
|
||||
.about-wrap .two-col img {
|
||||
margin-bottom: 1.5em;
|
||||
}
|
||||
@@ -252,18 +219,6 @@
|
||||
background: transparent; /* Hide loading.gif */
|
||||
}
|
||||
|
||||
.about-wrap video {
|
||||
margin: 1.5em auto;
|
||||
}
|
||||
|
||||
.about-wrap .cta {
|
||||
text-align: center;
|
||||
}
|
||||
.about-wrap .cta .button {
|
||||
margin: 0 auto 5px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/* 1.3 - Point Releases */
|
||||
|
||||
.about-wrap .point-releases {
|
||||
@@ -304,7 +259,9 @@
|
||||
}
|
||||
|
||||
.about-wrap .two-col-text {
|
||||
-webkit-column-count: 2;
|
||||
column-count: 2;
|
||||
-webkit-column-gap: 40px;
|
||||
column-gap: 40px;
|
||||
}
|
||||
|
||||
@@ -317,10 +274,6 @@
|
||||
margin-bottom: 3em;
|
||||
}
|
||||
|
||||
.about-wrap .under-the-hood img + h3 {
|
||||
margin-top: 1.25em;
|
||||
}
|
||||
|
||||
/* 2.2 - Structure */
|
||||
|
||||
.about-wrap .headline-feature.feature-video {
|
||||
@@ -347,6 +300,7 @@
|
||||
|
||||
.about-wrap .feature-section {
|
||||
overflow: hidden;
|
||||
padding: 0 0 40px;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section.no-heading {
|
||||
@@ -357,6 +311,10 @@
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section img {
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
|
||||
.about-wrap .embed-container {
|
||||
text-align: center;
|
||||
}
|
||||
@@ -394,6 +352,92 @@
|
||||
padding: 0 5px;
|
||||
}
|
||||
|
||||
/* 2.3 Floating Header Layout */
|
||||
|
||||
.about-wrap .floating-header-section {
|
||||
display: -ms-grid;
|
||||
display: grid;
|
||||
grid-gap: 0 60px;
|
||||
-ms-grid-columns: 5fr 11fr;
|
||||
grid-template-columns: 5fr 11fr;
|
||||
max-width: 1020px;
|
||||
margin: 0 auto 120px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-header {
|
||||
-ms-grid-column: 1;
|
||||
grid-column: 1;
|
||||
position: relative;
|
||||
min-width: 230px;
|
||||
max-width: 300px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section h2 {
|
||||
margin: 0;
|
||||
text-align: left;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-content {
|
||||
-ms-grid-column: 2;
|
||||
grid-column: 2;
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-pack: justify;
|
||||
justify-content: space-between;
|
||||
-webkit-box-align: start;
|
||||
align-items: flex-start;
|
||||
-webkit-box-orient: horizontal;
|
||||
-webkit-box-direction: normal;
|
||||
flex-flow: row wrap;
|
||||
-webkit-box-flex: 2;
|
||||
flex-grow: 2;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-item {
|
||||
-webkit-box-flex: 1;
|
||||
flex-grow: 1;
|
||||
max-width: calc(50% - 30px);
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-item:nth-child(1),
|
||||
.about-wrap .floating-header-section .section-item:nth-child(2) {
|
||||
margin-bottom: 60px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section .section-item:nth-child(1):nth-last-child(2),
|
||||
.about-wrap .floating-header-section .section-item:nth-child(2):nth-last-child(1) {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-header {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title h2 {
|
||||
position: static;
|
||||
margin-bottom: 60px;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-content {
|
||||
-webkit-box-pack: start;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-item {
|
||||
max-width: 300px;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section.has-long-title .section-item + .section-item {
|
||||
margin-left: 60px;
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------------------
|
||||
3.0 - Credits & Freedoms Pages
|
||||
------------------------------------------------------------------------------*/
|
||||
@@ -481,21 +525,6 @@
|
||||
margin: 0.6em 0;
|
||||
}
|
||||
|
||||
.freedoms-php .about-wrap .col .freedoms-image {
|
||||
background-image: url('https://s.w.org/wp-content/themes/pub/wporg-main/images/freedoms-2x.png');
|
||||
background-size: 100%;
|
||||
padding-top: 100%;
|
||||
}
|
||||
.freedoms-php .about-wrap .col:nth-of-type(2) .freedoms-image {
|
||||
background-position: 0 34%;
|
||||
}
|
||||
.freedoms-php .about-wrap .col:nth-of-type(3) .freedoms-image {
|
||||
background-position: 0 66%;
|
||||
}
|
||||
.freedoms-php .about-wrap .col:nth-of-type(4) .freedoms-image {
|
||||
background-position: 0 100%;
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------------------
|
||||
4.0 - Media Queries
|
||||
------------------------------------------------------------------------------*/
|
||||
@@ -519,36 +548,20 @@
|
||||
|
||||
@media screen and (max-width: 782px) {
|
||||
.about-wrap .two-col-text {
|
||||
-webkit-column-count: 1;
|
||||
column-count: 1;
|
||||
}
|
||||
|
||||
.about-wrap .two-col .col,
|
||||
.about-wrap .three-col .col,
|
||||
.about-wrap .four-col .col {
|
||||
.about-wrap .three-col .col {
|
||||
min-width: 48% !important;
|
||||
}
|
||||
|
||||
.about-wrap .eight-col .col {
|
||||
min-width: 24% !important;
|
||||
}
|
||||
|
||||
.about-wrap .three-col img,
|
||||
.about-wrap .four-col img,
|
||||
.about-wrap .eight-col img {
|
||||
.about-wrap .three-col img {
|
||||
display: block;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.about-wrap figcaption {
|
||||
position: relative;
|
||||
margin-top: 10px;
|
||||
margin-bottom: 15px;
|
||||
padding: 0;
|
||||
background: none;
|
||||
color: #40464D;
|
||||
text-shadow: none;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section {
|
||||
display: block;
|
||||
}
|
||||
@@ -585,21 +598,11 @@
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.about-wrap .feature-section .col {
|
||||
margin-top: 1em;
|
||||
}
|
||||
|
||||
.about-wrap .two-col .col,
|
||||
.about-wrap .three-col .col,
|
||||
.about-wrap .three-col .col {
|
||||
min-width: 100% !important;
|
||||
}
|
||||
|
||||
.about-wrap .eight-col .col {
|
||||
min-width: 48% !important;
|
||||
}
|
||||
|
||||
.about-wrap .under-the-hood.four-col .col,
|
||||
.about-wrap .under-the-hood.three-col .col,
|
||||
.about-wrap .under-the-hood.two-col .col,
|
||||
.about-wrap .under-the-hood.one-col .col {
|
||||
@@ -612,8 +615,9 @@
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.about-wrap .under-the-hood img + h3 {
|
||||
margin-top: 1.25em;
|
||||
.about-wrap .under-the-hood:nth-of-type(2n) h3,
|
||||
.about-wrap .under-the-hood:nth-of-type(3n) h3 {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.about-wrap .floating-header-section {
|
||||
|
||||
2
wp-admin/css/about.min.css
vendored
@@ -597,10 +597,12 @@ ul#adminmenu > li.current > a.current:after {
|
||||
/* rtl:ignore */
|
||||
.folded #collapse-button .collapse-button-icon:after,
|
||||
.rtl #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: rotate(180deg);
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
.rtl.folded #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -726,10 +728,12 @@ li#wp-admin-bar-menu-toggle {
|
||||
|
||||
/* rtl:ignore */
|
||||
.auto-fold #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: rotate(180deg);
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
.rtl.auto-fold #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/admin-menu-rtl.min.css
vendored
@@ -597,10 +597,12 @@ ul#adminmenu > li.current > a.current:after {
|
||||
/* rtl:ignore */
|
||||
.folded #collapse-button .collapse-button-icon:after,
|
||||
.rtl #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: rotate(180deg);
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
.rtl.folded #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -726,10 +728,12 @@ li#wp-admin-bar-menu-toggle {
|
||||
|
||||
/* rtl:ignore */
|
||||
.auto-fold #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: rotate(180deg);
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
.rtl.auto-fold #collapse-button .collapse-button-icon:after {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/admin-menu.min.css
vendored
@@ -70,7 +70,3 @@
|
||||
.CodeMirror {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.wrap .CodeMirror .CodeMirror-linenumber {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
2
wp-admin/css/code-editor-rtl.min.css
vendored
@@ -1,2 +1,2 @@
|
||||
/*! This file is auto-generated */
|
||||
.wp-core-ui [class*=CodeMirror-lint-message],.wrap .CodeMirror-lint-marker-multiple,.wrap [class*=CodeMirror-lint-marker]{background-image:none}.wp-core-ui .CodeMirror-lint-marker-error,.wp-core-ui .CodeMirror-lint-marker-warning{cursor:help}.wrap .CodeMirror-lint-marker-multiple{position:absolute;top:0}.wrap [class*=CodeMirror-lint-marker]:before{font:normal 18px/1 dashicons;position:relative;top:-2px}.wp-core-ui [class*=CodeMirror-lint-message]:before{font:normal 16px/1 dashicons;right:16px;position:absolute}.wp-core-ui .CodeMirror-lint-message-error,.wp-core-ui .CodeMirror-lint-message-warning{box-shadow:0 1px 1px 0 rgba(0,0,0,.1);margin:5px 0 2px;padding:3px 28px 3px 12px}.wp-core-ui .CodeMirror-lint-message-warning{background-color:#fff8e5;border-right:4px solid #ffb900}.wp-core-ui .CodeMirror-lint-message-warning:before,.wrap .CodeMirror-lint-marker-warning:before{content:"\f534";color:#f6a306}.wp-core-ui .CodeMirror-lint-message-error{background-color:#fbeaea;border-right:4px solid #dc3232}.wp-core-ui .CodeMirror-lint-message-error:before,.wrap .CodeMirror-lint-marker-error:before{content:"\f153";color:#dc3232}.wp-core-ui .CodeMirror-lint-tooltip{background:0 0;border:none;border-radius:0;direction:rtl}.wrap .CodeMirror .CodeMirror-matchingbracket{background:rgba(255,150,0,.3);color:inherit}.CodeMirror{text-align:right}.wrap .CodeMirror .CodeMirror-linenumber{color:#666}
|
||||
.wp-core-ui [class*=CodeMirror-lint-message],.wrap .CodeMirror-lint-marker-multiple,.wrap [class*=CodeMirror-lint-marker]{background-image:none}.wp-core-ui .CodeMirror-lint-marker-error,.wp-core-ui .CodeMirror-lint-marker-warning{cursor:help}.wrap .CodeMirror-lint-marker-multiple{position:absolute;top:0}.wrap [class*=CodeMirror-lint-marker]:before{font:normal 18px/1 dashicons;position:relative;top:-2px}.wp-core-ui [class*=CodeMirror-lint-message]:before{font:normal 16px/1 dashicons;right:16px;position:absolute}.wp-core-ui .CodeMirror-lint-message-error,.wp-core-ui .CodeMirror-lint-message-warning{box-shadow:0 1px 1px 0 rgba(0,0,0,.1);margin:5px 0 2px;padding:3px 28px 3px 12px}.wp-core-ui .CodeMirror-lint-message-warning{background-color:#fff8e5;border-right:4px solid #ffb900}.wp-core-ui .CodeMirror-lint-message-warning:before,.wrap .CodeMirror-lint-marker-warning:before{content:"\f534";color:#f6a306}.wp-core-ui .CodeMirror-lint-message-error{background-color:#fbeaea;border-right:4px solid #dc3232}.wp-core-ui .CodeMirror-lint-message-error:before,.wrap .CodeMirror-lint-marker-error:before{content:"\f153";color:#dc3232}.wp-core-ui .CodeMirror-lint-tooltip{background:0 0;border:none;border-radius:0;direction:rtl}.wrap .CodeMirror .CodeMirror-matchingbracket{background:rgba(255,150,0,.3);color:inherit}.CodeMirror{text-align:right}
|
||||
@@ -70,7 +70,3 @@
|
||||
.CodeMirror {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.wrap .CodeMirror .CodeMirror-linenumber {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
2
wp-admin/css/code-editor.min.css
vendored
@@ -1,2 +1,2 @@
|
||||
/*! This file is auto-generated */
|
||||
.wp-core-ui [class*=CodeMirror-lint-message],.wrap .CodeMirror-lint-marker-multiple,.wrap [class*=CodeMirror-lint-marker]{background-image:none}.wp-core-ui .CodeMirror-lint-marker-error,.wp-core-ui .CodeMirror-lint-marker-warning{cursor:help}.wrap .CodeMirror-lint-marker-multiple{position:absolute;top:0}.wrap [class*=CodeMirror-lint-marker]:before{font:normal 18px/1 dashicons;position:relative;top:-2px}.wp-core-ui [class*=CodeMirror-lint-message]:before{font:normal 16px/1 dashicons;left:16px;position:absolute}.wp-core-ui .CodeMirror-lint-message-error,.wp-core-ui .CodeMirror-lint-message-warning{box-shadow:0 1px 1px 0 rgba(0,0,0,.1);margin:5px 0 2px;padding:3px 12px 3px 28px}.wp-core-ui .CodeMirror-lint-message-warning{background-color:#fff8e5;border-left:4px solid #ffb900}.wp-core-ui .CodeMirror-lint-message-warning:before,.wrap .CodeMirror-lint-marker-warning:before{content:"\f534";color:#f6a306}.wp-core-ui .CodeMirror-lint-message-error{background-color:#fbeaea;border-left:4px solid #dc3232}.wp-core-ui .CodeMirror-lint-message-error:before,.wrap .CodeMirror-lint-marker-error:before{content:"\f153";color:#dc3232}.wp-core-ui .CodeMirror-lint-tooltip{background:0 0;border:none;border-radius:0;direction:ltr}.wrap .CodeMirror .CodeMirror-matchingbracket{background:rgba(255,150,0,.3);color:inherit}.CodeMirror{text-align:left}.wrap .CodeMirror .CodeMirror-linenumber{color:#666}
|
||||
.wp-core-ui [class*=CodeMirror-lint-message],.wrap .CodeMirror-lint-marker-multiple,.wrap [class*=CodeMirror-lint-marker]{background-image:none}.wp-core-ui .CodeMirror-lint-marker-error,.wp-core-ui .CodeMirror-lint-marker-warning{cursor:help}.wrap .CodeMirror-lint-marker-multiple{position:absolute;top:0}.wrap [class*=CodeMirror-lint-marker]:before{font:normal 18px/1 dashicons;position:relative;top:-2px}.wp-core-ui [class*=CodeMirror-lint-message]:before{font:normal 16px/1 dashicons;left:16px;position:absolute}.wp-core-ui .CodeMirror-lint-message-error,.wp-core-ui .CodeMirror-lint-message-warning{box-shadow:0 1px 1px 0 rgba(0,0,0,.1);margin:5px 0 2px;padding:3px 12px 3px 28px}.wp-core-ui .CodeMirror-lint-message-warning{background-color:#fff8e5;border-left:4px solid #ffb900}.wp-core-ui .CodeMirror-lint-message-warning:before,.wrap .CodeMirror-lint-marker-warning:before{content:"\f534";color:#f6a306}.wp-core-ui .CodeMirror-lint-message-error{background-color:#fbeaea;border-left:4px solid #dc3232}.wp-core-ui .CodeMirror-lint-message-error:before,.wrap .CodeMirror-lint-marker-error:before{content:"\f153";color:#dc3232}.wp-core-ui .CodeMirror-lint-tooltip{background:0 0;border:none;border-radius:0;direction:ltr}.wrap .CodeMirror .CodeMirror-matchingbracket{background:rgba(255,150,0,.3);color:inherit}.CodeMirror{text-align:left}
|
||||
@@ -50,6 +50,7 @@
|
||||
|
||||
.wp-color-result:active {
|
||||
/* See Trac ticket #39662 */
|
||||
-webkit-transform: none !important;
|
||||
transform: none !important;
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/color-picker-rtl.min.css
vendored
@@ -1,2 +1,2 @@
|
||||
/*! This file is auto-generated */
|
||||
.wp-color-picker{width:80px}.wp-picker-container .hidden{display:none}.wp-picker-container .wp-color-result.button{height:24px;margin:0 0 6px 6px;padding:0 30px 0 0;font-size:11px}.wp-color-result-text{background:#f7f7f7;border-radius:2px 0 0 2px;border-right:1px solid #ccc;color:#555;display:block;line-height:22px;padding:0 6px;text-align:center}.wp-color-result:focus,.wp-color-result:hover{background:#fafafa;border-color:#999;color:#23282d}.wp-color-result:focus:after,.wp-color-result:hover:after{color:#23282d;border-color:#a0a5aa;border-right:1px solid #999}.wp-picker-containers{display:inline-block}.wp-color-result:focus{border-color:#5b9dd9;box-shadow:0 0 3px rgba(0,115,170,.8)}.wp-color-result:active{transform:none!important}.wp-picker-open+.wp-picker-input-wrap{display:inline-block;vertical-align:top}.wp-picker-input-wrap label{display:inline-block;vertical-align:top}.form-table .wp-picker-input-wrap label{margin:0!important}.wp-customizer .wp-picker-input-wrap .button,.wp-picker-input-wrap .button{margin-right:6px}.wp-picker-container .iris-square-slider .ui-slider-handle:focus{background-color:#555}.wp-picker-container .iris-picker{border-radius:0;border-color:#ddd;margin-top:6px}.wp-picker-container input[type=text].wp-color-picker{width:65px;font-size:12px;font-family:monospace;line-height:16px;margin:0;vertical-align:top}.wp-color-picker::-webkit-input-placeholder{color:#72777c}.wp-color-picker::-moz-placeholder{color:#72777c;opacity:1}.wp-color-picker:-ms-input-placeholder{color:#72777c}.wp-picker-container input[type=text].iris-error{background-color:#ffebe8;border-color:#c00;color:#000}.iris-picker .iris-strip .ui-slider-handle:focus,.iris-picker .ui-square-handle:focus{box-shadow:0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}.iris-picker .iris-palette:focus{box-shadow:inset 0 0 5px rgba(0,0,0,.4),0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}@media screen and (max-width:782px){.wp-picker-container input[type=text].wp-color-picker{width:80px;padding:6px 5px 5px;font-size:16px;line-height:18px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:5px 5px 4px}.wp-picker-container .wp-color-result.button{height:auto;padding:0 40px 0 0;font-size:14px;line-height:29px}.wp-customizer .wp-picker-container .wp-color-result.button{font-size:13px;line-height:26px}.wp-picker-container .wp-color-result-text{padding:0 14px;font-size:inherit;line-height:inherit}.wp-customizer .wp-picker-container .wp-color-result-text{padding:0 10px}}@media screen and (max-width:640px){.wp-customizer .wp-picker-container .wp-color-result.button{font-size:14px;line-height:29px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:6px 5px}}
|
||||
.wp-color-picker{width:80px}.wp-picker-container .hidden{display:none}.wp-picker-container .wp-color-result.button{height:24px;margin:0 0 6px 6px;padding:0 30px 0 0;font-size:11px}.wp-color-result-text{background:#f7f7f7;border-radius:2px 0 0 2px;border-right:1px solid #ccc;color:#555;display:block;line-height:22px;padding:0 6px;text-align:center}.wp-color-result:focus,.wp-color-result:hover{background:#fafafa;border-color:#999;color:#23282d}.wp-color-result:focus:after,.wp-color-result:hover:after{color:#23282d;border-color:#a0a5aa;border-right:1px solid #999}.wp-picker-containers{display:inline-block}.wp-color-result:focus{border-color:#5b9dd9;box-shadow:0 0 3px rgba(0,115,170,.8)}.wp-color-result:active{-webkit-transform:none!important;transform:none!important}.wp-picker-open+.wp-picker-input-wrap{display:inline-block;vertical-align:top}.wp-picker-input-wrap label{display:inline-block;vertical-align:top}.form-table .wp-picker-input-wrap label{margin:0!important}.wp-customizer .wp-picker-input-wrap .button,.wp-picker-input-wrap .button{margin-right:6px}.wp-picker-container .iris-square-slider .ui-slider-handle:focus{background-color:#555}.wp-picker-container .iris-picker{border-radius:0;border-color:#ddd;margin-top:6px}.wp-picker-container input[type=text].wp-color-picker{width:65px;font-size:12px;font-family:monospace;line-height:16px;margin:0;vertical-align:top}.wp-color-picker::-webkit-input-placeholder{color:#72777c}.wp-color-picker::-moz-placeholder{color:#72777c;opacity:1}.wp-color-picker:-ms-input-placeholder{color:#72777c}.wp-picker-container input[type=text].iris-error{background-color:#ffebe8;border-color:#c00;color:#000}.iris-picker .iris-strip .ui-slider-handle:focus,.iris-picker .ui-square-handle:focus{box-shadow:0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}.iris-picker .iris-palette:focus{box-shadow:inset 0 0 5px rgba(0,0,0,.4),0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}@media screen and (max-width:782px){.wp-picker-container input[type=text].wp-color-picker{width:80px;padding:6px 5px 5px;font-size:16px;line-height:18px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:5px 5px 4px}.wp-picker-container .wp-color-result.button{height:auto;padding:0 40px 0 0;font-size:14px;line-height:29px}.wp-customizer .wp-picker-container .wp-color-result.button{font-size:13px;line-height:26px}.wp-picker-container .wp-color-result-text{padding:0 14px;font-size:inherit;line-height:inherit}.wp-customizer .wp-picker-container .wp-color-result-text{padding:0 10px}}@media screen and (max-width:640px){.wp-customizer .wp-picker-container .wp-color-result.button{font-size:14px;line-height:29px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:6px 5px}}
|
||||
@@ -50,6 +50,7 @@
|
||||
|
||||
.wp-color-result:active {
|
||||
/* See Trac ticket #39662 */
|
||||
-webkit-transform: none !important;
|
||||
transform: none !important;
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/color-picker.min.css
vendored
@@ -1,2 +1,2 @@
|
||||
/*! This file is auto-generated */
|
||||
.wp-color-picker{width:80px}.wp-picker-container .hidden{display:none}.wp-picker-container .wp-color-result.button{height:24px;margin:0 6px 6px 0;padding:0 0 0 30px;font-size:11px}.wp-color-result-text{background:#f7f7f7;border-radius:0 2px 2px 0;border-left:1px solid #ccc;color:#555;display:block;line-height:22px;padding:0 6px;text-align:center}.wp-color-result:focus,.wp-color-result:hover{background:#fafafa;border-color:#999;color:#23282d}.wp-color-result:focus:after,.wp-color-result:hover:after{color:#23282d;border-color:#a0a5aa;border-left:1px solid #999}.wp-picker-containers{display:inline-block}.wp-color-result:focus{border-color:#5b9dd9;box-shadow:0 0 3px rgba(0,115,170,.8)}.wp-color-result:active{transform:none!important}.wp-picker-open+.wp-picker-input-wrap{display:inline-block;vertical-align:top}.wp-picker-input-wrap label{display:inline-block;vertical-align:top}.form-table .wp-picker-input-wrap label{margin:0!important}.wp-customizer .wp-picker-input-wrap .button,.wp-picker-input-wrap .button{margin-left:6px}.wp-picker-container .iris-square-slider .ui-slider-handle:focus{background-color:#555}.wp-picker-container .iris-picker{border-radius:0;border-color:#ddd;margin-top:6px}.wp-picker-container input[type=text].wp-color-picker{width:65px;font-size:12px;font-family:monospace;line-height:16px;margin:0;vertical-align:top}.wp-color-picker::-webkit-input-placeholder{color:#72777c}.wp-color-picker::-moz-placeholder{color:#72777c;opacity:1}.wp-color-picker:-ms-input-placeholder{color:#72777c}.wp-picker-container input[type=text].iris-error{background-color:#ffebe8;border-color:#c00;color:#000}.iris-picker .iris-strip .ui-slider-handle:focus,.iris-picker .ui-square-handle:focus{box-shadow:0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}.iris-picker .iris-palette:focus{box-shadow:inset 0 0 5px rgba(0,0,0,.4),0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}@media screen and (max-width:782px){.wp-picker-container input[type=text].wp-color-picker{width:80px;padding:6px 5px 5px;font-size:16px;line-height:18px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:5px 5px 4px}.wp-picker-container .wp-color-result.button{height:auto;padding:0 0 0 40px;font-size:14px;line-height:29px}.wp-customizer .wp-picker-container .wp-color-result.button{font-size:13px;line-height:26px}.wp-picker-container .wp-color-result-text{padding:0 14px;font-size:inherit;line-height:inherit}.wp-customizer .wp-picker-container .wp-color-result-text{padding:0 10px}}@media screen and (max-width:640px){.wp-customizer .wp-picker-container .wp-color-result.button{font-size:14px;line-height:29px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:6px 5px}}
|
||||
.wp-color-picker{width:80px}.wp-picker-container .hidden{display:none}.wp-picker-container .wp-color-result.button{height:24px;margin:0 6px 6px 0;padding:0 0 0 30px;font-size:11px}.wp-color-result-text{background:#f7f7f7;border-radius:0 2px 2px 0;border-left:1px solid #ccc;color:#555;display:block;line-height:22px;padding:0 6px;text-align:center}.wp-color-result:focus,.wp-color-result:hover{background:#fafafa;border-color:#999;color:#23282d}.wp-color-result:focus:after,.wp-color-result:hover:after{color:#23282d;border-color:#a0a5aa;border-left:1px solid #999}.wp-picker-containers{display:inline-block}.wp-color-result:focus{border-color:#5b9dd9;box-shadow:0 0 3px rgba(0,115,170,.8)}.wp-color-result:active{-webkit-transform:none!important;transform:none!important}.wp-picker-open+.wp-picker-input-wrap{display:inline-block;vertical-align:top}.wp-picker-input-wrap label{display:inline-block;vertical-align:top}.form-table .wp-picker-input-wrap label{margin:0!important}.wp-customizer .wp-picker-input-wrap .button,.wp-picker-input-wrap .button{margin-left:6px}.wp-picker-container .iris-square-slider .ui-slider-handle:focus{background-color:#555}.wp-picker-container .iris-picker{border-radius:0;border-color:#ddd;margin-top:6px}.wp-picker-container input[type=text].wp-color-picker{width:65px;font-size:12px;font-family:monospace;line-height:16px;margin:0;vertical-align:top}.wp-color-picker::-webkit-input-placeholder{color:#72777c}.wp-color-picker::-moz-placeholder{color:#72777c;opacity:1}.wp-color-picker:-ms-input-placeholder{color:#72777c}.wp-picker-container input[type=text].iris-error{background-color:#ffebe8;border-color:#c00;color:#000}.iris-picker .iris-strip .ui-slider-handle:focus,.iris-picker .ui-square-handle:focus{box-shadow:0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}.iris-picker .iris-palette:focus{box-shadow:inset 0 0 5px rgba(0,0,0,.4),0 0 0 1px #5b9dd9,0 0 2px 1px rgba(30,140,190,.8)}@media screen and (max-width:782px){.wp-picker-container input[type=text].wp-color-picker{width:80px;padding:6px 5px 5px;font-size:16px;line-height:18px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:5px 5px 4px}.wp-picker-container .wp-color-result.button{height:auto;padding:0 0 0 40px;font-size:14px;line-height:29px}.wp-customizer .wp-picker-container .wp-color-result.button{font-size:13px;line-height:26px}.wp-picker-container .wp-color-result-text{padding:0 14px;font-size:inherit;line-height:inherit}.wp-customizer .wp-picker-container .wp-color-result-text{padding:0 10px}}@media screen and (max-width:640px){.wp-customizer .wp-picker-container .wp-color-result.button{font-size:14px;line-height:29px}.wp-customizer .wp-picker-container input[type=text].wp-color-picker{padding:6px 5px}}
|
||||
@@ -560,10 +560,6 @@ code {
|
||||
margin: 10px 2px 0 20px;
|
||||
}
|
||||
|
||||
.wrap.block-editor-no-js {
|
||||
padding-right: 20px;
|
||||
}
|
||||
|
||||
.wrap > h2:first-child, /* Back-compat for pre-4.4 */
|
||||
.wrap [class$="icon32"] + h2, /* Back-compat for pre-4.4 */
|
||||
.postbox .inside h2, /* Back-compat for pre-4.4 */
|
||||
@@ -1120,6 +1116,7 @@ th.action-links {
|
||||
.wp-filter .button.drawer-toggle:active {
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -1510,6 +1507,7 @@ div.error {
|
||||
.import-php .updating-message:before,
|
||||
.button.updating-message:before,
|
||||
.button.installing:before {
|
||||
-webkit-animation: rotation 2s infinite linear;
|
||||
animation: rotation 2s infinite linear;
|
||||
}
|
||||
|
||||
@@ -1682,6 +1680,7 @@ form.upgrade .hint {
|
||||
|
||||
#screen-meta-links .show-settings:active {
|
||||
box-shadow: none;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -2470,6 +2469,7 @@ div.star-holder .star-rating {
|
||||
}
|
||||
|
||||
.rtl .star-rating .star-half {
|
||||
-webkit-transform: rotateY(-180deg);
|
||||
transform: rotateY(-180deg);
|
||||
}
|
||||
|
||||
@@ -2918,6 +2918,7 @@ div.action-links {
|
||||
margin: -10px -10px 0 0;
|
||||
background: #fcfcfc url(../images/spinner.gif) no-repeat center;
|
||||
background-size: 20px 20px;
|
||||
-webkit-transform: translateZ(0);
|
||||
transform: translateZ(0);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/common-rtl.min.css
vendored
@@ -560,10 +560,6 @@ code {
|
||||
margin: 10px 20px 0 2px;
|
||||
}
|
||||
|
||||
.wrap.block-editor-no-js {
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
.wrap > h2:first-child, /* Back-compat for pre-4.4 */
|
||||
.wrap [class$="icon32"] + h2, /* Back-compat for pre-4.4 */
|
||||
.postbox .inside h2, /* Back-compat for pre-4.4 */
|
||||
@@ -1120,6 +1116,7 @@ th.action-links {
|
||||
.wp-filter .button.drawer-toggle:active {
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -1510,6 +1507,7 @@ div.error {
|
||||
.import-php .updating-message:before,
|
||||
.button.updating-message:before,
|
||||
.button.installing:before {
|
||||
-webkit-animation: rotation 2s infinite linear;
|
||||
animation: rotation 2s infinite linear;
|
||||
}
|
||||
|
||||
@@ -1682,6 +1680,7 @@ form.upgrade .hint {
|
||||
|
||||
#screen-meta-links .show-settings:active {
|
||||
box-shadow: none;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -2470,6 +2469,7 @@ div.star-holder .star-rating {
|
||||
}
|
||||
|
||||
.rtl .star-rating .star-half {
|
||||
-webkit-transform: rotateY(180deg);
|
||||
transform: rotateY(180deg);
|
||||
}
|
||||
|
||||
@@ -2918,6 +2918,7 @@ div.action-links {
|
||||
margin: -10px 0 0 -10px;
|
||||
background: #fcfcfc url(../images/spinner.gif) no-repeat center;
|
||||
background-size: 20px 20px;
|
||||
-webkit-transform: translateZ(0);
|
||||
transform: translateZ(0);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/common.min.css
vendored
@@ -157,6 +157,7 @@ body:not(.ready) #customize-save-button-wrapper .save {
|
||||
font-size: 14px;
|
||||
width: 30px;
|
||||
float: right;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
margin-top: 0;
|
||||
}
|
||||
@@ -633,7 +634,9 @@ body.trashing #publish-settings {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
box-sizing: border-box;
|
||||
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1); /* easeInOutCubic */
|
||||
transition: 0.18s -webkit-transform cubic-bezier(0.645, 0.045, 0.355, 1);
|
||||
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1);
|
||||
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1), 0.18s -webkit-transform cubic-bezier(0.645, 0.045, 0.355, 1); /* easeInOutCubic */
|
||||
}
|
||||
|
||||
#customize-theme-controls .customize-pane-child.skip-transition {
|
||||
@@ -647,6 +650,7 @@ body.trashing #publish-settings {
|
||||
height: auto;
|
||||
max-height: none;
|
||||
overflow: auto;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -658,11 +662,13 @@ body.trashing #publish-settings {
|
||||
height: 0;
|
||||
max-height: none;
|
||||
overflow: hidden;
|
||||
-webkit-transform: translateX(-100%);
|
||||
transform: translateX(-100%);
|
||||
}
|
||||
|
||||
#customize-theme-controls .customize-pane-child.open,
|
||||
#customize-theme-controls .customize-pane-child.current-panel {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -674,6 +680,7 @@ body.trashing #publish-settings {
|
||||
visibility: hidden;
|
||||
height: 0;
|
||||
overflow: hidden;
|
||||
-webkit-transform: translateX(100%);
|
||||
transform: translateX(100%);
|
||||
}
|
||||
|
||||
@@ -1068,6 +1075,7 @@ p.customize-section-description {
|
||||
bottom: 0;
|
||||
z-index: 10;
|
||||
background: #eee;
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
@@ -1079,12 +1087,14 @@ p.customize-section-description {
|
||||
|
||||
#available-menu-items .new-content-item .create-item-input,
|
||||
.customize-control-dropdown-pages .new-content-item .create-item-input {
|
||||
-webkit-box-flex: 10;
|
||||
flex-grow: 10;
|
||||
}
|
||||
|
||||
#available-menu-items .new-content-item .add-content,
|
||||
.customize-control-dropdown-pages .new-content-item .add-content {
|
||||
margin: 2px 6px 2px 0;
|
||||
-webkit-box-flex: 10;
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
@@ -1205,6 +1215,11 @@ p.customize-section-description {
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
@-webkit-keyframes customize-fade-in {
|
||||
0% { opacity: 0; }
|
||||
100% { opacity: 1; }
|
||||
}
|
||||
|
||||
@keyframes customize-fade-in {
|
||||
0% { opacity: 0; }
|
||||
100% { opacity: 1; }
|
||||
@@ -1217,6 +1232,7 @@ p.customize-section-description {
|
||||
}
|
||||
|
||||
#customize-controls .customize-control-notifications-container.has-overlay-notifications {
|
||||
-webkit-animation: customize-fade-in 0.5s;
|
||||
animation: customize-fade-in 0.5s;
|
||||
z-index: 30;
|
||||
}
|
||||
@@ -1490,31 +1506,62 @@ p.customize-section-description {
|
||||
|
||||
.customize-control-header .placeholder:hover .dice,
|
||||
.customize-control-header .header-view:hover > button.random .dice {
|
||||
-webkit-animation: dice-color-change 3s infinite;
|
||||
animation: dice-color-change 3s infinite;
|
||||
}
|
||||
|
||||
.button-see-me {
|
||||
-webkit-animation: bounce .7s 1;
|
||||
animation: bounce .7s 1;
|
||||
-webkit-transform-origin: center bottom;
|
||||
transform-origin: center bottom;
|
||||
}
|
||||
|
||||
@-webkit-keyframes bounce {
|
||||
from, 20%, 53%, 80%, to {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
|
||||
-webkit-transform: translate3d(0,0,0);
|
||||
}
|
||||
|
||||
40%, 43% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -12px, 0);
|
||||
}
|
||||
|
||||
70% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -6px, 0);
|
||||
}
|
||||
|
||||
90% {
|
||||
-webkit-transform: translate3d(0,-1px,0);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes bounce {
|
||||
from, 20%, 53%, 80%, to {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
|
||||
animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
|
||||
-webkit-transform: translate3d(0,0,0);
|
||||
transform: translate3d(0,0,0);
|
||||
}
|
||||
|
||||
40%, 43% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -12px, 0);
|
||||
transform: translate3d(0, -12px, 0);
|
||||
}
|
||||
|
||||
70% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -6px, 0);
|
||||
transform: translate3d(0, -6px, 0);
|
||||
}
|
||||
|
||||
90% {
|
||||
-webkit-transform: translate3d(0,-1px,0);
|
||||
transform: translate3d(0,-1px,0);
|
||||
}
|
||||
}
|
||||
@@ -1784,6 +1831,7 @@ p.customize-section-description {
|
||||
background: #eee;
|
||||
border-color: #999;
|
||||
box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 );
|
||||
-webkit-transform: translateY(1px);
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
@@ -1812,6 +1860,17 @@ p.customize-section-description {
|
||||
}
|
||||
|
||||
/* Adds a delay before fading in to avoid it "jumping" */
|
||||
@-webkit-keyframes themes-fade-in {
|
||||
0% {
|
||||
opacity: 0;
|
||||
}
|
||||
50% {
|
||||
opacity: 0;
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
@keyframes themes-fade-in {
|
||||
0% {
|
||||
opacity: 0;
|
||||
@@ -1825,10 +1884,12 @@ p.customize-section-description {
|
||||
}
|
||||
|
||||
.control-panel-themes .customize-themes-full-container.animate {
|
||||
-webkit-animation: .6s themes-fade-in 1;
|
||||
animation: .6s themes-fade-in 1;
|
||||
}
|
||||
|
||||
.in-themes-panel:not(.animating) .control-panel-themes .filter-themes-count {
|
||||
-webkit-animation: .6s themes-fade-in 1;
|
||||
animation: .6s themes-fade-in 1;
|
||||
}
|
||||
|
||||
@@ -2514,6 +2575,7 @@ body.adding-widget .add-new-widget:hover,
|
||||
body.adding-widget .add-new-widget:before,
|
||||
.adding-menu-items .add-new-menu-item:before,
|
||||
#accordion-section-add_menu .add-new-menu-item.open:before {
|
||||
-webkit-transform: rotate(-45deg);
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/customize-controls-rtl.min.css
vendored
@@ -157,6 +157,7 @@ body:not(.ready) #customize-save-button-wrapper .save {
|
||||
font-size: 14px;
|
||||
width: 30px;
|
||||
float: left;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
margin-top: 0;
|
||||
}
|
||||
@@ -633,7 +634,9 @@ body.trashing #publish-settings {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
box-sizing: border-box;
|
||||
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1); /* easeInOutCubic */
|
||||
transition: 0.18s -webkit-transform cubic-bezier(0.645, 0.045, 0.355, 1);
|
||||
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1);
|
||||
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1), 0.18s -webkit-transform cubic-bezier(0.645, 0.045, 0.355, 1); /* easeInOutCubic */
|
||||
}
|
||||
|
||||
#customize-theme-controls .customize-pane-child.skip-transition {
|
||||
@@ -647,6 +650,7 @@ body.trashing #publish-settings {
|
||||
height: auto;
|
||||
max-height: none;
|
||||
overflow: auto;
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -658,11 +662,13 @@ body.trashing #publish-settings {
|
||||
height: 0;
|
||||
max-height: none;
|
||||
overflow: hidden;
|
||||
-webkit-transform: translateX(100%);
|
||||
transform: translateX(100%);
|
||||
}
|
||||
|
||||
#customize-theme-controls .customize-pane-child.open,
|
||||
#customize-theme-controls .customize-pane-child.current-panel {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -674,6 +680,7 @@ body.trashing #publish-settings {
|
||||
visibility: hidden;
|
||||
height: 0;
|
||||
overflow: hidden;
|
||||
-webkit-transform: translateX(-100%);
|
||||
transform: translateX(-100%);
|
||||
}
|
||||
|
||||
@@ -1068,6 +1075,7 @@ p.customize-section-description {
|
||||
bottom: 0;
|
||||
z-index: 10;
|
||||
background: #eee;
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
@@ -1079,12 +1087,14 @@ p.customize-section-description {
|
||||
|
||||
#available-menu-items .new-content-item .create-item-input,
|
||||
.customize-control-dropdown-pages .new-content-item .create-item-input {
|
||||
-webkit-box-flex: 10;
|
||||
flex-grow: 10;
|
||||
}
|
||||
|
||||
#available-menu-items .new-content-item .add-content,
|
||||
.customize-control-dropdown-pages .new-content-item .add-content {
|
||||
margin: 2px 0 2px 6px;
|
||||
-webkit-box-flex: 10;
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
@@ -1205,6 +1215,11 @@ p.customize-section-description {
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
@-webkit-keyframes customize-fade-in {
|
||||
0% { opacity: 0; }
|
||||
100% { opacity: 1; }
|
||||
}
|
||||
|
||||
@keyframes customize-fade-in {
|
||||
0% { opacity: 0; }
|
||||
100% { opacity: 1; }
|
||||
@@ -1217,6 +1232,7 @@ p.customize-section-description {
|
||||
}
|
||||
|
||||
#customize-controls .customize-control-notifications-container.has-overlay-notifications {
|
||||
-webkit-animation: customize-fade-in 0.5s;
|
||||
animation: customize-fade-in 0.5s;
|
||||
z-index: 30;
|
||||
}
|
||||
@@ -1490,31 +1506,62 @@ p.customize-section-description {
|
||||
|
||||
.customize-control-header .placeholder:hover .dice,
|
||||
.customize-control-header .header-view:hover > button.random .dice {
|
||||
-webkit-animation: dice-color-change 3s infinite;
|
||||
animation: dice-color-change 3s infinite;
|
||||
}
|
||||
|
||||
.button-see-me {
|
||||
-webkit-animation: bounce .7s 1;
|
||||
animation: bounce .7s 1;
|
||||
-webkit-transform-origin: center bottom;
|
||||
transform-origin: center bottom;
|
||||
}
|
||||
|
||||
@-webkit-keyframes bounce {
|
||||
from, 20%, 53%, 80%, to {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
|
||||
-webkit-transform: translate3d(0,0,0);
|
||||
}
|
||||
|
||||
40%, 43% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -12px, 0);
|
||||
}
|
||||
|
||||
70% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -6px, 0);
|
||||
}
|
||||
|
||||
90% {
|
||||
-webkit-transform: translate3d(0,-1px,0);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes bounce {
|
||||
from, 20%, 53%, 80%, to {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
|
||||
animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
|
||||
-webkit-transform: translate3d(0,0,0);
|
||||
transform: translate3d(0,0,0);
|
||||
}
|
||||
|
||||
40%, 43% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -12px, 0);
|
||||
transform: translate3d(0, -12px, 0);
|
||||
}
|
||||
|
||||
70% {
|
||||
-webkit-animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
animation-timing-function: cubic-bezier(0.755, 0.050, 0.855, 0.060);
|
||||
-webkit-transform: translate3d(0, -6px, 0);
|
||||
transform: translate3d(0, -6px, 0);
|
||||
}
|
||||
|
||||
90% {
|
||||
-webkit-transform: translate3d(0,-1px,0);
|
||||
transform: translate3d(0,-1px,0);
|
||||
}
|
||||
}
|
||||
@@ -1784,6 +1831,7 @@ p.customize-section-description {
|
||||
background: #eee;
|
||||
border-color: #999;
|
||||
box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 );
|
||||
-webkit-transform: translateY(1px);
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
@@ -1812,6 +1860,17 @@ p.customize-section-description {
|
||||
}
|
||||
|
||||
/* Adds a delay before fading in to avoid it "jumping" */
|
||||
@-webkit-keyframes themes-fade-in {
|
||||
0% {
|
||||
opacity: 0;
|
||||
}
|
||||
50% {
|
||||
opacity: 0;
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
@keyframes themes-fade-in {
|
||||
0% {
|
||||
opacity: 0;
|
||||
@@ -1825,10 +1884,12 @@ p.customize-section-description {
|
||||
}
|
||||
|
||||
.control-panel-themes .customize-themes-full-container.animate {
|
||||
-webkit-animation: .6s themes-fade-in 1;
|
||||
animation: .6s themes-fade-in 1;
|
||||
}
|
||||
|
||||
.in-themes-panel:not(.animating) .control-panel-themes .filter-themes-count {
|
||||
-webkit-animation: .6s themes-fade-in 1;
|
||||
animation: .6s themes-fade-in 1;
|
||||
}
|
||||
|
||||
@@ -2514,6 +2575,7 @@ body.adding-widget .add-new-widget:hover,
|
||||
body.adding-widget .add-new-widget:before,
|
||||
.adding-menu-items .add-new-menu-item:before,
|
||||
#accordion-section-add_menu .add-new-menu-item.open:before {
|
||||
-webkit-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/customize-controls.min.css
vendored
@@ -203,7 +203,7 @@
|
||||
}
|
||||
|
||||
.welcome-panel .welcome-panel-column ul {
|
||||
margin: 0.8em 0 1em 1em;
|
||||
margin: 0.8em 0 1em 1em;
|
||||
}
|
||||
|
||||
.welcome-panel .welcome-panel-column li {
|
||||
|
||||
@@ -203,7 +203,7 @@
|
||||
}
|
||||
|
||||
.welcome-panel .welcome-panel-column ul {
|
||||
margin: 0.8em 1em 1em 0;
|
||||
margin: 0.8em 1em 1em 0;
|
||||
}
|
||||
|
||||
.welcome-panel .welcome-panel-column li {
|
||||
|
||||
@@ -1352,20 +1352,26 @@ table.links-table {
|
||||
.focus-on #adminmenuback,
|
||||
.focus-on #adminmenuwrap {
|
||||
transition-duration: 0.6s;
|
||||
transition-property: -webkit-transform;
|
||||
transition-property: transform;
|
||||
transition-property: transform, -webkit-transform;
|
||||
transition-timing-function: ease-in-out;
|
||||
}
|
||||
|
||||
.focus-on #adminmenuback,
|
||||
.focus-on #adminmenuwrap {
|
||||
-webkit-transform: translateX( 100% );
|
||||
transform: translateX( 100% );
|
||||
}
|
||||
|
||||
.focus-off #adminmenuback,
|
||||
.focus-off #adminmenuwrap {
|
||||
-webkit-transform: translateX( 0 );
|
||||
transform: translateX( 0 );
|
||||
transition-duration: 0.2s;
|
||||
transition-property: -webkit-transform;
|
||||
transition-property: transform;
|
||||
transition-property: transform, -webkit-transform;
|
||||
transition-timing-function: ease-in-out;
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/edit-rtl.min.css
vendored
@@ -1352,20 +1352,26 @@ table.links-table {
|
||||
.focus-on #adminmenuback,
|
||||
.focus-on #adminmenuwrap {
|
||||
transition-duration: 0.6s;
|
||||
transition-property: -webkit-transform;
|
||||
transition-property: transform;
|
||||
transition-property: transform, -webkit-transform;
|
||||
transition-timing-function: ease-in-out;
|
||||
}
|
||||
|
||||
.focus-on #adminmenuback,
|
||||
.focus-on #adminmenuwrap {
|
||||
-webkit-transform: translateX( -100% );
|
||||
transform: translateX( -100% );
|
||||
}
|
||||
|
||||
.focus-off #adminmenuback,
|
||||
.focus-off #adminmenuwrap {
|
||||
-webkit-transform: translateX( 0 );
|
||||
transform: translateX( 0 );
|
||||
transition-duration: 0.2s;
|
||||
transition-property: -webkit-transform;
|
||||
transition-property: transform;
|
||||
transition-property: transform, -webkit-transform;
|
||||
transition-timing-function: ease-in-out;
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/edit.min.css
vendored
@@ -834,11 +834,13 @@ table.form-table td .updated p {
|
||||
left: 10px;
|
||||
bottom: 9px;
|
||||
background: transparent;
|
||||
-webkit-transform: skew(-20deg) rotate(-6deg);
|
||||
transform: skew(-20deg) rotate(-6deg);
|
||||
box-shadow: 0 10px 8px rgba(0, 0, 0, 0.6);
|
||||
}
|
||||
|
||||
.pressthis-bookmarklet:hover:after {
|
||||
-webkit-transform: skew(-20deg) rotate(-9deg);
|
||||
transform: skew(-20deg) rotate(-9deg);
|
||||
box-shadow: 0 10px 8px rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
@@ -1202,6 +1204,7 @@ table.form-table td .updated p {
|
||||
.email-personal-data--sending::before {
|
||||
color: #f56e28;
|
||||
content: "\f463";
|
||||
-webkit-animation: rotation 2s infinite linear;
|
||||
animation: rotation 2s infinite linear;
|
||||
}
|
||||
|
||||
@@ -1566,11 +1569,24 @@ table.form-table td .updated p {
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rotation {
|
||||
@-webkit-keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(-359deg);
|
||||
transform: rotate(-359deg);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(-359deg);
|
||||
transform: rotate(-359deg);
|
||||
}
|
||||
}
|
||||
|
||||
2
wp-admin/css/forms-rtl.min.css
vendored
@@ -834,11 +834,13 @@ table.form-table td .updated p {
|
||||
right: 10px;
|
||||
bottom: 9px;
|
||||
background: transparent;
|
||||
-webkit-transform: skew(20deg) rotate(6deg);
|
||||
transform: skew(20deg) rotate(6deg);
|
||||
box-shadow: 0 10px 8px rgba(0, 0, 0, 0.6);
|
||||
}
|
||||
|
||||
.pressthis-bookmarklet:hover:after {
|
||||
-webkit-transform: skew(20deg) rotate(9deg);
|
||||
transform: skew(20deg) rotate(9deg);
|
||||
box-shadow: 0 10px 8px rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
@@ -1202,6 +1204,7 @@ table.form-table td .updated p {
|
||||
.email-personal-data--sending::before {
|
||||
color: #f56e28;
|
||||
content: "\f463";
|
||||
-webkit-animation: rotation 2s infinite linear;
|
||||
animation: rotation 2s infinite linear;
|
||||
}
|
||||
|
||||
@@ -1566,11 +1569,24 @@ table.form-table td .updated p {
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rotation {
|
||||
@-webkit-keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
|
||||
2
wp-admin/css/forms.min.css
vendored
@@ -1364,14 +1364,28 @@ ul.cat-checklist {
|
||||
|
||||
.plugin-card .updating-message:before {
|
||||
content: "\f463";
|
||||
-webkit-animation: rotation 2s infinite linear;
|
||||
animation: rotation 2s infinite linear;
|
||||
}
|
||||
|
||||
@-webkit-keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(-359deg);
|
||||
transform: rotate(-359deg);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(-359deg);
|
||||
transform: rotate(-359deg);
|
||||
}
|
||||
}
|
||||
|
||||
2
wp-admin/css/list-tables-rtl.min.css
vendored
@@ -1364,14 +1364,28 @@ ul.cat-checklist {
|
||||
|
||||
.plugin-card .updating-message:before {
|
||||
content: "\f463";
|
||||
-webkit-animation: rotation 2s infinite linear;
|
||||
animation: rotation 2s infinite linear;
|
||||
}
|
||||
|
||||
@-webkit-keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rotation {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
|
||||
2
wp-admin/css/list-tables.min.css
vendored
2
wp-admin/css/login-rtl.min.css
vendored
2
wp-admin/css/login.min.css
vendored
@@ -751,10 +751,6 @@ border color while dragging a file over the uploader drop area */
|
||||
background-size: 20px 20px;
|
||||
}
|
||||
|
||||
.edit-attachment-frame .attachment-media-view .details-image.icon {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.edit-attachment-frame .attachment-media-view .attachment-actions {
|
||||
text-align: center;
|
||||
}
|
||||
@@ -892,6 +888,7 @@ border color while dragging a file over the uploader drop area */
|
||||
margin: -10px -10px 0 0;
|
||||
background: transparent url(../images/spinner.gif) no-repeat center;
|
||||
background-size: 20px 20px;
|
||||
-webkit-transform: translateZ(0);
|
||||
transform: translateZ(0);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/media-rtl.min.css
vendored
@@ -751,10 +751,6 @@ border color while dragging a file over the uploader drop area */
|
||||
background-size: 20px 20px;
|
||||
}
|
||||
|
||||
.edit-attachment-frame .attachment-media-view .details-image.icon {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.edit-attachment-frame .attachment-media-view .attachment-actions {
|
||||
text-align: center;
|
||||
}
|
||||
@@ -892,6 +888,7 @@ border color while dragging a file over the uploader drop area */
|
||||
margin: -10px 0 0 -10px;
|
||||
background: transparent url(../images/spinner.gif) no-repeat center;
|
||||
background-size: 20px 20px;
|
||||
-webkit-transform: translateZ(0);
|
||||
transform: translateZ(0);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/media.min.css
vendored
@@ -355,6 +355,7 @@ table.diff .diff-addedline ins {
|
||||
top: -20px;
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
-webkit-transform: rotate(-45deg);
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
|
||||
@@ -416,6 +417,7 @@ table.diff .diff-addedline ins {
|
||||
top: -20px;
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
-webkit-transform: rotate(-45deg);
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
|
||||
@@ -471,6 +473,7 @@ div.revisions-controls > .wp-slider > .ui-slider-handle {
|
||||
background: #eee;
|
||||
border-color: #999;
|
||||
box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 );
|
||||
-webkit-transform: translateY(1px);
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/revisions-rtl.min.css
vendored
@@ -355,6 +355,7 @@ table.diff .diff-addedline ins {
|
||||
top: -20px;
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
-webkit-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
@@ -416,6 +417,7 @@ table.diff .diff-addedline ins {
|
||||
top: -20px;
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
-webkit-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
@@ -471,6 +473,7 @@ div.revisions-controls > .wp-slider > .ui-slider-handle {
|
||||
background: #eee;
|
||||
border-color: #999;
|
||||
box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 );
|
||||
-webkit-transform: translateY(1px);
|
||||
transform: translateY(1px);
|
||||
}
|
||||
|
||||
|
||||
2
wp-admin/css/revisions.min.css
vendored
@@ -230,6 +230,7 @@ body.js .theme-browser.search-loading {
|
||||
.theme-browser .theme .theme-actions {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
-webkit-transform: translateY(-50%);
|
||||
transform: translateY(-50%);
|
||||
left: 0;
|
||||
padding: 10px 15px;
|
||||
@@ -1238,6 +1239,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:first-child > label:first-child .dashicons {
|
||||
-webkit-transform: rotate( -45deg );
|
||||
transform: rotate( -45deg );
|
||||
}
|
||||
|
||||
@@ -1246,6 +1248,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:first-child > label:last-child .dashicons {
|
||||
-webkit-transform: rotate( 45deg );
|
||||
transform: rotate( 45deg );
|
||||
}
|
||||
|
||||
@@ -1254,6 +1257,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:last-child > label:first-child .dashicons {
|
||||
-webkit-transform: rotate( 45deg );
|
||||
transform: rotate( 45deg );
|
||||
}
|
||||
|
||||
@@ -1262,6 +1266,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:last-child > label:last-child .dashicons {
|
||||
-webkit-transform: rotate( -45deg );
|
||||
transform: rotate( -45deg );
|
||||
}
|
||||
|
||||
@@ -1558,10 +1563,12 @@ body.full-overlay-active {
|
||||
/* rtl:ignore */
|
||||
.wp-full-overlay.collapsed .collapse-sidebar-arrow:before,
|
||||
.rtl .wp-full-overlay .collapse-sidebar-arrow:before {
|
||||
-webkit-transform: rotate(180.001deg);
|
||||
transform: rotate(180.001deg); /* Firefox: promoting to its own layer to trigger anti-aliasing */
|
||||
}
|
||||
|
||||
.rtl .wp-full-overlay.collapsed .collapse-sidebar-arrow:before {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -1847,6 +1854,7 @@ body.full-overlay-active {
|
||||
top: 50%;
|
||||
z-index: -1;
|
||||
margin: -10px -10px 0 0;
|
||||
-webkit-transform: translateZ(0);
|
||||
transform: translateZ(0);
|
||||
background: transparent url(../images/spinner.gif) no-repeat center center;
|
||||
background-size: 20px 20px;
|
||||
|
||||
2
wp-admin/css/themes-rtl.min.css
vendored
@@ -230,6 +230,7 @@ body.js .theme-browser.search-loading {
|
||||
.theme-browser .theme .theme-actions {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
-webkit-transform: translateY(-50%);
|
||||
transform: translateY(-50%);
|
||||
right: 0;
|
||||
padding: 10px 15px;
|
||||
@@ -1238,6 +1239,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:first-child > label:first-child .dashicons {
|
||||
-webkit-transform: rotate( 45deg );
|
||||
transform: rotate( 45deg );
|
||||
}
|
||||
|
||||
@@ -1246,6 +1248,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:first-child > label:last-child .dashicons {
|
||||
-webkit-transform: rotate( -45deg );
|
||||
transform: rotate( -45deg );
|
||||
}
|
||||
|
||||
@@ -1254,6 +1257,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:last-child > label:first-child .dashicons {
|
||||
-webkit-transform: rotate( -45deg );
|
||||
transform: rotate( -45deg );
|
||||
}
|
||||
|
||||
@@ -1262,6 +1266,7 @@ div#custom-background-image img {
|
||||
}
|
||||
|
||||
.background-position-control .button-group:last-child > label:last-child .dashicons {
|
||||
-webkit-transform: rotate( 45deg );
|
||||
transform: rotate( 45deg );
|
||||
}
|
||||
|
||||
@@ -1558,10 +1563,12 @@ body.full-overlay-active {
|
||||
/* rtl:ignore */
|
||||
.wp-full-overlay.collapsed .collapse-sidebar-arrow:before,
|
||||
.rtl .wp-full-overlay .collapse-sidebar-arrow:before {
|
||||
-webkit-transform: rotate(180.001deg);
|
||||
transform: rotate(180.001deg); /* Firefox: promoting to its own layer to trigger anti-aliasing */
|
||||
}
|
||||
|
||||
.rtl .wp-full-overlay.collapsed .collapse-sidebar-arrow:before {
|
||||
-webkit-transform: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
@@ -1847,6 +1854,7 @@ body.full-overlay-active {
|
||||
top: 50%;
|
||||
z-index: -1;
|
||||
margin: -10px 0 0 -10px;
|
||||
-webkit-transform: translateZ(0);
|
||||
transform: translateZ(0);
|
||||
background: transparent url(../images/spinner.gif) no-repeat center center;
|
||||
background-size: 20px 20px;
|
||||
|
||||
2
wp-admin/css/themes.min.css
vendored
@@ -164,7 +164,9 @@
|
||||
}
|
||||
|
||||
.media-widget-gallery-preview {
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-pack: start;
|
||||
justify-content: flex-start;
|
||||
flex-wrap: wrap;
|
||||
margin: -1.79104477%;
|
||||
@@ -219,8 +221,11 @@
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-align: center;
|
||||
align-items: center;
|
||||
-webkit-box-pack: center;
|
||||
justify-content: center;
|
||||
background-color: rgba( 0, 0, 0, .5 );
|
||||
}
|
||||
|
||||
2
wp-admin/css/widgets-rtl.min.css
vendored
@@ -164,7 +164,9 @@
|
||||
}
|
||||
|
||||
.media-widget-gallery-preview {
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-pack: start;
|
||||
justify-content: flex-start;
|
||||
flex-wrap: wrap;
|
||||
margin: -1.79104477%;
|
||||
@@ -219,8 +221,11 @@
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: -webkit-box;
|
||||
display: flex;
|
||||
-webkit-box-align: center;
|
||||
align-items: center;
|
||||
-webkit-box-pack: center;
|
||||
justify-content: center;
|
||||
background-color: rgba( 0, 0, 0, .5 );
|
||||
}
|
||||
|
||||
2
wp-admin/css/widgets.min.css
vendored
@@ -225,7 +225,141 @@ $post_type_object = get_post_type_object($post_type);
|
||||
// All meta boxes should be defined and added before the first do_meta_boxes() call (or potentially during the do_meta_boxes action).
|
||||
require_once( ABSPATH . 'wp-admin/includes/meta-boxes.php' );
|
||||
|
||||
register_and_do_post_meta_boxes( $post );
|
||||
|
||||
$publish_callback_args = null;
|
||||
if ( post_type_supports($post_type, 'revisions') && 'auto-draft' != $post->post_status ) {
|
||||
$revisions = wp_get_post_revisions( $post_ID );
|
||||
|
||||
// We should aim to show the revisions meta box only when there are revisions.
|
||||
if ( count( $revisions ) > 1 ) {
|
||||
reset( $revisions ); // Reset pointer for key()
|
||||
$publish_callback_args = array( 'revisions_count' => count( $revisions ), 'revision_id' => key( $revisions ) );
|
||||
add_meta_box('revisionsdiv', __('Revisions'), 'post_revisions_meta_box', null, 'normal', 'core');
|
||||
}
|
||||
}
|
||||
|
||||
if ( 'attachment' == $post_type ) {
|
||||
wp_enqueue_script( 'image-edit' );
|
||||
wp_enqueue_style( 'imgareaselect' );
|
||||
add_meta_box( 'submitdiv', __('Save'), 'attachment_submit_meta_box', null, 'side', 'core' );
|
||||
add_action( 'edit_form_after_title', 'edit_form_image_editor' );
|
||||
|
||||
if ( wp_attachment_is( 'audio', $post ) ) {
|
||||
add_meta_box( 'attachment-id3', __( 'Metadata' ), 'attachment_id3_data_meta_box', null, 'normal', 'core' );
|
||||
}
|
||||
} else {
|
||||
add_meta_box( 'submitdiv', __( 'Publish' ), 'post_submit_meta_box', null, 'side', 'core', $publish_callback_args );
|
||||
}
|
||||
|
||||
if ( current_theme_supports( 'post-formats' ) && post_type_supports( $post_type, 'post-formats' ) )
|
||||
add_meta_box( 'formatdiv', _x( 'Format', 'post format' ), 'post_format_meta_box', null, 'side', 'core' );
|
||||
|
||||
// all taxonomies
|
||||
foreach ( get_object_taxonomies( $post ) as $tax_name ) {
|
||||
$taxonomy = get_taxonomy( $tax_name );
|
||||
if ( ! $taxonomy->show_ui || false === $taxonomy->meta_box_cb )
|
||||
continue;
|
||||
|
||||
$label = $taxonomy->labels->name;
|
||||
|
||||
if ( ! is_taxonomy_hierarchical( $tax_name ) )
|
||||
$tax_meta_box_id = 'tagsdiv-' . $tax_name;
|
||||
else
|
||||
$tax_meta_box_id = $tax_name . 'div';
|
||||
|
||||
add_meta_box( $tax_meta_box_id, $label, $taxonomy->meta_box_cb, null, 'side', 'core', array( 'taxonomy' => $tax_name ) );
|
||||
}
|
||||
|
||||
if ( post_type_supports( $post_type, 'page-attributes' ) || count( get_page_templates( $post ) ) > 0 ) {
|
||||
add_meta_box( 'pageparentdiv', $post_type_object->labels->attributes, 'page_attributes_meta_box', null, 'side', 'core' );
|
||||
}
|
||||
|
||||
if ( $thumbnail_support && current_user_can( 'upload_files' ) )
|
||||
add_meta_box('postimagediv', esc_html( $post_type_object->labels->featured_image ), 'post_thumbnail_meta_box', null, 'side', 'low');
|
||||
|
||||
if ( post_type_supports($post_type, 'excerpt') )
|
||||
add_meta_box('postexcerpt', __('Excerpt'), 'post_excerpt_meta_box', null, 'normal', 'core');
|
||||
|
||||
if ( post_type_supports($post_type, 'trackbacks') )
|
||||
add_meta_box('trackbacksdiv', __('Send Trackbacks'), 'post_trackback_meta_box', null, 'normal', 'core');
|
||||
|
||||
if ( post_type_supports($post_type, 'custom-fields') )
|
||||
add_meta_box('postcustom', __('Custom Fields'), 'post_custom_meta_box', null, 'normal', 'core');
|
||||
|
||||
/**
|
||||
* Fires in the middle of built-in meta box registration.
|
||||
*
|
||||
* @since 2.1.0
|
||||
* @deprecated 3.7.0 Use 'add_meta_boxes' instead.
|
||||
*
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( 'dbx_post_advanced', $post );
|
||||
|
||||
// Allow the Discussion meta box to show up if the post type supports comments,
|
||||
// or if comments or pings are open.
|
||||
if ( comments_open( $post ) || pings_open( $post ) || post_type_supports( $post_type, 'comments' ) ) {
|
||||
add_meta_box( 'commentstatusdiv', __( 'Discussion' ), 'post_comment_status_meta_box', null, 'normal', 'core' );
|
||||
}
|
||||
|
||||
$stati = get_post_stati( array( 'public' => true ) );
|
||||
if ( empty( $stati ) ) {
|
||||
$stati = array( 'publish' );
|
||||
}
|
||||
$stati[] = 'private';
|
||||
|
||||
if ( in_array( get_post_status( $post ), $stati ) ) {
|
||||
// If the post type support comments, or the post has comments, allow the
|
||||
// Comments meta box.
|
||||
if ( comments_open( $post ) || pings_open( $post ) || $post->comment_count > 0 || post_type_supports( $post_type, 'comments' ) ) {
|
||||
add_meta_box( 'commentsdiv', __( 'Comments' ), 'post_comment_meta_box', null, 'normal', 'core' );
|
||||
}
|
||||
}
|
||||
|
||||
if ( ! ( 'pending' == get_post_status( $post ) && ! current_user_can( $post_type_object->cap->publish_posts ) ) )
|
||||
add_meta_box('slugdiv', __('Slug'), 'post_slug_meta_box', null, 'normal', 'core');
|
||||
|
||||
if ( post_type_supports( $post_type, 'author' ) && current_user_can( $post_type_object->cap->edit_others_posts ) ) {
|
||||
add_meta_box( 'authordiv', __( 'Author' ), 'post_author_meta_box', null, 'normal', 'core' );
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires after all built-in meta boxes have been added.
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param string $post_type Post type.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( 'add_meta_boxes', $post_type, $post );
|
||||
|
||||
/**
|
||||
* Fires after all built-in meta boxes have been added, contextually for the given post type.
|
||||
*
|
||||
* The dynamic portion of the hook, `$post_type`, refers to the post type of the post.
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( "add_meta_boxes_{$post_type}", $post );
|
||||
|
||||
/**
|
||||
* Fires after meta boxes have been added.
|
||||
*
|
||||
* Fires once for each of the default meta box contexts: normal, advanced, and side.
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param string $post_type Post type of the post.
|
||||
* @param string $context string Meta box context.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( 'do_meta_boxes', $post_type, 'normal', $post );
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', $post_type, 'advanced', $post );
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', $post_type, 'side', $post );
|
||||
|
||||
add_screen_option('layout_columns', array('max' => 2, 'default' => 2) );
|
||||
|
||||
|
||||
@@ -1,430 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* The Block Editor page.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @package WordPress
|
||||
* @subpackage Administration
|
||||
*/
|
||||
|
||||
// don't load directly
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
die( '-1' );
|
||||
}
|
||||
|
||||
/**
|
||||
* @global string $post_type
|
||||
* @global WP_Post_Type $post_type_object
|
||||
* @global WP_Post $post
|
||||
* @global string $title
|
||||
* @global array $editor_styles
|
||||
* @global array $wp_meta_boxes
|
||||
*/
|
||||
global $post_type, $post_type_object, $post, $title, $editor_styles, $wp_meta_boxes;
|
||||
|
||||
// Flag that we're loading the block editor.
|
||||
$current_screen = get_current_screen();
|
||||
$current_screen->is_block_editor( true );
|
||||
|
||||
/*
|
||||
* Emoji replacement is disabled for now, until it plays nicely with React.
|
||||
*/
|
||||
remove_action( 'admin_print_scripts', 'print_emoji_detection_script' );
|
||||
|
||||
wp_enqueue_script( 'heartbeat' );
|
||||
wp_enqueue_script( 'wp-edit-post' );
|
||||
wp_enqueue_script( 'wp-format-library' );
|
||||
|
||||
$rest_base = ! empty( $post_type_object->rest_base ) ? $post_type_object->rest_base : $post_type_object->name;
|
||||
|
||||
// Preload common data.
|
||||
$preload_paths = array(
|
||||
'/',
|
||||
'/wp/v2/types?context=edit',
|
||||
'/wp/v2/taxonomies?per_page=-1&context=edit',
|
||||
'/wp/v2/themes?status=active',
|
||||
sprintf( '/wp/v2/%s/%s?context=edit', $rest_base, $post->ID ),
|
||||
sprintf( '/wp/v2/types/%s?context=edit', $post_type ),
|
||||
sprintf( '/wp/v2/users/me?post_type=%s&context=edit', $post_type ),
|
||||
array( '/wp/v2/media', 'OPTIONS' ),
|
||||
);
|
||||
|
||||
/**
|
||||
* Preload common data by specifying an array of REST API paths that will be preloaded.
|
||||
*
|
||||
* Filters the array of paths that will be preloaded.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param array $preload_paths Array of paths to preload.
|
||||
* @param object $post The post resource data.
|
||||
*/
|
||||
$preload_paths = apply_filters( 'block_editor_preload_paths', $preload_paths, $post );
|
||||
|
||||
/*
|
||||
* Ensure the global $post remains the same after API data is preloaded.
|
||||
* Because API preloading can call the_content and other filters, plugins
|
||||
* can unexpectedly modify $post.
|
||||
*/
|
||||
$backup_global_post = $post;
|
||||
|
||||
$preload_data = array_reduce(
|
||||
$preload_paths,
|
||||
'rest_preload_api_request',
|
||||
array()
|
||||
);
|
||||
|
||||
// Restore the global $post as it was before API preloading.
|
||||
$post = $backup_global_post;
|
||||
|
||||
wp_add_inline_script(
|
||||
'wp-api-fetch',
|
||||
sprintf( 'wp.apiFetch.use( wp.apiFetch.createPreloadingMiddleware( %s ) );', wp_json_encode( $preload_data ) ),
|
||||
'after'
|
||||
);
|
||||
|
||||
wp_add_inline_script(
|
||||
'wp-blocks',
|
||||
sprintf( 'wp.blocks.setCategories( %s );', wp_json_encode( get_block_categories( $post ) ) ),
|
||||
'after'
|
||||
);
|
||||
|
||||
/*
|
||||
* Assign initial edits, if applicable. These are not initially assigned to the persisted post,
|
||||
* but should be included in its save payload.
|
||||
*/
|
||||
$initial_edits = null;
|
||||
$is_new_post = false;
|
||||
if ( 'auto-draft' === $post->post_status ) {
|
||||
$is_new_post = true;
|
||||
// Override "(Auto Draft)" new post default title with empty string, or filtered value.
|
||||
$initial_edits = array(
|
||||
'title' => $post->post_title,
|
||||
'content' => $post->post_content,
|
||||
'excerpt' => $post->post_excerpt,
|
||||
);
|
||||
}
|
||||
|
||||
// Preload server-registered block schemas.
|
||||
wp_add_inline_script(
|
||||
'wp-blocks',
|
||||
'wp.blocks.unstable__bootstrapServerSideBlockDefinitions(' . wp_json_encode( get_block_editor_server_block_settings() ) . ');'
|
||||
);
|
||||
|
||||
// Get admin url for handling meta boxes.
|
||||
$meta_box_url = admin_url( 'post.php' );
|
||||
$meta_box_url = add_query_arg(
|
||||
array(
|
||||
'post' => $post->ID,
|
||||
'action' => 'edit',
|
||||
'meta-box-loader' => true,
|
||||
'_wpnonce' => wp_create_nonce( 'meta-box-loader' ),
|
||||
),
|
||||
$meta_box_url
|
||||
);
|
||||
wp_localize_script( 'wp-editor', '_wpMetaBoxUrl', $meta_box_url );
|
||||
|
||||
|
||||
/*
|
||||
* Initialize the editor.
|
||||
*/
|
||||
|
||||
$align_wide = get_theme_support( 'align-wide' );
|
||||
$color_palette = current( (array) get_theme_support( 'editor-color-palette' ) );
|
||||
$font_sizes = current( (array) get_theme_support( 'editor-font-sizes' ) );
|
||||
|
||||
/**
|
||||
* Filters the allowed block types for the editor, defaulting to true (all
|
||||
* block types supported).
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param bool|array $allowed_block_types Array of block type slugs, or
|
||||
* boolean to enable/disable all.
|
||||
* @param object $post The post resource data.
|
||||
*/
|
||||
$allowed_block_types = apply_filters( 'allowed_block_types', true, $post );
|
||||
|
||||
// Get all available templates for the post/page attributes meta-box.
|
||||
// The "Default template" array element should only be added if the array is
|
||||
// not empty so we do not trigger the template select element without any options
|
||||
// besides the default value.
|
||||
$available_templates = wp_get_theme()->get_page_templates( get_post( $post->ID ) );
|
||||
$available_templates = ! empty( $available_templates ) ? array_merge(
|
||||
array(
|
||||
/** This filter is documented in wp-admin/includes/meta-boxes.php */
|
||||
'' => apply_filters( 'default_page_template_title', __( 'Default template' ), 'rest-api' ),
|
||||
),
|
||||
$available_templates
|
||||
) : $available_templates;
|
||||
|
||||
// Media settings.
|
||||
$max_upload_size = wp_max_upload_size();
|
||||
if ( ! $max_upload_size ) {
|
||||
$max_upload_size = 0;
|
||||
}
|
||||
|
||||
// Editor Styles.
|
||||
$styles = array(
|
||||
array(
|
||||
'css' => file_get_contents(
|
||||
ABSPATH . WPINC . '/css/dist/editor/editor-styles.css'
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
/* Translators: Use this to specify the CSS font family for the default font */
|
||||
$locale_font_family = esc_html_x( 'Noto Serif', 'CSS Font Family for Editor Font' );
|
||||
$styles[] = array(
|
||||
'css' => "body { font-family: '$locale_font_family' }",
|
||||
);
|
||||
|
||||
if ( $editor_styles && current_theme_supports( 'editor-styles' ) ) {
|
||||
foreach ( $editor_styles as $style ) {
|
||||
if ( preg_match( '~^(https?:)?//~', $style ) ) {
|
||||
$response = wp_remote_get( $style );
|
||||
if ( ! is_wp_error( $response ) ) {
|
||||
$styles[] = array(
|
||||
'css' => wp_remote_retrieve_body( $response ),
|
||||
);
|
||||
}
|
||||
} else {
|
||||
$file = get_theme_file_path( $style );
|
||||
if ( file_exists( $file ) ) {
|
||||
$styles[] = array(
|
||||
'css' => file_get_contents( $file ),
|
||||
'baseURL' => get_theme_file_uri( $style ),
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Image sizes.
|
||||
|
||||
/** This filter is documented in wp-admin/includes/media.php */
|
||||
$image_size_names = apply_filters(
|
||||
'image_size_names_choose',
|
||||
array(
|
||||
'thumbnail' => __( 'Thumbnail' ),
|
||||
'medium' => __( 'Medium' ),
|
||||
'large' => __( 'Large' ),
|
||||
'full' => __( 'Full Size' ),
|
||||
)
|
||||
);
|
||||
|
||||
$available_image_sizes = array();
|
||||
foreach ( $image_size_names as $image_size_slug => $image_size_name ) {
|
||||
$available_image_sizes[] = array(
|
||||
'slug' => $image_size_slug,
|
||||
'name' => $image_size_name,
|
||||
);
|
||||
}
|
||||
|
||||
// Lock settings.
|
||||
$user_id = wp_check_post_lock( $post->ID );
|
||||
if ( $user_id ) {
|
||||
/** This filter is documented in wp-admin/includes/post.php */
|
||||
if ( apply_filters( 'show_post_locked_dialog', true, $post, $user_id ) ) {
|
||||
$locked = true;
|
||||
}
|
||||
|
||||
$user_details = null;
|
||||
if ( $locked ) {
|
||||
$user = get_userdata( $user_id );
|
||||
$user_details = array(
|
||||
'name' => $user->display_name,
|
||||
);
|
||||
$avatar = get_avatar_url( $user_id, array( 'size' => 64 ) );
|
||||
}
|
||||
|
||||
$lock_details = array(
|
||||
'isLocked' => $locked,
|
||||
'user' => $user_details,
|
||||
);
|
||||
} else {
|
||||
// Lock the post.
|
||||
$active_post_lock = wp_set_post_lock( $post->ID );
|
||||
$lock_details = array(
|
||||
'isLocked' => false,
|
||||
'activePostLock' => esc_attr( implode( ':', $active_post_lock ) ),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filters the body placeholder text.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param string $text Placeholder text. Default 'Start writing or type / to choose a block'.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
$body_placeholder = apply_filters( 'write_your_story', __( 'Start writing or type / to choose a block' ), $post );
|
||||
|
||||
$editor_settings = array(
|
||||
'alignWide' => $align_wide,
|
||||
'availableTemplates' => $available_templates,
|
||||
'allowedBlockTypes' => $allowed_block_types,
|
||||
'disableCustomColors' => get_theme_support( 'disable-custom-colors' ),
|
||||
'disableCustomFontSizes' => get_theme_support( 'disable-custom-font-sizes' ),
|
||||
'disablePostFormats' => ! current_theme_supports( 'post-formats' ),
|
||||
/** This filter is documented in wp-admin/edit-form-advanced.php */
|
||||
'titlePlaceholder' => apply_filters( 'enter_title_here', __( 'Add title' ), $post ),
|
||||
'bodyPlaceholder' => $body_placeholder,
|
||||
'isRTL' => is_rtl(),
|
||||
'autosaveInterval' => 10,
|
||||
'maxUploadFileSize' => $max_upload_size,
|
||||
'allowedMimeTypes' => get_allowed_mime_types(),
|
||||
'styles' => $styles,
|
||||
'imageSizes' => $available_image_sizes,
|
||||
'richEditingEnabled' => user_can_richedit(),
|
||||
'postLock' => $lock_details,
|
||||
'postLockUtils' => array(
|
||||
'nonce' => wp_create_nonce( 'lock-post_' . $post->ID ),
|
||||
'unlockNonce' => wp_create_nonce( 'update-post_' . $post->ID ),
|
||||
'ajaxUrl' => admin_url( 'admin-ajax.php' ),
|
||||
),
|
||||
|
||||
// Whether or not to load the 'postcustom' meta box is stored as a user meta
|
||||
// field so that we're not always loading its assets.
|
||||
'enableCustomFields' => (bool) get_user_meta( get_current_user_id(), 'enable_custom_fields', true ),
|
||||
);
|
||||
|
||||
$autosave = wp_get_post_autosave( $post_ID );
|
||||
if ( $autosave ) {
|
||||
if ( mysql2date( 'U', $autosave->post_modified_gmt, false ) > mysql2date( 'U', $post->post_modified_gmt, false ) ) {
|
||||
$editor_settings['autosave'] = array(
|
||||
'editLink' => get_edit_post_link( $autosave->ID ),
|
||||
);
|
||||
} else {
|
||||
wp_delete_post_revision( $autosave->ID );
|
||||
}
|
||||
}
|
||||
|
||||
if ( false !== $color_palette ) {
|
||||
$editor_settings['colors'] = $color_palette;
|
||||
}
|
||||
|
||||
if ( ! empty( $font_sizes ) ) {
|
||||
$editor_settings['fontSizes'] = $font_sizes;
|
||||
}
|
||||
|
||||
if ( ! empty( $post_type_object->template ) ) {
|
||||
$editor_settings['template'] = $post_type_object->template;
|
||||
$editor_settings['templateLock'] = ! empty( $post_type_object->template_lock ) ? $post_type_object->template_lock : false;
|
||||
}
|
||||
|
||||
// If there's no template set on a new post, use the post format, instead.
|
||||
if ( $is_new_post && ! isset( $editor_settings['template'] ) && 'post' === $post->post_type ) {
|
||||
$post_format = get_post_format( $post );
|
||||
if ( in_array( $post_format, array( 'audio', 'gallery', 'image', 'quote', 'video' ), true ) ) {
|
||||
$editor_settings['template'] = array( array( "core/$post_format" ) );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Scripts
|
||||
*/
|
||||
wp_enqueue_media(
|
||||
array(
|
||||
'post' => $post->ID,
|
||||
)
|
||||
);
|
||||
wp_tinymce_inline_scripts();
|
||||
wp_enqueue_editor();
|
||||
|
||||
/**
|
||||
* Styles
|
||||
*/
|
||||
wp_enqueue_style( 'wp-edit-post' );
|
||||
wp_enqueue_style( 'wp-format-library' );
|
||||
|
||||
/**
|
||||
* Fires after block assets have been enqueued for the editing interface.
|
||||
*
|
||||
* Call `add_action` on any hook before 'admin_enqueue_scripts'.
|
||||
*
|
||||
* In the function call you supply, simply use `wp_enqueue_script` and
|
||||
* `wp_enqueue_style` to add your functionality to the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*/
|
||||
do_action( 'enqueue_block_editor_assets' );
|
||||
|
||||
// In order to duplicate classic meta box behaviour, we need to run the classic meta box actions.
|
||||
require_once( ABSPATH . 'wp-admin/includes/meta-boxes.php' );
|
||||
register_and_do_post_meta_boxes( $post );
|
||||
|
||||
// Check if the Custom Fields meta box has been removed at some point.
|
||||
$core_meta_boxes = $wp_meta_boxes[ $current_screen->id ]['normal']['core'];
|
||||
if ( ! isset( $core_meta_boxes['postcustom'] ) || ! $core_meta_boxes['postcustom'] ) {
|
||||
unset( $editor_settings['enableCustomFields'] );
|
||||
}
|
||||
|
||||
/**
|
||||
* Filters the settings to pass to the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param array $editor_settings Default editor settings.
|
||||
* @param WP_Post $post Post being edited.
|
||||
*/
|
||||
$editor_settings = apply_filters( 'block_editor_settings', $editor_settings, $post );
|
||||
|
||||
$init_script = <<<JS
|
||||
( function() {
|
||||
window._wpLoadBlockEditor = new Promise( function( resolve ) {
|
||||
wp.domReady( function() {
|
||||
resolve( wp.editPost.initializeEditor( 'editor', "%s", %d, %s, %s ) );
|
||||
} );
|
||||
} );
|
||||
} )();
|
||||
JS;
|
||||
|
||||
$script = sprintf(
|
||||
$init_script,
|
||||
$post->post_type,
|
||||
$post->ID,
|
||||
wp_json_encode( $editor_settings ),
|
||||
wp_json_encode( $initial_edits )
|
||||
);
|
||||
wp_add_inline_script( 'wp-edit-post', $script );
|
||||
|
||||
require_once( ABSPATH . 'wp-admin/admin-header.php' );
|
||||
?>
|
||||
|
||||
<div class="block-editor">
|
||||
<h1 class="screen-reader-text hide-if-no-js"><?php echo esc_html( $title ); ?></h1>
|
||||
<div id="editor" class="block-editor__container hide-if-no-js"></div>
|
||||
<div id="metaboxes" class="hidden">
|
||||
<?php the_block_editor_meta_boxes(); ?>
|
||||
</div>
|
||||
|
||||
<?php // JavaScript is disabled. ?>
|
||||
<div class="wrap hide-if-js block-editor-no-js">
|
||||
<h1 class="wp-heading-inline"><?php echo esc_html( $title ); ?></h1>
|
||||
<div class="notice notice-error notice-alt">
|
||||
<p>
|
||||
<?php
|
||||
$message = sprintf(
|
||||
/* translators: %s: https://wordpress.org/plugins/classic-editor/ */
|
||||
__( 'The block editor requires JavaScript. Please enable JavaScript in your browser settings, or try the <a href="%s">Classic Editor plugin</a>.' ),
|
||||
__( 'https://wordpress.org/plugins/classic-editor/' )
|
||||
);
|
||||
|
||||
/**
|
||||
* Filters the message displayed in the block editor interface when JavaScript is
|
||||
* not enabled in the browser.
|
||||
*
|
||||
* @since 5.0.3
|
||||
*
|
||||
* @param string $message The message being displayed.
|
||||
* @param WP_Post $post The post being edited.
|
||||
*/
|
||||
echo apply_filters( 'block_editor_no_javascript_message', $message, $post );
|
||||
?>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -177,7 +177,7 @@ endif; ?>
|
||||
|
||||
<div id="postbox-container-2" class="postbox-container">
|
||||
<?php
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'add_meta_boxes', 'comment', $comment );
|
||||
|
||||
/**
|
||||
|
||||
@@ -30,7 +30,7 @@ add_meta_box('linktargetdiv', __('Target'), 'link_target_meta_box', null, 'norma
|
||||
add_meta_box('linkxfndiv', __('Link Relationship (XFN)'), 'link_xfn_meta_box', null, 'normal', 'core');
|
||||
add_meta_box('linkadvanceddiv', __('Advanced'), 'link_advanced_meta_box', null, 'normal', 'core');
|
||||
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'add_meta_boxes', 'link', $link );
|
||||
|
||||
/**
|
||||
@@ -42,11 +42,11 @@ do_action( 'add_meta_boxes', 'link', $link );
|
||||
*/
|
||||
do_action( 'add_meta_boxes_link', $link );
|
||||
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', 'link', 'normal', $link );
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', 'link', 'advanced', $link );
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', 'link', 'side', $link );
|
||||
|
||||
add_screen_option('layout_columns', array('max' => 2, 'default' => 2) );
|
||||
|
||||
@@ -182,11 +182,6 @@ $wp_list_table->prepare_items();
|
||||
wp_enqueue_script('inline-edit-post');
|
||||
wp_enqueue_script('heartbeat');
|
||||
|
||||
if ( 'wp_block' === $post_type ) {
|
||||
wp_enqueue_script( 'wp-list-reusable-blocks' );
|
||||
wp_enqueue_style( 'wp-list-reusable-blocks' );
|
||||
}
|
||||
|
||||
$title = $post_type_object->labels->name;
|
||||
|
||||
if ( 'post' == $post_type ) {
|
||||
@@ -290,13 +285,6 @@ $bulk_messages['page'] = array(
|
||||
'trashed' => _n( '%s page moved to the Trash.', '%s pages moved to the Trash.', $bulk_counts['trashed'] ),
|
||||
'untrashed' => _n( '%s page restored from the Trash.', '%s pages restored from the Trash.', $bulk_counts['untrashed'] ),
|
||||
);
|
||||
$bulk_messages['wp_block'] = array(
|
||||
'updated' => _n( '%s block updated.', '%s blocks updated.', $bulk_counts['updated'] ),
|
||||
'locked' => ( 1 == $bulk_counts['locked'] ) ? __( '1 block not updated, somebody is editing it.' ) : _n( '%s block not updated, somebody is editing it.', '%s blocks not updated, somebody is editing them.', $bulk_counts['locked'] ),
|
||||
'deleted' => _n( '%s block permanently deleted.', '%s blocks permanently deleted.', $bulk_counts['deleted'] ),
|
||||
'trashed' => _n( '%s block moved to the Trash.', '%s blocks moved to the Trash.', $bulk_counts['trashed'] ),
|
||||
'untrashed' => _n( '%s block restored from the Trash.', '%s blocks restored from the Trash.', $bulk_counts['untrashed'] ),
|
||||
);
|
||||
|
||||
/**
|
||||
* Filters the bulk action updated messages.
|
||||
|
||||
@@ -22,7 +22,7 @@ $is_privacy_notice = isset( $_GET['privacy-notice'] );
|
||||
|
||||
<h1><?php printf( __( 'Welcome to WordPress %s' ), $display_version ); ?></h1>
|
||||
|
||||
<p class="about-text"><?php printf( __( 'Thank you for updating to the latest version! WordPress %s introduces a robust new content creation experience.' ), $display_version ); ?></p>
|
||||
<p class="about-text"><?php printf( __( 'Thank you for updating to the latest version! WordPress %s will smooth your design workflow and keep you safe from coding errors.' ), $display_version ); ?></p>
|
||||
|
||||
<div class="wp-badge"><?php printf( __( 'Version %s' ), $display_version ); ?></div>
|
||||
|
||||
@@ -45,50 +45,25 @@ $is_privacy_notice = isset( $_GET['privacy-notice'] );
|
||||
|
||||
<?php else : ?>
|
||||
<div class="about-wrap-content">
|
||||
<div class="feature-section one-col">
|
||||
<div class="col">
|
||||
<h2><?php _e( 'Freedoms' ); ?></h2>
|
||||
<p class="about-description"><?php printf( __( 'WordPress is Free and open source software, built by a distributed community of mostly volunteer developers from around the world. WordPress comes with some awesome, worldview-changing rights courtesy of its <a href="%s">license</a>, the GPL.' ), 'https://wordpress.org/about/license/' ); ?></p>
|
||||
</div>
|
||||
</div>
|
||||
<p class="about-description"><?php printf( __( 'WordPress is Free and open source software, built by a distributed community of mostly volunteer developers from around the world. WordPress comes with some awesome, worldview-changing rights courtesy of its <a href="%s">license</a>, the GPL.' ), 'https://wordpress.org/about/license/' ); ?></p>
|
||||
|
||||
<div class="feature-section four-col">
|
||||
<div class="col">
|
||||
<div class="freedoms-image"></div>
|
||||
<h3><?php _e( 'The 1st Freedom' ); ?></h3>
|
||||
<p><?php _e( 'To run the program for any purpose.' ); ?></p>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="freedoms-image"></div>
|
||||
<h3><?php _e( 'The 2nd Freedom' ); ?></h3>
|
||||
<p><?php _e( 'To study how the program works and change it to make it do what you wish.' ); ?></p>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="freedoms-image"></div>
|
||||
<h3><?php _e( 'The 3rd Freedom' ); ?></h3>
|
||||
<p><?php _e( 'To redistribute.' ); ?></p>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="freedoms-image"></div>
|
||||
<h3><?php _e( 'The 4th Freedom' ); ?></h3>
|
||||
<p><?php _e( 'To distribute copies of your modified versions to others.' ); ?></p>
|
||||
</div>
|
||||
</div>
|
||||
<ol start="0">
|
||||
<li><p><?php _e( 'You have the freedom to run the program, for any purpose.' ); ?></p></li>
|
||||
<li><p><?php _e( 'You have access to the source code, the freedom to study how the program works, and the freedom to change it to make it do what you wish.' ); ?></p></li>
|
||||
<li><p><?php _e( 'You have the freedom to redistribute copies of the original program so you can help your neighbor.' ); ?></p></li>
|
||||
<li><p><?php _e( 'You have the freedom to distribute copies of your modified versions to others. By doing this you can give the whole community a chance to benefit from your changes.' ); ?></p></li>
|
||||
</ol>
|
||||
|
||||
<div class="feature-section one-col">
|
||||
<div class="col">
|
||||
<p><?php printf( __( 'WordPress grows when people like you tell their friends about it, and the thousands of businesses and services that are built on and around WordPress share that fact with their users. We’re flattered every time someone spreads the good word, just make sure to <a href="%s">check out our trademark guidelines</a> first.' ), 'https://wordpressfoundation.org/trademark-policy/' ); ?></p>
|
||||
<p><?php printf( __( 'WordPress grows when people like you tell their friends about it, and the thousands of businesses and services that are built on and around WordPress share that fact with their users. We’re flattered every time someone spreads the good word, just make sure to <a href="%s">check out our trademark guidelines</a> first.' ), 'https://wordpressfoundation.org/trademark-policy/' ); ?></p>
|
||||
|
||||
<p><?php
|
||||
<p><?php
|
||||
|
||||
$plugins_url = current_user_can( 'activate_plugins' ) ? admin_url( 'plugins.php' ) : __( 'https://wordpress.org/plugins/' );
|
||||
$themes_url = current_user_can( 'switch_themes' ) ? admin_url( 'themes.php' ) : __( 'https://wordpress.org/themes/' );
|
||||
$plugins_url = current_user_can( 'activate_plugins' ) ? admin_url( 'plugins.php' ) : __( 'https://wordpress.org/plugins/' );
|
||||
$themes_url = current_user_can( 'switch_themes' ) ? admin_url( 'themes.php' ) : __( 'https://wordpress.org/themes/' );
|
||||
|
||||
printf( __( 'Every plugin and theme in WordPress.org’s directory is 100%% GPL or a similarly free and compatible license, so you can feel safe finding <a href="%1$s">plugins</a> and <a href="%2$s">themes</a> there. If you get a plugin or theme from another source, make sure to <a href="%3$s">ask them if it’s GPL</a> first. If they don’t respect the WordPress license, we don’t recommend them.' ), $plugins_url, $themes_url, 'https://wordpress.org/about/license/' ); ?></p>
|
||||
printf( __( 'Every plugin and theme in WordPress.org’s directory is 100%% GPL or a similarly free and compatible license, so you can feel safe finding <a href="%1$s">plugins</a> and <a href="%2$s">themes</a> there. If you get a plugin or theme from another source, make sure to <a href="%3$s">ask them if it’s GPL</a> first. If they don’t respect the WordPress license, we don’t recommend them.' ), $plugins_url, $themes_url, 'https://wordpress.org/about/license/' ); ?></p>
|
||||
|
||||
<p><?php _e( 'Don’t you wish all software came with these freedoms? So do we! For more information, check out the <a href="https://www.fsf.org/">Free Software Foundation</a>.' ); ?></p>
|
||||
</div>
|
||||
</div>
|
||||
<p><?php _e( 'Don’t you wish all software came with these freedoms? So do we! For more information, check out the <a href="https://www.fsf.org/">Free Software Foundation</a>.' ); ?></p>
|
||||
</div>
|
||||
|
||||
<?php endif; ?>
|
||||
|
||||
|
Before Width: | Height: | Size: 424 B After Width: | Height: | Size: 507 B |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 2.2 KiB |
|
Before Width: | Height: | Size: 151 B After Width: | Height: | Size: 234 B |
|
Before Width: | Height: | Size: 150 B After Width: | Height: | Size: 233 B |
|
Before Width: | Height: | Size: 70 B After Width: | Height: | Size: 149 B |
|
Before Width: | Height: | Size: 64 B After Width: | Height: | Size: 70 B |
|
Before Width: | Height: | Size: 7.4 KiB After Width: | Height: | Size: 8.3 KiB |
|
Before Width: | Height: | Size: 3.6 KiB After Width: | Height: | Size: 4.1 KiB |
|
Before Width: | Height: | Size: 8.7 KiB After Width: | Height: | Size: 8.9 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.2 KiB |
@@ -68,11 +68,9 @@ add_action( 'update_option_new_admin_email', 'update_option_new_admin_email', 10
|
||||
|
||||
add_filter( 'heartbeat_received', 'wp_check_locked_posts', 10, 3 );
|
||||
add_filter( 'heartbeat_received', 'wp_refresh_post_lock', 10, 3 );
|
||||
add_filter( 'wp_refresh_nonces', 'wp_refresh_post_nonces', 10, 3 );
|
||||
add_filter( 'heartbeat_received', 'heartbeat_autosave', 500, 2 );
|
||||
|
||||
add_filter( 'wp_refresh_nonces', 'wp_refresh_post_nonces', 10, 3 );
|
||||
add_filter( 'wp_refresh_nonces', 'wp_refresh_heartbeat_nonces' );
|
||||
|
||||
add_filter( 'heartbeat_settings', 'wp_heartbeat_set_suspension' );
|
||||
|
||||
// Nav Menu hooks.
|
||||
@@ -146,7 +144,7 @@ add_action( 'wp_privacy_personal_data_erased', '_wp_privacy_send_erasure_fulfill
|
||||
add_action( 'admin_init', array( 'WP_Privacy_Policy_Content', 'text_change_check' ), 100 );
|
||||
|
||||
// Show a "postbox" with the text suggestions for a privacy policy.
|
||||
add_action( 'admin_notices', array( 'WP_Privacy_Policy_Content', 'notice' ) );
|
||||
add_action( 'edit_form_after_title', array( 'WP_Privacy_Policy_Content', 'notice' ) );
|
||||
|
||||
// Add the suggested policy text from WordPress.
|
||||
add_action( 'admin_init', array( 'WP_Privacy_Policy_Content', 'add_suggested_content' ), 1 );
|
||||
|
||||
@@ -1343,6 +1343,8 @@ function wp_ajax_add_meta() {
|
||||
$value = wp_unslash( $_POST['meta'][$mid]['value'] );
|
||||
if ( '' == trim($key) )
|
||||
wp_die( __( 'Please provide a custom field name.' ) );
|
||||
if ( '' == trim($value) )
|
||||
wp_die( __( 'Please provide a custom field value.' ) );
|
||||
if ( ! $meta = get_metadata_by_mid( 'post', $mid ) )
|
||||
wp_die( 0 ); // if meta doesn't exist
|
||||
if ( is_protected_meta( $meta->meta_key, 'post' ) || is_protected_meta( $key, 'post' ) ||
|
||||
@@ -2257,6 +2259,10 @@ function wp_ajax_set_attachment_thumbnail() {
|
||||
wp_send_json_error();
|
||||
}
|
||||
|
||||
if ( false === check_ajax_referer( 'set-attachment-thumbnail', '_ajax_nonce', false ) ) {
|
||||
wp_send_json_error();
|
||||
}
|
||||
|
||||
$post_ids = array();
|
||||
// For each URL, try to find its corresponding post ID.
|
||||
foreach ( $_POST['urls'] as $url ) {
|
||||
@@ -2469,7 +2475,7 @@ function wp_ajax_query_attachments() {
|
||||
|
||||
// Filter query clauses to include filenames.
|
||||
if ( isset( $query['s'] ) ) {
|
||||
add_filter( 'posts_clauses', '_filter_query_attachment_filenames' );
|
||||
add_filter( 'wp_allow_query_attachment_by_filename', '__return_true' );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -524,7 +524,7 @@ class ftp_base {
|
||||
return $exists;
|
||||
}
|
||||
|
||||
function fget($fp, $remotefile, $rest=0) {
|
||||
function fget($fp, $remotefile,$rest=0) {
|
||||
if($this->_can_restore and $rest!=0) fseek($fp, $rest);
|
||||
$pi=pathinfo($remotefile);
|
||||
if($this->_type==FTP_ASCII or ($this->_type==FTP_AUTOASCII and in_array(strtoupper($pi["extension"]), $this->AutoAsciiExt))) $mode=FTP_ASCII;
|
||||
@@ -583,7 +583,7 @@ class ftp_base {
|
||||
return $out;
|
||||
}
|
||||
|
||||
function fput($remotefile, $fp, $rest=0) {
|
||||
function fput($remotefile, $fp) {
|
||||
if($this->_can_restore and $rest!=0) fseek($fp, $rest);
|
||||
$pi=pathinfo($remotefile);
|
||||
if($this->_type==FTP_ASCII or ($this->_type==FTP_AUTOASCII and in_array(strtoupper($pi["extension"]), $this->AutoAsciiExt))) $mode=FTP_ASCII;
|
||||
@@ -775,7 +775,7 @@ class ftp_base {
|
||||
$pattern=substr($pattern,$lastpos);
|
||||
} else $path=getcwd();
|
||||
if(is_array($handle) and !empty($handle)) {
|
||||
foreach($handle as $dir) {
|
||||
while($dir=each($handle)) {
|
||||
if($this->glob_pattern_match($pattern,$dir))
|
||||
$output[]=$dir;
|
||||
}
|
||||
|
||||
@@ -190,11 +190,7 @@ class WP_Plugin_Install_List_Table extends WP_List_Table {
|
||||
$action = 'save_wporg_username_' . get_current_user_id();
|
||||
if ( isset( $_GET['_wpnonce'] ) && wp_verify_nonce( wp_unslash( $_GET['_wpnonce'] ), $action ) ) {
|
||||
$user = isset( $_GET['user'] ) ? wp_unslash( $_GET['user'] ) : get_user_option( 'wporg_favorites' );
|
||||
|
||||
// If the save url parameter is passed with a falsey value, don't save the favorite user.
|
||||
if ( ! isset( $_GET['save'] ) || $_GET['save'] ) {
|
||||
update_user_meta( get_current_user_id(), 'wporg_favorites', $user );
|
||||
}
|
||||
update_user_meta( get_current_user_id(), 'wporg_favorites', $user );
|
||||
} else {
|
||||
$user = get_user_option( 'wporg_favorites' );
|
||||
}
|
||||
|
||||
@@ -1237,15 +1237,12 @@ class WP_Posts_List_Table extends WP_List_Table {
|
||||
esc_attr( sprintf( __( 'Edit “%s”' ), $title ) ),
|
||||
__( 'Edit' )
|
||||
);
|
||||
|
||||
if ( 'wp_block' !== $post->post_type ) {
|
||||
$actions['inline hide-if-no-js'] = sprintf(
|
||||
'<a href="#" class="editinline" aria-label="%s">%s</a>',
|
||||
/* translators: %s: post title */
|
||||
esc_attr( sprintf( __( 'Quick edit “%s” inline' ), $title ) ),
|
||||
__( 'Quick Edit' )
|
||||
);
|
||||
}
|
||||
$actions['inline hide-if-no-js'] = sprintf(
|
||||
'<a href="#" class="editinline" aria-label="%s">%s</a>',
|
||||
/* translators: %s: post title */
|
||||
esc_attr( sprintf( __( 'Quick edit “%s” inline' ), $title ) ),
|
||||
__( 'Quick Edit' )
|
||||
);
|
||||
}
|
||||
|
||||
if ( current_user_can( 'delete_post', $post->ID ) ) {
|
||||
@@ -1300,16 +1297,6 @@ class WP_Posts_List_Table extends WP_List_Table {
|
||||
}
|
||||
}
|
||||
|
||||
if ( 'wp_block' === $post->post_type ) {
|
||||
$actions['export'] = sprintf(
|
||||
'<button type="button" class="wp-list-reusable-blocks__export button-link" data-id="%s" aria-label="%s">%s</button>',
|
||||
$post->ID,
|
||||
/* translators: %s: post title */
|
||||
esc_attr( sprintf( __( 'Export “%s” as JSON' ), $title ) ),
|
||||
__( 'Export as JSON' )
|
||||
);
|
||||
}
|
||||
|
||||
if ( is_post_type_hierarchical( $post->post_type ) ) {
|
||||
|
||||
/**
|
||||
@@ -1426,18 +1413,13 @@ class WP_Posts_List_Table extends WP_List_Table {
|
||||
<span class="input-text-wrap"><input type="text" name="post_title" class="ptitle" value="" /></span>
|
||||
</label>
|
||||
|
||||
<?php if ( is_post_type_viewable( $screen->post_type ) ) : // is_post_type_viewable check ?>
|
||||
|
||||
<label>
|
||||
<span class="title"><?php _e( 'Slug' ); ?></span>
|
||||
<span class="input-text-wrap"><input type="text" name="post_name" value="" /></span>
|
||||
</label>
|
||||
|
||||
<?php
|
||||
endif; // is_post_type_viewable check
|
||||
endif; // $bulk
|
||||
endif; // post_type_supports title
|
||||
?>
|
||||
<?php endif; // $bulk
|
||||
endif; // post_type_supports title ?>
|
||||
|
||||
<?php if ( !$bulk ) : ?>
|
||||
<fieldset class="inline-edit-date">
|
||||
|
||||
@@ -181,14 +181,6 @@ final class WP_Screen {
|
||||
*/
|
||||
private $_screen_settings;
|
||||
|
||||
/**
|
||||
* Whether the screen is using the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
* @var bool
|
||||
*/
|
||||
public $is_block_editor = false;
|
||||
|
||||
/**
|
||||
* Fetches a screen object.
|
||||
*
|
||||
@@ -409,22 +401,6 @@ final class WP_Screen {
|
||||
return ( $admin == $this->in_admin );
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets or returns whether the block editor is loading on the current screen.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param bool $set Optional. Sets whether the block editor is loading on the current screen or not.
|
||||
* @return bool True if the block editor is being loaded, false otherwise.
|
||||
*/
|
||||
public function is_block_editor( $set = null ) {
|
||||
if ( $set !== null ) {
|
||||
$this->is_block_editor = (bool) $set;
|
||||
}
|
||||
|
||||
return $this->is_block_editor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the old string-based contextual help for the screen for backward compatibility.
|
||||
*
|
||||
|
||||
@@ -230,15 +230,15 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
|
||||
* @param object $theme {
|
||||
* An object that contains theme data returned by the WordPress.org API.
|
||||
*
|
||||
* @type string $name Theme name, e.g. 'Twenty Nineteen'.
|
||||
* @type string $slug Theme slug, e.g. 'twentynineteen'.
|
||||
* @type string $name Theme name, e.g. 'Twenty Seventeen'.
|
||||
* @type string $slug Theme slug, e.g. 'twentyseventeen'.
|
||||
* @type string $version Theme version, e.g. '1.1'.
|
||||
* @type string $author Theme author username, e.g. 'melchoyce'.
|
||||
* @type string $preview_url Preview URL, e.g. 'http://2019.wordpress.net/'.
|
||||
* @type string $screenshot_url Screenshot URL, e.g. 'https://wordpress.org/themes/twentynineteen/'.
|
||||
* @type string $preview_url Preview URL, e.g. 'http://2017.wordpress.net/'.
|
||||
* @type string $screenshot_url Screenshot URL, e.g. 'https://wordpress.org/themes/twentyseventeen/'.
|
||||
* @type float $rating Rating score.
|
||||
* @type int $num_ratings The number of ratings.
|
||||
* @type string $homepage Theme homepage, e.g. 'https://wordpress.org/themes/twentynineteen/'.
|
||||
* @type string $homepage Theme homepage, e.g. 'https://wordpress.org/themes/twentyseventeen/'.
|
||||
* @type string $description Theme description.
|
||||
* @type string $download_link Theme ZIP download URL.
|
||||
* }
|
||||
|
||||
@@ -122,10 +122,10 @@ function wp_dashboard_setup() {
|
||||
exit;
|
||||
}
|
||||
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', $screen->id, 'normal', '' );
|
||||
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
/** This action is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'do_meta_boxes', $screen->id, 'side', '' );
|
||||
}
|
||||
|
||||
|
||||
@@ -343,7 +343,7 @@ function wp_read_image_metadata( $file ) {
|
||||
if ( ! file_exists( $file ) )
|
||||
return false;
|
||||
|
||||
list( , , $image_type ) = @getimagesize( $file );
|
||||
list( , , $sourceImageType ) = @getimagesize( $file );
|
||||
|
||||
/*
|
||||
* EXIF contains a bunch of data we'll probably never need formatted in ways
|
||||
@@ -420,8 +420,6 @@ function wp_read_image_metadata( $file ) {
|
||||
}
|
||||
}
|
||||
|
||||
$exif = array();
|
||||
|
||||
/**
|
||||
* Filters the image types to check for exif data.
|
||||
*
|
||||
@@ -429,9 +427,7 @@ function wp_read_image_metadata( $file ) {
|
||||
*
|
||||
* @param array $image_types Image types to check for exif data.
|
||||
*/
|
||||
$exif_image_types = apply_filters( 'wp_read_image_metadata_types', array( IMAGETYPE_JPEG, IMAGETYPE_TIFF_II, IMAGETYPE_TIFF_MM ) );
|
||||
|
||||
if ( is_callable( 'exif_read_data' ) && in_array( $image_type, $exif_image_types ) ) {
|
||||
if ( is_callable( 'exif_read_data' ) && in_array( $sourceImageType, apply_filters( 'wp_read_image_metadata_types', array( IMAGETYPE_JPEG, IMAGETYPE_TIFF_II, IMAGETYPE_TIFF_MM ) ) ) ) {
|
||||
$exif = @exif_read_data( $file );
|
||||
|
||||
if ( ! empty( $exif['ImageDescription'] ) ) {
|
||||
@@ -509,15 +505,13 @@ function wp_read_image_metadata( $file ) {
|
||||
*
|
||||
* @since 2.5.0
|
||||
* @since 4.4.0 The `$iptc` parameter was added.
|
||||
* @since 5.0.0 The `$exif` parameter was added.
|
||||
*
|
||||
* @param array $meta Image meta data.
|
||||
* @param string $file Path to image file.
|
||||
* @param int $image_type Type of image, one of the `IMAGETYPE_XXX` constants.
|
||||
* @param array $iptc IPTC data.
|
||||
* @param array $exif EXIF data.
|
||||
* @param array $meta Image meta data.
|
||||
* @param string $file Path to image file.
|
||||
* @param int $sourceImageType Type of image.
|
||||
* @param array $iptc IPTC data.
|
||||
*/
|
||||
return apply_filters( 'wp_read_image_metadata', $meta, $file, $image_type, $iptc, $exif );
|
||||
return apply_filters( 'wp_read_image_metadata', $meta, $file, $sourceImageType, $iptc );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -1282,164 +1282,3 @@ function attachment_id3_data_meta_box( $post ) {
|
||||
<?php
|
||||
endforeach;
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers the default post meta boxes, and runs the `do_meta_boxes` actions.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param WP_Post $post The post object that these meta boxes are being generated for.
|
||||
*/
|
||||
function register_and_do_post_meta_boxes( $post ) {
|
||||
$post_type = $post->post_type;
|
||||
$post_type_object = get_post_type_object( $post_type );
|
||||
|
||||
$thumbnail_support = current_theme_supports( 'post-thumbnails', $post_type ) && post_type_supports( $post_type, 'thumbnail' );
|
||||
if ( ! $thumbnail_support && 'attachment' === $post_type && $post->post_mime_type ) {
|
||||
if ( wp_attachment_is( 'audio', $post ) ) {
|
||||
$thumbnail_support = post_type_supports( 'attachment:audio', 'thumbnail' ) || current_theme_supports( 'post-thumbnails', 'attachment:audio' );
|
||||
} elseif ( wp_attachment_is( 'video', $post ) ) {
|
||||
$thumbnail_support = post_type_supports( 'attachment:video', 'thumbnail' ) || current_theme_supports( 'post-thumbnails', 'attachment:video' );
|
||||
}
|
||||
}
|
||||
|
||||
$publish_callback_args = array( '__back_compat_meta_box' => true );
|
||||
if ( post_type_supports($post_type, 'revisions') && 'auto-draft' != $post->post_status ) {
|
||||
$revisions = wp_get_post_revisions( $post->ID );
|
||||
|
||||
// We should aim to show the revisions meta box only when there are revisions.
|
||||
if ( count( $revisions ) > 1 ) {
|
||||
reset( $revisions ); // Reset pointer for key()
|
||||
$publish_callback_args = array( 'revisions_count' => count( $revisions ), 'revision_id' => key( $revisions ), '__back_compat_meta_box' => true );
|
||||
add_meta_box('revisionsdiv', __('Revisions'), 'post_revisions_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
}
|
||||
|
||||
if ( 'attachment' == $post_type ) {
|
||||
wp_enqueue_script( 'image-edit' );
|
||||
wp_enqueue_style( 'imgareaselect' );
|
||||
add_meta_box( 'submitdiv', __('Save'), 'attachment_submit_meta_box', null, 'side', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
add_action( 'edit_form_after_title', 'edit_form_image_editor' );
|
||||
|
||||
if ( wp_attachment_is( 'audio', $post ) ) {
|
||||
add_meta_box( 'attachment-id3', __( 'Metadata' ), 'attachment_id3_data_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
} else {
|
||||
add_meta_box( 'submitdiv', __( 'Publish' ), 'post_submit_meta_box', null, 'side', 'core', $publish_callback_args );
|
||||
}
|
||||
|
||||
if ( current_theme_supports( 'post-formats' ) && post_type_supports( $post_type, 'post-formats' ) )
|
||||
add_meta_box( 'formatdiv', _x( 'Format', 'post format' ), 'post_format_meta_box', null, 'side', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
|
||||
// all taxonomies
|
||||
foreach ( get_object_taxonomies( $post ) as $tax_name ) {
|
||||
$taxonomy = get_taxonomy( $tax_name );
|
||||
if ( ! $taxonomy->show_ui || false === $taxonomy->meta_box_cb )
|
||||
continue;
|
||||
|
||||
$label = $taxonomy->labels->name;
|
||||
|
||||
if ( ! is_taxonomy_hierarchical( $tax_name ) )
|
||||
$tax_meta_box_id = 'tagsdiv-' . $tax_name;
|
||||
else
|
||||
$tax_meta_box_id = $tax_name . 'div';
|
||||
|
||||
add_meta_box( $tax_meta_box_id, $label, $taxonomy->meta_box_cb, null, 'side', 'core', array( 'taxonomy' => $tax_name, '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
|
||||
if ( post_type_supports( $post_type, 'page-attributes' ) || count( get_page_templates( $post ) ) > 0 ) {
|
||||
add_meta_box( 'pageparentdiv', $post_type_object->labels->attributes, 'page_attributes_meta_box', null, 'side', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
|
||||
if ( $thumbnail_support && current_user_can( 'upload_files' ) )
|
||||
add_meta_box('postimagediv', esc_html( $post_type_object->labels->featured_image ), 'post_thumbnail_meta_box', null, 'side', 'low', array( '__back_compat_meta_box' => true ) );
|
||||
|
||||
if ( post_type_supports($post_type, 'excerpt') )
|
||||
add_meta_box('postexcerpt', __('Excerpt'), 'post_excerpt_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
|
||||
if ( post_type_supports($post_type, 'trackbacks') )
|
||||
add_meta_box('trackbacksdiv', __('Send Trackbacks'), 'post_trackback_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
|
||||
if ( post_type_supports($post_type, 'custom-fields') ) {
|
||||
$args = array(
|
||||
'__back_compat_meta_box' => ! (bool) get_user_meta( get_current_user_id(), 'enable_custom_fields', true ),
|
||||
'__block_editor_compatible_meta_box' => true
|
||||
);
|
||||
add_meta_box('postcustom', __('Custom Fields'), 'post_custom_meta_box', null, 'normal', 'core', $args );
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires in the middle of built-in meta box registration.
|
||||
*
|
||||
* @since 2.1.0
|
||||
* @deprecated 3.7.0 Use 'add_meta_boxes' instead.
|
||||
*
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( 'dbx_post_advanced', $post );
|
||||
|
||||
// Allow the Discussion meta box to show up if the post type supports comments,
|
||||
// or if comments or pings are open.
|
||||
if ( comments_open( $post ) || pings_open( $post ) || post_type_supports( $post_type, 'comments' ) ) {
|
||||
add_meta_box( 'commentstatusdiv', __( 'Discussion' ), 'post_comment_status_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
|
||||
$stati = get_post_stati( array( 'public' => true ) );
|
||||
if ( empty( $stati ) ) {
|
||||
$stati = array( 'publish' );
|
||||
}
|
||||
$stati[] = 'private';
|
||||
|
||||
if ( in_array( get_post_status( $post ), $stati ) ) {
|
||||
// If the post type support comments, or the post has comments, allow the
|
||||
// Comments meta box.
|
||||
if ( comments_open( $post ) || pings_open( $post ) || $post->comment_count > 0 || post_type_supports( $post_type, 'comments' ) ) {
|
||||
add_meta_box( 'commentsdiv', __( 'Comments' ), 'post_comment_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
}
|
||||
|
||||
if ( ! ( 'pending' == get_post_status( $post ) && ! current_user_can( $post_type_object->cap->publish_posts ) ) )
|
||||
add_meta_box('slugdiv', __('Slug'), 'post_slug_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
|
||||
if ( post_type_supports( $post_type, 'author' ) && current_user_can( $post_type_object->cap->edit_others_posts ) ) {
|
||||
add_meta_box( 'authordiv', __( 'Author' ), 'post_author_meta_box', null, 'normal', 'core', array( '__back_compat_meta_box' => true ) );
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires after all built-in meta boxes have been added.
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param string $post_type Post type.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( 'add_meta_boxes', $post_type, $post );
|
||||
|
||||
/**
|
||||
* Fires after all built-in meta boxes have been added, contextually for the given post type.
|
||||
*
|
||||
* The dynamic portion of the hook, `$post_type`, refers to the post type of the post.
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( "add_meta_boxes_{$post_type}", $post );
|
||||
|
||||
/**
|
||||
* Fires after meta boxes have been added.
|
||||
*
|
||||
* Fires once for each of the default meta box contexts: normal, advanced, and side.
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param string $post_type Post type of the post.
|
||||
* @param string $context string Meta box context.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
do_action( 'do_meta_boxes', $post_type, 'normal', $post );
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
do_action( 'do_meta_boxes', $post_type, 'advanced', $post );
|
||||
/** This action is documented in wp-admin/includes/meta-boxes.php */
|
||||
do_action( 'do_meta_boxes', $post_type, 'side', $post );
|
||||
}
|
||||
|
||||
@@ -1044,31 +1044,13 @@ function wp_refresh_post_nonces( $response, $data, $screen_id ) {
|
||||
'_ajax_linking_nonce' => wp_create_nonce( 'internal-linking' ),
|
||||
'_wpnonce' => wp_create_nonce( 'update-post_' . $post_id ),
|
||||
),
|
||||
'heartbeatNonce' => wp_create_nonce( 'heartbeat-nonce' ),
|
||||
);
|
||||
}
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the latest Heartbeat and REST-API nonce to the Heartbeat response.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param array $response The Heartbeat response.
|
||||
* @return array The Heartbeat response.
|
||||
*/
|
||||
function wp_refresh_heartbeat_nonces( $response ) {
|
||||
// Refresh the Rest API nonce.
|
||||
$response['rest_nonce'] = wp_create_nonce( 'wp_rest' );
|
||||
// TEMPORARY: Compat with api-fetch library
|
||||
$response['rest-nonce'] = $response['rest_nonce'];
|
||||
|
||||
// Refresh the Heartbeat nonce.
|
||||
$response['heartbeat_nonce'] = wp_create_nonce( 'heartbeat-nonce' );
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disable suspension of Heartbeat on the Add/Edit Post screens.
|
||||
*
|
||||
@@ -1582,13 +1564,10 @@ final class WP_Privacy_Policy_Content {
|
||||
* Add a notice with a link to the guide when editing the privacy policy page.
|
||||
*
|
||||
* @since 4.9.6
|
||||
* @since 5.0.0 The $post parameter is now optional.
|
||||
*
|
||||
* @param WP_Post|null $post The currently edited post. Default null.
|
||||
* @param WP_Post $post The currently edited post.
|
||||
*/
|
||||
public static function notice( $post = null ) {
|
||||
$post = get_post( $post );
|
||||
|
||||
public static function notice( $post ) {
|
||||
if ( ! ( $post instanceof WP_Post ) ) {
|
||||
return;
|
||||
}
|
||||
@@ -1719,252 +1698,142 @@ final class WP_Privacy_Policy_Content {
|
||||
* Return the default suggested privacy policy content.
|
||||
*
|
||||
* @since 4.9.6
|
||||
* @since 5.0.0 Added the `$blocks` parameter.
|
||||
*
|
||||
* @param bool $description Whether to include the descriptions under the section headings. Default false.
|
||||
* @param bool $blocks Whether to format the content for the block editor. Default true.
|
||||
* @param bool $descr Whether to include the descriptions under the section headings. Default false.
|
||||
* @return string The default policy content.
|
||||
*/
|
||||
public static function get_default_content( $description = false, $blocks = true ) {
|
||||
$suggested_text = $description ? '<strong class="privacy-policy-tutorial">' . __( 'Suggested text:' ) . ' </strong>' : '';
|
||||
public static function get_default_content( $descr = false ) {
|
||||
$suggested_text = $descr ? '<strong class="privacy-policy-tutorial">' . __( 'Suggested text:' ) . ' </strong>' : '';
|
||||
$content = '';
|
||||
$strings = array();
|
||||
|
||||
// Start of the suggested privacy policy text.
|
||||
if ( $description ) {
|
||||
$strings[] = '<div class="wp-suggested-text">';
|
||||
}
|
||||
$descr && $content .=
|
||||
'<div class="wp-suggested-text">';
|
||||
$content .=
|
||||
'<h2>' . __( 'Who we are' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should note your site URL, as well as the name of the company, organization, or individual behind it, and some accurate contact information.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'The amount of information you may be required to show will vary depending on your local or national business regulations. You may, for example, be required to display a physical address, a registered address, or your company registration number.' ) . '</p>';
|
||||
$content .=
|
||||
/* translators: %s Site URL */
|
||||
'<p>' . $suggested_text . sprintf( __( 'Our website address is: %s.' ), get_bloginfo( 'url', 'display' ) ) . '</p>' .
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'Who we are' ) . '</h2>';
|
||||
'<h2>' . __( 'What personal data we collect and why we collect it' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should note what personal data you collect from users and site visitors. This may include personal data, such as name, email address, personal account preferences; transactional data, such as purchase information; and technical data, such as information about cookies.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'You should also note any collection and retention of sensitive personal data, such as data concerning health.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In addition to listing what personal data you collect, you need to note why you collect it. These explanations must note either the legal basis for your data collection and retention or the active consent the user has given.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'Personal data is not just created by a user’s interactions with your site. Personal data is also generated from technical processes such as contact forms, comments, cookies, analytics, and third party embeds.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'By default WordPress does not collect any personal data about visitors, and only collects the data shown on the User Profile screen from registered users. However some of your plugins may collect personal data. You should add the relevant information below.' ) . '</p>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should note your site URL, as well as the name of the company, organization, or individual behind it, and some accurate contact information.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'The amount of information you may be required to show will vary depending on your local or national business regulations. You may, for example, be required to display a physical address, a registered address, or your company registration number.' ) . '</p>';
|
||||
}
|
||||
$content .=
|
||||
'<h3>' . __( 'Comments' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this subsection you should note what information is captured through comments. We have noted the data which WordPress collects by default.' ) . '</p>';
|
||||
$content .=
|
||||
'<p>' . $suggested_text . __( 'When visitors leave comments on the site we collect the data shown in the comments form, and also the visitor’s IP address and browser user agent string to help spam detection.' ) . '</p>' .
|
||||
'<p>' . __( 'An anonymized string created from your email address (also called a hash) may be provided to the Gravatar service to see if you are using it. The Gravatar service privacy policy is available here: https://automattic.com/privacy/. After approval of your comment, your profile picture is visible to the public in the context of your comment.' ) . '</p>' .
|
||||
|
||||
/* translators: default privacy policy text, %s Site URL. */
|
||||
$strings[] = '<p>' . $suggested_text . sprintf( __( 'Our website address is: %s.' ), get_bloginfo( 'url', 'display' ) ) . '</p>';
|
||||
'<h3>' . __( 'Media' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this subsection you should note what information may be disclosed by users who can upload media files. All uploaded files are usually publicly accessible.' ) . '</p>';
|
||||
$content .=
|
||||
'<p>' . $suggested_text . __( 'If you upload images to the website, you should avoid uploading images with embedded location data (EXIF GPS) included. Visitors to the website can download and extract any location data from images on the website.' ) . '</p>' .
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'What personal data we collect and why we collect it' ) . '</h2>';
|
||||
'<h3>' . __( 'Contact forms' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'By default, WordPress does not include a contact form. If you use a contact form plugin, use this subsection to note what personal data is captured when someone submits a contact form, and how long you keep it. For example, you may note that you keep contact form submissions for a certain period for customer service purposes, but you do not use the information submitted through them for marketing purposes.' ) . '</p>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should note what personal data you collect from users and site visitors. This may include personal data, such as name, email address, personal account preferences; transactional data, such as purchase information; and technical data, such as information about cookies.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'You should also note any collection and retention of sensitive personal data, such as data concerning health.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In addition to listing what personal data you collect, you need to note why you collect it. These explanations must note either the legal basis for your data collection and retention or the active consent the user has given.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'Personal data is not just created by a user’s interactions with your site. Personal data is also generated from technical processes such as contact forms, comments, cookies, analytics, and third party embeds.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'By default WordPress does not collect any personal data about visitors, and only collects the data shown on the User Profile screen from registered users. However some of your plugins may collect personal data. You should add the relevant information below.' ) . '</p>';
|
||||
}
|
||||
$content .=
|
||||
'<h3>' . __( 'Cookies' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this subsection you should list the cookies your web site uses, including those set by your plugins, social media, and analytics. We have provided the cookies which WordPress installs by default.' ) . '</p>';
|
||||
$content .=
|
||||
'<p>' . $suggested_text . __( 'If you leave a comment on our site you may opt-in to saving your name, email address and website in cookies. These are for your convenience so that you do not have to fill in your details again when you leave another comment. These cookies will last for one year.' ) . '</p>' .
|
||||
'<p>' . __( 'If you have an account and you log in to this site, we will set a temporary cookie to determine if your browser accepts cookies. This cookie contains no personal data and is discarded when you close your browser.' ) . '</p>' .
|
||||
'<p>' . __( 'When you log in, we will also set up several cookies to save your login information and your screen display choices. Login cookies last for two days, and screen options cookies last for a year. If you select "Remember Me", your login will persist for two weeks. If you log out of your account, the login cookies will be removed.' ) . '</p>' .
|
||||
'<p>' . __( 'If you edit or publish an article, an additional cookie will be saved in your browser. This cookie includes no personal data and simply indicates the post ID of the article you just edited. It expires after 1 day.' ) . '</p>' .
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Comments' ) . '</h3>';
|
||||
'<h3>' . __( 'Embedded content from other websites' ) . '</h3>' .
|
||||
'<p>' . $suggested_text . __( 'Articles on this site may include embedded content (e.g. videos, images, articles, etc.). Embedded content from other websites behaves in the exact same way as if the visitor has visited the other website.' ) . '</p>' .
|
||||
'<p>' . __( 'These websites may collect data about you, use cookies, embed additional third-party tracking, and monitor your interaction with that embedded content, including tracking your interaction with the embedded content if you have an account and are logged in to that website.' ) . '</p>' .
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this subsection you should note what information is captured through comments. We have noted the data which WordPress collects by default.' ) . '</p>';
|
||||
}
|
||||
'<h3>' . __( 'Analytics' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this subsection you should note what analytics package you use, how users can opt out of analytics tracking, and a link to your analytics provider’s privacy policy, if any.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'By default WordPress does not collect any analytics data. However, many web hosting accounts collect some anonymous analytics data. You may also have installed a WordPress plugin that provides analytics services. In that case, add information from that plugin here.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'When visitors leave comments on the site we collect the data shown in the comments form, and also the visitor’s IP address and browser user agent string to help spam detection.' ) . '</p>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . __( 'An anonymized string created from your email address (also called a hash) may be provided to the Gravatar service to see if you are using it. The Gravatar service privacy policy is available here: https://automattic.com/privacy/. After approval of your comment, your profile picture is visible to the public in the context of your comment.' ) . '</p>';
|
||||
$content .=
|
||||
'<h2>' . __( 'Who we share your data with' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should name and list all third party providers with whom you share site data, including partners, cloud-based services, payment processors, and third party service providers, and note what data you share with them and why. Link to their own privacy policies if possible.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'By default WordPress does not share any personal data with anyone.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Media' ) . '</h3>';
|
||||
$content .=
|
||||
'<h2>' . __( 'How long we retain your data' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should explain how long you retain personal data collected or processed by the web site. While it is your responsibility to come up with the schedule of how long you keep each dataset for and why you keep it, that information does need to be listed here. For example, you may want to say that you keep contact form entries for six months, analytics records for a year, and customer purchase records for ten years.' ) . '</p>';
|
||||
$content .=
|
||||
'<p>' . $suggested_text . __( 'If you leave a comment, the comment and its metadata are retained indefinitely. This is so we can recognize and approve any follow-up comments automatically instead of holding them in a moderation queue.' ) . '</p>' .
|
||||
'<p>' . __( 'For users that register on our website (if any), we also store the personal information they provide in their user profile. All users can see, edit, or delete their personal information at any time (except they cannot change their username). Website administrators can also see and edit that information.' ) . '</p>' .
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this subsection you should note what information may be disclosed by users who can upload media files. All uploaded files are usually publicly accessible.' ) . '</p>';
|
||||
}
|
||||
'<h2>' . __( 'What rights you have over your data' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should explain what rights your users have over their data and how they can invoke those rights.' ) . '</p>';
|
||||
$content .=
|
||||
'<p>' . $suggested_text . __( 'If you have an account on this site, or have left comments, you can request to receive an exported file of the personal data we hold about you, including any data you have provided to us. You can also request that we erase any personal data we hold about you. This does not include any data we are obliged to keep for administrative, legal, or security purposes.' ) . '</p>' .
|
||||
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'If you upload images to the website, you should avoid uploading images with embedded location data (EXIF GPS) included. Visitors to the website can download and extract any location data from images on the website.' ) . '</p>';
|
||||
'<h2>' . __( 'Where we send your data' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should list all transfers of your site data outside the European Union and describe the means by which that data is safeguarded to European data protection standards. This could include your web hosting, cloud storage, or other third party services.' ) . '</p>' .
|
||||
'<p class="privacy-policy-tutorial">' . __( 'European data protection law requires data about European residents which is transferred outside the European Union to be safeguarded to the same standards as if the data was in Europe. So in addition to listing where data goes, you should describe how you ensure that these standards are met either by yourself or by your third party providers, whether that is through an agreement such as Privacy Shield, model clauses in your contracts, or binding corporate rules.' ) . '</p>';
|
||||
$content .=
|
||||
'<p>' . $suggested_text . __( 'Visitor comments may be checked through an automated spam detection service.' ) . '</p>' .
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Contact forms' ) . '</h3>';
|
||||
'<h2>' . __( 'Your contact information' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should provide a contact method for privacy-specific concerns. If you are required to have a Data Protection Officer, list their name and full contact details here as well.' ) . '</p>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'By default, WordPress does not include a contact form. If you use a contact form plugin, use this subsection to note what personal data is captured when someone submits a contact form, and how long you keep it. For example, you may note that you keep contact form submissions for a certain period for customer service purposes, but you do not use the information submitted through them for marketing purposes.' ) . '</p>';
|
||||
}
|
||||
$content .=
|
||||
'<h2>' . __( 'Additional information' ) . '</h2>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'If you use your site for commercial purposes and you engage in more complex collection or processing of personal data, you should note the following information in your privacy policy in addition to the information we have already discussed.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Cookies' ) . '</h3>';
|
||||
$content .=
|
||||
'<h3>' . __( 'How we protect your data' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should explain what measures you have taken to protect your users’ data. This could include technical measures such as encryption; security measures such as two factor authentication; and measures such as staff training in data protection. If you have carried out a Privacy Impact Assessment, you can mention it here too.' ) . '</p>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this subsection you should list the cookies your web site uses, including those set by your plugins, social media, and analytics. We have provided the cookies which WordPress installs by default.' ) . '</p>';
|
||||
}
|
||||
$content .=
|
||||
'<h3>' . __( 'What data breach procedures we have in place' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'In this section you should explain what procedures you have in place to deal with data breaches, either potential or real, such as internal reporting systems, contact mechanisms, or bug bounties.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'If you leave a comment on our site you may opt-in to saving your name, email address and website in cookies. These are for your convenience so that you do not have to fill in your details again when you leave another comment. These cookies will last for one year.' ) . '</p>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . __( 'If you have an account and you log in to this site, we will set a temporary cookie to determine if your browser accepts cookies. This cookie contains no personal data and is discarded when you close your browser.' ) . '</p>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . __( 'When you log in, we will also set up several cookies to save your login information and your screen display choices. Login cookies last for two days, and screen options cookies last for a year. If you select "Remember Me", your login will persist for two weeks. If you log out of your account, the login cookies will be removed.' ) . '</p>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . __( 'If you edit or publish an article, an additional cookie will be saved in your browser. This cookie includes no personal data and simply indicates the post ID of the article you just edited. It expires after 1 day.' ) . '</p>';
|
||||
$content .=
|
||||
'<h3>' . __( 'What third parties we receive data from' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'If your web site receives data about users from third parties, including advertisers, this information must be included within the section of your privacy policy dealing with third party data.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Embedded content from other websites' ) . '</h3>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'Articles on this site may include embedded content (e.g. videos, images, articles, etc.). Embedded content from other websites behaves in the exact same way as if the visitor has visited the other website.' ) . '</p>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . __( 'These websites may collect data about you, use cookies, embed additional third-party tracking, and monitor your interaction with that embedded content, including tracking your interaction with the embedded content if you have an account and are logged in to that website.' ) . '</p>';
|
||||
$content .=
|
||||
'<h3>' . __( 'What automated decision making and/or profiling we do with user data' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'If your web site provides a service which includes automated decision making - for example, allowing customers to apply for credit, or aggregating their data into an advertising profile - you must note that this is taking place, and include information about how that information is used, what decisions are made with that aggregated data, and what rights users have over decisions made without human intervention.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Analytics' ) . '</h3>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this subsection you should note what analytics package you use, how users can opt out of analytics tracking, and a link to your analytics provider’s privacy policy, if any.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'By default WordPress does not collect any analytics data. However, many web hosting accounts collect some anonymous analytics data. You may also have installed a WordPress plugin that provides analytics services. In that case, add information from that plugin here.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'Who we share your data with' ) . '</h2>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should name and list all third party providers with whom you share site data, including partners, cloud-based services, payment processors, and third party service providers, and note what data you share with them and why. Link to their own privacy policies if possible.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'By default WordPress does not share any personal data with anyone.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'How long we retain your data' ) . '</h2>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should explain how long you retain personal data collected or processed by the web site. While it is your responsibility to come up with the schedule of how long you keep each dataset for and why you keep it, that information does need to be listed here. For example, you may want to say that you keep contact form entries for six months, analytics records for a year, and customer purchase records for ten years.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'If you leave a comment, the comment and its metadata are retained indefinitely. This is so we can recognize and approve any follow-up comments automatically instead of holding them in a moderation queue.' ) . '</p>';
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . __( 'For users that register on our website (if any), we also store the personal information they provide in their user profile. All users can see, edit, or delete their personal information at any time (except they cannot change their username). Website administrators can also see and edit that information.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'What rights you have over your data' ) . '</h2>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should explain what rights your users have over their data and how they can invoke those rights.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'If you have an account on this site, or have left comments, you can request to receive an exported file of the personal data we hold about you, including any data you have provided to us. You can also request that we erase any personal data we hold about you. This does not include any data we are obliged to keep for administrative, legal, or security purposes.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'Where we send your data' ) . '</h2>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should list all transfers of your site data outside the European Union and describe the means by which that data is safeguarded to European data protection standards. This could include your web hosting, cloud storage, or other third party services.' ) . '</p>';
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'European data protection law requires data about European residents which is transferred outside the European Union to be safeguarded to the same standards as if the data was in Europe. So in addition to listing where data goes, you should describe how you ensure that these standards are met either by yourself or by your third party providers, whether that is through an agreement such as Privacy Shield, model clauses in your contracts, or binding corporate rules.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy text. */
|
||||
$strings[] = '<p>' . $suggested_text . __( 'Visitor comments may be checked through an automated spam detection service.' ) . '</p>';
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'Your contact information' ) . '</h2>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should provide a contact method for privacy-specific concerns. If you are required to have a Data Protection Officer, list their name and full contact details here as well.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h2>' . __( 'Additional information' ) . '</h2>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'If you use your site for commercial purposes and you engage in more complex collection or processing of personal data, you should note the following information in your privacy policy in addition to the information we have already discussed.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'How we protect your data' ) . '</h3>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should explain what measures you have taken to protect your users’ data. This could include technical measures such as encryption; security measures such as two factor authentication; and measures such as staff training in data protection. If you have carried out a Privacy Impact Assessment, you can mention it here too.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'What data breach procedures we have in place' ) . '</h3>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'In this section you should explain what procedures you have in place to deal with data breaches, either potential or real, such as internal reporting systems, contact mechanisms, or bug bounties.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'What third parties we receive data from' ) . '</h3>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'If your web site receives data about users from third parties, including advertisers, this information must be included within the section of your privacy policy dealing with third party data.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'What automated decision making and/or profiling we do with user data' ) . '</h3>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'If your web site provides a service which includes automated decision making - for example, allowing customers to apply for credit, or aggregating their data into an advertising profile - you must note that this is taking place, and include information about how that information is used, what decisions are made with that aggregated data, and what rights users have over decisions made without human intervention.' ) . '</p>';
|
||||
}
|
||||
|
||||
/* translators: default privacy policy heading. */
|
||||
$strings[] = '<h3>' . __( 'Industry regulatory disclosure requirements' ) . '</h3>';
|
||||
|
||||
if ( $description ) {
|
||||
/* translators: privacy policy tutorial. */
|
||||
$strings[] = '<p class="privacy-policy-tutorial">' . __( 'If you are a member of a regulated industry, or if you are subject to additional privacy laws, you may be required to disclose that information here.' ) . '</p>';
|
||||
$strings[] = '</div>';
|
||||
}
|
||||
|
||||
if ( $blocks ) {
|
||||
foreach ( $strings as $key => $string ) {
|
||||
if ( 0 === strpos( $string, '<p>' ) ) {
|
||||
$strings[ $key ] = '<!-- wp:paragraph -->' . $string . '<!-- /wp:paragraph -->';
|
||||
}
|
||||
|
||||
if ( 0 === strpos( $string, '<h2>' ) ) {
|
||||
$strings[ $key ] = '<!-- wp:heading -->' . $string . '<!-- /wp:heading -->';
|
||||
}
|
||||
|
||||
if ( 0 === strpos( $string, '<h3>' ) ) {
|
||||
$strings[ $key ] = '<!-- wp:heading {"level":3} -->' . $string . '<!-- /wp:heading -->';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$content = implode( '', $strings );
|
||||
$content .=
|
||||
'<h3>' . __( 'Industry regulatory disclosure requirements' ) . '</h3>';
|
||||
$descr && $content .=
|
||||
'<p class="privacy-policy-tutorial">' . __( 'If you are a member of a regulated industry, or if you are subject to additional privacy laws, you may be required to disclose that information here.' ) . '</p>' .
|
||||
'</div>';
|
||||
// End of the suggested privacy policy text.
|
||||
|
||||
/**
|
||||
* Filters the default content suggested for inclusion in a privacy policy.
|
||||
*
|
||||
* @since 4.9.6
|
||||
* @since 5.0.0 Added the `$strings`, `$description`, and `$blocks` parameters.
|
||||
*
|
||||
* @param $content string The default policy content.
|
||||
* @param $strings array An array of privacy policy content strings.
|
||||
* @param $description bool Whether policy descriptions should be included.
|
||||
* @param $blocks bool Whether the content should be formatted for the block editor.
|
||||
* @param $content string The default policy content.
|
||||
*/
|
||||
return apply_filters( 'wp_get_default_privacy_policy_content', $content, $strings, $description, $blocks );
|
||||
return apply_filters( 'wp_get_default_privacy_policy_content', $content );
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1973,7 +1842,7 @@ final class WP_Privacy_Policy_Content {
|
||||
* @since 4.9.6
|
||||
*/
|
||||
public static function add_suggested_content() {
|
||||
$content = self::get_default_content( true, false );
|
||||
$content = self::get_default_content( true );
|
||||
wp_add_privacy_policy_content( __( 'WordPress' ), $content );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -394,7 +394,6 @@ function install_plugin_install_status($api, $loop = false) {
|
||||
$status = 'install';
|
||||
$url = false;
|
||||
$update_file = false;
|
||||
$version = '';
|
||||
|
||||
/*
|
||||
* Check to see if this plugin is known to be installed,
|
||||
|
||||
@@ -430,17 +430,13 @@ function _get_dropins() {
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines whether a plugin is active.
|
||||
* Check whether a plugin is active.
|
||||
*
|
||||
* Only plugins installed in the plugins/ folder can be active.
|
||||
*
|
||||
* Plugins in the mu-plugins/ folder can't be "activated," so this function will
|
||||
* return false for those plugins.
|
||||
*
|
||||
* For more information on this and similar theme functions, check out
|
||||
* the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
|
||||
* Conditional Tags} article in the Theme Developer Handbook.
|
||||
*
|
||||
*
|
||||
* @since 2.5.0
|
||||
*
|
||||
* @param string $plugin Path to the main plugin file from plugins directory.
|
||||
@@ -451,14 +447,10 @@ function is_plugin_active( $plugin ) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines whether the plugin is inactive.
|
||||
* Check whether the plugin is inactive.
|
||||
*
|
||||
* Reverse of is_plugin_active(). Used as a callback.
|
||||
*
|
||||
* For more information on this and similar theme functions, check out
|
||||
* the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
|
||||
* Conditional Tags} article in the Theme Developer Handbook.
|
||||
*
|
||||
*
|
||||
* @since 3.1.0
|
||||
* @see is_plugin_active()
|
||||
*
|
||||
@@ -470,21 +462,17 @@ function is_plugin_inactive( $plugin ) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines whether the plugin is active for the entire network.
|
||||
* Check whether the plugin is active for the entire network.
|
||||
*
|
||||
* Only plugins installed in the plugins/ folder can be active.
|
||||
*
|
||||
* Plugins in the mu-plugins/ folder can't be "activated," so this function will
|
||||
* return false for those plugins.
|
||||
*
|
||||
* For more information on this and similar theme functions, check out
|
||||
* the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
|
||||
* Conditional Tags} article in the Theme Developer Handbook.
|
||||
*
|
||||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param string $plugin Path to the main plugin file from plugins directory.
|
||||
* @return bool True if active for the network, otherwise false.
|
||||
* @return bool True, if active for the network, otherwise false.
|
||||
*/
|
||||
function is_plugin_active_for_network( $plugin ) {
|
||||
if ( !is_multisite() )
|
||||
|
||||
@@ -659,7 +659,7 @@ function get_default_post_to_edit( $post_type = 'post', $create_in_db = false )
|
||||
* @param string $post_content Default post content.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
$post->post_content = (string) apply_filters( 'default_content', $post_content, $post );
|
||||
$post->post_content = apply_filters( 'default_content', $post_content, $post );
|
||||
|
||||
/**
|
||||
* Filters the default post title initially used in the "Write Post" form.
|
||||
@@ -669,7 +669,7 @@ function get_default_post_to_edit( $post_type = 'post', $create_in_db = false )
|
||||
* @param string $post_title Default post title.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
$post->post_title = (string) apply_filters( 'default_title', $post_title, $post );
|
||||
$post->post_title = apply_filters( 'default_title', $post_title, $post );
|
||||
|
||||
/**
|
||||
* Filters the default post excerpt initially used in the "Write Post" form.
|
||||
@@ -679,7 +679,7 @@ function get_default_post_to_edit( $post_type = 'post', $create_in_db = false )
|
||||
* @param string $post_excerpt Default post excerpt.
|
||||
* @param WP_Post $post Post object.
|
||||
*/
|
||||
$post->post_excerpt = (string) apply_filters( 'default_excerpt', $post_excerpt, $post );
|
||||
$post->post_excerpt = apply_filters( 'default_excerpt', $post_excerpt, $post );
|
||||
|
||||
return $post;
|
||||
}
|
||||
@@ -835,7 +835,7 @@ function add_meta( $post_ID ) {
|
||||
if ( is_string( $metavalue ) )
|
||||
$metavalue = trim( $metavalue );
|
||||
|
||||
if ( ( ( '#NONE#' != $metakeyselect ) && ! empty( $metakeyselect ) ) || ! empty( $metakeyinput ) ) {
|
||||
if ( ('0' === $metavalue || ! empty ( $metavalue ) ) && ( ( ( '#NONE#' != $metakeyselect ) && !empty ( $metakeyselect) ) || !empty ( $metakeyinput ) ) ) {
|
||||
/*
|
||||
* We have a key/value pair. If both the select and the input
|
||||
* for the key have data, the input takes precedence.
|
||||
@@ -1029,24 +1029,18 @@ function wp_edit_posts_query( $q = false ) {
|
||||
$post_type = 'post';
|
||||
|
||||
$avail_post_stati = get_available_post_statuses($post_type);
|
||||
$post_status = '';
|
||||
$perm = '';
|
||||
|
||||
if ( isset($q['post_status']) && in_array( $q['post_status'], $post_stati ) ) {
|
||||
$post_status = $q['post_status'];
|
||||
$perm = 'readable';
|
||||
}
|
||||
|
||||
$orderby = '';
|
||||
|
||||
if ( isset( $q['orderby'] ) ) {
|
||||
$orderby = $q['orderby'];
|
||||
} elseif ( isset( $q['post_status'] ) && in_array( $q['post_status'], array( 'pending', 'draft' ) ) ) {
|
||||
$orderby = 'modified';
|
||||
}
|
||||
|
||||
$order = '';
|
||||
|
||||
if ( isset( $q['order'] ) ) {
|
||||
$order = $q['order'];
|
||||
} elseif ( isset( $q['post_status'] ) && 'pending' == $q['post_status'] ) {
|
||||
@@ -1086,7 +1080,7 @@ function wp_edit_posts_query( $q = false ) {
|
||||
$query = compact('post_type', 'post_status', 'perm', 'order', 'orderby', 'posts_per_page');
|
||||
|
||||
// Hierarchical types require special args.
|
||||
if ( is_post_type_hierarchical( $post_type ) && empty( $orderby ) ) {
|
||||
if ( is_post_type_hierarchical( $post_type ) && !isset($orderby) ) {
|
||||
$query['orderby'] = 'menu_order title';
|
||||
$query['order'] = 'asc';
|
||||
$query['posts_per_page'] = -1;
|
||||
@@ -1180,7 +1174,7 @@ function wp_edit_attachments_query_vars( $q = false ) {
|
||||
|
||||
// Filter query clauses to include filenames.
|
||||
if ( isset( $q['s'] ) ) {
|
||||
add_filter( 'posts_clauses', '_filter_query_attachment_filenames' );
|
||||
add_filter( 'wp_allow_query_attachment_by_filename', '__return_true' );
|
||||
}
|
||||
|
||||
return $q;
|
||||
@@ -1902,367 +1896,3 @@ function redirect_post($post_id = '') {
|
||||
wp_redirect( apply_filters( 'redirect_post_location', $location, $post_id ) );
|
||||
exit;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return whether the post can be edited in the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param int|WP_Post $post Post ID or WP_Post object.
|
||||
* @return bool Whether the post can be edited in the block editor.
|
||||
*/
|
||||
function use_block_editor_for_post( $post ) {
|
||||
$post = get_post( $post );
|
||||
|
||||
if ( ! $post ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// We're in the meta box loader, so don't use the block editor.
|
||||
if ( isset( $_GET['meta-box-loader'] ) ) {
|
||||
check_admin_referer( 'meta-box-loader' );
|
||||
return false;
|
||||
}
|
||||
|
||||
// The posts page can't be edited in the block editor.
|
||||
if ( absint( get_option( 'page_for_posts' ) ) === $post->ID && empty( $post->post_content ) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$use_block_editor = use_block_editor_for_post_type( $post->post_type );
|
||||
|
||||
/**
|
||||
* Filter whether a post is able to be edited in the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param bool $use_block_editor Whether the post can be edited or not.
|
||||
* @param WP_Post $post The post being checked.
|
||||
*/
|
||||
return apply_filters( 'use_block_editor_for_post', $use_block_editor, $post );
|
||||
}
|
||||
|
||||
/**
|
||||
* Return whether a post type is compatible with the block editor.
|
||||
*
|
||||
* The block editor depends on the REST API, and if the post type is not shown in the
|
||||
* REST API, then it won't work with the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param string $post_type The post type.
|
||||
* @return bool Whether the post type can be edited with the block editor.
|
||||
*/
|
||||
function use_block_editor_for_post_type( $post_type ) {
|
||||
if ( ! post_type_exists( $post_type ) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if ( ! post_type_supports( $post_type, 'editor' ) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$post_type_object = get_post_type_object( $post_type );
|
||||
if ( $post_type_object && ! $post_type_object->show_in_rest ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter whether a post is able to be edited in the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param bool $use_block_editor Whether the post type can be edited or not. Default true.
|
||||
* @param string $post_type The post type being checked.
|
||||
*/
|
||||
return apply_filters( 'use_block_editor_for_post_type', true, $post_type );
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns all the block categories that will be shown in the block editor.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param WP_Post $post Post object.
|
||||
* @return array Array of block categories.
|
||||
*/
|
||||
function get_block_categories( $post ) {
|
||||
$default_categories = array(
|
||||
array(
|
||||
'slug' => 'common',
|
||||
'title' => __( 'Common Blocks' ),
|
||||
'icon' => null,
|
||||
),
|
||||
array(
|
||||
'slug' => 'formatting',
|
||||
'title' => __( 'Formatting' ),
|
||||
'icon' => null,
|
||||
),
|
||||
array(
|
||||
'slug' => 'layout',
|
||||
'title' => __( 'Layout Elements' ),
|
||||
'icon' => null,
|
||||
),
|
||||
array(
|
||||
'slug' => 'widgets',
|
||||
'title' => __( 'Widgets' ),
|
||||
'icon' => null,
|
||||
),
|
||||
array(
|
||||
'slug' => 'embed',
|
||||
'title' => __( 'Embeds' ),
|
||||
'icon' => null,
|
||||
),
|
||||
array(
|
||||
'slug' => 'reusable',
|
||||
'title' => __( 'Reusable Blocks' ),
|
||||
'icon' => null,
|
||||
),
|
||||
);
|
||||
|
||||
/**
|
||||
* Filter the default array of block categories.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param array $default_categories Array of block categories.
|
||||
* @param WP_Post $post Post being loaded.
|
||||
*/
|
||||
return apply_filters( 'block_categories', $default_categories, $post );
|
||||
}
|
||||
|
||||
/**
|
||||
* Prepares server-registered blocks for the block editor.
|
||||
*
|
||||
* Returns an associative array of registered block data keyed by block name. Data includes properties
|
||||
* of a block relevant for client registration.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @return array An associative array of registered block data.
|
||||
*/
|
||||
function get_block_editor_server_block_settings() {
|
||||
$block_registry = WP_Block_Type_Registry::get_instance();
|
||||
$blocks = array();
|
||||
$keys_to_pick = array( 'title', 'description', 'icon', 'category', 'keywords', 'supports', 'attributes' );
|
||||
|
||||
foreach ( $block_registry->get_all_registered() as $block_name => $block_type ) {
|
||||
foreach ( $keys_to_pick as $key ) {
|
||||
if ( ! isset( $block_type->{ $key } ) ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if ( ! isset( $blocks[ $block_name ] ) ) {
|
||||
$blocks[ $block_name ] = array();
|
||||
}
|
||||
|
||||
$blocks[ $block_name ][ $key ] = $block_type->{ $key };
|
||||
}
|
||||
}
|
||||
|
||||
return $blocks;
|
||||
}
|
||||
|
||||
/**
|
||||
* Renders the meta boxes forms.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*/
|
||||
function the_block_editor_meta_boxes() {
|
||||
global $post, $current_screen, $wp_meta_boxes;
|
||||
|
||||
// Handle meta box state.
|
||||
$_original_meta_boxes = $wp_meta_boxes;
|
||||
|
||||
/**
|
||||
* Fires right before the meta boxes are rendered.
|
||||
*
|
||||
* This allows for the filtering of meta box data, that should already be
|
||||
* present by this point. Do not use as a means of adding meta box data.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param array $wp_meta_boxes Global meta box state.
|
||||
*/
|
||||
$wp_meta_boxes = apply_filters( 'filter_block_editor_meta_boxes', $wp_meta_boxes );
|
||||
$locations = array( 'side', 'normal', 'advanced' );
|
||||
$priorities = array( 'high', 'sorted', 'core', 'default', 'low' );
|
||||
|
||||
// Render meta boxes.
|
||||
?>
|
||||
<form class="metabox-base-form">
|
||||
<?php the_block_editor_meta_box_post_form_hidden_fields( $post ); ?>
|
||||
</form>
|
||||
<form id="toggle-custom-fields-form" method="post" action="<?php echo esc_attr( admin_url( 'post.php' ) ); ?>">
|
||||
<?php wp_nonce_field( 'toggle-custom-fields' ); ?>
|
||||
<input type="hidden" name="action" value="toggle-custom-fields" />
|
||||
</form>
|
||||
<?php foreach ( $locations as $location ) : ?>
|
||||
<form class="metabox-location-<?php echo esc_attr( $location ); ?>" onsubmit="return false;">
|
||||
<div id="poststuff" class="sidebar-open">
|
||||
<div id="postbox-container-2" class="postbox-container">
|
||||
<?php
|
||||
do_meta_boxes(
|
||||
$current_screen,
|
||||
$location,
|
||||
$post
|
||||
);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<?php endforeach; ?>
|
||||
<?php
|
||||
|
||||
$meta_boxes_per_location = array();
|
||||
foreach ( $locations as $location ) {
|
||||
$meta_boxes_per_location[ $location ] = array();
|
||||
|
||||
if ( ! isset( $wp_meta_boxes[ $current_screen->id ][ $location ] ) ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
foreach ( $priorities as $priority ) {
|
||||
if ( ! isset( $wp_meta_boxes[ $current_screen->id ][ $location ][ $priority ] ) ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$meta_boxes = (array) $wp_meta_boxes[ $current_screen->id ][ $location ][ $priority ];
|
||||
foreach ( $meta_boxes as $meta_box ) {
|
||||
if ( false == $meta_box || ! $meta_box['title'] ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// If a meta box is just here for back compat, don't show it in the block editor.
|
||||
if ( isset( $meta_box['args']['__back_compat_meta_box'] ) && $meta_box['args']['__back_compat_meta_box'] ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$meta_boxes_per_location[ $location ][] = array(
|
||||
'id' => $meta_box['id'],
|
||||
'title' => $meta_box['title'],
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Sadly we probably can not add this data directly into editor settings.
|
||||
*
|
||||
* Some meta boxes need admin_head to fire for meta box registry.
|
||||
* admin_head fires after admin_enqueue_scripts, which is where we create our
|
||||
* editor instance.
|
||||
*/
|
||||
$script = 'window._wpLoadBlockEditor.then( function() {
|
||||
wp.data.dispatch( \'core/edit-post\' ).setAvailableMetaBoxesPerLocation( ' . wp_json_encode( $meta_boxes_per_location ) . ' );
|
||||
} );';
|
||||
|
||||
wp_add_inline_script( 'wp-edit-post', $script );
|
||||
|
||||
/**
|
||||
* When `wp-edit-post` is output in the `<head>`, the inline script needs to be manually printed. Otherwise,
|
||||
* meta boxes will not display because inline scripts for `wp-edit-post` will not be printed again after this point.
|
||||
*/
|
||||
if ( wp_script_is( 'wp-edit-post', 'done' ) ) {
|
||||
printf( "<script type='text/javascript'>\n%s\n</script>\n", trim( $script ) );
|
||||
}
|
||||
|
||||
/**
|
||||
* If the 'postcustom' meta box is enabled, then we need to perform some
|
||||
* extra initialization on it.
|
||||
*/
|
||||
$enable_custom_fields = (bool) get_user_meta( get_current_user_id(), 'enable_custom_fields', true );
|
||||
if ( $enable_custom_fields ) {
|
||||
$script = "( function( $ ) {
|
||||
if ( $('#postcustom').length ) {
|
||||
$( '#the-list' ).wpList( {
|
||||
addBefore: function( s ) {
|
||||
s.data += '&post_id=$post->ID';
|
||||
return s;
|
||||
},
|
||||
addAfter: function() {
|
||||
$('table#list-table').show();
|
||||
}
|
||||
});
|
||||
}
|
||||
} )( jQuery );";
|
||||
wp_enqueue_script( 'wp-lists' );
|
||||
wp_add_inline_script( 'wp-lists', $script );
|
||||
}
|
||||
|
||||
// Reset meta box data.
|
||||
$wp_meta_boxes = $_original_meta_boxes;
|
||||
}
|
||||
|
||||
/**
|
||||
* Renders the hidden form required for the meta boxes form.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param WP_Post $post Current post object.
|
||||
*/
|
||||
function the_block_editor_meta_box_post_form_hidden_fields( $post ) {
|
||||
$form_extra = '';
|
||||
if ( 'auto-draft' === $post->post_status ) {
|
||||
$form_extra .= "<input type='hidden' id='auto_draft' name='auto_draft' value='1' />";
|
||||
}
|
||||
$form_action = 'editpost';
|
||||
$nonce_action = 'update-post_' . $post->ID;
|
||||
$form_extra .= "<input type='hidden' id='post_ID' name='post_ID' value='" . esc_attr( $post->ID ) . "' />";
|
||||
$referer = wp_get_referer();
|
||||
$current_user = wp_get_current_user();
|
||||
$user_id = $current_user->ID;
|
||||
wp_nonce_field( $nonce_action );
|
||||
|
||||
/*
|
||||
* Some meta boxes hook into these actions to add hidden input fields in the classic post form. For backwards
|
||||
* compatibility, we can capture the output from these actions, and extract the hidden input fields.
|
||||
*/
|
||||
ob_start();
|
||||
/** This filter is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'edit_form_after_title', $post );
|
||||
/** This filter is documented in wp-admin/edit-form-advanced.php */
|
||||
do_action( 'edit_form_advanced', $post );
|
||||
$classic_output = ob_get_clean();
|
||||
|
||||
$classic_elements = wp_html_split( $classic_output );
|
||||
$hidden_inputs = '';
|
||||
foreach( $classic_elements as $element ) {
|
||||
if ( 0 !== strpos( $element, '<input ') ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if ( preg_match( '/\stype=[\'"]hidden[\'"]\s/', $element ) ) {
|
||||
echo $element;
|
||||
}
|
||||
}
|
||||
?>
|
||||
<input type="hidden" id="user-id" name="user_ID" value="<?php echo (int) $user_id; ?>" />
|
||||
<input type="hidden" id="hiddenaction" name="action" value="<?php echo esc_attr( $form_action ); ?>" />
|
||||
<input type="hidden" id="originalaction" name="originalaction" value="<?php echo esc_attr( $form_action ); ?>" />
|
||||
<input type="hidden" id="post_type" name="post_type" value="<?php echo esc_attr( $post->post_type ); ?>" />
|
||||
<input type="hidden" id="original_post_status" name="original_post_status" value="<?php echo esc_attr( $post->post_status ); ?>" />
|
||||
<input type="hidden" id="referredby" name="referredby" value="<?php echo $referer ? esc_url( $referer ) : ''; ?>" />
|
||||
|
||||
<?php
|
||||
if ( 'draft' !== get_post_status( $post ) ) {
|
||||
wp_original_referer_field( true, 'previous' );
|
||||
}
|
||||
echo $form_extra;
|
||||
wp_nonce_field( 'meta-box-order', 'meta-box-order-nonce', false );
|
||||
wp_nonce_field( 'closedpostboxes', 'closedpostboxesnonce', false );
|
||||
// Permalink title nonce.
|
||||
wp_nonce_field( 'samplepermalink', 'samplepermalinknonce', false );
|
||||
|
||||
/**
|
||||
* Add hidden input fields to the meta box save form.
|
||||
*
|
||||
* Hook into this action to print `<input type="hidden" ... />` fields, which will be POSTed back to
|
||||
* the server when meta boxes are saved.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @params WP_Post $post The post that is being edited.
|
||||
*/
|
||||
do_action( 'block_editor_meta_box_hidden_fields', $post );
|
||||
}
|
||||
|
||||
@@ -998,105 +998,6 @@ function add_meta_box( $id, $title, $callback, $screen = null, $context = 'advan
|
||||
$wp_meta_boxes[$page][$context][$priority][$id] = array('id' => $id, 'title' => $title, 'callback' => $callback, 'args' => $callback_args);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Function that renders a "fake" meta box with an information message,
|
||||
* shown on the block editor, when an incompatible meta box is found.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @param mixed $object The data object being rendered on this screen.
|
||||
* @param array $box {
|
||||
* Custom formats meta box arguments.
|
||||
*
|
||||
* @type string $id Meta box 'id' attribute.
|
||||
* @type string $title Meta box title.
|
||||
* @type callable $old_callback The original callback for this meta box.
|
||||
* @type array $args Extra meta box arguments.
|
||||
* }
|
||||
*/
|
||||
function do_block_editor_incompatible_meta_box( $object, $box ) {
|
||||
$plugin = _get_plugin_from_callback( $box['old_callback'] );
|
||||
$plugins = get_plugins();
|
||||
echo '<p>';
|
||||
if ( $plugin ) {
|
||||
/* translators: %s: the name of the plugin that generated this meta box. */
|
||||
printf( __( "This meta box, from the %s plugin, isn't compatible with the block editor." ), "<strong>{$plugin['Name']}</strong>" );
|
||||
} else {
|
||||
_e( "This meta box isn't compatible with the block editor." );
|
||||
}
|
||||
echo '</p>';
|
||||
|
||||
if ( empty( $plugins['classic-editor/classic-editor.php'] ) ) {
|
||||
if ( current_user_can( 'install_plugins' ) ) {
|
||||
echo '<p>';
|
||||
/* translators: %s: A link to install the Classic Editor plugin. */
|
||||
printf( __( 'Please install the <a href="%s">Classic Editor plugin</a> to use this meta box.'), esc_url( self_admin_url( 'plugin-install.php?tab=featured' ) ) );
|
||||
echo '</p>';
|
||||
}
|
||||
} elseif ( is_plugin_inactive( 'classic-editor/classic-editor.php' ) ) {
|
||||
if ( current_user_can( 'activate_plugins' ) ) {
|
||||
$activate_url = wp_nonce_url( self_admin_url( 'plugins.php?action=activate&plugin=classic-editor/classic-editor.php' ), 'activate-plugin_classic-editor/classic-editor.php' );
|
||||
echo '<p>';
|
||||
/* translators: %s: A link to activate the Classic Editor plugin. */
|
||||
printf( __( 'Please activate the <a href="%s">Classic Editor plugin</a> to use this meta box.'), esc_url( $activate_url ) );
|
||||
echo '</p>';
|
||||
}
|
||||
} elseif ( $object instanceof WP_Post ) {
|
||||
$edit_url = add_query_arg( 'classic-editor', '', get_edit_post_link( $object ) );
|
||||
echo '<p>';
|
||||
/* translators: %s: An edit post link to use the classic editor. */
|
||||
printf( __( 'Please open the <a href="%s">classic editor</a> to use this meta box.'), esc_url( $edit_url ) );
|
||||
echo '</p>';
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Internal helper function to find the plugin from a meta box callback.
|
||||
*
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @access private
|
||||
*
|
||||
* @param callable $callback The callback function to check.
|
||||
* @return array|null The plugin that the callback belongs to, or null if it doesn't belong to a plugin.
|
||||
*/
|
||||
function _get_plugin_from_callback( $callback ) {
|
||||
try {
|
||||
if ( is_array( $callback ) ) {
|
||||
$reflection = new ReflectionMethod( $callback[0], $callback[1] );
|
||||
} elseif ( is_string( $callback) && false !== strpos( $callback, '::' ) ) {
|
||||
$reflection = new ReflectionMethod( $callback );
|
||||
} else {
|
||||
$reflection = new ReflectionFunction( $callback );
|
||||
}
|
||||
} catch ( ReflectionException $exception ) {
|
||||
// We could not properly reflect on the callable, so we abort here.
|
||||
return null;
|
||||
}
|
||||
|
||||
// Don't show an error if it's an internal PHP function.
|
||||
if ( ! $reflection->isInternal() ) {
|
||||
|
||||
// Only show errors if the meta box was registered by a plugin.
|
||||
$filename = wp_normalize_path( $reflection->getFileName() );
|
||||
$plugin_dir = wp_normalize_path( WP_PLUGIN_DIR );
|
||||
if ( strpos( $filename, $plugin_dir ) === 0 ) {
|
||||
$filename = str_replace( $plugin_dir, '', $filename );
|
||||
$filename = preg_replace( '|^/([^/]*/).*$|', '\\1', $filename );
|
||||
|
||||
$plugins = get_plugins();
|
||||
foreach ( $plugins as $name => $plugin ) {
|
||||
if ( strpos( $name, $filename ) === 0 ) {
|
||||
return $plugin;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Meta-Box template function
|
||||
*
|
||||
@@ -1150,34 +1051,8 @@ function do_meta_boxes( $screen, $context, $object ) {
|
||||
foreach ( (array) $wp_meta_boxes[ $page ][ $context ][ $priority ] as $box ) {
|
||||
if ( false == $box || ! $box['title'] )
|
||||
continue;
|
||||
|
||||
$block_compatible = true;
|
||||
if ( is_array( $box[ 'args' ] ) ) {
|
||||
// If a meta box is just here for back compat, don't show it in the block editor.
|
||||
if ( $screen->is_block_editor() && isset( $box['args']['__back_compat_meta_box'] ) && $box['args']['__back_compat_meta_box'] ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if ( isset( $box['args']['__block_editor_compatible_meta_box'] ) ) {
|
||||
$block_compatible = (bool) $box['args']['__block_editor_compatible_meta_box'];
|
||||
unset( $box['args']['__block_editor_compatible_meta_box'] );
|
||||
}
|
||||
|
||||
// If the meta box is declared as incompatible with the block editor, override the callback function.
|
||||
if ( ! $block_compatible && $screen->is_block_editor() ) {
|
||||
$box['old_callback'] = $box['callback'];
|
||||
$box['callback'] = 'do_block_editor_incompatible_meta_box';
|
||||
}
|
||||
|
||||
if ( isset( $box['args']['__back_compat_meta_box'] ) ) {
|
||||
$block_compatible = $block_compatible || (bool) $box['args']['__back_compat_meta_box'];
|
||||
unset( $box['args']['__back_compat_meta_box'] );
|
||||
}
|
||||
}
|
||||
|
||||
$i++;
|
||||
// get_hidden_meta_boxes() doesn't apply in the block editor.
|
||||
$hidden_class = ( ! $screen->is_block_editor() && in_array( $box['id'], $hidden ) ) ? ' hide-if-js' : '';
|
||||
$hidden_class = in_array($box['id'], $hidden) ? ' hide-if-js' : '';
|
||||
echo '<div id="' . $box['id'] . '" class="postbox ' . postbox_classes($box['id'], $page) . $hidden_class . '" ' . '>' . "\n";
|
||||
if ( 'dashboard_browser_nag' != $box['id'] ) {
|
||||
$widget_title = $box[ 'title' ];
|
||||
@@ -1195,23 +1070,6 @@ function do_meta_boxes( $screen, $context, $object ) {
|
||||
}
|
||||
echo "<h2 class='hndle'><span>{$box['title']}</span></h2>\n";
|
||||
echo '<div class="inside">' . "\n";
|
||||
|
||||
if ( WP_DEBUG && ! $block_compatible && 'edit' === $screen->parent_base && ! $screen->is_block_editor() && ! isset( $_GET['meta-box-loader'] ) ) {
|
||||
$plugin = _get_plugin_from_callback( $box['callback'] );
|
||||
if ( $plugin ) {
|
||||
?>
|
||||
<div class="error inline">
|
||||
<p>
|
||||
<?php
|
||||
/* translators: %s: the name of the plugin that generated this meta box. */
|
||||
printf( __( "This meta box, from the %s plugin, isn't compatible with the block editor." ), "<strong>{$plugin['Name']}</strong>" );
|
||||
?>
|
||||
</p>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
call_user_func($box['callback'], $object, $box);
|
||||
echo "</div>\n";
|
||||
echo "</div>\n";
|
||||
|
||||
@@ -814,7 +814,6 @@ $_new_bundled_files = array(
|
||||
'themes/twentyfifteen/' => '4.1',
|
||||
'themes/twentysixteen/' => '4.4',
|
||||
'themes/twentyseventeen/' => '4.7',
|
||||
'themes/twentynineteen/' => '5.0',
|
||||
);
|
||||
|
||||
/**
|
||||
|
||||
@@ -159,10 +159,8 @@ function wp_install_defaults( $user_id ) {
|
||||
$first_post = get_site_option( 'first_post' );
|
||||
|
||||
if ( ! $first_post ) {
|
||||
$first_post = "<!-- wp:paragraph -->\n<p>" .
|
||||
/* translators: first post content, %s: site link */
|
||||
__( 'Welcome to %s. This is your first post. Edit or delete it, then start writing!' ) .
|
||||
"</p>\n<!-- /wp:paragraph -->";
|
||||
/* translators: %s: site link */
|
||||
$first_post = __( 'Welcome to %s. This is your first post. Edit or delete it, then start blogging!' );
|
||||
}
|
||||
|
||||
$first_post = sprintf( $first_post,
|
||||
@@ -173,10 +171,7 @@ function wp_install_defaults( $user_id ) {
|
||||
$first_post = str_replace( 'SITE_URL', esc_url( network_home_url() ), $first_post );
|
||||
$first_post = str_replace( 'SITE_NAME', get_network()->site_name, $first_post );
|
||||
} else {
|
||||
$first_post = "<!-- wp:paragraph -->\n<p>" .
|
||||
/* translators: first post content, %s: site link */
|
||||
__( 'Welcome to WordPress. This is your first post. Edit or delete it, then start writing!' ) .
|
||||
"</p>\n<!-- /wp:paragraph -->";
|
||||
$first_post = __( 'Welcome to WordPress. This is your first post. Edit or delete it, then start writing!' );
|
||||
}
|
||||
|
||||
$wpdb->insert( $wpdb->posts, array(
|
||||
@@ -226,35 +221,15 @@ Commenter avatars come from <a href="https://gravatar.com">Gravatar</a>.' );
|
||||
if ( is_multisite() )
|
||||
$first_page = get_site_option( 'first_page' );
|
||||
|
||||
if ( empty( $first_page ) ) {
|
||||
$first_page = "<!-- wp:paragraph -->\n<p>";
|
||||
/* translators: first page content */
|
||||
$first_page .= __( "This is an example page. It's different from a blog post because it will stay in one place and will show up in your site navigation (in most themes). Most people start with an About page that introduces them to potential site visitors. It might say something like this:" );
|
||||
$first_page .= "</p>\n<!-- /wp:paragraph -->\n\n";
|
||||
$first_page = ! empty( $first_page ) ? $first_page : sprintf( __( "This is an example page. It's different from a blog post because it will stay in one place and will show up in your site navigation (in most themes). Most people start with an About page that introduces them to potential site visitors. It might say something like this:
|
||||
|
||||
$first_page .= "<!-- wp:quote -->\n<blockquote class=\"wp-block-quote\"><p>";
|
||||
/* translators: first page content */
|
||||
$first_page .= __( "Hi there! I'm a bike messenger by day, aspiring actor by night, and this is my website. I live in Los Angeles, have a great dog named Jack, and I like piña coladas. (And gettin' caught in the rain.)" );
|
||||
$first_page .= "</p></blockquote>\n<!-- /wp:quote -->\n\n";
|
||||
<blockquote>Hi there! I'm a bike messenger by day, aspiring actor by night, and this is my website. I live in Los Angeles, have a great dog named Jack, and I like piña coladas. (And gettin' caught in the rain.)</blockquote>
|
||||
|
||||
$first_page .= "<!-- wp:paragraph -->\n<p>";
|
||||
/* translators: first page content */
|
||||
$first_page .= __( '...or something like this:' );
|
||||
$first_page .= "</p>\n<!-- /wp:paragraph -->\n\n";
|
||||
...or something like this:
|
||||
|
||||
$first_page .= "<!-- wp:quote -->\n<blockquote class=\"wp-block-quote\"><p>";
|
||||
/* translators: first page content */
|
||||
$first_page .= __( 'The XYZ Doohickey Company was founded in 1971, and has been providing quality doohickeys to the public ever since. Located in Gotham City, XYZ employs over 2,000 people and does all kinds of awesome things for the Gotham community.' );
|
||||
$first_page .= "</p></blockquote>\n<!-- /wp:quote -->\n\n";
|
||||
<blockquote>The XYZ Doohickey Company was founded in 1971, and has been providing quality doohickeys to the public ever since. Located in Gotham City, XYZ employs over 2,000 people and does all kinds of awesome things for the Gotham community.</blockquote>
|
||||
|
||||
$first_page .= "<!-- wp:paragraph -->\n<p>";
|
||||
$first_page .= sprintf(
|
||||
/* translators: first page content, %s: site admin URL */
|
||||
__( 'As a new WordPress user, you should go to <a href="%s">your dashboard</a> to delete this page and create new pages for your content. Have fun!' ),
|
||||
admin_url()
|
||||
);
|
||||
$first_page .= "</p>\n<!-- /wp:paragraph -->";
|
||||
}
|
||||
As a new WordPress user, you should go to <a href=\"%s\">your dashboard</a> to delete this page and create new pages for your content. Have fun!" ), admin_url() );
|
||||
|
||||
$first_post_guid = get_option('home') . '/?page_id=2';
|
||||
$wpdb->insert( $wpdb->posts, array(
|
||||
@@ -330,7 +305,7 @@ Commenter avatars come from <a href="https://gravatar.com">Gravatar</a>.' );
|
||||
update_option( 'widget_archives', array ( 2 => array ( 'title' => '', 'count' => 0, 'dropdown' => 0 ), '_multiwidget' => 1 ) );
|
||||
update_option( 'widget_categories', array ( 2 => array ( 'title' => '', 'count' => 0, 'hierarchical' => 0, 'dropdown' => 0 ), '_multiwidget' => 1 ) );
|
||||
update_option( 'widget_meta', array ( 2 => array ( 'title' => '' ), '_multiwidget' => 1 ) );
|
||||
update_option( 'sidebars_widgets', array( 'wp_inactive_widgets' => array(), 'sidebar-1' => array( 0 => 'search-2', 1 => 'recent-posts-2', 2 => 'recent-comments-2', 3 => 'archives-2', 4 => 'categories-2', 5 => 'meta-2' ), 'array_version' => 3 ) );
|
||||
update_option( 'sidebars_widgets', array( 'wp_inactive_widgets' => array(), 'sidebar-1' => array( 0 => 'search-2', 1 => 'recent-posts-2', 2 => 'recent-comments-2', 3 => 'archives-2', 4 => 'categories-2', 5 => 'meta-2' ), 'sidebar-2' => array(), 'sidebar-3' => array(), 'array_version' => 3 ) );
|
||||
if ( ! is_multisite() )
|
||||
update_user_meta( $user_id, 'show_welcome_panel', 1 );
|
||||
elseif ( ! is_super_admin( $user_id ) && ! metadata_exists( 'user', $user_id, 'show_welcome_panel' ) )
|
||||
@@ -639,9 +614,6 @@ function upgrade_all() {
|
||||
if ( $wp_current_db_version < 37965 )
|
||||
upgrade_460();
|
||||
|
||||
if ( $wp_current_db_version < 43764 )
|
||||
upgrade_500();
|
||||
|
||||
maybe_disable_link_manager();
|
||||
|
||||
maybe_disable_automattic_widgets();
|
||||
@@ -1809,32 +1781,6 @@ function upgrade_460() {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes changes made in WordPress 5.0.0.
|
||||
*
|
||||
* @ignore
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @global int $wp_current_db_version Current database version.
|
||||
*/
|
||||
function upgrade_500() {
|
||||
global $wp_current_db_version;
|
||||
if ( $wp_current_db_version < 43764 ) {
|
||||
// Allow bypassing Gutenberg plugin deactivation.
|
||||
if ( defined( 'GUTENBERG_USE_PLUGIN' ) && GUTENBERG_USE_PLUGIN ) {
|
||||
return;
|
||||
}
|
||||
|
||||
$was_active = is_plugin_active( 'gutenberg/gutenberg.php' );
|
||||
if ( $was_active ) {
|
||||
// FIXME: Leave until 501 or 510 to clean up.
|
||||
update_site_option( 'upgrade_500_was_gutenberg_active', '1' );
|
||||
}
|
||||
|
||||
deactivate_plugins( array( 'gutenberg/gutenberg.php' ), true );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes network-level upgrade routines.
|
||||
*
|
||||
|
||||
2
wp-admin/js/common.min.js
vendored
2
wp-admin/js/customize-controls.min.js
vendored
@@ -3111,7 +3111,7 @@
|
||||
nav_menu_item: api.Menus.MenuItemControl,
|
||||
nav_menu: api.Menus.MenuControl,
|
||||
nav_menu_name: api.Menus.MenuNameControl,
|
||||
new_menu: api.Menus.NewMenuControl, // @todo Remove in a future release. See #42364.
|
||||
new_menu: api.Menus.NewMenuControl, // @todo Remove in 5.0. See #42364.
|
||||
nav_menu_locations: api.Menus.MenuLocationsControl,
|
||||
nav_menu_auto_add: api.Menus.MenuAutoAddControl
|
||||
});
|
||||
|
||||