Improve-auth-media (#1933)

* fix set power level broken after sdk update

* add media authentication hook

* fix service worker types

* fix service worker not working in dev mode

* fix env mode check when registering sw
This commit is contained in:
Ajay Bura authored and GitHub committed 2024-09-09 14:15:20 +05:30
1 parent 4dfce32730
commit 96df140153
38 files changed
+100 -124

No files matched your search

+10
View File
@@ -0,0 +1,10 @@
import { useSpecVersions } from './useSpecVersions';
export const useMediaAuthentication = (): boolean => {
const { versions } = useSpecVersions();
// Media authentication is introduced in spec version 1.11
const authenticatedMedia = versions.includes('v1.11');
return authenticatedMedia;
};