Forms: Dialogs not sticky

Created on 15 May 2020  ยท  10Comments  ยท  Source: nextcloud/forms

Configuration
Dialogs v1.3.0,
Forms-App on master
NC 18.0.4

Behaviour
Dialogs are not sticky, but appear at top of the page. So if i am not at top of the page (scrolled down on a long form), i don't see the dialog at all.

I assume, this is not intended, but they should appear sticky at the top of the current screen?

grafik

1. to develop bug ๐Ÿ“‘ form creation

Most helpful comment

๐Ÿ‘ , see link. :)

All 10 comments

@juliushaertl any clue? are we overwriting something with the styling or is this a bug in the toasts lib?

Hm that is odd, I can reproduce this by calling OCP.Toast.error in forms but not in any other app. There is maybe something odd with the body as a scroll container there, but I cannot see anything obvious.

So seems like a forms issue...?
@skjnldsv Any idea? ๐Ÿค”

Hm that is odd, I can reproduce this by calling OCP.Toast.error in forms but not in any other app. There is maybe something odd with the body as a scroll container there, but I cannot see anything obvious.

How can I invoke the toast so it stays and does not disappear automatically after some time? Then I could debug.

In theory timeout: 0 should work. But with OCP.Toast.error('test', {timeout: 0}) it even doesn't work for me...

@jancborchardt On branch test/dialog i just pushed my current testing environment. There it works for the toast to remain open.

Simply disabling the position: absolute (which is relative to the apparently moving body element) fixes it โ€“ cause then the position: fixed from server.css takes over. The inline one is from nextcloud-vue, correct? That one should be fixed as well, no @juliushaertl?
inline | server.css
-|-
toastify inline|toastify server

Nice @jancborchardt ๐Ÿ’ช

The inline-one comes from nextcloud-dialogs/styles/toast.scss

Interesting thing is, that the style from server contains in fact the same styles just with the changed position. Maybe one of them should be removed, so toast-styles are only defined in one place??
(And resp. fixed position in case it remains in dialogs.)

Yes, I think the server styles were fixed independently after we copied the styles over to https://github.com/nextcloud/nextcloud-dialogs/blob/master/styles/toast.scss#L10

@jotoeri Are you up for preparing a pull request to fix this in the dialogs library?

๐Ÿ‘ , see link. :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Chartman123 picture Chartman123  ยท  6Comments

ldavet picture ldavet  ยท  3Comments

Sohalt picture Sohalt  ยท  6Comments

jotoeri picture jotoeri  ยท  4Comments

marcelklehr picture marcelklehr  ยท  4Comments