hint "content" run-on with custom tag
See original GitHub issueUsing your example on your hint examples page (http://summernote.org/examples/#hint) I modified slightly the “content:” to highlight the item:
$(".hint2mention").summernote({
height: 100,
toolbar: false,
hint: {
mentions: ['jayden', 'sam', 'alvin', 'david'],
match: /\B@(\w*)$/,
search: function (keyword, callback) {
callback($.grep(this.mentions, function (item) {
return item.indexOf(keyword) == 0;
}));
},
content: function (item) {
return $("<b>").html('@' + item)[0]; // Changed from return '@'+item
}
}
});
browser: Chrominium Version 50.0.2661.94 (64-bit) OS: Linux Mint 17.3 64 bit Summernote source used: http://cdnjs.cloudflare.com/ajax/libs/summernote/0.8.1/summernote.js
result is like this:
here is text @sam words beyond selection are stil bold
I cannot seem to terminate the ‘bold’.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:7
Top Results From Across the Web
java ee 6 - Custom tag file code assist not working in Eclipse ...
1) Try Window / Preferences / Web / JSP Files / Editor / Content Assist. Make sure the HTML and XML Tag Proposals...
Read more >How To Create Custom Automation Tags - LambdaTest
LambdaTest allows you to group your automation tests using custom tags. In this document, we will see how to create custom tags and...
Read more >Custom Templates Guide For Google Tag Manager
A comprehensive guide to building custom templates (both tag templates and variable templates) in Google Tag Manager.
Read more >Personalize Content with Custom Fields | Digital Range Help Center ...
You can personalize the subject line, "From" name and content of your email by inserting personalization tags based on subscriber field data.
Read more >GitHub Actions — Run a Workflow When Creating a Tag
You can even customize the publishing process with tags to ignore. For example, if you're preparing the new major release of your project,...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
For anyone wondering, I solved this by modifying the summernote code:
I added the last line so that it jumps out of the span.
Guess we can’t really wrap it yet.
This works:
return $("<span>").html('<strong>@' + item.name + '</strong><span> </span>')[0]