Skip to content

Connect, collaborate, and grow with a community of TypeScript developers

flip a background image (harder than it looks) (#544)

PickleNikb8e435adccd6
diff --git a/apps/web/src/assets/images/background_pattern_flipped.webp b/apps/web/src/assets/images/background_pattern_flipped.webp
deleted file mode 100644
index 5a4e48fc..00000000
Binary files a/apps/web/src/assets/images/background_pattern_flipped.webp and /dev/null differ
diff --git a/apps/web/src/assets/images/waitlist-bg.webp b/apps/web/src/assets/images/waitlist-bg.webp
index c14ddd9c..31ee9026 100644
Binary files a/apps/web/src/assets/images/waitlist-bg.webp and b/apps/web/src/assets/images/waitlist-bg.webp differ
diff --git a/apps/web/src/components/landing/community/community.module.css b/apps/web/src/components/landing/community/community.module.css
index 5474dc45..b3a2128e 100644
--- a/apps/web/src/components/landing/community/community.module.css
+++ b/apps/web/src/components/landing/community/community.module.css
@@ -1,57 +1,66 @@
/* The module for the background of the banner on the landing page */
.backdrop {
+ position: relative;
+}
+.backdrop:before {
+ content: '';
+ width: 100%;
+ height: 100%;
+ position: absolute;
+ inset: 0;
background: linear-gradient(
- -3deg,
+ -183deg,
hsla(var(--background) / 0.75) 0%,
hsla(var(--background) / 0.95) 33%,
hsl(var(--background)) 50%
),
- url('../../../assets/images/background_pattern_flipped.webp');
+ url('../../../assets/images/background_pattern.webp');
background-size: cover;
- background-position-y: bottom;
+ background-position-y: top;
background-position-x: center;
background-repeat: no-repeat;
+ transform: scaleY(-1) !important;
}
@media (max-width: 3000px) {
- .backdrop {
+ .backdrop:before {
background-position-x: 50%;
background-size: 3300px;
}
}
@media (max-width: 2000px) {
- .backdrop {
+ .backdrop:before {
background-position-x: 50%;
background-size: 2200px;
}
}
@media (max-width: 1280px) {
- .backdrop {
+ .backdrop:before {
background-position-x: 50%;
background-size: 1800px;
}
}
@media (max-width: 768px) {
- .backdrop {
+ .backdrop:before {
background: linear-gradient(
- -3deg,
+ -183deg,
hsla(var(--background) / 0.75) 0%,
hsla(var(--background) / 0.95) 15%,
hsl(var(--background)) 30%
),
- url('../../../assets/images/background_pattern_flipped.webp');
+ url('../../../assets/images/background_pattern.webp');
background-size: 1800px;
- background-position-y: bottom;
+ background-position-y: top;
background-position-x: center;
background-repeat: no-repeat;
background-position-x: 60%;
}
}
@media (max-width: 480px) {
- .backdrop {
+ .backdrop:before {
background-position-x: 70%;
}
}
diff --git a/apps/web/src/components/landing/waitlist/waitlist.module.css b/apps/web/src/components/landing/waitlist/waitlist.module.css
index 58412707..e17a164d 100644
--- a/apps/web/src/components/landing/waitlist/waitlist.module.css
+++ b/apps/web/src/components/landing/waitlist/waitlist.module.css
@@ -21,7 +21,8 @@
background-position-y: 33%;
background-position-x: center;
background-repeat: no-repeat;
- background-size: 100% 200%;
+ background-size: 111% 200%;
+ filter: blur(69px);
}
/* The module for the background of the banner on the landing page */