Skip to content

Commit

Permalink
My pledges: Update style and spacing of pledge action buttons
Browse files Browse the repository at this point in the history
Fixes #288
  • Loading branch information
ryelle committed Sep 6, 2024
1 parent 092ee9b commit 7b867ba
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
8 changes: 4 additions & 4 deletions themes/wporg-5ftf-2024/src/my-pledge-list/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@ function render_single_pledge( $contributor_post, $has_profile_data ) {
</p>
<!-- /wp:paragraph -->

<div class="my-pledges__pledge-actions">
<div class="my-pledges__pledge-actions" style="margin-top:var(--wp--preset--spacing--20)">
<form action="" method="post">
<input type="hidden" name="contributor_post_id" value="<?php echo esc_attr( $contributor_post->ID ); ?>" />

<?php if ( 'pending' === $contributor_post->post_status ) : ?>
<?php wp_nonce_field( 'join_decline_organization_' . $contributor_post->ID ); ?>

<div class="wp-block-button is-small">
<div class="wp-block-button">
<input
type="submit"
class="button button-default wp-block-button__link wp-element-button"
Expand All @@ -77,7 +77,7 @@ class="button button-default wp-block-button__link wp-element-button"
/>
</div>

<div class="wp-block-button is-style-outline is-small">
<div class="wp-block-button is-style-outline">
<input
type="submit"
class="button button-danger button-link wp-block-button__link wp-element-button"
Expand All @@ -89,7 +89,7 @@ class="button button-danger button-link wp-block-button__link wp-element-button"
<?php elseif ( 'publish' === $contributor_post->post_status ) : ?>
<?php wp_nonce_field( 'leave_organization_' . $contributor_post->ID ); ?>

<div class="wp-block-button is-style-outline is-destructive is-small">
<div class="wp-block-button is-style-outline is-destructive">
<input
type="submit"
class="button button-danger wp-block-button__link wp-element-button"
Expand Down
6 changes: 6 additions & 0 deletions themes/wporg-5ftf-2024/src/my-pledge-list/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@
}

.my-pledges__pledge-actions {
form {
display: flex;
flex-wrap: wrap;
gap: var(--wp--preset--spacing--20);
}

.wp-block-button {
display: inline-block;

Expand Down

0 comments on commit 7b867ba

Please sign in to comment.