Consolidate and modernize SCSS into global styles
Move component-level styles into src/styles.scss and remove duplicated rules from several component SCSS files (app, topbar, about, algorithms, sorting, imprint, project dialog, projects, babylon-canvas). The global stylesheet now centralizes layout and typography (clamp-based sizing), sorting visualization & canvas rules, topbar/menu overrides, project/swiper styles, and shared utilities. This reduces duplication, improves responsiveness, and simplifies stylesheet management.
This commit is contained in:
@@ -1,183 +0,0 @@
|
||||
.about {
|
||||
display: grid;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
/* Hero block: Photo + Intro */
|
||||
.hero {
|
||||
display: grid;
|
||||
grid-template-columns: 425px 1fr;
|
||||
gap: 1.25rem;
|
||||
border-radius: 16px;
|
||||
background: var(--app-card-background);
|
||||
|
||||
.photo {
|
||||
align-items:flex-start; justify-content:center;
|
||||
img {
|
||||
display:block;
|
||||
width: 100%; height: auto;
|
||||
max-width: 425px;
|
||||
border-radius: 12px;
|
||||
box-shadow: 0 6px 24px rgba(0,0,0,.25);
|
||||
object-fit: cover;
|
||||
}
|
||||
}
|
||||
|
||||
.intro {
|
||||
display:flex; flex-direction:column; gap:.5rem;
|
||||
h1 { margin-top: .25rem }
|
||||
.lead { opacity:.9; margin: .25rem 0 0.5rem; }
|
||||
|
||||
.meta {
|
||||
display:flex; flex-direction:column; gap:.25rem; margin-bottom: 0.5rem;
|
||||
.row {
|
||||
display:flex; align-items:center; gap:.4rem;
|
||||
a { color: inherit; }
|
||||
}
|
||||
}
|
||||
|
||||
.actions {
|
||||
display:flex; gap:.5rem; flex-wrap:wrap; margin-top:.5rem;
|
||||
.mat-icon { margin-right:.25rem; }
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Skills block */
|
||||
.skills {
|
||||
padding: 5px;
|
||||
h2 { margin-top: .25rem; margin-left: .25rem; }
|
||||
.chip-groups {
|
||||
margin-left: .25rem;
|
||||
display:grid; gap:1rem;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
margin-bottom: .5rem;
|
||||
h3 { margin: .2rem 0 .4rem; font-size: .95rem; opacity:.85; }
|
||||
mat-chip-set {
|
||||
display:flex; flex-wrap:wrap; gap:.4rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Experience block */
|
||||
.experience {
|
||||
padding: 5px;
|
||||
h2 { margin-top: .25rem; margin-left: .25rem; }
|
||||
.xp-item {
|
||||
.xp-head {
|
||||
display:flex; align-items:baseline; gap:.5rem;
|
||||
.time { opacity:.75; font-size:.9rem; }
|
||||
}
|
||||
.xp-sub { opacity:.9; margin-bottom:.25rem; }
|
||||
ul { margin: .25rem 0 .5rem 1.15rem; }
|
||||
}
|
||||
}
|
||||
|
||||
/* Experience block */
|
||||
.projects {
|
||||
padding: 5px;
|
||||
h2 { margin-top: .25rem;margin-left: .25rem; }
|
||||
.xp-list {
|
||||
margin-left: .25rem;
|
||||
display: grid; gap: .75rem;
|
||||
}
|
||||
.xp-item {
|
||||
.xp-head {
|
||||
display:flex; align-items:baseline; gap:.5rem;
|
||||
.time { opacity:.75; font-size:.9rem; }
|
||||
}
|
||||
.xp-sub { opacity:.9; margin-bottom:.25rem; }
|
||||
ul { margin: .25rem 0 .5rem 1.15rem; }
|
||||
}
|
||||
}
|
||||
|
||||
/* Experience block */
|
||||
.education {
|
||||
padding: 5px;
|
||||
h2 { margin-top: .25rem;margin-left: .25rem; }
|
||||
.xp-list {
|
||||
margin-left: .25rem;
|
||||
display: grid; gap: .75rem;
|
||||
}
|
||||
.xp-item {
|
||||
.xp-head {
|
||||
display:flex; align-items:baseline; gap:.5rem;
|
||||
.time { opacity:.75; font-size:.9rem; }
|
||||
}
|
||||
.xp-sub { opacity:.9; margin-bottom:.25rem; }
|
||||
ul { margin: .25rem 0 .5rem 1.15rem; }
|
||||
}
|
||||
}
|
||||
|
||||
/* Responsive */
|
||||
@media (max-width: 900px) {
|
||||
.hero { grid-template-columns: 1fr; }
|
||||
.hero .photo { justify-content: flex-start; }
|
||||
.skills .chip-groups { grid-template-columns: 1fr; }
|
||||
}
|
||||
|
||||
.xp-head-grid {
|
||||
display: grid;
|
||||
grid-template-columns: calc(48px + .75rem) 1fr; /* 1: Logo, 2: Text */
|
||||
grid-template-rows: auto auto; /* 1: Role/Time, 2: Company */
|
||||
column-gap: .75rem;
|
||||
}
|
||||
|
||||
.logo-wrap {
|
||||
grid-row: 1 / span 2;
|
||||
grid-column: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.company-logo {
|
||||
width: 48px;
|
||||
height: 48px;
|
||||
object-fit: contain;
|
||||
opacity: .9;
|
||||
border-radius: 10%;
|
||||
background-color: var(--app-logo-bg);
|
||||
}
|
||||
|
||||
|
||||
.head-row {
|
||||
grid-row: 1;
|
||||
grid-column: 2;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: baseline;
|
||||
gap: .5rem 1rem;
|
||||
|
||||
strong {
|
||||
font-size: 1rem;
|
||||
}
|
||||
.time {
|
||||
opacity: .75; font-size: .9rem;
|
||||
}
|
||||
}
|
||||
|
||||
.company-row {
|
||||
grid-row: 2;
|
||||
grid-column: 2;
|
||||
margin-top: .1rem;
|
||||
opacity: .85;
|
||||
}
|
||||
|
||||
.highlights {
|
||||
margin-top: .4rem;
|
||||
margin-left: .75rem;
|
||||
padding-left: 1.2rem;
|
||||
|
||||
li {
|
||||
margin: .2rem 0;
|
||||
}
|
||||
}
|
||||
|
||||
.highlights-noMargin {
|
||||
margin-top: .4rem;
|
||||
|
||||
li {
|
||||
margin: .2rem 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
.container {
|
||||
padding: 2rem;
|
||||
}
|
||||
|
||||
.category-cards {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 1rem;
|
||||
margin-top: 2rem;
|
||||
|
||||
mat-card {
|
||||
cursor: pointer;
|
||||
min-width: 450px;
|
||||
max-width: 450px;
|
||||
|
||||
&:hover {
|
||||
transform: translateY(-5px);
|
||||
box-shadow: 0 4px 20px rgba(0,0,0,0.15);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,53 +0,0 @@
|
||||
.sorting-card {
|
||||
width: 100%;
|
||||
max-width: 1200px;
|
||||
padding: 20px;
|
||||
|
||||
.controls-panel {
|
||||
display: flex;
|
||||
gap: 10px;
|
||||
margin-bottom: 20px;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
|
||||
mat-form-field {
|
||||
width: 200px;
|
||||
}
|
||||
}
|
||||
|
||||
.visualization-area {
|
||||
display: flex;
|
||||
align-items: flex-end;
|
||||
height: 300px; /* Max height for bars */
|
||||
border-bottom: 1px solid #ccc;
|
||||
margin-bottom: 20px;
|
||||
gap: 1px;
|
||||
background-color: #f0f0f0;
|
||||
|
||||
.bar {
|
||||
flex-grow: 1;
|
||||
background-color: #424242; /* Default unsorted color */
|
||||
transition: height 0.05s ease-in-out, background-color 0.05s ease-in-out;
|
||||
width: 10px; /* Default width, flex-grow will adjust */
|
||||
min-width: 1px; /* Ensure bars are always visible */
|
||||
|
||||
&.unsorted {
|
||||
background-color: #424242;
|
||||
}
|
||||
|
||||
&.comparing {
|
||||
background-color: #ffeb3b; /* Yellow for comparing */
|
||||
}
|
||||
|
||||
&.sorted {
|
||||
background-color: #4caf50; /* Green for sorted */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.info-panel {
|
||||
margin-top: 10px;
|
||||
font-size: 0.9em;
|
||||
color: #FFFFFF;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,40 +0,0 @@
|
||||
.imprint {
|
||||
display: grid;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.imprint-card {
|
||||
padding: 1.25rem 1.5rem;
|
||||
}
|
||||
|
||||
.imprint-title {
|
||||
margin: 0 0 1rem;
|
||||
font-size: 1.1rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.imprint-section {
|
||||
display: grid;
|
||||
gap: 0.25rem;
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
}
|
||||
|
||||
.imprint-label {
|
||||
font-size: 0.75rem;
|
||||
letter-spacing: 0.04em;
|
||||
text-transform: uppercase;
|
||||
opacity: 0.7;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
a {
|
||||
color: var(--mat-primary);
|
||||
text-decoration: none;
|
||||
|
||||
&:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,81 +0,0 @@
|
||||
.my-swiper::part(button-prev),
|
||||
.my-swiper::part(button-next) {
|
||||
width: 35px;
|
||||
height: 35px;
|
||||
padding: 5px;
|
||||
border-radius: 999px;
|
||||
background: rgba(0,0,0,.5);
|
||||
color: white;
|
||||
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.my-swiper::part(button-prev):hover,
|
||||
.my-swiper::part(button-next):hover {
|
||||
background: rgba(0,0,0,.75);
|
||||
}
|
||||
|
||||
.my-swiper {
|
||||
border-radius: 12px;
|
||||
}
|
||||
|
||||
.my-swiper::part(pagination) {
|
||||
bottom: 12px;
|
||||
}
|
||||
|
||||
swiper-slide {
|
||||
border-radius: 12px;
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background-color: #222;
|
||||
}
|
||||
|
||||
.slide-img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
max-height: 512px !important;
|
||||
object-fit: contain;
|
||||
display: block;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.slide-source {
|
||||
font-size: 0.75rem;
|
||||
color: #aaa;
|
||||
background: #2a2a2a;
|
||||
padding: 0.5rem;
|
||||
text-align: right;
|
||||
border-top: 1px solid #444;
|
||||
}
|
||||
|
||||
ul {
|
||||
padding-left: 20px;
|
||||
margin-bottom: 1.5rem;
|
||||
}
|
||||
|
||||
li {
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
mat-chip-set {
|
||||
margin-top: 1.5rem;
|
||||
margin-bottom: 1.5rem;
|
||||
}
|
||||
|
||||
.link-section {
|
||||
display: flex;
|
||||
gap: 1rem;
|
||||
margin-top: 1.5rem;
|
||||
flex-wrap: wrap;
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
|
||||
mat-dialog-actions {
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
@@ -1,60 +0,0 @@
|
||||
.project-grid {
|
||||
display: grid;
|
||||
gap: 1.5rem;
|
||||
grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
|
||||
}
|
||||
|
||||
.project-card {
|
||||
transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
&:hover {
|
||||
transform: translateY(-5px);
|
||||
box-shadow: 0 4px 20px rgba(0,0,0,0.15);
|
||||
}
|
||||
|
||||
&.featured {
|
||||
grid-column: 1 / -1; // Span full width
|
||||
}
|
||||
|
||||
mat-card-header {
|
||||
padding-bottom: 1rem;
|
||||
}
|
||||
|
||||
mat-card-content {
|
||||
flex-grow: 1; // Ensure content area expands
|
||||
padding-top: 1rem;
|
||||
padding-bottom: 1rem;
|
||||
}
|
||||
|
||||
mat-chip-set {
|
||||
padding-top: 1rem;
|
||||
}
|
||||
|
||||
mat-card-actions {
|
||||
margin-top: auto; // Push actions to the bottom
|
||||
}
|
||||
}
|
||||
|
||||
.icon-container {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
height: 200px; /* Or a height that fits your design */
|
||||
background-color: #f0f0f0; /* A light background for the icon */
|
||||
}
|
||||
|
||||
.fallback-icon {
|
||||
font-size: 4rem;
|
||||
width: 4rem;
|
||||
height: 4rem;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
// Ensure images don't exceed the card width and maintain aspect ratio
|
||||
img[mat-card-image] {
|
||||
width: 100%;
|
||||
height: 250px;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user