]> git.proxmox.com Git - flutter/pve_flutter_frontend.git/log
flutter/pve_flutter_frontend.git
5 days agowelcome screen: increase dot-indicators slightly in size master
Thomas Lamprecht [Wed, 17 Apr 2024 18:36:20 +0000 (20:36 +0200)]
welcome screen: increase dot-indicators slightly in size

to make it slighlty easier to touch them

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agore-bump version to 1.8.0
Thomas Lamprecht [Wed, 17 Apr 2024 18:15:41 +0000 (20:15 +0200)]
re-bump version to 1.8.0

previous one did not yet released yet, so just bump the internal
version.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agowidgets: use colored safe-area to keep status bar color intact
Thomas Lamprecht [Wed, 17 Apr 2024 18:13:26 +0000 (20:13 +0200)]
widgets: use colored safe-area to keep status bar color intact

Decided to check all SafeArea's here after the previous commit and
found that most of them cause some breakage w.r.t. system status bar
coloring, so replace the problematic ones with the new
ColoredSafeArea widget.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agomain layout: use colored safe-area for resource view
Thomas Lamprecht [Wed, 17 Apr 2024 18:02:07 +0000 (20:02 +0200)]
main layout: use colored safe-area for resource view

This restores correct status bar coloring again, which broke when
introducing the SafeArea.

Fixes: 453eb81 ("put resource filter sheet into a SafeArea")
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agowidges: add ColoredSafeArea
Thomas Lamprecht [Wed, 17 Apr 2024 17:59:51 +0000 (19:59 +0200)]
widges: add ColoredSafeArea

We have a few SafeArea uses in cases where they interfere with
coloring, breaking the status bar color for example.

Add a a thin wrapper around SafeArea that wraps it inside a container
with a color so that the coloring of upper app/system layers is kept
intact.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agobump version to 1.8.0
Thomas Lamprecht [Wed, 17 Apr 2024 14:34:13 +0000 (16:34 +0200)]
bump version to 1.8.0

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agonode: power options: rework prompt title and text
Thomas Lamprecht [Wed, 17 Apr 2024 13:32:46 +0000 (15:32 +0200)]
node: power options: rework prompt title and text

Avoid some rather odd "to do action '...'" wording and try to better
follow the examples of material design style guide, as mentioned in
the previous commit, and convey the implications of the action.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agonode overview: power menu: reorder/reword confirm buttons
Dominik Csapak [Wed, 17 Apr 2024 08:53:02 +0000 (10:53 +0200)]
node overview: power menu: reorder/reword confirm buttons

Move the confirmation button to the right as mentioned in the
material spec [0], and reword the buttons to spell out the action,
i.e., 'cancel' and 'shutdown' or 'reboot', respectively.
For that to work properly, slightly rename the confirmation message.

0: https://m3.material.io/components/dialogs/guidelines#befd7f4d-1029-4957-b1b5-da13fc0bbf3c

