Use solid borders and quieter colors in the forms and the editor.

This commit is contained in:
tim
2026-09-26 00:10:06 +02:00
parent a9daa6a792
commit 6c745ed6a9
3 changed files with 134 additions and 94 deletions
+106 -84
View File
@@ -1,8 +1,11 @@
/* /*
* The story editor (publish/editor.js). The colors are the ones of the * The story editor (publish/editor.js). The size follows the TinyMCE 5
* TinyMCE "xxx" skin that it replaces, and the size and border follow the * settings of the live site: at most 450px wide, at least 300px high,
* TinyMCE 5 settings of the live site: at most 450px wide, at least 300px * resizable, with the toolbar on top.
* high, resizable, with the toolbar on top. *
* Colors: borders #b8c9be (lines inside the editor #dfe7e2), toolbar
* #f4f7f5, hover #e3ebe6, pressed #d2e2d8, and the site green #006633
* for focus and the main button.
*/ */
.xed { .xed {
box-sizing: border-box; box-sizing: border-box;
@@ -14,9 +17,12 @@
min-height: 300px; min-height: 300px;
overflow: hidden; overflow: hidden;
resize: both; resize: both;
border: 1px dashed #006633; border: 1px solid #b8c9be;
border-radius: 8px; border-radius: 8px;
background-color: #e2f0e2; background-color: #f4f7f5;
}
.xed:focus-within {
border-color: #006633;
} }
.xed-area { .xed-area {
@@ -39,23 +45,40 @@
margin: 1em 40px; margin: 1em 40px;
} }
/* The story textarea, shown in place of the editor by the source button */
.xed .xed-source {
box-sizing: border-box;
display: block;
flex: 1 1 300px;
width: 100%;
min-height: 0;
margin: 0;
padding: 8px;
border: 0;
border-radius: 0;
background-color: #ffffff;
color: #000000;
font: 10.5pt/1.5 "DejaVu Sans Mono", Menlo, Consolas, monospace;
resize: none;
outline: none;
}
.xed-toolbar { .xed-toolbar {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
flex: none; flex: none;
padding: 2px 0 4px; padding: 3px 2px;
border-bottom: 1px dashed #006633; border-bottom: 1px solid #dfe7e2;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
} }
.xed-group { .xed-group {
display: flex; display: flex;
gap: 2px; gap: 1px;
margin: 2px 0 0 2px; margin: 1px 0;
} }
.xed-group + .xed-group { .xed-group + .xed-group {
margin-left: 3px; margin-left: 4px;
padding-left: 3px; padding-left: 4px;
border-left: 1px solid #9ef89e; border-left: 1px solid #dfe7e2;
} }
.xed-btn { .xed-btn {
@@ -64,28 +87,34 @@
align-items: center; align-items: center;
justify-content: center; justify-content: center;
width: 28px; width: 28px;
height: 24px; height: 26px;
margin: 0; margin: 0;
padding: 0; padding: 0;
border: 1px solid transparent; border: 0;
border-radius: 0; border-radius: 4px;
background-color: #e0efe0; background: transparent;
color: #333333; color: #333333;
cursor: pointer; cursor: pointer;
} }
.xed-btn:hover, .xed-btn:hover {
background-color: #e3ebe6;
}
.xed-btn:focus-visible { .xed-btn:focus-visible {
background-color: #cde8cd; outline: 2px solid #006633;
border-color: #86f686; outline-offset: -2px;
outline: none;
} }
.xed-btn.xed-active { .xed-btn.xed-active {
background-color: #bfe7bf; background-color: #d2e2d8;
border-color: #86f686; color: #004d26;
}
.xed-btn:disabled {
background: transparent;
color: #333333;
opacity: 0.35;
cursor: default;
} }
.xed-btn svg { .xed-btn svg {
display: block; display: block;
filter: drop-shadow(0 1px 1px rgba(255, 255, 255, 0.75));
} }
/* Dialogs */ /* Dialogs */
@@ -93,7 +122,11 @@
position: fixed; position: fixed;
inset: 0; inset: 0;
z-index: 1000; z-index: 1000;
background-color: rgba(0, 0, 0, 0.3); background-color: rgba(0, 0, 0, 0.25);
}
/* A window that closes on a click outside it has a lighter backdrop */
.xed-modal-block.xed-modal-light {
background-color: rgba(0, 0, 0, 0.08);
} }
.xed-window { .xed-window {
position: fixed; position: fixed;
@@ -105,35 +138,42 @@
max-width: calc(100vw - 20px); max-width: calc(100vw - 20px);
max-height: calc(100vh - 20px); max-height: calc(100vh - 20px);
overflow: auto; overflow: auto;
border: 1px dashed #006633; border: 1px solid #b8c9be;
background-color: #e5fde5; border-radius: 8px;
background-color: #ffffff;
box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
color: #333333; color: #333333;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; font-family: "Noto Sans", "Verdana", sans-serif;
font-size: 14px; font-size: 11pt;
text-align: left; text-align: left;
} }
.xed-window-head { .xed-window-head {
display: flex; display: flex;
align-items: center; align-items: center;
padding: 9px 15px; padding: 10px 15px;
border-bottom: 1px dashed #006633; border-bottom: 1px solid #dfe7e2;
} }
.xed-title { .xed-title {
flex: 1; flex: 1;
padding-right: 10px; padding-right: 10px;
font-size: 20px; color: #006633;
font-size: 14pt;
font-weight: bold; font-weight: bold;
line-height: 20px; line-height: 1.3;
} }
.xed-close { .xed-close {
width: 28px;
height: 28px;
padding: 0; padding: 0;
border: 0; border: 0;
border-radius: 4px;
background: none; background: none;
color: #6d6d6d; color: #6d6d6d;
font: bold 20px/20px "Helvetica Neue", Helvetica, Arial, sans-serif; font: bold 20px/28px "Noto Sans", "Verdana", sans-serif;
cursor: pointer; cursor: pointer;
} }
.xed-close:hover { .xed-close:hover {
background-color: #e3ebe6;
color: #333333; color: #333333;
} }
.xed-window-body { .xed-window-body {
@@ -142,36 +182,37 @@
.xed-foot { .xed-foot {
display: flex; display: flex;
justify-content: flex-end; justify-content: flex-end;
gap: 3px; gap: 6px;
padding: 10px; padding: 10px 15px;
border-top: 1px dashed #006633; border-top: 1px solid #dfe7e2;
} }
.xed-button { .xed-button {
box-sizing: border-box; box-sizing: border-box;
height: 30px; min-width: 64px;
padding: 4px 8px; height: 32px;
border: 1px solid transparent; padding: 4px 12px;
border-radius: 0; border: 1px solid #b8c9be;
background-color: #e0efe0; border-radius: 6px;
background-color: #ffffff;
color: #333333; color: #333333;
font: 14px/20px "Helvetica Neue", Helvetica, Arial, sans-serif; font: 11pt/1.4 "Noto Sans", "Verdana", sans-serif;
cursor: pointer; cursor: pointer;
} }
.xed-button:hover, .xed-button:hover {
background-color: #f0f5f2;
}
.xed-button:focus-visible { .xed-button:focus-visible {
background-color: #cde8cd; outline: 2px solid #006633;
border-color: #86f686; outline-offset: 1px;
outline: none;
} }
.xed-button.xed-primary { .xed-button.xed-primary {
min-width: 52px; border-color: #006633;
background-color: #006dcc; background-color: #006633;
color: #ffffff; color: #ffffff;
font-weight: bold;
} }
.xed-button.xed-primary:hover, .xed-button.xed-primary:hover {
.xed-button.xed-primary:focus-visible { background-color: #00522a;
background-color: #005fb3;
border-color: transparent;
} }
/* Link dialog */ /* Link dialog */
@@ -195,17 +236,18 @@
box-sizing: border-box; box-sizing: border-box;
flex: 1; flex: 1;
min-width: 0; min-width: 0;
height: 30px; height: 32px;
padding: 0 4px; padding: 0 8px;
border: 1px solid #c5c5c5; border: 1px solid #b8c9be;
border-radius: 0; border-radius: 6px;
background-color: #ffffff; background-color: #ffffff;
color: #333333; color: #333333;
font: 14px "Helvetica Neue", Helvetica, Arial, sans-serif; font: 11pt "Noto Sans", "Verdana", sans-serif;
} }
.xed-textbox:focus { .xed-textbox:focus {
border-color: #59a5e1; border-color: #006633;
outline: none; outline: none;
box-shadow: 0 0 0 2px rgba(0, 102, 51, 0.15);
} }
/* Special character dialog */ /* Special character dialog */
@@ -224,15 +266,15 @@
min-width: 12px; min-width: 12px;
height: 20px; height: 20px;
padding: 2px; padding: 2px;
border: 1px dashed #006633; border: 1px solid #e3ebe6;
line-height: 20px; line-height: 20px;
text-align: center; text-align: center;
vertical-align: middle; vertical-align: middle;
cursor: default; cursor: pointer;
} }
.xed-charmap td:hover, .xed-charmap td:hover,
.xed-charmap td:focus-visible { .xed-charmap td:focus-visible {
background-color: #9ec49e; background-color: #d2e2d8;
outline: none; outline: none;
} }
.xed-charmap-preview { .xed-charmap-preview {
@@ -246,25 +288,5 @@
} }
.xed-charmap-name { .xed-charmap-name {
margin-top: 10px; margin-top: 10px;
font-size: 14px; font-size: 10.5pt;
}
/* Source code dialog */
.xed-source {
box-sizing: border-box;
display: block;
width: 600px;
max-width: 100%;
height: 500px;
max-height: calc(100vh - 160px);
padding: 4px;
border: 1px solid #59a5e1;
border-radius: 0;
background-color: #ffffff;
color: #333333;
font: 14px "Helvetica Neue", Helvetica, Arial, sans-serif;
resize: none;
}
.xed-source:focus {
outline: none;
} }
+3 -3
View File
@@ -24,9 +24,9 @@ var XxxEditor = (function () {
// Icons in a 16-unit box. "fill" paths are solid shapes; "stroke" paths // Icons in a 16-unit box. "fill" paths are solid shapes; "stroke" paths
// are lines, in their own box size. // are lines, in their own box size.
var ICONS = { var ICONS = {
bold: { fill: ["M4 2h4.8c2 0 3.4 1.2 3.4 3 0 1.1-.6 2-1.5 2.4 1.2.4 2 1.4 2 2.8 0 2.1-1.6 3.8-3.9 3.8H4z" + bold: { fill: ["M3.5 2h5.2c2.3 0 3.7 1.2 3.7 3.05 0 1.2-.6 2.1-1.6 2.6 1.3.4 2.2 1.5 2.2 3 0 2.1-1.6 3.35-4 3.35H3.5z" +
"M6.5 4.1v2.9h2c.9 0 1.5-.6 1.5-1.45S9.4 4.1 8.5 4.1z" + "M6.2 4.3v2.6h2.2c.9 0 1.4-.5 1.4-1.3s-.5-1.3-1.4-1.3z" +
"M6.5 9v3.9h2.4c1 0 1.7-.8 1.7-1.95S9.9 9 8.9 9z"] }, "M6.2 9.1v2.7h2.5c1 0 1.6-.5 1.6-1.35s-.6-1.35-1.6-1.35z"] },
italic: { fill: ["M6.5 2h6v1.8h-2.1L8.1 12.2h2.1V14h-6v-1.8h2.1l2.3-8.4H6.5z"] }, italic: { fill: ["M6.5 2h6v1.8h-2.1L8.1 12.2h2.1V14h-6v-1.8h2.1l2.3-8.4H6.5z"] },
alignleft: { fill: ["M1 2h14v2H1zM1 6h9v2H1zM1 10h14v2H1zM1 14h9v2H1z"] }, alignleft: { fill: ["M1 2h14v2H1zM1 6h9v2H1zM1 10h14v2H1zM1 14h9v2H1z"] },
aligncenter: { fill: ["M1 2h14v2H1zM3.5 6h9v2h-9zM1 10h14v2H1zM3.5 14h9v2h-9z"] }, aligncenter: { fill: ["M1 2h14v2H1zM3.5 6h9v2h-9zM1 10h14v2H1zM3.5 14h9v2h-9z"] },
+25 -7
View File
@@ -13,11 +13,18 @@ input {
} }
#main .grid .rightcolumn > input { #main .grid .rightcolumn > input {
display: block; display: block;
box-sizing: border-box;
width: 300px; width: 300px;
padding: 3px 8px;
font-size: 12pt; font-size: 12pt;
border: 1px dashed #006633; border: 1px solid #b8c9be;
border-radius: 8px; border-radius: 8px;
} }
#main .grid .rightcolumn > input:focus {
border-color: #006633;
outline: none;
box-shadow: 0 0 0 2px rgba(0, 102, 51, 0.15);
}
#main .grid .rightcolumn input#remember { #main .grid .rightcolumn input#remember {
margin-top: 7px; margin-top: 7px;
width: initial; width: initial;
@@ -39,10 +46,18 @@ input {
} }
#main .submission button { #main .submission button {
border: 1px dashed #006633; padding: 4px 14px;
border: 1px solid #006633;
border-radius: 6px;
background-color: #FFFFFF; background-color: #FFFFFF;
font-weight: bold; color: #006633;
font: bold 11pt "Noto Sans", "Verdana", sans-serif;
margin-right: 5px; margin-right: 5px;
cursor: pointer;
}
#main .submission button:hover {
background-color: #006633;
color: #FFFFFF;
} }
#main .grid #hidden { #main .grid #hidden {
display: block; display: block;
@@ -56,7 +71,7 @@ input {
#main .grid textarea.submission { #main .grid textarea.submission {
margin-top: 10px; margin-top: 10px;
border: 1px dotted #006633; border: 1px solid #b8c9be;
border-radius: 8px; border-radius: 8px;
font-size: 12pt; font-size: 12pt;
} }
@@ -112,7 +127,8 @@ div.note {
#uploadparent { #uploadparent {
height: 200px; height: 200px;
border: 1px dashed #006633; border: 1px solid #b8c9be;
border-radius: 8px;
margin-bottom: 10px; margin-bottom: 10px;
} }
#uploadparent>div { #uploadparent>div {
@@ -133,7 +149,9 @@ div.note {
} }
ul.error-box { ul.error-box {
border: 2px dotted red; border: 1px solid #cc0000;
border-radius: 8px;
background-color: #fff5f5;
padding: 10px 30px; padding: 10px 30px;
} }
fieldset.mi_group_prevacct ul.error-box { fieldset.mi_group_prevacct ul.error-box {
@@ -153,7 +171,7 @@ ul.error-box li {
} }
#captcha #recaptcha_image { #captcha #recaptcha_image {
margin-left: 120px; margin-left: 120px;
border: 1px dotted #006633; border: 1px solid #b8c9be;
border-radius: 8px; border-radius: 8px;
} }
#captcha .icons { #captcha .icons {