We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 16212ee commit 141781eCopy full SHA for 141781e
elements/pf-label-group/pf-label-group.ts
@@ -108,10 +108,15 @@ export class PfLabelGroup extends LitElement {
108
})
109
private _categorySlotted?: HTMLElement[];
110
111
- get #labels(): NodeListOf<PfLabel> {
+ get #labels(): NodeListOf<PfLabel> | PfLabel[] {
112
+ const isServer = typeof window === 'undefined' || !('document' in globalThis);
113
+ if (isServer) {
114
+ return [] as PfLabel[];
115
+ }
116
return this.querySelectorAll<PfLabel>('pf-label:not([slot]):not([overflow-label])');
117
}
118
119
+
120
#tabindex = RovingTabindexController.of(this, {
121
getItems: () => [
122
...Array.prototype.slice.call(
0 commit comments