Project:Wiktionary module modifications

From The Languages of David J. Peterson
Jump to navigation Jump to search

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. Also, check the module's edit history to see if any changes have been made, in case they have not been added here.

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 subpages

Changed links to point to Wiktionary, to prevent redlinks. Must be re-modified 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/poscatboiler/data/families

Removed unnecessary links. Must be re-modified in case of re-copy.

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/languages

Changed the language article link from "[[W:..." to a normal link to avoid redirect pages. Also removed some things that are not relevant to this wiki and its languages. Re-modify if re-copy.

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/non-lemma forms

Changed references to "morpheme forms" to "non-lemma forms". If re-copy, re-modify.

Module:Category tree/poscatboiler/data/phrases

Added "Quotes" phrasebook category. If re-copy, re-modify.

Module:Category tree/poscatboiler/data/scripts

Removed unnecessary links. If re-copy, re-modify.

Module:Category tree/poscatboiler/data/symbols

Removed references to "morphemes". If re-copy, re-modify.

Module:Category tree/poscatboiler/data/templates

Changed "declension" to the more general and appropriate "inflection". If re-copy, re-modify.

Module:Category tree/poscatboiler/data/terms by etymology

  • Changed parent of "roots" from "morphemes" to "lemmas". If re-copy, re-modify.
  • Removed "n-letter roots" categorizations to prevent roots with multiple words separated by spaces to be categorized as 2-or-more-letter roots. If re-copy, re-modify.
  • Added sections for Trigedasleng verb etymologies by root and satellite. If re-copy, re-add.

Module:Category tree/poscatboiler/data/terms by grammatical category

Added class categorization that works the same as gender categorization. If re-copy, re-modify.

Module:Category tree/poscatboiler/data/terms by lexical property

Added "terms with hiatus" label. If re-copy, re-add.

Module:Category tree/topic cat

  • Changed some code so that the language code is lowercased. Must be re-modified in case of re-copy.
  • Removed the line pointing to English language categories, since we don't have them on the wiki.

Module:Category tree/topic cat/data subpages

Changed links to point to Wiktionary, to prevent redlinks. Must be re-modified in case of re-copy.

Module:Category tree/topic cat/data/Miscellaneous

Added Homages category data. Must be re-added in case of re-copy.

Module:Category tree/topic cat/data/Sciences

Added Swadesh list category data. Must be re-added 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/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:Names

Added "dragon". Re-modify if re-copy.

Module:Rhymes

Changed the link to go to the category instead of a page. Also changed the category link creation to fit this. Re-modify if re-copy.

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.