├── .nvmrc ├── DailyPlayground ├── .nvmrc ├── .gitattributes ├── src │ ├── components │ │ ├── Icons │ │ │ ├── index.ts │ │ │ └── ScreenshareIcon.tsx │ │ ├── StartButton │ │ │ └── StartButton.tsx │ │ ├── CopyLinkButton │ │ │ └── CopyLinkButton.tsx │ │ ├── CallMessage │ │ │ └── CallMessage.tsx │ │ ├── Button │ │ │ └── Button.tsx │ │ ├── TrayButton │ │ │ └── TrayButton.tsx │ │ ├── CallPanel │ │ │ ├── callState.ts │ │ │ └── CallPanel.tsx │ │ ├── Tray │ │ │ └── Tray.tsx │ │ ├── Tile │ │ │ └── Tile.tsx │ │ └── App │ │ │ └── App.tsx │ ├── CallObjectContext.ts │ ├── useCallObject.ts │ ├── theme.ts │ ├── utils.ts │ ├── useOrientation.ts │ ├── api.ts │ └── useMeetingState.ts ├── tsconfig.json ├── assets │ ├── mic.png │ ├── camera.png │ ├── close.png │ ├── error.png │ ├── icon.png │ ├── leave.png │ ├── logo.png │ ├── mic@2x.png │ ├── mic@3x.png │ ├── close@2x.png │ ├── close@3x.png │ ├── error@2x.png │ ├── error@3x.png │ ├── leave@2x.png │ ├── leave@3x.png │ ├── logo@2x.png │ ├── logo@3x.png │ ├── mic-off.png │ ├── camera-off.png │ ├── camera@2x.png │ ├── camera@3x.png │ ├── mic-off@2x.png │ ├── mic-off@3x.png │ ├── camera-off@2x.png │ └── camera-off@3x.png ├── .prettierrc.js ├── metro.config.js ├── .gitignore ├── index.js ├── app.json └── package.json ├── xcode-screenshot.png ├── docsAssets ├── xcode-signing.png └── xcode-accounts.png ├── debuggerWorker-screenshot.png ├── .gitignore └── README.md /.nvmrc: -------------------------------------------------------------------------------- 1 | 20 -------------------------------------------------------------------------------- /DailyPlayground/.nvmrc: -------------------------------------------------------------------------------- 1 | 22.14 2 | -------------------------------------------------------------------------------- /DailyPlayground/.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | -------------------------------------------------------------------------------- /DailyPlayground/src/components/Icons/index.ts: -------------------------------------------------------------------------------- 1 | export { ScreenShareIcon } from './ScreenshareIcon'; 2 | -------------------------------------------------------------------------------- /DailyPlayground/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": {}, 3 | "extends": "expo/tsconfig.base" 4 | } 5 | -------------------------------------------------------------------------------- /xcode-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/xcode-screenshot.png -------------------------------------------------------------------------------- /docsAssets/xcode-signing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/docsAssets/xcode-signing.png -------------------------------------------------------------------------------- /DailyPlayground/assets/mic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/mic.png -------------------------------------------------------------------------------- /debuggerWorker-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/debuggerWorker-screenshot.png -------------------------------------------------------------------------------- /docsAssets/xcode-accounts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/docsAssets/xcode-accounts.png -------------------------------------------------------------------------------- /DailyPlayground/assets/camera.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/camera.png -------------------------------------------------------------------------------- /DailyPlayground/assets/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/close.png -------------------------------------------------------------------------------- /DailyPlayground/assets/error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/error.png -------------------------------------------------------------------------------- /DailyPlayground/assets/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/icon.png -------------------------------------------------------------------------------- /DailyPlayground/assets/leave.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/leave.png -------------------------------------------------------------------------------- /DailyPlayground/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/logo.png -------------------------------------------------------------------------------- /DailyPlayground/assets/mic@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/mic@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/mic@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/mic@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/close@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/close@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/close@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/close@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/error@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/error@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/error@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/error@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/leave@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/leave@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/leave@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/leave@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/logo@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/logo@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/logo@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/mic-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/mic-off.png -------------------------------------------------------------------------------- /DailyPlayground/assets/camera-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/camera-off.png -------------------------------------------------------------------------------- /DailyPlayground/assets/camera@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/camera@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/camera@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/camera@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/mic-off@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/mic-off@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/mic-off@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/mic-off@3x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/camera-off@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/camera-off@2x.png -------------------------------------------------------------------------------- /DailyPlayground/assets/camera-off@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daily-co/react-native-daily-js-playground/HEAD/DailyPlayground/assets/camera-off@3x.png -------------------------------------------------------------------------------- /DailyPlayground/src/CallObjectContext.ts: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { DailyCall } from '@daily-co/react-native-daily-js'; 3 | 4 | export default React.createContext(null); 5 | -------------------------------------------------------------------------------- /DailyPlayground/src/useCallObject.ts: -------------------------------------------------------------------------------- 1 | import { useContext } from 'react'; 2 | import CallObjectContext from './CallObjectContext'; 3 | 4 | export function useCallObject() { 5 | return useContext(CallObjectContext); 6 | } 7 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Artifacts from `npm pack` 2 | *.tgz 3 | 4 | # OSX 5 | *.DS_Store 6 | 7 | # Browserstack automated testing 8 | */bs_app_url.txt 9 | DailyPlayground/android/browserstackAPKs/* 10 | 11 | # dev scripts 12 | DailyPlayground/dev_scripts/variables.sh -------------------------------------------------------------------------------- /DailyPlayground/.prettierrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | semi: true, 3 | tabWidth: 2, 4 | useTabs: false, 5 | arrowParens: 'avoid', 6 | bracketSameLine: true, 7 | bracketSpacing: false, 8 | singleQuote: true, 9 | trailingComma: 'all', 10 | }; 11 | -------------------------------------------------------------------------------- /DailyPlayground/metro.config.js: -------------------------------------------------------------------------------- 1 | // Learn more https://docs.expo.io/guides/customizing-metro 2 | const { getDefaultConfig } = require('expo/metro-config'); 3 | 4 | /** @type {import('expo/metro-config').MetroConfig} */ 5 | const config = getDefaultConfig(__dirname); 6 | 7 | module.exports = config; 8 | -------------------------------------------------------------------------------- /DailyPlayground/src/theme.ts: -------------------------------------------------------------------------------- 1 | const theme = { 2 | colors: { 3 | blueDark: '#121a24', 4 | green: '#72cc18', 5 | grey: '#c8d1dc', 6 | greyDark: '#7b848f', 7 | greyLight: '#e6eaef', 8 | greyLightest: '#f7f9fa', 9 | red: '#e71115', 10 | white: '#ffffff', 11 | }, 12 | fontFamily: { 13 | body: 'Helvetica Neue', 14 | }, 15 | fontSize: { 16 | base: 16, 17 | }, 18 | }; 19 | 20 | export default theme; 21 | -------------------------------------------------------------------------------- /DailyPlayground/src/utils.ts: -------------------------------------------------------------------------------- 1 | import { Platform } from 'react-native'; 2 | import { DailyEventObject } from '@daily-co/react-native-daily-js'; 3 | 4 | export function logDailyEvent(event?: DailyEventObject) { 5 | event && console.log('[daily.co event]', event.action); 6 | } 7 | 8 | /** 9 | * For automated testing on browserstack / appium / wd. 10 | * 11 | */ 12 | export function robotID(id?: string) { 13 | if (!id) id = ''; 14 | // *coming soon* ios support 15 | return Platform.OS === 'ios' ? { } : { accessibilityLabel: id }; 16 | } 17 | -------------------------------------------------------------------------------- /DailyPlayground/.gitignore: -------------------------------------------------------------------------------- 1 | # Learn more https://docs.github.com/en/get-started/getting-started-with-git/ignoring-files 2 | 3 | # dependencies 4 | node_modules/ 5 | 6 | # Expo 7 | .expo/ 8 | dist/ 9 | web-build/ 10 | expo-env.d.ts 11 | android/ 12 | ios/ 13 | 14 | # Native 15 | *.orig.* 16 | *.jks 17 | *.p8 18 | *.p12 19 | *.key 20 | *.mobileprovision 21 | 22 | # Metro 23 | .metro-health-check* 24 | 25 | # debug 26 | npm-debug.* 27 | yarn-debug.* 28 | yarn-error.* 29 | 30 | # macOS 31 | .DS_Store 32 | *.pem 33 | 34 | # local env files 35 | .env*.local 36 | 37 | # typescript 38 | *.tsbuildinfo 39 | -------------------------------------------------------------------------------- /DailyPlayground/src/useOrientation.ts: -------------------------------------------------------------------------------- 1 | import React, { useState, useEffect, useCallback } from 'react'; 2 | import { Dimensions, ScaledSize, useWindowDimensions } from 'react-native'; 3 | 4 | export enum Orientation { 5 | Portrait, 6 | Landscape, 7 | } 8 | 9 | const computeOrientation = (windowDimensions: ScaledSize): Orientation => { 10 | return windowDimensions.height >= windowDimensions.width 11 | ? Orientation.Portrait 12 | : Orientation.Landscape; 13 | }; 14 | 15 | export const useOrientation = (): Orientation => { 16 | const windowDimensions = useWindowDimensions(); 17 | return computeOrientation(windowDimensions); 18 | }; 19 | -------------------------------------------------------------------------------- /DailyPlayground/index.js: -------------------------------------------------------------------------------- 1 | import {registerRootComponent} from 'expo'; 2 | 3 | // Enable debug logs 4 | /*window.localStorage = window.localStorage || {}; 5 | window.localStorage.debug = '*'; 6 | window.localStorage.getItem = (itemName) => { 7 | console.log('Requesting the localStorage item ', itemName); 8 | return window.localStorage[itemName]; 9 | };*/ 10 | 11 | //Disable webrtc logs 12 | /*import debug from 'debug'; 13 | debug.disable('rn-webrtc:*');*/ 14 | 15 | import App from './src/components/App/App'; 16 | 17 | // registerRootComponent calls AppRegistry.registerComponent('main', () => App); 18 | // It also ensures that whether you load the app in Expo Go or in a native build, 19 | // the environment is set up appropriately 20 | registerRootComponent(App); 21 | -------------------------------------------------------------------------------- /DailyPlayground/src/components/Icons/ScreenshareIcon.tsx: -------------------------------------------------------------------------------- 1 | import * as React from 'react'; 2 | import Svg, { SvgProps, Path } from 'react-native-svg'; 3 | /* SVGR has dropped some elements not supported by react-native-svg: title */ 4 | 5 | export const ScreenShareIcon = (props: SvgProps) => ( 6 | 7 | 11 | 12 | ); 13 | -------------------------------------------------------------------------------- /DailyPlayground/src/components/StartButton/StartButton.tsx: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import Button from '../Button/Button'; 3 | import { StyleSheet, View } from 'react-native'; 4 | 5 | type Props = { 6 | onPress: () => void; 7 | disabled: boolean; 8 | starting: boolean; 9 | robotId?: string; 10 | }; 11 | 12 | const StartButton = ({ onPress, disabled, starting }: Props) => { 13 | return ( 14 | 15 |