mirror of
https://github.com/charmbracelet/glow
synced 2024-11-10 14:14:17 +00:00
Fix regression where items stashed in the pager were treated as local
This commit is contained in:
parent
d7974f035c
commit
2e7b0ec60f
1 changed files with 5 additions and 2 deletions
|
@ -215,8 +215,11 @@ func pagerUpdate(msg tea.Msg, m pagerModel) (pagerModel, tea.Cmd) {
|
|||
return m, nil
|
||||
}
|
||||
case "m":
|
||||
isStashed := m.currentDocument.markdownType == stashedMarkdown ||
|
||||
m.currentDocument.markdownType == convertedMarkdown
|
||||
|
||||
// Users can only set the note on user-stashed markdown
|
||||
if m.currentDocument.markdownType != stashedMarkdown {
|
||||
if !isStashed {
|
||||
break
|
||||
}
|
||||
|
||||
|
@ -338,7 +341,7 @@ func pagerView(m pagerModel) string {
|
|||
|
||||
func pagerStatusBarView(b *strings.Builder, m pagerModel) {
|
||||
var (
|
||||
isStashed bool = m.currentDocument.markdownType == stashedMarkdown
|
||||
isStashed bool = m.currentDocument.markdownType == stashedMarkdown || m.currentDocument.markdownType == convertedMarkdown
|
||||
showStatusMessage bool = m.state == pagerStateStatusMessage
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue