Skip to content

Commit 0167584

Browse files
committed
chore: ignores navigator warning
1 parent 18cc3e8 commit 0167584

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/forms/src/elements/common/Label.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,8 @@ export const Label = React.forwardRef<HTMLLabelElement, ILabelProps>((props, ref
8080
* See: https://bugzilla.mozilla.org/show_bug.cgi?id=559506
8181
*/
8282
const onLabelSelect = (e: React.KeyboardEvent<HTMLInputElement>) => {
83-
const isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
83+
// eslint-disable-next-line n/no-unsupported-features/node-builtins
84+
const isFirefox = navigator?.userAgent.toLowerCase().indexOf('firefox') > -1;
8485

8586
if (fieldContext && isFirefox && e.target instanceof Element) {
8687
const inputId = e.target.getAttribute('for');

0 commit comments

Comments
 (0)