Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
Findeton committed Jul 3, 2023
1 parent 0f56351 commit d974023
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<div class="hidden unfixed-top-height"></div>
<h1 ng-bind-html="(election.presentation | customI18n : 'public_title') || (election | customI18n : 'title')">
</h1>
<p class="description" ng-bind-html="election.description | addTargetBlank"></p>
<p class="description" ng-bind-html="(election | customI18n : 'description') | addTargetBlank"></p>
</div>
</div>
</div>
Expand All @@ -16,15 +16,15 @@ <h1 ng-bind-html="(election.presentation | customI18n : 'public_title') || (elec
<div class="container">
<div class="row options-row">
<div class="col-xs-12">
<h3>{{election.questions[0].title}}</h3>
<h3>{{election.questions[0] | customI18n : 'title'}}</h3>
</div>
<div class="col-xs-6">
<div class="opt" ng-click="toggleOption(0, 0)">
<span class="glyphicon"
ng-class="{'glyphicon-unchecked': election.questions[0].answers[0].selected === -1,
'glyphicon-check': election.questions[0].answers[0].selected === 0}">
</span>
{{election.questions[0].answers[0].text}}
{{election.questions[0].answers[0] | customI18n : 'text'}}
</div>
</div>
<div class="col-xs-6 left-border">
Expand All @@ -33,20 +33,20 @@ <h3>{{election.questions[0].title}}</h3>
ng-class="{'glyphicon-unchecked': election.questions[0].answers[1].selected === -1,
'glyphicon-check': election.questions[0].answers[1].selected === 0}">
</span>
{{election.questions[0].answers[1].text}}
{{election.questions[0].answers[1] | customI18n : 'text'}}
</div>
<div class="container-fluid" ng-if="election.questions.length > 1">
<div class="row">
<div class="col-xs-12">
<h3>{{election.questions[1].title}}</h3>
<h3>{{election.questions[1] | customI18n : 'title'}}</h3>
</div>
<div class="col-xs-12 col-sm-{{12/election.questions[1].answers.length}}" ng-repeat="answer in election.questions[1].answers">
<div class="opt" ng-click="toggleOption(1, $index)">
<span class="glyphicon"
ng-class="{'glyphicon-unchecked': election.questions[1].answers[$index].selected === -1,
'glyphicon-check': election.questions[1].answers[$index].selected === 0}">
</span>
{{election.questions[1].answers[$index].text}}
{{election.questions[1].answers[$index] | customI18n : 'text'}}
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
ng-if="!category.hidden"
class="election-category"
>
<h2 class="category-title">{{category.title}}</h2>
<h2 class="category-title">{{category | customI18n : 'title'}}</h2>
<div class="category-elections-wrapper">
<div
ng-repeat="election in category.events"
Expand All @@ -15,8 +15,8 @@ <h2 class="category-title">{{category.title}}</h2>
ng-click="canVoteElection(election) && click(election)"
>
<div class="text-container">
<h3 class="election-title">{{election.title}}</h3>
<p class="election-description" ng-if="!!election.description">{{election.description}}</p>
<h3 class="election-title">{{election | customI18n : 'title'}}</h3>
<p class="election-description" ng-if="!!election.description">{{election | customI18n : 'description'}}</p>
<a
href="election/{{ election.event_id }}/public/home"
ng-if="checkElectionStarted(election.electionData)"
Expand Down
12 changes: 6 additions & 6 deletions avBooth/review-ballot-directive/review-ballot-directive.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@
<div class="title-container">
<h3 aria-level="2" class="text-brand-success question-title">
<span>{{$index + 1}}.</span>
<span class="question-title title-text" ng-bind-html="question.title"></span>
<span class="question-title title-text" ng-bind-html="question | customI18n : 'title'"></span>
</h3>
<span class="edit-btn">
<span class="glyphicon glyphicon-edit" aria-hidden="true"></span>
</span>
</div>
<p
class="question-description"
ng-if="question.extra_options.review_screen__show_question_description && question.description"
ng-bind-html="question.description | addTargetBlank"
ng-if="question.extra_options.review_screen__show_question_description && (question.description || question.description_i18n)"
ng-bind-html="(question | customI18n : 'description') | addTargetBlank"
></p>

