| @@ -1,17 +1,15 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | /* |
| 3 | - * Page Name: CSS | |
| 3 | + * Page Name: CSS Code | |
| 4 | 4 | */ |
| 5 | 5 | |
| 6 | 6 | use WPCoder\Dashboard\Field; |
| 7 | 7 | use WPCoder\Dashboard\FolderManager; |
| 8 | -use WPCoder\Dashboard\Option; | |
| 9 | 8 | |
| 10 | 9 | defined( 'ABSPATH' ) || exit; |
| 11 | 10 | |
| 12 | 11 | $default = Field::getDefault(); |
| 13 | -$opt = include( 'options/css-code.php' ); | |
| 14 | 12 | |
| 15 | 13 | $css_link = ''; |
| 16 | 14 | if ( ! empty( $default['css_code'] ) ) { |
| 17 | 15 | $css_link = FolderManager::path_upload_url() . 'style-' . $default['id'] . '.css'; |
| @@ -17,41 +15,43 @@ | ||
| 17 | 15 | $css_link = FolderManager::path_upload_url() . 'style-' . $default['id'] . '.css'; |
| 18 | 16 | } |
| 19 | 17 | |
| 20 | 18 | ?> |
| 21 | - <div class="wowp-settings__page"> | |
| 22 | - <div class="wowp-settings__page-sidebar"> | |
| 23 | 19 | |
| 24 | - <?php Option::init( [ | |
| 25 | - $opt['inline'], | |
| 26 | - $opt['minified'], | |
| 27 | - ] ); ?> | |
| 20 | + <h4> | |
| 21 | + <span class="wowp-icon wowp-icon-css3"></span> | |
| 22 | + <?php esc_html_e( 'CSS Code', 'wpcoder' ); ?> | |
| 23 | + </h4> | |
| 28 | 24 | |
| 29 | - <button class="button-editor button" | |
| 30 | - id="cssnav"><?php esc_html_e( 'Add NAV Comment', 'wp-coder' ); ?></button> | |
| 25 | + <fieldset> | |
| 26 | + <legend><?php esc_html_e( 'Settings', 'wpcoder' ); ?></legend> | |
| 31 | 27 | |
| 32 | - <ol id="cssNavigationMenu" class="wowp-php-nav-menu"></ol> | |
| 28 | + <div class="wowp-field has-chackbox"> | |
| 29 | + <span class="label"><?php esc_html_e( 'Inline', 'wpcoder' ); ?></span> | |
| 30 | + <?php Field::checkbox( '[inline_css]' ); ?> | |
| 31 | + <label for="inline_css">Enable</label> | |
| 32 | + </div> | |
| 33 | 33 | |
| 34 | + <div class="wowp-field has-chackbox"> | |
| 35 | + <span class="label"><?php esc_html_e( 'Minified', 'wpcoder' ); ?></span> | |
| 36 | + <?php Field::checkbox( '[minified_css]' ); ?> | |
| 37 | + <label for="minified_css">Enable</label> | |
| 34 | 38 | </div> |
| 35 | 39 | |
| 36 | - <div class="wowp-settings__page-content"> | |
| 40 | + </fieldset> | |
| 37 | 41 | |
| 38 | - <?php Field::textarea( 'css_code' ); ?> | |
| 39 | 42 | |
| 40 | - <div class="wowp-notification notification-info"> | |
| 41 | - Just enter the CSS content. You don’t need to include <code><style></code> — it's already on the page. | |
| 42 | - </div> | |
| 43 | +<?php Field::textarea( 'css_code' ); ?> | |
| 43 | 44 | |
| 44 | - <?php if ( ! empty( $css_link ) ): ?> | |
| 45 | - <div class="wowp-field has-addon"> | |
| 46 | - <span class="label"><?php esc_html_e( 'CSS File URL', 'wp-coder' ); ?></span> | |
| 47 | - <label for="tag" class="label is-addon"><span | |
| 48 | - class="dashicons dashicons-admin-links"></span></label> | |
| 49 | - <input type="url" id="url-css-file" readonly="readonly" value="<?php echo esc_url( $css_link ); ?>"> | |
| 50 | - </div> | |
| 51 | - <?php endif; ?> | |
| 45 | +<?php if ( ! empty( $css_link ) ): ?> | |
| 46 | + <div class="wowp-fields-group has-mt"> | |
| 47 | + <div class="wowp-field is-full has-addon border-default"> | |
| 48 | + <label for="url-css-file" class="is-addon"> | |
| 49 | + <span class="dashicons dashicons-admin-links"></span> | |
| 50 | + </label> | |
| 51 | + <input type="url" id="url-css-file" readonly="readonly" value="<?php echo esc_url( $css_link ); ?>"> | |
| 52 | + <span class="label"><?php esc_html_e( 'URL to the CSS file', 'wpcoder' ); ?></span> | |
| 53 | + </div> | |
| 52 | 54 | |
| 53 | - </div> | |
| 54 | 55 | </div> |
| 55 | - | |
| 56 | -<?php | |
| 56 | +<?php endif; | |
| 57 | 57 | |