799 Commits

Author SHA1 Message Date
Stefan Sterz
f5be46bc99 fix #4001: FileBrowser: show number of items in a directory as size
Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
2022-05-15 07:47:34 +02:00
Stefan Sterz
a3faf027a1 fix #4001: FileBrowser: add menu to button and selected entry label
this commit adds a label showing the currently selected entry in the
file browser and merges the "Download .tar.zst" and "Download .zip"
button into one menu button.

Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
2022-05-15 07:47:34 +02:00
Thomas Lamprecht
49275c6726 ui: acl role selector: make wider and wrap priv column
as UX was pretty poort, one could only see one and a half privileges
of the role, the rest overflowed and was hidden. While the column
could be resized, doing so would make the role name column shrink
automatically, and it really shouldn't be required in the first
place.

This is a very important selector and all privs of a role must be
visible when opening without any manual user interaction required.

So increase the width to 500px, make the priv colum take more
relative space and enable cellWrap to avoid hidden overflow.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-05-14 14:07:08 +02:00
Thomas Lamprecht
66cc6d92b8 safe destroy: indentation fix
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-05-11 15:40:08 +02:00
Dominik Csapak
a69f23580e window/FileBrowser: try reload again when getting a 503 error
for the file restore, we return a 503 error when we were not finished
mounting a disk in the restore vm, so ignore that error and try again
(up to 10 times) so a file listing now has a "real" timeout of
up to 300 seconds (30s pveproxy timeout * 10) instead of only 30,
which should be enough for most situations.

we also increase the proxy timeout to 60 seconds, since if one has many
disks, all of them will try to load at the same time, but the browser
has a maximum request limit and will stall+queue the remaining ones. so
those will not run into the extjs timeout when we increase it here.

for older backends without the new 503 returning feature, the calls
will still run into a pveproxy timeout anyway.

we also have to reimplement the 'monStoreErrors' functionality to
get a slightly different behaviour:
we disable the default extj loadMask of the treepanel and set it
ourselves. then on 503 we leave it up, and only remove it on success
or error (for non initial loads)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-04-28 15:18:59 +02:00
Thomas Lamprecht
081b26ed59 bump version to 3.4-10
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-27 18:58:26 +02:00
Matthias Heiserer
8832b5909f apt repos: use new AltText button
text is not needed with the AltText button.

Signed-off-by: Matthias Heiserer <m.heiserer@proxmox.com>
Reviewed-by: Dominik Csapak <d.csapak@proxmox.com>
2022-04-27 14:29:54 +02:00
Matthias Heiserer
463177281c Buttons: add AltText
The same code is used once in widget toolkit and twice in PVE already,
so it makes sense to add it as a separate button.

Signed-off-by: Matthias Heiserer <m.heiserer@proxmox.com>
Reviewed-by: Dominik Csapak <d.csapak@proxmox.com>
2022-04-27 14:29:54 +02:00
Dominik Csapak
8315a64201 StatusView: fix usage calculation for fields without valid values
Sometimes, total can be zero (e.g. for swap when it's not used), which
leads to the usage being NaN. This led to the progressbar not being
updated for InfoWidgets, leaving a spurious '0%' as text.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-04-26 08:28:28 +02:00
Fabian Ebner
5c7c81d39b css: add proxmox-good-row class
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2022-04-23 10:32:25 +02:00
Thomas Lamprecht
ad772f5bc6 bump version to 3.4-9
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-14 07:57:00 +02:00
Thomas Lamprecht
3637defc27 edit window: small code style/nits
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-14 07:53:45 +02:00
Stefan Sterz
11d4f4de44 toolkit: refactor markdown based NotesView and NotesEdit
refactor them to make them more flexible and, thus, usable in pbs.
adds parameters for enabling the TBar, setting the help section in the
editing dialog and cleans up the code in some places

Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
2022-04-13 11:28:07 +02:00
Stefan Sterz
e914453239 toolkit: add NotesView panel and NotesEdit window
move them here from pve so we can maintain them across several
products

Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
[ T: also rename class/xtypes to avoid temporary breakage ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-13 11:23:47 +02:00
Thomas Lamprecht
7d602ae678 css: fix tab icon/text baseline
the baseline for the text was seriously off, the text had
(relatively) much more space below than above, which looks off for
buttons with an actual background

Instead of centering with margin/padding explicitly, do so with the
flex layout model.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-13 11:18:02 +02:00
Dominik Csapak
3b974606a6 window/FileBrowser: add optional 'tar.zst' button
only show it when enabled in config (so that we can hide it where
that is not supported, which is in PVE right now)

also changes the text between 'Download' and 'Download .zip' depending
if the selected entry is a directory or not

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2022-04-13 10:34:51 +02:00
Thomas Lamprecht
ab6ec02d93 bump version to 3.4-8
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-12 16:46:15 +02:00
Thomas Lamprecht
f77ff713db dns: increase api intervall from 1s to 10s
this is not something that changes very often, so avoid to many api
calls.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-12 16:40:37 +02:00
Thomas Lamprecht
6dce03cf5a dns/time: small refactorings, style
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-12 16:40:12 +02:00
Thomas Lamprecht
38e653f14b object grid: call rendere with our scope
having window as this scope has zero benefits and while one could
already try to get the local scope via some Ext.ComponentQuery query
its just nicer to have it easily available.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-12 16:36:53 +02:00
Thomas Lamprecht
563cf87d59 icons: switch cpu/ram bitmaps to svg
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-01 10:35:50 +02:00
Dominik Csapak
01a79a9781 form: combo grid: fix selection after filtering
firing 'refresh' in 'clearLocalFilter' was wrong, since that triggers
too often, for example when selecting an entry (since the field lost
focus). This lead to the picker refreshing and not registering the
click and thus not selecting the desired entry.

Instead refresh the view when we really need it: when the picker is shown.
The filter is already gone, but the picker grid does not know this yet,
so we fire the event then.

Fixes: 7e47328 ("Combogrid: clear filter on blur")

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-03-29 17:49:15 +02:00
Thomas Lamprecht
04070ce5b1 node: task filter: code style
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-03-29 17:48:13 +02:00
Dominik Csapak
64c1d6191c node/Tasks: don't count 'preFilters' as normal filters
they can not be removed nor are they visible, so don't count them.

When having a prefilter, we now don't show anymore that there is an
active filter, and don't enable the button anymore.
This is the case for vms for example (vmid is a prefilter).

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-03-29 17:42:25 +02:00
Thomas Lamprecht
96fb7eaacd utils: add inline comment about cookie set-for-clear
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-03-18 15:58:53 +01:00
Dominik Csapak
c1a3584103 utils: clear cookies with secure flag set
otherwise firefox complains with a deprecation warning that the secure-flag
is not set but SameSite to 'None'. Since we cannot know how firefox will
behave once that behaviour is no longer supported, add the secure flag
now.

Note: ExtJS also clears by setting the cookie with an empty value,
there's no browser supported clear api.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-03-18 15:56:20 +01:00
Thomas Lamprecht
9716d0def1 add EOL notice component
to avoid copying the same thing to three different product's GUIs
this year..

cherry-picked from stable-6 as we can have this in the master branch
full time

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-03-16 08:23:05 +01:00
Thomas Lamprecht
b33a25589c form: combo grid: fix whitespace/indendation and refactor slightly
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-03-16 07:46:10 +01:00
Matthias Heiserer
7e47328692 Combogrid: clear filter on blur
Previously, deselecting and reselecting the input field
led to the previous filter still being applied, although the
input field was cleared.

Signed-off-by: Matthias Heiserer <m.heiserer@proxmox.com>
2022-03-15 11:03:20 +01:00
Thomas Lamprecht
6971ce9d6b log view: comment length fixup
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-03-04 14:54:59 +01:00
Dominik Csapak
80ea69b416 fix #3919: log view: show first task output line correctly
if a task did not produce output yet, we always get a single line
with "no output". our heuristic in the gui counts the total lines +
the current  position. so to update the first output correctly, we
have to update every time in case we only have one line.

Otherwise, we only update on the second line, which is bad
in case the only line we ever get is the result.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-03-04 14:54:21 +01:00
Thomas Lamprecht
4fecfeef70 toolkit: add comment regarding upstream changes
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-23 13:02:59 +01:00
Thomas Lamprecht
c39864ee29 bump version to 3.4-7
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-23 12:14:13 +01:00
Dominik Csapak
da24e83f64 fix drag&drop for pointerType 'pen'
some devices (e.g. vms via novnc, and some laptops) get the pointerType
'pen' under chromium.

the DragZone handler tries to ignore touch input for that by
checking for "=== 'mouse'" which does not include 'pen'
so override that to handle it when the pointerType !== 'touch'

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-02-23 12:14:13 +01:00
Thomas Lamprecht
4f5e2bd12b edit window: make response handling code path more robust
A 2xx error code doesn't necessarily mean we got data we can
dereference

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-16 07:58:27 +01:00
Thomas Lamprecht
bfc6233d92 tfa view: fix WebAuthn casing
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-16 07:57:43 +01:00
Thomas Lamprecht
67b0280dba bump version to 3.4-6
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-14 11:34:45 +01:00
Thomas Lamprecht
017a637682 tree-wide typo fixes
found with `codespell`, mostly comments but also a fn parameter and
an error in an exception message

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-14 11:28:29 +01:00
Thomas Lamprecht
45a670a4ae d/changelog: fix typos in historic entries
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-02-14 11:22:38 +01:00
Matthias Heiserer
aca2ab3cb2 edit: fix comment typos
Signed-off-by: Matthias Heiserer <m.heiserer@proxmox.com>
2022-02-14 11:21:41 +01:00
Fabian Ebner
1025802ef1 sorters: use correct property 'direction' and keep default 'ASC'
Ext.util.Sorter does not have an 'order' property, so 'order: DESC'
didn't have an effect. The default is 'ASC' and it is arguably the
preferred direction for realm anyways.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2022-02-10 13:56:33 +01:00
Matthias Heiserer
e06715d2e5 utils: render default value correctly 2022-02-10 13:08:11 +01:00
Thomas Lamprecht
0b73467346 bump version to 3.4-5
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-01-13 12:53:42 +01:00
Fabian Ebner
cd7e37fa95 window: safe destroy: make note more visible
by not using a smaller font size and using the pmx-hint class. Also
don't align to the middle, as everything else is left-aligned.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2022-01-13 12:53:42 +01:00
Fabian Ebner
79580cd0b6 zfs detail: hide the pool itself in tree view
and show the overall health in the grid instead.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2022-01-13 12:50:49 +01:00
Fabian Ebner
a18a674d51 zfs detail: increase window height
If there are mirrors and log/special vdevs it just feels too small.
It also doesn't help if there are errors in the upper part taking up
space. Make it 600, which was used in PVE before.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2022-01-13 12:50:49 +01:00
Thomas Lamprecht
c4ac6d1c14 toolkit: fix noisy ext warning of feature we do not want/use
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-12-10 13:23:02 +01:00
Wolfgang Bumiller
834cc8476d improve error handling when adding webauthn entries
There are cases where we directly throw a string error
(particularly, when navigator.credentials.create() fails,
for example when trying to register the same WA device to
the same user twice), which would end up with the WA window
simply not closing before.

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2021-12-02 19:19:31 +01:00
Thomas Lamprecht
d739e44117 tfa login: hide u2f and yubico-otp if not available
Else it may be to confusing for users to see TFA types they cannot
configure anymore (or never could, in the PBS/PMG case).

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-11-29 17:19:58 +01:00
Thomas Lamprecht
ca867fb10d bump version to 3.4-4
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-11-24 18:29:59 +01:00