diaspora/public/javascripts/widgets/timeago.js
Dan Hansen dc947e449b fix issues with comment stream, fix likes, merge comment stream and comment toggler widgets.
make timeago widget a simple wrapper for $.fn.timeago (we don't really need this.)
2011-08-30 21:07:40 -05:00

19 lines
547 B
JavaScript

/* Copyright (c) 2010, Diaspora Inc. This file is
* licensed under the Affero General Public License version 3 or later. See
* the COPYRIGHT file.
*/
(function() {
if(Diaspora.I18n.language !== "en") {
$.each($.timeago.settings.strings, function(index) {
$.timeago.settings.strings[index] = Diaspora.I18n.t("timeago." + index);
});
}
Diaspora.Widgets.TimeAgo = function() {
var self = this;
this.subscribe("widget/ready", function(evt, element) {
self.element = element.timeago();
});
};
})();