inferred-types 0.44.0 → 0.45.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/dist/constants/Characters.d.ts +2 -0
- package/dist/constants/Characters.d.ts.map +1 -0
- package/dist/constants/Characters.js +5 -0
- package/dist/constants/NetworkConstants.d.ts +29 -0
- package/dist/constants/NetworkConstants.d.ts.map +1 -0
- package/dist/constants/NetworkConstants.js +83 -0
- package/dist/constants/Phone.d.ts +8 -0
- package/dist/constants/Phone.d.ts.map +1 -0
- package/dist/constants/Phone.js +262 -0
- package/dist/constants/ProxmoxConstants.d.ts +2 -0
- package/dist/constants/ProxmoxConstants.d.ts.map +1 -0
- package/dist/constants/ProxmoxConstants.js +3 -0
- package/dist/constants/index.d.ts +4 -1
- package/dist/constants/index.d.ts.map +1 -1
- package/dist/constants/index.js +4 -1
- package/dist/constants/tsconfig.tsbuildinfo +1 -1
- package/dist/inferred-types/index.cjs +1657 -1029
- package/dist/inferred-types/tsconfig.tsbuildinfo +1 -1
- package/dist/runtime/api/defineApi.d.ts +56 -0
- package/dist/runtime/api/defineApi.d.ts.map +1 -0
- package/dist/runtime/api/defineApi.js +97 -0
- package/dist/runtime/api/handleDoneFn.d.ts.map +1 -0
- package/dist/runtime/api/index.d.ts +3 -0
- package/dist/runtime/api/index.d.ts.map +1 -0
- package/dist/runtime/api/index.js +2 -0
- package/dist/runtime/boolean-logic/ifArrayPartial.d.ts +1 -1
- package/dist/runtime/boolean-logic/ifArrayPartial.d.ts.map +1 -1
- package/dist/runtime/boolean-logic/ifArrayPartial.js +1 -1
- package/dist/runtime/boolean-logic/ifLength.d.ts.map +1 -1
- package/dist/runtime/boolean-logic/ifScalar.d.ts.map +1 -1
- package/dist/runtime/boolean-logic/ifScalar.js +1 -1
- package/dist/runtime/boolean-logic/index.d.ts +0 -1
- package/dist/runtime/boolean-logic/index.d.ts.map +1 -1
- package/dist/runtime/boolean-logic/index.js +0 -1
- package/dist/runtime/dictionary/defineOptions.d.ts +26 -0
- package/dist/runtime/dictionary/defineOptions.d.ts.map +1 -0
- package/dist/runtime/dictionary/defineOptions.js +30 -0
- package/dist/runtime/dictionary/keysOf.d.ts +1 -1
- package/dist/runtime/dictionary/keysOf.d.ts.map +1 -1
- package/dist/runtime/dictionary/withKeys.d.ts +1 -1
- package/dist/runtime/errors/KindError.d.ts +2 -2
- package/dist/runtime/errors/KindError.d.ts.map +1 -1
- package/dist/runtime/functions/index.d.ts +1 -0
- package/dist/runtime/functions/index.d.ts.map +1 -1
- package/dist/runtime/functions/index.js +1 -0
- package/dist/runtime/functions/wrapFn.d.ts +2 -0
- package/dist/runtime/functions/wrapFn.d.ts.map +1 -0
- package/dist/runtime/functions/wrapFn.js +24 -0
- package/dist/runtime/index.d.ts +2 -1
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/index.js +2 -10
- package/dist/runtime/lists/find.d.ts +1 -1
- package/dist/runtime/lists/find.d.ts.map +1 -1
- package/dist/runtime/lists/intersection.d.ts.map +1 -1
- package/dist/runtime/lists/intersection.js +2 -1
- package/dist/runtime/literals/asPhoneNumber.d.ts +10 -0
- package/dist/runtime/literals/asPhoneNumber.d.ts.map +1 -0
- package/dist/runtime/literals/asPhoneNumber.js +62 -0
- package/dist/runtime/literals/index.d.ts +5 -0
- package/dist/runtime/literals/index.d.ts.map +1 -1
- package/dist/runtime/literals/index.js +5 -0
- package/dist/runtime/literals/retainChars.d.ts +16 -0
- package/dist/runtime/literals/retainChars.d.ts.map +1 -0
- package/dist/runtime/literals/retainChars.js +17 -0
- package/dist/runtime/literals/retainWhile.d.ts +11 -0
- package/dist/runtime/literals/retainWhile.d.ts.map +1 -0
- package/dist/runtime/literals/retainWhile.js +12 -0
- package/dist/runtime/literals/stripChars.d.ts +10 -0
- package/dist/runtime/literals/stripChars.d.ts.map +1 -0
- package/dist/runtime/literals/stripChars.js +11 -0
- package/dist/runtime/literals/stripLeading.d.ts +3 -3
- package/dist/runtime/literals/stripLeading.d.ts.map +1 -1
- package/dist/runtime/literals/stripLeading.js +5 -5
- package/dist/runtime/literals/takeNumericCharacters.d.ts +9 -0
- package/dist/runtime/literals/takeNumericCharacters.d.ts.map +1 -0
- package/dist/runtime/literals/takeNumericCharacters.js +12 -0
- package/dist/runtime/literals/unset.d.ts +8 -0
- package/dist/runtime/literals/unset.d.ts.map +1 -0
- package/dist/runtime/literals/unset.js +14 -0
- package/dist/runtime/meta/index.d.ts +3 -0
- package/dist/runtime/meta/index.d.ts.map +1 -0
- package/dist/runtime/meta/index.js +2 -0
- package/dist/runtime/meta/urlMeta.d.ts +52 -0
- package/dist/runtime/meta/urlMeta.d.ts.map +1 -0
- package/dist/runtime/meta/urlMeta.js +57 -0
- package/dist/runtime/meta/youtube-meta.d.ts +38 -0
- package/dist/runtime/meta/youtube-meta.d.ts.map +1 -0
- package/dist/runtime/meta/youtube-meta.js +67 -0
- package/dist/runtime/runtime-types/dict.d.ts +2 -2
- package/dist/runtime/runtime-types/dict.d.ts.map +1 -1
- package/dist/runtime/runtime-types/ip6Prefix.d.ts +1 -1
- package/dist/runtime/runtime-types/parse.d.ts +1 -1
- package/dist/runtime/runtime-types/shape-helpers/getTokenData.d.ts +1 -1
- package/dist/runtime/runtime-types/shape-helpers/getTokenName.d.ts +1 -1
- package/dist/runtime/runtime-types/shape-helpers/singletons.d.ts.map +1 -1
- package/dist/runtime/runtime-types/shape-helpers/singletons.js +1 -1
- package/dist/runtime/runtime-types/shape.d.ts +1 -1
- package/dist/runtime/runtime-types/shape.js +1 -1
- package/dist/runtime/tsconfig.tsbuildinfo +1 -1
- package/dist/runtime/type-conversion/asChars.d.ts +8 -0
- package/dist/runtime/type-conversion/asChars.d.ts.map +1 -0
- package/dist/runtime/type-conversion/asChars.js +8 -0
- package/dist/runtime/type-conversion/index.d.ts +2 -0
- package/dist/runtime/type-conversion/index.d.ts.map +1 -1
- package/dist/runtime/type-conversion/index.js +2 -0
- package/dist/runtime/type-conversion/ip6GroupExpansion.d.ts +14 -0
- package/dist/runtime/type-conversion/ip6GroupExpansion.d.ts.map +1 -0
- package/dist/runtime/type-conversion/ip6GroupExpansion.js +15 -0
- package/dist/runtime/type-guards/api-tg.d.ts +33 -0
- package/dist/runtime/type-guards/api-tg.d.ts.map +1 -0
- package/dist/runtime/type-guards/api-tg.js +38 -0
- package/dist/runtime/type-guards/hasWhitespace.d.ts +7 -0
- package/dist/runtime/type-guards/hasWhitespace.d.ts.map +1 -0
- package/dist/runtime/type-guards/hasWhitespace.js +11 -0
- package/dist/runtime/type-guards/index.d.ts +11 -0
- package/dist/runtime/type-guards/index.d.ts.map +1 -1
- package/dist/runtime/type-guards/index.js +11 -0
- package/dist/runtime/type-guards/isConstant.d.ts +6 -0
- package/dist/runtime/type-guards/isConstant.d.ts.map +1 -1
- package/dist/runtime/type-guards/isConstant.js +12 -2
- package/dist/runtime/type-guards/isEmail.d.ts +7 -0
- package/dist/runtime/type-guards/isEmail.d.ts.map +1 -0
- package/dist/runtime/type-guards/isEmail.js +11 -0
- package/dist/runtime/type-guards/isHexadecimal.d.ts +8 -0
- package/dist/runtime/type-guards/isHexadecimal.d.ts.map +1 -0
- package/dist/runtime/type-guards/isHexadecimal.js +13 -0
- package/dist/runtime/type-guards/isPhoneNumber.d.ts +14 -0
- package/dist/runtime/type-guards/isPhoneNumber.d.ts.map +1 -0
- package/dist/runtime/type-guards/isPhoneNumber.js +26 -0
- package/dist/runtime/type-guards/isSpecificConstant.js +2 -3
- package/dist/runtime/type-guards/isTrimmable.d.ts +7 -0
- package/dist/runtime/type-guards/isTrimmable.d.ts.map +1 -0
- package/dist/runtime/type-guards/isTrimmable.js +9 -0
- package/dist/runtime/type-guards/isUnset.d.ts +18 -0
- package/dist/runtime/type-guards/isUnset.d.ts.map +1 -0
- package/dist/runtime/type-guards/isUnset.js +23 -0
- package/dist/runtime/type-guards/isUrl.d.ts +2 -4
- package/dist/runtime/type-guards/isUrl.d.ts.map +1 -1
- package/dist/runtime/type-guards/isUrl.js +2 -3
- package/dist/runtime/type-guards/network-tg.d.ts +54 -0
- package/dist/runtime/type-guards/network-tg.d.ts.map +1 -0
- package/dist/runtime/type-guards/network-tg.js +94 -0
- package/dist/runtime/type-guards/repos.d.ts +6 -6
- package/dist/runtime/type-guards/repos.d.ts.map +1 -1
- package/dist/runtime/type-guards/youtube.d.ts +44 -0
- package/dist/runtime/type-guards/youtube.d.ts.map +1 -0
- package/dist/runtime/type-guards/youtube.js +84 -0
- package/dist/types/api/api.d.ts +96 -37
- package/dist/types/api/api.d.ts.map +1 -1
- package/dist/types/base-types/fns/EscapeFunction.d.ts +22 -0
- package/dist/types/base-types/fns/EscapeFunction.d.ts.map +1 -0
- package/dist/types/base-types/fns/OptionalParamFn.d.ts +30 -0
- package/dist/types/base-types/fns/OptionalParamFn.d.ts.map +1 -0
- package/dist/types/base-types/fns/index.d.ts +2 -0
- package/dist/types/base-types/fns/index.d.ts.map +1 -1
- package/dist/types/base-types/fns/index.js +2 -0
- package/dist/types/boolean-logic/branching/If.d.ts +2 -3
- package/dist/types/boolean-logic/branching/If.d.ts.map +1 -1
- package/dist/types/boolean-logic/branching/IfUnset.d.ts +12 -0
- package/dist/types/boolean-logic/branching/IfUnset.d.ts.map +1 -0
- package/dist/types/boolean-logic/branching/OnPass.d.ts +4 -3
- package/dist/types/boolean-logic/branching/OnPass.d.ts.map +1 -1
- package/dist/types/boolean-logic/branching/WhenNever.d.ts +11 -0
- package/dist/types/boolean-logic/branching/WhenNever.d.ts.map +1 -0
- package/dist/types/boolean-logic/branching/index.d.ts +2 -0
- package/dist/types/boolean-logic/branching/index.d.ts.map +1 -1
- package/dist/types/boolean-logic/branching/index.js +2 -0
- package/dist/types/boolean-logic/combinators/And.d.ts +1 -1
- package/dist/types/boolean-logic/combinators/And.d.ts.map +1 -1
- package/dist/types/boolean-logic/combinators/Compare.d.ts +3 -3
- package/dist/types/boolean-logic/combinators/Compare.d.ts.map +1 -1
- package/dist/types/boolean-logic/combinators/Not.d.ts +5 -6
- package/dist/types/boolean-logic/combinators/Not.d.ts.map +1 -1
- package/dist/types/boolean-logic/combinators/Some.d.ts +8 -0
- package/dist/types/boolean-logic/combinators/Some.d.ts.map +1 -0
- package/dist/types/boolean-logic/combinators/Some.js +1 -0
- package/dist/types/boolean-logic/combinators/index.d.ts +1 -0
- package/dist/types/boolean-logic/combinators/index.d.ts.map +1 -1
- package/dist/types/boolean-logic/combinators/index.js +1 -0
- package/dist/types/boolean-logic/narrowing/AsDoneFn.d.ts +2 -2
- package/dist/types/boolean-logic/narrowing/AsDoneFn.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/ApiOperators.d.ts +11 -0
- package/dist/types/boolean-logic/operators/ApiOperators.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/ApiOperators.js +1 -0
- package/dist/types/boolean-logic/operators/Extends.d.ts +2 -1
- package/dist/types/boolean-logic/operators/Extends.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/HasSameValues.d.ts +4 -3
- package/dist/types/boolean-logic/operators/HasSameValues.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsBoolean.d.ts +2 -1
- package/dist/types/boolean-logic/operators/IsBoolean.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsCssHexadecimal.d.ts +9 -0
- package/dist/types/boolean-logic/operators/IsCssHexadecimal.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/IsCssHexadecimal.js +1 -0
- package/dist/types/boolean-logic/operators/IsEqual.d.ts +7 -1
- package/dist/types/boolean-logic/operators/IsEqual.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsGreaterThan.d.ts +2 -2
- package/dist/types/boolean-logic/operators/IsGreaterThan.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsLessThan.d.ts +13 -0
- package/dist/types/boolean-logic/operators/IsLessThan.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/IsLessThan.js +1 -0
- package/dist/types/boolean-logic/operators/IsNever.d.ts +2 -1
- package/dist/types/boolean-logic/operators/IsNever.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsNumber.d.ts +2 -2
- package/dist/types/boolean-logic/operators/IsNumber.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsString.d.ts +2 -2
- package/dist/types/boolean-logic/operators/IsString.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/IsUnset.d.ts +9 -0
- package/dist/types/boolean-logic/operators/IsUnset.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/IsUnset.js +1 -0
- package/dist/types/boolean-logic/operators/IsUrl.d.ts +35 -0
- package/dist/types/boolean-logic/operators/IsUrl.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/IsUrl.js +1 -0
- package/dist/types/boolean-logic/operators/Network-operators.d.ts +71 -0
- package/dist/types/boolean-logic/operators/Network-operators.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/Network-operators.js +1 -0
- package/dist/types/boolean-logic/operators/PhoneOperators.d.ts +33 -0
- package/dist/types/boolean-logic/operators/PhoneOperators.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/PhoneOperators.js +1 -0
- package/dist/types/boolean-logic/operators/YouTube-operators.d.ts +32 -0
- package/dist/types/boolean-logic/operators/YouTube-operators.d.ts.map +1 -0
- package/dist/types/boolean-logic/operators/YouTube-operators.js +1 -0
- package/dist/types/boolean-logic/operators/index.d.ts +7 -1
- package/dist/types/boolean-logic/operators/index.d.ts.map +1 -1
- package/dist/types/boolean-logic/operators/index.js +7 -1
- package/dist/types/dictionary/Keys.d.ts +58 -4
- package/dist/types/dictionary/Keys.d.ts.map +1 -1
- package/dist/types/dictionary/KvFn.d.ts +2 -2
- package/dist/types/dictionary/KvFn.d.ts.map +1 -1
- package/dist/types/dictionary/MakeKeysOptional.d.ts +12 -3
- package/dist/types/dictionary/MakeKeysOptional.d.ts.map +1 -1
- package/dist/types/dictionary/MakeKeysRequired.d.ts +14 -0
- package/dist/types/dictionary/MakeKeysRequired.d.ts.map +1 -0
- package/dist/types/dictionary/MakeKeysRequired.js +1 -0
- package/dist/types/dictionary/OptionalKeys.d.ts +19 -4
- package/dist/types/dictionary/OptionalKeys.d.ts.map +1 -1
- package/dist/types/dictionary/OptionalKeys.js +1 -0
- package/dist/types/dictionary/RequiredKeys.d.ts +14 -6
- package/dist/types/dictionary/RequiredKeys.d.ts.map +1 -1
- package/dist/types/dictionary/Values.d.ts +2 -2
- package/dist/types/dictionary/Values.d.ts.map +1 -1
- package/dist/types/dictionary/index.d.ts +1 -2
- package/dist/types/dictionary/index.d.ts.map +1 -1
- package/dist/types/dictionary/index.js +1 -2
- package/dist/types/errors/KindError.d.ts +1 -1
- package/dist/types/errors/KindError.d.ts.map +1 -1
- package/dist/types/functions/FnFrom.d.ts +5 -0
- package/dist/types/functions/FnFrom.d.ts.map +1 -1
- package/dist/types/functions/{Fn.d.ts → FnWithDescription.d.ts} +2 -2
- package/dist/types/functions/FnWithDescription.d.ts.map +1 -0
- package/dist/types/functions/FnWithDescription.js +1 -0
- package/dist/types/functions/WrapperFn.d.ts +23 -0
- package/dist/types/functions/WrapperFn.d.ts.map +1 -0
- package/dist/types/functions/WrapperFn.js +1 -0
- package/dist/types/functions/index.d.ts +2 -1
- package/dist/types/functions/index.d.ts.map +1 -1
- package/dist/types/functions/index.js +2 -1
- package/dist/types/lists/ConvertSet.d.ts +2 -2
- package/dist/types/lists/ConvertSet.d.ts.map +1 -1
- package/dist/types/lists/Find.d.ts +7 -18
- package/dist/types/lists/Find.d.ts.map +1 -1
- package/dist/types/literals/DoneFnTuple.d.ts +3 -3
- package/dist/types/literals/DoneFnTuple.d.ts.map +1 -1
- package/dist/types/literals/Unset.d.ts +13 -0
- package/dist/types/literals/Unset.d.ts.map +1 -0
- package/dist/types/literals/Unset.js +1 -0
- package/dist/types/literals/index.d.ts +1 -0
- package/dist/types/literals/index.d.ts.map +1 -1
- package/dist/types/literals/index.js +1 -0
- package/dist/types/numeric-literals/NumberLike.d.ts +1 -1
- package/dist/types/numeric-literals/NumberLike.d.ts.map +1 -1
- package/dist/types/string-literals/Proxmox.d.ts +7 -0
- package/dist/types/string-literals/Proxmox.d.ts.map +1 -0
- package/dist/types/string-literals/Proxmox.js +1 -0
- package/dist/types/string-literals/RetainUntil.d.ts +33 -0
- package/dist/types/string-literals/RetainUntil.d.ts.map +1 -0
- package/dist/types/string-literals/RetainUntil.js +1 -0
- package/dist/types/string-literals/Split.d.ts +3 -3
- package/dist/types/string-literals/Split.d.ts.map +1 -1
- package/dist/types/string-literals/StripAfter.d.ts +2 -2
- package/dist/types/string-literals/StripAfter.d.ts.map +1 -1
- package/dist/types/string-literals/StripBefore.d.ts +2 -2
- package/dist/types/string-literals/StripBefore.d.ts.map +1 -1
- package/dist/types/string-literals/StripLeading.d.ts +2 -2
- package/dist/types/string-literals/StripLeading.d.ts.map +1 -1
- package/dist/types/string-literals/StripUntil.d.ts +18 -0
- package/dist/types/string-literals/StripUntil.d.ts.map +1 -0
- package/dist/types/string-literals/StripUntil.js +1 -0
- package/dist/types/string-literals/character-sets/DomainName.d.ts +17 -18
- package/dist/types/string-literals/character-sets/DomainName.d.ts.map +1 -1
- package/dist/types/string-literals/character-sets/IpAddress.d.ts +28 -4
- package/dist/types/string-literals/character-sets/IpAddress.d.ts.map +1 -1
- package/dist/types/string-literals/character-sets/Optional.d.ts +14 -0
- package/dist/types/string-literals/character-sets/Optional.d.ts.map +1 -0
- package/dist/types/string-literals/character-sets/Optional.js +1 -0
- package/dist/types/string-literals/character-sets/Repos.d.ts.map +1 -1
- package/dist/types/string-literals/character-sets/Url.d.ts +85 -37
- package/dist/types/string-literals/character-sets/Url.d.ts.map +1 -1
- package/dist/types/string-literals/character-sets/Url.js +1 -0
- package/dist/types/string-literals/character-sets/Whitespace.d.ts +3 -1
- package/dist/types/string-literals/character-sets/Whitespace.d.ts.map +1 -1
- package/dist/types/string-literals/character-sets/YouTube.d.ts +127 -0
- package/dist/types/string-literals/character-sets/YouTube.d.ts.map +1 -0
- package/dist/types/string-literals/character-sets/YouTube.js +1 -0
- package/dist/types/string-literals/character-sets/index.d.ts +3 -0
- package/dist/types/string-literals/character-sets/index.d.ts.map +1 -1
- package/dist/types/string-literals/character-sets/index.js +3 -0
- package/dist/types/string-literals/character-sets/phone.d.ts +192 -0
- package/dist/types/string-literals/character-sets/phone.d.ts.map +1 -0
- package/dist/types/string-literals/character-sets/phone.js +1 -0
- package/dist/types/string-literals/index.d.ts +2 -0
- package/dist/types/string-literals/index.d.ts.map +1 -1
- package/dist/types/string-literals/index.js +2 -0
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/dist/types/type-conversion/ReduceValues.d.ts +19 -0
- package/dist/types/type-conversion/ReduceValues.d.ts.map +1 -0
- package/dist/types/type-conversion/ReduceValues.js +1 -0
- package/dist/types/type-conversion/ReturnValues.d.ts +10 -6
- package/dist/types/type-conversion/ReturnValues.d.ts.map +1 -1
- package/dist/types/type-conversion/Trim.d.ts +3 -1
- package/dist/types/type-conversion/Trim.d.ts.map +1 -1
- package/dist/types/type-conversion/UnionFilter.d.ts +2 -2
- package/dist/types/type-conversion/UnionFilter.d.ts.map +1 -1
- package/dist/types/type-conversion/form-fields.d.ts +5 -1
- package/dist/types/type-conversion/form-fields.d.ts.map +1 -1
- package/dist/types/type-conversion/index.d.ts +1 -0
- package/dist/types/type-conversion/index.d.ts.map +1 -1
- package/dist/types/type-conversion/index.js +1 -0
- package/package.json +17 -11
- package/dist/constants/Network.d.ts +0 -22
- package/dist/constants/Network.d.ts.map +0 -1
- package/dist/constants/Network.js +0 -21
- package/dist/runtime/boolean-logic/handleDoneFn.d.ts.map +0 -1
- package/dist/types/boolean-logic/operators/IsHexadecimal.d.ts +0 -9
- package/dist/types/boolean-logic/operators/IsHexadecimal.d.ts.map +0 -1
- package/dist/types/dictionary/PrivateKeys.d.ts +0 -17
- package/dist/types/dictionary/PrivateKeys.d.ts.map +0 -1
- package/dist/types/dictionary/PublicKeys.d.ts +0 -10
- package/dist/types/dictionary/PublicKeys.d.ts.map +0 -1
- package/dist/types/functions/Fn.d.ts.map +0 -1
- /package/dist/runtime/{boolean-logic → api}/handleDoneFn.d.ts +0 -0
- /package/dist/runtime/{boolean-logic → api}/handleDoneFn.js +0 -0
- /package/dist/types/{boolean-logic/operators/IsHexadecimal.js → base-types/fns/EscapeFunction.js} +0 -0
- /package/dist/types/{dictionary/PrivateKeys.js → base-types/fns/OptionalParamFn.js} +0 -0
- /package/dist/types/{dictionary/PublicKeys.js → boolean-logic/branching/IfUnset.js} +0 -0
- /package/dist/types/{functions/Fn.js → boolean-logic/branching/WhenNever.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PhoneOperators.d.ts","sourceRoot":"","sources":["../../../../src/types/boolean-logic/operators/PhoneOperators.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,OAAO,EAAE,MAAM,EAAE,gBAAgB,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAC5F,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAIpD;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,aAAa,CAAC,CAAC,IAAI,CAAC,SAAS,MAAM,GAC7C,eAAe,CAAC,CAAC,CAAC,SAAS,IAAI,GAC7B,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,SAAS,IAAI,GAClC,KAAK,GACL,IAAI,GACR,OAAO,GACP,KAAK,CAAC;AAGR;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,mBAAmB,CAC7B,MAAM,EACN,SAAS,SAAS,OAAO,GAAG,IAAI,IAC9B,MAAM,SAAS,MAAM,GACvB,eAAe,CAAC,MAAM,CAAC,SAAS,IAAI,GAChC,MAAM,CAAC,SAAS,CAAC,SAAS,IAAI,GAC5B,mBAAmB,CAAC,MAAM,CAAC,SAAS,gBAAgB,GAClD,IAAI,GACJ,KAAK,GACP,mBAAmB,CAAC,MAAM,CAAC,SAAS,EAAE,GACpC,KAAK,GACL,IAAI,GACZ,OAAO,GACP,KAAK,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { YouTubeVideoUrl, YouTubeUrl, IsStringLiteral, GetUrlQueryParams, YouTubePlaylistUrl } from "../../index";
|
|
2
|
+
type VideoUrlKind = "single-video" | "video-in-playlist" | "both";
|
|
3
|
+
/**
|
|
4
|
+
* **IsYouTubeUrl**`<T>`
|
|
5
|
+
*
|
|
6
|
+
* Boolean operator which returns _true_ when the string is a
|
|
7
|
+
* possible YouTube URL.
|
|
8
|
+
*/
|
|
9
|
+
export type IsYouTubeUrl<T> = [T] extends [string] ? [IsStringLiteral<T>] extends [true] ? [T] extends [YouTubeUrl] ? true : false : boolean : false;
|
|
10
|
+
type _VideoKind<TQueryParams extends string, TKind extends VideoUrlKind> = TQueryParams extends `${string}list=${string}` ? TKind extends "single-video" ? false : true : TKind extends "video-in-playlist" ? false : true;
|
|
11
|
+
/**
|
|
12
|
+
* **IsYouTubeVideoUrl**`<TTest,[TKind]>`
|
|
13
|
+
*
|
|
14
|
+
* Boolean operator which returns _true_ when the string is a
|
|
15
|
+
* possible YouTube URL which is for playing a video.
|
|
16
|
+
*
|
|
17
|
+
* **Note:** by default any URL which plays a video is allowed but
|
|
18
|
+
* you can change `TKind` to "single-video" or "video-in-playlist"
|
|
19
|
+
* to isolate to just one of the play styles.
|
|
20
|
+
*
|
|
21
|
+
* **Related:** `IsYouTubeUrl`, `YouTubeVideoUrl`
|
|
22
|
+
*/
|
|
23
|
+
export type IsYouTubeVideoUrl<TTest, TKind extends VideoUrlKind = "both"> = [TTest] extends [string] ? [IsStringLiteral<TTest>] extends [true] ? [TTest] extends [YouTubeVideoUrl] ? _VideoKind<GetUrlQueryParams<TTest>, TKind> : false : boolean : false;
|
|
24
|
+
/**
|
|
25
|
+
* **IsYouTubeUrl**`<T>`
|
|
26
|
+
*
|
|
27
|
+
* Boolean operator which returns _true_ when the string is a
|
|
28
|
+
* possible YouTube URL.
|
|
29
|
+
*/
|
|
30
|
+
export type IsYouTubePlaylist<T> = [T] extends [string] ? [IsStringLiteral<T>] extends [true] ? [T] extends [YouTubePlaylistUrl] ? true : false : boolean : false;
|
|
31
|
+
export {};
|
|
32
|
+
//# sourceMappingURL=YouTube-operators.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"YouTube-operators.d.ts","sourceRoot":"","sources":["../../../../src/types/boolean-logic/operators/YouTube-operators.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,eAAe,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,oBAAwB;AAEtH,KAAK,YAAY,GAAE,cAAc,GAAG,mBAAmB,GAAG,MAAM,CAAC;AAEjE;;;;;GAKG;AACH,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,GAChD,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,IAAI,CAAC,GACjC,CAAC,CAAC,CAAC,SAAS,CAAC,UAAU,CAAC,GACtB,IAAI,GACJ,KAAK,GACP,OAAO,GACT,KAAK,CAAC;AAER,KAAK,UAAU,CACb,YAAY,SAAS,MAAM,EAC3B,KAAK,SAAS,YAAY,IACxB,YAAY,SAAS,GAAG,MAAM,QAAQ,MAAM,EAAE,GAChD,KAAK,SAAS,cAAc,GAC1B,KAAK,GACL,IAAI,GACN,KAAK,SAAS,mBAAmB,GAC/B,KAAK,GACL,IAAI,CAAC;AAGT;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,iBAAiB,CAC3B,KAAK,EACL,KAAK,SAAS,YAAY,GAAG,MAAM,IACjC,CAAC,KAAK,CAAC,SAAS,CAAC,MAAM,CAAC,GAC1B,CAAC,eAAe,CAAC,KAAK,CAAC,CAAC,SAAS,CAAC,IAAI,CAAC,GACrC,CAAC,KAAK,CAAC,SAAS,CAAC,eAAe,CAAC,GAC/B,UAAU,CAAC,iBAAiB,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,GAC3C,KAAK,GACP,OAAO,GACT,KAAK,CAAC;AAGR;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,GACrD,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,IAAI,CAAC,GACjC,CAAC,CAAC,CAAC,SAAS,CAAC,kBAAkB,CAAC,GAC9B,IAAI,GACJ,KAAK,GACP,OAAO,GACT,KAAK,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export * from "./ApiOperators";
|
|
1
2
|
export * from "./AllExtend";
|
|
2
3
|
export * from "./AllLiteral";
|
|
3
4
|
export * from "./AreSameType";
|
|
@@ -32,6 +33,7 @@ export * from "./IsObjectLiteral";
|
|
|
32
33
|
export * from "./IsTuple";
|
|
33
34
|
export * from "./IsNothing";
|
|
34
35
|
export * from "./IsGreaterThan";
|
|
36
|
+
export * from "./IsLessThan";
|
|
35
37
|
export * from "./IsDotPath";
|
|
36
38
|
export * from "./IsSingularNoun";
|
|
37
39
|
export * from "./IsAllLowercase";
|
|
@@ -84,7 +86,11 @@ export * from "./IsLiteralUnion";
|
|
|
84
86
|
export * from "./IsNonLiteralUnion";
|
|
85
87
|
export * from "./HasRequiredProps";
|
|
86
88
|
export * from "./IsValidDotPath";
|
|
87
|
-
export * from "./
|
|
89
|
+
export * from "./IsCssHexadecimal";
|
|
88
90
|
export * from "./IsFloat";
|
|
89
91
|
export * from "./IsInteger";
|
|
92
|
+
export * from "./IsUrl";
|
|
93
|
+
export * from "./Network-operators";
|
|
94
|
+
export * from "./PhoneOperators";
|
|
95
|
+
export * from "./IsUnset";
|
|
90
96
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file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3
|
export * from "./AllLiteral.js";
|
|
3
4
|
export * from "./AreSameType.js";
|
|
@@ -32,6 +33,7 @@ export * from "./IsObjectLiteral.js";
|
|
|
32
33
|
export * from "./IsTuple.js";
|
|
33
34
|
export * from "./IsNothing.js";
|
|
34
35
|
export * from "./IsGreaterThan.js";
|
|
36
|
+
export * from "./IsLessThan.js";
|
|
35
37
|
export * from "./IsDotPath.js";
|
|
36
38
|
export * from "./IsSingularNoun.js";
|
|
37
39
|
export * from "./IsAllLowercase.js";
|
|
@@ -84,6 +86,10 @@ export * from "./IsLiteralUnion.js";
|
|
|
84
86
|
export * from "./IsNonLiteralUnion.js";
|
|
85
87
|
export * from "./HasRequiredProps.js";
|
|
86
88
|
export * from "./IsValidDotPath.js";
|
|
87
|
-
export * from "./
|
|
89
|
+
export * from "./IsCssHexadecimal.js";
|
|
88
90
|
export * from "./IsFloat.js";
|
|
89
91
|
export * from "./IsInteger.js";
|
|
92
|
+
export * from "./IsUrl.js";
|
|
93
|
+
export * from "./Network-operators.js";
|
|
94
|
+
export * from "./PhoneOperators.js";
|
|
95
|
+
export * from "./IsUnset.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type { Container, ObjectKey, UnionToTuple, NumericKeys, RemoveIndexKeys, IsVueRef, IsTuple, IsObjectLiteral } from "../index";
|
|
1
|
+
import type { Container, ObjectKey, UnionToTuple, NumericKeys, RemoveIndexKeys, IsVueRef, IsTuple, IsObjectLiteral, AfterFirst, StartsWith, First, TupleToUnion, As, Tuple, IsWideUnion } from "../index";
|
|
2
2
|
type _Keys<T extends object> = UnionToTuple<keyof RemoveIndexKeys<T>>;
|
|
3
3
|
type GetKeys<T extends object> = IsVueRef<T> extends true ? ["value"] : _Keys<T> extends [symbol] ? ObjectKey[] : _Keys<T> extends [] ? UnionToTuple<keyof T> extends [ObjectKey] ? (keyof T)[] : ObjectKey[] : _Keys<T>;
|
|
4
4
|
type ProcessObj<TContainer extends object> = GetKeys<TContainer>;
|
|
5
5
|
type ProcessTuple<TContainer extends readonly unknown[]> = NumericKeys<TContainer> extends readonly number[] ? NumericKeys<TContainer> : never;
|
|
6
|
-
type Process<TContainer extends Container> = TContainer extends readonly unknown[] ? IsTuple<TContainer> extends true ? ProcessTuple<TContainer> : number[] : TContainer extends object ? [IsObjectLiteral<RemoveIndexKeys<TContainer>>] extends [true] ? ProcessObj<RemoveIndexKeys<TContainer>> extends readonly (keyof TContainer)[] ? ProcessObj<RemoveIndexKeys<TContainer
|
|
6
|
+
type Process<TContainer extends Container> = TContainer extends readonly unknown[] ? IsTuple<TContainer> extends true ? ProcessTuple<TContainer> extends readonly number[] ? ProcessTuple<TContainer> : never : number[] : TContainer extends object ? [IsObjectLiteral<RemoveIndexKeys<TContainer>>] extends [true] ? ProcessObj<RemoveIndexKeys<TContainer>> extends readonly (keyof TContainer & ObjectKey)[] ? As<ProcessObj<RemoveIndexKeys<TContainer>>, readonly ObjectKey[]> : never : ObjectKey[] : never[];
|
|
7
7
|
/**
|
|
8
8
|
* **Keys**`<TContainer>`
|
|
9
9
|
*
|
|
@@ -18,8 +18,62 @@ type Process<TContainer extends Container> = TContainer extends readonly unknown
|
|
|
18
18
|
* type K2 = Keys<Arr>;
|
|
19
19
|
* ```
|
|
20
20
|
*
|
|
21
|
-
* **Related:** `ValidKey`
|
|
21
|
+
* **Related:** `ValidKey`, `PublicKeys`
|
|
22
22
|
*/
|
|
23
|
-
export type Keys<TContainer extends Container> = Process<TContainer>;
|
|
23
|
+
export type Keys<TContainer extends Container> = TContainer extends Tuple ? As<Process<TContainer>, readonly number[]> : As<Process<TContainer>, readonly ObjectKey[]>;
|
|
24
|
+
type _Public<TInput extends readonly PropertyKey[], TOutput extends readonly PropertyKey[] = []> = [] extends TInput ? TOutput : _Public<AfterFirst<TInput>, First<TInput> extends string ? StartsWith<First<TInput>, "_"> extends true ? TOutput : [...TOutput, First<TInput>] : TOutput>;
|
|
25
|
+
/**
|
|
26
|
+
* **PublicKeys**`<TContainer>`
|
|
27
|
+
*
|
|
28
|
+
* Provides a tuple of _keys_ for `TContainer` but unlike `Keys<T>` it removes any
|
|
29
|
+
* keys which start with an underscore character.
|
|
30
|
+
*/
|
|
31
|
+
export type PublicKeys<TContainer extends Container> = _Public<Keys<TContainer>>;
|
|
32
|
+
/**
|
|
33
|
+
* **PrivateKey**
|
|
34
|
+
*
|
|
35
|
+
* A `PrivateKey` is an object key that is preceded with a `_` character to indicate
|
|
36
|
+
* that it is a _private_ property.
|
|
37
|
+
*/
|
|
38
|
+
export type PrivateKey = `_${string}`;
|
|
39
|
+
/**
|
|
40
|
+
* **PrivateKeys**`<T>`
|
|
41
|
+
*
|
|
42
|
+
* Keys on an object which have a `_` character as first part of the
|
|
43
|
+
* name are considered private and this utility will create a union
|
|
44
|
+
* of all the keys in this category.
|
|
45
|
+
*
|
|
46
|
+
* **Related:** `PublicKeys`, `Keys`, `PrivateKeyOf`
|
|
47
|
+
*/
|
|
48
|
+
export type PrivateKeys<T extends object> = {
|
|
49
|
+
[K in keyof T]: K extends `_${string}` ? K : never;
|
|
50
|
+
}[keyof T];
|
|
51
|
+
type _KeyOf<TContainer extends Container> = TupleToUnion<Keys<TContainer>> extends PropertyKey ? TupleToUnion<Keys<TContainer>> extends keyof TContainer ? TupleToUnion<Keys<TContainer>> : never : never;
|
|
52
|
+
/**
|
|
53
|
+
* **KeyOf**`<TContainer>`
|
|
54
|
+
*
|
|
55
|
+
* Provides a **union type** of keys for the passed in container.
|
|
56
|
+
*
|
|
57
|
+
* **Related:** `Keys`,`PublicKeys`,`PublicKeyOf`
|
|
58
|
+
*/
|
|
59
|
+
export type KeyOf<TContainer extends Container> = IsWideUnion<_KeyOf<TContainer>> extends true ? "" : As<_KeyOf<TContainer>, string | symbol>;
|
|
60
|
+
/**
|
|
61
|
+
* **PublicKeyOf**`<TContainer>`
|
|
62
|
+
*
|
|
63
|
+
* Provides a **union type** of _public_ keys (aka, keys not starting with
|
|
64
|
+
* underscore character) for the passed in container.
|
|
65
|
+
*
|
|
66
|
+
* **Related:** `Keys`,`PublicKeys`,`KeyOf`
|
|
67
|
+
*/
|
|
68
|
+
export type PublicKeyOf<TContainer extends Container> = TupleToUnion<PublicKeys<TContainer>> extends PropertyKey ? TupleToUnion<PublicKeys<TContainer>> extends keyof TContainer ? TupleToUnion<PublicKeys<TContainer>> : never : never;
|
|
69
|
+
/**
|
|
70
|
+
* **PrivateKeyOf**`<TContainer>`
|
|
71
|
+
*
|
|
72
|
+
* Provides a **union type** of _private_ keys (aka, keys starting with
|
|
73
|
+
* underscore character) for the passed in container.
|
|
74
|
+
*
|
|
75
|
+
* **Related:** `Keys`,`PrivateKeys`,`KeyOf`
|
|
76
|
+
*/
|
|
77
|
+
export type PrivateKeyOf<TContainer extends Container> = TupleToUnion<PrivateKeys<TContainer>> extends PropertyKey ? TupleToUnion<PublicKeys<TContainer>> extends keyof TContainer ? TupleToUnion<PublicKeys<TContainer>> : never : never;
|
|
24
78
|
export {};
|
|
25
79
|
//# sourceMappingURL=Keys.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Keys.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/Keys.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,SAAS,EACT,SAAS,EACT,YAAY,EACZ,WAAW,EACX,eAAe,EACf,QAAQ,EACR,OAAO,EACP,eAAe,
|
|
1
|
+
{"version":3,"file":"Keys.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/Keys.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,SAAS,EACT,SAAS,EACT,YAAY,EACZ,WAAW,EACX,eAAe,EACf,QAAQ,EACR,OAAO,EACP,eAAe,EACf,UAAU,EACV,UAAU,EACV,KAAK,EACL,YAAY,EACZ,EAAE,EACF,KAAK,EACL,WAAW,EACZ,iBAAwB;AAEzB,KAAK,KAAK,CACV,CAAC,SAAS,MAAM,IACZ,YAAY,CAAC,MAAM,eAAe,CAAC,CAAC,CAAC,CAAC,CA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AK,CAAC;AAEV;;;;;;GAMG;AACH,MAAM,MAAM,KAAK,CAAC,UAAU,SAAS,SAAS,IAAI,WAAW,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,SAAS,IAAI,GAC5F,EAAE,GACF,EAAE,CAAC,MAAM,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC;AAE1C;;;;;;;GAOG;AACH,MAAM,MAAM,WAAW,CAAC,UAAU,SAAS,SAAS,IAAI,YAAY,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC,SAAS,WAAW,GAC5G,YAAY,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC,SAAS,MAAM,UAAU,GAC3D,YAAY,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC,GACpC,KAAK,GACP,KAAK,CAAC;AAEV;;;;;;;GAOG;AACH,MAAM,MAAM,YAAY,CAAC,UAAU,SAAS,SAAS,IAAI,YAAY,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC,SAAS,WAAW,GAC9G,YAAY,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC,SAAS,MAAM,UAAU,GAC3D,YAAY,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC,GACpC,KAAK,GACP,KAAK,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FnWithDescription, FnDefn } from "../functions/FnWithDescription";
|
|
2
2
|
/**
|
|
3
3
|
* **KvFnDefn**
|
|
4
4
|
*
|
|
@@ -11,5 +11,5 @@ export type KvFnDefn = [key: string, fn: FnDefn];
|
|
|
11
11
|
* A succinct and strong type definition for a KV value pair where the
|
|
12
12
|
* _value_ is a function.
|
|
13
13
|
*/
|
|
14
|
-
export type KvFn<T extends KvFnDefn = KvFnDefn> = Record<T[0],
|
|
14
|
+
export type KvFn<T extends KvFnDefn = KvFnDefn> = Record<T[0], FnWithDescription<T[1]>>;
|
|
15
15
|
//# sourceMappingURL=KvFn.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KvFn.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/KvFn.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"KvFn.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/KvFn.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAE3E;;;;GAIG;AACH,MAAM,MAAM,QAAQ,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,CAAC,CAAC;AAEjD;;;;;GAKG;AACH,MAAM,MAAM,IAAI,CACd,CAAC,SAAS,QAAQ,GAAG,QAAQ,IAC3B,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC"}
|
|
@@ -1,15 +1,24 @@
|
|
|
1
|
+
import { ObjectKey } from "../base-types";
|
|
1
2
|
import { Dictionary } from "../base-types/Dictionary";
|
|
3
|
+
import { IsWideUnion } from "../boolean-logic";
|
|
2
4
|
import { ExpandDictionary } from "../literals";
|
|
3
5
|
import { WithKeys } from "./WithKeys";
|
|
4
6
|
import { WithoutKeys } from "./WithoutKeys";
|
|
7
|
+
type ProcessTupleKeys<TObj extends Dictionary, TKeys extends readonly ObjectKey[]> = ExpandDictionary<WithoutKeys<TObj, TKeys> & {
|
|
8
|
+
[K in keyof WithKeys<TObj, TKeys>]?: K extends keyof TObj ? TObj[K] : never;
|
|
9
|
+
}>;
|
|
10
|
+
type ProcessUnionKeys<TObj extends Dictionary, TKeys extends (string | symbol)> = ExpandDictionary<WithoutKeys<TObj, TKeys> & {
|
|
11
|
+
[K in keyof WithKeys<TObj, TKeys>]?: K extends keyof TObj ? TObj[K] : never;
|
|
12
|
+
}>;
|
|
5
13
|
/**
|
|
6
14
|
* **MakeKeysOptional**`<TObj, TKeys>`
|
|
7
15
|
*
|
|
8
16
|
* Makes a set of keys on a known object `TObj` become
|
|
9
17
|
* _optional_ parameters while leaving the other properties
|
|
10
18
|
* "as is".
|
|
19
|
+
*
|
|
20
|
+
* **Related:** `MakeKeysRequired`
|
|
11
21
|
*/
|
|
12
|
-
export type MakeKeysOptional<TObj extends Dictionary, TKeys extends readonly
|
|
13
|
-
|
|
14
|
-
}>;
|
|
22
|
+
export type MakeKeysOptional<TObj extends Dictionary, TKeys extends (string | symbol) | readonly ObjectKey[]> = TKeys extends readonly ObjectKey[] ? ProcessTupleKeys<TObj, TKeys> : TKeys extends (string | symbol) ? IsWideUnion<TKeys> extends true ? never : ProcessUnionKeys<TObj, TKeys> : never;
|
|
23
|
+
export {};
|
|
15
24
|
//# sourceMappingURL=MakeKeysOptional.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MakeKeysOptional.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/MakeKeysOptional.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C
|
|
1
|
+
{"version":3,"file":"MakeKeysOptional.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/MakeKeysOptional.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAG,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,KAAK,gBAAgB,CACnB,IAAI,SAAS,UAAU,EACvB,KAAK,SAAS,SAAS,SAAS,EAAE,IAChC,gBAAgB,CACpB,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,GAAG;KACxB,CAAC,IAAI,MAAM,QAAQ,CAAC,IAAI,EAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,IAAI,GACpD,IAAI,CAAC,CAAC,CAAC,GACP,KAAK;CACV,CACA,CAAA;AAED,KAAK,gBAAgB,CACnB,IAAI,SAAS,UAAU,EACvB,KAAK,SAAS,CAAC,MAAM,GAAC,MAAM,CAAC,IAC3B,gBAAgB,CACpB,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,GAAG;KACxB,CAAC,IAAI,MAAM,QAAQ,CAAC,IAAI,EAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,IAAI,GACpD,IAAI,CAAC,CAAC,CAAC,GACP,KAAK;CACV,CACA,CAAA;AAGD;;;;;;;;GAQG;AACH,MAAM,MAAM,gBAAgB,CAC1B,IAAI,SAAS,UAAU,EACvB,KAAK,SAAS,CAAC,MAAM,GAAC,MAAM,CAAC,GAAG,SAAS,SAAS,EAAE,IAClD,KAAK,SAAS,SAAS,SAAS,EAAE,GACpC,gBAAgB,CAAC,IAAI,EAAC,KAAK,CAAC,GAC5B,KAAK,SAAS,CAAC,MAAM,GAAC,MAAM,CAAC,GAC3B,WAAW,CAAC,KAAK,CAAC,SAAS,IAAI,GAC7B,KAAK,GACL,gBAAgB,CAAC,IAAI,EAAC,KAAK,CAAC,GAChC,KAAK,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Dictionary, ExpandDictionary, ObjectKey, WithKeys, WithoutKeys } from "../index";
|
|
2
|
+
/**
|
|
3
|
+
* **MakeKeysRequired**`<TObj, TKeys>`
|
|
4
|
+
*
|
|
5
|
+
* Makes a set of keys on a known object `TObj` become
|
|
6
|
+
* _optional_ parameters while leaving the other properties
|
|
7
|
+
* "as is".
|
|
8
|
+
*
|
|
9
|
+
* **Related:** `MakeKeysOptional`
|
|
10
|
+
*/
|
|
11
|
+
export type MakeKeysRequired<TObj extends Dictionary, TKeys extends (string | symbol) | readonly ObjectKey[]> = ExpandDictionary<WithoutKeys<TObj, TKeys> & {
|
|
12
|
+
[K in keyof WithKeys<TObj, TKeys>]: K extends keyof TObj ? TObj[K] : never;
|
|
13
|
+
}>;
|
|
14
|
+
//# sourceMappingURL=MakeKeysRequired.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MakeKeysRequired.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/MakeKeysRequired.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,SAAS,EAAE,QAAQ,EAAE,WAAW,EAAE,iBAAwB;AAGjG;;;;;;;;GAQG;AACH,MAAM,MAAM,gBAAgB,CAC1B,IAAI,SAAS,UAAU,EACvB,KAAK,SAAS,CAAC,MAAM,GAAC,MAAM,CAAC,GAAG,SAAS,SAAS,EAAE,IAClD,gBAAgB,CAClB,WAAW,CAAC,IAAI,EAAC,KAAK,CAAC,GACvB;KACG,CAAC,IAAI,MAAM,QAAQ,CAAC,IAAI,EAAC,KAAK,CAAC,GAAG,CAAC,SAAS,MAAM,IAAI,GACnD,IAAI,CAAC,CAAC,CAAC,GACP,KAAK;CACV,CACF,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,11 +1,26 @@
|
|
|
1
|
+
import { AnyObject, If, IsEqual, Unset } from "../index";
|
|
1
2
|
/**
|
|
2
|
-
* **OptionalKeys**`<T>`
|
|
3
|
+
* **OptionalKeys**`<T,[V]>`
|
|
3
4
|
*
|
|
4
|
-
*
|
|
5
|
+
* Provides a union type of the _keys_ in `T` which are
|
|
6
|
+
* **optional** properties.
|
|
7
|
+
*
|
|
8
|
+
* **Note:** you also may optionally filter further by specifying a value
|
|
9
|
+
* by the _value_ of the key and then only keys which are required AND
|
|
10
|
+
* who extend `V` will be included in the union.
|
|
11
|
+
*
|
|
12
|
+
* **Related:** `OptionalKeys`, `RequiredProps` * Provides a union type of the _keys_ in `T` which are
|
|
13
|
+
* **required** properties.
|
|
14
|
+
*
|
|
15
|
+
* **Note:** you also may optionally filter further by specifying a value
|
|
16
|
+
* by the _value_ of the key and then only keys which are required AND
|
|
17
|
+
* who extend `V` will be included in the union.
|
|
18
|
+
*
|
|
19
|
+
* **Related:** `RequiredKeys`, `RequiredProps`
|
|
5
20
|
*/
|
|
6
|
-
export type OptionalKeys<T extends
|
|
21
|
+
export type OptionalKeys<T extends AnyObject, V = Unset> = {
|
|
7
22
|
[K in keyof T]-?: {} extends {
|
|
8
23
|
[P in K]: T[K];
|
|
9
|
-
} ? K : never;
|
|
24
|
+
} ? If<IsEqual<V, Unset>, K, K extends V ? K : never> : never;
|
|
10
25
|
}[keyof T];
|
|
11
26
|
//# sourceMappingURL=OptionalKeys.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OptionalKeys.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/OptionalKeys.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"OptionalKeys.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/OptionalKeys.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,SAAS,EACT,EAAE,EACF,OAAO,EACP,KAAK,EACL,iBAAwB;AAE1B;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,MAAM,YAAY,CACtB,CAAC,SAAS,SAAS,EACnB,CAAC,GAAG,KAAK,IACP;KACD,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS;SAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;KAAE,GAC3C,EAAE,CAAC,OAAO,CAAC,CAAC,EAAC,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC,GAChD,KAAK;CACV,CAAC,MAAM,CAAC,CAAC,CAAC"}
|
|
@@ -1,11 +1,19 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { As, Dictionary, IfUnset, ObjectKey, Unset } from "../index";
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
3
|
+
* **RequiredKeys**`<T,[V]>`
|
|
4
|
+
*
|
|
5
|
+
* Provides a union type of the _keys_ in `T` which are
|
|
6
|
+
* **required** properties.
|
|
7
|
+
*
|
|
8
|
+
* **Note:** you also may optionally filter further by specifying a value
|
|
9
|
+
* by the _value_ of the key and then only keys which are required AND
|
|
10
|
+
* who extend `V` will be included in the union.
|
|
11
|
+
*
|
|
12
|
+
* **Related:** `OptionalKeys`, `RequiredProps`
|
|
5
13
|
*/
|
|
6
|
-
export type RequiredKeys<T extends
|
|
14
|
+
export type RequiredKeys<T extends Dictionary, V = Unset> = As<{
|
|
7
15
|
[K in keyof T]-?: {} extends {
|
|
8
16
|
[P in K]: T[K];
|
|
9
|
-
} ? never : T[K] extends V ? K : never
|
|
10
|
-
}[keyof T]
|
|
17
|
+
} ? never : IfUnset<V, K, T[K] extends V ? K : never>;
|
|
18
|
+
}[keyof T], ObjectKey>;
|
|
11
19
|
//# sourceMappingURL=RequiredKeys.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RequiredKeys.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/RequiredKeys.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,iBAAwB;
|
|
1
|
+
{"version":3,"file":"RequiredKeys.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/RequiredKeys.ts"],"names":[],"mappings":"AAAA,OAAO,EAAG,EAAE,EAAE,UAAU,EAAE,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,iBAAwB;AAE7E;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,YAAY,CACtB,CAAC,SAAS,UAAU,EACpB,CAAC,GAAG,KAAK,IAAI,EAAE,CAAC;KAEf,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS;SAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;KAAE,GAC3C,KAAK,GACL,OAAO,CACL,CAAC,EACD,CAAC,EACD,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,GACV,CAAC,GACD,KAAK,CACV;CACN,CAAC,MAAM,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Container, Dictionary, ObjectKey, Tuple } from "../base-types";
|
|
1
|
+
import { Container, Dictionary, ObjectKey, Tuple, TypedFunction } from "../base-types";
|
|
2
2
|
import { AfterFirst, First } from "../lists";
|
|
3
3
|
import { Keys } from "./Keys";
|
|
4
4
|
type Process<TKeys extends readonly ObjectKey[], TObj extends Record<ObjectKey, unknown>, TResult extends readonly unknown[] = []> = [] extends TKeys ? TResult : Process<AfterFirst<TKeys>, TObj, [
|
|
@@ -13,6 +13,6 @@ type Process<TKeys extends readonly ObjectKey[], TObj extends Record<ObjectKey,
|
|
|
13
13
|
* - for **tuples** this is just a _proxy_ of the type
|
|
14
14
|
* - for _wide_ types like `string[]`
|
|
15
15
|
*/
|
|
16
|
-
export type Values<T extends Container> = T extends Tuple ? T : T extends Dictionary ? Process<Keys<T> extends readonly ObjectKey[] ? Keys<T> : never, T> : [];
|
|
16
|
+
export type Values<T extends Container> = T extends Tuple ? T : T extends Dictionary ? Process<Keys<T> extends readonly ObjectKey[] ? Keys<T> : never, T> : T extends TypedFunction ? [T] : [];
|
|
17
17
|
export {};
|
|
18
18
|
//# sourceMappingURL=Values.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Values.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/Values.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"Values.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/Values.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,SAAS,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACvF,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAG9B,KAAK,OAAO,CACV,KAAK,SAAS,SAAS,SAAS,EAAE,EAClC,IAAI,SAAS,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,EACvC,OAAO,SAAS,SAAS,OAAO,EAAE,GAAG,EAAE,IACrC,EAAE,SAAS,KAAK,GAClB,OAAO,GACP,OAAO,CACL,UAAU,CAAC,KAAK,CAAC,EACjB,IAAI,EACJ;IACE,GAAG,OAAO;IACV,KAAK,CAAC,KAAK,CAAC,SAAS,MAAM,IAAI,GAC3B,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,GAClB,KAAK;CACV,CACF,CAAA;AAGH;;;;;;;GAOG;AACH,MAAM,MAAM,MAAM,CAChB,CAAC,SAAS,SAAS,IACjB,CAAC,SAAS,KAAK,GACjB,CAAC,GACD,CAAC,SAAS,UAAU,GAClB,OAAO,CACL,IAAI,CAAC,CAAC,CAAC,SAAS,SAAS,SAAS,EAAE,GAChC,IAAI,CAAC,CAAC,CAAC,GACP,KAAK,EACT,CAAC,CACF,GACD,CAAC,SAAS,aAAa,GACrB,CAAC,CAAC,CAAC,GAEL,EAAE,CAAC"}
|
|
@@ -10,8 +10,6 @@ export * from "./MaybeRef";
|
|
|
10
10
|
export * from "./FromMaybeRef";
|
|
11
11
|
export * from "./RequiredProps";
|
|
12
12
|
export * from "./OptionalProps";
|
|
13
|
-
export * from "./PrivateKeys";
|
|
14
|
-
export * from "./PublicKeys";
|
|
15
13
|
export * from "./StringKeys";
|
|
16
14
|
export * from "./NonStringKeys";
|
|
17
15
|
export * from "./KeysWithValue";
|
|
@@ -45,4 +43,5 @@ export * from "./CreateLookup";
|
|
|
45
43
|
export * from "./MergeKVs";
|
|
46
44
|
export * from "./TakeProp";
|
|
47
45
|
export * from "./MakeKeysOptional";
|
|
46
|
+
export * from "./MakeKeysRequired";
|
|
48
47
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/index.ts"],"names":[],"mappings":"AAMA,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,OAAO,CAAC;AACtB,cAAc,kBAAkB,CAAC;AACjC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/dictionary/index.ts"],"names":[],"mappings":"AAMA,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,OAAO,CAAC;AACtB,cAAc,kBAAkB,CAAC;AACjC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,QAAQ,CAAC;AACvB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC"}
|
|
@@ -15,8 +15,6 @@ export * from "./MaybeRef.js";
|
|
|
15
15
|
export * from "./FromMaybeRef.js";
|
|
16
16
|
export * from "./RequiredProps.js";
|
|
17
17
|
export * from "./OptionalProps.js";
|
|
18
|
-
export * from "./PrivateKeys.js";
|
|
19
|
-
export * from "./PublicKeys.js";
|
|
20
18
|
export * from "./StringKeys.js";
|
|
21
19
|
export * from "./NonStringKeys.js";
|
|
22
20
|
export * from "./KeysWithValue.js";
|
|
@@ -50,6 +48,7 @@ export * from "./CreateLookup.js";
|
|
|
50
48
|
export * from "./MergeKVs.js";
|
|
51
49
|
export * from "./TakeProp.js";
|
|
52
50
|
export * from "./MakeKeysOptional.js";
|
|
51
|
+
export * from "./MakeKeysRequired.js";
|
|
53
52
|
// #endregion auto-indexed files
|
|
54
53
|
// see https://github.com/inocan-group/do-devops/docs/autoindex.md
|
|
55
54
|
// for more info
|
|
@@ -23,7 +23,7 @@ import { PascalCase, KebabCase } from "../index";
|
|
|
23
23
|
* BadJuju("oh my god!", { flavor: "strawberry"})
|
|
24
24
|
* ```
|
|
25
25
|
*/
|
|
26
|
-
export interface KindError<K extends string, C extends Record<string, unknown>
|
|
26
|
+
export interface KindError<K extends string, C extends Record<string, unknown> | undefined> extends Error {
|
|
27
27
|
__kind: "KindError";
|
|
28
28
|
name: PascalCase<K>;
|
|
29
29
|
kind: KebabCase<K>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KindError.d.ts","sourceRoot":"","sources":["../../../src/types/errors/KindError.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAE,SAAS,EAAC,iBAAwB;AAEtD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,WAAW,SAAS,CACxB,CAAC,SAAS,MAAM,EAChB,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,
|
|
1
|
+
{"version":3,"file":"KindError.d.ts","sourceRoot":"","sources":["../../../src/types/errors/KindError.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAE,SAAS,EAAC,iBAAwB;AAEtD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,WAAW,SAAS,CACxB,CAAC,SAAS,MAAM,EAChB,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAC7C,SAAQ,KAAK;IACb,MAAM,EAAE,WAAW,CAAC;IACpB,IAAI,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC;IACpB,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC;IACnB,OAAO,EAAE,CAAC,CAAC;CACZ;AAED;;;;;GAKG;AACH,MAAM,MAAM,aAAa,CACvB,CAAC,SAAS,MAAM,EAChB,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,WAAW,CAAC,OAAO,CAAC,IACtD,CACF,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE,CAAC,KACR,SAAS,CAAC,CAAC,EAAC,CAAC,CAAC,CAAC"}
|
|
@@ -1,3 +1,8 @@
|
|
|
1
1
|
import { Dictionary, EmptyObject, Tuple } from "../base-types";
|
|
2
|
+
/**
|
|
3
|
+
* **FnFrom**`<TParams,[TReturn],[TProps]>`
|
|
4
|
+
*
|
|
5
|
+
* Type utility to build a type from it's constituent parts.
|
|
6
|
+
*/
|
|
2
7
|
export type FnFrom<TParams extends Tuple, TReturn = unknown, TProps extends Dictionary = EmptyObject> = TProps extends EmptyObject ? <T extends TParams>(...args: T) => TReturn : (<T extends TParams>(...args: T) => TReturn) & TProps;
|
|
3
8
|
//# sourceMappingURL=FnFrom.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FnFrom.d.ts","sourceRoot":"","sources":["../../../src/types/functions/FnFrom.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"FnFrom.d.ts","sourceRoot":"","sources":["../../../src/types/functions/FnFrom.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAE/D;;;;GAIG;AACH,MAAM,MAAM,MAAM,CAChB,OAAO,SAAS,KAAK,EACrB,OAAO,GAAG,OAAO,EACjB,MAAM,SAAS,UAAU,GAAG,WAAW,IACrC,MAAM,SAAS,WAAW,GAC5B,CAAC,CAAC,SAAS,OAAO,EAAE,GAAG,IAAI,EAAE,CAAC,KAAK,OAAO,GAC1C,CAAC,CAAC,CAAC,SAAS,OAAO,EAAE,GAAG,IAAI,EAAE,CAAC,KAAK,OAAO,CAAC,GAAG,MAAM,CAAA"}
|
|
@@ -3,7 +3,7 @@ export type FnDefn = [fn: AnyFunction] | [fn: AnyFunction, desc: string] | [fn:
|
|
|
3
3
|
/**
|
|
4
4
|
* **Fn**`<TArgs,TReturn>`
|
|
5
5
|
*/
|
|
6
|
-
export type
|
|
6
|
+
export type FnWithDescription<TFn extends FnDefn = FnDefn> = TFn extends [fn: AnyFunction] ? TFn[0] : TFn extends [fn: AnyFunction, desc: string] ? TFn[0] & {
|
|
7
7
|
desc: TFn[1];
|
|
8
8
|
} : TFn extends [fn: AnyFunction, props: Record<ObjectKey, unknown>] ? TFn[0] & TFn[1] : never;
|
|
9
|
-
//# sourceMappingURL=
|
|
9
|
+
//# sourceMappingURL=FnWithDescription.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FnWithDescription.d.ts","sourceRoot":"","sources":["../../../src/types/functions/FnWithDescription.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAEvD,MAAM,MAAM,MAAM,GAAG,CAAC,EAAE,EAAE,WAAW,CAAE,GACrC,CAAC,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,CAAC,GAC/B,CAAC,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,CAAE,CAAC;AAExD;;GAEG;AACH,MAAM,MAAM,iBAAiB,CAC3B,GAAG,SAAS,MAAM,GAAG,MAAM,IACzB,GAAG,SAAS,CAAE,EAAE,EAAE,WAAW,CAAE,GACjC,GAAG,CAAC,CAAC,CAAC,GACN,GAAG,SAAS,CAAE,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,CAAC,GAC1C,GAAG,CAAC,CAAC,CAAC,GAAG;IAAE,IAAI,EAAE,GAAG,CAAC,CAAC,CAAC,CAAA;CAAE,GACzB,GAAG,SAAS,CAAE,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,CAAE,GAChE,GAAG,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,GACf,KAAK,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Container, TypedFunction } from "../base-types";
|
|
2
|
+
import { If, IsUnset } from "../boolean-logic";
|
|
3
|
+
import { Unset } from "../literals";
|
|
4
|
+
import { FnFrom } from "./FnFrom";
|
|
5
|
+
import { AsNarrowingFn } from "./NarrowingFn";
|
|
6
|
+
/**
|
|
7
|
+
* **WrapperFn**`<TFn,TTransform,[TState]>`
|
|
8
|
+
*
|
|
9
|
+
* A function which consumes a known function `TFn` and exposes the
|
|
10
|
+
* same parameters externally while allowing it to _transform_ the
|
|
11
|
+
* original functions return value before completing.
|
|
12
|
+
*
|
|
13
|
+
* Optionally, you can express some amount of _state_ which will be available
|
|
14
|
+
* to the `TTransform` function to do it's work.
|
|
15
|
+
*
|
|
16
|
+
* ```ts
|
|
17
|
+
* type Fn = (name: string) => `Hello ${string}`;
|
|
18
|
+
* // (name: string) => `Hello ${name}!`;
|
|
19
|
+
* type Wrapped = WrapperFn<Fn, v => `${v}!`>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export type WrapperFn<TFn extends TypedFunction, TTransform extends <TRtn extends ReturnType<TFn>>(rtn: TRtn) => unknown, TState extends Container | Unset = Unset> = If<IsUnset<TState>, FnFrom<Parameters<TFn>, ReturnType<AsNarrowingFn<TTransform>>>, <T extends TState>(state: T) => FnFrom<Parameters<TFn>, ReturnType<AsNarrowingFn<TTransform>>>>;
|
|
23
|
+
//# sourceMappingURL=WrapperFn.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WrapperFn.d.ts","sourceRoot":"","sources":["../../../src/types/functions/WrapperFn.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACzD,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAG9C;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,SAAS,CACnB,GAAG,SAAS,aAAa,EACzB,UAAU,SAAS,CAAC,IAAI,SAAS,UAAU,CAAC,GAAG,CAAC,EAAE,GAAG,EAAE,IAAI,KAAK,OAAO,EACvE,MAAM,SAAS,SAAS,GAAG,KAAK,GAAG,KAAK,IACtC,EAAE,CACJ,OAAO,CAAC,MAAM,CAAC,EACf,MAAM,CACJ,UAAU,CAAC,GAAG,CAAC,EACf,UAAU,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC,CACtC,EACD,CAAC,CAAC,SAAS,MAAM,EAAE,KAAK,EAAE,CAAC,KAAK,MAAM,CACpC,UAAU,CAAC,GAAG,CAAC,EACf,UAAU,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC,CACtC,CACF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -7,9 +7,10 @@ export * from "./FnMeta";
|
|
|
7
7
|
export * from "./FnFrom";
|
|
8
8
|
export * from "./PromiseAll";
|
|
9
9
|
export * from "./FnProps";
|
|
10
|
-
export * from "./
|
|
10
|
+
export * from "./FnWithDescription";
|
|
11
11
|
export * from "./HandleDoneFn";
|
|
12
12
|
export * from "./NarrowingFn";
|
|
13
13
|
export * from "./LiteralFn";
|
|
14
14
|
export * from "./IdentityFn";
|
|
15
|
+
export * from "./WrapperFn";
|
|
15
16
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/functions/index.ts"],"names":[],"mappings":"AAMA,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,iBAAiB,CAAC;AAChC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/functions/index.ts"],"names":[],"mappings":"AAMA,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,iBAAiB,CAAC;AAChC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,eAAe,CAAA;AAC7B,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,aAAa,CAAA"}
|
|
@@ -12,11 +12,12 @@ export * from "./FnMeta.js";
|
|
|
12
12
|
export * from "./FnFrom.js";
|
|
13
13
|
export * from "./PromiseAll.js";
|
|
14
14
|
export * from "./FnProps.js";
|
|
15
|
-
export * from "./
|
|
15
|
+
export * from "./FnWithDescription.js";
|
|
16
16
|
export * from "./HandleDoneFn.js";
|
|
17
17
|
export * from "./NarrowingFn.js";
|
|
18
18
|
export * from "./LiteralFn.js";
|
|
19
19
|
export * from "./IdentityFn.js";
|
|
20
|
+
export * from "./WrapperFn.js";
|
|
20
21
|
// export * from "src/types/index";
|
|
21
22
|
// #endregion auto-indexed files
|
|
22
23
|
// see https://github.com/inocan-group/do-devops/docs/autoindex.md
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Narrowable, AfterFirst,
|
|
1
|
+
import { Narrowable, AfterFirst, First, Find } from "../index";
|
|
2
2
|
export type ConversionTuple = [from: Narrowable, to: Narrowable];
|
|
3
|
-
type Convert<TValue, TConversions extends readonly ConversionTuple[]> =
|
|
3
|
+
type Convert<TValue, TConversions extends readonly ConversionTuple[]> = Find<TConversions, "extends", TValue, 0> extends ConversionTuple ? Find<TConversions, "extends", TValue, 0>[1] : TValue;
|
|
4
4
|
type ConvertAcc<TSet extends readonly unknown[], TConversions extends readonly ConversionTuple[], TResults extends readonly unknown[] = []> = [] extends TSet ? TResults : ConvertAcc<AfterFirst<TSet>, TConversions, [
|
|
5
5
|
...TResults,
|
|
6
6
|
Convert<First<TSet>, TConversions>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConvertSet.d.ts","sourceRoot":"","sources":["../../../src/types/lists/ConvertSet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAG,UAAU,
|
|
1
|
+
{"version":3,"file":"ConvertSet.d.ts","sourceRoot":"","sources":["../../../src/types/lists/ConvertSet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAG,UAAU,EAAI,KAAK,EAAE,IAAI,EAAE,iBAAwB;AAEzE,MAAM,MAAM,eAAe,GAAG,CAAC,IAAI,EAAE,UAAU,EAAE,EAAE,EAAE,UAAU,CAAC,CAAC;AAEjE,KAAK,OAAO,CACV,MAAM,EACN,YAAY,SAAS,SAAS,eAAe,EAAE,IAC7C,IAAI,CAAC,YAAY,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC,CAAC,SAAS,eAAe,GAChE,IAAI,CAAC,YAAY,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,GAC3C,MAAM,CAAC;AAEX,KAAK,UAAU,CACb,IAAI,SAAS,SAAS,OAAO,EAAE,EAC/B,YAAY,SAAS,SAAS,eAAe,EAAE,EAC/C,QAAQ,SAAS,SAAS,OAAO,EAAE,GAAG,EAAE,IACtC,E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