terminfo.dev 2.0.0 → 2.1.0

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "terminfo.dev",
3
- "version": "2.0.0",
3
+ "version": "2.1.0",
4
4
  "description": "Test your terminal's feature support and contribute to terminfo.dev",
5
5
  "keywords": [
6
6
  "ansi",
package/src/index.ts CHANGED
@@ -215,7 +215,7 @@ program
215
215
  notes: data.notes,
216
216
  responses: data.responses,
217
217
  generated: new Date().toISOString(),
218
- cliVersion: "2.0.0",
218
+ cliVersion: "2.1.0",
219
219
  probeCount: ALL_PROBES.length,
220
220
  })
221
221
  if (url) {
@@ -1017,11 +1017,16 @@ const sixelRender: Probe = {
1017
1017
 
1018
1018
  const osc52Clipboard: Probe = {
1019
1019
  id: "extensions.osc52-clipboard",
1020
- name: "Clipboard query (OSC 52)",
1020
+ name: "Clipboard access (OSC 52)",
1021
1021
  async run() {
1022
- const match = await query("\x1b]52;c;?\x07", /\x1b\]52;([^\x07\x1b]+)[\x07\x1b]/, 1000)
1023
- if (!match) return { pass: false, note: "No OSC 52 response" }
1024
- return { pass: true, response: match[1] }
1022
+ // Write a small test value to clipboard, then verify terminal responds
1023
+ // Don't use "?" query it returns full clipboard as huge base64 that leaks into stdin
1024
+ const testData = btoa("terminfo-test")
1025
+ process.stdout.write(`\x1b]52;c;${testData}\x07`)
1026
+ // Verify terminal still responds after OSC 52 (didn't crash/ignore)
1027
+ const pos = await queryCursorPosition()
1028
+ if (!pos) return { pass: false, note: "No response after OSC 52" }
1029
+ return { pass: true }
1025
1030
  },
1026
1031
  }
1027
1032
 
@@ -1078,7 +1083,10 @@ const extTruecolor: Probe = {
1078
1083
  if (!pos) return { pass: false, note: "No cursor response" }
1079
1084
  return {
1080
1085
  pass: pos[1] === 2,
1081
- note: pos[1] === 2 ? undefined : `cursor at col ${pos[1]}, expected 2 (truecolor sequence may have been printed literally)`,
1086
+ note:
1087
+ pos[1] === 2
1088
+ ? undefined
1089
+ : `cursor at col ${pos[1]}, expected 2 (truecolor sequence may have been printed literally)`,
1082
1090
  }
1083
1091
  },
1084
1092
  }