Skip to content

Commit

Permalink
New release
Browse files Browse the repository at this point in the history
  • Loading branch information
knsv committed Jun 21, 2015
1 parent 50219cf commit 0dc983d
Show file tree
Hide file tree
Showing 13 changed files with 125 additions and 62 deletions.
12 changes: 8 additions & 4 deletions dist/mermaid.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
stroke: #333333;
}
.cluster rect {
fill: #ffffde;
rx: 40;
stroke: #aaaa33;
stroke-width: 1px;
fill: #ffffde !important;
rx: 4 !important;
stroke: #aaaa33 !important;
stroke-width: 1px !important;
}
.cluster text {
fill: #333333;
Expand Down Expand Up @@ -254,3 +254,7 @@ text {
font-family: 'trebuchet ms', verdana, arial;
font-size: 14px;
}

.mermaid {
width:1200px;
}
8 changes: 4 additions & 4 deletions dist/mermaid.forest.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@
stroke-width: 1.5px;
}
.cluster rect {
fill: #cdffb2;
rx: 4;
stroke: #6eaa49;
stroke-width: 1px;
fill: #cdffb2 !important;
rx: 4 !important;
stroke: #6eaa49 !important;
stroke-width: 1px !important;
}
.cluster text {
fill: #333333;
Expand Down
28 changes: 21 additions & 7 deletions dist/mermaid.js
Original file line number Diff line number Diff line change
Expand Up @@ -24950,7 +24950,7 @@ process.chdir = function (dir) {
},{}],86:[function(require,module,exports){
module.exports={
"name": "mermaid",
"version": "0.5.0",
"version": "0.5.1",
"description": "Markdownish syntax for generating flowcharts, sequence diagrams and gantt charts.",
"main": "src/mermaid.js",
"keywords": [
Expand Down Expand Up @@ -25035,7 +25035,7 @@ module.exports={
"marked": "^0.3.2",
"mock-browser": "^0.90.27",
"path": "^0.4.9",
"phantomjs": "^1.9.12",
"phantomjs": "^1.9.17",
"proxyquire": "^1.3.1",
"require-dir": "^0.3.0",
"rewire": "^2.1.3",
Expand Down Expand Up @@ -26467,6 +26467,7 @@ exports.getClasses = function (text, isDot) {
if(typeof(classes.default) === 'undefined') {
classes.default = {id:'default'};
classes.default.styles = ['fill:#ffa','stroke:#666','stroke-width:3px'];
classes.default.clusterStyles = ['rx:4px','fill: rgb(255, 255, 222)','rx: 4px','stroke: rgb(170, 170, 51)','stroke-width: 1px'];
classes.default.nodeLabelStyles = ['fill:#000','stroke:none','font-weight:300','font-family:"Helvetica Neue",Helvetica,Arial,sans-serf','font-size:14px'];
classes.default.edgeLabelStyles = ['fill:#000','stroke:none','font-weight:300','font-family:"Helvetica Neue",Helvetica,Arial,sans-serf','font-size:14px'];
}
Expand Down Expand Up @@ -28800,7 +28801,7 @@ var getStartDate = function(prevTime, dateFormat, str){
}else{
console.log('Invalid date:'+str);
console.log('With date format:'+dateFormat.trim());
console.log('----');
//console.log('----');
}

// Default date - now
Expand Down Expand Up @@ -28978,16 +28979,18 @@ var w;
module.exports.draw = function (text, id) {
gantt.yy.clear();
gantt.parse(text);

var elem = document.getElementById(id);
w = elem.parentElement.offsetWidth;

console.log('id='+id,' w='+w);
console.log(elem.parentElement);

if (typeof w === 'undefined') {
w = 1200;
}

if(typeof conf.useWidth !== 'undefined'){
w = conf.useWidth;
}

var taskArray = gantt.yy.getTasks();

// Set height based on number of tasks
Expand Down Expand Up @@ -29035,6 +29038,10 @@ module.exports.draw = function (text, id) {


makeGant(taskArray, w, h);
if(typeof conf.useWidth !== 'undefined'){
elem.setAttribute('width', w);

}

var title = svg.append("text")
.text(gantt.yy.getTitle())
Expand Down Expand Up @@ -31096,7 +31103,6 @@ var drawMessage = function(elem, startx, stopx, verticalPos, msg){
textWidth = textElem[0][0].getBBox().width;
}
else{
console.log(textElem[0][0].getBoundingClientRect());
//textWidth = getBBox(textElem).width; //.getComputedTextLength()
textWidth = textElem[0][0].getBoundingClientRect();
//textWidth = textElem[0][0].getComputedTextLength();
Expand Down Expand Up @@ -31597,8 +31603,13 @@ var init = function () {

if(typeof mermaid_config !== 'undefined'){
mermaidAPI.initialize(mermaid_config);

}

if(typeof mermaid.ganttConfig !== 'undefined'){
mermaidAPI.initialize({gantt:mermaid.ganttConfig});
}

var insertSvg = function(svgCode){
element.innerHTML = svgCode;
};
Expand Down Expand Up @@ -32084,6 +32095,9 @@ module.exports.cloneCssStyles = function(svg, classes){
if (classes.default.edgeLabelStyles instanceof Array) {
defaultStyles += "#" + svg.id.trim() + ' .edgeLabel text ' + ' { ' + classes[className].edgeLabelStyles.join("; ") + '; }\n';
}
if (classes.default.clusterStyles instanceof Array) {
defaultStyles += "#" + svg.id.trim() + ' .cluster rect ' + ' { ' + classes[className].clusterStyles.join("; ") + '; }\n';
}
} else {
if (classes[className].styles instanceof Array) {
embeddedStyles += "#" + svg.id.trim() + ' .' + className + ' { ' + classes[className].styles.join("; ") + '; }\n';
Expand Down
6 changes: 3 additions & 3 deletions dist/mermaid.min.js

Large diffs are not rendered by default.

28 changes: 21 additions & 7 deletions dist/mermaid.slim.js
Original file line number Diff line number Diff line change
Expand Up @@ -15734,7 +15734,7 @@ process.chdir = function (dir) {
},{}],85:[function(require,module,exports){
module.exports={
"name": "mermaid",
"version": "0.5.0",
"version": "0.5.1",
"description": "Markdownish syntax for generating flowcharts, sequence diagrams and gantt charts.",
"main": "src/mermaid.js",
"keywords": [
Expand Down Expand Up @@ -15819,7 +15819,7 @@ module.exports={
"marked": "^0.3.2",
"mock-browser": "^0.90.27",
"path": "^0.4.9",
"phantomjs": "^1.9.12",
"phantomjs": "^1.9.17",
"proxyquire": "^1.3.1",
"require-dir": "^0.3.0",
"rewire": "^2.1.3",
Expand Down Expand Up @@ -17251,6 +17251,7 @@ exports.getClasses = function (text, isDot) {
if(typeof(classes.default) === 'undefined') {
classes.default = {id:'default'};
classes.default.styles = ['fill:#ffa','stroke:#666','stroke-width:3px'];
classes.default.clusterStyles = ['rx:4px','fill: rgb(255, 255, 222)','rx: 4px','stroke: rgb(170, 170, 51)','stroke-width: 1px'];
classes.default.nodeLabelStyles = ['fill:#000','stroke:none','font-weight:300','font-family:"Helvetica Neue",Helvetica,Arial,sans-serf','font-size:14px'];
classes.default.edgeLabelStyles = ['fill:#000','stroke:none','font-weight:300','font-family:"Helvetica Neue",Helvetica,Arial,sans-serf','font-size:14px'];
}
Expand Down Expand Up @@ -19584,7 +19585,7 @@ var getStartDate = function(prevTime, dateFormat, str){
}else{
console.log('Invalid date:'+str);
console.log('With date format:'+dateFormat.trim());
console.log('----');
//console.log('----');
}

// Default date - now
Expand Down Expand Up @@ -19762,16 +19763,18 @@ var w;
module.exports.draw = function (text, id) {
gantt.yy.clear();
gantt.parse(text);

var elem = document.getElementById(id);
w = elem.parentElement.offsetWidth;

console.log('id='+id,' w='+w);
console.log(elem.parentElement);

if (typeof w === 'undefined') {
w = 1200;
}

if(typeof conf.useWidth !== 'undefined'){
w = conf.useWidth;
}

var taskArray = gantt.yy.getTasks();

// Set height based on number of tasks
Expand Down Expand Up @@ -19819,6 +19822,10 @@ module.exports.draw = function (text, id) {


makeGant(taskArray, w, h);
if(typeof conf.useWidth !== 'undefined'){
elem.setAttribute('width', w);

}

var title = svg.append("text")
.text(gantt.yy.getTitle())
Expand Down Expand Up @@ -21880,7 +21887,6 @@ var drawMessage = function(elem, startx, stopx, verticalPos, msg){
textWidth = textElem[0][0].getBBox().width;
}
else{
console.log(textElem[0][0].getBoundingClientRect());
//textWidth = getBBox(textElem).width; //.getComputedTextLength()
textWidth = textElem[0][0].getBoundingClientRect();
//textWidth = textElem[0][0].getComputedTextLength();
Expand Down Expand Up @@ -22381,8 +22387,13 @@ var init = function () {

if(typeof mermaid_config !== 'undefined'){
mermaidAPI.initialize(mermaid_config);

}

if(typeof mermaid.ganttConfig !== 'undefined'){
mermaidAPI.initialize({gantt:mermaid.ganttConfig});
}

var insertSvg = function(svgCode){
element.innerHTML = svgCode;
};
Expand Down Expand Up @@ -22868,6 +22879,9 @@ module.exports.cloneCssStyles = function(svg, classes){
if (classes.default.edgeLabelStyles instanceof Array) {
defaultStyles += "#" + svg.id.trim() + ' .edgeLabel text ' + ' { ' + classes[className].edgeLabelStyles.join("; ") + '; }\n';
}
if (classes.default.clusterStyles instanceof Array) {
defaultStyles += "#" + svg.id.trim() + ' .cluster rect ' + ' { ' + classes[className].clusterStyles.join("; ") + '; }\n';
}
} else {
if (classes[className].styles instanceof Array) {
embeddedStyles += "#" + svg.id.trim() + ' .' + className + ' { ' + classes[className].styles.join("; ") + '; }\n';
Expand Down
6 changes: 3 additions & 3 deletions dist/mermaid.slim.min.js

Large diffs are not rendered by default.

23 changes: 16 additions & 7 deletions dist/mermaidAPI.js
Original file line number Diff line number Diff line change
Expand Up @@ -24617,7 +24617,7 @@ process.chdir = function (dir) {
},{}],85:[function(require,module,exports){
module.exports={
"name": "mermaid",
"version": "0.5.0",
"version": "0.5.1",
"description": "Markdownish syntax for generating flowcharts, sequence diagrams and gantt charts.",
"main": "src/mermaid.js",
"keywords": [
Expand Down Expand Up @@ -24702,7 +24702,7 @@ module.exports={
"marked": "^0.3.2",
"mock-browser": "^0.90.27",
"path": "^0.4.9",
"phantomjs": "^1.9.12",
"phantomjs": "^1.9.17",
"proxyquire": "^1.3.1",
"require-dir": "^0.3.0",
"rewire": "^2.1.3",
Expand Down Expand Up @@ -26134,6 +26134,7 @@ exports.getClasses = function (text, isDot) {
if(typeof(classes.default) === 'undefined') {
classes.default = {id:'default'};
classes.default.styles = ['fill:#ffa','stroke:#666','stroke-width:3px'];
classes.default.clusterStyles = ['rx:4px','fill: rgb(255, 255, 222)','rx: 4px','stroke: rgb(170, 170, 51)','stroke-width: 1px'];
classes.default.nodeLabelStyles = ['fill:#000','stroke:none','font-weight:300','font-family:"Helvetica Neue",Helvetica,Arial,sans-serf','font-size:14px'];
classes.default.edgeLabelStyles = ['fill:#000','stroke:none','font-weight:300','font-family:"Helvetica Neue",Helvetica,Arial,sans-serf','font-size:14px'];
}
Expand Down Expand Up @@ -28467,7 +28468,7 @@ var getStartDate = function(prevTime, dateFormat, str){
}else{
console.log('Invalid date:'+str);
console.log('With date format:'+dateFormat.trim());
console.log('----');
//console.log('----');
}

// Default date - now
Expand Down Expand Up @@ -28645,16 +28646,18 @@ var w;
module.exports.draw = function (text, id) {
gantt.yy.clear();
gantt.parse(text);

var elem = document.getElementById(id);
w = elem.parentElement.offsetWidth;

console.log('id='+id,' w='+w);
console.log(elem.parentElement);

if (typeof w === 'undefined') {
w = 1200;
}

if(typeof conf.useWidth !== 'undefined'){
w = conf.useWidth;
}

var taskArray = gantt.yy.getTasks();

// Set height based on number of tasks
Expand Down Expand Up @@ -28702,6 +28705,10 @@ module.exports.draw = function (text, id) {


makeGant(taskArray, w, h);
if(typeof conf.useWidth !== 'undefined'){
elem.setAttribute('width', w);

}

var title = svg.append("text")
.text(gantt.yy.getTitle())
Expand Down Expand Up @@ -30763,7 +30770,6 @@ var drawMessage = function(elem, startx, stopx, verticalPos, msg){
textWidth = textElem[0][0].getBBox().width;
}
else{
console.log(textElem[0][0].getBoundingClientRect());
//textWidth = getBBox(textElem).width; //.getComputedTextLength()
textWidth = textElem[0][0].getBoundingClientRect();
//textWidth = textElem[0][0].getComputedTextLength();
Expand Down Expand Up @@ -31572,6 +31578,9 @@ module.exports.cloneCssStyles = function(svg, classes){
if (classes.default.edgeLabelStyles instanceof Array) {
defaultStyles += "#" + svg.id.trim() + ' .edgeLabel text ' + ' { ' + classes[className].edgeLabelStyles.join("; ") + '; }\n';
}
if (classes.default.clusterStyles instanceof Array) {
defaultStyles += "#" + svg.id.trim() + ' .cluster rect ' + ' { ' + classes[className].clusterStyles.join("; ") + '; }\n';
}
} else {
if (classes[className].styles instanceof Array) {
embeddedStyles += "#" + svg.id.trim() + ' .' + className + ' { ' + classes[className].styles.join("; ") + '; }\n';
Expand Down

0 comments on commit 0dc983d

Please sign in to comment.