mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-07-07 11:15:44 +03:00
Update display to use new design
This commit is contained in:
parent
5a72ff8b53
commit
5d4d1b7f4c
3 changed files with 74 additions and 38 deletions
|
@ -11,39 +11,64 @@ use function WordPressDotOrg\FiveForTheFuture\get_views_path;
|
|||
<script type="text/template" id="tmpl-5ftf-contributor-lists">
|
||||
<# if ( data.publish.length ) { #>
|
||||
<h3 class="contributor-list-heading"><?php esc_html_e( 'Confirmed', 'wporg' ); ?></h3>
|
||||
<ul class="contributor-list publish">{{{ data.publish }}}</ul>
|
||||
<table class="contributor-list publish striped widefat">
|
||||
<thead>
|
||||
<th scope="col"><?php esc_html_e( 'Contributor', 'wporg-5ftf' ); ?></th>
|
||||
<th scope="col"><?php esc_html_e( 'Date Confirmed', 'wporg-5ftf' ); ?></th>
|
||||
<th scope="col"><?php esc_html_e( 'Remove Contributor', 'wporg-5ftf' ); ?></th>
|
||||
</thead>
|
||||
<tbody>{{{ data.publish }}}</tbody>
|
||||
</table>
|
||||
<# } #>
|
||||
<# if ( data.pending.length ) { #>
|
||||
<h3 class="contributor-list-heading"><?php esc_html_e( 'Unconfirmed', 'wporg' ); ?></h3>
|
||||
<ul class="contributor-list pending">{{{ data.pending }}}</ul>
|
||||
<table class="contributor-list pending striped widefat">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col"><?php esc_html_e( 'Contributor', 'wporg-5ftf' ); ?></th>
|
||||
<th scope="col"><?php esc_html_e( 'Resend Confirmation', 'wporg-5ftf' ); ?></th>
|
||||
<th scope="col"><?php esc_html_e( 'Remove Contributor', 'wporg-5ftf' ); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>{{{ data.pending }}}</tbody>
|
||||
</table>
|
||||
<# } #>
|
||||
</script>
|
||||
|
||||
<script type="text/template" id="tmpl-5ftf-contributor">
|
||||
<li>
|
||||
<button
|
||||
class="button-link button-link-delete"
|
||||
data-action="remove-contributor"
|
||||
data-contributor-post="{{ data.contributorId }}"
|
||||
data-confirm="{{ data.removeConfirm }}"
|
||||
aria-label="{{ data.removeLabel }}"
|
||||
>
|
||||
<span class="dashicons dashicons-no-alt" aria-hidden="true"></span>
|
||||
</button>
|
||||
{{{ data.avatar }}}
|
||||
<span class="contributor-list__name">
|
||||
{{ data.name }}
|
||||
</span>
|
||||
<tr>
|
||||
<th scope="row">
|
||||
{{{ data.avatar }}}
|
||||
<span class="contributor-list__name">
|
||||
{{ data.displayName }} ({{ data.name }})
|
||||
</span>
|
||||
</th>
|
||||
<# if ( 'pending' === data.status ) { #>
|
||||
<button
|
||||
class="button"
|
||||
data-action="resend-contributor-confirmation"
|
||||
data-contributor-post="{{ data.contributorId }}"
|
||||
>
|
||||
{{ data.resendLabel }}
|
||||
</button>
|
||||
<td>
|
||||
<button
|
||||
class="button"
|
||||
data-action="resend-contributor-confirmation"
|
||||
data-contributor-post="{{ data.contributorId }}"
|
||||
>
|
||||
{{ data.resendLabel }}
|
||||
</button>
|
||||
</td>
|
||||
<# } else { #>
|
||||
<td>{{ data.publishDate }}</td>
|
||||
<# } #>
|
||||
</li>
|
||||
<td>
|
||||
<button
|
||||
class="button-link button-link-delete"
|
||||
data-action="remove-contributor"
|
||||
data-contributor-post="{{ data.contributorId }}"
|
||||
data-confirm="{{ data.removeConfirm }}"
|
||||
aria-label="{{ data.removeLabel }}"
|
||||
>
|
||||
<span class="dashicons dashicons-no-alt" aria-hidden="true"></span>
|
||||
<?php esc_html_e( 'Remove', 'wporg-5ftf' ); ?>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</script>
|
||||
|
||||
<div id="5ftf-contributors">
|
||||
|
@ -60,8 +85,6 @@ use function WordPressDotOrg\FiveForTheFuture\get_views_path;
|
|||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<hr />
|
||||
|
||||
<?php
|
||||
$data = [ 'pledge-contributors' => '' ];
|
||||
require get_views_path() . 'inputs-pledge-contributors.php';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue