All skills
davila7 avatar

/avalonia-layout-zafiro

@1deb97c

Guidelines for modern Avalonia UI layout using Zafiro.Avalonia, emphasizing shared styles, generic components, and avoiding XAML redundancy.

Use this Skill: https://skilld.dev/gh/davila7/claude-code-templates/avalonia-layout-zafiro

This session only. Nothing lands on disk.

containers.md

≈390 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Semantic Containers

Using the right container for the data type simplifies XAML and improves maintainability. Zafiro.Avalonia provides specialized controls for common layout patterns.

📦 HeaderedContainer

Prefer HeaderedContainer over a Border or Grid when a section needs a title or header.

<HeaderedContainer Header="Security Settings" Classes="WizardSection">
    <StackPanel>
        <!-- Content here -->
    </StackPanel>
</HeaderedContainer>

Key Properties:

  • Header: The content or string for the header.
  • HeaderBackground: Brush for the header area.
  • ContentPadding: Padding for the content area.

↔️ EdgePanel

Use EdgePanel to position elements at the edges of a container without complex Grid definitions.

<EdgePanel StartContent="{Icon fa-wallet}" 
           Content="Wallet Balance" 
           EndContent="$1,234.00" />

Slots:

  • StartContent: Aligned to the left (or beginning).
  • Content: Fills the remaining space in the middle.
  • EndContent: Aligned to the right (or end).

📇 Card

A simple container for grouping related information, often used inside HeaderedContainer or as a standalone element in a list.

<Card Header="Enter recipient address:">
    <TextBox Text="{Binding Address}" />
</Card>

📐 Best Practices

  • Use Classes to apply themed variants (e.g., Classes="Section", Classes="Highlight").
  • Customize internal parts of the containers using templates in your styles when necessary, rather than nesting more controls.

Source: SKILL.md on GitHub

1 warning16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    Error: AI Analysis failed - API error after retries

  • Socket16d

    No alerts

  • Snyk16d

    Risk: LOW · No issues

  • Runlayer7mo

    1/6 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 1deb97c. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 16 hours ago.

Activeupdated 8 months ago
What it can do
Reads files Edits files
All 5 allowed tools
ReadWriteEditGlobGrep

README badge

README badge for davila7/claude-code-templates/avalonia-layout-zafiro