From 620e81b7fa3808500ca5f6a0eef6dcd1e2274e78 Mon Sep 17 00:00:00 2001 From: HynoR <20227709+HynoR@users.noreply.github.com> Date: Mon, 5 Jan 2026 11:23:55 +0800 Subject: [PATCH 1/3] fix: Update regex patterns for log highlighting in custom component --- .../src/components/log/custom-hightlight/index.vue | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/frontend/src/components/log/custom-hightlight/index.vue b/frontend/src/components/log/custom-hightlight/index.vue index f8c8a71fde8a..d404cc830ff2 100644 --- a/frontend/src/components/log/custom-hightlight/index.vue +++ b/frontend/src/components/log/custom-hightlight/index.vue @@ -41,25 +41,29 @@ const nginxRules: TokenRule[] = [ pattern: /\[(crit|error)\]/g, color: '#E74C3C', }, - { type: 'path', - pattern: /(?<=[\s"])\/[^"\s]+(?:\.\w+)?(?:\?\w+=\w+)?/g, + pattern: /(?<=[\s"])\/[^\s"]*/g, color: '#B87A2B', }, { type: 'http-method', - pattern: /(?<=)(?:GET|POST|PUT|DELETE|PATCH|HEAD|OPTIONS)(?=\s)/g, + pattern: /\b(GET|POST|PUT|DELETE|PATCH|HEAD|OPTIONS)\b/g, color: '#27AE60', }, { type: 'status-success', - pattern: /\s(2\d{2})\s/g, + pattern: /(?<=")\s(2\d{2})\b/g, color: '#2ECC71', }, + { + type: 'status-redirect', + pattern: /(?<=")\s(3\d{2})\b/g, + color: '#F39C12', + }, { type: 'status-error', - pattern: /\s([45]\d{2})\s/g, + pattern: /(?<=")\s([45]\d{2})\b/g, color: '#E74C3C', }, { From f5e6873403a802e3dc00c83d1f3631a291e69f1a Mon Sep 17 00:00:00 2001 From: HynoR <20227709+HynoR@users.noreply.github.com> Date: Mon, 5 Jan 2026 12:11:47 +0800 Subject: [PATCH 2/3] feat: Add new regex pattern for HTTP status codes highlighting in custom log component --- frontend/src/components/log/custom-hightlight/index.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/src/components/log/custom-hightlight/index.vue b/frontend/src/components/log/custom-hightlight/index.vue index d404cc830ff2..598ae4f67317 100644 --- a/frontend/src/components/log/custom-hightlight/index.vue +++ b/frontend/src/components/log/custom-hightlight/index.vue @@ -51,6 +51,11 @@ const nginxRules: TokenRule[] = [ pattern: /\b(GET|POST|PUT|DELETE|PATCH|HEAD|OPTIONS)\b/g, color: '#27AE60', }, + { + type: 'status-info', + pattern: /(?<=")\s(1\d{2})\b/g, + color: '#268785', + }, { type: 'status-success', pattern: /(?<=")\s(2\d{2})\b/g, From 48449b5ff310a24de6c7f9b9306fc42029674ad7 Mon Sep 17 00:00:00 2001 From: HynoR <20227709+HynoR@users.noreply.github.com> Date: Mon, 5 Jan 2026 12:12:35 +0800 Subject: [PATCH 3/3] refactor: Update HTTP status code regex patterns in custom log component for improved highlighting --- .../components/log/custom-hightlight/index.vue | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/frontend/src/components/log/custom-hightlight/index.vue b/frontend/src/components/log/custom-hightlight/index.vue index 598ae4f67317..2518ea33bd17 100644 --- a/frontend/src/components/log/custom-hightlight/index.vue +++ b/frontend/src/components/log/custom-hightlight/index.vue @@ -51,25 +51,25 @@ const nginxRules: TokenRule[] = [ pattern: /\b(GET|POST|PUT|DELETE|PATCH|HEAD|OPTIONS)\b/g, color: '#27AE60', }, - { - type: 'status-info', - pattern: /(?<=")\s(1\d{2})\b/g, - color: '#268785', - }, { type: 'status-success', pattern: /(?<=")\s(2\d{2})\b/g, color: '#2ECC71', }, + { + type: 'status-error', + pattern: /(?<=")\s([45]\d{2})\b/g, + color: '#E74C3C', + }, { type: 'status-redirect', pattern: /(?<=")\s(3\d{2})\b/g, color: '#F39C12', }, { - type: 'status-error', - pattern: /(?<=")\s([45]\d{2})\b/g, - color: '#E74C3C', + type: 'status-info', + pattern: /(?<=")\s(1\d{2})\b/g, + color: '#268785', }, { type: 'process-info',