Skip to content

Commit

Permalink
fix: typo
Browse files Browse the repository at this point in the history
  • Loading branch information
hfr committed Oct 13, 2023
1 parent 45d7d10 commit cae54ce
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 6 deletions.
2 changes: 1 addition & 1 deletion conf/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* @author Rüdiger Kessel <ruediger.kessel@gmail.com>
*/

$conf['save_mode'] = 'server';
$conf['safe_mode'] = 'server';
$conf['adoc2html'] = 'browser';
$conf['exec_node'] = 'node';
$conf['use_kroki'] = 1;
Expand Down
2 changes: 1 addition & 1 deletion conf/metadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
*/

$meta['use_css'] = array('onoff');
$meta['save_mode'] = array('multichoice','_choices' => array('unsave','save','server','secure'));
$meta['safe_mode'] = array('multichoice','_choices' => array('unsafe','safe','server','secure'));
$meta['adoc2html'] = array('multichoice','_choices' => array('browser','server'));
$meta['exec_node'] = array('string');
$meta['use_kroki'] = array('onoff');
Expand Down
2 changes: 1 addition & 1 deletion lang/en/settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @author Rüdiger Kessel <ruediger.kessel@gmail.com>
*/

$lang['save_mode'] = 'Asciidoctor save mode (see https://docs.asciidoctor.org/asciidoctor/latest/safe-modes/)';
$lang['safe_mode'] = 'Asciidoctor safe mode (see https://docs.asciidoctor.org/asciidoctor/latest/safe-modes/)';
$lang['adoc2html'] = 'Processing of the asciidoc to html conversion';
$lang['exec_node'] = 'node.js executable';
$lang['use_kroki'] = 'Use Kroki Extension for AsciiDoctor (see https://github.com/ggrossetie/asciidoctor-kroki)';
Expand Down
2 changes: 1 addition & 1 deletion plugin.info.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ author Rüdiger Kessel
email ruediger.kessel@gmail.com
date 2023-09-23
name asciidocjs plugin
desc Us asciidoc in Dokuwiki
desc Use asciidoc in Dokuwiki
url https://www.dokuwiki.org/plugin:asciidocjs
33 changes: 33 additions & 0 deletions remote.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<?php

//use dokuwiki\Extension\AdminPlugin;
use dokuwiki\Remote\RemoteException;

class remote_plugin_asciidocjs extends DokuWiki_Remote_Plugin {
/**
* Returns details about the remote plugin methods
*
* @return array Information about all provided methods. {@see dokuwiki\Remote\RemoteAPI}
*/
public function _getMethods() {
return [
'getMediaToken' => [
'args' => ['string','int','int'],
'return' => 'string'
],
'test' => [
'args' => [],
'return' => 'string'
]
];
}

public function getMediaToken($id, $w, $h) {
return media_get_token($id, $w, $h);
}
public function test() {
return 'Test';
}
}


5 changes: 3 additions & 2 deletions syntax/base.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ public function getSort()
* </p>
* @param $aNode String Path to the node.js exe.
* @param $aAscdoc String The asciidoc text to convert.
* @param $aSave_mode String AsciiDoctor save mode for the conversion.
* @param $extensions array List of extensions.
* @param $params array Conversion parameters.
*/
public function runAsciidoctor($node, $ascdoc, $extensions, $params)
{
Expand Down Expand Up @@ -108,7 +109,7 @@ public function getExtensions()
}
public function getParams()
{
$params = array("safe" => $this->getConf('save_mode'),
$params = array("safe" => $this->getConf('safe_mode'),
"header_footer" => false,
"attributes" => array(
"DOKUWIKI_BASE" => DOKU_BASE,
Expand Down

0 comments on commit cae54ce

Please sign in to comment.