|
219 | 219 | // @description:zu ⚡ Terus menghasilkan imibuzo eminingi ye-ChatGPT ngokwesizulu
|
220 | 220 | // @author Adam Lui
|
221 | 221 | // @namespace https://github.com/adamlui
|
222 |
| -// @version 2025.5.13.3 |
| 222 | +// @version 2025.5.13.4 |
223 | 223 | // @license MIT
|
224 | 224 | // @icon https://assets.chatgptautocontinue.com/images/icons/continue-symbol/black/icon48.png?v=a8c9387
|
225 | 225 | // @icon64 https://assets.chatgptautocontinue.com/images/icons/continue-symbol/black/icon64.png?v=a8c9387
|
|
232 | 232 | // @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@a3635a5/chromium/extension/components/modals.js#sha256-sm2ki3116WKOFQR/4LuXE6tNFUbQehbJjzYwQdm52HU=
|
233 | 233 | // @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@d4e4a20/chromium/extension/lib/browser.js#sha256-gzkpJ57Xp0CbWQuE4fBFL8DLf4OTsnRl3vfFDqg9fWs=
|
234 | 234 | // @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@df66b49/chromium/extension/lib/dom.js#sha256-kiKOn4x4hom5TRyrda7YqUNkq+s/JYgnFDQiWrR8ffk=
|
235 |
| -// @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@9070468/chromium/extension/lib/settings.js#sha256-rsHjP3SqLH9R5IeKBl+8+tebbSXt8nE6VjLLVbyy+Vo= |
| 235 | +// @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@5c8fb84/chromium/extension/lib/settings.js#sha256-Hv5/wY17fX6HKOFmuMewzBLhdV7NY/pqvQc6ZwtCg6s= |
| 236 | +// @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@5c8fb84/chromium/extension/lib/styles.js#sha256-qoU0eAkrQKRWxiOuIYIH/PiQC0wUCTb4h3OwipCtW9c= |
236 | 237 | // @require https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@78d7214/chromium/extension/lib/ui.js#sha256-2yuQbliwz+uaCxUIEeTMWIH5JADHgjDBZD4/8I2T8rE=
|
237 | 238 | // @resource rpgCSS https://cdn.jsdelivr.net/gh/adamlui/ai-web-extensions@727feff/assets/styles/rising-particles/dist/gray.min.css#sha256-48sEWzNUGUOP04ur52G5VOfGZPSnZQfrF3szUr4VaRs=
|
238 | 239 | // @resource rpwCSS https://cdn.jsdelivr.net/gh/adamlui/ai-web-extensions@727feff/assets/styles/rising-particles/dist/white.min.css#sha256-6xBXczm7yM1MZ/v0o1KVFfJGehHk47KJjq8oTktH4KE=
|
|
283 | 284 | // Init APP data
|
284 | 285 | window.app = {
|
285 | 286 | version: GM_info.script.version, chatgptjsVer: /chatgpt\.js@([\d.]+)/.exec(GM_info.scriptMetaStr)[1], urls: {},
|
286 |
| - latestResourceCommitHash: '47490a6' // for cached <app|messages>.json |
| 287 | + latestResourceCommitHash: '5c8fb84' // for cached <app|messages>.json |
287 | 288 | }
|
288 | 289 | app.urls.resourceHost = `https://cdn.jsdelivr.net/gh/adamlui/chatgpt-auto-continue@${app.latestResourceCommitHash}`
|
289 | 290 | const remoteAppData = await new Promise(resolve => xhr({
|
|
295 | 296 | appName: app.name,
|
296 | 297 | appAuthor: app.author.name,
|
297 | 298 | appDesc: 'Automatically continue generating multiple ChatGPT responses',
|
| 299 | + menuLabel_settings: 'Settings', |
| 300 | + menuLabel_notif: 'Notification', |
| 301 | + menuLabel_notifs: 'Notifications', |
298 | 302 | menuLabel_autoScroll: 'Auto-Scroll',
|
| 303 | + menuLabel_anchor: 'Anchor', |
299 | 304 | menuLabel_modeNotifs: 'Mode Notifications',
|
300 | 305 | menuLabel_about: 'About',
|
301 | 306 | menuLabel_donate: 'Please send a donation',
|
|
308 | 313 | about_openSourceCode: 'Open source code',
|
309 | 314 | about_latestChanges: 'Latest changes',
|
310 | 315 | mode_autoContinue: 'Auto-Continue',
|
| 316 | + mode_toast: 'Toast Mode', |
311 | 317 | helptip_autoScroll: 'Automatically scroll to bottom as replies are generating',
|
312 | 318 | helptip_modeNotifs: 'Show notifications when toggling modes/settings',
|
| 319 | + helptip_notifBottom: 'Anchor notifications to bottom of screen', |
| 320 | + helptip_toastMode: 'Shrink/center notifications into toast bubbles', |
313 | 321 | alert_updateAvail: 'Update available',
|
314 | 322 | alert_newerVer: 'An update to',
|
315 | 323 | alert_isAvail: 'is available',
|
|
447 | 455 | // Define FEEDBACK functions
|
448 | 456 |
|
449 | 457 | function notify(msg, pos = '', notifDuration = '', shadow = '') {
|
450 |
| - if (config.notifDisabled && !msg.includes(app.msgs.menuLabel_modeNotifs)) return |
| 458 | + if (!styles.toast.node) styles.toast.update() |
| 459 | + if (config.notifDisabled && !new RegExp(`${app.msgs.menuLabel_notifs}|${app.msgs.mode_toast}|🧩`).test(msg)) |
| 460 | + return |
451 | 461 |
|
452 | 462 | // Strip state word to append colored one later
|
453 | 463 | const foundState = toolbarMenu.state.words.find(word => msg.includes(word))
|
|
456 | 466 | // Show notification
|
457 | 467 | chatgpt.notify(`${app.symbol} ${msg}`, pos, notifDuration, shadow || env.ui.scheme == 'light')
|
458 | 468 | const notif = document.querySelector('.chatgpt-notif:last-child')
|
| 469 | + notif.classList.add(app.slug) // for styles.toast |
459 | 470 |
|
460 | 471 | // Append styled state word
|
461 | 472 | if (foundState) {
|
|
0 commit comments