mirror of
https://gitee.com/jmix/cuba.git
synced 2024-12-01 02:38:21 +08:00
PL-7461 ResizableTextArea should have minimal height equal to $v-unit-size
This commit is contained in:
parent
1f8fe36664
commit
5049caa263
@ -37,7 +37,6 @@ public class CubaResizableTextAreaWrapperWidget extends VCustomComponent {
|
||||
|
||||
protected static final int MOUSE_EVENTS = Event.ONMOUSEDOWN | Event.ONMOUSEMOVE | Event.ONMOUSEUP | Event.ONMOUSEOVER;
|
||||
protected static final int MINIMAL_WIDTH = 17;
|
||||
protected static final int MINIMAL_HEIGHT = 17;
|
||||
|
||||
public boolean isResizable() {
|
||||
return resizeElement != null;
|
||||
@ -132,8 +131,10 @@ public class CubaResizableTextAreaWrapperWidget extends VCustomComponent {
|
||||
int absoluteLeft = getAbsoluteLeft();
|
||||
int absoluteTop = getAbsoluteTop();
|
||||
|
||||
ComputedStyle cs = new ComputedStyle(getElement().getFirstChildElement());
|
||||
|
||||
//do not allow mirror-functionality
|
||||
if (mouseY > absoluteTop + MINIMAL_HEIGHT && mouseX > absoluteLeft + MINIMAL_WIDTH) {
|
||||
if (mouseY > absoluteTop + cs.getDoubleProperty("min-height") && mouseX > absoluteLeft + MINIMAL_WIDTH) {
|
||||
int width = mouseX - absoluteLeft + 2;
|
||||
int height = mouseY - absoluteTop + 2;
|
||||
|
||||
|
@ -21,6 +21,10 @@
|
||||
.cuba-resizabletextarea-wrapper {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
|
||||
.v-textarea {
|
||||
min-height: $v-unit-size;
|
||||
}
|
||||
}
|
||||
|
||||
.#{$primary-stylename}-resize-corner {
|
||||
|
@ -18,6 +18,10 @@
|
||||
.cuba-resizabletextarea-wrapper {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
|
||||
.v-textarea {
|
||||
min-height: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
.#{$primary-stylename}-resize-corner {
|
||||
|
Loading…
Reference in New Issue
Block a user