Skip to content

Commit

Permalink
Remove wrappers & fix h3 size
Browse files Browse the repository at this point in the history
  • Loading branch information
aristath committed Jul 8, 2024
1 parent d6bbfd4 commit 93c3373
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 23 deletions.
10 changes: 7 additions & 3 deletions assets/css/admin.css
Original file line number Diff line number Diff line change
Expand Up @@ -1098,14 +1098,18 @@ button.prpl-info-icon {
/*------------------------------------*\
Settings popup.
\*------------------------------------*/
.popup-settings-wrapper label {
#prpl-settings-form label {
display: block;
}

.popup-settings-wrapper form p {
#prpl-settings-form p {
max-width: 42em;
}

.popup-settings-wrapper form button.button-primary {
#prpl-settings-form h3 {
font-size: 1.15em;
}

#prpl-settings-form button.button-primary {
margin-top: 1em;
}
36 changes: 16 additions & 20 deletions classes/popups/class-settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,27 +48,23 @@ protected function the_content() {

<h2><?php \esc_html_e( 'Settings', 'progress-planner' ); ?></h2>

<div class="prpl-widgets-container">
<div class="prpl-widget-wrapper popup-settings-wrapper">
<form id="prpl-settings-form">
<h3><?php \esc_html_e( 'Exclude Post Types', 'progress-planner' ); ?></h3>
<p><?php \esc_html_e( 'Select the post types you want to exclude from activity scores. This setting will affect which post-type activities get tracked.', 'progress-planner' ); ?></p>
<?php foreach ( $post_types as $post_type ) : ?>
<label>
<input
type="checkbox"
name="prpl-settings-post-types-exclude[]"
value="<?php echo \esc_attr( $post_type ); ?>"
<?php checked( \in_array( $post_type, $saved_settings, true ) ); ?>
/>
<?php echo \esc_html( \get_post_type_object( $post_type )->labels->name ); ?>
</label>
<?php endforeach; ?>
<form id="prpl-settings-form">
<h3><?php \esc_html_e( 'Exclude Post Types', 'progress-planner' ); ?></h3>
<p><?php \esc_html_e( 'Select the post types you want to exclude from activity scores. This setting will affect which post-type activities get tracked.', 'progress-planner' ); ?></p>
<?php foreach ( $post_types as $post_type ) : ?>
<label>
<input
type="checkbox"
name="prpl-settings-post-types-exclude[]"
value="<?php echo \esc_attr( $post_type ); ?>"
<?php checked( \in_array( $post_type, $saved_settings, true ) ); ?>
/>
<?php echo \esc_html( \get_post_type_object( $post_type )->labels->name ); ?>
</label>
<?php endforeach; ?>

<button id="submit-exclude-post-types" class="button button-primary"><?php \esc_html_e( 'Save', 'progress-planner' ); ?></button>
</form>
</div>
</div>
<button id="submit-exclude-post-types" class="button button-primary"><?php \esc_html_e( 'Save', 'progress-planner' ); ?></button>
</form>
<?php
}
}

0 comments on commit 93c3373

Please sign in to comment.