Skip to content
This repository was archived by the owner on May 29, 2026. It is now read-only.

fix: dashboard cleanup + header/PHPCS/i18n improvements#272

Closed
rubenvdlinde wants to merge 6 commits into
developmentfrom
fix/header-info-email-phpcs
Closed

fix: dashboard cleanup + header/PHPCS/i18n improvements#272
rubenvdlinde wants to merge 6 commits into
developmentfrom
fix/header-info-email-phpcs

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

Summary

Mixed bag of fixes accumulated on this branch:

  • Dashboard — remove duplicate widgets caused by concatenated DEFAULT_LAYOUT, fix card-in-card and double-scrollbar effects on Deadline/TaskReminders/StalledCases widgets, fix broken NcAppNavigationItem nesting between Map and Voorstellen
  • i18n — complete Dutch translation coverage for Procest UI
  • Quality — run phpcbf to auto-resolve 1147 PHPCS violations
  • Headers — fix @author email typo (dev@conductio.nlinfo@conduction.nl)
  • Docs — add Greenmail dev docs and document seed-cases.sh
  • OpsX — add coverage scan reports for procest retrofit

Test plan

  • Procest dashboard renders with no duplicates and single scrollbar per widget
  • Map and Voorstellen show as separate items in the side nav
  • composer check:strict passes
  • Dutch translations render correctly across UI

Before: 1540 errors across 47 lib/ files
After:  393 errors across 45 lib/ files

Remaining violations are non-auto-fixable (named-parameter rewrites,
operator !/=== FALSE swaps, implicit truthy, inline-if rewrites) and
need human or reviewer judgment.
Literal string replacement in docblock @author tags.

Template fix in nextcloud-app-template PR #19 prevents recurrence.
Adds two coverage reports produced by /opsx-coverage-scan:

- coverage-report.pilot.{md,json} — 2026-04-20 file-level pilot run (PHP
  only, 89 files, ~180 Bucket 1 candidates estimated)
- coverage-report.{md,json} — 2026-04-20 full per-method pass (PHP + Vue/TS,
  764 PHP methods + 318 frontend units classified; 678 Bucket 1, 96 Bucket
  2a / 7 clusters, 206 Bucket 2b / 9 clusters, 73 Bucket 3b, 115 Bucket 4
  findings across 3 ADR rules)

Read-only — no code changes. Feeds the /opsx-annotate and /opsx-reverse-spec
retrofit commands.
- docs/development.md: document local Greenmail setup for mail-driven
  flows (case intake from citizen email, behandelaar notifications).
  Includes IMAP/SMTP config + seed-mail.sh pointer to the shared
  openregister stack.
- l10n: sync en/nl strings — add "All cases active", "Case Map",
  "Cases by status"; drop 4 stale case-type template strings.
Broken l10n/nl.js entries with unescaped quotes caused a JavaScript
parse error that silently failed OC.L10N.register(), so ALL Procest
translations fell back to English regardless of user language setting.
The stale entries were cleaned up in 51edd53; this commit fills in the
remaining coverage gaps that made the dashboard appear half-translated.

l10n additions (nl.js, en.js, en.json):
- Widget titles: Deadline Alerts, Task Due Reminders, Stalled Cases,
  Case Map, SLA Compliance, Work Queue, Map
- Empty states: No items found, No task reminders, All cases active,
  No SLA targets
- Action labels: View all, View all deadline alerts
- Lowercase "Open cases" / "Cases by status" aliases to match bundle output

Source fixes (require rebuild):
- Dashboard.vue: wrap hardcoded 'CASE'/'TASK' badges in t() and pass
  :empty-label="t(...)" to the 5 CnStatsBlock KPI widgets so their
  default 'No items found' string becomes translatable
- dashboardHelpers.js, doorlooptijdHelpers.js: wrap 'Unknown' fallback
  strings in t() (imports translate from @nextcloud/l10n)

