mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-26 10:26:15 -04:00
Merge branch 'master' into timeslider-realtimeupdate+readonly-pads
This commit is contained in:
commit
c173ebe197
11 changed files with 408 additions and 394 deletions
|
@ -1,138 +1,123 @@
|
|||
body {
|
||||
margin: 0;
|
||||
height: 100%;
|
||||
color: #333;
|
||||
font: 14px helvetica, sans-serif;
|
||||
background: #ddd;
|
||||
background: -webkit-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
background: -moz-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
background: -ms-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
background: -o-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
border-top: 8px solid rgba(51,51,51,.8);
|
||||
}
|
||||
#wrapper {
|
||||
border-top: 1px solid #999;
|
||||
margin-top: 160px;
|
||||
padding: 15px;
|
||||
background: #eee;
|
||||
background: -webkit-linear-gradient(#fff,#ccc);
|
||||
background: -moz-linear-gradient(#fff,#ccc);
|
||||
background: -ms-linear-gradient(#fff,#ccc);
|
||||
background: -o-linear-gradient(#fff,#ccc);
|
||||
opacity: .9;
|
||||
box-shadow: 0px 1px 8px rgba(0,0,0,0.3);
|
||||
max-width: 1200px;
|
||||
margin: auto;
|
||||
}
|
||||
#inner {
|
||||
width: 300px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
#button:hover {
|
||||
cursor: pointer;
|
||||
background: #666;
|
||||
background: -webkit-linear-gradient(#707070,#666666 50%,#5B5B5B 51%,#474747);
|
||||
background: -moz-linear-gradient(#707070,#666666 50%,#5B5B5B 51%,#474747);
|
||||
background: -ms-linear-gradient(#707070,#666666 50%,#5B5B5B 51%,#474747);
|
||||
background: -o-linear-gradient(#707070,#666666 50%,#5B5B5B 51%,#474747);
|
||||
}
|
||||
#button:active {
|
||||
box-shadow: inset 0 1px 12px rgba(0,0,0,0.9);
|
||||
background: #444;
|
||||
}
|
||||
#label {
|
||||
text-align: left;
|
||||
text-shadow: 0 1px 1px #fff;
|
||||
margin: 16px auto 0;
|
||||
}
|
||||
form {
|
||||
border: 1px solid #bbb;
|
||||
border-radius: 3px;
|
||||
position: relative;
|
||||
}
|
||||
button, input {
|
||||
font-weight: bold;
|
||||
font-size: 15px;
|
||||
}
|
||||
input[type="button"] {
|
||||
height:30px;
|
||||
}
|
||||
input[type="text"] {
|
||||
border-radius: 3px;
|
||||
box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
padding: 10px 45px 10px 10px;
|
||||
*padding: 0; /* IE7 hack */
|
||||
width: 100%;
|
||||
outline: none;
|
||||
border: none;
|
||||
}
|
||||
button{
|
||||
display:block;
|
||||
}
|
||||
@media only screen and (min-device-width: 320px) and (max-device-width: 720px) {
|
||||
body {
|
||||
background: #bbb;
|
||||
background: -webkit-linear-gradient(#aaa,#eee 60%) center fixed;
|
||||
background: -moz-linear-gradient(#aaa,#eee 60%) center fixed;
|
||||
background: -ms-linear-gradient(#aaa,#eee 60%) center fixed;
|
||||
}
|
||||
#wrapper {
|
||||
margin-top: 0;
|
||||
}
|
||||
#inner {
|
||||
width: 95%;
|
||||
}
|
||||
#label {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
}
|
||||
td, th {
|
||||
border: 1px solid black;
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 2px;
|
||||
}
|
||||
.template {
|
||||
display: none;
|
||||
}
|
||||
.dialog {
|
||||
display: none;
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
width: 700px;
|
||||
height: 500px;
|
||||
margin-left: -350px;
|
||||
margin-top: -250px;
|
||||
border: 3px solid #999999;
|
||||
background: #eeeeee;
|
||||
}
|
||||
.dialog .title {
|
||||
margin: 0;
|
||||
padding: 2px;
|
||||
border-bottom: 3px solid #999999;
|
||||
font-size: 24px;
|
||||
line-height: 24px;
|
||||
height: 24px;
|
||||
overflow: hidden;
|
||||
}
|
||||
.dialog .title .close {
|
||||
float: right;
|
||||
}
|
||||
.dialog .history {
|
||||
background: #222222;
|
||||
color: #eeeeee;
|
||||
position: absolute;
|
||||
top: 41px;
|
||||
bottom: 10px;
|
||||
left: 10px;
|
||||
right: 10px;
|
||||
padding: 2px;
|
||||
overflow: auto;
|
||||
}
|
||||
body {
|
||||
margin: 0;
|
||||
height: 100%;
|
||||
color: #333;
|
||||
font: 14px helvetica, sans-serif;
|
||||
background: #ddd;
|
||||
background: -webkit-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
background: -moz-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
background: -ms-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
background: -o-radial-gradient(circle,#aaa,#eee 60%) center fixed;
|
||||
border-top: 8px solid rgba(51,51,51,.8);
|
||||
}
|
||||
#wrapper {
|
||||
margin-top: 160px;
|
||||
padding: 15px;
|
||||
background: #fff;
|
||||
opacity: .9;
|
||||
box-shadow: 0px 1px 8px rgba(0,0,0,0.3);
|
||||
max-width: 700px;
|
||||
margin: auto;
|
||||
border-radius: 0 0 7px 7px;
|
||||
}
|
||||
h1 {
|
||||
font-size: 29px;
|
||||
}
|
||||
h2 {
|
||||
font-size: 24px;
|
||||
}
|
||||
.seperator {
|
||||
margin: 10px 0;
|
||||
height: 1px;
|
||||
background: #aaa;
|
||||
background: -webkit-linear-gradient(left, #fff, #aaa 20%, #aaa 80%, #fff);
|
||||
background: -moz-linear-gradient(left, #fff, #aaa 20%, #aaa 80%, #fff);
|
||||
background: -ms-linear-gradient(left, #fff, #aaa 20%, #aaa 80%, #fff);
|
||||
background: -o-linear-gradient(left, #fff, #aaa 20%, #aaa 80%, #fff);
|
||||
}
|
||||
form {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
#inner {
|
||||
width: 300px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
input {
|
||||
font-weight: bold;
|
||||
font-size: 15px;
|
||||
}
|
||||
input[type="button"] {
|
||||
padding: 4px 6px;
|
||||
margin: 0;
|
||||
}
|
||||
input[type="button"].do-install, input[type="button"].do-uninstall {
|
||||
float: right;
|
||||
width: 100px;
|
||||
}
|
||||
input[type="button"]#do-search {
|
||||
display: block;
|
||||
}
|
||||
input[type="text"] {
|
||||
border-radius: 3px;
|
||||
box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
padding: 10px;
|
||||
*padding: 0; /* IE7 hack */
|
||||
width: 100%;
|
||||
outline: none;
|
||||
border: 1px solid #ddd;
|
||||
margin: 0 0 5px 0;
|
||||
max-width: 500px;
|
||||
}
|
||||
table {
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 3px;
|
||||
border-spacing: 0;
|
||||
width: 100%;
|
||||
margin: 20px 0;
|
||||
}
|
||||
table thead tr {
|
||||
background: #eee;
|
||||
}
|
||||
td, th {
|
||||
padding: 5px;
|
||||
}
|
||||
.template {
|
||||
display: none;
|
||||
}
|
||||
.dialog {
|
||||
display: none;
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
width: 700px;
|
||||
height: 500px;
|
||||
margin-left: -350px;
|
||||
margin-top: -250px;
|
||||
border: 3px solid #999;
|
||||
background: #eee;
|
||||
}
|
||||
.dialog .title {
|
||||
margin: 0;
|
||||
padding: 2px;
|
||||
border-bottom: 3px solid #999;
|
||||
font-size: 24px;
|
||||
line-height: 24px;
|
||||
height: 24px;
|
||||
overflow: hidden;
|
||||
}
|
||||
.dialog .title .close {
|
||||
float: right;
|
||||
padding: 1px 10px;
|
||||
}
|
||||
.dialog .history {
|
||||
background: #222;
|
||||
color: #eee;
|
||||
position: absolute;
|
||||
top: 41px;
|
||||
bottom: 10px;
|
||||
left: 10px;
|
||||
right: 10px;
|
||||
padding: 2px;
|
||||
overflow: auto;
|
||||
}
|
|
@ -167,7 +167,13 @@ require.setGlobalKeyPath("require");\n\
|
|||
buffer.push(Ace2Editor.EMBEDED[KERNEL_SOURCE]);
|
||||
buffer.push(KERNEL_BOOT);
|
||||
buffer.push('<\/script>');
|
||||
}
|
||||
} else {
|
||||
file = KERNEL_SOURCE;
|
||||
buffer.push('<script type="application/javascript" src="' + KERNEL_SOURCE + '"><\/script>');
|
||||
buffer.push('<script type="text/javascript">');
|
||||
buffer.push(KERNEL_BOOT);
|
||||
buffer.push('<\/script>');
|
||||
}
|
||||
}
|
||||
function pushScriptsTo(buffer) {
|
||||
/* Folling is for packaging regular expression. */
|
||||
|
|
|
@ -229,6 +229,10 @@ domline.createDomLine = function(nonEmpty, doesWrap, optBrowser, optDocument)
|
|||
result.node.innerHTML = curHTML;
|
||||
}
|
||||
if (lineClass !== null) result.node.className = lineClass;
|
||||
|
||||
hooks.callAll("acePostWriteDomLineHTML", {
|
||||
node: result.node
|
||||
});
|
||||
}
|
||||
result.prepareForAdd = writeHTML;
|
||||
result.finishUpdate = writeHTML;
|
||||
|
|
|
@ -203,7 +203,8 @@ function handshake()
|
|||
//create the url
|
||||
var url = loc.protocol + "//" + loc.hostname + ":" + port + "/";
|
||||
//find out in which subfolder we are
|
||||
var resource = loc.pathname.substr(1, loc.pathname.indexOf("/p/")) + "socket.io";
|
||||
var resource = exports.baseURL + "socket.io";
|
||||
|
||||
//connect
|
||||
socket = pad.socket = io.connect(url, {
|
||||
resource: resource,
|
||||
|
@ -1035,7 +1036,7 @@ var settings = {
|
|||
};
|
||||
|
||||
pad.settings = settings;
|
||||
|
||||
exports.baseURL = '';
|
||||
exports.settings = settings;
|
||||
exports.createCookie = createCookie;
|
||||
exports.readCookie = readCookie;
|
||||
|
|
|
@ -182,7 +182,7 @@ var padeditbar = (function()
|
|||
//hide all modules
|
||||
if(moduleName == "none")
|
||||
{
|
||||
$("#editbar ul#menu_right > li").removeClass("selected");
|
||||
$(".toolbar ul.menu_right li").removeClass("selected");
|
||||
for(var i=0;i<modules.length;i++)
|
||||
{
|
||||
//skip the userlist
|
||||
|
@ -200,11 +200,11 @@ var padeditbar = (function()
|
|||
else
|
||||
{
|
||||
var nth_child = indexOf(modules, moduleName) + 1;
|
||||
if (nth_child > 0 && nth_child <= (modules.length-1)) {
|
||||
$("#editbar ul#menu_right li:not(:nth-child(" + nth_child + "))").removeClass("selected");
|
||||
$("#editbar ul#menu_right li:nth-child(" + nth_child + ")").toggleClass("selected");
|
||||
}
|
||||
if(modules[modules.length-1] === moduleName) $("#editbar ul#menu_right li").removeClass("selected");
|
||||
if (nth_child > 0 && nth_child <= (modules.length-1)) {
|
||||
$(".toolbar ul.menu_right li:not(:nth-child(" + nth_child + "))").removeClass("selected");
|
||||
$(".toolbar ul.menu_right li:nth-child(" + nth_child + ")").toggleClass("selected");
|
||||
}
|
||||
if(modules[modules.length-1] === moduleName) $(".toolbar ul.menu_right li").removeClass("selected");
|
||||
//hide all modules that are not selected and show the selected one
|
||||
for(var i=0;i<modules.length;i++)
|
||||
{
|
||||
|
|
|
@ -748,13 +748,14 @@ function closeColorPicker(accept)
|
|||
var newColor = $("#mycolorpickerpreview").css("background-color");
|
||||
var parts = newColor.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/);
|
||||
// parts now should be ["rgb(0, 70, 255", "0", "70", "255"]
|
||||
delete (parts[0]);
|
||||
for (var i = 1; i <= 3; ++i) {
|
||||
parts[i] = parseInt(parts[i]).toString(16);
|
||||
if (parts[i].length == 1) parts[i] = '0' + parts[i];
|
||||
if (parts) {
|
||||
delete (parts[0]);
|
||||
for (var i = 1; i <= 3; ++i) {
|
||||
parts[i] = parseInt(parts[i]).toString(16);
|
||||
if (parts[i].length == 1) parts[i] = '0' + parts[i];
|
||||
}
|
||||
var newColor = "#" +parts.join(''); // "0070ff"
|
||||
}
|
||||
var newColor = "#" +parts.join(''); // "0070ff"
|
||||
|
||||
myUserInfo.colorId = newColor;
|
||||
pad.notifyChangeColor(newColor);
|
||||
paduserlist.renderMyUserInfo();
|
||||
|
|
|
@ -24,6 +24,7 @@ exports.loaded = false;
|
|||
exports.plugins = {};
|
||||
exports.parts = [];
|
||||
exports.hooks = {};
|
||||
exports.baseURL = '';
|
||||
|
||||
exports.ensure = function (cb) {
|
||||
if (!exports.loaded)
|
||||
|
@ -103,7 +104,7 @@ if (exports.isClient) {
|
|||
// which appears to fix the issue.
|
||||
var callback = function () {setTimeout(cb, 0);};
|
||||
|
||||
jQuery.getJSON('/pluginfw/plugin-definitions.json', function(data) {
|
||||
jQuery.getJSON(exports.baseURL + 'pluginfw/plugin-definitions.json', function(data) {
|
||||
exports.plugins = data.plugins;
|
||||
exports.parts = data.parts;
|
||||
exports.hooks = exports.extractHooks(exports.parts, "client_hooks");
|
||||
|
|
|
@ -60,8 +60,8 @@ function init() {
|
|||
//create the url
|
||||
var url = loc.protocol + "//" + loc.hostname + ":" + port + "/";
|
||||
//find out in which subfolder we are
|
||||
var resource = loc.pathname.substr(1,loc.pathname.indexOf("/p/")) + "socket.io";
|
||||
|
||||
var resource = exports.baseURL + 'socket.io';
|
||||
|
||||
//build up the socket io connection
|
||||
socket = io.connect(url, {resource: resource});
|
||||
|
||||
|
@ -162,4 +162,5 @@ function handleClientVars(message)
|
|||
}
|
||||
}
|
||||
|
||||
exports.baseURL = '';
|
||||
exports.init = init;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue