ShareShortcuts

What’s my Wordle Score?

Simple shortcut to calculate and share your average Wordle score

basilsharecuts
„What’s my Wordle Score?“ forken

Hast du auf Basis dieses Kurzbefehls etwas Neues erstellt? Teile ihn als Fork: Er wird zu deinem eigenen Kurzbefehl, den du selbst verwaltest, und beide Seiten verlinken aufeinander, damit basilsharecuts die Anerkennung erhält.

  1. 1Lade den Kurzbefehl und ändere ihn in der Kurzbefehle-App. Gib ihm einen eigenen Namen.
  2. 2Teile ihn in der Kurzbefehle-App und kopiere den iCloud-Link.
  3. 3Komm hierher zurück, füge den Link ein und beschreibe, was sich geändert hat, z. B. „Einen Schritt hinzugefügt, der Apple Intelligence nutzt, um den Text zu personalisieren.“
Downloads
42K
Gesichert
0
Aktionen
22
Kategorie
API
Version
1.2
Sprache
EN

Simple shortcut to calculate and share your average Wordle score. Losses are treated as 7 points. To use, share from the Wordle page in Safari. Enjoy!

NOTE: Allow Running Scripts must be ON for this shortcut to work: Settings -> Shortcuts -> Advanced -> Allow Running Scripts

Neue Funktionen

Version 1.2

Add comment about enabling Allow Running Scripts

Versionsverlauf
1.2 2. Apr 2022

Add comment about enabling Allow Running Scripts

1.1 1. Apr 2022

Fix copy to clipboard

1.0 1. Apr 2022

First release

Was er macht

22 Aktionen
  1. Get Webpage Detail
  2. Comment
    v1.02 - Simple shortcut to calculate and share your average Wordle score. Losses are treated as 7 points. To use, share from the Wordle page in Safari. Enjoy! NOTE: Allow Running Scripts must be ON for this shortcut to work: Settings -> Shortcuts ->…
  3. If
  4. Show Alert
    Not Wordle!
  5. Stop This Shortcut
  6. If
  7. Run JavaScript on Web Page
  8. Get Dictionary from Input
  9. Get Dictionary Value
  10. Get Dictionary Value
  11. Get Dictionary Value
  12. Get Dictionary Value
  13. Get Dictionary Value
  14. Get Dictionary Value
  15. Get Dictionary Value
  16. Calculate Expression
  17. Calculate Expression
  18. Round Number
  19. Text
  20. Copy to Clipboard
  21. Show Alert
    Congratulations Wordler!
  22. Stop This Shortcut

Als Code ansehen
Beta

Jede Aktion dieses Kurzbefehls als Cherri ausgeschrieben, eine Programmiersprache für Kurzbefehle. Ideal, um zu lernen, wie er funktioniert.

#include 'actions/web'
#define color green
#define glyph boxOutline

const PageURL = getWebPageDetail(ShortcutInput, "Page URL")
/*
v1.02 - Simple shortcut to calculate and share your average Wordle score. Losses are treated as 7 points. To use, share from the Wordle page in Safari. Enjoy!

NOTE: Allow Running Scripts must be ON for this shortcut to work: Settings -> Shortcuts -> Advanced -> Allow Running Scripts
*/

if PageURL != "https://www.nytimes.com/games/wordle/index.html" {
	alert("This is not Wordle!", "Not Wordle!")
	stop()
} else {
}
const JavaScriptResult = runJavaScriptOnWebpage("const statistics = JSON.parse(localStorage.getItem('nyt-wordle-statistics'));\n// Call completion to finish\ncompletion(statistics.guesses);")
const Dictionary = getDictionary(JavaScriptResult)
const numberOfOnes = Dictionary['1']
const numberOfTwos = Dictionary['2']
const numberOfThrees = Dictionary['3']
const numberOfFours = Dictionary['4']
const numberOfFives = Dictionary['5']
const numberOfSixes = Dictionary['6']
const numberOfSevens = Dictionary['fail']
const numberOfGames = numberOfOnes+numberOfTwos+numberOfThrees+numberOfFours+numberOfFives+numberOfSixes+numberOfSevens
const averageScore = ((numberOfOnes*1)+(numberOfTwos*2)+(numberOfThrees*3)+(numberOfFours*4)+(numberOfFives*5)+(numberOfSixes*6)+(numberOfSevens*7))/numberOfGames
const roundedAvgScore = ceil(averageScore, "Thousandths")
const Text = "🤓My Average Wordle score is {roundedAvgScore} What's yours? \n🟩🟩🟩🟩🟩"
setClipboard(Text)
alert("Your Average Wordle Score is {roundedAvgScore}! (copied to clipboard for easy sharing 🙃)", "Congratulations Wordler!")
stop()
In Cherri Playground öffnen Mit cherri 2.3.0 (GPL-2.0) dekompiliert. Eventuell sind kleine Korrekturen nötig, bevor es kompiliert wird.

Bewertungen und Rezensionen

Rezension schreiben
–
von 5
★★★★★
★★★★
★★★
★★
★
0 ratings

No reviews yet. Be the first to share what you think!

Werbung

Das gefällt dir vielleicht auch

Alle anzeigen
Werbung