Zum Inhalt springen

Modul:LinkISBN: Unterschied zwischen den Versionen

i18n nach Module:LinkISBN/i18n ausgelagert
(Umbenennung)
(i18n nach Module:LinkISBN/i18n ausgelagert)
Zeile 2: Zeile 2:
local LinkISBN = {
local LinkISBN = {
suite  = 'LinkISBN',
suite  = 'LinkISBN',
serial = '2020-10-24',
serial = '2021-03-24',
item  = 65157187
item  = 65157187
}
}
Zeile 12: Zeile 12:
local ci = require( 'Module:Check_isxn' )
local ci = require( 'Module:Check_isxn' )
local fs = require( 'Module:Failsafe' )
local fs = require( 'Module:Failsafe' )
local li = require( 'Module:Link utilities/i18n' )
local lb = require( 'Module:LinkISBN/i18n' )
local lu = require( 'Module:Link utilities' )
local lu = require( 'Module:Link utilities' )
local yn = require( 'Module:Yesno' )
local yn = require( 'Module:Yesno' )
Zeile 27: Zeile 27:


m = m:gsub( 'ISBN *', '' ):upper() -- x -> X
m = m:gsub( 'ISBN *', '' ):upper() -- x -> X
local t = '<span class="' .. li.classes.booksources .. '" title="'
local t = '<span class="' .. lb.booksourcesClass .. '">[[Special:Booksources/'
.. li.categories.special .. m .. '">[[' .. li.categories.special
.. m .. '|' .. 'ISBN ' .. m .. ']]</span>'
.. m .. '|' .. 'ISBN ' .. m .. ']]</span>'
if not ignoreError then
if not ignoreError then
t = t .. ci._check_isbn( m,
t = t .. ci._check_isbn( m,
li.categories.invalidISBN .. ( demo and '' or li.categories.invalidCat ) )
lb.invalidISBN .. ( demo and '' or lb.invalidCat ) )
end
end
if comment ~= '' then
if comment ~= '' then
Zeile 51: Zeile 50:
local ns    = mw.title.getCurrentTitle().namespace
local ns    = mw.title.getCurrentTitle().namespace
local isDemo = ns == 10 or ns == 828
local isDemo = ns == 10 or ns == 828
 
-- split separate ISBNs
-- split separate ISBNs
local items = lu.splitItems( args.isbn, li.delimiters )
local items = lu.splitItems( args.isbn, lb.delimiters )
-- analyse ISBNs
-- analyse ISBNs
Anonymer Benutzer