<!-- Selected items line -->
Expand All @@ -43,7 +43,7 @@ <h3 aria-level="2" class="text-brand-success question-title">
<li
ng-repeat="pair in question.selection"
class="animate-repeat selected-answer" ng-i18next>
[html:i18next]({one: pair[0].text, two: pair[1].text})avBooth.reviewScreen.pair
[html:i18next]({one: (pair[0] | customI18n : 'text'), two: (pair[1] | customI18n : 'text')})avBooth.reviewScreen.pair
</li>
</ul>
<ul
Expand All @@ -55,7 +55,7 @@ <h3 aria-level="2" class="text-brand-success question-title">
ng-class="{'striked-text': markedAsInvalid(question)}"
ng-if="!question.invalidVoteAnswer || answer.id !== question.invalidVoteAnswer.id"
class="animate-repeat selected-answer">
<span ng-bind-html="answer.text"></span>
<span ng-bind-html="answer | customI18n : 'text'"></span>
<span
ng-if="showPoints(question) && !isWriteIn(answer)"
ng-i18next="[i18next]({points: getPoints(question, answer)})avBooth.showSelectedOptionPoints">
Expand Down Expand Up @@ -89,7 +89,7 @@ <h3 aria-level="2" class="text-brand-success question-title">
ng-if="!question.invalidVoteAnswer || answer.id !== question.invalidVoteAnswer.id"
ng-class="{'striked-text': markedAsInvalid(question)}"
class="animate-repeat selected-answer">
<span ng-bind-html="answer.text"></span>
<span ng-bind-html="answer | customI18n : 'text'"></span>
<span
ng-if="showPoints(question) && !isWriteIn(answer)"
ng-i18next="[i18next]({points: getPoints(question, answer)})avBooth.showSelectedOptionPoints">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
<div class="title-container">
<h1 aria-level="2" class="text-brand-success question-title">
<span>{{$index + 1}}.</span>
<span class="question-title title-text" ng-bind-html="question.title"></span>
<span class="question-title title-text" ng-bind-html="question | customI18n : 'title'"></span>
</h1>
</div>

<p
class="question-description"
ng-if="question.extra_options.review_screen__show_question_description && question.description"
ng-bind-html="question.description | addTargetBlank"
ng-if="question.extra_options.review_screen__show_question_description && (question.description || question.description_i18n)"
ng-bind-html="(question | customI18n : 'description') | addTargetBlank"
>
</p>

Expand Down Expand Up @@ -141,7 +141,7 @@ <h1 aria-level="2" class="text-brand-success question-title">
ng-if="!question.invalidVoteAnswer || answer.id !== question.invalidVoteAnswer.id"
ng-class="{'striked-text': markedAsInvalid(question)}"
class="animate-repeat selected-answer">
<span ng-bind-html="answer.text"></span>
<span ng-bind-html="answer | customI18n : 'text'"></span>
<span
ng-if="showPoints(question) && !isWriteIn(answer)"
ng-i18next="[i18next]({points: getPoints(question, answer)})avBooth.showSelectedOptionPoints">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@
ng-bind-html="(election.presentation | customI18n : 'public_title') || (election | customI18n : 'title')"
></h1>
<p
ng-if="election.description"
ng-if="election.description || election.description_i18n"
class="election-description"
ng-bind-html="election.description | addTargetBlank">
ng-bind-html="(election | customI18n : 'description') | addTargetBlank">
</p>
</div>
<div class="row options-row" ng-repeat="question in groupQuestions">
<div class="col-xs-12">
<h2 class="question-title text-center" aria-level="2" ng-bind-html="question.title">
<h2 class="question-title text-center" aria-level="2" ng-bind-html="question | customI18n : 'title'">
</h2>
<p
class="question-description"
ng-if="question.description"
ng-bind-html="question.description | addTargetBlank">
ng-if="question.description || question.description_i18n"
ng-bind-html="question | customI18n : 'description' | addTargetBlank">
</p>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,18 @@ <h1 class="election-header">
<i class="pull-right fa fa-lg fa-question-circle" ng-click="showHelp()"></i>
</h1>
<p
ng-if="election.description"
ng-if="election.description || election.description_i18n"
class="election-description"
ng-bind-html="election.description | addTargetBlank">
ng-bind-html="election | customI18n : 'description' | addTargetBlank">
</p>
<div class="notifications"></div>
<div class="question" ng-repeat="question in groupQuestions">
<h2 class="question-title" aria-level="2" ng-bind-html="question.title">
<h2 class="question-title" aria-level="2" ng-bind-html="question | customI18n : 'title'">
</h2>
<p
class="question-description"
ng-if="question.description"
ng-bind-html="question.description | addTargetBlank">
ng-if="question.description || question.description_i18n"
ng-bind-html="question | customI18n : 'description' | addTargetBlank">
</p>

<!-- QUESTION OPTIONS START -->
Expand Down

0 comments on commit d974023

Please sign in to comment.