Browse Source

corrections css from google doc

master
jules 4 years ago
parent
commit
aec82ffde8
  1. 29
      daapinterface.py
  2. 16
      static/css/style.css
  3. 3
      templates/artwork.html

29
daapinterface.py

@ -473,6 +473,22 @@ def artwork():
copiesincollection = sparql.query().convert() copiesincollection = sparql.query().convert()
# related works # related works
# sparql.setQuery('''
# SELECT ?relatedWorks ?relatedWorksLabel ?image ?daterelatedWorks
# WHERE {
# {
# SELECT ?relatedWorks ?relatedWorksLabel (SAMPLE(?daterelatedWorks) AS ?daterelatedWorks)
# WHERE
# { VALUES ?work {wd:'''+artwork_id+'''}
# ?work wdt:P44 ?relatedWorks.
# OPTIONAL {?relatedWorks wdt:P13 ?daterelatedWorks.}
# SERVICE wikibase:label { bd:serviceParam wikibase:language "en". }
# }
# GROUP BY ?relatedWorks ?relatedWorksLabel
# ORDER BY ?relatedWorksLabel
# }
# OPTIONAL {?relatedWorks wdt:P90 ?image.}
# } ''')
sparql.setQuery(''' sparql.setQuery('''
SELECT ?relatedWorks ?relatedWorksLabel ?image ?daterelatedWorks SELECT ?relatedWorks ?relatedWorksLabel ?image ?daterelatedWorks
WHERE { WHERE {
@ -487,8 +503,19 @@ def artwork():
GROUP BY ?relatedWorks ?relatedWorksLabel GROUP BY ?relatedWorks ?relatedWorksLabel
ORDER BY ?relatedWorksLabel ORDER BY ?relatedWorksLabel
} }
{
SELECT ?relatedWorks ?relatedWorksLabel (SAMPLE(?image) AS ?image)
WHERE
{ VALUES ?work {wd:'''+artwork_id+'''}
?work wdt:P44 ?relatedWorks.
OPTIONAL {?relatedWorks wdt:P90 ?image.} OPTIONAL {?relatedWorks wdt:P90 ?image.}
} ''') SERVICE wikibase:label { bd:serviceParam wikibase:language "en". }
}
GROUP BY ?relatedWorks ?relatedWorksLabel
ORDER BY ?relatedWorksLabel
}
}
''')
sparql.setReturnFormat(JSON) sparql.setReturnFormat(JSON)
relatedworks = sparql.query().convert() relatedworks = sparql.query().convert()

16
static/css/style.css

@ -240,7 +240,7 @@ html {
-webkit-box-sizing: inherit; -webkit-box-sizing: inherit;
-moz-box-sizing: inherit; -moz-box-sizing: inherit;
box-sizing: inherit; box-sizing: inherit;
margin: 0 /*margin: 0*/
} }
body { body {
@ -1489,7 +1489,7 @@ div.browsebycategory-categories:hover {
display: grid; display: grid;
row-gap: 0rem; row-gap: 0rem;
column-gap: 1rem; column-gap: 1rem;
grid-template-columns: repeat(19, 1fr); grid-template-columns: repeat(18, 1fr);
} }
.artwork-relatedwrapper,.artwork-copieswrapper, .artwork-lists { .artwork-relatedwrapper,.artwork-copieswrapper, .artwork-lists {
width: 100%; width: 100%;
@ -1548,7 +1548,7 @@ div.browsebycategory-categories:hover {
.artwork-rightcolumn-top, .artwork-rightcolumn-bottom { .artwork-rightcolumn-top, .artwork-rightcolumn-bottom {
margin: 0 0 0 0 !important; margin: 0 0 0 0 !important;
display: grid; display: grid;
padding: 0 0 20px 0; /*padding: 0 0 20px 0;*/
grid-template-columns: repeat(10, 1fr); grid-template-columns: repeat(10, 1fr);
column-gap: 1rem; column-gap: 1rem;
} }
@ -1637,7 +1637,7 @@ div.browsebycategory-categories:hover {
.text-description { .text-description {
grid-column-start: 1; grid-column-start: 1;
grid-column-end: 6; grid-column-end: 8;
grid-row-start: 2; grid-row-start: 2;
grid-row-end: 2; grid-row-end: 2;
} }
@ -1840,13 +1840,14 @@ img.artwork-relatedworks-imgs, .artwork-lists-img img{
margin: 0px; margin: 0px;
padding-bottom: 20px; padding-bottom: 20px;
padding-right: 15px; padding-right: 15px;
padding-top: 10px;
} }
.tns-nav > [aria-controls] { .tns-nav > [aria-controls] {
width: 16px; width: 16px;
height: 16px; height: 16px;
padding: 0; padding: 0;
margin: 0 10px 0 0; margin: 0 10px 0 0;
border-radius: 50%; /* border-radius: 50%;*/
border: 1px solid #000; border: 1px solid #000;
/*background: #FFF;*/ /*background: #FFF;*/
} }
@ -2106,13 +2107,14 @@ div#tutorials-intro h3, div#tutorials-intro p {
} }
#footer-title-others {text-align: right;} #footer-title-others {text-align: right;}
#footer-title-contact {text-align: left;} #footer-title-contact {text-align: left; padding-bottom: 20px;}
#footer-socials {width: 100%; } #footer-socials {width: 100%; }
#footer-socials-links{ #footer-socials-links {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
width: 100%; width: 100%;
padding-top: 10px;
} }
a#footer-img-wiki { a#footer-img-wiki {

3
templates/artwork.html

@ -62,7 +62,7 @@
{% endif %} {% endif %}
{% if "licenseLabel" in x %} {% if "licenseLabel" in x %}
<p>{{ x['licenseLabel']['value'] }}</p> <p>License: {{ x['licenseLabel']['value'] }}</p>
{% endif %} {% endif %}
<!-- END GROUP IMG + LABELS --> <!-- END GROUP IMG + LABELS -->
</div> </div>
@ -70,7 +70,6 @@
{% endif %} {% endif %}
</div> </div>

Loading…
Cancel
Save