File tree 2 files changed +65
-16
lines changed
layouts/shortcodes/blocks 2 files changed +65
-16
lines changed Original file line number Diff line number Diff line change @@ -1928,6 +1928,57 @@ body.td-search {
1928
1928
color : #ffffff !important ;
1929
1929
}
1930
1930
1931
+ body .td-home section .case-studies {
1932
+ h2 , h3 {
1933
+ text-align : center ;
1934
+ }
1935
+ .case-study-list {
1936
+ display : flex ;
1937
+ flex-direction : row ;
1938
+ max-width : 80vw ;
1939
+ margin-left : auto ;
1940
+ margin-right : auto ;
1941
+ align-items : stretch ;
1942
+ gap : clamp (1rem , 4em , 10vw );
1943
+ > .case-study-item {
1944
+ display : flex ;
1945
+ flex-direction : column ;
1946
+ justify-content : space-between ;
1947
+ width : clamp (6rem , 20% , 50vw );
1948
+ picture , picture img {
1949
+ height : 4.8rem ;
1950
+ text-align : center ;
1951
+ }
1952
+ > a {
1953
+ display : block ;
1954
+ text-align : right ;
1955
+ }
1956
+ padding-bottom : 2em ;
1957
+ }
1958
+ }
1959
+ padding-top : 4rem ;
1960
+ }
1961
+
1962
+ @media screen and (max-width : 768px ) {
1963
+ .case-study-list {
1964
+ justify-content : center ;
1965
+ flex-wrap : wrap ;
1966
+ > .case-study-item {
1967
+ min-width : 34vw ;
1968
+ }
1969
+ }
1970
+ }
1971
+
1972
+ @media screen and (max-width : 650px ) {
1973
+ .case-study-list {
1974
+ > .case-study-item {
1975
+ min-width : 51vw ;
1976
+ }
1977
+ }
1978
+ }
1979
+
1980
+
1981
+
1931
1982
// handle main page features on narrow viewports
1932
1983
@media screen and (max-width : 768px ) {
1933
1984
.features-container div .feature-box {
Original file line number Diff line number Diff line change 1
- {{ $caseStudiesSection := site.GetPage "case-studies" }}
2
- {{ if not $caseStudiesSection }}
1
+ {{- $caseStudiesSection := site.GetPage "case-studies" - }}
2
+ {{- if not $caseStudiesSection - }}
3
3
{{ errorf "[%s] No case-studies section found. Create content/%s/case-studies/_index.md" $.Page.Lang $.Page.Lang }}
4
- {{ else }}
4
+ {{- else - }}
5
5
{{ $caseStudiesPages := where $caseStudiesSection.Pages "Params.featured" true | first 4 }}
6
- < section id ="talkToUs ">
7
- < div class ="main-section ">
8
- < h3 style ="text-align: center "> < a href ="{{ $caseStudiesSection.RelPermalink }} " style ="color: #3371E3; font-weight: 400 "> {{ $caseStudiesSection.LinkTitle }}</ a > </ h3 >
9
- < div id ="caseStudiesWrapper ">
10
- {{ range $caseStudiesPages }}
6
+ < section class ="case-studies ">
7
+ < h3 > < a href ="{{ $caseStudiesSection.RelPermalink }} "> {{ $caseStudiesSection.LinkTitle }}</ a > </ h3 >
8
+ < div class ="case-study-list ">
9
+ {{- range $caseStudiesPages -}}
11
10
{{ $dark := .Resources.GetMatch "**{dark_logo}*.svg" }}
12
11
{{ $logo := .Resources.GetMatch "**{featured_logo}*.svg" }}
13
12
14
13
{{ if not $logo }}
15
14
{{ $logo = .Resources.GetMatch "**logo*.png" }}
16
15
{{ end }}
17
- {{ if not $dark }}
18
- {{ $dark = $logo }}
19
- {{ end }}
20
- < div >
16
+ {{- if not $dark - }}
17
+ {{ $dark = $logo }}
18
+ {{- end - }}
19
+ < div class =" case-study-item " >
21
20
< picture >
22
- < source srcset ={{$dark.RelPermalink}} media ="(prefers-color-scheme: dark) ">
21
+ < source srcset =" {{$dark.RelPermalink}} " media ="(prefers-color-scheme: dark) ">
23
22
< img src ="{{ $logo.RelPermalink }} " alt ="{{ .Title }} ">
24
23
</ picture >
25
24
< p > "{{ .Params.quote | truncate 100 }}"</ p >
26
25
< a href ="{{ .RelPermalink }} "> {{ T "main_read_more" }}</ a >
27
26
</ div >
28
- {{ end }}
29
- </ div >
27
+ {{- end -}}
30
28
</ div >
31
29
</ section >
32
- {{ end }}
30
+ {{- end - }}
You can’t perform that action at this time.
0 commit comments