@dimivelev/chimera 0.78.1 → 0.78.2
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/npm-shrinkwrap.json +2 -2
- package/package.json +1 -6
- package/node_modules/@anthropic-ai/sdk/CHANGELOG.md +0 -1677
- package/node_modules/@anthropic-ai/sdk/LICENSE +0 -8
- package/node_modules/@anthropic-ai/sdk/README.md +0 -674
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.d.mts +0 -3
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.d.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.js +0 -226
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.mjs +0 -223
- package/node_modules/@anthropic-ai/sdk/_vendor/partial-json-parser/parser.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/api-promise.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/api-promise.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/api-promise.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/api-promise.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/api-promise.js +0 -6
- package/node_modules/@anthropic-ai/sdk/api-promise.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/api-promise.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/api-promise.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/bin/cli +0 -53
- package/node_modules/@anthropic-ai/sdk/bin/migration-config.json +0 -7
- package/node_modules/@anthropic-ai/sdk/client.d.mts +0 -225
- package/node_modules/@anthropic-ai/sdk/client.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/client.d.ts +0 -225
- package/node_modules/@anthropic-ai/sdk/client.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/client.js +0 -536
- package/node_modules/@anthropic-ai/sdk/client.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/client.mjs +0 -531
- package/node_modules/@anthropic-ai/sdk/client.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/api-promise.d.mts +0 -49
- package/node_modules/@anthropic-ai/sdk/core/api-promise.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/api-promise.d.ts +0 -49
- package/node_modules/@anthropic-ai/sdk/core/api-promise.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/api-promise.js +0 -76
- package/node_modules/@anthropic-ai/sdk/core/api-promise.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/api-promise.mjs +0 -72
- package/node_modules/@anthropic-ai/sdk/core/api-promise.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/error.d.mts +0 -47
- package/node_modules/@anthropic-ai/sdk/core/error.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/error.d.ts +0 -47
- package/node_modules/@anthropic-ai/sdk/core/error.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/error.js +0 -114
- package/node_modules/@anthropic-ai/sdk/core/error.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/error.mjs +0 -98
- package/node_modules/@anthropic-ai/sdk/core/error.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/pagination.d.mts +0 -63
- package/node_modules/@anthropic-ai/sdk/core/pagination.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/pagination.d.ts +0 -63
- package/node_modules/@anthropic-ai/sdk/core/pagination.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/pagination.js +0 -123
- package/node_modules/@anthropic-ai/sdk/core/pagination.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/pagination.mjs +0 -117
- package/node_modules/@anthropic-ai/sdk/core/pagination.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/resource.d.mts +0 -6
- package/node_modules/@anthropic-ai/sdk/core/resource.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/resource.d.ts +0 -6
- package/node_modules/@anthropic-ai/sdk/core/resource.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/resource.js +0 -11
- package/node_modules/@anthropic-ai/sdk/core/resource.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/resource.mjs +0 -7
- package/node_modules/@anthropic-ai/sdk/core/resource.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/streaming.d.mts +0 -31
- package/node_modules/@anthropic-ai/sdk/core/streaming.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/streaming.d.ts +0 -31
- package/node_modules/@anthropic-ai/sdk/core/streaming.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/streaming.js +0 -282
- package/node_modules/@anthropic-ai/sdk/core/streaming.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/streaming.mjs +0 -277
- package/node_modules/@anthropic-ai/sdk/core/streaming.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/uploads.d.mts +0 -3
- package/node_modules/@anthropic-ai/sdk/core/uploads.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/uploads.d.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/core/uploads.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/uploads.js +0 -6
- package/node_modules/@anthropic-ai/sdk/core/uploads.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/core/uploads.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/core/uploads.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/error.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/error.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/error.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/error.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/error.js +0 -6
- package/node_modules/@anthropic-ai/sdk/error.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/error.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/error.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/index.d.mts +0 -7
- package/node_modules/@anthropic-ai/sdk/index.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/index.d.ts +0 -7
- package/node_modules/@anthropic-ai/sdk/index.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/index.js +0 -35
- package/node_modules/@anthropic-ai/sdk/index.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/index.mjs +0 -8
- package/node_modules/@anthropic-ai/sdk/index.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.d.mts +0 -73
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.d.ts +0 -73
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.js +0 -4
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/builtin-types.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/constants.d.mts +0 -5
- package/node_modules/@anthropic-ai/sdk/internal/constants.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/constants.d.ts +0 -5
- package/node_modules/@anthropic-ai/sdk/internal/constants.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/constants.js +0 -15
- package/node_modules/@anthropic-ai/sdk/internal/constants.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/constants.mjs +0 -12
- package/node_modules/@anthropic-ai/sdk/internal/constants.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.d.mts +0 -10
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.d.ts +0 -10
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.js +0 -39
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.mjs +0 -35
- package/node_modules/@anthropic-ai/sdk/internal/decoders/jsonl.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.d.mts +0 -17
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.d.ts +0 -17
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.js +0 -113
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.mjs +0 -108
- package/node_modules/@anthropic-ai/sdk/internal/decoders/line.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.d.mts +0 -15
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.d.ts +0 -15
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.js +0 -162
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.mjs +0 -157
- package/node_modules/@anthropic-ai/sdk/internal/detect-platform.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/errors.d.mts +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/errors.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/errors.d.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/errors.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/errors.js +0 -41
- package/node_modules/@anthropic-ai/sdk/internal/errors.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/errors.mjs +0 -36
- package/node_modules/@anthropic-ai/sdk/internal/errors.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/headers.d.mts +0 -22
- package/node_modules/@anthropic-ai/sdk/internal/headers.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/headers.d.ts +0 -22
- package/node_modules/@anthropic-ai/sdk/internal/headers.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/headers.js +0 -79
- package/node_modules/@anthropic-ai/sdk/internal/headers.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/headers.mjs +0 -74
- package/node_modules/@anthropic-ai/sdk/internal/headers.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/parse.d.mts +0 -17
- package/node_modules/@anthropic-ai/sdk/internal/parse.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/parse.d.ts +0 -17
- package/node_modules/@anthropic-ai/sdk/internal/parse.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/parse.js +0 -55
- package/node_modules/@anthropic-ai/sdk/internal/parse.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/parse.mjs +0 -51
- package/node_modules/@anthropic-ai/sdk/internal/parse.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/request-options.d.mts +0 -34
- package/node_modules/@anthropic-ai/sdk/internal/request-options.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/request-options.d.ts +0 -34
- package/node_modules/@anthropic-ai/sdk/internal/request-options.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/request-options.js +0 -14
- package/node_modules/@anthropic-ai/sdk/internal/request-options.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/request-options.mjs +0 -10
- package/node_modules/@anthropic-ai/sdk/internal/request-options.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/shim-types.d.mts +0 -28
- package/node_modules/@anthropic-ai/sdk/internal/shim-types.d.ts +0 -28
- package/node_modules/@anthropic-ai/sdk/internal/shims.d.mts +0 -20
- package/node_modules/@anthropic-ai/sdk/internal/shims.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/shims.d.ts +0 -20
- package/node_modules/@anthropic-ai/sdk/internal/shims.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/shims.js +0 -92
- package/node_modules/@anthropic-ai/sdk/internal/shims.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/shims.mjs +0 -85
- package/node_modules/@anthropic-ai/sdk/internal/shims.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.d.mts +0 -8
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.d.ts +0 -8
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.js +0 -38
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.mjs +0 -35
- package/node_modules/@anthropic-ai/sdk/internal/stream-utils.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/to-file.d.mts +0 -45
- package/node_modules/@anthropic-ai/sdk/internal/to-file.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/to-file.d.ts +0 -45
- package/node_modules/@anthropic-ai/sdk/internal/to-file.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/to-file.js +0 -96
- package/node_modules/@anthropic-ai/sdk/internal/to-file.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/to-file.mjs +0 -93
- package/node_modules/@anthropic-ai/sdk/internal/to-file.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/tslib.js +0 -81
- package/node_modules/@anthropic-ai/sdk/internal/tslib.mjs +0 -17
- package/node_modules/@anthropic-ai/sdk/internal/types.d.mts +0 -67
- package/node_modules/@anthropic-ai/sdk/internal/types.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/types.d.ts +0 -67
- package/node_modules/@anthropic-ai/sdk/internal/types.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/types.js +0 -4
- package/node_modules/@anthropic-ai/sdk/internal/types.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/types.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/types.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/uploads.d.mts +0 -42
- package/node_modules/@anthropic-ai/sdk/internal/uploads.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/uploads.d.ts +0 -42
- package/node_modules/@anthropic-ai/sdk/internal/uploads.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/uploads.js +0 -146
- package/node_modules/@anthropic-ai/sdk/internal/uploads.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/uploads.mjs +0 -136
- package/node_modules/@anthropic-ai/sdk/internal/uploads.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.d.mts +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.d.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.js +0 -38
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.mjs +0 -33
- package/node_modules/@anthropic-ai/sdk/internal/utils/base64.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.d.mts +0 -4
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.d.ts +0 -4
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.js +0 -31
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.mjs +0 -26
- package/node_modules/@anthropic-ai/sdk/internal/utils/bytes.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.d.mts +0 -9
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.d.ts +0 -9
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.js +0 -22
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.mjs +0 -18
- package/node_modules/@anthropic-ai/sdk/internal/utils/env.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.d.mts +0 -37
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.d.ts +0 -37
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.js +0 -86
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.mjs +0 -80
- package/node_modules/@anthropic-ai/sdk/internal/utils/log.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.d.mts +0 -15
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.d.ts +0 -15
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.js +0 -58
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.mjs +0 -53
- package/node_modules/@anthropic-ai/sdk/internal/utils/path.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.js +0 -7
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/internal/utils/sleep.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.d.mts +0 -5
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.d.ts +0 -5
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.js +0 -19
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.mjs +0 -15
- package/node_modules/@anthropic-ai/sdk/internal/utils/uuid.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.d.mts +0 -16
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.d.ts +0 -16
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.js +0 -109
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.mjs +0 -92
- package/node_modules/@anthropic-ai/sdk/internal/utils/values.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils.d.mts +0 -7
- package/node_modules/@anthropic-ai/sdk/internal/utils.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils.d.ts +0 -7
- package/node_modules/@anthropic-ai/sdk/internal/utils.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils.js +0 -11
- package/node_modules/@anthropic-ai/sdk/internal/utils.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/internal/utils.mjs +0 -8
- package/node_modules/@anthropic-ai/sdk/internal/utils.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.d.mts +0 -114
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.d.ts +0 -114
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.js +0 -553
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.mjs +0 -549
- package/node_modules/@anthropic-ai/sdk/lib/BetaMessageStream.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.d.mts +0 -114
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.d.ts +0 -114
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.js +0 -553
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.mjs +0 -549
- package/node_modules/@anthropic-ai/sdk/lib/MessageStream.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/package.json +0 -185
- package/node_modules/@anthropic-ai/sdk/pagination.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/pagination.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/pagination.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/pagination.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/pagination.js +0 -6
- package/node_modules/@anthropic-ai/sdk/pagination.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/pagination.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/pagination.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resource.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/resource.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resource.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/resource.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resource.js +0 -6
- package/node_modules/@anthropic-ai/sdk/resource.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resource.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/resource.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.d.mts +0 -61
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.d.ts +0 -61
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.js +0 -25
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.mjs +0 -20
- package/node_modules/@anthropic-ai/sdk/resources/beta/beta.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.d.mts +0 -151
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.d.ts +0 -151
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.js +0 -122
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.mjs +0 -118
- package/node_modules/@anthropic-ai/sdk/resources/beta/files.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.d.mts +0 -5
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.d.ts +0 -5
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.js +0 -13
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.mjs +0 -6
- package/node_modules/@anthropic-ai/sdk/resources/beta/index.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.d.mts +0 -343
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.d.ts +0 -343
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.js +0 -204
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.mjs +0 -200
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/batches.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.d.mts +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.d.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.js +0 -9
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.mjs +0 -4
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/index.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.d.mts +0 -1561
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.d.ts +0 -1561
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.js +0 -86
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.mjs +0 -81
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages/messages.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.js +0 -6
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/beta/messages.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.d.mts +0 -74
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.d.ts +0 -74
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.js +0 -60
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.mjs +0 -56
- package/node_modules/@anthropic-ai/sdk/resources/beta/models.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/beta.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/beta.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta.js +0 -6
- package/node_modules/@anthropic-ai/sdk/resources/beta.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/beta.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/beta.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/completions.d.mts +0 -183
- package/node_modules/@anthropic-ai/sdk/resources/completions.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/completions.d.ts +0 -183
- package/node_modules/@anthropic-ai/sdk/resources/completions.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/completions.js +0 -23
- package/node_modules/@anthropic-ai/sdk/resources/completions.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/completions.mjs +0 -19
- package/node_modules/@anthropic-ai/sdk/resources/completions.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/index.d.mts +0 -6
- package/node_modules/@anthropic-ai/sdk/resources/index.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/index.d.ts +0 -6
- package/node_modules/@anthropic-ai/sdk/resources/index.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/index.js +0 -15
- package/node_modules/@anthropic-ai/sdk/resources/index.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/index.mjs +0 -7
- package/node_modules/@anthropic-ai/sdk/resources/index.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.d.mts +0 -304
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.d.ts +0 -304
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.js +0 -153
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.mjs +0 -149
- package/node_modules/@anthropic-ai/sdk/resources/messages/batches.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.d.mts +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.d.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.js +0 -9
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.mjs +0 -4
- package/node_modules/@anthropic-ai/sdk/resources/messages/index.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.d.mts +0 -1264
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.d.ts +0 -1264
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.js +0 -72
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.mjs +0 -67
- package/node_modules/@anthropic-ai/sdk/resources/messages/messages.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/messages.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/messages.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages.js +0 -6
- package/node_modules/@anthropic-ai/sdk/resources/messages.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/messages.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/messages.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/models.d.mts +0 -59
- package/node_modules/@anthropic-ai/sdk/resources/models.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/models.d.ts +0 -59
- package/node_modules/@anthropic-ai/sdk/resources/models.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/models.js +0 -45
- package/node_modules/@anthropic-ai/sdk/resources/models.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/models.mjs +0 -41
- package/node_modules/@anthropic-ai/sdk/resources/models.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/shared.d.mts +0 -42
- package/node_modules/@anthropic-ai/sdk/resources/shared.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/shared.d.ts +0 -42
- package/node_modules/@anthropic-ai/sdk/resources/shared.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/shared.js +0 -4
- package/node_modules/@anthropic-ai/sdk/resources/shared.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/shared.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/shared.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/top-level.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/top-level.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/top-level.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources/top-level.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/top-level.js +0 -4
- package/node_modules/@anthropic-ai/sdk/resources/top-level.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources/top-level.mjs +0 -3
- package/node_modules/@anthropic-ai/sdk/resources/top-level.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/resources.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources.js +0 -5
- package/node_modules/@anthropic-ai/sdk/resources.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/resources.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/resources.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/src/_vendor/partial-json-parser/README.md +0 -3
- package/node_modules/@anthropic-ai/sdk/src/_vendor/partial-json-parser/parser.ts +0 -264
- package/node_modules/@anthropic-ai/sdk/src/api-promise.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/client.ts +0 -1070
- package/node_modules/@anthropic-ai/sdk/src/core/README.md +0 -3
- package/node_modules/@anthropic-ai/sdk/src/core/api-promise.ts +0 -101
- package/node_modules/@anthropic-ai/sdk/src/core/error.ts +0 -133
- package/node_modules/@anthropic-ai/sdk/src/core/pagination.ts +0 -201
- package/node_modules/@anthropic-ai/sdk/src/core/resource.ts +0 -11
- package/node_modules/@anthropic-ai/sdk/src/core/streaming.ts +0 -331
- package/node_modules/@anthropic-ai/sdk/src/core/uploads.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/error.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/index.ts +0 -23
- package/node_modules/@anthropic-ai/sdk/src/internal/README.md +0 -3
- package/node_modules/@anthropic-ai/sdk/src/internal/builtin-types.ts +0 -93
- package/node_modules/@anthropic-ai/sdk/src/internal/constants.ts +0 -12
- package/node_modules/@anthropic-ai/sdk/src/internal/decoders/jsonl.ts +0 -48
- package/node_modules/@anthropic-ai/sdk/src/internal/decoders/line.ts +0 -135
- package/node_modules/@anthropic-ai/sdk/src/internal/detect-platform.ts +0 -196
- package/node_modules/@anthropic-ai/sdk/src/internal/errors.ts +0 -33
- package/node_modules/@anthropic-ai/sdk/src/internal/headers.ts +0 -99
- package/node_modules/@anthropic-ai/sdk/src/internal/parse.ts +0 -84
- package/node_modules/@anthropic-ai/sdk/src/internal/request-options.ts +0 -39
- package/node_modules/@anthropic-ai/sdk/src/internal/shim-types.d.ts +0 -28
- package/node_modules/@anthropic-ai/sdk/src/internal/shims.ts +0 -107
- package/node_modules/@anthropic-ai/sdk/src/internal/stream-utils.ts +0 -32
- package/node_modules/@anthropic-ai/sdk/src/internal/to-file.ts +0 -159
- package/node_modules/@anthropic-ai/sdk/src/internal/types.ts +0 -92
- package/node_modules/@anthropic-ai/sdk/src/internal/uploads.ts +0 -193
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/base64.ts +0 -40
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/bytes.ts +0 -32
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/env.ts +0 -18
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/log.ts +0 -127
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/path.ts +0 -65
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/sleep.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/uuid.ts +0 -17
- package/node_modules/@anthropic-ai/sdk/src/internal/utils/values.ts +0 -102
- package/node_modules/@anthropic-ai/sdk/src/internal/utils.ts +0 -8
- package/node_modules/@anthropic-ai/sdk/src/lib/.keep +0 -4
- package/node_modules/@anthropic-ai/sdk/src/lib/BetaMessageStream.ts +0 -683
- package/node_modules/@anthropic-ai/sdk/src/lib/MessageStream.ts +0 -684
- package/node_modules/@anthropic-ai/sdk/src/pagination.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/resource.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/beta.ts +0 -380
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/files.ts +0 -258
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/index.ts +0 -148
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/messages/batches.ts +0 -502
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/messages/index.ts +0 -135
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/messages/messages.ts +0 -2249
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/messages.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/src/resources/beta/models.ts +0 -118
- package/node_modules/@anthropic-ai/sdk/src/resources/beta.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/src/resources/completions.ts +0 -231
- package/node_modules/@anthropic-ai/sdk/src/resources/index.ts +0 -121
- package/node_modules/@anthropic-ai/sdk/src/resources/messages/batches.ts +0 -396
- package/node_modules/@anthropic-ai/sdk/src/resources/messages/index.ts +0 -110
- package/node_modules/@anthropic-ai/sdk/src/resources/messages/messages.ts +0 -1783
- package/node_modules/@anthropic-ai/sdk/src/resources/messages.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/src/resources/models.ts +0 -103
- package/node_modules/@anthropic-ai/sdk/src/resources/shared.ts +0 -72
- package/node_modules/@anthropic-ai/sdk/src/resources/top-level.ts +0 -3
- package/node_modules/@anthropic-ai/sdk/src/resources.ts +0 -1
- package/node_modules/@anthropic-ai/sdk/src/streaming.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/tsconfig.json +0 -11
- package/node_modules/@anthropic-ai/sdk/src/uploads.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/src/version.ts +0 -1
- package/node_modules/@anthropic-ai/sdk/streaming.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/streaming.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/streaming.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/streaming.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/streaming.js +0 -6
- package/node_modules/@anthropic-ai/sdk/streaming.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/streaming.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/streaming.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/uploads.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/uploads.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/uploads.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/uploads.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/uploads.js +0 -6
- package/node_modules/@anthropic-ai/sdk/uploads.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/uploads.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/uploads.mjs.map +0 -1
- package/node_modules/@anthropic-ai/sdk/version.d.mts +0 -2
- package/node_modules/@anthropic-ai/sdk/version.d.mts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/version.d.ts +0 -2
- package/node_modules/@anthropic-ai/sdk/version.d.ts.map +0 -1
- package/node_modules/@anthropic-ai/sdk/version.js +0 -5
- package/node_modules/@anthropic-ai/sdk/version.js.map +0 -1
- package/node_modules/@anthropic-ai/sdk/version.mjs +0 -2
- package/node_modules/@anthropic-ai/sdk/version.mjs.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent-loop.d.ts +0 -24
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent-loop.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent-loop.js +0 -502
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent-loop.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent.d.ts +0 -118
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent.js +0 -402
- package/node_modules/@dimivelev/chimera-agent-core/dist/agent.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/agent-harness.d.ts +0 -95
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/agent-harness.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/agent-harness.js +0 -963
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/agent-harness.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/branch-summarization.d.ts +0 -53
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/branch-summarization.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/branch-summarization.js +0 -175
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/branch-summarization.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/compaction.d.ts +0 -95
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/compaction.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/compaction.js +0 -528
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/compaction.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/utils.d.ts +0 -25
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/utils.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/utils.js +0 -131
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/compaction/utils.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/env/nodejs.d.ts +0 -51
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/env/nodejs.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/env/nodejs.js +0 -486
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/env/nodejs.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/messages.d.ts +0 -51
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/messages.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/messages.js +0 -102
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/messages.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/prompt-templates.d.ts +0 -48
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/prompt-templates.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/prompt-templates.js +0 -230
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/prompt-templates.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-repo.d.ts +0 -26
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-repo.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-repo.js +0 -101
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-repo.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-storage.d.ts +0 -33
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-storage.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-storage.js +0 -231
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/jsonl-storage.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-repo.d.ts +0 -18
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-repo.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-repo.js +0 -42
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-repo.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-storage.d.ts +0 -25
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-storage.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-storage.js +0 -114
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/memory-storage.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/repo-utils.d.ts +0 -11
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/repo-utils.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/repo-utils.js +0 -39
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/repo-utils.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/session.d.ts +0 -33
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/session.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/session.js +0 -210
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/session.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/uuid.d.ts +0 -2
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/uuid.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/uuid.js +0 -50
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/session/uuid.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/skills.d.ts +0 -44
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/skills.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/skills.js +0 -311
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/skills.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/system-prompt.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/system-prompt.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/system-prompt.js +0 -30
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/system-prompt.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/types.d.ts +0 -615
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/types.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/types.js +0 -94
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/types.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/shell-output.d.ts +0 -14
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/shell-output.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/shell-output.js +0 -126
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/shell-output.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/truncate.d.ts +0 -70
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/truncate.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/truncate.js +0 -290
- package/node_modules/@dimivelev/chimera-agent-core/dist/harness/utils/truncate.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/index.d.ts +0 -20
- package/node_modules/@dimivelev/chimera-agent-core/dist/index.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/index.js +0 -25
- package/node_modules/@dimivelev/chimera-agent-core/dist/index.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/node.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-agent-core/dist/node.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/node.js +0 -3
- package/node_modules/@dimivelev/chimera-agent-core/dist/node.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/proxy.d.ts +0 -69
- package/node_modules/@dimivelev/chimera-agent-core/dist/proxy.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/proxy.js +0 -278
- package/node_modules/@dimivelev/chimera-agent-core/dist/proxy.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/types.d.ts +0 -393
- package/node_modules/@dimivelev/chimera-agent-core/dist/types.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/dist/types.js +0 -2
- package/node_modules/@dimivelev/chimera-agent-core/dist/types.js.map +0 -1
- package/node_modules/@dimivelev/chimera-agent-core/package.json +0 -60
- package/node_modules/@dimivelev/chimera-ai/dist/api-registry.d.ts +0 -20
- package/node_modules/@dimivelev/chimera-ai/dist/api-registry.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/api-registry.js +0 -44
- package/node_modules/@dimivelev/chimera-ai/dist/api-registry.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/bedrock-provider.d.ts +0 -5
- package/node_modules/@dimivelev/chimera-ai/dist/bedrock-provider.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/bedrock-provider.js +0 -6
- package/node_modules/@dimivelev/chimera-ai/dist/bedrock-provider.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/cli.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-ai/dist/cli.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/cli.js +0 -130
- package/node_modules/@dimivelev/chimera-ai/dist/cli.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/env-api-keys.d.ts +0 -18
- package/node_modules/@dimivelev/chimera-ai/dist/env-api-keys.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/env-api-keys.js +0 -178
- package/node_modules/@dimivelev/chimera-ai/dist/env-api-keys.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.d.ts +0 -10
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.generated.d.ts +0 -4
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.generated.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.generated.js +0 -6
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.generated.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.js +0 -23
- package/node_modules/@dimivelev/chimera-ai/dist/image-models.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/images-api-registry.d.ts +0 -14
- package/node_modules/@dimivelev/chimera-ai/dist/images-api-registry.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/images-api-registry.js +0 -22
- package/node_modules/@dimivelev/chimera-ai/dist/images-api-registry.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/images.d.ts +0 -4
- package/node_modules/@dimivelev/chimera-ai/dist/images.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/images.js +0 -14
- package/node_modules/@dimivelev/chimera-ai/dist/images.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/index.d.ts +0 -32
- package/node_modules/@dimivelev/chimera-ai/dist/index.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/index.js +0 -20
- package/node_modules/@dimivelev/chimera-ai/dist/index.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/models.d.ts +0 -18
- package/node_modules/@dimivelev/chimera-ai/dist/models.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/models.generated.d.ts +0 -14714
- package/node_modules/@dimivelev/chimera-ai/dist/models.generated.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/models.generated.js +0 -13379
- package/node_modules/@dimivelev/chimera-ai/dist/models.generated.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/models.js +0 -71
- package/node_modules/@dimivelev/chimera-ai/dist/models.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/oauth.d.ts +0 -2
- package/node_modules/@dimivelev/chimera-ai/dist/oauth.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/oauth.js +0 -2
- package/node_modules/@dimivelev/chimera-ai/dist/oauth.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/amazon-bedrock.d.ts +0 -38
- package/node_modules/@dimivelev/chimera-ai/dist/providers/amazon-bedrock.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/amazon-bedrock.js +0 -826
- package/node_modules/@dimivelev/chimera-ai/dist/providers/amazon-bedrock.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/anthropic.d.ts +0 -71
- package/node_modules/@dimivelev/chimera-ai/dist/providers/anthropic.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/anthropic.js +0 -959
- package/node_modules/@dimivelev/chimera-ai/dist/providers/anthropic.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/azure-openai-responses.d.ts +0 -15
- package/node_modules/@dimivelev/chimera-ai/dist/providers/azure-openai-responses.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/azure-openai-responses.js +0 -221
- package/node_modules/@dimivelev/chimera-ai/dist/providers/azure-openai-responses.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/cloudflare.d.ts +0 -13
- package/node_modules/@dimivelev/chimera-ai/dist/providers/cloudflare.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/cloudflare.js +0 -26
- package/node_modules/@dimivelev/chimera-ai/dist/providers/cloudflare.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/faux.d.ts +0 -56
- package/node_modules/@dimivelev/chimera-ai/dist/providers/faux.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/faux.js +0 -368
- package/node_modules/@dimivelev/chimera-ai/dist/providers/faux.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/github-copilot-headers.d.ts +0 -8
- package/node_modules/@dimivelev/chimera-ai/dist/providers/github-copilot-headers.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/github-copilot-headers.js +0 -29
- package/node_modules/@dimivelev/chimera-ai/dist/providers/github-copilot-headers.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-shared.d.ts +0 -70
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-shared.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-shared.js +0 -329
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-shared.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-vertex.d.ts +0 -15
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-vertex.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-vertex.js +0 -442
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google-vertex.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google.d.ts +0 -13
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google.js +0 -402
- package/node_modules/@dimivelev/chimera-ai/dist/providers/google.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/openrouter.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/openrouter.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/openrouter.js +0 -128
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/openrouter.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/register-builtins.d.ts +0 -4
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/register-builtins.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/register-builtins.js +0 -34
- package/node_modules/@dimivelev/chimera-ai/dist/providers/images/register-builtins.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/mistral.d.ts +0 -25
- package/node_modules/@dimivelev/chimera-ai/dist/providers/mistral.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/mistral.js +0 -534
- package/node_modules/@dimivelev/chimera-ai/dist/providers/mistral.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-codex-responses.d.ts +0 -30
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-codex-responses.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-codex-responses.js +0 -1171
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-codex-responses.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-completions.d.ts +0 -19
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-completions.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-completions.js +0 -956
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-completions.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-prompt-cache.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-prompt-cache.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-prompt-cache.js +0 -10
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-prompt-cache.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses-shared.d.ts +0 -18
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses-shared.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses-shared.js +0 -495
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses-shared.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses.d.ts +0 -13
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses.js +0 -233
- package/node_modules/@dimivelev/chimera-ai/dist/providers/openai-responses.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/register-builtins.d.ts +0 -35
- package/node_modules/@dimivelev/chimera-ai/dist/providers/register-builtins.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/register-builtins.js +0 -254
- package/node_modules/@dimivelev/chimera-ai/dist/providers/register-builtins.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/simple-options.d.ts +0 -8
- package/node_modules/@dimivelev/chimera-ai/dist/providers/simple-options.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/simple-options.js +0 -42
- package/node_modules/@dimivelev/chimera-ai/dist/providers/simple-options.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/transform-messages.d.ts +0 -8
- package/node_modules/@dimivelev/chimera-ai/dist/providers/transform-messages.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/providers/transform-messages.js +0 -184
- package/node_modules/@dimivelev/chimera-ai/dist/providers/transform-messages.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/session-resources.d.ts +0 -4
- package/node_modules/@dimivelev/chimera-ai/dist/session-resources.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/session-resources.js +0 -22
- package/node_modules/@dimivelev/chimera-ai/dist/session-resources.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/stream.d.ts +0 -8
- package/node_modules/@dimivelev/chimera-ai/dist/stream.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/stream.js +0 -39
- package/node_modules/@dimivelev/chimera-ai/dist/stream.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/types.d.ts +0 -514
- package/node_modules/@dimivelev/chimera-ai/dist/types.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/types.js +0 -2
- package/node_modules/@dimivelev/chimera-ai/dist/types.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/abort-signals.d.ts +0 -6
- package/node_modules/@dimivelev/chimera-ai/dist/utils/abort-signals.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/abort-signals.js +0 -34
- package/node_modules/@dimivelev/chimera-ai/dist/utils/abort-signals.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/diagnostics.d.ts +0 -19
- package/node_modules/@dimivelev/chimera-ai/dist/utils/diagnostics.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/diagnostics.js +0 -25
- package/node_modules/@dimivelev/chimera-ai/dist/utils/diagnostics.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/event-stream.d.ts +0 -21
- package/node_modules/@dimivelev/chimera-ai/dist/utils/event-stream.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/event-stream.js +0 -81
- package/node_modules/@dimivelev/chimera-ai/dist/utils/event-stream.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/hash.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-ai/dist/utils/hash.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/hash.js +0 -14
- package/node_modules/@dimivelev/chimera-ai/dist/utils/hash.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/headers.d.ts +0 -2
- package/node_modules/@dimivelev/chimera-ai/dist/utils/headers.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/headers.js +0 -8
- package/node_modules/@dimivelev/chimera-ai/dist/utils/headers.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/json-parse.d.ts +0 -16
- package/node_modules/@dimivelev/chimera-ai/dist/utils/json-parse.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/json-parse.js +0 -113
- package/node_modules/@dimivelev/chimera-ai/dist/utils/json-parse.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/node-http-proxy.d.ts +0 -10
- package/node_modules/@dimivelev/chimera-ai/dist/utils/node-http-proxy.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/node-http-proxy.js +0 -97
- package/node_modules/@dimivelev/chimera-ai/dist/utils/node-http-proxy.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/anthropic.d.ts +0 -25
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/anthropic.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/anthropic.js +0 -335
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/anthropic.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/device-code.d.ts +0 -21
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/device-code.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/device-code.js +0 -56
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/device-code.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/github-copilot.d.ts +0 -30
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/github-copilot.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/github-copilot.js +0 -268
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/github-copilot.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/index.d.ts +0 -58
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/index.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/index.js +0 -122
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/index.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/oauth-page.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/oauth-page.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/oauth-page.js +0 -105
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/oauth-page.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/openai-codex.d.ts +0 -43
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/openai-codex.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/openai-codex.js +0 -485
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/openai-codex.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/pkce.d.ts +0 -13
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/pkce.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/pkce.js +0 -31
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/pkce.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/types.d.ts +0 -64
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/types.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/types.js +0 -2
- package/node_modules/@dimivelev/chimera-ai/dist/utils/oauth/types.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/overflow.d.ts +0 -57
- package/node_modules/@dimivelev/chimera-ai/dist/utils/overflow.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/overflow.js +0 -154
- package/node_modules/@dimivelev/chimera-ai/dist/utils/overflow.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/sanitize-unicode.d.ts +0 -22
- package/node_modules/@dimivelev/chimera-ai/dist/utils/sanitize-unicode.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/sanitize-unicode.js +0 -26
- package/node_modules/@dimivelev/chimera-ai/dist/utils/sanitize-unicode.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/typebox-helpers.d.ts +0 -17
- package/node_modules/@dimivelev/chimera-ai/dist/utils/typebox-helpers.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/typebox-helpers.js +0 -21
- package/node_modules/@dimivelev/chimera-ai/dist/utils/typebox-helpers.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/validation.d.ts +0 -18
- package/node_modules/@dimivelev/chimera-ai/dist/utils/validation.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/dist/utils/validation.js +0 -281
- package/node_modules/@dimivelev/chimera-ai/dist/utils/validation.js.map +0 -1
- package/node_modules/@dimivelev/chimera-ai/package.json +0 -106
- package/node_modules/@dimivelev/chimera-tui/dist/autocomplete.d.ts +0 -54
- package/node_modules/@dimivelev/chimera-tui/dist/autocomplete.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/autocomplete.js +0 -632
- package/node_modules/@dimivelev/chimera-tui/dist/autocomplete.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/box.d.ts +0 -22
- package/node_modules/@dimivelev/chimera-tui/dist/components/box.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/box.js +0 -104
- package/node_modules/@dimivelev/chimera-tui/dist/components/box.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/cancellable-loader.d.ts +0 -22
- package/node_modules/@dimivelev/chimera-tui/dist/components/cancellable-loader.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/cancellable-loader.js +0 -35
- package/node_modules/@dimivelev/chimera-tui/dist/components/cancellable-loader.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/editor.d.ts +0 -249
- package/node_modules/@dimivelev/chimera-tui/dist/components/editor.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/editor.js +0 -1857
- package/node_modules/@dimivelev/chimera-tui/dist/components/editor.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/image.d.ts +0 -28
- package/node_modules/@dimivelev/chimera-tui/dist/components/image.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/image.js +0 -89
- package/node_modules/@dimivelev/chimera-tui/dist/components/image.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/input.d.ts +0 -37
- package/node_modules/@dimivelev/chimera-tui/dist/components/input.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/input.js +0 -378
- package/node_modules/@dimivelev/chimera-tui/dist/components/input.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/loader.d.ts +0 -31
- package/node_modules/@dimivelev/chimera-tui/dist/components/loader.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/loader.js +0 -69
- package/node_modules/@dimivelev/chimera-tui/dist/components/loader.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/markdown.d.ts +0 -96
- package/node_modules/@dimivelev/chimera-tui/dist/components/markdown.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/markdown.js +0 -644
- package/node_modules/@dimivelev/chimera-tui/dist/components/markdown.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/select-list.d.ts +0 -50
- package/node_modules/@dimivelev/chimera-tui/dist/components/select-list.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/select-list.js +0 -159
- package/node_modules/@dimivelev/chimera-tui/dist/components/select-list.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/settings-list.d.ts +0 -50
- package/node_modules/@dimivelev/chimera-tui/dist/components/settings-list.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/settings-list.js +0 -185
- package/node_modules/@dimivelev/chimera-tui/dist/components/settings-list.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/spacer.d.ts +0 -12
- package/node_modules/@dimivelev/chimera-tui/dist/components/spacer.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/spacer.js +0 -23
- package/node_modules/@dimivelev/chimera-tui/dist/components/spacer.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/text.d.ts +0 -19
- package/node_modules/@dimivelev/chimera-tui/dist/components/text.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/text.js +0 -89
- package/node_modules/@dimivelev/chimera-tui/dist/components/text.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/truncated-text.d.ts +0 -13
- package/node_modules/@dimivelev/chimera-tui/dist/components/truncated-text.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/components/truncated-text.js +0 -51
- package/node_modules/@dimivelev/chimera-tui/dist/components/truncated-text.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/editor-component.d.ts +0 -39
- package/node_modules/@dimivelev/chimera-tui/dist/editor-component.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/editor-component.js +0 -2
- package/node_modules/@dimivelev/chimera-tui/dist/editor-component.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/fuzzy.d.ts +0 -16
- package/node_modules/@dimivelev/chimera-tui/dist/fuzzy.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/fuzzy.js +0 -110
- package/node_modules/@dimivelev/chimera-tui/dist/fuzzy.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/index.d.ts +0 -23
- package/node_modules/@dimivelev/chimera-tui/dist/index.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/index.js +0 -32
- package/node_modules/@dimivelev/chimera-tui/dist/index.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/keybindings.d.ts +0 -193
- package/node_modules/@dimivelev/chimera-tui/dist/keybindings.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/keybindings.js +0 -174
- package/node_modules/@dimivelev/chimera-tui/dist/keybindings.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/keys.d.ts +0 -184
- package/node_modules/@dimivelev/chimera-tui/dist/keys.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/keys.js +0 -1173
- package/node_modules/@dimivelev/chimera-tui/dist/keys.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/kill-ring.d.ts +0 -28
- package/node_modules/@dimivelev/chimera-tui/dist/kill-ring.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/kill-ring.js +0 -44
- package/node_modules/@dimivelev/chimera-tui/dist/kill-ring.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/native-modifiers.d.ts +0 -3
- package/node_modules/@dimivelev/chimera-tui/dist/native-modifiers.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/native-modifiers.js +0 -53
- package/node_modules/@dimivelev/chimera-tui/dist/native-modifiers.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/stdin-buffer.d.ts +0 -50
- package/node_modules/@dimivelev/chimera-tui/dist/stdin-buffer.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/stdin-buffer.js +0 -361
- package/node_modules/@dimivelev/chimera-tui/dist/stdin-buffer.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/terminal-image.d.ts +0 -90
- package/node_modules/@dimivelev/chimera-tui/dist/terminal-image.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/terminal-image.js +0 -366
- package/node_modules/@dimivelev/chimera-tui/dist/terminal-image.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/terminal.d.ts +0 -113
- package/node_modules/@dimivelev/chimera-tui/dist/terminal.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/terminal.js +0 -472
- package/node_modules/@dimivelev/chimera-tui/dist/terminal.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/tui.d.ts +0 -242
- package/node_modules/@dimivelev/chimera-tui/dist/tui.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/tui.js +0 -1221
- package/node_modules/@dimivelev/chimera-tui/dist/tui.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/undo-stack.d.ts +0 -17
- package/node_modules/@dimivelev/chimera-tui/dist/undo-stack.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/undo-stack.js +0 -25
- package/node_modules/@dimivelev/chimera-tui/dist/undo-stack.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/utils.d.ts +0 -84
- package/node_modules/@dimivelev/chimera-tui/dist/utils.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/utils.js +0 -1029
- package/node_modules/@dimivelev/chimera-tui/dist/utils.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/word-navigation.d.ts +0 -25
- package/node_modules/@dimivelev/chimera-tui/dist/word-navigation.d.ts.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/dist/word-navigation.js +0 -96
- package/node_modules/@dimivelev/chimera-tui/dist/word-navigation.js.map +0 -1
- package/node_modules/@dimivelev/chimera-tui/package.json +0 -47
|
@@ -1,1173 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Keyboard input handling for terminal applications.
|
|
3
|
-
*
|
|
4
|
-
* Supports both legacy terminal sequences and Kitty keyboard protocol.
|
|
5
|
-
* See: https://sw.kovidgoyal.net/kitty/keyboard-protocol/
|
|
6
|
-
* Reference: https://github.com/sst/opentui/blob/7da92b4088aebfe27b9f691c04163a48821e49fd/packages/core/src/lib/parse.keypress.ts
|
|
7
|
-
*
|
|
8
|
-
* Symbol keys are also supported, however some ctrl+symbol combos
|
|
9
|
-
* overlap with ASCII codes, e.g. ctrl+[ = ESC.
|
|
10
|
-
* See: https://sw.kovidgoyal.net/kitty/keyboard-protocol/#legacy-ctrl-mapping-of-ascii-keys
|
|
11
|
-
* Those can still be * used for ctrl+shift combos
|
|
12
|
-
*
|
|
13
|
-
* API:
|
|
14
|
-
* - matchesKey(data, keyId) - Check if input matches a key identifier
|
|
15
|
-
* - parseKey(data) - Parse input and return the key identifier
|
|
16
|
-
* - Key - Helper object for creating typed key identifiers
|
|
17
|
-
* - setKittyProtocolActive(active) - Set global Kitty protocol state
|
|
18
|
-
* - isKittyProtocolActive() - Query global Kitty protocol state
|
|
19
|
-
*/
|
|
20
|
-
// =============================================================================
|
|
21
|
-
// Global Kitty Protocol State
|
|
22
|
-
// =============================================================================
|
|
23
|
-
let _kittyProtocolActive = false;
|
|
24
|
-
/**
|
|
25
|
-
* Set the global Kitty keyboard protocol state.
|
|
26
|
-
* Called by ProcessTerminal after detecting protocol support.
|
|
27
|
-
*/
|
|
28
|
-
export function setKittyProtocolActive(active) {
|
|
29
|
-
_kittyProtocolActive = active;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* Query whether Kitty keyboard protocol is currently active.
|
|
33
|
-
*/
|
|
34
|
-
export function isKittyProtocolActive() {
|
|
35
|
-
return _kittyProtocolActive;
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Helper object for creating typed key identifiers with autocomplete.
|
|
39
|
-
*
|
|
40
|
-
* Usage:
|
|
41
|
-
* - Key.escape, Key.enter, Key.tab, etc. for special keys
|
|
42
|
-
* - Key.backtick, Key.comma, Key.period, etc. for symbol keys
|
|
43
|
-
* - Key.ctrl("c"), Key.alt("x"), Key.super("k") for single modifiers
|
|
44
|
-
* - Key.ctrlShift("p"), Key.ctrlAlt("x"), Key.ctrlSuper("k") for combined modifiers
|
|
45
|
-
*/
|
|
46
|
-
export const Key = {
|
|
47
|
-
// Special keys
|
|
48
|
-
escape: "escape",
|
|
49
|
-
esc: "esc",
|
|
50
|
-
enter: "enter",
|
|
51
|
-
return: "return",
|
|
52
|
-
tab: "tab",
|
|
53
|
-
space: "space",
|
|
54
|
-
backspace: "backspace",
|
|
55
|
-
delete: "delete",
|
|
56
|
-
insert: "insert",
|
|
57
|
-
clear: "clear",
|
|
58
|
-
home: "home",
|
|
59
|
-
end: "end",
|
|
60
|
-
pageUp: "pageUp",
|
|
61
|
-
pageDown: "pageDown",
|
|
62
|
-
up: "up",
|
|
63
|
-
down: "down",
|
|
64
|
-
left: "left",
|
|
65
|
-
right: "right",
|
|
66
|
-
f1: "f1",
|
|
67
|
-
f2: "f2",
|
|
68
|
-
f3: "f3",
|
|
69
|
-
f4: "f4",
|
|
70
|
-
f5: "f5",
|
|
71
|
-
f6: "f6",
|
|
72
|
-
f7: "f7",
|
|
73
|
-
f8: "f8",
|
|
74
|
-
f9: "f9",
|
|
75
|
-
f10: "f10",
|
|
76
|
-
f11: "f11",
|
|
77
|
-
f12: "f12",
|
|
78
|
-
// Symbol keys
|
|
79
|
-
backtick: "`",
|
|
80
|
-
hyphen: "-",
|
|
81
|
-
equals: "=",
|
|
82
|
-
leftbracket: "[",
|
|
83
|
-
rightbracket: "]",
|
|
84
|
-
backslash: "\\",
|
|
85
|
-
semicolon: ";",
|
|
86
|
-
quote: "'",
|
|
87
|
-
comma: ",",
|
|
88
|
-
period: ".",
|
|
89
|
-
slash: "/",
|
|
90
|
-
exclamation: "!",
|
|
91
|
-
at: "@",
|
|
92
|
-
hash: "#",
|
|
93
|
-
dollar: "$",
|
|
94
|
-
percent: "%",
|
|
95
|
-
caret: "^",
|
|
96
|
-
ampersand: "&",
|
|
97
|
-
asterisk: "*",
|
|
98
|
-
leftparen: "(",
|
|
99
|
-
rightparen: ")",
|
|
100
|
-
underscore: "_",
|
|
101
|
-
plus: "+",
|
|
102
|
-
pipe: "|",
|
|
103
|
-
tilde: "~",
|
|
104
|
-
leftbrace: "{",
|
|
105
|
-
rightbrace: "}",
|
|
106
|
-
colon: ":",
|
|
107
|
-
lessthan: "<",
|
|
108
|
-
greaterthan: ">",
|
|
109
|
-
question: "?",
|
|
110
|
-
// Single modifiers
|
|
111
|
-
ctrl: (key) => `ctrl+${key}`,
|
|
112
|
-
shift: (key) => `shift+${key}`,
|
|
113
|
-
alt: (key) => `alt+${key}`,
|
|
114
|
-
super: (key) => `super+${key}`,
|
|
115
|
-
// Combined modifiers
|
|
116
|
-
ctrlShift: (key) => `ctrl+shift+${key}`,
|
|
117
|
-
shiftCtrl: (key) => `shift+ctrl+${key}`,
|
|
118
|
-
ctrlAlt: (key) => `ctrl+alt+${key}`,
|
|
119
|
-
altCtrl: (key) => `alt+ctrl+${key}`,
|
|
120
|
-
shiftAlt: (key) => `shift+alt+${key}`,
|
|
121
|
-
altShift: (key) => `alt+shift+${key}`,
|
|
122
|
-
ctrlSuper: (key) => `ctrl+super+${key}`,
|
|
123
|
-
superCtrl: (key) => `super+ctrl+${key}`,
|
|
124
|
-
shiftSuper: (key) => `shift+super+${key}`,
|
|
125
|
-
superShift: (key) => `super+shift+${key}`,
|
|
126
|
-
altSuper: (key) => `alt+super+${key}`,
|
|
127
|
-
superAlt: (key) => `super+alt+${key}`,
|
|
128
|
-
// Triple modifiers
|
|
129
|
-
ctrlShiftAlt: (key) => `ctrl+shift+alt+${key}`,
|
|
130
|
-
ctrlShiftSuper: (key) => `ctrl+shift+super+${key}`,
|
|
131
|
-
};
|
|
132
|
-
// =============================================================================
|
|
133
|
-
// Constants
|
|
134
|
-
// =============================================================================
|
|
135
|
-
const SYMBOL_KEYS = new Set([
|
|
136
|
-
"`",
|
|
137
|
-
"-",
|
|
138
|
-
"=",
|
|
139
|
-
"[",
|
|
140
|
-
"]",
|
|
141
|
-
"\\",
|
|
142
|
-
";",
|
|
143
|
-
"'",
|
|
144
|
-
",",
|
|
145
|
-
".",
|
|
146
|
-
"/",
|
|
147
|
-
"!",
|
|
148
|
-
"@",
|
|
149
|
-
"#",
|
|
150
|
-
"$",
|
|
151
|
-
"%",
|
|
152
|
-
"^",
|
|
153
|
-
"&",
|
|
154
|
-
"*",
|
|
155
|
-
"(",
|
|
156
|
-
")",
|
|
157
|
-
"_",
|
|
158
|
-
"+",
|
|
159
|
-
"|",
|
|
160
|
-
"~",
|
|
161
|
-
"{",
|
|
162
|
-
"}",
|
|
163
|
-
":",
|
|
164
|
-
"<",
|
|
165
|
-
">",
|
|
166
|
-
"?",
|
|
167
|
-
]);
|
|
168
|
-
const MODIFIERS = {
|
|
169
|
-
shift: 1,
|
|
170
|
-
alt: 2,
|
|
171
|
-
ctrl: 4,
|
|
172
|
-
super: 8,
|
|
173
|
-
};
|
|
174
|
-
const LOCK_MASK = 64 + 128; // Caps Lock + Num Lock
|
|
175
|
-
const CODEPOINTS = {
|
|
176
|
-
escape: 27,
|
|
177
|
-
tab: 9,
|
|
178
|
-
enter: 13,
|
|
179
|
-
space: 32,
|
|
180
|
-
backspace: 127,
|
|
181
|
-
kpEnter: 57414, // Numpad Enter (Kitty protocol)
|
|
182
|
-
};
|
|
183
|
-
const ARROW_CODEPOINTS = {
|
|
184
|
-
up: -1,
|
|
185
|
-
down: -2,
|
|
186
|
-
right: -3,
|
|
187
|
-
left: -4,
|
|
188
|
-
};
|
|
189
|
-
const FUNCTIONAL_CODEPOINTS = {
|
|
190
|
-
delete: -10,
|
|
191
|
-
insert: -11,
|
|
192
|
-
pageUp: -12,
|
|
193
|
-
pageDown: -13,
|
|
194
|
-
home: -14,
|
|
195
|
-
end: -15,
|
|
196
|
-
};
|
|
197
|
-
const KITTY_FUNCTIONAL_KEY_EQUIVALENTS = new Map([
|
|
198
|
-
[57399, 48], // KP_0 -> 0
|
|
199
|
-
[57400, 49], // KP_1 -> 1
|
|
200
|
-
[57401, 50], // KP_2 -> 2
|
|
201
|
-
[57402, 51], // KP_3 -> 3
|
|
202
|
-
[57403, 52], // KP_4 -> 4
|
|
203
|
-
[57404, 53], // KP_5 -> 5
|
|
204
|
-
[57405, 54], // KP_6 -> 6
|
|
205
|
-
[57406, 55], // KP_7 -> 7
|
|
206
|
-
[57407, 56], // KP_8 -> 8
|
|
207
|
-
[57408, 57], // KP_9 -> 9
|
|
208
|
-
[57409, 46], // KP_DECIMAL -> .
|
|
209
|
-
[57410, 47], // KP_DIVIDE -> /
|
|
210
|
-
[57411, 42], // KP_MULTIPLY -> *
|
|
211
|
-
[57412, 45], // KP_SUBTRACT -> -
|
|
212
|
-
[57413, 43], // KP_ADD -> +
|
|
213
|
-
[57415, 61], // KP_EQUAL -> =
|
|
214
|
-
[57416, 44], // KP_SEPARATOR -> ,
|
|
215
|
-
[57417, ARROW_CODEPOINTS.left],
|
|
216
|
-
[57418, ARROW_CODEPOINTS.right],
|
|
217
|
-
[57419, ARROW_CODEPOINTS.up],
|
|
218
|
-
[57420, ARROW_CODEPOINTS.down],
|
|
219
|
-
[57421, FUNCTIONAL_CODEPOINTS.pageUp],
|
|
220
|
-
[57422, FUNCTIONAL_CODEPOINTS.pageDown],
|
|
221
|
-
[57423, FUNCTIONAL_CODEPOINTS.home],
|
|
222
|
-
[57424, FUNCTIONAL_CODEPOINTS.end],
|
|
223
|
-
[57425, FUNCTIONAL_CODEPOINTS.insert],
|
|
224
|
-
[57426, FUNCTIONAL_CODEPOINTS.delete],
|
|
225
|
-
]);
|
|
226
|
-
function normalizeKittyFunctionalCodepoint(codepoint) {
|
|
227
|
-
return KITTY_FUNCTIONAL_KEY_EQUIVALENTS.get(codepoint) ?? codepoint;
|
|
228
|
-
}
|
|
229
|
-
function normalizeShiftedLetterIdentityCodepoint(codepoint, modifier) {
|
|
230
|
-
const effectiveModifier = modifier & ~LOCK_MASK;
|
|
231
|
-
if ((effectiveModifier & MODIFIERS.shift) !== 0 && codepoint >= 65 && codepoint <= 90) {
|
|
232
|
-
return codepoint + 32;
|
|
233
|
-
}
|
|
234
|
-
return codepoint;
|
|
235
|
-
}
|
|
236
|
-
const LEGACY_KEY_SEQUENCES = {
|
|
237
|
-
up: ["\x1b[A", "\x1bOA"],
|
|
238
|
-
down: ["\x1b[B", "\x1bOB"],
|
|
239
|
-
right: ["\x1b[C", "\x1bOC"],
|
|
240
|
-
left: ["\x1b[D", "\x1bOD"],
|
|
241
|
-
home: ["\x1b[H", "\x1bOH", "\x1b[1~", "\x1b[7~"],
|
|
242
|
-
end: ["\x1b[F", "\x1bOF", "\x1b[4~", "\x1b[8~"],
|
|
243
|
-
insert: ["\x1b[2~"],
|
|
244
|
-
delete: ["\x1b[3~"],
|
|
245
|
-
pageUp: ["\x1b[5~", "\x1b[[5~"],
|
|
246
|
-
pageDown: ["\x1b[6~", "\x1b[[6~"],
|
|
247
|
-
clear: ["\x1b[E", "\x1bOE"],
|
|
248
|
-
f1: ["\x1bOP", "\x1b[11~", "\x1b[[A"],
|
|
249
|
-
f2: ["\x1bOQ", "\x1b[12~", "\x1b[[B"],
|
|
250
|
-
f3: ["\x1bOR", "\x1b[13~", "\x1b[[C"],
|
|
251
|
-
f4: ["\x1bOS", "\x1b[14~", "\x1b[[D"],
|
|
252
|
-
f5: ["\x1b[15~", "\x1b[[E"],
|
|
253
|
-
f6: ["\x1b[17~"],
|
|
254
|
-
f7: ["\x1b[18~"],
|
|
255
|
-
f8: ["\x1b[19~"],
|
|
256
|
-
f9: ["\x1b[20~"],
|
|
257
|
-
f10: ["\x1b[21~"],
|
|
258
|
-
f11: ["\x1b[23~"],
|
|
259
|
-
f12: ["\x1b[24~"],
|
|
260
|
-
};
|
|
261
|
-
const LEGACY_SHIFT_SEQUENCES = {
|
|
262
|
-
up: ["\x1b[a"],
|
|
263
|
-
down: ["\x1b[b"],
|
|
264
|
-
right: ["\x1b[c"],
|
|
265
|
-
left: ["\x1b[d"],
|
|
266
|
-
clear: ["\x1b[e"],
|
|
267
|
-
insert: ["\x1b[2$"],
|
|
268
|
-
delete: ["\x1b[3$"],
|
|
269
|
-
pageUp: ["\x1b[5$"],
|
|
270
|
-
pageDown: ["\x1b[6$"],
|
|
271
|
-
home: ["\x1b[7$"],
|
|
272
|
-
end: ["\x1b[8$"],
|
|
273
|
-
};
|
|
274
|
-
const LEGACY_CTRL_SEQUENCES = {
|
|
275
|
-
up: ["\x1bOa"],
|
|
276
|
-
down: ["\x1bOb"],
|
|
277
|
-
right: ["\x1bOc"],
|
|
278
|
-
left: ["\x1bOd"],
|
|
279
|
-
clear: ["\x1bOe"],
|
|
280
|
-
insert: ["\x1b[2^"],
|
|
281
|
-
delete: ["\x1b[3^"],
|
|
282
|
-
pageUp: ["\x1b[5^"],
|
|
283
|
-
pageDown: ["\x1b[6^"],
|
|
284
|
-
home: ["\x1b[7^"],
|
|
285
|
-
end: ["\x1b[8^"],
|
|
286
|
-
};
|
|
287
|
-
const LEGACY_SEQUENCE_KEY_IDS = {
|
|
288
|
-
"\x1bOA": "up",
|
|
289
|
-
"\x1bOB": "down",
|
|
290
|
-
"\x1bOC": "right",
|
|
291
|
-
"\x1bOD": "left",
|
|
292
|
-
"\x1bOH": "home",
|
|
293
|
-
"\x1bOF": "end",
|
|
294
|
-
"\x1b[E": "clear",
|
|
295
|
-
"\x1bOE": "clear",
|
|
296
|
-
"\x1bOe": "ctrl+clear",
|
|
297
|
-
"\x1b[e": "shift+clear",
|
|
298
|
-
"\x1b[2~": "insert",
|
|
299
|
-
"\x1b[2$": "shift+insert",
|
|
300
|
-
"\x1b[2^": "ctrl+insert",
|
|
301
|
-
"\x1b[3$": "shift+delete",
|
|
302
|
-
"\x1b[3^": "ctrl+delete",
|
|
303
|
-
"\x1b[[5~": "pageUp",
|
|
304
|
-
"\x1b[[6~": "pageDown",
|
|
305
|
-
"\x1b[a": "shift+up",
|
|
306
|
-
"\x1b[b": "shift+down",
|
|
307
|
-
"\x1b[c": "shift+right",
|
|
308
|
-
"\x1b[d": "shift+left",
|
|
309
|
-
"\x1bOa": "ctrl+up",
|
|
310
|
-
"\x1bOb": "ctrl+down",
|
|
311
|
-
"\x1bOc": "ctrl+right",
|
|
312
|
-
"\x1bOd": "ctrl+left",
|
|
313
|
-
"\x1b[5$": "shift+pageUp",
|
|
314
|
-
"\x1b[6$": "shift+pageDown",
|
|
315
|
-
"\x1b[7$": "shift+home",
|
|
316
|
-
"\x1b[8$": "shift+end",
|
|
317
|
-
"\x1b[5^": "ctrl+pageUp",
|
|
318
|
-
"\x1b[6^": "ctrl+pageDown",
|
|
319
|
-
"\x1b[7^": "ctrl+home",
|
|
320
|
-
"\x1b[8^": "ctrl+end",
|
|
321
|
-
"\x1bOP": "f1",
|
|
322
|
-
"\x1bOQ": "f2",
|
|
323
|
-
"\x1bOR": "f3",
|
|
324
|
-
"\x1bOS": "f4",
|
|
325
|
-
"\x1b[11~": "f1",
|
|
326
|
-
"\x1b[12~": "f2",
|
|
327
|
-
"\x1b[13~": "f3",
|
|
328
|
-
"\x1b[14~": "f4",
|
|
329
|
-
"\x1b[[A": "f1",
|
|
330
|
-
"\x1b[[B": "f2",
|
|
331
|
-
"\x1b[[C": "f3",
|
|
332
|
-
"\x1b[[D": "f4",
|
|
333
|
-
"\x1b[[E": "f5",
|
|
334
|
-
"\x1b[15~": "f5",
|
|
335
|
-
"\x1b[17~": "f6",
|
|
336
|
-
"\x1b[18~": "f7",
|
|
337
|
-
"\x1b[19~": "f8",
|
|
338
|
-
"\x1b[20~": "f9",
|
|
339
|
-
"\x1b[21~": "f10",
|
|
340
|
-
"\x1b[23~": "f11",
|
|
341
|
-
"\x1b[24~": "f12",
|
|
342
|
-
"\x1bb": "alt+left",
|
|
343
|
-
"\x1bf": "alt+right",
|
|
344
|
-
"\x1bp": "alt+up",
|
|
345
|
-
"\x1bn": "alt+down",
|
|
346
|
-
};
|
|
347
|
-
const matchesLegacySequence = (data, sequences) => sequences.includes(data);
|
|
348
|
-
const matchesLegacyModifierSequence = (data, key, modifier) => {
|
|
349
|
-
if (modifier === MODIFIERS.shift) {
|
|
350
|
-
return matchesLegacySequence(data, LEGACY_SHIFT_SEQUENCES[key]);
|
|
351
|
-
}
|
|
352
|
-
if (modifier === MODIFIERS.ctrl) {
|
|
353
|
-
return matchesLegacySequence(data, LEGACY_CTRL_SEQUENCES[key]);
|
|
354
|
-
}
|
|
355
|
-
return false;
|
|
356
|
-
};
|
|
357
|
-
// Store the last parsed event type for isKeyRelease() to query
|
|
358
|
-
let _lastEventType = "press";
|
|
359
|
-
/**
|
|
360
|
-
* Check if the last parsed key event was a key release.
|
|
361
|
-
* Only meaningful when Kitty keyboard protocol with flag 2 is active.
|
|
362
|
-
*/
|
|
363
|
-
export function isKeyRelease(data) {
|
|
364
|
-
// Don't treat bracketed paste content as key release, even if it contains
|
|
365
|
-
// patterns like ":3F" (e.g., bluetooth MAC addresses like "90:62:3F:A5").
|
|
366
|
-
// Terminal.ts re-wraps paste content with bracketed paste markers before
|
|
367
|
-
// passing to TUI, so pasted data will always contain \x1b[200~.
|
|
368
|
-
if (data.includes("\x1b[200~")) {
|
|
369
|
-
return false;
|
|
370
|
-
}
|
|
371
|
-
// Quick check: release events with flag 2 contain ":3"
|
|
372
|
-
// Format: \x1b[<codepoint>;<modifier>:3u
|
|
373
|
-
if (data.includes(":3u") ||
|
|
374
|
-
data.includes(":3~") ||
|
|
375
|
-
data.includes(":3A") ||
|
|
376
|
-
data.includes(":3B") ||
|
|
377
|
-
data.includes(":3C") ||
|
|
378
|
-
data.includes(":3D") ||
|
|
379
|
-
data.includes(":3H") ||
|
|
380
|
-
data.includes(":3F")) {
|
|
381
|
-
return true;
|
|
382
|
-
}
|
|
383
|
-
return false;
|
|
384
|
-
}
|
|
385
|
-
/**
|
|
386
|
-
* Check if the last parsed key event was a key repeat.
|
|
387
|
-
* Only meaningful when Kitty keyboard protocol with flag 2 is active.
|
|
388
|
-
*/
|
|
389
|
-
export function isKeyRepeat(data) {
|
|
390
|
-
// Don't treat bracketed paste content as key repeat, even if it contains
|
|
391
|
-
// patterns like ":2F". See isKeyRelease() for details.
|
|
392
|
-
if (data.includes("\x1b[200~")) {
|
|
393
|
-
return false;
|
|
394
|
-
}
|
|
395
|
-
if (data.includes(":2u") ||
|
|
396
|
-
data.includes(":2~") ||
|
|
397
|
-
data.includes(":2A") ||
|
|
398
|
-
data.includes(":2B") ||
|
|
399
|
-
data.includes(":2C") ||
|
|
400
|
-
data.includes(":2D") ||
|
|
401
|
-
data.includes(":2H") ||
|
|
402
|
-
data.includes(":2F")) {
|
|
403
|
-
return true;
|
|
404
|
-
}
|
|
405
|
-
return false;
|
|
406
|
-
}
|
|
407
|
-
function parseEventType(eventTypeStr) {
|
|
408
|
-
if (!eventTypeStr)
|
|
409
|
-
return "press";
|
|
410
|
-
const eventType = parseInt(eventTypeStr, 10);
|
|
411
|
-
if (eventType === 2)
|
|
412
|
-
return "repeat";
|
|
413
|
-
if (eventType === 3)
|
|
414
|
-
return "release";
|
|
415
|
-
return "press";
|
|
416
|
-
}
|
|
417
|
-
function parseKittySequence(data) {
|
|
418
|
-
// CSI u format with alternate keys (flag 4):
|
|
419
|
-
// \x1b[<codepoint>u
|
|
420
|
-
// \x1b[<codepoint>;<mod>u
|
|
421
|
-
// \x1b[<codepoint>;<mod>:<event>u
|
|
422
|
-
// \x1b[<codepoint>:<shifted>;<mod>u
|
|
423
|
-
// \x1b[<codepoint>:<shifted>:<base>;<mod>u
|
|
424
|
-
// \x1b[<codepoint>::<base>;<mod>u (no shifted key, only base)
|
|
425
|
-
//
|
|
426
|
-
// With flag 2, event type is appended after modifier colon: 1=press, 2=repeat, 3=release
|
|
427
|
-
// With flag 4, alternate keys are appended after codepoint with colons
|
|
428
|
-
const csiUMatch = data.match(/^\x1b\[(\d+)(?::(\d*))?(?::(\d+))?(?:;(\d+))?(?::(\d+))?u$/);
|
|
429
|
-
if (csiUMatch) {
|
|
430
|
-
const codepoint = parseInt(csiUMatch[1], 10);
|
|
431
|
-
const shiftedKey = csiUMatch[2] && csiUMatch[2].length > 0 ? parseInt(csiUMatch[2], 10) : undefined;
|
|
432
|
-
const baseLayoutKey = csiUMatch[3] ? parseInt(csiUMatch[3], 10) : undefined;
|
|
433
|
-
const modValue = csiUMatch[4] ? parseInt(csiUMatch[4], 10) : 1;
|
|
434
|
-
const eventType = parseEventType(csiUMatch[5]);
|
|
435
|
-
_lastEventType = eventType;
|
|
436
|
-
return { codepoint, shiftedKey, baseLayoutKey, modifier: modValue - 1, eventType };
|
|
437
|
-
}
|
|
438
|
-
// Arrow keys with modifier: \x1b[1;<mod>A/B/C/D or \x1b[1;<mod>:<event>A/B/C/D
|
|
439
|
-
const arrowMatch = data.match(/^\x1b\[1;(\d+)(?::(\d+))?([ABCD])$/);
|
|
440
|
-
if (arrowMatch) {
|
|
441
|
-
const modValue = parseInt(arrowMatch[1], 10);
|
|
442
|
-
const eventType = parseEventType(arrowMatch[2]);
|
|
443
|
-
const arrowCodes = { A: -1, B: -2, C: -3, D: -4 };
|
|
444
|
-
_lastEventType = eventType;
|
|
445
|
-
return { codepoint: arrowCodes[arrowMatch[3]], modifier: modValue - 1, eventType };
|
|
446
|
-
}
|
|
447
|
-
// Functional keys: \x1b[<num>~ or \x1b[<num>;<mod>~ or \x1b[<num>;<mod>:<event>~
|
|
448
|
-
const funcMatch = data.match(/^\x1b\[(\d+)(?:;(\d+))?(?::(\d+))?~$/);
|
|
449
|
-
if (funcMatch) {
|
|
450
|
-
const keyNum = parseInt(funcMatch[1], 10);
|
|
451
|
-
const modValue = funcMatch[2] ? parseInt(funcMatch[2], 10) : 1;
|
|
452
|
-
const eventType = parseEventType(funcMatch[3]);
|
|
453
|
-
const funcCodes = {
|
|
454
|
-
2: FUNCTIONAL_CODEPOINTS.insert,
|
|
455
|
-
3: FUNCTIONAL_CODEPOINTS.delete,
|
|
456
|
-
5: FUNCTIONAL_CODEPOINTS.pageUp,
|
|
457
|
-
6: FUNCTIONAL_CODEPOINTS.pageDown,
|
|
458
|
-
7: FUNCTIONAL_CODEPOINTS.home,
|
|
459
|
-
8: FUNCTIONAL_CODEPOINTS.end,
|
|
460
|
-
};
|
|
461
|
-
const codepoint = funcCodes[keyNum];
|
|
462
|
-
if (codepoint !== undefined) {
|
|
463
|
-
_lastEventType = eventType;
|
|
464
|
-
return { codepoint, modifier: modValue - 1, eventType };
|
|
465
|
-
}
|
|
466
|
-
}
|
|
467
|
-
// Home/End with modifier: \x1b[1;<mod>H/F or \x1b[1;<mod>:<event>H/F
|
|
468
|
-
const homeEndMatch = data.match(/^\x1b\[1;(\d+)(?::(\d+))?([HF])$/);
|
|
469
|
-
if (homeEndMatch) {
|
|
470
|
-
const modValue = parseInt(homeEndMatch[1], 10);
|
|
471
|
-
const eventType = parseEventType(homeEndMatch[2]);
|
|
472
|
-
const codepoint = homeEndMatch[3] === "H" ? FUNCTIONAL_CODEPOINTS.home : FUNCTIONAL_CODEPOINTS.end;
|
|
473
|
-
_lastEventType = eventType;
|
|
474
|
-
return { codepoint, modifier: modValue - 1, eventType };
|
|
475
|
-
}
|
|
476
|
-
return null;
|
|
477
|
-
}
|
|
478
|
-
function matchesKittySequence(data, expectedCodepoint, expectedModifier) {
|
|
479
|
-
const parsed = parseKittySequence(data);
|
|
480
|
-
if (!parsed)
|
|
481
|
-
return false;
|
|
482
|
-
const actualMod = parsed.modifier & ~LOCK_MASK;
|
|
483
|
-
const expectedMod = expectedModifier & ~LOCK_MASK;
|
|
484
|
-
// Check if modifiers match
|
|
485
|
-
if (actualMod !== expectedMod)
|
|
486
|
-
return false;
|
|
487
|
-
const normalizedCodepoint = normalizeShiftedLetterIdentityCodepoint(normalizeKittyFunctionalCodepoint(parsed.codepoint), parsed.modifier);
|
|
488
|
-
const normalizedExpectedCodepoint = normalizeShiftedLetterIdentityCodepoint(normalizeKittyFunctionalCodepoint(expectedCodepoint), expectedModifier);
|
|
489
|
-
// Primary match: codepoint matches directly after normalizing functional keys
|
|
490
|
-
if (normalizedCodepoint === normalizedExpectedCodepoint)
|
|
491
|
-
return true;
|
|
492
|
-
// Alternate match: use base layout key for non-Latin keyboard layouts.
|
|
493
|
-
// This allows Ctrl+С (Cyrillic) to match Ctrl+c (Latin) when terminal reports
|
|
494
|
-
// the base layout key (the key in standard PC-101 layout).
|
|
495
|
-
//
|
|
496
|
-
// Only fall back to base layout key when the codepoint is NOT already a
|
|
497
|
-
// recognized Latin letter (a-z) or symbol (e.g., /, -, [, ;, etc.).
|
|
498
|
-
// When the codepoint is a recognized key, it is authoritative regardless
|
|
499
|
-
// of physical key position. This prevents remapped layouts (Dvorak, Colemak,
|
|
500
|
-
// xremap, etc.) from causing false matches: both letters and symbols move
|
|
501
|
-
// to different physical positions, so Ctrl+K could falsely match Ctrl+V
|
|
502
|
-
// (letter remapping) and Ctrl+/ could falsely match Ctrl+[ (symbol remapping)
|
|
503
|
-
// if the base layout key were always considered.
|
|
504
|
-
if (parsed.baseLayoutKey !== undefined && parsed.baseLayoutKey === expectedCodepoint) {
|
|
505
|
-
const cp = normalizedCodepoint;
|
|
506
|
-
const isLatinLetter = cp >= 97 && cp <= 122; // a-z
|
|
507
|
-
const isKnownSymbol = SYMBOL_KEYS.has(String.fromCharCode(cp));
|
|
508
|
-
if (!isLatinLetter && !isKnownSymbol)
|
|
509
|
-
return true;
|
|
510
|
-
}
|
|
511
|
-
return false;
|
|
512
|
-
}
|
|
513
|
-
function parseModifyOtherKeysSequence(data) {
|
|
514
|
-
const match = data.match(/^\x1b\[27;(\d+);(\d+)~$/);
|
|
515
|
-
if (!match)
|
|
516
|
-
return null;
|
|
517
|
-
const modValue = parseInt(match[1], 10);
|
|
518
|
-
const codepoint = parseInt(match[2], 10);
|
|
519
|
-
return { codepoint, modifier: modValue - 1 };
|
|
520
|
-
}
|
|
521
|
-
/**
|
|
522
|
-
* Match xterm modifyOtherKeys format: CSI 27 ; modifiers ; keycode ~
|
|
523
|
-
* This is used by terminals when Kitty protocol is not enabled.
|
|
524
|
-
* Modifier values are 1-indexed: 2=shift, 3=alt, 5=ctrl, etc.
|
|
525
|
-
*/
|
|
526
|
-
function matchesModifyOtherKeys(data, expectedKeycode, expectedModifier) {
|
|
527
|
-
const parsed = parseModifyOtherKeysSequence(data);
|
|
528
|
-
if (!parsed)
|
|
529
|
-
return false;
|
|
530
|
-
return parsed.codepoint === expectedKeycode && parsed.modifier === expectedModifier;
|
|
531
|
-
}
|
|
532
|
-
function isWindowsTerminalSession() {
|
|
533
|
-
return (Boolean(process.env.WT_SESSION) && !process.env.SSH_CONNECTION && !process.env.SSH_CLIENT && !process.env.SSH_TTY);
|
|
534
|
-
}
|
|
535
|
-
/**
|
|
536
|
-
* Raw 0x08 (BS) is ambiguous in legacy terminals.
|
|
537
|
-
*
|
|
538
|
-
* - Windows Terminal uses it for Ctrl+Backspace.
|
|
539
|
-
* - Some legacy terminals and tmux setups send it for plain Backspace.
|
|
540
|
-
*
|
|
541
|
-
* Prefer explicit Kitty / CSI-u / modifyOtherKeys sequences whenever they are
|
|
542
|
-
* available. Fall back to a Windows Terminal heuristic only for raw BS bytes.
|
|
543
|
-
*/
|
|
544
|
-
function matchesRawBackspace(data, expectedModifier) {
|
|
545
|
-
if (data === "\x7f")
|
|
546
|
-
return expectedModifier === 0;
|
|
547
|
-
if (data !== "\x08")
|
|
548
|
-
return false;
|
|
549
|
-
return isWindowsTerminalSession() ? expectedModifier === MODIFIERS.ctrl : expectedModifier === 0;
|
|
550
|
-
}
|
|
551
|
-
// =============================================================================
|
|
552
|
-
// Generic Key Matching
|
|
553
|
-
// =============================================================================
|
|
554
|
-
/**
|
|
555
|
-
* Get the control character for a key.
|
|
556
|
-
* Uses the universal formula: code & 0x1f (mask to lower 5 bits)
|
|
557
|
-
*
|
|
558
|
-
* Works for:
|
|
559
|
-
* - Letters a-z → 1-26
|
|
560
|
-
* - Symbols [\]_ → 27, 28, 29, 31
|
|
561
|
-
* - Also maps - to same as _ (same physical key on US keyboards)
|
|
562
|
-
*/
|
|
563
|
-
function rawCtrlChar(key) {
|
|
564
|
-
const char = key.toLowerCase();
|
|
565
|
-
const code = char.charCodeAt(0);
|
|
566
|
-
if ((code >= 97 && code <= 122) || char === "[" || char === "\\" || char === "]" || char === "_") {
|
|
567
|
-
return String.fromCharCode(code & 0x1f);
|
|
568
|
-
}
|
|
569
|
-
// Handle - as _ (same physical key on US keyboards)
|
|
570
|
-
if (char === "-") {
|
|
571
|
-
return String.fromCharCode(31); // Same as Ctrl+_
|
|
572
|
-
}
|
|
573
|
-
return null;
|
|
574
|
-
}
|
|
575
|
-
function isDigitKey(key) {
|
|
576
|
-
return key >= "0" && key <= "9";
|
|
577
|
-
}
|
|
578
|
-
function matchesPrintableModifyOtherKeys(data, expectedKeycode, expectedModifier) {
|
|
579
|
-
if (expectedModifier === 0)
|
|
580
|
-
return false;
|
|
581
|
-
const parsed = parseModifyOtherKeysSequence(data);
|
|
582
|
-
if (!parsed || parsed.modifier !== expectedModifier)
|
|
583
|
-
return false;
|
|
584
|
-
return (normalizeShiftedLetterIdentityCodepoint(parsed.codepoint, parsed.modifier) ===
|
|
585
|
-
normalizeShiftedLetterIdentityCodepoint(expectedKeycode, expectedModifier));
|
|
586
|
-
}
|
|
587
|
-
function formatKeyNameWithModifiers(keyName, modifier) {
|
|
588
|
-
const mods = [];
|
|
589
|
-
const effectiveMod = modifier & ~LOCK_MASK;
|
|
590
|
-
const supportedModifierMask = MODIFIERS.shift | MODIFIERS.ctrl | MODIFIERS.alt | MODIFIERS.super;
|
|
591
|
-
if ((effectiveMod & ~supportedModifierMask) !== 0)
|
|
592
|
-
return undefined;
|
|
593
|
-
if (effectiveMod & MODIFIERS.shift)
|
|
594
|
-
mods.push("shift");
|
|
595
|
-
if (effectiveMod & MODIFIERS.ctrl)
|
|
596
|
-
mods.push("ctrl");
|
|
597
|
-
if (effectiveMod & MODIFIERS.alt)
|
|
598
|
-
mods.push("alt");
|
|
599
|
-
if (effectiveMod & MODIFIERS.super)
|
|
600
|
-
mods.push("super");
|
|
601
|
-
return mods.length > 0 ? `${mods.join("+")}+${keyName}` : keyName;
|
|
602
|
-
}
|
|
603
|
-
function parseKeyId(keyId) {
|
|
604
|
-
const parts = keyId.toLowerCase().split("+");
|
|
605
|
-
const key = parts[parts.length - 1];
|
|
606
|
-
if (!key)
|
|
607
|
-
return null;
|
|
608
|
-
return {
|
|
609
|
-
key,
|
|
610
|
-
ctrl: parts.includes("ctrl"),
|
|
611
|
-
shift: parts.includes("shift"),
|
|
612
|
-
alt: parts.includes("alt"),
|
|
613
|
-
super: parts.includes("super"),
|
|
614
|
-
};
|
|
615
|
-
}
|
|
616
|
-
/**
|
|
617
|
-
* Match input data against a key identifier string.
|
|
618
|
-
*
|
|
619
|
-
* Supported key identifiers:
|
|
620
|
-
* - Single keys: "escape", "tab", "enter", "backspace", "delete", "home", "end", "space"
|
|
621
|
-
* - Arrow keys: "up", "down", "left", "right"
|
|
622
|
-
* - Ctrl combinations: "ctrl+c", "ctrl+z", etc.
|
|
623
|
-
* - Shift combinations: "shift+tab", "shift+enter"
|
|
624
|
-
* - Alt combinations: "alt+enter", "alt+backspace"
|
|
625
|
-
* - Super combinations: "super+k", "super+enter"
|
|
626
|
-
* - Combined modifiers: "shift+ctrl+p", "ctrl+alt+x", "ctrl+super+k"
|
|
627
|
-
*
|
|
628
|
-
* Use the Key helper for autocomplete: Key.ctrl("c"), Key.escape, Key.ctrlShift("p"), Key.super("k")
|
|
629
|
-
*
|
|
630
|
-
* @param data - Raw input data from terminal
|
|
631
|
-
* @param keyId - Key identifier (e.g., "ctrl+c", "escape", Key.ctrl("c"))
|
|
632
|
-
*/
|
|
633
|
-
export function matchesKey(data, keyId) {
|
|
634
|
-
const parsed = parseKeyId(keyId);
|
|
635
|
-
if (!parsed)
|
|
636
|
-
return false;
|
|
637
|
-
const { key, ctrl, shift, alt, super: superModifier } = parsed;
|
|
638
|
-
let modifier = 0;
|
|
639
|
-
if (shift)
|
|
640
|
-
modifier |= MODIFIERS.shift;
|
|
641
|
-
if (alt)
|
|
642
|
-
modifier |= MODIFIERS.alt;
|
|
643
|
-
if (ctrl)
|
|
644
|
-
modifier |= MODIFIERS.ctrl;
|
|
645
|
-
if (superModifier)
|
|
646
|
-
modifier |= MODIFIERS.super;
|
|
647
|
-
switch (key) {
|
|
648
|
-
case "escape":
|
|
649
|
-
case "esc":
|
|
650
|
-
if (modifier !== 0)
|
|
651
|
-
return false;
|
|
652
|
-
return (data === "\x1b" ||
|
|
653
|
-
matchesKittySequence(data, CODEPOINTS.escape, 0) ||
|
|
654
|
-
matchesModifyOtherKeys(data, CODEPOINTS.escape, 0));
|
|
655
|
-
case "space":
|
|
656
|
-
if (!_kittyProtocolActive) {
|
|
657
|
-
if (modifier === MODIFIERS.ctrl && data === "\x00") {
|
|
658
|
-
return true;
|
|
659
|
-
}
|
|
660
|
-
if (modifier === MODIFIERS.alt && data === "\x1b ") {
|
|
661
|
-
return true;
|
|
662
|
-
}
|
|
663
|
-
}
|
|
664
|
-
if (modifier === 0) {
|
|
665
|
-
return (data === " " ||
|
|
666
|
-
matchesKittySequence(data, CODEPOINTS.space, 0) ||
|
|
667
|
-
matchesModifyOtherKeys(data, CODEPOINTS.space, 0));
|
|
668
|
-
}
|
|
669
|
-
return (matchesKittySequence(data, CODEPOINTS.space, modifier) ||
|
|
670
|
-
matchesModifyOtherKeys(data, CODEPOINTS.space, modifier));
|
|
671
|
-
case "tab":
|
|
672
|
-
if (modifier === MODIFIERS.shift) {
|
|
673
|
-
return (data === "\x1b[Z" ||
|
|
674
|
-
matchesKittySequence(data, CODEPOINTS.tab, MODIFIERS.shift) ||
|
|
675
|
-
matchesModifyOtherKeys(data, CODEPOINTS.tab, MODIFIERS.shift));
|
|
676
|
-
}
|
|
677
|
-
if (modifier === 0) {
|
|
678
|
-
return data === "\t" || matchesKittySequence(data, CODEPOINTS.tab, 0);
|
|
679
|
-
}
|
|
680
|
-
return (matchesKittySequence(data, CODEPOINTS.tab, modifier) ||
|
|
681
|
-
matchesModifyOtherKeys(data, CODEPOINTS.tab, modifier));
|
|
682
|
-
case "enter":
|
|
683
|
-
case "return":
|
|
684
|
-
if (modifier === MODIFIERS.shift) {
|
|
685
|
-
// CSI u sequences (standard Kitty protocol)
|
|
686
|
-
if (matchesKittySequence(data, CODEPOINTS.enter, MODIFIERS.shift) ||
|
|
687
|
-
matchesKittySequence(data, CODEPOINTS.kpEnter, MODIFIERS.shift)) {
|
|
688
|
-
return true;
|
|
689
|
-
}
|
|
690
|
-
// xterm modifyOtherKeys format (fallback when Kitty protocol not enabled)
|
|
691
|
-
if (matchesModifyOtherKeys(data, CODEPOINTS.enter, MODIFIERS.shift)) {
|
|
692
|
-
return true;
|
|
693
|
-
}
|
|
694
|
-
// When Kitty protocol is active, legacy sequences are custom terminal mappings
|
|
695
|
-
// \x1b\r = Kitty's "map shift+enter send_text all \e\r"
|
|
696
|
-
// \n = Ghostty's "keybind = shift+enter=text:\n"
|
|
697
|
-
if (_kittyProtocolActive) {
|
|
698
|
-
return data === "\x1b\r" || data === "\n";
|
|
699
|
-
}
|
|
700
|
-
return false;
|
|
701
|
-
}
|
|
702
|
-
if (modifier === MODIFIERS.alt) {
|
|
703
|
-
// CSI u sequences (standard Kitty protocol)
|
|
704
|
-
if (matchesKittySequence(data, CODEPOINTS.enter, MODIFIERS.alt) ||
|
|
705
|
-
matchesKittySequence(data, CODEPOINTS.kpEnter, MODIFIERS.alt)) {
|
|
706
|
-
return true;
|
|
707
|
-
}
|
|
708
|
-
// xterm modifyOtherKeys format (fallback when Kitty protocol not enabled)
|
|
709
|
-
if (matchesModifyOtherKeys(data, CODEPOINTS.enter, MODIFIERS.alt)) {
|
|
710
|
-
return true;
|
|
711
|
-
}
|
|
712
|
-
// \x1b\r is alt+enter only in legacy mode (no Kitty protocol)
|
|
713
|
-
// When Kitty protocol is active, alt+enter comes as CSI u sequence
|
|
714
|
-
if (!_kittyProtocolActive) {
|
|
715
|
-
return data === "\x1b\r";
|
|
716
|
-
}
|
|
717
|
-
return false;
|
|
718
|
-
}
|
|
719
|
-
if (modifier === 0) {
|
|
720
|
-
return (data === "\r" ||
|
|
721
|
-
(!_kittyProtocolActive && data === "\n") ||
|
|
722
|
-
data === "\x1bOM" || // SS3 M (numpad enter in some terminals)
|
|
723
|
-
matchesKittySequence(data, CODEPOINTS.enter, 0) ||
|
|
724
|
-
matchesKittySequence(data, CODEPOINTS.kpEnter, 0));
|
|
725
|
-
}
|
|
726
|
-
return (matchesKittySequence(data, CODEPOINTS.enter, modifier) ||
|
|
727
|
-
matchesKittySequence(data, CODEPOINTS.kpEnter, modifier) ||
|
|
728
|
-
matchesModifyOtherKeys(data, CODEPOINTS.enter, modifier));
|
|
729
|
-
case "backspace":
|
|
730
|
-
if (modifier === MODIFIERS.alt) {
|
|
731
|
-
if (data === "\x1b\x7f" || data === "\x1b\b") {
|
|
732
|
-
return true;
|
|
733
|
-
}
|
|
734
|
-
return (matchesKittySequence(data, CODEPOINTS.backspace, MODIFIERS.alt) ||
|
|
735
|
-
matchesModifyOtherKeys(data, CODEPOINTS.backspace, MODIFIERS.alt));
|
|
736
|
-
}
|
|
737
|
-
if (modifier === MODIFIERS.ctrl) {
|
|
738
|
-
// Legacy raw 0x08 is ambiguous: it can be Ctrl+Backspace on Windows
|
|
739
|
-
// Terminal or plain Backspace on other terminals, while also
|
|
740
|
-
// overlapping with Ctrl+H.
|
|
741
|
-
if (matchesRawBackspace(data, MODIFIERS.ctrl))
|
|
742
|
-
return true;
|
|
743
|
-
return (matchesKittySequence(data, CODEPOINTS.backspace, MODIFIERS.ctrl) ||
|
|
744
|
-
matchesModifyOtherKeys(data, CODEPOINTS.backspace, MODIFIERS.ctrl));
|
|
745
|
-
}
|
|
746
|
-
if (modifier === 0) {
|
|
747
|
-
return (matchesRawBackspace(data, 0) ||
|
|
748
|
-
matchesKittySequence(data, CODEPOINTS.backspace, 0) ||
|
|
749
|
-
matchesModifyOtherKeys(data, CODEPOINTS.backspace, 0));
|
|
750
|
-
}
|
|
751
|
-
return (matchesKittySequence(data, CODEPOINTS.backspace, modifier) ||
|
|
752
|
-
matchesModifyOtherKeys(data, CODEPOINTS.backspace, modifier));
|
|
753
|
-
case "insert":
|
|
754
|
-
if (modifier === 0) {
|
|
755
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.insert) ||
|
|
756
|
-
matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.insert, 0));
|
|
757
|
-
}
|
|
758
|
-
if (matchesLegacyModifierSequence(data, "insert", modifier)) {
|
|
759
|
-
return true;
|
|
760
|
-
}
|
|
761
|
-
return matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.insert, modifier);
|
|
762
|
-
case "delete":
|
|
763
|
-
if (modifier === 0) {
|
|
764
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.delete) ||
|
|
765
|
-
matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.delete, 0));
|
|
766
|
-
}
|
|
767
|
-
if (matchesLegacyModifierSequence(data, "delete", modifier)) {
|
|
768
|
-
return true;
|
|
769
|
-
}
|
|
770
|
-
return matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.delete, modifier);
|
|
771
|
-
case "clear":
|
|
772
|
-
if (modifier === 0) {
|
|
773
|
-
return matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.clear);
|
|
774
|
-
}
|
|
775
|
-
return matchesLegacyModifierSequence(data, "clear", modifier);
|
|
776
|
-
case "home":
|
|
777
|
-
if (modifier === 0) {
|
|
778
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.home) ||
|
|
779
|
-
matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.home, 0));
|
|
780
|
-
}
|
|
781
|
-
if (matchesLegacyModifierSequence(data, "home", modifier)) {
|
|
782
|
-
return true;
|
|
783
|
-
}
|
|
784
|
-
return matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.home, modifier);
|
|
785
|
-
case "end":
|
|
786
|
-
if (modifier === 0) {
|
|
787
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.end) ||
|
|
788
|
-
matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.end, 0));
|
|
789
|
-
}
|
|
790
|
-
if (matchesLegacyModifierSequence(data, "end", modifier)) {
|
|
791
|
-
return true;
|
|
792
|
-
}
|
|
793
|
-
return matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.end, modifier);
|
|
794
|
-
case "pageup":
|
|
795
|
-
if (modifier === 0) {
|
|
796
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.pageUp) ||
|
|
797
|
-
matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.pageUp, 0));
|
|
798
|
-
}
|
|
799
|
-
if (matchesLegacyModifierSequence(data, "pageUp", modifier)) {
|
|
800
|
-
return true;
|
|
801
|
-
}
|
|
802
|
-
return matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.pageUp, modifier);
|
|
803
|
-
case "pagedown":
|
|
804
|
-
if (modifier === 0) {
|
|
805
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.pageDown) ||
|
|
806
|
-
matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.pageDown, 0));
|
|
807
|
-
}
|
|
808
|
-
if (matchesLegacyModifierSequence(data, "pageDown", modifier)) {
|
|
809
|
-
return true;
|
|
810
|
-
}
|
|
811
|
-
return matchesKittySequence(data, FUNCTIONAL_CODEPOINTS.pageDown, modifier);
|
|
812
|
-
case "up":
|
|
813
|
-
if (modifier === MODIFIERS.alt) {
|
|
814
|
-
return data === "\x1bp" || matchesKittySequence(data, ARROW_CODEPOINTS.up, MODIFIERS.alt);
|
|
815
|
-
}
|
|
816
|
-
if (modifier === 0) {
|
|
817
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.up) ||
|
|
818
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.up, 0));
|
|
819
|
-
}
|
|
820
|
-
if (matchesLegacyModifierSequence(data, "up", modifier)) {
|
|
821
|
-
return true;
|
|
822
|
-
}
|
|
823
|
-
return matchesKittySequence(data, ARROW_CODEPOINTS.up, modifier);
|
|
824
|
-
case "down":
|
|
825
|
-
if (modifier === MODIFIERS.alt) {
|
|
826
|
-
return data === "\x1bn" || matchesKittySequence(data, ARROW_CODEPOINTS.down, MODIFIERS.alt);
|
|
827
|
-
}
|
|
828
|
-
if (modifier === 0) {
|
|
829
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.down) ||
|
|
830
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.down, 0));
|
|
831
|
-
}
|
|
832
|
-
if (matchesLegacyModifierSequence(data, "down", modifier)) {
|
|
833
|
-
return true;
|
|
834
|
-
}
|
|
835
|
-
return matchesKittySequence(data, ARROW_CODEPOINTS.down, modifier);
|
|
836
|
-
case "left":
|
|
837
|
-
if (modifier === MODIFIERS.alt) {
|
|
838
|
-
return (data === "\x1b[1;3D" ||
|
|
839
|
-
(!_kittyProtocolActive && data === "\x1bB") ||
|
|
840
|
-
data === "\x1bb" ||
|
|
841
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.left, MODIFIERS.alt));
|
|
842
|
-
}
|
|
843
|
-
if (modifier === MODIFIERS.ctrl) {
|
|
844
|
-
return (data === "\x1b[1;5D" ||
|
|
845
|
-
matchesLegacyModifierSequence(data, "left", MODIFIERS.ctrl) ||
|
|
846
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.left, MODIFIERS.ctrl));
|
|
847
|
-
}
|
|
848
|
-
if (modifier === 0) {
|
|
849
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.left) ||
|
|
850
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.left, 0));
|
|
851
|
-
}
|
|
852
|
-
if (matchesLegacyModifierSequence(data, "left", modifier)) {
|
|
853
|
-
return true;
|
|
854
|
-
}
|
|
855
|
-
return matchesKittySequence(data, ARROW_CODEPOINTS.left, modifier);
|
|
856
|
-
case "right":
|
|
857
|
-
if (modifier === MODIFIERS.alt) {
|
|
858
|
-
return (data === "\x1b[1;3C" ||
|
|
859
|
-
(!_kittyProtocolActive && data === "\x1bF") ||
|
|
860
|
-
data === "\x1bf" ||
|
|
861
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.right, MODIFIERS.alt));
|
|
862
|
-
}
|
|
863
|
-
if (modifier === MODIFIERS.ctrl) {
|
|
864
|
-
return (data === "\x1b[1;5C" ||
|
|
865
|
-
matchesLegacyModifierSequence(data, "right", MODIFIERS.ctrl) ||
|
|
866
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.right, MODIFIERS.ctrl));
|
|
867
|
-
}
|
|
868
|
-
if (modifier === 0) {
|
|
869
|
-
return (matchesLegacySequence(data, LEGACY_KEY_SEQUENCES.right) ||
|
|
870
|
-
matchesKittySequence(data, ARROW_CODEPOINTS.right, 0));
|
|
871
|
-
}
|
|
872
|
-
if (matchesLegacyModifierSequence(data, "right", modifier)) {
|
|
873
|
-
return true;
|
|
874
|
-
}
|
|
875
|
-
return matchesKittySequence(data, ARROW_CODEPOINTS.right, modifier);
|
|
876
|
-
case "f1":
|
|
877
|
-
case "f2":
|
|
878
|
-
case "f3":
|
|
879
|
-
case "f4":
|
|
880
|
-
case "f5":
|
|
881
|
-
case "f6":
|
|
882
|
-
case "f7":
|
|
883
|
-
case "f8":
|
|
884
|
-
case "f9":
|
|
885
|
-
case "f10":
|
|
886
|
-
case "f11":
|
|
887
|
-
case "f12": {
|
|
888
|
-
if (modifier !== 0) {
|
|
889
|
-
return false;
|
|
890
|
-
}
|
|
891
|
-
const functionKey = key;
|
|
892
|
-
return matchesLegacySequence(data, LEGACY_KEY_SEQUENCES[functionKey]);
|
|
893
|
-
}
|
|
894
|
-
}
|
|
895
|
-
// Handle single letter/digit keys and symbols
|
|
896
|
-
if (key.length === 1 && ((key >= "a" && key <= "z") || isDigitKey(key) || SYMBOL_KEYS.has(key))) {
|
|
897
|
-
const codepoint = key.charCodeAt(0);
|
|
898
|
-
const rawCtrl = rawCtrlChar(key);
|
|
899
|
-
const isLetter = key >= "a" && key <= "z";
|
|
900
|
-
const isDigit = isDigitKey(key);
|
|
901
|
-
if (modifier === MODIFIERS.ctrl + MODIFIERS.alt && !_kittyProtocolActive && rawCtrl) {
|
|
902
|
-
// Legacy: ctrl+alt+key is ESC followed by the control character.
|
|
903
|
-
// If that legacy form does not match, continue so CSI-u and
|
|
904
|
-
// modifyOtherKeys sequences from tmux can still be recognized.
|
|
905
|
-
if (data === `\x1b${rawCtrl}`)
|
|
906
|
-
return true;
|
|
907
|
-
}
|
|
908
|
-
if (modifier === MODIFIERS.alt && !_kittyProtocolActive && (isLetter || isDigit)) {
|
|
909
|
-
// Legacy: alt+letter/digit is ESC followed by the key
|
|
910
|
-
if (data === `\x1b${key}`)
|
|
911
|
-
return true;
|
|
912
|
-
}
|
|
913
|
-
if (modifier === MODIFIERS.ctrl) {
|
|
914
|
-
// Legacy: ctrl+key sends the control character
|
|
915
|
-
if (rawCtrl && data === rawCtrl)
|
|
916
|
-
return true;
|
|
917
|
-
return (matchesKittySequence(data, codepoint, MODIFIERS.ctrl) ||
|
|
918
|
-
matchesPrintableModifyOtherKeys(data, codepoint, MODIFIERS.ctrl));
|
|
919
|
-
}
|
|
920
|
-
if (modifier === MODIFIERS.shift + MODIFIERS.ctrl) {
|
|
921
|
-
return (matchesKittySequence(data, codepoint, MODIFIERS.shift + MODIFIERS.ctrl) ||
|
|
922
|
-
matchesPrintableModifyOtherKeys(data, codepoint, MODIFIERS.shift + MODIFIERS.ctrl));
|
|
923
|
-
}
|
|
924
|
-
if (modifier === MODIFIERS.shift) {
|
|
925
|
-
// Legacy: shift+letter produces uppercase
|
|
926
|
-
if (isLetter && data === key.toUpperCase())
|
|
927
|
-
return true;
|
|
928
|
-
return (matchesKittySequence(data, codepoint, MODIFIERS.shift) ||
|
|
929
|
-
matchesPrintableModifyOtherKeys(data, codepoint, MODIFIERS.shift));
|
|
930
|
-
}
|
|
931
|
-
if (modifier !== 0) {
|
|
932
|
-
return (matchesKittySequence(data, codepoint, modifier) ||
|
|
933
|
-
matchesPrintableModifyOtherKeys(data, codepoint, modifier));
|
|
934
|
-
}
|
|
935
|
-
// Check both raw char and Kitty sequence (needed for release events)
|
|
936
|
-
return data === key || matchesKittySequence(data, codepoint, 0);
|
|
937
|
-
}
|
|
938
|
-
return false;
|
|
939
|
-
}
|
|
940
|
-
/**
|
|
941
|
-
* Parse input data and return the key identifier if recognized.
|
|
942
|
-
*
|
|
943
|
-
* @param data - Raw input data from terminal
|
|
944
|
-
* @returns Key identifier string (e.g., "ctrl+c") or undefined
|
|
945
|
-
*/
|
|
946
|
-
function formatParsedKey(codepoint, modifier, baseLayoutKey) {
|
|
947
|
-
const normalizedCodepoint = normalizeKittyFunctionalCodepoint(codepoint);
|
|
948
|
-
const identityCodepoint = normalizeShiftedLetterIdentityCodepoint(normalizedCodepoint, modifier);
|
|
949
|
-
// Use base layout key only when codepoint is not a recognized Latin
|
|
950
|
-
// letter (a-z), digit (0-9), or symbol (/, -, [, ;, etc.). For those,
|
|
951
|
-
// the codepoint is authoritative regardless of physical key position.
|
|
952
|
-
// This prevents remapped layouts (Dvorak, Colemak, xremap, etc.) from
|
|
953
|
-
// reporting the wrong key name based on the QWERTY physical position.
|
|
954
|
-
const isLatinLetter = identityCodepoint >= 97 && identityCodepoint <= 122; // a-z
|
|
955
|
-
const isDigit = identityCodepoint >= 48 && identityCodepoint <= 57; // 0-9
|
|
956
|
-
const isKnownSymbol = SYMBOL_KEYS.has(String.fromCharCode(identityCodepoint));
|
|
957
|
-
const effectiveCodepoint = isLatinLetter || isDigit || isKnownSymbol ? identityCodepoint : (baseLayoutKey ?? identityCodepoint);
|
|
958
|
-
let keyName;
|
|
959
|
-
if (effectiveCodepoint === CODEPOINTS.escape)
|
|
960
|
-
keyName = "escape";
|
|
961
|
-
else if (effectiveCodepoint === CODEPOINTS.tab)
|
|
962
|
-
keyName = "tab";
|
|
963
|
-
else if (effectiveCodepoint === CODEPOINTS.enter || effectiveCodepoint === CODEPOINTS.kpEnter)
|
|
964
|
-
keyName = "enter";
|
|
965
|
-
else if (effectiveCodepoint === CODEPOINTS.space)
|
|
966
|
-
keyName = "space";
|
|
967
|
-
else if (effectiveCodepoint === CODEPOINTS.backspace)
|
|
968
|
-
keyName = "backspace";
|
|
969
|
-
else if (effectiveCodepoint === FUNCTIONAL_CODEPOINTS.delete)
|
|
970
|
-
keyName = "delete";
|
|
971
|
-
else if (effectiveCodepoint === FUNCTIONAL_CODEPOINTS.insert)
|
|
972
|
-
keyName = "insert";
|
|
973
|
-
else if (effectiveCodepoint === FUNCTIONAL_CODEPOINTS.home)
|
|
974
|
-
keyName = "home";
|
|
975
|
-
else if (effectiveCodepoint === FUNCTIONAL_CODEPOINTS.end)
|
|
976
|
-
keyName = "end";
|
|
977
|
-
else if (effectiveCodepoint === FUNCTIONAL_CODEPOINTS.pageUp)
|
|
978
|
-
keyName = "pageUp";
|
|
979
|
-
else if (effectiveCodepoint === FUNCTIONAL_CODEPOINTS.pageDown)
|
|
980
|
-
keyName = "pageDown";
|
|
981
|
-
else if (effectiveCodepoint === ARROW_CODEPOINTS.up)
|
|
982
|
-
keyName = "up";
|
|
983
|
-
else if (effectiveCodepoint === ARROW_CODEPOINTS.down)
|
|
984
|
-
keyName = "down";
|
|
985
|
-
else if (effectiveCodepoint === ARROW_CODEPOINTS.left)
|
|
986
|
-
keyName = "left";
|
|
987
|
-
else if (effectiveCodepoint === ARROW_CODEPOINTS.right)
|
|
988
|
-
keyName = "right";
|
|
989
|
-
else if (effectiveCodepoint >= 48 && effectiveCodepoint <= 57)
|
|
990
|
-
keyName = String.fromCharCode(effectiveCodepoint);
|
|
991
|
-
else if (effectiveCodepoint >= 97 && effectiveCodepoint <= 122)
|
|
992
|
-
keyName = String.fromCharCode(effectiveCodepoint);
|
|
993
|
-
else if (SYMBOL_KEYS.has(String.fromCharCode(effectiveCodepoint)))
|
|
994
|
-
keyName = String.fromCharCode(effectiveCodepoint);
|
|
995
|
-
if (!keyName)
|
|
996
|
-
return undefined;
|
|
997
|
-
return formatKeyNameWithModifiers(keyName, modifier);
|
|
998
|
-
}
|
|
999
|
-
export function parseKey(data) {
|
|
1000
|
-
const kitty = parseKittySequence(data);
|
|
1001
|
-
if (kitty) {
|
|
1002
|
-
return formatParsedKey(kitty.codepoint, kitty.modifier, kitty.baseLayoutKey);
|
|
1003
|
-
}
|
|
1004
|
-
const modifyOtherKeys = parseModifyOtherKeysSequence(data);
|
|
1005
|
-
if (modifyOtherKeys) {
|
|
1006
|
-
return formatParsedKey(modifyOtherKeys.codepoint, modifyOtherKeys.modifier);
|
|
1007
|
-
}
|
|
1008
|
-
// Mode-aware legacy sequences
|
|
1009
|
-
// When Kitty protocol is active, ambiguous sequences are interpreted as custom terminal mappings:
|
|
1010
|
-
// - \x1b\r = shift+enter (Kitty mapping), not alt+enter
|
|
1011
|
-
// - \n = shift+enter (Ghostty mapping)
|
|
1012
|
-
if (_kittyProtocolActive) {
|
|
1013
|
-
if (data === "\x1b\r" || data === "\n")
|
|
1014
|
-
return "shift+enter";
|
|
1015
|
-
}
|
|
1016
|
-
const legacySequenceKeyId = LEGACY_SEQUENCE_KEY_IDS[data];
|
|
1017
|
-
if (legacySequenceKeyId)
|
|
1018
|
-
return legacySequenceKeyId;
|
|
1019
|
-
// Legacy sequences (used when Kitty protocol is not active, or for unambiguous sequences)
|
|
1020
|
-
if (data === "\x1b")
|
|
1021
|
-
return "escape";
|
|
1022
|
-
if (data === "\x1c")
|
|
1023
|
-
return "ctrl+\\";
|
|
1024
|
-
if (data === "\x1d")
|
|
1025
|
-
return "ctrl+]";
|
|
1026
|
-
if (data === "\x1f")
|
|
1027
|
-
return "ctrl+-";
|
|
1028
|
-
if (data === "\x1b\x1b")
|
|
1029
|
-
return "ctrl+alt+[";
|
|
1030
|
-
if (data === "\x1b\x1c")
|
|
1031
|
-
return "ctrl+alt+\\";
|
|
1032
|
-
if (data === "\x1b\x1d")
|
|
1033
|
-
return "ctrl+alt+]";
|
|
1034
|
-
if (data === "\x1b\x1f")
|
|
1035
|
-
return "ctrl+alt+-";
|
|
1036
|
-
if (data === "\t")
|
|
1037
|
-
return "tab";
|
|
1038
|
-
if (data === "\r" || (!_kittyProtocolActive && data === "\n") || data === "\x1bOM")
|
|
1039
|
-
return "enter";
|
|
1040
|
-
if (data === "\x00")
|
|
1041
|
-
return "ctrl+space";
|
|
1042
|
-
if (data === " ")
|
|
1043
|
-
return "space";
|
|
1044
|
-
if (data === "\x7f")
|
|
1045
|
-
return "backspace";
|
|
1046
|
-
if (data === "\x08")
|
|
1047
|
-
return isWindowsTerminalSession() ? "ctrl+backspace" : "backspace";
|
|
1048
|
-
if (data === "\x1b[Z")
|
|
1049
|
-
return "shift+tab";
|
|
1050
|
-
if (!_kittyProtocolActive && data === "\x1b\r")
|
|
1051
|
-
return "alt+enter";
|
|
1052
|
-
if (!_kittyProtocolActive && data === "\x1b ")
|
|
1053
|
-
return "alt+space";
|
|
1054
|
-
if (data === "\x1b\x7f" || data === "\x1b\b")
|
|
1055
|
-
return "alt+backspace";
|
|
1056
|
-
if (!_kittyProtocolActive && data === "\x1bB")
|
|
1057
|
-
return "alt+left";
|
|
1058
|
-
if (!_kittyProtocolActive && data === "\x1bF")
|
|
1059
|
-
return "alt+right";
|
|
1060
|
-
if (!_kittyProtocolActive && data.length === 2 && data[0] === "\x1b") {
|
|
1061
|
-
const code = data.charCodeAt(1);
|
|
1062
|
-
if (code >= 1 && code <= 26) {
|
|
1063
|
-
return `ctrl+alt+${String.fromCharCode(code + 96)}`;
|
|
1064
|
-
}
|
|
1065
|
-
// Legacy alt+letter/digit (ESC followed by the key)
|
|
1066
|
-
if ((code >= 97 && code <= 122) || (code >= 48 && code <= 57)) {
|
|
1067
|
-
return `alt+${String.fromCharCode(code)}`;
|
|
1068
|
-
}
|
|
1069
|
-
}
|
|
1070
|
-
if (data === "\x1b[A")
|
|
1071
|
-
return "up";
|
|
1072
|
-
if (data === "\x1b[B")
|
|
1073
|
-
return "down";
|
|
1074
|
-
if (data === "\x1b[C")
|
|
1075
|
-
return "right";
|
|
1076
|
-
if (data === "\x1b[D")
|
|
1077
|
-
return "left";
|
|
1078
|
-
if (data === "\x1b[H" || data === "\x1bOH")
|
|
1079
|
-
return "home";
|
|
1080
|
-
if (data === "\x1b[F" || data === "\x1bOF")
|
|
1081
|
-
return "end";
|
|
1082
|
-
if (data === "\x1b[3~")
|
|
1083
|
-
return "delete";
|
|
1084
|
-
if (data === "\x1b[5~")
|
|
1085
|
-
return "pageUp";
|
|
1086
|
-
if (data === "\x1b[6~")
|
|
1087
|
-
return "pageDown";
|
|
1088
|
-
// Raw Ctrl+letter
|
|
1089
|
-
if (data.length === 1) {
|
|
1090
|
-
const code = data.charCodeAt(0);
|
|
1091
|
-
if (code >= 1 && code <= 26) {
|
|
1092
|
-
return `ctrl+${String.fromCharCode(code + 96)}`;
|
|
1093
|
-
}
|
|
1094
|
-
if (code >= 32 && code <= 126) {
|
|
1095
|
-
return data;
|
|
1096
|
-
}
|
|
1097
|
-
}
|
|
1098
|
-
return undefined;
|
|
1099
|
-
}
|
|
1100
|
-
// =============================================================================
|
|
1101
|
-
// Kitty CSI-u Printable Decoding
|
|
1102
|
-
// =============================================================================
|
|
1103
|
-
const KITTY_CSI_U_REGEX = /^\x1b\[(\d+)(?::(\d*))?(?::(\d+))?(?:;(\d+))?(?::(\d+))?u$/;
|
|
1104
|
-
const KITTY_PRINTABLE_ALLOWED_MODIFIERS = MODIFIERS.shift | LOCK_MASK;
|
|
1105
|
-
/**
|
|
1106
|
-
* Decode a Kitty CSI-u sequence into a printable character, if applicable.
|
|
1107
|
-
*
|
|
1108
|
-
* When Kitty keyboard protocol flag 1 (disambiguate) is active, terminals send
|
|
1109
|
-
* CSI-u sequences for all keys, including plain printable characters. This
|
|
1110
|
-
* function extracts the printable character from such sequences.
|
|
1111
|
-
*
|
|
1112
|
-
* Only accepts plain or Shift-modified keys. Rejects Ctrl, Alt, and unsupported
|
|
1113
|
-
* modifier combinations (those are handled by keybinding matching instead).
|
|
1114
|
-
* Prefers the shifted keycode when Shift is held and a shifted key is reported.
|
|
1115
|
-
*
|
|
1116
|
-
* @param data - Raw input data from terminal
|
|
1117
|
-
* @returns The printable character, or undefined if not a printable CSI-u sequence
|
|
1118
|
-
*/
|
|
1119
|
-
export function decodeKittyPrintable(data) {
|
|
1120
|
-
const match = data.match(KITTY_CSI_U_REGEX);
|
|
1121
|
-
if (!match)
|
|
1122
|
-
return undefined;
|
|
1123
|
-
// CSI-u groups: <codepoint>[:<shifted>[:<base>]];<mod>[:<event>]u
|
|
1124
|
-
const codepoint = Number.parseInt(match[1] ?? "", 10);
|
|
1125
|
-
if (!Number.isFinite(codepoint))
|
|
1126
|
-
return undefined;
|
|
1127
|
-
const shiftedKey = match[2] && match[2].length > 0 ? Number.parseInt(match[2], 10) : undefined;
|
|
1128
|
-
const modValue = match[4] ? Number.parseInt(match[4], 10) : 1;
|
|
1129
|
-
// Modifiers are 1-indexed in CSI-u; normalize to our bitmask.
|
|
1130
|
-
const modifier = Number.isFinite(modValue) ? modValue - 1 : 0;
|
|
1131
|
-
// Only accept printable CSI-u input for plain or Shift-modified text keys.
|
|
1132
|
-
// Reject unsupported modifier bits (e.g. Super/Meta) to avoid inserting
|
|
1133
|
-
// characters from modifier-only terminal events.
|
|
1134
|
-
if ((modifier & ~KITTY_PRINTABLE_ALLOWED_MODIFIERS) !== 0)
|
|
1135
|
-
return undefined;
|
|
1136
|
-
if (modifier & (MODIFIERS.alt | MODIFIERS.ctrl))
|
|
1137
|
-
return undefined;
|
|
1138
|
-
// Prefer the shifted keycode when Shift is held.
|
|
1139
|
-
let effectiveCodepoint = codepoint;
|
|
1140
|
-
if (modifier & MODIFIERS.shift && typeof shiftedKey === "number") {
|
|
1141
|
-
effectiveCodepoint = shiftedKey;
|
|
1142
|
-
}
|
|
1143
|
-
effectiveCodepoint = normalizeKittyFunctionalCodepoint(effectiveCodepoint);
|
|
1144
|
-
// Drop control characters or invalid codepoints.
|
|
1145
|
-
if (!Number.isFinite(effectiveCodepoint) || effectiveCodepoint < 32)
|
|
1146
|
-
return undefined;
|
|
1147
|
-
try {
|
|
1148
|
-
return String.fromCodePoint(effectiveCodepoint);
|
|
1149
|
-
}
|
|
1150
|
-
catch {
|
|
1151
|
-
return undefined;
|
|
1152
|
-
}
|
|
1153
|
-
}
|
|
1154
|
-
function decodeModifyOtherKeysPrintable(data) {
|
|
1155
|
-
const parsed = parseModifyOtherKeysSequence(data);
|
|
1156
|
-
if (!parsed)
|
|
1157
|
-
return undefined;
|
|
1158
|
-
const modifier = parsed.modifier & ~LOCK_MASK;
|
|
1159
|
-
if ((modifier & ~MODIFIERS.shift) !== 0)
|
|
1160
|
-
return undefined;
|
|
1161
|
-
if (!Number.isFinite(parsed.codepoint) || parsed.codepoint < 32)
|
|
1162
|
-
return undefined;
|
|
1163
|
-
try {
|
|
1164
|
-
return String.fromCodePoint(parsed.codepoint);
|
|
1165
|
-
}
|
|
1166
|
-
catch {
|
|
1167
|
-
return undefined;
|
|
1168
|
-
}
|
|
1169
|
-
}
|
|
1170
|
-
export function decodePrintableKey(data) {
|
|
1171
|
-
return decodeKittyPrintable(data) ?? decodeModifyOtherKeysPrintable(data);
|
|
1172
|
-
}
|
|
1173
|
-
//# sourceMappingURL=keys.js.map
|