From c5c24d2b6b0b53cfccc2102fae055f5716cb20a2 Mon Sep 17 00:00:00 2001 From: Tienson Qin Date: Thu, 21 May 2026 13:47:00 +0800 Subject: [PATCH] fix: stabilize cmdk page result test id --- src/main/frontend/components/cmdk/core.cljs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/frontend/components/cmdk/core.cljs b/src/main/frontend/components/cmdk/core.cljs index 7a457f3106..338c676c40 100644 --- a/src/main/frontend/components/cmdk/core.cljs +++ b/src/main/frontend/components/cmdk/core.cljs @@ -347,11 +347,14 @@ current-page? (and current-page-uuid (= current-page-uuid result-page-id)) icon (icon-component/get-node-icon-cp entity {:ignore-current-icon? true}) - title (:block.temp/unique-title page)] + title (:block.temp/unique-title page) + plain-title (block-handler/block-unique-title entity + :alias (:block/title source-page) + :truncate? false)] (hash-map :icon icon :icon-theme :gray :text (if (string/includes? title "$pfts_2lqh>$") ; sqlite matched - [:span {"data-testid" title} + [:span {"data-testid" plain-title} (highlight-content-query title input)] title) :header (when (:block/parent entity)