Merge pull request #193 from mdruuu/patch-1

fixed getTabByRelPosition
Closes #192
This commit is contained in:
Thomas Brouard 2023-09-06 09:14:24 +02:00 committed by GitHub
commit 6b06e2d103
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -228,7 +228,7 @@ class TabGroup extends HTMLElement {
getTabByRelPosition(position: number) {
position = this.getActiveTab().getPosition() + position;
if (position <= 0) {
if (position < 0) {
return null;
}
return this.getTabByPosition(position);