Skip to content

Commit

Permalink
Update for extended blockmark
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Pollinger committed May 22, 2018
1 parent f9e16d8 commit 75fc324
Show file tree
Hide file tree
Showing 8 changed files with 1,314 additions and 23 deletions.
554 changes: 554 additions & 0 deletions demoNewBlockmarks.html

Large diffs are not rendered by default.

554 changes: 554 additions & 0 deletions demoNewxBlockmarks.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion demoWSM.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</head>

<body>
<pre class="brush: WSM">
<pre class="brush: wsm;">
&lt;!IoRedDotOpenPage&gt;&lt;a href=&quot;&lt;%infoBackLink%&gt;&quot;&gt;BACK&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;
&lt;hr/&gt;
&lt;!IoRangeDynLink&gt;&lt;%anchorDymanic%&gt;&lt;br/&gt;&lt;!/IoRangeDynLink&gt;
Expand Down
51 changes: 51 additions & 0 deletions demoxWSM.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<html>

<head>
<script type="text/javascript" src="scripts/XRegExp.js"></script>
<script type="text/javascript" src="scripts/shCore.js"></script>
<link href="styles/shCore.css" rel="stylesheet" type="text/css" />
<link href="styles/shThemeDefault.css" rel="stylesheet" type="text/css" />

<script type="text/javascript" src="scripts/shBrushxWSM.js"></script>
<link href="styles/shCorexWSM.css" rel="stylesheet" type="text/css" />
</head>

<body>
<pre class="brush: xwsm;">
&lt;!IoRedDotOpenPage&gt;&lt;a href=&quot;&lt;%infoBackLink%&gt;&quot;&gt;BACK&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;
&lt;hr/&gt;
&lt;!IoRangeDynLink&gt;&lt;%anchorDymanic%&gt;&lt;br/&gt;&lt;!/IoRangeDynLink&gt;
&lt;%!! Store:Get(test) !!%&gt;
&lt;li&gt;
&lt;!-- Render link to the current index page --&gt;
&lt;a href=&quot;&lt;%!! Context:CurrentIndex.GetUrl() !!%&gt;&quot;&gt;
&lt;%!! Context:CurrentIndex.Page.Headline !!%&gt;
&lt;/a&gt;
&lt;reddot:cms&gt;
&lt;if&gt;
If the current index has child pages
&lt;query valuea=&quot;Context:CurrentIndex.HasChildren()&quot; operator=&quot;==&quot; valueb=&quot;Bool:True&quot;&gt;
&lt;htmltext&gt;
&lt;!-- Render list and call next level --&gt;
&lt;ul&gt;
&lt;navigation:nextlevel&gt;
&lt;/ul&gt;
&lt;/htmltext&gt;
&lt;/query&gt;
&lt;/if&gt;
&lt;/reddot:cms&gt;
&lt;/li&gt;
&lt;reddot:cms&gt;
&lt;foreach itemname=&quot;item&quot; object=&quot;Context:CurrentPage.Elements&quot; countername=&quot;counter&quot;&gt;
&lt;output type=&quot;object&quot; object=&quot;Store:counter&quot; /&gt;
&lt;output type=&quot;object&quot; object=&quot;Store:item.Name&quot; /&gt;
&lt;output type=&quot;object&quot; object=&quot;Escape:Br&quot; /&gt;
&lt;/foreach&gt;
&lt;/reddot:cms&gt;
</pre>
<script type='text/javascript'>
SyntaxHighlighter.all();
</script>
</body>

