]> git.proxmox.com Git - ui/proxmox-yew-widget-toolkit.git/log
ui/proxmox-yew-widget-toolkit.git
3 days agoMakefile: add dsc target to build debian source packages master
Dietmar Maurer [Tue, 14 Jan 2025 13:17:53 +0000 (14:17 +0100)]
Makefile: add dsc target to build debian source packages

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
3 days agomacros: update dummy pwt implementations so that the doc tests succeed
Shannon Sterz [Tue, 14 Jan 2025 11:44:40 +0000 (12:44 +0100)]
macros: update dummy pwt implementations so that the doc tests succeed

adds the updated trait definitions and adds a dummy `oncklick`
implementation so that the doc tests succeed again

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
3 days agomacros: update wrong_comp test to adjust to new additional traits
Shannon Sterz [Tue, 14 Jan 2025 11:44:39 +0000 (12:44 +0100)]
macros: update wrong_comp test to adjust to new additional traits

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
3 days agomacros: update no_clone test to adjust to new additional traits
Shannon Sterz [Tue, 14 Jan 2025 11:44:38 +0000 (12:44 +0100)]
macros: update no_clone test to adjust to new additional traits

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
3 days agomacros: update compiler version in invalid_type test
Shannon Sterz [Tue, 14 Jan 2025 11:44:37 +0000 (12:44 +0100)]
macros: update compiler version in invalid_type test

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
3 days agopwt-macros: fix typo in changelog
Dietmar Maurer [Tue, 14 Jan 2025 12:17:29 +0000 (13:17 +0100)]
pwt-macros: fix typo in changelog

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
3 days agomacros: fix build for tests
Shannon Sterz [Mon, 13 Jan 2025 14:55:27 +0000 (15:55 +0100)]
macros: fix build for tests

it seems adapting the test case in pwt-macros was forgotten at some
point. this makes the test cases build-able again. please note that
this does not make all test cases here work, as some of them seem to
expect the output of specific rustc versions. this should probably be
addressed in a separate commit.

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
4 days agotree-wide: use `?` instead of match statement where easily possible
Shannon Sterz [Mon, 13 Jan 2025 11:15:05 +0000 (12:15 +0100)]
tree-wide: use `?` instead of match statement where easily possible

this makes the code more concise and fixes the clippy lint
`question_mark` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#question_mark

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
9 days agobump version to 0.4.7
Dietmar Maurer [Wed, 8 Jan 2025 09:36:13 +0000 (10:36 +0100)]
bump version to 0.4.7

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
9 days agowidget: confirm_dialog: refactor to use message box
Shannon Sterz [Thu, 19 Dec 2024 11:00:59 +0000 (12:00 +0100)]
widget: confirm_dialog: refactor to use message box

this allows using an icon next to the message and generally simplifies
the code.

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
10 days agoinput_panel: cleanup: avoid generic parameter to reduce code size
Dietmar Maurer [Tue, 7 Jan 2025 12:52:16 +0000 (13:52 +0100)]
input_panel: cleanup: avoid generic parameter to reduce code size

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
2 weeks agomenu: remove MenuBar struct
Shannon Sterz [Fri, 3 Jan 2025 13:58:46 +0000 (14:58 +0100)]
menu: remove MenuBar struct

this only had one use, create a Menu where `menubar` was already set to
`true`. use a new constructor instead called `new_menubar()` that does
the same without creating a superfluous type. it's also more idiomatic
to it this way. this fixes the clippy lint `new_ret_no_self` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#new_ret_no_self

2 weeks agopwt-macros: indent list items in doc string properly
Shannon Sterz [Fri, 3 Jan 2025 13:41:30 +0000 (14:41 +0100)]
pwt-macros: indent list items in doc string properly

avoid the clippy lint `doc_lazy_continuation` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation

2 weeks agodom: use `into()` when converting JSValue to HtmlElement
Shannon Sterz [Fri, 3 Jan 2025 13:37:10 +0000 (14:37 +0100)]
dom: use `into()` when converting JSValue to HtmlElement

this cannot fail, so just use `into()` and then wrap with `Some()` to
conform to function signature. this removes the clippy lint
`unnecessary_fallible_conversions` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_fallible_conversions

2 weeks agoselection/store/tree_store: use `where` for generics in hooks
Shannon Sterz [Fri, 3 Jan 2025 13:29:22 +0000 (14:29 +0100)]
selection/store/tree_store: use `where` for generics in hooks

instead of in-lining them in the function definition. the `hook!` macro
will add a `'hook` liftime via a `where` clause to them when expanded,
which triggers the clippy lint `multiple_bound_locations` [1] as the
generics would then be bound in the function signature and the `where`
clause. so just define them in the `where` clause right away to avoid
that.

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations

2 weeks agotheme: use `is_err` instead of `if let Err(_)`
Shannon Sterz [Fri, 3 Jan 2025 13:19:12 +0000 (14:19 +0100)]
theme: use `is_err` instead of `if let Err(_)`

this is more idiomatic and removes the clippy lint
`redundant_pattern_matching` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching

2 weeks agosnack_bar_manager: use a box for `Show` message
Shannon Sterz [Fri, 3 Jan 2025 13:15:20 +0000 (14:15 +0100)]
snack_bar_manager: use a box for `Show` message

the `Show` message takes a whole `SnackBar` struct that is
significantlly larger than the other enum variants here. use a `Box` to
improve performance and remove the clippy lint `large_enum_variant` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant

2 weeks agopage_stack/page_view: use `Ord` trait to get rid of comparison chains
Shannon Sterz [Fri, 3 Jan 2025 13:10:32 +0000 (14:10 +0100)]
page_stack/page_view: use `Ord` trait to get rid of comparison chains

this makes the code more readable and idiomatic, fixes the clippy lint
`comparison_chain` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#comparison_chain

2 weeks agoform context: allow register_field with too many arguments
Shannon Sterz [Fri, 3 Jan 2025 12:45:31 +0000 (13:45 +0100)]
form context: allow register_field with too many arguments

this is a publically facing api so allow the clippy lint
`too_many_arguments` [1] here for now and add a to-do to possible
refactor this to use it's own parameter types.

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

2 weeks agoform module: allow module inception as we only public re-expose `Form`
Shannon Sterz [Fri, 3 Jan 2025 12:33:33 +0000 (13:33 +0100)]
form module: allow module inception as we only public re-expose `Form`

allowing the clippy lint `module_inception` [1] here makes some sense as
no one should every really need to import anything but `pwt::form::Form`
or `pwt::form::PwtForm`.

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#module_inception

2 weeks agonavigation_drawer: use if-let instead of map to avoid unit-closure map
Shannon Sterz [Fri, 3 Jan 2025 12:24:20 +0000 (13:24 +0100)]
navigation_drawer: use if-let instead of map to avoid unit-closure map

an if-let statement is more clear and simplifies the code here quite a
bit. also fixes the clippy lint `option_map_unit_fn` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#option_map_unit_fn

2 weeks agosplit_pane: take ownership of `self` in `PaneSize` `to_*` functions
Shannon Sterz [Fri, 3 Jan 2025 12:11:40 +0000 (13:11 +0100)]
split_pane: take ownership of `self` in `PaneSize` `to_*` functions

this breaks the self convention for types that are `Copy` such as
`PaneSize`. this should improve readability and fixes the
`wrong_self_convention` clippy lint [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#wrong_self_convention

2 weeks agoloader/data_table: refactor match statements that return booleans
Shannon Sterz [Fri, 3 Jan 2025 12:03:14 +0000 (13:03 +0100)]
loader/data_table: refactor match statements that return booleans

this can usually be more succinctly expressed with the `matches!` macro
or other methods to deal with `Result`s or `Option`s. this also fixed
the clippy lint `match_like_matches_macro` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro

2 weeks agodata_table/menu: re-write loops as while-let loops
Shannon Sterz [Fri, 3 Jan 2025 11:46:04 +0000 (12:46 +0100)]
data_table/menu: re-write loops as while-let loops

this is more idiomatic and fixes the clippy lint `while_let_loop` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop

2 weeks agotree wide: allow type complexity lints where necessary
Shannon Sterz [Fri, 3 Jan 2025 11:31:32 +0000 (12:31 +0100)]
tree wide: allow type complexity lints where necessary

allow type complexity where neccessary. this avoid triggering the clippy
lint `type_complexity` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity

2 weeks agotheme_mode_selector: `_`-prefix ctx as it's only used in recursion
Shannon Sterz [Fri, 3 Jan 2025 10:46:04 +0000 (11:46 +0100)]
theme_mode_selector: `_`-prefix ctx as it's only used in recursion

since we olny pass through the `ctx` parameter and don't use it here
ourselves mark it with a `-`-prefix. this fixes the clippy lint
`only_used_in_recursion` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#only_used_in_recursion

2 weeks agotree wide: remove empty lines between doc comments and code
Shannon Sterz [Fri, 3 Jan 2025 10:40:49 +0000 (11:40 +0100)]
tree wide: remove empty lines between doc comments and code

to make clear that the doc comments actually do document the following
lines of code. this fices the clippy lint
`empty_line_after_doc_comments` [1].

[1]:
https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments

2 weeks agotree wide: apply auto-appliable clippy fix-ups
Shannon Sterz [Fri, 3 Jan 2025 10:26:25 +0000 (11:26 +0100)]
tree wide: apply auto-appliable clippy fix-ups

this mostly includes:

- switching from `Into` to `From` implementations as that also provides
  an `Into` implementation for "free"
- adding `Default` implementations where possible (e.g. if a `new`
  function without parameters exists)
- removing unnecessary reference and dereference operations (e.g. if the
  compiler would do that automatically anyway)
- using more idiomatic syntax (e.g. using `contains` instead of `<` and
  `>=` operators)
- removing closures where they aren't necessary
- removing `format!` macros where `to_string()` would do to improve
  performance
- remove unnecessary convertions and into calls

these should not change the semantics of the exists code itself, so
there are no breaking changes. however, adding `Default` implementations
and such, does add new public APIs for some types.

2 weeks agogettext_wrapper: run rustfmt
Shannon Sterz [Fri, 3 Jan 2025 08:56:01 +0000 (09:56 +0100)]
gettext_wrapper: run rustfmt

4 weeks agowidget: dropdown: update picker placement after showing
Dominik Csapak [Fri, 20 Dec 2024 10:31:39 +0000 (11:31 +0100)]
widget: dropdown: update picker placement after showing

It seems that under certain circumstances (e.g. a dropdown in a
dialog) updating the position of the picker before it's opened (it's a
popover) does not work properly in safari/webkit/epiphany.

When trying to open such a dropdown, it (or some parts of it) would be
rendered with a height of 0px, even though the elements have a height
set explicitly.

