File tree Expand file tree Collapse file tree
core/jinja2/components/breast-diagram
mammograms/jinja2/mammograms/medical_information/breast_features Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- {% macro app_breast_diagram (version , attributes ) %}
2- {% - include ' components/breast-diagram/template.jinja' -%}
1+ {% macro app_breast_diagram (params ) %}
2+ {% - include " components/breast-diagram/template.jinja" -%}
33{% endmacro %}
Original file line number Diff line number Diff line change 55 <span >Left</span >
66</div >
77
8- <figure class =" app-breast-diagram__image-map nhsuk-u-width-full" data-module =" app-image-map" {{- nhsukAttributes(attributes) }} >
9- {% if version == 1 %}
8+ <figure
9+ {{- nhsukAttributes({
10+ " class" : " app-breast-diagram__image-map nhsuk-u-width-full" ,
11+ " data-module" : " app-image-map" ,
12+ " data-read-only" : {
13+ " value" : " true" if params.read_only else false,
14+ " optional" : true
15+ }
16+ }) -}}
17+
18+ {{- nhsukAttributes(params.attributes) -}} >
19+ {% if params .version == 1 %}
1020{% include "components/breast-diagram/v1.svg" %}
1121{% endif %}
1222</figure >
Original file line number Diff line number Diff line change 99
1010{% from "components/breast-diagram/macro.jinja" import app_breast_diagram %}
1111
12- {% set form_attributes = { "data-module" : "app-breast-diagram" } %}
12+ {% set form_attributes = {
13+ "class" : "app-breast-diagram" ,
14+ "action" : request .path ,
15+ "method" : "post" ,
16+ "data-module" : "app-breast-diagram" ,
17+ "data-debug" : {
18+ "value" : "true" if "debug" in request .GET else false ,
19+ "optional" : true
20+ },
21+ "novalidate" : {
22+ "value" : true ,
23+ "optional" : true
24+ }
25+ } %}
1326
1427{% block page_content %}
15- <div class =" nhsuk-u-reading-width" >
28+ <div class =" nhsuk-u-reading-width" >
1629 {{ form_error_summary(form) }}
1730
1831 <h1 class =" nhsuk-heading-l" >
2437 {{ heading }}
2538 </h1 >
2639
27- <form class = " app-breast-diagram " action = " {{ request.path }} " method = " post " novalidate {{ nhsukAttributes(form_attributes) }} >
40+ <form {{- nhsukAttributes(form_attributes) }} >
2841 {{ csrf_input }}
2942
3043 <p class =" nhsuk-body" id =" breast-diagram-description" >
3548 <h2 class =" nhsuk-heading-m" >Where is the feature?</h2 >
3649 </div >
3750
38- {{ app_breast_diagram(
39- version=diagram_version,
40- attributes={
51+ {{ app_breast_diagram({
52+ "read_only": false,
53+ "version": diagram_version,
54+ "attributes": {
4155 "aria-labelledby": "breast-diagram-description"
4256 }
43- ) }}
57+ } ) }}
4458
4559 {{ form.features }}
4660
100114 </a >
101115 </p >
102116 </form >
103- </div >
117+ </div >
104118{% endblock %}
You can’t perform that action at this time.
0 commit comments