</html>
34 changes: 17 additions & 17 deletions scripts/shBrushWSM.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
SyntaxHighlighter.brushes.Custom = function () {
SyntaxHighlighter.brushes.wsm = function () {
this.regexList = [
{ regex: /&lt;%([^!])+?%&gt;/gm, css: 'placeholder' },
{ regex: /&lt;!(\/?)IoRange(.+?)&gt;/gm, css: 'blockmark' },
{ regex: /&lt;!IoRedDot(.+?)&gt;/gm, css: 'smartedit-wsm' },
{ regex: /&lt;%!!(.+?)!!%&gt;/gm, css: 'rendertag-short' },
{ regex: /&lt;(\/?)reddot:cms&gt;/gm, css: 'rendertag' },
{ regex: /&lt;navigation(.*?)&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)output(.*?)&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)foreach(.*?)&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)if&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)query(.*?)&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)htmltext&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)xmltext&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)currentPageCommentCount(.*?)&gt;/gm, css: 'rendertag' },
{ regex: /&lt;(\/?)pagesMostCommented(.*?)&gt;/gm, css: 'rendertag' }
{ regex: /&lt;%([^!])+?%&gt;/gm, css: 'wsm-placeholder' },
{ regex: /&lt;!(\/?)IoRange(.+?)&gt;/gm, css: 'wsm-blockmark' },
{ regex: /&lt;!IoRedDot(.+?)&gt;/gm, css: 'wsm-smartedit' },
{ regex: /&lt;%!!(.+?)!!%&gt;/gm, css: 'wsm-rendertag-short' },
{ regex: /&lt;(\/?)reddot:cms&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;navigation(.*?)&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)output(.*?)&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)foreach(.*?)&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)if&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)query(.*?)&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)htmltext&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)xmltext&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)currentPageCommentCount(.*?)&gt;/gm, css: 'wsm-rendertag' },
{ regex: /&lt;(\/?)pagesMostCommented(.*?)&gt;/gm, css: 'wsm-rendertag' }
];
};
SyntaxHighlighter.brushes.Custom.prototype = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Custom.aliases = ['WSM'];
SyntaxHighlighter.brushes.wsm.prototype = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.wsm.aliases = ['wsm','ms'];
64 changes: 64 additions & 0 deletions scripts/shBrushxWSM.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
SyntaxHighlighter.brushes.xwsm = function () {
this.regexList = [
{ regex: /&lt;%([^!])+?%&gt;/gm, css: 'xplaceholder' },
{ regex: /&lt;!(\/?)IoRangeNavigation&gt;/gm, css: 'xblockmark-navigation' },
{ regex: /&lt;!(\/?)IoRangeNavigationArea&gt;/gm, css: 'xblockmark-navigation' },
{ regex: /&lt;!(\/?)IoRangeIf&gt;/gm, css: 'xblockmark-condition' },
{ regex: /&lt;!(\/?)IoRangeIfExists&gt;/gm, css: 'xblockmark-condition' },
{ regex: /&lt;!(\/?)IoRangeSwitch&gt;/gm, css: 'xblockmark-condition' },
{ regex: /&lt;!(\/?)IoRangeConstraint&gt;/gm, css: 'xblockmark-constraint' },
{ regex: /&lt;!(\/?)IoRangeThen&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeElse&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeCase&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeFor&gt;/gm, css: 'xblockmark-loop' },
{ regex: /&lt;!(\/?)IoRangeForEach&gt;/gm, css: 'xblockmark-loop' },
{ regex: /&lt;!(\/?)IoRangeDo&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeComment&gt;/gm, css: 'xblockmark-comment' },
{ regex: /&lt;!(\/?)IoRangeDocumentation&gt;/gm, css: 'xblockmark-comment' },
{ regex: /&lt;!(\/?)IoRangeNoOutput&gt;/gm, css: 'xblockmark-comment' },
{ regex: /&lt;!(\/?)IoRangeImageList&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeInclude&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangeMath&gt;/gm, css: 'xblockmark-math' },
{ regex: /&lt;!(\/?)IoRangePreDefinition&gt;/gm, css: 'xblockmark-special' },
{ regex: /&lt;!(\/?)IoRangeTemp&gt;/gm, css: 'xblockmark-special' },
{ regex: /&lt;!(\/?)IoRangeSession&gt;/gm, css: 'xblockmark-special' },
{ regex: /&lt;!(\/?)IoRangeUiSession&gt;/gm, css: 'xblockmark-special' },
{ regex: /&lt;!(\/?)IoRangePreviewMode&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangeEditMode&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangeEditModeOn&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangeEditModeOff&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangePublishMode&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangeRDExecute&gt;/gm, css: 'xblockmark-rendermode' },
{ regex: /&lt;!(\/?)IoRangePreExecute&gt;/gm, css: 'xblockmark-rendermode' },

{ regex: /&lt;!(\/?)IoRangeBlocktyp&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeBack&gt;/gm, css: 'xblockmark-navigation' },
{ regex: /&lt;!(\/?)IoRangeBreadCrumb&gt;/gm, css: 'xblockmark-navigation' },
{ regex: /&lt;!(\/?)IoRangeConditional&gt;/gm, css: 'xblockmark-condition' },
{ regex: /&lt;!(\/?)IoRangeData&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeDragDrop&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeDynLink&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeHit&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeList&gt;/gm, css: 'xblockmark-loop' },
{ regex: /&lt;!(\/?)IoRangeRedDotMode&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeNoRedDotMode&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeRedDotEditOnly&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!(\/?)IoRangeNoEditMode&gt;/gm, css: 'xblockmark' },

{ regex: /&lt;!(\/?)IoRangeX(.+?)&gt;/gm, css: 'xblockmark' },
{ regex: /&lt;!IoRedDot(.+?)&gt;/gm, css: 'xsmartedit-wsm' },
{ regex: /&lt;%!!(.+?)!!%&gt;/gm, css: 'xrendertag-short' },
{ regex: /&lt;(\/?)reddot:cms&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;navigation(.*?)&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)output(.*?)&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)foreach(.*?)&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)if&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)query(.*?)&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)htmltext&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)xmltext&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)currentPageCommentCount(.*?)&gt;/gm, css: 'xrendertag' },
{ regex: /&lt;(\/?)pagesMostCommented(.*?)&gt;/gm, css: 'xrendertag' }
];
};
SyntaxHighlighter.brushes.xwsm.prototype = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.xwsm.aliases = ['xwsm','xms'];
10 changes: 5 additions & 5 deletions styles/shCoreWSM.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,27 @@
line-height: 1.2em !important;
}

