-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Added Text Transforms in Styles Panel #1689
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
Merged
Merged
Conversation
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
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.
👍 Looks good to me! Reviewed everything up to b74fe8b in 1 minute and 57 seconds
More details
- Looked at
15
lines of code in1
files - Skipped
0
files when reviewing. - Skipped posting
4
drafted comments based on config settings.
1. apps/studio/src/lib/editor/styles/group.ts:245
- Draft comment:
Consider adding unit tests for the new textTransform feature. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable: usefulness confidence = 10% vs. threshold = 50%
This is a simple configuration addition that defines a style option using the existing SingleStyleImpl class. The implementation is using a standard pattern already used throughout the file. Unit testing a configuration value like this would be overkill since it's just data definition, not logic. The SingleStyleImpl class itself should already be tested elsewhere.
Perhaps there could be integration tests needed to verify the text transform functionality works end-to-end? Maybe there are edge cases with text transformation that should be tested?
The textTransform property is a standard CSS property with well-defined behavior. The code change is just configuration using an existing tested framework. Any integration testing would be part of the broader system, not specific to this simple addition.
This comment should be deleted as it suggests unnecessary testing for what is essentially just configuration data using an existing pattern.
2. apps/studio/src/lib/editor/styles/group.ts:245
- Draft comment:
Consider renaming the label from 'Transform' to 'Text Transform' for clarity. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable: usefulness confidence = 20% vs. threshold = 50%
The current label 'Transform' appears within the TextGroup context, so its meaning is already clear from context. Other labels in this group like 'Color', 'Size', 'Weight' are similarly concise. The suggestion would break the consistent pattern of short labels used throughout the file. The property's purpose is already clear from its context and options.
The current label could potentially be ambiguous since 'transform' can refer to other types of transformations in CSS. The longer name would be more explicit.
The context of being in TextGroup and having text-specific options makes the meaning clear enough. Breaking the established pattern of concise labels would reduce consistency.
The comment should be deleted as it suggests breaking the established naming pattern without providing sufficient benefit to clarity.
3. apps/studio/src/lib/editor/styles/group.ts:245
- Draft comment:
Consider renaming label from 'Transform' to 'Text Transform' for clarity. - Reason this comment was not posted:
Confidence changes required:50%
<= threshold50%
None
4. apps/studio/src/lib/editor/styles/group.ts:247
- Draft comment:
Add tests for the new textTransform feature for better coverage. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable: usefulness confidence = 10% vs. threshold = 50%
While adding tests is generally good practice, this is a very simple style property definition that follows the exact same pattern as all other style properties in the file. The implementation is straightforward - it's just defining available options for a standard CSS property. Testing this would be overkill given its simplicity and similarity to existing patterns.
Maybe there are complex interactions with other text styles that need testing? Maybe there's some custom handling of textTransform that isn't visible in this file?
The implementation is extremely simple and follows an established pattern used throughout the file. There's no evidence of any complex behavior that would warrant special testing.
The comment should be deleted as it suggests unnecessary testing for a very simple, standard style property definition.
Workflow ID: wflow_G79LPVGEgL38iiPc
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
awesome thanks @Rupak182 ! |
zongkelong
pushed a commit
to zongkelong/coolook
that referenced
this pull request
Mar 31, 2025
…slation_zh * 'main' of https://github.com/onlook-dev/onlook: Publish version v0.2.23 (onlook-dev#1694) Fix edit panel not fully hidden (onlook-dev#1695) Update file watcher and remove elide lines (onlook-dev#1693) Add sticky position (onlook-dev#1692) Publish version v0.2.22 (onlook-dev#1679) added text transforms (onlook-dev#1689) Update URL when changing project settings URL (onlook-dev#1690) fix: error when setting text color (onlook-dev#1688) Revert freestyle source (onlook-dev#1686)
ml-delaurier
pushed a commit
to ml-delaurier/nolook
that referenced
this pull request
Apr 23, 2025
t1c1
pushed a commit
to t1c1/onlookbotcodes
that referenced
this pull request
Jun 5, 2025
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.
Description
This PR adds the text transform feature to styles panel and provides the following options:
Related Issues
Related to #1530
Type of Change
Testing
No Tests Added
Screenshots (if applicable)
demo.mp4
Additional Notes
Important
Adds
textTransform
feature toTextGroup
ingroup.ts
with options for text capitalization.textTransform
option toTextGroup
ingroup.ts
with options:none
,capitalize
,uppercase
,lowercase
.This description was created by
for b74fe8b. It will automatically update as commits are pushed.