Skip to content

Commit 5ff8db3

Browse files
authored
Merge pull request #22 from agoravoting/move-footer
move foot directive here, first commit
2 parents f875700 + ad0432a commit 5ff8db3

File tree

21 files changed

+357
-15
lines changed

21 files changed

+357
-15
lines changed

app.less

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
/* avUi */
3737
@import "avUi/simple-error-directive/simple-error-directive.less";
3838
@import "avUi/change-lang-directive/change-lang-directive.less";
39+
@import "avUi/foot-directive/foot-directive.less";
3940

4041
/* Add Component LESS Above */
4142
@import "../../app.less";
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
<div class="commonfoot">
2+
<div class="container">
3+
<div class="row">
4+
<div class="col-md-2 col-md-offset-1">
5+
<h3 ng-i18next="avCommon.foot.contact"></h3>
6+
<ul>
7+
<li><a href="mailto:{{contact.email}}" ng-i18next="avCommon.foot.contactsupport"></a></li>
8+
<li><a href="mailto:{{contact.sales}}" ng-i18next="avCommon.foot.contactsales"></a></li>
9+
</ul>
10+
<!-- social links -->
11+
<div class="social">
12+
<a href="{{social.facebook}}"><i class="fa fa-fw fa-lg fa-facebook"></i></a>
13+
<a href="{{social.twitter}}"><i class="fa fa-fw fa-lg fa-twitter"></i></a>
14+
<a href="{{social.googleplus}}"><i class="fa fa-fw fa-lg fa-google-plus"></i></a>
15+
<a href="{{social.youtube}}"><i class="fa fa-fw fa-lg fa-youtube-play"></i></a>
16+
<a href="{{social.github}}"><i class="fa fa-fw fa-lg fa-github"></i></a>
17+
</div>
18+
</div>
19+
20+
<div class="col-md-2">
21+
<h3 ng-i18next="avCommon.foot.technology"></h3>
22+
<ul>
23+
<li><a href="{{technology.aboutus}}" ng-i18next="avCommon.foot.aboutus"></a></li>
24+
<li><a href="{{technology.pricing}}" ng-i18next="avCommon.foot.pricing"></a></li>
25+
<li><a href="{{technology.overview}}" ng-i18next="avCommon.foot.technology"></a></li>
26+
<li><a href="{{technology.solutions}}" ng-i18next="avCommon.foot.solutions"></a></li>
27+
<li><a href="{{technology.admin_manual}}" ng-i18next="avCommon.foot.adminManual"></a></li>
28+
</ul>
29+
</div>
30+
31+
<div class="col-md-2">
32+
<h3 ng-i18next="avCommon.foot.legal"></h3>
33+
<ul>
34+
<li>
35+
<a
36+
href="{{legal.terms_of_service}}"
37+
ng-i18next="avCommon.foot.tos">
38+
</a>
39+
</li>
40+
<li>
41+
<a
42+
href="{{legal.cookies}}"
43+
ng-i18next="avCommon.foot.cookies">
44+
</a>
45+
</li>
46+
<li>
47+
<a
48+
href="{{legal.privacy}}"
49+
ng-i18next="avCommon.foot.privacy">
50+
</a>
51+
</li>
52+
<li>
53+
<a
54+
href="{{legal.security_contact}}"
55+
ng-i18next="avCommon.foot.securitycontact">
56+
</a>
57+
</li>
58+
<li>
59+
<a
60+
target="_blank"
61+
href="{{legal.community_website}}"
62+
ng-i18next="avCommon.foot.communitywebsite">
63+
</a>
64+
</li>
65+
</ul>
66+
</div>
67+
</div>
68+
</div>
69+
</div>

avUi/foot-directive/foot-directive.js

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
/**
2+
* This file is part of agora-gui-admin.
3+
* Copyright (C) 2015-2016 Agora Voting SL <[email protected]>
4+
5+
* agora-gui-admin is free software: you can redistribute it and/or modify
6+
* it under the terms of the GNU Affero General Public License as published by
7+
* the Free Software Foundation, either version 3 of the License.
8+
9+
* agora-gui-admin is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU Affero General Public License for more details.
13+
14+
* You should have received a copy of the GNU Affero General Public License
15+
* along with agora-gui-admin. If not, see <http://www.gnu.org/licenses/>.
16+
**/
17+
18+
angular.module('avUi')
19+
.directive('avFoot', function(ConfigService) {
20+
// we use it as something similar to a controller here
21+
function link(scope, element, attrs) {
22+
scope.contact = ConfigService.contact;
23+
scope.social = ConfigService.social;
24+
scope.technology = ConfigService.technology;
25+
scope.legal = ConfigService.legal;
26+
}
27+
28+
return {
29+
restrict: 'AE',
30+
scope: {
31+
},
32+
link: link,
33+
templateUrl: 'avUi/foot-directive/foot-directive.html'
34+
};
35+
});
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
.commonfoot {
2+
padding: 40px 0 200px 0;
3+
background-color: @av-bg;
4+
}
5+
6+
.commonfoot ul {
7+
margin: 0px;
8+
padding: 0px;
9+
list-style: none;
10+
}
11+
12+
.commonfoot .social {
13+
margin-top: 10px;
14+
}

dist/appCommon-v3.0.1.js

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -938,7 +938,18 @@ angular.module("avRegistration").factory("Authmethod", [ "$http", "$cookies", "C
938938
templateUrl: "avUi/documentation-directive/documentation-directive.html",
939939
controller: "DocumentationUiController"
940940
};
941-
}), angular.module("agora-gui-common", [ "ui.bootstrap", "ui.utils", "ui.router", "ngAnimate", "ngResource", "ngCookies", "ipCookie", "ngSanitize", "infinite-scroll", "angularMoment", "avConfig", "jm.i18next", "avRegistration", "avUi", "avTest", "angularFileUpload", "dndLists", "angularLoad", "angular-date-picker-polyfill", "ng-autofocus" ]),
941+
}), angular.module("avUi").directive("avFoot", [ "ConfigService", function(ConfigService) {
942+
function link(scope, element, attrs) {
943+
scope.contact = ConfigService.contact, scope.social = ConfigService.social, scope.technology = ConfigService.technology,
944+
scope.legal = ConfigService.legal;
945+
}
946+
return {
947+
restrict: "AE",
948+
scope: {},
949+
link: link,
950+
templateUrl: "avUi/foot-directive/foot-directive.html"
951+
};
952+
} ]), angular.module("agora-gui-common", [ "ui.bootstrap", "ui.utils", "ui.router", "ngAnimate", "ngResource", "ngCookies", "ipCookie", "ngSanitize", "infinite-scroll", "angularMoment", "avConfig", "jm.i18next", "avRegistration", "avUi", "avTest", "angularFileUpload", "dndLists", "angularLoad", "angular-date-picker-polyfill", "ng-autofocus" ]),
942953
angular.module("jm.i18next").config([ "$i18nextProvider", "ConfigServiceProvider", function($i18nextProvider, ConfigServiceProvider) {
943954
$("#no-js").hide(), $i18nextProvider.options = _.extend({
944955
useCookie: !0,
@@ -996,6 +1007,7 @@ angular.module("jm.i18next").config([ "$i18nextProvider", "ConfigServiceProvider
9961007
$templateCache.put("avRegistration/success.html", '<div av-success><p ng-i18next="avRegistration.successRegistration"></p></div>'),
9971008
$templateCache.put("avUi/change-lang-directive/change-lang-directive.html", '<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">{{ deflang }} <span class="caret"></span></a><ul class="dropdown-menu" role="menu"><li ng-repeat="lang in langs"><a ng-click="changeLang(lang)">{{lang}}</a></li></ul>'),
9981009
$templateCache.put("avUi/documentation-directive/documentation-directive.html", '<div><h2 class="text-center text-av-secondary" ng-i18next="avDocumentation.documentation.title"></h2><p ng-i18next="avDocumentation.documentation.first_line"></p><ul><li><a href="{{documentation.faq}}" target="_blank" ng-i18next="avDocumentation.documentation.faq"></a></li><li><a href="{{documentation.overview}}" target="_blank" ng-i18next="avDocumentation.documentation.overview"></a></li><li><a href="{{auths_url}}" target="_blank" ng-i18next="avDocumentation.documentation.authorities"></a></li><li><a href="{{documentation.technical}}" target="_blank" ng-i18next="avDocumentation.documentation.technical"></a></li><li><a href="{{documentation.security_contact}}" target="_blank" ng-i18next="avDocumentation.documentation.security_contact"></a></li><li><a href="{{legal_url}}" target="_blank" ng-i18next="avDocumentation.legal.title"></a></li></ul><div class="documentation-html-include" ng-bind-html="documentation_html_include | addTargetBlank"></div></div>'),
1010+
$templateCache.put("avUi/foot-directive/foot-directive.html", '<div class="commonfoot"><div class="container"><div class="row"><div class="col-md-2 col-md-offset-1"><h3 ng-i18next="avCommon.foot.contact"></h3><ul><li><a href="mailto:{{contact.email}}" ng-i18next="avCommon.foot.contactsupport"></a></li><li><a href="mailto:{{contact.sales}}" ng-i18next="avCommon.foot.contactsales"></a></li></ul><!-- social links --><div class="social"><a href="{{social.facebook}}"><i class="fa fa-fw fa-lg fa-facebook"></i></a> <a href="{{social.twitter}}"><i class="fa fa-fw fa-lg fa-twitter"></i></a> <a href="{{social.googleplus}}"><i class="fa fa-fw fa-lg fa-google-plus"></i></a> <a href="{{social.youtube}}"><i class="fa fa-fw fa-lg fa-youtube-play"></i></a> <a href="{{social.github}}"><i class="fa fa-fw fa-lg fa-github"></i></a></div></div><div class="col-md-2"><h3 ng-i18next="avCommon.foot.technology"></h3><ul><li><a href="{{technology.aboutus}}" ng-i18next="avCommon.foot.aboutus"></a></li><li><a href="{{technology.pricing}}" ng-i18next="avCommon.foot.pricing"></a></li><li><a href="{{technology.overview}}" ng-i18next="avCommon.foot.technology"></a></li><li><a href="{{technology.solutions}}" ng-i18next="avCommon.foot.solutions"></a></li><li><a href="{{technology.admin_manual}}" ng-i18next="avCommon.foot.adminManual"></a></li></ul></div><div class="col-md-2"><h3 ng-i18next="avCommon.foot.legal"></h3><ul><li><a href="{{legal.terms_of_service}}" ng-i18next="avCommon.foot.tos"></a></li><li><a href="{{legal.cookies}}" ng-i18next="avCommon.foot.cookies"></a></li><li><a href="{{legal.privacy}}" ng-i18next="avCommon.foot.privacy"></a></li><li><a href="{{legal.security_contact}}" ng-i18next="avCommon.foot.securitycontact"></a></li><li><a target="_blank" href="{{legal.community_website}}" ng-i18next="avCommon.foot.communitywebsite"></a></li></ul></div></div></div></div>'),
9991011
$templateCache.put("avUi/simple-error-directive/simple-error-directive.html", '<div class="av-simple-error-title" ng-transclude></div>'),
10001012
$templateCache.put("test/test_booth_widget.html", '<!DOCTYPE html><html><head><title>Test frame</title><meta charset="UTF-8"></head><script>function getCastHmac(auth_data, callback) {\n callback("khmac:///sha-256;5e25a9af28a33d94b8c2c0edbc83d6d87355e45b93021c35a103821557ec7dc5/voter-1110-1dee0c135afeae29e208550e7258dab7b64fb008bc606fc326d41946ab8e773f:1415185712");\n }</script><body style="overflow-y: hidden; overflow-x: hidden; padding: 0; margin: 0"><div style="width: 100%; display: block; position: absolute; top: 0; bottom: 0; scroll: none; padding: 0; margin: 0"><a class="agoravoting-voting-booth" href="http://agora.dev/#/election/1110/vote" data-authorization-funcname="getCastHmac">Votar con Agora Voting</a><script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="http://agora.dev/avWidgets.min.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","agoravoting-widgets-js");</script></div></body></html>'),
10011013
$templateCache.put("test/unit_test_e2e.html", '<div dynamic="html" id="dynamic-result"></div>');
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
.commonfoot {
2+
padding: 40px 0 200px 0;
3+
background-color: @av-bg;
4+
}
5+
6+
.commonfoot ul {
7+
margin: 0px;
8+
padding: 0px;
9+
list-style: none;
10+
}
11+
12+
.commonfoot .social {
13+
margin-top: 10px;
14+
}

dist/locales/ca.json

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,29 @@
8484
}
8585
},
8686
"avCommon": {
87-
"poweredBy": "Funciona amb <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>"
87+
"poweredBy": "Funciona amb <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>",
88+
"foot": {
89+
"contact": "Contacto",
90+
"contactsupport": "Contacto de soporte",
91+
"contactsales": "Contacto de ventas",
92+
"callsales": "Ventas:",
93+
"aboutus": "Acerca de",
94+
"pricing": "Precios",
95+
"technology": "Tecnología",
96+
"solutions": "Soluciones",
97+
"adminManual": "Manual de admin",
98+
"electionTypes": "Tipos de votació",
99+
"primaries": "Primarias y elecciones de candidatos",
100+
"participatoryBudgeting": "Presupuestos participativos",
101+
"referendums": "Referéndums y consultas",
102+
"professional": "Elecciones profesionales y sindicales",
103+
"universities": "Universidades",
104+
"legal": "Legal",
105+
"tos": "Condiciones de uso",
106+
"cookies": "Política de Cookies",
107+
"privacy": "Política de Privacidad",
108+
"securitycontact": "Contacto de seguridad",
109+
"communitywebsite": "Sitio web del proyecto"
110+
}
88111
}
89112
}

dist/locales/en.json

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,30 @@
9191
}
9292
},
9393
"avCommon": {
94-
"poweredBy": "Powered by <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>"
94+
"poweredBy": "Powered by <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>",
95+
"foot": {
96+
"contact": "Contact",
97+
"contactsupport": "Contact support",
98+
"contactsales": "Contact sales",
99+
"callsales": "Sales: ",
100+
"aboutus": "About us",
101+
"pricing": "Pricing",
102+
"technology": "Technology",
103+
"solutions": "Solutions",
104+
"adminManual": "Admin Manual",
105+
"electionTypes": "Election types",
106+
"primaries": "Primaries and candidate elections",
107+
"participatoryBudgeting": "Participatory budgeting",
108+
"referendums": "Referendums and consultations",
109+
"professional": "Professionals and Labor Unions",
110+
"universities": "Universities",
111+
"legal": "Legal",
112+
"tos": "Term of service",
113+
"cookies": "Cookies policy",
114+
"privacy": "Privacy policy",
115+
"securitycontact": "Security Contact",
116+
"communitywebsite": "Community Website"
117+
}
95118
},
96119
"cookies-eu": {
97120
"text": "COOOOOKIES"

dist/locales/es.json

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,30 @@
9191
}
9292
},
9393
"avCommon": {
94-
"poweredBy": "Funciona con <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>"
94+
"poweredBy": "Funciona con <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>",
95+
"foot": {
96+
"contact": "Contacto",
97+
"contactsupport": "Contacto de soporte",
98+
"contactsales": "Contacto de ventas",
99+
"callsales": "Ventas: ",
100+
"aboutus": "Acerca de",
101+
"pricing": "Precios",
102+
"technology": "Tecnología",
103+
"solutions": "Soluciones",
104+
"adminManual": "Manual de admin",
105+
"electionTypes": "Tipos de votación",
106+
"primaries": "Primarias y elecciones de candidatos",
107+
"participatoryBudgeting": "Presupuestos participativos",
108+
"referendums": "Referéndums y consultas",
109+
"professional": "Elecciones profesionales y sindicales",
110+
"universities": "Universidades",
111+
"legal": "Legal",
112+
"tos": "Condiciones de uso",
113+
"cookies": "Política de Cookies",
114+
"privacy": "Política de Privacidad",
115+
"securitycontact": "Contacto de seguridad",
116+
"communitywebsite": "Sitio web del proyecto"
117+
}
95118
},
96119
"cookies-eu": {
97120
"text": "COOOOOKIES"

dist/locales/gl.json

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,29 @@
8989
}
9090
},
9191
"avCommon": {
92-
"poweredBy": "Funciona amb <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>"
92+
"poweredBy": "Funciona amb <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>",
93+
"foot": {
94+
"contact": "Contacto",
95+
"contactsupport": "Contacto de soporte",
96+
"contactsales": "Contacto de ventas",
97+
"callsales": "Ventas:",
98+
"aboutus": "Acerca de",
99+
"pricing": "Prezos",
100+
"technology": "Tecnología",
101+
"solutions": "Soluciones",
102+
"adminManual": "Manual de admin",
103+
"electionTypes": "Tipos de votación",
104+
"primaries": "Primarias y elecciones de candidatos",
105+
"participatoryBudgeting": "Presupuestos participativos",
106+
"referendums": "Referéndums y consultas",
107+
"professional": "Elecciones profesionales y sindicales",
108+
"universities": "Universidades",
109+
"legal": "Legal",
110+
"tos": "Condiciones de uso",
111+
"cookies": "Política de Cookies",
112+
"privacy": "Política de Privacidad",
113+
"securitycontact": "Contacto de seguridad",
114+
"communitywebsite": "Sitio web del proyecto"
115+
}
93116
}
94117
}

dist/themes/bcnencomu/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/themes/cup/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/themes/default/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/themes/loop/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/themes/podemos/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/themes/test/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@
109109
<script src="avUi/custom-delegates.js" class="app"></script>
110110
<script src="avUi/learn-more-directive.js" class="app"></script>
111111
<script src="avUi/documentation-directive/documentation-directive.js" class="app"></script>
112+
<script src="avUi/foot-directive/foot-directive.js" class="app"></script>
112113

113114
<script src="app.js" class="app"></script>
114115

locales/ca.json

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,32 @@
9393
},
9494

9595
"avCommon": {
96-
"poweredBy": "Funciona amb <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>"
96+
"poweredBy": "Funciona amb <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>",
97+
"foot": {
98+
"contact": "Contacto",
99+
"contactsupport": "Contacto de soporte",
100+
"contactsales": "Contacto de ventas",
101+
"callsales": "Ventas:",
102+
103+
"aboutus": "Acerca de",
104+
"pricing": "Precios",
105+
"technology": "Tecnología",
106+
"solutions": "Soluciones",
107+
"adminManual": "Manual de admin",
108+
109+
"electionTypes": "Tipos de votació",
110+
"primaries": "Primarias y elecciones de candidatos",
111+
"participatoryBudgeting": "Presupuestos participativos",
112+
"referendums": "Referéndums y consultas",
113+
"professional": "Elecciones profesionales y sindicales",
114+
"universities": "Universidades",
115+
116+
"legal": "Legal",
117+
"tos": "Condiciones de uso",
118+
"cookies": "Política de Cookies",
119+
"privacy": "Política de Privacidad",
120+
"securitycontact": "Contacto de seguridad",
121+
"communitywebsite": "Sitio web del proyecto"
122+
}
97123
}
98124
}

locales/en.json

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,32 @@
101101
},
102102

103103
"avCommon": {
104-
"poweredBy": "Powered by <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>"
104+
"poweredBy": "Powered by <strong><a href=\"__url__\" target=\"_blank\">__name__</a></strong>",
105+
"foot": {
106+
"contact": "Contact",
107+
"contactsupport": "Contact support",
108+
"contactsales": "Contact sales",
109+
"callsales": "Sales: ",
110+
111+
"aboutus": "About us",
112+
"pricing": "Pricing",
113+
"technology": "Technology",
114+
"solutions": "Solutions",
115+
"adminManual": "Admin Manual",
116+
117+
"electionTypes": "Election types",
118+
"primaries": "Primaries and candidate elections",
119+
"participatoryBudgeting": "Participatory budgeting",
120+
"referendums": "Referendums and consultations",
121+
"professional": "Professionals and Labor Unions",
122+
"universities": "Universities",
123+
124+
"legal": "Legal",
125+
"tos": "Term of service",
126+
"cookies": "Cookies policy",
127+
"privacy": "Privacy policy",
128+
"securitycontact": "Security Contact",
129+
"communitywebsite": "Community Website"
130+
}
105131
}
106132
}

0 commit comments

Comments
 (0)