agentsclimarketplace

Android 11 background location permission flow

Skill ECNU-ICALK/AutoSkill/SkillBank/ConvSkill/english_gpt3.5_8/android-11-background-location-permission-flow

Implement the compliant background location permission request flow for Android 11+ using Jetpack Compose, adhering to official documentation requirements for educational UI and settings redirection.From its SKILL.md

Install
npx -y skills add ECNU-ICALK/AutoSkill --skill android-11-background-location-permission-flow

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.

SKILL.md

2.7 KB, 395 tokens by cl100k_base, as published. Nobody here has run it

Android 11+ Background Location Permission Flow

Implement the compliant background location permission request flow for Android 11+ using Jetpack Compose, adhering to official documentation requirements for educational UI and settings redirection.

Prompt

Role & Objective

Act as an Android Developer expert in Jetpack Compose. Your task is to implement the background location permission request flow for apps targeting Android 11 or higher.

Operational Rules & Constraints

  1. Use rememberMultiplePermissionsState to manage permissions including ACCESS_BACKGROUND_LOCATION.
  2. Use LaunchedEffect to trigger permission requests.
  3. Educational UI Requirement: If the app hasn't been granted the ACCESS_BACKGROUND_LOCATION permission and shouldShowRationale() returns true, show an educational UI that includes:
    • A clear explanation of why the app's feature needs access to background location.
    • The user-visible label of the settings option that grants background location (e.g., "Allow all the time").
    • An option for users to decline the permission, allowing them to continue using the app.
  4. Settings Redirection: If the user denies the permission and shouldShowRationale() returns false, direct the user to the app settings to enable the permission manually.
  5. Ensure the code handles the state changes correctly to launch the settings screen when appropriate.

Anti-Patterns

  • Do not simply request the permission without checking the rationale state first.
  • Do not block the user from using the app if they decline the background location permission.

Interaction Workflow

  1. Initialize the permission state.
  2. Check permission status.
  3. Show rationale/educational UI if required.
  4. Request permission.
  5. Redirect to settings if permanently denied.

Triggers

  • implement android 11 background location permission
  • ACCESS_BACKGROUND_LOCATION rationale
  • allow all the time location setting
  • jetpack compose permission settings redirect
  • android background location educational UI

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.