Commit f0a86d7d authored by techird's avatar techird

stash

parent 9e89a241
......@@ -9,9 +9,9 @@
<title>百度脑图 - 便捷的思维导图工具</title>
<script src="kityminder.all.min.js?_=1409099802809" charset="utf-8"></script>
<script src="kityminder.config.js?_=1409099802809" charset="utf-8"></script>
<script src="lang/zh-cn/zh-cn.js?_=1409099802809" charset="utf-8"></script>
<script src="kityminder.all.min.js?_=1409280817067" charset="utf-8"></script>
<script src="kityminder.config.js?_=1409280817067" charset="utf-8"></script>
<script src="lang/zh-cn/zh-cn.js?_=1409280817067" charset="utf-8"></script>
<link href="ui/theme/default/css/default.all.css" type="text/css" rel="stylesheet" />
......
/*!
* ====================================================
* kityminder - v1.2.1 - 2014-08-27
* kityminder - v1.2.1 - 2014-08-29
* https://github.com/fex-team/kityminder
* GitHub: https://github.com/fex-team/kityminder.git
* Copyright (c) 2014 f-cube @ FEX; Licensed MIT
......@@ -15313,7 +15313,7 @@
/* lib/fio/dist/fio.js */
/* lib/fio/src/fio.js */
/**
* @fileOverview
*
......@@ -15386,15 +15386,48 @@
}
File.prototype.setPath = function(path) {
var filename, dotpos;
fio.file.anlysisPath(path, this);
};
filename = path.substr(path.lastIndexOf('/') + 1);
dotpos = filename.lastIndexOf('.');
fio.file.anlysisPath = function(path, fill) {
fill = fill || {};
this.extension = ~dotpos ? filename.substr(dotpos) : null;
this.name = ~dotpos ? filename.substr(0, dotpos) : filename;
this.filename = filename;
this.path = path;
var pathParts = path.split('/');
// trim start
while (pathParts[0] == '/' || pathParts[0] === '') {
pathParts.shift();
}
// trim end
while (pathParts[pathParts.length - 1] == '/' || pathParts[pathParts.length - 1] === '') {
pathParts.pop();
}
fill.filename = pathParts.pop() || null;
if (pathParts.length) {
fill.parentPath = '/' + pathParts.join('/') + '/';
} else {
fill.parentPath = fill.filename ? '/' : null;
}
if (fill.filename) {
var filenameParts = fill.filename.split('.');
if (filenameParts.length > 1) {
fill.extension = '.' + filenameParts.pop();
} else {
fill.extension = null;
}
fill.name = filenameParts.join('.');
fill.path = fill.parentPath + fill.filename;
} else {
fill.path = '/';
}
return fill;
};
/* 数据结构:表示一个访问控制列表记录 */
......@@ -15825,8 +15858,9 @@
request.extra = opt;
var response = provider.handle(request);
// 确保返回的是一个 Promise 对象
return Promise.resolve(provider.handle(request));
return Promise.resolve(response);
});
};
});
......@@ -15834,7 +15868,7 @@
// export
window.fio = fio;
})(Promise);
/* lib/fio/dist/fio.js end */
/* lib/fio/src/fio.js end */
......@@ -16083,24 +16117,25 @@
// 根据文件请求分发处理
function handle(request) {
if (!access_token) throw new Error('Not Authorized');
var param = {
access_token: access_token
};
// 默认参数
var opt = {
url: urls.file,
type: 'GET',
data: param,
dataType: 'JSON'
};
// 处理 path 参数
if (request.method != fio.file.METHOD_MOVE) {
param.path = request.path;
} else {
if (request.method == fio.file.METHOD_MOVE) {
param.from = request.path;
} else {
param.path = request.path;
}
// 处理其他参数
......@@ -16117,15 +16152,21 @@
case fio.file.METHOD_WRITE:
opt.type = 'POST';
param.method = 'upload';
param.ondup = request.dupPolicy == fio.file.DUP_OVERWRITE ? 'overwrite' : 'newcopy';
if (request.data.type == 'blob') {
var form = new FormData();
if (request.data.type == fio.file.TYPE_BLOB) {
form.append('file', request.data.content);
opt.url += $.param(param);
opt.data = form;
} else {
form.append('file', new Blob([request.data.content], {
type: 'text/plain'
}));
}
opt.data = form;
opt.processData = false;
opt.contentType = false;
break;
......@@ -16150,6 +16191,9 @@
break;
}
// 参数拼接到 URL 中
opt.url += '?' + $.param(param);
function throwError(response) {
throw new Error([response.error_code, response.error_msg]);
}
......@@ -16196,7 +16240,6 @@
return file;
}, function(e) {
console.log(e);
if (e.responseText) throwError(JSON.parse(e.responseText));
else throw e;
});
......@@ -25589,8 +25632,7 @@
});
},
exportData: function(protocolName) {
exportJson: function() {
/* 导出 node 上整棵树的数据为 JSON */
function exportNode(node) {
var exported = {};
......@@ -25605,14 +25647,67 @@
return exported;
}
var json, protocol;
json = exportNode(this.getRoot());
var json = exportNode(this.getRoot());
json.template = this.getTemplate();
json.theme = this.getTheme();
json.version = KityMinder.version;
return json;
},
importJson: function(json, params) {
function importNode(node, json, km) {
var data = json.data;
node.data = {};
for (var field in data) {
node.setData(field, data[field]);
}
node.setData('text', data.text || km.getLang(DEFAULT_TEXT[node.getType()]));
var childrenTreeData = json.children || [];
for (var i = 0; i < childrenTreeData.length; i++) {
var childNode = km.createNode(null, node);
importNode(childNode, childrenTreeData[i], km);
}
return node;
}
if (!json) return;
this._fire(new MinderEvent('preimport', params, false));
// 删除当前所有节点
while (this._root.getChildren().length) {
this.removeNode(this._root.getChildren()[0]);
}
json = KityMinder.compatibility(json);
importNode(this._root, json, this);
this.setTemplate(json.template || null);
this.setTheme(json.theme || null);
this.refresh();
this.fire('import', params);
this._firePharse({
type: 'contentchange'
});
this._firePharse({
type: 'interactchange'
});
},
exportData: function(protocolName) {
var json, protocol;
json = this.exportJson();
// 指定了协议进行导出,需要检测协议是否支持
if (protocolName) {
protocol = this.getProtocol(protocolName);
......@@ -25666,58 +25761,12 @@
}).then(function(json) {
minder._doImport(json, params);
minder.importJson(json, params);
return json;
});
},
_doImport: function(json, params) {
function importNode(node, json, km) {
var data = json.data;
node.data = {};
for (var field in data) {
node.setData(field, data[field]);
}
node.setData('text', data.text || km.getLang(DEFAULT_TEXT[node.getType()]));
var childrenTreeData = json.children || [];
for (var i = 0; i < childrenTreeData.length; i++) {
var childNode = km.createNode(null, node);
importNode(childNode, childrenTreeData[i], km);
}
return node;
}
if (!json) return;
this._fire(new MinderEvent('preimport', params, false));
// 删除当前所有节点
while (this._root.getChildren().length) {
this.removeNode(this._root.getChildren()[0]);
}
json = KityMinder.compatibility(json);
importNode(this._root, json, this);
this.setTemplate(json.template || null);
this.setTheme(json.theme || null);
this.refresh();
this.fire('import', params);
this._firePharse({
type: 'contentchange'
});
this._firePharse({
type: 'interactchange'
});
}
});
/* src/core/minder.data.js end */
......@@ -30596,7 +30645,6 @@
dragger.dragEnd();
//e.stopPropagation();
e.preventDefault();
this.fire('contentchange');
},
'statuschange': function(e) {
if (e.lastStatus == 'textedit' && e.currentStatus == 'normal') {
......@@ -31645,9 +31693,9 @@
this.km.setStatus('inputready');
clearTimeout(me.inputTextTimer);
e.preventDefault();
this.km.fire('contentchange');
}else{
this.km.setStatus('normal');
this.km.fire('contentchange');
}
restoreTextContent();
return;
......@@ -31729,7 +31777,6 @@
e.preventDefault();
}else{
this.km.setStatus('normal');
this.km.fire('contentchange');
}
restoreTextContent();
return;
......@@ -33029,7 +33076,7 @@
};
return {
fileDescription: 'xmind格式文件',
fileDescription: 'XMind 格式',
fileExtension: '.xmind',
dataType: 'blob',
......@@ -33218,7 +33265,7 @@
}
return {
fileDescription: 'freemind格式文件',
fileDescription: 'Freemind 格式',
fileExtension: '.mm',
dataType: 'text',
......@@ -33358,7 +33405,7 @@
}
return {
fileDescription: 'mindmanager格式文件',
fileDescription: 'MindManager 格式',
fileExtension: '.mmap',
dataType: 'blob',
......@@ -33480,7 +33527,7 @@
KityMinder.registerProtocol('json', function(minder) {
return {
fileDescription: 'KityMinder',
fileDescription: 'KityMinder 格式',
fileExtension: '.km',
dataType: 'text',
mineType: 'application/json',
......@@ -33640,6 +33687,7 @@
fileDescription: 'PNG 图片',
fileExtension: '.png',
mineType: 'image/png',
dataType: 'base64',
encode: encode,
recognizePriority: -1
};
......@@ -33659,6 +33707,7 @@
fileDescription: 'SVG 矢量图',
fileExtension: '.svg',
mineType: 'image/svg+xml',
dataType: 'text',
encode: function(json) {
......@@ -33755,6 +33804,8 @@
e.stopPropagation();
});
minder.getPaper().addClass('loading-target');
this.fire('interactchange');
},
......@@ -33883,6 +33934,115 @@
/* ui/doc.js */
/**
* @fileOverview
*
* 当前文档管理
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('doc', function(minder) {
var ret = minder.getUI('eve').setup({});
var current = {};
var loading = false;
/**
* 加载文档
*
* @param {Object} doc 文档的属性,可包括:
* doc.content {string} [Required] 文档内容
* doc.protocol {string} [Required] 内容所使用的编码协议
* doc.title {string} 文档的标题
* doc.source {string} 文档的来源
* doc.path {string} 文档的路径
* doc.saved {bool} 文档的保存状态
*
* @event docload(doc)
* doc - 文档解析之后的文档对象
*
* @return {Promise<doc>} 返回解析完之后的文档对象,解析的结果为 doc.data
*/
function load(doc) {
var restore = doc;
current = doc;
loading = true;
return minder.importData(doc.content, doc.protocol).then(function(data) {
doc.title = doc.title || minder.getMinderTitle();
minder.execCommand('camera', minder.getRoot(), 300);
doc.data = data;
doc.json = JSON.stringify(data);
minder.getUI('topbar/title').setTitle(doc.title, doc.saved);
ret.fire('docload', doc);
return doc;
})['catch'](function() {
current = restore;
}).then(function() {
loading = false;
});
}
function save(doc) {
current = doc;
minder.getUI('topbar/title').setTitle(doc.title, true);
ret.fire('docsave', doc);
}
function getCurrent() {
return current;
}
/* 绕开初始化时候的乱事件 */
setTimeout(function() {
minder.on('contentchange', function() {
if (loading) return;
var $title = minder.getUI('topbar/title');
if (current.source != 'netdisk') {
current.title = minder.getMinderTitle();
$title.setTitle(current.title, false);
ret.fire('docchange', current);
} else {
if (current.json != JSON.stringify(minder.exportJson())) {
$title.setSaved(false);
ret.fire('docchange', current);
} else {
$title.setSaved(true);
}
}
});
}, 1000);
ret.load = load;
ret.save = save;
ret.current = getCurrent;
return ret;
});
/* ui/doc.js end */
/* ui/widget/commandbutton.js */
/**
* @fileOverview
......@@ -34034,9 +34194,19 @@
*/
KityMinder.registerUI('widget/friendlytimespan', function(minder) {
function getFriendlyTimeSpan(t1_in_ms, t2_in_ms) {
t2_in_ms = t2_in_ms || +new Date();
var ms = Math.abs(t1_in_ms - t2_in_ms),
$.extend($.fn, {
displayFriendlyTime: function(time) {
return this.each(function() {
display($(this)
.addClass('friendly-time')
.data('time', time));
});
}
});
function getTimeText(timeInMs) {
var ms = Math.abs(timeInMs - new Date()),
s = ms / 1000,
m = s / 60,
h = m / 60,
......@@ -34046,12 +34216,21 @@
if (h < 24) return minder.getLang('ui.hoursago', h | 0);
if (d < 2) return minder.getLang('ui.yesterday');
if (d <= 30) return minder.getLang('ui.daysago', d | 0);
return minder.getLang("ui.longago");
}
return {
display: getFriendlyTimeSpan
};
function display($element) {
$element.text(getTimeText($element.data('time')));
}
function update() {
$('.friendly-time').each(function() {
display($(this));
});
}
setInterval(update, 60000);
});
/* ui/widget/friendlytimespan.js end */
......@@ -34081,11 +34260,13 @@
} else {
list = [];
}
this.length = list.length;
}
function save() {
while (list.length > maxCount) list.pop();
localStorage.setItem(name, JSON.stringify(list));
this.length = list.length;
}
function get(index) {
......@@ -34097,6 +34278,11 @@
save();
}
function clear() {
list = [];
save();
}
function unshift(item) {
list.unshift(item);
save();
......@@ -34134,6 +34320,7 @@
this.find = find;
this.forEach = forEach;
this.unshift = unshift;
this.clear = clear;
}
return {
......@@ -34147,68 +34334,6 @@
/* ui/widget/fileloader.js */
/**
* @fileOverview
*
* 完成加载一个脑图文件的流程
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('widget/fileloader', function(minder) {
var $container = $(minder.getRenderTarget());
var supports = minder.getSupportedProtocols();
function getProtocolByExtension(extension) {
for (var protocol in supports) {
if (supports[protocol].fileExtension == extension) return supports[protocol];
}
return false;
}
function load(file) {
var protocol = getProtocolByExtension(file.extension);
return minder.importData(file.data.content, protocol.name).then(function(json) {
var $title = minder.getUI('topbar/title');
$title.setTitle(file.filename);
$container.removeClass('loading');
minder.execCommand('camera', minder.getRoot(), 300);
return {
file: file,
json: json
};
});
}
function error(err) {
window.alert('加载文件失败:' + err.message);
$container.removeClass('loading');
}
return {
load: function(filePromise) {
$container.addClass('loading');
return Promise.resolve(filePromise).then(load)['catch'](error);
},
support: function(file) {
return getProtocolByExtension(file.extension);
}
};
});
/* ui/widget/fileloader.js end */
/* ui/widget/netdiskfinder.js */
/**
* @fileOverview
......@@ -34253,12 +34378,15 @@
.addClass('button netdisk-mkdir')
.click(mkdir);
var selected = null;
$nav.after($mkdir);
$container.addClass('netdisk-finder-container');
/* 点击目录中的项目时打开项目 */
$list.delegate('.netdisk-file-list-item', 'click', function(e) {
if (mkdir.onprogress) return mkdir.onprogress.select();
var $file = $(e.target),
file = $file.data('file');
if (file) open(file);
......@@ -34266,6 +34394,7 @@
/* 点击导航处,切换路径 */
$nav.delegate('a', 'click', function(e) {
if (mkdir.onprogress) return mkdir.onprogress.select();
if ($(e.target).hasClass('dir-back')) {
var parts = currentPath.split('/');
parts.pop(); // 有一个无效部分
......@@ -34280,20 +34409,45 @@
hide();
function mkdir() {
if (mkdir.onprogress) {
return mkdir.onprogress.select();
}
var $li = $('<li>').addClass('netdisk-file-list-item dir').prependTo($list);
var $input = $('<input>')
.attr('type', 'text')
.addClass('new-dir-name')
.val(minder.getLang('ui.newdir'))
.appendTo($li);
mkdir.onprogress = $input[0];
$input[0].select();
$input.on('keydown', function(e) {
if (e.keyCode == 13) {
var name = $input.val();
$input.on('keydown', function(e) {
if (e.keyCode == 13) confirm();
if (e.keyCode == 27) {
$li.remove();
mkdir.onprogress = false;
e.stopPropagation();
}
});
function confirm() {
var name = $input.val();
if (name) {
fio.file.mkdir({
path: currentPath + name
}).then(function() {
return list(currentPath);
}, function(e) {
window.alert('创建目录失败:' + e.message);
}).then(function() {
mkdir.onprogress = false;
});
}
$li.remove();
}
}
function show() {
......@@ -34358,14 +34512,13 @@
var transitPromise = fadeOutList(-100 * sign(path.length - currentPath.length));
Promise.all([listPromise, transitPromise]).then(renderList, function(error) {
window.alert('加载目录发生错误:' + error);
});
currentPath = path.charAt(path.length - 1) == '/' ? path : path + '/';
updateNav();
return Promise.all([listPromise, transitPromise]).then(renderList, function(error) {
window.alert('加载目录发生错误:' + error);
});
}
function renderList(values) {
......@@ -34373,6 +34526,14 @@
var files = values[0];
files.sort(function(a, b) {
if (a.isDir > b.isDir) {
return -1;
} else if (a.isDir == b.isDir) {
return a.createTime > b.createTime ? -1 : 1;
} else return 1;
});
if (!files.length) {
$list.append('<li class="empty" disabled="disabled">' + minder.getLang('ui.emptydir') + '</li>');
} else {
......@@ -34390,6 +34551,7 @@
}
fadeInList();
checkSelect();
finder.fire('cd', currentPath);
}
......@@ -34425,7 +34587,31 @@
});
}
function select(path) {
selected = path;
return checkSelect();
}
function checkSelect() {
var hasSelect = false;
$list.find('.netdisk-file-list-item').removeClass('selected').each(function() {
var file = $(this).data('file');
if (file && file.path == selected) {
$(this).addClass('selected');
hasSelect = true;
}
});
if (!hasSelect) selected = false;
return hasSelect;
}
function pwd() {
return currentPath;
}
finder.list = list;
finder.select = select;
finder.pwd = pwd;
return finder;
}
......@@ -34462,6 +34648,7 @@
$mainMenuButton.on('click', function(e) {
$panel.addClass('show');
$panel.trigger('show');
});
$panel = $('<div id="main-menu"></div>').appendTo('#content-wrapper');
......@@ -34470,6 +34657,7 @@
// ESC Pressed
if (e.keyCode == 27) {
$panel.toggleClass('show');
if ($panel.hasClass('show')) $panel.trigger('show');
}
});
......@@ -34542,7 +34730,7 @@
$l1_tabs.appendTo($menu[0]);
$l1_tabs.select(2);
$l1_tabs.select(3);
var ret = {};
......@@ -34571,6 +34759,7 @@
var $menu = minder.getUI('menu/menu');
var $level1 = minder.getUI('menu/level1');
var $doc = minder.getUI('doc');
var eve = minder.getUI('eve');
var $panel = $level1['new'].getContentElement();
......@@ -34600,14 +34789,16 @@
$ul.delegate('.template-item', 'click', function(e) {
var template = $(e.target).data('template');
minder.importData({
$doc.load({
content: {
template: template,
version: KityMinder.version,
data: {
text: minder.getLang('template')[template]
}
},
protocol: null
});
minder.execCommand('camera', minder.getRoot());
$menu.removeClass('show');
});
......@@ -34652,6 +34843,8 @@
})
}).appendTo($level1.open);
$tabs.select(3);
// 暴露
var ret = {};
......@@ -34693,51 +34886,27 @@
var $menu = minder.getUI('menu/menu');
var $open = minder.getUI('menu/open/open');
var $loader = minder.getUI('widget/fileloader');
var $doc = minder.getUI('doc');
// 支持的文件类型
var supportedExtensions = [];
/* extension => protocol */
var supports = {};
var accepts = [];
Utils.each(minder.getSupportedProtocols(), function(name, protocol) {
if (protocol && protocol.decode) {
supportedExtensions.push(protocol.fileExtension);
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.decode) {
supports[protocol.fileExtension] = protocol;
accepts.push(protocol.fileExtension);
}
});
supportedExtensions = supportedExtensions.join(', ');
function readFile(domfile) {
return new Promise(function(resolve, reject) {
var file = new fio.file.File(domfile.name);
var protocol = minder.getProtocol($loader.support(file));
var reader;
if (protocol.dataType == 'blob') {
file.data = new fio.file.Data(domfile);
resolve(file);
} else {
reader = new FileReader();
reader.onload = function() {
file.data = new fio.file.Data(this.result);
resolve(file);
};
reader.readAsText(domfile, 'utf-8');
}
});
}
/* 网盘面板 */
var $panel = $($open.local.getContentElement()).addClass('local-file-open-panel');
/* 路径导航 */
var $nav = $('<h2>本地文件</h2>')
/* 标题 */
$('<h2>本地文件</h2>')
.appendTo($panel);
/* 选择文件 */
var $pick = $('<div class="pick-file"></div>')
.appendTo($panel);
......@@ -34746,18 +34915,25 @@
.appendTo($pick);
$('<span></span>')
.text(minder.getLang('ui.acceptfile', supportedExtensions))
.appendTo($pick);
.text(minder.getLang('ui.acceptfile', accepts.map(function(ext) {
var protocol = supports[ext];
return protocol.fileDescription + '(' + ext + ')';
}).join(', '))).appendTo($pick);
/* 拖放提示 */
var $drop = $('<div class="drop-file"></div>')
.append($('<span></span>').html(minder.getLang('ui.dropfile')))
.appendTo($panel);
/* 交互事件 */
$pickButton.click(function() {
var $file = $('<input type="file" />')
.attr('accept', supportedExtensions)
$('<input type="file" />')
.attr('accept', accepts.join())
.on('change', function(e) {
readFile(this.files[0]).then($loader.load);
read(this.files[0]);
$menu.removeClass('show');
}).click();
});
......@@ -34767,11 +34943,64 @@
e.stopPropagation();
}).on('drop', function(e) {
e = e.originalEvent;
var file = e.dataTransfer.files[0];
readFile(file).then($loader.load);
read(e.dataTransfer.files[0]);
$menu.removeClass('show');
e.preventDefault();
});
function read(domfile) {
if (!domfile) return;
var info = new fio.file.anlysisPath(domfile.name);
var protocol = supports[info.extension];
var dataPromise = new Promise(function(resolve, reject) {
var reader;
if (protocol.dataType == 'blob') {
resolve(new fio.file.Data(domfile));
} else {
reader = new FileReader();
reader.onload = function() {
resolve(new fio.file.Data(this.result));
};
reader.onerror = reject;
reader.readAsText(domfile, 'utf-8');
}
});
$(minder.getRenderTarget()).addClass('loading');
return dataPromise.then(function(data) {
var doc = {
content: data.content,
protocol: protocol.name,
title: info.filename,
source: 'local'
};
return $doc.load(doc);
})['catch'](function(error) {
window.alert(minder.getLang('ui.errorloading', error.message || minder.getLang('ui.unknownreason')));
}).then(function() {
$(minder.getRenderTarget()).removeClass('loading');
});
}
return {
read: read
};
});
/* ui/menu/open/local.js end */
......@@ -34792,39 +35021,74 @@
var $menu = minder.getUI('menu/menu');
var $open = minder.getUI('menu/open/open');
var $loader = minder.getUI('widget/fileloader');
var $netdiskfinder = minder.getUI('widget/netdiskfinder');
var $eve = minder.getUI('eve');
var $doc = minder.getUI('doc');
var ret = $eve.setup({});
/* 网盘面板 */
var $panel = $($open.netdisk.getContentElement());
/* extension => protocol */
var supports = {};
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.decode) {
supports[protocol.fileExtension] = protocol;
}
});
/* Finder */
var $finder = $netdiskfinder.generate($panel, function(file) {
return $loader.support(file);
return supports[file.extension];
});
$finder.on('fileclick', openFile);
$finder.on('fileclick', function(file) {
return open(file.path);
});
function openFile(file) {
var protocol = $loader.support(file);
function open(path) {
$menu.removeClass('show');
$(minder.getRenderTarget()).addClass('loading');
return $loader.load(fio.file.read({
path: file.path,
var info = fio.file.anlysisPath(path);
var protocol = supports[info.extension];
return fio.file.read({
path: path,
dataType: protocol.dataType
})).then(function(readed) {
if (readed) ret.fire('fileload', readed);
}).then(function(file) {
var doc = {
protocol: supports[file.extension].name,
content: file.data.content,
title: file.filename,
source: 'netdisk',
path: file.path,
saved: true
};
return $doc.load(doc);
})['catch'](function(error) {
window.alert(minder.getLang('ui.errorloading', error.message || minder.getLang('unknownreason')));
}).then(function() {
$(minder.getRenderTarget()).removeClass('loading');
});
}
ret.loadFileByPath = function(path) {
var file = new fio.file.File(path);
return openFile(file);
};
ret.open = open;
return ret;
});
/* ui/menu/open/netdisk.js end */
......@@ -34849,13 +35113,20 @@
var $loader = minder.getUI('widget/fileloader');
var frdTime = minder.getUI('widget/friendlytimespan');
var netdisk = minder.getUI('menu/open/netdisk');
var doc = minder.getUI('doc');
var recentList = minder.getUI('widget/locallist').use('recent');
/* 网盘面板 */
var $panel = $($open.recent.getContentElement()).addClass('recent-file-panel');
/* 路径导航 */
var $nav = $('<h2>最近使用</h2>')
/* 标题 */
var $title = $('<h2></h2>')
.text(minder.getLang('ui.recent'))
.appendTo($panel);
var $clear = $('<button></button>')
.addClass('clear-recent-list')
.text(minder.getLang('ui.clearrecent'))
.appendTo($panel);
/* 最近文件列表容器 */
......@@ -34863,10 +35134,49 @@
.addClass('recent-file-list')
.appendTo($panel);
$ul.delegate('.recent-file-item', 'click', function(e) {
var path = $(e.target)
.closest('.recent-file-item')
.data('path');
netdisk.open(path);
});
$clear.on('click', function() {
if (!window.confirm(minder.getLang('ui.clearrecentconfirm'))) return;
recentList.clear();
renderList();
});
doc.on('docload', addToList);
doc.on('docsave', addToList);
renderList();
function addToList(doc) {
if (doc.source != 'netdisk') return;
var exist = recentList.findIndex('path', doc.path);
if (~exist) {
recentList.remove(exist);
}
recentList.unshift({
path: doc.path,
filename: fio.file.anlysisPath(doc.path).filename,
title: minder.getMinderTitle(),
time: +new Date()
});
renderList();
}
function renderList() {
$ul.empty();
recentList.forEach(function(item) {
var $li = $('<li></li>')
......@@ -34886,41 +35196,11 @@
$('<span></span>')
.addClass('file-time')
.data('time', item.time)
.text(frdTime.display(item.time))
.displayFriendlyTime(item.time)
.appendTo($li);
});
}
$ul.delegate('.recent-file-item', 'click', function(e) {
var path = $(e.target)
.closest('.recent-file-item')
.data('path');
netdisk.loadFileByPath(path);
});
netdisk.on('fileload', function(loaded) {
var exist = recentList.findIndex('path', loaded.file.path);
if (~exist) {
recentList.remove(exist);
}
recentList.unshift({
path: loaded.file.path,
filename: loaded.file.filename,
title: loaded.json.data.text || minder.getLang('untitleddoc'),
time: +new Date()
});
renderList();
});
function updateTime() {
$ul.find('.file-time').each(function(index, element) {
$(element).text(frdTime.display($(element).data('time')));
});
}
setInterval(updateTime, 60000);
});
/* ui/menu/open/recent.js end */
......@@ -34938,11 +35218,139 @@
*/
KityMinder.registerUI('menu/open/draft', function(minder) {
var $menu = minder.getUI('menu/menu');
var $open = minder.getUI('menu/open/open');
var $panel = $($open.draft.getContentElement()).addClass('draft-file-list');
var drafts = minder.getUI('widget/locallist').use('draft');
var $loader = minder.getUI('widget/fileloader');
var frdTime = minder.getUI('widget/friendlytimespan');
var $doc = minder.getUI('doc');
// 旧数据迁移
if (localStorage.drafts) {
var oldDrafts = JSON.parse(localStorage.drafts);
var list = oldDrafts.map(function(draft) {
var ret = {};
ret.json = draft.data;
ret.time = +new Date(draft.update);
ret.title = JSON.parse(draft.data).data.text;
return ret;
});
delete localStorage.drafts;
localStorage.draft = JSON.stringify(list);
}
var draftList = minder.getUI('widget/locallist').use('draft');
/* 网盘面板 */
var $panel = $($open.draft.getContentElement()).addClass('draft-panel');
/* 标题 */
var $title = $('<h2></h2>')
.text(minder.getLang('ui.menu.open.draft'))
.appendTo($panel);
$panel.append('<h2>草稿箱</h2>');
var $clear = $('<button></button>')
.addClass('clear-draft')
.text(minder.getLang('ui.cleardraft'))
.appendTo($panel);
/* 最近文件列表容器 */
var $ul = $('<ul></ul>')
.addClass('draft-list')
.appendTo($panel);
var current = null,
lastDoc = null;
$ul.delegate('.draft-list-item', 'click', function(e) {
var item = $(e.target).closest('.draft-list-item').data('item');
var index = draftList.findIndex(function(finding) {
return finding == item;
});
if (index > -1) {
current = item;
draftList.remove(index);
draftList.unshift(current);
lastDoc = {
title: current.title,
protocol: 'json',
content: current.json,
path: current.path,
source: current.source,
saved: false
};
$doc.load(lastDoc);
}
$menu.removeClass('show');
});
$clear.on('click', function() {
if (!window.confirm(minder.getLang('ui.cleardraftconfirm'))) return;
draftList.clear();
current = null;
renderList();
});
$doc.on('docsave', popDraft);
$doc.on('docchange', pushDraft);
renderList();
function pushDraft(doc) {
if (doc == lastDoc) {
if (current) {
draftList.remove(0);
}
} else {
current = null;
}
lastDoc = doc;
current = current || {};
current.json = JSON.stringify(minder.exportJson());
current.title = doc.title;
current.time = +new Date();
current.path = doc.path;
current.source = doc.source;
draftList.unshift(current);
renderList();
}
function popDraft() {
if (current) {
draftList.remove(0);
current = null;
}
renderList();
console.log('pop draft');
}
function renderList() {
$ul.empty();
draftList.forEach(function(item) {
var $li = $('<li></li>')
.addClass('draft-list-item')
.data('item', item)
.appendTo($ul);
$('<h4></h4>')
.addClass('draft-title')
.text(item.title)
.appendTo($li);
$('<span></span>')
.addClass('file-time')
.displayFriendlyTime(item.time)
.appendTo($li);
});
}
});
/* ui/menu/open/draft.js end */
......@@ -34968,7 +35376,7 @@
.text(minder.getLang('ui.menu.save.header'))
.appendTo($level1.save.getContentElement());
var source = ['netdisk', 'local'];
var source = ['netdisk', 'download'];
var $tabs = new FUI.Tabs({
buttons: source.map(function(key) {
......@@ -34993,6 +35401,8 @@
ret.fire('select', info);
});
$tabs.select(1);
// 暴露选择事件
ret.select = $tabs.select.bind($tabs);
......@@ -35017,19 +35427,23 @@
var $save = minder.getUI('menu/save/save');
var $netdiskfinder = minder.getUI('widget/netdiskfinder');
var $eve = minder.getUI('eve');
var $doc = minder.getUI('doc');
var ret = $eve.setup({});
var protocols = minder.getSupportedProtocols().filter(function(protocol) {
return protocol.encode;
/* extension => protocol */
var supports = {};
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.encode && protocol.decode) {
supports[protocol.fileExtension] = protocol;
}
});
/* 网盘面板 */
var $panel = $($save.netdisk.getContentElement()).addClass('netdisk-save-panel');
var $finder = $netdiskfinder.generate($panel, function(file) {
return protocols.some(function(protocol) {
return protocol.fileExtension == file.extension;
}, false);
return supports[file.extension];
});
var $selects = $('<div class="netdisk-save-select"></div>')
......@@ -35039,29 +35453,134 @@
.text(minder.getLang('ui.saveas'))
.appendTo($selects);
/* 文件名 */
var $filename = $('<input>')
.attr('type', 'text')
.attr('placeholder', minder.getLang('ui.filename'))
.attr('title', minder.getLang('ui.filename'))
.on('keydown', function(e) {
if (e.keyCode == 27) $menu.toggleClass('show');
})
.appendTo($selects);
/* 文件格式 */
var $format = $('<select>')
.attr('title', minder.getLang('ui.fileformat'))
.appendTo($selects);
protocols.forEach(function(protocol) {
for (var ext in supports) {
var protocol = supports[ext];
if (!protocol.encode) return;
$('<option>')
.text(protocol.fileDescription + '(' + protocol.fileExtension + ')')
.val(protocol.name)
.val(ext)
.appendTo($format);
});
}
$format.val('json');
$format.val('.km');
/* 保存按钮 */
var $saveBtn = $('<button></button>')
.addClass('save-button')
.text(minder.getLang('ui.save'))
.click(save)
.appendTo($selects);
$menu.on('show', setFileName);
$finder.on('fileclick', function(file) {
$finder.select(file.path);
$filename.val(file.filename);
});
function save() {
var filename = $filename.val();
if (fio.file.anlysisPath(filename).extension != $format.val()) {
$filename.val(filename += $format.val())[0].select();
}
var path = $finder.pwd() + filename;
var doc = $doc.current();
var protocol = supports[$format.val()];
var exist = $finder.select(path); // 目标路径存在
var match = doc.path == path; // 目标路径正是当前文档
var duplicated = exist && !match;
if (!exist || match || duplicated && window.confirm(minder.getLang('ui.overrideconfirm', filename))) {
doSave(path, protocol, doc);
}
}
function doSave(path, protocol, doc) {
$panel.addClass('loading');
return minder.exportData(protocol.name).then(function(data) {
return fio.file.write({
path: path,
content: data,
ondup: fio.file.DUP_OVERWRITE
});
}).then(function() {
$panel.removeClass('loading');
$menu.removeClass('show');
doc.path = path;
doc.title = $filename.val();
doc.source = 'netdisk';
$doc.save(doc);
setTimeout($finder.list, 500);
})['catch'](function(e) {
window.alert('保存文件失败:' + (e.message || minder.getLang('ui.unknownreason')));
});
}
function setFileName() {
var doc = $doc.current();
switch (doc.source) {
case 'netdisk':
setFileNameForNetDiskSource(doc);
break;
default:
setFileNameForOtherSource(doc);
break;
}
$filename[0].select();
}
function setFileNameForNetDiskSource(doc) {
var path = doc.path;
var pathInfo = fio.file.anlysisPath(path);
// 选中当前文件
if ($finder.pwd() != pathInfo.parentPath) {
$finder.list(pathInfo.parentPath).then(function() {
$finder.select(path);
});
} else {
$finder.select(path);
}
$filename.val(pathInfo.filename);
}
function setFileNameForOtherSource(doc) {
$filename.val(doc.title);
$finder.select(null);
}
return ret;
});
/* ui/menu/save/netdisk.js end */
......@@ -35073,12 +35592,111 @@
/**
* @fileOverview
*
*
* 导出数据到本地
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/save/download', function(minder) {
var $menu = minder.getUI('menu/menu');
var $save = minder.getUI('menu/save/save');
/* 导出面板 */
var $panel = $($save.download.getContentElement()).addClass('download-panel');
/* 标题 */
var $title = $('<h2></h2>')
.text(minder.getLang('ui.menu.save.download'))
.appendTo($panel);
var $list = $('<ul>')
.addClass('download-list')
.appendTo($panel);
var supports = [];
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.encode) {
supports.push(protocol);
}
});
supports.forEach(function(protocol) {
$('<li>')
.addClass(protocol.name)
.text(protocol.fileDescription + ' (' + protocol.fileExtension + ')')
.data('protocol', protocol)
.appendTo($list);
});
$list.delegate('li', 'click', function(e) {
var protocol = $(e.target).data('protocol');
doExport(protocol);
});
function doExport(protocol) {
var filename = minder.getMinderTitle() + protocol.fileExtension;
var mineType = protocol.mineType || 'text/plain';
$panel.addClass('loading');
minder.exportData(protocol.name).then(function(data) {
if (typeof(data) != 'string') return;
switch (protocol.dataType) {
case 'text':
return doDownload(buildDataUrl(mineType), filename, 'text');
case 'base64':
return doDownload(data, filename, 'base64');
}
return null;
}).then(function() {
$panel.removeClass('loading');
$menu.removeClass('show');
});
}
function doDownload(url, filename, type) {
var content = url.split(',')[1];
var $form = $('<form></form>').attr({
'action': 'download.php',
'method': 'POST',
'accept-charset': 'utf-8'
});
var $content = $('<input />').attr({
name: 'content',
type: 'hidden',
value: decodeURIComponent(content)
}).appendTo($form);
var $type = $('<input />').attr({
name: 'type',
type: 'hidden',
value: type
}).appendTo($form);
var $filename = $('<input />').attr({
name: 'filename',
type: 'hidden',
value: filename
}).appendTo($form);
$('<input name="iehack" value="&#9760;" />').appendTo($form);
$form.appendTo('body').submit().remove();
}
function buildDataUrl(mineType, data) {
return 'data:' + mineType + '; utf-8,' + encodeURIComponent(data);
}
});
/* ui/menu/save/download.js end */
......@@ -35088,11 +35706,34 @@
/**
* @fileOverview
*
*
* 分享功能交互
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/share/share', function(minder) {
var $level1 = minder.getUI('menu/level1');
var eve = minder.getUI('eve');
var $panel = $level1.share.getContentElement();
var $h2 = $('<h2></h2>')
.text(minder.getLang('ui.menu.share.header'))
.appendTo($panel);
var $publicShare = $('<fieldset>')
.appendTo($panel);
/* global jshtmls: true */
var render = jshtmls.render(function() {
/*template
<p>Mark Here</p>
fekwlf200sfwe
*/
});
});
/* ui/menu/share/share.js end */
......@@ -35141,6 +35782,8 @@
var $userPanel = $('<div class="user-panel"></div>').appendTo('#panel');
var $tip = $('<span></span>').text(minder.getLang('ui.checklogin')).appendTo($userPanel);
/* 登录按钮 */
var $loginButton = new FUI.Button({
label: minder.getLang('ui.login'),
......@@ -35202,7 +35845,11 @@
apiKey: 'wiE55BGOG8BkGnpPs6UNtPbb'
});
fio.user.check().then(check);
fio.user.check().then(check)['catch'](function(error) {
$loginButton.show();
$userButton.hide();
$tip.remove();
});
$loginButton.on('click', login);
$('body').delegate('.login-button', 'click', login);
......@@ -35218,6 +35865,7 @@
$loginButton.show();
$userButton.hide();
}
$tip.remove();
currentUser = user;
}
......@@ -35229,6 +35877,7 @@
}
function login() {
$loginButton.setLabel(minder.getLang('ui.loggingin'));
fio.user.login({
remember: 7 * 24 * 60 * 60 // remember 7 days
}).then(check);
......@@ -35322,9 +35971,7 @@
setSaved: function(saved) {
if (saved !== false) {
_saved = true;
}
_saved = saved !== false;
update();
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -67,7 +67,10 @@ KityMinder.LANG['zh-cn'] = {
'save': {
'header': '保存到',
'netdisk': '百度网盘',
'local': '导出到本地'
'download': '导出到本地'
},
'share': {
'header': '分享我的脑图'
}
},
......@@ -78,6 +81,16 @@ KityMinder.LANG['zh-cn'] = {
'dropfile': '或将文件拖至此处',
'unsupportedfile': '不支持的文件格式',
'untitleddoc': '未命名文档',
'errorloading': '加载失败:{0}',
'unknownreason': '可能是外星人篡改了代码...',
'overrideconfirm': '{0} 已存在,确认覆盖吗?',
'checklogin': '检查登录状态中...',
'loggingin': '正在登录...',
'recent': '最近打开',
'clearrecent': '清空',
'clearrecentconfirm': '确认清空最近文档列表?',
'cleardraft': '清空',
'cleardraftconfirm': '确认清空草稿箱?',
'login': '登录',
'logout': '注销',
......
......@@ -543,6 +543,108 @@
filter: blur(5px);
filter: url(../images/blur.svg#blur);
}
.validate-error {
color: red;
border-color: red !important;
}
.button,
button {
display: inline-block;
height: 30px;
padding: 0 15px;
line-height: 30px;
text-align: center;
outline: none;
background: #717b94;
cursor: default;
color: #ffffff;
border: none;
}
.button:hover,
button:hover {
background: #8e96aa;
}
.button:active,
button:active {
background: #656f87;
}
input[type=text] {
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid #c8ccd6;
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
border-radius: 2px;
}
input[type=text]:focus {
border-color: #6179b8;
}
.loading .loading-target {
-webkit-filter: blur(5px);
-moz-filter: blur(5px);
-mz-filter: blur(5px);
-o-filter: blur(5px);
filter: blur(5px);
filter: url(../images/blur.svg#blur);
}
.loading:after {
content: ' ';
display: block;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
background: rgba(128, 130, 140, 0.75);
}
.loading:before {
content: ' ';
width: 40px;
height: 40px;
border: 4px solid;
border-color: #ffffff transparent transparent;
box-shadow: 0 0 35px white;
position: absolute;
left: 50%;
top: 50%;
margin-left: -24px;
margin-top: -24px;
z-index: 10;
border-radius: 100%;
-webkit-animation: rotate 1.33s ease infinite;
}
@-webkit-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-moz-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-ms-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
.triangle {
content: ' ';
display: block;
......@@ -867,37 +969,6 @@
line-height: 30px;
height: 30px;
}
.validate-error {
color: red;
border-color: red !important;
}
.button,
button {
display: inline-block;
height: 30px;
padding: 0 15px;
line-height: 30px;
text-align: center;
outline: none;
background: #717b94;
cursor: default;
color: #ffffff;
border: none;
}
.button:hover,
button:hover {
background: #8e96aa;
}
.button:active,
button:active {
background: #656f87;
}
input[type=text] {
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid #abb1c0;
}
/**
* 基本页面样式
*/
......@@ -933,72 +1004,6 @@ body {
left: 0;
-moz-user-select: none;
}
#kityminder.loading svg {
-webkit-filter: blur(5px);
-moz-filter: blur(5px);
-mz-filter: blur(5px);
-o-filter: blur(5px);
filter: blur(5px);
filter: url(../images/blur.svg#blur);
}
#kityminder.loading:after {
content: ' ';
display: block;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
background: rgba(128, 130, 140, 0.75);
}
#kityminder.loading:before {
content: ' ';
width: 40px;
height: 40px;
border: 4px solid;
border-color: #fff transparent transparent;
box-shadow: 0 0 35px white;
position: absolute;
left: 50%;
top: 50%;
margin-left: -24px;
margin-top: -24px;
z-index: 10;
border-radius: 100%;
-webkit-animation: rotate 1.33s ease infinite;
}
@-webkit-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-moz-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-ms-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
#panel {
background: #393f4f;
font-family: 'Hiragino Sans GB', 'Arial', 'Microsoft Yahei';
......@@ -1053,21 +1058,22 @@ body {
top: 16px;
}
#main-menu {
background: white;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
overflow: hidden;
transform: scale(0);
transform: translate3d(0, -100%, 0);
transform-origin: 0 0;
opacity: 0;
transition: opacity .25s ease, transform .25s ease;
transition: opacity .2s ease, transform .2s ease;
z-index: 100;
}
#main-menu.show {
opacity: 1;
transform: scale(1);
transform: translate3d(0, 0, 0);
}
#main-menu:before {
content: ' ';
......@@ -1080,11 +1086,11 @@ body {
box-shadow: 0 -3px 8px rgba(0, 0, 0, 0.15);
z-index: 1;
transform: translateX(-200px) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
.show#main-menu:before {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
#main-menu .main-menu-header {
background: white;
......@@ -1097,28 +1103,45 @@ body {
height: 40px;
}
#main-menu .main-menu-back-panel .main-menu-back-button {
width: 25px;
height: 25px;
border-radius: 100%;
border: 2px solid white;
left: 5px;
top: 5px;
cursor: pointer;
width: 190px;
height: 30px;
padding: 5px;
}
#main-menu .main-menu-back-panel .main-menu-back-button .fui-label {
display: inline-block;
color: white;
margin-left: 10px;
font-size: 14px;
display: none;
}
#main-menu .main-menu-back-panel .main-menu-back-button .fui-icon {
display: block;
display: inline-block;
width: 25px;
height: 25px;
line-height: 25px;
border-radius: 100%;
border: 2px solid white;
background: url(../images/icons.png) -1px -370px;
vertical-align: middle;
}
#main-menu .main-menu-back-panel .main-menu-back-button:hover {
background-color: rgba(255, 255, 255, 0.3);
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* FF3.6+ */
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0.3)), color-stop(100%, rgba(255, 255, 255, 0)));
/* Chrome,Safari4+ */
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* Opera 11.10+ */
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* IE10+ */
background: linear-gradient(to right, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* W3C */
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#4dffffff', endColorstr='#00ffffff', GradientType=1);
/* IE6-9 */
}
#main-menu .main-menu-back-panel .main-menu-back-button:active {
background-color: rgba(0, 0, 0, 0.05);
background: #fb5151;
}
#main-menu .main-menu-title {
margin-left: 200px;
......@@ -1132,11 +1155,11 @@ body {
line-height: 40px;
color: #999;
transform: translateX(-200px) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
.show#main-menu .main-menu-title {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
#main-menu .main-menu-level-1 {
position: absolute;
......@@ -1187,12 +1210,12 @@ body {
background-color: white;
z-index: 2;
transform: translateX(-200px) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
/* 每个二级菜单的面板 */
}
.show#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel {
position: absolute;
......@@ -1548,6 +1571,9 @@ body {
float: right;
height: 40px;
line-height: 40px;
font-size: 14px;
color: #ffffff;
vertical-align: baseline;
}
#panel div.user-panel .fui-button {
padding: 5px 10px;
......@@ -1593,11 +1619,25 @@ body {
top: 2px;
background: url(../images/icons.png) no-repeat 0 -520px;
}
.recent-file-panel > .clear-recent-list {
position: absolute;
right: 0;
top: 0;
}
.recent-file-panel > .recent-file-list {
margin: 0;
padding: 0;
list-style: none;
}
.recent-file-panel > .recent-file-list:empty:after {
content: '没有最近打开文件!';
display: block;
text-align: center;
font-size: 18px;
height: 50px;
line-height: 50px;
color: #CCC;
}
.recent-file-panel > .recent-file-list .recent-file-item {
font-size: 14px;
line-height: 20px;
......@@ -1727,6 +1767,13 @@ body {
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item:active {
background-color: #e5e7ec;
}
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item.selected {
background-color: #717b94;
color: white;
}
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item.selected.file:before {
background-position: 0 -545px;
}
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item.file {
position: relative;
}
......@@ -1799,7 +1846,8 @@ body {
display: block;
}
.netdisk-finder-container.require-login .netdisk-nav,
.netdisk-finder-container.require-login .netdisk-file-list {
.netdisk-finder-container.require-login .netdisk-file-list,
.netdisk-finder-container.require-login .netdisk-mkdir {
display: none;
}
.netdisk-save-panel .netdisk-file-list {
......@@ -1811,7 +1859,7 @@ body {
right: 0;
bottom: 0;
left: 0;
height: 30px;
height: auto;
padding: 10px;
border-top: 1px solid #EEE;
background: #fcfcfc;
......@@ -1824,27 +1872,20 @@ body {
}
.netdisk-save-select > input {
width: 50%;
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid #abb1c0;
margin: 0;
margin-top: 5px;
margin-right: 10px;
vertical-align: middle;
}
.netdisk-save-select > input:focus {
border-color: #abb1c0;
}
.netdisk-save-select > select {
margin: 5px 0 0 10px;
margin: 5px 0 0 0;
outline: none;
vertical-align: middle;
}
.netdisk-save-select > .save-button {
position: absolute;
right: 10px;
top: 10px;
float: right;
width: 80px;
vertical-align: middle;
}
.local-file-open-panel {
position: relative;
......@@ -1880,6 +1921,9 @@ body {
.local-file-open-panel .pick-file a:active {
background: #656f87;
}
.local-file-open-panel .pick-file span {
line-height: 30px;
}
.local-file-open-panel .drop-file {
border: 2px dashed #eee;
border-radius: 4px;
......@@ -1904,6 +1948,100 @@ body {
border-color: #eee;
color: #eee;
}
.draft-panel h2:before {
content: ' ';
display: block;
width: 25px;
height: 25px;
position: absolute;
left: 0;
background: url(../images/icons.png) no-repeat 0 -570px;
}
.draft-panel > .clear-draft {
position: absolute;
right: 0;
top: 0;
}
.draft-panel > .draft-list {
margin: 0;
padding: 0;
list-style: none;
}
.draft-panel > .draft-list:empty:after {
content: '这是个空虚寂寞的草稿箱!';
display: block;
text-align: center;
font-size: 18px;
height: 50px;
line-height: 50px;
color: #CCC;
}
.draft-panel > .draft-list .draft-list-item {
font-size: 14px;
line-height: 20px;
padding: 10px 20px 10px 40px;
cursor: default;
position: relative;
}
.draft-panel > .draft-list .draft-list-item:hover {
background-color: #f4f5f7;
}
.draft-panel > .draft-list .draft-list-item:active {
background-color: #e5e7ec;
}
.draft-panel > .draft-list .draft-list-item .draft-title {
margin: 0;
font-weight: normal;
height: 20px;
line-height: 20px;
}
.draft-panel > .draft-list .draft-list-item .draft-title:after {
content: ' ';
display: block;
position: absolute;
width: 25px;
height: 25px;
background: url(../images/icons.png) no-repeat 0 -445px;
left: 5px;
top: 10px;
}
.draft-panel > .draft-list .draft-list-item .file-time {
position: absolute;
right: 5px;
top: 10px;
font-size: 12px;
color: #999;
}
.download-panel h2:before {
content: ' ';
display: block;
width: 25px;
height: 25px;
position: absolute;
left: 0;
background: url(../images/icons.png) no-repeat 0 -595px;
}
.download-panel > .download-list {
margin: 0;
padding: 0;
list-style: none;
}
.download-panel > .download-list li {
font-size: 14px;
padding: 10px 20px 10px 40px;
cursor: default;
position: relative;
margin: 0;
font-weight: normal;
height: 20px;
line-height: 20px;
}
.download-panel > .download-list li:hover {
background-color: #f4f5f7;
}
.download-panel > .download-list li:active {
background-color: #e5e7ec;
}
#tab-container .command-buttonset.priority {
width: 140px;
}
......
......@@ -14,8 +14,10 @@
'lib/ZeroClipboard.min.js',
'lib/fui/dev-lib/jhtmls.min.js',
'lib/fui/dist/fui.all.js',
'lib/fio/dist/fio.js',
'lib/fio/src/fio.js',
'lib/fio/provider/netdisk/oauth.js',
'lib/fio/provider/netdisk/netdisk.js',
'lib/fio/provider/mongoshare/mongoshare.js',
/* Kity 依赖库 */
'lib/kity/dist/kity.js',
......@@ -102,6 +104,7 @@
'ui/eve.js',
'ui/fuix.js',
'ui/fiox.js',
'ui/doc.js',
/* UI 组件 */
'ui/widget/commandbutton.js',
......@@ -109,22 +112,21 @@
'ui/widget/commandinputmenu.js',
'ui/widget/friendlytimespan.js',
'ui/widget/locallist.js',
'ui/widget/fileloader.js',
'ui/widget/netdiskfinder.js',
'ui/widget/menutab',
/* UI 菜单 */
'ui/menu/menu.js',
'ui/menu/header.js',
'ui/menu/level1.js',
/* UI 菜单 - 新建 */
'ui/menu/new/new.js',
/* UI 菜单 - 打开 */
'ui/menu/open/open.js',
'ui/menu/open/local.js',
'ui/menu/open/netdisk.js',
'ui/menu/open/recent.js',
'ui/menu/open/netdisk.js',
'ui/menu/open/local.js',
'ui/menu/open/draft.js',
/* UI 菜单 - 保存 */
......
/**
* 开发版本的文件导入
*/
(function() {
var paths = [
/* 依赖库 */
'lib/jquery-2.1.1.js',
'lib/jquery.transit.min.js',
'lib/promise-1.0.0.js',
'lib/fui/dev-lib/jhtmls.min.js',
'lib/fui/dist/fui.all.js',
/* Kity 依赖库 */
'lib/kity/dist/kity.js',
/* 核心代码 */
'src/core/kityminder.js',
'src/core/utils.js',
'src/core/command.js',
'src/core/node.js',
'src/core/module.js',
'src/core/event.js',
'src/core/minder.js',
'src/core/minder.data.compatibility.js',
'src/core/minder.data.js',
'src/core/minder.event.js',
'src/core/minder.module.js',
'src/core/minder.command.js',
'src/core/minder.node.js',
'src/core/minder.select.js',
'src/core/keymap.js',
'src/core/minder.lang.js',
'src/core/minder.defaultoptions.js',
'src/core/minder.preference.js',
'src/core/browser.js',
'src/core/layout.js',
'src/core/connect.js',
'src/core/render.js',
'src/core/theme.js',
'src/core/template.js',
/* 布局 */
'src/layout/default.js',
'src/layout/default.connect.js',
'src/layout/bottom.js',
'src/layout/filetree.js',
/* 皮肤 */
'src/theme/default.js',
'src/theme/snow.js',
'src/theme/fresh.js',
/* 模板 */
'src/template/structure.js',
/* 模块 */
'src/module/node.js',
'src/module/text.js',
'src/module/expand.js',
'src/module/outline.js',
'src/module/geometry.js',
'src/module/history.js',
'src/module/progress.js',
'src/module/priority.js',
'src/module/image.js',
'src/module/resource.js',
'src/module/view.js',
'src/module/dragtree.js',
'src/module/keyboard.js',
'src/module/select.js',
'src/module/history.js',
'src/module/basestyle.js',
'src/module/font.js',
'src/module/zoom.js',
'src/module/hyperlink.js',
'src/module/arrange.js',
'src/module/paste.js',
'src/module/style.js',
/* 格式支持 */
'src/protocol/plain.js',
'src/protocol/json.js',
'src/protocol/png.js',
'src/protocol/svg.js',
/* UI 基础 */
'ui/ui.js',
'ui/eve.js',
'ui/fuix.js',
// 'ui/fiox.js',
'ui/doc.js',
/* UI 组件 */
// 'ui/widget/commandbutton.js',
// 'ui/widget/commandbuttonset.js',
// 'ui/widget/commandinputmenu.js',
// 'ui/widget/friendlytimespan.js',
// 'ui/widget/locallist.js',
// 'ui/widget/netdiskfinder.js',
'ui/widget/menutab',
/* UI 菜单 */
'ui/menu/menu.js',
'ui/menu/header.js',
/* UI 菜单 - 新建 */
// 'ui/menu/new/new.js',
/* UI 菜单 - 打开 */
// 'ui/menu/open/open.js',
// 'ui/menu/open/recent.js',
// 'ui/menu/open/netdisk.js',
// 'ui/menu/open/local.js',
// 'ui/menu/open/draft.js',
/* UI 菜单 - 保存 */
'ui/menu/save/save.js',
// 'ui/menu/save/netdisk.js',
'ui/menu/save/download.js',
/* UI 菜单 - 分享 */
// 'ui/menu/share/share.js',
/* UI Top Bar */
// 'ui/topbar/history.js',
// 'ui/topbar/user.js',
'ui/topbar/search.js',
'ui/topbar/title.js',
/* UI Ribbon */
// 'ui/ribbon/tabs.js',
/* UI Ribbon「思路」面板 */
// 'ui/ribbon/idea/insert.js',
// 'ui/ribbon/idea/arrange.js',
// 'ui/ribbon/idea/operation.js',
// 'ui/ribbon/idea/attachment.js',
// 'ui/ribbon/idea/link.js',
// 'ui/ribbon/idea/image.js',
// 'ui/ribbon/idea/priority.js',
// 'ui/ribbon/idea/progress.js',
// 'ui/ribbon/idea/resource.js',
/* UI Ribbon「展示」面板 */
// 'ui/ribbon/appearence/template.js',
// 'ui/ribbon/appearence/theme.js',
// 'ui/ribbon/appearence/layout.js',
// 'ui/ribbon/appearence/style.js',
// 'ui/ribbon/appearence/font.js',
// 'ui/ribbon/appearence/color.js',
/* UI Ribbon「视图」面板 */
// 'ui/ribbon/view/level.js'
];
if (typeof(module) === 'object' && module.exports) {
module.exports = paths;
} else if (document) {
while (paths.length) {
/* jshint browser:true */
window.document.write('<script type="text/javascript" src="' + paths.shift() + '"></script>');
}
}
})();
\ No newline at end of file
......@@ -27,22 +27,6 @@
</div>
<div id="share-dialog">
<h3>URL分享:</h3>
<p>
<input id="share-url" type="url" value="http://naotu.baidu.com/?shareId=kcev3dd" />
<button id="copy-share-url" data-clipboard-target="share-url" type="button">复制</button>
</p>
<h3>社交分享:</h3>
<p id="share-platform" class="bdsharebuttonbox">
<a href="#" class="bds_tsina" data-cmd="tsina" title="分享到新浪微博"></a>
<a href="#" class="bds_qzone" data-cmd="qzone" title="分享到QQ空间"></a>
<a href="#" class="bds_tqq" data-cmd="tqq" title="分享到腾讯微博"></a>
<a href="#" class="bds_renren" data-cmd="renren" title="分享到人人网"></a>
<a href="#" class="bds_weixin" data-cmd="weixin" title="分享到微信"></a>
</p>
</div>
<div id="about">
<svg id="km-cat" viewBox="0 0 1200 1200" width="32px" height="32px">
<g id="cat-face">
......@@ -100,7 +84,6 @@
$(function() {
/* 依赖库初始化 */
ZeroClipboard.setDefaults({ moviePath: 'lib/ZeroClipboard.swf' });
zip.inflateJSPath = 'lib/inflate.js';
});
......
......@@ -46,29 +46,27 @@ KityMinder.LANG['zh-cn'] = {
},
'menu': {
'level1': {
'new': '新建',
'open': '打开',
'save': '保存',
'share': '分享',
'help': '帮助',
'setting': '设置'
},
'new': {
'header': '新建脑图'
},
'open': {
'header': '打开',
'recent': '最近使用',
'netdisk': '百度云盘',
'local': '本地文件',
'draft': '草稿箱'
},
'save': {
'header': '保存到',
'netdisk': '百度网盘',
'local': '导出到本地'
}
'mainmenutext': '百度脑图', // 主菜单按钮文本
'newtab': '新建',
'opentab': '打开',
'savetab': '保存',
'sharetab': '分享',
'helptab': '帮助',
'settingtab': '设置',
'recenttab': '最近使用',
'netdisktab': '百度云存储',
'localtab': '本地文件',
'drafttab': '草稿箱',
'downloadtab': '导出到本地',
'createsharetab': '当前脑图',
'managesharetab': '已分享',
'newheader': '新建脑图',
'openheader': '打开',
'saveheader': '保存到',
'shareheader': '分享我的脑图'
},
'mydocument': '我的文档',
......@@ -78,6 +76,34 @@ KityMinder.LANG['zh-cn'] = {
'dropfile': '或将文件拖至此处',
'unsupportedfile': '不支持的文件格式',
'untitleddoc': '未命名文档',
'errorloading': '加载失败:{0}',
'unknownreason': '可能是外星人篡改了代码...',
'overrideconfirm': '{0} 已存在,确认覆盖吗?',
'checklogin': '检查登录状态中...',
'loggingin': '正在登录...',
'recent': '最近打开',
'clearrecent': '清空',
'clearrecentconfirm': '确认清空最近文档列表?',
'cleardraft': '清空',
'cleardraftconfirm': '确认清空草稿箱?',
'none_share': '不分享',
'public_share': '公开分享',
'password_share': '私密分享',
'email_share': '邮件邀请',
'url_share': '脑图 URL 地址:',
'sns_share': '社交网络分享:',
'sns_share_text': '“{0}” - 我用「百度脑图」制作的思维导图,快看看吧!(地址:{1})',
'none_share_description': '不分享当前脑图',
'public_share_description': '创建任何人可见的分享',
'share_button_text': '创建',
'password_share_description': '创建需要密码才可见的分享',
'email_share_description': '创建指定人可见的分享,您还可以允许他们编辑',
'ondev': '敬请期待!',
'create_share_failed': '分享失败:{0}',
'copy': '复制',
'copied': '已复制',
'shared_tip': '当前脑图被 {0} 分享,你可以修改之后保存到自己的网盘上或再次分享',
'login': '登录',
'logout': '注销',
......
Subproject commit b5a61278a057db00d81d54718514df9492007d1e
Subproject commit f56bdb0c9bd079b42ea07f683dc79c5796174ea9
Subproject commit bdca414351274d350a1cc87c2f3d17536b715903
Subproject commit 7198d3af584d6cf2b4b6335045a57d0b07d5c292
......@@ -269,7 +269,7 @@ define("promise/polyfill",
return isFunction(resolve);
}());
if (!es6PromiseSupport) {
if (!es6PromiseSupport || ~window.location.href.indexOf('rsvpromise')) {
local.Promise = RSVPPromise;
}
}
......
......@@ -35,8 +35,7 @@ kity.extendClass(Minder, {
});
},
exportData: function(protocolName) {
exportJson: function() {
/* 导出 node 上整棵树的数据为 JSON */
function exportNode(node) {
var exported = {};
......@@ -51,14 +50,67 @@ kity.extendClass(Minder, {
return exported;
}
var json, protocol;
json = exportNode(this.getRoot());
var json = exportNode(this.getRoot());
json.template = this.getTemplate();
json.theme = this.getTheme();
json.version = KityMinder.version;
return json;
},
importJson: function(json, params) {
function importNode(node, json, km) {
var data = json.data;
node.data = {};
for (var field in data) {
node.setData(field, data[field]);
}
node.setData('text', data.text || km.getLang(DEFAULT_TEXT[node.getType()]));
var childrenTreeData = json.children || [];
for (var i = 0; i < childrenTreeData.length; i++) {
var childNode = km.createNode(null, node);
importNode(childNode, childrenTreeData[i], km);
}
return node;
}
if (!json) return;
this._fire(new MinderEvent('preimport', params, false));
// 删除当前所有节点
while (this._root.getChildren().length) {
this.removeNode(this._root.getChildren()[0]);
}
json = KityMinder.compatibility(json);
importNode(this._root, json, this);
this.setTemplate(json.template || null);
this.setTheme(json.theme || null);
this.refresh();
this.fire('import', params);
this._firePharse({
type: 'contentchange'
});
this._firePharse({
type: 'interactchange'
});
},
exportData: function(protocolName) {
var json, protocol;
json = this.exportJson();
// 指定了协议进行导出,需要检测协议是否支持
if (protocolName) {
protocol = this.getProtocol(protocolName);
......@@ -112,57 +164,11 @@ kity.extendClass(Minder, {
}).then(function(json) {
minder._doImport(json, params);
minder.importJson(json, params);
return json;
});
},
_doImport: function(json, params) {
function importNode(node, json, km) {
var data = json.data;
node.data = {};
for (var field in data) {
node.setData(field, data[field]);
}
node.setData('text', data.text || km.getLang(DEFAULT_TEXT[node.getType()]));
var childrenTreeData = json.children || [];
for (var i = 0; i < childrenTreeData.length; i++) {
var childNode = km.createNode(null, node);
importNode(childNode, childrenTreeData[i], km);
}
return node;
}
if (!json) return;
this._fire(new MinderEvent('preimport', params, false));
// 删除当前所有节点
while (this._root.getChildren().length) {
this.removeNode(this._root.getChildren()[0]);
}
json = KityMinder.compatibility(json);
importNode(this._root, json, this);
this.setTemplate(json.template || null);
this.setTheme(json.theme || null);
this.refresh();
this.fire('import', params);
this._firePharse({
type: 'contentchange'
});
this._firePharse({
type: 'interactchange'
});
}
});
\ No newline at end of file
......@@ -368,7 +368,6 @@ KityMinder.registerModule('DragTree', function() {
dragger.dragEnd();
//e.stopPropagation();
e.preventDefault();
this.fire('contentchange');
},
'statuschange': function(e) {
if (e.lastStatus == 'textedit' && e.currentStatus == 'normal') {
......
......@@ -219,9 +219,9 @@ Minder.Receiver = kity.createClass('Receiver', {
this.km.setStatus('inputready');
clearTimeout(me.inputTextTimer);
e.preventDefault();
this.km.fire('contentchange');
}else{
this.km.setStatus('normal');
this.km.fire('contentchange');
}
restoreTextContent();
return;
......@@ -303,7 +303,6 @@ Minder.Receiver = kity.createClass('Receiver', {
e.preventDefault();
}else{
this.km.setStatus('normal');
this.km.fire('contentchange');
}
restoreTextContent();
return;
......
......@@ -74,7 +74,7 @@ KityMinder.registerProtocol('freemind', function(minder) {
}
return {
fileDescription: 'freemind格式文件',
fileDescription: 'Freemind 格式',
fileExtension: '.mm',
dataType: 'text',
......
KityMinder.registerProtocol('json', function(minder) {
return {
fileDescription: 'KityMinder',
fileDescription: 'KityMinder 格式',
fileExtension: '.km',
dataType: 'text',
mineType: 'application/json',
......
......@@ -113,7 +113,7 @@ KityMinder.registerProtocol('mindmanager', function(minder) {
}
return {
fileDescription: 'mindmanager格式文件',
fileDescription: 'MindManager 格式',
fileExtension: '.mmap',
dataType: 'blob',
......
......@@ -138,6 +138,7 @@ if (!kity.Browser.ie) {
fileDescription: 'PNG 图片',
fileExtension: '.png',
mineType: 'image/png',
dataType: 'base64',
encode: encode,
recognizePriority: -1
};
......
......@@ -6,6 +6,7 @@ if (!kity.Browser.ie) {
fileDescription: 'SVG 矢量图',
fileExtension: '.svg',
mineType: 'image/svg+xml',
dataType: 'text',
encode: function(json) {
......
......@@ -32,7 +32,7 @@ KityMinder.registerProtocol('xmind', function(minder) {
};
return {
fileDescription: 'xmind格式文件',
fileDescription: 'XMind 格式',
fileExtension: '.xmind',
dataType: 'blob',
......
/**
* @fileOverview
*
* 当前文档管理
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('doc', function(minder) {
var ret = minder.getUI('eve').setup({});
var current = {};
var loading = false;
/**
* 加载文档
*
* @param {Object} doc 文档的属性,可包括:
* doc.content {string} [Required] 文档内容
* doc.protocol {string} [Required] 内容所使用的编码协议
* doc.title {string} 文档的标题
* doc.source {string} 文档的来源
* doc.path {string} 文档的路径
* doc.saved {bool} 文档的保存状态
*
* @event docload(doc)
* doc - 文档解析之后的文档对象
*
* @return {Promise<doc>} 返回解析完之后的文档对象,解析的结果为 doc.data
*/
function load(doc) {
var restore = doc;
current = doc;
loading = true;
return minder.importData(doc.content, doc.protocol).then(function(data) {
doc.title = doc.title || minder.getMinderTitle();
minder.execCommand('camera', minder.getRoot(), 300);
doc.data = data;
doc.json = JSON.stringify(data);
minder.getUI('topbar/title').setTitle(doc.title, doc.saved);
ret.fire('docload', doc);
return doc;
})['catch'](function(e) {
current = restore;
throw e;
}).then(function(doc) {
loading = false;
return doc;
});
}
function save(doc) {
current = doc;
minder.getUI('topbar/title').setTitle(doc.title, true);
ret.fire('docsave', doc);
}
function getCurrent() {
return current;
}
/* 绕开初始化时候的乱事件 */
setTimeout(function() {
minder.on('contentchange', function() {
if (loading) return;
var $title = minder.getUI('topbar/title');
if (current.source != 'netdisk') {
current.title = minder.getMinderTitle();
$title.setTitle(current.title, false);
ret.fire('docchange', current);
} else {
if (current.json != JSON.stringify(minder.exportJson())) {
$title.setSaved(false);
ret.fire('docchange', current);
} else {
$title.setSaved(true);
}
}
});
}, 1000);
ret.load = load;
ret.save = save;
ret.current = getCurrent;
return ret;
});
\ No newline at end of file
......@@ -10,4 +10,9 @@
KityMinder.registerUI('fiox', function(minder) {
var eve = minder.getUI('eve');
eve.setup(fio.user);
/* 初始化网盘使用的 APP 身份 */
fio.user.init({
apiKey: 'wiE55BGOG8BkGnpPs6UNtPbb'
});
});
\ No newline at end of file
/**
* @fileOverview
*
* 菜单默认选择项目
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/default', function (minder) {
});
\ No newline at end of file
......@@ -7,21 +7,29 @@
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/header', function (minder) {
KityMinder.registerUI('menu/header', function(minder) {
var $menu = minder.getUI('menu/menu');
var $header = $('<div class="main-menu-header"></div>').appendTo($menu);
var $header = $('<div class="main-menu-header"></div>')
.prependTo($menu.$panel);
var $backPanel = $('<div class="main-menu-back-panel"></div>').appendTo($header);
var $backPanel = $('<div class="main-menu-back-panel"></div>')
.appendTo($header);
var $titlePanel = $('<div class="main-menu-title">百度脑图</div>').appendTo($header);
var $titlePanel = $('<div class="main-menu-title">百度脑图</div>')
.appendTo($header);
var $backButton = new FUI.Button({
className: 'main-menu-back-button',
label: minder.getLang('ui.back')
}).appendTo($backPanel[0]).on('click', function() {
$menu.removeClass('show');
}).appendTo($backPanel[0]).on('click', $menu.hide);
$menu.on('show', function() {
var $title = minder.getUI('topbar/title');
$titlePanel.text($title.getTitle());
});
return $header;
......
/**
* @fileOverview
*
* 一级菜单
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/level1', function(minder) {
var $menu = minder.getUI('menu/menu');
var tabs = ['new', 'open', 'save', 'share', 'help'];
var $l1_tabs = new FUI.Tabs({
buttons: tabs.map(function(key) {
return {
label: minder.getLang('ui.menu.level1.' + key),
className: key
};
}),
className: 'main-menu-level-1'
});
$l1_tabs.appendTo($menu[0]);
$l1_tabs.select(2);
var ret = {};
tabs.forEach(function(key, index) {
ret[key] = $l1_tabs.getPanel(index);
});
return ret;
});
\ No newline at end of file
......@@ -9,27 +9,79 @@
KityMinder.registerUI('menu/menu', function(minder) {
var $mainMenuButton = new FUI.Button({
id: 'main-menu-btn'
});
var ret = minder.getUI('eve').setup({});
var $menutab = minder.getUI('widget/menutab');
// 主菜单容器
var $panel = $('<div>')
.attr('id', 'main-menu')
.appendTo('#content-wrapper');
// 主菜单按钮
var $button = new FUI.Button({
id: 'main-menu-btn',
label: minder.getLang('ui.menu.mainmenutext')
}).appendTo(document.getElementById('panel'));
var $panel;
// 一级菜单选项卡
var $tabs = new FUI.Tabs({
className: 'main-menu-level1'
}).appendTo($panel[0]);
$mainMenuButton.setLabel('百度脑图');
$mainMenuButton.appendTo(document.getElementById('panel'));
$mainMenuButton.on('click', function(e) {
function show() {
$panel.addClass('show');
});
ret.fire('show');
}
$panel = $('<div id="main-menu"></div>').appendTo('#content-wrapper');
function hide() {
$panel.removeClass('show');
ret.fire('hide');
}
function toggle() {
($panel.hasClass('show') ? hide : show)();
}
function createSub(name, asDefault) {
var $sub = $menutab.generate($tabs, name, asDefault);
var $h2 = $('<h2></h2>')
.text(minder.getLang('ui.menu.' + name + 'header'))
.appendTo($sub);
return $sub;
}
function createSubMenu(name, asDefault) {
var $sub = createSub(name, asDefault);
var $subtabs = new FUI.Tabs().appendTo($sub);
return {
$tabs: $subtabs,
createSub: function(subname, asDefault) {
return $menutab.generate($subtabs, subname, asDefault);
}
};
}
$button.on('click', toggle);
$(window).keydown(function(e) {
// ESC Pressed
if (e.keyCode == 27) {
$panel.toggleClass('show');
}
if (e.keyCode == 27) toggle();
});
return $panel.addClass('show');
// expose
ret.show = show;
ret.hide = hide;
ret.toggle = toggle;
ret.createSub = createSub;
ret.createSubMenu = createSubMenu;
ret.$panel = $panel;
ret.$button = $button;
ret.$tabs = $tabs;
show();
return ret;
});
\ No newline at end of file
......@@ -10,14 +10,10 @@
KityMinder.registerUI('menu/new/new', function(minder) {
var $menu = minder.getUI('menu/menu');
var $level1 = minder.getUI('menu/level1');
var eve = minder.getUI('eve');
var $doc = minder.getUI('doc');
var ret = minder.getUI('eve').setup({});
var $panel = $level1['new'].getContentElement();
var $h2 = $('<h2></h2>')
.text(minder.getLang('ui.menu.new.header'))
.appendTo($panel);
var $panel = $menu.createSub('new');
// 模板列表容器
var $ul = $('<ul></ul>')
......@@ -40,20 +36,18 @@ KityMinder.registerUI('menu/new/new', function(minder) {
$ul.delegate('.template-item', 'click', function(e) {
var template = $(e.target).data('template');
minder.importData({
$doc.load({
content: {
template: template,
version: KityMinder.version,
data: {
text: minder.getLang('template')[template]
}
},
protocol: null
});
minder.execCommand('camera', minder.getRoot());
$menu.removeClass('show');
$menu.hide();
});
var ret = {};
eve.setup(ret);
return ret;
});
\ No newline at end of file
......@@ -8,9 +8,137 @@
*/
KityMinder.registerUI('menu/open/draft', function(minder) {
var $menu = minder.getUI('menu/menu');
var $open = minder.getUI('menu/open/open');
var $panel = $($open.draft.getContentElement()).addClass('draft-file-list');
var drafts = minder.getUI('widget/locallist').use('draft');
var $loader = minder.getUI('widget/fileloader');
$panel.append('<h2>草稿箱</h2>');
var frdTime = minder.getUI('widget/friendlytimespan');
var $doc = minder.getUI('doc');
// 旧数据迁移
if (localStorage.drafts) {
var oldDrafts = JSON.parse(localStorage.drafts);
var list = oldDrafts.map(function(draft) {
var ret = {};
ret.json = draft.data;
ret.time = +new Date(draft.update);
ret.title = JSON.parse(draft.data).data.text;
return ret;
});
delete localStorage.drafts;
localStorage.draft = JSON.stringify(list);
}
var draftList = minder.getUI('widget/locallist').use('draft');
/* 网盘面板 */
var $panel = $($open.createSub('draft')).addClass('draft-panel');
/* 标题 */
var $title = $('<h2></h2>')
.text(minder.getLang('ui.menu.open.draft'))
.appendTo($panel);
var $clear = $('<button></button>')
.addClass('clear-draft')
.text(minder.getLang('ui.cleardraft'))
.appendTo($panel);
/* 最近文件列表容器 */
var $ul = $('<ul></ul>')
.addClass('draft-list')
.appendTo($panel);
var current = null,
lastDoc = null;
$ul.delegate('.draft-list-item', 'click', function(e) {
var item = $(e.target).closest('.draft-list-item').data('item');
var index = draftList.findIndex(function(finding) {
return finding == item;
});
if (index > -1) {
current = item;
draftList.remove(index);
draftList.unshift(current);
lastDoc = {
title: current.title,
protocol: 'json',
content: current.json,
path: current.path,
source: current.source,
saved: false
};
$doc.load(lastDoc);
}
$menu.hide();
});
$clear.on('click', function() {
if (!window.confirm(minder.getLang('ui.cleardraftconfirm'))) return;
draftList.clear();
current = null;
renderList();
});
$doc.on('docsave', popDraft);
$doc.on('docchange', pushDraft);
renderList();
function pushDraft(doc) {
if (doc == lastDoc) {
if (current) {
draftList.remove(0);
}
} else {
current = null;
}
lastDoc = doc;
current = current || {};
current.json = JSON.stringify(minder.exportJson());
current.title = doc.title;
current.time = +new Date();
current.path = doc.path;
current.source = doc.source;
draftList.unshift(current);
renderList();
}
function popDraft() {
if (current) {
draftList.remove(0);
current = null;
}
renderList();
console.log('pop draft');
}
function renderList() {
$ul.empty();
draftList.forEach(function(item) {
var $li = $('<li></li>')
.addClass('draft-list-item')
.data('item', item)
.appendTo($ul);
$('<h4></h4>')
.addClass('draft-title')
.text(item.title)
.appendTo($li);
$('<span></span>')
.addClass('file-time')
.displayFriendlyTime(item.time)
.appendTo($li);
});
}
});
\ No newline at end of file
......@@ -11,51 +11,27 @@ KityMinder.registerUI('menu/open/local', function(minder) {
var $menu = minder.getUI('menu/menu');
var $open = minder.getUI('menu/open/open');
var $loader = minder.getUI('widget/fileloader');
var $doc = minder.getUI('doc');
// 支持的文件类型
var supportedExtensions = [];
/* extension => protocol */
var supports = {};
var accepts = [];
Utils.each(minder.getSupportedProtocols(), function(name, protocol) {
if (protocol && protocol.decode) {
supportedExtensions.push(protocol.fileExtension);
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.decode) {
supports[protocol.fileExtension] = protocol;
accepts.push(protocol.fileExtension);
}
});
supportedExtensions = supportedExtensions.join(', ');
function readFile(domfile) {
return new Promise(function(resolve, reject) {
var file = new fio.file.File(domfile.name);
var protocol = minder.getProtocol($loader.support(file));
var reader;
if (protocol.dataType == 'blob') {
file.data = new fio.file.Data(domfile);
resolve(file);
} else {
reader = new FileReader();
reader.onload = function() {
file.data = new fio.file.Data(this.result);
resolve(file);
};
reader.readAsText(domfile, 'utf-8');
}
});
}
/* 网盘面板 */
var $panel = $($open.local.getContentElement()).addClass('local-file-open-panel');
var $panel = $($open.createSub('local')).addClass('local-file-open-panel');
/* 路径导航 */
var $nav = $('<h2>本地文件</h2>')
/* 标题 */
$('<h2>本地文件</h2>')
.appendTo($panel);
/* 选择文件 */
var $pick = $('<div class="pick-file"></div>')
.appendTo($panel);
......@@ -64,19 +40,26 @@ KityMinder.registerUI('menu/open/local', function(minder) {
.appendTo($pick);
$('<span></span>')
.text(minder.getLang('ui.acceptfile', supportedExtensions))
.appendTo($pick);
.text(minder.getLang('ui.acceptfile', accepts.map(function(ext) {
var protocol = supports[ext];
return protocol.fileDescription + '(' + ext + ')';
}).join(', '))).appendTo($pick);
/* 拖放提示 */
var $drop = $('<div class="drop-file"></div>')
.append($('<span></span>').html(minder.getLang('ui.dropfile')))
.appendTo($panel);
/* 交互事件 */
$pickButton.click(function() {
var $file = $('<input type="file" />')
.attr('accept', supportedExtensions)
$('<input type="file" />')
.attr('accept', accepts.join())
.on('change', function(e) {
readFile(this.files[0]).then($loader.load);
$menu.removeClass('show');
read(this.files[0]);
$menu.hide();
}).click();
});
......@@ -85,9 +68,62 @@ KityMinder.registerUI('menu/open/local', function(minder) {
e.stopPropagation();
}).on('drop', function(e) {
e = e.originalEvent;
var file = e.dataTransfer.files[0];
readFile(file).then($loader.load);
$menu.removeClass('show');
read(e.dataTransfer.files[0]);
$menu.hide();
e.preventDefault();
});
function read(domfile) {
if (!domfile) return;
var info = new fio.file.anlysisPath(domfile.name);
var protocol = supports[info.extension];
var dataPromise = new Promise(function(resolve, reject) {
var reader;
if (protocol.dataType == 'blob') {
resolve(new fio.file.Data(domfile));
} else {
reader = new FileReader();
reader.onload = function() {
resolve(new fio.file.Data(this.result));
};
reader.onerror = reject;
reader.readAsText(domfile, 'utf-8');
}
});
$(minder.getRenderTarget()).addClass('loading');
return dataPromise.then(function(data) {
var doc = {
content: data.content,
protocol: protocol.name,
title: info.filename,
source: 'local'
};
return $doc.load(doc);
})['catch'](function(error) {
window.alert(minder.getLang('ui.errorloading', error.message || minder.getLang('ui.unknownreason')));
}).then(function() {
$(minder.getRenderTarget()).removeClass('loading');
});
}
return {
read: read
};
});
\ No newline at end of file
......@@ -11,38 +11,73 @@ KityMinder.registerUI('menu/open/netdisk', function(minder) {
var $menu = minder.getUI('menu/menu');
var $open = minder.getUI('menu/open/open');
var $loader = minder.getUI('widget/fileloader');
var $netdiskfinder = minder.getUI('widget/netdiskfinder');
var $eve = minder.getUI('eve');
var $doc = minder.getUI('doc');
var ret = $eve.setup({});
/* 网盘面板 */
var $panel = $($open.netdisk.getContentElement());
var $panel = $($open.createSub('netdisk'));
/* extension => protocol */
var supports = {};
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.decode) {
supports[protocol.fileExtension] = protocol;
}
});
/* Finder */
var $finder = $netdiskfinder.generate($panel, function(file) {
return $loader.support(file);
return supports[file.extension];
});
$finder.on('fileclick', openFile);
$finder.on('fileclick', function(file) {
return open(file.path);
});
function openFile(file) {
var protocol = $loader.support(file);
function open(path) {
$menu.removeClass('show');
$menu.hide();
$(minder.getRenderTarget()).addClass('loading');
return $loader.load(fio.file.read({
path: file.path,
var info = fio.file.anlysisPath(path);
var protocol = supports[info.extension];
return fio.file.read({
path: path,
dataType: protocol.dataType
})).then(function(readed) {
if (readed) ret.fire('fileload', readed);
}).then(function(file) {
var doc = {
protocol: supports[file.extension].name,
content: file.data.content,
title: file.filename,
source: 'netdisk',
path: file.path,
saved: true
};
return $doc.load(doc);
})['catch'](function(error) {
window.alert(minder.getLang('ui.errorloading', error.message || minder.getLang('unknownreason')));
}).then(function() {
$(minder.getRenderTarget()).removeClass('loading');
});
}
ret.loadFileByPath = function(path) {
var file = new fio.file.File(path);
return openFile(file);
};
ret.open = open;
return ret;
});
\ No newline at end of file
......@@ -6,46 +6,6 @@
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/open/open', function(minder) {
var $level1 = minder.getUI('menu/level1');
var eve = minder.getUI('eve');
var $h2 = $('<h2></h2>')
.text(minder.getLang('ui.menu.open.header'))
.appendTo($level1.open.getContentElement());
var source = ['recent', 'netdisk', 'local', 'draft'];
var $tabs = new FUI.Tabs({
buttons: source.map(function(key) {
return {
label: minder.getLang('ui.menu.open.' + key),
className: key
};
})
}).appendTo($level1.open);
// 暴露
var ret = {};
// 暴露每个面板
source.forEach(function(key, index) {
ret[key] = $tabs.getPanel(index);
});
// 支持事件
eve.setup(ret);
// 暴露打开菜单(选项卡)选择事件
$tabs.on('tabsselect', function(e, info) {
ret.fire('select', info);
});
// 暴露选择事件
ret.select = $tabs.select.bind($tabs);
return ret;
return minder.getUI('menu/menu').createSubMenu('open', true);
});
\ No newline at end of file
......@@ -13,14 +13,24 @@ KityMinder.registerUI('menu/open/recent', function(minder) {
var $open = minder.getUI('menu/open/open');
var $loader = minder.getUI('widget/fileloader');
var frdTime = minder.getUI('widget/friendlytimespan');
var netdisk = minder.getUI('menu/open/netdisk');
var doc = minder.getUI('doc');
var recentList = minder.getUI('widget/locallist').use('recent');
/* 网盘面板 */
var $panel = $($open.recent.getContentElement()).addClass('recent-file-panel');
var $panel = $($open.createSub('recent', true)).addClass('recent-file-panel');
minder.on('uiready', function() {
minder.getUI('topbar/user').requireLogin($panel);
});
/* 路径导航 */
var $nav = $('<h2>最近使用</h2>')
/* 标题 */
var $title = $('<h2></h2>')
.text(minder.getLang('ui.recent'))
.appendTo($panel);
var $clear = $('<button></button>')
.addClass('clear-recent-list')
.text(minder.getLang('ui.clearrecent'))
.appendTo($panel);
/* 最近文件列表容器 */
......@@ -28,10 +38,50 @@ KityMinder.registerUI('menu/open/recent', function(minder) {
.addClass('recent-file-list')
.appendTo($panel);
$ul.delegate('.recent-file-item', 'click', function(e) {
var netdisk = minder.getUI('menu/open/netdisk');
var path = $(e.target)
.closest('.recent-file-item')
.data('path');
netdisk.open(path);
});
$clear.on('click', function() {
if (!window.confirm(minder.getLang('ui.clearrecentconfirm'))) return;
recentList.clear();
renderList();
});
doc.on('docload', addToList);
doc.on('docsave', addToList);
renderList();
function addToList(doc) {
if (doc.source != 'netdisk') return;
var exist = recentList.findIndex('path', doc.path);
if (~exist) {
recentList.remove(exist);
}
recentList.unshift({
path: doc.path,
filename: fio.file.anlysisPath(doc.path).filename,
title: minder.getMinderTitle(),
time: +new Date()
});
renderList();
}
function renderList() {
$ul.empty();
recentList.forEach(function(item) {
var $li = $('<li></li>')
......@@ -51,39 +101,9 @@ KityMinder.registerUI('menu/open/recent', function(minder) {
$('<span></span>')
.addClass('file-time')
.data('time', item.time)
.text(frdTime.display(item.time))
.displayFriendlyTime(item.time)
.appendTo($li);
});
}
$ul.delegate('.recent-file-item', 'click', function(e) {
var path = $(e.target)
.closest('.recent-file-item')
.data('path');
netdisk.loadFileByPath(path);
});
netdisk.on('fileload', function(loaded) {
var exist = recentList.findIndex('path', loaded.file.path);
if (~exist) {
recentList.remove(exist);
}
recentList.unshift({
path: loaded.file.path,
filename: loaded.file.filename,
title: loaded.json.data.text || minder.getLang('untitleddoc'),
time: +new Date()
});
renderList();
});
function updateTime() {
$ul.find('.file-time').each(function(index, element) {
$(element).text(frdTime.display($(element).data('time')));
});
}
setInterval(updateTime, 60000);
});
\ No newline at end of file
/**
* @fileOverview
*
*
* 导出数据到本地
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/save/download', function(minder) {
var $menu = minder.getUI('menu/menu');
var $save = minder.getUI('menu/save/save');
/* 导出面板 */
var $panel = $($save.createSub('download')).addClass('download-panel');
/* 标题 */
var $title = $('<h2></h2>')
.text(minder.getLang('ui.menu.save.download'))
.appendTo($panel);
var $list = $('<ul>')
.addClass('download-list')
.appendTo($panel);
var supports = [];
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.encode) {
supports.push(protocol);
}
});
supports.forEach(function(protocol) {
$('<li>')
.addClass(protocol.name)
.text(protocol.fileDescription + ' (' + protocol.fileExtension + ')')
.data('protocol', protocol)
.appendTo($list);
});
$list.delegate('li', 'click', function(e) {
var protocol = $(e.target).data('protocol');
doExport(protocol);
});
function doExport(protocol) {
var filename = minder.getMinderTitle() + protocol.fileExtension;
var mineType = protocol.mineType || 'text/plain';
$panel.addClass('loading');
minder.exportData(protocol.name).then(function(data) {
if (typeof(data) != 'string') return;
switch (protocol.dataType) {
case 'text':
return doDownload(buildDataUrl(mineType), filename, 'text');
case 'base64':
return doDownload(data, filename, 'base64');
}
return null;
}).then(function() {
$panel.removeClass('loading');
$menu.hide();
});
}
function doDownload(url, filename, type) {
var content = url.split(',')[1];
var $form = $('<form></form>').attr({
'action': 'download.php',
'method': 'POST',
'accept-charset': 'utf-8'
});
var $content = $('<input />').attr({
name: 'content',
type: 'hidden',
value: decodeURIComponent(content)
}).appendTo($form);
var $type = $('<input />').attr({
name: 'type',
type: 'hidden',
value: type
}).appendTo($form);
var $filename = $('<input />').attr({
name: 'filename',
type: 'hidden',
value: filename
}).appendTo($form);
$('<input name="iehack" value="&#9760;" />').appendTo($form);
$form.appendTo('body').submit().remove();
}
function buildDataUrl(mineType, data) {
return 'data:' + mineType + '; utf-8,' + encodeURIComponent(data);
}
});
\ No newline at end of file
......@@ -11,19 +11,23 @@ KityMinder.registerUI('menu/save/netdisk', function(minder) {
var $save = minder.getUI('menu/save/save');
var $netdiskfinder = minder.getUI('widget/netdiskfinder');
var $eve = minder.getUI('eve');
var $doc = minder.getUI('doc');
var ret = $eve.setup({});
var protocols = minder.getSupportedProtocols().filter(function(protocol) {
return protocol.encode;
/* extension => protocol */
var supports = {};
minder.getSupportedProtocols().forEach(function(protocol) {
if (protocol.encode && protocol.decode) {
supports[protocol.fileExtension] = protocol;
}
});
/* 网盘面板 */
var $panel = $($save.netdisk.getContentElement()).addClass('netdisk-save-panel');
var $panel = $($save.createSub('netdisk', true)).addClass('netdisk-save-panel');
var $finder = $netdiskfinder.generate($panel, function(file) {
return protocols.some(function(protocol) {
return protocol.fileExtension == file.extension;
}, false);
return supports[file.extension];
});
var $selects = $('<div class="netdisk-save-select"></div>')
......@@ -33,28 +37,133 @@ KityMinder.registerUI('menu/save/netdisk', function(minder) {
.text(minder.getLang('ui.saveas'))
.appendTo($selects);
/* 文件名 */
var $filename = $('<input>')
.attr('type', 'text')
.attr('placeholder', minder.getLang('ui.filename'))
.attr('title', minder.getLang('ui.filename'))
.on('keydown', function(e) {
if (e.keyCode == 27) $menu.toggleClass('show');
})
.appendTo($selects);
/* 文件格式 */
var $format = $('<select>')
.attr('title', minder.getLang('ui.fileformat'))
.appendTo($selects);
protocols.forEach(function(protocol) {
for (var ext in supports) {
var protocol = supports[ext];
if (!protocol.encode) return;
$('<option>')
.text(protocol.fileDescription + '(' + protocol.fileExtension + ')')
.val(protocol.name)
.val(ext)
.appendTo($format);
});
}
$format.val('json');
$format.val('.km');
/* 保存按钮 */
var $saveBtn = $('<button></button>')
.addClass('save-button')
.text(minder.getLang('ui.save'))
.click(save)
.appendTo($selects);
$menu.on('show', setFileName);
$finder.on('fileclick', function(file) {
$finder.select(file.path);
$filename.val(file.filename);
});
function save() {
var filename = $filename.val();
if (fio.file.anlysisPath(filename).extension != $format.val()) {
$filename.val(filename += $format.val())[0].select();
}
var path = $finder.pwd() + filename;
var doc = $doc.current();
var protocol = supports[$format.val()];
var exist = $finder.select(path); // 目标路径存在
var match = doc.path == path; // 目标路径正是当前文档
var duplicated = exist && !match;
if (!exist || match || duplicated && window.confirm(minder.getLang('ui.overrideconfirm', filename))) {
doSave(path, protocol, doc);
}
}
function doSave(path, protocol, doc) {
$panel.addClass('loading');
return minder.exportData(protocol.name).then(function(data) {
return fio.file.write({
path: path,
content: data,
ondup: fio.file.DUP_OVERWRITE
});
}).then(function() {
$panel.removeClass('loading');
$menu.hide();
doc.path = path;
doc.title = $filename.val();
doc.source = 'netdisk';
$doc.save(doc);
setTimeout($finder.list, 500);
})['catch'](function(e) {
window.alert('保存文件失败:' + (e.message || minder.getLang('ui.unknownreason')));
});
}
function setFileName() {
var doc = $doc.current();
switch (doc.source) {
case 'netdisk':
setFileNameForNetDiskSource(doc);
break;
default:
setFileNameForOtherSource(doc);
break;
}
$filename[0].select();
}
function setFileNameForNetDiskSource(doc) {
var path = doc.path;
var pathInfo = fio.file.anlysisPath(path);
// 选中当前文件
if ($finder.pwd() != pathInfo.parentPath) {
$finder.list(pathInfo.parentPath).then(function() {
$finder.select(path);
});
} else {
$finder.select(path);
}
$filename.val(pathInfo.filename);
}
function setFileNameForOtherSource(doc) {
$filename.val(doc.title);
$finder.select(null);
}
return ret;
});
\ No newline at end of file
......@@ -8,41 +8,5 @@
*/
KityMinder.registerUI('menu/save/save', function(minder) {
var $level1 = minder.getUI('menu/level1');
var eve = minder.getUI('eve');
var $h2 = $('<h2></h2>')
.text(minder.getLang('ui.menu.save.header'))
.appendTo($level1.save.getContentElement());
var source = ['netdisk', 'local'];
var $tabs = new FUI.Tabs({
buttons: source.map(function(key) {
return {
label: minder.getLang('ui.menu.save.' + key),
className: key
};
})
}).appendTo($level1.save);
// 暴露
var ret = eve.setup({});
// 暴露每个面板
source.forEach(function(key, index) {
ret[key] = $tabs.getPanel(index);
});
// 暴露保存菜单(选项卡)选择事件
$tabs.on('tabsselect', function(e, info) {
ret.fire('select', info);
});
// 暴露选择事件
ret.select = $tabs.select.bind($tabs);
return ret;
return minder.getUI('menu/menu').createSubMenu('save');
});
\ No newline at end of file
<form id="share-select">
<div id="shared-tip"></div>
<fieldset id="no-share">
<legend>
<label>
<input name="sharetype" type="radio" value="none" checked />
$lang.none_share
</label>
</legend>
<div class="share-description">
$lang.none_share_description
</div>
</fieldset>
<fieldset id="public-share">
<legend>
<label>
<input name="sharetype" type="radio" value="public"/>
$lang.public_share
</label>
</legend>
<div class="share-description">$lang.public_share_description</div>
<div class="share-body">
<h3>$lang.url_share</h3>
<p>
<input id="share-url" type="url" value="http://naotu.baidu.com/?shareId=kcev3dd" />
<button id="copy-share-url" data-clipboard-target="share-url" type="button">$lang.copy</button>
</p>
<h3>$lang.sns_share</h3>
<p id="share-platform" class="bdsharebuttonbox">
<a href="#" class="bds_tsina" data-cmd="tsina" title="分享到新浪微博"></a>
<a href="#" class="bds_qzone" data-cmd="qzone" title="分享到QQ空间"></a>
<a href="#" class="bds_tqq" data-cmd="tqq" title="分享到腾讯微博"></a>
<a href="#" class="bds_renren" data-cmd="renren" title="分享到人人网"></a>
<a href="#" class="bds_weixin" data-cmd="weixin" title="分享到微信"></a>
</p>
</div>
</fieldset>
<fieldset id="password-share" disabled>
<legend>
<label>
<input name="sharetype" type="radio" value="password" disabled />
$lang.password_share
</label>
</legend>
<div class="share-description">$lang.password_share_description</div>
<div class="share-body">$lang.ondev</div>
</fieldset>
<fieldset id="email-share" disabled>
<legend>
<label>
<input name="sharetype" type="radio" value="email" disabled />
$lang.email_share
</label>
</legend>
<div class="share-description">$lang.email_share_description</div>
<div class="share-body">$lang.ondev</div>
</fieldset>
</form>
\ No newline at end of file
/**
* @fileOverview
*
*
* 分享功能交互
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/share/share', function(minder) {
var $share_menu = minder.getUI('menu/menu').createSubMenu('share', true);
var $create_menu = $($share_menu.createSub('createshare', true));
var $manage_menu = $($share_menu.createSub('manageshare'));
var $doc = minder.getUI('doc');
var BACKEND_URL = 'http://127.0.0.1/naotu/mongo.php';
var currentShare = null;
var shareList = [];
var panelReady = renderCreatePanel();
panelReady.then(bindCreatePanelEvent);
fio.user.on('login', loadShareList);
fio.user.on('logout', clearShareList);
function renderCreatePanel() {
// render template
return $.pajax('ui/menu/share/create.html').then(function(html) {
/* global jhtmls: true */
var render = jhtmls.render(html);
$create_menu.html(render({
lang: minder.getLang('ui'),
minder: minder
}));
zeroCopy();
return $create_menu;
});
}
function bindCreatePanelEvent($panel) {
$panel.delegate('input[name=sharetype]', 'click', function(e) {
var actions = {
'none': removeShare,
'public': createPublicShare
};
actions[e.target.value]();
});
}
function removeShare() {
if (!currentShare) return;
if (currentShare) {
return $.pajax({
});
}
}
function uuid() {
var timeLead = 1e9;
return ((+new Date() * timeLead) + (Math.random() * --timeLead)).toString(36);
}
function createPublicShare(user) {
if (currentShare) return;
$create_menu.addClass('loading');
return fio.user.check().then(function(user) {
var record = {
shareMinder: {
id: uuid(),
data: JSON.stringify(minder.exportJson())
}
};
var currentDoc = $doc.current();
if (currentDoc.source == 'netdisk') {
record.path = currentDoc.path;
}
return $.pajax(BACKEND_URL, {
type: 'POST',
data: {
action: 'insert',
record: JSON.stringify(record),
ak: user && user.access_token
},
dataType: 'json'
}).then(function(result) {
if (result.error) {
throw new Error(result.error);
}
return result;
})['catch'](function(e) {
window.alert(minder.getLang('create_share_failed', e.message));
});
})
.then(function(shared) {
if (shared) {
currentShare = shared;
renderPublicShare(shared);
}
$create_menu.removeClass('loading');
});
}
function renderPublicShare(shared) {
var $sbody = $('#public-share .share-body', $create_menu);
var baseUrl = /^(.*?)(\?|\#|$)/.exec(window.location.href)[1];
var shareUrl = baseUrl + '?shareId=' + shared.shareMinder.id;
$('#share-url', $sbody).val(shareUrl)[0].select();
var shareConfig = window._bd_share_config.common,
resetShare = window._bd_share_main.init;
if (shareConfig && resetShare) {
shareConfig.bdTitle = shareConfig.bdText = minder.getMinderTitle();
shareConfig.bdDesc = shareConfig.bdText = minder.getLang('ui.sns_share_text', minder.getMinderTitle(), shareUrl);
shareConfig.bdUrl = shareUrl;
resetShare();
}
$sbody.show();
}
function loadShareList() {
var user = fio.user.current();
return $.pajax(BACKEND_URL, {
});
}
function clearShareList() {
shareList = [];
}
function shareRedirect() {
var pattern = /(?:shareId|share_id)=(\w+)([&#]|$)/;
var match = pattern.exec(window.location) || pattern.exec(document.referrer);
if (match) {
window.location.href = 'viewshare.html?shareId=' + match[1];
}
}
function zeroCopy() {
/* global ZeroClipboard:true */
ZeroClipboard.setDefaults({ moviePath: 'lib/ZeroClipboard.swf' });
var $copy_url_btn = $('#copy-share-url', $create_menu);
if (window.ZeroClipboard) {
var clip = new window.ZeroClipboard($copy_url_btn, {
hoverClass: 'hover',
activeClass: 'active'
});
clip.on('dataRequested', function(client, args) {
$copy_url_btn.text(minder.getLang('ui.copied')).attr('disabled', 'disabled');
setTimeout(function() {
$copy_url_btn
.text(minder.getLang('ui.copy'))
.removeAttr('disabled');
}, 3000);
});
}
}
return $share_menu;
});
\ No newline at end of file
/**
* @fileOverview
*
* 查看分享文件
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KityMinder.registerUI('menu/share/view', function (minder) {
var $doc = minder.getUI('doc');
var $save = minder.getUI('menu/save');
var $download = minder.getUI('download');
function loadShareDoc(results) {
var user = results[0],
$panel = results[1];
var pattern = /(?:shareId|share_id)=(\w+)([&#]|$)/;
var match = pattern.exec(window.location) || pattern.exec(document.referrer);
if (!match) return Promise.resolve(null);
var shareId = match[1];
function renderShareData(data) {
if (data.error) {
return window.alert(data.error);
}
var content = data.shareMinder.data;
return $doc.load({
source: 'share',
content: content,
protocol: 'json',
saved: false,
ownerId: data.uid,
ownerName: data.uname
}).then(function(doc) {
if (user) {
if (doc.ownerId == user.id) {
}
}
// 分享着不是当前用户
if (doc.ownerId && doc.ownerId != (user && user.id)) {
$('#shared-tip', $panel).text(minder.getLang('ui.shared_tip', doc.ownerName));
}
});
}
return $.pajax({
url: 'http://127.0.0.1/naotu/mongo.php', //'http://naotu.baidu.com/mongo.php',
data: {
action: 'find',
id: shareId
},
dataType: 'json'
}).then(renderShareData)['catch'](function(e) {
window.alert('请求分享文件失败,请重试!');
}).then(function() {
$(minder.getRenderTarget()).removeClass('loading');
});
}
});
\ No newline at end of file
.download-panel {
h2 {
&:before {
content: ' ';
display: block;
width: 25px;
height: 25px;
position: absolute;
left: 0;
background: url(../images/icons.png) no-repeat 0 -595px;
}
}
& > .download-list {
margin: 0;
padding: 0;
list-style: none;
li {
font-size: 14px;
line-height: 20px;
padding: 10px 20px 10px 40px;
cursor: default;
position: relative;
margin: 0;
font-weight: normal;
height: 20px;
line-height: 20px;
&:hover {
background-color: lighten(@tab-hover, 55%);
}
&:active {
background-color: lighten(@tab-hover, 50%);
}
}
}
}
\ No newline at end of file
.draft-panel {
h2 {
&:before {
content: ' ';
display: block;
width: 25px;
height: 25px;
position: absolute;
left: 0;
background: url(../images/icons.png) no-repeat 0 -570px;
}
}
& > .clear-draft {
position: absolute;
right: 0;
top: 0;
}
& > .draft-list {
margin: 0;
padding: 0;
list-style: none;
&:empty:after {
content: '这是个空虚寂寞的草稿箱!';
display: block;
text-align: center;
font-size: 18px;
height: 50px;
line-height: 50px;
color: #CCC;
}
.draft-list-item {
font-size: 14px;
line-height: 20px;
padding: 10px 20px 10px 40px;
cursor: default;
position: relative;
&:hover {
background-color: lighten(@tab-hover, 55%);
}
&:active {
background-color: lighten(@tab-hover, 50%);
}
.draft-title {
margin: 0;
font-weight: normal;
height: 20px;
line-height: 20px;
&:after {
content: ' ';
display: block;
position: absolute;
width: 25px;
height: 25px;
background: url(../images/icons.png) no-repeat 0 -445px;
left: 5px;
top: 10px;
}
}
.file-time {
position: absolute;
right: 5px;
top: 10px;
font-size: 12px;
color: #999;
}
}
}
}
\ No newline at end of file
......@@ -25,53 +25,6 @@ html, body {
#kityminder {
.dock(@panel-height, 0, 0, 0);
-moz-user-select: none;
&.loading {
svg {
.blur;
}
&:after {
content: ' ';
display: block;
.dock;
background: rgba(128, 130, 140, .75);
}
&:before {
content: ' ';
width: 40px;
height: 40px;
border: 4px solid;
border-color: #fff transparent transparent;
box-shadow: 0 0 35px white;
position: absolute;
left: 50%;
top: 50%;
margin-left: -24px;
margin-top: -24px;
z-index: 10;
border-radius: 100%;
-webkit-animation: rotate 1.33s ease infinite;
}
}
}
@-webkit-keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
@-moz-keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
@-ms-keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
@keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
#panel {
......
......@@ -18,6 +18,9 @@
.button;
margin: 0 10px 10px 0;
}
span {
line-height: 30px;
}
}
.drop-file {
border: 2px dashed #eee;
......
......@@ -38,27 +38,28 @@
#main-menu {
@left-width: 200px;
background: white;
.dock;
overflow: hidden;
transform: scale(0);
transform: translate3d(0, -100%, 0);
transform-origin: 0 0;
opacity: 0;
transition: opacity .25s ease, transform .25s ease;
transition: opacity .2s ease, transform .2s ease;
z-index: 100;
&.show {
opacity: 1;
transform: scale(1);
transform: translate3d(0, 0, 0);
}
.slide-in() {
transform: translateX(-(@left-width)) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
.show& {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
}
......@@ -89,26 +90,36 @@
.main-menu-back-button {
.fui-label {
display: inline-block;
color: white;
margin-left: 10px;
font-size: 14px;
display: none;
}
.fui-icon {
display: block;
width: 25px;
height: 25px;
background: url(../images/icons.png) -1px -370px;
}
display: inline-block;
width: 25px;
height: 25px;
line-height: 25px;
border-radius: 100%;
border: 2px solid white;
left: 5px;
top: 5px;
cursor: pointer;
background: url(../images/icons.png) -1px -370px;
vertical-align: middle;
}
width: @left-width - 10px;
height: @panel-height - 10px;
padding: 5px;
&:hover {
background-color: rgba(255,255,255,.3);
background: -moz-linear-gradient(left, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, right top, color-stop(0%,rgba(255,255,255,0.3)), color-stop(100%,rgba(255,255,255,0))); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(left, rgba(255,255,255,0.3) 0%,rgba(255,255,255,0) 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(left, rgba(255,255,255,0.3) 0%,rgba(255,255,255,0) 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(left, rgba(255,255,255,0.3) 0%,rgba(255,255,255,0) 100%); /* IE10+ */
background: linear-gradient(to right, rgba(255,255,255,0.3) 0%,rgba(255,255,255,0) 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#4dffffff', endColorstr='#00ffffff',GradientType=1 ); /* IE6-9 */
}
&:active {
background-color: rgba(0,0,0,.05);
background: darken(@main-menu-theme-color, 10%);
}
}
}
......@@ -125,7 +136,7 @@
color: #999;
.slide-in;
}
&level-1 {
&level1 {
position: absolute;
left: 0;
right: 0;
......
......@@ -80,6 +80,13 @@
&:active {
background-color: lighten(@tab-hover, 50%);
}
&.selected {
background-color: lighten(@tab-active, 20%);
color: white;
&.file:before {
background-position: 0 -545px;
}
}
&.file {
position: relative;
&:before {
......@@ -127,41 +134,15 @@
top: 0;
}
.login-tip {
display: none;
text-align: center;
font-size: 16px;
color: #999;
margin-top: 30px;
a {
text-decoration: underline;
color: @main-menu-theme-color;
cursor: pointer;
&:hover {
color: lighten(@main-menu-theme-color, 10%);
}
}
}
&.require-login {
.login-tip {
display: block;
}
.netdisk-nav, .netdisk-file-list {
display: none;
}
}
}
// for save
.netdisk-save-panel .netdisk-file-list {
bottom: 60px;
bottom: 50px;
}
.netdisk-save-select {
.dock(auto, 0, 0, 0);
height: 30px;
height: auto;
padding: 10px;
border-top: 1px solid #EEE;
background: #fcfcfc;
......@@ -174,29 +155,22 @@
}
& > input {
width: 50%;
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid lighten(@tab-hover, 30%);
margin: 0;
margin-top: 5px;
margin-right: 10px;
&:focus {
border-color: lighten(@tab-active, 40%);
}
vertical-align: middle;
}
& > select {
margin: 5px 0 0 10px;
margin: 5px 0 0 0;
outline: none;
vertical-align: middle;
}
& > .save-button {
position: absolute;
right: 10px;
top: 10px;
float: right;
width: 80px;
vertical-align: middle;
}
}
\ No newline at end of file
......@@ -30,3 +30,102 @@
bottom: @bottom;
left: @left;
}
.validate-error {
color: red;
border-color: red !important;
}
.button, button {
display: inline-block;
height: 30px;
padding: 0 15px;
line-height: 30px;
text-align: center;
outline: none;
background: lighten(@tab-active, 20%);
&:hover, &.hover {
background: lighten(@tab-hover, 20%);
}
&:active, &.active {
background: lighten(@tab-active, 15%);
}
&:disabled {
background: #CCC;
&:hover, &.hover,
&:active, &.active {
background: #CCC;
}
}
cursor: default;
color: @ui-fore;
border: none;
}
input[type=text],
input[type=url] {
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid lighten(@tab-hover, 50%);
box-shadow: inset 0 1px 3px rgba(0,0,0,.05);
border-radius: 2px;
&:focus {
border-color: hsl(223, 38%, 55%);
}
}
.loading(@color: rgb(128, 130, 140), @border-color: #fff) {
.loading-target {
.blur;
}
&:after {
content: ' ';
display: block;
.dock;
background: fadeOut(@color, 25%);
}
&:before {
content: ' ';
width: 40px;
height: 40px;
border: 4px solid;
border-color: @border-color transparent transparent;
box-shadow: 0 0 35px white;
position: absolute;
left: 50%;
top: 50%;
margin-left: -24px;
margin-top: -24px;
z-index: 10;
border-radius: 100%;
-webkit-animation: rotate 1.33s ease infinite;
filter: none;
-webkit-filter: none;
}
}
.loading {
.loading();
}
@-webkit-keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
@-moz-keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
@-ms-keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
@keyframes rotate {
from { transform: rotate(0); }
to { transform: rotate(360deg); }
}
\ No newline at end of file
......@@ -12,11 +12,27 @@
}
}
& > .clear-recent-list {
position: absolute;
right: 0;
top: 0;
}
& > .recent-file-list {
margin: 0;
padding: 0;
list-style: none;
&:empty:after {
content: '没有最近打开文件!';
display: block;
text-align: center;
font-size: 18px;
height: 50px;
line-height: 50px;
color: #CCC;
}
.recent-file-item {
font-size: 14px;
line-height: 20px;
......
#share-dialog {
#share-select {
fieldset {
border: 1px solid #f0f0f0;
margin: 0;
margin-bottom: 10px;
padding: 10px;
legend {
font-size: 14px;
}
&:disabled {
opacity: 0.5;
}
.share-description {
}
.share-body {
margin-top: 10px;
}
}
}
#public-share {
p {
position: relative;
max-width: 500px;
input {
width: 100%;
box-sizing: border-box;
height: 24px;
margin: 0;
}
#copy-share-url {
position: absolute;
right: 0;
top: 0;
margin: 0;
height: 24px;
line-height: 24px;
border-radius: 2px;
}
}
.share-body {
display: none;
}
}
\ No newline at end of file
......@@ -2,6 +2,9 @@
float: right;
height: @panel-height;
line-height: @panel-height;
font-size: 14px;
color: @ui-fore;
vertical-align: baseline;
.fui-button {
......@@ -42,3 +45,28 @@
}
}
}
.login-tip {
display: none;
}
.login-required {
& > * {
display: none;
}
& > .login-tip {
display: block;
text-align: center;
font-size: 16px;
color: #999;
margin-top: 30px;
a {
text-decoration: underline;
color: @main-menu-theme-color;
cursor: pointer;
&:hover {
color: lighten(@main-menu-theme-color, 10%);
}
}
}
}
\ No newline at end of file
......@@ -2,6 +2,11 @@
.transition(background-color .2s ease);
}
.fui-disabled,
.fui-disabled .fui-widget {
background-color: transparent !important;
}
#tab-container .fui-button {
display: inline-block;
padding: 2px 5px 2px 3px;
......@@ -150,9 +155,13 @@
height: 50px;
display: inline-block;
margin-top: 5px;
&:hover {
border-color: @button-hover;
}
&.fui-disabled:hover {
border-color: transparent;
}
.fui-button:first-child {
display: block;
......@@ -298,34 +307,3 @@
}
}
}
.validate-error {
color: red;
border-color: red !important;
}
.button, button {
display: inline-block;
height: 30px;
padding: 0 15px;
line-height: 30px;
text-align: center;
outline: none;
background: lighten(@tab-active, 20%);
&:hover {
background: lighten(@tab-hover, 20%);
}
&:active {
background: lighten(@tab-active, 15%);
}
cursor: default;
color: @ui-fore;
border: none;
}
input[type=text] {
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid lighten(@tab-hover, 30%);
}
\ No newline at end of file
......@@ -543,6 +543,130 @@
filter: blur(5px);
filter: url(../images/blur.svg#blur);
}
.validate-error {
color: red;
border-color: red !important;
}
.button,
button {
display: inline-block;
height: 30px;
padding: 0 15px;
line-height: 30px;
text-align: center;
outline: none;
background: #717b94;
cursor: default;
color: #ffffff;
border: none;
}
.button:hover,
button:hover,
.button.hover,
button.hover {
background: #8e96aa;
}
.button:active,
button:active,
.button.active,
button.active {
background: #656f87;
}
.button:disabled,
button:disabled {
background: #CCC;
}
.button:disabled:hover,
button:disabled:hover,
.button:disabled.hover,
button:disabled.hover,
.button:disabled:active,
button:disabled:active,
.button:disabled.active,
button:disabled.active {
background: #CCC;
}
input[type=text],
input[type=url] {
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid #e5e7ec;
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
border-radius: 2px;
}
input[type=text]:focus,
input[type=url]:focus {
border-color: #6179b8;
}
.loading .loading-target {
-webkit-filter: blur(5px);
-moz-filter: blur(5px);
-mz-filter: blur(5px);
-o-filter: blur(5px);
filter: blur(5px);
filter: url(../images/blur.svg#blur);
}
.loading:after {
content: ' ';
display: block;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
background: rgba(128, 130, 140, 0.75);
}
.loading:before {
content: ' ';
width: 40px;
height: 40px;
border: 4px solid;
border-color: #ffffff transparent transparent;
box-shadow: 0 0 35px white;
position: absolute;
left: 50%;
top: 50%;
margin-left: -24px;
margin-top: -24px;
z-index: 10;
border-radius: 100%;
-webkit-animation: rotate 1.33s ease infinite;
filter: none;
-webkit-filter: none;
}
@-webkit-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-moz-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-ms-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
.triangle {
content: ' ';
display: block;
......@@ -561,6 +685,10 @@
-o-transition: background-color 0.2s ease;
transition: background-color 0.2s ease;
}
.fui-disabled,
.fui-disabled .fui-widget {
background-color: transparent !important;
}
#tab-container .fui-button {
display: inline-block;
padding: 2px 5px 2px 3px;
......@@ -725,6 +853,9 @@
#tab-container .fui-button-menu:hover {
border-color: #eff3fa;
}
#tab-container .fui-button-menu.fui-disabled:hover {
border-color: transparent;
}
#tab-container .fui-button-menu .fui-button:first-child {
display: block;
width: 40px;
......@@ -867,37 +998,6 @@
line-height: 30px;
height: 30px;
}
.validate-error {
color: red;
border-color: red !important;
}
.button,
button {
display: inline-block;
height: 30px;
padding: 0 15px;
line-height: 30px;
text-align: center;
outline: none;
background: #717b94;
cursor: default;
color: #ffffff;
border: none;
}
.button:hover,
button:hover {
background: #8e96aa;
}
.button:active,
button:active {
background: #656f87;
}
input[type=text] {
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid #abb1c0;
}
/**
* 基本页面样式
*/
......@@ -933,72 +1033,6 @@ body {
left: 0;
-moz-user-select: none;
}
#kityminder.loading svg {
-webkit-filter: blur(5px);
-moz-filter: blur(5px);
-mz-filter: blur(5px);
-o-filter: blur(5px);
filter: blur(5px);
filter: url(../images/blur.svg#blur);
}
#kityminder.loading:after {
content: ' ';
display: block;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
background: rgba(128, 130, 140, 0.75);
}
#kityminder.loading:before {
content: ' ';
width: 40px;
height: 40px;
border: 4px solid;
border-color: #fff transparent transparent;
box-shadow: 0 0 35px white;
position: absolute;
left: 50%;
top: 50%;
margin-left: -24px;
margin-top: -24px;
z-index: 10;
border-radius: 100%;
-webkit-animation: rotate 1.33s ease infinite;
}
@-webkit-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-moz-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@-ms-keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
@keyframes rotate {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}
#panel {
background: #393f4f;
font-family: 'Hiragino Sans GB', 'Arial', 'Microsoft Yahei';
......@@ -1053,21 +1087,22 @@ body {
top: 16px;
}
#main-menu {
background: white;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
overflow: hidden;
transform: scale(0);
transform: translate3d(0, -100%, 0);
transform-origin: 0 0;
opacity: 0;
transition: opacity .25s ease, transform .25s ease;
transition: opacity .2s ease, transform .2s ease;
z-index: 100;
}
#main-menu.show {
opacity: 1;
transform: scale(1);
transform: translate3d(0, 0, 0);
}
#main-menu:before {
content: ' ';
......@@ -1080,11 +1115,11 @@ body {
box-shadow: 0 -3px 8px rgba(0, 0, 0, 0.15);
z-index: 1;
transform: translateX(-200px) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
.show#main-menu:before {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
#main-menu .main-menu-header {
background: white;
......@@ -1097,28 +1132,45 @@ body {
height: 40px;
}
#main-menu .main-menu-back-panel .main-menu-back-button {
width: 25px;
height: 25px;
border-radius: 100%;
border: 2px solid white;
left: 5px;
top: 5px;
cursor: pointer;
width: 190px;
height: 30px;
padding: 5px;
}
#main-menu .main-menu-back-panel .main-menu-back-button .fui-label {
display: inline-block;
color: white;
margin-left: 10px;
font-size: 14px;
display: none;
}
#main-menu .main-menu-back-panel .main-menu-back-button .fui-icon {
display: block;
display: inline-block;
width: 25px;
height: 25px;
line-height: 25px;
border-radius: 100%;
border: 2px solid white;
background: url(../images/icons.png) -1px -370px;
vertical-align: middle;
}
#main-menu .main-menu-back-panel .main-menu-back-button:hover {
background-color: rgba(255, 255, 255, 0.3);
background: -moz-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* FF3.6+ */
background: -webkit-gradient(linear, left top, right top, color-stop(0%, rgba(255, 255, 255, 0.3)), color-stop(100%, rgba(255, 255, 255, 0)));
/* Chrome,Safari4+ */
background: -webkit-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* Opera 11.10+ */
background: -ms-linear-gradient(left, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* IE10+ */
background: linear-gradient(to right, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 100%);
/* W3C */
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#4dffffff', endColorstr='#00ffffff', GradientType=1);
/* IE6-9 */
}
#main-menu .main-menu-back-panel .main-menu-back-button:active {
background-color: rgba(0, 0, 0, 0.05);
background: #fb5151;
}
#main-menu .main-menu-title {
margin-left: 200px;
......@@ -1132,23 +1184,23 @@ body {
line-height: 40px;
color: #999;
transform: translateX(-200px) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
.show#main-menu .main-menu-title {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
#main-menu .main-menu-level-1 {
#main-menu .main-menu-level1 {
position: absolute;
left: 0;
right: 0;
bottom: 0;
top: 40px;
}
#main-menu .main-menu-level-1 > .fui-tabs- {
#main-menu .main-menu-level1 > .fui-tabs- {
/* 二级菜单区域 */
}
#main-menu .main-menu-level-1 > .fui-tabs-button-wrap {
#main-menu .main-menu-level1 > .fui-tabs-button-wrap {
top: 0;
right: auto;
bottom: 0;
......@@ -1157,28 +1209,28 @@ body {
position: absolute;
background-color: #fc8383;
}
#main-menu .main-menu-level-1 > .fui-tabs-button-wrap .fui-button {
#main-menu .main-menu-level1 > .fui-tabs-button-wrap .fui-button {
display: block;
text-align: right;
height: 50px;
}
#main-menu .main-menu-level-1 > .fui-tabs-button-wrap .fui-button .fui-label {
#main-menu .main-menu-level1 > .fui-tabs-button-wrap .fui-button .fui-label {
height: 50px;
line-height: 50px;
color: white;
padding-right: 20px;
font-size: 16px;
}
#main-menu .main-menu-level-1 > .fui-tabs-button-wrap .fui-button:hover {
#main-menu .main-menu-level1 > .fui-tabs-button-wrap .fui-button:hover {
background: #fb6a6a;
}
#main-menu .main-menu-level-1 > .fui-tabs-button-wrap .fui-button:active {
#main-menu .main-menu-level1 > .fui-tabs-button-wrap .fui-button:active {
background: #fb5151;
}
#main-menu .main-menu-level-1 > .fui-tabs-button-wrap .fui-button.fui-selected {
#main-menu .main-menu-level1 > .fui-tabs-button-wrap .fui-button.fui-selected {
background: #fdb4b4;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap {
position: absolute;
top: 0;
right: 0;
......@@ -1187,14 +1239,14 @@ body {
background-color: white;
z-index: 2;
transform: translateX(-200px) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
/* 每个二级菜单的面板 */
}
.show#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap {
.show#main-menu .main-menu-level1 > .fui-tabs-panel-wrap {
transform: translateX(0) translateZ(0);
transition: transform .5s ease;
transition: transform .7s ease, opacity .5s ease;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel {
position: absolute;
top: 0;
right: 40px;
......@@ -1202,7 +1254,7 @@ body {
left: 40px;
/* 面板内容 */
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content {
position: absolute;
top: 0;
right: 0;
......@@ -1211,14 +1263,14 @@ body {
/* 二级菜单大标题 */
/* 二级菜单导航 */
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > h2 {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > h2 {
font-size: 24px;
font-weight: normal;
margin-top: 0;
margin-bottom: 20px;
color: #465468;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs {
position: absolute;
top: 0;
right: 0;
......@@ -1227,7 +1279,7 @@ body {
/* 二级导航菜单区域 */
/* 二级菜单内容区域 */
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap {
position: absolute;
top: 60px;
right: auto;
......@@ -1237,35 +1289,35 @@ body {
width: 180px;
border-right: 1px solid #c8ccd6;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button {
display: block;
height: 50px;
line-height: 50px;
text-align: right;
padding-right: 20px;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button > .fui-label {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button > .fui-label {
font-size: 14px;
line-height: 50px;
color: #465468;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button:hover {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button:hover {
background-color: #c8ccd6;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button.fui-selected {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button.fui-selected {
background-color: #717b94;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button.fui-selected > .fui-label {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-button-wrap > .fui-button.fui-selected > .fui-label {
color: white;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap {
position: absolute;
top: 60px;
right: 0;
bottom: 30px;
left: 200px;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap > .fui-panel {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap > .fui-panel {
display: block;
position: absolute;
top: 0;
......@@ -1273,7 +1325,7 @@ body {
bottom: 0;
left: 0;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content {
position: absolute;
top: 0;
right: 0;
......@@ -1281,7 +1333,7 @@ body {
left: 0;
display: block;
}
#main-menu .main-menu-level-1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content h2 {
#main-menu .main-menu-level1 > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content > .fui-tabs > .fui-tabs-panel-wrap > .fui-panel > .fui-panel-content h2 {
padding-bottom: 10px;
height: 30px;
line-height: 30px;
......@@ -1548,6 +1600,9 @@ body {
float: right;
height: 40px;
line-height: 40px;
font-size: 14px;
color: #ffffff;
vertical-align: baseline;
}
#panel div.user-panel .fui-button {
padding: 5px 10px;
......@@ -1583,6 +1638,27 @@ body {
vertical-align: baseline;
background: url(../images/icons.png) 0 -320px;
}
.login-tip {
display: none;
}
.login-required > * {
display: none;
}
.login-required > .login-tip {
display: block;
text-align: center;
font-size: 16px;
color: #999;
margin-top: 30px;
}
.login-required > .login-tip a {
text-decoration: underline;
color: #fc8383;
cursor: pointer;
}
.login-required > .login-tip a:hover {
color: #fdb4b4;
}
.recent-file-panel h2:before {
content: ' ';
display: block;
......@@ -1593,11 +1669,25 @@ body {
top: 2px;
background: url(../images/icons.png) no-repeat 0 -520px;
}
.recent-file-panel > .clear-recent-list {
position: absolute;
right: 0;
top: 0;
}
.recent-file-panel > .recent-file-list {
margin: 0;
padding: 0;
list-style: none;
}
.recent-file-panel > .recent-file-list:empty:after {
content: '没有最近打开文件!';
display: block;
text-align: center;
font-size: 18px;
height: 50px;
line-height: 50px;
color: #CCC;
}
.recent-file-panel > .recent-file-list .recent-file-item {
font-size: 14px;
line-height: 20px;
......@@ -1727,6 +1817,13 @@ body {
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item:active {
background-color: #e5e7ec;
}
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item.selected {
background-color: #717b94;
color: white;
}
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item.selected.file:before {
background-position: 0 -545px;
}
.netdisk-finder-container .netdisk-file-list .netdisk-file-list-item.file {
position: relative;
}
......@@ -1780,30 +1877,8 @@ body {
right: 0;
top: 0;
}
.netdisk-finder-container .login-tip {
display: none;
text-align: center;
font-size: 16px;
color: #999;
margin-top: 30px;
}
.netdisk-finder-container .login-tip a {
text-decoration: underline;
color: #fc8383;
cursor: pointer;
}
.netdisk-finder-container .login-tip a:hover {
color: #fdb4b4;
}
.netdisk-finder-container.require-login .login-tip {
display: block;
}
.netdisk-finder-container.require-login .netdisk-nav,
.netdisk-finder-container.require-login .netdisk-file-list {
display: none;
}
.netdisk-save-panel .netdisk-file-list {
bottom: 60px;
bottom: 50px;
}
.netdisk-save-select {
position: absolute;
......@@ -1811,7 +1886,7 @@ body {
right: 0;
bottom: 0;
left: 0;
height: 30px;
height: auto;
padding: 10px;
border-top: 1px solid #EEE;
background: #fcfcfc;
......@@ -1824,27 +1899,20 @@ body {
}
.netdisk-save-select > input {
width: 50%;
padding: 2px 5px;
height: 16px;
outline: none;
border: 1px solid #abb1c0;
margin: 0;
margin-top: 5px;
margin-right: 10px;
vertical-align: middle;
}
.netdisk-save-select > input:focus {
border-color: #abb1c0;
}
.netdisk-save-select > select {
margin: 5px 0 0 10px;
margin: 5px 0 0 0;
outline: none;
vertical-align: middle;
}
.netdisk-save-select > .save-button {
position: absolute;
right: 10px;
top: 10px;
float: right;
width: 80px;
vertical-align: middle;
}
.local-file-open-panel {
position: relative;
......@@ -1874,12 +1942,26 @@ body {
border: none;
margin: 0 10px 10px 0;
}
.local-file-open-panel .pick-file a:hover {
.local-file-open-panel .pick-file a:hover,
.local-file-open-panel .pick-file a.hover {
background: #8e96aa;
}
.local-file-open-panel .pick-file a:active {
.local-file-open-panel .pick-file a:active,
.local-file-open-panel .pick-file a.active {
background: #656f87;
}
.local-file-open-panel .pick-file a:disabled {
background: #CCC;
}
.local-file-open-panel .pick-file a:disabled:hover,
.local-file-open-panel .pick-file a:disabled.hover,
.local-file-open-panel .pick-file a:disabled:active,
.local-file-open-panel .pick-file a:disabled.active {
background: #CCC;
}
.local-file-open-panel .pick-file span {
line-height: 30px;
}
.local-file-open-panel .drop-file {
border: 2px dashed #eee;
border-radius: 4px;
......@@ -1904,6 +1986,100 @@ body {
border-color: #eee;
color: #eee;
}
.draft-panel h2:before {
content: ' ';
display: block;
width: 25px;
height: 25px;
position: absolute;
left: 0;
background: url(../images/icons.png) no-repeat 0 -570px;
}
.draft-panel > .clear-draft {
position: absolute;
right: 0;
top: 0;
}
.draft-panel > .draft-list {
margin: 0;
padding: 0;
list-style: none;
}
.draft-panel > .draft-list:empty:after {
content: '这是个空虚寂寞的草稿箱!';
display: block;
text-align: center;
font-size: 18px;
height: 50px;
line-height: 50px;
color: #CCC;
}
.draft-panel > .draft-list .draft-list-item {
font-size: 14px;
line-height: 20px;
padding: 10px 20px 10px 40px;
cursor: default;
position: relative;
}
.draft-panel > .draft-list .draft-list-item:hover {
background-color: #f4f5f7;
}
.draft-panel > .draft-list .draft-list-item:active {
background-color: #e5e7ec;
}
.draft-panel > .draft-list .draft-list-item .draft-title {
margin: 0;
font-weight: normal;
height: 20px;
line-height: 20px;
}
.draft-panel > .draft-list .draft-list-item .draft-title:after {
content: ' ';
display: block;
position: absolute;
width: 25px;
height: 25px;
background: url(../images/icons.png) no-repeat 0 -445px;
left: 5px;
top: 10px;
}
.draft-panel > .draft-list .draft-list-item .file-time {
position: absolute;
right: 5px;
top: 10px;
font-size: 12px;
color: #999;
}
.download-panel h2:before {
content: ' ';
display: block;
width: 25px;
height: 25px;
position: absolute;
left: 0;
background: url(../images/icons.png) no-repeat 0 -595px;
}
.download-panel > .download-list {
margin: 0;
padding: 0;
list-style: none;
}
.download-panel > .download-list li {
font-size: 14px;
padding: 10px 20px 10px 40px;
cursor: default;
position: relative;
margin: 0;
font-weight: normal;
height: 20px;
line-height: 20px;
}
.download-panel > .download-list li:hover {
background-color: #f4f5f7;
}
.download-panel > .download-list li:active {
background-color: #e5e7ec;
}
#tab-container .command-buttonset.priority {
width: 140px;
}
......@@ -2404,7 +2580,41 @@ ul.resource-list li {
div.right {
float: right;
}
#share-dialog {
#share-select fieldset {
border: 1px solid #f0f0f0;
margin: 0;
margin-bottom: 10px;
padding: 10px;
}
#share-select fieldset legend {
font-size: 14px;
}
#share-select fieldset:disabled {
opacity: 0.5;
}
#share-select fieldset .share-body {
margin-top: 10px;
}
#public-share p {
position: relative;
max-width: 500px;
}
#public-share p input {
width: 100%;
box-sizing: border-box;
height: 24px;
margin: 0;
}
#public-share p #copy-share-url {
position: absolute;
right: 0;
top: 0;
margin: 0;
height: 24px;
line-height: 24px;
border-radius: 2px;
}
#public-share .share-body {
display: none;
}
.command-button .fui-icon {
......
{"version":3,"sources":["lib/fui/theme/default/fui.all.css","_public.less","_triangle.less","_widgets.less","_kityminder.less","_mainmenu.less","_mainmenu.new.less","_history.less","_tab.less","_search.less","_user.less","_recent.less","_netdisk.less","_localfile.less","_priority_panel.less","_progress_panel.less","_resource_panel.less","_themepanel.less","_fontpanel.less","_colorpanel.less","_about.less","_receiver.less","_help.less","_share.less","_icons.less"],"names":[],"mappings":";;;;;;;;AAQA;EACE,yBAAA;EACA,wBAAA;EACA,sBAAA;EACA,qBAAA;EACA,iBAAA;EACA,uBAAA;EACA,cAAA;EACA,gBAAA;EACA,eAAA;EACA,aAAa,qBAAqB,qBAAqB,iBAAiB,oBAAoB,uBAAuB,mBAAmB,iCAAtI;EACA,mCAAA;EACA,aAAA;EACA,qBAAA;EACA,mBAAA;EACA,kBAAA;EACA,MAAA;EACA,OAAA;;AAEF,WAAW;EACT,yBAAA;EACA,wBAAA;EACA,sBAAA;EACA,qBAAA;EACA,iBAAA;EACA,uBAAA;;AAEF,WAAY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AAGD,IAAK,eAAc,KAAK;EACpB,SAAS,GAAT;;AAEJ,IAAK,eAAc,MAAM;EACrB,SAAS,GAAT;;AAEJ,IAAK,eAAc,IAAI;EACnB,SAAS,GAAT;;AAEJ,cAAc,GAAG;EACb,SAAS,GAAT;EACH,QAAA;;AAED,cAAc,KAAK;EACf,SAAS,GAAT;EACH,QAAA;;AAED,cAAc,KAAK;EACf,SAAS,GAAT;EACH,QAAA;;AAED,cAAc,MAAM;EAChB,SAAS,GAAT;EACH,QAAA;;AAED,GAAG;EACC,YAAA;;AC9IJ;EACI,aAAA;;ACKJ,eAAgB;EACZ,8CAAA;EAJA,2BAAA;;AAQA,gBAAgB,eALJ;EAHZ,0BAAA;;AASA,kBAAkB,eANN;EAHZ,4BAAA;;AAUA,SAAS,eAPG;EAHZ,4BAAA;;AAWA,WAAW,eARC;EAHZ,4BAAA;;AAYA,YAAY,eATA;EASI,6BAAA;;AAChB,WAAW,eAVC;EAUG,6BAAA;;AACf,UAAU,eAXE;EAHZ,6BAAA;;AAeA,WAAW,eAZC;EAHZ,6BAAA;;AAgBA,KAAK,eAbO;EAHZ,6BAAA;;AAiBA,OAAO,eAdK;EAHZ,6BAAA;;AAkBA,UAAU,eAfE;EAHZ,6BAAA;;AAmBA,YAAY,eAhBA;EAHZ,6BAAA"}
\ No newline at end of file
{"version":3,"sources":["lib/fui/theme/default/fui.all.css","_public.less","_triangle.less","_widgets.less","_kityminder.less","_mainmenu.less","_mainmenu.new.less","_history.less","_tab.less","_search.less","_user.less","_recent.less","_netdisk.less","_localfile.less","_draft.less","_download.less","_priority_panel.less","_progress_panel.less","_resource_panel.less","_themepanel.less","_fontpanel.less","_colorpanel.less","_about.less","_receiver.less","_help.less","_share.less","_icons.less"],"names":[],"mappings":";;;;;;;;AAQA;EACE,yBAAA;EACA,wBAAA;EACA,sBAAA;EACA,qBAAA;EACA,iBAAA;EACA,uBAAA;EACA,cAAA;EACA,gBAAA;EACA,eAAA;EACA,aAAa,qBAAqB,qB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K;EACpB,SAAS,GAAT;;AAEJ,IAAK,eAAc,MAAM;EACrB,SAAS,GAAT;;AAEJ,IAAK,eAAc,IAAI;EACnB,SAAS,GAAT;;AAEJ,cAAc,GAAG;EACb,SAAS,GAAT;EACH,QAAA;;AAED,cAAc,KAAK;EACf,SAAS,GAAT;EACH,QAAA;;AAED,cAAc,KAAK;EACf,SAAS,GAAT;EACH,QAAA;;AAED,cAAc,MAAM;EAChB,SAAS,GAAT;EACH,QAAA;;AAED,GAAG;EACC,YAAA;;AC9IJ,aACI;EACI,yBAAA;EACA,SAAA;EACA,mBAAA;EACA,aAAA;;AALR,aACI,SAMI;EACI,eAAA;;AAGJ,aAVJ,SAUK;EACG,YAAA;;AAZZ,aACI,SAkBI;EACI,gBAAA;;AAMZ,aACI;EACI,kBAAA;EACA,gBAAA;;AAHR,aACI,EAGI;EACI,WAAA;EACA,sBAAA;EACA,YAAA;EACA,SAAA;;AARZ,aACI,EASI;EACI,kBAAA;EACA,QAAA;EACA,MAAA;EACA,SAAA;EACA,YAAA;EACA,iBAAA;EACA,kBAAA;;AAjBZ,aAqBI;EACI,aAAA;;AC1CR,eAAgB;EACZ,8CAAA;EAJA,2BAAA;;AAQA,gBAAgB,eALJ;EAHZ,0BAAA;;AASA,kBAAkB,eANN;EAHZ,4BAAA;;AAUA,SAAS,eAPG;EAHZ,4BAAA;;AAWA,WAAW,eARC;EAHZ,4BAAA;;AAYA,YAAY,eATA;EASI,6BAAA;;AAChB,WAAW,eAVC;EAUG,6BAAA;;AACf,UAAU,eAXE;EAHZ,6BAAA;;AAeA,WAAW,eAZC;EAHZ,6BAAA;;AAgBA,KAAK,eAbO;EAHZ,6BAAA;;AAiBA,OAAO,eAdK;EAHZ,6BAAA;;AAkBA,UAAU,eAfE;EAHZ,6BAAA;;AAmBA,YAAY,eAhBA;EAHZ,6BAAA"}
\ No newline at end of file
......@@ -15,6 +15,8 @@
@import "_recent";
@import "_netdisk";
@import "_localfile";
@import "_draft";
@import "_download";
@import "_priority_panel";
@import "_progress_panel";
......
ui/theme/default/images/icons.png

8.9 KB | W: | H:

ui/theme/default/images/icons.png

9.82 KB | W: | H:

ui/theme/default/images/icons.png
ui/theme/default/images/icons.png
ui/theme/default/images/icons.png
ui/theme/default/images/icons.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -44,9 +44,7 @@ KityMinder.registerUI('topbar/title', function(minder) {
setSaved: function(saved) {
if (saved !== false) {
_saved = true;
}
_saved = saved !== false;
update();
......
......@@ -14,6 +14,8 @@ KityMinder.registerUI('topbar/user', function(minder) {
var $userPanel = $('<div class="user-panel"></div>').appendTo('#panel');
var $tip = $('<span></span>').text(minder.getLang('ui.checklogin')).appendTo($userPanel);
/* 登录按钮 */
var $loginButton = new FUI.Button({
label: minder.getLang('ui.login'),
......@@ -69,16 +71,16 @@ KityMinder.registerUI('topbar/user', function(minder) {
});
/* 初始化网盘使用的 APP 身份 */
fio.provider.init('netdisk', {
apiKey: 'wiE55BGOG8BkGnpPs6UNtPbb'
minder.on('uiready', function() {
fio.user.check().then(check)['catch'](function(error) {
$loginButton.show();
$userButton.hide();
$tip.remove();
});
});
fio.user.check().then(check);
$loginButton.on('click', login);
$('body').delegate('.login-button', 'click', login);
$('#content-wrapper').delegate('.login-button', 'click', login);
function check(user) {
if (user) {
......@@ -90,7 +92,9 @@ KityMinder.registerUI('topbar/user', function(minder) {
} else {
$loginButton.show();
$userButton.hide();
fio.user.fire('logout', user);
}
$tip.remove();
currentUser = user;
}
......@@ -102,6 +106,7 @@ KityMinder.registerUI('topbar/user', function(minder) {
}
function login() {
$loginButton.setLabel(minder.getLang('ui.loggingin'));
fio.user.login({
remember: 7 * 24 * 60 * 60 // remember 7 days
}).then(check);
......@@ -114,12 +119,25 @@ KityMinder.registerUI('topbar/user', function(minder) {
}).then(check);
}
function requireLogin($element) {
var $login_tip = $('<p class="login-tip"></p>')
.html(minder.getLang('ui.requirelogin'));
$element.append($login_tip);
fio.user.on('login', function() {
$element.removeClass('login-required');
});
fio.user.on('logout', function() {
$element.addClass('login-required');
});
}
return {
getCurrent: function() {
return currentUser;
},
loginLink: function() {
return $('<a></a>').click(login);
}
},
requireLogin: requireLogin
};
});
\ No newline at end of file
......@@ -28,6 +28,7 @@
initUI: function() {
var ui = this._ui = {};
var minder = this;
uiQueue.forEach(function(uiDeal) {
var deps = uiDeal.deps;
if (deps) deps = deps.map(function(dep) {
......@@ -37,11 +38,14 @@
});
// 阻止非脑图事件冒泡
$('#content-wrapper').delegate('#panel, #tab-container, .fui-dialog, #main-menu', 'click mousedown keydown keyup', function(e) {
$('body').delegate('#panel, #tab-container, .fui-dialog, #main-menu', 'keydown keyup', function(e) {
e.stopPropagation();
});
minder.getPaper().addClass('loading-target');
this.fire('interactchange');
this.fire('uiready');
},
/* 获得实例的 UI 实例 */
......@@ -50,4 +54,11 @@
}
});
$.extend($, {
pajax: function() {
var defered = $.ajax.apply($, arguments);
return Promise.resolve(defered);
}
});
})();
\ No newline at end of file
......@@ -9,6 +9,8 @@
KityMinder.registerUI('widget/fileloader', function(minder) {
var doc = minder.getUI('doc');
var $container = $(minder.getRenderTarget());
var supports = minder.getSupportedProtocols();
......@@ -23,12 +25,16 @@ KityMinder.registerUI('widget/fileloader', function(minder) {
function load(file) {
var protocol = getProtocolByExtension(file.extension);
return minder.importData(file.data.content, protocol.name).then(function(json) {
return doc.load({
source: file.source,
title: file.filename,
content: file.data.content,
protocol: protocol.name
}).then(function(json) {
var $title = minder.getUI('topbar/title');
$title.setTitle(file.filename);
$container.removeClass('loading');
minder.execCommand('camera', minder.getRoot(), 300);
return {
file: file,
......@@ -44,7 +50,7 @@ KityMinder.registerUI('widget/fileloader', function(minder) {
}
return {
load: function(filePromise) {
load: function(filePromise, source) {
$container.addClass('loading');
return Promise.resolve(filePromise).then(load)['catch'](error);
},
......
......@@ -8,9 +8,19 @@
*/
KityMinder.registerUI('widget/friendlytimespan', function(minder) {
function getFriendlyTimeSpan(t1_in_ms, t2_in_ms) {
t2_in_ms = t2_in_ms || +new Date();
var ms = Math.abs(t1_in_ms - t2_in_ms),
$.extend($.fn, {
displayFriendlyTime: function(time) {
return this.each(function() {
display($(this)
.addClass('friendly-time')
.data('time', time));
});
}
});
function getTimeText(timeInMs) {
var ms = Math.abs(timeInMs - new Date()),
s = ms / 1000,
m = s / 60,
h = m / 60,
......@@ -20,10 +30,19 @@ KityMinder.registerUI('widget/friendlytimespan', function(minder) {
if (h < 24) return minder.getLang('ui.hoursago', h | 0);
if (d < 2) return minder.getLang('ui.yesterday');
if (d <= 30) return minder.getLang('ui.daysago', d | 0);
return minder.getLang("ui.longago");
}
return {
display: getFriendlyTimeSpan
};
function display($element) {
$element.text(getTimeText($element.data('time')));
}
function update() {
$('.friendly-time').each(function() {
display($(this));
});
}
setInterval(update, 60000);
});
\ No newline at end of file
......@@ -20,11 +20,13 @@ KityMinder.registerUI('widget/locallist', function() {
} else {
list = [];
}
this.length = list.length;
}
function save() {
while (list.length > maxCount) list.pop();
localStorage.setItem(name, JSON.stringify(list));
this.length = list.length;
}
function get(index) {
......@@ -36,6 +38,11 @@ KityMinder.registerUI('widget/locallist', function() {
save();
}
function clear() {
list = [];
save();
}
function unshift(item) {
list.unshift(item);
save();
......@@ -73,6 +80,7 @@ KityMinder.registerUI('widget/locallist', function() {
this.find = find;
this.forEach = forEach;
this.unshift = unshift;
this.clear = clear;
}
return {
......
/**
* @fileOverview
*
* 用 FUI.Tabs 实现的多级的创建
*
* @author: techird
* @copyright: Baidu FEX, 2014
*/
KM.registerUI('widget/menutab', function(minder) {
function generate(parent, name, asDefault) {
var index = parent.getButtons().length;
var tab = parent.appendTab({
buttons: [{
label: minder.getLang('ui.menu.' + name + 'tab'),
className: 'tab-' + name
}]
});
if (asDefault) {
parent.select(index);
}
return tab[0].panel.getContentElement();
}
return {
generate: generate
};
});
\ No newline at end of file
......@@ -32,21 +32,20 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
var $list = $('<ul class="netdisk-file-list"></ul>')
.appendTo($container);
var $tip = $('<p class="login-tip"></p>')
.html(minder.getLang('ui.requirelogin'))
.appendTo($container);
var $mkdir = $('<a></a>')
.text(minder.getLang('ui.mkdir'))
.addClass('button netdisk-mkdir')
.click(mkdir);
var selected = null;
$nav.after($mkdir);
$container.addClass('netdisk-finder-container');
/* 点击目录中的项目时打开项目 */
$list.delegate('.netdisk-file-list-item', 'click', function(e) {
if (mkdir.onprogress) return mkdir.onprogress.select();
var $file = $(e.target),
file = $file.data('file');
if (file) open(file);
......@@ -54,6 +53,7 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
/* 点击导航处,切换路径 */
$nav.delegate('a', 'click', function(e) {
if (mkdir.onprogress) return mkdir.onprogress.select();
if ($(e.target).hasClass('dir-back')) {
var parts = currentPath.split('/');
parts.pop(); // 有一个无效部分
......@@ -63,34 +63,55 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
list($(e.target).data('path'));
});
fio.user.on('login', show);
fio.user.on('logout', hide);
hide();
minder.on('uiready', function() {
var $user = minder.getUI('topbar/user');
$user.requireLogin($container);
fio.user.on('login', function() {
list();
});
});
function mkdir() {
if (mkdir.onprogress) {
return mkdir.onprogress.select();
}
var $li = $('<li>').addClass('netdisk-file-list-item dir').prependTo($list);
var $input = $('<input>')
.attr('type', 'text')
.addClass('new-dir-name')
.val(minder.getLang('ui.newdir'))
.appendTo($li);
mkdir.onprogress = $input[0];
$input[0].select();
$input.on('keydown', function(e) {
if (e.keyCode == 13) {
var name = $input.val();
$input.on('keydown', function(e) {
if (e.keyCode == 13) confirm();
if (e.keyCode == 27) {
$li.remove();
mkdir.onprogress = false;
e.stopPropagation();
}
});
}
function show() {
$container.removeClass('require-login');
list();
function confirm() {
var name = $input.val();
if (name) {
fio.file.mkdir({
path: currentPath + name
}).then(function() {
return list(currentPath);
}, function(e) {
window.alert('创建目录失败:' + e.message);
}).then(function() {
mkdir.onprogress = false;
});
}
$li.remove();
}
function hide() {
$container.addClass('require-login');
}
/**
......@@ -146,14 +167,13 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
var transitPromise = fadeOutList(-100 * sign(path.length - currentPath.length));
Promise.all([listPromise, transitPromise]).then(renderList, function(error) {
window.alert('加载目录发生错误:' + error);
});
currentPath = path.charAt(path.length - 1) == '/' ? path : path + '/';
updateNav();
return Promise.all([listPromise, transitPromise]).then(renderList, function(error) {
window.alert('加载目录发生错误:' + error);
});
}
function renderList(values) {
......@@ -161,6 +181,14 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
var files = values[0];
files.sort(function(a, b) {
if (a.isDir > b.isDir) {
return -1;
} else if (a.isDir == b.isDir) {
return a.createTime > b.createTime ? -1 : 1;
} else return 1;
});
if (!files.length) {
$list.append('<li class="empty" disabled="disabled">' + minder.getLang('ui.emptydir') + '</li>');
} else {
......@@ -178,6 +206,7 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
}
fadeInList();
checkSelect();
finder.fire('cd', currentPath);
}
......@@ -213,7 +242,31 @@ KityMinder.registerUI('widget/netdiskfinder', function(minder) {
});
}
function select(path) {
selected = path;
return checkSelect();
}
function checkSelect() {
var hasSelect = false;
$list.find('.netdisk-file-list-item').removeClass('selected').each(function() {
var file = $(this).data('file');
if (file && file.path == selected) {
$(this).addClass('selected');
hasSelect = true;
}
});
if (!hasSelect) selected = false;
return hasSelect;
}
function pwd() {
return currentPath;
}
finder.list = list;
finder.select = select;
finder.pwd = pwd;
return finder;
}
......
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="title" content="百度脑图(KityMinder)">
<meta name="keyword" content="kityminder,脑图,思维导图,kity,svg,minder,百度,fex,前端,在线">
<meta name="description" content="百度脑图,便捷的脑图编辑工具。让您在线上直接创建、保存并分享你的思路。">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
<title>百度脑图 - 便捷的思维导图工具</title>
<script src="import.share.js" charset="utf-8"></script>
<script src="kityminder.config.js" charset="utf-8"></script>
<script src="lang/zh-cn/zh-cn.js" charset="utf-8"></script>
<link href="ui/theme/default/css/default.all.css" type="text/css" rel="stylesheet" />
<link href="favicon.ico" type="image/x-icon" rel="shortcut icon">
<link href="favicon.ico" type="image/x-icon" rel="apple-touch-icon-precomposed">
</head>
<body>
<div id="content-wrapper">
<div id="panel"></div>
<div id="kityminder" onselectstart="return false">
</div>
<div id="about">
<svg id="km-cat" viewBox="0 0 1200 1200" width="32px" height="32px">
<g id="cat-face">
<path d="M1066.769,368.482L1119.5,80L830,131.611C760.552,97.29,682.35,77.999,599.641,77.999
c-82.424,0-160.371,19.161-229.641,53.26L81,81l50.769,289l0,0c-33.792,69.019-52.77,146.612-52.77,228.641
c0,287.542,233.099,520.642,520.642,520.642s520.642-233.099,520.642-520.642C1120.282,516.011,1101.028,437.88,1066.769,368.482z"
/>
</g>
<g id="cat-eye">
<path style="fill:#FFFFFF;" d="M920.255,371C794.746,371,693,472.746,693,598.255s101.746,227.255,227.255,227.255
s227.255-101.746,227.255-227.255S1045.765,371,920.255,371z M920,746c-80.081,0-145-64.919-145-145s64.919-145,145-145
s145,64.919,145,145S1000.081,746,920,746z"/>
<path style="fill:#FFFFFF;" d="M276.255,371C150.746,371,49,472.746,49,598.255s101.746,227.255,227.255,227.255
s227.255-101.746,227.255-227.255S401.765,371,276.255,371z M276,745c-80.081,0-145-64.919-145-145s64.919-145,145-145
s145,64.919,145,145S356.081,745,276,745z"/>
</g>
</svg>
KityMinder
<a id="km-version"
href="https://github.com/fex-team/kityminder/blob/dev/CHANGELOG.md"
target="blank"
tabindex="-1">
</a>
under
<a href="https://raw.githubusercontent.com/fex-team/kityminder/dev/LICENSE"
target="_blank"
tabindex="-1">BSD License
</a>.
Powered by f-cube,
<a href="http://fex.baidu.com"
target="_blank"
tabindex="-1">FEX
</a> |
<a href="https://github.com/fex-team/kityminder.git"
target="_blank"
tabindex="-1">Source
</a>
<a href="https://github.com/fex-team/kityminder/issues/new"
target="_blank"
tabindex="-1">Bug
</a> |
<a href="mailto:kity@baidu.com"
target="_blank"
tabindex="-1">Contact Us
</a>
</div>
</div>
</body>
<!--脑图启动代码-->
<script>
/* global km:true, ZeroClipboard:true, zip:true */
/* jshint browser:true */
$(function() {
// create km instance
km = KM.getMinder('kityminder', window.KITYMINDER_CONFIG);
// init ui for instance
km.initUI();
// New Version Notify
$(function() {
var lastVersion = localStorage.lastKMVersion;
$('#km-version').text( 'v' + KM.version );
if (lastVersion != KM.version) {
$( '#km-version' ).addClass( 'new-version' );
localStorage.lastKMVersion = KM.version;
}
});
});
</script>
<!--Baidu Tongji Code-->
<script type="text/javascript">
if (document.domain == 'naotu.baidu.com') {
var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : " http://");
document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3F0703917f224067c887f3664479a03887' type='text/javascript'%3E%3C/script%3E"));
}
</script>
</html>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment