Skip to content

JioMeet/JioMatrixTranslationiOSUIKit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

Configure JioMatrixTranslationiOSUIKit inside your app

Project Settings

Info.plist Changes

Please add below permissions keys to your Info.plist file with proper description.

<key>NSContactsUsageDescription</key>
<string>Allow access to Contacts display your contacts for calling</string>
<key>NSMicrophoneUsageDescription</key>
<string>Allow access to mic for recordings</string>

Integration Steps

Add SDK

Please add below pod to your Podfile and run command pod install --repo-update --verbose.

pod 'JioMatrixTranslationSDK', '~> 0.1.0-alpha2'

Also please add this lines in your pod file if you're facing any issues.

post_install do |installer|
  installer.generated_projects.each do |project|
    project.targets.each do |target|
      target.build_configurations.each do |config|
        config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '12.0'
        config.build_settings['BUILD_LIBRARY_FOR_DISTRIBUTION'] = 'YES'
      end
    end
  end
end

Import SDK

Please use below import statements

import JioMatrixTranslationSDK

Integrate Translation View

Create instance of JMTranslationView.

private var translationView = JMTranslationView()

Add it to your viewController view.

translationView.translatesAutoresizingMaskIntoConstraints = false
view.addSubview(translationView)

NSLayoutConstraint.activate([
    translationView.leadingAnchor.constraint(equalTo: view.leadingAnchor),
    translationView.trailingAnchor.constraint(equalTo: view.trailingAnchor),
    translationView.topAnchor.constraint(equalTo: view.topAnchor),
    translationView.bottomAnchor.constraint(equalTo: view.bottomAnchor),
])

Initialisation

let config = JMTranslationConfig(speechKey: SPEECH_KEY, speechRegion: SPEECH_REGION, textTranslationKey: TEXT_TRANSLATION_KEY)
translationView.setUpTranslationScreen(webToken: YOUR_TOKEN, config: config)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published