Project:Wiktionary module modifications: Difference between revisions

From The Languages of David J. Peterson
Jump to navigation Jump to search
No edit summary
No edit summary
Line 24: Line 24:
==== [[Module:Category_tree/poscatboiler/data/entry_maintenance]] ====
==== [[Module:Category_tree/poscatboiler/data/entry_maintenance]] ====
Re-added some custom labels for quotations by project. Must be re-added again in case of re-copy.
Re-added some custom labels for quotations by project. Must be re-added again in case of re-copy.
==== [[Module:Category_tree/topic_cat]] ====
Changed some code so that the language code is lowercased. Must be re-modified in case of re-copy.


===[[Module:Headword]]===
===[[Module:Headword]]===

Revision as of 00:17, 27 September 2023

Modules from Wiktionary are usually copied whole-cloth from Wiktionary. However, some modifications have had to been made to work for this site. Review these modifications when upgrading these scripts from Wiktionary.

Modifications

Module:Affix

Module:Affix/templates

Changed so that the category displayed by the function derivsee uses a lowercase version of the entry name. Mostly relevant to Template:prefixsee. Must be remodified in case of re-copy.

Module:Auto cat

In local function add_handler(func), for topical categories, added capital letters to the find patterns.

Module:Category tree

In export.show, down where the category name is checked to be correct, added functions to lowercase both sides of the comparison as so:

if mw.ustring.lower(mw.title.getCurrentTitle().text) ~= mw.ustring.lower(current:getCategoryName()) then

Module:Category tree/poscatboiler/data/lemmas

Removed all references to "morphemes" *shudder*. These changes must be kept at all costs!

Module:Category tree/poscatboiler/data/lang-specific‎

References to languages with language-specific categories/labels added. Must be re-added in case of re-copy. Submodules of this modules should be preserved, however, in case of re-copy.

Module:Category_tree/poscatboiler/data/entry_maintenance

Re-added some custom labels for quotations by project. Must be re-added again in case of re-copy.

Module:Category_tree/topic_cat

Changed some code so that the language code is lowercased. Must be re-modified in case of re-copy.

Module:Headword

Changed all references to the "Wiktionary" namespace to "Project".

Changed non_categorizable(data) to flag Main Page as non-categorizable. This is to prevent head words that appear on the Main page (through {{WOTD}}) from adding categories to the page.

Changed code for default_head to set displayed headword to all lowercase (reverted change to format_headword(data) since it produced "redundant head" categories).

Module:Families

Module:Families/data

Modified beginning of file to include language families defined in Module:Families/data/djp in the script list. Unlike with Module:Languages/data, this page will need to be re-modified after a recopy from Wiktionary since the page itself had to be changed to support this.

Module:Families/data/djp

Added this page as a repository for language families in this wiki, so if other Module:Families/data subpages are updated, no config from this language family is lost. Note, as mentioned about, the updater must ensure the changes to Module:Families/data are maintained or re-added for this file to be read.

Module:Form of

Module:Form of

Changed the format of the definition line to match other templates on this wiki, i.e. italic text followed by the word in bold, instead of regular text followed by the word in italics. Module must be remodified in case of an update.

Module:Form of/data‎

Removed the shortcut "positive" from "positive degree" (adjective sense), to be able to use "positive" as a label for the verb sense of "positive" which is used on this wiki. Module must be remodified in case of an update.

Module:Form of/data2‎

Added extra labels matching terms used on this wiki. Module must be remodified in case of an update.

Module:Interlinear

Module:Interlinear/data‎

Note: the module is from Wikipedia, not Wiktionary. Added a few shortcuts to terms/labels used for languages on this wiki. Will need to be re-added in case of re-copy.

Module:IPA

Module:IPA/data

All of the Wiktionary data has been replaced by data for this wiki. Any changes to the functions and formats from Wiktionary will need to be integrated into the page.

Module:IPA/data/symbols

There are small changes to this page that need to be maintained. Make a compare of the current version and new version before updating.

Module:Languages

Updated function export.getDataModuleName(code) to support four-letter language codes and specifically look for them in Module:Languages/data/djp. This is to separate the DJP language codes from the standard codes.

Module:Languages/canonical names

Adding languages to this wiki requires this file to be changed. If it needs to be refreshed from Wiktionary, ensure that the changes for this wiki are retained or re-added.

Module:Languages/code to canonical name

Adding languages to this wiki requires this file to be changed. If it needs to be refreshed from Wiktionary, ensure that the changes for this wiki are retained or re-added.

Module:Languages/data/djp

Added this page as a repository for languages in this wiki, so if other Module:Languages/data subpages are updated, no config from this language is lost.

Module:Languages/data/djp/extra

Added to support Module:Languages/data/djp

Module:Links

Re-added some code to make self-links work as intended in the templates that use this module. Has to do with that entry titles are always upper-case on this wiki, while links may be either lower-case or upper-case. Must be re-added again in case of update.

Module:Links/templates

The original Wiktionary module was copied over in 2019 and has not been updated since then. Unclear if it needs to be re-modified in case of another update, but probably not, since there are no apparent changes to the 2019 original according to the page history.

Module:Scripts

Module:Scripts/data

Modified beginning of file to include scripts defined in Module:Scripts/data/djp in the script list. Unlike with Module:Languages/data, this page will need to be re-modified after a recopy from Wiktionary since the page itself had to be changed to support this.

Module:Scripts/data/djp

Added this page as a repository for scripts in this wiki, so if other Module:Scripts/data subpages are updated, no config from this script is lost. Note, as mentioned about, the updater must ensure the changes to Module:Scripts/data are maintained or re-added for this file to be read.

Module:Scripts/by name

Adding scripts to this wiki requires this file to be changed. If it needs to be refreshed from Wiktionary, ensure that the changes for this wiki are retained or re-added.

Module:Scripts/code to canonical name‎

Adding scripts to this wiki requires this file to be changed. If it needs to be refreshed from Wiktionary, ensure that the changes for this wiki are retained or re-added.