gd-bs 6.6.40 → 6.6.41

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": "6.6.40",
3
+ "version": "6.6.41",
4
4
  "description": "Bootstrap JavaScript, TypeScript and Web Components library.",
5
5
  "main": "build/index.js",
6
6
  "typings": "src/index.d.ts",
@@ -631,8 +631,14 @@ export class FormControl implements IFormControl {
631
631
  if (this._el) {
632
632
  // See if this is a row
633
633
  if (this._el.parentElement && this._el.parentElement.parentElement && this._el.parentElement.parentElement.classList.contains("row")) {
634
- // Hide the row element
635
- this._el.parentElement.parentElement.classList.add("d-none");
634
+ // See if there are other controls in this row
635
+ if (this._el.parentElement.parentElement.querySelectorAll(".col").length > 1) {
636
+ // Hide the column element
637
+ this._el.parentElement.classList.add("d-none");
638
+ } else {
639
+ // Hide the row element
640
+ this._el.parentElement.parentElement.classList.add("d-none");
641
+ }
636
642
  }
637
643
  // Else, ensure the parent element exists
638
644
  else if (this._el.parentElement) {
@@ -734,8 +740,14 @@ export class FormControl implements IFormControl {
734
740
  if (this._el) {
735
741
  // See if this is a row
736
742
  if (this._el.parentElement && this._el.parentElement.parentElement && this._el.parentElement.parentElement.classList.contains("row")) {
737
- // Show the row element
738
- this._el.parentElement.parentElement.classList.remove("d-none");
743
+ // See if there are other controls in this row
744
+ if (this._el.parentElement.parentElement.querySelectorAll(".col").length > 1) {
745
+ // Show the column element
746
+ this._el.parentElement.classList.remove("d-none");
747
+ } else {
748
+ // Show the row element
749
+ this._el.parentElement.parentElement.classList.remove("d-none");
750
+ }
739
751
  }
740
752
  // Else, ensure the parent element exists
741
753
  else if (this._el.parentElement) {