style: adopt the E&P corporate design tokens and components
This commit is contained in:
1 parent
126a0680db
commit
acd8e78e55
12 files changed
+120
-49
No files matched your search
@@ -8,3 +8,18 @@
|
||||
@import "./components/timeline.css";
|
||||
@import "./components/mail-body.css";
|
||||
@import "./components/questionnaire.css";
|
||||
|
||||
/* the entries of the header's account menu (_partials/_user_menu.html.twig) */
|
||||
.user-menu-item {
|
||||
@apply flex items-center gap-x-3 px-4 py-2 text-ink no-underline hover:bg-page hover:text-brand;
|
||||
}
|
||||
|
||||
/* white box on the light blue page, as the card of the apps portal (EP/apps frontend/components/ui.ts) */
|
||||
.card {
|
||||
@apply border border-line bg-white;
|
||||
}
|
||||
|
||||
/* heading of a section or card */
|
||||
.section-title {
|
||||
@apply text-base font-semibold uppercase tracking-wide text-brand;
|
||||
}
|
||||
+42
-3
@@ -6,12 +6,45 @@
|
||||
|
||||
@source inline("rotate-90");
|
||||
|
||||
/*
|
||||
* Corporate design of the internal E&P tools, as defined by the apps portal (Gitea EP/apps,
|
||||
* frontend/app/globals.css) and ported to Symfony by epbms: Lato, deep blue as the brand colour,
|
||||
* magenta only for the main action, square shapes, light blue page.
|
||||
* Status colours (green, red, amber) always come with text, never alone.
|
||||
*/
|
||||
@theme {
|
||||
--font-sans: Lato, sans-serif;
|
||||
--font-weight-semibold: 700;
|
||||
--font-weight-bold: 900;
|
||||
--color-primary: #3d8ccb;
|
||||
--color-secondary: #f9c700;
|
||||
|
||||
/* square everywhere; rounded-full stays round. Plain `rounded` reads --radius. */
|
||||
--radius: 0px;
|
||||
--radius-xs: 0px;
|
||||
--radius-sm: 0px;
|
||||
--radius-md: 0px;
|
||||
--radius-lg: 0px;
|
||||
--radius-xl: 0px;
|
||||
--radius-2xl: 0px;
|
||||
--radius-3xl: 0px;
|
||||
--radius-4xl: 0px;
|
||||
|
||||
--color-brand: #18527b; /* E&P deep blue, 8.5:1 on white */
|
||||
--color-brand-dark: #103c5b;
|
||||
--color-brand-mid: #165883;
|
||||
--color-brand-bright: #009fff; /* underlines and focus, never text */
|
||||
--color-brand-light: #e3eef8;
|
||||
|
||||
--color-page: #ebf3fa; /* page background */
|
||||
--color-line: #d8e3ed; /* borders */
|
||||
--color-ink: #27272a; /* text */
|
||||
--color-muted: #52525b; /* secondary text, 7.7:1 on white */
|
||||
|
||||
--color-accent: #c4097c; /* magenta of the main action */
|
||||
--color-accent-from: #960167;
|
||||
--color-accent-to: #fa1a8c;
|
||||
|
||||
/* the colour name the templates were written with, now on the brand colour */
|
||||
--color-primary: var(--color-brand);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -24,7 +57,7 @@
|
||||
::before,
|
||||
::backdrop,
|
||||
::file-selector-button {
|
||||
border-color: var(--color-gray-200, currentcolor);
|
||||
border-color: var(--color-line, currentcolor);
|
||||
}
|
||||
|
||||
button:not(:disabled),
|
||||
@@ -43,4 +76,10 @@
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: var(--color-gray-300) transparent;
|
||||
}
|
||||
|
||||
/* visible keyboard focus everywhere (WCAG 2.4.7) */
|
||||
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
|
||||
outline: 3px solid var(--color-brand-bright);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
}
|
||||
@@ -1,16 +1,28 @@
|
||||
/*
|
||||
* Buttons as in the apps portal (EP/apps frontend/components/ui.ts): square, small bold uppercase.
|
||||
* The default is filled brand blue; magenta (.btn--cta) only for the one main action of a page.
|
||||
*/
|
||||
.btn {
|
||||
@apply inline-flex space-x-1 justify-center items-center rounded-lg text-sm uppercase font-semibold py-2.5 px-4;
|
||||
@apply bg-primary text-white hover:bg-primary/80 shadow-md disabled:opacity-50 disabled:cursor-not-allowed;
|
||||
@apply inline-flex space-x-1 justify-center items-center text-xs uppercase tracking-wide font-semibold py-2.5 px-4 no-underline transition-colors;
|
||||
@apply bg-brand text-white hover:bg-brand-dark disabled:opacity-50 disabled:cursor-not-allowed;
|
||||
}
|
||||
|
||||
.btn--small {
|
||||
@apply text-xs py-1 px-2 rounded-md;
|
||||
@apply py-1 px-2;
|
||||
}
|
||||
|
||||
.btn--secondary {
|
||||
@apply bg-secondary text-gray-800 hover:bg-secondary/80;
|
||||
@apply border border-brand bg-white text-brand hover:bg-brand hover:text-white;
|
||||
}
|
||||
|
||||
.btn--active {
|
||||
@apply shadow-none;
|
||||
.btn--cta {
|
||||
background-image: linear-gradient(120deg, var(--color-accent-from), #9e036a 40%, var(--color-accent-to));
|
||||
}
|
||||
|
||||
.btn--cta:hover {
|
||||
background-image: linear-gradient(120deg, #7d0156, #8a035d 40%, #e3107c);
|
||||
}
|
||||
|
||||
.btn--cta:disabled {
|
||||
background-image: none;
|
||||
}
|
||||
@@ -20,12 +20,13 @@ tbody {
|
||||
@apply bg-white;
|
||||
}
|
||||
|
||||
/* rows and head as the table head of the apps portal (EP/apps frontend/components/ui.ts) */
|
||||
tr {
|
||||
@apply border border-gray-300;
|
||||
@apply border-b border-line;
|
||||
}
|
||||
|
||||
th {
|
||||
@apply px-4 py-2 bg-gray-200 text-left leading-4 font-bold text-primary align-top;
|
||||
@apply px-4 py-2 bg-white border-b-2 border-brand text-left text-[11px] leading-4 font-semibold uppercase tracking-wide text-brand align-top;
|
||||
}
|
||||
|
||||
td {
|
||||
@@ -38,5 +39,5 @@ table.horizontal td {
|
||||
}
|
||||
|
||||
.data-table tbody tr {
|
||||
@apply hover:bg-gray-100;
|
||||
@apply hover:bg-brand-light/50;
|
||||
}
|
||||
@@ -3,8 +3,8 @@
|
||||
.flatpickr-day.selected,
|
||||
.flatpickr-day.selected:hover,
|
||||
.flatpickr-day.selected:focus {
|
||||
background-color: var(--color-secondary);
|
||||
border-color: var(--color-secondary);
|
||||
background-color: var(--color-brand);
|
||||
border-color: var(--color-brand);
|
||||
}
|
||||
|
||||
.flatpickr-monthDropdown-months,
|
||||
|
||||
@@ -1,20 +1,23 @@
|
||||
@import "toastify-js/src/toastify.css";
|
||||
|
||||
.toastify {
|
||||
@apply shadow-lg rounded-sm;
|
||||
@apply max-w-sm border-l-4 px-4 py-3 text-sm shadow-lg;
|
||||
background: none;
|
||||
}
|
||||
|
||||
/* in the colours of the alerts, as in epbms */
|
||||
.toastify--success {
|
||||
@apply text-gray-100;
|
||||
background: var(--color-emerald-600);
|
||||
@apply border-emerald-700 bg-emerald-50 text-emerald-950;
|
||||
}
|
||||
|
||||
.toastify--warning {
|
||||
@apply text-gray-100;
|
||||
background: var(--color-red-600);
|
||||
@apply border-red-700 bg-red-50 text-red-950;
|
||||
}
|
||||
|
||||
.toastify--info {
|
||||
@apply text-gray-100;
|
||||
background: var(--color-blue-600);
|
||||
@apply border-brand bg-brand-light text-ink;
|
||||
}
|
||||
|
||||
.toastify .toast-close {
|
||||
@apply ml-3 text-current opacity-60 hover:opacity-100;
|
||||
}
|
||||
Reference in new issue
Block a user