New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

nodebb-plugin-mentions-cards

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nodebb-plugin-mentions-cards - npm Package Compare versions

Comparing version 0.0.2 to 0.0.3

2

package.json
{
"name": "nodebb-plugin-mentions-cards",
"version": "0.0.2",
"version": "0.0.3",
"description": "NodeBB plugin that extends the mentions plugin with hover cards",

@@ -5,0 +5,0 @@ "main": "library.js",

(function(window) {
var delay, cardTpl, currentCard, destroyDelay;
var delay, cardTpl, currentCard, destroyDelay,
events = 'mouseenter.card mouseleave.card',
selector = 'a[href*="/user/"]:not(.mentions-card-img-container a)';
$(document).ready(function() {

@@ -8,7 +11,10 @@ window.ajaxify.loadTemplate('mentions/card', function(tpl) {

$(window).on('action:ajaxify.end', function() {
$('.plugin-mentions-a').off("mouseenter.card mouseleave.card").on("mouseenter.card mouseleave.card", function(e){
$('.container').off(events, selector).on(events, selector, function(e){
var target = $(e.currentTarget);
if (target.children('img')) {
target.children('img').tooltip('destroy');
}
if (e.type === "mouseenter" && !target.is(currentCard)) {
delay = setTimeout(function() {
createCard(target, target.attr('href'));
createCard(target, target.attr('href').match(/\/user\/.+/)[0]);
}, 500);

@@ -20,3 +26,3 @@ } else {

}, 500);
target.next('.popover').off("mouseenter.card mouseleave.card").on("mouseenter.card mouseleave.card", function(e) {
target.data('bs.popover')['$tip'].off(events).on(events, function(e) {
if (e.type === "mouseenter") {

@@ -70,4 +76,5 @@ clearTimeout(destroyDelay);

content: html,
placement: "top",
trigger: "manual"
placement: 'top',
trigger: 'manual',
container: 'body'
}).popover('show');

@@ -77,2 +84,4 @@

utils.makeNumbersHumanReadable($('.mentions-card-stats li span'));
$('.mentions-card-chat').off('click.card').on('click.card', function(e) {

@@ -86,2 +95,6 @@ var card = $(e.currentTarget).parents('.mentions-card');

}
})(window);
app.createUserTooltips = function() {
//so metal
}
})(window);

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc