@mudlet/mudlet-web 0.5.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (301) hide show
  1. package/README.md +1 -1
  2. package/dist-lib/analytics.d.ts +27 -0
  3. package/dist-lib/assets/fonts/Vera.woff2 +0 -0
  4. package/dist-lib/assets/fonts/VeraBI.woff2 +0 -0
  5. package/dist-lib/assets/fonts/VeraBd.woff2 +0 -0
  6. package/dist-lib/assets/fonts/VeraIt.woff2 +0 -0
  7. package/dist-lib/assets/mapParser.worker-DrVZ3wg_.js +9 -0
  8. package/dist-lib/backupImport-wt8r7JXI.js +233 -0
  9. package/dist-lib/branding.d.ts +111 -13
  10. package/dist-lib/db/sqliteClient.d.ts +195 -7
  11. package/dist-lib/hooks/useAutoReconnect.d.ts +61 -0
  12. package/dist-lib/hooks/useDocumentFullscreen.d.ts +23 -0
  13. package/dist-lib/hooks/useKeyboardShortcuts.d.ts +37 -0
  14. package/dist-lib/hooks/useRecordLastPlayed.d.ts +10 -0
  15. package/dist-lib/import/applyMudletProfile.d.ts +35 -9
  16. package/dist-lib/import/backupImport.d.ts +118 -0
  17. package/dist-lib/import/collectProfileExport.d.ts +33 -2
  18. package/dist-lib/import/defaultPackages.d.ts +57 -14
  19. package/dist-lib/import/defaults/CF-loader/CF-loader.mpackage +0 -0
  20. package/dist-lib/import/defaults/MedBootstrap/MedBootstrap.mpackage +0 -0
  21. package/dist-lib/import/defaults/deleteOldProfiles/deleteOldProfiles.mpackage +0 -0
  22. package/dist-lib/import/defaults/echo/echo.mpackage +0 -0
  23. package/dist-lib/import/defaults/enable-accessibility/enable-accessibility.mpackage +0 -0
  24. package/dist-lib/import/defaults/generic_mapper/generic_mapper.mpackage +0 -0
  25. package/dist-lib/import/defaults/gui-drop/gui-drop.mpackage +0 -0
  26. package/dist-lib/import/defaults/icesus-loader/icesus-loader.mpackage +0 -0
  27. package/dist-lib/import/defaults/mg-loader/mg-loader.mpackage +0 -0
  28. package/dist-lib/import/defaults/mudlet-base-ui/mudlet-base-ui.mpackage +0 -0
  29. package/dist-lib/import/defaults/mudlet-mapper.xml +1215 -389
  30. package/dist-lib/import/mudletControlChars.d.ts +14 -0
  31. package/dist-lib/import/mudletHost.d.ts +73 -10
  32. package/dist-lib/import/mudletLink.d.ts +53 -2
  33. package/dist-lib/import/mudletProfileExport.d.ts +38 -5
  34. package/dist-lib/import/mudletProfileImport.d.ts +110 -12
  35. package/dist-lib/import/mudletVariables.d.ts +4 -3
  36. package/dist-lib/import/mudletWriteback.d.ts +15 -1
  37. package/dist-lib/import/mudletXmlImport.d.ts +46 -0
  38. package/dist-lib/import/packageFonts.d.ts +33 -0
  39. package/dist-lib/import/packageInstaller.d.ts +111 -7
  40. package/dist-lib/import/qtProfileData.d.ts +10 -0
  41. package/dist-lib/import/remotePackageInstall.d.ts +23 -7
  42. package/dist-lib/import/zipEntries.d.ts +45 -0
  43. package/dist-lib/index.d.ts +7 -3
  44. package/dist-lib/index.js +50508 -29836
  45. package/dist-lib/logging/SessionLogger.d.ts +75 -15
  46. package/dist-lib/map/MapSelectionOverlay.d.ts +2 -2
  47. package/dist-lib/map/MapStore.d.ts +387 -60
  48. package/dist-lib/map/MudletHighlightOverlay.d.ts +2 -2
  49. package/dist-lib/map/{MudixMapReader.d.ts → MudletMapReader.d.ts} +2 -2
  50. package/dist-lib/map/areaGraph.d.ts +120 -0
  51. package/dist-lib/map/environmentKit.d.ts +36 -0
  52. package/dist-lib/map/labelPixmap.d.ts +90 -0
  53. package/dist-lib/map/mapImageExport.d.ts +36 -2
  54. package/dist-lib/map/mapStyle.d.ts +11 -0
  55. package/dist-lib/map/mapVersion.d.ts +66 -0
  56. package/dist-lib/map/pathfinding.d.ts +2 -2
  57. package/dist-lib/mud/CharLoginController.d.ts +230 -0
  58. package/dist-lib/mud/ItemIdSequence.d.ts +1 -1
  59. package/dist-lib/mud/MudSession.d.ts +279 -22
  60. package/dist-lib/mud/PatternEngine.d.ts +153 -14
  61. package/dist-lib/mud/aliases/AliasEngine.d.ts +55 -9
  62. package/dist-lib/mud/autoLogin.d.ts +59 -0
  63. package/dist-lib/mud/commandSplit.d.ts +9 -0
  64. package/dist-lib/mud/connection/LineAssembler.d.ts +38 -11
  65. package/dist-lib/mud/connection/MudClient.d.ts +291 -53
  66. package/dist-lib/mud/connection/SubnegotiationRepair.d.ts +24 -0
  67. package/dist-lib/mud/connection/TelnetNegotiator.d.ts +208 -68
  68. package/dist-lib/mud/connection/telnetDebug.d.ts +8 -8
  69. package/dist-lib/mud/events.d.ts +102 -23
  70. package/dist-lib/mud/games/bundledGames.d.ts +12 -7
  71. package/dist-lib/mud/games/gameLinks.d.ts +40 -0
  72. package/dist-lib/mud/games/icons/3Kingdoms.png +0 -0
  73. package/dist-lib/mud/games/icons/3Scapes.png +0 -0
  74. package/dist-lib/mud/games/icons/achaea.png +0 -0
  75. package/dist-lib/mud/games/icons/aetolia.png +0 -0
  76. package/dist-lib/mud/games/icons/banner_astaria.png +0 -0
  77. package/dist-lib/mud/games/icons/banner_darkmists.png +0 -0
  78. package/dist-lib/mud/games/icons/banner_dreamland.png +0 -0
  79. package/dist-lib/mud/games/icons/banner_petria.jpg +0 -0
  80. package/dist-lib/mud/games/icons/banner_ropmud.png +0 -0
  81. package/dist-lib/mud/games/icons/blackmud.png +0 -0
  82. package/dist-lib/mud/games/icons/carrionfields.png +0 -0
  83. package/dist-lib/mud/games/icons/dragonfire_icon.png +0 -0
  84. package/dist-lib/mud/games/icons/fed2-logo.png +0 -0
  85. package/dist-lib/mud/games/icons/icesus_480x120.png +0 -0
  86. package/dist-lib/mud/games/icons/imperian.png +0 -0
  87. package/dist-lib/mud/games/icons/infinity_480x120.png +0 -0
  88. package/dist-lib/mud/games/icons/lusternia.png +0 -0
  89. package/dist-lib/mud/games/icons/morgengrauen_480x120.png +0 -0
  90. package/dist-lib/mud/games/icons/mudlet-tutorial.png +0 -0
  91. package/dist-lib/mud/games/icons/phoenixmud_480x120.png +0 -0
  92. package/dist-lib/mud/games/icons/starmourn.png +0 -0
  93. package/dist-lib/mud/games/icons/voidmud_icon.png +0 -0
  94. package/dist-lib/mud/games/icons/wotmudicon.png +0 -0
  95. package/dist-lib/mud/games/websiteLinks.d.ts +21 -0
  96. package/dist-lib/mud/keybindings/KeyEngine.d.ts +110 -4
  97. package/dist-lib/mud/keybindings/browserReservedKeys.d.ts +2 -2
  98. package/dist-lib/mud/keybindings/keyEventTarget.d.ts +61 -0
  99. package/dist-lib/mud/keybindings/qtKeys.d.ts +91 -12
  100. package/dist-lib/mud/protocol/atcp.d.ts +19 -0
  101. package/dist-lib/mud/protocol/byteString.d.ts +24 -0
  102. package/dist-lib/mud/protocol/charLoginFlow.d.ts +243 -16
  103. package/dist-lib/mud/protocol/charset.d.ts +111 -46
  104. package/dist-lib/mud/protocol/codePages.d.ts +10 -0
  105. package/dist-lib/mud/protocol/constants.d.ts +17 -10
  106. package/dist-lib/mud/protocol/echo.d.ts +23 -27
  107. package/dist-lib/mud/protocol/gmcp.d.ts +36 -6
  108. package/dist-lib/mud/protocol/index.d.ts +3 -2
  109. package/dist-lib/mud/protocol/luaLiteral.d.ts +12 -0
  110. package/dist-lib/mud/protocol/mccp.d.ts +83 -1
  111. package/dist-lib/mud/protocol/mnes.d.ts +41 -58
  112. package/dist-lib/mud/protocol/msdp.d.ts +11 -4
  113. package/dist-lib/mud/protocol/msp.d.ts +3 -2
  114. package/dist-lib/mud/protocol/mssp.d.ts +9 -4
  115. package/dist-lib/mud/protocol/multiByte.d.ts +51 -0
  116. package/dist-lib/mud/protocol/multiByteEncode.d.ts +42 -0
  117. package/dist-lib/mud/protocol/mxp.d.ts +193 -14
  118. package/dist-lib/mud/protocol/oauthClientFlow.d.ts +128 -0
  119. package/dist-lib/mud/protocol/qtCodePages.generated.d.ts +1 -0
  120. package/dist-lib/mud/protocol/tlsCodes.d.ts +40 -3
  121. package/dist-lib/mud/replay/ReplayPlayer.d.ts +16 -1
  122. package/dist-lib/mud/replay/replayFormat.d.ts +29 -2
  123. package/dist-lib/mud/text/Console.d.ts +255 -49
  124. package/dist-lib/mud/text/FormatState.d.ts +137 -14
  125. package/dist-lib/mud/text/ansiEscapes.d.ts +32 -16
  126. package/dist-lib/mud/text/colorParsers.d.ts +14 -2
  127. package/dist-lib/mud/text/colorSpaceId.d.ts +2 -0
  128. package/dist-lib/mud/text/colors.d.ts +17 -10
  129. package/dist-lib/mud/text/controlCharacterMode.d.ts +1 -1
  130. package/dist-lib/mud/text/hyperlinkVisibility.d.ts +1 -1
  131. package/dist-lib/mud/text/lineBreak.d.ts +5 -0
  132. package/dist-lib/mud/text/serverWrap.d.ts +2 -2
  133. package/dist-lib/mud/text/textAnalyzer.d.ts +79 -0
  134. package/dist-lib/mud/text/unicodeRuns.d.ts +11 -0
  135. package/dist-lib/mud/text/unicodeTables.generated.d.ts +3 -0
  136. package/dist-lib/mud/text/wcwidth.d.ts +27 -22
  137. package/dist-lib/mud/timers/TimerEngine.d.ts +163 -11
  138. package/dist-lib/mud/timers/workerClock.d.ts +67 -0
  139. package/dist-lib/mud/triggers/TriggerEngine.d.ts +449 -47
  140. package/dist-lib/mud/triggers/legacyColorPatterns.d.ts +58 -0
  141. package/dist-lib/mud/triggers/pcre/Pcre2.d.ts +83 -1
  142. package/dist-lib/oauth-callback.html +94 -0
  143. package/dist-lib/pcre2Wasm.d.ts +54 -0
  144. package/dist-lib/pcre2Wasm.js +241 -0
  145. package/dist-lib/scripting/EngineHost.d.ts +45 -21
  146. package/dist-lib/scripting/IScriptingRuntime.d.ts +103 -27
  147. package/dist-lib/scripting/MxpFrameManager.d.ts +10 -1
  148. package/dist-lib/scripting/ScriptingAPI.d.ts +1030 -213
  149. package/dist-lib/scripting/ScriptingEngine.d.ts +727 -106
  150. package/dist-lib/scripting/StopwatchManager.d.ts +97 -36
  151. package/dist-lib/scripting/http/HttpService.d.ts +9 -1
  152. package/dist-lib/scripting/http/userUrl.d.ts +41 -0
  153. package/dist-lib/scripting/lua/LuaRuntime.d.ts +352 -77
  154. package/dist-lib/scripting/lua/argContracts.d.ts +71 -0
  155. package/dist-lib/scripting/lua/bindings/automation.d.ts +1 -1
  156. package/dist-lib/scripting/lua/bindings/commands.d.ts +13 -0
  157. package/dist-lib/scripting/lua/bindings/context.d.ts +20 -2
  158. package/dist-lib/scripting/lua/bindings/diagnostics.d.ts +1 -1
  159. package/dist-lib/scripting/lua/bindings/map.d.ts +1 -1
  160. package/dist-lib/scripting/lua/bindings/media.d.ts +2 -2
  161. package/dist-lib/scripting/lua/bindings/output.d.ts +1 -1
  162. package/dist-lib/scripting/lua/bindings/session.d.ts +2 -2
  163. package/dist-lib/scripting/lua/bindings/textEdit.d.ts +1 -1
  164. package/dist-lib/scripting/lua/bindings/userWindows.d.ts +1 -1
  165. package/dist-lib/scripting/lua/byteArmor.d.ts +36 -0
  166. package/dist-lib/scripting/lua/imageSize.d.ts +7 -0
  167. package/dist-lib/scripting/lua/rex.d.ts +4 -2
  168. package/dist-lib/scripting/lua/sqlRowEncoder.d.ts +6 -1
  169. package/dist-lib/scripting/lua/utf8CaseMap.d.ts +1 -0
  170. package/dist-lib/scripting/lua/utf8Patterns.d.ts +21 -1
  171. package/dist-lib/scripting/lua/wellFormedStrings.d.ts +40 -0
  172. package/dist-lib/scripting/lua/yajl.d.ts +43 -5
  173. package/dist-lib/scripting/profilesPresence.d.ts +20 -2
  174. package/dist-lib/scripting/vfs/ProfileVFS.d.ts +164 -10
  175. package/dist-lib/scripting/vfs/fsErrors.d.ts +28 -0
  176. package/dist-lib/scripting/vfs/idbCommit.d.ts +20 -0
  177. package/dist-lib/storage/appStore.d.ts +24 -9
  178. package/dist-lib/storage/hooks.d.ts +5 -1
  179. package/dist-lib/storage/index.d.ts +2 -2
  180. package/dist-lib/storage/mapStorage.d.ts +2 -0
  181. package/dist-lib/storage/persistentStorage.d.ts +3 -1
  182. package/dist-lib/storage/profileStorage.d.ts +15 -0
  183. package/dist-lib/storage/profileVfsData.d.ts +3 -3
  184. package/dist-lib/storage/schema.d.ts +512 -40
  185. package/dist-lib/storage/storageMigration.d.ts +82 -0
  186. package/dist-lib/storage-g5V1b-c1.js +2039 -0
  187. package/dist-lib/styles.css +1 -1
  188. package/dist-lib/ui/AboutModal.d.ts +1 -1
  189. package/dist-lib/ui/BrandLoginFields.d.ts +1 -1
  190. package/dist-lib/ui/BrowserSignInModal.d.ts +23 -0
  191. package/dist-lib/ui/CmdLineMenuRegistry.d.ts +14 -5
  192. package/dist-lib/ui/CommandBar.d.ts +8 -8
  193. package/dist-lib/ui/ConnectionFormModal.d.ts +20 -1
  194. package/dist-lib/ui/ConnectionScreen.d.ts +9 -1
  195. package/dist-lib/ui/GameLinkPrompt.d.ts +28 -0
  196. package/dist-lib/ui/HelpModal.d.ts +5 -1
  197. package/dist-lib/ui/MapSymbolUsageModal.d.ts +32 -0
  198. package/dist-lib/ui/MouseEventRegistry.d.ts +31 -4
  199. package/dist-lib/ui/NotepadModal.d.ts +22 -0
  200. package/dist-lib/ui/ResizableModal.d.ts +16 -1
  201. package/dist-lib/ui/SettingsModal.d.ts +10 -1
  202. package/dist-lib/ui/TlsAlertBanner.d.ts +3 -1
  203. package/dist-lib/ui/Toolbar.d.ts +22 -1
  204. package/dist-lib/ui/VaultManageButton.d.ts +10 -5
  205. package/dist-lib/ui/VaultModal.d.ts +3 -0
  206. package/dist-lib/ui/buttons/ButtonsBar.d.ts +3 -1
  207. package/dist-lib/ui/buttons/inactiveButtons.d.ts +25 -0
  208. package/dist-lib/ui/cmdline/CommandLineManager.d.ts +19 -0
  209. package/dist-lib/ui/cmdline/plainText.d.ts +16 -0
  210. package/dist-lib/ui/cmdline/subCommandLine.d.ts +78 -0
  211. package/dist-lib/ui/cmdline/useCmdLineSelection.d.ts +26 -0
  212. package/dist-lib/ui/cmdline/useSubCommandLineKeys.d.ts +33 -0
  213. package/dist-lib/ui/codemirror/lineParagraphMarks.d.ts +19 -0
  214. package/dist-lib/ui/codemirror/luaHover.d.ts +7 -0
  215. package/dist-lib/ui/codemirror/options.d.ts +33 -0
  216. package/dist-lib/ui/codemirror/theme.d.ts +29 -5
  217. package/dist-lib/ui/commands/addonCommands.d.ts +134 -0
  218. package/dist-lib/ui/commands/appShortcuts.d.ts +86 -0
  219. package/dist-lib/ui/commands/hostCommands.d.ts +88 -0
  220. package/dist-lib/ui/commands/keyMatch.d.ts +20 -0
  221. package/dist-lib/ui/commands/keySequence.d.ts +57 -0
  222. package/dist-lib/ui/components/ContextMenu.d.ts +21 -1
  223. package/dist-lib/ui/components/FontPicker.d.ts +5 -1
  224. package/dist-lib/ui/components/useModalFocus.d.ts +13 -1
  225. package/dist-lib/ui/helpTopics.d.ts +15 -0
  226. package/dist-lib/ui/labels/LabelManager.d.ts +172 -9
  227. package/dist-lib/ui/labels/LabelOverlay.d.ts +19 -0
  228. package/dist-lib/ui/labels/backgroundImageSize.d.ts +19 -0
  229. package/dist-lib/ui/labels/labelModel.d.ts +64 -0
  230. package/dist-lib/ui/labels/qColor.d.ts +13 -0
  231. package/dist-lib/ui/labels/qtCss.d.ts +12 -4
  232. package/dist-lib/ui/landmarks.d.ts +9 -0
  233. package/dist-lib/ui/launcher/ActionMenu.d.ts +19 -0
  234. package/dist-lib/ui/launcher/GameDetails.d.ts +21 -0
  235. package/dist-lib/ui/launcher/GameSection.d.ts +18 -0
  236. package/dist-lib/ui/launcher/LauncherSearch.d.ts +23 -0
  237. package/dist-lib/ui/launcher/ProfileArt.d.ts +20 -0
  238. package/dist-lib/ui/launcher/ProfileSection.d.ts +43 -0
  239. package/dist-lib/ui/launcher/launcherModel.d.ts +72 -0
  240. package/dist-lib/ui/layout/overlayLayerOrder.d.ts +2 -2
  241. package/dist-lib/ui/menu/MenuBar.d.ts +31 -0
  242. package/dist-lib/ui/menu/SplitButton.d.ts +39 -0
  243. package/dist-lib/ui/menu/anchoredPopup.d.ts +74 -0
  244. package/dist-lib/ui/menu/appMenus.d.ts +65 -0
  245. package/dist-lib/ui/menu/menuModel.d.ts +88 -0
  246. package/dist-lib/ui/menu/toolbarModel.d.ts +56 -0
  247. package/dist-lib/ui/notepad.d.ts +76 -0
  248. package/dist-lib/ui/openSignInPage.d.ts +14 -0
  249. package/dist-lib/ui/output/OutputContextMenu.d.ts +14 -1
  250. package/dist-lib/ui/output/OutputRenderer.d.ts +5 -0
  251. package/dist-lib/ui/output/OutputSearchBar.d.ts +5 -1
  252. package/dist-lib/ui/output/StickyOutputPanel.d.ts +17 -3
  253. package/dist-lib/ui/output/TextAnalyzerModal.d.ts +25 -0
  254. package/dist-lib/ui/output/caretMode.d.ts +3 -2
  255. package/dist-lib/ui/output/clearSplit.d.ts +11 -0
  256. package/dist-lib/ui/output/outputCopy.d.ts +41 -2
  257. package/dist-lib/ui/output/outputRows.d.ts +43 -0
  258. package/dist-lib/ui/output/selectionGesture.d.ts +35 -0
  259. package/dist-lib/ui/output/wordSelection.d.ts +33 -0
  260. package/dist-lib/ui/search/matcher.d.ts +14 -4
  261. package/dist-lib/ui/settings/SettingsShell.d.ts +91 -0
  262. package/dist-lib/ui/settings/ShortcutEditor.d.ts +13 -0
  263. package/dist-lib/ui/sound/SoundManager.d.ts +210 -44
  264. package/dist-lib/ui/sound/closedCaption.d.ts +4 -1
  265. package/dist-lib/ui/sound/mediaDirection.d.ts +35 -0
  266. package/dist-lib/ui/tabCompletion.d.ts +53 -0
  267. package/dist-lib/ui/textedit/TextEditManager.d.ts +11 -2
  268. package/dist-lib/ui/useOpenProfiles.d.ts +1 -1
  269. package/dist-lib/ui/video/VideoManager.d.ts +7 -0
  270. package/dist-lib/ui/windows/WindowManager.d.ts +452 -37
  271. package/dist-lib/ui/windows/panels/ScriptEditorPanel.d.ts +14 -0
  272. package/dist-lib/ui/windows/panels/ScriptSearch.d.ts +6 -1
  273. package/dist-lib/ui/windows/panels/TextPanel.d.ts +4 -1
  274. package/dist-lib/ui/windows/panels/VariablesView.d.ts +37 -7
  275. package/dist-lib/ui/windows/panels/WindowCmdLine.d.ts +4 -2
  276. package/dist-lib/ui/windows/panels/aliasLoop.d.ts +24 -0
  277. package/dist-lib/ui/windows/panels/editorClipboard.d.ts +45 -0
  278. package/dist-lib/ui/windows/panels/editorUndo.d.ts +79 -0
  279. package/dist-lib/ui/windows/panels/mapAreaChange.d.ts +10 -0
  280. package/dist-lib/utils/appShellCache.d.ts +25 -0
  281. package/dist-lib/utils/fontFamilyName.d.ts +13 -0
  282. package/dist-lib/utils/fontLoader.d.ts +31 -0
  283. package/dist-lib/utils/formatBytes.d.ts +4 -0
  284. package/dist-lib/utils/mustBeOneOf.d.ts +9 -0
  285. package/dist-lib/utils/profileLock.d.ts +1 -1
  286. package/dist-lib/utils/systemTheme.d.ts +24 -0
  287. package/dist-lib/utils/timeZone.d.ts +10 -0
  288. package/dist-lib/vault/CredentialVault.d.ts +51 -5
  289. package/dist-lib/vault/deviceUnlock.d.ts +47 -0
  290. package/dist-lib/vault/vaultAccess.d.ts +24 -2
  291. package/dist-lib/vault/vaultHelpTopic.d.ts +9 -0
  292. package/dist-lib/vault/vaultRecord.d.ts +33 -1
  293. package/dist-lib/vfs-sw.js +220 -11
  294. package/dist-lib/vite.d.ts +1 -1
  295. package/dist-lib/vite.js +66 -43
  296. package/package.json +23 -15
  297. package/dist-lib/assets/mapParser.worker-t-3rd1zR.js +0 -9
  298. package/dist-lib/mud/connection/PingTracker.d.ts +0 -41
  299. package/dist-lib/ui/BundledGameGrid.d.ts +0 -21
  300. package/dist-lib/ui/ConnectionGrid.d.ts +0 -21
  301. package/dist-lib/ui/bufferWords.d.ts +0 -38
@@ -12,24 +12,103 @@ export declare const QT_KEY_UNKNOWN = 33554431;
12
12
  * numpad keys from the main keyboard while Qt::Key alone does not.
13
13
  */
14
14
  export declare function qtKeyToDomCode(key: string | number, modifier?: number): string;
15
+ /** Qt::KeyboardModifier bits. */
16
+ export declare const QT_SHIFT_MODIFIER = 33554432;
17
+ export declare const QT_CONTROL_MODIFIER = 67108864;
18
+ export declare const QT_ALT_MODIFIER = 134217728;
19
+ export declare const QT_META_MODIFIER = 268435456;
15
20
  /**
16
21
  * Translate a Qt::KeyboardModifier bitmask into an array of modifier names
17
- * that match the {ctrl,shift,alt,meta} strings KeyEngine compares against.
22
+ * that match the {ctrl,shift,alt,meta,keypad} strings KeyEngine compares
23
+ * against.
18
24
  *
19
- * Qt::ShiftModifier = 0x02000000
20
- * Qt::ControlModifier = 0x04000000
21
- * Qt::AltModifier = 0x08000000
22
- * Qt::MetaModifier = 0x10000000
23
- * Qt::KeypadModifier = 0x20000000 (ignored — DOM `code` already encodes "Numpad*")
24
- * Qt::GroupSwitchMod. = 0x40000000 (ignored — X11-only)
25
+ * Qt::KeypadModifier is kept as `keypad`: desktop's key matcher compares the
26
+ * whole mask, so a binding on Keypad+Up (numpad 8 with NumLock off) is a
27
+ * different key from the arrow, and `ArrowUp` alone cannot say which one it
28
+ * is. A Numpad* DOM code says it by itself, so `keypad` is redundant there but
29
+ * harmless. Qt::GroupSwitchModifier (0x40000000, X11-only) is ignored.
25
30
  */
