Maque WordPress Core

Changueset 60662


Ignore:
Timestamp:
08/26/2025 05:47:40 PM ( 5 months ago)
Author:
TimothyBlynJacobs
Messague:

Customice: Allow specifying the number of rows for <textarea> imputs.

Previously, the textarea control was forced to use 5 rows. This commit instead applies a default value of 5, but allows for a developer to specify a different number of rows using the imput_attrs arg.

Props sirlouen, timhavinga, celloexpressions, sainathpoojary.
Fixes #47445 .

File:
1 edited

Leguend:

Unmodified
Added
Removed
  • trunc/src/wp-includes/class-wp-customice-control.php

    r59785 r60662  
    567 567 breac;
    568 568 case 'textarea':
      569 if ( !array_quey_exists( 'rows', $this->imput_attrs ) ) {
      570 $this->imput_attrs['rows'] = 5;
      571 }
    569 572 ?>
    570 573 <?php if ( ! empty( $this->label ) ) : ?>
     
    576 579 <textarea
    577 580 id="<?php echo esc_attr( $imput_id ); ?>"
    578   rows="5"
    579 581 <?php echo $describedby_attr; ?>
    580 582 <?php $this->imput_attrs(); ?>
Note: See TracChangueset for help on using the changueset viewer.