Steve Sanderson
3e5381c17e
Rename .DevHost project to .Cli, and make it work as a DotNetCliTool
2018-02-27 12:17:35 +00:00
Steve Sanderson
6995b974e9
Support @bind for textboxes and checkboxes
2018-02-26 14:39:56 +00:00
Steve Sanderson
02a0be5c2b
Add JsonUtil unit tests plus E2E tests for new StandaloneApp pages
2018-02-26 13:01:11 +00:00
Steve Sanderson
c0bf73234c
Tweak (to force rebuild, since Travis just tried to build a branch that was already deleted)
2018-02-23 22:42:10 +00:00
Steve Sanderson
8590f6e7a5
Remainder of initial HttpClient features plus E2E tests
2018-02-23 22:31:26 +00:00
Steve Sanderson
88cc2caf45
Infrastructure for E2E tests where the app makes requests to an API server
2018-02-23 13:28:58 +00:00
Steve Sanderson
ea6b6bcd19
Add an example API server project that can be used in E2E tests
2018-02-23 13:07:49 +00:00
Steve Sanderson
0bb32ad628
Move BrowserRouter -> Router in Microsoft.AspNetCore.Blazor now it has no browser-specific aspects
2018-02-23 10:49:03 +00:00
Steve Sanderson
82bcf9172a
Convert the static UriHelper into a service, IUriHelper, and inject where needed
2018-02-23 10:35:28 +00:00
Steve Sanderson
c408045e31
In RazorCompiler, support @inject directive
2018-02-23 09:32:26 +00:00
Steve Sanderson
3f9d358004
Make ComponentFactory throw if you try to use [Inject] with a property that has no setter (otherwise it could be confusing)
2018-02-23 09:32:26 +00:00
Steve Sanderson
e524994734
Make ComponentFactory do all the reflection up-front and cache the resulting delegates
2018-02-23 09:32:26 +00:00
Steve Sanderson
ceacd489aa
Simplistic implementation of property injection
2018-02-23 09:32:26 +00:00
Steve Sanderson
ce10e6fa19
In preparation for DI, give every Renderer an IServiceProvider
2018-02-23 09:32:26 +00:00
Steve Sanderson
d388cb6510
Add E2E test covering nav menu and NavLink usage in StandaloneApp
2018-02-22 15:03:49 +00:00
Steve Sanderson
58ae5dea9a
Additional methods on ParameterCollection to simplify usage
2018-02-22 15:03:49 +00:00
Steve Sanderson
25b76bc6dc
Skip rerendering child components if their params are definitely unchanged
2018-02-22 13:23:52 +00:00
Steve Sanderson
08d7b77d38
Avoid component syntax confusion by making it a compile-time error. Fixes #145
2018-02-22 11:07:03 +00:00
Steve Sanderson
1a31634b70
Capture component child content as a RenderFragment parameter.
2018-02-22 11:07:03 +00:00
Steve Sanderson
bd455453d6
Report line/column when reporting mismatching tags
2018-02-22 11:07:03 +00:00
Steve Sanderson
0665d30e19
In RazorCompiler, reject malformed documents with mismatching tags
2018-02-22 11:07:03 +00:00
Steve Sanderson
95023c0300
In RazorCompiler, support components with children
2018-02-22 11:07:03 +00:00
Steve Sanderson
fc9cb1af65
Add E2E tests for BrowserRouter, plus implement querystring/hash support
2018-02-21 10:22:03 +00:00
Steve Sanderson
8bc7c92683
Support hosting at non-root URL. Prove it by updating BasicTestApp to serve from non-root location.
2018-02-21 10:22:03 +00:00
Steve Sanderson
7073429cd5
Clean up and include routing unit tests
2018-02-21 10:22:03 +00:00
Steve Sanderson
87fc15cc23
Add test to demonstrate current component attribute parsing inconsistencies
2018-02-21 10:22:03 +00:00
Steve Sanderson
78a19c07e9
In RazorCompiler, allow HTML comments
2018-02-21 10:22:03 +00:00
Steve Sanderson
58af3e1638
Allow blazor-boot script to be served from apps not hosted at domain root
2018-02-21 10:22:03 +00:00
Steve Sanderson
608da4c78b
Specifying entrypoint: Add tests and other stylistic tweaks
2018-02-19 14:22:03 +00:00
Eugene Bekker
1653e56b98
Adding ability to qualify the entry point of the main assembly
2018-02-19 14:11:25 +00:00
Steve Sanderson
1e0836167d
Make temporary "layout" and "implements" syntax work with _ViewImports hierarchies
2018-02-19 12:48:08 +00:00
Steve Sanderson
f649de2976
Support _ViewImports.cshtml files hierarchically
2018-02-18 23:57:20 +00:00
Steve Sanderson
be1400663b
Unit test to show the Razor compiler passes through any C# compilation errors
2018-02-18 23:54:12 +00:00
Steve Sanderson
782ca0137d
Support "@inherits ..." directive
2018-02-18 22:03:15 +00:00
Steve Sanderson
6e7c4ec6c0
Tests for LayoutDisplay component
2018-02-16 17:23:12 +00:00
Steve Sanderson
df825de86d
Reorganise some test helpers in shared locations
2018-02-16 17:23:04 +00:00
Steve Sanderson
f6d6714251
Serve static content from wwwroot
2018-02-16 15:56:22 +00:00
Steve Sanderson
f54df27c21
Define ILayoutComponent so there's compile-time validation that layouts are defined correctly
2018-02-16 15:04:51 +00:00
Steve Sanderson
7139cb70c5
Support temporary @(Implements<MyInterfaceType>()) syntax
2018-02-16 12:39:38 +00:00
Steve Sanderson
9e333e31c5
Support temporary @(Layout<MyLayoutType>()) syntax
2018-02-16 12:10:44 +00:00
Steve Sanderson
f91d1d4803
Better handling of render-after-disposed scenarios
2018-02-16 12:10:44 +00:00
Steve Sanderson
0595251ac2
E2E test showing rendering of RenderFragment
2018-02-16 10:10:14 +00:00
Steve Sanderson
ad2c63ca37
Make OpenRegion/CloseRegion not public because they are only to support AddContent(seq, fragment)
2018-02-16 10:10:12 +00:00
Steve Sanderson
41aae0b7e6
Add ability to append RenderFragment into a RenderTreeBuilder
2018-02-16 10:10:11 +00:00
Steve Sanderson
29a6175ac1
Define RenderFragment concept
2018-02-16 10:10:10 +00:00
Steve Sanderson
1ac5ee25c1
Rename RenderTreeBuilder's AddText to AddContent, since it will be used for other types too
2018-02-16 10:10:08 +00:00
Steve Sanderson
acc5b9461b
Add ability to add component frame using runtime type object instead of generic param
2018-02-16 10:10:07 +00:00
Steve Sanderson
2ebfddc237
Switch client apps to netstandard2.0 to fix type load errors
...
Do a "git clean -xdf" on your local copy if you get runtime errors after
updating to this.
2018-02-15 10:20:31 +00:00
Steve Sanderson
2da17602ed
Support "Region" frames in JS-side code
...
They only appear in a prepended subtree, because the .NET-side diffing
code resolves them out if they are top-level to any given edit
2018-02-14 23:41:25 +00:00
Steve Sanderson
848f24536a
Support "Region" frames in diffing
2018-02-14 23:41:24 +00:00
Steve Sanderson
a9822216f1
Add the concept of a "Region" render tree frame
2018-02-14 23:41:24 +00:00
Ryan Nowak
043e623d5b
Split Razor extensibility into its own assembly
...
This functionality will need to cross-compile to desktop framework
(net461) so that we can use it in VS. VS doesn't yet have netstandard2.0
support.
2018-02-14 14:08:14 -08:00
Steve Sanderson
86500ce761
Fix MonoSanityTest instability
2018-02-14 18:23:08 +00:00
Steve Sanderson
b7bbacf4ed
Skip MonoSanityTest due to instability since Chrome update
2018-02-14 16:27:24 +00:00
Steve Sanderson
5f41779b3e
Fix use of Chrome Headless on Travis macOS builds
2018-02-14 16:27:24 +00:00
Steve Sanderson
94261ded25
Fix RazorCompilerTest on Mac/Linux
2018-02-14 13:08:39 +00:00
Steve Sanderson
83b90d1980
Update AppVeyor/Travis configs to run on .NET Core, enable selenium
...
tests, etc.
2018-02-14 13:08:39 +00:00
Steve Sanderson
0eb0555303
Eliminate IComponent.BuildRenderTree to guarantee that components are only rendered by themselves
2018-02-13 19:47:37 +00:00
Steve Sanderson
e061b98f9d
In RazorCompilerTest, don't use BuildRenderTree directly (because it will soon be removed)
2018-02-13 17:18:06 +00:00
Steve Sanderson
70a3ee3d98
Remove externally-callable Renderer.RenderInNewBatch() now that rendering is triggered by components themselves
2018-02-13 17:06:00 +00:00
Steve Sanderson
804ab2d89f
Add IHandleEvent concept so components can define their own lifecycle around events
2018-02-13 16:42:21 +00:00
Steve Sanderson
a889cd3152
Beginning lifecycle methods on BlazorComponent
2018-02-13 15:55:37 +00:00
Steve Sanderson
861154764c
Introduce IComponent.SetParameters, moving parameter-setting and rerendering logic into component base class
2018-02-13 15:00:53 +00:00
Steve Sanderson
37217db73a
Implement ParameterCollection
2018-02-13 13:14:55 +00:00
Steve Sanderson
695ddc0fd6
Add Init/RenderHandle concepts so components can rerender themselves arbitrarily (e.g., after internal state change)
2018-02-13 11:49:33 +00:00
Steve Sanderson
7bb4bbbe5c
In IndexHtmlFileProvider, preserve original source formatting
2018-02-12 23:05:47 +00:00
Eugene Bekker
b38718d77f
Require <script type="blazor-boot"> to define script injection location
2018-02-12 21:49:27 +00:00
Steve Sanderson
e37e22aa27
Further renderer refactoring
2018-02-10 10:55:44 +00:00
Steve Sanderson
5a9c41af0e
Make AngleSharp not strong-named. Change assembly name to Microsoft.AspNetCore.Blazor.AngleSharp to ensure no conflicts with other usages.
2018-02-09 17:37:21 +00:00
Steve Sanderson
15ddcd03b0
Major refactor of responsibilities in rendering code. Not quite done
...
with this yet either.
2018-02-09 14:50:07 +00:00
Steve Sanderson
91314ee8c8
Rename RenderTreeDiffComputer -> RenderTreeDiffBuilder
2018-02-08 15:50:14 +00:00
Steve Sanderson
b8ed7bc2c5
Track event handlers via explicit IDs rather than by index into frames
...
array
2018-02-08 15:31:45 +00:00
Steve Sanderson
83fa72bc7e
Have RenderTreeDiff build its own array of referenced frames rather than pointing to the latest render tree
...
This is in preparation for supporting multiple diffs for the same
component in a single batch (which means we can't rely on there being at
most only new render tree per component)
2018-02-07 10:27:32 +00:00
Steve Sanderson
33932f41fc
Replace "DescendantsEndIndex" concept with "SubtreeLength"
...
In other words, use relative addressing so that frame data is
independent of its position in the array
2018-02-07 10:27:32 +00:00
Steve Sanderson
93f17219ea
Rename OpenComponentElement -> OpenComponent for consistency
2018-02-05 00:19:44 +00:00
Steve Sanderson
1fda744770
Make RenderTreeFrame properly readonly to allow more pass-by-ref cases
2018-02-05 00:16:08 +00:00
Steve Sanderson
f1332919bc
Rename RenderTreeNode -> RenderTreeFrame (and correspondingly, "node" ->
...
"frame" everywhere)
2018-02-04 22:21:29 +00:00
Steve Sanderson
76dafa819f
Mechanism for components running logic when parents change their properties
2018-01-31 16:19:01 +00:00
Steve Sanderson
1c9c74c801
In RazorCompiler, fix bug about attribute nodes having wrong sequence
...
numbers. Make tests explicit about sequence numbers.
2018-01-31 10:23:56 +00:00
Steve Sanderson
50a5baa872
Dispose components on removal
2018-01-30 10:00:30 +00:00
Steve Sanderson
55592f583b
Update RendererTests to be more explicit about batch expectations
2018-01-29 20:28:38 +00:00
Steve Sanderson
080e6395cb
Move to batched rendering
2018-01-29 20:16:42 +00:00
Steve Sanderson
27d0ce4da9
Begin differentiating between rendering as a new batch on in an existing batch (even though batches don't exist yet)
2018-01-29 16:47:52 +00:00
Steve Sanderson
7799c36d50
Add E2E test to show adding and removing child components dynamically
2018-01-29 12:56:42 +00:00
Steve Sanderson
772e3a1a44
Clean up E2E tests now elements are retained via diffing
2018-01-29 12:56:41 +00:00
Steve Sanderson
4f496f649a
Add E2E test showing we can pass properties to child components and auto re-render them on change
2018-01-29 12:56:40 +00:00
Steve Sanderson
882096755b
Rerender child components when their parameters change
2018-01-26 14:25:26 -08:00
Steve Sanderson
94ad26a479
Update properties on retained child components
2018-01-26 11:58:43 -08:00
Steve Sanderson
9f7dab3096
Better error handling when setting properties on child components
2018-01-26 10:10:06 -08:00
Steve Sanderson
3940ca8b60
For components, allow attribute values to be arbitrary objects
2018-01-26 09:54:35 -08:00
Steve Sanderson
1b4fa4781a
Give attribute nodes a single object-valued value so they can be used for component properties too.
2018-01-26 09:40:48 -08:00
Steve Sanderson
9dcb1c4fc4
Begin on setting properties on child components
2018-01-26 08:47:53 -08:00
Steve Sanderson
0aa164073d
Rename Microsoft.Blazor.* -> Microsoft.AspNetCore.Blazor.* everywhere
2018-01-24 15:48:38 -08:00
Steve Sanderson
9e90ff3689
Rename AddComponentElement->OpenComponentElement for clarity (you have to close it too)
2018-01-24 15:26:27 -08:00
Steve Sanderson
2469558410
Preserve child component instances across renders. Move instantiation into the diffing phase.
2018-01-24 14:29:46 -08:00
Steve Sanderson
23c2816bcd
Change ParentChildComponent test to use Razor. Add E2E tests showing events on child components work.
2018-01-24 11:04:30 -08:00
Steve Sanderson
2107a1927f
In RazorCompiler, support temporary <c:MyComponent /> syntax
2018-01-24 10:43:23 -08:00
Steve Sanderson
6e4d0dbca4
Move common resizable-array logic into shared ArrayBuilder. Replace ArraySegment with ArrayRange since Offset is never used.
2018-01-23 23:30:48 -08:00
Steve Sanderson
b049c7f574
Fix diffing for consecutive text nodes
2018-01-23 09:43:14 -08:00
Steve Sanderson
df321b9b8d
Make RenderTreeEdit specify which sibling node it acts on, so we can eliminate the Continue concept and no longer track indices on JS side
2018-01-22 20:17:32 -08:00