Style CSS (lien hypertexte) en javascript
Bonjour,
J'ai récemment mis en place un wysiwyg (ckeditor) pour un projet perso, à l'intérieur duquel je souhaite mettre des styles de texte prédéfinis, façon CSS.
J'ai bien réussi à implémenter mes styles de texte simples pour le menu déroulant de l'éditeur, ce qui ressemble à ça :
Code:
1 2 3 4
| CKEDITOR.stylesSet.add( 'my_styles',
[
{ name : 'texte', element : 'text', styles : { 'color' : '#FFFFFF', 'font-family' : 'Verdana', 'font-size' : '11px', 'font-style' : 'normal', 'font-weight' : 'normal', 'font-variant' : 'normal', 'text-decoration' : 'none' } }
]); |
Cependant, je n'arrive pas à implémenter mes styles relatifs aux liens hypertextes, qui en CSS ressemblent à ça :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
| a.menu:link {
font-family: Verdana;
font-size: 12px;
font-style: normal;
line-height: normal;
font-weight: bold;
font-variant: normal;
text-transform: Aucune;
color: #FFFFFF;
text-decoration: none;
}
a.menu:visited {
font-family: Verdana;
font-size: 12px;
font-style: normal;
line-height: normal;
font-weight: bold;
font-variant: normal;
text-transform: Aucune;
color: #FFFFFF;
text-decoration: none;
}
a.menu:hover {
font-family: Verdana;
font-size: 12px;
font-style: normal;
line-height: normal;
font-weight: bold;
font-variant: normal;
text-transform: Aucune;
color: #cc0000;
text-decoration: none;
}
a.menu:active {
font-family: Verdana;
font-size: 12px;
font-style: normal;
line-height: normal;
font-weight: bold;
font-variant: normal;
text-transform: Aucune;
color: #cc0000;
text-decoration: none;
} |
Quelqu'un aurait-il déjà rencontré ce problème, et serait à même de m'aider, ou me proposer un lien qui traite du sujet ? Mon ami Google n'arrive pas à m'aider, quant à Chuck Norris, j'ai perdu son numéro :)
Merci !