To fix this, update the picker placement after opening it. What
exactly is the cause (e.g. if it's a browser bug or our css/aligning)
is yet to be determined.

This fixes an issue on webkit (tested with epiphany) that opening
dropdowns in a dialog did not show the dropdown properly.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Tested-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
 [ TL: extend comment to mention webkit explicitly ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agobump version to 0.4.6
Thomas Lamprecht [Thu, 19 Dec 2024 12:25:17 +0000 (13:25 +0100)]
bump version to 0.4.6

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agowhitepaper: fix some typos
Thomas Lamprecht [Thu, 19 Dec 2024 12:24:35 +0000 (13:24 +0100)]
whitepaper: fix some typos

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agowidget: input panel: use correct column for custom childs
Dominik Csapak [Thu, 19 Dec 2024 12:09:16 +0000 (13:09 +0100)]
widget: input panel: use correct column for custom childs

we added a 'padding column' recently, and we forgot to adapt
the custom childs for that.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
4 weeks agowhitepaper: re-flow text to 80 cc width
Thomas Lamprecht [Thu, 19 Dec 2024 11:13:16 +0000 (12:13 +0100)]
whitepaper: re-flow text to 80 cc width

Wrap at a consistent text-width of 80 character columns, that is
a relatively standard width for prose and a good balance for having
more context visible at the same time while not requiring to much neck
moving.

Also fix a unclosed code-block by adding the third backtick

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agoreadme: re-wrap to 80cc and small fixes
Thomas Lamprecht [Thu, 19 Dec 2024 11:22:02 +0000 (12:22 +0100)]
readme: re-wrap to 80cc and small fixes

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agobump version to 0.4.5
Thomas Lamprecht [Wed, 18 Dec 2024 14:40:32 +0000 (15:40 +0100)]
bump version to 0.4.5

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agowidget: display: don't set inital value
Dominik Csapak [Wed, 18 Dec 2024 14:25:08 +0000 (15:25 +0100)]
widget: display: don't set inital value

when doing that, a new value that is set via `new` won't get used as a
value anymore, which is undesired. only use the value for the default,
which was the original intenion.

This fixes an issue where the value of a display field changes after the
first creation and would not update it's displayed value.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
4 weeks agobump version to 0.4.4
Thomas Lamprecht [Wed, 18 Dec 2024 13:40:30 +0000 (14:40 +0100)]
bump version to 0.4.4

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agowidget: add ConfirmDialog
Shannon Sterz [Wed, 18 Dec 2024 12:14:58 +0000 (13:14 +0100)]
widget: add ConfirmDialog

this is a dialog that allows for confirming or canceling an action
easily.

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
4 weeks agocatalog_loader: don't try to load the catalog if the language is empty
Shannon Sterz [Tue, 17 Dec 2024 15:09:46 +0000 (16:09 +0100)]
catalog_loader: don't try to load the catalog if the language is empty

this means that the Language value in the local storage is not set. by
default this would try to load `catalog-.mo` as language is an empty
string, so just skip trying to load something here and simply initialize
with an empty catalog instead, avoiding a failed load.

Signed-off-by: Shannon Sterz <s.sterz@proxmox.com>
4 weeks agowidget: button: use 'fa-spin' for refresh icon
Dominik Csapak [Tue, 17 Dec 2024 15:15:15 +0000 (16:15 +0100)]
widget: button: use 'fa-spin' for refresh icon

instead of loading icon, since the change is too jarring

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
4 weeks agobump version to 0.4.3
Dietmar Maurer [Tue, 17 Dec 2024 11:55:00 +0000 (12:55 +0100)]
bump version to 0.4.3

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agobuildsys: simplify upload target, add missing uses for BUILDDIR
Thomas Lamprecht [Tue, 17 Dec 2024 11:48:51 +0000 (12:48 +0100)]
buildsys: simplify upload target, add missing uses for BUILDDIR

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agofocus: move code to dom module
Dietmar Maurer [Tue, 17 Dec 2024 11:14:14 +0000 (12:14 +0100)]
focus: move code to dom module

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agoalign: move code to dom module
Dietmar Maurer [Tue, 17 Dec 2024 11:05:57 +0000 (12:05 +0100)]
align: move code to dom module

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agocolumn: derive Properties instead of Default
Dietmar Maurer [Tue, 17 Dec 2024 10:55:58 +0000 (11:55 +0100)]
column: derive Properties instead of Default

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agocard: derive Properties instead of Default
Dietmar Maurer [Tue, 17 Dec 2024 10:54:19 +0000 (11:54 +0100)]
card: derive Properties instead of Default

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agobuildsys: add upload target
Thomas Lamprecht [Tue, 17 Dec 2024 10:53:25 +0000 (11:53 +0100)]
buildsys: add upload target

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agobuildsys: add DEBS and BUILDDIR variables
Thomas Lamprecht [Tue, 17 Dec 2024 10:52:51 +0000 (11:52 +0100)]
buildsys: add DEBS and BUILDDIR variables

Make it a bit more complete and allow overriding the BUILDDIR one from
the outside.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agoimprove docs
Dietmar Maurer [Tue, 17 Dec 2024 10:48:10 +0000 (11:48 +0100)]
improve docs

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agoimprove size observer docs
Dietmar Maurer [Tue, 17 Dec 2024 10:37:29 +0000 (11:37 +0100)]
improve size observer docs

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agorow: derive Properties instead of Default
Dietmar Maurer [Tue, 17 Dec 2024 10:31:11 +0000 (11:31 +0100)]
row: derive Properties instead of Default

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agovisibility observer: remove unused generic parameter, improve docs
Dietmar Maurer [Tue, 17 Dec 2024 10:27:44 +0000 (11:27 +0100)]
visibility observer: remove unused generic parameter, improve docs

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agopanel: derive Properties instead of Default
Dietmar Maurer [Tue, 17 Dec 2024 10:23:57 +0000 (11:23 +0100)]
panel: derive Properties instead of Default

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agobump version to 0.4.2
Dietmar Maurer [Tue, 17 Dec 2024 08:38:40 +0000 (09:38 +0100)]
bump version to 0.4.2

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agopwt-macros: bump version 0.3.0
Dietmar Maurer [Tue, 17 Dec 2024 08:34:15 +0000 (09:34 +0100)]
pwt-macros: bump version 0.3.0

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agoadd real VisibilityObserver component
Dietmar Maurer [Mon, 16 Dec 2024 17:40:37 +0000 (18:40 +0100)]
add real VisibilityObserver component

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agorename VisibilityObserver to DomVisibilityObserver
Dietmar Maurer [Mon, 16 Dec 2024 17:22:22 +0000 (18:22 +0100)]
rename VisibilityObserver to DomVisibilityObserver

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agolist: use new SizeObserver component
Dietmar Maurer [Mon, 16 Dec 2024 12:38:19 +0000 (13:38 +0100)]
list: use new SizeObserver component

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agoadd real SizeObserver component
Dietmar Maurer [Mon, 16 Dec 2024 11:05:17 +0000 (12:05 +0100)]
add real SizeObserver component

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agorename SizeObserver to DomSizeObserver
Dietmar Maurer [Sun, 15 Dec 2024 15:27:30 +0000 (16:27 +0100)]
rename SizeObserver to DomSizeObserver

And move it into the dom module.

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agobump version to 0.4.1
Thomas Lamprecht [Mon, 16 Dec 2024 13:30:42 +0000 (14:30 +0100)]
bump version to 0.4.1

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agostyle fix line-length and formatting in various doc-comments
Thomas Lamprecht [Mon, 16 Dec 2024 13:38:00 +0000 (14:38 +0100)]
style fix line-length and formatting in various doc-comments

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agocleanup: remove unused code
Dietmar Maurer [Mon, 16 Dec 2024 17:01:35 +0000 (18:01 +0100)]
cleanup: remove unused code

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agowidget: data table: beter handle navigation input
Dominik Csapak [Mon, 16 Dec 2024 13:18:38 +0000 (14:18 +0100)]
widget: data table: beter handle navigation input

when inside a cell, we generally want to navigate with arrow keys,
except if we're inside an input element. In that case, use tab/shift+tab
to navigate out and don't catch arrows/space to allow navigation within
the input field (and input a space).

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
4 weeks agoreadme: fix future git repo url
Thomas Lamprecht [Mon, 16 Dec 2024 11:21:44 +0000 (12:21 +0100)]
readme: fix future git repo url

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agoreflow some doc-comments to use full 100cc width
Thomas Lamprecht [Mon, 16 Dec 2024 11:21:07 +0000 (12:21 +0100)]
reflow some doc-comments to use full 100cc width

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agotree wide: remove debug log statements
Dominik Csapak [Mon, 16 Dec 2024 09:09:10 +0000 (10:09 +0100)]
tree wide: remove debug log statements

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
4 weeks agocheck in generated d/control files
Thomas Lamprecht [Sun, 15 Dec 2024 14:01:26 +0000 (15:01 +0100)]
check in generated d/control files

Makes it a bit easier to bootstrap and also see what changed w.r.t.
dependencies and meta information

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agobuildsys: wrap debcargo command over multiple lines
Thomas Lamprecht [Sun, 15 Dec 2024 14:07:02 +0000 (15:07 +0100)]
buildsys: wrap debcargo command over multiple lines

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
4 weeks agolist: make number of prefetched rows configurable
Dietmar Maurer [Sun, 15 Dec 2024 10:44:25 +0000 (11:44 +0100)]
list: make number of prefetched rows configurable

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
4 weeks agotheme density: rework naming to more telling variants
Thomas Lamprecht [Sat, 14 Dec 2024 12:58:52 +0000 (13:58 +0100)]
theme density: rework naming to more telling variants

Rework the naming and doc comments of the theme density type but
include backward compatibility for the old variants when parsing the
density from a string. There's nothing to adapt on the actual UI
examples or products.

The bigger improvement is avoiding "Auto" for the default theme
spacing/density, as "auto" is widely used for something that
dynamically adapts on some environment aspects. But all our themes do
not have any such queries for high/low dpi or screen width to choose a
fitting spacing dynamically. Use `Preset` to avoid clashing with the
widely used `Default` trait from the rust std lib, albeit we could use
that if we really want.

The smaller fine tuning is renaming "High" to "Compact" and "Touch" to
"Relaxed".
The reasoning for the first is that most people, including our user
base, does not work with density a lot in their every day life, be it
physical density or screen density, so "higher density", while
definitively correct for what it does, is not that intuitive, i.e.
when "higher" makes things "smaller" we have a sort of double-negation
that is almost never good to have for UX.
The reasoning for the second (Touch -> Relaxed) is that this is not
doing anything with touch directly, it just might correlate with that
use case, and coupling a setting name with one specific use case is a
bit confusing for peoples coming from other use cases, like simply
having a higher DPI but not doing desktop wide scaling.

Note the naming was initially suggested by me with Thunderbird as
example, so this is really just improving on my own short comings from
the past. It also seems that newer Thunderbird Versions (e.g., latest
134.0b4) changed the wording to something similar than we now have
after this commit.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
5 weeks agopwt-macros: bump version to 0.2.0
Dietmar Maurer [Fri, 13 Dec 2024 16:32:46 +0000 (17:32 +0100)]
pwt-macros: bump version to 0.2.0

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agofix debian release name
Dietmar Maurer [Fri, 13 Dec 2024 16:29:51 +0000 (17:29 +0100)]
fix debian release name

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agobump version to 0.4.0
Dietmar Maurer [Fri, 13 Dec 2024 16:24:43 +0000 (17:24 +0100)]
bump version to 0.4.0

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agowidget: meter: add 'animated' flag
Dominik Csapak [Fri, 13 Dec 2024 14:53:29 +0000 (15:53 +0100)]
widget: meter: add 'animated' flag

for adding the 'pwt-animated' class that animates the value transitions.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
5 weeks agolist: also hide sparator behind wrapper
Dietmar Maurer [Fri, 13 Dec 2024 11:52:07 +0000 (12:52 +0100)]
list: also hide sparator behind wrapper

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: cleanup: avoid compiler warnings
Dietmar Maurer [Fri, 13 Dec 2024 11:33:32 +0000 (12:33 +0100)]
list: cleanup: avoid compiler warnings

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agocss: add rust enum for font style
Dominik Csapak [Fri, 13 Dec 2024 10:14:41 +0000 (11:14 +0100)]
css: add rust enum for font style

so we can write `FontStyle::DisplaySmall` instead of
`pwt-font-display-small` and get compile time checks.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
5 weeks agolist: remove key property, because it is already in the standard widget properties
Dietmar Maurer [Fri, 13 Dec 2024 10:45:04 +0000 (11:45 +0100)]
list: remove key property, because it is already in the standard widget properties

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: add separator property
Dietmar Maurer [Fri, 13 Dec 2024 08:43:13 +0000 (09:43 +0100)]
list: add separator property

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: split out list tile observer code
Dietmar Maurer [Fri, 13 Dec 2024 08:26:34 +0000 (09:26 +0100)]
list: split out list tile observer code

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: use list tiles with forcable height
Dietmar Maurer [Fri, 13 Dec 2024 06:57:07 +0000 (07:57 +0100)]
list: use list tiles with forcable height

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: remove separator property to simplify development
Dietmar Maurer [Thu, 12 Dec 2024 10:37:21 +0000 (11:37 +0100)]
list: remove separator property to simplify development

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist tile: add force_height property
Dietmar Maurer [Thu, 12 Dec 2024 07:14:52 +0000 (08:14 +0100)]
list tile: add force_height property

This restricts the used container height, but still renders the tile with full
height so that we still get resize events with the correct size.

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agotab: change default style to MaterialPrimary
Dietmar Maurer [Thu, 12 Dec 2024 08:55:59 +0000 (09:55 +0100)]
tab: change default style to MaterialPrimary

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: add ARIA roles
Dietmar Maurer [Tue, 10 Dec 2024 12:29:39 +0000 (13:29 +0100)]
list: add ARIA roles

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agocleanup: list: remove unused code, use better names
Dietmar Maurer [Tue, 10 Dec 2024 11:26:39 +0000 (12:26 +0100)]
cleanup: list: remove unused code, use better names

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: compute tail height
Dietmar Maurer [Tue, 10 Dec 2024 11:12:32 +0000 (12:12 +0100)]
list: compute tail height

Instead of using a bad esitimation.

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: fix for missing onscroll event.
Dietmar Maurer [Tue, 10 Dec 2024 09:28:38 +0000 (10:28 +0100)]
list: fix for missing onscroll event.

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: rate limit TileResize events
Dietmar Maurer [Mon, 9 Dec 2024 13:24:53 +0000 (14:24 +0100)]
list: rate limit TileResize events

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: observe tile resizes
Dietmar Maurer [Mon, 9 Dec 2024 11:52:37 +0000 (12:52 +0100)]
list: observe tile resizes

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist_tile: add resize_callback
Dietmar Maurer [Mon, 9 Dec 2024 11:10:53 +0000 (12:10 +0100)]
list_tile: add resize_callback

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: improve inline docs
Dietmar Maurer [Sun, 8 Dec 2024 15:36:43 +0000 (16:36 +0100)]
list: improve inline docs

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agorename ProxmoxLanguageSelector to PwtLanguageSelector
Dietmar Maurer [Sat, 7 Dec 2024 14:14:52 +0000 (15:14 +0100)]
rename ProxmoxLanguageSelector to PwtLanguageSelector

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agodocs: avoid useless re-export docs
Dietmar Maurer [Sat, 7 Dec 2024 11:00:53 +0000 (12:00 +0100)]
docs: avoid useless re-export docs

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: improve docs
Dietmar Maurer [Sat, 7 Dec 2024 10:08:19 +0000 (11:08 +0100)]
list: improve docs

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agodocs: fix compiler warning
Dietmar Maurer [Sat, 7 Dec 2024 09:42:00 +0000 (10:42 +0100)]
docs: fix compiler warning

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: improve docu
Dietmar Maurer [Sat, 7 Dec 2024 09:33:17 +0000 (10:33 +0100)]
list: improve docu

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
5 weeks agolist: set scroll_to to correct size estimations
Dietmar Maurer [Fri, 6 Dec 2024 16:04:47 +0000 (17:04 +0100)]
list: set scroll_to to correct size estimations

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>