[feat] Add BidiComponent and tests#12756
Merged
sfc-gh-bnisco merged 1 commit intodevelopfrom Oct 25, 2025
Merged
Conversation
This was referenced Oct 10, 2025
Contributor
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
This was referenced Oct 10, 2025
Collaborator
Author
This was referenced Oct 10, 2025
40cc462 to
56905f0
Compare
428a03c to
df8b8c9
Compare
56905f0 to
fde956b
Compare
df8b8c9 to
f0e43b0
Compare
fde956b to
11a18e8
Compare
f0e43b0 to
b395286
Compare
11a18e8 to
9202c81
Compare
b395286 to
9137990
Compare
07eba44 to
20309b7
Compare
1b4face to
83046b6
Compare
20309b7 to
490d011
Compare
83046b6 to
c33ae67
Compare
490d011 to
0b7c5c3
Compare
c33ae67 to
bd292db
Compare
0b7c5c3 to
0bb0b3c
Compare
bd292db to
9529cf0
Compare
8fa7a97 to
d4a0e93
Compare
9529cf0 to
1124a77
Compare
sfc-gh-bnisco
added a commit
that referenced
this pull request
Oct 24, 2025
## Describe your changes Added two new hooks for CCv2 to handle HTML, CSS, and JavaScript content from the user's component: 1. `useHandleHtmlAndCssContent`: Safely injects HTML content (including script tags) and CSS into the component container. It supports both inline CSS and external CSS files. 2. `useHandleJsContent`: Manages JavaScript content execution for CCv2. It supports both inline JS and external JS files, and provides proper lifecycle management with cleanup functions. These hooks provide a clean separation of concerns for handling different types of content in BidiComponents, with proper error handling and resource cleanup. ## GitHub Issue Link (if applicable) ## Testing Plan - These code paths are tested when they are actually used by the composed component in #12756 --- **Contribution License Agreement** By submitting this pull request you agree that all contributions to this project are made under the Apache 2.0 license.
1124a77 to
25ad6bd
Compare
d4a0e93 to
985a57b
Compare
Collaborator
Author
Merge activity
|
sfc-gh-bnisco
added a commit
that referenced
this pull request
Oct 24, 2025
## Describe your changes Added isolated and non-isolated component implementations for the CCv2 widget. This includes: 1. `IsolatedComponent.tsx` - A component that uses Shadow DOM for content isolation 2. `NonIsolatedComponent.tsx` - A component that renders content directly without isolation 3. `styled-components.ts` - Shared styled components for both implementations The isolated component creates a shadow root for content encapsulation, while the non-isolated version renders directly to a div. Both components use shared hooks for handling HTML, CSS, and JavaScript content. ## GitHub Issue Link (if applicable) ## Testing Plan - These code paths are tested when they are actually used by the composed component in #12756 and in the e2e tests #12758 --- **Contribution License Agreement** By submitting this pull request you agree that all contributions to this project are made under the Apache 2.0 license.
985a57b to
eccbd34
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Describe your changes
Added the main BidiComponent component. This component composes everything from the prior few components:
GitHub Issue Link (if applicable)
Testing Plan
Contribution License Agreement
By submitting this pull request you agree that all contributions to this project are made under the Apache 2.0 license.