kopia lustrzana https://github.com/miklobit/TiddlyWiki5
tw5dropbox updates
rodzic
d4b2ab4a5f
commit
071c876d41
|
@ -15,22 +15,10 @@ type: text/x-tiddlywiki-html
|
|||
<<serialize "$:/core/copyright.txt" text/plain>>
|
||||
" />
|
||||
<title><<tiddler "$:/core/wiki/title">></title>
|
||||
<!----------- This is a Tiddlywiki file. The points of interest in the file are marked with this pattern ----------->
|
||||
|
||||
<!----------- Raw markup ----------->
|
||||
<<serialize "[tag[$:/core/wiki/rawmarkup]]" text/plain>>
|
||||
</head>
|
||||
<body>
|
||||
<!----------- Static styles ----------->
|
||||
<link rel="stylesheet" href="//dl-web.dropbox.com/spa/4f6lw6nhu5zn5pr/TiddlyWiki5/public/styles.css" type="text/css" />
|
||||
<!----------- Miscellaneous shadow tiddlers ----------->
|
||||
<div id="shadowArea" style="display:none;">
|
||||
<<serialize "[is[shadow]] -[type[text/css]] -[type[application/javascript]has[module-type]] -[type[application/javascript]library[yes]] -[[$:/core/boot.js]] -[[$:/core/bootprefix.js]]" application/x-tiddler-html-div>>
|
||||
</div>
|
||||
<!----------- Ordinary tiddlers ----------->
|
||||
<div id="storeArea" style="display:none;">
|
||||
<<serialize "$1" application/x-tiddler-html-div>>
|
||||
</div>
|
||||
</body>
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/dropbox.js/0.6.1/dropbox.min.js"></script>
|
||||
<script src="//dl-web.dropbox.com/spa/4f6lw6nhu5zn5pr/TiddlyWiki5/public/tw5dropbox.js"></script>
|
||||
|
|
|
@ -3,5 +3,7 @@ type: text/x-tiddlywiki-html
|
|||
|
||||
<<serialize "[is[shadow]type[application/javascript]library[yes]] -[[$:/library/sjcl.js]]" text/plain>>
|
||||
<<serialize "$:/core/bootprefix.js" text/plain>>
|
||||
<<serialize "[is[shadow]] -[type[text/css]] -[type[application/javascript]has[module-type]] -[type[application/javascript]library[yes]] -[[$:/core/boot.js]] -[[$:/core/bootprefix.js]]" application/x-tiddler-javascript>>
|
||||
<<serialize "[is[shadow]type[application/javascript]has[module-type]]" application/x-tiddler-module-plain>>
|
||||
<<serialize "$:/core/boot.js" text/plain>>
|
||||
|
||||
|
|
|
@ -229,7 +229,7 @@ $tw.plugins.dropbox.forceLogin = function() {
|
|||
// Create a new empty TiddlyWiki
|
||||
$tw.plugins.dropbox.createWiki = function(wikiName) {
|
||||
// Remove any dodgy characters from the wiki name
|
||||
wikiName = wikiName.replace(/[\$\:\?\#\/\\]/g,"");
|
||||
wikiName = wikiName.replace(/[\!\@\€\£\%\^\*\+\$\:\?\#\/\\\<\>\|\"\'\`\~\=]/g,"");
|
||||
// Check that the name isn't now empty
|
||||
if(wikiName.length === 0) {
|
||||
return alert("Bad wiki name");
|
||||
|
@ -261,8 +261,12 @@ $tw.plugins.dropbox.createWiki = function(wikiName) {
|
|||
}
|
||||
],
|
||||
// optional callback
|
||||
function(err,results) {
|
||||
alert("Created wiki " + wikiName + " error " + err);
|
||||
function(error,results) {
|
||||
if(error) {
|
||||
$tw.plugins.dropbox.showError(error);
|
||||
} else {
|
||||
alert("Created wiki " + wikiName);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue