Skip to content

merge main to tooltips branch - #304

Merged
timothy-mugo merged 0 commit into
fix/make-tooltips-centeredfrom
main
Nov 3, 2026
Merged

timothy-mugo merged 0 commit into
fix/make-tooltips-centeredfrom
main

Conversation

@timothy-mugo

Copy link
Copy Markdown
Contributor

…ibility## Description

Type of change

  • Bug fix (fix:)
  • New feature (feat:)
  • Breaking change (BREAKING CHANGE:)
  • Refactor / chore (refactor: / chore:)
  • Documentation update (docs:)

Affected package(s)

  • @devgateway/dvz-ui-react
  • @devgateway/wp-react-lib
  • example only (no changeset needed)

Checklist

  • PR title follows Conventional Commits format
  • A changeset has been added (pnpm changeset) for any change to a published package
  • pnpm build passes locally
  • pnpm --filter @devgateway/* typecheck passes
  • No hardcoded credentials, internal URLs, client names, or PII introduced
  • Any new dependency has an Apache-2.0-compatible license

@timothy-mugo
timothy-mugo added this pull request to stack #305 November 3, 2026 12:09
Copilot AI lite review requested due to automatic review settings November 3, 2026 12:09
@timothy-mugo timothy-mugo changed the title fix: Fix map data parsing for Superset and Spring Boot payload compat… merge main to tooltips branch Nov 3, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Several active issues remain, including a critical ReferenceError on API-backed D3 map mounts and additional formatting, reset-state, logging, and prop-tracking bugs.

5 open issues
What changed in this PR

This pull request improves map-data compatibility across Superset, Spring Boot, and WordPress payloads while expanding tooltip support, responsive map behavior, and filter handling.

Changes:

  • Adds flexible map parsing for measures, dimensions, nested children, flat aggregates, and extra tooltip columns.
  • Adds recursive tooltip variables, currency formatting, row-level color overrides, and Senegal map support.
  • Updates post loading, filter behavior, responsive sizing, documentation, package versions, and changelogs.

This pull request requires changes.

File Summary Review status
packages/​react-lib/​wp-react-lib/​src/​providers/​PostProvider.jsx Tracks post type changes when fetching posts. Moderate issue: update the stored snapshot after comparisons (3 votes).
packages/​react-lib/​wp-react-lib/​package.json Bumps the WordPress library patch version. Reviewed
packages/​react-lib/​wp-react-lib/​CHANGELOG.md Documents the PostProvider fix. Reviewed
packages/​dvz-ui/​src/​scss/​themes/​default/​_map.scss Makes map SVGs fill responsive containers. Reviewed
packages/​dvz-ui/​src/​embeddable/​tabbedposts/​index.jsx Normalizes category values and handles missing post types. Reviewed
packages/​dvz-ui/​src/​embeddable/​map/​README.md Updates map label font-size documentation. Nit: document the data-extra-tooltip-columns attribute and behavior (1 vote).
packages/​dvz-ui/​src/​embeddable/​map/​mapHelpers.ts Removes obsolete device-specific map sizing constants. Reviewed
packages/​dvz-ui/​src/​embeddable/​map/​MapDataFrame.jsx Supports multiple measure, dimension, nested-child, and flat-payload formats. Reviewed
packages/​dvz-ui/​src/​embeddable/​map/​map.jsx Refines map dimensions, positioning, and responsive label scaling. Reviewed
packages/​dvz-ui/​src/​embeddable/​map/​index.jsx Adds Senegal support, extra tooltip columns, and filter normalization. Reviewed
packages/​dvz-ui/​src/​embeddable/​filter/​index.tsx Improves filter initialization when options become available. Reviewed
packages/​dvz-ui/​src/​embeddable/​filter-reset-button/​index.tsx Corrects changed-filter detection logic. Moderate issue: compare empty arrays instead of returning early (2 votes).
packages/​dvz-ui/​src/​embeddable/​data/​D3MapDataProvider.jsx Adds extra-column loading and editor parameter refresh handling. Critical issue: undeclared extraTooltipColumns causes API-backed maps to throw; moderate issue: remove or gate props logging (4 and 3 votes).
packages/​dvz-ui/​src/​embeddable/​d3Map/​Utils.jsx Adds recursive tooltip-variable extraction and color override helpers. Reviewed
packages/​dvz-ui/​src/​embeddable/​d3Map/​Tooltip.jsx Adds normalized tooltip variables and currency formatting. Moderate issue: capture the full currency expression, including spaces and symbols (4 votes).
packages/​dvz-ui/​src/​embeddable/​d3Map/​README.md Documents tooltip templates, formatting, color overrides, and extra API columns. Reviewed
packages/​dvz-ui/​src/​embeddable/​d3Map/​Legends.jsx Includes extra tooltip columns in legend requests. Reviewed
packages/​dvz-ui/​src/​embeddable/​d3Map/​LatLongLayer.jsx Adds expanded tooltip metadata and extra-column requests. Reviewed
packages/​dvz-ui/​src/​embeddable/​d3Map/​FlowLayer.jsx Adds improved flow tooltips and extra-column requests. Reviewed
packages/​dvz-ui/​src/​embeddable/​d3Map/​DataLayer.jsx Adds nested tooltip variables, color overrides, and extra-column requests. Reviewed
packages/​dvz-ui/​package.json Bumps the main UI package version. Reviewed
packages/​dvz-ui/​CHANGELOG.md Documents the map, tooltip, filter, and compatibility changes. Reviewed

Review effort: Lite

if (!waitForFilters || editing) {
console.log('📥 [D3 Map DataProvider] Initial data load triggered', { app, editing, waitForFilters });
this.loadData({ app, source, store, params, group });
this.loadData({ app, source, store, params, group, includeColumns: extraTooltipColumns });
const percentExpresion = /(\+?\%)[\(]([A-z0-9,.,-]+)\)/gi
const numericExpresion = /(\+?\#)[\(]([A-z0-9,.,-]+)\)/gi
const compactExpresion = /(\+?\#C)[\(]([A-z0-9,.,-]+)\)/gi
const currencyExpresion = /(\$)[\(]([A-Za-z0-9,.]+)\)/gi
waitForFilters,
editing
} = this.props
console.log("Current props in d3MapDataProvider", this.props);
Comment on lines +38 to 39
return initialValues.length !== filteredApplied.length ||
!initialValues.every(v => filteredApplied.includes(v));
Comment on lines +33 to 39
const prevProps = useRef({type, categories, locale, slug, taxonomy, page, perPage, search}).current;

useEffect(() => {

if (categories != prevProps.categories || locale != prevProps.locale || slug != prevProps.slug ||
if (type != prevProps.type || categories != prevProps.categories || locale != prevProps.locale || slug != prevProps.slug ||
taxonomy != prevProps.taxonomy || page != prevProps.page || perPage != prevProps.perPage || search != prevProps.search
) {
Copilot AI lite review requested due to automatic review settings November 3, 2026 13:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

Critical defects can cause an API-mode ReferenceError and repeated request loop, while the tooltip matching issue leaves documented currency names unsupported.

5 open issues

Review effort: Lite

Copilot AI lite review requested due to automatic review settings November 3, 2026 13:42
@timothy-mugo
timothy-mugo merged commit 5402e50 into main Nov 3, 2026
3 checks passed

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request. Check if the Files changed in this pull request are included in default exclusions.

Still open (5)

An error occurred while trying to automatically change base from fix/make-tooltips-centered to main November 3, 2026 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants