Skip to content

Latest commit

 

History

History
51 lines (41 loc) · 1.48 KB

File metadata and controls

51 lines (41 loc) · 1.48 KB

Permissions Component

Important

This is a PRO component. Gain access to the Swift and Kotlin code by purchasing a PRO license.

Gets the status of the user's granted permissions, like location and push notifications.

Permissions Component examples

<table data-controller="bridge--permissions">
  <thead>
    <tr>
      <th>Permission</th>
      <th>Status</th>
      <th>Code</th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <th>Camera</th>
      <td data-bridge--permissions-target="cameraStatus"></td>
      <td data-bridge--permissions-target="cameraCode"></td>
    </tr>

    <tr>
      <th>Location</th>
      <td data-bridge--permissions-target="locationStatus"></td>
      <td data-bridge--permissions-target="locationCode"></td>
    </tr>

    <tr>
      <th>Notifications</th>
      <td data-bridge--permissions-target="notificationsStatus"></td>
      <td data-bridge--permissions-target="notificationsCode"></td>
    </tr>
  </tbody>
</table>

Notification permission status

The following notification permission statuses are returned from the app. Use the status code to determine behavior in your app as needed.

Text Code iOS status Android status
authorized 1 authorized, provisional, or ephemeral PERMISSION_GRANTED
denied 0 denied or restricted PERMISSION_DENIED
not determined -1 notDetermined N/A
unknown -2 (anything else) N/A