mirror of
https://github.com/scratchfoundation/jquery-timeago.git
synced 2024-11-27 09:45:38 -05:00
Merge pull request #131 from DvdGiessen/update-title-attr
Added support for updating locale titles
This commit is contained in:
commit
f512100060
1 changed files with 3 additions and 1 deletions
|
@ -132,7 +132,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
update: function(time){
|
update: function(time){
|
||||||
$(this).data('timeago', { datetime: $t.parse(time) });
|
var parsedTime = $t.parse(time);
|
||||||
|
$(this).data('timeago', { datetime: parsedTime });
|
||||||
|
if($t.settings.localeTitle) $(this).attr("title", parsedTime.toLocaleString());
|
||||||
refresh.apply(this);
|
refresh.apply(this);
|
||||||
},
|
},
|
||||||
updateFromDOM: function(){
|
updateFromDOM: function(){
|
||||||
|
|
Loading…
Reference in a new issue