GithubHelp home page GithubHelp logo

anthrax3 / mermaid-1 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from semanticmediawiki/mermaid

0.0 1.0 0.0 488 KB

Provides a parser function to generate diagrams and flowcharts with the help of the mermaid script language

Home Page: https://www.mediawiki.org/wiki/Extension:Mermaid

License: Other

PHP 80.63% JavaScript 3.60% Shell 15.78%

mermaid-1's Introduction

Mermaid

Build Status Latest Stable Version Packagist download count

This extension provides the #mermaid parser function to support the generation of diagrams and flowcharts with the help of the mermaid script language. Supported diagram forms include:

  • Flowchart
  • Sequence diagram
  • Gantt diagram

Requirements

  • PHP 5.6 or later
  • MediaWiki 1.27 or later

Installation

The recommended way to install Mermaid is by using Composer with an entry in MediaWiki's "composer.json" file or preferably "composer.local.json" file.

{
	"require": {
		"mediawiki/mermaid": "~1.0"
	}
}
  1. From your MediaWiki installation directory, execute composer require mediawiki/mermaid:~1.0
  2. Add wfLoadExtension( 'Mermaid' ); to the "LocalSettings.php" file
  3. Navigate to Special:Version on your wiki and verify that the package have been successfully installed.

Usage

The #mermaid parser function allows to add mermaid typed content to a wiki article. For example, copying examples is as easy as:

{{#mermaid:sequenceDiagram
participant Alice
participant Bob
  Alice->John: Hello John, how are you?
  loop Healthcheck
       John->John: Fight against hypochondria
  end
  Note right of John: Rational thoughts <br/>prevail...
    John-->Alice: Great!
    John->Bob: How about you?
    Bob-->John: Jolly good!
}}

image

Contribution and support

If you want to contribute work to the project please subscribe to the developers mailing list and have a look at the contribution guideline.

Tests

This extension provides unit and integration tests that are run by a continues integration platform but can also be executed using composer phpunit from the extension base directory.

License

GNU General Public License, version 2 or later.

mermaid-1's People

Contributors

kghbln avatar mwjames avatar translatewiki avatar

Watchers

 avatar

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.