diff options
| author | David Schlachter <t480-debian-git@schlachter.ca> | 2026-01-13 14:56:52 -0500 |
|---|---|---|
| committer | David Schlachter <t480-debian-git@schlachter.ca> | 2026-01-13 14:56:52 -0500 |
| commit | 3b059edbeca54bc62b1de5d2a8d923fb115716d8 (patch) | |
| tree | 4f9b66c15ca8268119a92e3fa314f37f5232782e | |
| parent | 173f2ad8a1ec5ee917d07595313ebd0dbcdf0910 (diff) | |
Only initialize progress bar when setting up
| -rw-r--r-- | ui.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -85,7 +85,6 @@ func initialModel(c *http.Client, db *sql.DB, apiURL, ankiDeck, ankiModel, rawDi wordInput: input, definitionViewport: textbox, - importProgress: progress.New(progress.WithDefaultGradient()), ankiDeck: ankiDeck, ankiModel: ankiModel, @@ -110,6 +109,7 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) { switch msg := msg.(type) { case isDictionaryEmptyMsg: if bool(msg) { // We need to populate the dictionary + m.importProgress = progress.New(progress.WithDefaultGradient()) return m, setupPopulator(&m.dp) } else { // The dictionary is ready m.dictionaryReady = true |
