Skip to content

fix(types): shared types of the microservices - #595

Merged
BenPinet merged 12 commits into
nextfrom
fix/shared_types
Nov 20, 2026
Merged

BenPinet merged 12 commits into
nextfrom
fix/shared_types

Conversation

@JulienChampagnol

Copy link
Copy Markdown
Member

Summary

Uses the shared types of the microservices instead of declaring its own (Geode-solutions/OpenGeodeWeb-Microservice#35, Geode-solutions/OpenGeodeWeb-Back#296, Geode-solutions/OpenGeodeWeb-Viewer#206).

  • Geode object types: GeodeObjectType and ViewerObjectType come from @geode/opengeodeweb-microservice/data_types. The back responses, the allowed objects (Partial<Record<GeodeObjectType, AllowedObject>>) and the icons (Record<GeodeObjectType, string>, geodeObjectImage(geodeObjectType)) are keyed by it; HorizonStack3D gets a stratigraphic column icon.
  • Schema types, imported from the package defining them:
    • DataId, GeodeId from @geode/opengeodeweb-microservice/schema_types;
    • CRS from @geode/opengeodeweb-back/schema_types;
    • ColorRGB, ColorRGBA, Visibility, Opacity, EdgeWidth (was Width), PointSize (was Size), AttributeName, AttributeItem, AttributeRangeMinimum, AttributeRangeMaximum from @geode/opengeodeweb-viewer/schema_types.
  • app/types/style.ts is removed; app/types/identifiers.ts and app/types/attribute.ts only declare the front's own types.
  • ⚠️ The background and text colors are sent as {red, green, blue} (Viewer#206).

Test plan

  • Type check: same 143 errors as next
  • 410 unit tests pass, scene integration test passes with the Viewer
  • oxlint clean on the changed files

🤖 Generated with Claude Code

JulienChampagnol and others added 7 commits November 19, 2026 15:15
…b-Microservice

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every geode object type must have an icon: add the missing HorizonStack3D one, a stratigraphic column of horizons and erosions. The tooltip was always the type name, the map only keeps the image

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The icon of a geode object only takes a GeodeObjectType: the allowed objects map, its candidates and the object selector keep the type instead of plain strings

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The types the front declared itself come from the packages defining them:
- DataId and GeodeId from @geode/opengeodeweb-microservice/schema_types,
  app/types/identifiers.ts only declares the ids derived from them
- Visibility, Opacity, EdgeWidth (was Width), PointSize (was Size), AttributeName,
  AttributeItem and the attribute range bounds from
  @geode/opengeodeweb-viewer/schema_types
app/types/style.ts is removed, app/types/attribute.ts only declares the attribute
types of the front. The edges width of the mesh options was typed as a Size.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
JulienChampagnol and others added 4 commits November 20, 2026 15:06
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts:
#	internal/stores/data_style/scene.ts
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.

3 participants