Build config:
- webpack.config.js: add scss/sass-loader rule — needed for the new
  CnCard component from @conduction/nextcloud-vue which uses
  <style lang="scss">; procest had no SCSS rule and built fine until
  CnCard was added upstream
- package.json: add sass-loader to devDependencies
- Collapse duplicate DEFAULT_LAYOUT entries that rendered every top-row widget twice
- Add missing </template> for #widget-case-map slot
- Drop redundant card border/background/padding from DeadlineAlerts, TaskDueReminders, StalledCases (CnDashboardPage already wraps each widget)
- Remove inner overflow-y on __list containers to fix double scrollbar
- Fix broken NcAppNavigationItem nesting between Map and Voorstellen in MainMenu
- Document seed-cases.sh in development.md
@codeinputmachine

Copy link
Copy Markdown

Hey @rubenvdlinde, Code Input detected this PR has a merge conflict. Some of the conflicts of this PR can be resolved with a semantic merge driver. Code Input can do that automatically: https://codeinput.com/r/IEkxPeAZXGu Let me know if you need more help with this conflict or how Code Input works.

@rubenvdlinde

Copy link
Copy Markdown
Contributor Author

Branch too stale to rebase. Same situation as #306development's json-manifest migration deleted files this branch modified; 40+ merge conflicts. The PHPCS/i18n/header fixes here are worth keeping but should be re-applied from a fresh branch. Recommend close + re-do. Flagged during the production-readiness sweep.

@rubenvdlinde

Copy link
Copy Markdown
Contributor Author

Superseded by #420 — the fix/header-info-email-phpcs branch had 40+ conflicts with development (the json-manifest migration deleted files the branch modified) and couldn't be rebased. #420 re-applies the still-relevant parts cleanly: dashboard widget card-in-card cleanup, the t('procest', …) i18n fixes + missing dashboard translation keys, removal of the malformed l10n extraction artifacts, and the @author email typo fix. The blanket phpcbf reformat and the now-obsolete MainMenu/Dashboard nav changes were intentionally not carried over.

rubenvdlinde added a commit that referenced this pull request May 19, 2026
…do of #272)

Re-implements the still-relevant parts of #272 against current development
(after the json-manifest migration):

- Dashboard: remove card-in-card framing (background/border/border-radius)
  and inner scrollbars from the DeadlineAlerts / StalledCases /
  TaskDueReminders widgets so they sit cleanly inside the manifest
  dashboard tiles.
- i18n: wrap the "Unknown" fallback labels in dashboardHelpers.js and
  doorlooptijdHelpers.js with t('procest', ...); add the missing dashboard
  translation keys (All cases active, No task reminders, SLA Compliance,
  View all deadline alerts) to l10n/{en,nl}.{js,json} with Dutch
  translations; drop four malformed extraction-artifact keys
  ("Case created with type \", "Case type \", "Status changed from/to \")
  that left l10n/en.js syntactically broken.
- Headers: fix the @author email typo (dev@conductio.nl -> info@conduction.nl)
  in lib/ and appinfo/routes.php.

Parts of #272 that are now obsolete (MainMenu.vue / Dashboard.vue nav and
DEFAULT_LAYOUT changes, the duplicate-widget DEFAULT_LAYOUT fix, the
"Map"/"Case Map" nav keys) were already resolved by the manifest migration
and are intentionally not re-applied. The blanket phpcbf reformat from #272
is left out as out-of-scope; the codebase still has a pre-existing PHPCS
baseline tracked separately.
rubenvdlinde added a commit that referenced this pull request May 19, 2026
…do of #272)

Re-implements the still-relevant parts of #272 against current development
(after the json-manifest migration):

- Dashboard: remove card-in-card framing (background/border/border-radius)
  and inner scrollbars from the DeadlineAlerts / StalledCases /
  TaskDueReminders widgets so they sit cleanly inside the manifest
  dashboard tiles.
- i18n: wrap the "Unknown" fallback labels in dashboardHelpers.js and
  doorlooptijdHelpers.js with t('procest', ...); add the missing dashboard
  translation keys (All cases active, No task reminders, SLA Compliance,
  View all deadline alerts) to l10n/{en,nl}.{js,json} with Dutch
  translations; drop four malformed extraction-artifact keys
  ("Case created with type \", "Case type \", "Status changed from/to \")
  that left l10n/en.js syntactically broken.
- Headers: fix the @author email typo (dev@conductio.nl -> info@conduction.nl)
  in lib/ and appinfo/routes.php.

Parts of #272 that are now obsolete (MainMenu.vue / Dashboard.vue nav and
DEFAULT_LAYOUT changes, the duplicate-widget DEFAULT_LAYOUT fix, the
"Map"/"Case Map" nav keys) were already resolved by the manifest migration
and are intentionally not re-applied. The blanket phpcbf reformat from #272
is left out as out-of-scope; the codebase still has a pre-existing PHPCS
baseline tracked separately.
rubenvdlinde added a commit that referenced this pull request May 19, 2026
…do of #272)

Re-implements the still-relevant parts of #272 against current development
(after the json-manifest migration):

- Dashboard: remove card-in-card framing (background/border/border-radius)
  and inner scrollbars from the DeadlineAlerts / StalledCases /
  TaskDueReminders widgets so they sit cleanly inside the manifest
  dashboard tiles.
- i18n: wrap the "Unknown" fallback labels in dashboardHelpers.js and
  doorlooptijdHelpers.js with t('procest', ...); add the missing dashboard
  translation keys (All cases active, No task reminders, SLA Compliance,
  View all deadline alerts) to l10n/{en,nl}.{js,json} with Dutch
  translations; drop four malformed extraction-artifact keys
  ("Case created with type \", "Case type \", "Status changed from/to \")
  that left l10n/en.js syntactically broken.
- Headers: fix the @author email typo (dev@conductio.nl -> info@conduction.nl)
  in lib/ and appinfo/routes.php.

Parts of #272 that are now obsolete (MainMenu.vue / Dashboard.vue nav and
DEFAULT_LAYOUT changes, the duplicate-widget DEFAULT_LAYOUT fix, the
"Map"/"Case Map" nav keys) were already resolved by the manifest migration
and are intentionally not re-applied. The blanket phpcbf reformat from #272
is left out as out-of-scope; the codebase still has a pre-existing PHPCS
baseline tracked separately.
rubenvdlinde added a commit that referenced this pull request May 19, 2026
…do of #272) (#489)

Re-implements the still-relevant parts of #272 against current development
(after the json-manifest migration):

- Dashboard: remove card-in-card framing (background/border/border-radius)
  and inner scrollbars from the DeadlineAlerts / StalledCases /
  TaskDueReminders widgets so they sit cleanly inside the manifest
  dashboard tiles.
- i18n: wrap the "Unknown" fallback labels in dashboardHelpers.js and
  doorlooptijdHelpers.js with t('procest', ...); add the missing dashboard
  translation keys (All cases active, No task reminders, SLA Compliance,
  View all deadline alerts) to l10n/{en,nl}.{js,json} with Dutch
  translations; drop four malformed extraction-artifact keys
  ("Case created with type \", "Case type \", "Status changed from/to \")
  that left l10n/en.js syntactically broken.
- Headers: fix the @author email typo (dev@conductio.nl -> info@conduction.nl)
  in lib/ and appinfo/routes.php.

Parts of #272 that are now obsolete (MainMenu.vue / Dashboard.vue nav and
DEFAULT_LAYOUT changes, the duplicate-widget DEFAULT_LAYOUT fix, the
"Map"/"Case Map" nav keys) were already resolved by the manifest migration
and are intentionally not re-applied. The blanket phpcbf reformat from #272
is left out as out-of-scope; the codebase still has a pre-existing PHPCS
baseline tracked separately.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants