MCPcopy Create free account
hub / github.com/ChinaGodMan/UserScripts / displayStatus

Function displayStatus

github-co-authors/github-co-authors.user.js:410–415  ·  view source on GitHub ↗
(msg, color = 'subtle')

Source from the content-addressed store, hash-verified

408 * @param {'subtle' | 'success' | 'danger'} color The status color to use.
409 */
410 const displayStatus = (msg, color = 'subtle') => {
411 clearTimeout(bannerTimeout)
412 banner.textContent = msg
413 banner.className = `color-fg-${color}`
414 bannerTimeout = setTimeout(() => (banner.textContent = ''), 5000)
415 }
416
417 const button = document.createElement('button')
418 button.textContent = 'Add co-authors'

Callers 1

createCoAuthorsUIFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected