gd-bs 5.4.6 → 5.4.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gd-bs",
3
- "version": "5.4.6",
3
+ "version": "5.4.7",
4
4
  "description": "Bootstrap JavaScript, TypeScript and Web Components library.",
5
5
  "main": "build/index.js",
6
6
  "typings": "src/index.d.ts",
@@ -114,10 +114,10 @@ export const FormValidationTypes: IFormValidationTypes;
114
114
  */
115
115
  export interface IForm {
116
116
  /** Appends controls to the form */
117
- appendControls: (controls: Array<IFormControlProps>) => Array<IFormControl>;
117
+ appendControls: (controls: Array<IFormControlProps>) => void;
118
118
 
119
119
  /** Appends rows to the form */
120
- appendRows: (rows: Array<IFormRow>) => Array<IFormControl>;
120
+ appendRows: (rows: Array<IFormRow>) => void;
121
121
 
122
122
  /** The form controls */
123
123
  controls: Array<IFormControl>;
@@ -44,7 +44,7 @@ export class FormGroup {
44
44
 
45
45
  // Update the property
46
46
  this._props.onControlRendering = onControlRendering;
47
- })
47
+ });
48
48
  });
49
49
  }
50
50
 
@@ -89,41 +89,25 @@ class _Form extends Base<IFormProps> implements IForm {
89
89
  */
90
90
 
91
91
  // Append controls to the form
92
- appendControls(controls: Array<IFormControlProps> = []): Array<IFormControl> {
93
- let addedControls: Array<IFormControl> = [];
94
-
92
+ appendControls(controls: Array<IFormControlProps> = []) {
95
93
  // Parse the controls
96
94
  for (let i = 0; i < controls.length; i++) {
97
95
  // Create the group
98
96
  let group = new FormGroup(controls[i], this.props);
99
97
  this._groups.push(group);
100
98
  this.el.appendChild(group.el);
101
-
102
- // Append the control
103
- addedControls.push(group.control);
104
99
  }
105
-
106
- // Return the controls
107
- return addedControls;
108
100
  }
109
101
 
110
102
  // Append rows to the form
111
103
  appendRows(rows: Array<IFormRow> = []) {
112
- let addedControls: Array<IFormControl> = [];
113
-
114
104
  // Parse the rows
115
105
  for (let i = 0; i < rows.length; i++) {
116
106
  // Create the row
117
107
  let row = new FormRow(rows[i], this.props);
118
108
  this._rows.push(row);
119
109
  this.el.appendChild(row.el);
120
-
121
- // Append the control
122
- addedControls = addedControls.concat(row.controls);
123
110
  }
124
-
125
- // Return the controls
126
- return addedControls;
127
111
  }
128
112
 
129
113
  // The forms controls