|
@@ -1354,19 +1354,14 @@ export const publishNFTTweetPost = ({ postId, srcContent, groupId }) => {
|
|
|
let inputEle = document.querySelector('div[contenteditable="true"]');
|
|
|
let textContent = inputEle.innerText
|
|
|
let arr = srcContent.split(' ') || []
|
|
|
- let text_content_arr = textContent.split(' ') || []
|
|
|
arr.forEach((item) => {
|
|
|
if (textContent.includes(item)) {
|
|
|
textContent = textContent.replaceAll(item, '')
|
|
|
}
|
|
|
})
|
|
|
- text_content_arr.forEach((item) => {
|
|
|
- if (item.includes('#DNFT') || item.includes('⬇️')) {
|
|
|
- textContent = textContent.replaceAll(item, '')
|
|
|
- }
|
|
|
- })
|
|
|
textContent = textContent.replaceAll('#DNFT', '')
|
|
|
textContent = textContent.replaceAll('⬇️', '')
|
|
|
+ textContent = textContent.replaceAll('Join Now:', '')
|
|
|
|
|
|
let formData = {
|
|
|
groupId,
|
|
@@ -1421,7 +1416,8 @@ const initGroupTip = () => {
|
|
|
let iframe_banner = document.querySelector('#denet_group_banner')
|
|
|
if (iframe_banner) {
|
|
|
if (twitterAccount != getQueryStringByUrl(iframe_banner.src, 'twitterAccount')) {
|
|
|
- iframe_banner.style.display = 'none'
|
|
|
+ iframe_banner.style.visibility = 'hidden'
|
|
|
+ iframe_banner.style.height = '0px'
|
|
|
iframe_banner.src = chrome.runtime.getURL(`/iframe/group-card.html?twitterAccount=${twitterAccount}`)
|
|
|
}
|
|
|
return
|
|
@@ -1430,12 +1426,14 @@ const initGroupTip = () => {
|
|
|
let dom = document.querySelector('div[data-testid="ScrollSnap-SwipeableList"]').closest('nav')
|
|
|
let iframe = document.createElement('iframe')
|
|
|
iframe.id = 'denet_group_banner'
|
|
|
- iframe.style.cssText = 'border: medium none; display:none; width:100%; height:100px;'
|
|
|
+ iframe.style.cssText = 'border: medium none; visibility:hidden; width:100%; height:0px;'
|
|
|
|
|
|
iframe.src = chrome.runtime.getURL(`/iframe/group-card.html?twitterAccount=${twitterAccount}`)
|
|
|
|
|
|
- if (dom && !dom.parentNode.children[0].querySelector('iframe')) {
|
|
|
- dom.parentNode.children[0].appendChild(iframe)
|
|
|
+
|
|
|
+ if (dom && !dom.parentNode.querySelector('iframe')) {
|
|
|
+ dom.parentNode.insertBefore(iframe,dom)
|
|
|
+ // .children[0].appendChild(iframe)
|
|
|
}
|
|
|
|
|
|
} catch (error) {
|
|
@@ -1446,8 +1444,8 @@ const initGroupTip = () => {
|
|
|
|
|
|
export const showGroupTip = () => {
|
|
|
let dom_denet_group_banner = document.querySelector('#denet_group_banner')
|
|
|
- dom_denet_group_banner.style.display = 'block';
|
|
|
-
|
|
|
+ dom_denet_group_banner.style.visibility = 'visible';
|
|
|
+ dom_denet_group_banner.style.height = '100px';
|
|
|
groupBtnStyleChange();
|
|
|
}
|
|
|
|