-
-
Notifications
You must be signed in to change notification settings - Fork 382
doc(Attributes): update components xml comments #7780
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -6,31 +6,18 @@ | |||||||||||||||||||||||||||||
| namespace BootstrapBlazor.Components; | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| /// <summary> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">定义目标数据类型的 UI 生成元数据组</para> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">通常模型类型位于与 Blazor 组件 UI 层不同的层</para> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">在这种情况下,使用 <see cref="TableMetadataForAttribute"/> 为 Table 组件定义元数据类型</para> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">然后使用 <seealso cref="TableMetadataTypeService"/> 注册元数据类型</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">Define a group of UI generation metadata for target data type</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">Usually model types are at different layer to the blazor component UI layer</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">In this case, use <see cref="TableMetadataForAttribute"/> to define a metadata type for Table component</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">Then register metadata type with <seealso cref="TableMetadataTypeService"/></para> | ||||||||||||||||||||||||||||||
| /// | ||||||||||||||||||||||||||||||
| /// <para lang="zh">定义目标数据类型的 UI 生成元数据组,通常模型类型位于与 Blazor 组件 UI 层不同的层,在这种情况下,使用 <see cref="TableMetadataForAttribute"/> 为 Table 组件定义元数据类型,然后使用 <seealso cref="TableMetadataTypeService"/> 注册元数据类型</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">Defines a group of UI generation metadata for the target data type. Usually, model types are located in a different layer than the Blazor component UI layer. In this case, use <see cref="TableMetadataForAttribute"/> to define a metadata type for the Table component, and then use <seealso cref="TableMetadataTypeService"/> to register the metadata type.</para> | ||||||||||||||||||||||||||||||
| /// <example> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">示例:</para> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">Pig 数据类型通常位于业务层或数据层</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">Example:</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">the Pig data type is usually at biz or data layer</para> | ||||||||||||||||||||||||||||||
| /// <code> | ||||||||||||||||||||||||||||||
| /// <para>示例:Pig 数据类型通常位于业务层或数据层; Example: the Pig data type is usually at biz or data layer</para> | ||||||||||||||||||||||||||||||
| /// <code> | ||||||||||||||||||||||||||||||
|
Comment on lines
11
to
+13
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. suggestion: Avoid mixing languages in a single XML doc paragraph to keep localization clearer. Previously, zh/en text was split into separate
Suggested change
Comment on lines
11
to
+13
|
||||||||||||||||||||||||||||||
| /// public class Pig | ||||||||||||||||||||||||||||||
| /// { | ||||||||||||||||||||||||||||||
| /// public string? Name1 { get; set; } | ||||||||||||||||||||||||||||||
| /// | ||||||||||||||||||||||||||||||
| /// public string? Name2 { get; set; } | ||||||||||||||||||||||||||||||
| /// } | ||||||||||||||||||||||||||||||
| /// </code> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">PigMetadata 可以定义在 UI/组件层</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">the PigMetadata can be defined at UI/component layer</para> | ||||||||||||||||||||||||||||||
| /// <code> | ||||||||||||||||||||||||||||||
| /// | ||||||||||||||||||||||||||||||
| /// [TableMetadataFor(typeof(Pig))] | ||||||||||||||||||||||||||||||
| /// [AutoGenerateClass(Align = Alignment.Center)] | ||||||||||||||||||||||||||||||
| /// public class PigMetadata | ||||||||||||||||||||||||||||||
|
|
@@ -41,28 +28,19 @@ namespace BootstrapBlazor.Components; | |||||||||||||||||||||||||||||
| /// [AutoGenerateColumn(Align = Alignment.Center, Order = -2)] | ||||||||||||||||||||||||||||||
| /// public string? Name2 { get; set; } | ||||||||||||||||||||||||||||||
| /// } | ||||||||||||||||||||||||||||||
| /// </code> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">在使用元数据之前,需要注册元数据类型</para> | ||||||||||||||||||||||||||||||
| /// <para lang="zh">在程序集中注册元数据类型</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">before using the metadata, it needs to register the metadata types</para> | ||||||||||||||||||||||||||||||
| /// <para lang="en">register metadata types in assembly</para> | ||||||||||||||||||||||||||||||
| /// <code> | ||||||||||||||||||||||||||||||
| /// </code> | ||||||||||||||||||||||||||||||
| /// <para>register metadata types in assembly</para> | ||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||
| /// <para>register metadata types in assembly</para> | |
| /// <para lang="zh">在程序集中注册元数据类型</para> | |
| /// <para lang="en">Register metadata types in the assembly</para> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The summary text mentions
JSModuleAutoLoaderAttributeas plain text. Using<see cref="JSModuleAutoLoaderAttribute"/>here (as done elsewhere in the codebase) would preserve clickable API links in generated docs and avoid drift between the zh/en summaries.