From 3e975beba1e03df4ea41c2b642711393c9737f1d Mon Sep 17 00:00:00 2001 From: Meng-Heng Date: Wed, 14 Jan 2026 12:07:14 +0700 Subject: [PATCH 01/27] feat: add search knowledge base title --- cdn/dev/css/kb-search.css | 33 +++++++++++++++++++++++++++++++++ knowledge-base/index.php | 39 +++++++++++++++++++++++++++++++++------ 2 files changed, 66 insertions(+), 6 deletions(-) create mode 100644 cdn/dev/css/kb-search.css diff --git a/cdn/dev/css/kb-search.css b/cdn/dev/css/kb-search.css new file mode 100644 index 000000000..8acbb54da --- /dev/null +++ b/cdn/dev/css/kb-search.css @@ -0,0 +1,33 @@ +.search-bar { + display: flex; + align-items: center; + width: 40vw; + height: 56px; + padding: 0 10px; + margin-bottom: 20px; + margin-left: 10px; + background-color: #eceef3; + border: 1px solid gray; +} + +.search-icon { + font-size: 20px; + opacity: 0.6; + margin-right: 10px; +} + +.search-bar form { + width: 100%; + display: flex; + flex-direction: row; +} + +.search-bar input { + flex: 1; + background: transparent; + border: none; + outline: none; + font-size: 18px; + width: 100%; + padding: 0 10px; +} diff --git a/knowledge-base/index.php b/knowledge-base/index.php index fe4f3b780..f5c428ee4 100644 --- a/knowledge-base/index.php +++ b/knowledge-base/index.php @@ -38,11 +38,11 @@ // Required head([ 'title' =>'Keyman Support | ' . $title, - 'css' => ['template.css','prism.css'], + 'css' => ['template.css','prism.css', 'kb-search.css'], 'showMenu' => true, 'index' => false ]); - + echo "

Knowledge Base index

"; if($id) { echo "

"; $pid = intval($id,10) - 1; @@ -55,19 +55,46 @@ $ParsedownAndAlerts = new \Keyman\Site\Common\GFMAlerts(); echo $ParsedownAndAlerts->text($kb); } else { - echo "

Knowledge Base index

"; - echo "