Coverage for ivatar/ivataraccount/templates/choose_libravatar_export.html: 100%

50 statements  

« prev     ^ index     » next       coverage.py v7.10.7, created at 2025-10-13 23:07 +0000

1{% extends 'base.html' %} 

2{% load i18n %} 

3{% load static %} 

4  

5{% block title %}{% trans 'Choose items to be uploaded' %}{% endblock title %} 

6  

7{% block content %} 

8<style> 

9input[type=checkbox] {display:none} 

10input[type=checkbox].image + label:before { 

11font-family: "Font Awesome 7 Free"; 

12font-weight: 900; 

13display: inline-block; 

14} 

15input[type=checkbox].image + label:before {content: "\f0c8"} 

16input[type=checkbox].image + label:before {letter-spacing: 5px} 

17input[type=checkbox].image:checked + label:before {content: "\f14a"} 

18input[type=checkbox].image:checked + label:before {letter-spacing: 3px} 

19</style> 

20 <h1>{% trans 'Choose items to be imported' %}</h1> 

21  

22 <form method="post" action="{% url 'upload_export' 'save' %}">{% csrf_token %} 

23 {% if emails %} 

24 <h4>{% trans 'Email addresses we found in the export - existing ones will not be re-added' %}</h4> 

25 {% for email in emails %} 

26 <div class="checkbox"> 

27 <input type="checkbox" checked name="email_{{ forloop.counter }}" id="email_{{ forloop.counter }}" value="{{ email.email }}" class="text"><label for="email_{{ forloop.counter }}">{{ email.email }}</label> 

28 </div> 

29 {% endfor %} 

30 {% endif %} 

31 {% if photos %} 

32 <h4>{% trans 'Photos we found in the export' %}</h4> 

33<div class="row"> 

34 {% for photo in photos %} 

35<div class="panel panel-tortin" style="width:132px;float:left;margin-left:20px"> 

36 <div class="panel-heading"> 

37 <h3 class="panel-title"> 

38 <input type="checkbox" checked name="photo_{{ forloop.counter }}" id="photo_{{ forloop.counter }}" value="{{ photo.data }}" class="image"> 

39<label for="photo_{{ forloop.counter }}">{% trans 'Image' %} {{ forloop.counter }}</label> 

40</label> 

41</h3></div> 

42 <div class="panel-body"> 

43 <center> 

44 <img style="max-height:100px;max-width:100px" src="data:image/{{ photo.format }};base64,{{ photo.data }}"> 

45 </center> 

46</div> 

47</div> 

48 {% endfor %} 

49</div> 

50 {% endif %} 

51<p> 

52 <button type="submit" class="button">{% trans 'Upload' %}</button> 

53</p> 

54 </form> 

55<div style="height:40px"></div> 

56{% endblock content %}