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

Critical Error in 1.0.1 #83

Closed
wagslane opened this issue Aug 9, 2020 · 8 comments · Fixed by #84
Closed

Critical Error in 1.0.1 #83

wagslane opened this issue Aug 9, 2020 · 8 comments · Fixed by #84

Comments

@wagslane
Copy link
Contributor

wagslane commented Aug 9, 2020

Take a look at https://classroom.qvault.io/playground/go

Try to write code longer than ~26 lines. You will see that the cursor is no longer able to move downwards. Not sure what is causing this but I will likely have to rollback until a solution is pushed out

The problem is also present in your example: https://codesandbox.io/s/61yrlnlnmn
However, there it starts around line ~16

It's looking like it's dependent on the height of the <textarea>. It isn't resizing dynamically or something...

@wagslane
Copy link
Contributor Author

wagslane commented Aug 9, 2020

Should be an easy fix. I was able to patch it with the following CSS:

.prism-editor-wrapper {
  height: auto;
}

@koca
Copy link
Owner

koca commented Aug 9, 2020

Oh! thanks for the report @lane-c-wagner. Let me check.

@wagslane
Copy link
Contributor Author

wagslane commented Aug 9, 2020

I patched qvault, so you will need to verify on your demo. Sorry about that haha

@koca
Copy link
Owner

koca commented Aug 9, 2020

Made width and height auto and didn't fix 🤔 here is a repro:
https://codesandbox.io/s/vue-prism-editor-bug-83-xdpt1?file=/src/App.vue
I added the css of the editor so you can play with it.

@wagslane
Copy link
Contributor Author

wagslane commented Aug 9, 2020

Adding !important to those additions you made fixed it. I don't think that the !important is the right choice though, probably just need to also change your duplicate rules:

.prism-editor-wrapper .prism-editor__textarea {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  resize: none;
  color: inherit;
  overflow: hidden;
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  -webkit-text-fill-color: transparent;
}

or

.prism-editor-wrapper .prism-editor__container {
  position: relative;
  text-align: left;
  box-sizing: border-box;
  padding: 0;
  overflow: hidden;
  width: 100%;
  height: 100%;
}

@koca
Copy link
Owner

koca commented Aug 9, 2020

Removing this:

fixes all cases i think 🤔 Would you mind trying and updating the PR?

@wagslane
Copy link
Contributor Author

wagslane commented Aug 9, 2020

@koca done, and thanks

@koca koca closed this as completed in #84 Aug 9, 2020
@koca
Copy link
Owner

koca commented Aug 9, 2020

released v1.2.0 🚀

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 a pull request may close this issue.

2 participants