Línea 6: |
Línea 6: |
| | | |
| if (mw.cookie.get('buscar_tour')){ | | if (mw.cookie.get('buscar_tour')){ |
− | //return; | + | return; |
| } | | } |
| | | |
Línea 20: |
Línea 20: |
| tour.firstStep( { | | tour.firstStep( { |
| name: 'buscar', | | name: 'buscar', |
− | title: '¿Buscas algo?', | + | title: '¿Buscas algo? <br> ¡Es muy fácil encontrar material <br> en el CNB en línea!', |
− | description: '¡Es muy fácil encontrar material en el CNB en línea!',
| + | description: 'Puedes buscar contenido de dos maneras: con el buscador wiki o con el buscador de Google ubicado al final del menú lateral.', |
| position: 'topLeft', | | position: 'topLeft', |
| attachTo: '#p-search', | | attachTo: '#p-search', |
Línea 32: |
Línea 32: |
| tour.step( { | | tour.step( { |
| name: 'buscar1', | | name: 'buscar1', |
− | title: 'Prueba el buscador wiki.', | + | title: 'Prueba el buscador wiki', |
− | description: 'Escribe <i>Comunicación</i> en la ventana de búsqueda o selecciona el botón «Enséñame cómo». <br>Cuida bien la ortografía (en especial las tildes) porque la búsqueda wiki es exacta.', | + | description: 'Escribe algo en la casilla de búsqueda y presiona la tecla <i>Enter</i>. Cuida bien la ortografía (en especial las tildes) porque la búsqueda wiki es exacta.', |
− | attachTo: '#Inicial-y-Preprimaria-main',
| |
| position: 'left', | | position: 'left', |
| attachTo: '#p-search', | | attachTo: '#p-search', |
Línea 40: |
Línea 39: |
| closeOnClickOutside: false, | | closeOnClickOutside: false, |
| allowAutomaticOkay: false, | | allowAutomaticOkay: false, |
− | buttons: [ {
| |
− | name: 'Enséñame cómo',
| |
− | onclick: function () {
| |
− | mw.libs.guiders.next();
| |
− | $('#searchInput').focus();
| |
− | $('#searchInput').val('Comunicación');
| |
− | $('#searchInput').focus();
| |
− | var press = jQuery.Event("keypress");
| |
− | press.which = 40;
| |
− | $("#searchInput").trigger(press);
| |
− | $('#searchInput').focus();
| |
− | }
| |
− | } ],
| |
| } ) | | } ) |
| .next( 'buscar2' ) | | .next( 'buscar2' ) |
Línea 60: |
Línea 46: |
| tour.step( { | | tour.step( { |
| name: 'buscar2', | | name: 'buscar2', |
− | title: 'El buscador wiki te ayuda a encontrar títulos de páginas...', | + | title: 'El buscador wiki encuentra páginas...', |
− | description: 'El buscador te sugerirá nombres de páginas que incluyen tu búsqueda en el título', | + | description: 'Te ayudará a encontrar páginas que incluyan las palabras que buscas en sus títulos.', |
| attachTo: '#p-search', | | attachTo: '#p-search', |
| position: 'left', | | position: 'left', |
Línea 67: |
Línea 53: |
| overlay: false, | | overlay: false, |
| buttons: [ { | | buttons: [ { |
− | name: 'Muéstrame la lista de nuevo', | + | name: 'Mostrar ejemplo', |
| onclick: function () { | | onclick: function () { |
| + | mw.libs.guiders.next(); |
| $('#searchInput').focus(); | | $('#searchInput').focus(); |
| $('#searchInput').val('Comunicación'); | | $('#searchInput').val('Comunicación'); |
Línea 74: |
Línea 61: |
| var press = jQuery.Event("keypress"); | | var press = jQuery.Event("keypress"); |
| press.which = 40; | | press.which = 40; |
− | $("#searchInput").trigger(press);
| |
| $('#searchInput').focus(); | | $('#searchInput').focus(); |
| } | | } |
Línea 84: |
Línea 70: |
| tour.step( { | | tour.step( { |
| name: 'buscar3', | | name: 'buscar3', |
− | title: '... y también a encontrar contenidos.', | + | title: '... y también encuentra contenidos.', |
− | description: 'Selecciona el término abajo de "que contiene..." para ver páginas con el término en su contenido ', | + | description: 'Selecciona lo que aparece debajo de "que contiene..." para ver páginas con ese texto.', |
| attachTo: '#p-search', | | attachTo: '#p-search', |
| position: 'bottomLeft', | | position: 'bottomLeft', |
Línea 91: |
Línea 77: |
| overlay: false, | | overlay: false, |
| onShow: function () { | | onShow: function () { |
− | $('#searchInput').focus();
| + | var press = jQuery.Event("keypress"); |
− | $('#searchInput').val('Comunicación ');
| + | press.which = 36; |
− | $('#searchInput').trigger({type: 'keypress', which: 32, keyCode: 32});
| + | $("#searchInput").trigger(press); |
− | $('#searchInput').focus();
| + | $('#searchInput').val('Comunicación'); |
− | },
| + | var press = jQuery.Event("keypress"); |
| + | press.which = 36; |
| + | $("#searchInput").trigger(press); |
| + | }, |
| + | |
| + | |
| | | |
− | buttons: [
| + | } ) |
− | { name: 'show list',
| + | .next( 'buscar4' ) |
− | onclick: function () {
| + | .back( 'buscar2' ); |
− | $('#searchInput').focus();
| |
− | $('#searchInput').val('Comunicación');
| |
− | $('#searchInput').focus();
| |
− | var press = jQuery.Event("keypress");
| |
− | press.which = 40;
| |
− | $("#searchInput").trigger(press);
| |
− | $('#searchInput').focus();
| |
− | }
| |
− | },{
| |
− | name: 'Enséñame cómo',
| |
− | onclick: function () {
| |
− | $('#searchInput').focus();
| |
− | mw.libs.guiders.next();
| |
− | window.location.href = "http://cnbguatemala.org/index.php?search=Comunicación&title=Special:Search&fulltext=1";
| |
− | }
| |
− | } ],
| |
| | | |
− | } ) | + | tour.step( { |
− | .next( 'buscar4' )
| + | name: 'buscar4', |
− | .back( 'buscar2' );
| + | title: 'Si elegiste el contenido, entonces aquí verás la lista de páginas que tienen en su título lo que buscaste...', |
| + | description: '', |
| + | attachTo: 'span[id^="Resultados_por_t"]', |
| + | position: 'topLeft', |
| + | closeOnClickOutside: false, |
| + | overlay: false |
| + | } ) |
| + | .next( 'buscar5' ) |
| + | .back( 'buscar3' ); |
| | | |
− | tour.step( {
| + | tour.step( { |
− | name: 'buscar4',
| + | name: 'buscar5', |
− | title: 'Aquí verás la lista de páginas que contienen en su título el término que buscaste...',
| + | title: '... y aquí está la lista de páginas que lo incluyen en el texto.', |
− | description: '',
| + | description: '', |
− | attachTo: 'span[id^="Resultados_por_t"]',
| + | attachTo: 'span[id^="Resultados_por_texto_de"]', |
− | position: 'topLeft',
| + | position: 'topLeft', |
− | closeOnClickOutside: false,
| + | closeOnClickOutside: false, |
− | overlay: false
| + | overlay: false |
− | } )
| + | } ) |
− | .next( 'buscar5' )
| + | .next( 'buscar6' ) |
− | .back( 'buscar3' );
| + | .back( 'buscar4' ); |
| | | |
− | tour.step( {
| |
− | name: 'buscar5',
| |
− | title: 'Aquí verás la lista de páginas que contienen en su texto el término que buscaste...',
| |
− | description: '',
| |
− | attachTo: 'span[id^="Resultados_por_texto_de"]',
| |
− | position: 'topLeft',
| |
− | closeOnClickOutside: false,
| |
− | overlay: false
| |
− | } )
| |
− | .next( 'buscar6' )
| |
− | .back( 'buscar4' );
| |
| | | |
− | tour.step( {
| + | tour.step( { |
− | name: 'buscar6',
| + | name: 'buscar6', |
− | title: '... y aquí puedes crear una página nueva usando el término como título.',
| + | title: 'También puedes hacer una búsqueda más específica con los operadores booleanos "+" y "-"', |
− | description: '',
| + | description: '¡Pruébalo! Escribe <i>criterio +evaluativo</i> o <i>criterio -evaluativo</i>, presiona la tecla <i>Enter</i> y observa los resultados.', |
− | attachTo: '.mw-search-createlink a',
| + | attachTo: '#p-search', |
− | position: 'topLeft',
| + | position: 'bottomLeft', |
− | closeOnClickOutside: false,
| + | closeOnClickOutside: false, |
− | overlay: false
| + | allowAutomaticOkay: false, |
− | } ) | + | overlay: false, |
− | .next( 'buscar7' )
| + | buttons: [ { |
− | .back( 'buscar5' ); | + | name: 'Mostrar ejemplo', |
| + | onclick: function () { |
| + | $('#searchInput').focus(); |
| + | $('#searchInput').val('criterio -evaluativo'); |
| + | $('#searchInput').focus(); |
| + | var press = jQuery.Event("keypress"); |
| + | press.which = 40; |
| + | $("#searchInput").trigger(press); |
| + | $('#searchInput').focus(); |
| + | } |
| + | } ], |
| + | } ) |
| + | .back( 'buscar5' ) |
| + | .next( 'buscar7' ); |
| | | |
| | | |
− | tour.step( {
| + | tour.step( { |
− | name: 'buscar7',
| + | name: 'buscar7', |
− | title: 'Usa las comillas para precisar más tu búsqueda.',
| + | title: 'También puedes usar el buscador de Google', |
− | description: '¡Pruébalo! Escribe <i>"criterio evaluativo"</i> en la búsqueda wiki.',
| + | description: 'Este buscador es más flexible y poderoso. Escribe algo en la casilla y presiona la tecla <i>Enter</i> para probarlo.', |
− | attachTo: '#p-search',
| + | attachTo: '#cse-search-box', |
− | position: 'right',
| + | position: 'right', |
− | closeOnClickOutside: false,
| + | closeOnClickOutside: false, |
− | overlay: false,
| + | overlay: false, |
− | buttons: [ {
| + | } ) |
− | name: 'Enséñame cómo',
| + | .back( 'buscar6' ) |
− | onclick: function () {
| + | .next( 'buscar8' ); |
− | $('#searchInput').focus();
| |
− | $('#searchInput').val('"criterio evaluativo"');
| |
− | $('#searchInput').focus();
| |
− | $('form#searchform').submit();
| |
− | mw.libs.guiders.next();
| |
− | }
| |
− | } ],
| |
− | } ) | |
− | .next( 'buscar9' )
| |
− | .back( 'buscar6' );
| |
| | | |
− |
| |
− | tour.step( {
| |
− | name: 'buscar9',
| |
− | title: 'También puedes precisar tu búsqueda con los operadores booleanos "+" y "-".',
| |
− | description: '¡Pruébalo! Escribe <i>criterio -evaluativo</i> en la búsqueda wiki',
| |
− | attachTo: '#p-search',
| |
− | position: 'left',
| |
− | closeOnClickOutside: false,
| |
− | overlay: false,
| |
− | buttons: [ {
| |
− | name: 'Enséñame cómo',
| |
− | onclick: function () {
| |
− | $('#cse-search-box input[type="text"]').focus();
| |
− | $('#cse-search-box input[type="text"]').val('criterio');
| |
− | $('#cse-search-box input[type="text"]').focus();
| |
− | $('form#cse-search-box').submit();
| |
− | mw.libs.guiders.next();
| |
− | }
| |
− | } ],
| |
− | } )
| |
− | .back( 'buscar7' )
| |
− | .next( 'buscar11' )
| |
− |
| |
− |
| |
− |
| |
− | tour.step( {
| |
− | name: 'buscar11',
| |
− | title: '2) También puedes usar el buscador de Google',
| |
− | description: 'El buscador Google es más flexible y poderoso. Encontrarás resultados aunque no utilices tildes, pero no podrás crear páginas nuevas.',
| |
− | attachTo: '#cse-search-box',
| |
− | position: 'right',
| |
− | closeOnClickOutside: false,
| |
− | overlay: false,
| |
− | buttons: [ {
| |
− | name: 'Make a search',
| |
− | onclick: function () {
| |
− | $('#cse-search-box input[type="text"]').focus();
| |
− | $('#cse-search-box input[type="text"]').val('criterio');
| |
− | $('#cse-search-box input[type="text"]').focus();
| |
| | | |
− | }
| + | tour.step( { |
− | } ],
| + | name: 'buscar8', |
− | } )
| + | title: '¡Usa los buscadores y no te pierdas nada en el sitio!', |
− | .back( 'buscar9' )
| + | description: '', |
− | .next( 'buscar12' )
| + | position: 'center', |
− | tour.step( {
| + | closeOnClickOutside: false, |
− | name: 'buscar12',
| + | overlay: true, |
− | title: '',
| + | } ) |
− | description: '¡Usa los buscadores y no te pierdas nada en el sitio!',
| + | .back( 'buscar7' ); |
− | position: 'center',
| |
− | closeOnClickOutside: false,
| |
− | overlay: true,
| |
− | } )
| |
− | .back( 'buscar11' );
| |
| | | |
| | | |
| } ( window, document, jQuery, mediaWiki, mediaWiki.guidedTour ) ); | | } ( window, document, jQuery, mediaWiki, mediaWiki.guidedTour ) ); |