* Allow ".dll" extensions in BlazorWebAssemblyLazyLoad MSBuild task.
* Only allow assemblies that are specified with an extension.
Co-authored-by: Adrian Wright <adrian@compiledcoding.co.uk>
* Add tests for navigate on form submit
* Add fix for re-render after event dispatch
* Remove deferred event handling in .NET
* Only dispatch events with registered handlers once
* Use BlazorWebAssemblySDK
* Update projects to use the BlazorSDK
* Remove tasks and targets from RazorSDK
* Remove workarounds from BlazorSDK
* Fixup
* Fixup
* Remove Internal.AspNetCore.Analyzers
This resolves build flakiness caused by referencing the analyzer:
```
2020-08-07T21:22:39.1149296Z ##[error].dotnet\sdk\5.0.100-rc.1.20379.10\Microsoft.Common.CurrentVersion.targets(4188,5): error MSB3026: (NETCORE_ENGINEERING_TELEMETRY=Build)
Could not copy "F:\workspace\_work\1\s\artifacts\obj\Internal.AspNetCore.Analyzers\Release\netstandard1.3\Internal.AspNetCore.Analyzers.dll"
to "F:\workspace\_work\1\s\artifacts\bin\Internal.AspNetCore.Analyzers\Release\netstandard1.3\Internal.AspNetCore.Analyzers.dll". Beginning retry 1 in 1000ms.
The process cannot access the file 'F:\workspace\_work\1\s\artifacts\bin\Internal.AspNetCore.Analyzers\Release\netstandard1.3\Internal.AspNetCore.Analyzers.dll' because it is being used by another process.
```
The analyzer checks if pubternal types are being exposed in public APIs. We no longer author pubternal types, so this is no longer a concern.
* Remove DisablePubternalApiCheck
* Quarantine LinkedApplicationWorks
* Quarantine flaky tests
* Quarantine CanBindTextbox_Decimal_InvalidInput
* React to NetworkException type
* One more test
* Remove LinkerWorkaround.xml
The workaround file is no longer needed, now that the underlying bugs are fixed in the dotnet/runtime libraries.
Fix#23262
* Also remove LinkerWorkaround from Components/WebAssembly
* Add guard check for cleared closest DOM element
* Update src/Components/Web.JS/src/Rendering/BrowserRenderer.ts
Co-authored-by: Steve Sanderson <SteveSandersonMS@users.noreply.github.com>
Co-authored-by: Steve Sanderson <SteveSandersonMS@users.noreply.github.com>
* Quarantine falky test ServerEventTest.EventDuringBatchRendering_CanTriggerDOMEvents
Blazor's E2E testing uses a much shorter timeout after a test failure. This test run had several test failures, but most of these appear to be the result of
an incredibly short timeot. This PR quarantines the one test that appears to be a genuine failure and also increases the timeout duration for after test failure.
* Quarantine ServerExecutionTests.ServerGlobalizationTest.CanSetCultureAndParseCultureSensitiveNumbersAndDates
* Put back InternalCalls
* Removing .NET profiling calls
* Remove JS side profiling
Co-authored-by: Steve Sanderson <SteveSandersonMS@users.noreply.github.com>
- #20818, fix e.g. references to Microsoft.Web.Xdt.Extensions in our packages
- make `@(Reference)` items much more broadly applicable
- emit an error when `@(ProjectReference)` is used instead of `@(Reference)`
- then get rid of the errors (!!)
- rename a couple of projects to match their assembly names
- then regenerate the `@(ProjectReferenceProvider)` items
- switch intersection approach from Exclude / Exclude to Copy / Update / Copy
Projects of particular interest:
- src/DefaultBuilder/src/Microsoft.AspNetCore.csproj
- honouring metadata left e.g. Microsoft.AspNetCore.Components.WebAssembly.DevServer package unchanged
- removed redundant metadata after that confirmation
- src/Razor/tools/Microsoft.AspNetCore.Razor.Internal.Transport/
- content of this package unchanged but metadata avoids extra work
- add a comment about the extra work
- src/SiteExtensions/LoggingAggregate/src/Microsoft.AspNetCore.AzureAppServices.SiteExtension/
- success! removes Microsoft.Web.Xdt.Extensions dependency from the package
- src/SiteExtensions/Runtime/Microsoft.AspNetCore.Runtime.SiteExtension.pkgproj
- add a `Condition` to avoid an ordering issue I hit here
- src/Tools/Extensions.ApiDescription.Server/src/
- avoid errors the new build ordering and timing caused
Separately, up the timeout in the `<DownloadFile />` task
- hit repeated timeouts downloading dotnet-runtime-5.0.0-rc.1.20370.4-win-x64.zip
nits:
- remove dupe `@(Reference)` item in Microsoft.AspNetCore.Components.WebAssembly.DevServer.csproj
- remove useless `%(ProjectReference.IsImplicitlyDefined)` metadata as well as its misspellings
- remove extra spaces from ProjectReferences.props
- clean up a few comments in ResolveReferences.targets
* !fixup! Correct other references to renamed projects
Using the full gc sometimes leads to an infinite recursion resulting
in a browser freeze. This was noted as part of running Blazor's benchmarks.
This is being addressed in rc1, in the meanwhile this reverts the behavior to 3.2 defaults.
Browser freezes when using a Blazor WASM application.
Yes. Full GC on is new to WASM on .NET Core
Low. Off by default is the behavior we had in 3.2.
* Wires up CSS isolation on the build.
* Transforms the css files during build.
* Bundles all scopes css into a single file and exposes it on _framework/scoped.styles.cs
* Packs pre-processed files as static web assets.
* Wires up CSS isolation on the build.
* Transforms the css files during build.
* Bundles all scopes css into a single file and exposes it on _framework/scoped.styles.cs
* Packs pre-processed files as static web assets.
* Started on head manager
* Working prototype.
* Started on improved meta tag support.
* Improved meta support and better thread safety.
* Improved synchronization.
* Added support for meta "property" attribute.
* Updated exception message.
* Added link element support.
* Started on functional tests.
* Added more functional tests.
* Added E2E tests.
* Simplified implementation.
* Prerendering support.
* Small documentation updates.
* Made TagElement and TitleElement readonly.
* Removed M.A.Components.Server dependency.
* Minor fixes and updates.
* Update PrerenderedHeadComponent.razor
* Removed AddWebExtensions.
* Applied CR feedback
* Add element/component name for duplicate key
* Add in keyword for frame param
Co-authored-by: Javier Calvarro Nelson <jacalvar@microsoft.com>
Co-authored-by: Javier Calvarro Nelson <jacalvar@microsoft.com>
* Render 'OnNavigateError' fragment on unhandled exception in OnNavigateAsync
* Address first round of feedback from peer review
* Refactor OnNavigateAsync handling and fix tests
* Make OnNavigateAsync cancellation cooperative with user tasks
* Fix aggressive re-rendering and cancellation handling
* Fix up tests based on peer review
* Remove all ref/ projects
* Remove GenAPI infrastructure
* Remove notion of a reference assembly project
- remove `$(IsReferenceAssemblyProject)`, `$(ReferenceReferenceAssemblies)` and `$(ReferenceImplementationAssemblies)`
- remove unnecessary `$(NoWarn)` settings
nits:
- remove a few misleading comments
- wrap some long lines
* Move .0 package version workaround into Versions.props
- touch up SharedFramework.External.props
* Expose `%(LatestPackageReference.RTMVersion)` metadata
- automate use of properties in the `@(LatestPackageReference)` item group to make this maintainable
- add a couple of special cases at the bottom of eng/Dependencies.props
- add one more `$(...PackageVersion)` property to avoid yet-another special case
* Enable Roslyn reference assemblies
- exclude ref/ assembly from packages other than targeting pack
- update Microsoft.AspNetCore.App.Ref.csproj
- `%(IsReferenceAssembly)` and `%(ReferenceGrouping)` metadata no longer relevant
- only ref/ assemblies are in `@(ReferencePathWithRefAssemblies)` item group
nits:
- remove now-unnecessary workaround
- issues with TFM transition are behind us
- clean up Microsoft.AspNetCore.App.Runtime.csproj slightly
- use `GeneratePathProperty="true"`
- reorder item / property settings for meta-expansion
- correct spelling errors and phrasing in comments
* Update documentation to reflect recent changes
- remove CrossRepoBreakingChanges.md; was tied to old TeamCity infrastructure
- also much less relevant given repo merges
- adjust details and examples in ReferenceResolution.md
- reflect repo merges, Dependencies.props changes, and current Maestro++ channels
- add a few more details e.g. specific files where Version.Details.xml versions are used
* !fixup! Remove another irrelevant doc file
* !fixup! Address PR review suggestions
- convert a couple of warnings to errors
- use consistent casing for Microsoft.NETCore.App.Runtime.* packages
- reduce `%(LatestPackageReference.Version)` metadata special cases
- add and improve comments e.g.
- improve comments about `$(*V0PackageVersion)` properties
- improve placement of comments about item removal in ResolveReferences.targets
- confirmed `$(*V0PackageVersion)` property list is complete
nits:
- fix solution example in ReferenceResolution.md
- remove item group definition for `@(LatestPackageReference)`
- remove `%(LatestPackageReference.VersionName)` metadata after use; large item group
- similarly, remove `%(LatestPackageReference.RTMVersion)` when not needed; just complicates `Condition`s
When I squash, I must remember this fixes
- #14801
- dotnet/aspnetcore-internal#2693
* Actually use `%(LatestPackageReference.RTMVersion)` metadata
- gather RTM package references in a new project
- a (very) separate project to work around package conflict resolution
- empty `Test` target works around Arcade's testing approach
- new target in ResolveReferences.targets updates relevant assembly paths to use the RTM packages
- done as soon as possible after `ResolvePackageAssets` determines the paths
- done for all compilation inputs, not just ref/ assemblies
AuthorizeRouteView combines AuthorizeView and RouteView on one abstraction for convenience, but it was missing a Resource parameter to capture and flow the resource to pass on to the AuthorizationService. This PR adds a new Resource parameter and makes sure that the value is passed to the authorization service so that it is available for the authorization handlers in a policy.
* Modified EditForm to return _fixedEditContext via the EditContext parameter. Also added some tests to cover the new functionality
* Swapped to boolean to track provided EditContext
* Patched ref assembly
* Simplified setting _hasSetEditContextExplicitly
* Renamed _fixedEditContext to _editContext
* Updated null check in OnParametersSet
* Simplified check for EditContext updates based on Model changes
Add a `DisplayName` parameter to `InputBase`, which is used in validation messages instead of `FieldIdentifier.FieldName`.
- This works for `InputDate`, `InputNumber` and `InputSelect`.
- Extracted some shared code, just like what @StephanZahariev did in his PR.
Addresses #11414
Adds an empty InvokeAsync() overload for both EventCallback and EventCallbackOfT.
Updated tests to simply use this new overload instead of InvokeAsync(null).
Addresses #23603.
* [Blazor] Support IAsyncDisposable in components
* Handles async disposal of components within the Blazor pipeline.
* Renders remain synchronous and don't wait for disposal to complete.
* Synchronous disposal executions remain inlined.
* Async disposal executions can trigger renders in different batches.
* Async disposals are handled individually and not grouped based on the batch they were generated on.
* Spruce up async handling in OnNavigateAsync
* Apply suggestions from code review
Co-authored-by: Günther Foidl <gue@korporal.at>
* Ensure previous task awaited before starting next one
* Apply suggestions from code review
Co-authored-by: Pranav K <prkrishn@hotmail.com>
* Validate no exceptions throw on multiple invocations
* Address feedback from peer review
Co-authored-by: Günther Foidl <gue@korporal.at>
Co-authored-by: Pranav K <prkrishn@hotmail.com>
* Migrated protected browser storage.
* Added E2E tests.
* Added safeguard against using ProtectedBrowserStorage in wasm.
* Added TryGetValue.
* Added Microsoft.AspNetCore.Components.Web.Extensions
* Minor cleanup
* Moved ProtectedBrowserStorage out of Web.JS.
* Delete Microsoft.AspNetCore.Components.Web.Extensions.netcoreapp.cs
* Updated ProjectReferences.props
* Improvements and cleanup.
* Update Microsoft.AspNetCore.Components.Web.Extensions.csproj
* Added Web.Extensions to the VS solution.
* Add framework support for lazy-loading assemblies on route change
* Configure lazy-loaded assemblies in WebAssemblyLazyLoadDefinition
* Move tests to WebAssembly-only scenarios
* Refactor RouteTableFactory and add WebAssemblyDynamicResourceLoader
* Address feedback from peer review
* Rename 'dynamicAssembly' to 'lazyAssembly' and address peer review
* Add sample with loading state
* Update Router API and assembly loading tests
* Support and test cancellation and pre-rendering
* Apply suggestions from code review
Co-authored-by: Steve Sanderson <SteveSandersonMS@users.noreply.github.com>
* Spurce up API and add tests for pre-rendering scenario
* Use CT instead of CTS in NavigationContext
* Address feedback from peer review
* Remove extra test file and update Router
Co-authored-by: Steve Sanderson <SteveSandersonMS@users.noreply.github.com>
* Started on InputRadio forms component.
* Added E2E test for InputRadio.
* Added docstring for InputRadio.
* Changed value to be serialized using BindConverter.
* Added InputChoice for choice-based inputs.
InputChoice contains checks for valid choice types that used to exist in InputSelect. Both InputSelect and InputRadio now derive from InputChoice and thus also contain those checks.
* Added InputRadioGroup.
* Small fix.
* Removed InputChoice, cleaned up.
* Added internal access modifier to InputExtensions.
* Small improvements.
* Updated an outdated exception message.
* Updated test to reflect updated exception message.
* Improved API to enforce InputRadioGroup.
* Added support for InputSelect int and Guid bindings.
* Changed validation CSS classes to influence InputRadio components.
* Ensure BlazorWebAssembly.js is present
* Unquaratine blazor template tests
* The failure issue https://github.com/dotnet/aspnetcore/issues/20479 was resolved, but the assembly level quarantine was
missed being removed.
* Use shorter project file names to avoid long path issues.
* Update blazorwasm template tests to react to net5 updates
* Update src/ProjectTemplates/Shared/ProjectFactoryFixture.cs
Specifying the RID and PublishDir when publishing the driver app causes all sorts of
build issues. This change moves specifying the RID in to the driver app and ensures PublishDir
does not flow to the referenced RazorSDK project.
* Fix docker build
* Update readme typos