resolve merge conflict

This commit is contained in:
John McLear 2013-01-27 17:54:26 +00:00
commit 3fac18f88a
22 changed files with 517 additions and 137 deletions

View File

@ -4,6 +4,7 @@ outdoc_files = $(addprefix out/,$(doc_sources:.md=.html))
docassets = $(addprefix out/,$(wildcard doc/assets/*))
VERSION = $(shell node -e "console.log( require('./src/package.json').version )")
UNAME := $(shell uname -s)
docs: $(outdoc_files) $(docassets)
@ -14,7 +15,11 @@ out/doc/assets/%: doc/assets/%
out/doc/%.html: doc/%.md
mkdir -p $(@D)
node tools/doc/generate.js --format=html --template=doc/template.html $< > $@
cat $@ | sed 's/__VERSION__/${VERSION}/' > $@
ifeq ($(UNAME),Darwin)
sed -i '' 's/__VERSION__/${VERSION}/' $@
else
sed -i 's/__VERSION__/${VERSION}/' $@
endif
clean:
rm -rf out/

View File

@ -292,6 +292,34 @@ returns the text of a pad formatted as HTML
* `{code: 0, message:"ok", data: {html:"Welcome Text<br>More Text"}}`
* `{code: 1, message:"padID does not exist", data: null}`
### Chat
#### getChatHistory(padID, [start, end])
* API >= 1.2.7
returns
* a part of the chat history, when `start` and `end` are given
* the whole chat histroy, when no extra parameters are given
*Example returns:*
* `{"code":0,"message":"ok","data":{"messages":[{"text":"foo","userId":"a.foo","time":1359199533759,"userName":"test"},{"text":"bar","userId":"a.foo","time":1359199534622,"userName":"test"}]}}`
* `{code: 1, message:"start is higher or equal to the current chatHead", data: null}`
* `{code: 1, message:"padID does not exist", data: null}`
#### getChatHead(padID)
* API >= 1.2.7
returns the chatHead (last number of the last chat-message) of the pad
*Example returns:*
* `{code: 0, message:"ok", data: {chatHead: 42}}`
* `{code: 1, message:"padID does not exist", data: null}`
### Pad
Group pads are normal pads, but with the name schema GROUPID$PADNAME. A security manager controls access of them and its forbidden for normal pads to include a $ in the name.

View File

@ -101,5 +101,5 @@
"loglevel": "INFO",
// restrict socket.io transport methods
"socketTransportProtocols" : ['xhr-polling', 'jsonp-polling', 'htmlfile']
"socketTransportProtocols" : ["xhr-polling", "jsonp-polling", "htmlfile"]
}

File diff suppressed because one or more lines are too long

View File

@ -278,6 +278,77 @@ exports.setHTML = function(padID, html, callback)
});
}
/******************/
/**CHAT FUNCTIONS */
/******************/
/**
getChatHistory(padId, start, end), returns a part of or the whole chat-history of this pad
Example returns:
{"code":0,"message":"ok","data":{"messages":[{"text":"foo","userId":"a.foo","time":1359199533759,"userName":"test"},
{"text":"bar","userId":"a.foo","time":1359199534622,"userName":"test"}]}}
{code: 1, message:"start is higher or equal to the current chatHead", data: null}
{code: 1, message:"padID does not exist", data: null}
*/
exports.getChatHistory = function(padID, start, end, callback)
{
if(start && end)
{
if(start < 0)
{
callback(new customError("start is below zero","apierror"));
return;
}
if(end < 0)
{
callback(new customError("end is below zero","apierror"));
return;
}
if(start > end)
{
callback(new customError("start is higher than end","apierror"));
return;
}
}
//get the pad
getPadSafe(padID, true, function(err, pad)
{
if(ERR(err, callback)) return;
var chatHead = pad.chatHead;
// fall back to getting the whole chat-history if a parameter is missing
if(!start || !end)
{
start = 0;
end = pad.chatHead - 1;
}
if(start >= chatHead)
{
callback(new customError("start is higher or equal to the current chatHead","apierror"));
return;
}
if(end >= chatHead)
{
callback(new customError("end is higher or equal to the current chatHead","apierror"));
return;
}
// the the whole message-log and return it to the client
pad.getChatMessages(start, end,
function(err, msgs)
{
if(ERR(err, callback)) return;
callback(null, {messages: msgs});
});
});
}
/*****************/
/**PAD FUNCTIONS */
/*****************/
@ -568,6 +639,23 @@ exports.checkToken = function(callback)
callback();
}
/**
getChatHead(padID) returns the chatHead (last number of the last chat-message) of the pad
Example returns:
{code: 0, message:"ok", data: {chatHead: 42}}
{code: 1, message:"padID does not exist", data: null}
*/
exports.getChatHead = function(padID, callback)
{
//get the pad
getPadSafe(padID, true, function(err, pad)
{
if(ERR(err, callback)) return;
callback(null, {chatHead: pad.chatHead});
});
}
/**
createDiff(padID, startRev, endRev) returns an object of diffs from 2 points in a pad

View File

@ -174,13 +174,13 @@ var version =
, "listAllGroups" : []
, "checkToken" : []
}
, "1.2.2":
, "1.2.7":
{ "createGroup" : []
, "createGroupIfNotExistsFor" : ["groupMapper"]
, "deleteGroup" : ["groupID"]
, "listPads" : ["groupID"]
, "listAllPads" : []
, "createDiff" : ["padID", "startRev", "endRev"]
, "createDiff" : ["padID", "startRev", "endRev"]
, "createPad" : ["padID", "text"]
, "createGroupPad" : ["groupID", "padName", "text"]
, "createAuthor" : ["name"]
@ -210,6 +210,9 @@ var version =
, "sendClientsMessage" : ["padID", "msg"]
, "listAllGroups" : []
, "checkToken" : []
, "getChatHistory" : ["padID"]
, "getChatHistory" : ["padID", "start", "end"]
, "getChatHead" : ["padID"]
}
};

View File

@ -176,7 +176,7 @@ exports.doImport = function(req, res, padId)
ERR(err);
//close the connection
res.send("<head><script type='text/javascript' src='../../static/js/jquery.js'></script></head><script>$(window).load(function(){if ( (!$.browser.msie) && (!($.browser.mozilla && $.browser.version.indexOf(\"1.8.\") == 0)) ){document.domain = document.domain;}var impexp = window.parent.require('/pad_impexp').padimpexp.handleFrameCall('" + status + "');})</script>", 200);
res.send("<head><script type='text/javascript' src='../../static/js/jquery.js'></script></head><script>$(window).load(function(){if ( (!$.browser.msie) && (!($.browser.mozilla && $.browser.version.indexOf(\"1.8.\") == 0)) ){document.domain = document.domain;}var impexp = window.parent.padimpexp.handleFrameCall('" + status + "');})</script>", 200);
});
}

View File

@ -2,6 +2,9 @@ var path = require('path');
var eejs = require('ep_etherpad-lite/node/eejs');
var installer = require('ep_etherpad-lite/static/js/pluginfw/installer');
var plugins = require('ep_etherpad-lite/static/js/pluginfw/plugins');
var _ = require('underscore');
var semver = require('semver');
var async = require('async');
exports.expressCreateServer = function (hook_name, args, cb) {
args.app.get('/admin/plugins', function(req, res) {
@ -25,8 +28,26 @@ exports.socketio = function (hook_name, args, cb) {
if (!socket.handshake.session.user || !socket.handshake.session.user.is_admin) return;
socket.on("load", function (query) {
// send currently installed plugins
socket.emit("installed-results", {results: plugins.plugins});
socket.emit("progress", {progress:1});
});
socket.on("checkUpdates", function() {
socket.emit("progress", {progress:0, message:'Checking for plugin updates...'});
// Check plugins for updates
installer.search({offset: 0, pattern: '', limit: 500}, /*useCache:*/true, function(data) { // hacky
if (!data.results) return;
var updatable = _(plugins.plugins).keys().filter(function(plugin) {
if(!data.results[plugin]) return false;
var latestVersion = data.results[plugin]['dist-tags'].latest
var currentVersion = plugins.plugins[plugin].package.version
return semver.gt(latestVersion, currentVersion)
});
socket.emit("updatable", {updatable: updatable});
socket.emit("progress", {progress:1});
});
})
socket.on("search", function (query) {
socket.emit("progress", {progress:0, message:'Fetching results...'});

View File

@ -7,17 +7,52 @@ body {
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;
#topborder {
border-top: 8px solid rgba(51, 51, 51, 0.8);
position: fixed;
top: 0px;
width: 100%;
}
div.menu {
background: none repeat scroll 0% 0% rgba(255, 255, 255, 0.75);
box-shadow: 0px -4px 4px rgba(0, 0, 0, 0.3);
display: block;
float: left;
height: 100%;
padding: 15px;
position: fixed;
width: 220px;
}
div.menu li {
list-style: none;
margin-left: 3px;
line-height: 1.6
}
div.innerwrapper {
display: block;
float: right;
opacity: 0.9;
padding: 15px;
background: #fff;
opacity: .9;
box-shadow: 0px 1px 8px rgba(0,0,0,0.3);
max-width: 700px;
margin: auto;
max-width: 860px;
border-radius: 0 0 7px 7px;
margin-left:250px;
min-width:400px;
}
#wrapper {
background: none repeat scroll 0px 0px #FFFFFF;
box-shadow: 0px 1px 8px rgba(0, 0, 0, 0.3);
margin: auto;
max-width: 1150px;
min-height: 100%;
overflow: auto;
padding-left: 15px;
opacity: .9;
}
h1 {
font-size: 29px;
@ -49,13 +84,10 @@ input[type="button"] {
padding: 4px 6px;
margin: 0;
}
input[type="button"].do-install, input[type="button"].do-uninstall {
table input[type="button"] {
float: right;
width: 100px;
}
input[type="button"]#do-search {
display: block;
}
input[type="text"] {
border-radius: 3px;
box-sizing: border-box;
@ -84,41 +116,9 @@ td, th {
.template {
display: none;
}
.dialog {
display: none;
#progress {
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;
bottom: 50px;
}
.settings {
margin-top:10px;
@ -128,3 +128,13 @@ td, th {
#response{
display:inline;
}
a:link, a:visited, a:hover, a:focus {
color: #333333;
text-decoration: none;
border-bottom: #333333 1px dotted;
}
a:focus, a:hover {
border-bottom: #333333 1px solid;
}

View File

@ -22,13 +22,10 @@ $(document).ready(function () {
var search = function () {
socket.emit("search", $('.search-results').data('query'));
tasks++;
}
function updateHandlers() {
$("#progress.dialog .close").unbind('click').click(function () {
$("#progress.dialog").hide();
});
$("form").submit(function(){
var query = $('.search-results').data('query');
query.pattern = $("#search-query").val();
@ -36,24 +33,26 @@ $(document).ready(function () {
search();
return false;
});
$("#do-search").unbind('click').click(function () {
$("#search-query").unbind('keyup').keyup(function () {
var query = $('.search-results').data('query');
query.pattern = $("#search-query").val();
query.offset = 0;
search();
});
$(".do-install").unbind('click').click(function (e) {
$(".do-install, .do-update").unbind('click').click(function (e) {
var row = $(e.target).closest("tr");
doUpdate = true;
socket.emit("install", row.find(".name").html());
socket.emit("install", row.find(".name").text());
tasks++;
});
$(".do-uninstall").unbind('click').click(function (e) {
var row = $(e.target).closest("tr");
doUpdate = true;
socket.emit("uninstall", row.find(".name").html());
socket.emit("uninstall", row.find(".name").text());
tasks++;
});
$(".do-prev-page").unbind('click').click(function (e) {
@ -76,33 +75,37 @@ $(document).ready(function () {
updateHandlers();
var tasks = 0;
socket.on('progress', function (data) {
if (data.progress > 0 && $('#progress.dialog').data('progress') > data.progress) return;
$("#progress.dialog .close").hide();
$("#progress.dialog").show();
$('#progress.dialog').data('progress', data.progress);
$("#progress").show();
$('#progress').data('progress', data.progress);
var message = "Unknown status";
if (data.message) {
message = "<span class='status'>" + data.message.toString() + "</span>";
message = data.message.toString();
}
if (data.error) {
message = "<span class='error'>" + data.error.toString() + "<span>";
data.progress = 1;
}
$("#progress.dialog .message").html(message);
$("#progress.dialog .history").append("<div>" + message + "</div>");
$("#progress .message").html(message);
if (data.progress >= 1) {
tasks--;
if (tasks <= 0) {
// Hide the activity indicator once all tasks are done
$("#progress").hide();
tasks = 0;
}
if (data.error) {
$("#progress.dialog .close").show();
} else {
alert('An error occurred: '+data.error+' -- the server log might know more...');
}else {
if (doUpdate) {
doUpdate = false;
socket.emit("load");
tasks++;
}
$("#progress.dialog").hide();
}
}
});
@ -114,21 +117,26 @@ $(document).ready(function () {
widget.data('total', data.total);
widget.find('.offset').html(data.query.offset);
widget.find('.limit').html(data.query.offset + data.query.limit);
if (data.query.offset + data.query.limit > data.total){
widget.find('.limit').html(data.total);
}else{
widget.find('.limit').html(data.query.offset + data.query.limit);
}
widget.find('.total').html(data.total);
widget.find(".results *").remove();
for (plugin_name in data.results) {
var plugin = data.results[plugin_name];
var row = widget.find(".template tr").clone();
var version = '0.0.0';
// hack to access "versions" property of the npm package object
for (version in data.results[plugin_name].versions) break;
for (attr in plugin) {
row.find("." + attr).html(plugin[attr]);
if(attr == "name"){ // Hack to rewrite URLS into name
row.find(".name").html("<a target='_blank' href='https://npmjs.org/package/"+plugin['name']+"'>"+plugin[attr]+"</a>");
}else{
row.find("." + attr).html(plugin[attr]);
}
}
row.find(".version").html(version);
row.find(".version").html( data.results[plugin_name]['dist-tags'].latest );
widget.find(".results").append(row);
}
@ -138,20 +146,42 @@ $(document).ready(function () {
socket.on('installed-results', function (data) {
$("#installed-plugins *").remove();
for (plugin_name in data.results) {
if (plugin_name == "ep_etherpad-lite") continue; // Hack...
var plugin = data.results[plugin_name];
var row = $("#installed-plugin-template").clone();
for (attr in plugin.package) {
row.find("." + attr).html(plugin.package[attr]);
if(attr == "name"){ // Hack to rewrite URLS into name
row.find(".name").html("<a target='_blank' href='https://npmjs.org/package/"+plugin.package['name']+"'>"+plugin.package[attr]+"</a>");
}else{
row.find("." + attr).html(plugin.package[attr]);
}
}
$("#installed-plugins").append(row);
}
updateHandlers();
socket.emit('checkUpdates');
tasks++;
});
socket.on('updatable', function(data) {
$('#installed-plugins>tr').each(function(i,tr) {
var pluginName = $(tr).find('.name').text()
if (data.updatable.indexOf(pluginName) >= 0) {
var actions = $(tr).find('.actions')
actions.append('<input class="do-update" type="button" value="Update" />')
actions.css('width', 200)
}
})
updateHandlers();
})
socket.emit("load");
tasks++;
search();
});

View File

@ -193,7 +193,12 @@ function loadBroadcastSliderJS(fireWhenAllScriptsAreLoaded)
});
if (numAnonymous > 0)
{
var anonymousAuthorString = numAnonymous + " unnamed author" + (numAnonymous > 1 ? "s" : "")
var anonymousAuthorString;
if(numAnonymous == 1)
anonymousAuthorString = html10n.get("timeslider.unnamedauthor", { num: numAnonymous });
else
anonymousAuthorString = html10n.get("timeslider.unnamedauthors", { num: numAnonymous });
if (numNamed !== 0){
authorsList.append(' + ' + anonymousAuthorString);
} else {
@ -361,7 +366,11 @@ function loadBroadcastSliderJS(fireWhenAllScriptsAreLoaded)
$(self).css('left', newloc);
// if(getSliderPosition() != Math.floor(newloc * sliderLength / ($("#ui-slider-bar").width()-2)))
setSliderPosition(Math.floor(newloc * sliderLength / ($("#ui-slider-bar").width() - 2)))
self.currentLoc = parseInt($(self).css('left'));
if(parseInt($(self).css('left')) < 2){
$(self).css('left', '2px');
}else{
self.currentLoc = parseInt($(self).css('left'));
}
});
})

View File

@ -21,6 +21,8 @@
* IN THE SOFTWARE.
*/
window.html10n = (function(window, document, undefined) {
// fix console
var console = window.console
function interceptConsole(method){
if (!console) return function() {}
@ -44,6 +46,39 @@ window.html10n = (function(window, document, undefined) {
, consoleError = interceptConsole('warn')
// fix Array.prototype.instanceOf in, guess what, IE! <3
if (!Array.prototype.indexOf) {
Array.prototype.indexOf = function (searchElement /*, fromIndex */ ) {
"use strict";
if (this == null) {
throw new TypeError();
}
var t = Object(this);
var len = t.length >>> 0;
if (len === 0) {
return -1;
}
var n = 0;
if (arguments.length > 1) {
n = Number(arguments[1]);
if (n != n) { // shortcut for verifying if it's NaN
n = 0;
} else if (n != 0 && n != Infinity && n != -Infinity) {
n = (n > 0 || -1) * Math.floor(Math.abs(n));
}
}
if (n >= len) {
return -1;
}
var k = n >= 0 ? n : Math.max(len - Math.abs(n), 0);
for (; k < len; k++) {
if (k in t && t[k] === searchElement) {
return k;
}
}
return -1;
}
}
/**
* MicroEvent - to make any js object an event emitter (server or browser)

View File

@ -78,6 +78,16 @@ var padeditor = (function()
html10n.bind('localized', function() {
$("#languagemenu").val(html10n.getLanguage());
// translate the value of 'unnamed' and 'Enter your name' textboxes in the userlist
// this does not interfere with html10n's normal value-setting because html10n just ingores <input>s
// also, a value which has been set by the user will be not overwritten since a user-edited <input>
// does *not* have the editempty-class
$('input[data-l10n-id]').each(function(key, input)
{
input = $(input);
if(input.hasClass("editempty"))
input.val(html10n.get(input.attr("data-l10n-id")));
});
})
$("#languagemenu").val(html10n.getLanguage());
$("#languagemenu").change(function() {

View File

@ -212,10 +212,8 @@ var padimpexp = (function()
//get /p/padname
var pad_root_path = new RegExp(/.*\/p\/[^\/]+/).exec(document.location.pathname);
//get http://example.com/p/padname
var pad_root_url = document.location.href.replace(document.location.pathname, pad_root_path);
//strip out params IE ?noColor=true
pad_root_url = pad_root_url.substring(0, pad_root_url.indexOf('?'));
//get http://example.com/p/padname without Params
var pad_root_url = document.location.protocol + '//' + document.location.host + document.location.pathname;
//i10l buttom import
$('#importsubmitinput').val(html10n.get("pad.impexp.importbutton"));

View File

@ -118,7 +118,7 @@ var paduserlist = (function()
}
else
{
nameHtml = '<input type="text" class="editempty newinput" value="'+_('pad.userlist.unnamed')+'" ' + (isNameEditable(data) ? '' : 'disabled="disabled" ') + '/>';
nameHtml = '<input data-l10n-id="pad.userlist.unnamed" type="text" class="editempty newinput" value="'+_('pad.userlist.unnamed')+'" ' + (isNameEditable(data) ? '' : 'disabled="disabled" ') + '/>';
}
return ['<td style="height:', height, 'px" class="usertdswatch"><div class="swatch" style="background:' + data.color + '">&nbsp;</div></td>', '<td style="height:', height, 'px" class="usertdname">', nameHtml, '</td>', '<td style="height:', height, 'px" class="activity">', padutils.escapeHtml(data.activity), '</td>'].join('');
@ -710,8 +710,7 @@ var paduserlist = (function()
{
if (myUserInfo.name)
{
$("#myusernameedit").removeClass("editempty").val(
myUserInfo.name);
$("#myusernameedit").removeClass("editempty").val(myUserInfo.name);
}
else
{

View File

@ -15,7 +15,10 @@ var withNpm = function (npmfn, final, cb) {
cb({progress: 0.5, message:message.msg + ": " + message.pref});
});
npmfn(function (er, data) {
if (er) return cb({progress:1, error:er.code + ": " + er.path});
if (er) {
console.error(er);
return cb({progress:1, error: er.message});
}
if (!data) data = {};
data.progress = 1;
data.message = "Done.";

View File

@ -1,6 +1,6 @@
<html>
<head>
<title>Etherpad Lite Admin Dashboard</title>
<title>Admin Dashboard - Etherpad lite</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0">
<link rel="stylesheet" href="../static/css/admin.css">
<script src="../static/js/jquery.js"></script>
@ -8,13 +8,14 @@
</head>
<body>
<div id="wrapper">
<h1>Etherpad Lite Admin Dashboard</h1>
<div>
<a href="../admin/plugins">Install and Uninstall plugins</a>
</div>
<div>
<a href="../admin/settings">Modify Server and Plugin Settings</a>
<div class="menu">
<h1>Etherpad lite</h1>
<li><a href="admin/plugins">Plugin manager</a> </li>
<li><a href="admin/settings">Settings</a> </li>
<li><a href="admin/plugins/info">Troubleshooting information</a> </li>
</div>
</div>
<div id="topborder"></div>
</body>
</html>

View File

@ -4,27 +4,36 @@
<html>
<head>
<title>Plugin information</title>
<title>Plugin information - Etherpad lite</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0">
<link rel="stylesheet" href="../../static/css/admin.css">
</head>
<body>
<div id="wrapper">
<h1>Etherpad Lite</h1>
<div class="separator"></div>
<div class="menu">
<h1>Etherpad lite</h1>
<li><a href="../plugins">Plugin manager</a> </li>
<li><a href="../settings">Settings</a> </li>
<li><a href="../plugins/info">Troubleshooting information</a> </li>
</div>
<h2>Installed plugins</h2>
<pre><%- plugins.formatPlugins().replace(", ","\n") %></pre>
<div class="innerwrapper">
<h2>Installed parts</h2>
<pre><%= plugins.formatParts() %></pre>
<h2>Installed plugins</h2>
<pre><%- plugins.formatPlugins().replace(", ","\n") %></pre>
<h2>Installed hooks</h2>
<h3>Server side hooks</h3>
<div><%- plugins.formatHooks() %></div>
<h2>Installed parts</h2>
<pre><%= plugins.formatParts() %></pre>
<h3>Client side hooks</h3>
<div><%- plugins.formatHooks("client_hooks") %></div>
<h2>Installed hooks</h2>
<h3>Server side hooks</h3>
<div><%- plugins.formatHooks() %></div>
<h3>Client side hooks</h3>
<div><%- plugins.formatHooks("client_hooks") %></div>
</div>
</div>
<div id="topborder"></div>
</body>
</html>

View File

@ -1,6 +1,6 @@
<html>
<head>
<title>Plugin manager</title>
<title>Plugin manager - Etherpad lite</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0">
<link rel="stylesheet" href="../static/css/admin.css">
<script src="../static/js/jquery.js"></script>
@ -18,12 +18,16 @@
</div>
<% } %>
<div class="menu">
<h1>Etherpad lite</h1>
<li><a href="plugins">Plugin manager</a> </li>
<li><a href="settings">Settings</a> </li>
<li><a href="plugins/info">Troubleshooting information</a> </li>
<div id="progress"><img src="../static/img/loading.gif" alt=""/>&nbsp;&nbsp;<span class="message"></span></div>
</div>
<h1>Etherpad Lite</h1>
<a href="plugins/info">Technical information on installed plugins</a>
<div class="separator"></div>
<div class="innerwrapper">
<h2>Installed plugins</h2>
<table>
<thead>
@ -50,11 +54,12 @@
<div class="paged listing search-results">
<div class="separator"></div>
<h2>Search for plugins to install</h2>
<h2>Available plugins</h2>
<form>
<input type="text" name="search" placeholder="Search term" id="search-query">
<input type="button" value="Search" id="do-search">
<input type="text" name="search" placeholder="Search for plugins to install" id="search-query">
</form>
<table>
<thead>
<tr>
@ -81,14 +86,9 @@
<span class="offset"></span>..<span class="limit"></span> of <span class="total"></span>.
<input type="button" value=">>" class="do-next-page">
</div>
<div id="progress" class="dialog">
<h1 class="title">
Please wait: <span class="message"></span>
<input type="button" class="close" value="Close">
</h1>
<div class="history"></div>
</div>
</div>
<div id="topborder"></div>
</body>
</html>

View File

@ -1,6 +1,6 @@
<html>
<head>
<title>Settings manager</title>
<title>Settings - Etherpad lite</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0">
<link rel="stylesheet" href="../static/css/admin.css">
<script src="../static/js/jquery.js"></script>
@ -22,13 +22,23 @@
<% } %>
<h1>Etherpad Lite Settings</h1>
<a href='https://github.com/ether/etherpad-lite/wiki/Example-Production-Settings.JSON'>Example production settings template</a>
<a href='https://github.com/ether/etherpad-lite/wiki/Example-Development-Settings.JSON'>Example development settings template</a>
<textarea class="settings"></textarea>
<input type="button" class="settingsButton" id="saveSettings" value="Save Settings">
<input type="button" class="settingsButton" id="restartEtherpad" value="Restart Etherpad">
<div id="response"></div>
<div class="menu">
<h1>Etherpad lite</h1>
<li><a href="plugins">Plugin manager</a> </li>
<li><a href="settings">Settings</a> </li>
<li><a href="plugins/info">Troubleshooting information</a> </li>
</div>
<div class="innerwrapper">
<a href='https://github.com/ether/etherpad-lite/wiki/Example-Production-Settings.JSON'>Example production settings template</a>
<a href='https://github.com/ether/etherpad-lite/wiki/Example-Development-Settings.JSON'>Example development settings template</a>
<textarea class="settings"></textarea>
<input type="button" class="settingsButton" id="saveSettings" value="Save Settings">
<input type="button" class="settingsButton" id="restartEtherpad" value="Restart Etherpad">
<div id="response"></div>
</div>
</div>
<div id="topborder"></div>
</body>
</html>

View File

@ -150,6 +150,7 @@
<link href="static/custom/index.css" rel="stylesheet">
<div id="wrapper">
<% e.begin_block("indexWrapper"); %>
<div id="inner">
<div id="button" onclick="go2Random()" data-l10n-id="index.newPad"></div>
<div id="label" data-l10n-id="index.createOpenPad"></div>
@ -158,6 +159,7 @@
<button type="submit">OK</button>
</form>
</div>
<% e.end_block(); %>
</div>
<script src="static/custom/index.js"></script>

View File

@ -3,7 +3,10 @@
, langs = require("ep_etherpad-lite/node/hooks/i18n").availableLangs
%>
<!doctype html>
<% e.begin_block("htmlHead"); %>
<html>
<% e.end_block(); %>
<title><%=settings.title%></title>
<script>
/*
@ -163,7 +166,7 @@
<span id="mycolorpickerpreview" class="myswatchboxhoverable"></span>
</div>
<div id="myswatchbox"><div id="myswatch"></div></div>
<div id="myusernameform"><input type="text" id="myusernameedit" disabled="disabled"></div>
<div id="myusernameform"><input type="text" id="myusernameedit" disabled="disabled" data-l10n-id="pad.userlist.entername"></div>
<div id="mystatusform"><input type="text" id="mystatusedit" disabled="disabled"></div>
</div>
<div id="otherusers">
@ -328,10 +331,12 @@
<p data-l10n-id="pad.modals.deleted.explanation"></p>
</div>
<div class="disconnected">
<% e.begin_block("disconnected"); %>
<h1 data-l10n-id="pad.modals.disconnected"></h1>
<h2 data-l10n-id="pad.modals.disconnected.explanation"></h2>
<p data-l10n-id="pad.modals.disconnected.cause"></p>
<button id="forcereconnect" data-l10n-id="pad.modals.forcereconnect"></button>
<% e.end_block(); %>
</div>
<form id="reconnectform" method="post" action="/ep/pad/reconnect" accept-charset="UTF-8" style="display: none;">
<input type="hidden" class="padId" name="padId">