saimod documentation proto, workin markdown viewer
This commit is contained in:
parent
819e3b21c7
commit
7c3a80d9cf
@ -34,4 +34,8 @@ spl_autoload_register('__autoload_system');
|
||||
|
||||
\SYSTEM\autoload::registerFolder(dirname(__FILE__).'/cache','SYSTEM\CACHE');
|
||||
|
||||
\SYSTEM\autoload::registerFolder(dirname(__FILE__).'/sai','SYSTEM\SAI');
|
||||
\SYSTEM\autoload::registerFolder(dirname(__FILE__).'/sai','SYSTEM\SAI');
|
||||
\SYSTEM\autoload::registerFolder(dirname(__FILE__).'/docu','SYSTEM\DOCU');
|
||||
|
||||
require_once dirname(__FILE__).'/lib/autoload.inc.php';
|
||||
require_once dirname(__FILE__).'/docu/register_sys_docu.php';
|
||||
25
docu/docu.php
Normal file
25
docu/docu.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
namespace SYSTEM\DOCU;
|
||||
|
||||
class docu {
|
||||
private static $documents = array(); //only strings!
|
||||
|
||||
public static function registerFolder($folder,$category){
|
||||
if(!is_dir($folder)){
|
||||
throw new \SYSTEM\LOG\ERROR('Docu Folder does not exist: '.$folder);}
|
||||
|
||||
foreach (glob($folder."/*.md") as $filename) {
|
||||
self::register($filename, $category);}
|
||||
}
|
||||
public static function register($document,$category){
|
||||
if(!file_exists($document)){
|
||||
throw new \SYSTEM\LOG\ERROR("Could not find registered documentation: ".$document);}
|
||||
if(!isset(self::$documents[$category])){
|
||||
self::$documents[$category] = array();}
|
||||
array_push(self::$documents[$category],$document);}
|
||||
|
||||
public static function getDocuments(){
|
||||
return self::$documents;}
|
||||
public static function getCategory($category){
|
||||
return self::$documents[$category];}
|
||||
}
|
||||
6
docu/docu_categories.php
Normal file
6
docu/docu_categories.php
Normal file
@ -0,0 +1,6 @@
|
||||
<?php
|
||||
namespace SYSTEM\DOCU;
|
||||
|
||||
class docu_categories {
|
||||
const DOCU_CAT_SYS = 'System';
|
||||
}
|
||||
2
docu/register_sys_docu.php
Normal file
2
docu/register_sys_docu.php
Normal file
@ -0,0 +1,2 @@
|
||||
<?php
|
||||
\SYSTEM\DOCU\docu::registerFolder(dirname(__FILE__).'/system',\SYSTEM\DOCU\docu_categories::DOCU_CAT_SYS);
|
||||
3
docu/system/1.system.md
Normal file
3
docu/system/1.system.md
Normal file
@ -0,0 +1,3 @@
|
||||
system
|
||||
======
|
||||
System - PHP Framework
|
||||
21
docu/system/2.license.md
Normal file
21
docu/system/2.license.md
Normal file
@ -0,0 +1,21 @@
|
||||
License
|
||||
=======
|
||||
Copyright (c) 2013 TU-Darmstadt, Ulf Gebhardt
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
0
docu/system/3.getting started.md
Normal file
0
docu/system/3.getting started.md
Normal file
0
docu/system/system.api.md
Normal file
0
docu/system/system.api.md
Normal file
0
docu/system/system.cache.md
Normal file
0
docu/system/system.cache.md
Normal file
0
docu/system/system.config.md
Normal file
0
docu/system/system.config.md
Normal file
0
docu/system/system.db.md
Normal file
0
docu/system/system.db.md
Normal file
0
docu/system/system.docu.md
Normal file
0
docu/system/system.docu.md
Normal file
0
docu/system/system.log.md
Normal file
0
docu/system/system.log.md
Normal file
0
docu/system/system.page.md
Normal file
0
docu/system/system.page.md
Normal file
0
docu/system/system.sai.md
Normal file
0
docu/system/system.sai.md
Normal file
0
docu/system/system.security.md
Normal file
0
docu/system/system.security.md
Normal file
0
docu/system/system.system.md
Normal file
0
docu/system/system.system.md
Normal file
16
img/img.php
Normal file
16
img/img.php
Normal file
@ -0,0 +1,16 @@
|
||||
<?php
|
||||
namespace SYSTEM;
|
||||
|
||||
class img {
|
||||
protected static function folder_path(){
|
||||
throw new \RuntimeException("Not implemeted");}
|
||||
|
||||
public static function get($hash){
|
||||
|
||||
}
|
||||
|
||||
public static function put($file){
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
2899
lib/EpicEditor/js/epiceditor.js
Normal file
2899
lib/EpicEditor/js/epiceditor.js
Normal file
File diff suppressed because it is too large
Load Diff
5
lib/EpicEditor/js/epiceditor.min.js
vendored
Normal file
5
lib/EpicEditor/js/epiceditor.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
70
lib/EpicEditor/themes/base/epiceditor.css
Normal file
70
lib/EpicEditor/themes/base/epiceditor.css
Normal file
@ -0,0 +1,70 @@
|
||||
html, body, iframe, div {
|
||||
margin:0;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#epiceditor-utilbar {
|
||||
position:fixed;
|
||||
bottom:10px;
|
||||
right:10px;
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button {
|
||||
display:block;
|
||||
float:left;
|
||||
width:30px;
|
||||
height:30px;
|
||||
border:none;
|
||||
background:none;
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button.epiceditor-toggle-preview-btn {
|
||||
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAf9JREFUeNrsVu1twjAQLZmAEcIGYYKGDWACkgkSkPiQ+CifAoEgyQTQDegEpROQDZoRMgH0HToj1yIglKr90Vg62T6f/e4d9gu50+n09BctlwFnwP8TOAgCA10VRr2ZELaHhbBXx3HCVMC+71voXmD6g4Qi2NB13e1DwAAkZhtmmKYRcxsJhHeBPc8bMMufbDU0PxF4vV4TSyth8477csI6lTV/a71er9tioonBarXaIAmLErliNWyqoM8nrJPpHFNLWLcI4xvj5XKpMo2ZgcvzIvs+75S0wKwPPB/CnpWXsG00Gra2WCwshekOVoC9Sb6IGN1ge2HNsWK+B0iJqxAL5oSpYeDJJW02mxVYLAWSGfDtebylA68Bc4wh+ahK5PcxLh6PR5GUpym/iTOfz89PqNVqhRI4iQf1/o174HNMVYDSGeTDmXQ3znogCGrtdpsYVBhER1aH2Wzm8iE7UR74DMTWGNxUQWmNYqTEzq8APoo9sJ8wKoR5eU7T6VQVjZAvx4YvDJWt1Ol0QsTqkppF8EW8/12OhTnSpT2LCe2/KiCTyUQVkJgPuwgb6XG32w05Xui4q0imLLNDxA/uSuZ4PNaZqZlSsejDYfd6veihj8RoNDK5XOUHAen3Dfr9/j7VZxEJ6AwuxCCvhMTM7oNAARhl/0Ay4Az419qXAAMAfBdK7281j6YAAAAASUVORK5CYII=);
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button.epiceditor-toggle-edit-btn {
|
||||
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAnVJREFUeNrsV+lt4lAQNtEWAB2QCtZ0ABWsqYB1BU5AgDgkQOISl9cV4FQQtgLYCuKtIN4K4gogM9H3pMmLTTh24c+O9An7+XnOb8aP1G63M64hN8aV5GqGvxyyyfO8Y3S6hDtc2wTfcZyLRPwdvxEbPSviIwjIRtO49s9ONSRLMIGvwkBI+EPYEEqyQmcZdl2Xo3BgcJ90xPUGDh1veLFYWCBK9oQ6P4BgiXVO6fUjg5zCJcE6kVxsLEN4QTlWzO5yuRwlGp7P55zOxz1RRqK2SfKD8BvOG4IHxUqlEnxop9lsZpITa0KWndGwIeQIXswzHbynpK2xzjXbeBfxdDrlhbUWjYyuiJS9fBJxgL3PItKsprNQrVaD1GQyYUVP2oYelDziPoPnT5+k2QajleEC3usI/exM7oYiXor0hpxS8qhLv5FIVVrcBwkp5ueclbS27qNMvkj7kg3nZX1qtVqAaSUN5OGUwn2M4RUb3263plh700E6I7wTKn1suCAW3PF4zL1r1Ov1SBhXZLEJFqGTQCq5N1BZIp3s+DOi5fXcG7lGo1Ea5DIFSWzcq7a4R6uYqJmlkSqHoeGKeq+w905MtGKj0Yje9TE5ID9pqictQQwmXTfh82cIJ0NML0d0QY8MdhMn13A4zENB0hAJEYn6EnGL3MZ0hsyG3Ww2g70jU8lgMOhqHicJz+KfovVkz3J5/FardfhBgDZzS90SeoJ8cXjQJlUAEmZUCx30kYiTfr9vgFRc72+ChCHSzNH+Qgk+fA7b7fZZJ5AAiIRhT4zUv3/Y07LiaPW9yPE2L5jrI/p/d7wVEZe0U8bJkvr/F+ZS8irAAIorRozUvI0gAAAAAElFTkSuQmCC);
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button.epiceditor-fullscreen-btn {
|
||||
background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAY5JREFUeNrsV8tthDAQhYgCtoV04BKghK2En5AQBw4IITjwq2RLgBJcwpawHZAxMpGDYGwTFPaQkUbG1sybj58NmNM0GVfIh3GRXBbYEid932N9d1zXHWWAGAb4m+9VsUA0H5SubKkKIGA4qyUC2qKBxSCe541HKln7dV2nVbHRtq0Nw7CXGNtz/jzwqjZ5odtqTOagQRC82KRpGkcS/L2Ok7lXZV3Xp7Q6DMNR2mqNthMhKXLqzcUCc6Wgn3wU1wlX1PboHs8tjaLoyVtLT7JFK2ZZM6CZvWyE+X1Voaj3la3DMA63epGqqm4wfyCBH8xmz1+Z1WVZ2vyqU2HvHtv9OI4PsRpjL91YV2a7pcB8onmOifYFUhSFLQCTnQtkDpokyYv73JBtcAQsA3zGTXJBEgNXgrF3CcrBZGwnC+4uqxHnH+zN8/ybvexZwvZNhlsHbrt5CyCgDtu1XosUe58K4kuOF9EKnKYp20eVrxDUJssyreM0bDg4kIw0EfCbftvqQ6KKYf7/wvyVfAkwAMjqoFSaWbrBAAAAAElFTkSuQmCC);
|
||||
}
|
||||
|
||||
@media
|
||||
only screen and (-webkit-min-device-pixel-ratio: 2),
|
||||
only screen and ( min--moz-device-pixel-ratio: 2),
|
||||
only screen and ( -o-min-device-pixel-ratio: 2/1),
|
||||
only screen and ( min-device-pixel-ratio: 2),
|
||||
only screen and ( min-resolution: 192dpi),
|
||||
only screen and ( min-resolution: 2dppx) {
|
||||
#epiceditor-utilbar button.epiceditor-toggle-preview-btn {
|
||||
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAABrVBMVEWIiIiHh4eIiIiJiYmEhISEhISEhISMjIyNjY2MjIyNjY2MjIyFhYWDg4OFhYWKioqKioqBgYGJiYmJiYmJiYmKioqKioqFhYWIiIiJiYmIiIiJiYmIiIiGhoaIiIiGhoaIiIiHh4eHh4eGhoaFhYWKioqFhYWEhISFhYWEhISDg4ONjY2NjY2MjIyHh4eMjIyLi4uCgoKCgoKCgoKBgYGBgYGOjo6Ojo6BgYGPj4+Ojo6Hh4eNjY2Pj4+BgYGNjY2BgYGHh4eQkJCNjY2FhYWHh4eDg4OQkJCQkJCAgICCgoKAgICAgICQkJCQkJCQkJCAgICQkJCAgICQkJCFhYWHh4eHh4eGhoaKioqGhoaMjIyDg4OEhISDg4OEhISDg4OEhISKioqBgYGJiYmKioqKioqJiYmMjIyEhISCgoKGhoaLi4uPj4+Pj4+BgYGKioqDg4OGhoaGhoaMjIyHh4eEhISEhISDg4OIiIiJiYmGhoaHh4eJiYkAAACAgICFhYWQkJCIiIiEhISLi4uDg4OHh4eGhoaCgoKBgYGJiYmMjIyOjo6KioqNjY2Pj4+o6Lr0AAAAfnRSTlPfvxDPEL8gv5/Pr3AQ3++vn8+/cCCA34/vj8/vMJ+vgJ+vYN/fMIBAv4/v38/v39+PgBBg74DPgGAwMHDvrzBQj1AggJ8wIHC/IM9gjxBQgO+vv89Qz0C/70Bgz89ggIDvYN/fII8wIHDvMJ+/QBBAMBDPnxBgML9AEI/vQACT8cYwAAACXElEQVR42u2WV1caURRGJ73H9J7YW+y99957ARREURAFQRFEOFGMkybxN+eec2cWUwBnrTwli/1yvvnm7PvEuoMAf0FGzsj/nDwxOTUzdyoxNzM1OWFU7h0aPtUxPNRrQPZ0XKagw3OF7Nm9TMOuJ43cQmpavSWV3HRhgKakcmvjhSEaW/VyV/tvg7R3aeU+9ULZ/fLEQ/ndMvXbPrV88EvBvQdOMCsLMzjNd5TFgSTr3SpWOCuUTYWTVVV6m+Sdr0qqqVGxw6pqXUPyZlziFaU9Vi3HVSyzag+D/YlcbXLZLm+85AsOgMK4hkIABz/YkSVVdpS3fnKevQCIYgCcGqKslGd0g3dbIIR5fP8cZCkMdOANWeSLEJZklt5StxEWcmLIuw+AHGE+YiEWE67jGxnlO8xv8OGTEBGRRSACmNtYyBUjgcCCKJPLqjYMAeD04ENEGIjQ7AGikuUFNhdF8Vogj0T5bDyqEjh55AwI4N7/hmRTe4zRxEM+ZuKYFSYeEP9HzPtuEFjm9pKf9W5KQLbKhSVMbkymfHL90i+s/wR5PM9iCaYiLOcLTogCrKEIYwkLD19T25/4bR+unSG3bkOQwiG1QZfV6gryBaqL5c01XCCZ9lbOCOvNUpouUOGishSK+dpKUHMZ2M6Jz7ZHNEO+hOoLUWVZZROx6a8hn+VcRWh1EOtBUuhcPiy+pBdg3fZ3DaOj2ma7LtXVW1uj0XVqTW2aS9/bUP8jJfUN3is+N97mp8nV9Wavka9kZ/e6zuzuNP59Hhkbn53+QkzPjo+NZP6TZOSM/L/LfwAJ69Ba3fXmtwAAAABJRU5ErkJggg==);
|
||||
background-size: 30px 30px;
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button.epiceditor-toggle-edit-btn {
|
||||
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAACNFBMVEWIiIiHh4eIiIiGhoaEhISDg4OCgoKDg4OMjIyNjY2MjIyMjIyLi4uMjIyKioqCgoKNjY2Ojo6Dg4ONjY2FhYWFhYWCgoKKioqKioqLi4uLi4uMjIyLi4uFhYWKioqKioqEhISJiYmJiYmEhISEhISFhYWEhISGhoaHh4eJiYmNjY2Hh4eKioqDg4ODg4OCgoKOjo6Ojo6Dg4OOjo6BgYGOjo6AgICCgoKNjY2Dg4OPj4+BgYGBgYGAgICOjo6BgYGOjo6AgICOjo6BgYGBgYGAgICPj4+QkJCQkJCQkJCQkJCPj4+NjY2IiIiIiIiFhYWFhYWEhISEhISGhoaDg4OGhoaDg4OHh4eDg4OCgoKMjIyLi4uLi4uKioqNjY2KioqNjY2NjY2NjY2Dg4OKioqGhoaJiYmIiIiGhoaFhYWEhISFhYWFhYWOjo6Pj4+FhYWGhoaPj4+Hh4eMjIyMjIyMjIyJiYmIiIiIiIiOjo6Ojo6CgoKBgYGPj4+QkJCHh4eHh4eEhISIiIiDg4OEhISDg4ODg4OLi4uHh4eEhISMjIyFhYWGhoaHh4eOjo6IiIiKioqKioqMjIyGhoaIiIiJiYmIiIiFhYWGhoaGhoaHh4eKioqJiYmLi4uIiIiGhoaJiYmHh4eGhoaGhoaJiYmFhYWKioqPj4+IiIiGhoYAAACAgICCgoKQkJCPj4+BgYGDg4OFhYWHh4eOjo6JiYmGhoaLi4uEhISIiIiNjY2MjIyKioqRGRgVAAAAq3RSTlNQz7+Pz4AQr4/vIK+Av99QICBQzyCv37/PcM+f378QgHAwgIBgnxBQMK+PgFCf34Bwn0BQv2Ag7zBwEFDvj4CAv1DvYK/f398gUICA39+fYHAwQHAQn78gz0DfYO8wgO+/YECPIK9gz89Av8/f31AwgK9A72AwIGCAMM+PICCvrxCfr+/fYCAgYO9QgGBQjyCPYM8QcM8wEEAgn58Qn+8w7+/fv0DvQEBA7wCxres+AAAC50lEQVR42u2XVUMbQRSFU3d3d3d3d8EpUKRoKbS40+LuDsEtQOFQKA2FEvhz3XsnS5IlJLB9a/s95J49M99sXpJsNPgD/st/oZwxJJGhTn4+RLxQJ78k9xnUyU+HJV6pk6OGiXR1ciy5sZizfPMrwzl9mIiak5x6/sLnUZmH9+9eqqAQCftyakXkqFUq7MpX6JbW2WBHDnxtmJUAIMiGfD3AYINArDdsCppNfmewxQqx4aRVObFm0ibLAW+aNYkz5ZL4SdusRIkI8SVKOcFyp/cu5ftYA6ySc4Kl3DZuxs4dhfAZV+CDQtNFm0lWuLsBFPoqXF9g9bjSZrlqypwqAC1TClqAtYprIVfLjT+f0gfAXyn7oY9GNZ/KiWVumX17OYYAIUp3O+AnDu7bZqxOk5zU+ZOpPwD0UABNBaEAaPYACBVCZ5Ik14vlg5ClVjFpC0NZ6lplGa0nxN2gSZkg2vtB9FOmKDUNCyemcTStMXXcpmh4yGUl5ToAORMOaGiflhtkoRKCfq41yTw+GFsHKeeIRUfwwbwKOo/eIATi3GQNivREVxyIZsqeADL1+swuvZEiAJ4UmsEUsVEODRAnNp2iulzekrVAbyJLPrYctJTJ7nGQjI7uMULXBIBjIyQWUWLeAGik0E39sQGKYU0QMmp1vGnADSjj0EFtk5uOjuKzOtgok8r34rxasMzEjDFhjdDJNsE7u2VXh9oYDgNllp/n8IgfzJbwXhq9zlRu5soZWtFFl/Zy8SkaljK0R6inJTEinLQo5aSFE889kkqUWvsCdM37ZcnHYnrNBhably5QyoJDtFuJK1xMF3mHgVlkHM2e4eYB02Xxfts/NwXBuSMWLIG7sTmbb/+Hzj3fy1wuQD6N3DMX5/g0VHDDQ3aXAR4jXsEb5/co9fbLN2KdlJbO/zmM5a0qH+KukXxOnfzoO5GmTr5M7mOoktP4xrfUyffIvQ118pNBiTvq5AeDxNV//W+CFX4Doxg1lHC8FNUAAAAASUVORK5CYII=);
|
||||
background-size: 30px 30px;
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button.epiceditor-fullscreen-btn {
|
||||
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAAA5FBMVEWPj4+JiYmJiYmCgoKGhoaPj4+Li4uEhISAgICNjY2Li4uNjY2QkJCFhYWEhISLi4uHh4eHh4eIiIiHh4eGhoaHh4eEhISOjo6EhISJiYmFhYWJiYmFhYWNjY2NjY2Hh4eOjo6CgoKGhoaKioqKioqJiYmKioqDg4ODg4OBgYGGhoaKioqKioqLi4uMjIyMjIyIiIiIiIiMjIyOjo6GhoaDg4ONjY2EhISPj4+CgoIAAACJiYmHh4eIiIiFhYWCgoKPj4+Li4uAgICKioqEhISGhoaBgYGOjo6MjIyQkJCNjY2Dg4O2Jy/OAAAAO3RSTlMQz0DPEHDPz0DvMDBAQBBAQBAQz88wMM/v7zAw788Q7xAQQM9AEBDPEEAwMO/v7zDvMEBA70BAQEBAAAENmbYAAAG1SURBVHja7dftM0JREMdxD5GkEEqKpBJRSc8rQq7Q////2Dnm3t85jtkTmmGG75t7Z3c/t9fN0Tf6x1/Dz0ZrZGZf/BJ8a9QjM/vCwks9Px5aBcslC+P3nPVmi8dcczrcHHM2flug1CHRYcoYNd0YFlrAL1yHqPOC9g9IdbAfjHAjYFjoT+FI1MfRiAM/cZdEl0+oVidVvRaMcAOMgJWGBUYSVhrWjdfvjKqrq1Vzsu7Cy1Vo7XXZhYuj0ahwfHY+sjo/Oy7woyhitkTQsESsZawstG6VlvDCfIlUmfSVVjpDqtL8goBLbKFhsRcwalxcB100CDkxLLQbJxKwpvb3At7Y2iRuJzd4V26HuM2tDQkPWMOamu1Awkeetx2qtDy/lvZaCW173pGIWetA/xBbF+ZgiVgjGcdutLJ7xO1l9VnMiWGhJdzl4vx4CNpN+ifJXUy7RPEuZ2C1AIY1NG5kHI4Dx8MynnBtovYkqHzi25OyP8ONiKFh3djQsCIecn2i/lBvMU+UXxwi3HyE832jvD0RsLuP8CN3Oh0+feRmixE+g7CdLb43WiEz++Jb+M//x/gB/ArCl0G4nsFuEQAAAABJRU5ErkJggg==);
|
||||
background-size: 30px 30px;
|
||||
}
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button:last-child {
|
||||
margin-left:15px;
|
||||
}
|
||||
|
||||
#epiceditor-utilbar button:hover {
|
||||
cursor:pointer;
|
||||
}
|
||||
|
||||
.epiceditor-edit-mode #epiceditor-utilbar button.epiceditor-toggle-edit-btn {
|
||||
display:none;
|
||||
}
|
||||
|
||||
.epiceditor-preview-mode #epiceditor-utilbar button.epiceditor-toggle-preview-btn {
|
||||
display:none;
|
||||
}
|
||||
13
lib/EpicEditor/themes/editor/epic-dark.css
Normal file
13
lib/EpicEditor/themes/editor/epic-dark.css
Normal file
@ -0,0 +1,13 @@
|
||||
html { padding:10px; }
|
||||
|
||||
body {
|
||||
border:0;
|
||||
background:rgb(41,41,41);
|
||||
font-family:monospace;
|
||||
font-size:14px;
|
||||
padding:10px;
|
||||
color:#ddd;
|
||||
line-height:1.35em;
|
||||
margin:0;
|
||||
padding:0;
|
||||
}
|
||||
12
lib/EpicEditor/themes/editor/epic-light.css
Normal file
12
lib/EpicEditor/themes/editor/epic-light.css
Normal file
@ -0,0 +1,12 @@
|
||||
html { padding:10px; }
|
||||
|
||||
body {
|
||||
border:0;
|
||||
background:#fcfcfc;
|
||||
font-family:monospace;
|
||||
font-size:14px;
|
||||
padding:10px;
|
||||
line-height:1.35em;
|
||||
margin:0;
|
||||
padding:0;
|
||||
}
|
||||
167
lib/EpicEditor/themes/preview/bartik.css
Normal file
167
lib/EpicEditor/themes/preview/bartik.css
Normal file
@ -0,0 +1,167 @@
|
||||
body {
|
||||
font-family: Georgia, "Times New Roman", Times, serif;
|
||||
line-height: 1.5;
|
||||
font-size: 87.5%;
|
||||
word-wrap: break-word;
|
||||
margin: 2em;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
outline: 0;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
h1,
|
||||
h2,
|
||||
h3,
|
||||
h4,
|
||||
h5,
|
||||
h6 {
|
||||
margin: 1.0em 0 0.5em;
|
||||
font-weight: inherit;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 1.357em;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 1.143em;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 0 0 1.2em;
|
||||
}
|
||||
|
||||
del {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
tr:nth-child(odd) {
|
||||
background-color: #dddddd;
|
||||
}
|
||||
|
||||
img {
|
||||
outline: 0;
|
||||
}
|
||||
|
||||
code {
|
||||
background-color: #f2f2f2;
|
||||
background-color: rgba(40, 40, 0, 0.06);
|
||||
}
|
||||
|
||||
pre {
|
||||
background-color: #f2f2f2;
|
||||
background-color: rgba(40, 40, 0, 0.06);
|
||||
margin: 10px 0;
|
||||
overflow: hidden;
|
||||
padding: 15px;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
pre code {
|
||||
font-size: 100%;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
blockquote {
|
||||
background: #f7f7f7;
|
||||
border-left: 1px solid #bbb;
|
||||
font-style: italic;
|
||||
margin: 1.5em 10px;
|
||||
padding: 0.5em 10px;
|
||||
}
|
||||
|
||||
blockquote:before {
|
||||
color: #bbb;
|
||||
content: "\201C";
|
||||
font-size: 3em;
|
||||
line-height: 0.1em;
|
||||
margin-right: 0.2em;
|
||||
vertical-align: -.4em;
|
||||
}
|
||||
|
||||
blockquote:after {
|
||||
color: #bbb;
|
||||
content: "\201D";
|
||||
font-size: 3em;
|
||||
line-height: 0.1em;
|
||||
vertical-align: -.45em;
|
||||
}
|
||||
|
||||
blockquote > p:first-child {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
table {
|
||||
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
|
||||
border: 0;
|
||||
border-spacing: 0;
|
||||
font-size: 0.857em;
|
||||
margin: 10px 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table table {
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
table tr th {
|
||||
background: #757575;
|
||||
background: rgba(0, 0, 0, 0.51);
|
||||
border-bottom-style: none;
|
||||
}
|
||||
|
||||
table tr th,
|
||||
table tr th a,
|
||||
table tr th a:hover {
|
||||
color: #FFF;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
table tbody tr th {
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
tr td,
|
||||
tr th {
|
||||
padding: 4px 9px;
|
||||
border: 1px solid #fff;
|
||||
text-align: left; /* LTR */
|
||||
}
|
||||
|
||||
tr:nth-child(odd) {
|
||||
background: #e4e4e4;
|
||||
background: rgba(0, 0, 0, 0.105);
|
||||
}
|
||||
|
||||
tr,
|
||||
tr:nth-child(even) {
|
||||
background: #efefef;
|
||||
background: rgba(0, 0, 0, 0.063);
|
||||
}
|
||||
|
||||
a {
|
||||
color: #0071B3;
|
||||
}
|
||||
|
||||
a:hover,
|
||||
a:focus {
|
||||
color: #018fe2;
|
||||
}
|
||||
|
||||
a:active {
|
||||
color: #23aeff;
|
||||
}
|
||||
|
||||
a:link,
|
||||
a:visited {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:hover,
|
||||
a:active,
|
||||
a:focus {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
368
lib/EpicEditor/themes/preview/github.css
Normal file
368
lib/EpicEditor/themes/preview/github.css
Normal file
@ -0,0 +1,368 @@
|
||||
html { padding:0 10px; }
|
||||
|
||||
body {
|
||||
margin:0;
|
||||
padding:0;
|
||||
background:#fff;
|
||||
}
|
||||
|
||||
#epiceditor-wrapper{
|
||||
background:white;
|
||||
}
|
||||
|
||||
#epiceditor-preview{
|
||||
padding-top:10px;
|
||||
padding-bottom:10px;
|
||||
font-family: Helvetica,arial,freesans,clean,sans-serif;
|
||||
font-size:13px;
|
||||
line-height:1.6;
|
||||
}
|
||||
|
||||
#epiceditor-preview>*:first-child{
|
||||
margin-top:0!important;
|
||||
}
|
||||
|
||||
#epiceditor-preview>*:last-child{
|
||||
margin-bottom:0!important;
|
||||
}
|
||||
|
||||
#epiceditor-preview a{
|
||||
color:#4183C4;
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
#epiceditor-preview a:hover{
|
||||
text-decoration:underline;
|
||||
}
|
||||
|
||||
#epiceditor-preview h1,
|
||||
#epiceditor-preview h2,
|
||||
#epiceditor-preview h3,
|
||||
#epiceditor-preview h4,
|
||||
#epiceditor-preview h5,
|
||||
#epiceditor-preview h6{
|
||||
margin:20px 0 10px;
|
||||
padding:0;
|
||||
font-weight:bold;
|
||||
-webkit-font-smoothing:antialiased;
|
||||
}
|
||||
|
||||
#epiceditor-preview h1 tt,
|
||||
#epiceditor-preview h1 code,
|
||||
#epiceditor-preview h2 tt,
|
||||
#epiceditor-preview h2 code,
|
||||
#epiceditor-preview h3 tt,
|
||||
#epiceditor-preview h3 code,
|
||||
#epiceditor-preview h4 tt,
|
||||
#epiceditor-preview h4 code,
|
||||
#epiceditor-preview h5 tt,
|
||||
#epiceditor-preview h5 code,
|
||||
#epiceditor-preview h6 tt,
|
||||
#epiceditor-preview h6 code{
|
||||
font-size:inherit;
|
||||
}
|
||||
|
||||
#epiceditor-preview h1{
|
||||
font-size:28px;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
#epiceditor-preview h2{
|
||||
font-size:24px;
|
||||
border-bottom:1px solid #ccc;
|
||||
color:#000;
|
||||
}
|
||||
|
||||
#epiceditor-preview h3{
|
||||
font-size:18px;
|
||||
}
|
||||
|
||||
#epiceditor-preview h4{
|
||||
font-size:16px;
|
||||
}
|
||||
|
||||
#epiceditor-preview h5{
|
||||
font-size:14px;
|
||||
}
|
||||
|
||||
#epiceditor-preview h6{
|
||||
color:#777;
|
||||
font-size:14px;
|
||||
}
|
||||
|
||||
#epiceditor-preview p,
|
||||
#epiceditor-preview blockquote,
|
||||
#epiceditor-preview ul,
|
||||
#epiceditor-preview ol,
|
||||
#epiceditor-preview dl,
|
||||
#epiceditor-preview li,
|
||||
#epiceditor-preview table,
|
||||
#epiceditor-preview pre{
|
||||
margin:15px 0;
|
||||
}
|
||||
|
||||
#epiceditor-preview hr{
|
||||
background:transparent url('../../images/modules/pulls/dirty-shade.png') repeat-x 0 0;
|
||||
border:0 none;
|
||||
color:#ccc;
|
||||
height:4px;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview>h2:first-child,
|
||||
#epiceditor-preview>h1:first-child,
|
||||
#epiceditor-preview>h1:first-child+h2,
|
||||
#epiceditor-preview>h3:first-child,
|
||||
#epiceditor-preview>h4:first-child,
|
||||
#epiceditor-preview>h5:first-child,
|
||||
#epiceditor-preview>h6:first-child{
|
||||
margin-top:0;
|
||||
padding-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview h1+p,
|
||||
#epiceditor-preview h2+p,
|
||||
#epiceditor-preview h3+p,
|
||||
#epiceditor-preview h4+p,
|
||||
#epiceditor-preview h5+p,
|
||||
#epiceditor-preview h6+p{
|
||||
margin-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview li p.first{
|
||||
display:inline-block;
|
||||
}
|
||||
|
||||
#epiceditor-preview ul,
|
||||
#epiceditor-preview ol{
|
||||
padding-left:30px;
|
||||
}
|
||||
|
||||
#epiceditor-preview ul li>:first-child,
|
||||
#epiceditor-preview ol li>:first-child{
|
||||
margin-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview ul li>:last-child,
|
||||
#epiceditor-preview ol li>:last-child{
|
||||
margin-bottom:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl{
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dt{
|
||||
font-size:14px;
|
||||
font-weight:bold;
|
||||
font-style:italic;
|
||||
padding:0;
|
||||
margin:15px 0 5px;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dt:first-child{
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dt>:first-child{
|
||||
margin-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dt>:last-child{
|
||||
margin-bottom:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dd{
|
||||
margin:0 0 15px;
|
||||
padding:0 15px;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dd>:first-child{
|
||||
margin-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview dl dd>:last-child{
|
||||
margin-bottom:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview blockquote{
|
||||
border-left:4px solid #DDD;
|
||||
padding:0 15px;
|
||||
color:#777;
|
||||
}
|
||||
|
||||
#epiceditor-preview blockquote>:first-child{
|
||||
margin-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview blockquote>:last-child{
|
||||
margin-bottom:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview table{
|
||||
padding:0;
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
font-size: 100%;
|
||||
font: inherit;
|
||||
}
|
||||
|
||||
#epiceditor-preview table tr{
|
||||
border-top:1px solid #ccc;
|
||||
background-color:#fff;
|
||||
margin:0;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview table tr:nth-child(2n){
|
||||
background-color:#f8f8f8;
|
||||
}
|
||||
|
||||
#epiceditor-preview table tr th{
|
||||
font-weight:bold;
|
||||
}
|
||||
|
||||
#epiceditor-preview table tr th,
|
||||
#epiceditor-preview table tr td{
|
||||
border:1px solid #ccc;
|
||||
text-align:left;
|
||||
margin:0;
|
||||
padding:6px 13px;
|
||||
}
|
||||
|
||||
#epiceditor-preview table tr th>:first-child,
|
||||
#epiceditor-preview table tr td>:first-child{
|
||||
margin-top:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview table tr th>:last-child,
|
||||
#epiceditor-preview table tr td>:last-child{
|
||||
margin-bottom:0;
|
||||
}
|
||||
|
||||
#epiceditor-preview img{
|
||||
max-width:100%;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.frame{
|
||||
display:block;
|
||||
overflow:hidden;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.frame>span{
|
||||
border:1px solid #ddd;
|
||||
display:block;
|
||||
float:left;
|
||||
overflow:hidden;
|
||||
margin:13px 0 0;
|
||||
padding:7px;
|
||||
width:auto;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.frame span img{
|
||||
display:block;
|
||||
float:left;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.frame span span{
|
||||
clear:both;
|
||||
color:#333;
|
||||
display:block;
|
||||
padding:5px 0 0;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.align-center{
|
||||
display:block;
|
||||
overflow:hidden;
|
||||
clear:both;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.align-center>span{
|
||||
display:block;
|
||||
overflow:hidden;
|
||||
margin:13px auto 0;
|
||||
text-align:center;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.align-center span img{
|
||||
margin:0 auto;
|
||||
text-align:center;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.align-right{
|
||||
display:block;
|
||||
overflow:hidden;
|
||||
clear:both;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.align-right>span{
|
||||
display:block;
|
||||
overflow:hidden;
|
||||
margin:13px 0 0;
|
||||
text-align:right;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.align-right span img{
|
||||
margin:0;
|
||||
text-align:right;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.float-left{
|
||||
display:block;
|
||||
margin-right:13px;
|
||||
overflow:hidden;
|
||||
float:left;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.float-left span{
|
||||
margin:13px 0 0;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.float-right{
|
||||
display:block;
|
||||
margin-left:13px;
|
||||
overflow:hidden;
|
||||
float:right;
|
||||
}
|
||||
|
||||
#epiceditor-preview span.float-right>span{
|
||||
display:block;
|
||||
overflow:hidden;
|
||||
margin:13px auto 0;
|
||||
text-align:right;
|
||||
}
|
||||
|
||||
#epiceditor-preview code,
|
||||
#epiceditor-preview tt{
|
||||
margin:0 2px;
|
||||
padding:0 5px;
|
||||
white-space:nowrap;
|
||||
border:1px solid #eaeaea;
|
||||
background-color:#f8f8f8;
|
||||
border-radius:3px;
|
||||
}
|
||||
|
||||
#epiceditor-preview pre>code{
|
||||
margin:0;
|
||||
padding:0;
|
||||
white-space:pre;
|
||||
border:none;
|
||||
background:transparent;
|
||||
}
|
||||
|
||||
#epiceditor-preview .highlight pre,
|
||||
#epiceditor-preview pre{
|
||||
background-color:#f8f8f8;
|
||||
border:1px solid #ccc;
|
||||
font-size:13px;
|
||||
line-height:19px;
|
||||
overflow:auto;
|
||||
padding:6px 10px;
|
||||
border-radius:3px;
|
||||
}
|
||||
|
||||
#epiceditor-preview pre code,
|
||||
#epiceditor-preview pre tt{
|
||||
background-color:transparent;
|
||||
border:none;
|
||||
}
|
||||
121
lib/EpicEditor/themes/preview/preview-dark.css
Normal file
121
lib/EpicEditor/themes/preview/preview-dark.css
Normal file
@ -0,0 +1,121 @@
|
||||
html { padding:0 10px; }
|
||||
|
||||
body {
|
||||
margin:0;
|
||||
padding:10px 0;
|
||||
background:#000;
|
||||
}
|
||||
|
||||
#epiceditor-preview h1,
|
||||
#epiceditor-preview h2,
|
||||
#epiceditor-preview h3,
|
||||
#epiceditor-preview h4,
|
||||
#epiceditor-preview h5,
|
||||
#epiceditor-preview h6,
|
||||
#epiceditor-preview p,
|
||||
#epiceditor-preview blockquote {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
#epiceditor-preview {
|
||||
background:#000;
|
||||
font-family: "Helvetica Neue", Helvetica, "Hiragino Sans GB", Arial, sans-serif;
|
||||
font-size: 13px;
|
||||
line-height: 18px;
|
||||
color: #ccc;
|
||||
}
|
||||
#epiceditor-preview a {
|
||||
color: #fff;
|
||||
}
|
||||
#epiceditor-preview a:hover {
|
||||
color: #00ff00;
|
||||
text-decoration: none;
|
||||
}
|
||||
#epiceditor-preview a img {
|
||||
border: none;
|
||||
}
|
||||
#epiceditor-preview p {
|
||||
margin-bottom: 9px;
|
||||
}
|
||||
#epiceditor-preview h1,
|
||||
#epiceditor-preview h2,
|
||||
#epiceditor-preview h3,
|
||||
#epiceditor-preview h4,
|
||||
#epiceditor-preview h5,
|
||||
#epiceditor-preview h6 {
|
||||
color: #cdcdcd;
|
||||
line-height: 36px;
|
||||
}
|
||||
#epiceditor-preview h1 {
|
||||
margin-bottom: 18px;
|
||||
font-size: 30px;
|
||||
}
|
||||
#epiceditor-preview h2 {
|
||||
font-size: 24px;
|
||||
}
|
||||
#epiceditor-preview h3 {
|
||||
font-size: 18px;
|
||||
}
|
||||
#epiceditor-preview h4 {
|
||||
font-size: 16px;
|
||||
}
|
||||
#epiceditor-preview h5 {
|
||||
font-size: 14px;
|
||||
}
|
||||
#epiceditor-preview h6 {
|
||||
font-size: 13px;
|
||||
}
|
||||
#epiceditor-preview hr {
|
||||
margin: 0 0 19px;
|
||||
border: 0;
|
||||
border-bottom: 1px solid #ccc;
|
||||
}
|
||||
#epiceditor-preview blockquote {
|
||||
padding: 13px 13px 21px 15px;
|
||||
margin-bottom: 18px;
|
||||
font-family:georgia,serif;
|
||||
font-style: italic;
|
||||
}
|
||||
#epiceditor-preview blockquote:before {
|
||||
content:"\201C";
|
||||
font-size:40px;
|
||||
margin-left:-10px;
|
||||
font-family:georgia,serif;
|
||||
color:#eee;
|
||||
}
|
||||
#epiceditor-preview blockquote p {
|
||||
font-size: 14px;
|
||||
font-weight: 300;
|
||||
line-height: 18px;
|
||||
margin-bottom: 0;
|
||||
font-style: italic;
|
||||
}
|
||||
#epiceditor-preview code, #epiceditor-preview pre {
|
||||
font-family: Monaco, Andale Mono, Courier New, monospace;
|
||||
}
|
||||
#epiceditor-preview code {
|
||||
background-color: #000;
|
||||
color: #f92672;
|
||||
padding: 1px 3px;
|
||||
font-size: 12px;
|
||||
-webkit-border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
}
|
||||
#epiceditor-preview pre {
|
||||
display: block;
|
||||
padding: 14px;
|
||||
color:#66d9ef;
|
||||
margin: 0 0 18px;
|
||||
line-height: 16px;
|
||||
font-size: 11px;
|
||||
border: 1px solid #d9d9d9;
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
#epiceditor-preview pre code {
|
||||
background-color: #000;
|
||||
color:#ccc;
|
||||
font-size: 11px;
|
||||
padding: 0;
|
||||
}
|
||||
3096
lib/Michelf/Markdown.php
Normal file
3096
lib/Michelf/Markdown.php
Normal file
File diff suppressed because it is too large
Load Diff
40
lib/Michelf/MarkdownExtra.php
Normal file
40
lib/Michelf/MarkdownExtra.php
Normal file
@ -0,0 +1,40 @@
|
||||
<?php
|
||||
#
|
||||
# Markdown Extra - A text-to-HTML conversion tool for web writers
|
||||
#
|
||||
# PHP Markdown Extra
|
||||
# Copyright (c) 2004-2013 Michel Fortin
|
||||
# <http://michelf.com/projects/php-markdown/>
|
||||
#
|
||||
# Original Markdown
|
||||
# Copyright (c) 2004-2006 John Gruber
|
||||
# <http://daringfireball.net/projects/markdown/>
|
||||
#
|
||||
namespace Michelf;
|
||||
|
||||
|
||||
# Just force Michelf/Markdown.php to load. This is needed to load
|
||||
# the temporary implementation class. See below for details.
|
||||
\Michelf\Markdown::MARKDOWNLIB_VERSION;
|
||||
|
||||
#
|
||||
# Markdown Extra Parser Class
|
||||
#
|
||||
# Note: Currently the implementation resides in the temporary class
|
||||
# \Michelf\MarkdownExtra_TmpImpl (in the same file as \Michelf\Markdown).
|
||||
# This makes it easier to propagate the changes between the three different
|
||||
# packaging styles of PHP Markdown. Once this issue is resolved, the
|
||||
# _MarkdownExtra_TmpImpl will disappear and this one will contain the code.
|
||||
#
|
||||
|
||||
class MarkdownExtra extends \Michelf\_MarkdownExtra_TmpImpl {
|
||||
|
||||
### Parser Implementation ###
|
||||
|
||||
# Temporarily, the implemenation is in the _MarkdownExtra_TmpImpl class.
|
||||
# See note above.
|
||||
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
36
lib/Michelf/extra/License.md
Normal file
36
lib/Michelf/extra/License.md
Normal file
@ -0,0 +1,36 @@
|
||||
PHP Markdown Lib
|
||||
Copyright (c) 2004-2013 Michel Fortin
|
||||
<http://michelf.ca/>
|
||||
All rights reserved.
|
||||
|
||||
Based on Markdown
|
||||
Copyright (c) 2003-2006 John Gruber
|
||||
<http://daringfireball.net/>
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice,
|
||||
this list of conditions and the following disclaimer.
|
||||
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
* Neither the name "Markdown" nor the names of its contributors may
|
||||
be used to endorse or promote products derived from this software
|
||||
without specific prior written permission.
|
||||
|
||||
This software is provided by the copyright holders and contributors "as
|
||||
is" and any express or implied warranties, including, but not limited
|
||||
to, the implied warranties of merchantability and fitness for a
|
||||
particular purpose are disclaimed. In no event shall the copyright owner
|
||||
or contributors be liable for any direct, indirect, incidental, special,
|
||||
exemplary, or consequential damages (including, but not limited to,
|
||||
procurement of substitute goods or services; loss of use, data, or
|
||||
profits; or business interruption) however caused and on any theory of
|
||||
liability, whether in contract, strict liability, or tort (including
|
||||
negligence or otherwise) arising in any way out of the use of this
|
||||
software, even if advised of the possibility of such damage.
|
||||
259
lib/Michelf/extra/Readme.md
Normal file
259
lib/Michelf/extra/Readme.md
Normal file
@ -0,0 +1,259 @@
|
||||
PHP Markdown
|
||||
============
|
||||
|
||||
PHP Markdown Lib 1.3 - 11 Apr 2013
|
||||
|
||||
by Michel Fortin
|
||||
<http://michelf.ca/>
|
||||
|
||||
based on Markdown by John Gruber
|
||||
<http://daringfireball.net/>
|
||||
|
||||
|
||||
Introduction
|
||||
------------
|
||||
|
||||
This is a library package that includes the PHP Markdown parser and its
|
||||
sibling PHP Markdown Extra which additional features.
|
||||
|
||||
Markdown is a text-to-HTML conversion tool for web writers. Markdown
|
||||
allows you to write using an easy-to-read, easy-to-write plain text
|
||||
format, then convert it to structurally valid XHTML (or HTML).
|
||||
|
||||
"Markdown" is two things: a plain text markup syntax, and a software
|
||||
tool, written in Perl, that converts the plain text markup to HTML.
|
||||
PHP Markdown is a port to PHP of the original Markdown program by
|
||||
John Gruber.
|
||||
|
||||
PHP Markdown can work as a plug-in for WordPress, as a modifier for
|
||||
the Smarty templating engine, or as a replacement for Textile
|
||||
formatting in any software that supports Textile.
|
||||
|
||||
Full documentation of Markdown's syntax is available on John's
|
||||
Markdown page: <http://daringfireball.net/projects/markdown/>
|
||||
|
||||
|
||||
Requirement
|
||||
-----------
|
||||
|
||||
This library package requires PHP 5.3 or later.
|
||||
|
||||
Note: The older plugin/library hybrid package for PHP Markdown and
|
||||
PHP Markdown Extra is still maintained and will work with PHP 4.0.5 and later.
|
||||
|
||||
Before PHP 5.3.7, pcre.backtrack_limit defaults to 100 000, which is too small
|
||||
in many situations. You might need to set it to higher values. Later PHP
|
||||
releases defaults to 1 000 000, which is usually fine.
|
||||
|
||||
|
||||
Usage
|
||||
-----
|
||||
|
||||
This library package is meant to be used with class autoloading. For autoloading
|
||||
to work, your project needs have setup a PSR-0-compatible autoloader. See the
|
||||
included Readme.php file for a minimal autoloader setup. (If you don't want to
|
||||
use autoloading you can do a classic `require_once` to manually include the
|
||||
files prior use instead.)
|
||||
|
||||
With class autoloading in place, putting the 'Michelf' folder in your
|
||||
include path should be enough for this to work:
|
||||
|
||||
use \Michelf\Markdown;
|
||||
$my_html = Markdown::defaultTransform($my_text);
|
||||
|
||||
Markdown Extra syntax is also available the same way:
|
||||
|
||||
use \Michelf\MarkdownExtra;
|
||||
$my_html = MarkdownExtra::defaultTransform($my_text);
|
||||
|
||||
If you wish to use PHP Markdown with another text filter function
|
||||
built to parse HTML, you should filter the text *after* the `transform`
|
||||
function call. This is an example with [PHP SmartyPants][psp]:
|
||||
|
||||
use \Michelf\Markdown, \Michelf\SmartyPants;
|
||||
$my_html = Markdown::defaultTransform($my_text);
|
||||
$my_html = SmartyPants::defaultTransform($my_html);
|
||||
|
||||
All these examples are using the static `defaultTransform` static function
|
||||
found inside the parser class. If you want to customize the parser
|
||||
configuration, you can also instantiate it directly and change some
|
||||
configuration variables:
|
||||
|
||||
use \Michelf\MarkdownExtra;
|
||||
$parser = new MarkdownExtra;
|
||||
$parser->fn_id_prefix = "post22-";
|
||||
$my_html = $parser->transform($my_text);
|
||||
|
||||
|
||||
Usage
|
||||
-----
|
||||
|
||||
This library package is meant to be used with class autoloading. For autoloading
|
||||
to work, your project needs have setup a PSR-0-compatible autoloader. See the
|
||||
included Readme.php file for a minimal autoloader setup. (If you don't want to
|
||||
use autoloading you can do a classic `require_once` to manually include the
|
||||
files prior use instead.)
|
||||
|
||||
With class autoloading in place, putting the 'Michelf' folder in your
|
||||
include path should be enough for this to work:
|
||||
|
||||
use \Michelf\Markdown;
|
||||
$my_html = Markdown::defaultTransform($my_text);
|
||||
|
||||
Markdown Extra syntax is also available the same way:
|
||||
|
||||
use \Michelf\MarkdownExtra;
|
||||
$my_html = MarkdownExtra::defaultTransform($my_text);
|
||||
|
||||
If you wish to use PHP Markdown with another text filter function
|
||||
built to parse HTML, you should filter the text *after* the `transform`
|
||||
function call. This is an example with [PHP SmartyPants][psp]:
|
||||
|
||||
use \Michelf\Markdown, \Michelf\SmartyPants;
|
||||
$my_html = Markdown::defaultTransform($my_text);
|
||||
$my_html = SmartyPants::defaultTransform($my_html);
|
||||
|
||||
All these examples are using the static `defaultTransform` static function
|
||||
found inside the parser class. If you want to customize the parser
|
||||
configuration, you can also instantiate it directly and change some
|
||||
configuration variables:
|
||||
|
||||
use \Michelf\MarkdownExtra;
|
||||
$parser = new MarkdownExtra;
|
||||
$parser->fn_id_prefix = "post22-";
|
||||
$my_html = $parser->transform($my_text);
|
||||
|
||||
To learn more, see the full list of [configuration variables].
|
||||
|
||||
[configuration variables]: http://michelf.ca/project/php-markdown/configuration/
|
||||
|
||||
|
||||
Public API and Versionning Policy
|
||||
---------------------------------
|
||||
|
||||
Version numbers are of the form *major*.*minor*.*patch*.
|
||||
|
||||
The public API of PHP Markdown consist of the two parser classes `Markdown`
|
||||
and `MarkdownExtra`, their constructors, the `transform` and `defaultTransform`
|
||||
functions and their configuration variables. The public API is stable for
|
||||
a given major version number. It might get additions when the minor version
|
||||
number increments.
|
||||
|
||||
**Protected members are not considered public API.** This is unconventionnal
|
||||
and deserves an explanation. Incrementing the major version number every time
|
||||
the underlying implementation of something changes is going to give nonsential
|
||||
version numbers for the vast majority of people who just use the parser.
|
||||
Protected members are meant to create parser subclasses that behave in
|
||||
different ways. Very few people create parser subclasses. I don't want to
|
||||
discourage it by making everything private, but at the same time I can't
|
||||
guarenty any stable hook between versions if you use protected members.
|
||||
|
||||
**Syntax changes** will increment the minor number for new features, and the
|
||||
patch number for small corrections. A *new feature* is something that needs a
|
||||
change in the syntax documentation. Note that since PHP Markdown Lib includes
|
||||
two parsers, a syntax change for either of them will increment the minor
|
||||
number. Also note that there is nothigng perfectly backward-compatible with the
|
||||
Markdown syntax: all inputs are always valid, so new features always replace
|
||||
something that was previously legal, although generally non-sensial to do.
|
||||
|
||||
|
||||
Bugs
|
||||
----
|
||||
|
||||
To file bug reports please send email to:
|
||||
<michel.fortin@michelf.ca>
|
||||
|
||||
Please include with your report: (1) the example input; (2) the output you
|
||||
expected; (3) the output PHP Markdown actually produced.
|
||||
|
||||
If you have a problem where Markdown gives you an empty result, first check
|
||||
that the backtrack limit is not too low by running `php --info | grep pcre`.
|
||||
See Installation and Requirement above for details.
|
||||
|
||||
|
||||
Version History
|
||||
---------------
|
||||
|
||||
PHP Markdown Lib 1.3 (11 Apr 2013):
|
||||
|
||||
This is the first release of PHP Markdown Lib. This package requires PHP
|
||||
version 4.3 or later and is designed to work with PSR-0 autoloading and,
|
||||
optionally with Composer. Here is a list of the changes since
|
||||
PHP Markdown Extra 1.2.6:
|
||||
|
||||
* Plugin interface for Wordpress and other systems is no longer present in
|
||||
the Lib package. The classic package is still available if you need it:
|
||||
<http://michelf.ca/projects/php-markdown/classic/>
|
||||
|
||||
* Added `public` and `protected` protection attributes, plus a section about
|
||||
what is "public API" and what isn't in the Readme file.
|
||||
|
||||
* Changed HTML output for footnotes: now instead of adding `rel` and `rev`
|
||||
attributes, footnotes links have the class name `footnote-ref` and
|
||||
backlinks `footnote-backref`.
|
||||
|
||||
* Fixed some regular expressions to make PCRE not shout warnings about POSIX
|
||||
collation classes (dependent on your version of PCRE).
|
||||
|
||||
* Added optional class and id attributes to images and links using the same
|
||||
syntax as for headers:
|
||||
|
||||
[link](url){#id .class}
|
||||
{#id .class}
|
||||
|
||||
It work too for reference-style links and images. In this case you need
|
||||
to put those attributes at the reference definition:
|
||||
|
||||
[link][linkref] or [linkref]
|
||||
![img][linkref]
|
||||
|
||||
[linkref]: url "optional title" {#id .class}
|
||||
|
||||
* Fixed a PHP notice message triggered when some table column separator
|
||||
markers are missing on the separator line below column headers.
|
||||
|
||||
* Fixed a small mistake that could cause the parser to retain an invalid
|
||||
state related to parsing links across multiple runs. This was never
|
||||
observed (that I know of), but it's still worth fixing.
|
||||
|
||||
|
||||
Copyright and License
|
||||
---------------------
|
||||
|
||||
PHP Markdown Lib
|
||||
Copyright (c) 2004-2013 Michel Fortin
|
||||
<http://michelf.ca/>
|
||||
All rights reserved.
|
||||
|
||||
Based on Markdown
|
||||
Copyright (c) 2003-2005 John Gruber
|
||||
<http://daringfireball.net/>
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the
|
||||
distribution.
|
||||
|
||||
* Neither the name "Markdown" nor the names of its contributors may
|
||||
be used to endorse or promote products derived from this software
|
||||
without specific prior written permission.
|
||||
|
||||
This software is provided by the copyright holders and contributors "as
|
||||
is" and any express or implied warranties, including, but not limited
|
||||
to, the implied warranties of merchantability and fitness for a
|
||||
particular purpose are disclaimed. In no event shall the copyright owner
|
||||
or contributors be liable for any direct, indirect, incidental, special,
|
||||
exemplary, or consequential damages (including, but not limited to,
|
||||
procurement of substitute goods or services; loss of use, data, or
|
||||
profits; or business interruption) however caused and on any theory of
|
||||
liability, whether in contract, strict liability, or tort (including
|
||||
negligence or otherwise) arising in any way out of the use of this
|
||||
software, even if advised of the possibility of such damage.
|
||||
31
lib/Michelf/extra/Readme.php
Normal file
31
lib/Michelf/extra/Readme.php
Normal file
@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
# This file passes the content of the Readme.md file in the same directory
|
||||
# through the Markdown filter. You can adapt this sample code in any way
|
||||
# you like.
|
||||
|
||||
# Install PSR-0-compatible class autoloader
|
||||
spl_autoload_register(function($class){
|
||||
require preg_replace('{\\\\|_(?!.*\\\\)}', DIRECTORY_SEPARATOR, ltrim($class, '\\')).'.php';
|
||||
});
|
||||
|
||||
# Get Markdown class
|
||||
use \Michelf\Markdown;
|
||||
|
||||
# Read file and pass content through the Markdown praser
|
||||
$text = file_get_contents('Readme.md');
|
||||
$html = Markdown::defaultTransform($text);
|
||||
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>PHP Markdown Lib - Readme</title>
|
||||
</head>
|
||||
<body>
|
||||
<?php
|
||||
# Put HTML content in the document
|
||||
echo $html;
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
31
lib/Michelf/extra/composer.json
Normal file
31
lib/Michelf/extra/composer.json
Normal file
@ -0,0 +1,31 @@
|
||||
{
|
||||
"name": "michelf/php-markdown",
|
||||
"type": "library",
|
||||
"description": "PHP Markdown",
|
||||
"homepage": "http://michelf.ca/projects/php-markdown/",
|
||||
"keywords": ["markdown"],
|
||||
"license": "BSD-3-Clause",
|
||||
"authors": [
|
||||
{
|
||||
"name": "Michel Fortin",
|
||||
"email": "michel.fortin@michelf.ca",
|
||||
"homepage": "http://michelf.ca/",
|
||||
"role": "Developer"
|
||||
},
|
||||
{
|
||||
"name": "John Gruber",
|
||||
"homepage": "http://daringfireball.net/"
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": ">=5.3.0"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-0": { "Michelf": "" }
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-lib": "1.3.x-dev"
|
||||
}
|
||||
}
|
||||
}
|
||||
2
lib/autoload.inc.php
Normal file
2
lib/autoload.inc.php
Normal file
@ -0,0 +1,2 @@
|
||||
<?php
|
||||
\SYSTEM\autoload::registerFolder(dirname(__FILE__).'/Michelf','Michelf');
|
||||
16
sai/modules/saimod_sys_docu/saimod_sys_docu.js
Normal file
16
sai/modules/saimod_sys_docu/saimod_sys_docu.js
Normal file
@ -0,0 +1,16 @@
|
||||
var editor = null;
|
||||
|
||||
function init__SYSTEM_SAI_saimod_sys_docu() {
|
||||
$('#documaintab a, .subtabs a').click(function (e) {
|
||||
e.preventDefault();
|
||||
$(this).tab('show');
|
||||
if(editor != null){
|
||||
editor.unload();
|
||||
}
|
||||
});
|
||||
|
||||
$('.docuedit').click(function (){
|
||||
var opts = {basePath: '../system/lib/EpicEditor'};
|
||||
editor = new EpicEditor(opts).load();
|
||||
});
|
||||
};
|
||||
@ -3,7 +3,42 @@ namespace SYSTEM\SAI;
|
||||
|
||||
class saimod_sys_docu extends \SYSTEM\SAI\SaiModule {
|
||||
public static function sai_mod__SYSTEM_SAI_saimod_sys_docu(){
|
||||
return "todo";
|
||||
$documents = \SYSTEM\DOCU\docu::getDocuments();
|
||||
|
||||
$vars['tabopts'] = '';
|
||||
$first = true;
|
||||
foreach($documents as $cat => $docs){
|
||||
$vars2 = array( 'active' => ($first ? 'active' : ''),
|
||||
'tab_id' => str_replace(' ', '_', $cat),
|
||||
'tab_id_pretty' => $cat);
|
||||
$first = false;
|
||||
$vars['tabopts'] .= \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_docu/tabopt.tpl'), $vars2);
|
||||
|
||||
$first2 = true;
|
||||
foreach($docs as $doc){
|
||||
$tabs[$cat]['tab_id'] = str_replace(' ', '_', $cat);
|
||||
$tabs[$cat]['content'] = isset($tabs[$cat]['content']) ? $tabs[$cat]['content'] : '';
|
||||
$tabs[$cat]['menu'] = isset($tabs[$cat]['menu']) ? $tabs[$cat]['menu'] : '';
|
||||
//$tabs[$cat]['content'] .= \Michelf\Markdown::defaultTransform(file_get_contents($doc));
|
||||
$vars3 = array( 'active' => ($first2 ? 'active' : ''),
|
||||
'content' => \Michelf\Markdown::defaultTransform(file_get_contents($doc)),
|
||||
'tab_id' => str_replace(array('.',' '), '_', basename($doc)));
|
||||
$tabs[$cat]['content'] .= \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_docu/tab2.tpl'), $vars3);
|
||||
$vars3 = array( 'active' => ($first2 ? 'active' : ''),
|
||||
'tab_id' => str_replace(array('.',' '), '_', basename($doc)),
|
||||
'tab_id_pretty' => basename($doc));
|
||||
$tabs[$cat]['menu'] .= \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_docu/tabopt.tpl'), $vars3);
|
||||
$first2 = false;
|
||||
}
|
||||
|
||||
$vars['tabs'] = '';
|
||||
$first = true;
|
||||
foreach($tabs as $tab){
|
||||
$tab['active'] = ($first ? 'active' : '');
|
||||
$first = false;
|
||||
$vars['tabs'] .= \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_docu/tab.tpl'), $tab);}
|
||||
}
|
||||
return \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_docu/tabs.tpl'), $vars);
|
||||
}
|
||||
|
||||
public static function html_li_menu(){return '<li><a href="#" saimenu=".SYSTEM.SAI.saimod_sys_docu">Docu</a></li>';}
|
||||
@ -11,5 +46,8 @@ class saimod_sys_docu extends \SYSTEM\SAI\SaiModule {
|
||||
public static function right_right(){return \SYSTEM\SECURITY\Security::check(\SYSTEM\SECURITY\RIGHTS::SYS_SAI);}
|
||||
|
||||
public static function sai_mod__SYSTEM_SAI_saimod_sys_docu_flag_css(){}
|
||||
public static function sai_mod__SYSTEM_SAI_saimod_sys_docu_flag_js(){}
|
||||
public static function sai_mod__SYSTEM_SAI_saimod_sys_docu_flag_js(){
|
||||
return \SYSTEM\LOG\JsonResult::toString(
|
||||
array( \SYSTEM\WEBPATH(new \SYSTEM\PSYSTEM(),'lib/EpicEditor/js/epiceditor.min.js'),
|
||||
\SYSTEM\WEBPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_docu/saimod_sys_docu.js')));}
|
||||
}
|
||||
12
sai/modules/saimod_sys_docu/tab.tpl
Normal file
12
sai/modules/saimod_sys_docu/tab.tpl
Normal file
@ -0,0 +1,12 @@
|
||||
<div class="tab-pane ${active}" id="tab_${tab_id}">
|
||||
<div class="tabbable tabs-left subtabs">
|
||||
<ul class="nav nav-tabs">
|
||||
${menu}
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
${content}
|
||||
</br>
|
||||
<div id="epiceditor"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
8
sai/modules/saimod_sys_docu/tab2.tpl
Normal file
8
sai/modules/saimod_sys_docu/tab2.tpl
Normal file
@ -0,0 +1,8 @@
|
||||
<div class="tab-pane ${active}" id="tab_${tab_id}">
|
||||
<div class="tabbable tabs-left">
|
||||
<div class="tab-content">
|
||||
${content}
|
||||
<button class="btn docuedit" tabid="${tab_id}">Edit</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
1
sai/modules/saimod_sys_docu/tabopt.tpl
Normal file
1
sai/modules/saimod_sys_docu/tabopt.tpl
Normal file
@ -0,0 +1 @@
|
||||
<li class="${active}"><a href="#tab_${tab_id}">${tab_id_pretty}</a></li>
|
||||
10
sai/modules/saimod_sys_docu/tabs.tpl
Normal file
10
sai/modules/saimod_sys_docu/tabs.tpl
Normal file
@ -0,0 +1,10 @@
|
||||
<h3>Documentation</h3>
|
||||
<br>
|
||||
<div class="tabbable">
|
||||
<ul class="nav nav-tabs" id="documaintab">
|
||||
${tabopts}
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
${tabs}
|
||||
</div>
|
||||
</div>
|
||||
Loading…
x
Reference in New Issue
Block a user