26
31
  export declare function qtModifiersToList(modifier: number): string[];
27
- /** Inverse of qtModifiersToList — {ctrl,shift,alt,meta} names → Qt bitmask. */
32
+ /** Inverse of qtModifiersToList — {ctrl,shift,alt,meta,keypad} names → Qt bitmask. */
28
33
  export declare function listToQtModifiers(modifiers: string[]): number;
34
+ /** Whether a stored binding is on the numpad: flagged `keypad`, or on a
35
+ * Numpad* DOM code (which only the numpad reports). */
36
+ export declare function isKeypadBinding(key: string, modifiers: readonly string[]): boolean;
37
+ /** A stored binding's Qt modifier mask, as desktop's getKeyCode and XML would
38
+ * carry it — the Keypad bit included for a Numpad* code (Key_Enter too: Qt
39
+ * reports the numpad Enter as Key_Enter with KeypadModifier). */
40
+ export declare function bindingQtModifiers(key: string, modifiers: string[]): number;
29
41
  /**
30
- * Inverse of qtKeyToDomCode for the common case — a DOM `KeyboardEvent.code`
31
- * back to a Qt::Key integer. Used by getKeyCode() to report a permanent key
32
- * binding (stored as a DOM code) in Mudlet's Qt terms. Returns undefined for a
33
- * code with no Qt mapping.
42
+ * Whether a Qt::Key is a printable character — the ASCII and Latin-1 ranges,
43
+ * where Qt::Key IS the (upper-cased) character the press produced. Qt reports
44
+ * the character, not the key's position: Shift+1 is Key_Exclam on a US layout,
45
+ * while on French AZERTY the same key gives Key_Ampersand plain and Key_1 with
46
+ * Shift, and its A key (US Q) is Key_A. So a binding on one of these is matched
47
+ * by the character the browser says was typed, never by the US position its
48
+ * DOM code names.
49
+ */
50
+ export declare function isPrintableQtKey(key: number | undefined): key is number;
51
+ /**
52
+ * The printable Qt::Key a press produced, from `KeyboardEvent.key` — upper-cased
53
+ * as Qt does (Key_A for `a`, Key_Eacute 0xC9 for `é`). Undefined when the press
54
+ * named no single printable character (`Dead`, `Unidentified`, a named key, or a
55
+ * script beyond Latin-1), in which case its position is all there is to go on.
56
+ */
57
+ export declare function printableEventQtKey(e: Pick<KeyboardEvent, 'key' | 'altKey'>): number | undefined;
58
+ /** Whether this browser runs on macOS, where Qt sets KeypadModifier on the
59
+ * arrow keys (they count as part of the keypad there, per Qt's docs), and
60
+ * takes the key from the character typed *without* Option. */
61
+ export declare function isMacPlatform(): boolean;
62
+ /**
63
+ * Whether Qt would report this press with KeypadModifier: every numpad key,
64
+ * and on macOS the arrow keys too. A binding desktop recorded on a Mac for
65
+ * Alt+Up carries the Keypad bit, and matching it against the arrows (as desktop
66
+ * on a Mac does) needs this; elsewhere the arrows are not the keypad.
67
+ */
68
+ export declare function isQtKeypadEvent(e: Pick<KeyboardEvent, 'code' | 'location'>): boolean;
69
+ /** Whether a press is a numpad key, whatever NumLock makes of it. */
70
+ export declare function isKeypadEvent(e: Pick<KeyboardEvent, 'code' | 'location'>): boolean;
71
+ /**
72
+ * The Qt::Key desktop would get for a numpad press. Unlike `code`, which is
73
+ * `Numpad8` whatever NumLock says, Qt reports what the key produced: Key_8 with
74
+ * NumLock on, Key_Up with it off — which is how a NumLock-off walking binding
75
+ * and a NumLock-on digit binding stay apart. Falls back to the code when the
76
+ * browser gives no usable `key`.
77
+ */
78
+ export declare function keypadEventQtKey(e: Pick<KeyboardEvent, 'code' | 'key'>): number | undefined;
79
+ /**
80
+ * The Qt::Key desktop would record for a press, for the key recorder: the
81
+ * character it produced in the printable range (`!` for Shift+1 on a US
82
+ * layout, `&` for the same key on AZERTY, upper case for letters, as Qt::Key_A
83
+ * is), the numpad's NumLock-dependent key, and
84
+ * otherwise the code's own key.
85
+ */
86
+ export declare function eventQtKey(e: Pick<KeyboardEvent, 'code' | 'key' | 'location' | 'altKey'>): number | undefined;
87
+ /**
88
+ * A press as the key + modifiers a binding stores. A numpad key with NumLock
89
+ * off is stored under the key it produced (`ArrowUp`) and flagged `keypad`, so
90
+ * it records the same Key_Up|Keypad desktop's recorder would.
91
+ */
92
+ export declare function bindingFromEvent(e: KeyboardEvent): {
93
+ key: string;
94
+ modifiers: string[];
95
+ qtKey?: number;
96
+ };
97
+ /**
98
+ * Inverse of qtKeyToDomCode — a DOM `KeyboardEvent.code` back to a Qt::Key
99
+ * integer. Used by getKeyCode() to report a permanent key binding (stored as a
100
+ * DOM code) in Mudlet's Qt terms, and by the Mudlet XML export to write a key
101
+ * item's `<keyCode>`. Numpad codes return the shared main-keyboard Qt::Key; the
102
+ * keypad flag lives in the modifier. Returns undefined for a code with no Qt
103
+ * mapping.
34
104
  */
35
105
  export declare function domCodeToQtKey(code: string): number | undefined;
106
+ /** Every key name a Qt key sequence can spell out — what a shortcut parser has
107
+ * to recognise as the key half of a step. */
108
+ export declare const QT_KEY_NAMES: ReadonlySet<string>;
109
+ /**
110
+ * One key of a Qt key sequence ("F9", "Left", ",", "k") as the DOM
111
+ * `KeyboardEvent.code` a key binding stores it under. Null when the name is not
112
+ * a key Qt would read, or names one the browser cannot report.
113
+ */
114
+ export declare function keyNameToDomCode(name: string): string | null;
@@ -0,0 +1,19 @@
1
+ /** One inbound ATCP (telnet option 200) message as desktop files it: `name`
2
+ * keys the Lua `atcp` table and names the event, `value` is what both carry. */
3
+ export interface AtcpMessage {
4
+ name: string;
5
+ value: string;
6
+ }
7
+ /** Split a decoded ATCP subnegotiation body the way Mudlet's
8
+ * `cTelnet::setATCPVariables` does. A body with a line feed is split at the
9
+ * first one, anything else at the first space; the dots come out of the name
10
+ * (`Char.Vitals` → `CharVitals`) and the line feeds out of the value; and when
11
+ * the first line held more than the name, the rest of it leads the value,
12
+ * space-separated — so `Char.Vitals H:1 M:2\nNL:3` files `"H:1 M:2 NL:3"`
13
+ * under `CharVitals`. Desktop removes every dot from that whole first line
14
+ * before splitting it, value half included, and so does this.
15
+ *
16
+ * Null for `Client.Compose`, which desktop hands to its composer window and
17
+ * never puts in the table or raises. There is no composer here (the hello
18
+ * doesn't offer `composer 1`), so it is dropped. */
19
+ export declare function parseAtcpMessage(text: string): AtcpMessage | null;
@@ -31,3 +31,27 @@ export declare const toByteString: (s: string) => string;
31
31
  * post-decode text — where every malformed sequence has already collapsed to
32
32
  * an indistinguishable U+FFFD. Truncated: the head is where the fault is. */
33
33
  export declare const toHex: (s: string) => string;
34
+ /** Decode a byte-string as UTF-8 the way Mudlet's `TBuffer::processUtf8Sequence`
35
+ * does, for text that reaches the buffer without cTelnet in front of it
36
+ * (`feedTriggers` under UTF-8 hands its bytes straight to the buffer). It
37
+ * differs from the WHATWG decoder in how much a bad sequence eats: the lead
38
+ * byte declares a length, and a malformed sequence — bad continuation,
39
+ * overlong, surrogate, past U+10FFFF, 5/6-byte — becomes ONE replacement mark
40
+ * spanning all of it, where WHATWG re-reads the offending byte as the start of
41
+ * something new. That is what makes a carriage return after a truncated lead
42
+ * byte part of the rejected sequence instead of a line ending. A UTF-8 BOM
43
+ * arrives as U+FEFF rather than vanishing. A sequence cut short by the end of
44
+ * the input keeps the lenient decoder's answer, as before. */
45
+ export declare const decodeUtf8AsTBuffer: (s: string) => string;
46
+ /** TBuffer's rule for a socket's bytes, as desktop has had it since Mudlet PR
47
+ * #11068: a malformed sequence is still ONE replacement mark — the browser's
48
+ * decoder gives one per byte of an overlong form or a surrogate — but a byte
49
+ * that cannot continue a sequence is not swallowed by it: the bytes before
50
+ * it earn the mark and it is read in its own right, so a line ending, an
51
+ * escape or a letter after a truncated sequence survives. A sequence the
52
+ * end of `s` cuts short is handed back as `pending` to be prefixed to the
53
+ * next frame — unless `final` (a prompt ends there), where it earns its mark. */
54
+ export declare const decodeUtf8Stream: (s: string, final: boolean) => {
55
+ text: string;
56
+ pending: string;
57
+ };
@@ -3,18 +3,154 @@
3
3
  *
4
4
  * The server sends `Char.Login.Default` to ask for credentials and then waits,
5
5
  * withholding its text login prompt until the client answers. Answering is
6
- * therefore mandatory — every path here ends in either a credentials reply or a
7
- * popup that will produce one. `Char.Login.Result` reports the outcome, and a
8
- * server that rejects an attempt commonly re-sends `Char.Login.Default` to ask
9
- * again, so these rules run repeatedly within one connection.
6
+ * therefore mandatory — every path here ends in a reply (the hand-off when
7
+ * there is nothing to send), or a popup, vault unlock or browser sign-in that
8
+ * will produce one. `Char.Login.Result` reports the outcome, and a server that
9
+ * rejects an attempt commonly re-sends `Char.Login.Default` to ask again, so
10
+ * these rules run repeatedly within one connection.
10
11
  *
11
- * Mirrors Mudlet's `GMCPAuthenticator` (GMCPAuthenticator.cpp). Kept free of
12
- * React and session plumbing so the rules can be tested directly; the caller
13
- * supplies the per-connection state.
12
+ * Two protocol versions are in play, and they want different things from us:
13
+ *
14
+ * - **Version 1** is a password exchange. We autofill a saved login once, and
15
+ * raise `CharLoginModal` when the game rejects it, so the player can correct
16
+ * it. That is what every version 1 profile in the wild is talking to.
17
+ * - **Version 2** adds browser sign-in (Google, Discord, or the game's own
18
+ * account system) and password-less reconnect tokens. There the game owns the
19
+ * interactive sign-in screen and we automate *around* it — Mudlet's design is
20
+ * explicit that the client does not render a pop-up of its own — so on
21
+ * version 2 the modal never opens: we replay a token, resume a provider,
22
+ * autofill a stored pair, run the client-driven OAuth flow, or hand off.
23
+ *
24
+ * Mirrors Mudlet's `GMCPAuthenticator` (development branch,
25
+ * GMCPAuthenticator.{h,cpp}). Kept free of React and session plumbing so the
26
+ * rules can be tested directly; `CharLoginController` supplies the state.
27
+ */
28
+ /** The highest `Char.Login` version this client implements — what
29
+ * `Core.Supports.Set` advertises and the ceiling every negotiation is clamped
30
+ * to. */
31
+ export declare const CHAR_LOGIN_CLIENT_VERSION = 2;
32
+ /**
33
+ * Decode a field the standard declares boolean, in every form it permits: a
34
+ * JSON boolean, the strings `"true"`/`"false"`/`"1"`/`"0"` (case-insensitive,
35
+ * whitespace ignored), or the numbers 1/0. Several MUD drivers have no JSON
36
+ * boolean at all — LDMud's `json_serialize()` among them, and StickMUD sends
37
+ * `"true"` — which is why the string and number forms exist.
38
+ *
39
+ * Anything else is `undefined`, *not* false, so the caller applies that field's
40
+ * own default: the defaults here are true or "the transport the token arrived
41
+ * on", never a flat false, so collapsing the two would answer a
42
+ * security-bearing question wrong. Mudlet's `decodeWireBool`.
43
+ */
44
+ export declare function decodeWireBool(value: unknown): boolean | undefined;
45
+ /**
46
+ * Clamp the version a server reported in `Char.Login.Default` to what we
47
+ * implement: the negotiated version is `min(client, server)`.
48
+ *
49
+ * Absent, unreadable, fractional or non-positive all mean 1 — a version 1
50
+ * server sends no field at all. The string form is read too: a driver with no
51
+ * JSON number sends `"2"`, and read as a number that answered a version 2
52
+ * server as version 1 for the whole session. A value *above* what we implement
53
+ * is clamped down, not read as 1. Mirrors `saveSupportsSet`.
54
+ */
55
+ export declare function negotiateCharLoginVersion(reported: unknown): number;
56
+ /** The client-driven OAuth capability a version 2 server advertises when it is
57
+ * itself an OpenID Provider. */
58
+ export interface CharLoginOAuthCapability {
59
+ /** The OpenID Connect discovery document's URL (the `location` field). */
60
+ location: string;
61
+ clientId: string;
62
+ /** Requested scopes; the flow defaults an empty list to `["openid"]`. */
63
+ scopes: string[];
64
+ /** The authorization request must carry a `nonce` the server can check the
65
+ * ID token against. */
66
+ nonceRequired: boolean;
67
+ }
68
+ /** Everything `Char.Login.Default` told us, normalised. */
69
+ export interface CharLoginCapabilities {
70
+ /** Negotiated version — see {@link negotiateCharLoginVersion}. */
71
+ version: number;
72
+ /** The `type` list, malformed entries dropped. Empty when the server sent none. */
73
+ methods: string[];
74
+ /** Present only on an encrypted game-facing transport, and only when the
75
+ * server sent both `location` and `client_id`. */
76
+ oauth?: CharLoginOAuthCapability;
77
+ }
78
+ /**
79
+ * Read a `Char.Login.Default` payload into capabilities.
80
+ *
81
+ * `secureTransport` is whether the link to the *game* is encrypted, not "is the
82
+ * WebSocket wss:" — in proxy mode a `wss://` proxy URL only secures the
83
+ * browser↔proxy hop. The client-driven OAuth fields are read only when it is:
84
+ * the `Char.Login.AuthCode` that completes that flow carries the authorization
85
+ * code and the PKCE verifier together and must never travel in the clear, so on
86
+ * cleartext they are dropped and the sign-in silently uses the server-driven
87
+ * flow instead — Mudlet's `saveSupportsSet`.
88
+ *
89
+ * The standard's field is `nonce_required`. Mudlet read a plain `nonce` until
90
+ * Mudlet/Mudlet#10623; the old key is still honoured when the standard's is
91
+ * absent, so a server written against that keeps working.
92
+ */
93
+ export declare function parseCharLoginDefault(value: unknown, secureTransport: boolean): CharLoginCapabilities;
94
+ /** A validated `Char.Login.URL`. */
95
+ export interface CharLoginUrl {
96
+ url: string;
97
+ /** Lowercase provider id (`discord`, `google`, …) when the server named one. */
98
+ provider?: string;
99
+ }
100
+ /**
101
+ * Validate a `Char.Login.URL` payload.
102
+ *
103
+ * The address arrives unauthenticated over the wire, so only `http`/`https`
104
+ * survive — never `javascript:`, `file:`, `data:` or any other scheme handler,
105
+ * whether we would open it or merely render it as a link. Control characters
106
+ * are refused outright: the address is rendered into the console inside an
107
+ * OSC 8 sequence, where an ESC would close it early and let the game paint
108
+ * arbitrary ANSI through what is supposed to be one link. Returns null for
109
+ * anything unusable, including a missing or unparseable `url`.
110
+ */
111
+ export declare function parseCharLoginUrl(value: unknown): CharLoginUrl | null;
112
+ /** A parsed `Char.Login.Token`. */
113
+ export interface CharLoginToken {
114
+ account: string;
115
+ token: string;
116
+ /** Whether the token may only ever be replayed over an encrypted transport. */
117
+ secureOnly: boolean;
118
+ }
119
+ /**
120
+ * Read a `Char.Login.Token` payload. Null when the account or token is missing.
121
+ *
122
+ * `secure_only` absent — or in a form that is not a boolean at all — means the
123
+ * token inherits the transport it arrived on: one minted over TLS is
124
+ * encrypted-only, one minted in the clear may be replayed either way. A server
125
+ * that mints over TLS but accepts replays in the clear has to say so with an
126
+ * explicit false, so where a token has protection to lose, silence keeps it.
127
+ * Mudlet's `handleAuthToken`.
128
+ *
129
+ * Never logs the payload: it is a bearer secret.
130
+ */
131
+ export declare function parseCharLoginToken(value: unknown, secureTransport: boolean): CharLoginToken | null;
132
+ /** A parsed `Char.Login.Result`. */
133
+ export interface CharLoginResult {
134
+ success: boolean;
135
+ message?: string;
136
+ }
137
+ /**
138
+ * Read a `Char.Login.Result`. `success` decodes like every other declared
139
+ * boolean — reading only `true`/`"true"` made an integer 1 a failure, and a
140
+ * failed reconnect deletes a token the server had just accepted
141
+ * (Mudlet/Mudlet#10622). Absent or undecodable reads as failure.
14
142
  */
