Profile
MimiSDK provides a built-in Profile that provides everything your user could need to start enjoying personalized audio with Mimi.
The Profile is a highly configurable and dynamic UI component which is versatile enough to be used anywhere in your app. It provides:
- Onboarding - guiding the user through creating their individual Hearing ID.
- Mimi Account integration - allowing a Hearing ID to be stored in a permanent user account.
- Personalization controls - update and adjust personalized audio processing.
Usage
The Profile is entirely self contained and therefore requires minimal configuration to be used - it’s simply as easy as displaying a UIViewController
.
import UIKit
import MimiSDK
let profile = MimiProfileNavigationController()
self.rootViewController = profile
The Profile works best when it is embedded inside a UINavigationController
, and MimiProfileNavigationController
does this for you. However, if you wish to use the Profile inside your own navigation controller, you could use the MimiProfileViewController
by itself.
let profile = MimiProfileViewController()
let navigationController = UINavigationController(rootViewController: profile)
self.rootViewController = navigationController
If you want to present the Profile modally in your application, check out the Profile Launcher.
Configuration
It’s possible to configure various features and behaviors within the Profile during initialization. To do this, simply set the configuration:
parameter on the initializer of the profile component you are using.
import MimiSDK
let personalization = MimiPersonalizationConfiguration(showsSampleSoundPlayer: true) // Example config values. Yours may differ.
let configuration = MimiProfileConfiguration(
allowsRemoteDeviceAuthorization: true,
allowsAnonymousUserOnly: false,
showsOnboardingIntroduction: true,
personalization: personalization
) // Example config values. Yours may differ.
let profile = MimiProfileViewController(configuration: configuration)
The configuration:
parameter is available on MimiProfileViewController
, MimiProfileNavigationController
and MimiProfileLauncherView
.
Profile Configuration Properties
The following behaviors and features can be configured using MimiProfileConfiguration
:
allowsRemoteDeviceAuthorization
Whether to allow the user to authorize other Mimi compatible devices remotely using a QR code.
allowsAnonymousUserOnly
Whether to allow creation of only anonymous users. Setting this to true
will hide all Mimi Login & Signup functionality from the profile.
showsOnboardingIntroduction
Whether to show the onboarding introduction. Setting this to false
will hide the Onboarding Introduction from the profile.
personalization
Configuration which can customize the Sound Personalization features available in the Mimi Profile.
Personalization Configuration Properties
The following behaviors and features can be configured using MimiPersonalizationConfiguration
:
showsSampleSoundPlayer
Whether to show the sample sound player on the Mimi Profile.
Launcher
The Profile Launcher is a compact view designed to give one-tap access to the Mimi Profile. It allows you to provide a seamless Mimi Profile experience in your app, while taking a minimal amount of space.
The launcher will always reflect a compact version of the current Profile state, with the above depiction showing a Profile that is capable of Personalized audio. The controls in the Launcher are fully interactable, and tapping it will expand into the full Profile - presented modally.
The launcher is intended to be as flexible as possible, so the default implementation is just a standard UIView
with no rounded corners or shadows.
import MimiSDK
let launcher = MimiProfileLauncherView()
view.addSubview(launcher)
// that's it!
MimiProfileLauncherView
will automatically set the layer.shadowPath
if a shadow is added to the view layer.
Next Steps
Check out how to customize your new Mimi Profile to fit your brand with Theming.