Module talk:Citation/CS1/Feature requests

This page is used to make requests for new features for the Lua based CS1 templates. Please understand that the priority is to update and debug the older templates before implementing new features. Completed feature requests are archived at Module talk:Citation/CS1/Feature_requests/Completed

Language
Titles should be wrapped with markup indicating the language. --— Gadget850 (Ed) talk 14:37, 29 March 2013 (UTC)


 * How would this actually work? You have some template examples in mind maybe?  Dragons flight (talk) 18:57, 8 April 2013 (UTC)
 * See lang. --   Gadget850talk 23:38, 26 April 2013 (UTC)
 * Let me be a bit more specific. First, which elements would you have the language= apply markup to?  Title?  Title and Chapter?  Title and Periodical?  Secondly, do you want to use the existing templates, e.g. actually call   when getting Spanish?  Or is it sufficient to bypass the templates and just add a span and (sometimes) a category?  Also, is there a automated way of knowing that "Spanish" maps to "es", etc.?  Dragons flight (talk) 23:52, 26 April 2013 (UTC)
 * I was looking at that. We will have to roll our own, as I don't see a template that converts the full language name to the ISO form. Or, we could create a new 'lang' parameter that uses the ISO and overrides 'language'. I would think we could apply  where applicable. Might be best to do this in a separate module that could be used elsewhere. --   Gadget850talk 00:53, 27 April 2013 (UTC)
 * I habitually enter, say, es, then have to go back and change it :-( Your proposed new lang parameter would be much appreciated. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 16:19, 17 May 2013 (UTC)


 * I think this ought to wait until someone converts the language template tree to Lua, so we have a good list of code-to-language mappings. What's needed basically already exists, but as presently implemented its scattered across hundreds of lang subtemplates, which isn't very usable for us.  Dragons flight (talk) 22:32, 20 May 2013 (UTC)
 * I'm not sure what "the language template tree" is, but there's already a language name library available in Lua: -> . Liangent (talk) 12:55, 29 May 2013 (UTC)

I believe that this request has been implemented. Example:

– Jonesey95 (talk) 04:34, 20 December 2013 (UTC)

The code to language conversion is done, but not the language markup.

The above example, renders as (less COinS):
 * Will Ferrell. La Casa de Mi Padre (in Spanish).

What we need is:


 * Will Ferrell.  La Casa de Mi Padre  (in Spanish).

See lang.

--  Gadget850talk 13:12, 20 April 2014 (UTC)


 * Is it possible to reinstigate discussion on this change? At the moment, providing human-readable language tagging is done (as Jonesey95 pointed out on 20 December 2013) and COinS-tagging means that we can't use lang within CS1 templates (like {{cite book |title={{lang|es|La Casa de Mi Padre}} |trans_title=My Father's Home |author=Will Ferrell |language=es }}) because it would pollute the machine-readable data; we need to use {{cite book |title=La Casa de Mi Padre |trans_title=My Father's Home |author=Will Ferrell |language=es }} instead.


 * What would be great would be to change the output markup so that this example above goes from rendering (without the COinS):   to rendering   for example. This would allow assistive technologies correctly to identify the language of the title (and, for example, user CSS to style text differently according to language). Alternatively, rather than assuming that the   (and only the  ) will match the , new parameters could be added such as title_lang, chapter_lang and journal_lang, for example.


 * I'm entirely open to discussing the details, as I've just made these up on the spot, but in principle this feels like something we could make work, no? :o)
 * — OwenBlacker (Talk) 14:32, 7 February 2016 (UTC)


 * —Trappist the monk (talk) 16:43, 7 February 2016 (UTC)

Name suffixes
The COinS implementation guide specifies that, at least for the first author of a work, it should be possible to separate their name into first name(s), last name, and suffix. When the templates were created, they were regarded solely as presentational, and separate parameters for suffixes weren't thought to be worth implementing. Scanning the ends of first1, first2, editor1,...and so forth for "Sr", "Jr", "II", and "III" should probably pick up most of the citations where suffixes should be moved to their own parameters. Choess (talk) 15:26, 30 March 2013 (UTC)
 * We should still add parameters for those oddball suffixes. --  Gadget850 (Ed) talk 16:58, 30 March 2013 (UTC)
 * Sorry, I combined two thoughts. We'd need new "suffix*" parameters for names in general, which could be used for any suffix. The scanning I mentioned could be for a (temporary?) maintenance category to identify citations that would need to be edited to use the new parameters. Choess (talk) 17:15, 30 March 2013 (UTC)
 * See Suffix (name). We have no guidelines for suffixes, but you are discussing generational suffixes. I need to check some style guides to see if we should include academic, professional, religious or honorary suffixes. --  Gadget850 (Ed) talk 17:20, 30 March 2013 (UTC)
 * OpenURL (COinS) only provides a field for "name suffixes", not titles or degrees. Choess (talk) 17:32, 30 March 2013 (UTC)

Internet Archive
Can someone familiar with this module add code to enable Internet Archive links for books etc. For example, the open library code OL16525337M is the book "A concise etymological dictionary of the English language", which also has LCCN 11035890 and Internet Archive code cu31924008779690. Thanks. Mind matrix  03:20, 2 April 2013 (UTC)
 * And Google Books ls_XijT33IUC. What other archive systems are used? --  Gadget850 (Ed) talk 09:42, 2 April 2013 (UTC)
 * at WebCite users can archive single webpages. the Internet Archive also crawls for site/page snapshots and these may follow the rate of change of the originals. Google Books is different, as it may act more like an online publisher than an archival service. 70.19.122.39 (talk) 00:25, 3 April 2013 (UTC)

Here is the id_handler example for LCCN from Module:Citation/CS1/Configuration.

parameters = {'LCCN', 'lccn'}                   How specified in the citation template, i.e. LCCN= link = 'Library of Congress Control Number'     Wikipage to link to at the ID label label = 'LCCN'                                  Text to use for the ID label mode = 'external'                               Indicates an external link (the typical case) prefix = 'http://lccn.loc.gov/'                 Start of the url to use with the ID suffix = ''                                      Anything to include in the url after the ID COinS = 'rft.lccn'                               Where to map the data in COinS encode = false                                  Whether the ID must be urlencoded separator = '&amp;nbsp;'                            Separator to use between the ID label and the ID

When given LCCN=123456, this generates output that looks like:

LCCN 123456 = LCCN 123456

If you can figure out how to update the fields for Internet Archive, Google Books, or some other ID scheme, then they would be easy to add. A few ID schemes (including Open Library) don't easily map to this format and have to be specially handled, so that is possible too, but it would take more effort. Dragons flight (talk) 19:13, 8 April 2013 (UTC)


 * Internet Archive has various media (text, audio, video), but they all appear to have the same URL pattern ( http://www.archive.org/details/identifier ). Should we create one entry and disregard type, or create separate entries for each, some of which may have subtypes? (For example, some of the audio files could use a handler for Live Music Archive instead of Internet Archive.) I think one handler is probably the better option. Mind  matrix  15:53, 10 April 2013 (UTC)


 * In general, I tend to think that less is more in cases like this unless there is a strong reason to differentiate. However, I don't really know much about the Internet Archive, so I'm not really a good person to judge.  Dragons flight (talk) 16:37, 10 April 2013 (UTC)

Format size
Add 'formatsize' to indicate the size of the linked document. This should show right after 'format' and in the parenthesis. There is already a bot filling in PDF sizes for another template, so it can be repurposed to detect if 'format' is defined, then add 'formatsize' if it isn't already defined. --  Gadget850talk 18:24, 26 April 2013 (UTC)
 * ? (Feature request brought to you by Templates for discussion/Log/2013 April 24.) --Izno (talk) 13:41, 27 April 2013 (UTC)
 * formatsize presumably to be filled in for known file types (PDF, XLS, ...), and not for things not in the list like formathardcover, handout, etc. For streaming media, the file size is rarely known up front, unless it's hosted as a file (such as on Commons), so perhaps not filled in for formatvideo, but perhaps for AVI, MP4, etc. --Lexein (talk) 03:36, 28 April 2013 (UTC)


 * video is not a format, but a medium, and should be inserted as a value for type (per the so-called documentation). video formats are: (various) tape formats, (various) disc formats, film etc. AVI, MP4, etc. are not video formats: they are digital file formats and should be used with the appropriate (digital) type = webcast/e-video/downloadable media etc.
 * the confusion begins with type, a parameter name that only a geek would love, since it can mean anything. apparently, aliasing it with "medium" would be too obvious for some people.
 * get yer stories straight!
 * 70.19.122.39 (talk) 12:54, 29 April 2013 (UTC)


 * It occurs to me that we might alleviate some of the confusion going forward by aliasing format as fileformat to emphasize that we are talking about a digital file. If that were done, a new size parameter could be called filesize.  Dragons flight (talk) 15:52, 29 April 2013 (UTC)
 * 'urlformat' might be better, since it indicates that it modifies 'url', since there seems to be confusion. Then 'urlsize'. --   Gadget850talk 16:08, 29 April 2013 (UTC)
 * I'm not sure about 'urlformat' (as opposed to 'fileformat'). My initial reaction is that 'urlformat' suffers much the same problem as 'format', in that people may be inclined to assume it means the format of the work described at the other end of the URL and put things like "book" or "video" in there.  'fileformat' seems closer to the intended use.  Dragons flight (talk) 22:06, 20 May 2013 (UTC)

ORCID
We should add an ORCID parameter for each author (and possibly one for ISNI) as discussed at Help talk:Citation Style 1/Archive 2 Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 15:41, 17 May 2013 (UTC)


 * If I understand correctly, the proposal is to create a parameter for each author that could specify their associated ORCID, and if there is no local wikilink for that author then to add an external link from the author's name to the associated ORCID database entry? Dragons flight (talk) 02:20, 21 May 2013 (UTC)
 * Why would it be dependent on the authorlink? If the page is ported to another site, that link may not exist. --  Gadget850talk 02:28, 21 May 2013 (UTC)
 * If there is an article about an author, then the ORCID link will be on that page. It seems unnecessary to include it in every reference, but I'd be content that we did, if that's what others want. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 13:21, 29 May 2013 (UTC)
 * Yes. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 13:21, 29 May 2013 (UTC)

Wow: nearly three years on, and no further responses. A resolution for this matter is now being discussed at Help talk:Citation Style 1#‎Proposal: addition of 'author-id' parameter. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 10:47, 11 April 2016 (UTC)
 * Discussion was archived, unresolved. Link updated. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 16:25, 1 August 2016 (UTC)

HTML classes
We should add HTML classes, identifying the various parameter values, by way of a microformat, as discussed at Module talk:Citation/CS1/Archive 6. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 16:13, 17 May 2013 (UTC)


 * When might we see some movement on this? Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 10:48, 11 April 2016 (UTC)
 * Is there a written standard that maps cs1|2 parameters to microformat tags?
 * —Trappist the monk (talk) 11:58, 11 April 2016 (UTC)
 * Please see Module talk:Citation/CS1/Archive 6. Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 17:56, 11 April 2016 (UTC)
 * What I read there suggests that there isn't a written standard yet.
 * —Trappist the monk (talk) 20:18, 11 April 2016 (UTC)
 * Indeed; as discussed previously (three & four years ago!) we should mint one; and as I said there, "I've started a brainstorming page at WikiProject Microformats/citation, with a draft proposal for discussion and an example". Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 20:50, 11 April 2016 (UTC)
 * When WikiProject Microformats/citation is done let us know. It will help you to consider each of the meta parameters listed in Module:Citation/CS1/Configuration in the aliases table (the meta parameters are the lvalues: , etc).  Clearly not every cs1|2 meta parameter will need a class because some of them don't display anything to the reader.
 * —Trappist the monk (talk) 22:20, 11 April 2016 (UTC)
 * Only just seen your reply, so apologies for the delayed response. I've started a provisional mapping at WikiProject Microformats/citation. However, I'm not clear what some of those aliases mean, nor when they're used. Is there any additional documentation? Many of the module's properties won't have a direct equivalent in the microformat; we could simply prepend "p-", so for example "Mode" would map to "p-mode". Andy Mabbett ( Pigsonthewing ); Talk to Andy; Andy's edits 16:18, 1 August 2016 (UTC)

Wikisource

 * See also above

The Cite wikisource is not used for many of the templates that call wikisource (See for example EB1911 -- There are currently over 12,000 articles in Category:Wikipedia articles incorporating text from the 1911 Encyclopædia Britannica of which over 3,000 link to wikisource).

For wikisource to be used for templates such as EB1911 it would need to be refocused. The reason why it is not used very much is because not all the articles in these large encyclopaedias have been ported to Wikisource. So we need two parameters one to handle the case were the text is available on wikisource and one where it is not. As over time more more encyclopaedias and other large works will gradually be made available on Wikisource, this problem of gradual availability will not go away in the foreseeable future.

The way this problem is currently handled is to use cite encyclopaedia and place a wrapper around it (I have [User:PBS/Notes#List of PD Templates|list of dozens] on my notes page), most of which use as a de facto standard:
 * title= — is used for non-wikisource articles
 * wstitle= —  is used for wikisource articles

The different scripts wrapped around cite encyclopaedia handle the specific requirements, but most are similar (and some of these parameters are hard coded):
 * iconstr — can be one of two icons [[Image:wikisource-logo.svg|12px|link=]] and [[Image:PD-icon.svg|12px|link=]] depending on whether wstitle is set.
 * noicon — to turn off the display of the lead icon.
 * prescript — for handling attribution as per WP:PLAGIARISM. In most cases this string is ""
 * inline —  alters the wording of the prescript from "This article" to "One or more of the preceding sentences"
 * wstitle — if the title is on wikisource, otherwise use "title="
 * prewstitle — needed for the wikisource prestring starts
 * postwstitle — needed for the wikisource poststing ends
 * display — used as a display in place of "wstitle=" so that things like disambiguation extensions can be hidden.
 * Sometimes the handling of the Wikisource string, involves including other parameter(s)such as or  or whatever into prewstitle or postwstitle  — see for example Cite PSM. Most of the templates that use "wstitle=" will only set the "url=" it "title=" is set.

It seems to me that it should be fairly easy to incorporate these requirements into this module and allow much of the code in the current scripts could be junked as it would allow all the other parameters standard to be passed in without the need to do so explicitly (as had to be done previously). -- PBS (talk) 13:22, 14 June 2013 (UTC)

Separator suppression
If the value ends in punctuation, then suppress the separator/postscript to prevent extra punctuation. Example:

--  Gadget850talk 14:05, 21 July 2013 (UTC)

Consistent date location
This is a reminder, in case it hasn't been implemented yet, of the RfC re consistent date location, Help_talk:Citation_Style_1/Archive_3. – Jonesey95 (talk) 14:18, 19 November 2013 (UTC)

Detect and report wikilinks in author parameters
Our documentation says not to use wikilinks in author parameters. We could create a hidden error message and category for articles that have wikilinks in author parameters. It may be possible for a bot to then convert these links to authorlink parameters.

See discussion at User_talk:Citation_bot. – Jonesey95 (talk) 15:48, 30 January 2014 (UTC)

UA features
Create a UAfeatures parameter, where features depended upon by the referenced media to present the referenced information are specified. e.g. Cookies, Javascript, Flash. — Preceding unsigned comment added by Mattmill30 (talk • contribs) 03:54, 17 November 2014‎ (UTC)

Circa year ranges - CS1 date error at Development of the New Testament canon
Trappist the monk at Help talk:Citation Style 1 sent me over here.

I’d like to request the support of circa year ranges in CS1, for example "c. 303 – c. 325" (which is the format per MOS:DATERANGE).

The last paragraph of the lead of Development of the New Testament canon contains several CS1 date errors ("Check date values in: |date= (help)". For example, the citation  renders as "".  According to MOS:DATERANGE the preferred form would be "c. 303 – c. 325", although that produces the same error.  "303–325" works, but omits the circa.  "c. 303" works, but omits the range.  I've tried various other combinations without success.

At least for the Eusebius reference, it's a series of several writings, and the approximate range of years in which they were written is known, but not the exact dates. For example, because of the dedication of the last part, it's known to have been completed before 325, but whether it was 323 or 324 is not known. Some of that is covered at Church History (Eusebius). I believe the same applies to the start date. So using circa is reasonable.

Any other suggestions welcome. Rwessel (talk) 21:02, 4 December 2014 (UTC)
 * I support this request. We get requests related to "c." more frequently than any other date-related request than I can think of (now that ranges are generally supported). In many cases, we suggest using orig-year and putting the publication date of the actual publication being cited in date, but citation templates are often used to provide a consistent format for a list of publications within the body of an article, in which case orig-year is not desirable. – Jonesey95 (talk) 23:14, 4 December 2014 (UTC)


 * We could use the same date algorithm but simply allow c. and AD before the date and BC, AD, BCE, and CE after the date (if I am reading WP:ERA correctly). --  Gadget850talk 20:07, 7 December 2014 (UTC)


 * Any thoughts on when such a change might be implemented, or a possible work-around? Rwessel (talk) 07:12, 5 January 2015 (UTC)


 * Allow me to second Rwessel's last post. This is a serious readability issue for such a long list of references, which is difficult enough to read without the error messages. Texas Dervish (talk) 19:40, 6 January 2015 (UTC)


 * --Izno (talk) 16:09, 13 March 2020 (UTC)
 * --Izno (talk) 16:09, 13 March 2020 (UTC)

Convert dashes in dates
We currently convert hyphens and em dashes in page rages to the proper en dash. Do so for dates as well. --  Gadget850talk 19:04, 12 January 2015 (UTC)
 * Some hyphens in dates, such as in the YYYY-MM-DD format, should stay as hyphens, so the programming will need to have a bit of subtlety. – Jonesey95 (talk) 21:56, 12 January 2015 (UTC)

suggestion list and enumerated parameters
The module doesn't know how to suggest enumerated parameters:

compare:

—Trappist the monk (talk) 15:12, 6 August 2015 (UTC)
 * The more general case: The Suggestion list would be better if it accepted regular expressions or something similar. There are myriad misspelled forms of "access-date" that I catch and fix with a regex in User:Jonesey95/AutoEd/unnamed.js. It would be great if we could feed something like "ac+e+s-*d+a+t+e" (only one "s") or "ac+e+sss+-*d+at+e" (triple "s") into the Suggestions list and have it suggest "access-date". – Jonesey95 (talk) 20:53, 6 August 2015 (UTC)

Citing Standards
There apparently is no cite standard template yet, which could be used for citing technical standards, although these are often used as references for articles on technical subjects in Wikipedia or even have dedicated articles. Some standards, e.g. most of those issued by ISO, are not available for free, which is sometimes seen as hindering their use as a (reliable) source, but most are available to the general (paying) public, thus do not really violate the principles of verifiability.

Standards usually have one or more issuing bodies which are almost always best known by an acronym, e.g. ISO, IEC, IETF (RFC), IEEE, ITU, SMPTE, ETSI, CEN/CENELEC (EN), CIE, W3C, WHATWG, ECMA, EBU, ANSI, NTSC, NIST, FCC, AMSE, BS, CAN, DIN, JIS, GOST, ARIA, ARIB, CCIR, ASTM, IATA, ICAO.

Most standards are identified by an identification number, sometimes a part or sub-part, and a date (often just the year) of initial publishing or last revision, but they usually also have a title, subtitle, possibly part title, draft or release status, category, subject etc. Author and publisher are often the same, although a designated bureau, committee, taskforce or workgroup may have been chartered with its creation. Many are also related to other standards: they may revise, replace or update them, be published jointly in synchronization with them, translate or adapt them nationally etc.

In short: I'm not sure which (new) parameters would be needed, which should be discouraged, recommended or required and which should be mapped to existing ones by aliases, but I sure wish there was a helpful template. — Christoph Päper 12:47, 16 November 2019 (UTC)
 * Previous discussions:
 * —Trappist the monk (talk) 13:00, 16 November 2019 (UTC)
 * —Trappist the monk (talk) 13:00, 16 November 2019 (UTC)
 * —Trappist the monk (talk) 13:00, 16 November 2019 (UTC)

Fix stacked parentheses problem
Documented at Help talk:Citation Style 1/Archive 24. Also relevant for which would add to it when an author/editor is unspecified. --Izno (talk) 02:13, 8 May 2020 (UTC)


 * Author, Editor, Chapter, Work, Type, Language, Format, Date all specified: (ChapterFormat???)
 * Author (Date). "Chapter" (Format Type in Language). In Editor (ed.). Work.
 * Missing any one parenthetical above: Trivial case.
 * Missing Editor: Trivial case.
 * Missing Author:
 * Editor, ed. (Date). "Chapter" (Format Type in Language). Work.
 * Missing Chapter
 * Author (Date). In Editor (ed.). Work (Format Type in Language).
 * Missing Work: Author (Date). Editor (ed.). "Chapter" (Format Type in Language).

Of note in this set is if Date is in the "big" parentheses, in MDY, it needs a comma following the Y e.g. (January 1, 2001, Format Type in Language).

Combinations: 2 things missing at 1 star and 3 things missing at 2 stars.


 * Author Date: Editor, ed. "Chapter" (Format Type in Language). Work.
 * And Editor: "Chapter" (Format Type in Language). Work.
 * And Chapter: Editor (ed.). Work. (Format Type in Language).
 * And one of Format/Type/Language: Trivial.
 * And Work: Editor (ed.). "Chapter" (Format Type in Language).
 * Author Editor: "Chapter" (Date Format Type in Language). Work.
 * And Chapter: Work (Date Format Type in Language).
 * And one of Format/Type/Language: Trivial.
 * And Work: "Chapter" (Date Format Type in Language).
 * Author Chapter: Editor, ed. (Date). Work (Format Type in Language).
 * And one of Format/Type/Language: Trivial.
 * And Work: Error.
 * Author and one of Format or Type or Language: Trivial.
 * And Work: Editor, ed. (Date). "Chapter" (Format Type in Language).
 * Author Work: Editor, ed. (Date). "Chapter" (Format Type in Language).
 * Editor Date: Author. "Chapter" (FTL). Work.
 * And Chapter: Author. Work (Format Type in Language).
 * And one of Format or Type or Language: Trivial
 * And Work: Author. "Chapter" (Format Type in Language).
 * Editor Chapter: Trivial Missing Chapter.
 * And one of Format or Type or Language: Trivial
 * And Work: Error.
 * Editor and one of Format or Type or Language: Trivial Missing Editor.
 * And Work: Author (Date). "Chapter" (Format Type in Language).
 * Editor Work: Trivial Missing Editor.
 * Date Chapter: Trivial Missing Chapter.
 * And one of Format or Type or Language: Trivial.
 * Date and one of Format or Type or Language: Trivial Missing Date.
 * And Work: Trivial.
 * Date and Work: Trivial Missing Work.
 * Format or Type or Language and one of others: Trivial.
 * And all three: Author (Date). "Chapter". In Editor (ed.). Work.
 * And Work: Trivial.
 * Format or Type or Language and Work: Trivial.

In general: FTL can reasonably be considered as one unit. It sometimes has Date added. It takes a while to get to the point where it doesn't display at all. Could probably be changed in the module today pretty easily (+- ChapterFormat versus Format). --Izno (talk) 03:34, 8 May 2020 (UTC)


 * Related discussion: Help talk:Citation Style 1
 * --Matthiaspaul (talk) 08:45, 31 May 2020 (UTC)