mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-19 01:17:18 +00:00
Merge branch 'dev' of github.com:coderaiser/cloudcmd into dev
This commit is contained in:
commit
63baa185a2
6 changed files with 227 additions and 18 deletions
|
|
@ -20,12 +20,6 @@ body { margin: 0; font-size: 1em; line-height: 1.4; }
|
|||
/*
|
||||
::selection { background: #fe57a1; color: #fff; text-shadow: none; }
|
||||
*/
|
||||
::-moz-selection{ text-shadow: none; opacity: 0;}
|
||||
::selection {
|
||||
text-shadow: none;
|
||||
opacity: 0;
|
||||
background-color:white; /* opera */
|
||||
}
|
||||
|
||||
|
||||
/* =============================================================================
|
||||
|
|
@ -81,4 +75,4 @@ a:hover, a:active { outline: 0; }
|
|||
a[href]:after { content: " (" attr(href) ")"; }
|
||||
.ir a:after, a[href^="javascript:"]:after, a[href^="#"]:after { content: ""; } /* Don't show links for images, or javascript/internal links */
|
||||
@page { margin: 0.5cm; }
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,6 +31,18 @@ body{
|
|||
background-color:white;
|
||||
}
|
||||
|
||||
#fm::-moz-selection, #left>li::-moz-selection, #right>li::-moz-selection, .path::-moz-selection, .fm-header::-moz-selection,
|
||||
.mini-icon::-moz-selection, .name::-moz-selection, .size::-moz-selection, .owner::-moz-selection, .mode::-moz-selection {
|
||||
text-shadow: none; opacity: 0;
|
||||
}
|
||||
|
||||
#fm::selection, #left>li::selection, #right>li::selection, .path::selection, .fm-header::selection,
|
||||
.mini-icon::selection, .name::selection, .size::selection, .owner::selection, .mode::selection {
|
||||
text-shadow: none;
|
||||
opacity: 0;
|
||||
background-color:white; /* opera */
|
||||
}
|
||||
|
||||
.path-icon{
|
||||
position: relative;
|
||||
top: 3px;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
var CloudCmd, Util, DOM, $;
|
||||
var CloudCmd, Util, DOM, $, jqconsole;
|
||||
(function(CloudCmd, Util, DOM){
|
||||
'use strict';
|
||||
|
||||
|
|
@ -6,8 +6,9 @@ var CloudCmd, Util, DOM, $;
|
|||
|
||||
function ConsoleProto(CloudCmd, Util, DOM){
|
||||
var Name = 'Console',
|
||||
jqconsole,
|
||||
//jqconsole,
|
||||
Element,
|
||||
MouseBinded,
|
||||
Key = CloudCmd.Key,
|
||||
Images = DOM.Images,
|
||||
Console = this;
|
||||
|
|
@ -61,8 +62,24 @@ var CloudCmd, Util, DOM, $;
|
|||
handler();
|
||||
}
|
||||
|
||||
CloudCmd.View.show(Element, function(){
|
||||
jqconsole.$input_source.focus();
|
||||
CloudCmd.View.show(Element, function(){
|
||||
var l$Console = jqconsole.$console,
|
||||
l$Input = jqconsole.$input_source,
|
||||
lFocus = l$Input.focus.bind(l$Input);
|
||||
|
||||
lFocus();
|
||||
|
||||
if (!MouseBinded) {
|
||||
MouseBinded = true;
|
||||
|
||||
$(l$Console).unbind('mouseup');
|
||||
$(l$Console).mouseup(function(){
|
||||
var lTop = l$Console.scrollTop();
|
||||
|
||||
lFocus();
|
||||
l$Console.scrollTop(lTop);
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
|
|
@ -72,14 +89,26 @@ var CloudCmd, Util, DOM, $;
|
|||
|
||||
this.log = function(pText){
|
||||
if (jqconsole)
|
||||
jqconsole.Write(pText + '\n', 'log-msg');
|
||||
jqconsole.Write( addNewLine(pText), 'log-msg');
|
||||
};
|
||||
|
||||
this.error = function(pText){
|
||||
this.error = function(pText){
|
||||
if (jqconsole)
|
||||
jqconsole.Write(pText + '\n', 'error-msg');
|
||||
jqconsole.Write( addNewLine(pText), 'error-msg');
|
||||
};
|
||||
|
||||
function addNewLine(pText){
|
||||
var lNewLine, n = pText && pText.length;
|
||||
|
||||
if(n && pText[n-1] !== '\n')
|
||||
lNewLine = '\n';
|
||||
else
|
||||
lNewLine = '';
|
||||
|
||||
return pText + lNewLine;
|
||||
}
|
||||
|
||||
|
||||
function load(pCallBack){
|
||||
Util.time(Name + ' load');
|
||||
|
||||
|
|
@ -87,6 +116,7 @@ var CloudCmd, Util, DOM, $;
|
|||
lFiles = [
|
||||
lDir + 'jqconsole.js',
|
||||
lDir + 'jqconsole.css',
|
||||
lDir + 'ansi.css',
|
||||
CloudCmd.LIBDIRCLIENT + 'terminal/jquery-terminal/jquery-migrate-1.0.0.js'
|
||||
];
|
||||
|
||||
|
|
|
|||
173
lib/client/terminal/jq-console/ansi.css
Normal file
173
lib/client/terminal/jq-console/ansi.css
Normal file
|
|
@ -0,0 +1,173 @@
|
|||
|
||||
.jqconsole-ansi-bold {
|
||||
/* font-weight: bold; */
|
||||
}
|
||||
|
||||
.jqconsole-ansi-lighter {
|
||||
font-weight: lighter;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-italic {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-underline {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
@-webkit-keyframes blinker {
|
||||
from { opacity: 1.0; }
|
||||
to { opacity: 0.0; }
|
||||
}
|
||||
|
||||
@-moz-keyframes blinker {
|
||||
from { opacity: 1.0; }
|
||||
to { opacity: 0.0; }
|
||||
}
|
||||
|
||||
@-ms-keyframes blinker {
|
||||
from { opacity: 1.0; }
|
||||
to { opacity: 0.0; }
|
||||
}
|
||||
|
||||
@-o-keyframes blinker {
|
||||
from { opacity: 1.0; }
|
||||
to { opacity: 0.0; }
|
||||
}
|
||||
|
||||
.jqconsole-ansi-blink {
|
||||
-webkit-animation-name: blinker;
|
||||
-moz-animation-name: blinker;
|
||||
-ms-animation-name: blinker;
|
||||
-o-animation-name: blinker;
|
||||
-webkit-animation-iteration-count: infinite;
|
||||
-moz-animation-iteration-count: infinite;
|
||||
-ms-animation-iteration-count: infinite;
|
||||
-o-animation-iteration-count: infinite;
|
||||
-webkit-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-ms-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-o-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-moz-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-webkit-animation-duration: 1s;
|
||||
-moz-animation-duration: 1s;
|
||||
-o-animation-duration: 1s;
|
||||
-ms-animation-duration: 1s;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-blink-rapid {
|
||||
-webkit-animation-name: blinker;
|
||||
-moz-animation-name: blinker;
|
||||
-ms-animation-name: blinker;
|
||||
-o-animation-name: blinker;
|
||||
-webkit-animation-iteration-count: infinite;
|
||||
-moz-animation-iteration-count: infinite;
|
||||
-ms-animation-iteration-count: infinite;
|
||||
-o-animation-iteration-count: infinite;
|
||||
-webkit-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-ms-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-o-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-moz-animation-timing-function: cubic-bezier(1.0,0,0,1.0);
|
||||
-webkit-animation-duration: 0.5s;
|
||||
-moz-animation-duration: 0.5s;
|
||||
-o-animation-duration: 0.5s;
|
||||
-ms-animation-duration: 0.5s;
|
||||
}
|
||||
|
||||
|
||||
.jqconsole-ansi-hidden {
|
||||
visibility:hidden;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-line-through {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-fonts-1 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-2 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-3 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-4 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-5 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-6 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-7 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-8 {
|
||||
|
||||
}
|
||||
.jqconsole-ansi-fonts-9 {
|
||||
|
||||
}
|
||||
|
||||
.jqconsole-ansi-fraktur {
|
||||
|
||||
}
|
||||
|
||||
.jqconsole-ansi-color-black {
|
||||
color: black;
|
||||
}
|
||||
.jqconsole-ansi-color-red {
|
||||
color: red;
|
||||
}
|
||||
.jqconsole-ansi-color-green {
|
||||
color: #65b04b;
|
||||
}
|
||||
.jqconsole-ansi-color-yellow {
|
||||
color: #fed563;
|
||||
}
|
||||
.jqconsole-ansi-color-blue {
|
||||
color: rgb(49,123,249);
|
||||
}
|
||||
.jqconsole-ansi-color-magenta {
|
||||
color: magenta;
|
||||
}
|
||||
.jqconsole-ansi-color-cyan {
|
||||
color: cyan;
|
||||
}
|
||||
.jqconsole-ansi-color-white {
|
||||
color: white;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-background-color-black {
|
||||
background-color: black;
|
||||
}
|
||||
.jqconsole-ansi-background-color-red {
|
||||
background-color: red;
|
||||
}
|
||||
.jqconsole-ansi-background-color-green {
|
||||
background-color: #65b04b;
|
||||
}
|
||||
.jqconsole-ansi-background-color-yellow {
|
||||
background-color: #fed563;
|
||||
}
|
||||
.jqconsole-ansi-background-color-blue {
|
||||
background-color: blue;
|
||||
}
|
||||
.jqconsole-ansi-background-color-magenta {
|
||||
background-color: magenta;
|
||||
}
|
||||
.jqconsole-ansi-background-color-cyan {
|
||||
background-color: cyan;
|
||||
}
|
||||
.jqconsole-ansi-background-color-white {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
.jqconsole-ansi-framed {
|
||||
border: 1px solid;
|
||||
}
|
||||
.jqconsole-ansi-overline {
|
||||
text-decoration: overline;
|
||||
}
|
||||
|
||||
|
|
@ -19,10 +19,7 @@
|
|||
.error-msg, .log-msg{
|
||||
background-color: #f5f5f5;
|
||||
display: block;
|
||||
font: monospace 16px "Droid Sans Mono";
|
||||
white-space: pre-wrap;
|
||||
word-break: normal;
|
||||
word-wrap: normal;
|
||||
font: 16px "Droid Sans Mono";
|
||||
margin: 10px;
|
||||
padding: 10px;
|
||||
background: beige;
|
||||
|
|
@ -36,6 +33,7 @@
|
|||
padding: 10px;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
|
||||
.jqconsole-cursor {
|
||||
background-color: #999;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,6 +26,8 @@ var CloudCmd, Util, DOM, CloudFunc, $;
|
|||
closeEffect : 'none',
|
||||
autoSize : false,
|
||||
height : window.innerHeight,
|
||||
width : window.innerWidth/1.75,
|
||||
|
||||
helpers : {
|
||||
overlay : {
|
||||
css : {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue