Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
e3fb926
initial dynamo changes
Chloepeg Feb 16, 2026
7aec4f3
Add NewWorkspaceWithTemplate method to open templates in new workspace
Chloepeg Feb 24, 2026
7fde2d7
Merge branch 'DynamoDS:master' into DYN-9702-templates-to-home-screen
Chloepeg Feb 24, 2026
cb1454c
Merge upstream/master into DYN-9702-templates-to-home-screen
Chloepeg Mar 2, 2026
2189df6
Merge branch 'DYN-9702-templates-to-home-screen' of https://github.co…
Chloepeg Mar 2, 2026
1739ed2
initial dynamo changes
Chloepeg Feb 16, 2026
e8ecae4
Add NewWorkspaceWithTemplate method to open templates in new workspace
Chloepeg Feb 24, 2026
d445a53
Fix DynamoHome bundle file
Chloepeg Mar 3, 2026
3236104
Merge branch 'DYN-9702-templates-to-home-screen' of https://github.co…
Chloepeg Mar 3, 2026
09b9a97
Adds the missing TemplateFiles property to StartPageViewModel
Chloepeg Mar 3, 2026
36f0768
Fixes build error
Chloepeg Mar 3, 2026
99a0538
Revert "Add NewWorkspaceWithTemplate method to open templates in new …
Chloepeg Mar 3, 2026
eec3510
Merge remote-tracking branch 'upstream/master' into DYN-9702-template…
Chloepeg Mar 10, 2026
4e7fd6b
Fix build
Chloepeg Mar 10, 2026
533156c
remove merge conflict marker
Chloepeg Mar 20, 2026
7c38dd6
Merge fix
Chloepeg Mar 27, 2026
8fb554c
Merge remote-tracking branch 'upstream/master' into DYN-9702-template…
Chloepeg Mar 27, 2026
859da9d
Fix DynamoHome embedded path and remove duplicate XAML code-behind co…
Chloepeg Mar 27, 2026
6689e5c
Fix Sonar issues
Chloepeg Mar 27, 2026
f83703f
Address SonarQube cloud issues in StartPage and HomePage
Chloepeg Mar 29, 2026
595057c
Copy distrib templates to output
Chloepeg Apr 21, 2026
9412121
initial dynamo changes
Chloepeg Feb 16, 2026
dac3c59
Add NewWorkspaceWithTemplate method to open templates in new workspace
Chloepeg Feb 24, 2026
22646e4
Fix DynamoHome bundle file
Chloepeg Mar 3, 2026
8d3a1ca
initial dynamo changes
Chloepeg Feb 16, 2026
ae933cf
Adds the missing TemplateFiles property to StartPageViewModel
Chloepeg Mar 3, 2026
5e26a96
Fixes build error
Chloepeg Mar 3, 2026
9035c81
Revert "Add NewWorkspaceWithTemplate method to open templates in new …
Chloepeg Mar 3, 2026
fb71bd3
Fix build
Chloepeg Mar 10, 2026
4b987db
remove merge conflict marker
Chloepeg Mar 20, 2026
697673b
Merge fix
Chloepeg Mar 27, 2026
a52f6fd
Fix DynamoHome embedded path and remove duplicate XAML code-behind co…
Chloepeg Mar 27, 2026
2360354
Fix Sonar issues
Chloepeg Mar 27, 2026
40bfbcc
Address SonarQube cloud issues in StartPage and HomePage
Chloepeg Mar 29, 2026
961db9a
Copy distrib templates to output
Chloepeg Apr 21, 2026
c31a4f6
Merge branch 'DYN-9702-templates-to-home-screen' of https://github.co…
Chloepeg May 6, 2026
cac9297
Merge branch 'DynamoDS:master' into DYN-9702-templates-to-home-screen
Chloepeg May 12, 2026
d7e142b
Open template files as new graphs
Chloepeg May 12, 2026
7e900f7
Update Dynamo Home package for templates
Chloepeg May 13, 2026
bd4bab7
Addressing copilot's comments
Chloepeg May 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/DynamoCore/DynamoCore.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@
<LibGMain Include="$(LibGMainPackagePath)\tools\netstandard2.1\$(LibGOsToken)\$(LIBGVerMain)\*" />
<LibGSecondary Include="$(LibGSecondaryPackagePath)\tools\netstandard2.1\$(LibGOsToken)\$(LIBGVerSecondary)\*" />
<SampleFiles Include="$(SolutionDir)..\doc\distrib\Samples\**\*.*" />
<TemplateFiles Include="$(SolutionDir)..\doc\distrib\Templates\**\*.*" />
<NodeHelpCsCZMDFiles Include="$(SolutionDir)..\doc\distrib\NodeHelpFiles\cs-CZ\**\*.md" />
<NodeHelpDeDEMDFiles Include="$(SolutionDir)..\doc\distrib\NodeHelpFiles\de-DE\**\*.md" />
<NodeHelpEnUSMDFiles Include="$(SolutionDir)..\doc\distrib\NodeHelpFiles\en-US\**\*.md" />
Expand Down Expand Up @@ -221,6 +222,7 @@
<Copy SourceFiles="@(LibGSecondary)" DestinationFolder="$(OutputPath)$(LIBGVerSecondary)\" />
<Copy SourceFiles="@(LibGMain)" DestinationFolder="$(OutputPath)$(LIBGVerMain)\" />
<Copy SourceFiles="@(SampleFiles)" DestinationFolder="$(OutputPath)samples\%(RecursiveDir)" />
<Copy SourceFiles="@(TemplateFiles)" DestinationFolder="$(OutputPath)templates\%(RecursiveDir)" />
<Copy SourceFiles="@(LocalizedResources)" DestinationFolder="$(OutputPath)%(RecursiveDir)" />
<Copy SourceFiles="$(ProjectDir)\BuiltInAndOperators\Operators.xml" DestinationFolder="$(OutputPath)\$(UICulture)" />
<Copy SourceFiles="$(ProjectDir)\BuiltInAndOperators\BuiltIn.xml" DestinationFolder="$(OutputPath)\$(UICulture)" />
Expand Down
16 changes: 15 additions & 1 deletion src/DynamoCoreWpf/Controls/StartPage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,21 @@ private void HandleRegularCommand(StartPageListItem item)
private void HandleFilePath(StartPageListItem item)
{
var path = item.ContextData;
this.DynamoViewModel.OpenCommand.Execute(path);
// Listed templates: use the same open path as the template file-picker (ShowOpenTemplateDialog),
// i.e. open as a new graph from the file contents, not as the saved template path on disk.
object openArg = IsTemplateFilePath(path)
? Tuple.Create(path, false, true)
: path;
if (this.DynamoViewModel.OpenCommand.CanExecute(openArg))
{
this.DynamoViewModel.OpenCommand.Execute(openArg);
Comment on lines 656 to +664
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed this to compare template paths instead of relying on StartPageListItem reference equality. I used a case-insensitive comparison since these are Windows file paths.

}
}

private bool IsTemplateFilePath(string path)
{
return TemplateFiles.Any(template =>
string.Equals(template.ContextData, path, StringComparison.OrdinalIgnoreCase));
}

private void HandleExternalUrl(StartPageListItem item)
Expand Down
2 changes: 1 addition & 1 deletion src/DynamoCoreWpf/DynamoCoreWpf.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@

<Target Name="NpmRunBuildHomePage" BeforeTargets="BeforeBuild">
<PropertyGroup>
<PackageVersion>1.0.28</PackageVersion>
<PackageVersion>1.0.30</PackageVersion>
<PackageName>DynamoHome</PackageName>
</PropertyGroup>
<Exec Command="$(PowerShellCommand) -ExecutionPolicy Bypass -File &quot;$(SolutionDir)pkgexist.ps1&quot; &quot;$(PackageName)&quot; &quot;$(PackageVersion)&quot;" ConsoleToMSBuild="true">
Expand Down
11 changes: 9 additions & 2 deletions src/DynamoCoreWpf/ViewModels/Core/DynamoViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2378,8 +2378,15 @@

private bool CanOpen(object parameters)
{

var filePath = parameters as string;
string filePath = parameters as string;

Check warning on line 2381 in src/DynamoCoreWpf/ViewModels/Core/DynamoViewModel.cs

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Rename 'filePath' which hides the field with the same name.

See more on https://sonarcloud.io/project/issues?id=DynamoDS_Dynamo&issues=AZ4iW2JCW4Q6haNCeITq&open=AZ4iW2JCW4Q6haNCeITq&pullRequest=17107
if (filePath == null && parameters is Tuple<string, bool> packedTwo)
{
filePath = packedTwo.Item1;
}
else if (filePath == null && parameters is Tuple<string, bool, bool> packedThree)
{
filePath = packedThree.Item1;
}
Comment on lines +2381 to +2389
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I Added a focused test for OpenCommand.CanExecute with the Tuple<string, bool, bool> template parameter shape.


if (!PathHelper.IsValidPath(filePath))
{
Expand Down
16 changes: 14 additions & 2 deletions src/DynamoCoreWpf/Views/HomePage/HomePage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -542,8 +542,20 @@ internal void OpenFile(string path)
return;
}

if (this.startPage.DynamoViewModel.OpenCommand.CanExecute(path))
this.startPage.DynamoViewModel.OpenCommand.Execute(path);
var dvm = this.startPage.DynamoViewModel;
var openArg = IsListedHomePageTemplate(path)
? (object)Tuple.Create(path, false, true)
: path;
if (dvm.OpenCommand.CanExecute(openArg))
{
dvm.OpenCommand.Execute(openArg);
}
}

private bool IsListedHomePageTemplate(string path)
{
return startPage?.TemplateFiles?.Any(t =>
string.Equals(t.ContextData, path, StringComparison.OrdinalIgnoreCase)) == true;
}

internal void StartGuidedTour(string path)
Expand Down
9 changes: 9 additions & 0 deletions test/DynamoCoreWpf3Tests/WorkspaceOpeningTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,15 @@ public void OpeningWorkspaceWithAutoRunState()
Assert.IsTrue(ws.HasRunWithoutCrash);
}

[Test]
public void CanOpenTemplateTupleWithValidPath()
{
var examplePath = Path.Combine(SampleDirectory, @"en-US\Basics\Basics_Basic01.dyn");
var openParams = Tuple.Create(examplePath, false, true);

Assert.IsTrue(ViewModel.OpenCommand.CanExecute(openParams));
}

[Test]
public void OpeningXMLWorkspaceShouldSetDeterministicId()
{
Expand Down
Loading