Coder Social home page Coder Social logo

flowchartjs's People

Contributors

ghbore avatar lprobsth avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

flowchartjs's Issues

Image in Dokuwiki too small

When I do a Flowchart in Dokuwiki the size of the result ist very small.
<flowchartjs default> st=>start: Start|past:>http://www.google.com[blank] e=>end: End|future:>http://www.google.com op1=>operation: My Operation|past op2=>operation: Stuff|current sub1=>subroutine: My Subroutine|invalid cond=>condition: Yes or No?|approved:>http://www.google.com c2=>condition: Good idea|rejected io=>inputoutput: catch something...|future st->op1(right)->cond cond(yes, right)->c2 cond(no)->sub1(left)->op1 c2(yes)->io->e c2(no)->op2->e </flowchartjs>

wrong url for style

Thanks for a supernice plugin! I had to make a small edit to it to make it work for me though.

I installed the flowchartjs plugin on Synology Diskstation. Tried your example, and got no styles on diagram (no fills, uniform std font, all black lines). On inspection it turns out I have a 404: Failed to load resource: the server responded with a status of 404 (Not Found).

It tries to access http://mytestsite:9000/lib/plugins/flowchartjs/styles/default.json (9000 is a redirect port I'm using)

this requested URL does indeed not exist on my server.

So I go into your script.js and I find what loads the style:

function draw1style (style, callback){
jQuery.ajax('/lib/plugins/flowchartjs/styles/' + style + '.json', {dataType: 'json'})
.done(function(d){
callback(d);
})
.fail(function(j, s, e){
callback(null);
});
}

I remove the initial slash in the ajax call URL so I now have:
...
jQuery.ajax('lib/plugins/flowchartjs/styles/' + style + '.json', {dataType: 'json'})
...

And now it works like a charm.

I have no idea if or how the current script works on other platforms, but I am absolutely no expert.

Anyway, thought you should know.

regards

Ingvar

Inner links inside nodes not working.

Hi,

I'm trying to add an inner link to the flowchart, but it doesn't work.

<flowchartjs default>

st=>start: start:>documentation:start

ed=>end: Acepta

st->ed

</flowchartjs>

I don't know if it's possible or am I doing something wrong.

Thank you,

Franz Jimeno

Flowcharts not working with Igor

I upgraded my Dokuwiki installation to Igor and it resulted in flowcharts not loading. I rolled back to Hogfather and flowcharts are working once again. It would be great if whatever adjustments are required for compatibility with Igor could be made.

Flowcharts not wroking on DokuWiki 2020-07-29 "Hogfather"

I installed this plug in for DokuWiki 2020-07-29 "Hogfather" (local installation)

I tried syntax for
image

<flowchartjs default>
  st=>start: Start|past:>http://www.google.com[blank]
  e=>end: End|future:>http://www.google.com
  op1=>operation: My Operation|past
  op2=>operation: Stuff|current
  sub1=>subroutine: My Subroutine|invalid
  cond=>condition: Yes
  or No?|approved:>http://www.google.com
  c2=>condition: Good idea|rejected
  io=>inputoutput: catch something...|future
  st->op1(right)->cond
  cond(yes, right)->c2
  cond(no)->sub1(left)->op1
  c2(yes)->io->e
  c2(no)->op2->e
</flowchartjs>

After safe I got and no flow is rendering:

<p>st&rArr;start: Start|past:&gt;<a class="urlextern" href="http://www.google.com[blank]" rel="ugc nofollow" title="http://www.google.com[blank]">http://www.google.com[blank]</a></p>

<pre class="code">
e=&gt;end: End|future:&gt;http://www.google.com
op1=&gt;operation: My Operation|past
op2=&gt;operation: Stuff|current
sub1=&gt;subroutine: My Subroutine|invalid
cond=&gt;condition: Yes
or No?|approved:&gt;http://www.google.com
c2=&gt;condition: Good idea|rejected
io=&gt;inputoutput: catch something...|future
st-&gt;op1(right)-&gt;cond
cond(yes, right)-&gt;c2
cond(no)-&gt;sub1(left)-&gt;op1
c2(yes)-&gt;io-&gt;e
c2(no)-&gt;op2-&gt;e

</pre>

Also there is no "FC" in the toolbar

PHP 7.0 compliance

Warning: Declaration of syntax_plugin_flowchartjs::handle($match, $state, $pos, $handler) should be compatible with DokuWiki_Syntax_Plugin::handle($match, $state, $pos, Doku_Handler $handler) in /volume1/web/dokuwiki/lib/plugins/flowchartjs/syntax.php on line 0

