Media: Support title fields to be removed from attachments.
props antpb. fixes #23932. Built from https://develop.svn.wordpress.org/trunk@32773 git-svn-id: http://core.svn.wordpress.org/trunk@32744 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
ed46512c20
commit
a0f4e8e086
|
@ -378,10 +378,12 @@ function wp_print_media_templates() {
|
||||||
<input type="text" value="{{ data.url }}" readonly />
|
<input type="text" value="{{ data.url }}" readonly />
|
||||||
</label>
|
</label>
|
||||||
<# var maybeReadOnly = data.can.save || data.allowLocalEdits ? '' : 'readonly'; #>
|
<# var maybeReadOnly = data.can.save || data.allowLocalEdits ? '' : 'readonly'; #>
|
||||||
|
<?php if ( post_type_supports( 'attachment', 'title' ) ) : ?>
|
||||||
<label class="setting" data-setting="title">
|
<label class="setting" data-setting="title">
|
||||||
<span class="name"><?php _e('Title'); ?></span>
|
<span class="name"><?php _e('Title'); ?></span>
|
||||||
<input type="text" value="{{ data.title }}" {{ maybeReadOnly }} />
|
<input type="text" value="{{ data.title }}" {{ maybeReadOnly }} />
|
||||||
</label>
|
</label>
|
||||||
|
<?php endif; ?>
|
||||||
<# if ( 'audio' === data.type ) { #>
|
<# if ( 'audio' === data.type ) { #>
|
||||||
<?php foreach ( array(
|
<?php foreach ( array(
|
||||||
'artist' => __( 'Artist' ),
|
'artist' => __( 'Artist' ),
|
||||||
|
@ -557,10 +559,12 @@ function wp_print_media_templates() {
|
||||||
<input type="text" value="{{ data.url }}" readonly />
|
<input type="text" value="{{ data.url }}" readonly />
|
||||||
</label>
|
</label>
|
||||||
<# var maybeReadOnly = data.can.save || data.allowLocalEdits ? '' : 'readonly'; #>
|
<# var maybeReadOnly = data.can.save || data.allowLocalEdits ? '' : 'readonly'; #>
|
||||||
|
<?php if ( post_type_supports( 'attachment', 'title' ) ) : ?>
|
||||||
<label class="setting" data-setting="title">
|
<label class="setting" data-setting="title">
|
||||||
<span class="name"><?php _e('Title'); ?></span>
|
<span class="name"><?php _e('Title'); ?></span>
|
||||||
<input type="text" value="{{ data.title }}" {{ maybeReadOnly }} />
|
<input type="text" value="{{ data.title }}" {{ maybeReadOnly }} />
|
||||||
</label>
|
</label>
|
||||||
|
<?php endif; ?>
|
||||||
<# if ( 'audio' === data.type ) { #>
|
<# if ( 'audio' === data.type ) { #>
|
||||||
<?php foreach ( array(
|
<?php foreach ( array(
|
||||||
'artist' => __( 'Artist' ),
|
'artist' => __( 'Artist' ),
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.3-alpha-32772';
|
$wp_version = '4.3-alpha-32773';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue