feat: add notification controls (#3723)
* feat(ios): add `showNotificationControls` prop * feat(android): add `showNotificationControls` prop * add docs * feat!: add `metadata` property to srouce This is breaking change for iOS/tvOS as we are moving some properties, but I believe that this will more readable and more user friendly * chore(ios): remove UI blocking function * code review changes for android * update example * fix readme * fix typos * update docs * fix typo * chore: improve sample metadata notification * update codegen types * rename properties * update tvOS example * reset metadata on source change * update docs --------- Co-authored-by: Olivier Bouillet <freeboub@gmail.com>
This commit is contained in:
@@ -8,11 +8,7 @@ struct VideoSource {
|
||||
let startPosition: Float64?
|
||||
let cropStart: Int64?
|
||||
let cropEnd: Int64?
|
||||
// Custom Metadata
|
||||
let title: String?
|
||||
let subtitle: String?
|
||||
let description: String?
|
||||
let customImageUri: String?
|
||||
let customMetadata: CustomMetadata?
|
||||
|
||||
let json: NSDictionary?
|
||||
|
||||
@@ -28,10 +24,7 @@ struct VideoSource {
|
||||
self.startPosition = nil
|
||||
self.cropStart = nil
|
||||
self.cropEnd = nil
|
||||
self.title = nil
|
||||
self.subtitle = nil
|
||||
self.description = nil
|
||||
self.customImageUri = nil
|
||||
self.customMetadata = nil
|
||||
return
|
||||
}
|
||||
self.json = json
|
||||
@@ -54,9 +47,6 @@ struct VideoSource {
|
||||
self.startPosition = json["startPosition"] as? Float64
|
||||
self.cropStart = (json["cropStart"] as? Float64).flatMap { Int64(round($0)) }
|
||||
self.cropEnd = (json["cropEnd"] as? Float64).flatMap { Int64(round($0)) }
|
||||
self.title = json["title"] as? String
|
||||
self.subtitle = json["subtitle"] as? String
|
||||
self.description = json["description"] as? String
|
||||
self.customImageUri = json["customImageUri"] as? String
|
||||
self.customMetadata = CustomMetadata(json["metadata"] as? NSDictionary)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user