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

[Dialog] Add new component, deprecate modal component #7886

Closed
7 of 9 tasks
geospatialem opened this issue Sep 26, 2023 · 19 comments
Closed
7 of 9 tasks

[Dialog] Add new component, deprecate modal component #7886

geospatialem opened this issue Sep 26, 2023 · 19 comments
Assignees
Labels
4 - verified Issues that have been released and confirmed resolved. ArcGIS Web Analysis Issues logged by ArcGIS Web Analysis team members calcite-components Issues specific to the @esri/calcite-components package. design Issues that need design consultation prior to development. enhancement Issues tied to a new feature or request. estimate - design - md Medium design effort; 5-10 days of design work estimate - 8 Requires input from team, consider smaller steps. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive new component Issues tied to a new component. p - high Issue should be addressed in the current milestone, impacts component or core functionality ready for dev Issues ready for development implementation.

Comments

@geospatialem
Copy link
Member

geospatialem commented Sep 26, 2023

Check existing issues

Description

The ModelBuider Web team is seeking a movable, non-attached component in early 2024 to support a workflow not requiring an additional click and is not restrictive for the user experience, where the use case cannot use modal as a solution.

We should identify if the new dialog component should support:

  • Resizing
  • Moving

Or, if not, what the recommended workflow would be for support with docking or an alternative approach.

Acceptance Criteria

Design: Figma file 🎨

  1. Dependency issues
  2. Add a new dialog component
    • "Render a panel inside" paradigm - refer to popover, sheet, and shell-panel
    • Properties
    • Slots
      • content
      • header
  3. Deprecate the modal component

Relevant Info

Originally reported in https://devtopia.esri.com/WebGIS/calcite-design-system/issues/163

Which Component

New component

Example Use Case

See the internal issue for additional context.

Priority impact

impact - p3 - not time sensitive

Calcite package

  • @esri/calcite-components
  • @esri/calcite-components-react
  • @esri/eslint-plugin-calcite-components

Esri team

N/A

@geospatialem geospatialem added enhancement Issues tied to a new feature or request. discussion Issues relating to a conversation where feedback is optional. design Issues that need design consultation prior to development. 0 - new New issues that need assignment. needs triage Planning workflow - pending design/dev review. labels Sep 26, 2023
@github-actions github-actions bot added impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive calcite-components Issues specific to the @esri/calcite-components package. labels Sep 26, 2023
@ethanbdev ethanbdev added the ArcGIS Web Analysis Issues logged by ArcGIS Web Analysis team members label Sep 26, 2023
@driskull
Copy link
Member

driskull commented Sep 26, 2023

The use case cannot use modal as a solution.

Can you elaborate on this a bit? I don't see why a non blocking modal (scrim turned off) couldn't support this better.

It seems like modal would fit this use case better or if not, we need a new component that is just a dialog and can be dragged.

I could see popover supporting resizing but not being a movable draggable object. Modal would be better for that use case. The whole point of popover (and floating-ui) is to attach to another element.

@driskull
Copy link
Member

@geospatialem can we separate resizing into their own unique issues? I do see resizing as valid requests for both modal and popover. However, the dragging is probably only valid for modal or another component that is visually equivalent to modal but non blocking.

@driskull
Copy link
Member

I think the best solution would be to deprecate modal and add a dialog component. The dialog component could have a property for modal/non-modal as well as properties for resizing and dragging.

@ethanbdev
Copy link
Contributor

Totally open to the best solution, whether its enhancing the modal or a new dialog component to meet the use case

@ethanbdev
Copy link
Contributor

ethanbdev commented Oct 5, 2023

Hey @geospatialem - could this be assigned to a milestone for tracking? I am not sure how far out you plan

@geospatialem
Copy link
Member Author

Hey @geospatialem - could this be assigned to a milestone for tracking? I am not sure how far out you plan

Hi @ethanbdev, this issue will need some design expertise prior to dev work, so there will likely be two milestones to address the effort. Design will be triaging issues late next week for consideration into an upcoming design sprint. cc @brittneytewks

@ethanbdev
Copy link
Contributor

Perfect - thanks!

@macandcheese
Copy link
Contributor

macandcheese commented Oct 16, 2023

I think the best solution would be to deprecate modal and add a dialog component. The dialog component could have a property for modal/non-modal as well as properties for resizing and dragging.

I think this is a good idea. It would also allow the new component to follow the “slot a Panel inside” paradigm that Popover, Sheet, Shell Panel follow, instead of Modal’s current slot set up.

@mjuniper
Copy link
Member

We have a use case for this. We want to show a non-modal privacy consent dialog positioned in the lower right of the screen like this:

image

@macandcheese
Copy link
Contributor

@geospatialem maybe we can repurpose this issue to encompass the discussion above re: Modal -> Dialog.

@geospatialem geospatialem added new component Issues tied to a new component. and removed discussion Issues relating to a conversation where feedback is optional. labels Oct 26, 2023
@geospatialem geospatialem changed the title [Popover] Support free-floating, movable, non-modal/attached component [Dialog] Add new component, deprecate modal component Oct 26, 2023
@brittneytewks brittneytewks added the p - high Issue should be addressed in the current milestone, impacts component or core functionality label Nov 16, 2023
@macandcheese
Copy link
Contributor

macandcheese commented Nov 16, 2023

If we explore Panel as the expected slotted element in this new Dialog - it would align more closely with Shell Panel / Sheet DX and UI. We'd likely want to rename "Action bar" and "Fab" slots in Panel to be more generic like Modal's "sticky top and bottom" ones.

We'd probably want to use the "placement" values from Alert as well as a "center (default)" value.

@brittneytewks brittneytewks added the estimate - design - md Medium design effort; 5-10 days of design work label Nov 16, 2023
@brittneytewks brittneytewks added this to the Design Backlog milestone Nov 16, 2023
@brittneytewks brittneytewks removed the needs triage Planning workflow - pending design/dev review. label Nov 16, 2023
@Azadirachta
Copy link

Hello @geospatialem - Please could you suggest a possible timeline for this issue? Thank You!

Originally reported in https://devtopia.esri.com/WebGIS/calcite-design-system/issues/163

@geospatialem
Copy link
Member Author

Hello @geospatialem - Please could you suggest a possible timeline for this issue? Thank You!

@Azadirachta Thanks for reaching out! The new component effort is currently in the design backlog for consideration with other high priority bug fixes and enhancements - Calcite does not have a timeline at this time, but will update the issue in the coming weeks on the design efforts (note that the dev efforts for implementation would be in addition to the design).

@brittneytewks brittneytewks removed this from the Design Backlog milestone Dec 14, 2023
@github-actions github-actions bot added the needs milestone Planning workflow - pending milestone assignment, has priority and/or estimate. label Jun 17, 2024
Copy link
Contributor

cc @geospatialem, @brittneytewks

@geospatialem geospatialem added the estimate - 8 Requires input from team, consider smaller steps. label Jun 18, 2024
@geospatialem geospatialem added this to the 2024-07-30 - Jul Release milestone Jun 18, 2024
@geospatialem geospatialem removed needs milestone Planning workflow - pending milestone assignment, has priority and/or estimate. p4 - not time sensitive labels Jun 18, 2024
@geospatialem geospatialem added 1 - assigned Issues that are assigned to a sprint and a team member. and removed 0 - new New issues that need assignment. labels Jun 27, 2024
@driskull
Copy link
Member

Can we get a separate issue for adding alerts slot on calcite-panel? This way it will be installed and documented as a separate feat PR.

@driskull driskull mentioned this issue Jul 12, 2024
6 tasks
@driskull
Copy link
Member

@SkyeSeitz @geospatialem from Figma docs, it says keyboard user will get a live area notification and move via keyboard.

What should the text say for this aria-live area?

I'm assuming it would say something for moving and resizing via keyboard but I could use help with what exactly to say.

Arrow keys should move the dialog whereas arrow keys plus shiftKey should resize the dialog.

@geospatialem
Copy link
Member Author

@SkyeSeitz @geospatialem from Figma docs, it says keyboard user will get a live area notification and move via keyboard.

What should the text say for this aria-live area?

I'm assuming it would say something for moving and resizing via keyboard but I could use help with what exactly to say.

Arrow keys should move the dialog whereas arrow keys plus shiftKey should resize the dialog.

@driskull The role should provide the context of how to interact with the component, but we should support a label to provide additional context to what the purpose of the component is. Maybe we should have a default label, and the developer could specify using a label attr/prop? cc @SkyeSeitz

driskull added a commit that referenced this issue Jul 26, 2024
…onent (#9751)

**Related Issue:** #7886

## Summary

- Adds new `calcite-dialog` component.
  - Includes e2e, stories, demos, resources
  - Updates stencil config to note new component
- Panel esc key should emit close event  
- Adds `dialogs` slot to `calcite-shell` for slotting dialogs.
- Deprecates `calcite-modal` component.
- cleans up global style imports
- makes `focusTrapDisabled` optional on FocusTrapComponent

## Notes

- Animations need review
@driskull driskull added 3 - installed Issues that have been merged to master branch and are ready for final confirmation. and removed 1 - assigned Issues that are assigned to a sprint and a team member. labels Jul 26, 2024
Copy link
Contributor

Installed and assigned for verification.

@geospatialem geospatialem added 4 - verified Issues that have been released and confirmed resolved. and removed 3 - installed Issues that have been merged to master branch and are ready for final confirmation. labels Jul 29, 2024
@geospatialem
Copy link
Member Author

geospatialem commented Jul 29, 2024

Verified in 2.11.0-next.25 in https://codepen.io/geospatialem/pen/rNEjemQ with the following (listed as attributes below, where applicable):

  • Default slot
  • placement for "top-start", "top", "top-end", "center" (default), "bottom-start", "bottom", and "bottom-end"
  • kind for "brand", "danger", "info", "none" (default), "success", "warning"
  • heading
  • description
  • scale
  • width-scale
  • open
  • close-disabled
  • loading
  • menu-open
  • modal
  • overlay-positioning

Of note the resizing and dragging of the component will be handled in #9875 anticipated for the August release.

There looks to be something off when overlay-positioning="fixed" and menu-open is present: https://codepen.io/geospatialem/pen/ZEdLWNZ, opened via #9876. cc @driskull

calcite-admin pushed a commit that referenced this issue Jul 30, 2024
…onent (#9751)

**Related Issue:** #7886

## Summary

- Adds new `calcite-dialog` component.
  - Includes e2e, stories, demos, resources
  - Updates stencil config to note new component
- Panel esc key should emit close event  
- Adds `dialogs` slot to `calcite-shell` for slotting dialogs.
- Deprecates `calcite-modal` component.
- cleans up global style imports
- makes `focusTrapDisabled` optional on FocusTrapComponent

## Notes

- Animations need review
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4 - verified Issues that have been released and confirmed resolved. ArcGIS Web Analysis Issues logged by ArcGIS Web Analysis team members calcite-components Issues specific to the @esri/calcite-components package. design Issues that need design consultation prior to development. enhancement Issues tied to a new feature or request. estimate - design - md Medium design effort; 5-10 days of design work estimate - 8 Requires input from team, consider smaller steps. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive new component Issues tied to a new component. p - high Issue should be addressed in the current milestone, impacts component or core functionality ready for dev Issues ready for development implementation.
Projects
None yet
Development

No branches or pull requests

9 participants