Change layer size on response #789
Unanswered
alexandremjacques
asked this question in
Q&A
Replies: 1 comment
-
|
If you open an overlay with There's no public API to directly change the width of an overlay after it has opened. However, right now the size is only an attribute on the overlay container, and the width is styled using CSS. You can probably hack it by changing the attribute. E.g. this is your response that wants a "wide" layout: <form needs-overlay-size="large">
...
</form>Here is a compiler that sets the up.compiler('[needs-overlay-size]', (element) => {
let size = element.getAttribute('needs-overlay-size')
let layer = up.element.get(element)
layer.element.setAttribute('size', size)
})Untested! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I have a opened layer with
size="medium"that has a form inside it. Upon success submit, I would like to change its size tolargesince the response is another form that has a wider layout.Is there a way to achieve that?
TIA.
Beta Was this translation helpful? Give feedback.
All reactions