Skip to content
This repository has been archived by the owner on Dec 28, 2022. It is now read-only.

Commit

Permalink
refactor: less and bullet
Browse files Browse the repository at this point in the history
- use `&` instead of repeat `.markup`
- fix font smoothing
  • Loading branch information
ldez committed Apr 14, 2016
1 parent 4d4b51f commit 8beec1d
Showing 1 changed file with 42 additions and 36 deletions.
78 changes: 42 additions & 36 deletions styles/asciidoc.atom-text-editor.less
Original file line number Diff line number Diff line change
Expand Up @@ -5,55 +5,61 @@
atom-text-editor, :host {
.asciidoc {

.markup.bold {
font-weight: bold;
}
.markup{
-webkit-font-smoothing: auto;

.markup.italic {
font-style: italic;
}
&.bold {
font-weight: bold;
}

.markup.url {
color: mix(red, @syntax-text-color, 20%);
}
&.italic {
font-style: italic;
}

.markup.htmlentity {
font-style: italic;
color: mix(red, @syntax-text-color, 20%);
}
&.url {
color: mix(red, @syntax-text-color, 20%);
}

.markup.biblioref,
.markup.blockid {
font-weight: bold;
color: mix(green, @syntax-text-color, 20%);
}
&.htmlentity {
font-style: italic;
color: mix(red, @syntax-text-color, 20%);
}

.markup.reference {
font-style: italic;
color: mix(green, @syntax-text-color, 20%);
}
&.biblioref,
&.blockid {
font-weight: bold;
color: mix(green, @syntax-text-color, 20%);
}

&.reference {
font-style: italic;
color: mix(green, @syntax-text-color, 20%);
}

&.admonition,
&.explicit,
&.heading,
&.section {
font-weight: bold;

.markup.admonition,
.markup.explicit,
.markup.heading,
.markup.section {
font-weight: bold;
// Lighten headers for dark themes.
& when (lightness(@syntax-background-color) < 50%){
color: lighten(@syntax-text-color, 20%);
}

// Lighten headers for dark themes.
& when (lightness(@syntax-background-color) < 50%){
color: lighten(@syntax-text-color, 20%);
// Darken headers for light themes.
& when (lightness(@syntax-background-color) > 50%){
color: darken(@syntax-text-color, 20%);
}
}

// Darken headers for light themes.
& when (lightness(@syntax-background-color) > 50%){
color: darken(@syntax-text-color, 20%);
&.heading.blocktitle,
&.substitution{
color: @syntax-text-color-unobtrusive;
}
}

.block,
.markup.heading.blocktitle,
.markup.list.bullet,
.markup.substitution,
.table.spec {
color: @syntax-text-color-unobtrusive;
}
Expand Down

0 comments on commit 8beec1d

Please sign in to comment.