mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-11-10 09:10:29 +03:00
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:
parent
4dfce32730
commit
96df140153
38 changed files with 100 additions and 124 deletions
10
src/app/hooks/useMediaAuthentication.ts
Normal file
10
src/app/hooks/useMediaAuthentication.ts
Normal 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;
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue