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

When resizing the window uploaded image gets greyed out and shifts to bottom #2603

Open
PiyushChandra17 opened this issue Nov 14, 2023 · 4 comments
Assignees

Comments

@PiyushChandra17
Copy link
Contributor

p5.js version

2.9.2

What is your operating system?

Mac OS

Web browser and version

Chrome and 117.0.5938.132

Actual Behavior

When resizing the window uploaded image gets greyed out and shifts to bottom
image-responsive

Expected Behavior

When resizing the window uploaded image should not get greyed out and should remain at its initial position. Perhaps it's not fully responsive at some extent, also the width of the side bar is unnecessarily large and i think this is the root cause

Steps to reproduce

Steps:

  1. Open the editor web app
  2. Click on sidebar expand icon
  3. Click on "+"
  4. Click on upload file
  5. Upload an image
  6. Resize the widow
  7. Verify the image gets greyed out and shifts to bottom
@lindapaiste
Copy link
Collaborator

Good catch. It is not just while resizing. Previewing an image is messed up when in the mobile size range. I'm seeing the image show up below the code editor. We should be just showing the image (AssetPreview) and not showing the editor at all when you are viewing a media file. It is hidden via CSS when on desktop but not on mobile.

const editorHolderClass = classNames({
'editor-holder': true,
'editor-holder--hidden':
this.props.file.fileType === 'folder' || this.props.file.url
});

@Akhilbisht798
Copy link
Contributor

Hey, i am not sure about the greyed part of this issue but i can confirm that the image is shifting toward the bottom of the screen.

@Akhilbisht798
Copy link
Contributor

                <EditorHolder
                  ref={(element) => {
                    this.codemirrorContainer = element;
                  }}
                  className={editorHolderClass}
                />

I think this will solve the problem, but I am not able to test it because It requires a s3 bucket to upload a file.
And I don't have one so

@aditya123473892
Copy link

@lindapaiste can i be assigned with issue if no one is working on it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants