Skip to content

Confusing preview behavior #1821

@klaaspieter

Description

@klaaspieter

Describe the bug

I'm attempting to use previewPermissionStatuses to customize previews for different scenarios but it looks like PreviewMultiplePermissionsState doesn't actually adapt to a change in permissions.

A quick look at the code suggests that only PreviewPermissionsState.permissions is an accurate reflection making properties like shouldShowRationale and code to detect partial permissions like the following unavailable:

locationPermissionsState.permissions.size == locationPermissionsState.revokedPermissions.size

It appears that in a preview shouldShowRationale always returns false and the partial permission code above will always be true because the revoked permissions list is always empty.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions