Module:Citation/CS1/Suggestions:修订间差异
外观
删除的内容 添加的内容
enwiki>Trappist the monk sync from sandbox; |
zhwiki>Xiplus-abot 小 已更改“Module:Citation/CS1/Suggestions”的保护设置:高風險模板:105157引用<!-- 機器人3 -->([编辑=仅允许管理员](无限期)[移动=仅允许管理员](无限期)) |
||
| 第1行: | 第1行: | ||
-- |
--Please insert new suggestions in alphabetical order |
||
-- |
--The form is ['incorrect'] = 'correct', |
||
suggestions = { |
suggestions = { |
||
-- ['acccessdate'] = 'access-date', |
|||
['ASIN-TLD'] = 'asin-tld', -- old parameter name |
|||
-- ['accesdate'] = 'access-date', |
|||
-- ['access date'] = 'access-date', |
|||
-- ['accessate'] = 'access-date', |
|||
-- ['accessdare'] = 'access-date', |
|||
-- ['accessdatte'] = 'access-date', |
|||
-- ['accessddate'] = 'access-date', |
|||
-- ['accessdte'] = 'access-date', |
|||
['ad'] = 'first', -- Turkish |
|||
-- ['accessed'] = 'access-date', |
|||
-- ['accessedate'] = 'access-date', |
|||
-- ['accesssdate'] = 'access-date', |
|||
-- ['accssdate'] = 'access-date', |
|||
-- ['acessdate'] = 'access-date', |
|||
['address'] = 'location', |
['address'] = 'location', |
||
[' |
['année'] = 'year', -- French |
||
[' |
['añoacceso'] = 'access-date', -- Spanish, Italian |
||
[' |
['apellido'] = 'last', -- Spanish, Italian |
||
[' |
['archive date'] = 'archive-date', |
||
[' |
['archive url'] = 'archive-url', -- Spanish, Italian |
||
[' |
['artist'] = 'others', |
||
[' |
['auteur'] = 'author', -- French |
||
['auther'] = 'author', |
|||
['archiv-datum'] = 'archive-date', -- German |
|||
[' |
['authorformat'] = 'name-list-format', -- remove after 2016-01-01 |
||
['author-format'] = 'name-list-format', -- remove after 2016-01-01 |
|||
['archive date'] = 'archive-date', -- misspelling |
|||
[' |
['author link'] = 'author-link', |
||
-- ['autor'] = 'author', -- Spanish, Italian |
|||
['archive-link'] = 'archive-url', -- old parameter name |
|||
-- ['autor2'] = 'author2', -- Spanish, Italian |
|||
['archiv-url'] = 'archive-url', -- German |
|||
['autthor'] = 'author', |
|||
['arkivdatum'] = 'archive-date', -- Swedish, Norwegian |
|||
['began'] = 'date', -- remove after 2016-01-01 |
|||
['artist'] = 'others', |
|||
['arşiv-tarihi'] = 'archive-date', -- Turkish |
|||
['arşiv-url'] = 'archive-url', -- Turkish |
|||
['arşivtarihi'] = 'archive-date', -- Turkish |
|||
['arşivurl'] = 'archive-url', -- Turkish |
|||
['auflage'] = 'edition', -- German |
|||
['auteur'] = 'author', -- French |
|||
['auther'] = 'author', -- misspelling |
|||
['author link'] = 'author-link', -- Polish |
|||
['authorfirst'] = 'author-first', -- old parameter name |
|||
['authorgiven'] = 'author-given', -- old parameter name |
|||
['authorlast'] = 'author-last', -- old parameter name |
|||
['authormask'] = 'author-mask', -- old parameter name |
|||
['authorsurname'] = 'author-surname', -- old parameter name |
|||
['autor'] = 'author', -- Spanish, German (singular and plural) |
|||
['autore'] = 'author', -- Italian |
|||
['autthor'] = 'author', -- misspelling |
|||
['ay'] = 'month', -- Turkish |
|||
['año'] = 'date', -- Spanish |
|||
['año-original'] = 'orig-date', -- Spanish |
|||
['añoacceso'] = 'access-date', -- Spanish |
|||
['añooriginal'] = 'orig-date', -- Spanish |
|||
['band'] = 'volume', -- German |
|||
['bandreihe'] = 'volume', -- German |
|||
['baskı'] = 'edition', -- Turkish |
|||
['başlık'] = 'title', -- Turkish |
|||
['began'] = 'date', -- old parameter name (cite serial only); or orig-date= |
|||
['booktitle'] = 'book-title', -- old parameter name |
|||
['ch'] = 'language', -- German (as 'language=de-CH') |
|||
['chapter_title'] = 'chapter', |
['chapter_title'] = 'chapter', |
||
[' |
['cita'] = 'quote', -- Spanish, Italian |
||
[' |
['coautores'] = 'coauthors', -- Spanish, Italian |
||
[' |
['consulté le'] = 'access-date', -- French |
||
[' |
['deadlink'] = 'dead-url', |
||
['citazione'] = 'quote', -- Italian |
|||
['città'] = 'location', -- Italian |
|||
['city'] = 'location', -- old parameter name (cite serial only) |
|||
['coauthor'] = 'author', |
|||
['coauthors'] = 'author', |
|||
['coautores'] = 'author', -- Spanish |
|||
['coautori'] = 'author', -- Italian |
|||
['cognome'] = 'last', -- Italian |
|||
['conferenceurl'] = 'conference-url', -- old parameter name |
|||
['consulté le'] = 'access-date', -- French |
|||
['contributionurl'] = 'contribution-url', -- old parameter name |
|||
['curatore'] = 'publisher', -- Italian |
|||
['czasopismo'] = 'journal', -- Polish |
|||
['data dostępu'] = 'access-date', -- Polish |
|||
['data'] = 'date', -- Polish, Italian |
|||
['dataaccesso'] = 'access-date', -- Italian |
|||
['dataarchivio'] = 'archive-date', -- Italian |
|||
['datum'] = 'date', -- German, Swedish |
|||
['dead-url'] = 'url-status', -- old parameter name |
|||
['deadlink'] = 'url-status', -- old parameter name |
|||
['deadurl'] = 'url-status', -- old parameter name |
|||
['dergi'] = 'work', -- Turkish |
|||
['dil'] = 'language', -- Turkish |
|||
['displayauthors'] = 'display-authors', -- old parameter name |
|||
['displayeditors'] = 'display-editors', -- old parameter name |
|||
['distributor'] = 'publisher', |
['distributor'] = 'publisher', |
||
['éditeur'] = 'editor', -- French |
|||
['dnb'] = 'id', -- German (as 'id={{DNB-IDN|...}}') |
|||
['editon'] = 'edition', |
|||
['doi-broken'] = 'doi-broken-date', -- old parameter alias |
|||
['editoin'] = 'edition', |
|||
['doi-inactive'] = 'doi-broken-date', -- invalid name found in mainspace |
|||
[' |
['editorformat'] = 'name-list-format', -- remove after 2016-01-01 |
||
[' |
['editor-format'] = 'name-list-format', -- remove after 2016-01-01 |
||
[' |
['editorgiven'] = 'editor-given', -- remove after 2016-01-01 |
||
['editorial'] = 'publisher', |
|||
['doibroken'] = 'doi-broken-date', -- invalid name found in mainspace |
|||
[' |
['editorsurname'] = 'editor-surname', -- remove after 2016-01-01 |
||
[' |
['en ligne le'] = 'archive-date', -- French |
||
['ended'] = 'date', -- remove after 2016-01-01 |
|||
['enlaceautor'] = 'author-link', -- Spanish, Italian |
|||
-- ['editora'] = 'publisher', -- can be either editor or publisher |
|||
['fecha'] = 'date', -- Spanish, Italian |
|||
-- ['editore'] = 'agency', -- can be either publisher or agency |
|||
['fechaacceso'] = 'access-date', -- Spanish, Italian |
|||
-- ['editori'] = 'editor', -- can be either editor or publisher |
|||
['fechaarchivo'] = 'archive-date', -- Spanish, Italian |
|||
-- ['editorial'] = 'publisher', -- can be either publisher or work |
|||
['editoin'] = 'edition', -- misspelling |
|||
['editon'] = 'edition', -- misspelling |
|||
['editorfirst'] = 'editor-first', -- old parameter name |
|||
['editorgiven'] = 'editor-given', -- old parameter name |
|||
['editorlast'] = 'editor-last', -- old parameter name |
|||
['editorlink'] = 'editor-link', -- old parameter name |
|||
['editormask'] = 'editor-mask', -- old parameter name |
|||
['editors'] = 'editor', -- old parameter name (can be emulated using multiple singular |editor= params) |
|||
['editorsurname'] = 'editor-surname', -- old parameter name |
|||
['edizione'] = 'edition', -- Italian |
|||
['embargo'] = 'pmc-embargo-date', -- old parameter name |
|||
['ended'] = 'date', -- old parameter name (cite serial only) |
|||
['en ligne le'] = 'archive-date', -- French |
|||
['encyclopædia'] = 'encyclopedia', |
|||
['enlaceautor'] = 'author-link', -- Spanish |
|||
['enlaceroto'] = 'url-status', -- Spanish |
|||
['episodelink'] = 'episode-link', -- old parameter name |
|||
['erişimtarihi'] = 'access-date', -- Turkish |
|||
['eser'] = 'work', -- Turkish |
|||
['family'] = 'surname', -- misguess |
|||
['fecha'] = 'date', -- Spanish |
|||
['fechaacceso'] = 'access-date', -- Spanish |
|||
['fechaarchivo'] = 'archive-date', -- Spanish |
|||
['filetype'] = 'format', |
['filetype'] = 'format', |
||
[' |
['first 1'] = 'first1', |
||
['foramt'] = 'format', |
|||
['fore-name'] = 'given', -- misguess/misspelling |
|||
[' |
['formato'] = 'format', -- Spanish, Italian |
||
['frist'] = 'first', |
|||
['författare'] = 'author', -- Swedish, Norwegian |
|||
['idioma'] = 'language', -- Spanish, Italian |
|||
[' |
['isnb'] = 'isbn', |
||
[' |
['lang'] = 'language', |
||
[' |
['langauge'] = 'language', |
||
[' |
['langue'] = 'language', -- French |
||
['last 1'] = 'last1', |
|||
['hämtdatum'] = 'access-date', -- Swedish |
|||
['lieu'] = 'location', -- French |
|||
['herausgeber'] = 'editor', -- German (singular and plural) |
|||
[' |
['lire en ligne'] = 'url', -- French |
||
[' |
['loaction'] = 'location', |
||
[' |
['locatoin'] = 'location', |
||
['mois'] = 'month', -- French |
|||
['ignore-isbn-error'] = 'isbn', -- old parameter (can be fully emulated using ((syntax))) |
|||
['month'] = 'date', -- remove after 2016-01-01 |
|||
['ignoreisbnerror'] = 'isbn', -- old parameter alias (suggest |isbn as |ignore-isbn-error is deprecated), not a direct replacement, but can be fully emulated using ((syntax)) |
|||
-- ['name'] = 'author', -- 'name' is often erroneously used for 'title' and 'work' as well, so no suggestion is better than a wrong suggestion |
|||
['imię'] = 'first', -- Polish |
|||
['nespaper'] = 'newspaper', |
|||
['in-set'] = 'inset', -- misspelling |
|||
['newpaper'] = 'newspaper', |
|||
['interviewerlink'] = 'interviewer-link', -- old parameter alias |
|||
['interviewermask'] = 'interviewer-mask', -- old parameter alias |
|||
['isbndefekt'] = 'isbn', -- German (suggest |isbn as |ignore-isbn-error is deprecated), not a direct replacement, but can be fully emulated using ((syntax)) |
|||
['isbnformalfalsch'] = 'isbn', -- German (suggest |isbn as |ignore-isbn-error is deprecated), not a direct replacement, but can be fully emulated using ((syntax)) |
|||
['isbnistformalfalsch'] = 'isbn', -- German (suggest |isbn as |ignore-isbn-error is deprecated), not a direct replacement, but can be fully emulated using ((syntax)) |
|||
['isnb'] = 'isbn', -- misspelling |
|||
['issnformalfalsch'] = 'issn', -- German (can be fully emulated using ((syntax))) |
|||
['jahr'] = 'date', -- German |
|||
['jahrea'] = 'orig-date', -- German (not a direct replacement, but can be emulated) |
|||
['kapitel'] = 'chapter', -- German |
|||
['langauge'] = 'language', -- misspelling |
|||
['langue'] = 'language', -- French |
|||
['last-author-amp'] = 'name-list-style', -- old parameter name (as |name-list-style=amp) |
|||
['lastauthoramp'] = 'name-list-style', -- old parameter name (as |name-list-style=amp) |
|||
['lieu'] = 'location', -- French |
|||
['lingua'] = 'language', -- Italian |
|||
['lire en ligne'] = 'url', -- French |
|||
['lizenznummer'] = 'id', -- German (as 'id=License No. ...') |
|||
['loaction'] = 'location', -- misspelling |
|||
['local'] = 'location', -- Brazilian Portuguese |
|||
['locatoin'] = 'location', -- misspelling |
|||
['lugar'] = 'location', -- Spanish |
|||
['mailinglist'] = 'mailing-list', -- old parameter name |
|||
['mapurl'] = 'map-url', -- old parameter name |
|||
['mes'] = 'date', -- Spanish (not a direct replacement) |
|||
['mese'] = 'date', -- Italian (not a direct replacement) |
|||
['miejsce'] = 'location', -- Polish |
|||
['miesiąc'] = 'date', -- Polish |
|||
['mois'] = 'date', -- French |
|||
['monat'] = 'date', -- German |
|||
-- ['name'] = 'author', -- 'name' is often erroneously used for 'title' and 'work' as well, so no suggestion is better than a wrong suggestion |
|||
['name-list-format'] = 'name-list-style', -- old parameter name (as |name-list-style=amp) |
|||
['nazwisko'] = 'last', -- Polish |
|||
['nespaper'] = 'newspaper', -- misspelling |
|||
['net-work'] = 'network', -- misspelling |
|||
['newpaper'] = 'newspaper', -- misspelling |
|||
['news'] = 'newspaper', |
['news'] = 'newspaper', |
||
[' |
['nom'] = 'last', -- French |
||
[' |
['nom1'] = 'last1', -- French |
||
[' |
['nombre'] = 'first', -- Spanish, Italian |
||
[' |
['obra'] = 'work', -- Spanish, Italian |
||
[' |
['origdate'] = 'orig-year', |
||
['nombre'] = 'first', -- Spanish |
|||
['nome'] = 'first', -- Italian |
|||
['nopp'] = 'no-pp', -- old parameter name |
|||
['notracking'] = 'no-tracking', -- old parameter |
|||
['numero'] = 'number', -- Italian, Spanish |
|||
['nummer'] = 'number', -- German |
|||
['nummerreihe'] = 'number', -- German |
|||
['obra'] = 'work', -- Spanish |
|||
['odpowiedzialność'] = 'agency', -- Polish |
|||
['offline'] = 'url-status', -- German (as 'url-status=dead') |
|||
['online'] = 'url', -- German (not a direct replacement, but can be emulated) |
|||
['opera'] = 'work', -- Italian |
|||
['opublikowany'] = 'agency', -- Polish |
|||
['origdate'] = 'orig-date', -- misspelling |
|||
['originaljahr'] = 'orig-date', -- German |
|||
['originalort'] = 'publication-place', -- German |
|||
['originalsprache'] = 'language', -- German |
|||
['originaltitel'] = 'title', -- German (if 'originaltitel' is specified, any possible contents of 'title' should be put in 'trans-title') |
|||
['ort'] = 'publication-place', -- German |
|||
['ortea'] = 'publication-place', -- German (not a direct replacement, but can be emulated) |
|||
['other'] = 'others', |
['other'] = 'others', |
||
[' |
['pagees'] = 'pages', |
||
[' |
['página'] = 'page', -- Spanish, Italian |
||
[' |
['páginas'] = 'pages', -- Spanish, Italian |
||
[' |
['passage'] = 'pages', -- French |
||
[' |
['périodique'] = 'publisher', -- French |
||
[' |
['plublisher'] = 'publisher', |
||
['passage'] = 'pages', -- French |
|||
['periodico'] = 'magazine', -- Spanish |
|||
['plublisher'] = 'publisher', -- misspelling |
|||
['pmcid'] = 'pmc', |
['pmcid'] = 'pmc', |
||
[' |
['prénom'] = 'first', -- French |
||
[' |
['prénom1'] = 'first1', -- French |
||
['primero'] = 'first', -- Spanish |
|||
['prénom'] = 'first', -- French |
|||
['prénom1'] = 'first1', -- French |
|||
['ps'] = 'postscript', |
['ps'] = 'postscript', |
||
['pub'] = 'publisher', |
['pub'] = 'publisher', |
||
-- ['pubisher'] = 'publisher', |
|||
-- ['pubblicazione'] = 'magazine', -- could be any kind of work |
|||
-- ['publiser'] = 'publisher', |
|||
-- ['publicación'] = 'journal', -- could be any kind of work |
|||
-- ['publishers'] = 'publisher', |
|||
['publicationdate'] = 'publication-date', -- old parameter name |
|||
-- ['publsher'] = 'publisher', |
|||
-- ['publsiher'] = 'publisher', |
|||
['publicationplace'] = 'publication-place', -- old parameter name |
|||
['pulbication-place'] = 'publication-place', |
['pulbication-place'] = 'publication-place', |
||
-- ['pulbisher'] = 'publisher', |
|||
['página'] = 'page', -- Spanish |
|||
-- ['pulisher'] = 'publisher', |
|||
['páginas'] = 'pages', -- Spanish |
|||
[' |
['retrieved'] = 'access-date', |
||
[' |
['separator'] = 'mode', -- remove after 2016-01-01 |
||
[' |
['série'] = 'work', -- French |
||
['retrieved'] = 'access-date', -- old parameter name |
|||
['richiestasottoscrizione'] = 'url-access', -- Italian (as |url-access=subscription) |
|||
['rivista'] = 'magazine', -- Italian |
|||
['rok'] = 'date', -- Polish |
|||
['rubrik'] = 'title', -- Swedish |
|||
['sammelwerk'] = 'work', -- German |
|||
['sayfa'] = 'page', -- Turkish |
|||
['sayfalar'] = 'pages', -- Turkish |
|||
['sayı'] = 'issue', -- Turkish |
|||
['script-post'] = 'postscript', -- misspelling |
|||
['script-trans'] = 'transcript', -- misspelling |
|||
['season'] = 'date', -- old parameter name (cite serial only) |
|||
['sectionurl'] = 'section-url', -- old parameter name |
|||
['seiten'] = 'pages', -- German |
|||
['seria'] = 'series', -- Spanish, Polish |
|||
['serie'] = 'series', -- Italian |
|||
['série'] = 'series', -- French |
|||
['serieslink'] = 'series-link', -- old parameter name |
|||
['seriesno'] = 'series-number', -- old parameter name |
|||
['service'] = 'agency', |
['service'] = 'agency', |
||
[' |
['suscripción'] = 'subscription', -- Spanish, Italian |
||
[' |
['tile'] = 'title', |
||
[' |
['tite'] = 'title', |
||
['titolo'] = 'title', -- Spanish, Italian |
|||
['spalten'] = 'at', -- German (not a direct replacement, but can be emulated) |
|||
[' |
['titre'] = 'title', -- French |
||
['título'] = 'title', -- Spanish, Italian |
|||
['språk'] = 'language', -- Swedish, Norwegian |
|||
['stron'] = 'page', -- Polish |
|||
['strony'] = 'pages', -- Polish |
|||
['subjectlink'] = 'subject-link', -- old parameter name |
|||
['subscription'] = 'url-access', -- old parameter name (emulated as |url-access=subscription) |
|||
['sur-name'] = 'surname', -- misspelling |
|||
['suscripción'] = 'url-access', -- Spanish, Polish (as |url-access=subscription) |
|||
['tag'] = 'date', -- German |
|||
['tarih'] = 'date', -- Turkish |
|||
['template doc demo'] = 'no-tracking', -- old parameter alias |
|||
['tidning'] = 'work', -- Swedish |
|||
['tile'] = 'title', -- misspelling |
|||
['timecaption'] = 'time-caption', -- old parameter name |
|||
['titlelink'] = 'title-link', -- old parameter name |
|||
['tipo'] = 'type', -- Italian |
|||
['tite'] = 'title', -- misspelling |
|||
['titel'] = 'title', -- German |
|||
['titel-p'] = 'title', -- German ('postscript=none' should be added as well) |
|||
['titelerg'] = 'contribution', -- German (not a direct replacement, but can be emulated) |
|||
['titled'] = 'title', -- Brazilian Portuguese |
|||
['titolo'] = 'title', -- Italian |
|||
['titre'] = 'title', -- French |
|||
['trans-script'] = 'transcript', -- misspelling |
|||
['trans_chapter'] = 'trans-chapter', -- old parameter alias |
|||
['trans_title'] = 'trans-title', -- old parameter alias |
|||
['transchapter'] = 'trans-chapter', |
['transchapter'] = 'trans-chapter', |
||
['translator'] = 'others', |
|||
['transcripturl'] = 'transcript-url', -- old parameter name |
|||
['transscript'] = 'transcript', -- misspelling |
|||
['transscript-format'] = 'transcript-format', -- misspelling |
|||
['transscript-url'] = 'transcript-url', -- misspelling |
|||
['transscripturl'] = 'transcript-url', -- misspelling |
|||
['transtitle'] = 'trans-title', |
['transtitle'] = 'trans-title', |
||
['ubicación'] = 'location', -- Spanish, Italian |
|||
['typ'] = 'author-mask', -- German (not a direct replacement, but the only valid argument 'typ=wl' can be emulated using 'author-mask') |
|||
[' |
['urlarchivo'] = 'archive-url', -- Spanish, Italian |
||
[' |
['vol'] = 'volume', |
||
['título'] = 'title', -- Spanish |
|||
['ubicación'] = 'location', -- Spanish |
|||
['urlarchivio'] = 'archive-url', -- Italian |
|||
['urlarchivo'] = 'archive-url', -- Spanish |
|||
['urlmorto'] = 'url-status', -- Italian |
|||
['urn'] = 'id', -- German (as 'id={{URN|...}}') |
|||
['v-authors'] = 'vauthors', -- misspelling |
|||
['v-editors'] = 'veditors', -- misspelling |
|||
['verlag'] = 'publisher', -- German |
|||
['verlagea'] = 'publisher', -- German (not a direct replacement, but can be emulated) |
|||
['vol'] = 'volume', |
|||
['volumen'] = 'volume', -- Spanish |
|||
['werk'] = 'work', -- German |
|||
['werkerg'] = 'contribution', -- German (not a direct replacement, but can be emulated) |
|||
['wkautore'] = 'author-link', -- Italian |
|||
['wolumin'] = 'volume', -- Polish |
|||
['wydanie'] = 'number', -- Polish |
|||
['wydawca'] = 'publisher', -- French |
|||
['yardımcıyazarlar'] = 'author', -- Turkish |
|||
['yayımcı'] = 'publisher', -- Turkish |
|||
['yayıncı'] = 'publisher', -- Turkish |
|||
['yazar'] = 'author', -- Turkish |
|||
['yazarbağı'] = 'author-link', -- Turkish |
|||
['yer'] = 'location', -- Turkish |
|||
['yıl'] = 'date', -- Turkish |
|||
['zaprezentowany'] = 'publisher', -- French |
|||
['zdb'] = 'id', -- German (as 'id={{ZDB|...}}') |
|||
['zitat'] = 'quote', -- German |
|||
['zugriff'] = 'access-date', -- German |
|||
['éditeur'] = 'editor', -- French |
|||
['ölüurl'] = 'url-status', -- Turkish |
|||
['übersetzer'] = 'translator', -- German (singular and plural) |
|||
} |
} |
||
--[[--------------------------< P A T T E R N S >-------------------------------------------------------------- |
--[[--------------------------< P A T T E R N S >-------------------------------------------------------------- |
||
Here we use Lua patterns to make suggestions. The form is |
Here we use Lua patterns to make suggestions. The form is ['pattern'] = 'correct', |
||
['pattern'] = 'correct', |
|||
Lua patterns are not |
Lua patterns are not regex though they are similar. The escape character is '%', not '\'. For more information about |
||
lua patterns, see: Extension:Scribunto/Lua_reference_manual#Patterns |
|||
Patterns should probably always include the '^' and '$' anchor assertions to prevent a partial |
Patterns should probably always include the '^' and '$' anchor assertions to prevent a partial match from incorrectly |
||
suggesting the wrong parameter name. For instance, the pattern 'a[utho]+r' matches 'author' in the no-longer-supported |
|||
parameter |author-separator= so the code suggests '|author='; the same pattern also matches the no-longer-supported |
|||
parameter |separator= (returning 'ator') so again, the code suggests '|author='. |
|||
'|author='; the same pattern also matches the no-longer-supported parameter |separator= (returning 'ator') |
|||
so again, the code suggests '|author='. |
|||
One capture is supported, typically the enumerator from an enumerated parameter (the '6' in |author6=, etc.) |
One capture is supported, typically the enumerator from an enumerated parameter (the '6' in |author6=, etc.) The value from the |
||
capture replaces $1 in the 'correct' value. |
|||
]] |
]] |
||
local patterns = { |
local patterns = { |
||
['^ac+es+ ?d?a?t?e?$'] = 'access-date', |
['^ac+es+ ?d?a?t?e?$'] = 'access-date', |
||
['^ |
['^a[utho]+r$'] = 'author', |
||
['^a[utho]+r$'] = 'author', |
['^a[utho]+r(%d+)$'] = 'author$1', -- enumerated |
||
['^ |
['^pu[blish]+ers?$'] = 'publisher', |
||
['^author link(%d+)$'] = 'author-link$1', -- Polish, enumerated |
|||
['^autor[e]?(%d+)$'] = 'author$1', -- Italian/Spanish/German, enumerated |
|||
['^authorfirst(%d+)$'] = 'author-first$1', -- old parameter name, enumerated |
|||
['^author(%d+)first$'] = 'author-first$1', -- old parameter name, enumerated |
|||
['^authorgiven(%d+)$'] = 'author-given$1', -- old parameter name, enumerated |
|||
['^author(%d+)given$'] = 'author-given$1', -- old parameter name, enumerated |
|||
['^authorlast(%d+)$'] = 'author-last$1', -- old parameter name, enumerated |
|||
['^author(%d+)last$'] = 'author-last$1', -- old parameter name, enumerated |
|||
['^authormask(%d+)$'] = 'author-mask$1', -- old parameter name, enumerated |
|||
['^author(%d+)mask$'] = 'author-mask$1', -- old parameter name, enumerated |
|||
['^authorsurname(%d+)$'] = 'author-surname$1', -- old parameter name, enumerated |
|||
['^author(%d+)surname$'] = 'author-surname$1', -- old parameter name, enumerated |
|||
['^cognome(%d+)$'] = 'last$1', -- Italian, enumerated |
|||
['^editorfirst(%d+)$'] = 'editor-first$1', -- old parameter name, enumerated |
|||
['^editor(%d+)first$'] = 'editor-first$1', -- old parameter name, enumerated |
|||
['^editorgiven(%d+)$'] = 'editor-given$1', -- old parameter name, enumerated |
|||
['^editor(%d+)given$'] = 'editor-given$1', -- old parameter name, enumerated |
|||
['^editorlast(%d+)$'] = 'editor-last$1', -- old parameter name, enumerated |
|||
['^editor(%d+)last$'] = 'editor-last$1', -- old parameter name, enumerated |
|||
['^editorlink(%d+)$'] = 'editor-link$1', -- old parameter name, enumerated |
|||
['^editor(%d+)link$'] = 'editor-link$1', -- old parameter name, enumerated |
|||
['^editormask(%d+)$'] = 'editor-mask$1', -- old parameter name, enumerated |
|||
['^editor(%d+)mask$'] = 'editor-mask$1', -- old parameter name, enumerated |
|||
['^editorsurname(%d+)$'] = 'editor-surname$1', -- old parameter name, enumerated |
|||
['^editor(%d+)surname$'] = 'editor-surname$1', -- old parameter name, enumerated |
|||
['^enlaceautore(%d+)$'] = 'author-link$1', -- Spanish, enumerated |
|||
['^first (%d+)$'] = 'first$1', -- enumerated |
|||
['^last (%d+)$'] = 'last$1', -- enumerated |
|||
['^nom[e]?(%d+)$'] = 'last$1', -- Italian/French, enumerated |
|||
['^nombre(%d+)$'] = 'first$1', -- Spanish, enumerated |
|||
['^primero(%d+)$'] = 'first$1', -- Spanish, enumerated |
|||
['^pu[blish]+ers?$'] = 'publisher', -- misspelling |
|||
['^subjectlink(%d+)$'] = 'subject-link$1', -- old parameter name, enumerated |
|||
['^subject(%d+)link$'] = 'subject-link$1', -- old parameter name, enumerated |
|||
['^wkautore(%d+)$'] = 'author-link$1', -- Italian, enumerated |
|||
} |
} |
||
2024年1月18日 (四) 20:51的版本
此列表是在引用模板中的参数未知时使用的建议名单。引用模板中发现未知参数时会生成一个错误消息,软件会基于此列表提醒用户常见的误写。
每项格式如下: ['bad input parameter'] = 'suggested parameter to use'
即输入的有误参数、建议使用的参数。
与此列表比对的有误参数检查前会转为小写,因此列表中的所有输入内容均应为小写形式。
如下文件涉及对CS1与CS2引用模板的支持:
| 线上 | 沙盒 | 描述 | ||
|---|---|---|---|---|
| Module:Citation/CS1 | Module:Citation/CS1/sandbox | 编辑 | 渲染及支持功能 | |
| Module:Citation/CS1/Configuration | Module:Citation/CS1/Configuration/sandbox | 编辑 | 翻译表;错误和标识符处理 | |
| Module:Citation/CS1/Whitelist | Module:Citation/CS1/Whitelist/sandbox | 编辑 | 现行与已过时不推荐使用的CS1与CS2参数 | |
| Module:Citation/CS1/Date validation | Module:Citation/CS1/Date validation/sandbox | 编辑 | 日期格式验证函数 | |
| Module:Citation/CS1/Identifiers | Module:Citation/CS1/Identifiers/sandbox | 编辑 | 支持命名标识符(ISBN、DOI、PMID等)的函数 | |
| Module:Citation/CS1/Utilities | Module:Citation/CS1/Utilities/sandbox | 编辑 | 常用函数及表 | |
| Module:Citation/CS1/COinS | Module:Citation/CS1/COinS/sandbox | 编辑 | 支持CS1与CS2模板元数据渲染的函数 | |
| Module:Citation/CS1/styles.css | Module:Citation/CS1/sandbox/styles.css | 编辑 | 为CS1与CS2模板提供CSS样式 | |
| Module:Citation/CS1/Suggestions | Module:Citation/CS1/Suggestions/sandbox | 编辑 | 将常见错误参数名映射到有效参数名的列表 | |
--Please insert new suggestions in alphabetical order
--The form is ['incorrect'] = 'correct',
suggestions = {
-- ['acccessdate'] = 'access-date',
-- ['accesdate'] = 'access-date',
-- ['access date'] = 'access-date',
-- ['accessate'] = 'access-date',
-- ['accessdare'] = 'access-date',
-- ['accessdatte'] = 'access-date',
-- ['accessddate'] = 'access-date',
-- ['accessdte'] = 'access-date',
-- ['accessed'] = 'access-date',
-- ['accessedate'] = 'access-date',
-- ['accesssdate'] = 'access-date',
-- ['accssdate'] = 'access-date',
-- ['acessdate'] = 'access-date',
['address'] = 'location',
['année'] = 'year', -- French
['añoacceso'] = 'access-date', -- Spanish, Italian
['apellido'] = 'last', -- Spanish, Italian
['archive date'] = 'archive-date',
['archive url'] = 'archive-url', -- Spanish, Italian
['artist'] = 'others',
['auteur'] = 'author', -- French
['auther'] = 'author',
['authorformat'] = 'name-list-format', -- remove after 2016-01-01
['author-format'] = 'name-list-format', -- remove after 2016-01-01
['author link'] = 'author-link',
-- ['autor'] = 'author', -- Spanish, Italian
-- ['autor2'] = 'author2', -- Spanish, Italian
['autthor'] = 'author',
['began'] = 'date', -- remove after 2016-01-01
['chapter_title'] = 'chapter',
['cita'] = 'quote', -- Spanish, Italian
['coautores'] = 'coauthors', -- Spanish, Italian
['consulté le'] = 'access-date', -- French
['deadlink'] = 'dead-url',
['distributor'] = 'publisher',
['éditeur'] = 'editor', -- French
['editon'] = 'edition',
['editoin'] = 'edition',
['editorformat'] = 'name-list-format', -- remove after 2016-01-01
['editor-format'] = 'name-list-format', -- remove after 2016-01-01
['editorgiven'] = 'editor-given', -- remove after 2016-01-01
['editorial'] = 'publisher',
['editorsurname'] = 'editor-surname', -- remove after 2016-01-01
['en ligne le'] = 'archive-date', -- French
['ended'] = 'date', -- remove after 2016-01-01
['enlaceautor'] = 'author-link', -- Spanish, Italian
['fecha'] = 'date', -- Spanish, Italian
['fechaacceso'] = 'access-date', -- Spanish, Italian
['fechaarchivo'] = 'archive-date', -- Spanish, Italian
['filetype'] = 'format',
['first 1'] = 'first1',
['foramt'] = 'format',
['formato'] = 'format', -- Spanish, Italian
['frist'] = 'first',
['idioma'] = 'language', -- Spanish, Italian
['isnb'] = 'isbn',
['lang'] = 'language',
['langauge'] = 'language',
['langue'] = 'language', -- French
['last 1'] = 'last1',
['lieu'] = 'location', -- French
['lire en ligne'] = 'url', -- French
['loaction'] = 'location',
['locatoin'] = 'location',
['mois'] = 'month', -- French
['month'] = 'date', -- remove after 2016-01-01
-- ['name'] = 'author', -- 'name' is often erroneously used for 'title' and 'work' as well, so no suggestion is better than a wrong suggestion
['nespaper'] = 'newspaper',
['newpaper'] = 'newspaper',
['news'] = 'newspaper',
['nom'] = 'last', -- French
['nom1'] = 'last1', -- French
['nombre'] = 'first', -- Spanish, Italian
['obra'] = 'work', -- Spanish, Italian
['origdate'] = 'orig-year',
['other'] = 'others',
['pagees'] = 'pages',
['página'] = 'page', -- Spanish, Italian
['páginas'] = 'pages', -- Spanish, Italian
['passage'] = 'pages', -- French
['périodique'] = 'publisher', -- French
['plublisher'] = 'publisher',
['pmcid'] = 'pmc',
['prénom'] = 'first', -- French
['prénom1'] = 'first1', -- French
['ps'] = 'postscript',
['pub'] = 'publisher',
-- ['pubisher'] = 'publisher',
-- ['publiser'] = 'publisher',
-- ['publishers'] = 'publisher',
-- ['publsher'] = 'publisher',
-- ['publsiher'] = 'publisher',
['pulbication-place'] = 'publication-place',
-- ['pulbisher'] = 'publisher',
-- ['pulisher'] = 'publisher',
['retrieved'] = 'access-date',
['separator'] = 'mode', -- remove after 2016-01-01
['série'] = 'work', -- French
['service'] = 'agency',
['suscripción'] = 'subscription', -- Spanish, Italian
['tile'] = 'title',
['tite'] = 'title',
['titolo'] = 'title', -- Spanish, Italian
['titre'] = 'title', -- French
['título'] = 'title', -- Spanish, Italian
['transchapter'] = 'trans-chapter',
['translator'] = 'others',
['transtitle'] = 'trans-title',
['ubicación'] = 'location', -- Spanish, Italian
['urlarchivo'] = 'archive-url', -- Spanish, Italian
['vol'] = 'volume',
}
--[[--------------------------< P A T T E R N S >--------------------------------------------------------------
Here we use Lua patterns to make suggestions. The form is ['pattern'] = 'correct',
Lua patterns are not regex though they are similar. The escape character is '%', not '\'. For more information about
lua patterns, see: Extension:Scribunto/Lua_reference_manual#Patterns
Patterns should probably always include the '^' and '$' anchor assertions to prevent a partial match from incorrectly
suggesting the wrong parameter name. For instance, the pattern 'a[utho]+r' matches 'author' in the no-longer-supported
parameter |author-separator= so the code suggests '|author='; the same pattern also matches the no-longer-supported
parameter |separator= (returning 'ator') so again, the code suggests '|author='.
One capture is supported, typically the enumerator from an enumerated parameter (the '6' in |author6=, etc.) The value from the
capture replaces $1 in the 'correct' value.
]]
local patterns = {
['^ac+es+ ?d?a?t?e?$'] = 'access-date',
['^a[utho]+r$'] = 'author',
['^a[utho]+r(%d+)$'] = 'author$1', -- enumerated
['^pu[blish]+ers?$'] = 'publisher',
}
return {suggestions = suggestions, patterns=patterns};