Skip to content

Commit b83ef78

Browse files
committed
Fix #8520 - Component parameters not found
This resolves the issue blocking use of component parameters from our ref assemblies. Making properties public with private get is our recommended guidance for wanting documentation to work in the IDE. We also now need to manually generate the ref-assembly types for these so they will show up for tooling with setters. I've logged an issue to track whether we want to keep this long term, it seems like a suitable workaround for now.
1 parent 6641a02 commit b83ef78

13 files changed

+231
-132
lines changed

eng/GenAPI.exclusions.txt

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,20 @@
22
T:Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame
33
# Manually implemented - https://github.com/dotnet/arcade/issues/2066
44
T:Microsoft.AspNetCore.Mvc.ApplicationModels.PageParameterModel
5-
T:Microsoft.AspNetCore.Mvc.ApplicationModels.PagePropertyModel
5+
T:Microsoft.AspNetCore.Mvc.ApplicationModels.PagePropertyModel
6+
# Manually implemented - https://github.com/aspnet/AspNetCore/issues/8825
7+
T:Microsoft.AspNetCore.Components.CascadingValue`1
8+
T:Microsoft.AspNetCore.Components.Forms.DataAnnotationsValidator
9+
T:Microsoft.AspNetCore.Components.Forms.EditForm
10+
T:Microsoft.AspNetCore.Components.Forms.InputBase`1
11+
T:Microsoft.AspNetCore.Components.Forms.InputCheckbox
12+
T:Microsoft.AspNetCore.Components.Forms.InputDate`1
13+
T:Microsoft.AspNetCore.Components.Forms.InputNumber`1
14+
T:Microsoft.AspNetCore.Components.Forms.InputSelect`1
15+
T:Microsoft.AspNetCore.Components.Forms.InputText
16+
T:Microsoft.AspNetCore.Components.Forms.InputTextArea
17+
T:Microsoft.AspNetCore.Components.Forms.ValidationMessage`1
18+
T:Microsoft.AspNetCore.Components.Forms.ValidationSummary
19+
T:Microsoft.AspNetCore.Components.Layouts.LayoutDisplay
20+
T:Microsoft.AspNetCore.Components.Routing.NavLink
21+
T:Microsoft.AspNetCore.Components.Routing.Router

src/Components/Components/ref/Microsoft.AspNetCore.Components.netstandard2.0.Manual.cs

Lines changed: 180 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,184 @@ public readonly partial struct RenderTreeFrame
4444
public Microsoft.AspNetCore.Components.IComponent Component { get { throw null; } }
4545
public override string ToString() { throw null; }
4646
}
47+
}
48+
49+
// Built-in components: https://github.com/aspnet/AspNetCore/issues/8825
50+
namespace Microsoft.AspNetCore.Components
51+
{
52+
public partial class CascadingValue<T> : Microsoft.AspNetCore.Components.IComponent
53+
{
54+
public CascadingValue() { }
55+
[Microsoft.AspNetCore.Components.ParameterAttribute]
56+
public Microsoft.AspNetCore.Components.RenderFragment ChildContent { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
57+
[Microsoft.AspNetCore.Components.ParameterAttribute]
58+
public bool IsFixed { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
59+
[Microsoft.AspNetCore.Components.ParameterAttribute]
60+
public string Name { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
61+
[Microsoft.AspNetCore.Components.ParameterAttribute]
62+
public T Value { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
63+
public void Configure(Microsoft.AspNetCore.Components.RenderHandle renderHandle) { }
64+
public System.Threading.Tasks.Task SetParametersAsync(Microsoft.AspNetCore.Components.ParameterCollection parameters) { throw null; }
65+
}
66+
}
67+
68+
namespace Microsoft.AspNetCore.Components.Forms
69+
{
70+
public partial class DataAnnotationsValidator : Microsoft.AspNetCore.Components.ComponentBase
71+
{
72+
public DataAnnotationsValidator() { }
73+
protected override void OnInit() { }
74+
}
75+
76+
public partial class EditForm : Microsoft.AspNetCore.Components.ComponentBase
77+
{
78+
public EditForm() { }
79+
[Microsoft.AspNetCore.Components.ParameterAttribute]
80+
public Microsoft.AspNetCore.Components.RenderFragment<Microsoft.AspNetCore.Components.Forms.EditContext> ChildContent { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
81+
[Microsoft.AspNetCore.Components.ParameterAttribute]
82+
public Microsoft.AspNetCore.Components.Forms.EditContext EditContext { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
83+
[Microsoft.AspNetCore.Components.ParameterAttribute]
84+
public object Model { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
85+
[Microsoft.AspNetCore.Components.ParameterAttribute]
86+
public Microsoft.AspNetCore.Components.EventCallback<Microsoft.AspNetCore.Components.Forms.EditContext> OnInvalidSubmit { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
87+
[Microsoft.AspNetCore.Components.ParameterAttribute]
88+
public Microsoft.AspNetCore.Components.EventCallback<Microsoft.AspNetCore.Components.Forms.EditContext> OnSubmit { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
89+
[Microsoft.AspNetCore.Components.ParameterAttribute]
90+
public Microsoft.AspNetCore.Components.EventCallback<Microsoft.AspNetCore.Components.Forms.EditContext> OnValidSubmit { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
91+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
92+
protected override void OnParametersSet() { }
93+
}
94+
95+
public abstract partial class InputBase<T> : Microsoft.AspNetCore.Components.ComponentBase
96+
{
97+
protected InputBase() { }
98+
[Microsoft.AspNetCore.Components.ParameterAttribute]
99+
public string Class { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
100+
protected string CssClass { get { throw null; } }
101+
protected T CurrentValue { get { throw null; } set { } }
102+
protected string CurrentValueAsString { get { throw null; } set { } }
103+
protected Microsoft.AspNetCore.Components.Forms.EditContext EditContext { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } }
104+
protected string FieldClass { get { throw null; } }
105+
protected Microsoft.AspNetCore.Components.Forms.FieldIdentifier FieldIdentifier { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } }
106+
[Microsoft.AspNetCore.Components.ParameterAttribute]
107+
public string Id { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
108+
[Microsoft.AspNetCore.Components.ParameterAttribute]
109+
public T Value { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
110+
[Microsoft.AspNetCore.Components.ParameterAttribute]
111+
public Microsoft.AspNetCore.Components.EventCallback<T> ValueChanged { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
112+
[Microsoft.AspNetCore.Components.ParameterAttribute]
113+
public System.Linq.Expressions.Expression<System.Func<T>> ValueExpression { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
114+
protected virtual string FormatValueAsString(T value) { throw null; }
115+
public override System.Threading.Tasks.Task SetParametersAsync(Microsoft.AspNetCore.Components.ParameterCollection parameters) { throw null; }
116+
protected abstract bool TryParseValueFromString(string value, out T result, out string validationErrorMessage);
117+
}
118+
119+
public partial class InputCheckbox : Microsoft.AspNetCore.Components.Forms.InputBase<bool>
120+
{
121+
public InputCheckbox() { }
122+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
123+
protected override bool TryParseValueFromString(string value, out bool result, out string validationErrorMessage) { throw null; }
124+
}
125+
126+
public partial class InputDate<T> : Microsoft.AspNetCore.Components.Forms.InputBase<T>
127+
{
128+
public InputDate() { }
129+
[Microsoft.AspNetCore.Components.ParameterAttribute]
130+
public string ParsingErrorMessage { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
131+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
132+
protected override string FormatValueAsString(T value) { throw null; }
133+
protected override bool TryParseValueFromString(string value, out T result, out string validationErrorMessage) { throw null; }
134+
}
135+
136+
public partial class InputNumber<T> : Microsoft.AspNetCore.Components.Forms.InputBase<T>
137+
{
138+
public InputNumber() { }
139+
[Microsoft.AspNetCore.Components.ParameterAttribute]
140+
public string ParsingErrorMessage { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
141+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
142+
protected override bool TryParseValueFromString(string value, out T result, out string validationErrorMessage) { throw null; }
143+
}
144+
145+
public partial class InputSelect<T> : Microsoft.AspNetCore.Components.Forms.InputBase<T>
146+
{
147+
public InputSelect() { }
148+
[Microsoft.AspNetCore.Components.ParameterAttribute]
149+
public Microsoft.AspNetCore.Components.RenderFragment ChildContent { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
150+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
151+
protected override bool TryParseValueFromString(string value, out T result, out string validationErrorMessage) { throw null; }
152+
}
153+
154+
public partial class InputText : Microsoft.AspNetCore.Components.Forms.InputBase<string>
155+
{
156+
public InputText() { }
157+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
158+
protected override bool TryParseValueFromString(string value, out string result, out string validationErrorMessage) { throw null; }
159+
}
160+
161+
public partial class InputTextArea : Microsoft.AspNetCore.Components.Forms.InputBase<string>
162+
{
163+
public InputTextArea() { }
164+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
165+
protected override bool TryParseValueFromString(string value, out string result, out string validationErrorMessage) { throw null; }
166+
}
167+
168+
public partial class ValidationMessage<T> : Microsoft.AspNetCore.Components.ComponentBase, System.IDisposable
169+
{
170+
public ValidationMessage() { }
171+
[Microsoft.AspNetCore.Components.ParameterAttribute]
172+
public System.Linq.Expressions.Expression<System.Func<T>> For { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
173+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
174+
protected override void OnParametersSet() { }
175+
void System.IDisposable.Dispose() { }
176+
}
177+
178+
public partial class ValidationSummary : Microsoft.AspNetCore.Components.ComponentBase, System.IDisposable
179+
{
180+
public ValidationSummary() { }
181+
protected override void BuildRenderTree(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder) { }
182+
protected override void OnParametersSet() { }
183+
void System.IDisposable.Dispose() { }
184+
}
185+
}
186+
187+
namespace Microsoft.AspNetCore.Components.Layouts
188+
{
189+
public partial class LayoutDisplay : Microsoft.AspNetCore.Components.IComponent
190+
{
191+
public LayoutDisplay() { }
192+
[Microsoft.AspNetCore.Components.ParameterAttribute]
193+
public System.Type Page { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
194+
[Microsoft.AspNetCore.Components.ParameterAttribute]
195+
public System.Collections.Generic.IDictionary<string, object> PageParameters { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
196+
public void Configure(Microsoft.AspNetCore.Components.RenderHandle renderHandle) { }
197+
public System.Threading.Tasks.Task SetParametersAsync(Microsoft.AspNetCore.Components.ParameterCollection parameters) { throw null; }
198+
}
199+
}
200+
201+
namespace Microsoft.AspNetCore.Components.Routing
202+
{
203+
public partial class NavLink : Microsoft.AspNetCore.Components.IComponent, System.IDisposable
204+
{
205+
public NavLink() { }
206+
[Microsoft.AspNetCore.Components.ParameterAttribute]
207+
public string ActiveClass { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
208+
[Microsoft.AspNetCore.Components.ParameterAttribute]
209+
public Microsoft.AspNetCore.Components.Routing.NavLinkMatch Match { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
210+
public void Configure(Microsoft.AspNetCore.Components.RenderHandle renderHandle) { }
211+
public void Dispose() { }
212+
public System.Threading.Tasks.Task SetParametersAsync(Microsoft.AspNetCore.Components.ParameterCollection parameters) { throw null; }
213+
}
214+
215+
public partial class Router : Microsoft.AspNetCore.Components.IComponent, System.IDisposable
216+
{
217+
public Router() { }
218+
[Microsoft.AspNetCore.Components.ParameterAttribute]
219+
public System.Reflection.Assembly AppAssembly { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
220+
[Microsoft.AspNetCore.Components.ParameterAttribute]
221+
public System.Type FallbackComponent { [System.Runtime.CompilerServices.CompilerGeneratedAttribute]get { throw null; } private set { throw null; }}
222+
public void Configure(Microsoft.AspNetCore.Components.RenderHandle renderHandle) { }
223+
public void Dispose() { }
224+
protected virtual void Render(Microsoft.AspNetCore.Components.RenderTree.RenderTreeBuilder builder, System.Type handler, System.Collections.Generic.IDictionary<string, object> parameters) { }
225+
public System.Threading.Tasks.Task SetParametersAsync(Microsoft.AspNetCore.Components.ParameterCollection parameters) { throw null; }
226+
}
47227
}

0 commit comments

Comments
 (0)