Warning: Declaration of syntax_plugin_flowchartjs::render($mode, $renderer, $data) should be compatible with DokuWiki_Syntax_Plugin::render($format, Doku_Renderer $renderer, $data) in /volume1/web/dokuwiki/lib/plugins/flowchartjs/syntax.php on line 0

To fix this please change in syntax.php line 30 to:
function handle($match, $state, $pos, Doku_Handler $handler){

and line 41 to:
function render($mode, Doku_Renderer $renderer, $data) {

compatibility to dw2pdf?

Not a bug report, but a feature request: Could you make it possible to export the flow chart from dw to pdf for example over dw2pdf?

Applying styles

The plugin is awesome and much appreciated, and does produce the flowchart.
But I can't get the styles from the JSON files to be applied.
I've checked and it is valid json in the .\lib\plugins\flowchartjs\styles folder with, what appear to be, the correct permmissions.
I copied the default and uploaded it as other and it does show in the page editor Fs/c button.
Using the sample below I would expect the nodes to be colour coded, but they are just white.
Changing any of the other.json global entries, e.g. "font-color", has no effect.
<flowchartjs other>
st=>start: Start|past:>http://www.google.com[blank]
e=>end: End|future:>http://www.google.com
op1=>operation: My Operation|past
op2=>operation: Stuff|current
sub1=>subroutine: My Subroutine|invalid
cond=>condition: Yes
or No?|approved:>http://www.google.com
c2=>condition: Good idea|rejected
io=>inputoutput: catch something...|future
st->op1(right)->cond
cond(yes, right)->c2
cond(no)->sub1(left)->op1
c2(yes)->io->e
c2(no)->op2->e

cond@>sub1({"stroke":"Red","stroke-width":2,"arrow-end":"classic-wide-long"})
c2@>op2({"stroke":"Red","stroke-width":2,"arrow-end":"classic-wide-long"})
cond@>c2({"stroke":"Green","stroke-width":2,"arrow-end":"classic-wide-long"})
c2@>io({"stroke":"Green","stroke-width":2,"arrow-end":"classic-wide-long"})
</flowchartjs>
opera_2018-11-08_16-34-06

Why this plugin dosen't work in my dokuwiki?

I install the plugin to my dokuwiki successfully. But it dosen't work. I copied the code same as your example. After I submitted, page show a block of source code, not the flowchat view.

Can the size of the generated chart been adapted to the dokuwiki width?

Hi
the generated chart does not care about the view width of the surrounding dokuwiki page, so whenever it exceeds the view width, it becomes partly invisible and so lost its sense :-(

Could it be made somehow that the chart is somehow "squeezed" into the available width and becomes fully visible, just smaller?

thanks for your help :-)

regards
Steffen
image

Direction Indicators not Always Honored

I've got a flowchart that renders properly when I paste the text definition in at http://flowchart.js.org/, but when I plug the exact same text in on my Dokuwiki site, one of the direction indicators is being ignored and results in an ugly flowchart.

The relevant connector definition is as follows:

cnPassInspect(yes,left)->opMoveToStock->end
cnPassInspect(no)->opMoveMRB->opNotifyBuyer(left)->end

Below are screenshots showing the relevant node and how the connectors are being rendered in my Dokuwiki (1st image) compared to flowcharts.js.org (2nd image.)

bad
good

Do you have any ideas as to what the problem is and how I can correct this?

Thanks for building this plugin and for any assistance you can provide with this issue.

Warnings after Dokuwiki Install

I'm getting Warnings when I install your plugin on my Dokuwiki. They appear on other pages too.

`Warning: Declaration of syntax_plugin_flowchartjs::handle($match, $state, $pos, &$handler) should be compatible with DokuWiki_Syntax_Plugin::handle($match, $state, $pos, Doku_Handler $handler) in ...wiki/lib/plugins/flowchartjs/syntax.php on line 59

Warning: Declaration of syntax_plugin_flowchartjs::render($mode, &$renderer, $data) should be compatible with DokuWiki_Syntax_Plugin::render($format, Doku_Renderer $renderer, $data) in ...wiki/lib/plugins/flowchartjs/syntax.php on line 59

Warning: Cannot modify header information - headers already sent by (output started at ...wiki/lib/plugins/flowchartjs/syntax.php:59) in ...wiki/inc/actions.php on line 210

Warning: Cannot modify header information - headers already sent by (output started at ...wiki/lib/plugins/flowchartjs/syntax.php:59) in ...wiki/lib/tpl/dokuwiki/main.php on line 12`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.