Skip to content
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

Highlight target scene of comment #4597

Merged
merged 2 commits into from
Dec 4, 2023
Merged

Conversation

gbalint
Copy link
Contributor

@gbalint gbalint commented Dec 4, 2023

Description:

  • When inserting a comment, highlight the target scene under the mouse.
  • When opening a comment thread, highlight the scene of the comment thread (if there is one).

Copy link
Contributor

github-actions bot commented Dec 4, 2023

Try me

if (remixState == null) {
return
}
remixState.navigate(remixLocationRoute)
})
}
dispatch([

const actions = stripNulls([
Copy link
Contributor

Choose a reason for hiding this comment

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

can you use openCommentThreadActions?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

True, that is why i extracted these to openCommentThreadActions, thanks!

Copy link

relativeci bot commented Dec 4, 2023

Job #9444: Bundle Size — 66.34MiB (~+0.01%).

6448e76(current) vs 5957b21 master#9440(baseline)

Warning

Bundle contains 68 duplicate packages – View duplicate packages

Bundle metrics  Change 2 changes Regression 1 regression
                 Current
Job #9444
     Baseline
Job #9440
Regression  Initial JS 48.48MiB(~+0.01%) 48.48MiB
No change  Initial CSS 0B 0B
Change  Cache Invalidation 18.32% 19.94%
No change  Chunks 26 26
No change  Assets 30 30
No change  Modules 4493 4493
No change  Duplicate Modules 477 477
No change  Duplicate Code 30.26% 30.26%
No change  Packages 467 467
No change  Duplicate Packages 68 68
Bundle size by type  Change 1 change Regression 1 regression
                 Current
Job #9444
     Baseline
Job #9440
Regression  JS 66.33MiB (~+0.01%) 66.32MiB
Not changed  HTML 11.32KiB 11.32KiB

View job #9444 reportView feature/highlight-comment-scene branch activity

Copy link
Contributor

github-actions bot commented Dec 4, 2023

Performance test results:
(Chart1)
(Chart2)

@@ -98,18 +99,22 @@ const CommentIndicator = React.memo(({ thread }: CommentIndicatorProps) => {
const onClick = React.useCallback(() => {
if (isOnAnotherRoute && remixLocationRoute != null) {
// TODO: after we have scene identifier in the comment metadata we should only navigate the scene with the comment
Object.keys(remixNavigationState).forEach((scene) => {
const remixState = remixNavigationState[scene]
Object.keys(remixNavigationState).forEach((s) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

wasn't it better the way it was before?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I renamed it because i have a variable named scene in the outer scope. But I renamed that now, and renamed this inner s to scene again.

@gbalint gbalint merged commit c5bef28 into master Dec 4, 2023
13 checks passed
@gbalint gbalint deleted the feature/highlight-comment-scene branch December 4, 2023 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants