Commit Graph

572 Commits

Author SHA1 Message Date
Javier Calvarro Nelson 111e26dd03 Conditionally enable content items in the razor SDK (dotnet/aspnetcore-tooling#589)
* Move the globs from the project system into the Razor SDK on a separate file that can be imported by itself.
* Import the file conditionally based on the EnableRazorContent property\n\nCommit migrated from 62e33dac1d
2019-05-20 21:06:38 +02:00
Alex Lorimer 98a2a4348b fixed destructive property assignment (reference self correctly using `$(GetCopyToOutputDirectoryItemsDependsOn)` instead of `$(GetCopyToOutputDirectoryItems)`) (dotnet/aspnetcore-tooling#603)
The intention here would have been to add to the existing GetCopyToOutputDirectoryItemsDependsOn property, defined in Microsoft.Common.Targets. Instead what was happening is that it was being completely overwitten with the _RazorGetCopyToOutputDirectoryItems entry, given that $(GetCopyToOutputDirectoryItems) doesn't exist as a property and must have been a typo (it exists as a task, not a property).

An effect of this bug was that the `AssignTargetPaths` target is not always executed before the `GetCopyToOutputDirectoryItems` target, which should explicitly depend on it. `AssignTargetPaths` is responsible for populating the `ContentWithTargetPath` itemgroup. Left empty, it appears to `GetCopyToOutputDirectoryItems` task that there are no Content files to copy to the final output directory, when in fact there are.\n\nCommit migrated from 4597bc3d55
2019-05-20 06:39:51 -07:00
Pranav K b5a7daba2b Do build time discovery of MVC ApplicationParts (dotnet/aspnetcore-tooling#598)
* Do build time discovery of MVC ApplicationParts
\n\nCommit migrated from e79d5600f7
2019-05-17 13:14:41 -07:00
N. Taylor Mullen 96475e488d Render more TagHelper code at design time.
- This is a pre-requisite to properly warnings users about TagHelpers in code blocks. With this change VS indicates that there's an asynchronous operation happening in a code block but because the code is auto-generated it happens behind the scenes and therefore always gets logged as a line 1 error (unusable). Therefore, to fix this issue there will be a partner PR that will go out in AspNetCore that adds analyzer errors for cases where `__tagHelperRunner.RunAsync` exists in code blocks that do not return `Task` and are not marked with `async` properly.
- Updated test files to reflect the new TagHelper codegen at design time.
- Note: This doesn't solve the `~/` case that will be in a follow up PR.

aspnet/AspNetCoredotnet/aspnetcore-tooling#8630
\n\nCommit migrated from 17af3efccd
2019-05-17 12:59:32 -07:00
N. Taylor Mullen ffd11eaa05 Add support for single line control flow statements in code blocks.
- This adds support for C# single line variations of: `if`, `for`, `foreach`, `do`, `while`, `lock` and `using`.
- Turns out the existing parser had 99% of the support for these scenarios already. Therefore, in this change set I went ahead and added exhaustive tests to verify things worked end-to-end.
- Added a restriction to single line markup to not allow markup in single line control flow statements. Updated resx to provide a better error message for cases when users do use markup in single line control flow statements.

dotnet/aspnetcore-tooling#9637
\n\nCommit migrated from cf474c97aa
2019-05-08 14:20:08 -07:00
N. Taylor Mullen b9fde956ea Fix RazorDiagnostics from being hidden and unordered.
- Diagnostics were not being raised to the `RazorSyntaxTree` and weren't being ordered on final output. This resulted in some of our tests missing the fact that certain cases were generating errors.
- Made all three phases of Razor parsing order their diagnostics.
- Added `GetAllDiagnostics` methods to `SyntaxNode`s to be more consistent with IR documents.
- Updated test files. In some cases new errors were found because we're now lifting them to the `SyntaxTree`, in most others the errors are re-ordered.

**Note: In end-to-end scenarios diagnostics were not hidden, only unordered. The IR phase would find nested/hidden documents and lift them to the IR/C# documents.**
\n\nCommit migrated from ef31a9683b
2019-05-08 09:22:42 -07:00
Ben Adams 19c9010c2f Read interface IList.Count once rather than per iteration (#9962) 2019-05-04 17:54:12 -07:00
Pranav K 997ab19511 Unskip Build_WithViews_ProducesDepsFileWithCompilationContext_ButNoReferences (dotnet/aspnetcore-tooling#560)
\n\nCommit migrated from e5a23e0588
2019-05-03 12:15:27 -07:00
Nate McMaster 4a4b80046d Enable resx source generation (dotnet/aspnetcore-tooling#561)
\n\nCommit migrated from 627710fcb8
2019-05-03 12:04:53 -07:00
Ajay Bhargav Baaskaran 9a456a5aeb Fix crash in functions block (dotnet/aspnetcore-tooling#550)
\n\nCommit migrated from 3fe99e9d7f
2019-05-02 13:40:25 -07:00
Ajay Bhargav Baaskaran c21572bf8f Merge pull request dotnet/aspnetcore-tooling#526 from aspnet/ajbaaska/generic-int-fix
Fix invalid cast in non-generic parameterized ChildContent\n\nCommit migrated from e622d7c405
2019-05-01 17:18:31 -07:00
Ajay Bhargav Baaskaran 9860cfc34b do the needful
\n\nCommit migrated from c5a7e9ecce
2019-05-01 14:53:26 -07:00
Ajay Bhargav Baaskaran 67855582bb Update comment
\n\nCommit migrated from f78e4c258e
2019-05-01 14:41:35 -07:00
Ajay Bhargav Baaskaran 2050916767 Add @code directive support for Blazor
\n\nCommit migrated from 7dc5887b49
2019-04-30 21:05:23 -07:00
Ajay Bhargav Baaskaran 3c5903095a Fix invalid cast in non-generic parameterized ChildContent
\n\nCommit migrated from 5ca26a352e
2019-04-30 20:32:16 -07:00
Ajay Bhargav Baaskaran 5f462346c6 Added support for @namespace directive in Blazor (dotnet/aspnetcore-tooling#504)
* Added support for @namespace directive in Blazor
\n\nCommit migrated from 7f6c1422dd
2019-04-30 17:58:13 -07:00
Nate McMaster ae8e96f154
Remove API check baselines and related project settings (#9846) 2019-04-30 14:58:13 -07:00
Steve Sanderson ed04f3ebb8 'key' directive attribute for components (dotnet/aspnetcore-tooling#508)
\n\nCommit migrated from 0803d3bbed
2019-04-29 16:16:05 +01:00
Ryan Nowak 9deb4401e4 Fix dotnet/aspnetcore-tooling#5709
Enables the correct processing of data- attributes for components.
\n\nCommit migrated from 7ae8a8c842
2019-04-25 08:27:43 -07:00
dotnet-maestro[bot] 8eb2e8baec
[master] Update dependencies from dotnet/arcade (#9715)
* Update dependencies from https://github.com/dotnet/arcade build 20190423.2

- Microsoft.DotNet.GenAPI - 1.0.0-beta.19223.2

* Adjust to GenApi change in `enum` ordering
- was sorted by name, now by value
2019-04-24 19:21:37 +00:00
Ajay Bhargav Baaskaran 43824a4c12 Verify line pragmas on generated code (dotnet/aspnetcore-tooling#392)
* Verify line pragmas on generated code
\n\nCommit migrated from ca33b2d51b
2019-04-22 14:43:13 -07:00
Ajay Bhargav Baaskaran 956606ee5d Fix TypeInference code gen for non-generic parameter (dotnet/aspnetcore-tooling#433)
\n\nCommit migrated from 4233bc593c
2019-04-19 10:06:13 -07:00
dotnet-maestro[bot] dd5dac97e5 [master] Update dependencies from aspnet/Extensions (dotnet/aspnetcore-tooling#409)
* Update dependencies from https://github.com/aspnet/Extensions build 20190410.2

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19210.2
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19210.2
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.Logging - 3.0.0-preview5.19210.2

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)

* Try a coherent SDK and Runtime

* Try again

* Fix codecheck

* Update dependencies from https://github.com/aspnet/Extensions build 20190410.2

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19210.2
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19210.2
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.Logging - 3.0.0-preview5.19210.2

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)

* Try again

* Update dependencies from https://github.com/aspnet/Extensions build 20190410.2

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19210.2
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19210.2
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19210.2
- Microsoft.Extensions.Logging - 3.0.0-preview5.19210.2

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19208.5 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27608-16 (parent: Microsoft.Extensions.Logging)

* Update dependencies from https://github.com/aspnet/Extensions build 20190412.9

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19212.9
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19212.9
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19212.9
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19212.9
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19212.9
- Microsoft.Extensions.Logging - 3.0.0-preview5.19212.9

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19211.22 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27611-18 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19211.22 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27611-18 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27611-18 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19211.22 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27611-18 (parent: Microsoft.Extensions.Logging)

* Update dependencies from https://github.com/aspnet/Extensions build 20190413.4

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19213.4
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19213.4
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19213.4
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19213.4
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19213.4
- Microsoft.Extensions.Logging - 3.0.0-preview5.19213.4

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19212.14 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27613-02 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19212.14 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27613-02 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27613-02 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19212.14 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27613-02 (parent: Microsoft.Extensions.Logging)

* Update dependencies from https://github.com/aspnet/Extensions build 20190414.1

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19214.1
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19214.1
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19214.1
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19214.1
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19214.1
- Microsoft.Extensions.Logging - 3.0.0-preview5.19214.1

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19212.14 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27613-11 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19212.14 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27613-11 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27613-11 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19212.14 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27613-11 (parent: Microsoft.Extensions.Logging)

* Restore with the appropriate RuntimeFrameworkVersion before building or publishing

* Fix incremental test

* Update dependencies from https://github.com/aspnet/Extensions build 20190416.8

- Microsoft.AspNetCore.BenchmarkRunner.Sources - 3.0.0-preview5.19216.8
- Microsoft.AspNetCore.Testing - 3.0.0-preview5.19216.8
- Microsoft.Extensions.CommandLineUtils.Sources - 3.0.0-preview5.19216.8
- Microsoft.Extensions.NonCapturingTimer.Sources - 3.0.0-preview5.19216.8
- Microsoft.Extensions.HashCodeCombiner.Sources - 3.0.0-preview5.19216.8
- Microsoft.Extensions.Logging - 3.0.0-preview5.19216.8

Dependency coherency updates

- System.Diagnostics.DiagnosticSource - 4.6.0-preview5.19215.16 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27616-01 (parent: Microsoft.Extensions.Logging)
- System.Text.Encodings.Web - 4.6.0-preview5.19215.16 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27616-01 (parent: Microsoft.Extensions.Logging)
- Microsoft.Extensions.DependencyModel - 3.0.0-preview5-27616-01 (parent: Microsoft.Extensions.Logging)
- Microsoft.NETCore.Platforms - 3.0.0-preview5.19215.16 (parent: Microsoft.NETCore.App)
- Microsoft.NETCore.App - 3.0.0-preview5-27616-01 (parent: Microsoft.Extensions.Logging)
\n\nCommit migrated from f9c222d305
2019-04-17 16:16:34 +00:00
Pranav K 2309e56de8 Do not split warning message across multiple lines (dotnet/aspnetcore-tooling#432)
The newline in the warning messages causes the warning message to appear as two separate warnings in the build output:

Microsoft.NET.Sdk.Razor\build\netstandard2.0\Sdk.Razor.CurrentVersion.targets(805,5): warning RAZORSDK1004: One or more Razor view or page files were found, but the project is not configured to add Razor support for MVC. The MSBuild property 'AddRazorSupportForMvc' must be set to correctly
Microsoft.NET.Sdk.Razor\build\netstandard2.0\Sdk.Razor.CurrentVersion.targets(805,5): warning RAZORSDK1004:  compile Razor files that target MVC. For more information, see https://go.microsoft.com/fwlink/?linkid=868374.

This change fixes the warning message to appear as a single warning:

Microsoft.NET.Sdk.Razor\build\netstandard2.0\Sdk.Razor.CurrentVersion.targets(805,5): warning RAZORSDK1004: One or more Razor view or page files were found, but the project is not configured to add Razor support for MVC. The MSBuild property 'AddRazorSupportForMvc' must be set to correctly compile Razor files that target MVC. For more information, see https://go.microsoft.com/fwlink/?linkid=868374.\n\nCommit migrated from 373bf2b74f
2019-04-16 20:44:34 -07:00
Pranav K 92e86f9d02 Check for TargetFramework in addition to version (dotnet/aspnetcore-tooling#428)
* Check for TargetFramework in addition to version

\n\nCommit migrated from a4ed82f823
2019-04-16 11:13:26 -07:00
Doug Bunting ae4af3d154 Shorten Microsoft.AspNetCore.Razor.Language.Test paths (dotnet/aspnetcore-tooling#425)
* Shorten Microsoft.AspNetCore.Razor.Language.Test paths
- aspnet/AspNetCoredotnet/aspnetcore-tooling#9358 and aspnet/AspNetCoredotnet/aspnetcore-tooling#7882
- do 4046 renames
- adjust solutions to renamed directory
- special-case directory of the Microsoft.AspNetCore.Razor.Language.Test project in `TestProject`\n\nCommit migrated from 72b939d855
2019-04-15 10:46:17 -07:00
Pranav K 90eb9e8535 Fixup SDK workarounds (dotnet/aspnetcore-tooling#413)
* Correctly update the .NET Core SDK used in Razor
* Replace LangVersion 8.0 with LangVersion Preview
* Remove AddRazorSupportForMvc from projects that do not require it
* Cleanup how AspNetCore.App is not referenced in the project
* Remove uses of _RazorComponentInclude from tests\n\nCommit migrated from 81ea07caf7
2019-04-12 11:17:09 -07:00
Ajay Bhargav Baaskaran 607f64b386 Don't render text tags for component documents (dotnet/aspnetcore-tooling#391)
\n\nCommit migrated from cb6f5d0dc7
2019-04-06 19:46:24 -07:00
dotnet-maestro[bot] 7957c11d02 [master] Update dependencies from dotnet/arcade (dotnet/aspnetcore-tooling#346)
* Update dependencies from https://github.com/dotnet/arcade build 20190317.10

This change updates the following dependencies
- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19167.10

* Update dependencies from https://github.com/dotnet/arcade build 20190320.2

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19170.2

* Update dependencies from https://github.com/dotnet/arcade build 20190321.3

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19171.3

* Update dependencies from https://github.com/dotnet/arcade build 20190321.6

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19171.6

* Update dependencies from https://github.com/dotnet/arcade build 20190325.9

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19175.9

* Update dependencies from https://github.com/dotnet/arcade build 20190326.14

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19176.14

* Update dependencies from https://github.com/dotnet/arcade build 20190327.11

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19177.11

* Update dependencies from https://github.com/dotnet/arcade build 20190329.1

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19179.1

* Update dependencies from https://github.com/dotnet/arcade build 20190329.2

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19179.2

* Update dependencies from https://github.com/dotnet/arcade build 20190401.12

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19201.12

* Update dependencies from https://github.com/dotnet/arcade build 20190402.13

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19202.13

* Update dependencies from https://github.com/dotnet/arcade build 20190403.10

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19203.10

* Update dependencies from https://github.com/dotnet/arcade build 20190404.16

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19204.16

* Update dependencies from https://github.com/dotnet/arcade build 20190405.6

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19205.6

* Use updated Arcade NuSpec helpers
- provide `InitializeStandardNuspecProperties` with expected information
- use `$CommonMetadataElements$` in Microsoft.NET.Sdk.Razor.nuspec

nits:
- correct a typo or two
\n\nCommit migrated from c60b63e296
2019-04-07 00:22:02 +00:00
Ajay Bhargav Baaskaran 35edb562c5 Match component childcontent tag helper from a different namespace (dotnet/aspnetcore-tooling#390)
\n\nCommit migrated from 8a815a1882
2019-04-05 16:00:29 -07:00
Pranav K 5b71a24b4f Fixup
\n\nCommit migrated from f6dd261211
2019-04-04 06:05:46 -07:00
Pranav K 37275e5fd5 Do not generate MVC attributes unless necessary
Fixes https://github.com/aspnet/AspNetCore/issues/8161
\n\nCommit migrated from a976b80c7c
2019-04-03 21:57:08 -07:00
Ajay Bhargav Baaskaran 01e9d70207 Decode HTML entities (dotnet/aspnetcore-tooling#379)
* Decode HTML entities
\n\nCommit migrated from 6b7b9a3bc3
2019-04-03 10:03:42 -07:00
Ajay Bhargav Baaskaran 249752087e Fix csharp intellisense in _Imports.razor (dotnet/aspnetcore-tooling#387)
* Fix csharp intellisense in _Imports.razor

* Feedback
\n\nCommit migrated from 229951a5c8
2019-04-02 21:55:37 -07:00
N. Taylor Mullen b1aef03aaf Expand RazorProject.GetItem to take in FileKinds when getting items.
- Obsoleted old `GetItem` API.
- Updated tests to take new API.
- Added a new test to verify the broken scenario.

dotnet/aspnetcore-tooling#8972
\n\nCommit migrated from 2dd34b8dd8
2019-04-02 13:32:35 -07:00
N. Taylor Mullen ea5d10509e Expand RazorProject.GetItem to take in FileKinds when getting items.
- Obsoleted old `GetItem` API.
- Updated tests to take new API.
- Added a new test to verify the broken scenario.

dotnet/aspnetcore-tooling#8972
\n\nCommit migrated from 2dd34b8dd8
2019-04-02 13:32:35 -07:00
Pranav K d365a92ca4 Ensure _TargetingNETCoreApp30OrLater is available for older design time targets (dotnet/aspnetcore-tooling#386)
* Ensure _TargetingNETCoreApp30OrLater is available for design time targets

\n\nCommit migrated from 9d7fd089a6
2019-04-02 13:00:22 -07:00
Pranav K 8bc448e255 Prevent build failures and warnings when building 2.x projects (dotnet/aspnetcore-tooling#382)
* Move targets for component design time generation to
Components.targets

* Provide a better error message when referencing a 2.x Razor.Design
package in a 3.0 project

* Do not produce a warning for unresolved configuration when building
2.x projects\n\nCommit migrated from b5b1647646
2019-04-01 22:38:09 -07:00
Ryan Nowak 2ff5e7301e Fixes: dotnet/aspnetcore-tooling#5640 FormatException from diagnostic
This was just a badly written diagnostic format string
\n\nCommit migrated from ef7d82a7ff
2019-04-01 20:44:26 -07:00
Ajay Bhargav Baaskaran 8bb16c28aa Prevent newlines from being encoded in the output (dotnet/aspnetcore-tooling#374)
* Prevent newlines from being encoded in the output
\n\nCommit migrated from 5f74fae0d2
2019-03-29 13:04:15 -07:00
Steve Sanderson 8a8e144653 Remove base.BuildRenderTree calls (dotnet/aspnetcore-tooling#368)
\n\nCommit migrated from bcc77db762
2019-03-28 12:46:36 +00:00
Ajay Bhargav Baaskaran 8eee2d5bc4 Skip running ModelDirective pass for component documents (dotnet/aspnetcore-tooling#372)
\n\nCommit migrated from 6824620cb0
2019-03-27 09:52:34 -07:00
Ajay Bhargav Baaskaran 730f3cdc6b Better support for _Imports.razor (dotnet/aspnetcore-tooling#357)
* Better support for _Imports.razor

* Special case component imports when generating code

* Prevent a future VS crash

* Rebased and updated

* update

* Removed unnecessary newline
\n\nCommit migrated from abbfe00bdc
2019-03-26 17:58:37 -07:00
N. Taylor Mullen 784596aba6 Add support for C# 8 using variable declarations and add more C# 8 coverage.
- When adding additional C# 8 tests found that we didn't fully support this.
- Updated the C# 8.0 test to fully encompass everything C# 8.0.
- Added a feature flag to control using variable declaration errors when not top level.
- Added using variable declaration specific tests.

aspnet/AspNetCoredotnet/aspnetcore-tooling#5092
\n\nCommit migrated from ac08ad3659
2019-03-26 17:37:12 -07:00
Pranav K 6eb9044660 Fixup invalid configuration error message (dotnet/aspnetcore-tooling#365)
* Fix invalid parameter used in error message
* Re-organize test code\n\nCommit migrated from 5a73c2abe9
2019-03-26 08:58:38 -07:00
Javier Calvarro Nelson 9c35c07a0b bind-Value on EditText often results in the wrong thing (dotnet/aspnetcore-tooling#364)
Updates the bindtaghelperdescriptorprovider to use the changed event property type name on the bound attribute instead of the value property type attribute.\n\nCommit migrated from 3009045206
2019-03-26 10:06:18 +01:00
N. Taylor Mullen f98ffcd759 Update more test files.
\n\nCommit migrated from 76c1352d2c
2019-03-25 20:26:36 -07:00
N. Taylor Mullen 40340e9b91 Design update.
\n\nCommit migrated from c9e0d2a60f
2019-03-25 20:26:36 -07:00
N. Taylor Mullen f33e1fca53 Enforce nullability for user code.
- Expanded the `ProjectWorkspaceStateGenerator` to extract the C# language version when building the `ProjectWorkspaceState`. This approach enables all platforms to get nullability support without any changes (as long as they support `ProjectWorkspaceState`, which they do). Also, Roslyn suggested that we avoid dealing with LangVersion directly because there are several factors that impact its "effective" value on a project when run in tooling.
- Updated the `LinePragma` code generation to include `#nullable restore` and `#nullable disable` lines to allow for project restored nullability state for user code.
- Added a new `RazorProjectEngineBuilderExtensions` class that adds Roslyn specific project engine modifications. In this case it allows us to set the C# language version for a project engine and configure underlying features accordingly.
- Added a `SuppressNullabilityEnforcement` flag that only turns on if C# < 8 is specified.
- Updated LiveShare, VS4Mac and RazorGenerate to understand CSharpLanguageVersion.
- Added a single test output to show the change.

dotnet/aspnetcore-tooling#5092
\n\nCommit migrated from 1df8128b87
2019-03-25 20:26:36 -07:00
Pranav K 31e916cdfd Add .razor files to UpToDateCheckInput (dotnet/aspnetcore-tooling#359)
Fixes https://github.com/aspnet/AspNetCore/issues/8181\n\nCommit migrated from da168188b4
2019-03-23 14:05:21 -07:00
Ajay Bhargav Baaskaran 1d53925b8e Fixed generic components with fully qualified names (dotnet/aspnetcore-tooling#356)
\n\nCommit migrated from b7392f1f84
2019-03-22 14:22:12 -07:00
Ajay Bhargav Baaskaran 92d931c229 Support importing components with @using directives (dotnet/aspnetcore-tooling#276)
* Support importing components with @using directives

* Suppress taghelper directive completion in component documents

* feedback

* More feedback

* Update tests

* Update CodeAnalysis.Razor tests

* Flow filekind

* Changes

* More code gen tests

* More tests

* fix

* Added more tests

* Made stuff internal

* Filter out temporary tag helper descriptors

* update

* Do the needful
\n\nCommit migrated from 343f37748e
2019-03-22 10:29:38 -07:00
Ajay Bhargav Baaskaran 91a383ad3b Add support for _Imports.razor (dotnet/aspnetcore-tooling#354)
* Added support _Imports.razor

* Feedback
\n\nCommit migrated from 14704054f2
2019-03-22 09:19:56 -07:00
Ajay Bhargav Baaskaran 62199e2195 Bring back errors for missing tags in component documents (dotnet/aspnetcore-tooling#351)
\n\nCommit migrated from ca1e656f6b
2019-03-21 12:22:28 -07:00
Pranav K b2b207faa1 Allow some warnings (dotnet/aspnetcore-tooling#353)
Fixes https://github.com/aspnet/AspNetCore-Internal/issues/2050\n\nCommit migrated from e2b1df744e
2019-03-21 12:10:16 -07:00
Pranav K cf116d619b Do not restore as part of test (dotnet/aspnetcore-tooling#350)
\n\nCommit migrated from 84bc53671f
2019-03-21 09:28:44 -07:00
N. Taylor Mullen e5064d3c76 Allow markup in local functions and @functions.
- Allow markup to exist in all code blocks. Prior to this change whenever we'd see nested curly braces we would do dumb brace matching to skip over any potentially risky code; now we treat every curly brace as an opportunity to intermingle Markup.
- One fix I had to introduce was now that functions blocks are parsed like `@{}` blocks I ran into cases where certain reserved keywords would get improperly parsed. This exposed a bug in our parsing where we’d treat **class** and **namespace** as directives without a transition in a `@{}` block. For instance this:
```
@{
    class
}
```
would barf in the old parser by treating the `class` piece as a directive even though it did not have a transition. To account for this I changed our reserved directives to be parsed as directives instead of keywords (it's how they should have been parsed anyhow). This isn't a breaking change because the directive parsing logic is a subset of how keywords get parsed.

- One quirk this change introduces is a difference in behavior in regards to one error case. Before this change if you were to have `@if (foo)) { var bar = foo; }` the entire statement would be classified as C# and you'd get a C# error on the trailing `)`. With my changes we try to keep group statements together more closely and allow for HTML in unexpected or end of statement scenarios. So, with these new changes the above example would only have `@if (foo))` classified as C# and the rest as markup because the original was invalid.
- Added lots of tests,
- Modified the feature flag to maintain the old behavior when disabled.

aspnet/AspNetCoredotnet/aspnetcore-tooling#5110
\n\nCommit migrated from 5ffd84e56d
2019-03-20 10:38:50 -07:00
Pranav K 25e5a4ffab Infer Razor Configuration \ RazorLangVersion based on TFM (dotnet/aspnetcore-tooling#343)
* Infer Razor Configuration \ RazorLangVersion based on TFM

Fixes https://github.com/aspnet/AspNetCore/issues/6392
\n\nCommit migrated from cfee40a19e
2019-03-19 16:33:26 -07:00
Ajay Bhargav Baaskaran ec503be2d5 Flow RootNamespace from MSBuild (dotnet/aspnetcore-tooling#331)
- Flow Root namespace through in command line builds

- Flow Root namespace through in design time builds

- Feedback\n\nCommit migrated from 057d4f3570
2019-03-13 14:18:07 -07:00
Ajay Bhargav Baaskaran 2c39457306 Flow RootNamespace from MSBuild (dotnet/aspnetcore-tooling#331)
- Flow Root namespace through in command line builds

- Flow Root namespace through in design time builds

- Feedback\n\nCommit migrated from 057d4f3570
2019-03-13 14:18:07 -07:00
Andrew Stanton-Nurse eeabe9ee71 skip flaky razor build integration test (dotnet/aspnetcore-tooling#326)
mitigates aspnet/AspNetCore-Internaldotnet/aspnetcore-tooling#1931\n\nCommit migrated from 128efdd177
2019-03-12 09:51:35 -07:00
Ajay Bhargav Baaskaran 6747e90b05 Preserve diagnostics when rewriting Red nodes (dotnet/aspnetcore-tooling#319)
\n\nCommit migrated from 276532454e
2019-03-11 10:31:37 -07:00
Ajay Bhargav Baaskaran c5c30e460e Preserve diagnostics when rewriting Red nodes (dotnet/aspnetcore-tooling#319)
\n\nCommit migrated from 276532454e
2019-03-11 10:31:37 -07:00
Ajay Bhargav Baaskaran c7dcbd82d6 Added missed files to RazorSyntaxGenerator (dotnet/aspnetcore-tooling#318)
\n\nCommit migrated from 84066bc880
2019-03-08 15:56:46 -08:00
Ajay Bhargav Baaskaran b2b8ca6479 Added RazorSyntaxGenerator to the repo (dotnet/aspnetcore-tooling#313)
\n\nCommit migrated from cdafa554d7
2019-03-08 10:40:43 -08:00
N. Taylor Mullen b3d727b631 Enable IntelliSense for new component parameters.
- Added a `FilePathComparison` object since not all string methods allow a comparer.
- Updated `RazorDirectiveCompletionProvider` to also understand `.razor` files. This is an edge case scenario where users have disabled modern completion and are using Razor components (you need a reg key to disable the modern completion or MS needs to disable it).
- Tested this in VS by referencing the latest Razor SDK (preview 3) from NuGet and then replacing the Razor design time targets in VS to be the ones from the preview 3 package.
- Added workspace project state change detector tests.

dotnet/aspnetcore-tooling#8064
\n\nCommit migrated from 6a83ed13fc
2019-03-08 09:01:03 -08:00
Ajay Bhargav Baaskaran 1657080589 Correctly normalize file path from network shares (dotnet/aspnetcore-tooling#298)
* Correctly normalize file path from network shares

* Feedback
\n\nCommit migrated from 8ee676d84c
2019-03-05 15:13:54 -08:00
Ajay Bhargav Baaskaran 8775af3309 Re-enable skipped test (dotnet/aspnetcore-tooling#303)
\n\nCommit migrated from 14eee079bf
2019-03-05 12:22:21 -08:00
N. Taylor Mullen 9ffd08c061 Remove rarely used public obsolete public API.
- The `DocumentWriter` case should never be called because you need to override a lot of the internals of the RazorEngine to get to the document writer. Therefore, little harm in removing the method.
- `ProjectChangeEventArgs` used to be uised by the LiveShare extension. We've since taken ownership of those bits and no longer need to maintain those constructors.
- `DefaultTagHelperDescriptorProvider.DesignTime` didn't actually do anything. Removing since the code was truly dead and did nothing functionally.

dotnet/aspnetcore-tooling#7146
\n\nCommit migrated from ba6450a695
2019-03-04 19:35:17 -08:00
N. Taylor Mullen 53392ba761 Add LanguageServer Common IVTs
\n\nCommit migrated from 29b0e92bcd
2019-03-04 15:08:49 -08:00
Ajay Bhargav Baaskaran ede3a6809e Temporarily skip test (dotnet/aspnetcore-tooling#288)
\n\nCommit migrated from 0598ec4497
2019-03-01 11:48:46 -08:00
Sebastien Ros 275960631d Updating ref file 2019-03-01 10:52:24 -08:00
Sébastien Ros 1c2c2c9be0 Update NullHtmlEncoder.cs 2019-03-01 10:52:24 -08:00
Sebastien Ros 23dee7c43f Keep argument checks 2019-03-01 10:52:24 -08:00
Sebastien Ros ba875bffcd Using spans to optimize the slicing case 2019-03-01 10:52:24 -08:00
Sebastien Ros 55fea7976c Improve NullHtmlEncoder perf 2019-03-01 10:52:23 -08:00
Pranav K 1af49ef26f Reference the SDK project to make build time restore actually work (dotnet/aspnetcore-tooling#278)
\n\nCommit migrated from 22f4c134c1
2019-03-01 09:35:52 -08:00
Ajay Bhargav Baaskaran c7b34a9184 Unskip test (dotnet/aspnetcore-tooling#231)
* Unskip test

* Better test
\n\nCommit migrated from 933d0919ad
2019-02-28 17:21:55 -08:00
N. Taylor Mullen 875e40a5c1 Skip first run experience locally and on azure pipelines.
- This would cause our functional tests to time out and occasionally crash due to dotnet first run experience sentinels being locked.

aspnet/AspNetCore-Internaldotnet/aspnetcore-tooling#1859
\n\nCommit migrated from 2668a0e8a9
2019-02-28 15:25:50 -08:00
N. Taylor Mullen 740b1d3c27 Move TagHelperResolver to CodeAnalysis.Workspaces
- There's nothing specific about the TagHelperResolver that needs to be bound to VS. Moving it to the workspaces assembly so it can be used by VSCode.
- Also changed the `TagHelperResolver` to be an `IWorkspaceService`.
\n\nCommit migrated from 9f73afef3a
2019-02-26 11:28:11 -08:00
Ryan Nowak 6274d4ec86 Update naming and branding for components
\n\nCommit migrated from f820894941
2019-02-25 19:17:00 -08:00
Ryan Nowak 8f76b90585 Add new nesting capability
\n\nCommit migrated from 2ca30ed836
2019-02-25 17:39:44 -08:00
N. Taylor Mullen 921373b0a6 Add IVT to OmniSharpPlugin.StrongNamed.
\n\nCommit migrated from b66f016af8
2019-02-22 16:59:34 -08:00
Nate McMaster d05aa84ec3 Merge branch 'release/3.0-preview3'
\n\nCommit migrated from ce4813df7d
2019-02-22 10:26:10 -08:00
Nate McMaster 61e85256a6 Update dependencies and remove some unused version variable overrides (dotnet/aspnetcore-tooling#238)
* Update dependencies
* Add workaround for dotnet/sdkdotnet/aspnetcore-tooling#2976
* Remove unused NETStandard package version variable and overrides
* Update xunit to 2.4.1
\n\nCommit migrated from 67082970b7
2019-02-22 10:24:51 -08:00
Ryan Nowak 81ac40e82d Fix a bad copy-paste
\n\nCommit migrated from d63c6bbc2c
2019-02-21 15:23:43 -08:00
Pavel Krymets 9355c7c1a5
Add reference assemblies support (#7764) 2019-02-21 14:33:35 -08:00
Nate McMaster 9a2db43848
Follow-up to VS2019 conversion (#7753)
* Set VS version in file to 16.0.0.0
* Fix for restore failure on Microsoft.AspNetCore.App.Runtime.csproj
2019-02-20 11:02:38 -08:00
Nate McMaster 85ae18c723
Make Visual Studio 2019 a prerequisite to building this repo (#7005)
Changes:

* Make Visual Studio 2019 a prerequisite for building this repo
* Update .sln files
* Update Windows SDK to 17134
* Update developer docs
* Disable ANCM tests
* Update to .NET Core SDK 3.0 Preview 2
* Use Microsoft.NET.Sdk.Razor as a package consistently accross the repo
* React to changes in metadata from Microsoft.NETCore.App
* React to changes in .NET Core SDK
* Attempt to workaround CodeCheck.ps1 failure which doesn't repro locally or on different agents. Possibly due to differences in the version of the PowerShell task?
* Remove dead YML file
* Rename usages of win7-{x64,x86} to win-{x64,x86}
* Update KoreBuild to 3.0.0-build-20190219.1
2019-02-20 09:53:53 -08:00
Ajay Bhargav Baaskaran ca3e094bee Fixed an assumption in ComponentLoweringPass (dotnet/aspnetcore-tooling#226)
\n\nCommit migrated from 87bb138304
2019-02-20 09:25:12 -08:00
Ryan Nowak 54e79153ec Add compiler support for EventCallback (dotnet/aspnetcore-tooling#222)
* Add new APIs to ComponentShim

* Add new APIs to ComponentsApi

* Add EventCallback metadata

* Add discovery of EventCallback properties

* Errata for Runtime APIs

* Add ability to use EventCallback as parameter

* Add support for bind to component

* Use EventCallback for bind-... to elements

* Use EventCallback<T> for event handlers
\n\nCommit migrated from a0b6bc0e52
2019-02-19 12:39:34 -08:00
N. Taylor Mullen 1243e07e56 Make TagHelper & Razor comments locatable at design time.
- Added a step to full fidelity verification that does a `LocateOwner` at every source location. If we find a `null` owner we build a snippet with a detailed response to enable us to diagnose the problem.

Addresses aspnet/AspNetCoredotnet/aspnetcore-tooling#7718
\n\nCommit migrated from 08587a30fd
2019-02-19 12:31:36 -08:00
Steve Sanderson 82d850d3a7 Components that accept bind-Something can request SomethingExpression (dotnet/aspnetcore-tooling#213)
* In binding to components, automatically supply FooExpression when requested

* Fix tests

* CR feedback
\n\nCommit migrated from ca9de74f4e
2019-02-18 09:37:41 +00:00
Ajay Bhargav Baaskaran 0ab2a1e586 Fix an assumption in ComponentBindLoweringPass (dotnet/aspnetcore-tooling#212)
\n\nCommit migrated from 315f804d6e
2019-02-14 17:25:52 -08:00
Nate McMaster 338de4710a
Automatically set 'PrivateAssets=All' for .Sources references (#7539)
When a `<Reference>` is named `*.Sources`, set PrivateAssets=All (exclude from generated nuspec) and IncludeAssets=ContentFiles (only consume content files, not .dll's)
2019-02-13 14:31:15 -08:00
Nate McMaster 3fd8a97af2
Add targets to generate the list of shared framework assemblies from project property (#7510)
Changes:
* Add support for a property, `IsAspNetCoreApp`, in the .csproj file of assemblies which are part of the shared framework. 
* Remove unused dependencies
* Remove reference which have become part of 'netcoreapp3.0'
2019-02-12 23:00:19 -08:00
Pranav K 8b61ae7196 Use new PreserveCompilationReferences in Razor Sdk (dotnet/aspnetcore-tooling#187)
* Use new PreserveCompilationReferences in Razor Sdk

Fixes https://github.com/aspnet/AspNetCore/issues/6512
\n\nCommit migrated from f58c436961
2019-02-11 19:54:04 -08:00
Doug Bunting 58e6d78549 Suppress Razor warnings about missing doc comments 2019-02-11 10:35:48 -08:00
N. Taylor Mullen abd5ab8080 Add @await foreach for C# 8
- Added general C# 8 tests that we can use to include nullability when the time comes.
- Added statement test to ensure syntax tree is correct for await foreach.

aspnet/AspNetCoredotnet/aspnetcore-tooling#5078
\n\nCommit migrated from 27e1d8c011
2019-02-11 09:45:02 -08:00
N. Taylor Mullen 824796b4e4 Add IVT to LanguageServer.Common project.
\n\nCommit migrated from b18dcbff57
2019-02-08 17:32:39 -08:00
Nate McMaster cc065f0055
Produce a package with just reference assemblies for AspNetCore.App (#7355) 2019-02-07 19:47:52 -08:00
Ajay Bhargav Baaskaran 990c585eba Merge branch 'release/vs16.0-preview4'
\n\nCommit migrated from 408b123a64
2019-02-07 15:08:16 -08:00
Ajay Bhargav Baaskaran daeb4f80d1 Fix invalid cast with end script tag containing code (dotnet/aspnetcore-tooling#193)
\n\nCommit migrated from 56fa17b094
2019-02-07 15:06:26 -08:00
Ajay Bhargav Baaskaran 73ca91f603 Handle multiple nested sections correctly (dotnet/aspnetcore-tooling#196)
\n\nCommit migrated from 26e8d86b21
2019-02-07 14:04:57 -08:00
Ajay Bhargav Baaskaran 57c10c0321 Fixed null-ref with reserved word inside a code block (dotnet/aspnetcore-tooling#192)
\n\nCommit migrated from 10dbc434ee
2019-02-07 14:03:23 -08:00
Ajay Bhargav Baaskaran b15af76917 Fix crash with code blocks in tag helper attributes (dotnet/aspnetcore-tooling#190)
* Fix crash with code blocks in tag helper attributes

* Better fix

* Fixed another case
\n\nCommit migrated from 9e97ba9b97
2019-02-07 14:02:10 -08:00
Pranav K 1cbc513cfb Restore packages as part of build to avoid restore timeouts as part of running tests
Fixes https://github.com/aspnet/AspNetCore-Internal/issues/1701
\n\nCommit migrated from 7f49b97eb5
2019-02-06 14:04:24 -08:00
N. Taylor Mullen 3c6f99b3f1 Merge branch 'release/vs16.0-preview4'
\n\nCommit migrated from 5af7556663
2019-02-01 11:08:57 -08:00
N. Taylor Mullen 83c8c0cba2 Don't associate Roslyn workspace project with ProjectSnapshot.
- Removed the differences of workspace project and `HostProject` in regards to `ProjectSnapshotManager` methods. We now just have `ProjectAdded`, `ProjectRemoved` etc.
- Obsoleted Workspace related members from the `ProjectSnapshot`in order to ensure that current LiveShare continues to work. Once LiveShare has been incorporated into Razor we can remove these members from the project snapshot.
- Removed several TagHelper calculating logic pieces from the document tracker. This is now done entirely from the ProjectSnapshotManager so there's no secondary route that needs to be taken in order to resolve TagHelpers for VS windows cases.
- Updated the `ProjectState` to take in TagHelpers and removed the internal logic it had to resolve TagHelpers.
- Added a TagHelpers property to ProjectSnapshot to indicate that they're no longer calculated, they're part of the project inputs.
- Added a ProjectWorkspaceChange generator to be responsible for calculating any workspace related information that is needed for a `ProjectSnapshot`. For now, this just calculates TagHelpers but in the future it may do more.
- Added a `FilePathComparison` static helper class which acts similarly to `FilePathComparer`.
- Changed our dynamic file info provider to no longer care about `ProjectIds`. Before this, it kept track of the project ids internally but never used them so this is a noop functional change.
- Changed how the out of process remote TagHelper resolution flow works. Prior to this you'd pass a Project across the wire as part of a project snapshot handle and then resolve TagHelpers the old fashioned way.
- Updated all existing tests to respect the new `ProjectWorkspaceState` flows.
- Added tests for new APIs.

dotnet/aspnetcore-tooling#6672
\n\nCommit migrated from a5621641f8
2019-02-01 11:06:20 -08:00
N. Taylor Mullen e4a686575c Don't associate Roslyn workspace project with ProjectSnapshot.
- Removed the differences of workspace project and `HostProject` in regards to `ProjectSnapshotManager` methods. We now just have `ProjectAdded`, `ProjectRemoved` etc.
- Obsoleted Workspace related members from the `ProjectSnapshot`in order to ensure that current LiveShare continues to work. Once LiveShare has been incorporated into Razor we can remove these members from the project snapshot.
- Removed several TagHelper calculating logic pieces from the document tracker. This is now done entirely from the ProjectSnapshotManager so there's no secondary route that needs to be taken in order to resolve TagHelpers for VS windows cases.
- Updated the `ProjectState` to take in TagHelpers and removed the internal logic it had to resolve TagHelpers.
- Added a TagHelpers property to ProjectSnapshot to indicate that they're no longer calculated, they're part of the project inputs.
- Added a ProjectWorkspaceChange generator to be responsible for calculating any workspace related information that is needed for a `ProjectSnapshot`. For now, this just calculates TagHelpers but in the future it may do more.
- Added a `FilePathComparison` static helper class which acts similarly to `FilePathComparer`.
- Changed our dynamic file info provider to no longer care about `ProjectIds`. Before this, it kept track of the project ids internally but never used them so this is a noop functional change.
- Changed how the out of process remote TagHelper resolution flow works. Prior to this you'd pass a Project across the wire as part of a project snapshot handle and then resolve TagHelpers the old fashioned way.
- Updated all existing tests to respect the new `ProjectWorkspaceState` flows.
- Added tests for new APIs.

dotnet/aspnetcore-tooling#6672
\n\nCommit migrated from a5621641f8
2019-02-01 11:06:20 -08:00
N. Taylor Mullen 12a6864710 Prioritize local dotnet when running SDK Razor tests.
- The SDK tests were occasionally failing with access denied due to the test using the machines dotnet.exe (instead of the local projects dotnet.exe).

dotnet/aspnetcore-tooling#1667
\n\nCommit migrated from 1a96714921
2019-02-01 11:06:19 -08:00
Ajay Bhargav Baaskaran b87b984902 Merge branch 'release/vs16.0-preview3'
\n\nCommit migrated from 77532db903
2019-02-01 10:59:34 -08:00
Ajay Bhargav Baaskaran 57211a33db Fix: Exception for empty data- attributes in tag helpers (dotnet/aspnetcore-tooling#173)
\n\nCommit migrated from 6d71b6a265
2019-01-30 09:12:37 -08:00
Pranav K 4505f76987 Ensure TagHelpers from the current project are discovered for projects targeting 2.x
As part of migrating the CodeGeneration targets in to the Razor.Sdk,
the SDK broke the contract that RazorReferencePaths includes the full closure
of assemblies during tag helper discovery.

This change restores the behavior to be compatible with the 2.x Razor.Design
package and adds tests to verify TagHelper discovery works in a range of projects.

Fixes https://github.com/aspnet/AspNetCore/issues/6825
\n\nCommit migrated from 99938c9b7e
2019-01-29 11:21:27 -08:00
Ryan Nowak d4c3a2fbd9 Fix dependency to aspnet/AspNetCore-Tooling (dotnet/aspnetcore-tooling#170)
* Remove unused package versions
* Remove references to Html.Abstractions
Removing this package since it's from the aspnet/AspNetCore.

* Remove System.ValueTuple package inside remove
* Add versions.details.xml items from corefx
* Add Microsoft.NETCore.App
* Fill up Version.Details.xml
* Update dependencies
* Fix failing test
\n\nCommit migrated from bd7fc9ddf6
2019-01-24 16:57:16 -08:00
Ajay Bhargav Baaskaran 642a2f5789 Final cleanup to remove all traces of ParseBlockTest (dotnet/aspnetcore-tooling#169)
\n\nCommit migrated from e160872142
2019-01-24 12:42:10 -08:00
N. Taylor Mullen 67588374aa Convert HtmlAttributeTest to use ParseDocument
aspnet/AspNetCoredotnet/aspnetcore-tooling#6470
\n\nCommit migrated from 61b7265bed
2019-01-24 09:05:52 -08:00
Ajay Bhargav Baaskaran cdaad2964d Fix tag grouping for tags with no name
\n\nCommit migrated from f5c1068d88
2019-01-22 15:32:22 -08:00
Ajay Bhargav Baaskaran 6c6e048dcc Fix missing transition in using keyword
\n\nCommit migrated from 02781b17cd
2019-01-22 15:32:22 -08:00
Ajay Bhargav Baaskaran 542d17bbfa Fix tag grouping for tags with no name
\n\nCommit migrated from e24c9b25a4
2019-01-22 14:49:21 -08:00
Ajay Bhargav Baaskaran f97ab076b5 Fix missing transition in using keyword
\n\nCommit migrated from dd45375f72
2019-01-22 14:38:28 -08:00
Pranav K ada61cf03d Ensure updates to Razor components trigger design time build
* Use _RazorComponentInclude to determine the set of files to set Generator property for
* Run RazorGenerateComponentDeclarationDesignTime instead of RazorComponentGenerate during design time builds
* Update design time targets to set Generator for content files with .razor extension.

Fixes https://github.com/aspnet/AspNetCore/issues/6859
Fixes https://github.com/aspnet/AspNetCore/issues/6860
\n\nCommit migrated from 37d96aa417
2019-01-22 09:37:18 -08:00
Ajay Bhargav Baaskaran 2bbd247b13 Convert CSharpNestedStatementsTest, CSharpReservedWordsTest, CSharpSpecialBlockTest and CSharpStatementTest to use ParseDocumentTest (dotnet/aspnetcore-tooling#148)
\n\nCommit migrated from 45b304a348
2019-01-18 13:26:58 -08:00
Ajay Bhargav Baaskaran e7d5ee95ed Port: Fix failing file comparison tests (dotnet/aspnetcore-tooling#135)
\n\nCommit migrated from 5166fec846
2019-01-18 08:50:22 -08:00
Ajay Bhargav Baaskaran 31e2271134 Enable full fidelity check for ParseBlock tests as well (dotnet/aspnetcore-tooling#137)
\n\nCommit migrated from 6ca6a37f9b
2019-01-17 17:30:15 -08:00
Ajay Bhargav Baaskaran 299db398fe Merge pull request dotnet/aspnetcore-tooling#136 from aspnet/release/vs16.0-preview3
Merge branch release/vs16.0-preview3 to master\n\nCommit migrated from abb01b0653
2019-01-17 14:15:35 -08:00
Ajay Bhargav Baaskaran e6b8c86a48 Better structure for Tag helper start/end tags (dotnet/aspnetcore-tooling#132)
\n\nCommit migrated from f6ab4cc1d1
2019-01-17 13:38:17 -08:00
NTaylorMullen 237a7a65d6 Seal RestrictChildrenAttribute.
Addresses #5041
2019-01-16 15:03:30 -08:00
NTaylorMullen 060c8e63b1 Remove RazorTemplateEngine and friends.
- Also nuked tests and resource entries specific to the template engine.

Addresses aspnet/AspNetCoredotnet/aspnetcore-tooling#5079
\n\nCommit migrated from d5f0b4c0b4
2019-01-16 14:26:31 -08:00
N. Taylor Mullen 439349899b Prioritize local dotnet when running SDK Razor tests.
- The SDK tests were occasionally failing with access denied due to the test using the machines dotnet.exe (instead of the local projects dotnet.exe).

dotnet/aspnetcore-tooling#1667
\n\nCommit migrated from bb2134a536
2019-01-15 15:38:52 -08:00
N. Taylor Mullen 7eb90cbbbd Remove obsolete RazorProject ViewEngine based create method.
aspnet/AspNetCoredotnet/aspnetcore-tooling#4876
\n\nCommit migrated from 57df0ea9cf
2019-01-15 15:36:02 -08:00
Ajay Bhargav Baaskaran ceb4d0853a Some minor cleanup (dotnet/aspnetcore-tooling#123)
\n\nCommit migrated from 97930b91f8
2019-01-15 15:26:44 -08:00
Ryan Nowak 40633dde21 Add attribute only bindings and fix dotnet/aspnetcore-tooling#6373
Adds a new API for WTE to call given a TagHelperBinding to determine if
the binding should colorize/classify only the attributes of the HTML
element in source code. This is driven by a new metadata item that the
Components 'directive attributes' all set. There's no way for a user to
access this feature via tag helpers currently, but it could be added
easily in the future.

Also fixing dotnet/aspnetcore-tooling#6376 while I'm in there. 👍
\n\nCommit migrated from df449beea9
2019-01-14 15:25:49 -08:00
Pranav K 148bc99cce Use a property to allow specifying component globbing pattern
Workaround for https://github.com/aspnet/AspNetCore/issues/6500
\n\nCommit migrated from cee0223732
2019-01-14 14:53:24 -08:00
Ajay Bhargav Baaskaran 56695d17c9 Set ParserContext.StartOfLine to true when parsing starts (dotnet/aspnetcore-tooling#116)
* Set ParserContext.StartOfLine to true when parsing starts

* Missed baselines
\n\nCommit migrated from a80c3a981a
2019-01-14 14:17:22 -08:00
Ajay Bhargav Baaskaran d5e9a153c7 Correctly handle whitespace that precedes a Razor directive (dotnet/aspnetcore-tooling#117)
\n\nCommit migrated from 15556c8ff3
2019-01-14 11:59:37 -08:00
Ryan Nowak 9541938327 Fix A VS issue
The issue here is that the downlevel SDK (2.1/2.2) don't define the
component-related targets needed for the component design time build.
Depending on the ordering of targets, this can break all features in VS
that depend on the design-time build.

Since we want this to noop in those cases, the best fix is to make our
targets depend on a target property that will be empty in the downlevel
SDKS, but will contain our targets in the 3.0 SDK.

(cherry picked from commit dotnet/aspnetcore-tooling@b88b32c73a)
\n\nCommit migrated from 1c4b19ae88
2019-01-14 08:55:39 -08:00
Ajay Bhargav Baaskaran b0e2dc2add Added check to ensure we generate syntax tree with full fidelity (dotnet/aspnetcore-tooling#111)
* Added check to ensure we generate syntax tree with full fidelity

* Better check

* Feedback
\n\nCommit migrated from 88653fc348
2019-01-10 13:55:28 -08:00
Nate McMaster 0f65d44482
Merge branch 'release/2.2' 2019-01-09 18:09:25 -08:00
Nate McMaster a3f9b74bb9
Merge branch 'release/2.1' into release/2.2 2019-01-09 14:52:53 -08:00
Ajay Bhargav Baaskaran b449a44440 Fix void tags grouping logic (dotnet/aspnetcore-tooling#110)
* Fix void tags grouping logic

* Handle bang in tag name
\n\nCommit migrated from 2c41ae9550
2019-01-09 11:41:10 -08:00
Ajay Bhargav Baaskaran 14afcc3eaf Reenable skipped test (dotnet/aspnetcore-tooling#99)
\n\nCommit migrated from 2ad0641b1e
2019-01-09 11:39:02 -08:00
Ajay Bhargav Baaskaran e1245d874f Fix: Missing void end tag when targeted by TH with WithoutEndTag structure (dotnet/aspnetcore-tooling#105)
\n\nCommit migrated from 33bf2691d5
2019-01-08 16:11:18 -08:00
Nate McMaster 5d16f97965
Remove netcoreapp2.0 test TFMs (#6461)
.NET Core 2.0 reached EOL last year. This removes multi-targeting our test projects and test assets to only use .NET Core 2.1 and .NET Framework 4.6.1.
2019-01-08 11:20:09 -08:00
Ryan Nowak 5b5aa6837f Properly handle attr-value prefix in markup pass
Fixes aspnet/AspNetCoredotnet/aspnetcore-tooling#6480

We were missing handling for the attribute value prefix of a markup
attribute during the markup block rewrite pass. This is properly handled
inside the runtime code writer so you wouldn't see this bug if the
contents of the element were dynamic (and thus could not be rewritten).

Most of the churn here is due to renaming classes. We generally prefer
the term *markup* over *html* in code artifacts, and this was one piece
of new code that refers to html.
\n\nCommit migrated from d16eafd667
2019-01-08 10:10:29 -08:00
Ajay Bhargav Baaskaran 77bd9d343c Fixed exception with non taghelper start/end void tags
\n\nCommit migrated from ee8fdae756
2019-01-07 21:02:10 -08:00
Ajay Bhargav Baaskaran f87d9b5335 Fix null ref in the parser (dotnet/aspnetcore-tooling#103)
\n\nCommit migrated from 8e1629b60b
2019-01-07 20:18:39 -08:00
Ryan Nowak 32a8a7485e Remove workarounds for missing 3.0 support
Leading up the release of VS 16.0p1 we added workarounds to the SDK to
make Razor fall back to the 2.1 configuration for design-time. Since
we're adding the 3.0 language support to preview2 we can remove these
workarounds. These features have been available in internal builds for
some time.
\n\nCommit migrated from e6be8a7a3e
2019-01-07 16:53:55 -08:00
Ryan Nowak d46aa2e2bd Enabling features for Components in VS
This is the final set of enabling features for VS.. including:
- Adding component types to IDE project engine
- Using file kind in the editor
- Enabling component documents in the project system
- Fixing some bugs in the xaml/msbuild authoring
- Adding a missing capability for component projects

The only thing here that probably bears explaining is the class name
mangling. This is a carry over from Blazor, basically because the
generated code is part of the workspace, we have to mangle the class
name to avoid collisions. The work to resolve this is tracked
separately, and will require coordination from a few teams to resolve.
\n\nCommit migrated from d0a8aa3f97
2019-01-07 16:28:48 -08:00
Pranav K 4e909515a7 PR changes
\n\nCommit migrated from ef1a7507c9
2019-01-07 15:43:28 -08:00
Pranav K 500bdc1fd4 Exclude RazorComponent items from RazorGenerate item group
Interim solution to allow components to share the .cshtml extension. When declared in
the project file, the SDK will prevent RazorComponent items from being included
in the RazorGenerate itemgroup.
\n\nCommit migrated from 92e2c70b69
2019-01-07 15:17:41 -08:00
Nate McMaster 9556cc133d
Merge branch 'release/2.1' into release/2.2 2019-01-04 14:17:28 -08:00
Ryan Nowak e6e8fba39c SDK updates for components tooling
This is a bug fix for the RazorComponentWithTargetPath xaml rule. We
need to have separate targets for components and views.

The other fix here is a change to the set of workarounds we're using for
components currently. We need this project capability for the correct
project host to be used when loading the project.
\n\nCommit migrated from 78163f7e4f
2019-01-04 13:08:05 -08:00
Pranav K 49dfd7dacc Add a test using 2.2 project with current Sdk (dotnet/aspnetcore-tooling#91)
* Add a test using 2.2 project with current Sdk

Fixes https://github.com/aspnet/AspNetCore/issues/5101

* Do not reference Microsoft.AspNetCore.App in test apps
\n\nCommit migrated from 9b4fd448d4
2019-01-04 10:36:41 -08:00
Ajay Bhargav Baaskaran 07a62871d0 Make whitespace in extensible directives be SpanKind.None (dotnet/aspnetcore-tooling#90)
\n\nCommit migrated from 9035677e46
2019-01-03 15:58:48 -08:00
Ryan Nowak 7f725e099c Pass filekind through the workspace layer
This commit enables us to initialize projects with the correct file
kind, thus allowing mixed views and components in the same project.

This isn't hooked up to MSBuild yet, so for now nothing will initialize
this code with the correct file kind.
\n\nCommit migrated from 7216d18cfb
2019-01-03 08:50:15 -08:00
Ryan Nowak 19bc651858 Add design-time MSBuild support for components
\n\nCommit migrated from f6f6e16467
2019-01-03 08:50:15 -08:00
Ryan Nowak 14abd88648 Clean up usage of FileKinds
\n\nCommit migrated from b45125a755
2019-01-03 08:50:15 -08:00
Ajay Bhargav Baaskaran 053121e0b7 Refined Start tag and End tag structure (dotnet/aspnetcore-tooling#62)
Regenerated baselines\n\nCommit migrated from d54460296f
2019-01-02 15:32:55 -08:00
Ajay Bhargav Baaskaran a10aff3a03
Specify correct global.json path for Razor.Design tests (#6311) 2019-01-02 14:30:01 -08:00
Nate McMaster 61e505c894
Merge branch 'release/2.1' into release/2.2 2019-01-02 08:58:22 -08:00
Ryan Nowak 583113686c Test cleanup for component tests
This code all got dumped here during the port. This change deletes tests
that have already **moved** to the aspnet/AspNetCore repo.

Also fixed the markup rewriter tests for components.
\n\nCommit migrated from 86cc904004
2019-01-01 22:30:04 -08:00
Ryan Nowak 74d56ce024 Ignore markup comments in components
Fixes: aspnet/AspNetCoredotnet/aspnetcore-tooling#6184

This gives us parity with the current behavior. Since comments aren't
meaningful in a component/render-tree context, we ignore everything
inside of them for codegen/lowering.
\n\nCommit migrated from 7250dd2624
2019-01-01 20:06:32 -08:00
Ryan Nowak f741241171 Fix lowering of data- with HTML for components
This was missed in the previous attempt to fix data- attributes. HTML
wasn't being translated into the correct IR.
\n\nCommit migrated from 239a88d973
2019-01-01 19:40:06 -08:00
Ryan Nowak 724178680f Provide a public entry point for Roslyn features
We need to be able to wire up these features from outside of the Razor
repo. For layering reasons this can't be done in the main Razor
assembly, so it can't be done by default.
\n\nCommit migrated from 386e2b3797
2019-01-01 17:51:48 -08:00
Ryan Nowak f973693438 Fix aspnet/AspNetCoredotnet/aspnetcore-tooling#6186
The issue here is that the compiler generates a different syntax tree
for `data-` attributes :(. I've added a note to dotnet/aspnetcore-tooling#6112 to follow up on
the compiler behavior. We used to parse data- attributes differently for
components, but I really don't think having the compiler special case
them makes sense.

For now I've added a workaround here to lower `data-` attributes in a
fashion similar to other dynamic attribute values.
\n\nCommit migrated from f5109fbfec
2018-12-31 16:14:04 -08:00
Ryan Nowak 7f3a187455 Fix aspnet/AspNetCoredotnet/aspnetcore-tooling#6187
The bug here is that we have extra whitespace being written out when the
component renders. This happens because parser adds an empty C#
statement node to wrap all of the whitespace that precedes `@functions`.
This is tracked by aspnet/AspNetCoredotnet/aspnetcore-tooling#6207.

To fix this issue I'm allowing the whitespace pass to skip over an empty
C# statement to remove whitespace. This is sound because an empty C#
statement produces no output - we allow removing whitespace before and
after all nodes that produce no output.
\n\nCommit migrated from e68d93f458
2018-12-31 14:43:16 -08:00
Ryan Nowak 14a8159919 Enable component class libraries in SDK
This change contains the enabling features to use Razor Components in a
class library. Currently we require a few workarounds, see the test
project file. This is good enough to get things unblocked.

One part that was needed was to register the correct component features
in the rzc. This is a good example, of why we don't like to add new
features that get registered conditionally, it's error-prone :)

The other part that was needed was to make some of the MVC-related
features for assembly attributes conditional on the TFM. We need to be
able to use the 3.0 (all inclusive) SDK, but without the MVC-related
features. This isn't the right heuristic, but it gets us unblocked.
\n\nCommit migrated from 8dbf02076b
2018-12-28 14:27:33 -08:00
Ryan Nowak 0c1c05efc6 Implement Components with new HTML parser
This change ports the existing Blazor component compiler features to
work on top of the Razor compiler. These new features are on once Razor
Language version is set to V3 or higher.

The tests and code for the old Blazor compiler were added to this repo
in previous changes. This change adds the necessary enabling features,
and gets the tests working.

Code generation for tests tests is identical with a few exceptions.
Design time directives now include line mappings (as they should). The
infrastructure seems to prefer windows style line-endings whereas the
Blazor code did the opposite. I plan to leave this alone unless it's a
problem for testing on *nix.

IR Generation will be cosmetically different due to different node names
and formatting. Structure should generally be the same.

----

In order to implement this support, I had to add the following core
features.

Configuring passes/engine-features based on the langauge version. This
required revisiting a *lot* of old tests and forcing them to use a
version appropriate Razor engine. A lot of our tests for legacy things
were using new versions of the language :(.

Configuring passes/engine-features to switch on/off depending on the
document kind.

Configuring directives depending on the file-kind. Directives are a
parser feature, so this decision needs to be made before the IR phase.
Directives that are specific to a file kind will override directives
that are not - this allows components to customize templates for
instance.

Adding functions/inherits/implements directive as mainline features that
are always on in V3. I'm not quite motivated to do this yet for
typeparam, but we might end up there. Remember that directives are
reserved words in Razor.
\n\nCommit migrated from a04addb86f
2018-12-23 23:37:54 -08:00
Nate McMaster 3641761d18
Convert AADIntegration projects to ProjectRef (#6082) 2018-12-21 11:43:09 -08:00
Ryan Nowak 45ad1c0ae8 Formalize Component node types
This change cleans up the intermediate node types that we have so far
for components and changes the naming, visibility, etc to match our
existing nodes.

The next change will integrate these types with the IR lowering process.
\n\nCommit migrated from 34cf523c0d
2018-12-21 11:07:12 -08:00
Nate McMaster c3beb1f9b1
build.cmd/sh changes (#5958)
Update the build scripts to support building subfolders or subgroups of projects

* Add build scripts for ci
* Remove obsolete scripts
* Add flags like --test and --pack to control running just test or packaging
* Add flags like --managed and --native to control building sub-types of projects
* Remove KoreBuild bootstrapper flags
* Update to extensions 3.0.0-preview.18619.1 (needed to get a fix for aspnet/Extensions#815 to make this change work on MSBuild.exe)
2018-12-20 16:52:15 -08:00
Ryan Nowak 51d19d1745 Code dump of Blazor compiler BindTagHelperDescriptorProvider
This change adds all of the code from the Blazor/Components compiler into
the Razor language assembly. Minimal refactoring or integration work has
been done, that is next :)

All of the code compiles and all unit tests pass, except the one I had
to skip until integration work is done.
\n\nCommit migrated from aa5c82ca5e
2018-12-20 16:04:24 -08:00
Ryan Nowak c37dada0dc Flow FileKind from project items -> code document
This is a bit of a rework of how we initially set this up, but with more
forethought to how this will work in the project system. I have not yet
surfaced this through VS.

My immediate next step is to light up the component integration tests
and something like this is on the critical path to get that work since
we need a way to specify in tests that a document should be treated as
a component.
\n\nCommit migrated from 6b81da3f02
2018-12-18 22:34:14 -08:00
Ajay Bhargav Baaskaran cef4e1aceb Added correct test TFMs 2018-12-18 13:06:20 -08:00
Ajay Bhargav Baaskaran 2a696f6a1c Merge branch 'release/2.2' 2018-12-18 12:50:01 -08:00
Ryan Nowak ceb1189b2e Stop generating page/view attribute in 3.0
\n\nCommit migrated from 4eb93869b9
2018-12-18 11:55:16 -08:00
Ajay Bhargav Baaskaran 647fbbac7b Merge branch 'release/2.1' into ajbaaska/merge-22 2018-12-17 18:40:08 -08:00
Ryan Nowak 2c2ff1f592 Code dump of component tests
This is a dump of the existing component codegen tests from
the Blazor effort.

I'm also adding the minimal Component types as a new shim to get things
to compile. This is similar to how our shims work already for MVC.

The next step will be add port functionality until the tests pass.
\n\nCommit migrated from 49f49dd9f0
2018-12-17 18:21:18 -08:00
Ajay Bhargav Baaskaran b079041488
Convert Razor to use Reference (#4954) 2018-12-17 12:10:40 -08:00
Ajay Bhargav Baaskaran 9fc340553f Minor text tag fix
\n\nCommit migrated from 5787d1e7d4
2018-12-14 16:34:03 -08:00
Nate McMaster 02780bac26
Merge branch 'release/2.2' 2018-12-14 16:03:16 -08:00
N. Taylor Mullen e8a584729f Fix racey directive token auto-complete.
- This happens because a completion session starts when we've rendered a marker directive token without a line pragma and then we return our parse results which provide a C# buffer with a line pragma. This pull request fixes that.
- Updated tests and verified in VS d16.0stg.

aspnet/AspNetCoredotnet/aspnetcore-tooling#4810
\n\nCommit migrated from ca593c80f7
2018-12-14 11:57:17 -08:00
Nate McMaster feb641ddda
Merge branch 'release/2.1' into release/2.2 2018-12-14 09:44:15 -08:00
Nate McMaster 13ae0057fb
Replace .Sources package references with local code (#4801)
Replaces package references the following packages with local code:

Microsoft.AspNetCore.Certificates.Generation.Sources
Microsoft.Extensions.CopyOnWriteDictionary.Sources 
Microsoft.Extensions.ClosedGenericMatcher.Sources
Microsoft.Extensions.ObjectMethodExecutor.Sources
Microsoft.Extensions.PropertyActivator.Sources
Microsoft.Extensions.PropertyHelper.Sources
Microsoft.Extensions.RazorViews.Sources
Microsoft.Extensions.SecurityHelper.Sources
Microsoft.Extensions.StackTrace.Sources
Microsoft.Extensions.WebEncoders.Sources
2018-12-14 08:36:36 -08:00
Ryan Nowak 341636b05d Convert Razor to netcoreapp3.0 2018-12-14 08:17:27 -08:00
Ajay Bhargav Baaskaran ad3835c3e2
Removed unnecessary projects (#4586) (#4612) 2018-12-12 12:59:04 -08:00
Ajay Bhargav Baaskaran 98f2973880
Removed unnecessary projects (#4586) 2018-12-12 10:41:06 -08:00
Ajay Bhargav Baaskaran 9105653629 Completely moved tag grouping logic to the parser (dotnet/aspnetcore-tooling#28)
* Completely moved tag grouping logic to the parser
- Removed MarkupElementRewriter
- Removed legacy Html parser
\n\nCommit migrated from c98b2fe1be
2018-12-11 18:24:39 -08:00
Chris Ross 7fdd930f50
Change IIS projects to target netcoreapp3.0 (#4371)
* Change IIS projects to target netcoreapp3.0 #3754
2018-12-11 13:46:46 -08:00
Nate McMaster 85e2147ff0
Merge branch 'release/2.2' 2018-12-07 11:11:44 -08:00
Nate McMaster 569a14ecb8
Merge branch 'release/2.1' into release/2.2 2018-12-06 17:09:03 -08:00
Ajay Bhargav Baaskaran 9f93a212f0 Partially moved tag grouping logic to the parser (dotnet/aspnetcore-tooling#20)
* Partially moved tag grouping logic to the parser
- Added StackGuard

* Feedback

* More feedback
\n\nCommit migrated from 0a37f5dafa
2018-12-06 16:08:43 -08:00
Ajay Bhargav Baaskaran cf6b1d7135 Correct logic for GetTagName
\n\nCommit migrated from 72a389149a
2018-12-06 16:08:42 -08:00
Ryan Nowak e3773b6383 Remove Razor tooling projects
Removes the Razor compiler/tooling projects from this repo
2018-12-06 07:47:00 -08:00
Justin Kotalik 0588b13f5b Fix 2.1 build issues and remove obsolete build code (#4443)
- Stop producing the 'Universe' lineup package
- Removes all PackageLineup code
- Use full msbuild on Windows
- Fix invalid reference to internal.aspnetcore.sdk in 2.1.x
- Fix shared folder references for PackageArchive task.
2018-12-05 17:01:02 -08:00
Ajay Bhargav Baaskaran 0c71f4f520 Added test for razor comment between code block and markup (dotnet/aspnetcore-tooling#14)
\n\nCommit migrated from 131003d0c3
2018-12-05 11:48:33 -08:00
Nate McMaster be3b66d1d1
Revert "Remove Razor tooling projects"
This reverts commit 3cfa6c0526.
2018-12-05 08:40:49 -08:00
Ryan Nowak 3cfa6c0526 Remove Razor tooling projects
Removes the Razor compiler/tooling projects from this repo
2018-12-04 19:58:37 -08:00
Ajay Bhargav Baaskaran ad0f2a5af4 Group HTML tags (dotnet/aspnetcore-tooling#6)
\n\nCommit migrated from a2d1ac4cea
2018-12-04 16:04:20 -08:00
Ryan Nowak ebd37599b6 PR feedback
\n\nCommit migrated from d38687acf2
2018-12-04 14:08:21 -08:00
N. Taylor Mullen 3c3d699804 Only add DotNetCoreRazorConfiguration capability in SDK for netcoreapp3.0.
- Prior to this we were unconditionally adding the `DotNetCoreRazorConfiguration` capability resulting in 1.0 projects looking like 2.1+ projects.
- Added a project capability test that verifies we're maintaining project capabilities for netcoreapp3.0 projects.
- Added a project capability test that verifies we don't muck with 1.1 project capabilities.

aspnet/Razordotnet/aspnetcore-tooling#2751
\n\nCommit migrated from 8d733ecc04
2018-12-04 13:01:26 -08:00
Ryan Nowak 6b4e03db1b Merge pull request dotnet/aspnetcore-tooling#2 from aspnet/rynowak/workaround-publishing
Attempt to work around dotnet/arcadedotnet/aspnetcore-tooling#1425\n\nCommit migrated from 451f10ab8f
2018-12-03 13:33:46 -08:00
Ryan Nowak c9f0acd5fd Increase timeout
\n\nCommit migrated from 5f1204a960
2018-12-03 12:59:56 -08:00
Ajay Bhargav Baaskaran 19f5798c2a Refactor attribute parsing (dotnet/aspnetcore-tooling#3)
\n\nCommit migrated from b7441d433f
2018-12-03 12:24:12 -08:00
Ryan Nowak 616ec14459 Remove Razor Runtime projects
\n\nCommit migrated from 39472ca0d6
2018-12-02 13:40:01 -08:00
N. Taylor Mullen c8bb6c34bb Use MVC 2.1 at design time for Razor 3.0 projects. (dotnet/aspnetcore-tooling#4324)
- When we detect a design time build we force tooling to use 2.1
- In runtime builds (i.e. rzc) it still uses the 3.0 configuration for 3.0 apps.

(cherry picked from commit dotnet/aspnetcore-tooling@0326abe530)
\n\nCommit migrated from a6dc88e455
2018-12-02 11:01:08 -08:00
Ajay Bhargav Baaskaran 5bb16b1a14 Refactored Html parser - part 1
(cherry picked from commit dotnet/aspnetcore-tooling@31f53d44b5)
\n\nCommit migrated from b154e53f06
2018-12-02 10:59:41 -08:00
Ryan Nowak 6fa46903e2 Fix DevDiv 736427
When a user builds a 2.1 or 2.2 project with a 3.0 they can get an error
due to invalid command line options from rzc. What happens is that the
3.0 tasks (which are a singleton) are talking to the 2.X build tool
(which is NOT a singleton).

Recently some changes were make to the 3.0 tasks which caused this bug
because it did not properly accomodate downlevel versions of rzc. We
have an integration test for this scenario for but the regression was
not detected, so obviously something is wrong with the test setup. I'll
investigate that separately.

(cherry picked from commit dotnet/aspnetcore-tooling@1aace2b6c7)
\n\nCommit migrated from d2654d0847
2018-12-02 10:59:09 -08:00
Ryan Nowak 7df54be754 Merged PR 304: Enable local builds with dotnet/Arcade
[WIP] Enable local builds with dotnet/Arcade
\n\nCommit migrated from 409618521f
2018-12-02 00:25:55 +00:00
Ryan Nowak 1c99d2ed4a Reorganize source code in preparation to move into aspnet/AspNetCore
Prior to reorganization, this source code was found in https://github.com/aspnet/Razor/tree/dotnet/aspnetcore-tooling@582f3f867eeb8fca00e6b328faf7665c9a98476c
\n\nCommit migrated from 33b287d4a4
2018-11-29 15:13:03 -08:00
Ryan Nowak a5ef5133a3 Reorganize source code in preparation to move into aspnet/AspNetCore
Prior to reorganization, this source code was found in https://github.com/aspnet/Razor/tree/dotnet/aspnetcore-tooling@582f3f867eeb8fca00e6b328faf7665c9a98476c
\n\nCommit migrated from 33b287d4a4
2018-11-29 15:13:03 -08:00
N. Taylor Mullen 0326abe530 Use MVC 2.1 at design time for Razor 3.0 projects. (#4324)
- When we detect a design time build we force tooling to use 2.1
- In runtime builds (i.e. rzc) it still uses the 3.0 configuration for 3.0 apps.
2018-11-29 12:41:29 -08:00
Nate McMaster 26dfce1f3c
Disable building src/Components and fix its code signing configuration (#4299) 2018-11-28 15:29:25 -08:00
Ryan Brandenburg 8a37389a9f Fix RepositoryUrl for some repos 2018-11-28 14:54:47 -08:00
Ajay Bhargav Baaskaran 31f53d44b5 Refactored Html parser - part 1 2018-11-28 13:28:14 -08:00
Ajay Bhargav Baaskaran 46242b307c
Added build scripts for Razor (#4298) 2018-11-28 13:27:41 -08:00
Ryan Nowak 1aace2b6c7 Fix DevDiv 736427
When a user builds a 2.1 or 2.2 project with a 3.0 they can get an error
due to invalid command line options from rzc. What happens is that the
3.0 tasks (which are a singleton) are talking to the 2.X build tool
(which is NOT a singleton).

Recently some changes were make to the 3.0 tasks which caused this bug
because it did not properly accomodate downlevel versions of rzc. We
have an integration test for this scenario for but the regression was
not detected, so obviously something is wrong with the test setup. I'll
investigate that separately.
2018-11-28 12:42:54 -08:00
Ryan Brandenburg ba1bb521bc Add korebuild.json back to SignalR and Razor 2018-11-28 09:33:49 -08:00
Ryan Brandenburg 64e97a3604 Reorganize source code in preparation to move into aspnet/AspNetCore
Prior to reorganization, this source code was found in 582f3f867e
2018-11-27 15:43:05 -08:00
Ryan Brandenburg 6f80eeda29 Reorganize source code in preparation to move into aspnet/AspNetCore
Prior to reorganization, this source code was found in 8ba0a89425
2018-11-27 12:16:27 -08:00
Ryan Brandenburg 1b461749cb Reorganize source code in preparation to move into aspnet/AspNetCore
Prior to reorganization, this source code was found in fd4572874e
2018-11-27 10:52:49 -08:00