Saltar para o conteúdo

Help in Spanish Wikisource

Help in Spanish Wikisource

Editado por 2 outros utilizadores.
Última edição: 08h09min de 17 de agosto de 2016

Hi! I don't know about Portuguese (I can understand it a bit) so I hope you don't mind if I speak English instead.

I'm from es.wikisource and I've been watching the implementation of Modernisation.js. To be honest, I haven't been able to enable it on Wikisource; I'm not an expert with scripts, css, js and all that stuff... Anyway, I looked at the Portuguese Wikisource and I've seen that you are using a different script which seems better for me.

So I wish you could help me to enable the script. I have created a small dictionary at es:s:Wikisource:Diccionario and in our case, we have only one ortography so we don't need to have different options. I hope you could help me... thanks a lot in advance! --B1mbo (Discussão) 21h14min de 19 de Janeiro de 2011 (UTC)

B1mbo (Discussão)21h14min de 19 de janeiro de 2011
Editado por 2 outros utilizadores.
Última edição: 08h09min de 17 de agosto de 2016

Hello!

The script used on pt.wikisource is based on that from fr.wikisource. It is relatively easy to configure it also for your project.

I've made an initial configuration of the script for use on es.wikisource, but you may want to translate the messages and replace some things as necessary...

To test the initial configuration, just replace this code by this one in your vector.js, and add this to your vector.css (and then purge the cache ;-) ). The script will add a menu on top of pages of selected namespaces (in ns_list) which transcludes s:es:Plantilla:Modernización automática, like this.

Since you are an admin there, fell free to edit my user subpage to change the texts as you want (I've left some comments on that script). ;-)

There is some basic documentation of those parameters on this page (in Portuguese), but you can ask me if needed. Helder 23h49min de 19 de Janeiro de 2011 (UTC)

Helder23h49min de 19 de janeiro de 2011
Editado por outro utilizador.
Última edição: 08h09min de 17 de agosto de 2016

It works! Perfect! Thanks a lot :D

I have one problem although. The word "y" in old ortography is "i" and is probably one of the most common words in Spanish. The problem is for example when "I" is used as a single letter (for example, as a Roman number). Here you can see the problem: [1]

Is there any way I can "isolate" the first I and not change it, but changing all the others "I" in the text?. Also, I want to change "Páj." to "Pág." but it doesn't work in the dictionary. What can I do?

Obrigado, B1mbo (Discussão) 14h47min de 20 de Janeiro de 2011 (UTC)

B1mbo (Discussão)14h47min de 20 de janeiro de 2011
Editado por outro utilizador.
Última edição: 08h09min de 17 de agosto de 2016

This feature was missing in the JavascriptScript we use for modernization, although it was already available in the LanguageConverter from MediaWiki, which is a tool I've suggested on multilingual wikisource (before knowing of the French modernization script):

I've made a change in the script which seems to make it possible to isolate parts of a page which shouldn't be converted. You can put a class in an HTML element, as in <span class="no-convert">i</span>, to avoid the conversion of the text inside that element. The name of the class can be configured using the parameter "no_conversion_class" added in this edit. It worked in this test.

About the other problem, you can try to use the rule "páj: pág", without the dot (which can't be put in the alphabet, since it would make thinks more difficult).

Just a note: It seems that the MediaWiki caches the API call used by the script, so after adding new rules to dictionary, it takes some time before they start to be used (I don't know how long does it takes, neither how to purge that cache, unfortunatelly...).

PS: I'm sorry for that typo.

Helder16h52min de 20 de janeiro de 2011
 
Editado por outro utilizador.
Última edição: 08h09min de 17 de agosto de 2016

Hi!

I've noticed you added the template to another template which is used in a lot of pages.

Do you want to enable the script in all pages of "Pagina" namespace? Any other namespaces?

If so, it will be better to set selection_mode: 'OR', and then list on "ns_list" only the namespaces where the script should be enabled for all pages. This would still allow the script to be used in specific pages of namespaces outside that list. This is (partially) documented on s:Usuário:Helder.wiki/Scripts/LanguageConverter#Configurando_o_script.

Helder17h55min de 20 de janeiro de 2011
Editado por outro utilizador.
Última edição: 08h09min de 17 de agosto de 2016

Thanks a lot!!!!

Don't worry about the typo. It made me think a bit ;) "Páj" works fine now... I guess it was just a caché problem.

I created an special template to make it easier to use "no-convert". It works fine!

And finally... I don't think we will use it in all pages of the namespace Página; or at least, we should discuss it as a community. I use it DatosCL because it is related to a project of the Library of the Chilean Congress and all pages are under old ortography rules, so I'm sure we are using it right. But anyway, thanks for the advice. And again, thanks a lot for everything!!! --B1mbo (Discussão) 23h42min de 20 de Janeiro de 2011 (UTC)

B1mbo (Discussão)23h42min de 20 de janeiro de 2011