diff --git a/templates/base.html b/templates/base.html new file mode 100644 index 0000000..820407a --- /dev/null +++ b/templates/base.html @@ -0,0 +1,24 @@ + + + + + + + + + {% block title %}{% endblock %} + + + {% block style %}{% endblock %} + + + + {% block content %}{% endblock %} + + + + + + {% block script %}{% endblock %} + + diff --git a/templates/find_more.html b/templates/find_more.html new file mode 100644 index 0000000..163a7af --- /dev/null +++ b/templates/find_more.html @@ -0,0 +1,58 @@ +{% extends "base.html" %} + +{% block title %}{{ label }}{% endblock %} + +{% block style %} + +{% endblock %} + +{% block content %} +
+

{{ self.title() }}

+ + {# + {% for key, label in property_labels.items() %} +

{{ label }} ({{ key }})

+
{{ item_entity['claims'][key] | pprint }}
+ {% endfor %} + #} + +

{{ '{:,d}'.format(total) }} paintings found

+ + {% for key, values in facets.items() %} +

{{ prop_labels[key] }}: + {% for v in values %} + {{ v.label }} ({{ v.count }}) + {% if not loop.last %}|{% endif %} + {% endfor %} +

+ + {% endfor %} + +
+ {% for item in items %} + {% set image = item.image %} +
+ + {# #} + +
+
{{ item.label }}
+

by {{ item.artist_name }} + {% if item.date %}({{ item.date }}){% endif %} +

+
+
+ {% endfor %} +
+ +{# + {% for item in items %} +
{{ item | pprint }}
+ {% endfor %} +#} + +
+{% endblock %} diff --git a/templates/index.html b/templates/index.html new file mode 100644 index 0000000..010671c --- /dev/null +++ b/templates/index.html @@ -0,0 +1,16 @@ +{% extends "base.html" %} + +{% block title %}Wikidata painting depicts{% endblock %} + +{% block content %} +
+ +
+ +{% endblock %} diff --git a/templates/next.html b/templates/next.html new file mode 100644 index 0000000..0c45f85 --- /dev/null +++ b/templates/next.html @@ -0,0 +1,32 @@ +{% extends "base.html" %} + +{% block title %}{{ label }} ({{qid }}){% endblock %} + +{% block content %} +
+

{{ self.title() }}

+ {#
{{ other | pprint }}
#} + + {# #} +
+
+ +
+ +
+

view on Wikidata

+ {% for key, prop_label in labels.items() %} + {% set claims = entity['claims'][key] %} + {% if claims %} +

{{ prop_label }} ({{ key }})

+ {% for claim in claims %} + {% set claim_qid = claim.mainsnak.datavalue.value.id %} + {{ other[claim_qid] }} ({{ claim_qid }}) + {% endfor %} + {% endif %} + {% endfor %} +
+
+ +
+{% endblock %} diff --git a/templates/property.html b/templates/property.html new file mode 100644 index 0000000..8fee4ee --- /dev/null +++ b/templates/property.html @@ -0,0 +1,30 @@ +{% extends "base.html" %} + +{% block title %}{{ label }}{% endblock %} + +{% block content %} +
+

{{ self.title() }}

+ +

back to index

+ + +
+ +{% endblock %}