Modification de Module:Infobox/Quête
La modification peut être annulée. Veuillez vérifier les différences ci-dessous pour voir si c’est bien ce que vous voulez faire, puis publier ces changements pour finaliser l’annulation de cette modification.
Version actuelle | Votre texte | ||
Ligne 1 : | Ligne 1 : | ||
local localdata = require('Module:Infobox/Localdata') | local localdata = require('Module:Infobox/Localdata') | ||
function buildSuccess(localdata) | function buildSuccess(localdata) | ||
local success = nil | local success = nil | ||
Ligne 23 : | Ligne 17 : | ||
if localdata['gamerscore'] then | if localdata['gamerscore'] then | ||
success = success ..'<span style="padding-left:4px;">'.. icon. | success = success ..'<span style="padding-left:4px;">'.. icon.build({ 'gamerscore' }) ..'</span>' | ||
success = success ..'<span style="padding-left: 2px;position:relative;top:1px;">'.. localdata['gamerscore'] ..'</span>' | success = success ..'<span style="padding-left: 2px;position:relative;top:1px;">'.. localdata['gamerscore'] ..'</span>' | ||
end | end | ||
if localdata['type trophée'] then | if localdata['type trophée'] then | ||
success = success ..'<span style="padding-left:4px;">'.. icon. | success = success ..'<span style="padding-left:4px;">'.. icon.build({ 'trophéeps3' }) ..'</span>' | ||
success = success ..'<span style="padding-left: 2px;position:relative;top:1px;">'.. localdata['type trophée'] ..'</span>' | success = success ..'<span style="padding-left: 2px;position:relative;top:1px;">'.. localdata['type trophée'] ..'</span>' | ||
end | end | ||
Ligne 38 : | Ligne 32 : | ||
end | end | ||
function buildSubject(arg) | |||
function buildSubject( | local subject = 'Quête' | ||
local subject | local type = nil | ||
local | |||
if | if arg then | ||
local types = { | local types = { | ||
['principale'] = ' | ['principale'] = 'principale', | ||
['répétable'] = ' | ['répétable'] = 'répétable', | ||
['annexe'] = ' | ['annexe'] = 'annexe', | ||
['secondaire'] = ' | ['secondaire'] = 'secondaire', | ||
['quotidienne'] = ' | ['quotidienne'] = 'quotidienne', | ||
['non marquée'] = ' | ['non marquée'] = 'non marquée', | ||
['aléatoire'] = ' | ['aléatoire'] = 'aléatoire' | ||
} | } | ||
type = types[arg:lower()] | |||
end | end | ||
if type then | |||
subject = subject..' '..type | |||
end | end | ||
return | return subject | ||
end | end | ||
return { | return { | ||
parts = { | parts = { | ||
{ type = 'title', value = 'nom', subtitle = 'sous-titre', icon = 'icône', subhead = { games = 'jeux', subject = buildSubject(localdata), link = | { type = 'title', value = 'nom', subtitle = 'sous-titre', icon = 'icône', subhead = { games = 'jeux', subject = buildSubject(localdata['type']), link = 'Quêtes' }}, | ||
{ type = 'images', imageparameters = { 'image', 'image2', 'image3', 'image4', 'image5' }, captionparameter = { 'légende', 'image desc' }}, | { type = 'images', imageparameters = { 'image', 'image2', 'image3', 'image4', 'image5' }, captionparameter = { 'légende', 'image desc' }}, | ||
{ type = 'table', title = 'Informations', rows = { | { type = 'table', title = 'Informations', rows = { | ||
Ligne 103 : | Ligne 70 : | ||
}}, | }}, | ||
{ type = 'table', title = 'Technique', rows = { | { type = 'table', title = 'Technique', rows = { | ||
{ type = 'row', label = 'Editor ID', value = ' | { type = 'row', label = 'Editor ID', value = 'editor id' }, | ||
{ type = 'row', label = '[[Form ID]]', value = ' | { type = 'row', label = '[[Form ID|Base ID]]', value = { 'base id', 'baseid' } } | ||
}}, | }}, | ||
{ type = 'table', title = 'Quêtes associées', rows = { | { type = 'table', title = 'Quêtes associées', rows = { | ||
{ type = 'succession', value = { | { type = 'succession', value = { | ||
before = | before = localdata['précédente'], | ||
after = | after = localdata['suivante'] | ||
}}, | }}, | ||
{ type = 'row1col', value = { 'relative', 'associée' } } | { type = 'row1col', value = { 'relative', 'associée' } } | ||
}}, | }}, | ||
{ type = 'text', value = 'pied' } | { type = 'text', value = 'pied' } | ||
} | } | ||
} | } |