coer-elements 2.0.58 → 2.0.59
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/components/lib/coer-checkbox/coer-checkbox.component.d.ts +1 -1
- package/components/lib/coer-dropdown/coer-dropdown.component.d.ts +1 -1
- package/components/lib/coer-grid/coer-grid-body/coer-grid-body.component.d.ts +1 -0
- package/components/lib/coer-grid/coer-grid-footer/coer-grid-footer.component.d.ts +5 -1
- package/components/lib/coer-grid/coer-grid-header/coer-grid-header.component.d.ts +8 -2
- package/components/lib/coer-grid/coer-grid.extension.d.ts +4 -0
- package/components/lib/coer-switch/coer-switch.component.d.ts +1 -1
- package/components/lib/coer-textarea/coer-textarea.component.d.ts +1 -1
- package/fesm2022/coer-elements-components.mjs +133 -60
- package/fesm2022/coer-elements-components.mjs.map +1 -1
- package/fesm2022/coer-elements-tools.mjs +32 -0
- package/fesm2022/coer-elements-tools.mjs.map +1 -1
- package/package.json +1 -1
- package/tools/lib/html-elements.tools.d.ts +10 -0
@@ -753,6 +753,13 @@ class HTMLElements {
|
|
753
753
|
}
|
754
754
|
}; }
|
755
755
|
/** */
|
756
|
+
static { this.GetOffsetTop = (element) => {
|
757
|
+
const HTML_ELEMENT = (typeof element === 'string') ? this.GetElement(element) : element;
|
758
|
+
return (HTML_ELEMENT)
|
759
|
+
? HTML_ELEMENT.offsetTop
|
760
|
+
: 0;
|
761
|
+
}; }
|
762
|
+
/** */
|
756
763
|
static { this.GetCssValue = (element, style) => {
|
757
764
|
const HTML_ELEMENT = (typeof element === 'string') ? this.GetElement(element) : element;
|
758
765
|
return (HTML_ELEMENT)
|
@@ -845,6 +852,31 @@ class HTMLElements {
|
|
845
852
|
}
|
846
853
|
return false;
|
847
854
|
}; }
|
855
|
+
/** */
|
856
|
+
static { this.HasChildren = (element) => {
|
857
|
+
return this.GetChildren(element).length > 0;
|
858
|
+
}; }
|
859
|
+
/** */
|
860
|
+
static { this.GetChildren = (element) => {
|
861
|
+
const HTML_ELEMENT = (typeof element === 'string') ? this.GetElement(element) : element;
|
862
|
+
return (HTML_ELEMENT)
|
863
|
+
? Array.from(HTML_ELEMENT?.children)
|
864
|
+
: [];
|
865
|
+
}; }
|
866
|
+
/** */
|
867
|
+
static { this.GetFather = (element) => {
|
868
|
+
const HTML_ELEMENT = (typeof element === 'string') ? this.GetElement(element) : element;
|
869
|
+
return (HTML_ELEMENT)
|
870
|
+
? HTML_ELEMENT.parentElement
|
871
|
+
: null;
|
872
|
+
}; }
|
873
|
+
/** */
|
874
|
+
static { this.GetGrandfather = (element) => {
|
875
|
+
const HTML_ELEMENT = (typeof element === 'string') ? this.GetElement(element) : element;
|
876
|
+
return (HTML_ELEMENT)
|
877
|
+
? HTML_ELEMENT.parentElement?.parentElement || null
|
878
|
+
: null;
|
879
|
+
}; }
|
848
880
|
}
|
849
881
|
;
|
850
882
|
|