Move jquery.textcomplete to git submodule in vendor.

pull/2281/head
Gordon Martin 2016-09-27 22:00:13 +01:00
parent 03c75d358c
commit bcea5863de
4 changed files with 6 additions and 1486 deletions

3
.gitmodules vendored
View File

@ -44,3 +44,6 @@
path = public/vendor/Sunsetter8
url = https://github.com/niklasf/Sunsetter8
branch = js
[submodule "public/vendor/jquery-textcomplete"]
path = public/vendor/jquery-textcomplete
url = https://github.com/yuku-t/jquery-textcomplete

View File

@ -10,7 +10,7 @@ $(function () {
form.find('textarea').height(message.height());
});
lichess.loadScript('/assets/javascripts/vendor/jquery.textcomplete.js').then(function() {
lichess.loadScript('/assets/vendor/jquery-textcomplete/dist/jquery.textcomplete.js').then(function() {
var getTopicId = function () {
return $('.post-text-area').attr('data-topic');
@ -28,8 +28,7 @@ $(function () {
};
var searchCandidates = function(term, candidateUsers) {
return $.map(candidateUsers,
function (user) {
return candidateUsers.map(function (user) {
return user.indexOf(term) === 0 ? user : null;
});
};

File diff suppressed because it is too large Load Diff

@ -0,0 +1 @@
Subproject commit adda11608d4aa33250dd31471ac33fdfee17363e