Open ehamberg opened 7 years ago
@Oustad found out that wrapping the Input.multiline
in a fixes the issue too:
Element.layout stylesheet <|
column None
[ height (px 300), width (px 300) ]
[ row None
[ height (percent 100)
, width (percent 100)
]
[ Input.multiline Green
[ height (percent 100), width (percent 100) ]
{ onChange = \_ -> ""
, value = "foo\nbar\nbaz"
, label =
Input.hiddenLabel ""
, options = []
}
]
]
I had the same problem, and wrapping it in a row helped for me too (though for correct behavior I used height fill
on the multiline instead of height (percent 100)
).
I would greatly appreciate this working as expected. After all, this library is meant to make very predictable layouts :)
The big picture of what I'm trying to do
Trying to create a multi-line input that fills the entire width and height of its parent component.
What I did
Added a
Input.multiline
with[ height (percent 100), width (percent 100) ]
:What I Expected To Happen
Expected the text area to fill the entire parent component.
What Actually Happened
The text area fills the parent element's entire height only if
<!DOCTYPE HTML>
is not used.Here is an ellie with the code (this looks correct since Ellie's HTML does not include
<!DOCTYPE HTML>
!): https://ellie-app.com/dMVkrcHxga1/4Screenshot:
However, if you give the same code to
elm-make
, theindex.html
that is produced will display the following:Removing the first line of the
index.html
produced byelm-make
(<!DOCTYPE HTML>
) “fixes” the issue.Wrapping the
Input.multiline
in anel
does not seem to have an effect.Versions