[PR #7882] [MERGED] Add ability to create tags on the fly in tag autocomplete #136261

Closed
opened 2026-06-17 20:55:44 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/actualbudget/actual/pull/7882
Author: @alecbakholdin
Created: 5/17/2026
Status: Merged
Merged: 5/19/2026
Merged by: @matt-fidd

Base: masterHead: tag-autocomplete-create-tags


📝 Commits (10+)

  • a0b483a [AI] Make TypeScript work in test files across packages
  • 909649f [AI] Address review feedback on test type fixes
  • c250762 [AI] Drop tsconfig.build.json for loot-core and api
  • a792bf4 first pass at implementation
  • 20f6134 finished implementing what I feel would be a good user experience
  • dff8874 padding update
  • c2a7838 added ability to use tab to select
  • c1cfc17 release notes
  • 3dab7fc updated release notes
  • 4c5c470 auto highlights first entry

📊 Changes

11 files changed (+263 additions, -87 deletions)

View changed files

📝 packages/desktop-client/src/components/autocomplete/TagAutocomplete.tsx (+92 -42)
📝 packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx (+69 -4)
📝 packages/desktop-client/src/components/tags/TagCreationRow.tsx (+15 -8)
📝 packages/desktop-client/src/components/tags/TagEditor.tsx (+1 -1)
📝 packages/desktop-client/src/components/transactions/TransactionsTable.test.tsx (+33 -3)
📝 packages/desktop-client/src/hooks/useCursorPosition.ts (+22 -19)
📝 packages/desktop-client/src/hooks/useTagCSS.ts (+10 -3)
📝 packages/desktop-client/src/hooks/useTags.ts (+8 -4)
📝 packages/loot-core/src/server/db/index.ts (+0 -2)
📝 packages/loot-core/src/server/tags/app.ts (+7 -1)
upcoming-release-notes/7882.md (+6 -0)

📄 Description

Description

Following #7654, made some improvements and adjustments:

  1. Found some minor things I took issue with, some janky keyboard navigation, long tags weren't rendering properly, keyboard navigation was failing, so went around and fixed those.
  2. Added 'create tag' option to both mobile and desktop tag autocomplete.

Desktop

image

Mobile

image

Testing

Keyboard navigation, mouse/touch clicking.

Checklist

  • Release notes added (see link above)
  • No obvious regressions in affected areas
  • Self-review has been performed - I understand what each change in the code does and why it is needed

Bundle Stats

Bundle Files count Total bundle size % Changed
desktop-client 33 13.99 MB → 14 MB (+5.15 kB) +0.04%
loot-core 1 5.34 MB → 5.34 MB (+100 B) +0.00%
api 2 3.96 MB → 3.96 MB (+94 B) +0.00%
cli 1 7.97 MB 0%
crdt 1 11.12 kB 0%
View detailed bundle stats

desktop-client

Total

Files count Total bundle size % Changed
33 13.99 MB → 14 MB (+5.15 kB) +0.04%
Changeset
File Δ Size
src/components/autocomplete/TagAutocomplete.tsx 📈 +1.67 kB (+35.90%) 4.65 kB → 6.32 kB
src/hooks/useTags.ts 📈 +88 B (+16.33%) 539 B → 627 B
src/hooks/useTagCSS.ts 📈 +156 B (+12.86%) 1.18 kB → 1.34 kB
src/components/tags/TagEditor.tsx 📈 +129 B (+8.98%) 1.4 kB → 1.53 kB
src/components/mobile/transactions/TransactionEdit.tsx 📈 +2.76 kB (+4.07%) 67.79 kB → 70.55 kB
src/components/tags/TagCreationRow.tsx 📈 +193 B (+1.79%) 10.52 kB → 10.71 kB
src/hooks/useCursorPosition.ts 📈 +9 B (+0.93%) 971 B → 980 B
node_modules/fzf/dist/fzf.es.js 📈 +157 B (+0.72%) 21.25 kB → 21.4 kB
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger

Asset File Size % Changed
static/js/TransactionEdit.js 86.89 kB → 89.65 kB (+2.76 kB) +3.18%
static/js/Value.js 5.08 MB → 5.08 MB (+2.07 kB) +0.04%
static/js/index.js 2.02 MB → 2.02 MB (+322 B) +0.02%

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
static/js/BackgroundImage.js 121.09 kB 0%
static/js/FormulaEditor.js 962.55 kB 0%
static/js/ReportRouter.js 1.25 MB 0%
static/js/ScheduleEditForm.js 146.45 kB 0%
static/js/TransactionList.js 85.81 kB 0%
static/js/bankSyncUtils.js 54.15 kB 0%
static/js/ca.js 186.78 kB 0%
static/js/chart-theme.js 800.08 kB 0%
static/js/client.js 451.37 kB 0%
static/js/da.js 101.17 kB 0%
static/js/de.js 170.27 kB 0%
static/js/en-GB.js 9.25 kB 0%
static/js/en.js 197.83 kB 0%
static/js/es.js 178.71 kB 0%
static/js/extends.js 500.57 kB 0%
static/js/fr.js 178.61 kB 0%
static/js/indexeddb-main-thread-worker-e59fee74.js 13.46 kB 0%
static/js/it.js 165.02 kB 0%
static/js/narrow.js 364.2 kB 0%
static/js/nb-NO.js 148.08 kB 0%
static/js/nl.js 106.24 kB 0%
static/js/pt-BR.js 188.46 kB 0%
static/js/resize-observer.js 18.06 kB 0%
static/js/th.js 174.48 kB 0%
static/js/theme.js 31.77 kB 0%
static/js/uk.js 207.38 kB 0%
static/js/useFormatList.js 4.96 kB 0%
static/js/wide.js 453 B 0%
static/js/workbox-window.prod.es5.js 7.33 kB 0%
static/js/zh-Hans.js 116.92 kB 0%

loot-core

Total

Files count Total bundle size % Changed
1 5.34 MB → 5.34 MB (+100 B) +0.00%
Changeset
File Δ Size
home/runner/work/actual/actual/packages/loot-core/src/server/tags/app.ts 📈 +164 B (+9.74%) 1.64 kB → 1.8 kB
home/runner/work/actual/actual/packages/loot-core/src/server/db/index.ts 📉 -64 B (-0.31%) 20.42 kB → 20.35 kB
View detailed bundle breakdown

Added

Asset File Size % Changed
kcab.worker.DsubqxS5.js 0 B → 5.34 MB (+5.34 MB) -

Removed

Asset File Size % Changed
kcab.worker.BkJq0HmC.js 5.34 MB → 0 B (-5.34 MB) -100%

Bigger
No assets were bigger

Smaller
No assets were smaller

Unchanged
No assets were unchanged


api

Total

Files count Total bundle size % Changed
2 3.96 MB → 3.96 MB (+94 B) +0.00%
Changeset
File Δ Size
home/runner/work/actual/actual/packages/loot-core/src/server/tags/app.ts 📈 +158 B (+9.63%) 1.6 kB → 1.76 kB
home/runner/work/actual/actual/packages/loot-core/src/server/db/index.ts 📉 -64 B (-0.31%) 19.96 kB → 19.9 kB
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger

Asset File Size % Changed
index.js 3.96 MB → 3.96 MB (+94 B) +0.00%

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
models.js 0 B 0%

cli

Total

Files count Total bundle size % Changed
1 7.97 MB 0%
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger
No assets were bigger

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
cli.js 7.97 MB 0%

crdt

Total

Files count Total bundle size % Changed
1 11.12 kB 0%
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger
No assets were bigger

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
index.js 11.12 kB 0%

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/actualbudget/actual/pull/7882 **Author:** [@alecbakholdin](https://github.com/alecbakholdin) **Created:** 5/17/2026 **Status:** ✅ Merged **Merged:** 5/19/2026 **Merged by:** [@matt-fidd](https://github.com/matt-fidd) **Base:** `master` ← **Head:** `tag-autocomplete-create-tags` --- ### 📝 Commits (10+) - [`a0b483a`](https://github.com/actualbudget/actual/commit/a0b483a1d842f856e2e7acc3d1397b2c7059f18f) [AI] Make TypeScript work in test files across packages - [`909649f`](https://github.com/actualbudget/actual/commit/909649f05f7df48869e3daa0fee34df194543b60) [AI] Address review feedback on test type fixes - [`c250762`](https://github.com/actualbudget/actual/commit/c2507621dc1f9c4ba89865ca318fa1757c192791) [AI] Drop tsconfig.build.json for loot-core and api - [`a792bf4`](https://github.com/actualbudget/actual/commit/a792bf4ebe36699e78d8c1ce8acc54ef31bed22a) first pass at implementation - [`20f6134`](https://github.com/actualbudget/actual/commit/20f6134788dec9cea0eecdfc1ea87b73e0e9463e) finished implementing what I feel would be a good user experience - [`dff8874`](https://github.com/actualbudget/actual/commit/dff8874d99d78a2cfbd0fc1507824be599f7e251) padding update - [`c2a7838`](https://github.com/actualbudget/actual/commit/c2a7838418e9046f96d60a84f5848acb13fc2900) added ability to use tab to select - [`c1cfc17`](https://github.com/actualbudget/actual/commit/c1cfc174c098d2723adbbac76936e69a55ac1dfd) release notes - [`3dab7fc`](https://github.com/actualbudget/actual/commit/3dab7fc9450aa5e25ecf7f3e6d7040fa349a2e0e) updated release notes - [`4c5c470`](https://github.com/actualbudget/actual/commit/4c5c4703667d64ecf6c8ca2d388ae19c8649a0a9) auto highlights first entry ### 📊 Changes **11 files changed** (+263 additions, -87 deletions) <details> <summary>View changed files</summary> 📝 `packages/desktop-client/src/components/autocomplete/TagAutocomplete.tsx` (+92 -42) 📝 `packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx` (+69 -4) 📝 `packages/desktop-client/src/components/tags/TagCreationRow.tsx` (+15 -8) 📝 `packages/desktop-client/src/components/tags/TagEditor.tsx` (+1 -1) 📝 `packages/desktop-client/src/components/transactions/TransactionsTable.test.tsx` (+33 -3) 📝 `packages/desktop-client/src/hooks/useCursorPosition.ts` (+22 -19) 📝 `packages/desktop-client/src/hooks/useTagCSS.ts` (+10 -3) 📝 `packages/desktop-client/src/hooks/useTags.ts` (+8 -4) 📝 `packages/loot-core/src/server/db/index.ts` (+0 -2) 📝 `packages/loot-core/src/server/tags/app.ts` (+7 -1) ➕ `upcoming-release-notes/7882.md` (+6 -0) </details> ### 📄 Description <!-- Thank you for submitting a pull request! Make sure to follow the instructions to write release notes for your PR — it should only take a minute or two: https://actualbudget.org/docs/contributing/#writing-good-release-notes. Try running yarn generate:release-notes *before* pushing your PR for an interactive experience. --> ## Description Following #7654, made some improvements and adjustments: 1. Found some minor things I took issue with, some janky keyboard navigation, long tags weren't rendering properly, keyboard navigation was failing, so went around and fixed those. 2. Added 'create tag' option to both mobile and desktop tag autocomplete. Desktop <img width="288" height="75" alt="image" src="https://github.com/user-attachments/assets/d7db824e-7d3c-45b8-96b8-288bd736e986" /> Mobile <img width="409" height="113" alt="image" src="https://github.com/user-attachments/assets/818d527a-2398-4ec4-af55-15d6a06c394d" /> ## Testing Keyboard navigation, mouse/touch clicking. ## Checklist - [x] Release notes added (see link above) - [x] No obvious regressions in affected areas - [x] Self-review has been performed - I understand what each change in the code does and why it is needed <!--- actual-bot-sections ---> <!--- bundlestats-action-comment key:combined start ---> ### Bundle Stats Bundle | Files count | Total bundle size | % Changed ------ | ----------- | ----------------- | --------- desktop-client | 33 | 13.99 MB → 14 MB (+5.15 kB) | +0.04% loot-core | 1 | 5.34 MB → 5.34 MB (+100 B) | +0.00% api | 2 | 3.96 MB → 3.96 MB (+94 B) | +0.00% cli | 1 | 7.97 MB | 0% crdt | 1 | 11.12 kB | 0% <details> <summary>View detailed bundle stats</summary> #### desktop-client **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 33 | 13.99 MB → 14 MB (+5.15 kB) | +0.04% <details> <summary>Changeset</summary> File | Δ | Size ---- | - | ---- `src/components/autocomplete/TagAutocomplete.tsx` | 📈 +1.67 kB (+35.90%) | 4.65 kB → 6.32 kB `src/hooks/useTags.ts` | 📈 +88 B (+16.33%) | 539 B → 627 B `src/hooks/useTagCSS.ts` | 📈 +156 B (+12.86%) | 1.18 kB → 1.34 kB `src/components/tags/TagEditor.tsx` | 📈 +129 B (+8.98%) | 1.4 kB → 1.53 kB `src/components/mobile/transactions/TransactionEdit.tsx` | 📈 +2.76 kB (+4.07%) | 67.79 kB → 70.55 kB `src/components/tags/TagCreationRow.tsx` | 📈 +193 B (+1.79%) | 10.52 kB → 10.71 kB `src/hooks/useCursorPosition.ts` | 📈 +9 B (+0.93%) | 971 B → 980 B `node_modules/fzf/dist/fzf.es.js` | 📈 +157 B (+0.72%) | 21.25 kB → 21.4 kB </details> <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** Asset | File Size | % Changed ----- | --------- | --------- static/js/TransactionEdit.js | 86.89 kB → 89.65 kB (+2.76 kB) | +3.18% static/js/Value.js | 5.08 MB → 5.08 MB (+2.07 kB) | +0.04% static/js/index.js | 2.02 MB → 2.02 MB (+322 B) | +0.02% **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- static/js/BackgroundImage.js | 121.09 kB | 0% static/js/FormulaEditor.js | 962.55 kB | 0% static/js/ReportRouter.js | 1.25 MB | 0% static/js/ScheduleEditForm.js | 146.45 kB | 0% static/js/TransactionList.js | 85.81 kB | 0% static/js/bankSyncUtils.js | 54.15 kB | 0% static/js/ca.js | 186.78 kB | 0% static/js/chart-theme.js | 800.08 kB | 0% static/js/client.js | 451.37 kB | 0% static/js/da.js | 101.17 kB | 0% static/js/de.js | 170.27 kB | 0% static/js/en-GB.js | 9.25 kB | 0% static/js/en.js | 197.83 kB | 0% static/js/es.js | 178.71 kB | 0% static/js/extends.js | 500.57 kB | 0% static/js/fr.js | 178.61 kB | 0% static/js/indexeddb-main-thread-worker-e59fee74.js | 13.46 kB | 0% static/js/it.js | 165.02 kB | 0% static/js/narrow.js | 364.2 kB | 0% static/js/nb-NO.js | 148.08 kB | 0% static/js/nl.js | 106.24 kB | 0% static/js/pt-BR.js | 188.46 kB | 0% static/js/resize-observer.js | 18.06 kB | 0% static/js/th.js | 174.48 kB | 0% static/js/theme.js | 31.77 kB | 0% static/js/uk.js | 207.38 kB | 0% static/js/useFormatList.js | 4.96 kB | 0% static/js/wide.js | 453 B | 0% static/js/workbox-window.prod.es5.js | 7.33 kB | 0% static/js/zh-Hans.js | 116.92 kB | 0% </div> </details> --- #### loot-core **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 1 | 5.34 MB → 5.34 MB (+100 B) | +0.00% <details> <summary>Changeset</summary> File | Δ | Size ---- | - | ---- `home/runner/work/actual/actual/packages/loot-core/src/server/tags/app.ts` | 📈 +164 B (+9.74%) | 1.64 kB → 1.8 kB `home/runner/work/actual/actual/packages/loot-core/src/server/db/index.ts` | 📉 -64 B (-0.31%) | 20.42 kB → 20.35 kB </details> <details> <summary>View detailed bundle breakdown</summary> <div> **Added** Asset | File Size | % Changed ----- | --------- | --------- kcab.worker.DsubqxS5.js | 0 B → 5.34 MB (+5.34 MB) | - **Removed** Asset | File Size | % Changed ----- | --------- | --------- kcab.worker.BkJq0HmC.js | 5.34 MB → 0 B (-5.34 MB) | -100% **Bigger** No assets were bigger **Smaller** No assets were smaller **Unchanged** No assets were unchanged </div> </details> --- #### api **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 2 | 3.96 MB → 3.96 MB (+94 B) | +0.00% <details> <summary>Changeset</summary> File | Δ | Size ---- | - | ---- `home/runner/work/actual/actual/packages/loot-core/src/server/tags/app.ts` | 📈 +158 B (+9.63%) | 1.6 kB → 1.76 kB `home/runner/work/actual/actual/packages/loot-core/src/server/db/index.ts` | 📉 -64 B (-0.31%) | 19.96 kB → 19.9 kB </details> <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** Asset | File Size | % Changed ----- | --------- | --------- index.js | 3.96 MB → 3.96 MB (+94 B) | +0.00% **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- models.js | 0 B | 0% </div> </details> --- #### cli **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 1 | 7.97 MB | 0% <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** No assets were bigger **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- cli.js | 7.97 MB | 0% </div> </details> --- #### crdt **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 1 | 11.12 kB | 0% <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** No assets were bigger **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- index.js | 11.12 kB | 0% </div> </details> </details> <!--- bundlestats-action-comment key:combined end ---> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-06-17 20:55:44 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#136261