Suggested-by: Folke Gleumes <f.gleumes@proxmox.com>
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
 [ TL: captialize action text in method automatically ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 days agoupgrade flutter_inappwebview to 6.0
Thomas Lamprecht [Wed, 17 Apr 2024 08:06:48 +0000 (10:06 +0200)]
upgrade flutter_inappwebview to 6.0

only need to change the two URL's to the inappwebview's internal
WebUri type.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
6 days agobloc: guest overview: add type to config-field variable
Thomas Lamprecht [Wed, 17 Apr 2024 07:47:21 +0000 (09:47 +0200)]
bloc: guest overview: add type to config-field variable

to satify the prefer_typing_uninitialized_variables lint

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
6 days agotree-wide: check if build context is still valid after async call
Thomas Lamprecht [Wed, 17 Apr 2024 07:40:49 +0000 (09:40 +0200)]
tree-wide: check if build context is still valid after async call

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
6 days agotree-wide: drop unnecessary containers
Thomas Lamprecht [Wed, 17 Apr 2024 07:31:17 +0000 (09:31 +0200)]
tree-wide: drop unnecessary containers

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
6 days ago404 pages: fix some linter nits
Thomas Lamprecht [Wed, 17 Apr 2024 07:17:06 +0000 (09:17 +0200)]
404 pages: fix some linter nits

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
6 days agonode power widget: readabillity & style clean-ups
Thomas Lamprecht [Wed, 17 Apr 2024 07:11:27 +0000 (09:11 +0200)]
node power widget: readabillity & style clean-ups

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
6 days agonode overview: add power settings menu
Dominik Csapak [Wed, 17 Apr 2024 06:45:46 +0000 (08:45 +0200)]
node overview: add power settings menu

similar to how it works for qemu, but add a confirmation dialog
so one does not accidentally shutdown or reboot a node.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
6 days agoimprove back button behavior
Dominik Csapak [Mon, 15 Apr 2024 10:30:27 +0000 (12:30 +0200)]
improve back button behavior

by using 'SystemNavigator.pop()' on the top level page when pressing the
back button. On Android this minimizes/closes the app an presents
whatever was shown before.

This fixes an issue where we would show a blank screen when pressing the
back button on the dashboard.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
6 days agonode overview: use correct color for rrd icons
Dominik Csapak [Mon, 15 Apr 2024 10:30:25 +0000 (12:30 +0200)]
node overview: use correct color for rrd icons

same as the guests use for that.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
6 days agoconsole: use flutter inappwebview as webview
Dominik Csapak [Mon, 15 Apr 2024 10:30:23 +0000 (12:30 +0200)]
console: use flutter inappwebview as webview

instead of flutter webview. This new dependency does not have the
limitations of the "official" flutter webview. We now can ignore
https errors and even get some info on the certificate.

We use that to now show a 'do you want to trust this cert' dialog with
the fingerprint of the server, which the user can then either trust or
abort.

When pressing yes, we save that fingerprint in the shared preferences so
that we don't have to ask the next time.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
6 days agonode overview: relay if updates could not be queried due to permissions
Thomas Lamprecht [Tue, 16 Apr 2024 14:11:25 +0000 (16:11 +0200)]
node overview: relay if updates could not be queried due to permissions

While this is an edge case (most users connect via root or a user
holding powerful admin rights over all) it still better to avoid
suggesting that there are no updates available if the user cannot
query them due to lacking the Sys.Modify permissions on the node.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
7 days agotask log list: make warning icon more distinct
Dominik Csapak [Fri, 12 Apr 2024 08:04:58 +0000 (10:04 +0200)]
task log list: make warning icon more distinct

by making it rounded (which appears as 'less dangerous').
Sadly the 'error' icon is not really usable for us, since it looks
almost the same as the 'info' icon (just 180 degree rotated).

We could use an 'outline' variant for either, but making the 'less
dangerous' one rounded feels alright.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agotask logs: use separate color for warnings
Dominik Csapak [Fri, 12 Apr 2024 08:04:57 +0000 (10:04 +0200)]
task logs: use separate color for warnings

orange instead of red, so one can differentiate between error and
warnings better.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agotask logs: don't always say 'Last Task: '
Dominik Csapak [Fri, 12 Apr 2024 08:04:56 +0000 (10:04 +0200)]
task logs: don't always say 'Last Task: '

only put that when we show the last task, which is only when we show the
'more tasks' button. Make the title otherwise just 'Task: '

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agoset the color of the template indicator to that of the icon
Dominik Csapak [Fri, 12 Apr 2024 08:04:55 +0000 (10:04 +0200)]
set the color of the template indicator to that of the icon

otherwise we have a grey icon but black template indicator, which looks
a bit out of place.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agofix clipping for data card widget
Dominik Csapak [Fri, 12 Apr 2024 08:04:54 +0000 (10:04 +0200)]
fix clipping for data card widget

since cards now have a very rounded corner, one can see the non clipped
shape of the contained ExpansionTile.

To fix that, make the shape a RoundedRectangleBorder (which also removes
the added top/bottom border on expansion) and set the clipBehavior of
the surrounding card to antiAlias.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agoadapt to material 3 changes for themes
Dominik Csapak [Fri, 12 Apr 2024 08:04:53 +0000 (10:04 +0200)]
adapt to material 3 changes for themes

it's recommended to use fromSeed with what was the primary color
beforehand. With this, all colors are correctly deduced from it (e.g.
outline colors etc.).

But since we then set primaryContainer, we also have to set
onPrimaryContainer, otherwise it's deduced from the original primaryContainer
color that would have been generated.

this fixes the issue of the overly stark contrast of the divider color (which
uses the outline color).

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agonode overview: don't throw permission errors on every update
Dominik Csapak [Fri, 12 Apr 2024 08:04:52 +0000 (10:04 +0200)]
node overview: don't throw permission errors on every update

getting the apt update status requires Sys.Modify, but the user does not
necessarily has that. So instead of showing a pop up every 10 seconds,
simply ignore permission errors and only show other exceptions here.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agoresource tab: improve colors for headers
Dominik Csapak [Fri, 12 Apr 2024 08:04:51 +0000 (10:04 +0200)]
resource tab: improve colors for headers

since material 3, the colors are different, and there is no 'muted'
color for the unselected labels anymore. instead use secondary for the
selected, and onPrimary for the unselected ones.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
7 days agoreplace BottomNavigationBar with NavigationBar
Dominik Csapak [Fri, 12 Apr 2024 08:04:50 +0000 (10:04 +0200)]
replace BottomNavigationBar with NavigationBar

it has proper material 3 styling. For the animations to work correctly,
we have to put the bar outside of the part that we replace when we
navigate though

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 days agowidgets: node overview: style-fix missing braces in else-if
Thomas Lamprecht [Thu, 11 Apr 2024 10:55:21 +0000 (12:55 +0200)]
widgets: node overview: style-fix missing braces in else-if

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoutils: dot indicator: fix context param name
Thomas Lamprecht [Thu, 11 Apr 2024 10:52:54 +0000 (12:52 +0200)]
utils: dot indicator: fix context param name

was used but still slightly confusing and the linter complained

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoline chart: drop dead code for unrealisitc Y-axis overflow
Thomas Lamprecht [Thu, 11 Apr 2024 10:50:53 +0000 (12:50 +0200)]
line chart: drop dead code for unrealisitc Y-axis overflow

it was never active for the last releases so just drop that, it's
still in git if we actually require it some day.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoadd analysis options for linter
Thomas Lamprecht [Thu, 11 Apr 2024 10:41:26 +0000 (12:41 +0200)]
add analysis options for linter

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotask logs: crudely handle warnings
Thomas Lamprecht [Thu, 11 Apr 2024 10:39:44 +0000 (12:39 +0200)]
task logs: crudely handle warnings

needs some more thoughs and probably rework of the whole coloring
here, probably using more from the (dynamic) theme instead.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agorenderer: fix using fallback for support level
Thomas Lamprecht [Thu, 11 Apr 2024 10:39:28 +0000 (12:39 +0200)]
renderer: fix using fallback for support level

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: fix various dead code statements
Thomas Lamprecht [Thu, 11 Apr 2024 10:38:24 +0000 (12:38 +0200)]
tree-wide: fix various dead code statements

mostly 'break' statements being useless if the code returns in that
branch anyway.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agourl launch: rework launching URL
Thomas Lamprecht [Thu, 11 Apr 2024 09:52:26 +0000 (11:52 +0200)]
url launch: rework launching URL

Switch deprecated launch with launchUrl and move over the try-launch
helper to a new module with a better name.
Add our static links there too for easier access where needed.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agofont awesome icons: replace depracated variants with new ones
Thomas Lamprecht [Thu, 11 Apr 2024 09:48:13 +0000 (11:48 +0200)]
font awesome icons: replace depracated variants with new ones

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agomain layout: replace depreacated WillPopScope with PopScope
Thomas Lamprecht [Thu, 11 Apr 2024 09:43:13 +0000 (11:43 +0200)]
main layout: replace depreacated WillPopScope with PopScope

We use this to handle back navigation for our bottom navigation
drawer manually, something which we might want to revisit in the
future in general, but for now just replace this with a
non-depreacted variant.

There set canPop to false to disable the auto-pop of the framework
and handle popping then manually.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotheme: drop checkbox/radiogroup related overrides
Thomas Lamprecht [Thu, 11 Apr 2024 09:18:23 +0000 (11:18 +0200)]
theme: drop checkbox/radiogroup related overrides

they got added automatically by dart fix but actually make it worse
as with that one cannot see the inner check-mark or dot if a
box/radio toggle is checked/on, so just drop that whole thing again.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: auto-fix all smaller lints
Thomas Lamprecht [Thu, 11 Apr 2024 08:45:27 +0000 (10:45 +0200)]
tree-wide: auto-fix all smaller lints

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoresource list: fix fallback for unknown resource types
Thomas Lamprecht [Thu, 11 Apr 2024 08:46:42 +0000 (10:46 +0200)]
resource list: fix fallback for unknown resource types

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotask log: show duration correctly for running tasks
Thomas Lamprecht [Thu, 11 Apr 2024 08:46:58 +0000 (10:46 +0200)]
task log: show duration correctly for running tasks

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotask log: fallback to empty list if no tasks returned
Thomas Lamprecht [Thu, 11 Apr 2024 08:45:58 +0000 (10:45 +0200)]
task log: fallback to empty list if no tasks returned

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: prefer sized box for whitespace
Thomas Lamprecht [Thu, 11 Apr 2024 08:04:04 +0000 (10:04 +0200)]
tree-wide: prefer sized box for whitespace

Similar to the change in the login manager package. Container are
much heavier w.r.t. performance impact, as per the
sized_box_for_whitespace lint.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: prefer const declarations and constructors, avoid null in if-null
Thomas Lamprecht [Thu, 11 Apr 2024 07:58:29 +0000 (09:58 +0200)]
tree-wide: prefer const declarations and constructors, avoid null in if-null

Adapted using `dart fix --code` with following lints:
- prefer_const_constructors
- prefer_const_declarations
- unnecessary_null_in_if_null_operators

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoRevert "tree-wide: avoid using private types in public APIs for State"
Thomas Lamprecht [Thu, 11 Apr 2024 06:08:03 +0000 (08:08 +0200)]
Revert "tree-wide: avoid using private types in public APIs for State"

This reverts commit d9798fb108c1a783b5115f2f781779c91c666f66.

11 days agotree-wide: avoid using private types in public APIs for State
Thomas Lamprecht [Thu, 11 Apr 2024 05:37:55 +0000 (07:37 +0200)]
tree-wide: avoid using private types in public APIs for State

Adapt to more modern style for getting the State type via public
interfaces only, like documented:

https://api.flutter.dev/flutter/widgets/StatefulWidget/createState.html

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: drop unnecessary null comparions
Thomas Lamprecht [Wed, 10 Apr 2024 11:08:26 +0000 (13:08 +0200)]
tree-wide: drop unnecessary null comparions

Feels a bit scary but dart and nullaware should have us coverred, at
least if the code has the invariants correct.

Changed using: dart fix --apply --code=unnecessary_null_comparison
Best viewed with white-space changes ignored.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: avoid unused imports
Thomas Lamprecht [Wed, 10 Apr 2024 06:42:10 +0000 (08:42 +0200)]
tree-wide: avoid unused imports

fixed using: dart fix --apply --code=unused_import

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agonetwork bridge selector: cope with null value
Thomas Lamprecht [Wed, 10 Apr 2024 06:41:05 +0000 (08:41 +0200)]
network bridge selector: cope with null value

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agofix widget test
Thomas Lamprecht [Wed, 10 Apr 2024 06:40:38 +0000 (08:40 +0200)]
fix widget test

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: various smaller auto-lint fixes
Thomas Lamprecht [Wed, 10 Apr 2024 06:27:12 +0000 (08:27 +0200)]
tree-wide: various smaller auto-lint fixes

using `dart fix --apply` with the following codes:
- prefer_interpolation_to_compose_strings
- unnecessary_new
- use_super_parameters
- sort_child_properties_last
- unnecessary_string_interpolations
- use_key_in_widget_constructors
- curly_braces_in_flow_control_structures
- prefer_const_constructors_in_immutables
- invalid_null_aware_operator

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: switch depreacted member use to new ones
Thomas Lamprecht [Wed, 10 Apr 2024 06:23:34 +0000 (08:23 +0200)]
tree-wide: switch depreacted member use to new ones

using: dart fix --apply --code=deprecated_member_use

The biggest one is the toggleableActiveColor property having been
deprecated [0].

[0]: https://docs.flutter.dev/release/breaking-changes/toggleable-active-color

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: dart format
Thomas Lamprecht [Wed, 10 Apr 2024 06:23:05 +0000 (08:23 +0200)]
tree-wide: dart format

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agotree-wide: prefer const constructors
Thomas Lamprecht [Wed, 10 Apr 2024 06:20:56 +0000 (08:20 +0200)]
tree-wide: prefer const constructors

change made through:
dart fix --apply --code=prefer_const_constructors

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agonodes: overview: switch to updated camelCase name for disk wearout percentage
Thomas Lamprecht [Wed, 10 Apr 2024 06:08:01 +0000 (08:08 +0200)]
nodes: overview: switch to updated camelCase name for disk wearout percentage

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoutils: update coding style to set default value for dot indicator
Thomas Lamprecht [Wed, 10 Apr 2024 06:06:58 +0000 (08:06 +0200)]
utils: update coding style to set default value for dot indicator

Assigning the default value through a colon is not allowed in dart 3
anymore.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agostates: make base state a full mixin
Thomas Lamprecht [Wed, 10 Apr 2024 06:05:00 +0000 (08:05 +0200)]
states: make base state a full mixin

we only use it as that and as dart 3 disallows using regular classes
as mixings this is required for the upgrade.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoandroid: drop buildscript in favor of native plugin definition
Thomas Lamprecht [Wed, 10 Apr 2024 05:44:29 +0000 (07:44 +0200)]
android: drop buildscript in favor of native plugin definition

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoandroid: target and compile with sdk 34 (Android 14)
Thomas Lamprecht [Wed, 3 Apr 2024 06:21:18 +0000 (08:21 +0200)]
android: target and compile with sdk 34 (Android 14)

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoaccess control view: fix label color of selected tabs
Thomas Lamprecht [Tue, 2 Apr 2024 14:55:10 +0000 (16:55 +0200)]
access control view: fix label color of selected tabs

avoid that selected tabs have the same foreground and background
colors, making the label text and icon invisible.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agopubspec: mark as not for publishing
Thomas Lamprecht [Thu, 11 Apr 2024 10:25:53 +0000 (12:25 +0200)]
pubspec: mark as not for publishing

at least not on pub.dev

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agopubspec: record missing shared_preferences dependency
Thomas Lamprecht [Thu, 11 Apr 2024 08:49:03 +0000 (10:49 +0200)]
pubspec: record missing shared_preferences dependency

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 days agoupgrade to dart 3.0 as baseline
Thomas Lamprecht [Thu, 11 Apr 2024 08:48:13 +0000 (10:48 +0200)]
upgrade to dart 3.0 as baseline

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2 weeks agoupdate dependencies and adapt to breaking changes and material 3
Thomas Lamprecht [Tue, 2 Apr 2024 14:53:45 +0000 (16:53 +0200)]
update dependencies and adapt to breaking changes and material 3

Adapt the theme color variables to the new names of Material Design 3
[0], and the text button styles to the styleFrom property changes
[1].

[0]: https://docs.flutter.dev/release/breaking-changes/material-3-migration
[1]: https://docs.flutter.dev/release/breaking-changes/3-16-deprecations#button-stylefrom-properties

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 months agobump version to 1.7.2+43
Thomas Lamprecht [Wed, 5 Jul 2023 10:21:44 +0000 (12:21 +0200)]
bump version to 1.7.2+43

- tfa: use number input-type keyboard for TOTP.
- tfa form: avoid glitches where submit button was sometimes
  partially off-screen.
- avoid error when trying to submit empty origin via the keyboard's
  enter button.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 months agoupdate metadata and build system to current flutter create
Thomas Lamprecht [Wed, 5 Jul 2023 10:19:17 +0000 (12:19 +0200)]
update metadata and build system to current flutter create

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 months agobump version to 1.7.1+42
Thomas Lamprecht [Tue, 4 Jul 2023 15:30:56 +0000 (17:30 +0200)]
bump version to 1.7.1+42

- build with flutter 3.10
- fix #4749: correctly show lxc rrd data
- saved login: don't give outdated ticket to login form
- tfa: allow closing tfa form without glitchy error

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 months agoupdate biometric storage to 5.0
Thomas Lamprecht [Tue, 4 Jul 2023 15:35:07 +0000 (17:35 +0200)]
update biometric storage to 5.0

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 months agoupgrade to flutter 3.10 with dart 3.0 as baseline
Thomas Lamprecht [Tue, 4 Jul 2023 15:26:13 +0000 (17:26 +0200)]
upgrade to flutter 3.10 with dart 3.0 as baseline

upgrade all dependencies while at it, most of them are required for
dart 3 compat anyway

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 months agofix #4749: correctly show lxc rrd data
Dominik Csapak [Tue, 4 Jul 2023 13:53:50 +0000 (15:53 +0200)]
fix #4749: correctly show lxc rrd data

like we do for qemu guest, by multiplying cpu usage by 100

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
9 months agoremove package_info_plus dependency
Dominik Csapak [Tue, 4 Jul 2023 12:20:32 +0000 (14:20 +0200)]
remove package_info_plus dependency

we only used it in one widget that was itself unused and trivial.
Also the version we depended on was outdated and not compatible with
dart 3.0

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
9 months agobump version to 1.7.0+41
Thomas Lamprecht [Tue, 4 Jul 2023 08:39:44 +0000 (10:39 +0200)]
bump version to 1.7.0+41

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agobump version to 1.6.1+40
Dominik Csapak [Tue, 2 May 2023 10:50:10 +0000 (12:50 +0200)]
bump version to 1.6.1+40

rebuild with newer proxmox_login_manager to fix saved password
handling with expired ticket

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agobump version to 1.6.1+39
Dominik Csapak [Fri, 28 Apr 2023 11:52:37 +0000 (13:52 +0200)]
bump version to 1.6.1+39

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agoconsole: fix first load
Dominik Csapak [Fri, 28 Apr 2023 11:19:24 +0000 (13:19 +0200)]
console: fix first load

if we don't wait for the cookie manager to set the cookie before
calling loadRequest, the first time the user gets a CSRFToken error

moving the loadRequest into the build method of the FutureBuilder
prevents that from happening.

Reported-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Reported-by: Aaron Lauterer <a.lauterer@proxmox.com>
Reviewed-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agobump version to 1.6.0+38
Dominik Csapak [Thu, 27 Apr 2023 13:32:34 +0000 (15:32 +0200)]
bump version to 1.6.0+38

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agoandroid build: support getting signing key PW from env or a command
Thomas Lamprecht [Thu, 27 Apr 2023 13:07:08 +0000 (15:07 +0200)]
android build: support getting signing key PW from env or a command

One can now specify a command that will be executed to read the
password via it's (whitespace trimmed) stdout output, e.g. for using
the pass[0] toll one would write something like:

```
keyPasswordCommand=pass show work/release/flutter/proxmox-mobile-keystore
```

[0]: https://www.passwordstore.org/

Note, we don't support separate keystore and key passwords anymore
(never used that), but could easily add that again.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agoreadme: record that libsecret-1-dev is required now
Thomas Lamprecht [Wed, 26 Apr 2023 09:09:33 +0000 (11:09 +0200)]
readme: record that libsecret-1-dev is required now

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agoupdate metadata
Thomas Lamprecht [Wed, 26 Apr 2023 08:55:02 +0000 (10:55 +0200)]
update metadata

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agoreadme: improve on small nits
Thomas Lamprecht [Wed, 26 Apr 2023 08:54:12 +0000 (10:54 +0200)]
readme: improve on small nits

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
11 months agoadd tooling upgrade info to README
Dominik Csapak [Mon, 24 Apr 2023 12:43:03 +0000 (14:43 +0200)]
add tooling upgrade info to README

Short and basic upgrade guide, in which order the toolings should be
upgraded, and which parts to check for compatibility.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agoandroid: change jcenter to mavenCentral
Dominik Csapak [Mon, 24 Apr 2023 12:09:29 +0000 (14:09 +0200)]
android: change jcenter to mavenCentral

jcenter is not updated anymore, change to mavenCentral
(as recommended by android studio)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agopubspec: update dependencies
Dominik Csapak [Mon, 24 Apr 2023 09:54:29 +0000 (11:54 +0200)]
pubspec: update dependencies

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agoupdate metadata/cmake
Dominik Csapak [Thu, 20 Apr 2023 14:03:49 +0000 (16:03 +0200)]
update metadata/cmake

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agoupdate webview_flutter to 4.2.0
Dominik Csapak [Mon, 24 Apr 2023 08:38:04 +0000 (10:38 +0200)]
update webview_flutter to 4.2.0

the api changed considerably, so we have to rework how we initialize it:

most is now down in the WebViewController instead of the WebView widget
(which now is WebViewWidget). Cookies can only be set globally in the
WebViewCookieManager. Since this is now async, we have to use a
FutureBuilder to wait for it before returning the WebViewWidget

for this to work, we have to update the kotlin_version, gradle and the
android gradle plugin
(flutter 3.7 supports up to agp 7.4[0], which requires at least gradle 7.5[1]
and IIUC for kotlin 1.7.20 we need at least gradle 7.6[2])

0: https://github.com/flutter/flutter/issues/125181#issuecomment-1518238664
1: https://developer.android.com/build/releases/gradle-plugin
2: https://docs.gradle.org/current/userguide/compatibility.html

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
11 months agoguest migrate window: show correct usages in the node dropdown
Dominik Csapak [Fri, 21 Apr 2023 12:20:16 +0000 (14:20 +0200)]
guest migrate window: show correct usages in the node dropdown

we showed 'CPU: <memoryUsage>' which is wrong, instead show

 CPU: <cpuUsage>
 Memory: <memoryUsage>

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
12 months agofix a few null problems and warnings
Dominik Csapak [Fri, 21 Apr 2023 11:26:58 +0000 (13:26 +0200)]
fix a few null problems and warnings

memused/cpu/loadavg don't have to be there if the rrd data does not
go all the way into the past, so instead of using ! to ignore the null
chekc, use a sensible default

if we use '??' to default to a value, there is no need
to access the last property with '.?' since if it's null it falls back
anyway. (this was only a warning from linting)

also if a value cannot be null (because of its type) we don't have
to do an explicit null check (also a warning from linting)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
12 months agoNodeListTile: fix required online parameter
Dominik Csapak [Fri, 21 Apr 2023 11:14:16 +0000 (13:14 +0200)]
NodeListTile: fix required online parameter

required named parameters cannot have a default, also the @required
has changed to required, so fix that by making 'online' non nullable
and remove the default value (since we give a value everywhere anyway)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
12 months agoput resource filter sheet into a SafeArea
Dominik Csapak [Tue, 13 Sep 2022 13:55:50 +0000 (15:55 +0200)]
put resource filter sheet into a SafeArea

otherwise it can happen that the 'Reset' button is obstructed by
the top status bar

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
12 months agochange to FlutterFragmentActivity
Dominik Csapak [Tue, 13 Sep 2022 13:55:26 +0000 (15:55 +0200)]
change to FlutterFragmentActivity

necessary for usage of 'biometric_storage'

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
18 months agobump version to 1.5.2
Thomas Lamprecht [Wed, 28 Sep 2022 11:05:13 +0000 (13:05 +0200)]
bump version to 1.5.2

for rebuild with current flutter master (basically 3.4 pre-rc) to fix
at least one regression[0] of 3.3 which resulted in crashes with a
stack trace like:

> Exception java.lang.AssertionError: Unexpected metaState 0 for key 0x200000102 during an ACTION_down event.
>   at io.flutter.embedding.android.KeyEmbedderResponder.synchronizePressingKey (KeyEmbedderResponder.java)
>   at io.flutter.embedding.android.KeyEmbedderResponder.handleEventImpl (KeyEmbedderResponder.java)
>   at io.flutter.embedding.android.KeyEmbedderResponder.handleEvent (KeyEmbedderResponder.java)
>   at io.flutter.embedding.android.KeyboardManager.handleEvent (KeyboardManager.java)
>   at io.flutter.plugin.editing.InputConnectionAdaptor.sendKeyEvent (InputConnectionAdaptor.java)
>   at com.android.internal.view.IInputConnectionWrapper.executeMessage (IInputConnectionWrapper.java:704)
>   at com.android.internal.view.IInputConnectionWrapper$MyHandler.handleMessage (IInputConnectionWrapper.java:118)
>   at android.os.Handler.dispatchMessage (Handler.java:106)
>   at android.os.Looper.loopOnce (Looper.java:226)
>   at android.os.Looper.loop (Looper.java:313)
>   at android.app.ActivityThread.main (ActivityThread.java:8751)
>   at java.lang.reflect.Method.invoke (Method.java)
>   at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:571)
>   at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1135

