Compare commits

...

7 Commits

Author SHA1 Message Date
Antoine M
a762d15768 FEATURE Handle self page scrolling
All checks were successful
continuous-integration/drone/push Build is passing
2025-10-07 17:43:57 +02:00
Antoine M
3418325d03 FIX Removing mistaken code 2025-10-07 17:43:44 +02:00
Antoine M
bfdc9122f5 REFACTOR Renaming stylesheet 2025-10-07 17:43:21 +02:00
Antoine M
42e6f3f37b STYLE Test link styling 2025-10-07 17:42:34 +02:00
Antoine M
a17cb5c405 FEATURE Adapating cta icon color on background color change 2025-10-07 17:42:19 +02:00
Antoine M
d3641a3453 FEATURE introducing class underline link 2025-10-07 17:41:35 +02:00
Antoine M
588d3c4467 FEATURE Custom css sheet for form contact 2025-10-07 17:41:21 +02:00
9 changed files with 54 additions and 5 deletions

View File

@ -14,7 +14,8 @@
/* ########### FORMS ############ */
@import './forms/forms.css';
@import './forms/form_contributions.css';
@import './forms/form-contributions.css';
@import './forms/form-contact.css';
/* ########### COMPONENTS ############ */
@import './components/buttons.css';

View File

@ -1,4 +1,7 @@
a[target='_blank'] {
@apply external-link;
}
.external-link {
&:after {
@apply content-[''] w-7 h-7 ml-2 inline-block;
background-image: url('../resources/img/carhop-fleche-lien-externe-full--green.svg');
@ -9,6 +12,24 @@ a[target='_blank'] {
background-position: center;
}
}
.underlined-link {
transition: all 0.3s ease-out;
@apply underline underline-offset-8;
text-decoration-thickness: 1px;
&--white {
@apply decoration-white;
&:hover {
@apply decoration-carhop-green-300;
}
}
&--green {
@apply decoration-carhop-green-700;
&:hover {
@apply decoration-carhop-green-400;
}
}
}
.internal-link-with-icon {
@apply flex items-center;
transition: transform 0.3s ease-out;

View File

@ -107,6 +107,14 @@
}
}
&--bg-dark {
.wp-block-carhop-blocks-cta {
&:after {
filter: brightness(41);
}
}
}
> *:not(.chapter-section__background) {
z-index: 2;
}

View File

@ -53,6 +53,13 @@
h3 + p {
@apply !mt-3;
}
p > a {
transition: all 0.3s ease-out;
@apply underline underline-offset-8;
text-decoration-thickness: 1px;
@apply underlined-link underlined-link--white;
}
ul {
list-style: disc;

View File

View File

@ -2,6 +2,9 @@
/* margin-top: -30px !important; */
margin-bottom: 20px !important;
a {
@apply underlined-link underlined-link--white;
}
.gfield_description {
@apply !text-xl !font-light;
@apply max-w-3xl pb-4;

View File

@ -45,10 +45,6 @@ article > *:not(.entry-content),
}
.site-content {
a {
/* @apply underline underline-offset-4;
text-decoration-thickness: 1px; */
}
p,
li {
strong {

View File

@ -1,8 +1,10 @@
import menuInit from './header';
import initFooterShapes from './footer';
import handleScrollTop from './utilities/scroll-top';
import handleInsidePageScrolling from './page-scrolling';
window.addEventListener('load', function () {
// menuInit();
initFooterShapes();
handleScrollTop();
handleInsidePageScrolling();
});

View File

@ -0,0 +1,11 @@
export default function HandleInsidePageScrolling() {
const insideLinks = document.querySelectorAll('a[href^="#"]');
insideLinks.forEach((link) => {
link.addEventListener('click', (e) => {
e.preventDefault();
const target = document.querySelector(link.getAttribute('href'));
target?.scrollIntoView({ behavior: 'smooth' });
});
});
}