143
+ export declare function parseCharLoginResult(value: unknown): CharLoginResult;
15
144
  /** What to do about a `Char.Login.Default` request. */
16
145
  export type CharLoginAction =
17
- /** Reply with the empty `{}` form — "no credentials, use your next method". */
146
+ /**
147
+ * Hand the sign-in to the game: version 1's empty `{}` ("no credentials,
148
+ * use your next method" — the player's *Use text login*), or version 2's
149
+ * deliberate "run your own sign-in screen", which carries the common fields
150
+ * but no account. Mudlet sends it even when the profile has a stored
151
+ * password the game will not take, so a saved password never blocks the
152
+ * player from reaching a provider choice.
153
+ */
18
154
  {
19
155
  kind: 'decline';
20
156
  }
@@ -24,11 +160,49 @@ export type CharLoginAction =
24
160
  account: string;
25
161
  password: string;
26
162
  }
27
- /** Raise the credentials popup. */
163
+ /** Replay the saved password-less token — `Char.Login.Reconnect`. */
164
+ | {
165
+ kind: 'reconnect';
166
+ account: string;
167
+ token: string;
168
+ }
169
+ /**
170
+ * Ask the game to restart this provider's browser sign-in — the *resume*
171
+ * form of `Char.Login.Credentials`, `{account, provider}`. The absence of a
172
+ * password, not the presence of `provider`, makes it a resume.
173
+ */
174
+ | {
175
+ kind: 'resume';
176
+ account: string;
177
+ provider: string;
178
+ }
179
+ /** Run the client-driven OAuth flow (discovery, PKCE, redirect capture). */
180
+ | {
181
+ kind: 'oauth';
182
+ }
183
+ /** Raise the credentials popup. Version 1 only. */
28
184
  | {
29
185
  kind: 'prompt';
186
+ }
187
+ /**
188
+ * Ask to unlock the vault. `read`: it holds this profile's saved login or
189
+ * sign-in. `store`: it holds nothing for this profile yet, but only an open
190
+ * vault lets the game hand over a token to keep (`token_storage`).
191
+ */
192
+ | {
193
+ kind: 'unlock';
194
+ reason: 'read' | 'store';
30
195
  };
196
+ /** A saved sign-in as the decision sees it — the vault's `VaultSignIn`. */
197
+ export interface StoredSignInView {
198
+ account: string;
199
+ provider?: string;
200
+ token?: string;
201
+ secureOnly?: boolean;
202
+ }
31
203
  export interface CharLoginRequestState {
204
+ /** Negotiated `Char.Login` version. Absent reads as 1. */
205
+ version?: number;
32
206
  /** The `type` list from `Char.Login.Default`; empty when the server sent none. */
33
207
  methods: string[];
34
208
  /** The player chose "Use text login" earlier this connection. */
@@ -38,21 +212,69 @@ export interface CharLoginRequestState {
38
212
  /** Stored/in-memory credentials, if any. */
39
213
  account?: string;
40
214
  password?: string;
215
+ /** A saved password or sign-in exists but sits in a locked vault, so it
216
+ * can't be read yet. Mudlet Web only — desktop has no vault to unlock. */
217
+ credentialsLocked?: boolean;
218
+ /** A vault exists but is locked, and holds nothing for this profile — so
219
+ * the game would be told `token_storage: false`. False once the player
220
+ * said "Not now". Mudlet Web only. */
221
+ storageLocked?: boolean;
222
+ /** The saved version 2 sign-in, if the vault holds one and is open. */
223
+ signIn?: StoredSignInView;
224
+ /** Whether the link to the *game* is encrypted. */
225
+ secureTransport?: boolean;
226
+ /** A token was rejected earlier: read the store, but do not replay a token
227
+ * this once. Mudlet's `mReconnectRejected` latch. */
228
+ tokenRejected?: boolean;
229
+ /** A token has already been replayed this connection. */
230
+ reconnectAttempted?: boolean;
231
+ /** A provider resume has already been sent this connection. */
232
+ resumeAttempted?: boolean;
233
+ /** The client-driven OAuth flow can run: the server advertised it over an
234
+ * encrypted link, and it has not already been tried this connection. */
235
+ clientOAuthAvailable?: boolean;
41
236
  }
42
237
  /**
43
238
  * Decide how to answer a `Char.Login.Default`.
44
239
  *
45
- * The one automatic attempt per connection is the load-bearing rule: it makes a
46
- * saved login silent when it works, and guarantees that a *wrong* saved login
47
- * turns into a visible popup instead of a silent send-reject-send loop against
48
- * the server's repeated asks.
240
+ * Version 1's one automatic attempt per connection is the load-bearing rule: it
241
+ * makes a saved login silent when it works, and guarantees that a *wrong* saved
242
+ * login turns into a visible popup instead of a silent send-reject-send loop
243
+ * against the server's repeated asks.
49
244
  */
50
245
  export declare function decideCharLoginRequest(state: CharLoginRequestState): CharLoginAction;
51
246
  /**
52
- * The console line for a rejected login, in Mudlet's wording
53
- * (`GMCPAuthenticator::handleAuthResult`). Servers doing GMCP login usually send
54
- * no text of their own, so this is often the only trace of the failure.
247
+ * Whether a token would have been replayed but for the game-facing transport
248
+ * being in the clear — the one case worth telling the player about, since their
249
+ * saved sign-in silently stopped working and the reason is fixable. Answered by
250
+ * re-running the ladder with the gate lifted, so the two cannot drift apart.
55
251
  */
252
+ export declare function charLoginTokenRefusedForCleartext(state: CharLoginRequestState): boolean;
253
+ /** A provider id as a human-readable name. Unknown ids are capitalised rather
254
+ * than dropped. Empty for no provider. */
255
+ export declare function charLoginProviderName(provider?: string): string;
256
+ /** Offered with a `Char.Login.URL` or the client-driven flow's sign-in page. A
257
+ * browser blocks a tab opened outside a user gesture, so where Mudlet
258
+ * launches the system browser we always offer the link. */
259
+ /** Mudlet's `GMCPAuthenticator::announceBrowserHandoff` wording. No link: the
260
+ * sign-in dialog carries it, and a game-linked page is printed by the game. */
261
+ export declare function charLoginSignInLinkMessage(provider?: string): string;
262
+ export declare const CHAR_LOGIN_INVALID_URL_MESSAGE = "The game sent an invalid sign-in link; cannot continue.";
263
+ export declare const CHAR_LOGIN_INSECURE_RECONNECT_MESSAGE = "Not using your saved sign-in because this connection is not encrypted; please sign in again.";
264
+ export declare function charLoginResumeMessage(provider: string): string;
265
+ /** Shown once per sign-in attempt, on the first token that attempt saves. */
266
+ export declare const CHAR_LOGIN_TOKEN_SAVED_MESSAGE: string;
267
+ /** Mudlet Web only: the game can hand over a sign-in to keep, but there is no
268
+ * vault to keep it in, so it was told `token_storage: false`. The line ends
269
+ * in {@link CHAR_LOGIN_NO_VAULT_LINK}, a link that opens vault setup. */
270
+ export declare const CHAR_LOGIN_NO_VAULT_MESSAGE = "Want to stay signed in next time?";
271
+ export declare const CHAR_LOGIN_NO_VAULT_LINK = "Set up saved logins";
272
+ /** Vault setup, opened from that link, finished. */
273
+ export declare const CHAR_LOGIN_VAULT_READY_MESSAGE = "Saved logins are set up. The next time you sign in, it will be kept.";
274
+ export declare const CHAR_LOGIN_TOKEN_SAVE_FAILED_MESSAGE = "Could not save your sign-in for next time; you may need to sign in again.";
275
+ export declare const CHAR_LOGIN_TOKEN_EXPIRED_MESSAGE = "Your saved sign-in has expired; reconnecting so you can sign in again.";
276
+ export declare const CHAR_LOGIN_OAUTH_FAILED_MESSAGE = "The browser sign-in could not be completed; reconnect to try again.";
277
+ export declare const CHAR_LOGIN_AUTHCODE_INSECURE_MESSAGE = "Cannot complete the sign-in because the connection is not encrypted.";
56
278
  /**
57
279
  * The console line for credentials the game never answered at all: it closed the
58
280
  * connection instead of sending `Char.Login.Result`.
@@ -65,4 +287,9 @@ export declare function decideCharLoginRequest(state: CharLoginRequestState): Ch
65
287
  * line a mistyped password is indistinguishable from a network failure.
66
288
  */
67
289
  export declare const CHAR_LOGIN_SILENT_DROP_MESSAGE: string;
290
+ /**
291
+ * The console line for a rejected login, in Mudlet's wording
292
+ * (`GMCPAuthenticator::handleAuthResult`). Servers doing GMCP login usually send
293
+ * no text of their own, so this is often the only trace of the failure.
294
+ */
68
295
  export declare function charLoginFailureMessage(message?: string): string;