From 8e4a73e49303537cd320ec2b975661862315306a Mon Sep 17 00:00:00 2001 From: WTIFS <9314475+WTIFS@users.noreply.github.com> Date: Mon, 25 Nov 2024 20:04:44 +0800 Subject: [PATCH] feat: highlight diffs for properties (#5282) * feat: support properties diff * feat: support gray scale diff * style: add semicolon * feat: support diff in history * feat: adjust ui * style: remove redundant codes * style: recover original css * feat: update css * feat: update CHANGES.md --- CHANGES.md | 1 + .../main/resources/static/config/diff.html | 27 +++-- .../main/resources/static/config/history.html | 13 +- .../src/main/resources/static/i18n/en.json | 1 + .../src/main/resources/static/i18n/zh-CN.json | 19 +-- .../controller/config/DiffConfigController.js | 13 +- .../config/ReleaseHistoryController.js | 9 ++ .../scripts/directive/diff-directive.js | 1 + .../directive/release-modal-directive.js | 4 + .../directive/show-text-modal-directive.js | 5 +- .../resources/static/styles/common-style.css | 19 ++- .../static/views/component/diff.html | 2 +- .../static/views/component/release-modal.html | 112 ++++++++---------- .../views/component/show-text-modal.html | 12 +- 14 files changed, 139 insertions(+), 99 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index d62918c565f..c584794bdc7 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -21,6 +21,7 @@ Apollo 2.4.0 * [Feature: Added the value length limit function for AppId-level configuration items](https://github.com/apolloconfig/apollo/pull/5264) * [Fix: ensure clusters order in envClusters open api](https://github.com/apolloconfig/apollo/pull/5277) * [Fix: bump xstream from 1.4.20 to 1.4.21 to fix CVE-2024-47072](https://github.com/apolloconfig/apollo/pull/5280) +* [Feature: highlight diffs for properties](https://github.com/apolloconfig/apollo/pull/5282) ------------------ All issues and pull requests are [here](https://github.com/apolloconfig/apollo/milestone/15?closed=1) diff --git a/apollo-portal/src/main/resources/static/config/diff.html b/apollo-portal/src/main/resources/static/config/diff.html index bbfc3098ee5..08ecbacea9d 100644 --- a/apollo-portal/src/main/resources/static/config/diff.html +++ b/apollo-portal/src/main/resources/static/config/diff.html @@ -127,31 +127,38 @@