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

feat: Floating panel v2 #4613

Merged
merged 43 commits into from
Dec 20, 2024
Merged

feat: Floating panel v2 #4613

merged 43 commits into from
Dec 20, 2024

Conversation

kof
Copy link
Member

@kof kof commented Dec 18, 2024

Closes #4572

Description

  • All floating panels are now using a dialog and are draggable (bindings and expressions not migrated yet, separate PR)
  • Logic for positioning the panels is now in our control and easier to manage, because we have lots of special cases
  • Deleted FloatingPanelPopover, now everything uses either FloatingPanel or Popover, difference is in positioning logic, FloatingPanel is using Dialog
  • Big center positioned dialogs like code for html embed allow having another panel open at the same time, wile all other floating panels close the other panel when clicked
  • Most extended settings in style panel are now positioned above style panel, not on the left

Steps for reproduction

  1. click button
  2. expect xyz

Code Review

  • hi @kof, I need you to do
    • conceptual review (architecture, feature-correctness)
    • detailed review (read every line)
    • test it on preview

Before requesting a review

  • made a self-review
  • added inline comments where things may be not obvious (the "why", not "what")

Before merging

  • tested locally and on preview environment (preview dev login: 0000)
  • updated test cases document
  • added tests
  • if any new env variables are added, added them to .env file

@kof kof requested a review from TrySound December 18, 2024 01:42
@kof kof force-pushed the floating-panel-v2 branch from e2f76ac to bcba312 Compare December 18, 2024 14:26
@kof kof requested review from johnsicili and TrySound December 18, 2024 22:52
@johnsicili
Copy link
Contributor

1

  1. Set resource
  2. Drag window
  3. Open bindings for URL
  4. See new window not relative to first window
Screenshot 2024-12-18 at 4 00 12 PM

2

Not sure if they should move together

move.mp4

3

Idk if related but project setting code actions are gone like closing window

settings.mp4

4

Discoverability is hard

Breakpoint window not draggable, project settings window not draggable, but to me they look the same.

Though idk how much I'll be using this/how important it is from a user perspective.

5

Open bindings in page settings, window is off.

Screenshot 2024-12-18 at 4 07 58 PM

@kof
Copy link
Member Author

kof commented Dec 19, 2024

  1. Second window opens relative to the trigger that was clicked, not sure if it was the case when you tested, but seems as expected. Also these 2 are open at the same time only because the first one had errors and couldn't close

@kof
Copy link
Member Author

kof commented Dec 19, 2024

  1. Not intended, but seems minor
  2. fixed

@kof
Copy link
Member Author

kof commented Dec 19, 2024

  1. yeah, in case of project settings enabling draggable now, others, when there is no title/close button I think its intuitive to not expect them to be draggable. Maybe removing close button from publish and share dialogs will make this more clear in this case, they are basically popovers, not dialogs, but yeah

I felt like using the move cursor to the title bar is a bit too distracting, figma is not doing it either where its draggable, but idk

@kof
Copy link
Member Author

kof commented Dec 19, 2024

  1. fixed

Copy link
Member

@TrySound TrySound left a comment

Choose a reason for hiding this comment

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

maybe ok

@kof kof merged commit 6cb74d4 into main Dec 20, 2024
17 checks passed
@kof kof deleted the floating-panel-v2 branch December 20, 2024 10:22
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.

Make floating panel draggable
3 participants