Skip to content

feat: show all tags in tag mapper for icon setting#285

Merged
fiddur merged 2 commits intodevelopfrom
feat/tag-mapper-all-tags
Mar 1, 2026
Merged

feat: show all tags in tag mapper for icon setting#285
fiddur merged 2 commits intodevelopfrom
feat/tag-mapper-all-tags

Conversation

@fiddur
Copy link
Owner

@fiddur fiddur commented Feb 28, 2026

Summary

  • Tag mapper now shows all tags, not just Oura programmatic tags (UUIDs/tag_* prefixes)
  • Manual, lastfm-auto, and calendar tags appear in the mapper so users can set icons on any tag
  • Non-programmatic tags have their name field read-only (they already have human-readable names) but the icon field is editable

Changes

  • packages/api-spec: Added is_programmatic boolean to programmaticTagSchema to distinguish tags needing name mapping vs icon-only
  • apps/backend/src/db/tags.ts: getProgrammaticTags() now returns all tags — programmatic ones (with tag_key or matching UUID/tag_* patterns) and regular ones (grouped by tag name with isProgrammatic: false)
  • apps/backend/src/routes/tags-router.ts: GET /tags/programmatic passes is_programmatic flag and sets current_name to the tag name for non-programmatic tags
  • apps/backend/src/mcp/settings-tools.ts: MCP get_programmatic_tags tool updated with matching logic
  • apps/web/src/components/TagMappingsSettings.tsx:
    • Name input is read-only for non-programmatic tags
    • "Unmapped" highlighting only applies to programmatic tags without a name
    • Tag key column hidden for non-programmatic tags
    • Description updated to reflect broader scope
  • Integration tests: Updated existing tests and added new ones for non-programmatic tag inclusion

Previously, the tag mapper only showed Oura programmatic tags (UUIDs and
tag_* prefixes). Manual, lastfm-auto, and calendar tags were excluded,
making it impossible to set icons on those tags.

Now all tags appear in the tag mapper. Non-programmatic tags have their
name field read-only (since they already have human-readable names) but
the icon field is editable. An is_programmatic flag distinguishes which
tags need name mapping vs icon-only configuration.
@codecov
Copy link

codecov bot commented Feb 28, 2026

Codecov Report

❌ Patch coverage is 77.77778% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 31.49%. Comparing base (1adbaf3) to head (b71afca).
⚠️ Report is 3 commits behind head on develop.

Files with missing lines Patch % Lines
apps/backend/src/routes/tags-router.ts 0.00% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #285      +/-   ##
===========================================
+ Coverage    31.43%   31.49%   +0.06%     
===========================================
  Files          181      181              
  Lines        22986    22982       -4     
  Branches      1856     1860       +4     
===========================================
+ Hits          7225     7239      +14     
+ Misses       15727    15709      -18     
  Partials        34       34              
Flag Coverage Δ
backend 58.18% <77.77%> (+0.10%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Cover the new is_programmatic field and current_name logic for both
programmatic (Oura) and non-programmatic (manual, lastfm-auto, calendar)
tags in the MCP tool handler.
@fiddur fiddur marked this pull request as ready for review March 1, 2026 08:04
@fiddur fiddur merged commit 7800e05 into develop Mar 1, 2026
6 checks passed
@fiddur fiddur deleted the feat/tag-mapper-all-tags branch March 1, 2026 08:04
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.

1 participant