Claude Skill

mobile-android-design

Master Material Design 3 and Jetpack Compose patterns for building native Android apps. Use when designing Android interfaces, implementing Compose UI, or following Google's Material Design guidelines.

LLM Mart · 0 points · 1 views 0 listing impressions 0 install-command copies
Download maomaochong-ai-open-astravia-.agents_skills_mobile-android-design-cf58759.zip · 16 KB

Install

skills CLI npx skills add https://github.com/maomaochong-ai/open-astravia/tree/main/.agents/skills/mobile-android-design
Claude Code claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install maomaochong-ai-open-astravia@llmmart
Git git clone https://github.com/maomaochong-ai/open-astravia.git

The skills CLI installs just this skill, for any of its supported agents. Claude Code installs the whole maomaochong-ai/open-astravia collection as a plugin from our marketplace. Git is the plain clone.

Skill manifest

Android Mobile Design

Master Material Design 3 (Material You) and Jetpack Compose to build modern, adaptive Android applications that integrate seamlessly with the Android ecosystem.

When to Use This Skill

  • Designing Android app interfaces following Material Design 3
  • Building Jetpack Compose UI and layouts
  • Implementing Android navigation patterns (Navigation Compose)
  • Creating adaptive layouts for phones, tablets, and foldables
  • Using Material 3 theming with dynamic colors
  • Building accessible Android interfaces
  • Implementing Android-specific gestures and interactions
  • Designing for different screen configurations

Detailed section: Core Concepts

Originally a 9201-byte section in this SKILL.md. Moved to references/details.md to fit Codex's 8 KB skill body cap.

Quick Start Component

@Composable
fun ItemListCard(
    item: Item,
    onItemClick: () -> Unit,
    modifier: Modifier = Modifier
) {
    Card(
        onClick = onItemClick,
        modifier = modifier.fillMaxWidth(),
        shape = RoundedCornerShape(12.dp)
    ) {
        Row(
            modifier = Modifier
                .padding(16.dp)
                .fillMaxWidth(),
            verticalAlignment = Alignment.CenterVertically
        ) {
            Box(
                modifier = Modifier
                    .size(48.dp)
                    .clip(CircleShape)
                    .background(MaterialTheme.colorScheme.primaryContainer),
                contentAlignment = Alignment.Center
            ) {
                Icon(
                    imageVector = Icons.Default.Star,
                    contentDescription = null,
                    tint = MaterialTheme.colorScheme.onPrimaryContainer
                )
            }

            Spacer(modifier = Modifier.width(16.dp))

            Column(modifier = Modifier.weight(1f)) {
                Text(
                    text = item.title,
                    style = MaterialTheme.typography.titleMedium
                )
                Text(
                    text = item.subtitle,
                    style = MaterialTheme.typography.bodyMedium,
                    color = MaterialTheme.colorScheme.onSurfaceVariant
                )
            }

            Icon(
                imageVector = Icons.Default.ChevronRight,
                contentDescription = null,
                tint = MaterialTheme.colorScheme.onSurfaceVariant
            )
        }
    }
}

Best Practices

  1. Use Material Theme: Access colors via MaterialTheme.colorScheme for automatic dark mode support
  2. Support Dynamic Color: Enable dynamic color on Android 12+ for personalization
  3. Adaptive Layouts: Use WindowSizeClass for responsive designs
  4. Content Descriptions: Add contentDescription to all interactive elements
  5. Touch Targets: Minimum 48dp touch targets for accessibility
  6. State Hoisting: Hoist state to make components reusable and testable
  7. Remember Properly: Use remember and rememberSaveable appropriately
  8. Preview Annotations: Add @Preview with different configurations

Common Issues

  • Recomposition Issues: Avoid passing unstable lambdas; use remember
  • State Loss: Use rememberSaveable for configuration changes
  • Performance: Use LazyColumn instead of Column for long lists
  • Theme Leaks: Ensure MaterialTheme wraps all composables
  • Navigation Crashes: Handle back press and deep links properly
  • Memory Leaks: Cancel coroutines in DisposableEffect
Files (open-astravia)
  • references
    • android-navigation.md 19.5 KB
      Loading…
    • compose-components.md 22.8 KB
      Loading…
    • details.md 9 KB
      Loading…
    • material3-theming.md 15.8 KB
      Loading…
  • SKILL.md 3.7 KB
    ---
    name: mobile-android-design
    description: Master Material Design 3 and Jetpack Compose patterns for building native Android apps. Use when designing Android interfaces, implementing Compose UI, or following Google's Material Design guidelines.
    ---
    
    # Android Mobile Design
    
    Master Material Design 3 (Material You) and Jetpack Compose to build modern, adaptive Android applications that integrate seamlessly with the Android ecosystem.
    
    ## When to Use This Skill
    
    - Designing Android app interfaces following Material Design 3
    - Building Jetpack Compose UI and layouts
    - Implementing Android navigation patterns (Navigation Compose)
    - Creating adaptive layouts for phones, tablets, and foldables
    - Using Material 3 theming with dynamic colors
    - Building accessible Android interfaces
    - Implementing Android-specific gestures and interactions
    - Designing for different screen configurations
    
    ## Detailed section: Core Concepts
    
    Originally a 9201-byte section in this SKILL.md. Moved to `references/details.md` to fit Codex's 8 KB skill body cap.
    
    ## Quick Start Component
    
    ```kotlin
    @Composable
    fun ItemListCard(
        item: Item,
        onItemClick: () -> Unit,
        modifier: Modifier = Modifier
    ) {
        Card(
            onClick = onItemClick,
            modifier = modifier.fillMaxWidth(),
            shape = RoundedCornerShape(12.dp)
        ) {
            Row(
                modifier = Modifier
                    .padding(16.dp)
                    .fillMaxWidth(),
                verticalAlignment = Alignment.CenterVertically
            ) {
                Box(
                    modifier = Modifier
                        .size(48.dp)
                        .clip(CircleShape)
                        .background(MaterialTheme.colorScheme.primaryContainer),
                    contentAlignment = Alignment.Center
                ) {
                    Icon(
                        imageVector = Icons.Default.Star,
                        contentDescription = null,
                        tint = MaterialTheme.colorScheme.onPrimaryContainer
                    )
                }
    
                Spacer(modifier = Modifier.width(16.dp))
    
                Column(modifier = Modifier.weight(1f)) {
                    Text(
                        text = item.title,
                        style = MaterialTheme.typography.titleMedium
                    )
                    Text(
                        text = item.subtitle,
                        style = MaterialTheme.typography.bodyMedium,
                        color = MaterialTheme.colorScheme.onSurfaceVariant
                    )
                }
    
                Icon(
                    imageVector = Icons.Default.ChevronRight,
                    contentDescription = null,
                    tint = MaterialTheme.colorScheme.onSurfaceVariant
                )
            }
        }
    }
    ```
    
    ## Best Practices
    
    1. **Use Material Theme**: Access colors via `MaterialTheme.colorScheme` for automatic dark mode support
    2. **Support Dynamic Color**: Enable dynamic color on Android 12+ for personalization
    3. **Adaptive Layouts**: Use `WindowSizeClass` for responsive designs
    4. **Content Descriptions**: Add `contentDescription` to all interactive elements
    5. **Touch Targets**: Minimum 48dp touch targets for accessibility
    6. **State Hoisting**: Hoist state to make components reusable and testable
    7. **Remember Properly**: Use `remember` and `rememberSaveable` appropriately
    8. **Preview Annotations**: Add `@Preview` with different configurations
    
    ## Common Issues
    
    - **Recomposition Issues**: Avoid passing unstable lambdas; use `remember`
    - **State Loss**: Use `rememberSaveable` for configuration changes
    - **Performance**: Use `LazyColumn` instead of `Column` for long lists
    - **Theme Leaks**: Ensure `MaterialTheme` wraps all composables
    - **Navigation Crashes**: Handle back press and deep links properly
    - **Memory Leaks**: Cancel coroutines in `DisposableEffect`
    

Comments (0)

Sign in to join the conversation.

No comments yet.

Reviews (0)

No reviews yet.