From f7c579e7e6007460a729878a6ab86069a75bd5c1 Mon Sep 17 00:00:00 2001 From: JC Brand Date: Fri, 9 Aug 2013 19:22:49 +0200 Subject: [PATCH] Add OTR to bower.json and converse.js --- bower.json | 6 +++--- converse.js | 9 +++++---- index.html | 4 ++-- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/bower.json b/bower.json index 04b0ed6b9..7b103b0df 100644 --- a/bower.json +++ b/bower.json @@ -17,8 +17,8 @@ "strophe.roster": "https://raw.github.com/jcbrand/strophejs-plugins/75c8693992bc357c699b6d615eeb396e799f5c02/roster/strophe.roster.js", "strophe.vcard": "https://raw.github.com/jcbrand/strophejs-plugins/75c8693992bc357c699b6d615eeb396e799f5c02/vcard/strophe.vcard.js", "strophe.disco": "https://raw.github.com/jcbrand/strophejs-plugins/75c8693992bc357c699b6d615eeb396e799f5c02/disco/strophe.disco.js", - "strophe.muc": "https://raw.github.com/jcbrand/strophejs-plugins/75c8693992bc357c699b6d615eeb396e799f5c02/muc/strophe.muc.js" + "strophe.muc": "https://raw.github.com/jcbrand/strophejs-plugins/75c8693992bc357c699b6d615eeb396e799f5c02/muc/strophe.muc.js", + "otr": "~0.2.1" }, - "exportsOverride": { - } + "exportsOverride": {} } diff --git a/converse.js b/converse.js index ce795527c..05ad19b67 100644 --- a/converse.js +++ b/converse.js @@ -13,6 +13,7 @@ } if (typeof define === 'function' && define.amd) { define("converse", [ + "components/otr/build/otr", "locales", "localstorage", "tinysort", @@ -22,13 +23,13 @@ "strophe.roster", "strophe.vcard", "strophe.disco" - ], function() { + ], function(otr) { // Use Mustache style syntax for variable interpolation _.templateSettings = { evaluate : /\{\[([\s\S]+?)\]\}/g, interpolate : /\{\{([\s\S]+?)\}\}/g }; - return factory(jQuery, _, console); + return factory(jQuery, _, otr, console); } ); } else { @@ -37,9 +38,9 @@ evaluate : /\{\[([\s\S]+?)\]\}/g, interpolate : /\{\{([\s\S]+?)\}\}/g }; - root.converse = factory(jQuery, _, console || {log: function(){}}); + root.converse = factory(jQuery, _, otr, console || {log: function(){}}); } -}(this, function ($, _, console) { +}(this, function ($, _, otr, console) { var converse = {}; converse.initialize = function (settings) { // Default values diff --git a/index.html b/index.html index 07e3aa70c..ab76ac447 100644 --- a/index.html +++ b/index.html @@ -6,8 +6,8 @@ - - + + Converse.js