From 56d38bd63c993845a7ea50bd98772d7c00adbdfb Mon Sep 17 00:00:00 2001
From: Jawin-SF4519 <165898284+Jawin-SF4519@users.noreply.github.com>
Date: Thu, 12 Jun 2025 18:07:21 +0530
Subject: [PATCH] 963343: DiagramInDialog
---
.../DiagramInDialog/DiagramInDialog/App.razor | 13 ++
.../DiagramInDialog_NET8.csproj | 14 ++
.../DiagramInDialog_NET8.csproj.user | 6 +
.../DiagramInDialog_NET9.csproj | 14 ++
.../DiagramInDialog_NET9.csproj.user | 6 +
.../DiagramInDialog/MainLayout.razor | 3 +
.../DiagramInDialog/Pages/Index.razor | 132 ++++++++++++++++++
.../DiagramInDialog/Pages/_Host.cshtml | 33 +++++
.../DiagramInDialog/Program.cs | 28 ++++
.../Properties/launchSettings.json | 35 +++++
.../DiagramInDialog/_Imports.razor | 5 +
.../appsettings.Development.json | 9 ++
.../DiagramInDialog/appsettings.json | 9 ++
.../DiagramInDialog/wwwroot/Interop.js | 3 +
.../DiagramInDialog/wwwroot/css/site.css | 28 ++++
15 files changed, 338 insertions(+)
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/App.razor
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj.user
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj.user
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/MainLayout.razor
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/Pages/Index.razor
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/Pages/_Host.cshtml
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/Program.cs
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/Properties/launchSettings.json
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/_Imports.razor
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/appsettings.Development.json
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/appsettings.json
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/wwwroot/Interop.js
create mode 100644 KB-Samples/DiagramInDialog/DiagramInDialog/wwwroot/css/site.css
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/App.razor b/KB-Samples/DiagramInDialog/DiagramInDialog/App.razor
new file mode 100644
index 00000000..221ec128
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/App.razor
@@ -0,0 +1,13 @@
+@namespace DiagramInDialog
+
+
+
+
+
+
+ Not found
+
+ Sorry, there's nothing at this address.
+
+
+
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj
new file mode 100644
index 00000000..81dc84cb
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj
@@ -0,0 +1,14 @@
+
+
+
+ net8.0
+ enable
+ enable
+
+
+
+
+
+
+
+
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj.user b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj.user
new file mode 100644
index 00000000..9ff5820a
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET8.csproj.user
@@ -0,0 +1,6 @@
+
+
+
+ https
+
+
\ No newline at end of file
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj
new file mode 100644
index 00000000..3a9de092
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj
@@ -0,0 +1,14 @@
+
+
+
+ net9.0
+ enable
+ enable
+
+
+
+
+
+
+
+
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj.user b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj.user
new file mode 100644
index 00000000..9ff5820a
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/DiagramInDialog_NET9.csproj.user
@@ -0,0 +1,6 @@
+
+
+
+ https
+
+
\ No newline at end of file
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/MainLayout.razor b/KB-Samples/DiagramInDialog/DiagramInDialog/MainLayout.razor
new file mode 100644
index 00000000..ad2343a2
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/MainLayout.razor
@@ -0,0 +1,3 @@
+@inherits LayoutComponentBase
+@namespace DiagramInDialog
+ @Body
diff --git a/KB-Samples/DiagramInDialog/DiagramInDialog/Pages/Index.razor b/KB-Samples/DiagramInDialog/DiagramInDialog/Pages/Index.razor
new file mode 100644
index 00000000..373a91b6
--- /dev/null
+++ b/KB-Samples/DiagramInDialog/DiagramInDialog/Pages/Index.razor
@@ -0,0 +1,132 @@
+@page "/"
+
+@using Syncfusion.Blazor.Buttons
+@using Syncfusion.Blazor.Popups
+@using Syncfusion.Blazor.Diagram
+@using System.Collections.ObjectModel
+@inject IJSRuntime jsRuntime;
+
+
+ Open Diagram Dialog
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+@code {
+ private SfDialog _dialog;
+ private SfDiagramComponent Diagram;
+
+ private bool IsDialogVisible = false;
+
+ private int HorizontalSpacing { get; set; } = 50;
+ private int VerticalSpacing { get; set; } = 50;
+ bool open = false;
+ public ObservableCollection DataSource { get; set; } = new()
+ {
+ new DiagramData { Id = "1", ParentId = "", Label = "CEO" },
+ new DiagramData { Id = "2", ParentId = "1", Label = "Manager" },
+ new DiagramData { Id = "3", ParentId = "2", Label = "Team Lead" },
+ new DiagramData { Id = "4", ParentId = "3", Label = "Senior Developer" },
+ new DiagramData { Id = "5", ParentId = "4", Label = "Developer" },
+ new DiagramData { Id = "6", ParentId = "5", Label = "Fresher" }
+ };
+
+ public class DiagramData
+ {
+ public string Id { get; set; }
+ public string ParentId { get; set; }
+ public string Label { get; set; }
+ }
+
+ private async Task ShowDialog()
+ {
+ IsDialogVisible = true;
+ }
+ private async Task OpenDialog(BeforeOpenEventArgs args)
+ {
+ await jsRuntime.InvokeAsync