Skip to content

Commit

Permalink
Landsgemeinde: Remove extra titles for assembly items
Browse files Browse the repository at this point in the history
TYPE: Feature
LINK: OGC-1808
  • Loading branch information
BreathingFlesh authored Sep 4, 2024
1 parent 1f979c1 commit 47768a5
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
5 changes: 2 additions & 3 deletions src/onegov/landsgemeinde/templates/macros.pt
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
</metal:agenda-item-title>

<metal:agenda-item-title-in-list define-macro="agenda-item-title-in-list">
<h5 class="list-title"><tal:block i18n:translate="">Agenda item</tal:block> ${agenda_item.number}<br></h5>
<span class="agenda-item-title"><tal:block tal:repeat="part agenda_item.title_parts">${part}<br tal:condition="not:repeat.part.end"></tal:block></span>
<h5 class="list-title"><span class="agenda-item-title"><tal:block tal:repeat="part agenda_item.title_parts">${part}<br tal:condition="not:repeat.part.end"></tal:block></span></h5>
</metal:agenda-item-title-in-list>

<metal:agenda-item-list define-macro="agenda_item_list">
Expand Down Expand Up @@ -62,7 +61,7 @@
<div class="line"></div>
</div>
<div class="title">
<h5 class="list-title"><tal:block metal:use-macro="layout.macros['agenda-item-title-in-list']" tal:define="agenda_item current_agenda_item"/></h5>
<tal:block metal:use-macro="layout.macros['agenda-item-title-in-list']" tal:define="agenda_item current_agenda_item"/>
</div>
</a>
</li>
Expand Down
6 changes: 5 additions & 1 deletion src/onegov/landsgemeinde/theme/styles/landsgemeinde.scss
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,10 @@ h1.main-title small {
margin-bottom: 4rem;
}

.side-panel .agenda-item-list {
padding: .5rem 0;
}

.callout.secondary.agenda-item-resolution,
.callout.secondary.assembly-completed {
background: transparent;
Expand Down Expand Up @@ -408,6 +412,7 @@ h1.main-title small {
}

.title {
border-top: 1px solid $white-smoke;
padding: .5rem 0;
}

Expand Down Expand Up @@ -442,7 +447,6 @@ h1.main-title small {
}

.list-title {
border-top: 1px solid $white-smoke;
padding-top: .7rem;
transition: opacity 200ms linear;

Expand Down
10 changes: 5 additions & 5 deletions tests/onegov/landsgemeinde/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def assert_last_modified():
page.form['number'] = 6
page.form['start_time'] = '10:42:13 AM'
page = page.form.submit().follow()
assert 'Traktandum 6' in page
assert 'A. consectetur adipiscing\nB. tempor incididunt' in page
assert 'https://www.youtube.com/embed/1234?start=4321' in page
assert_last_modified()

Expand All @@ -88,15 +88,15 @@ def assert_last_modified():
page = page.click('Bearbeiten')
page.form['start_time'] = '09:30:14 AM'
page = page.form.submit().follow()
page = page.click('Traktandum 6')
page = page.click('A. consectetur adipiscing')
assert 'https://www.youtube.com/embed/1234?start=4319' in page

# add custom timestamp
page = page.click('Bearbeiten')
page.form['number'] = 6
page.form['video_timestamp'] = '1h2m3s'
page = page.form.submit().follow()
assert 'Traktandum 6' in page
assert 'A. consectetur adipiscing\nB. tempor incididunt' in page
assert 'https://www.youtube.com/embed/1234?start=3723' in page

# add votum
Expand Down Expand Up @@ -159,7 +159,7 @@ def assert_last_modified():
# delete votum
with freeze_time('2023-05-07 9:36'):
page.click('Löschen', href='votum')
page = page.click('Traktandum 6', index=0)
page = page.click('A. consectetur adipiscing', index=0)
assert '<p>Dolore magna aliqua.</p>' in page
assert 'Joe Quimby' not in page
assert_last_modified()
Expand All @@ -169,7 +169,7 @@ def assert_last_modified():
page.click('Löschen')
page = page.click('Landsgemeinde', index=2)
assert '<p>Lorem ipsum dolor sit amet</p>' in page
assert 'Traktandum 6' not in page
assert 'A. consectetur adipiscing' not in page
assert_last_modified()

# delete landsgemeinde
Expand Down

0 comments on commit 47768a5

Please sign in to comment.