@ecency/render-helper 2.5.14 → 2.5.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/node/index.mjs
CHANGED
|
@@ -14,6 +14,8 @@ var WHITE_LIST = [
|
|
|
14
14
|
"ecency.com",
|
|
15
15
|
"hive.blog",
|
|
16
16
|
"peakd.com",
|
|
17
|
+
"snapie.io",
|
|
18
|
+
"hivesuite.app",
|
|
17
19
|
"travelfeed.io",
|
|
18
20
|
"dapplr.in",
|
|
19
21
|
"leofinance.io",
|
|
@@ -838,7 +840,7 @@ var matchesHref = (href, value) => {
|
|
|
838
840
|
return normalizeValue(value) === normalizedHref;
|
|
839
841
|
};
|
|
840
842
|
var normalizeDisplayText = (text2) => {
|
|
841
|
-
const beforeTrailingSlash = text2.trim().replace(/^https?:\/\/(www\.)?(ecency\.com|peakd\.com|hive\.blog)/i, "").replace(/^\/+/, "").split("?")[0].replace(/#@.*$/i, "");
|
|
843
|
+
const beforeTrailingSlash = text2.trim().replace(/^https?:\/\/(www\.)?(ecency\.com|peakd\.com|hive\.blog|leofinance\.io|inleo\.io|snapie\.io|hivesuite\.app)/i, "").replace(/^\/+/, "").split("?")[0].replace(/#@.*$/i, "");
|
|
842
844
|
return trimTrailingSlash(beforeTrailingSlash).toLowerCase();
|
|
843
845
|
};
|
|
844
846
|
var getInlineMeta = (el, href, author, permlink, communityTag) => {
|
|
@@ -1615,8 +1617,11 @@ function iframe(el, parentDomain = "ecency.com", forApp = false, renderOptions)
|
|
|
1615
1617
|
return;
|
|
1616
1618
|
}
|
|
1617
1619
|
if (src.match(SKATEHIVE_IPFS_REGEX)) {
|
|
1618
|
-
el.
|
|
1619
|
-
|
|
1620
|
+
const video = el.ownerDocument.createElement("video");
|
|
1621
|
+
video.setAttribute("src", src);
|
|
1622
|
+
video.setAttribute("controls", "");
|
|
1623
|
+
el.parentNode.insertBefore(video, el);
|
|
1624
|
+
el.parentNode.removeChild(el);
|
|
1620
1625
|
return;
|
|
1621
1626
|
}
|
|
1622
1627
|
if (src.match(SKATEHYPE_EMBED_REGEX)) {
|