Repositorio del curso CCOM4030 el semestre B91 del proyecto Artesanías con el Instituto de Cultura

index.html 33KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713
  1. <!DOCTYPE html>
  2. <!--
  3. Licensed to the Apache Software Foundation (ASF) under one
  4. or more contributor license agreements. See the NOTICE file
  5. distributed with this work for additional information
  6. regarding copyright ownership. The ASF licenses this file
  7. to you under the Apache License, Version 2.0 (the
  8. "License"); you may not use this file except in compliance
  9. with the License. You may obtain a copy of the License at
  10. http://www.apache.org/licenses/LICENSE-2.0
  11. Unless required by applicable law or agreed to in writing,
  12. software distributed under the License is distributed on an
  13. "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  14. KIND, either express or implied. See the License for the
  15. specific language governing permissions and limitations
  16. under the License.
  17. -->
  18. <html>
  19. <head>
  20. <!--
  21. Customize this policy to fit your own app's needs. For more guidance, see:
  22. https://github.com/apache/cordova-plugin-whitelist/blob/master/README.md#content-security-policy
  23. Some notes:
  24. * gap: is required only on iOS (when using UIWebView) and is needed for JS->native communication
  25. * https://ssl.gstatic.com is required only on Android and is needed for TalkBack to function properly
  26. * Disables use of inline scripts in order to mitigate risk of XSS vulnerabilities. To change this:
  27. * Enable inline JS: add 'unsafe-inline' to default-src
  28. -->
  29. <meta http-equiv="Content-Security-Policy" content="default-src *; style-src 'self' http://* 'unsafe-inline'; script-src 'self' http://* 'unsafe-inline' 'unsafe-eval'" />
  30. <!--these three for the calendar-->
  31. <link href="https://fonts.googleapis.com/css?family=Roboto+Condensed" rel="stylesheet">
  32. <link href="css/robotocondensed.css" rel="stylesheet">
  33. <link rel="stylesheet" href="calendar_files/css/demo.css"/>
  34. <link rel="stylesheet" href="css/file.css"/>
  35. <link rel="stylesheet" href="calendar_files/css/theme1.css"/>
  36. <!--this is for the search bar-->
  37. <link rel = "stylesheet" href = "css/searchbar1.css">
  38. <meta name="format-detection" content="telephone=no">
  39. <meta name="msapplication-tap-highlight" content="no">
  40. <meta name="viewport" content="initial-scale=1, width=device-width, height=device, heigth viewport-fit=cover">
  41. <link rel="stylesheet" type="text/css" href="css/index.css">
  42. <link rel="stylesheet" href="lib/OnsenUI/css/onsenui.css">
  43. <link rel="stylesheet" href="lib/OnsenUI/css/onsen-css-components.min.css">
  44. <script src="lib/OnsenUI/js/onsenui.min.js"></script>
  45. <script src="js/jquery_.js"></script>
  46. </head>
  47. <body>
  48. <script type="text/javascript" src="js/saveLocal.js"></script>
  49. <ons-page>
  50. <ons-toolbar>
  51. <div class="center">Artesanias PR</div>
  52. <div class="right"><img class="list-item__thumbnail" src="img/ICP.png"></div>
  53. </ons-toolbar>
  54. <ons-tabbar swipeable position="bottom" modifier="autogrow">
  55. <ons-tab page="home.html" label="Hogar" active></ons-tab>
  56. <ons-tab page="renglones.html" label="Artesanías"></ons-tab>
  57. <ons-tab page ="search.html" label="Buscar"> </ons-tab>
  58. <ons-tab page="ferias.html" label="Eventos"></ons-tab>
  59. <ons-tab page="instituto.html" label="ICP"></ons-tab>
  60. </ons-tabbar>
  61. </ons-page>
  62. </ons-navigator>
  63. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  64. <template id="home.html">
  65. <ons-page id="home" class="red">
  66. <ons-card id="azar">
  67. <!--<div class="title" id="Title"></div>-->
  68. <div id="image"></div><br>
  69. <div class="content" id="Content"></div>
  70. <script type="text/javascript" src="js/azar.js"> </script>
  71. </ons-card>
  72. </ons-page>
  73. </template>
  74. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  75. <template id="artesanos.html">
  76. <ons-page id="artesanos">
  77. <ons-toolbar>
  78. <div class="left"><ons-back-button>Atrás</ons-back-button></div>
  79. <div class="center"></div>
  80. </ons-toolbar>
  81. <ons-pull-hook id="pull-hook" threshold-height="120px">
  82. <ons-icon id="pull-hook-icon" size="22px" class="pull-hook-content" icon="fa-arrow-down"></ons-icon>
  83. </ons-pull-hook>
  84. <ons-list id="artesanos-list" src="">
  85. <ons-list-header>Artesanos</ons-list-header>
  86. </ons-list>
  87. <script>
  88. ons.getScriptPage().onInit = function () {
  89. this.querySelector('ons-toolbar div.center').textContent = this.data.title;
  90. //var File = this.data.title.toUpperCase() + '.json' ;
  91. var Esp = this.data.esp.split(', ');
  92. var artesanos_json = this.data.json;
  93. //Convertir en mayuscula primera letra del string.
  94. for(var i=0; i<Esp.length; i++) {
  95. Esp[i] = Esp[i].charAt(0).toUpperCase() + Esp[i].slice(1);
  96. };
  97. var pullHook = document.getElementById('pull-hook');
  98. var icon = document.getElementById('pull-hook-icon');
  99. pullHook.addEventListener('changestate', function (event) {
  100. switch (event.state) {
  101. case 'initial':
  102. icon.setAttribute('icon', 'fa-arrow-down');
  103. icon.removeAttribute('rotate');
  104. icon.removeAttribute('spin');
  105. break;
  106. case 'preaction':
  107. icon.setAttribute('icon', 'fa-arrow-down');
  108. icon.setAttribute('rotate', '180');
  109. icon.removeAttribute('spin');
  110. break;
  111. case 'action':
  112. icon.setAttribute('icon', 'fa-spinner');
  113. icon.removeAttribute('rotate');
  114. icon.setAttribute('spin', true);
  115. break;
  116. }
  117. });
  118. var getArtesania = function (num) {
  119. var Artesanos = ``;
  120. console.log('Filtrado de ',Esp[num])
  121. var results = [];
  122. var searchVal = "my Name";
  123. for (var i=0 ; i < artesanos_json.length ; i++)
  124. {
  125. if (artesanos_json[i].Especificaciones.includes(Esp[num])) {
  126. results.push(artesanos_json[i]);
  127. }
  128. }
  129. /*var arr1=artesanos_json.filter(function(item){
  130. return item.Nombre=="Ana";
  131. });*/
  132. for(var i=0; i<results.length; i++) {
  133. //if(Esp[num] in artesanos_json.) {}
  134. Artesanos=Artesanos+`<a id='home.html'>${results[i].Nombre} | ${results[i].Municipio}<br>`
  135. //`<a id='home.html'>${Artesania.artesano} | ${Artesania.municipio}</a> `
  136. }
  137. return {
  138. name: Esp[num],
  139. artesan: Artesanos
  140. };
  141. };
  142. var getData = function () {
  143. const data = [];
  144. for (var i = 0; i < Esp.length; i++) {
  145. data.push(getArtesania(i));
  146. }
  147. return data;
  148. };
  149. var createArtesano = function (Artesano) {
  150. return ons.createElement(`
  151. <ons-list-item expandable tappable>
  152. <div class="center" >${Artesano.Nombre}</div>
  153. <div class="expandable-content"> Municipio: ${Artesano.Municipio}<br>
  154. Tel\u00e9fono: ${Artesano["Telefono 1"]}<br>
  155. Correo Electr\u00f3nico: ${Artesano["E-mail"]}<br>
  156. </div>
  157. </ons-list-item>`
  158. );
  159. };
  160. //var Artesanias = getData();
  161. //artesanos_json
  162. for (Artesano of artesanos_json) {
  163. var cont = 0;
  164. var lista = document.getElementById('artesanos-list');
  165. //Recopilar datos no vacios.
  166. if (Artesano.Municipio.trim().length != 0) {
  167. cont ++;
  168. }
  169. if (Artesano["Telefono 1"].trim().length != 0) {
  170. cont ++;
  171. }
  172. if (Artesano["E-mail"].trim().length != 0 & Artesano["E-mail"].toUpperCase().trim() != "NO TIENE") {
  173. cont ++;
  174. }
  175. if (Artesano.Especificacion.trim().length != 0) {
  176. cont ++;
  177. }
  178. //info a pasar
  179. //'title':'${Artesano.Nombre}','esp': '${info}'
  180. var item = ons.createElement(`<ons-list-item onclick="myNavigator.pushPage('artesano.html', { data: { title: '${Artesano.Nombre}', mun: '${Artesano.Municipio}', tel: '${Artesano["Telefono 1"]}', email: '${Artesano["E-mail"]}', esp: '${Artesano.Especificacion}', redes: '${Artesano["E-Commerce 1"]}' } })" tappable>
  181. <div class="title">${Artesano.Nombre}</div>
  182. </ons-list-item>`);
  183. if(cont == 0){
  184. console.log(Artesano.Nombre+' no tiene ningun tipo de informacion.');
  185. //return ons.createElement(``);
  186. }
  187. else {
  188. lista.appendChild(item);
  189. }
  190. };
  191. };
  192. </script>
  193. <style>
  194. .pull-hook-content {
  195. color: #333;
  196. transition: transform .25s ease-in-out;
  197. }
  198. </style>
  199. </ons-page>
  200. </template>
  201. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  202. <template id="artesanias.html">
  203. <ons-page id="artesanias">
  204. <ons-toolbar>
  205. <div class="left"><ons-back-button>Atrás</ons-back-button></div>
  206. <div class="center"></div>
  207. </ons-toolbar>
  208. <ons-pull-hook id="pull-hook" threshold-height="120px">
  209. <ons-icon id="pull-hook-icon" size="22px" class="pull-hook-content" icon="fa-arrow-down"></ons-icon>
  210. </ons-pull-hook>
  211. <ons-list id="artesania-list" src="">
  212. <ons-list-header>Artesanias</ons-list-header>
  213. </ons-list>
  214. <script>
  215. ons.getScriptPage().onInit = function () {
  216. this.querySelector('ons-toolbar div.center').textContent = this.data.title;
  217. //var File = this.data.title.toUpperCase() + '.json' ;
  218. var Esp = this.data.esp.split(', ');
  219. var artesanos_json = this.data.json;
  220. //Convertir en mayuscula primera letra del string.
  221. for(var i=0; i<Esp.length; i++) {
  222. Esp[i] = Esp[i].charAt(0).toUpperCase() + Esp[i].slice(1);
  223. };
  224. var pullHook = document.getElementById('pull-hook');
  225. var icon = document.getElementById('pull-hook-icon');
  226. pullHook.addEventListener('changestate', function (event) {
  227. switch (event.state) {
  228. case 'initial':
  229. icon.setAttribute('icon', 'fa-arrow-down');
  230. icon.removeAttribute('rotate');
  231. icon.removeAttribute('spin');
  232. break;
  233. case 'preaction':
  234. icon.setAttribute('icon', 'fa-arrow-down');
  235. icon.setAttribute('rotate', '180');
  236. icon.removeAttribute('spin');
  237. break;
  238. case 'action':
  239. icon.setAttribute('icon', 'fa-spinner');
  240. icon.removeAttribute('rotate');
  241. icon.setAttribute('spin', true);
  242. break;
  243. }
  244. });
  245. var getArtesania = function (num) {
  246. var Artesanos = ``,
  247. ArtesanosInfo = ``;
  248. //console.log('Filtrado de ',Esp[num])
  249. var results = [];
  250. var searchVal = "my Name";
  251. for (var i=0 ; i < artesanos_json.length ; i++)
  252. {
  253. if (artesanos_json[i].Especificacion.includes(Esp[num])) {
  254. results.push(artesanos_json[i]);
  255. }
  256. }
  257. /*var arr1=artesanos_json.filter(function(item){
  258. return item.Nombre=="Ana";
  259. });*/
  260. for(var i=0; i<results.length; i++) {
  261. //if(Esp[num] in artesanos_json.) {}
  262. Artesanos+=`${results[i].Nombre}|`
  263. ArtesanosInfo+=`${results[i].Municipio}|${results[i]["Telefono 1"]}|${results[i]["E-mail"]}|${results[i].Especificacion}&&`
  264. //`<a id='home.html'>${Artesania.artesano} | ${Artesania.municipio}</a> `
  265. }
  266. return {
  267. name: Esp[num],
  268. artesan: Artesanos,
  269. info: ArtesanosInfo
  270. };
  271. };
  272. var getData = function () {
  273. const data = [];
  274. for (var i = 0; i < Esp.length; i++) {
  275. data.push(getArtesania(i));
  276. }
  277. return data;
  278. };
  279. var createArtesania = function (Artesania) {
  280. //console.log('Devuelto elemento')
  281. var listaArt=``;
  282. var arts = Artesania.artesan.split('|');
  283. var artsInfo = Artesania.info.split('&&');
  284. for(var i=0; i<arts.length; i++) {
  285. var lot = artsInfo[i].split('|'),
  286. mun = lot[0],
  287. tel = lot[1],
  288. email = lot[2],
  289. esp = lot[3],
  290. redes = lot[4];
  291. listaArt += `<ons-item tappable onclick="myNavigator.pushPage('artesano.html', {data: {title:'${arts[i]}', mun: '${mun}', tel: '${tel}', email: '${email}', esp: '${esp}', redes: '${redes}'}} )" ><div class="center">`+ arts[i] +`</div></ons-item><br>`;
  292. }
  293. return ons.createElement(`
  294. <ons-list-item expandable tappable>
  295. <div class="center" >${Artesania.name}</div>
  296. <div class="expandable-content">Artesanos que trabajan con ${Artesania.name}
  297. <ons-card>${listaArt}</ons-card></div>
  298. </ons-list-item>`
  299. );
  300. };
  301. var Artesanias = getData();
  302. for (Art of Artesanias) {
  303. var Artesania = createArtesania(Art);
  304. document.getElementById('artesania-list').appendChild(Artesania);
  305. };
  306. pullHook.onAction = function (done) {
  307. setTimeout(function() {
  308. document.getElementById('artesania-list').appendChild(createArtesania(getArtesania()));
  309. done();
  310. }, 400);
  311. }
  312. };
  313. </script>
  314. <style>
  315. .pull-hook-content {
  316. color: #333;
  317. transition: transform .25s ease-in-out;
  318. }
  319. </style>
  320. </ons-page>
  321. </template>
  322. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  323. <!----------------------------------------------------------------------------------->
  324. <script src = "js/searchfunctions.js"></script>
  325. <script>
  326. //JSON file that has all the artesanos
  327. var all_artesanos = JSON.parse(window.localStorage.getItem("TODOS"));
  328. function filter(){
  329. var input = document.getElementById('searchbar').value;
  330. var inputarte = document.getElementById('searchartesania').value;
  331. var inputmuni = document.getElementById('searchbarmunicipio').value;
  332. var x = document.getElementsByClassName('artists');
  333. //making sure they're all in the same format
  334. input = input.trim().toLowerCase();
  335. inputarte = inputarte.trim().toLowerCase();
  336. inputmuni = inputmuni.trim().toLowerCase();
  337. input = acento_replace(input);
  338. inputarte = acento_replace(inputarte);
  339. inputmuni = acento_replace(inputmuni);
  340. //default case is where evey one of them has nothing or less than 3 characters (displays every artist)
  341. if (input.length <= 3 && inputarte.length <= 3 && inputmuni.length <= 3){
  342. for (var i = 0; all_artesanos.length; i++){
  343. x[i].style.display = "list-item";
  344. }
  345. }
  346. else{
  347. var cases = 0;
  348. cases = getcasenum(input,inputarte,inputmuni);
  349. //take every one of them out first (dont display any)
  350. for (var i = 0; i < all_artesanos.length; i++){
  351. x[i].style.display = "none";
  352. }
  353. switch(cases){
  354. //cases == 1 when only inputmuni has been writen on
  355. case 1:
  356. filter_municipios(inputmuni);
  357. break;
  358. //cases == 2 when only inputarte has been written on
  359. case 2:
  360. filter_artesanias(inputarte);
  361. break;
  362. //cases == 3 when inputarte and inputmuni has been written on
  363. case 3:
  364. search_art_mun(inputarte,inputmuni);
  365. break;
  366. //cases == 4 when input has been writen on
  367. case 4:
  368. filter_any(input);
  369. break;
  370. //cases == 5 when input and inputmuni has been written on
  371. case 5:
  372. search_any_mun(input,inputmuni);
  373. break;
  374. //cases == 6 when input and inputart has been written on
  375. case 6:
  376. search_any_art(input,inputarte);
  377. break;
  378. //cases == 7 when input, inputart and inputmuni has been writen on
  379. case 7:
  380. search_any_art_mun(input,inputarte,inputmuni);
  381. break;
  382. }
  383. }
  384. }
  385. </script>
  386. <template id="search.html">
  387. <ons-navigator swipeable animation="slide" id="SNavigator">
  388. <ons-page id="Buscar">
  389. <p style="text-align: center; margin-top: 10px;">
  390. <ons-search-input placeholder="Busqueda en cualquiera" id = "searchbar"
  391. onkeyup = "filter()"></ons-search-input>
  392. <ons-search-input placeholder="Busqueda por artesanias" id = "searchartesania"
  393. onkeyup = "filter()"></ons-search-input>
  394. <ons-search-input placeholder = "Busqueda por municipio" id = "searchbarmunicipio"
  395. onkeyup = "filter()"></ons-search-input>
  396. </p>
  397. <ons-list id="results" src="">
  398. </ons-list>
  399. <script>
  400. for (i = 0; i < all_artesanos.length;i++){
  401. var artesano = ons.createElement(`<ons-list-item class = "artists"
  402. onclick="SNavigator.pushPage('artesano.html', { data: {title: '${all_artesanos[i].Nombre}', mun: '${all_artesanos[i].Municipio}', tel: '${all_artesanos[i]["Telefono 1"]}', email: '${all_artesanos[i]["E-mail"]}', esp: '${all_artesanos[i].Especificacion}', redes: '${all_artesanos[i]["E-Commerce 1"]}' } })" tappable>
  403. <div>${all_artesanos[i].Nombre}</div>
  404. </ons-list-item>`);
  405. // var artesano = ons.createElement(`
  406. // <ons-list-item class = "artists">
  407. // <div class="center" >${all_artesanos[i].Nombre}</div>
  408. // </ons-list-item>`
  409. // );
  410. document.getElementById('results').appendChild(artesano);
  411. }
  412. </script>
  413. </ons-page>
  414. </template>
  415. <!-- ---------------------------------------------------------------------------------------------------------------------------------------- -->
  416. <template id= "artesano.html">
  417. <ons-page id = "artesano">
  418. <ons-toolbar>
  419. <div class = "left"> <ons-back-button> Atras </ons-back-button></div>
  420. <div class = "center"></div>
  421. </ons-toolbar>
  422. <body>
  423. <ons-card id="all"></ons-card>
  424. </body>
  425. <script>
  426. ons.getScriptPage().onInit = function () {
  427. this.querySelector('ons-toolbar div.center').textContent = this.data.title;
  428. var data = '',
  429. mun = this.data.mun,
  430. tel = this.data.tel,
  431. em = this.data.email,
  432. esp = this.data.esp,
  433. redes = this.data.redes;
  434. email = em.slice(0, em.search("#"));
  435. if(esp.trim() != ""){
  436. if(esp.includes(";", 0)){
  437. esp=esp.replace(/;/g,", ");
  438. data+='Tipos de artesanias: '+esp+'<br>';
  439. }
  440. else {
  441. data+='Tipo de artesania: '+esp+'<br>';
  442. }
  443. }
  444. //console.log("Las redes son..."+this.data.redes);
  445. if(mun.trim() != ""){
  446. data+='Municipio: '+ mun +'<br>';
  447. }
  448. if(email.trim() != "" & email.toUpperCase().trim() != "NO TIENE"){
  449. data+='Correo Electr\u00f3nico: <a style="color:blue" href="mailto: '+email+'"><u>'+email+'</u></a><br>';
  450. }
  451. //Underlined <u></u>
  452. //Color blue <p style="color:blue"></p>
  453. if(tel.trim() != "" ){
  454. data+='Tel\u00e9fono: <a style="color:blue" href="tel: '+ tel +'"><u>'+ tel +'</u></a><br>';
  455. }
  456. console.log("Redes: "+redes);
  457. if(redes.includes("facebook")){
  458. console.log(redes.substring(1,redes.length-2));
  459. data+='<br><a href="'+ redes.substring(1,redes.length-2) + '"><img src="img/facebook.png" alt="Facebook"style="width:35px;height:35px;border:0;"><br>';
  460. }
  461. else if(redes.includes("instagram")){
  462. console.log(redes.substring(1,redes.length-2));
  463. data+='<br><a href="'+ redes.substring(1,redes.length-2) + '"><img src="img/instagram.png" alt="Instagram"style="width:35px;height:35px;border:0;"><br>';
  464. }
  465. else if(redes.includes("myspace")){
  466. console.log(redes.substring(1,redes.length-2));
  467. data+='<br><a href="'+ redes.substring(1,redes.length-2) + '"><img src="img/MySpace.png" alt="MySpace"style="width:35px;height:35px;border:0;"><br>';
  468. }
  469. else if((redes.includes(".org") || redes.includes(".com")) && !redes.includes("mailto")){
  470. redes = redes.substr(redes.indexOf("#")+1,redes.length);
  471. redes = redes.substr(0, redes.length-1);
  472. console.log(redes);
  473. data+='<br><a href="'+ redes + '"><img src="img/internet.jpg" style="width:35px;height:35px;border:0;"><br>';
  474. }
  475. else if(redes.includes("#") || redes.includes("mailto")){
  476. console.log("tiene un disparate");
  477. } else {
  478. console.log("no tiene nada");
  479. }
  480. document.getElementById("all").innerHTML = `${data}`;
  481. }
  482. </script>
  483. </ons-page>
  484. </template>
  485. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  486. <template id="renglones.html">
  487. <ons-navigator swipeable animation="slide" id="myNavigator">
  488. <ons-page id="renglones">
  489. <!--div class="search-bar">
  490. <p style="text-align: center; margin-top: 10px;">
  491. <ons-search-input placeholder="Search" onchange="ons.notification.alert('Searched for: ' + this.value)"
  492. style="width: 96%; margin: 6px auto 6px auto;"></ons-search-input>
  493. </p>
  494. </div-->
  495. <ons-card id="list">
  496. <script type="text/javascript" src="js/renglones.js"></script>
  497. </ons-card>
  498. <!--Javascript function to hide other open expandables-->
  499. <script>
  500. const hideAll = () => {
  501. Array.from(document.querySelector('#list').children)
  502. .forEach(item => {
  503. if (item.expanded) {
  504. item.hideExpansion();
  505. }
  506. });
  507. };
  508. </script>
  509. <style>
  510. .intro {
  511. text-align: center;
  512. padding: 20px;
  513. margin-top: 30px;
  514. }
  515. ons-card {
  516. cursor: pointer;
  517. color: #333;
  518. }
  519. .card__title,
  520. .card--material__title {
  521. font-size: 15px;
  522. }
  523. </style>
  524. </ons-page>
  525. </template>
  526. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  527. <template id="ferias.html">
  528. <ons-page id="ferias">
  529. <!--<ons-card>
  530. <div id = "caleandar" class = "calendar" style="margin-top: 20px;">
  531. <script type="text/javascript" src="calendar_files/js/caleandar.js"></script>
  532. <script type="text/javascript" src="calendar_files/js/events.js"></script>
  533. </div>
  534. </ons-card>-->
  535. <br><br><br>
  536. <button onclick="redirect()">Pasar a la pagina de eventos</button>
  537. <script>
  538. function redirect() {
  539. location.replace("https://facebook.com/icppr")
  540. }
  541. </script>
  542. </ons-page>
  543. </template>
  544. <!-- ------------------------------------------------------------------------------------------------------------------------------------------------------- -->
  545. <template id="instituto.html">
  546. <ons-page id="instituto">
  547. <ons-card>
  548. <h1>Instituto de Cultura Puertorriqueña</h1>
  549. <h3>Ven, descubre lo que nuestra riqueza cultural puertorriqueña tiene para tí.<br> Disfrútala, es tu identidad.
  550. </h3>
  551. <body>
  552. <br>
  553. El Instituto de Cultura Puertorriqueña (ICP) tiene como misión investigar, conservar, promover y divulgar la cultura puertorriqueña en su diversidad y complejidad. Con la memoria y la promesa de la cultura, los distintos niveles, sectores, edades e intereses de la comunidad crean el conjunto de modos de vida, costumbres y manifestaciones artísticas que nos identifica como país. El ICP existe para preservar y divulgar estos saberes, difundir internacionalmente nuestro talento y enriquecer el amor a lo propio.
  554. <br><br>
  555. Nuestras tradiciones no son rígidos objetos de museo, sino actividades vivas en constante renovación y reapropiación, según van también desarrollándose nuevas tradiciones. El respeto a la diversidad, a lo híbrido, a lo apropiado y a lo replanteado también son parte esencial de esta institución que busca activamente la colaboración de todos en un quehacer que debe ser siempre compartido de la mano con su ingente diversidad.
  556. <br><br>
  557. Prof. Carlos R. Ruiz Cortés<br>
  558. Director Ejecutivo<br>
  559. Instituto de Cultura Puertorriqueña<br>
  560. Directorio Artesanal Cultural PR <img src="img/gobierno.png" style="width:35px;height:35px;border:0;">
  561. <br><br>
  562. </body>
  563. Visita nuestra <a href="https://www.icp.pr.gov/">Página Web</a> o síguenos en nuestras redes sociales: <br>
  564. <a href="https://twitter.com/icppr"><img src="img/twitter.png" alt="Twitter" style="width:35px;height:35px;border:0;">
  565. </a>
  566. <a href="https://facebook.com/icppr"><img src="img/facebook.png" alt="Facebook" style="width:35px;height:35px;border:0;">
  567. </a>
  568. <a href="https://youtube.com/user/icppr"><img src="img/youtube.png" alt="Youtube" style="width:35px;height:35px;border:0;">
  569. </a>
  570. <a href="https://instagram.com/icppr"><img src="img/instagram.png" alt="Instagram" style="width:35px;height:35px;border:0;">
  571. </a>
  572. <!--</div>
  573. <!--</p>-->
  574. </ons-card>
  575. </ons-page>
  576. </template>
  577. <script src="js/load.js"></script>
  578. <script type="text/javascript" src="cordova.js"></script>
  579. <script type="text/javascript" src="js/index.js"></script>
  580. </body>
  581. </html>