Caixas de mensagem CSS para SMF 2.0 RCX

Started by candidosa2, 09 de January de 2011, 15:55

previous topic - next topic

0 Members and 1 Guest are viewing this topic.

Go Down

candidosa2

Link Original:http://custom.simplemachines.org/mods/index.php?mod=2078
Modo Nome: CSS Message Boxes
Created By: SAFAD
Última versão: 1.1
Versão compatível: 2.0 RC1.2, 2.0 RC3
Instalação Manual : Sim / Por Candidosa2

Sources/Subs-Editor.php

Code Select
         'ftp' => array('code' => 'ftp', 'before' => '[ftp]', 'after' => '[/ftp]', 'description' => $txt['ftp']),
         array(),


Code Select
         'error' => array('code' => 'error', 'before' => '[error]', 'after' => '[/error]', 'description' => $txt['error_bbc']),
         'warning' => array('code' => 'warning', 'before' => '[warning]', 'after' => '[/warning]', 'description' => $txt['warning_bbc']),
         'okay' => array('code' => 'okay', 'before' => '[okay]', 'after' => '[/okay]', 'description' => $txt['okay_bbc']),
         'info' => array('code' => 'info', 'before' => '[info]', 'after' => '[/info]', 'description' => $txt['info_bbc']),
         array(),



Sources/Subs.php

Code Select
         array(
            'tag' => 'white',
            'before' => '<span style="color: white;" class="bbc_color">',
            'after' => '</span>',
         ),


Code Select
         // CSS Message Boxes - grafitus
         array(
            'tag' => 'error',
            'before' => '<div class="error_bbc">',
            'after' => '</div>',
         ),
         array(
            'tag' => 'warning',
            'before' => '<div class="warning_bbc">',
            'after' => '</div>',
         ),
         array(
            'tag' => 'okay',
            'before' => '<div class="okay_bbc">',
            'after' => '</div>',
         ),
         array(
            'tag' => 'info',
            'before' => '<div class="info_bbc">',
            'after' => '</div>',
         ),


Themes/Default/style.css -

Code Select
/* A quote, perhaps from another post. */

Code Select
/* -----------------------------------------------
   C S S   M E S S A G E   B O X E S   v1.0

   Thanks for eBurhan
   http://www.eburhan.com/

   Thanks for famfamfam icons
   http://www.famfamfam.com/
-------------------------------------------------- */

.error_bbc, .warning_bbc, .okay_bbc, .info_bbc {
    margin-bottom: 1.5em;
    padding: 1em 1.5em 1em 5.5em;
    border-bottom: 2px solid #fff;
    border-top: 2px solid #fff;
    color: #444
}

.error_bbc    {background: #fbe3e4 url(images/mBox/error.png) 2.2em center no-repeat; border-color: #e0011b}
.error_bbc a  {color: #d12f19}

.warning_bbc    {background: #fff6bf url(images/mBox/warning.png) 2.2em center no-repeat; border-color: #ffd324}
.warning_bbc a  {color: #817134}

.okay_bbc   {background: #e9ffdd url(images/mBox/okay.png) 2.2em center no-repeat; border-color: #72c868}
.okay_bbc a {color: #529214}

.info_bbc   {background: #e2ecee url(images/mBox/info.png) 2.2em center no-repeat; border-color: #9ddae6}
.info_bbc a {color: #2d7ba2}


/* Lists */
.error_bbc ul, .warning_bbc ul, .okay_bbc ul, .info_bbc ul {
    list-style: none;
    margin: 1.3em 1.5em
}
.error_bbc ul li, .warning_bbc ul li, .okay_bbc ul li, .info_bbc ul li {
    padding-left: 1.3em
}
.error_bbc ul li  { background: url(images/mBox/error-bullet.png)  0 0.55em no-repeat }
.warning_bbc ul li  { background: url(images/mBox/warning-bullet.png)  0 0.55em no-repeat }
.okay_bbc ul li { background: url(images/mBox/okay-bullet.png) 0 0.55em no-repeat }
.info_bbc ul li { background: url(images/mBox/info-bullet.png) 0 0.55em no-repeat }



Themes/Default/Languages Klasöründe/Modifications.teuidioma.php

Code Select
?>

Code Select
$txt['error_bbc'] = 'Adicionar caixa de erro';
$txt['warning_bbc'] = 'Adicionar Caixa de Aviso';
$txt['okay_bbc'] = 'Adicionar Caixa Ok';
$txt['info_bbc'] = 'Adicionar Caixa de Informa&ccedil;&otilde;es';



Nao esqueça de colocar a pasta "mbox" diretório ". / Themes / default / images " .
Incluído o pacote, o diretório "BBC". / Themes / default / images ".


candidosa2

Testado no smf 2.0.9 a funcionar



./Sources/Subs-Editor.php

Code Select
array(
'image' => 'ftp',
'code' => 'ftp',
'before' => '[ftp]',
'after' => '[/ftp]',
'description' => $txt['ftp']
),
array(),



Code Select
array(
'image' => 'error',
'code' => 'error',
'before' => '[error]',
'after' => '[/error]',
'description' => $txt['error_bbc']),

array(
'image' => 'warning',
'code' => 'warning',
'before' => '[warning]',
'after' => '[/warning]',
'description' => $txt['warning_bbc']),

array(
'image' => 'okay',
'code' => 'okay',
'before' => '[okay]',
'after' => '[/okay]',
'description' => $txt['okay_bbc']),

array(
'image' => 'info',
'code' => 'info',
'before' => '[info]',
'after' => '[/info]',
'description' => $txt['info_bbc']),
array(),



./Sources/Subs.php

Code Select
array(
'tag' => 'white',
'before' => '<span style="color: white;" class="bbc_color">',
'after' => '</span>',
),


Code Select
// CSS Message Boxes - grafitus
array(
'tag' => 'error',
'before' => '<div class="error_bbc">',
'after' => '</div>',
),
array(
'tag' => 'warning',
'before' => '<div class="warning_bbc">',
'after' => '</div>',
),
array(
'tag' => 'okay',
'before' => '<div class="okay_bbc">',
'after' => '</div>',
),
array(
'tag' => 'info',
'before' => '<div class="info_bbc">',
'after' => '</div>',
),



./Themes/default/css/index.css

Code Select
/* -----------------------------------------------
   C S S   M E S S A G E   B O X E S   v1.1
 
   Thanks for eBurhan
   http://www.eburhan.com/

   Thanks for famfamfam icons
   http://www.famfamfam.com/
   
   New version by SAFAD
   http://www.safadsoft.com/
-------------------------------------------------- */

.error_bbc, .warning_bbc, .okay_bbc, .info_bbc {
    margin-bottom: 1.5em;
    padding: 1em 1.5em 1em 5.5em;
    border-bottom: 2px solid #fff;
    border-top: 2px solid #fff;
    color: #444
}

.error_bbc    {background: #fbe3e4 url(../images/mBox/error.png) 2.2em center no-repeat; border-color: #e0011b}
.error_bbc a  {color: #d12f19}

.warning_bbc    {background: #fff6bf url(../images/mBox/warning.png) 2.2em center no-repeat; border-color: #ffd324}
.warning_bbc a  {color: #817134}

.okay_bbc   {background: #e9ffdd url(../images/mBox/okay.png) 2.2em center no-repeat; border-color: #72c868}
.okay_bbc a {color: #529214}

.info_bbc   {background: #e2ecee url(../images/mBox/info.png) 2.2em center no-repeat; border-color: #9ddae6}
.info_bbc a {color: #2d7ba2}


/* Lists */
.error_bbc ul, .warning_bbc ul, .okay_bbc ul, .info_bbc ul {
    list-style: none;
    margin: 1.3em 1.5em
}
.error_bbc ul li, .warning_bbc ul li, .okay_bbc ul li, .info_bbc ul li {
    padding-left: 1.3em
}
.error_bbc ul li  { background: url(../images/mBox/error-bullet.png)  0 0.55em no-repeat }
.warning_bbc ul li  { background: url(../images/mBox/warning-bullet.png)  0 0.55em no-repeat }
.okay_bbc ul li { background: url(../images/mBox/okay-bullet.png) 0 0.55em no-repeat }
.info_bbc ul li { background: url(../images/mBox/info-bullet.png) 0 0.55em no-repeat }

Go Up