« Module:Message box » : différence entre les versions

temp>Anomie
File:Cscr-featured.svg needs a link to the description page for license and attribution. Add the ability for the configuration to specify a flag to accomplish this.
Clementin.granier1 (discussion | contributions)
m 1 version importée
 
(3 versions intermédiaires par 2 utilisateurs non affichées)
Ligne 188 : Ligne 188 :
-- Set text style.
-- Set text style.
self.textstyle = args.textstyle
self.textstyle = args.textstyle
-- Set image classes.
self.imageRightClass = args.imagerightclass or args.imageclass
self.imageLeftClass = args.imageleftclass or args.imageclass


-- Find if we are on the template page or not. This functionality is only
-- Find if we are on the template page or not. This functionality is only
Ligne 519 : Ligne 523 :
imageLeftCell = imageLeftCell:tag('div'):addClass('mbox-image-div')
imageLeftCell = imageLeftCell:tag('div'):addClass('mbox-image-div')
end
end
imageLeftCell:wikitext(self.imageLeft or nil)
imageLeftCell
:addClass(self.imageLeftClass)
:wikitext(self.imageLeft or nil)
elseif self.imageEmptyCell then
elseif self.imageEmptyCell then
-- Some message boxes define an empty cell if no image is specified, and
-- Some message boxes define an empty cell if no image is specified, and
Ligne 574 : Ligne 580 :
end
end
imageRightCell
imageRightCell
:addClass(self.imageRightClass)
:wikitext(self.imageRight or nil)
:wikitext(self.imageRight or nil)
end
end