mirror of
https://github.com/logseq/logseq.git
synced 2026-04-28 16:15:21 +00:00
fix: incorrect page title when 'hls__' is opened (#8697)
* dev: move 'hls-file?' to pdf-utils * dev: use 'hls-file?' instead of string comparison * fix: window title when hls file opened
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
[frontend.handler.ui :as ui-handler]
|
||||
[frontend.state :as state]
|
||||
[frontend.util :as util]
|
||||
[frontend.extensions.pdf.utils :as pdf-utils]
|
||||
[logseq.graph-parser.text :as text]
|
||||
[reitit.frontend.easy :as rfe]
|
||||
[frontend.context.i18n :refer [t]]))
|
||||
@@ -143,8 +144,9 @@
|
||||
(defn update-page-title!
|
||||
[route]
|
||||
(let [{:keys [data path-params]} route
|
||||
title (get-title (:name data) path-params)]
|
||||
(util/set-title! title)))
|
||||
title (get-title (:name data) path-params)
|
||||
hls? (pdf-utils/hls-file? title)]
|
||||
(util/set-title! (if hls? (pdf-utils/fix-local-asset-pagename title) title))))
|
||||
|
||||
(defn update-page-label!
|
||||
[route]
|
||||
|
||||
Reference in New Issue
Block a user