Johannes Meyer
3464455021
js: Preserve scroll position if focus is forced to a particular element
2020-01-16 15:54:17 +01:00
Johannes Meyer
8bc84a5f9e
js: Teach the url parsing a final lesson about query strings
...
`utils.parseParams()` now returns an array instead of an object.
This may require some changes in modules using this directly or
by `utils.parseUrl().params`
refs #4056
2020-01-16 13:45:10 +01:00
Johannes Meyer
844cb911a4
loader.js: Use `utils.addUrlFlag` instead of the now deprecated one
2020-01-15 08:00:04 +01:00
Eric Lippmann
7f8ee4f94d
JS: Deprecate Icinga.Loader.addUrlFlag() in favor of Icinga.Utils.addUrlFlag()
2020-01-14 14:58:34 +01:00
ValeDaRold
5edd267f2a
Refresh container if X-Icinga-Extra-Updates with length 1 is defined ( #3970 )
...
* Refresh container if X-Icinga-Extra-Updates with length 1 is defined
2019-12-12 13:50:03 +01:00
Johannes Meyer
d6677bfb66
loader.js: Also preserve scroll position of `display:flex` containers
2019-12-11 15:27:03 +01:00
Johannes Meyer
55b9b44be9
js: Fix error when focusing navigation anchors
2019-12-11 09:27:18 +01:00
Johannes Meyer
4af48c797d
js: Remove `ui.fixControls()` and `ui.initializeControls()`
...
Hooray!
2019-12-06 15:39:14 +01:00
Johannes Meyer
48098a2830
js: Don't initialize modules using a `beforerender` event
...
`beforerender` is already too late. Module initialization
done using an event handler is wrong anyway. It's some
kind of bootstrapping after all and should be performed
by parts of the code which is directly responsible for
DOM content handling of modules. (i.e. loader.js)
This change though introduces a side-effect which was
not the case previously: Nested `.container` elements
trigger `rendered` events now. I've introduced this to
ensure we're also lazy loading modules and let them
handle their `rendered` events right after a redirect
which rerendered the layout. (Only `#layout` got a
`rendered` event then prior to this change)
2019-11-21 09:55:20 +01:00
Johannes Meyer
5f739deea3
loader.js: Enhance __BACK__ handling
2019-11-05 15:04:23 +01:00
Johannes Meyer
da565f4d16
loader.js: Refresh left twice in case right has been closed..
...
..if the redirect target is `__BACK__`
2019-11-04 17:25:05 +01:00
Johannes Meyer
42e596f457
loader.js: Navigate back if redirect target is `__BACK__`
2019-11-04 16:03:54 +01:00
Johannes Meyer
c0cac6fe3c
loader.js: Allow to use a separate target for redirections
2019-11-04 12:46:30 +01:00
Johannes Meyer
0e5e046ae5
js: Split event handling and processing of form submits
2019-11-04 12:46:30 +01:00
Johannes Meyer
50bf126d36
js: Move function events.getLinkTargetFor to loader.js
2019-11-04 12:46:30 +01:00
Johannes Meyer
2896cbd781
loader.js: Avoid named capture groups to parse multipart content
...
fixes #3975
2019-10-07 14:35:49 +02:00
Johannes Meyer
a8dc609b62
loader.js: Add support for multipart content
...
refs #3953
2019-09-25 10:34:24 +02:00
Johannes Meyer
dda49b5ff1
loader.js: Drop redundant method `cacheLoadedIcons`
2019-09-25 10:34:24 +02:00
Johannes Meyer
da513a746d
loader.js: Add support for extra updates
...
refs #3953
2019-09-25 10:34:24 +02:00
Johannes Meyer
b15c012671
loader.js: Only pre-wrap a search response's html with a div
...
It's not required for all responses anymore.
refs #3953
2019-09-25 10:34:24 +02:00
Johannes Meyer
f98f988aff
Remove tristate form element
2019-09-23 08:36:24 +02:00
Johannes Meyer
5333bbf04d
loader.js: Also set title directly if layout is base target
2019-08-02 15:42:58 +02:00
Johannes Meyer
b168c3d7db
js: Don't use jquery.focus shorthand anymore, but icinga.ui.focusElement
2019-07-18 07:57:14 +02:00
Johannes Meyer
6323a065ea
loader.js: Keep using the promise interface for complete callbacks
2019-07-18 07:57:14 +02:00
Johannes Meyer
5cf71c9bbd
js: Drop iframe-upload fallback for IE
2019-07-18 07:57:14 +02:00
Jennifer Mourek
f6a5f952bb
loader.js: Remove comment
2019-07-18 07:56:09 +02:00
Florian Strohmaier
5fe264be6a
JS: Fix errors
...
refs #3813
2019-07-18 07:56:09 +02:00
Johannes Meyer
f6d40a9d1c
loader.js: Directly set the window's title for full layout requests
...
refs #3851
2019-07-15 08:24:44 +02:00
Johannes Meyer
43c87d2388
loader.js: Return in onComplete upon handled redirects
...
Got changed with f12a5741b8
. Triggering
rendered events for stuff that's never displayed doesn't seem right.
2019-04-30 09:23:59 +02:00
Johannes Meyer
f72aa291bc
Merge pull request #3610 from Icinga/fix/window-id-cannot-be-used-to-differentiate-containers-3609
...
Fix window id cannot be used to differentiate containers
2019-04-17 11:38:48 +02:00
Johannes Meyer
4900040d47
js: Restore previous title when closing right column
...
fixes #3654
2019-04-16 09:29:42 +02:00
Johannes Meyer
d8c4fcc517
Merge pull request #3661 from Icinga/feature/preserve-scroll-position-upon-form-submits
...
Preserve scroll position upon form submits
2019-04-16 08:04:15 +02:00
Johannes Meyer
cb3528a7be
js: Don't scroll to re-focused elements after auto-refreshes
...
refs #2048
refs #3295
refs #3492
refs #3518
2019-04-15 15:42:14 +02:00
Johannes Meyer
f54f2f8627
js: Prevent flickering when refreshing scrolled content
2019-04-15 14:27:14 +02:00
Eric Lippmann
915c7b8fe5
Merge pull request #3504 from Icinga/fix/collapsible-sidebar-issues-3187
...
Fix collapsible sidebar issues
2019-03-21 09:09:27 +01:00
Jennifer Mourek
b3b80fdc31
Make active first-level nav items better distinguishable
2019-03-20 11:07:39 +01:00
Johannes Meyer
27569d09d8
loader.js: Preserve scroll position also for form submits
...
Restores the scroll position if:
* it's been a POST request
* the source and target url path is the same
* the target's url params do not change significantly
2019-01-10 15:32:28 +01:00
Johannes Meyer
d2214ef0e4
loader.js: Pass-through previous request when peforming a redirection
2019-01-10 15:31:39 +01:00
Johannes Meyer
29a8184548
loader.js: Remember a request's method
2019-01-10 15:30:48 +01:00
Johannes Meyer
c8a49414b1
js: Append a unique container id to the Window-Id
...
Generates a semi-random id for containers other than the menu and col1.
This id is then appended to the Window-Id of every request separated by
an underscore: `window-id_container-id`
refs #3609
2018-11-07 12:44:25 +01:00
Johannes Meyer
5f4aa1e296
loader.js: Make anchor navigation working again
...
fixes #3492
2018-07-10 10:50:31 +02:00
Johannes Meyer
990df95f36
loader.js: Allow to force HTTP to be used for JS redirection
2018-07-04 14:44:03 +02:00
Johannes Meyer
9857021d2c
Revert "loader.js: place focus at the end of text inputs"
...
This reverts commit d1fd7e4be7
.
Browsers seem to do this on their own natively. Way better.
refs #3348
2018-04-24 11:18:10 +02:00
Alexander A. Klimov
68870ca411
Icinga.Loader.prototype.renderContentToContainer(): preserve scroll position despite the focus
2018-01-19 15:32:54 +01:00
Eric Lippmann
cb83a7dea3
JS: Always request application-state
...
Icinga Web 2 version 2.5.0 suspends auto-refresh if the tab is inactive.
This also pauses the application-state requests which are intended to refresh the session and announcements.
If a tab is inactive for longer than the PHP session timeout (session.gc_maxlifetime in php.ini), users are automatically logged out.
With this patch Web 2 will always request application-state. Even if auto-refresh is disabled.
2017-12-04 14:25:23 +01:00
Jennifer Mourek
3a8ba39abd
Disable auto-refresh when page is not visible
...
credits to @towolf
Icinga offers the user to enable or disable 'auto-refresh' with a
static preference.
But 'auto-refresh' is the default and our users often have dozens of
Icinga tabs open in their browser, which they are not looking at.
The background tabs lead to significant load on the database to to
repeated queries to keep the invisible UI fresh.
This change adds a visibility listener, which disables auto-refresh when the
page is not visible.
refs #2761
2017-10-26 13:53:25 +02:00
Eric Lippmann
e030229d7f
Fix CSS issues when rerendering the layout
...
fixes #13467
2016-12-12 15:02:51 +01:00
Eric Lippmann
39c7451664
Implement announcements
...
refs #11198
2016-11-29 15:24:34 +01:00
Eric Lippmann
875d42c0a6
Revert "Merge branch 'bugfix/always-use-the-jquery-find-method-w/-node-context-10704'"
...
This reverts commit f517c62fde
, reversing
changes made to d1fd7e4be7
.
refs #10704
2016-11-21 14:34:58 +01:00
Eric Lippmann
f517c62fde
Merge branch 'bugfix/always-use-the-jquery-find-method-w/-node-context-10704'
...
fixes #10704
2016-11-21 14:33:43 +01:00