aboutsummaryrefslogtreecommitdiffstats
path: root/web_src/css
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2024-03-17 04:21:14 +0100
committerGitHub <noreply@github.com>2024-03-17 11:21:14 +0800
commit4e547822f348c2963e0db33135b45d43dfc58df8 (patch)
tree1707735fec66ced0e261e9d43c96bbef1cd4f762 /web_src/css
parent43aa914b1750add631698a7fd57d76f743b0489b (diff)
downloadgitea-4e547822f348c2963e0db33135b45d43dfc58df8.tar.gz
gitea-4e547822f348c2963e0db33135b45d43dfc58df8.zip
Remove fomantic message module (#29856)
Remove this CSS-only module, which gives a nice reduction in CSS size. Should look exactly like before.
Diffstat (limited to 'web_src/css')
-rw-r--r--web_src/css/base.css67
-rw-r--r--web_src/css/index.css1
-rw-r--r--web_src/css/modules/message.css99
3 files changed, 100 insertions, 67 deletions
diff --git a/web_src/css/base.css b/web_src/css/base.css
index 6a5f923281..ea5ba9ce87 100644
--- a/web_src/css/base.css
+++ b/web_src/css/base.css
@@ -510,73 +510,6 @@ ol.ui.list li,
visibility: visible !important;
}
-.ui.message {
- background: var(--color-box-body);
- color: var(--color-text);
- box-shadow: none !important;
- border: 1px solid var(--color-secondary);
-}
-
-.ui.info.message .header,
-.ui.blue.message .header {
- color: var(--color-blue);
-}
-
-.ui.info.message,
-.ui.attached.info.message,
-.ui.blue.message,
-.ui.attached.blue.message {
- background: var(--color-info-bg);
- color: var(--color-info-text);
- border-color: var(--color-info-border);
-}
-
-.ui.success.message .header,
-.ui.positive.message .header,
-.ui.green.message .header {
- color: var(--color-green);
-}
-
-.ui.success.message,
-.ui.attached.success.message,
-.ui.positive.message,
-.ui.attached.positive.message {
- background: var(--color-success-bg);
- color: var(--color-success-text);
- border-color: var(--color-success-border);
-}
-
-.ui.error.message .header,
-.ui.negative.message .header,
-.ui.red.message .header {
- color: var(--color-red);
-}
-
-.ui.error.message,
-.ui.attached.error.message,
-.ui.red.message,
-.ui.attached.red.message,
-.ui.negative.message,
-.ui.attached.negative.message {
- background: var(--color-error-bg);
- color: var(--color-error-text);
- border-color: var(--color-error-border);
-}
-
-.ui.warning.message .header,
-.ui.yellow.message .header {
- color: var(--color-yellow);
-}
-
-.ui.warning.message,
-.ui.attached.warning.message,
-.ui.yellow.message,
-.ui.attached.yellow.message {
- background: var(--color-warning-bg);
- color: var(--color-warning-text);
- border-color: var(--color-warning-border);
-}
-
.ui.error.header {
background: var(--color-error-bg) !important;
color: var(--color-error-text) !important;
diff --git a/web_src/css/index.css b/web_src/css/index.css
index ab925a4aa0..f6e4c196e6 100644
--- a/web_src/css/index.css
+++ b/web_src/css/index.css
@@ -12,6 +12,7 @@
@import "./modules/divider.css";
@import "./modules/svg.css";
@import "./modules/flexcontainer.css";
+@import "./modules/message.css";
@import "./shared/flex-list.css";
@import "./shared/milestone.css";
diff --git a/web_src/css/modules/message.css b/web_src/css/modules/message.css
new file mode 100644
index 0000000000..22dd03232b
--- /dev/null
+++ b/web_src/css/modules/message.css
@@ -0,0 +1,99 @@
+.ui.message {
+ background: var(--color-box-body);
+ color: var(--color-text);
+ border: 1px solid var(--color-secondary);
+ position: relative;
+ min-height: 1em;
+ margin: 1em 0;
+ padding: 1em 1.5em;
+ border-radius: var(--border-radius);
+}
+
+.ui.message:first-child {
+ margin-top: 0;
+}
+
+.ui.message:last-child {
+ margin-bottom: 0;
+}
+
+.ui.attached.message {
+ margin-bottom: -1px;
+ border-radius: var(--border-radius) var(--border-radius) 0 0;
+ margin-left: -1px;
+ margin-right: -1px;
+}
+
+.ui.attached + .ui.attached.message:not(.top):not(.bottom) {
+ margin-top: -1px;
+ border-radius: 0;
+}
+
+.ui.bottom.attached.message {
+ margin-top: -1px;
+ border-radius: 0 0 var(--border-radius) var(--border-radius);
+}
+
+.ui.bottom.attached.message:not(:last-child) {
+ margin-bottom: 1em;
+}
+
+.ui.info.message .header,
+.ui.blue.message .header {
+ color: var(--color-blue);
+}
+
+.ui.info.message,
+.ui.attached.info.message,
+.ui.blue.message,
+.ui.attached.blue.message {
+ background: var(--color-info-bg);
+ color: var(--color-info-text);
+ border-color: var(--color-info-border);
+}
+
+.ui.success.message .header,
+.ui.positive.message .header,
+.ui.green.message .header {
+ color: var(--color-green);
+}
+
+.ui.success.message,
+.ui.attached.success.message,
+.ui.positive.message,
+.ui.attached.positive.message {
+ background: var(--color-success-bg);
+ color: var(--color-success-text);
+ border-color: var(--color-success-border);
+}
+
+.ui.error.message .header,
+.ui.negative.message .header,
+.ui.red.message .header {
+ color: var(--color-red);
+}
+
+.ui.error.message,
+.ui.attached.error.message,
+.ui.red.message,
+.ui.attached.red.message,
+.ui.negative.message,
+.ui.attached.negative.message {
+ background: var(--color-error-bg);
+ color: var(--color-error-text);
+ border-color: var(--color-error-border);
+}
+
+.ui.warning.message .header,
+.ui.yellow.message .header {
+ color: var(--color-yellow);
+}
+
+.ui.warning.message,
+.ui.attached.warning.message,
+.ui.yellow.message,
+.ui.attached.yellow.message {
+ background: var(--color-warning-bg);
+ color: var(--color-warning-text);
+ border-color: var(--color-warning-border);
+}