Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 21 additions & 14 deletions css/custom-metadata-manager.css
Original file line number Diff line number Diff line change
Expand Up @@ -199,34 +199,41 @@

.custom-metadata-multifield-clone,
.custom-metadata-multifield-delete {
color: #fff;
position: absolute;
display: block;
top: 50%;
right: 25px;
padding: 0 3px 4px;
font-size: 35px;
line-height: 20px;
padding: 5px;
font: 20px/1 dashicons;
text-decoration: none;
border: 1px solid;
border-radius: 50%;
}
.custom-metadata-multifield-clone:hover,
.custom-metadata-multifield-delete:hover {
color: #fff;
}
.custom-metadata-multifield-clone {
background-color: #5cb85c;
margin-top: -17px;
color: green;
border-color: green;
}
.custom-metadata-multifield-clone:hover {
background-color: #4cae4c;
}
.custom-metadata-multifield-clone:before {
content: "\f132";
}
.custom-metadata-multifield-delete ~ .custom-metadata-multifield-clone {
margin-top: -35px;
}
.custom-metadata-multifield-delete {
background-color: #d9534f;
margin-top: 17px;
padding: 1px 6px 4px;
color: red;
border-color: red;
}
.custom-metadata-multifield-clone:hover,
.custom-metadata-multifield-clone:active,
.custom-metadata-multifield-delete:hover,
.custom-metadata-multifield-delete:active {
border-color: #d54e21;
.custom-metadata-multifield-delete:hover {
background-color: #d43f3a;
}

.custom-metadata-multifield-delete:before {
content: "\f158";
}
4 changes: 2 additions & 2 deletions custom_metadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -1121,10 +1121,10 @@ function _display_metadata_multifield( $slug, $multifield, $object_type, $object
$this->_display_metadata_field( $display_field_slug, $field, $object_type, $object_id, $field_id, $value );
}
echo '<div class="clear"></div>';
printf( '<a title="%s" class="custom-metadata-multifield-clone hide-if-no-js" href="#">+</a>', __( 'duplicate this set of fields' ) );
printf( '<a title="%s" class="custom-metadata-multifield-clone hide-if-no-js" href="#"></a>', __( 'duplicate this set of fields' ) );

if ( $grouping_count > 1 ) {
printf( '<a title="%s" class="custom-metadata-multifield-delete hide-if-no-js" href="#">-</a>', __( 'remove this set of fields' ) );
printf( '<a title="%s" class="custom-metadata-multifield-delete hide-if-no-js" href="#"></a>', __( 'remove this set of fields' ) );
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be a good idea to leave the text in place for accessibility?

}

echo '</div>';
Expand Down