From 84ca6726b5494ef02da75acb4cb53c85ed4dbf02 Mon Sep 17 00:00:00 2001 From: Taka Date: Wed, 8 Aug 2018 13:43:40 +0000 Subject: [PATCH] Added scenario notes. --- .../default-template-pack/scenario_note.j2 | 13 +++ vasl_templates/webapp/static/css/main.css | 13 ++- .../webapp/static/css/tabs-scenario.css | 20 +++++ vasl_templates/webapp/static/main.js | 9 +++ vasl_templates/webapp/static/simple_notes.js | 18 ++++- vasl_templates/webapp/static/snippets.js | 19 +++-- vasl_templates/webapp/templates/index.html | 15 ++++ .../default-template-pack/scenario_note.j2 | 1 + .../template-packs/full/scenario_note.j2 | 1 + .../new-default/scenario_note.j2 | 1 + vasl_templates/webapp/tests/test_ob.py | 5 +- .../webapp/tests/test_scenario_persistence.py | 6 ++ vasl_templates/webapp/tests/test_snippets.py | 81 ++++++++++++++++++- .../webapp/tests/test_template_packs.py | 17 +++- vasl_templates/webapp/tests/utils.py | 16 +++- 15 files changed, 208 insertions(+), 27 deletions(-) create mode 100644 vasl_templates/webapp/data/default-template-pack/scenario_note.j2 create mode 100644 vasl_templates/webapp/tests/fixtures/data/default-template-pack/scenario_note.j2 create mode 100644 vasl_templates/webapp/tests/fixtures/template-packs/full/scenario_note.j2 create mode 100644 vasl_templates/webapp/tests/fixtures/template-packs/new-default/scenario_note.j2 diff --git a/vasl_templates/webapp/data/default-template-pack/scenario_note.j2 b/vasl_templates/webapp/data/default-template-pack/scenario_note.j2 new file mode 100644 index 0000000..727a355 --- /dev/null +++ b/vasl_templates/webapp/data/default-template-pack/scenario_note.j2 @@ -0,0 +1,13 @@ + + + + + +
+ {{SCENARIO_NOTE}} + +
+ + diff --git a/vasl_templates/webapp/static/css/main.css b/vasl_templates/webapp/static/css/main.css index 77e6099..4e6b234 100644 --- a/vasl_templates/webapp/static/css/main.css +++ b/vasl_templates/webapp/static/css/main.css @@ -30,14 +30,11 @@ body { height: 100% ; } grid-template-rows: 16em 1fr ; -ms-grid-rows: 14em 1fr ; grid-template-columns: 28em 1fr ; -ms-grid-columns: 28em 1fr ; } - -#tabs-scenario fieldset.tr { - -ms-grid-row: 1 ; -ms-grid-column: 2 ; -} -#tabs-scenario fieldset.br { - grid-column-start: 2 ; - -ms-grid-row: 2 ; -ms-grid-column: 2 ; -} +/* FUDGE! IE hackamathon follows... */ +#tabs-scenario fieldset.tl { -ms-grid-row: 1 ; -ms-grid-column: 1 ; } +#tabs-scenario fieldset.tr { -ms-grid-row: 1 ; -ms-grid-column: 2 ; } +#tabs-scenario fieldset.bl { -ms-grid-row: 2 ; -ms-grid-column: 1 ; } +#tabs-scenario fieldset.br { -ms-grid-row: 2 ; -ms-grid-column: 2 ; } /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */ diff --git a/vasl_templates/webapp/static/css/tabs-scenario.css b/vasl_templates/webapp/static/css/tabs-scenario.css index 216534f..5c620ea 100644 --- a/vasl_templates/webapp/static/css/tabs-scenario.css +++ b/vasl_templates/webapp/static/css/tabs-scenario.css @@ -61,6 +61,26 @@ /* -------------------------------------------------------------------- */ +#panel-scenario_notes { + height: 100% ; + display: grid ; display: -ms-grid ; + grid-template-rows: 1fr 2em ; -ms-grid-rows: 1fr 2em ; +} +/* FUDGE! IE hackamathon follows (nb: