{
  "$schema": "https://ai.syncfusion.com/schema/registry-item.json",
  "name": "diagram-annotations",
  "framework": "maui",
  "type": "registry:component",
  "component": "Diagram",
  "variant": "annotations",
  "dependencies": [
    "Syncfusion.Maui.Diagram"
  ],
  "description": "Diagram displays connected nodes and connectors with annotations that label diagram elements.",
  "meta": {
    "essentialStudioRelease": "2026 Volume 3 (v35.1.37)",
    "license": "commercial-or-community",
    "licenseNote": "The Syncfusion package is licensed. The composition in this file is source you own and edit. See https://ai.syncfusion.com/licensing.md",
    "requiresLicenseKey": true,
    "requiresServerEndpoint": false,
    "platformIndex": "https://ai.syncfusion.com/maui/llms.txt",
    "skillPack": "syncfusion/maui-ui-components-skills",
    "docs": "https://ai.syncfusion.com/gallery/maui/diagram-annotations.md"
  },
  "files": [
    {
      "target": "src/components/diagram-annotations/Diagram.xaml",
      "content": "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n<ContentPage xmlns=\"http://schemas.microsoft.com/dotnet/2021/maui\"\n             xmlns:x=\"http://schemas.microsoft.com/winfx/2009/xaml\"\n             xmlns:diagram=\"clr-namespace:Syncfusion.Maui.Diagram;assembly=Syncfusion.Maui.Diagram\"\n             xmlns:editors=\"clr-namespace:Syncfusion.Maui.Inputs;assembly=Syncfusion.Maui.Inputs\"\n             xmlns:conv=\"clr-namespace:MAUI.Controls.Diagram.Converters\"\n             x:Class=\"MAUI.Controls.Diagram.Annotations.AnnotationsView\">\n\n    <ContentPage.Resources>\n        <conv:ActiveStateToColorConverter x:Key=\"AlignmentToColor\" />\n    </ContentPage.Resources>\n\n    <Grid>\n        <Grid.ColumnDefinitions>\n            <ColumnDefinition Width=\"*\"/>\n            <ColumnDefinition Width=\"300\"/>\n        </Grid.ColumnDefinitions>\n        <Grid x:Name=\"grid\" Grid.Column=\"0\">\n            <!-- Diagram Control -->\n            <diagram:SfDiagram x:Name=\"Diagram\" Nodes=\"{Binding Nodes}\" Connectors=\"{Binding Connectors}\"\n                               Grid.Row=\"0\"\n                               BackgroundColor=\"#FAFAFA\"\n                               HorizontalOptions=\"Fill\"\n                               VerticalOptions=\"Fill\"\n                               Created=\"OnCreated\" />\n        </Grid>\n\n        <ContentView Grid.Column=\"1\">\n            <ScrollView Padding=\"0, 0, 5, 0\">\n                <StackLayout Orientation=\"Vertical\">\n                    <!-- Horizontal Alignment -->\n                    <Label Text=\"Alignment\"\n                           Margin=\"0,15,0,8\"\n                           FontSize=\"14\"\n                           FontAttributes=\"Bold\"/>\n\n                    <Grid x:Name=\"alignmentGrid\" ColumnSpacing=\"5\" RowSpacing=\"5\" Margin=\"0,0,0,15\">\n                        <Grid.ColumnDefinitions>\n                            <ColumnDefinition Width=\"*\"/>\n                            <ColumnDefinition Width=\"*\"/>\n                            <ColumnDefinition Width=\"*\"/>\n                        </Grid.ColumnDefinitions>\n                        <Grid.RowDefinitions>\n                            <RowDefinition Height=\"Auto\"/>\n                            <RowDefinition Height=\"Auto\"/>\n                            <RowDefinition Height=\"Auto\"/>\n                        </Grid.RowDefinitions>\n\n                        <Button Grid.Row=\"0\" Grid.Column=\"0\" Text=\"TL\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"TopLeft\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=TopLeft}\" />\n                        <Button Grid.Row=\"0\" Grid.Column=\"1\" Text=\"Top\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"TopCenter\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=TopCenter}\" />\n                        <Button Grid.Row=\"0\" Grid.Column=\"2\" Text=\"TR\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"TopRight\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=TopRight}\" />\n\n                        <Button Grid.Row=\"1\" Grid.Column=\"0\" Text=\"Left\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"Left\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=Left}\" />\n                        <Button Grid.Row=\"1\" Grid.Column=\"1\" Text=\"Center\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"Center\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=Center}\" />\n                        <Button Grid.Row=\"1\" Grid.Column=\"2\" Text=\"Right\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"Right\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=Right}\" />\n\n                        <Button Grid.Row=\"2\" Grid.Column=\"0\" Text=\"BL\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"BottomLeft\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=BottomLeft}\" />\n                        <Button Grid.Row=\"2\" Grid.Column=\"1\" Text=\"Bottom\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"BottomCenter\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=BottomCenter}\" />\n                        <Button Grid.Row=\"2\" Grid.Column=\"2\" Text=\"BR\"\n                                Command=\"{Binding SetAlignmentCommand}\" CommandParameter=\"BottomRight\"\n                                BackgroundColor=\"{Binding SelectedAlignment, Converter={StaticResource AlignmentToColor}, ConverterParameter=BottomRight}\" />\n                    </Grid>\n\n                    <!-- Appearance Section -->\n                    <Label Text=\"Appearance\"\n                           Margin=\"0,15,0,8\"\n                           FontSize=\"14\"\n                           FontAttributes=\"Bold\"/>\n\n                    <Grid x:Name=\"boldGrid\">\n                        <Grid.ColumnDefinitions>\n                            <ColumnDefinition Width=\"*\"/>\n                            <ColumnDefinition Width=\"*\"/>\n                        </Grid.ColumnDefinitions>\n                        <Button Text=\"B\" Command=\"{Binding ToggleBoldCommand}\" Margin=\"0,0,5,0\"\n                                BackgroundColor=\"{Binding IsBold, Converter={StaticResource AlignmentToColor}, ConverterParameter=True}\" />\n                        <Button Text=\"I\" Grid.Column=\"1\" Command=\"{Binding ToggleItalicCommand}\" Margin=\"5,0,0,0\"\n                                BackgroundColor=\"{Binding IsItalic, Converter={StaticResource AlignmentToColor}, ConverterParameter=True}\" />\n                    </Grid>\n\n                    <!-- Font Size -->\n                    <Grid x:Name=\"fontSizeGrid\" Margin=\"0,12,0,0\">\n                        <Grid.ColumnDefinitions>\n                            <ColumnDefinition Width=\"0.5*\"/>\n                            <ColumnDefinition Width=\"0.5*\"/>\n                        </Grid.ColumnDefinitions>\n                        <Label Text=\"Font Size\"\n                               Margin=\"0,8,0,0\"\n                               LineBreakMode=\"WordWrap\"\n                               FontSize=\"14\"\n                               VerticalOptions=\"Center\"\n                               HorizontalOptions=\"Start\"/>\n                        <editors:SfNumericEntry Value=\"{Binding FontSize}\"\n                                                FontSize=\"12\"\n                                                Grid.Column=\"1\"\n                                                Margin=\"5,8,0,0\"\n                                                VerticalOptions=\"Center\"\n                                                HorizontalOptions=\"End\"\n                                                Minimum=\"8\"\n                                                Maximum=\"32\" />\n                    </Grid>\n\n                    <!-- Text Color -->\n                    <Grid x:Name=\"textColorGrid\" Margin=\"0,12,0,0\">\n                        <Grid.ColumnDefinitions>\n                            <ColumnDefinition Width=\"0.5*\"/>\n                            <ColumnDefinition Width=\"0.5*\"/>\n                        </Grid.ColumnDefinitions>\n                        <Label Text=\"Text Color\"\n                               Margin=\"0,15,0,0\"\n                               LineBreakMode=\"WordWrap\"\n                               FontSize=\"14\"\n                               VerticalOptions=\"Center\"\n                               HorizontalOptions=\"Start\"/>\n                        <editors:SfComboBox ItemsSource=\"{Binding TextColors}\"\n                                            SelectedIndex=\"{Binding SelectedTextColorIndex, Mode=TwoWay}\"\n                                            FontSize=\"12\"\n                                            Grid.Column=\"1\"\n                                            Margin=\"5,15,0,0\"\n                                            VerticalOptions=\"Center\"\n                                            HorizontalOptions=\"End\"\n                                            IsClearButtonVisible=\"False\" />\n                    </Grid>\n\n                    <!-- Font Family -->\n                    <Grid x:Name=\"fontFamilyGrid\" Margin=\"0,12,0,0\">\n                        <Grid.ColumnDefinitions>\n                            <ColumnDefinition Width=\"0.5*\"/>\n                            <ColumnDefinition Width=\"0.5*\"/>\n                        </Grid.ColumnDefinitions>\n                        <Label Text=\"Font Family\"\n                               Margin=\"0,15,0,0\"\n                               LineBreakMode=\"WordWrap\"\n                               FontSize=\"14\"\n                               VerticalOptions=\"Center\"\n                               HorizontalOptions=\"Start\"/>\n                        <editors:SfComboBox ItemsSource=\"{Binding FontFamilies}\"\n                                            SelectedIndex=\"{Binding SelectedFontFamilyIndex, Mode=TwoWay}\"\n                                            FontSize=\"12\"\n                                            Grid.Column=\"1\"\n                                            Margin=\"5,15,0,0\"\n                                            VerticalOptions=\"Center\"\n                                            HorizontalOptions=\"End\"\n                                            IsClearButtonVisible=\"False\" />\n                    </Grid>\n\n                </StackLayout>\n            </ScrollView>\n        </ContentView>\n    </Grid>\n</ContentPage>\n"
    },
    {
      "target": "src/components/diagram-annotations/Diagram.xaml.cs",
      "content": "using MAUI.Controls.Diagram.AnnotationsViewModel;\n\nnamespace MAUI.Controls.Diagram.Annotations;\n\npublic partial class AnnotationsView : ContentPage\n{\n    public AnnotationsView()\n\t{\n        BindingContext = new AnnotationsViewModel.AnnotationsViewModel();\n        InitializeComponent();\n    }\n\n    public void OnCreated(object? sender, EventArgs e)\n    {\n        _ = Diagram.FitToPage();\n    }\n}\n"
    }
  ]
}