151 feat youtube embed iframe (#176)

* youtube embed iframe temp commit

* Fixes styling and code cleanup

* lint

* Now clicking between the pause and settings button doesn't trigger the parent

* use modest branding (less yt logos)

* Stop playing the video once there's a navigation event

* Make sure the iframe is unmounted on any navigation event

* fixes tests

* lint
This commit is contained in:
Aryan Goharzad
2023-02-09 13:11:02 -05:00
committed by GitHub
parent 00d41c9168
commit b84c88cd21
15 changed files with 328 additions and 61 deletions
+6 -1
View File
@@ -1,11 +1,16 @@
import {RootStoreModel} from './../../../src/state/models/root-store'
import {NavigationModel} from './../../../src/state/models/navigation'
import * as flags from '../../../src/build-flags'
import AtpAgent from '@atproto/api'
import {DEFAULT_SERVICE} from '../../../src/state'
describe('NavigationModel', () => {
let model: NavigationModel
let rootStore: RootStoreModel
beforeEach(() => {
model = new NavigationModel()
rootStore = new RootStoreModel(new AtpAgent({service: DEFAULT_SERVICE}))
model = new NavigationModel(rootStore)
model.setTitle('0-0', 'title')
})
+6 -1
View File
@@ -3,12 +3,17 @@ import {
ImagesLightbox,
ShellUiModel,
} from './../../../src/state/models/shell-ui'
import {RootStoreModel} from '../../../src/state'
import AtpAgent from '@atproto/api'
import {DEFAULT_SERVICE} from '../../../src/state'
describe('ShellUiModel', () => {
let model: ShellUiModel
let rootStore: RootStoreModel
beforeEach(() => {
model = new ShellUiModel()
rootStore = new RootStoreModel(new AtpAgent({service: DEFAULT_SERVICE}))
model = new ShellUiModel(rootStore)
})
afterAll(() => {