Files
NapCatQQ/.pnpm-store/v3/files/5d/b60dca199e2a525f98ef918af183af00df6c07c807e5d31ec97d93f462e25744cc647b7811bc8631008df2d1887d36a8ad30e35dfd0f7c2fbf54727c11e6d6
TanTan e311ca3275
Build NapCat Artifacts / Type Check & Test (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

27 lines
987 B
Plaintext

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.IndexFromMappedKey = IndexFromMappedKey;
const indexed_1 = require("./indexed");
const index_1 = require("../mapped/index");
const value_1 = require("../clone/value");
// prettier-ignore
function MappedIndexPropertyKey(type, key, options) {
return { [key]: (0, indexed_1.Index)(type, [key], (0, value_1.Clone)(options)) };
}
// prettier-ignore
function MappedIndexPropertyKeys(type, propertyKeys, options) {
return propertyKeys.reduce((result, left) => {
return { ...result, ...MappedIndexPropertyKey(type, left, options) };
}, {});
}
// prettier-ignore
function MappedIndexProperties(type, mappedKey, options) {
return MappedIndexPropertyKeys(type, mappedKey.keys, options);
}
// prettier-ignore
function IndexFromMappedKey(type, mappedKey, options) {
const properties = MappedIndexProperties(type, mappedKey, options);
return (0, index_1.MappedResult)(properties);
}