Skip to content

Commit

Permalink
Removed some logging
Browse files Browse the repository at this point in the history
  • Loading branch information
knsv committed Nov 22, 2014
1 parent 20d927c commit cb58aea
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 155 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "mermaid",
"version": "0.2.1",
"version": "0.2.2",
"authors": [
"knsv <knut@sveido.com>"
],
Expand Down
13 changes: 3 additions & 10 deletions dist/mermaid.full.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/mermaid.full.min.js

Large diffs are not rendered by default.

13 changes: 3 additions & 10 deletions dist/mermaid.slim.js
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ var addEdges = function (edges, g) {
// Add the edge to the graph
if (typeof edge.text === 'undefined') {
if(typeof edge.style === 'undefined'){
g.setEdge(edge.start, edge.end,{ arrowheadStyle: "fill: #333", arrowhead: aHead},cnt);
g.setEdge(edge.start, edge.end,{ style: "stroke: #333; stroke-width: 1.5px;fill:none", arrowheadStyle: "fill: #333", arrowhead: aHead},cnt);
}else{
g.setEdge(edge.start, edge.end, {
style: edge.style, arrowheadStyle: "fill: #333", arrowhead: aHead
Expand All @@ -396,8 +396,7 @@ var addEdges = function (edges, g) {
else {

if(typeof edge.style === 'undefined'){
console.log('Edge with Text no style: '+edge.text);
g.setEdge(edge.start, edge.end,{label: edge.text, arrowheadStyle: "fill: #33f", arrowhead: aHead},cnt);
g.setEdge(edge.start, edge.end,{style: "stroke: #333; stroke-width: 1.5px;fill:none", label: edge.text, arrowheadStyle: "fill: #333", arrowhead: aHead},cnt);
}else{

g.setEdge(edge.start, edge.end, {
Expand Down Expand Up @@ -448,9 +447,6 @@ var drawChart = function (text, id) {
classes.default = {id:'default'};
classes.default.styles = ['fill:#eaeaea','stroke:#666','stroke-width:1.5px'];
}

console.log(classes);

addVertices(vert, g);
addEdges(edges, g);

Expand Down Expand Up @@ -516,7 +512,6 @@ var drawChart = function (text, id) {
* Go through the document and find the chart definitions in there and render the charts
*/
var init = function () {
console.log('Mermaid v'+exports.version()+' starting');
var arr = document.querySelectorAll('.mermaid');

var cnt = 0;
Expand All @@ -543,7 +538,7 @@ var init = function () {
* @returns {string}
*/
exports.version = function(){
return '0.2.0';
return '0.2.2';
}

var equals = function (val, variable){
Expand Down Expand Up @@ -656,7 +651,6 @@ exports.addClass = function (id, style) {
if (typeof style !== 'undefined') {
if (style !== null) {
style.forEach(function (s) {
console.log('Adding style'+s)
classes[id].styles.push(s);
});
}
Expand All @@ -676,7 +670,6 @@ exports.setDirection = function (dir) {
* @param dir
*/
exports.setClass = function (id,className) {
console.log('Got id:'+id);
if(id.indexOf(',')>0){
id.split(',').forEach(function(id2){
if(typeof vertices[id2] !== 'undefined'){
Expand Down
2 changes: 1 addition & 1 deletion dist/mermaid.slim.min.js

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions src/graphDb.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ exports.addClass = function (id, style) {
if (typeof style !== 'undefined') {
if (style !== null) {
style.forEach(function (s) {
console.log('Adding style'+s)
classes[id].styles.push(s);
});
}
Expand All @@ -92,7 +91,6 @@ exports.setDirection = function (dir) {
* @param dir
*/
exports.setClass = function (id,className) {
console.log('Got id:'+id);
if(id.indexOf(',')>0){
id.split(',').forEach(function(id2){
if(typeof vertices[id2] !== 'undefined'){
Expand Down
11 changes: 3 additions & 8 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ var addEdges = function (edges, g) {
// Add the edge to the graph
if (typeof edge.text === 'undefined') {
if(typeof edge.style === 'undefined'){
g.setEdge(edge.start, edge.end,{ arrowheadStyle: "fill: #333", arrowhead: aHead},cnt);
g.setEdge(edge.start, edge.end,{ style: "stroke: #333; stroke-width: 1.5px;fill:none", arrowheadStyle: "fill: #333", arrowhead: aHead},cnt);
}else{
g.setEdge(edge.start, edge.end, {
style: edge.style, arrowheadStyle: "fill: #333", arrowhead: aHead
Expand All @@ -99,8 +99,7 @@ var addEdges = function (edges, g) {
else {

if(typeof edge.style === 'undefined'){
console.log('Edge with Text no style: '+edge.text);
g.setEdge(edge.start, edge.end,{label: edge.text, arrowheadStyle: "fill: #33f", arrowhead: aHead},cnt);
g.setEdge(edge.start, edge.end,{style: "stroke: #333; stroke-width: 1.5px;fill:none", label: edge.text, arrowheadStyle: "fill: #333", arrowhead: aHead},cnt);
}else{

g.setEdge(edge.start, edge.end, {
Expand Down Expand Up @@ -151,9 +150,6 @@ var drawChart = function (text, id) {
classes.default = {id:'default'};
classes.default.styles = ['fill:#eaeaea','stroke:#666','stroke-width:1.5px'];
}

console.log(classes);

addVertices(vert, g);
addEdges(edges, g);

Expand Down Expand Up @@ -219,7 +215,6 @@ var drawChart = function (text, id) {
* Go through the document and find the chart definitions in there and render the charts
*/
var init = function () {
console.log('Mermaid v'+exports.version()+' starting');
var arr = document.querySelectorAll('.mermaid');

var cnt = 0;
Expand All @@ -246,7 +241,7 @@ var init = function () {
* @returns {string}
*/
exports.version = function(){
return '0.2.1';
return '0.2.2';
}

var equals = function (val, variable){
Expand Down
2 changes: 1 addition & 1 deletion src/parser/sequence.jison
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ statement

action:
SQS SQE
{console.log('#a');$$='action';}
{$$='action';}
;

actorDefinition:
Expand Down
95 changes: 0 additions & 95 deletions test/mermaid.html

This file was deleted.

26 changes: 0 additions & 26 deletions test/web.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,6 @@
<html>
<head>

<style id="css">
/* This sets the color for "TK" nodes to a light blue green. */
g.type-TK > rect {
fill: #ccffd0;
}

text {
font-weight: 300;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serf;
font-size: 14px;
}

.node rect {
stroke: #999;
fill: #fff;
stroke-width: 1.5px;
}

.edgePath path {
stroke: #333;
stroke-width: 1.5px;
fill:#fff;

}

</style>
<script src="../dist/mermaid.full.js"></script>
<scrpt>
var mermaid_config = {
Expand Down

0 comments on commit cb58aea

Please sign in to comment.