-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
339 changed files
with
63,121 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
<?php | ||
|
||
/** | ||
* CodeMirror plugin | ||
* | ||
* @package Monstra | ||
* @subpackage Plugins | ||
* @author Romanenko Sergey / Awilum | ||
* @copyright 2012-2014 Romanenko Sergey / Awilum | ||
* @version 1.0.0 | ||
* | ||
*/ | ||
|
||
// Register plugin | ||
Plugin::register( __FILE__, | ||
__('CodeMirror', 'codemirror'), | ||
__('CodeMirror is a versatile text editor implemented in JavaScript for the browser.', 'codemirror'), | ||
'1.0.0', | ||
'Awilum', | ||
'http://monstra.org/'); | ||
|
||
// Add hooks | ||
Action::add('admin_header', 'CodeMirror::headers'); | ||
|
||
/** | ||
* Codemirror Class | ||
*/ | ||
class CodeMirror | ||
{ | ||
|
||
public static $theme = 'ambiance'; | ||
|
||
/** | ||
* Set editor headers | ||
*/ | ||
public static function headers() | ||
{ | ||
echo (' | ||
<link rel="stylesheet" type="text/css" href="'.Option::get('siteurl').'plugins/codemirror/codemirror/lib/codemirror.css" /> | ||
<script type="text/javascript" src="'.Option::get('siteurl').'plugins/codemirror/codemirror/lib/codemirror.js"></script> | ||
<script type="text/javascript" src="'.Option::get('siteurl').'plugins/codemirror/codemirror/addon/edit/matchbrackets.js"></script> | ||
<script type="text/javascript" src="'.Option::get('siteurl').'plugins/codemirror/codemirror/mode/htmlmixed/htmlmixed.js"></script> | ||
<script type="text/javascript" src="'.Option::get('siteurl').'plugins/codemirror/codemirror/mode/xml/xml.js"></script> | ||
<script type="text/javascript" src="'.Option::get('siteurl').'plugins/codemirror/codemirror/mode/javascript/javascript.js"></script> | ||
<script type="text/javascript" src="'.Option::get('siteurl').'plugins/codemirror/codemirror/mode/php/php.js"></script> | ||
<link rel="stylesheet" href="'.Option::get('siteurl').'plugins/codemirror/codemirror/theme/'.CodeMirror::$theme.'.css"> | ||
<style> .CodeMirror { height:500px!important; } </style> | ||
'); | ||
|
||
if (Request::get('id') == 'themes' || Request::get('id') == 'snippets') { | ||
|
||
echo ('<script> | ||
$(document).ready(function() { | ||
var editor = CodeMirror.fromTextArea(document.getElementById("content"), { | ||
lineNumbers: true, | ||
matchBrackets: true, | ||
mode: "htmlmixed", | ||
indentUnit: 4, | ||
indentWithTabs: true, | ||
enterMode: "keep", | ||
tabMode: "shift", | ||
theme: "'.CodeMirror::$theme.'" | ||
}); | ||
}); | ||
</script>'); | ||
|
||
} | ||
|
||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
*.txt text | ||
*.js text | ||
*.html text | ||
*.md text | ||
*.json text | ||
*.yml text | ||
*.css text | ||
*.svg text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
/node_modules | ||
/npm-debug.log | ||
test.html | ||
.tern-* | ||
*~ | ||
*.swp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Options -Indexes | ||
Allow from all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
language: node_js | ||
node_js: | ||
- 0.8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,255 @@ | ||
List of CodeMirror contributors. Updated before every release. | ||
|
||
4r2r | ||
Aaron Brooks | ||
Adam King | ||
adanlobato | ||
Adán Lobato | ||
aeroson | ||
Ahmad Amireh | ||
Ahmad M. Zawawi | ||
ahoward | ||
Akeksandr Motsjonov | ||
Albert Xing | ||
Alexander Pavlov | ||
Alexander Schepanovski | ||
alexey-k | ||
Alex Piggott | ||
Amy | ||
Ananya Sen | ||
AndersMad | ||
Andre von Houck | ||
Andrey Lushnikov | ||
Andy Kimball | ||
Andy Li | ||
angelozerr | ||
[email protected] | ||
Ankit Ahuja | ||
Ansel Santosa | ||
Anthony Grimes | ||
areos | ||
Atul Bhouraskar | ||
Aurelian Oancea | ||
Bastian Müller | ||
benbro | ||
Benjamin DeCoste | ||
Ben Keen | ||
boomyjee | ||
borawjm | ||
Brandon Frohs | ||
Brett Zamir | ||
Brian Sletten | ||
Bruce Mitchener | ||
Chandra Sekhar Pydi | ||
Charles Skelton | ||
Chris Coyier | ||
Chris Granger | ||
Chris Morgan | ||
Christopher Brown | ||
ciaranj | ||
CodeAnimal | ||
ComFreek | ||
dagsta | ||
Dan Heberden | ||
Daniel, Dao Quang Minh | ||
Daniel Faust | ||
Daniel Huigens | ||
Daniel Neel | ||
Daniel Parnell | ||
Danny Yoo | ||
David Mignot | ||
David Pathakjee | ||
deebugger | ||
Deep Thought | ||
Dominator008 | ||
Domizio Demichelis | ||
Drew Bratcher | ||
Drew Hintz | ||
Drew Khoury | ||
Dror BG | ||
duralog | ||
edsharp | ||
ekhaled | ||
Eric Allam | ||
eustas | ||
Fauntleroy | ||
fbuchinger | ||
feizhang365 | ||
Felipe Lalanne | ||
Felix Raab | ||
Filip Noetzel | ||
flack | ||
ForbesLindesay | ||
Ford_Lawnmower | ||
Gabriel Nahmias | ||
galambalazs | ||
Gautam Mehta | ||
Glenn Jorde | ||
Glenn Ruehle | ||
Golevka | ||
Gordon Smith | ||
greengiant | ||
Guillaume Massé | ||
Guillaume Massé | ||
Hans Engel | ||
Hardest | ||
Hasan Karahan | ||
Hocdoc | ||
Ian Beck | ||
Ian Wehrman | ||
Ian Wetherbee | ||
Ice White | ||
ICHIKAWA, Yuji | ||
Ingo Richter | ||
Irakli Gozalishvili | ||
Ivan Kurnosov | ||
Jacob Lee | ||
Jakub Vrana | ||
James Campos | ||
James Thorne | ||
Jamie Hill | ||
Jan Jongboom | ||
jankeromnes | ||
Jan Keromnes | ||
Jan T. Sott | ||
Jason | ||
Jason Grout | ||
Jason Johnston | ||
Jason San Jose | ||
Jason Siefken | ||
Jean Boussier | ||
jeffkenton | ||
Jeff Pickhardt | ||
jem (graphite) | ||
Jochen Berger | ||
John Connor | ||
John Lees-Miller | ||
John Snelson | ||
jongalloway | ||
Joost-Wim Boekesteijn | ||
Joseph Pecoraro | ||
Joshua Newman | ||
jots | ||
Juan Benavides Romero | ||
Jucovschi Constantin | ||
[email protected] | ||
kaniga | ||
Ken Newman | ||
Ken Rockot | ||
Kevin Sawicki | ||
Klaus Silveira | ||
Koh Zi Han, Cliff | ||
komakino | ||
Konstantin Lopuhin | ||
koops | ||
ks-ifware | ||
kubelsmieci | ||
Lanny | ||
leaf corcoran | ||
Leonya Khachaturov | ||
Liam Newman | ||
LM | ||
Lorenzo Stoakes | ||
lynschinzer | ||
Maksim Lin | ||
Maksym Taran | ||
Marat Dreizin | ||
Marco Aurélio | ||
Marijn Haverbeke | ||
Mario Pietsch | ||
Mark Lentczner | ||
Martin Balek | ||
Martín Gaitán | ||
Mason Malone | ||
Mateusz Paprocki | ||
mats cronqvist | ||
Matthew Beale | ||
Matthias BUSSONNIER | ||
Matt McDonald | ||
Matt Pass | ||
Matt Sacks | ||
Maximilian Hils | ||
Max Kirsch | ||
mbarkhau | ||
Metatheos | ||
Micah Dubinko | ||
Michael Lehenbauer | ||
Michael Zhou | ||
Mighty Guava | ||
Miguel Castillo | ||
Mike | ||
Mike Brevoort | ||
Mike Diaz | ||
Mike Ivanov | ||
Mike Kadin | ||
MinRK | ||
misfo | ||
mps | ||
Narciso Jaramillo | ||
Nathan Williams | ||
nerbert | ||
nguillaumin | ||
Niels van Groningen | ||
Nikita Beloglazov | ||
Nikita Vasilyev | ||
nlwillia | ||
pablo | ||
Page | ||
Patrick Strawderman | ||
Paul Garvin | ||
Paul Ivanov | ||
Pavel Feldman | ||
Paweł Bartkiewicz | ||
peteguhl | ||
peterkroon | ||
Peter Kroon | ||
prasanthj | ||
Prasanth J | ||
Rahul | ||
Randy Edmunds | ||
Richard Z.H. Wang | ||
robertop23 | ||
Robert Plummer | ||
Ruslan Osmanov | ||
sabaca | ||
Samuel Ainsworth | ||
sandeepshetty | ||
santec | ||
Sascha Peilicke | ||
satchmorun | ||
sathyamoorthi | ||
SCLINIC\jdecker | ||
shaund | ||
shaun gilchrist | ||
Shmuel Englard | ||
sonson | ||
spastorelli | ||
Stas Kobzar | ||
Stefan Borsje | ||
Steffen Beyer | ||
Steve O'Hara | ||
stoskov | ||
Tarmil | ||
tfjgeorge | ||
Thaddee Tyl | ||
think | ||
Thomas Dvornik | ||
Thomas Schmid | ||
Tim Baumann | ||
Timothy Farrell | ||
Timothy Hatcher | ||
TobiasBg | ||
Tomas-A | ||
Tomas Varaneckas | ||
Tom Erik Støwer | ||
Tom MacWright | ||
Tony Jian | ||
Vestimir Markov | ||
vf | ||
Volker Mische | ||
William Jamieson | ||
Wojtek Ptak | ||
Xavier Mendez | ||
Yunchi Luo | ||
Yuvi Panda | ||
Zachary Dremann |
Oops, something went wrong.