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

TextArea is not resizing #109

Closed
qradle opened this issue Dec 19, 2018 · 4 comments
Closed

TextArea is not resizing #109

qradle opened this issue Dec 19, 2018 · 4 comments
Labels

Comments

@qradle
Copy link

qradle commented Dec 19, 2018

Version

3.3.0

Development Environment

Chrome Firefox, ubuntu

Current Behavior

You can found current behavior even in the examples. (so I use same api methods).
http:https://nhnent.github.io/tui.image-editor/latest/tutorial-example02-useApiDirect.html

steps to reproduce:

  1. add text object with addText method.
  2. double click to enter editing mode
  3. start typing
    You can see that textarea width is not resizing while typing, and tail signs became hidden.

Expected Behavior

Textarea width resizing by the content.
The proper behavior is expected just like in example with includeUI.
https://nhnent.github.io/tui.image-editor/latest/tutorial-example01-includeUi.html (example 1).

@calvinkei
Copy link

+1, the behavior of using API directly is different from includeUI

@sabinayakc
Copy link

I am having the same issue. Any updates on this or how we can update the API to use the same functionality as the UI?

If you can point me to the code that updates the Text Area width I can maybe make a local code change for a temporary workaround.

@sabinayakc
Copy link

Found the problem. It has to do with IText settings when initializing the image editor. Currently, when you don't use UI, useIText is set to false. If you set that to true then the API version will use IText. I don't know the reason for setting that to false for API versions but setting that to true enables textArea resizing. Hope this helps @calvinkei @qradle @jinwoo-kim-nhn

Line 178 - imageEditor.js

useItext: !!this.ui,

image

@jinwoo-kim-nhn
Copy link
Contributor

jinwoo-kim-nhn commented Apr 1, 2020

I'm improving this. It's almost finished. Please wait a little longer.

jinwoo-kim-nhn added a commit that referenced this issue Jun 16, 2020
* fix: fixed Text object -> ITextObject

* apply codereview

Co-authored-by: jwc <[email protected]>
HerlinMatos pushed a commit to EveryMundo/tui.image-editor that referenced this issue Jul 2, 2020
* fix: fixed Text object -> ITextObject

* apply codereview

Co-authored-by: jwc <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants