Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: links are direct to asset #2593

Merged
merged 8 commits into from
Oct 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
125 changes: 103 additions & 22 deletions static/sass/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -2350,7 +2350,7 @@ table tfoot {
/* ! ===== Success Stories landing page ===== */
.featured-success-story {
padding: 1.3125em 0;
background: center -230px no-repeat url('../img/success-glow2.png?1646853871') transparent;
background: center -230px no-repeat url('../img/success-glow2.png?1726783859') transparent;
/*blockquote*/ }
.featured-success-story img {
padding: 10px 30px; }
Expand Down Expand Up @@ -3354,11 +3354,11 @@ span.highlighted {
.python .site-headline a:before {
width: 290px;
height: 82px;
content: url('../img/python-logo_print.png?1646853871'); }
content: url('../img/python-logo_print.png?1726783859'); }
.psf .site-headline a:before {
width: 334px;
height: 82px;
content: url('../img/psf-logo_print.png?1646853871'); } }
content: url('../img/psf-logo_print.png?1726783859'); } }
/*
* When we want to review the markup for W3 and similar errors, turn some of these on
* Uses :not selectors a bunch, so only modern browsers will support them
Expand Down Expand Up @@ -3979,25 +3979,106 @@ span.highlighted {
.hidden {
JacobCoffee marked this conversation as resolved.
Show resolved Hide resolved
display: none; }

#sponsorship-detail-container .info-cards {
display: flex;
width: 100%;
align-content: center;
flex-wrap: wrap; }
#sponsorship-detail-container .card {
flex: 1 0 48%; }
#sponsorship-detail-container .card-info {
margin: .5em .5em;
padding: 1em 1em;
border: 1px solid #caccce;
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
-ms-border-radius: 6px;
-o-border-radius: 6px;
border-radius: 6px;
background: #e6e8ea; }
#sponsorship-detail-container .card-info h3 {
margin: 0; }
#sponsorship-detail-container {
max-width: 1200px;
margin: 0 auto;
padding: 2rem; }
#sponsorship-detail-container .info-cards {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 1.5rem; }
@media (max-width: 768px) {
#sponsorship-detail-container .info-cards {
grid-template-columns: 1fr; } }
#sponsorship-detail-container .card {
background-color: #fff;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
padding: 0.75rem; }
#sponsorship-detail-container .card h3 {
margin-top: 0;
margin-bottom: 1rem; }
#sponsorship-detail-container .card ul li {
margin-bottom: 0.5rem; }
#sponsorship-detail-container .wide-column {
grid-column: 1 / -1; }
#sponsorship-detail-container .assets-list {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
gap: 1rem;
margin-top: 1rem; }
#sponsorship-detail-container .asset-item {
background-color: #f8f9fa;
border: 1px solid #e9ecef;
border-radius: 6px;
padding: 1rem; }
#sponsorship-detail-container .asset-item h4 {
margin-top: 0;
margin-bottom: 0.5rem;
font-size: 1rem; }
#sponsorship-detail-container .asset-item p {
margin-bottom: 0.75rem;
font-size: 0.9rem; }
#sponsorship-detail-container .asset-item.incomplete {
border-left: 3px solid #dc3545; }
#sponsorship-detail-container .asset-item.fulfilled {
border-left: 3px solid #28a745; }
#sponsorship-detail-container .due-date {
font-weight: bold;
color: #dc3545; }
#sponsorship-detail-container .btn {
display: inline-block;
padding: 0.375rem 0.75rem;
font-size: 0.9rem;
text-align: center;
text-decoration: none;
border-radius: 4px;
transition: background-color 0.2s ease; }
#sponsorship-detail-container .btn-link {
color: #007bff; }
#sponsorship-detail-container .edit-all-assets {
margin-top: 1.5rem;
text-align: right; }
#sponsorship-detail-container .benefits-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 1rem;
margin-top: 1rem; }
#sponsorship-detail-container .benefit-item {
display: flex;
flex-direction: column;
background-color: #ffffff;
border: 1px solid #e9ecef;
border-radius: 4px;
padding: 0.75rem;
transition: background-color 0.2s ease; }
#sponsorship-detail-container .benefit-item:hover {
background-color: #f8f9fa; }
#sponsorship-detail-container .benefit-content {
flex-grow: 1; }
#sponsorship-detail-container .benefit-name {
display: block;
font-weight: 500;
font-size: 0.9rem;
line-height: 1.2;
margin-bottom: 0.25rem; }
#sponsorship-detail-container .benefit-description {
color: #6c757d;
cursor: help;
font-size: 0.8rem; }
#sponsorship-detail-container .benefit-category {
display: inline-block;
background-color: #e9ecef;
color: #495057;
font-size: 0.75rem;
padding: 0.25rem 0.5rem;
border-radius: 4px;
margin-top: 0.5rem; }
@media (max-width: 768px) {
#sponsorship-detail-container .info-cards {
grid-template-columns: 1fr; }
#sponsorship-detail-container .assets-list {
grid-template-columns: 1fr; } }

#update-sponsorship-assets input {
padding: 0.25em;
Expand Down
166 changes: 148 additions & 18 deletions static/sass/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2943,28 +2943,158 @@ $breakpoint-desktop: 1200px;


#sponsorship-detail-container {
.info-cards {
display: flex;
width: 100%;
align-content: center;
flex-wrap: wrap;
}
max-width: 1200px;
margin: 0 auto;
padding: 2rem;

.card {
flex: 1 0 48%;
}
.info-cards {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 1.5rem;
}

.card-info {
margin: .5em .5em;
padding: 1em 1em;
border: 1px solid $default-border-color;
@include border-radius();
background: $grey-lightest;
@media (max-width: 768px) {
.info-cards {
grid-template-columns: 1fr;
}
}

h3 {
margin: 0;

.card {
background-color: #fff;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
padding: 0.75rem;
}

.card h3 {
margin-top: 0;
margin-bottom: 1rem;
}

.card ul li {
margin-bottom: 0.5rem;
}

.wide-column {
grid-column: 1 / -1;
}

.assets-list {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
gap: 1rem;
margin-top: 1rem;
}

.asset-item {
background-color: #f8f9fa;
border: 1px solid #e9ecef;
border-radius: 6px;
padding: 1rem;
}

.asset-item h4 {
margin-top: 0;
margin-bottom: 0.5rem;
font-size: 1rem;
}

.asset-item p {
margin-bottom: 0.75rem;
font-size: 0.9rem;
}

.asset-item.incomplete {
border-left: 3px solid #dc3545;
}

.asset-item.fulfilled {
border-left: 3px solid #28a745;
}

.due-date {
font-weight: bold;
color: #dc3545;
}

.btn {
display: inline-block;
padding: 0.375rem 0.75rem;
font-size: 0.9rem;
text-align: center;
text-decoration: none;
border-radius: 4px;
transition: background-color 0.2s ease;
}

.btn-link {
color: #007bff;
}

.edit-all-assets {
margin-top: 1.5rem;
text-align: right;
}

.benefits-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 1rem;
margin-top: 1rem;
}

.benefit-item {
display: flex;
flex-direction: column;
background-color: #ffffff;
border: 1px solid #e9ecef;
border-radius: 4px;
padding: 0.75rem;
transition: background-color 0.2s ease;
}

.benefit-item:hover {
background-color: #f8f9fa;
}

.benefit-content {
flex-grow: 1;
}

.benefit-name {
display: block;
font-weight: 500;
font-size: 0.9rem;
line-height: 1.2;
margin-bottom: 0.25rem;
}

.benefit-description {
color: #6c757d;
cursor: help;
font-size: 0.8rem;
}

.benefit-category {
display: inline-block;
background-color: #e9ecef;
color: #495057;
font-size: 0.75rem;
padding: 0.25rem 0.5rem;
border-radius: 4px;
margin-top: 0.5rem;
}

@media (max-width: 768px) {
.info-cards {
grid-template-columns: 1fr;
}

.assets-list {
grid-template-columns: 1fr;
}
}
}
}

#update-sponsorship-assets {
Expand Down
3 changes: 2 additions & 1 deletion templates/users/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
{% endblock %}


{% block content_attributes %}with-right-sidebar{% endblock %}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's fine to remove this rather than comment it.

{# This added an unnecessarily large gap on every user/ page. #}
{#{% block content_attributes %}with-right-sidebar{% endblock %}#}


{% block content %}
Expand Down
Loading
Loading