Changeset 6181 for SRUAggregator
- Timestamp:
- 04/30/15 17:01:10 (9 years ago)
- Location:
- SRUAggregator/trunk
- Files:
-
- 1 added
- 5 deleted
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
SRUAggregator/trunk/pom.xml
r6174 r6181 8 8 <groupId>eu.clarin.sru.fcs</groupId> 9 9 <artifactId>aggregator</artifactId> 10 <version>2.0.0-beta-4 5</version>10 <version>2.0.0-beta-46</version> 11 11 <name>FCS Aggregator</name> 12 12 -
SRUAggregator/trunk/src/main/resources/assets/clarinservices/clarinservices.css
r6180 r6181 17 17 border-radius: 50px; 18 18 border-top-left-radius: 0; 19 padding: 20px;19 padding: 15px; 20 20 font-size: 13px; 21 } 22 @media (min-width: 768px) { 23 #clarinservices ul.dropdown-menu { 24 width: 483px; 25 } 21 26 } 22 27 … … 26 31 } 27 32 28 #clarinservices ul .flex { 29 display: -webkit-box; /* OLD - iOS 6-, Safari 3.1-6 */ 30 display: -moz-box; /* OLD - Firefox 19- (buggy but mostly works) */ 31 display: -ms-flexbox; /* TWEENER - IE 10 */ 32 display: -webkit-flex; /* NEW - Chrome */ 33 display: flex; 34 } 35 36 #clarinservices table { 37 text-align: center; 38 background-color: #FFFFFF; 39 width: 100%; 40 } 41 42 #clarinservices table td a{ 33 #clarinservices ul li { 34 display: inline; 35 float: left; 36 text-align: center; 37 background-color: #FFFFFF; 38 } 39 40 #clarinservices ul li a{ 43 41 display: block; 44 42 width: 150px; … … 51 49 } 52 50 53 #clarinservices table td:hover a {51 #clarinservices ul li:hover a { 54 52 background-color: #fff; 55 53 border: 2px solid #003f6e; … … 57 55 } 58 56 59 #clarinservices table td a div img { 57 #clarinservices ul li a > div { 58 margin-top:30px; 59 } 60 61 #clarinservices ul li a > div > div { 62 white-space: normal; 63 } 64 65 #clarinservices ul li a div img { 60 66 margin-right: 0px; 61 67 max-width: 100px; 62 68 max-height: 50px; 63 69 } 64 65 70 66 71 -
SRUAggregator/trunk/src/main/resources/assets/clarinservices/clarinservices.js
r6180 r6181 1 1 (function() { 2 2 "use strict"; 3 4 var more_img = "clarinservices/more-clarin-services.png"; 5 6 var service_list = [ 7 { 8 href: 'http://www.clarin.eu/portal', 9 image: 'https://www.clarin.eu/sites/default/files/portal_small.png', 10 title: "CLARIN portal", 11 description: "Quick introduction to CLARIN, giving an impression about what's currently available", 12 }, 13 { 14 href: 'http://www.clarin.eu/services/depositing', 15 image: 'http://www.clarin.eu/sites/default/files/long-term-archive.jpg', 16 title: "Depositing services", 17 description: "Store language resources in a sustainable repository at a CLARIN centre", 18 }, 19 { 20 href: 'http://www.clarin.eu/vlo', 21 image: 'https://www.clarin.eu/sites/default/files/vlo_small.png', 22 title: "Virtual Language Observatory", 23 description: "Discover language resources using a faceted browser or a map", 24 }, 25 { 26 href: 'http://www.clarin.eu/content/easy-access-protected-resources', 27 image: 'http://www.clarin.eu/sites/default/files/federated-identity.jpg', 28 title: "Easy federated access", 29 description: "Get easy access to protected resources, with your institutional username and password.", 30 }, 31 { 32 href: 'http://www.clarin.eu/content/web-services', 33 image: 'https://www.clarin.eu/sites/default/files/webservice.png', 34 title: "Web services and applications", 35 description: "Explore and analyze language data with a wide variety of tools", 36 }, 37 { 38 href: 'http://www.clarin.eu/content/virtual-collections', 39 image: 'https://www.clarin.eu/sites/default/files/virtualcollection.png', 40 title: "Virtual Collections", 41 description: "Create your own digital bookmarks, ideal for citing data sets.", 42 }, 43 { 44 href: 'http://www.clarin.eu/content/language-resource-inventory', 45 image: 'https://www.clarin.eu/sites/default/files/lrt-inventory_small.png', 46 title: "Language Resource Inventory", 47 description: "Submit and access information about language resources relevant to your research." 48 }, 49 { 50 href: 'http://www.clarin.eu/content/content-search', 51 image: 'https://www.clarin.eu/sites/default/files/search.png', 52 title: "Content Search (prototype version)", 53 description: "Search different corpora with a single search engine" 54 }, 55 { 56 href: 'http://www.clarin.eu/contact', 57 image: 'https://www.clarin.eu/sites/default/files/questionmark.png', 58 title: "Consulting Services", 59 description: "Searching for a specific data set or application? Wondering how CLARIN can assist your research? Feel free to contact us!" 60 }, 61 ]; 3 62 4 63 /** … … 9 68 * 4. calling `main` 10 69 */ 11 var more_img = "img/more-clarin-services.png";12 var service_list = [13 [14 {15 href: 'http://www.clarin.eu/portal',16 image: 'https://www.clarin.eu/sites/default/files/portal_small.png',17 title: "CLARIN portal",18 description: "Quick introduction to CLARIN, giving an impression about what's currently available",19 },20 {21 href: 'http://www.clarin.eu/services/depositing',22 image: 'http://www.clarin.eu/sites/default/files/long-term-archive.jpg',23 title: "Depositing services",24 description: "Store language resources in a sustainable repository at a CLARIN centre",25 },26 {27 href: 'http://www.clarin.eu/vlo',28 image: 'https://www.clarin.eu/sites/default/files/vlo_small.png',29 title: "Virtual Language Observatory",30 description: "Discover language resources using a faceted browser or a map",31 },32 ],33 [34 {35 href: 'http://www.clarin.eu/content/easy-access-protected-resources',36 image: 'http://www.clarin.eu/sites/default/files/federated-identity.jpg',37 title: "Easy federated access",38 description: "Get easy access to protected resources, with your institutional username and password.",39 },40 {41 href: 'http://www.clarin.eu/content/web-services',42 image: 'https://www.clarin.eu/sites/default/files/webservice.png',43 title: "Web services and applications",44 description: "Explore and analyze language data with a wide variety of tools",45 },46 {47 href: 'http://www.clarin.eu/content/virtual-collections',48 image: 'https://www.clarin.eu/sites/default/files/virtualcollection.png',49 title: "Virtual Collections",50 description: "Create your own digital bookmarks, ideal for citing data sets.",51 },52 ],53 [54 {55 href: 'http://www.clarin.eu/content/language-resource-inventory',56 image: 'https://www.clarin.eu/sites/default/files/lrt-inventory_small.png',57 title: "Language Resource Inventory",58 description: "Submit and access information about language resources relevant to your research."59 },60 {61 href: 'http://www.clarin.eu/content/content-search',62 image: 'https://www.clarin.eu/sites/default/files/search.png',63 title: "Content Search (prototype version)",64 description: "Search different corpora with a single search engine"65 },66 {67 href: 'http://www.clarin.eu/contact',68 image: 'https://www.clarin.eu/sites/default/files/questionmark.png',69 title: "Consulting Services",70 description: "Searching for a specific data set or application? Wondering how CLARIN can assist your research? Feel free to contact us!"71 },72 ],73 ];74 75 // TODO: now that we're using Zepto, replace manual html management with $ calls76 70 77 71 var entityMap = { … … 91 85 92 86 function renderCell(service) { 93 var href = escapeHtml(service.href); 94 var image = escapeHtml(service.image); 95 var title = escapeHtml(service.title); 96 var description = escapeHtml(service.description); 97 98 var p_image = "<img src='" + image + "'>"; 99 var p_title = "<div>" + title + "</div>"; 100 101 return "<td title='"+description+"'><a href='" + href + "'><div>" + 102 p_image + p_title + 103 "</div></a></td>"; 104 } 105 106 function renderRow(services) { 107 return "<tr>" + services.map(renderCell).join('') + "</tr>"; 87 var img = $('<img>').attr('src', service.image); 88 var title = $('<div>').text(escapeHtml(service.title)); 89 var div = $('<div>').append(img).append(title); 90 var a = $('<a>').attr('href', service.href).append(div); 91 var li = $('<li>').attr('title', escapeHtml(service.description)).append(a); 92 console.log(li); 93 return li; 108 94 } 109 95 110 96 function renderDropdown(service_table) { 111 var rows = service_list.map(renderRow).join(''); 112 var tablediv = "<div><table><tbody>" + rows + "</tbody></table></div>"; 113 return '<div class="dropdown">' + 114 '<button class="btn dropdown-toggle" type="button"'+ 115 ' id="dropdown-clarinservices" data-toggle="dropdown" aria-expanded="true">'+ 116 '<div id="clarinmore"><img src="'+more_img+'"></div> '+ 117 '</button>'+ 118 '<ul class="dropdown-menu" role="menu" aria-labelledby="dropdown-clarinservices">'+ 119 tablediv + 120 '</ul>'+ 121 '</div>'; 97 var img = $('<img>').attr('src', more_img); 98 var imgdiv = $('<div>').attr('id', 'clarinmore').append(img); 99 var button = $('<button>').attr({ 100 'class': 'btn dropdown-toggle', 101 type: 'button', 102 id:"dropdown-clarinservices", 103 'data-toggle': "dropdown", 104 'aria-expanded':"true" 105 }).append(imgdiv); 106 107 var ul = $('<ul>').attr({ 108 'class': 'dropdown-menu', 109 role: 'menu', 110 "aria-labelledby": "dropdown-clarinservices" 111 }); 112 service_list.map(renderCell).forEach(function(x){x.appendTo(ul);}); 113 114 return $('<div>').attr('class', 'dropdown').append(button).append(ul); 122 115 } 123 116 … … 125 118 var csdiv = document.getElementById('clarinservices'); 126 119 if (csdiv) { 127 csdiv.innerHTML = renderDropdown(service_list);120 $(csdiv).append(renderDropdown(service_list)); 128 121 $(csdiv).children().each(function (x) { 129 122 $(x).data('bs.dropdown', new Dropdown(x)); … … 186 179 187 180 Dropdown.prototype.toggle = function (e) { 188 console.log('tggle');189 181 var $this = $(this) 190 182 … … 252 244 253 245 function clearMenus(e) { 254 console.log('clearMenus', e);255 246 if (e && e.which === 3) return 256 247 $(backdrop).remove() … … 272 263 273 264 function getParent($this) { 274 console.log('getParent', $this);275 265 var selector = $this.attr('data-target') 276 266 -
SRUAggregator/trunk/src/main/resources/assets/js/main.js
r6180 r6181 3 3 "use strict"; 4 4 5 var VERSION = window.MyAggregator.VERSION = "v.2.0.0-beta-4 5";5 var VERSION = window.MyAggregator.VERSION = "v.2.0.0-beta-46"; 6 6 7 7 var URLROOT = window.MyAggregator.URLROOT = -
SRUAggregator/trunk/src/main/resources/assets/js/main.jsx
r6180 r6181 3 3 "use strict"; 4 4 5 var VERSION = window.MyAggregator.VERSION = "v.2.0.0-beta-4 5";5 var VERSION = window.MyAggregator.VERSION = "v.2.0.0-beta-46"; 6 6 7 7 var URLROOT = window.MyAggregator.URLROOT =
Note: See TracChangeset
for help on using the changeset viewer.