Merge branch 'dev' of http://github.com/amark/gun into dev

This commit is contained in:
Mark Nadal 2019-11-17 03:35:25 -08:00
commit 56678aa7f5
2 changed files with 18 additions and 8 deletions

View File

@ -116,7 +116,8 @@ Thanks to:<br/>
<a href="https://github.com/dfreire">Dário Freire</a>,
<a href="http://github.com/velua">John Williamson</a>,
<a href="http://github.com/finwo">Robin Bron</a>,
<a href="http://github.com/ElieMakhoul">Elie Makhoul</a>
<a href="http://github.com/ElieMakhoul">Elie Makhoul</a>,
<a href="http://github.com/mikestaub">Mike Staub</a>
</p>
- Join others in sponsoring code: https://www.patreon.com/gunDB !
@ -193,7 +194,7 @@ var Gun = require('gun/gun');
If you also need to install SEA for user auth and crypto, also install some of its dependencies like this:
`npm install text-encoding node-webcrypto-ossl --save`
`npm install text-encoding @peculiar/webcrypto --save`
You will need to require it too (it will be automatically added to the Gun object):

View File

@ -15,7 +15,9 @@
}
if(typeof module !== "undefined"){ var common = module }
/* UNBUILD */
;USE(function(module){
var noop = function(){}, u;
$.fn.or = function(s){ return this.length ? this : $(s||'body') };
var m = window.meta = {edit:[]};
@ -141,11 +143,12 @@
edit.combow = edit.combow.join(',');
m.list(meta.edit);
}
})(USE, './metaCore');
;USE(function(module){
try{
/* UI */
if(meta.css){ return }
var $m = $('<div>').attr('id', 'meta');
$m.append($('<span>').html('&#9776;').addClass('meta-start'));
$m.append($('<div>').addClass('meta-menu meta-none').append('<ul>'));
@ -231,9 +234,11 @@
});
var tag = document.createElement('style');
tag.innerHTML = tmp;
document.body.appendChild(tag);
$m.append(tag)
}
}catch(e){}
})(USE, './metaUI');
;USE(function(module){
// include basic text editing by default.
@ -377,6 +382,8 @@
on: function(eve){ meta.text.editor('fontSize', 7) },
up: function(){}
});
})(USE, './metaText');
;USE(function(module){
var m = meta, k = m.key;
@ -394,10 +401,10 @@
});
$(document).on('touchstart', '#meta .meta-start', function(eve){ m.tap.stun = true });
$(document).on('click', '#meta .meta-menu li', function(eve){
eve.fake = eve.which = $(this).data().combo.slice(-1)[0].charCodeAt(0);
var combo = $(this).data().combo;
eve.fake = eve.which = combo && combo.slice(-1)[0].charCodeAt(0);
eve.tap = true;
k.down(eve);
//k.up(eve);
k.down(eve); k.up(eve);
return;
if(m.tap.stun){ return m.tap.stun = false }
if(!(eve.fake = eve.which = (($(this).text().match(/[A-Z]/)||{})[0]||'').toUpperCase().charCodeAt(0))){ return }
@ -407,5 +414,7 @@
});
$(document).on('keydown', k.down).on('keyup', k.up);
$(document).on('select contextmenu keyup mouseup', '[contenteditable=true]', m.text.on);
})(USE, './metaEvents');
}());
}());