mirror of
https://github.com/mickael-kerjean/filestash.git
synced 2026-10-19 16:14:39 +00:00
maintenance (cleanup): remove dead code and comments
This commit is contained in:
@@ -82,7 +82,7 @@ export class Editor extends React.Component {
|
||||
|
||||
updateHeight(height){
|
||||
if(height){
|
||||
//document.querySelector('.CodeMirror').style.height = height+'px';
|
||||
document.querySelector('.CodeMirror').style.height = height+'px';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -142,12 +142,3 @@ Editor.propTypes = {
|
||||
onChange: PropTypes.func,
|
||||
onSave: PropTypes.func
|
||||
}
|
||||
|
||||
// function load(mode){
|
||||
// let url = 'https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.26.0/mode/'+mode+'/'+mode+'.js';
|
||||
// var script = document.createElement('script');
|
||||
// script.type = 'text/javascript';
|
||||
// script.src = url;
|
||||
// document.getElementsByTagName('head')[0].appendChild(script);
|
||||
// return mode;
|
||||
// }
|
||||
|
||||
@@ -82,12 +82,6 @@ export class FileSystem extends React.Component {
|
||||
onComponentPropsUpdate(props){
|
||||
this.setState({access_right: this._findAccessRight(props.files)});
|
||||
}
|
||||
|
||||
// IN NEW THING
|
||||
// onCreating={(value) => this.setState({creating: value})} onCreate={this.onCreate.bind(this)}
|
||||
|
||||
// IN FILEZONE
|
||||
// onUpload={this.onUpload.bind(this)}
|
||||
|
||||
render() {
|
||||
return this.props.connectDropFile(
|
||||
|
||||
@@ -4,15 +4,13 @@ CodeMirror.__mode = 'orgmode';
|
||||
|
||||
CodeMirror.defineSimpleMode("orgmode", {
|
||||
start: [
|
||||
{regex: /^(^\*{1,6}\s)(TODO|DOING|WAITING){0,1}(CANCEL|DEFERRED|DONE){0,1}(.*)$/, token: ["header org-level-star", "header org-todo", "header org-done", "header"]},
|
||||
{regex: /^(^\*{1,6}\s)(TODO|DOING|WAITING|NEXT){0,1}(CANCELLED|CANCEL|DEFERRED|DONE|REJECTED|STOP|STOPPED){0,1}(.*)$/, token: ["header org-level-star", "header org-todo", "header org-done", "header"]},
|
||||
{regex: /(^\+[^\/]*\+)/, token: ["strikethrough"]},
|
||||
{regex: /(^\*[^\/]*\*)/, token: ["strong"]},
|
||||
{regex: /(^\/[^\/]*\/)/, token: ["em"]},
|
||||
{regex: /(^\_[^\/]*\_)/, token: ["link"]},
|
||||
{regex: /(^\~[^\/]*\~)/, token: ["comment"]},
|
||||
{regex: /(^\=[^\/]*\=)/, token: ["comment"]},
|
||||
// special syntax
|
||||
//{regex: /(^[\*]+)(\s[TODO|NEXT|DONE|DEFERRED|REJECTED|WAITING]{2,})?(.*)/, token: ['comment', 'qualifier', 'header']}, // headline
|
||||
{regex: /\[\[[^\[\]]*\]\[[^\[\]]*\]\]/, token: "url"}, // links
|
||||
{regex: /\[[xX\s]?\]/, token: 'qualifier'}, // checkbox
|
||||
{regex: /\#\+BEGIN_[A-Z]*/, token: "comment", next: "env"}, // comments
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
// export function test(){
|
||||
// return 'aaaa';
|
||||
// }
|
||||
|
||||
|
||||
function cube(x) {
|
||||
return x * x * x;
|
||||
}
|
||||
const foo = Math.PI + Math.SQRT2;
|
||||
export { cube, foo };
|
||||
@@ -10,15 +10,12 @@ export class VideoPlayer extends React.Component {
|
||||
|
||||
componentDidMount(){
|
||||
this.player = videojs(this.videoNode, {
|
||||
//autoplay: true,
|
||||
controls: true,
|
||||
aspectRatio: '16:9',
|
||||
fluid: false,
|
||||
sources: [{
|
||||
src: this.props.data
|
||||
}]
|
||||
}, function onPlayerReady() {
|
||||
//console.log('onPlayerReady', this)
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user