Fix link preview event conflict onClick

This commit is contained in:
idotj 2023-12-11 18:43:33 +01:00
parent a6e93435cc
commit ff4286a15e
4 changed files with 8 additions and 4 deletions

View File

@ -1,3 +1,6 @@
v3.12.0 - 11/12/2023
- Fix link preview event on click
v3.11.0 - 4/11/2023 v3.11.0 - 4/11/2023
- Update icons - Update icons
- Improve loader spinner - Improve loader spinner

View File

@ -1,4 +1,4 @@
/* Mastodon embed feed timeline v3.11.0 */ /* Mastodon embed feed timeline v3.12.0 */
/* More info at: */ /* More info at: */
/* https://gitlab.com/idotj/mastodon-embed-feed-timeline */ /* https://gitlab.com/idotj/mastodon-embed-feed-timeline */

View File

@ -1,5 +1,5 @@
/** /**
* Mastodon embed feed timeline v3.11.0 * Mastodon embed feed timeline v3.12.0
* More info at: * More info at:
* https://gitlab.com/idotj/mastodon-embed-feed-timeline * https://gitlab.com/idotj/mastodon-embed-feed-timeline
*/ */
@ -149,7 +149,7 @@ MastodonApi.prototype.buildTimeline = async function () {
this.mtBodyContainer.innerHTML = this.mtBodyContainer.innerHTML =
'<div class="mt-error"><span class="mt-error-icon">📭</span><br/><strong>Sorry, no toots to show</strong><br/><div class="mt-error-message">Got ' + '<div class="mt-error"><span class="mt-error-icon">📭</span><br/><strong>Sorry, no toots to show</strong><br/><div class="mt-error-message">Got ' +
this.FETCHED_DATA.timeline.length + this.FETCHED_DATA.timeline.length +
' toots from the server. <br/>This may be due to an incorrect configuration in the parameters or to filters applied to hide certains type of toots.</div></div>'; " toots from the server. <br/>This may be due to an incorrect configuration in the parameters or to filters applied to hide certains type of toots.</div></div>";
} else { } else {
// Insert link after last toot to visit Mastodon page // Insert link after last toot to visit Mastodon page
if (this.LINK_SEE_MORE) { if (this.LINK_SEE_MORE) {
@ -216,6 +216,7 @@ MastodonApi.prototype.buildTimeline = async function () {
e.target.parentNode.className !== "mt-toot-avatar-image-big" && e.target.parentNode.className !== "mt-toot-avatar-image-big" &&
e.target.parentNode.className !== "mt-toot-avatar-image-small" && e.target.parentNode.className !== "mt-toot-avatar-image-small" &&
e.target.parentNode.className !== "mt-toot-preview-image" && e.target.parentNode.className !== "mt-toot-preview-image" &&
e.target.parentNode.className !== "mt-toot-preview" &&
urlToot urlToot
) { ) {
window.open(urlToot, "_blank", "noopener"); window.open(urlToot, "_blank", "noopener");

File diff suppressed because one or more lines are too long