Skip to content

Add additional blazor tags for button, highlight and splitter#2241

Merged
rkaraivanov merged 2 commits into
masterfrom
mdragnev/add-blazor-tags
Jun 5, 2026
Merged

Add additional blazor tags for button, highlight and splitter#2241
rkaraivanov merged 2 commits into
masterfrom
mdragnev/add-blazor-tags

Conversation

@mddragnev

Copy link
Copy Markdown
Member

This is needed when updating blazor to 7.2.x

Description

Provide a clear and concise summary of the changes in this PR and the motivation behind them

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that causes existing functionality to change)
  • Documentation update
  • Refactoring (code improvements without functional changes)

Related Issues

Closes #

Testing

Checklist

  • My code follows the project's coding standards
  • I have tested my changes locally
  • I have updated documentation if needed
  • Breaking changes are documented in the description

@mddragnev mddragnev marked this pull request as ready for review June 4, 2026 12:57

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates component API metadata annotations used by the Blazor generator/analyzer (targeting a Blazor 7.2.x update), primarily by marking certain option/event argument shapes as plain JSON objects and adjusting Blazor-specific type metadata.

Changes:

  • Add /* jsonAPIPlainObject */ annotations for splitter resize event args and highlight navigation options.
  • Switch HighlightNavigation from a type alias to an interface to support analyzer metadata.
  • Add Blazor-specific metadata for button commandForElement, and suppress Blazor generation for chat resourceStrings.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
src/components/splitter/types.ts Marks IgcSplitterResizeEventArgs as a plain JSON object for interop tooling.
src/components/highlight/service.ts Marks HighlightNavigation as a plain JSON object and changes it to an interface for metadata support.
src/components/chat/chat.ts Adds /* blazorSuppress */ to resourceStrings to affect Blazor API generation.
src/components/button/button-base.ts Adds /* alternateType: object */ for commandForElement accessors to guide Blazor type mapping.
Comments suppressed due to low confidence (1)

src/components/chat/chat.ts:320

  • This change adds a Blazor analyzer directive on resourceStrings, but the PR title/description only mention button/highlight/splitter. Please update the PR metadata (title/description) to include the chat change or explain why this directive is required for the Blazor 7.2.x update, to avoid an undocumented API-generation change for igc-chat.
  /* blazorSuppress */
  /**
   * The resource strings of the chat.
   */
  @property({ attribute: false })
  public set resourceStrings(

@rkaraivanov rkaraivanov merged commit 79837d4 into master Jun 5, 2026
8 checks passed
@rkaraivanov rkaraivanov deleted the mdragnev/add-blazor-tags branch June 5, 2026 06:13
Comment on lines 159 to +160
/* blazorCSSuppress */
/* alternateType: object */

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mddragnev If this is already CS-suppressed, what caused the need for alt object?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

blazorCSSuppress is not entirely suppressing the member but the api analyzer generates it and marks it as BlazorSuppressWidgetMember then the blazor translator skip it. I guess that it has no use now when we dont have our react components using the translator. If you insist I can change that to blazorSuppress and remove the alternateType

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

blazorSuppress it then (aka full hide)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants