Commit Graph

43 Commits

Author SHA1 Message Date
nathan
12151139ff Et2Dialog: Better non-modal handling, now with less internal conflicts with SlDialog 2022-12-07 13:45:38 -07:00
nathan
32248e67ee Et2Dialog: Better non-modal styling 2022-12-07 11:30:14 -07:00
nathan
4b6357dd90 Et2Dialog nonmodal WIP
Non-modal dialogs don't cover header with app tabs.
TODO: The dialog needs to be added to the app content div instead of the body
2022-12-07 09:13:46 -07:00
nathan
57993741cb Et2Dialog: Don't close dialog for buttons that are not in the footer 2022-12-06 09:44:56 -07:00
nathan
3a1c415ce4 Styling for buttons on dialog 2022-12-02 11:23:09 -07:00
nathan
72626b0dc2 Et2Dialog: Fix width property 2022-12-02 09:37:22 -07:00
nathan
dc5e0b528e Dialog work
Style changes
2022-12-01 13:02:40 -07:00
nathan
e2fc779207 Dialog work
Get tracker "Multiple changes" working
2022-12-01 11:38:02 -07:00
nathan
634e00f948 Dialog work
Get calendar quick add working again
2022-12-01 11:20:58 -07:00
nathan
83ab58329e Dialog work
- Add destroy() to remove dialog

Fixes admin ACL dialog
2022-12-01 10:24:17 -07:00
nathan
390fbf3608 Dialog work
- Switch from LionDialog to SlDialog as base
- First input should get focus
- First button gets set as primary (if no default set), Enter key will act as a click on it
- Escape key closes dialog
2022-11-30 15:59:25 -07:00
nathan
127ccdedbb Et2Dialog: Fix incorrect button adoption search 2022-11-02 08:36:44 -06:00
ralf
0ec8636a7b do NOT submit dialog, if it has no etemplate_exec_id, it only gives and error on server-side 2022-11-02 13:51:17 +01:00
nathan
2659a8ab63 Filemanager: Add copy to clipboard button to share link dialog 2022-10-28 10:05:03 -06:00
Hadi Nategh
cedaf4027c Fix navigational buttons no longer work in VfsSelect dialog 2022-10-07 14:48:20 +02:00
ralf
196024a454 stopping buttons in dialog from submitting it to server-side 2022-10-06 13:55:24 +02:00
ralf
ed05a8b6ee always need to stop button click events as otherwise the result would be submitted to server-side eT2 handler 2022-10-05 09:53:45 +02:00
nathan
b88ce18639 Fix invalid template names caused by appending cache_buster incorrectly
38721229b0
2022-08-04 16:15:04 -06:00
ralf
38721229b0 inject preprocessor and (daily) cache-buster for templates in dialog widget
also allow for a xml comment inside the deprecated menulist tag
fixes Admin ACL popup
2022-07-27 17:54:09 +02:00
nathan
aace76b97a Fix camelCased attributes didn't work for more than 1 underscore
Also fixes vfsSelect destroyed session
2022-07-25 16:12:09 -06:00
Hadi Nategh
9f363ad51c Fix importing interactjs library 2022-05-23 11:35:14 +02:00
nathan
5ed00cc435 Make dialogs resizable again 2022-05-20 11:41:09 -06:00
Hadi Nategh
c707af32b6 Add hideOnEscape and noCloseButton options into ET2Dialog 2022-04-29 14:28:43 +02:00
Hadi Nategh
36f41a9470 Handle appendTo attribute used in legacy dialog properly 2022-04-28 18:00:37 +02:00
nathan
911a2970b0 Et2Dialog: Turn on modal now that style issue is fixed 2022-04-06 15:13:51 -06:00
nathan
6120d820aa Change to Et2Dialog
- History diff
- Fix some bugs in placeholder widget
- Change load listener target, the dialog content node might have been moved out before the event gets triggered
2022-03-30 15:11:15 -06:00
nathan
bfdb53b1cf Change over some more dialogs 2022-03-30 13:24:52 -06:00
nathan
21da0b067a Get vfsSelect dialog working again 2022-03-24 13:01:41 -06:00
nathan
67dba61ef6 Et2Dialog changes
- dialog can now adopt buttons from the template.  Preferrably set slot="buttons", but it'll find them anywhere if you don't
- Reduce size & padding for non-template content
2022-03-24 11:21:32 -06:00
nathan
cdbdf53d46 Et2Dialog: Make sure value has a content before loading template, otherwise we get an error from etemplate2 2022-03-23 13:02:12 -06:00
nathan
2c92ddfe92 Et2Dialog: Fix template's DOMContainer ID still had .xet in it 2022-03-23 10:53:00 -06:00
nathan
56ed4e1267 Et2Dialog: Fix incorrect properties declaration 2022-03-22 17:19:53 -06:00
nathan
322fa3c8f4 Get nm_action dialogs working 2022-03-22 15:49:42 -06:00
nathan
b600059b68 Et2Dialog changes
- improve documentation
2022-03-21 09:52:09 -06:00
nathan
e9a381da69 Et2Dialog changes
- Set template's DOM ID so CSS can style it

This is the best way to set [minimum] dimensions, though you can set width & height on the Et2Dialog.
2022-03-21 08:46:03 -06:00
nathan
9e989596c2 Et2Dialog changes
- Fix Et2Dialog.show_prompt() incorrectly returned too much, should be just the prompt value
2022-03-18 14:40:54 -06:00
nathan
fefc822d9c Et2Dialog changes
- Fire a close event on close
- When closing, clear the template (if present)
2022-03-18 14:05:57 -06:00
nathan
255add7d98 Api: Switch from et2_dialog to Et2Dialog
Might be some I missed or can't change just yet
2022-03-17 16:18:39 -06:00
nathan
0479671ac4 Et2Dialog changes
- implement Et2Dialog.long_task()
- change to use Et2Dialog._buttons.label instead of Et2Dialog._buttons.text for better consistency
2022-03-17 15:21:15 -06:00
nathan
56571c6fc7 Et2Dialog changes
- Fix some event listeners
- Add getCompleted() promise that resolves when the dialog closes.
- Et2Dialog.alert() returns the promise directly, other static methods return the Et2Dialog to avoid breaking existing code

You can now wait for a dialog with:
Et2Dialog.show_prompt(null,"Name?").getComplete().then(([button_id,value]) => console.log(value));
or using async:
[button_id, value] = await Et2Dialog.show_prompt(null,"Name?").getComplete();
if(button_id === Et2Dialog.BUTTON_OK) {...}
2022-03-17 13:03:47 -06:00
nathan
5fdc594d00 Get templates working in Et2Dialog 2022-03-16 13:53:50 -06:00
nathan
c120f13466 Get separate egw object & some styling sorted out 2022-03-15 14:10:53 -06:00
nathan
2c1f9b2579 WIP on dialog
You can try it with
et2_dialog.show_dialog(null, "This is the message", "Title")
2022-03-14 17:07:25 -06:00