Browse Source

Added 'alert tip' support, so it's now possible to create an alert box which is green and shows 'tip' instead of info/danger/important/warning

tags/0.13
Frans Bouma 10 years ago
parent
commit
d69c9f87e9
4 changed files with 22 additions and 0 deletions
  1. +9
    -0
      Themes/Default/Destination/css/theme_colors.css
  2. +4
    -0
      src/MarkdownDeep/Block.cs
  3. +5
    -0
      src/MarkdownDeepTests/testfiles/docnetmode/Alert(DocNetMode).html
  4. +4
    -0
      src/MarkdownDeepTests/testfiles/docnetmode/Alert(DocNetMode).txt

+ 9
- 0
Themes/Default/Destination/css/theme_colors.css View File

@@ -108,6 +108,15 @@ mark {
.alert.alert-neutral a { .alert.alert-neutral a {
color: #2980B9; color: #2980B9;
} }

.alert.alert-tip {
background:#dbfaf4;
}

.alert.alert-tip .alert-title {
background:#1abc9c;
}

/* #endregion*/ /* #endregion*/


/* #region Tables*/ /* #region Tables*/


+ 4
- 0
src/MarkdownDeep/Block.cs View File

@@ -520,6 +520,10 @@ namespace MarkdownDeep
title = "Info"; title = "Info";
faIconName = "info-circle"; faIconName = "info-circle";
break; break;
case "tip":
title = "Tip";
faIconName = "info-circle";
break;
} }
b.Append("<div class=\"alert alert-"); b.Append("<div class=\"alert alert-");
b.Append(alertTypeClass); b.Append(alertTypeClass);


+ 5
- 0
src/MarkdownDeepTests/testfiles/docnetmode/Alert(DocNetMode).html View File

@@ -25,4 +25,9 @@
<p>@alert <p>@alert
This is an info text, it will be displayed in an info alert box! This is an info text, it will be displayed in an info alert box!
@end</p> @end</p>

<div class="alert alert-tip">
<span class="alert-title"><i class="fa fa-info-circle"></i>Tip</span><p>This is a tip, whether you like it or not!</p>
</div>

<p>post</p> <p>post</p>

+ 4
- 0
src/MarkdownDeepTests/testfiles/docnetmode/Alert(DocNetMode).txt View File

@@ -25,4 +25,8 @@ This is an **info text**, it will be displayed in an info alert box!
This is an info text, it will be displayed in an info alert box! This is an info text, it will be displayed in an info alert box!
@end @end


@alert tip
This is a tip, whether you like it or not!
@end

post post

Loading…
Cancel
Save