@@ -145,6 +145,7 @@ public function __construct( $attributes, $content = null, $form = null ) {
145
145
'optionstyles ' => null ,
146
146
'min ' => null ,
147
147
'max ' => null ,
148
+ 'startingvalue ' => null ,
148
149
'maxfiles ' => null ,
149
150
'fieldwrapperclasses ' => null ,
150
151
'stylevariationattributes ' => array (),
@@ -483,6 +484,9 @@ public function render() {
483
484
if ( is_numeric ( $ this ->get_attribute ( 'max ' ) ) ) {
484
485
$ extra_attrs ['max ' ] = $ this ->get_attribute ( 'max ' );
485
486
}
487
+ if ( is_numeric ( $ this ->get_attribute ( 'startingvalue ' ) ) ) {
488
+ $ extra_attrs ['startingvalue ' ] = $ this ->get_attribute ( 'startingvalue ' );
489
+ }
486
490
}
487
491
488
492
$ rendered_field = $ this ->render_field ( $ field_type , $ field_id , $ field_label , $ field_value , $ field_class , $ field_placeholder , $ field_required , $ field_required_text , $ extra_attrs );
@@ -2202,7 +2206,7 @@ public function render_slider_field( $id, $label, $value, $class, $required, $re
2202
2206
}
2203
2207
$ min = isset ( $ extra_attrs ['min ' ] ) ? $ extra_attrs ['min ' ] : 0 ;
2204
2208
$ max = isset ( $ extra_attrs ['max ' ] ) ? $ extra_attrs ['max ' ] : 100 ;
2205
- $ starting_value = isset ( $ extra_attrs ['startingValue ' ] ) ? $ extra_attrs ['startingValue ' ] : 50 ;
2209
+ $ starting_value = isset ( $ extra_attrs ['startingvalue ' ] ) ? $ extra_attrs ['startingvalue ' ] : 50 ;
2206
2210
$ current_value = ( $ value !== '' && $ value !== null ) ? $ value : $ starting_value ;
2207
2211
2208
2212
$ field = $ this ->render_label ( 'slider ' , $ id , $ label , $ required , $ required_field_text );
0 commit comments