Changeset 1341128
- Timestamp:
- 02/02/2016 03:54:34 AM (10 years ago)
- Location:
- kopatheme/trunk
- Files:
-
- 1 deleted
- 6 edited
-
includes/admin/class-kopa-admin-meta-box.php (modified) (3 diffs)
-
includes/admin/class-kopa-admin-term-meta-origin.php (deleted)
-
includes/admin/layouts/class-kopa-layout-post-type.php (modified) (1 diff)
-
includes/admin/layouts/class-kopa-layout-taxonomy.php (modified) (1 diff)
-
includes/class-kopa-frontend-assets.php (modified) (1 diff)
-
kopa-framework.php (modified) (1 diff)
-
readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
kopatheme/trunk/includes/admin/class-kopa-admin-meta-box.php
r1323880 r1341128 217 217 $value['type'] = 'text'; 218 218 } 219 $class = 'large-text'; 220 if( isset( $value['class'] ) && !empty( $value['class'] )){ 221 $class = esc_attr( $value['class'] ); 222 } 219 223 220 224 $output .= $option_wrap_start; 221 225 $output .= '<input 222 class=" large-text"226 class="' . esc_attr( $class ) . '" 223 227 type="'.esc_attr( $value['type'] ).'" 224 228 name="'.esc_attr( $value['id'] ).'" … … 398 402 $output .= $option_wrap_start; 399 403 $output .= '<input 400 class=" large-text kopa-framework-datetime"404 class="medium-text kopa-framework-datetime" 401 405 type="'.esc_attr( $value['type'] ).'" 402 406 name="'.esc_attr( $value['id'] ).'" … … 455 459 } 456 460 break; 461 462 case 'color': 463 if ( $advanced_field ) { 464 $default_color = ''; 465 $field_class = ''; 466 467 if ( 'color' === $value['type'] ) { 468 $field_class = ' kopa_color'; 469 470 if ( $value['default'] ) { 471 $default_color = ' data-default-color="' .esc_attr( $value['default'] ) . '" '; 472 } // end check empty option value 473 } // end check color type 474 475 $output .= $option_wrap_start; 476 $output .= '<input 477 class="'.esc_attr( $field_class ).'" 478 style="'.esc_attr( $value['css'] ).'" 479 type="'.esc_attr( $value['type'] ).'" 480 name="'.esc_attr( $value['id'] ).'" 481 id="'.esc_attr( $value['id'] ).'" 482 value="'.esc_attr( $option_value ).'"'. 483 $default_color.'>'; 484 $output .= $option_wrap_end; 485 } 486 break; 457 487 default: 458 488 $output .= apply_filters( 'kopa_admin_meta_box_field_' . $value['type'], '', $option_wrap_start, $option_wrap_end, $value, $option_value); -
kopatheme/trunk/includes/admin/layouts/class-kopa-layout-post-type.php
r1208795 r1341128 42 42 * @access public 43 43 */ 44 public function add_layout_box() { 45 $args = $this->layout_settings; 46 47 add_meta_box( 48 'kopa_custom_layout', 49 __( 'Custom Layout', 'kopa-framework' ), 50 array( $this, 'output_fields' ), 51 $args['screen'], 52 'normal', 53 'default', 54 $args 55 ); 56 } 44 public function add_layout_box() { 45 $args = $this->layout_settings; 46 $enable_custom = apply_filters('kopa_custom_use_page_layout_singular', true); 47 if ( isset($args['hide_in']) && $args['hide_in'] ) { 48 $enable_custom = false; 49 } 50 if ( $enable_custom ) { 51 add_meta_box( 52 'kopa_custom_layout', 53 __( 'Custom Layout', 'kopa-framework' ), 54 array( $this, 'output_fields' ), 55 $args['screen'], 56 'normal', 57 'default', 58 $args 59 ); 60 } 61 } 57 62 58 63 /** -
kopatheme/trunk/includes/admin/layouts/class-kopa-layout-taxonomy.php
r1208795 r1341128 31 31 */ 32 32 public function __construct( $layout_settings ) { 33 $this->layout_settings = $layout_settings; 34 add_action( $layout_settings['screen'] . '_edit_form_fields', array( $this, 'output_fields' ) ); 35 add_action( 'edit_term', array( $this, 'save_fields' ) ); 36 add_action( 'delete_term', array( $this, 'delete_fields' ) ); 33 $this->layout_settings = $layout_settings; 34 $enable_custom = apply_filters('kopa_custom_use_page_layout_taxonomy', true); 35 if ( isset($args['hide_in']) && $args['hide_in'] ) { 36 $enable_custom = false; 37 } 38 if ( $enable_custom ) { 39 add_action( $layout_settings['screen'] . '_edit_form_fields', array( $this, 'output_fields' ) ); 40 add_action( 'edit_term', array( $this, 'save_fields' ) ); 41 add_action( 'delete_term', array( $this, 'delete_fields' ) ); 42 } 37 43 } 38 44 -
kopatheme/trunk/includes/class-kopa-frontend-assets.php
r989825 r1341128 37 37 public function register_styles() { 38 38 wp_register_style( 'kopa_font_awesome', KF()->framework_url() . '/assets/css/font-awesome.css', array(), '4.0.3' ); 39 $enable_flaticon = apply_filters('kopa_front_enable_register_flaticon_font', false); 40 if ( $enable_flaticon ) { 41 wp_register_style( 'kopa_font_flaticon', KF()->framework_url() . '/assets/css/flaticon.css', array(), KOPA_FRAMEWORK_VERSION ); 42 } 39 43 } 40 44 -
kopatheme/trunk/kopa-framework.php
r1323880 r1341128 3 3 * Plugin Name: Kopa Framework 4 4 * Description: A WordPress framework by Kopatheme. 5 * Version: 1. 0.115 * Version: 1.1.0 6 6 * Author: Kopa Theme 7 7 * Author URI: http://kopatheme.com -
kopatheme/trunk/readme.txt
r1323880 r1341128 21 21 22 22 == Changelog == 23 24 = 1.1.0 = 25 * Add: filter 'kopa_front_enable_register_flaticon_font' to enable/disable register flaticon font. 26 * Add param 'hide_in' to enable hide custom layout for 'post type' and 'taxonomy' in edit mode 27 Example to hide custom layout for post type 'product' in edit mode. You can use: 28 $args[] = array( 29 'screen' => 'product', 30 'taxonomy' => false, 31 'layout' => 'product-single', 32 'hide_in' => true 33 ); 23 34 24 35 = 1.0.11 =
Note: See TracChangeset
for help on using the changeset viewer.