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

Sidebar: forms can't be submitted in the presence of non-modal Sidebars #3360

Open
inad9300 opened this issue Sep 23, 2022 · 5 comments
Open
Labels
Resolution: Workaround Issue or pull request contains a workaround. It needs to be reviewed further by Core Team Type: Bug Issue contains a defect related to a specific component.

Comments

@inad9300
Copy link
Contributor

inad9300 commented Sep 23, 2022

Describe the bug

Likely related to #2562

Reproducer

https://codesandbox.io/s/primereact-test-forked-ghjz97?file=/src/index.js

PrimeReact version

8.6.0

React version

18.x

Language

ALL

Build / Runtime

Create React App (CRA)

Browser(s)

No response

Steps to reproduce the behavior

  1. Click "Submit"
  2. Verify that no message is logged, i.e. submission doesn't work
  3. Comment out <Sidebar /> element
  4. Verify that a message is logged, i.e. submission works

Expected behavior

No response

@inad9300 inad9300 added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Sep 23, 2022
@inad9300 inad9300 changed the title Sidebar: forms can't be submitted in the presence of non-modal Sidebar Sidebar: forms can't be submitted in the presence of non-modal Sidebars Sep 23, 2022
@melloware melloware added Type: Bug Issue contains a defect related to a specific component. and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Sep 23, 2022
@melloware
Copy link
Member

I agree it looks like when modal={false} the mask is still filling the screen and intercepting clicks.

@atrhacker
Copy link

Seems to be linked to the following:
https://forum.primefaces.org/viewtopic.php?f=57&t=74993

Basically, if you put any input type file (or FileUpload) in the page when there is a sidebar, the behavior of the input file will be completely blocked. (with or without form attached to it)
You can test it here:
https://codesandbox.io/s/withered-water ... oadDemo.js](https://codesandbox.io/s/withered-waterfall-cs307o?file=/src/demo/FileUploadDemo.js

Not sure, if I need to open a different bug request for this or shall we attach it to this one?

@melloware
Copy link
Member

I think this one is fine it's most likely the same issue

@atrhacker
Copy link

Would there be any temporary solutions ? even I fork the code.. This is the only item which forbid me from migrating to v8.
I'm surprised that it's not affecting the official documentation webpage as it also contain a side bar?

@kl-nevermore
Copy link
Contributor

kl-nevermore commented Jan 4, 2024

@atrhacker
I just encountered this problem too
you can add dismissable={false}

<Sidebar visible={true} modal={false} dismissable={false} onHide={() => setVisible(false)} />

@melloware melloware added the Resolution: Workaround Issue or pull request contains a workaround. It needs to be reviewed further by Core Team label Jan 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Workaround Issue or pull request contains a workaround. It needs to be reviewed further by Core Team Type: Bug Issue contains a defect related to a specific component.
Projects
None yet
Development

No branches or pull requests

4 participants