.syntaxhighlighter .placeholder {
.syntaxhighlighter .wsm-placeholder {
color: #000000 !important;
background-color: #ffff80 !important;
}

.syntaxhighlighter .blockmark {
.syntaxhighlighter .wsm-blockmark {
color: #008800 !important;
background-color: #ccffcc !important;
}

.syntaxhighlighter .smartedit-wsm {
.syntaxhighlighter .wsm-smartedit {
color: #ff0000 !important;
background-color: #ffe5e5 !important;
}

.syntaxhighlighter .rendertag {
.syntaxhighlighter .wsm-rendertag {
color: #197674 !important;
background-color: #ccf0ff !important;
}

.syntaxhighlighter .rendertag-short {
.syntaxhighlighter .wsm-rendertag-short {
color: #000000 !important;
background-color: #ccf0ff !important;
}
68 changes: 68 additions & 0 deletions styles/shCorexWSM.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
.syntaxhighlighter a, .syntaxhighlighter div, .syntaxhighlighter code, .syntaxhighlighter table, .syntaxhighlighter table td, .syntaxhighlighter table tr, .syntaxhighlighter table tbody, .syntaxhighlighter table thead, .syntaxhighlighter table caption, .syntaxhighlighter textarea {
line-height: 1.2em !important;
}

.syntaxhighlighter .xplaceholder {
color: #000000 !important;
background-color: #ffff80 !important;
}

.syntaxhighlighter .xblockmark {
color: #008800 !important;
background-color: #ccffcc !important;
}

.syntaxhighlighter .xblockmark-comment {
color: #000000 !important;
background-color: #d8d8d8 !important;
}

.syntaxhighlighter .xblockmark-condition {
color: #8a4b08 !important;
background-color: #f5d0a9 !important;
}

.syntaxhighlighter .xblockmark-loop {
color: #886a08 !important;
background-color: #f3e2a9 !important;
}

.syntaxhighlighter .xblockmark-constraint {
color: #8a2908 !important;
background-color: #f5bca9 !important;
}

.syntaxhighlighter .xblockmark-navigation {
color: #197674 !important;
background-color: #ccf0ff !important;
}

.syntaxhighlighter .xblockmark-rendermode {
color: #08088a !important;
background-color: #cecef6 !important;
}

.syntaxhighlighter .xblockmark-math {
color: #8a0808 !important;
background-color: #f8e0e0 !important;
}

.syntaxhighlighter .xblockmark-special {
color: #610b5e !important;
background-color: #f6cef5 !important;
}

.syntaxhighlighter .xsmartedit-wsm {
color: #ff0000 !important;
background-color: #ffe5e5 !important;
}

.syntaxhighlighter .xrendertag {
color: #197674 !important;
background-color: #ccf0ff !important;
}

.syntaxhighlighter .xrendertag-short {
color: #000000 !important;
background-color: #ccf0ff !important;
}

0 comments on commit 75fc324

Please sign in to comment.