Commit Graph

39 Commits

Author SHA1 Message Date
Pit Friedrich 21834ec9a0 fix: add KPI tile widget type to the dashboard (#26)
CI / build-and-test (pull_request) Successful in 2m24s
Adds a non-chart dashboard widget: a large value with its label, an
optional signed delta versus the previous period, and an optional
sparkline. Four tiles now sit above the charts, 3x1 each.

- KpiTile draws no surface of its own and fills the grid item's, styled
  from the --dialect-* token layer; the delta's up/down colors are new
  tokens rather than literals, so they follow the light/dark toggle.
- Value and delta share one row: stacking them costs a line the tile does
  not have at its default height of one grid cell.
- SparklineChart is a chrome-free line chart built on DialectTheme, so it
  shares the palette and font with the real charts.
- ApexCharts' sparkline.enabled drops the axes on the initial render but
  updateOptions (how the theme toggle recolors a chart) brings the y-axis
  labels back; they are hidden in CSS, which reaches the chart SVG since
  it renders into light DOM.

The registry registration the issue asks for is left out: #21 is blocked,
so there is no widget picker to register with yet. The tiles are wired
into DashboardView the same way the chart widgets are, and their values
come from the translation bundle until the data service (#20) lands.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0124BiJikbhbiEsNfJxdWM69
2026-07-28 19:57:55 +02:00
pitfriedrich 1b846751dd Merge pull request 'refactor: merge DashboardView and GridStackView into a single dashboard (#19)' (#31) from ai/issue-19-merge-dashboard into main
Reviewed-on: #31
2026-07-28 17:15:44 +00:00
Pit Friedrich 487c206411 fix: merge GridStackView into DashboardView (#19)
CI / build-and-test (pull_request) Successful in 2m22s
DashboardView and GridStackView rendered the same three charts from the
same hardcoded data, so every chart factory method existed twice. The
dashboard is now the GridStackLayout variant at @Route(""):

- GridStackView deleted, its grid/toolbar/chart factories moved into
  DashboardView, which keeps the point-click notifications the old
  dashboard had.
- Charts size to their widget (100%/100%) instead of a fixed 400px.
- MainLayout has one dashboard entry; nav.gridstack/page.gridstack keys
  dropped from all three bundles.
- Storage key is "dashboard" (was "gridstack-demo"), so a saved layout
  from the old route is not reused.
- GridStackViewTest renamed to DashboardViewTest, plus a test asserting
  the three charts render.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0124BiJikbhbiEsNfJxdWM69
2026-07-28 19:12:52 +02:00
pitfriedrich 7aff9fee4f Merge pull request 'test: add Playwright end-to-end example for FormView (#16)' (#18) from ai/issue-16-playwright-formview into main
Reviewed-on: #18
2026-07-26 18:50:21 +00:00
Pit Friedrich a996269aff test: add Playwright end-to-end example for FormView (#16)
CI / build-and-test (pull_request) Successful in 2m16s
Adds the first browser-driven test to the project: PlaywrightTestBase starts
the app on a random port and drives a headless Chromium against it, and
FormViewPlaywrightTest covers the form's rendering, binder validation and the
save/reset buttons.

The tests skip themselves via a JUnit assumption when no browser can be
launched, so runners without Playwright browsers stay green.

Closes #16

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ue9ZtWUBQF4SuSHpzZ3zwq
2026-07-26 20:38:34 +02:00
pitfriedrich 4de757df99 Merge pull request 'fix: make dashboard widgets closable (#14)' (#17) from ai/issue-14-closable-widgets into main
Reviewed-on: #17
2026-07-26 18:20:26 +00:00
Pit Friedrich 7d23eef81b fix: make dashboard widgets closable (#14)
CI / build-and-test (pull_request) Successful in 1m27s
Every GridStackItem now renders a close button next to its drag grip,
mirroring the grip's hover affordance. Closing detaches the item
server-side; grid-stack.ts already unregisters widgets via its
MutationObserver, so the layout is persisted without an extra protocol.

Closable is on by default and can be turned off per item with
setClosable(false); GridStackItem.CloseEvent lets views react.

The GridStackView "remove last" toolbar button is dropped — per-widget
close replaces it, so the view no longer tracks a widget stack. Its
counter now only grows, keeping a closed widget's id from being handed
to a new widget (which would inherit the saved position).

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ue9ZtWUBQF4SuSHpzZ3zwq
2026-07-26 20:17:05 +02:00
Pit Friedrich 2e2c9aec3b added playwright to dev dependencies 2026-07-26 20:10:08 +02:00
pitfriedrich f242bbd8a6 Merge pull request 'fix: restore saved gridstack layout faithfully (#13)' (#15) from ai/issue-13-persist-layout into main
Reviewed-on: #15
Reviewed-by: pitfriedrich <bp.webservice@gmail.com>
2026-07-26 18:07:48 +00:00
Pit Friedrich 85bb0c8c0b fix: restore saved gridstack layout faithfully (#13)
CI / build-and-test (pull_request) Successful in 1m17s
The layout was saved to localStorage, but restoring it did not reliably
reproduce it:

- restore() applied the saved nodes one by one via grid.update(). A later
  item could collide with one already put back and push it off its saved
  spot, and nothing moved it back — so the restored layout was not the one
  the user left. Use grid.load(nodes, false) instead: it sorts the nodes,
  removes them from the engine before re-placing them, and runs in a single
  batch. addRemove is off because Flow owns which children exist.
- gridstack's save() omits w/h when they are 1. The manual restore passed
  them through as undefined, and the server read them as 0 and wrote a
  zero-sized widget back onto the item. load() re-applies gridstack's own
  defaults; onLayoutChange now reads a missing w/h as 1.
- A drag followed immediately by navigating to another route detached the
  element inside the 150ms persist debounce, dropping the pending save.
  disconnectedCallback now flushes it to localStorage first.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ue9ZtWUBQF4SuSHpzZ3zwq
2026-07-26 20:00:16 +02:00
Pit Friedrich f9860fd701 fix mvnw script, crlf + executable 2026-07-26 19:14:58 +02:00
pitfriedrich a5f2fb18ed Merge pull request 'Fixes #11' (#12) from issue/11 into main
Reviewed-on: #12
2026-07-26 12:07:17 +00:00
Pit Friedrich 9311d494bd Fixes #11
CI / build-and-test (pull_request) Successful in 1m15s
- Fix dashboard draggin: introduced sophistaced drag handle
- Fix disappearing of charts when dragged inside a dashboard widget
2026-07-26 14:05:11 +02:00
pitfriedrich 6bd81ff561 Merge pull request 'feat: GridStackLayout showcase view' (#10) from ai/issue-7-gridstack-demo into main
Reviewed-on: #10
2026-07-25 20:14:29 +00:00
Pit Friedrich 17396466a9 fix: add GridStackLayout showcase view (#7)
CI / build-and-test (pull_request) Successful in 1m13s
Adds a /gridstack route demonstrating GridStackLayout: four default
widgets (line/bar/pie chart cards plus a usage hint), buttons to add and
remove widgets at runtime, a reset-layout button and a layout-change
status line. Layout is persisted per browser via the existing
localStorage support. The view gets its own SideNavItem in MainLayout
and full de/en/es translations.

Fixes an infinite recursion in GridStackLayout.add(Component): a
single-argument add(item) resolves to that overload rather than the
varargs one, so its delegation to add(item) called itself. It now
appends through the element API and passes a GridStackItem through
unwrapped.

Adds the first test sources (browserless UI tests) covering the view's
widget count and the add/remove buttons.

Closes #7

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PYAcKoXKPN3rJ7nBroKZkc
2026-07-25 22:12:05 +02:00
pitfriedrich 12761d53ca Merge pull request 'fix: i18n for TimePicker' (#9) from ai/issue-8-timepicker-i18n into main
Reviewed-on: #9
2026-07-25 20:02:11 +00:00
Pit Friedrich e3342d0f53 fix: add i18n for TimePicker matching DatePicker (#8)
CI / build-and-test (pull_request) Successful in 1m9s
Set German locale on TimePicker in FormView and wire TimePickerI18n
error messages (bad input, required, min, max) through the existing
vaadin-i18n translation bundles, mirroring the DatePicker.DatePickerI18n
setup already present in FormView.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PYAcKoXKPN3rJ7nBroKZkc
2026-07-25 22:00:24 +02:00
Pit Friedrich bcf604b7c5 added gridstack 2026-07-25 21:56:47 +02:00
Pit Friedrich c2d29f0635 added gridstack 2026-07-25 20:51:53 +02:00
Pit Friedrich 198988da35 Added autofix agent and loop 2026-07-25 20:37:28 +02:00
pitfriedrich e477bbcc1f Merge pull request '[FEATURE] FontAwesome Icons' (#6) from feature/icons into main
Reviewed-on: #6
2026-07-19 21:41:08 +00:00
Pit Friedrich aca411ca9e [FEATURE] FontAwesome Icons
CI / build-and-test (pull_request) Successful in 1m9s
2026-07-19 23:39:10 +02:00
pitfriedrich 38d3cbe38a Merge pull request 'Feature/i18n' (#5) from feature/i18n into main
Reviewed-on: #5
2026-07-19 19:17:08 +00:00
Pit Friedrich 9114ea9800 [FEATURE] i18n
CI / build-and-test (pull_request) Successful in 1m14s
2026-07-19 21:15:23 +02:00
Pit Friedrich 9316b83f82 chore(i18n): scaffold translation bundles 2026-07-19 20:48:03 +02:00
pitfriedrich b463a00edd Merge pull request '[FEATURE] PWA + Showcase Grid' (#4) from feature/pwa into main
Reviewed-on: #4
2026-07-12 16:22:17 +00:00
Pit Friedrich acb2f5964f [FEATURE] PWA + Showcase Grid
CI / build-and-test (pull_request) Successful in 10m36s
2026-07-12 18:10:26 +02:00
Pit Friedrich 9df764d065 [FEATURE] Dark Theme 2026-07-11 22:31:08 +02:00
Pit Friedrich aa8fbb4838 [FEATURE] Custom Theme (Part II) 2026-07-11 17:38:32 +02:00
pitfriedrich 725125680b Merge pull request '[FEATURE] Custom Theme' (#3) from feature/theme into main
Reviewed-on: #3
2026-07-07 18:07:05 +00:00
Pit Friedrich d947833214 [FEATURE] Customn Theme
CI / build-and-test (pull_request) Successful in 10m26s
2026-07-07 19:55:42 +02:00
pitfriedrich 5ed6937c88 Merge pull request 'Build CI' (#2) from feature/workflows into main
Reviewed-on: #2
2026-07-06 06:04:27 +00:00
Pit Friedrich 018e1c0922 Build CI
CI / build-and-test (pull_request) Successful in 10m33s
2026-07-06 07:36:31 +02:00
pitfriedrich 0639823a69 Merge pull request 'Build CI' (#1) from feature/workflows into main
Reviewed-on: #1
2026-07-06 05:36:08 +00:00
Pit Friedrich 3cd9bcc0ba Build CI 2026-07-06 07:35:25 +02:00
Pit Friedrich af79286cb0 Different types of charts 2026-07-06 07:33:15 +02:00
Pit Friedrich 9ffba461fe Initial commit 2026-07-05 17:27:02 +02:00
Pit Friedrich 23b392a19b Initial commit 2026-07-05 17:06:59 +02:00
start.vaadin.com 0935b7a98a Generated project 2026-07-04 06:04:51 +00:00