LLMS_Form_Field::prepare_wrapper_classes()
Prepare CSS wrapper classes for the field.
Return Return
(void)
Source Source
File: includes/forms/class-llms-form-field.php
protected function prepare_wrapper_classes() { $defaults = array(); // Base field class. $defaults[] = 'llms-form-field'; // Add class for the field type. $defaults[] = sprintf( 'type-%s', $this->settings['type'] ); if ( $this->is_input_group() ) { $defaults[] = 'is-group'; } // Add columns classes. $defaults[] = sprintf( 'llms-cols-%d', $this->settings['columns'] ); if ( $this->settings['last_column'] ) { $defaults[] = 'llms-cols-last'; } // If required, add a class. if ( $this->settings['required'] ) { $defaults[] = 'llms-is-required'; } $this->settings['wrapper_classes'] = $this->classes_ensure_array( $this->settings['wrapper_classes'], $defaults ); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
5.0.0 | Introduced. |