Skip to content

Commit b876c81

Browse files
committed
Converted strings to template literal, tightened comparisons ↞ [auto-sync from https://github.com/adamlui/ai-web-extensions/tree/main/duckduckgpt]
1 parent eaa0a45 commit b876c81

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

chatgpt/duckduckgpt/duckduckgpt.user.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@
148148
// @description:zu Yengeza izimpendulo ze-AI ku-DuckDuckGo (inikwa amandla yi-GPT-4o!)
149149
// @author KudoAI
150150
// @namespace https://kudoai.com
151-
// @version 2026.7.26
151+
// @version 2026.7.26.1
152152
// @license MIT
153153
// @icon https://cdn.jsdelivr.net/gh/KudoAI/duckduckgpt@e73859f/assets/images/icons/app/icon48.png
154154
// @icon64 https://cdn.jsdelivr.net/gh/KudoAI/duckduckgpt@e73859f/assets/images/icons/app/icon64.png
@@ -1633,7 +1633,7 @@
16331633
return // since big Summarize button exists
16341634
const btn = dom.create.elem('button', {
16351635
id: `${app.slug}-${btnType}-btn`, class: `${app.slug}-chatbar-btn no-mobile-tap-outline` })
1636-
btn.style.right = `${ idx == 0 ? 5 : 0.3 }px`
1636+
btn.style.right = `${ idx === 0 ? 5 : 0.3 }px`
16371637
if (env.browser.isFF && btnType == 'shuffle') btn.style.right = '1.4px'
16381638
btn.append(icons.create({ key: btnType, size: btnType == 'send' ? 14 : 18 }))
16391639
continueChatDiv.append(btn)
@@ -1863,7 +1863,7 @@
18631863
+ `<span class="about-em">${app.version}</span>\n`
18641864
+ `<span style="${labelStyles}">📜 ${app.msgs.about_openSourceCode}:</span> `
18651865
+ `<a href="${app.urls.github}" target="_blank" rel="nopener">`
1866-
+ app.urls.github + '</a>\n'
1866+
+ `${app.urls.github}</a>\n`
18671867
+ `<span style="${labelStyles}">🚀 ${app.msgs.about_latestChanges}:</span> `
18681868
+ `<a href="${app.urls.github}/commits" target="_blank" rel="nopener">`
18691869
+ `${app.urls.github}/commits</a>\n`
@@ -1952,7 +1952,7 @@
19521952
btnsDiv.style.cssText = `margin: 18px 0px 6px !important ; ${ env.browser.isCompact ? ''
19531953
: 'flex-wrap: wrap ; justify-content: center ; gap: 9px' }` // gridify wide view btns
19541954
btnsDiv.querySelectorAll('button').forEach((btn, idx) => {
1955-
if (idx == 0) btn.style.display = 'none' // hide Dismiss button
1955+
if (idx === 0) btn.style.display = 'none' // hide Dismiss button
19561956
else btn.classList.toggle('primary-modal-btn', // emphasize preferred API
19571957
app.config.preferredAPI && app.config.preferredAPI.toLowerCase() == btn.textContent.toLowerCase()
19581958
|| btn.textContent == app.msgs.menuLabel_random && !app.config.preferredAPI)
@@ -1982,7 +1982,7 @@
19821982
// Hack buttons
19831983
btns = btnsDiv.querySelectorAll('button')
19841984
btns.forEach((btn, idx) => {
1985-
if (idx == 0) btn.style.display = 'none' // hide Dismiss button
1985+
if (idx === 0) btn.style.display = 'none' // hide Dismiss button
19861986
if (idx == btns.length -1) btn.classList.remove('primary-modal-btn') // de-emphasize last link
19871987
btn.style.marginTop = btn.style.marginBottom = '5px' // v-pad btns
19881988

@@ -2105,7 +2105,7 @@
21052105
const modalBG = modal.parentNode
21062106
new MutationObserver(([mutation], obs) =>
21072107
mutation.removedNodes.forEach(removedNode => {
2108-
if (removedNode != modalBG) return
2108+
if (removedNode !== modalBG) return
21092109
if (modals.stack[0].includes(modalSubType || modalType)) { // new modal not launched so nav back
21102110
modals.stack.shift() // remove this modal type from stack 1st
21112111
const prevModalType = modals.stack[0]

0 commit comments

Comments
 (0)