[0]: https://github.com/flutter/flutter/issues/110640

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
18 months agopubspec: update dependencies
Thomas Lamprecht [Tue, 27 Sep 2022 11:35:39 +0000 (13:35 +0200)]
pubspec: update dependencies

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agobump version to 1.5.1
Thomas Lamprecht [Mon, 12 Sep 2022 14:45:29 +0000 (16:45 +0200)]
bump version to 1.5.1

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agofix text selection theme
Dominik Csapak [Mon, 12 Sep 2022 09:24:03 +0000 (11:24 +0200)]
fix text selection theme

by default, flutter derives the text selection theme from the global
MaterialApp defined themes primary color, which is problematic in our
case, since we often have the same primary color as background for text
fields. This resulted in the cursorColor/selectionHandleColor to be the
same as the background, making them invisible.

Fix it by creating a manual textSelectionTheme with colors that properly
contrast the background. (The color works well for both light and dark mode)

The selectionHandleColor is modifed with an opacity of 0.4 like flutter
does by default.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
19 months agoandroid: target and compile with sdk 33 (android 13)
Thomas Lamprecht [Thu, 8 Sep 2022 15:24:11 +0000 (17:24 +0200)]
android: target and compile with sdk 33 (android 13)

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agomain: apply some lints
Thomas Lamprecht [Thu, 8 Sep 2022 15:23:49 +0000 (17:23 +0200)]
main: apply some lints

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agobump version to 1.5.0
Thomas Lamprecht [Thu, 8 Sep 2022 14:37:42 +0000 (16:37 +0200)]
bump version to 1.5.0

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agoswitch depreacted package_info with package_info_plus
Thomas Lamprecht [Thu, 8 Sep 2022 14:36:42 +0000 (16:36 +0200)]
switch depreacted package_info with package_info_plus

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
19 months agoupdate metadata/cmake templates
Thomas Lamprecht [Thu, 8 Sep 2022 14:32:51 +0000 (16:32 +0200)]
update metadata/cmake templates

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>