Skip to content

Commit

Permalink
WIP: issue-867
Browse files Browse the repository at this point in the history
  • Loading branch information
nikkifurls committed May 2, 2024
1 parent a63b186 commit 1beab31
Show file tree
Hide file tree
Showing 15 changed files with 32 additions and 32 deletions.
4 changes: 2 additions & 2 deletions php/class-fieldmanager-autocomplete.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ class Fieldmanager_Autocomplete extends Fieldmanager_Field {
*
* @throws FM_Developer_Exception Must use a datasource.
*
* @param string $label The label.
* @param array $options The options for the field.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->attributes = array(
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-colorpicker.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ class Fieldmanager_Colorpicker extends Fieldmanager_Field {
/**
* Build the colorpicker object and enqueue assets.
*
* @param string $label The label to use.
* @param array $options The options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
fm_add_script( 'fm_colorpicker', 'js/fieldmanager-colorpicker.js', array( 'fm_loader', 'jquery', 'wp-color-picker' ), FM_VERSION, true );
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-datepicker.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ class Fieldmanager_Datepicker extends Fieldmanager_Field {
/**
* Construct default attributes and enqueue JavaScript.
*
* @param string $label Field label.
* @param array $options Associative array of class property values. @see Fieldmanager_Field::__construct().
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
fm_add_style( 'fm-jquery-ui', 'css/jquery-ui/jquery-ui-1.10.2.custom.min.css' );
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-draggablepost.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ class Fieldmanager_DraggablePost extends Fieldmanager_Field {
/**
* Add scripts and styles and other setup tasks.
*
* @param string $label The label.
* @param array $options The field options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
_deprecated_function( __METHOD__, '1.2.0' );
Expand Down
8 changes: 4 additions & 4 deletions php/class-fieldmanager-field.php
Original file line number Diff line number Diff line change
Expand Up @@ -401,8 +401,8 @@ public function form_element( $value ) {
* Superclass constructor, just populates options and sanity-checks common elements.
* It might also die, but only helpfully, to catch errors in development.
*
* @param string $label Title of form field.
* @param array $options With keys matching vars of the field in use.
* @param string|array $label The field label.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->set_options( $label, $options );
Expand All @@ -429,8 +429,8 @@ public function __construct( $label = '', $options = array() ) {
* @throws FM_Developer_Exception If an option is set but not defined in this class or the child class.
* @throws FM_Developer_Exception If an option is set but not public.
*
* @param string $label Title of form field.
* @param array $options With keys matching vars of the field in use.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function set_options( $label, $options ) {
if ( is_array( $label ) ) {
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-grid.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ class Fieldmanager_Grid extends Fieldmanager_Field {
/**
* Constructor which adds several scrips and CSS.
*
* @param string $label The form label.
* @param array $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
_deprecated_function( __METHOD__, '1.4.0' );
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-group.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,8 @@ class Fieldmanager_Group extends Fieldmanager_Field {
*
* @throws FM_Developer_Exception Not serializing data with repeatable groups.
*
* @param string $label The form label.
* @param array $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {

Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-link.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ class Fieldmanager_Link extends Fieldmanager_Textfield {
/**
* Construct default attributes, set link sanitizer.
*
* @param string $label The form label.
* @param array $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->sanitize = 'esc_url_raw';
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-media.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ class Fieldmanager_Media extends Fieldmanager_Field {
/**
* Construct default attributes.
*
* @param string $label The form label.
* @param array $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->button_label = __( 'Attach a File', 'fieldmanager' );
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-options.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ abstract class Fieldmanager_Options extends Fieldmanager_Field {
/**
* Add CSS, construct parent.
*
* @param string $label The form label.
* @param mixed $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->sanitize = array( $this, 'sanitize' );
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-password.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ class Fieldmanager_Password extends Fieldmanager_Field {
/**
* Override constructor to set default size.
*
* @param string $label Field label.
* @param array $options Associative array of class property values. @see Fieldmanager_Field::__construct().
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->attributes = array(
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-richtextarea.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@ class Fieldmanager_RichTextArea extends Fieldmanager_Field {
/**
* Construct defaults for this field.
*
* @param string $label Title of form field.
* @param array $options With keys matching vars of the field in use.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->sanitize = array( $this, 'sanitize' );
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-select.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ class Fieldmanager_Select extends Fieldmanager_Options {
/**
* Override constructor to add chosen.js maybe.
*
* @param string $label The form label.
* @param array $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {

Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-textarea.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ class Fieldmanager_TextArea extends Fieldmanager_Field {
/**
* Construct default attributes; 50x10 textarea.
*
* @param string $label Field label.
* @param array $options Associative array of class property values. @see Fieldmanager_Field::__construct().
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->attributes = array(
Expand Down
4 changes: 2 additions & 2 deletions php/class-fieldmanager-textfield.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ class Fieldmanager_TextField extends Fieldmanager_Field {
/**
* Override constructor to set default size.
*
* @param string $label The form label.
* @param array $options The form options.
* @param string|array $label The field label. A provided string sets $options['label'], while an array sets $options, overriding any existing data in $options.
* @param array $options The field options.
*/
public function __construct( $label = '', $options = array() ) {
$this->attributes = array(
Expand Down

0 comments on commit 1beab31

Please sign in to comment.