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
4 changes: 2 additions & 2 deletions classes/class-plugin-install.php
Original file line number Diff line number Diff line change
Expand Up @@ -376,9 +376,9 @@ public function render_menu() {
<div class="cp-plugin-search-form">
<form method="GET" action="<?php echo esc_url( add_query_arg( array( 'page' => 'classicpress-directory-integration-plugin-install' ), remove_query_arg( array( 'getpage' ) ) ) ); ?>">
<p class="cp-plugin-search-box">
<label for="searchfor" class="screen-reader-text" ><?php echo esc_html__( 'Search for plugins', 'classicpress-directory-integration' ); ?></label><br>
<label for="searchfor" class="screen-reader-text" ><?php echo esc_html__( 'Search for plugins', 'classicpress-directory-integration' ); ?></label>
<input type="hidden" name="searchingfor" value="<?php echo esc_html( $searching ); ?>">
<input type="search" id="searchfor" name="searchfor" class="wp-filter-search" <?php echo $searching !== '' ? 'value="' . esc_html( $searching ) . '" ' : ''; ?>placeholder="<?php echo esc_html__( 'Search for a plugin...', 'classicpress-directory-integration' ); ?>"><br>
<input type="search" id="searchfor" name="searchfor" class="wp-filter-search" <?php echo $searching !== '' ? 'value="' . esc_html( $searching ) . '" ' : ''; ?>placeholder="<?php echo esc_html__( 'Search for a plugin...', 'classicpress-directory-integration' ); ?>">
<?php
foreach ( (array) $_GET as $key => $val ) { //phpcs:ignore WordPress.Security.NonceVerification.Recommended
if ( in_array( $key, array( 'searchfor', 'getpage', 'searchingfor' ) ) ) {
Expand Down
4 changes: 2 additions & 2 deletions classes/class-theme-install.php
Original file line number Diff line number Diff line change
Expand Up @@ -368,9 +368,9 @@ public function render_menu() {
<div class="cp-plugin-search-form">
<form method="GET" action="<?php echo esc_url( add_query_arg( array( 'page' => 'classicpress-directory-integration-theme-install' ), remove_query_arg( array( 'getpage' ) ) ) ); ?>">
<p class="cp-plugin-search-box">
<label for="searchfor" class="screen-reader-text"><?php echo esc_html__( 'Search for a theme', 'classicpress-directory-integration' ); ?></label><br>
<label for="searchfor" class="screen-reader-text"><?php echo esc_html__( 'Search for a theme', 'classicpress-directory-integration' ); ?></label>
<input type="hidden" name="searchingfor" value="<?php echo esc_html( $searching ); ?>">
<input type="search" id="searchfor" name="searchfor" class="wp-filter-search" <?php echo $searching !== '' ? 'value="' . esc_html( $searching ) . '" ' : ''; ?>placeholder="<?php echo esc_html__( 'Search for a theme...', 'classicpress-directory-integration' ); ?>"><br>
<input type="search" id="searchfor" name="searchfor" class="wp-filter-search" <?php echo $searching !== '' ? 'value="' . esc_html( $searching ) . '" ' : ''; ?>placeholder="<?php echo esc_html__( 'Search for a theme...', 'classicpress-directory-integration' ); ?>">
<?php
foreach ( (array) $_GET as $key => $val ) { //phpcs:ignore WordPress.Security.NonceVerification.Recommended
if ( in_array( $key, array( 'searchfor', 'getpage', 'searchingfor' ) ) ) {
Expand Down
2 changes: 1 addition & 1 deletion scripts/directory-integration.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ document.addEventListener( 'DOMContentLoaded', function() {
status.id = 'plugin-install-from-modal';

dialog.showModal();
dialog.innerHTML = '<div id="plugin-information" style="width: ' + ( width * 9 / 10 ) + 'px;height: ' + ( height * 9 / 10 ) + 'px;" title="' + title + '"><button type="button" id="dialog-close-button" autofocus><span class="screen-reader-text">' + wp.i18n.__( 'Close' ) + '</span></button><div id="plugin-information-scrollable"><h2>' + header + '</h2>' + content + '<div style="height:60px"></div></div><div id="plugin-information-footer">' + status.outerHTML + '</div></div>';
dialog.innerHTML = '<div id="plugin-information" style="width: ' + ( width * 9 / 10 ) + 'px;height: ' + ( height * 9 / 10 ) + 'px;" title="' + title + '"><button type="button" id="dialog-close-button" autofocus><span class="screen-reader-text">' + wp.i18n.__( 'Close' ) + '</span></button><div id="plugin-information-scrollable"><div id="plugin-information-inner"><h2>' + header + '</h2>' + content + '</div></div><div id="plugin-information-footer">' + status.outerHTML + '</div></div>';

// Set initial focus on the "Close" button
closeButton = dialog.querySelector( '#dialog-close-button' );
Expand Down
29 changes: 20 additions & 9 deletions styles/directory-integration.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
margin-bottom: 1em;
}

.cp-plugin-search-box {
.cp-plugin-search-form {
float: right;
margin: -5em 0 0;
}

.plugin-install-tab .wp-header-end {
Expand Down Expand Up @@ -154,23 +153,23 @@
border: 2px solid #000;
}

#plugin-information-scrollable {
padding: 0 1.5em;
#plugin-information-inner {
padding: 0 1.5em 60px;
}

#plugin-information-scrollable h2 {
#plugin-information-inner h2 {
font-size: 2em;
}

#plugin-information-scrollable h4 {
#plugin-information-inner h4 {
font-size: 1.2em;
}

#plugin-information-scrollable h5 {
#plugin-information-inner h5 {
font-size: 1.1em;
}

#plugin-information-scrollable h6 {
#plugin-information-inner h6 {
font-size: 1.05em;
}

Expand All @@ -197,7 +196,6 @@

#plugin-install-from-modal {
float: right;
margin-top: -2px;
}

#plugin-information-footer .cp-plugin-installed {
Expand All @@ -215,3 +213,16 @@
height: unset;
}
}

@media (max-width: 782px) {
.cp-plugin-search-form {
float: none;
clear: both;
width: 100%;
margin: 0 0 3em;
}

.cp-plugin-search-box .wp-filter-search {
width: 100%;
}
}