Skip to content

Commit 3ad7b96

Browse files
authored
fix: links are direct to asset (#2593)
* fix: links are direct to assett Closes: #2577 * test: add them * chore: remove unused imports
1 parent 102fee6 commit 3ad7b96

File tree

6 files changed

+393
-161
lines changed

6 files changed

+393
-161
lines changed

Diff for: static/sass/style.css

+103-22
Original file line numberDiff line numberDiff line change
@@ -2350,7 +2350,7 @@ table tfoot {
23502350
/* ! ===== Success Stories landing page ===== */
23512351
.featured-success-story {
23522352
padding: 1.3125em 0;
2353-
background: center -230px no-repeat url('../img/success-glow2.png?1646853871') transparent;
2353+
background: center -230px no-repeat url('../img/success-glow2.png?1726783859') transparent;
23542354
/*blockquote*/ }
23552355
.featured-success-story img {
23562356
padding: 10px 30px; }
@@ -3354,11 +3354,11 @@ span.highlighted {
33543354
.python .site-headline a:before {
33553355
width: 290px;
33563356
height: 82px;
3357-
content: url('../img/python-logo_print.png?1646853871'); }
3357+
content: url('../img/python-logo_print.png?1726783859'); }
33583358
.psf .site-headline a:before {
33593359
width: 334px;
33603360
height: 82px;
3361-
content: url('../img/psf-logo_print.png?1646853871'); } }
3361+
content: url('../img/psf-logo_print.png?1726783859'); } }
33623362
/*
33633363
* When we want to review the markup for W3 and similar errors, turn some of these on
33643364
* Uses :not selectors a bunch, so only modern browsers will support them
@@ -3979,25 +3979,106 @@ span.highlighted {
39793979
.hidden {
39803980
display: none; }
39813981

3982-
#sponsorship-detail-container .info-cards {
3983-
display: flex;
3984-
width: 100%;
3985-
align-content: center;
3986-
flex-wrap: wrap; }
3987-
#sponsorship-detail-container .card {
3988-
flex: 1 0 48%; }
3989-
#sponsorship-detail-container .card-info {
3990-
margin: .5em .5em;
3991-
padding: 1em 1em;
3992-
border: 1px solid #caccce;
3993-
-webkit-border-radius: 6px;
3994-
-moz-border-radius: 6px;
3995-
-ms-border-radius: 6px;
3996-
-o-border-radius: 6px;
3997-
border-radius: 6px;
3998-
background: #e6e8ea; }
3999-
#sponsorship-detail-container .card-info h3 {
4000-
margin: 0; }
3982+
#sponsorship-detail-container {
3983+
max-width: 1200px;
3984+
margin: 0 auto;
3985+
padding: 2rem; }
3986+
#sponsorship-detail-container .info-cards {
3987+
display: grid;
3988+
grid-template-columns: repeat(2, 1fr);
3989+
gap: 1.5rem; }
3990+
@media (max-width: 768px) {
3991+
#sponsorship-detail-container .info-cards {
3992+
grid-template-columns: 1fr; } }
3993+
#sponsorship-detail-container .card {
3994+
background-color: #fff;
3995+
border-radius: 8px;
3996+
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
3997+
padding: 0.75rem; }
3998+
#sponsorship-detail-container .card h3 {
3999+
margin-top: 0;
4000+
margin-bottom: 1rem; }
4001+
#sponsorship-detail-container .card ul li {
4002+
margin-bottom: 0.5rem; }
4003+
#sponsorship-detail-container .wide-column {
4004+
grid-column: 1 / -1; }
4005+
#sponsorship-detail-container .assets-list {
4006+
display: grid;
4007+
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
4008+
gap: 1rem;
4009+
margin-top: 1rem; }
4010+
#sponsorship-detail-container .asset-item {
4011+
background-color: #f8f9fa;
4012+
border: 1px solid #e9ecef;
4013+
border-radius: 6px;
4014+
padding: 1rem; }
4015+
#sponsorship-detail-container .asset-item h4 {
4016+
margin-top: 0;
4017+
margin-bottom: 0.5rem;
4018+
font-size: 1rem; }
4019+
#sponsorship-detail-container .asset-item p {
4020+
margin-bottom: 0.75rem;
4021+
font-size: 0.9rem; }
4022+
#sponsorship-detail-container .asset-item.incomplete {
4023+
border-left: 3px solid #dc3545; }
4024+
#sponsorship-detail-container .asset-item.fulfilled {
4025+
border-left: 3px solid #28a745; }
4026+
#sponsorship-detail-container .due-date {
4027+
font-weight: bold;
4028+
color: #dc3545; }
4029+
#sponsorship-detail-container .btn {
4030+
display: inline-block;
4031+
padding: 0.375rem 0.75rem;
4032+
font-size: 0.9rem;
4033+
text-align: center;
4034+
text-decoration: none;
4035+
border-radius: 4px;
4036+
transition: background-color 0.2s ease; }
4037+
#sponsorship-detail-container .btn-link {
4038+
color: #007bff; }
4039+
#sponsorship-detail-container .edit-all-assets {
4040+
margin-top: 1.5rem;
4041+
text-align: right; }
4042+
#sponsorship-detail-container .benefits-grid {
4043+
display: grid;
4044+
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
4045+
gap: 1rem;
4046+
margin-top: 1rem; }
4047+
#sponsorship-detail-container .benefit-item {
4048+
display: flex;
4049+
flex-direction: column;
4050+
background-color: #ffffff;
4051+
border: 1px solid #e9ecef;
4052+
border-radius: 4px;
4053+
padding: 0.75rem;
4054+
transition: background-color 0.2s ease; }
4055+
#sponsorship-detail-container .benefit-item:hover {
4056+
background-color: #f8f9fa; }
4057+
#sponsorship-detail-container .benefit-content {
4058+
flex-grow: 1; }
4059+
#sponsorship-detail-container .benefit-name {
4060+
display: block;
4061+
font-weight: 500;
4062+
font-size: 0.9rem;
4063+
line-height: 1.2;
4064+
margin-bottom: 0.25rem; }
4065+
#sponsorship-detail-container .benefit-description {
4066+
color: #6c757d;
4067+
cursor: help;
4068+
font-size: 0.8rem; }
4069+
#sponsorship-detail-container .benefit-category {
4070+
display: inline-block;
4071+
background-color: #e9ecef;
4072+
color: #495057;
4073+
font-size: 0.75rem;
4074+
padding: 0.25rem 0.5rem;
4075+
border-radius: 4px;
4076+
margin-top: 0.5rem; }
4077+
@media (max-width: 768px) {
4078+
#sponsorship-detail-container .info-cards {
4079+
grid-template-columns: 1fr; }
4080+
#sponsorship-detail-container .assets-list {
4081+
grid-template-columns: 1fr; } }
40014082

40024083
#update-sponsorship-assets input {
40034084
padding: 0.25em;

Diff for: static/sass/style.scss

+148-18
Original file line numberDiff line numberDiff line change
@@ -2943,28 +2943,158 @@ $breakpoint-desktop: 1200px;
29432943

29442944

29452945
#sponsorship-detail-container {
2946-
.info-cards {
2947-
display: flex;
2948-
width: 100%;
2949-
align-content: center;
2950-
flex-wrap: wrap;
2951-
}
2946+
max-width: 1200px;
2947+
margin: 0 auto;
2948+
padding: 2rem;
29522949

2953-
.card {
2954-
flex: 1 0 48%;
2955-
}
2950+
.info-cards {
2951+
display: grid;
2952+
grid-template-columns: repeat(2, 1fr);
2953+
gap: 1.5rem;
2954+
}
29562955

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

2964-
h3 {
2965-
margin: 0;
2962+
2963+
.card {
2964+
background-color: #fff;
2965+
border-radius: 8px;
2966+
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
2967+
padding: 0.75rem;
2968+
}
2969+
2970+
.card h3 {
2971+
margin-top: 0;
2972+
margin-bottom: 1rem;
2973+
}
2974+
2975+
.card ul li {
2976+
margin-bottom: 0.5rem;
2977+
}
2978+
2979+
.wide-column {
2980+
grid-column: 1 / -1;
2981+
}
2982+
2983+
.assets-list {
2984+
display: grid;
2985+
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
2986+
gap: 1rem;
2987+
margin-top: 1rem;
2988+
}
2989+
2990+
.asset-item {
2991+
background-color: #f8f9fa;
2992+
border: 1px solid #e9ecef;
2993+
border-radius: 6px;
2994+
padding: 1rem;
2995+
}
2996+
2997+
.asset-item h4 {
2998+
margin-top: 0;
2999+
margin-bottom: 0.5rem;
3000+
font-size: 1rem;
3001+
}
3002+
3003+
.asset-item p {
3004+
margin-bottom: 0.75rem;
3005+
font-size: 0.9rem;
3006+
}
3007+
3008+
.asset-item.incomplete {
3009+
border-left: 3px solid #dc3545;
3010+
}
3011+
3012+
.asset-item.fulfilled {
3013+
border-left: 3px solid #28a745;
3014+
}
3015+
3016+
.due-date {
3017+
font-weight: bold;
3018+
color: #dc3545;
3019+
}
3020+
3021+
.btn {
3022+
display: inline-block;
3023+
padding: 0.375rem 0.75rem;
3024+
font-size: 0.9rem;
3025+
text-align: center;
3026+
text-decoration: none;
3027+
border-radius: 4px;
3028+
transition: background-color 0.2s ease;
3029+
}
3030+
3031+
.btn-link {
3032+
color: #007bff;
3033+
}
3034+
3035+
.edit-all-assets {
3036+
margin-top: 1.5rem;
3037+
text-align: right;
3038+
}
3039+
3040+
.benefits-grid {
3041+
display: grid;
3042+
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
3043+
gap: 1rem;
3044+
margin-top: 1rem;
3045+
}
3046+
3047+
.benefit-item {
3048+
display: flex;
3049+
flex-direction: column;
3050+
background-color: #ffffff;
3051+
border: 1px solid #e9ecef;
3052+
border-radius: 4px;
3053+
padding: 0.75rem;
3054+
transition: background-color 0.2s ease;
3055+
}
3056+
3057+
.benefit-item:hover {
3058+
background-color: #f8f9fa;
3059+
}
3060+
3061+
.benefit-content {
3062+
flex-grow: 1;
3063+
}
3064+
3065+
.benefit-name {
3066+
display: block;
3067+
font-weight: 500;
3068+
font-size: 0.9rem;
3069+
line-height: 1.2;
3070+
margin-bottom: 0.25rem;
3071+
}
3072+
3073+
.benefit-description {
3074+
color: #6c757d;
3075+
cursor: help;
3076+
font-size: 0.8rem;
3077+
}
3078+
3079+
.benefit-category {
3080+
display: inline-block;
3081+
background-color: #e9ecef;
3082+
color: #495057;
3083+
font-size: 0.75rem;
3084+
padding: 0.25rem 0.5rem;
3085+
border-radius: 4px;
3086+
margin-top: 0.5rem;
3087+
}
3088+
3089+
@media (max-width: 768px) {
3090+
.info-cards {
3091+
grid-template-columns: 1fr;
3092+
}
3093+
3094+
.assets-list {
3095+
grid-template-columns: 1fr;
3096+
}
29663097
}
2967-
}
29683098
}
29693099

29703100
#update-sponsorship-assets {

Diff for: templates/users/base.html

+2-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
{% endblock %}
1111

1212

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

1516

1617
{% block content %}

0 commit comments

Comments
 (0)