type-plus 8.0.0-beta.6 → 8.0.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (993) hide show
  1. package/{esm/type_plus → cjs/$type}/$resolve_options.d.ts +2 -2
  2. package/cjs/$type/$resolve_options.d.ts.map +1 -0
  3. package/cjs/$type/$resolve_options.js.map +1 -0
  4. package/cjs/$type/$type.d.ts +34 -0
  5. package/cjs/$type/$type.d.ts.map +1 -0
  6. package/cjs/{type_plus → $type}/$type.js.map +1 -1
  7. package/{esm/type_plus → cjs/$type}/branch/$branch.d.ts +3 -3
  8. package/cjs/$type/branch/$branch.d.ts.map +1 -0
  9. package/cjs/$type/branch/$branch.js.map +1 -0
  10. package/{esm/type_plus → cjs/$type}/branch/$input_options.d.ts +2 -1
  11. package/cjs/$type/branch/$input_options.d.ts.map +1 -0
  12. package/cjs/$type/branch/$input_options.js.map +1 -0
  13. package/cjs/$type/branch/$resolve_branch.d.ts +22 -0
  14. package/cjs/$type/branch/$resolve_branch.d.ts.map +1 -0
  15. package/cjs/$type/branch/$resolve_branch.js.map +1 -0
  16. package/cjs/$type/branch/$selection.d.ts +161 -0
  17. package/cjs/$type/branch/$selection.d.ts.map +1 -0
  18. package/cjs/$type/branch/$selection.js.map +1 -0
  19. package/cjs/$type/distributive/$distributive.d.ts +27 -0
  20. package/cjs/$type/distributive/$distributive.d.ts.map +1 -0
  21. package/cjs/$type/distributive/$distributive.js.map +1 -0
  22. package/cjs/$type/errors/$error.d.ts +23 -0
  23. package/cjs/$type/errors/$error.d.ts.map +1 -0
  24. package/cjs/{type_plus → $type/errors}/$error.js.map +1 -1
  25. package/{esm/type_plus → cjs/$type/errors}/$infer_error.d.ts +7 -6
  26. package/cjs/$type/errors/$infer_error.d.ts.map +1 -0
  27. package/cjs/$type/errors/$infer_error.js.map +1 -0
  28. package/{esm/type → cjs/$type/errors}/failed.d.ts +4 -0
  29. package/cjs/$type/errors/failed.d.ts.map +1 -0
  30. package/cjs/{type → $type/errors}/failed.js.map +1 -1
  31. package/cjs/$type/exact/$exact.d.ts +27 -0
  32. package/cjs/$type/exact/$exact.d.ts.map +1 -0
  33. package/cjs/{type_plus/branch → $type/exact}/$exact.js.map +1 -1
  34. package/cjs/$type/special/$any.d.ts +36 -0
  35. package/cjs/$type/special/$any.d.ts.map +1 -0
  36. package/cjs/{any/any.js → $type/special/$any.js} +1 -1
  37. package/cjs/$type/special/$any.js.map +1 -0
  38. package/cjs/$type/special/$never.d.ts +52 -0
  39. package/cjs/$type/special/$never.d.ts.map +1 -0
  40. package/cjs/$type/special/$never.js +3 -0
  41. package/cjs/$type/special/$never.js.map +1 -0
  42. package/cjs/$type/special/$special.d.ts +31 -0
  43. package/cjs/$type/special/$special.d.ts.map +1 -0
  44. package/cjs/$type/special/$special.js +3 -0
  45. package/cjs/$type/special/$special.js.map +1 -0
  46. package/cjs/$type/special/$unknown.d.ts +37 -0
  47. package/cjs/$type/special/$unknown.d.ts.map +1 -0
  48. package/cjs/$type/special/$unknown.js +3 -0
  49. package/cjs/$type/special/$unknown.js.map +1 -0
  50. package/cjs/$type/special/$void.d.ts +46 -0
  51. package/cjs/$type/special/$void.d.ts.map +1 -0
  52. package/cjs/{never/never.js → $type/special/$void.js} +1 -1
  53. package/cjs/$type/special/$void.js.map +1 -0
  54. package/cjs/$type/utils/$merge_options.d.ts +14 -0
  55. package/cjs/$type/utils/$merge_options.d.ts.map +1 -0
  56. package/cjs/$type/utils/$merge_options.js.map +1 -0
  57. package/cjs/any/is_any.d.ts +23 -20
  58. package/cjs/any/is_any.d.ts.map +1 -1
  59. package/cjs/any/is_not_any.d.ts +15 -14
  60. package/cjs/any/is_not_any.d.ts.map +1 -1
  61. package/cjs/array/array.reverse.d.ts +1 -1
  62. package/cjs/array/array.reverse.d.ts.map +1 -1
  63. package/cjs/array/array.some.d.ts +1 -1
  64. package/cjs/array/array.some.d.ts.map +1 -1
  65. package/cjs/array/array_plus.common_prop_keys.d.ts +1 -1
  66. package/cjs/array/array_plus.common_prop_keys.d.ts.map +1 -1
  67. package/cjs/array/array_plus.filter.d.ts +2 -2
  68. package/cjs/array/array_plus.filter.d.ts.map +1 -1
  69. package/cjs/array/array_plus.find.d.ts +2 -2
  70. package/cjs/array/array_plus.find.d.ts.map +1 -1
  71. package/cjs/array/array_plus.index_at.d.ts +16 -10
  72. package/cjs/array/array_plus.index_at.d.ts.map +1 -1
  73. package/cjs/array/array_plus.index_at.js.map +1 -1
  74. package/cjs/array/array_plus.is_readonly.d.ts +3 -3
  75. package/cjs/array/array_plus.is_readonly.d.ts.map +1 -1
  76. package/cjs/array/head.d.ts +3 -3
  77. package/cjs/array/head.d.ts.map +1 -1
  78. package/cjs/array/is_array.d.ts +23 -19
  79. package/cjs/array/is_array.d.ts.map +1 -1
  80. package/cjs/array/is_not_array.d.ts +23 -19
  81. package/cjs/array/is_not_array.d.ts.map +1 -1
  82. package/cjs/array/last.d.ts +5 -3
  83. package/cjs/array/last.d.ts.map +1 -1
  84. package/cjs/array/literal_array.js +1 -2
  85. package/cjs/array/literal_array.js.map +1 -1
  86. package/cjs/array/reduce_while.js +1 -2
  87. package/cjs/array/reduce_while.js.map +1 -1
  88. package/cjs/assertion/assert_type.d.ts +1 -1
  89. package/cjs/assertion/assert_type.d.ts.map +1 -1
  90. package/cjs/assertion/assert_type.js +1 -4
  91. package/cjs/assertion/assert_type.js.map +1 -1
  92. package/cjs/bigint/is_bigint.d.ts +20 -16
  93. package/cjs/bigint/is_bigint.d.ts.map +1 -1
  94. package/cjs/bigint/is_bigint_literal.d.ts +18 -13
  95. package/cjs/bigint/is_bigint_literal.d.ts.map +1 -1
  96. package/cjs/bigint/is_not_bigint.d.ts +20 -16
  97. package/cjs/bigint/is_not_bigint.d.ts.map +1 -1
  98. package/cjs/bigint/is_not_bigint_literal.d.ts +19 -13
  99. package/cjs/bigint/is_not_bigint_literal.d.ts.map +1 -1
  100. package/cjs/binary/_binary.d.ts +2 -1
  101. package/cjs/binary/_binary.d.ts.map +1 -1
  102. package/cjs/binary/_binary.js +3 -0
  103. package/cjs/binary/_binary.js.map +1 -1
  104. package/cjs/binary/bit.d.ts +26 -0
  105. package/cjs/binary/bit.d.ts.map +1 -0
  106. package/cjs/binary/{Bit.js → bit.js} +1 -1
  107. package/cjs/binary/bit.js.map +1 -0
  108. package/cjs/boolean/is_boolean.d.ts +20 -16
  109. package/cjs/boolean/is_boolean.d.ts.map +1 -1
  110. package/cjs/boolean/is_false.d.ts +15 -9
  111. package/cjs/boolean/is_false.d.ts.map +1 -1
  112. package/cjs/boolean/is_not_boolean.d.ts +21 -16
  113. package/cjs/boolean/is_not_boolean.d.ts.map +1 -1
  114. package/cjs/boolean/is_not_false.d.ts +16 -9
  115. package/cjs/boolean/is_not_false.d.ts.map +1 -1
  116. package/cjs/boolean/is_not_true.d.ts +15 -9
  117. package/cjs/boolean/is_not_true.d.ts.map +1 -1
  118. package/cjs/boolean/is_true.d.ts +15 -9
  119. package/cjs/boolean/is_true.d.ts.map +1 -1
  120. package/cjs/class/isConstructor.js +2 -3
  121. package/cjs/class/isConstructor.js.map +1 -1
  122. package/cjs/equal/equal.d.ts +189 -74
  123. package/cjs/equal/equal.d.ts.map +1 -1
  124. package/cjs/equal/identity_equal.d.ts +5 -1
  125. package/cjs/equal/identity_equal.d.ts.map +1 -1
  126. package/cjs/equal/is_equal.d.ts +102 -0
  127. package/cjs/equal/is_equal.d.ts.map +1 -0
  128. package/cjs/equal/is_equal.js +3 -0
  129. package/cjs/equal/is_equal.js.map +1 -0
  130. package/cjs/function/extract_function.d.ts.map +1 -1
  131. package/cjs/function/extract_function.js +1 -2
  132. package/cjs/function/extract_function.js.map +1 -1
  133. package/cjs/function/is_function.d.ts +28 -5
  134. package/cjs/function/is_function.d.ts.map +1 -1
  135. package/cjs/function/is_not_function.d.ts +1 -1
  136. package/cjs/function/is_not_function.d.ts.map +1 -1
  137. package/cjs/function/is_not_strict_function.d.ts +15 -13
  138. package/cjs/function/is_not_strict_function.d.ts.map +1 -1
  139. package/cjs/function/is_strict_function.d.ts +22 -17
  140. package/cjs/function/is_strict_function.d.ts.map +1 -1
  141. package/cjs/functional/Maybe.d.ts +1 -1
  142. package/cjs/functional/Maybe.d.ts.map +1 -1
  143. package/cjs/functional/Maybe.js +2 -3
  144. package/cjs/functional/Maybe.js.map +1 -1
  145. package/cjs/functional/compose.d.ts.map +1 -1
  146. package/cjs/functional/compose.js +2 -5
  147. package/cjs/functional/compose.js.map +1 -1
  148. package/cjs/functional/context.js +1 -2
  149. package/cjs/functional/context.js.map +1 -1
  150. package/cjs/index.d.ts +21 -22
  151. package/cjs/index.d.ts.map +1 -1
  152. package/cjs/index.js.map +1 -1
  153. package/cjs/json.js +1 -1
  154. package/cjs/json.js.map +1 -1
  155. package/cjs/logical/logical.d.ts +35 -0
  156. package/cjs/logical/logical.d.ts.map +1 -0
  157. package/cjs/{predicates → logical}/logical.js.map +1 -1
  158. package/cjs/math/abs.d.ts +1 -1
  159. package/cjs/math/abs.d.ts.map +1 -1
  160. package/cjs/math/numeric_struct.d.ts.map +1 -1
  161. package/cjs/mix_types/box.d.ts +2 -2
  162. package/cjs/mix_types/box.d.ts.map +1 -1
  163. package/cjs/mix_types/is_any_or_never.d.ts +2 -3
  164. package/cjs/mix_types/is_any_or_never.d.ts.map +1 -1
  165. package/cjs/mix_types/merge.d.ts +18 -6
  166. package/cjs/mix_types/merge.d.ts.map +1 -1
  167. package/cjs/mix_types/merge.js +1 -2
  168. package/cjs/mix_types/merge.js.map +1 -1
  169. package/cjs/never/is_never.d.ts +16 -15
  170. package/cjs/never/is_never.d.ts.map +1 -1
  171. package/cjs/never/is_not_never.d.ts +16 -15
  172. package/cjs/never/is_not_never.d.ts.map +1 -1
  173. package/cjs/nodejs/isNodeError.js +1 -2
  174. package/cjs/nodejs/isNodeError.js.map +1 -1
  175. package/cjs/nominal/brand.js +1 -2
  176. package/cjs/nominal/brand.js.map +1 -1
  177. package/cjs/nominal/flavor.js +1 -2
  178. package/cjs/nominal/flavor.js.map +1 -1
  179. package/cjs/nominal/nominal_match.js +1 -2
  180. package/cjs/nominal/nominal_match.js.map +1 -1
  181. package/cjs/null/is_not_null.d.ts +15 -9
  182. package/cjs/null/is_not_null.d.ts.map +1 -1
  183. package/cjs/null/is_null.d.ts +15 -9
  184. package/cjs/null/is_null.d.ts.map +1 -1
  185. package/cjs/number/is_not_number.d.ts +20 -16
  186. package/cjs/number/is_not_number.d.ts.map +1 -1
  187. package/cjs/number/is_not_number_literal.d.ts +18 -13
  188. package/cjs/number/is_not_number_literal.d.ts.map +1 -1
  189. package/cjs/number/is_number.d.ts +20 -16
  190. package/cjs/number/is_number.d.ts.map +1 -1
  191. package/cjs/number/is_number_literal.d.ts +18 -13
  192. package/cjs/number/is_number_literal.d.ts.map +1 -1
  193. package/cjs/numeric/is_integer.d.ts +18 -12
  194. package/cjs/numeric/is_integer.d.ts.map +1 -1
  195. package/cjs/numeric/is_negative.d.ts +19 -13
  196. package/cjs/numeric/is_negative.d.ts.map +1 -1
  197. package/cjs/numeric/is_not_integer.d.ts +13 -7
  198. package/cjs/numeric/is_not_integer.d.ts.map +1 -1
  199. package/cjs/numeric/is_not_negative.d.ts +15 -9
  200. package/cjs/numeric/is_not_negative.d.ts.map +1 -1
  201. package/cjs/numeric/is_not_numeric.d.ts +1 -1
  202. package/cjs/numeric/is_not_numeric.d.ts.map +1 -1
  203. package/cjs/numeric/is_not_positive.d.ts +13 -7
  204. package/cjs/numeric/is_not_positive.d.ts.map +1 -1
  205. package/cjs/numeric/is_numeric.d.ts +28 -5
  206. package/cjs/numeric/is_numeric.d.ts.map +1 -1
  207. package/cjs/numeric/is_positive.d.ts +19 -13
  208. package/cjs/numeric/is_positive.d.ts.map +1 -1
  209. package/cjs/object/ANotB.d.ts +1 -1
  210. package/cjs/object/ANotB.d.ts.map +1 -1
  211. package/cjs/object/adjust_exact_optional_props.d.ts +6 -3
  212. package/cjs/object/adjust_exact_optional_props.d.ts.map +1 -1
  213. package/cjs/object/everyKey.js +1 -2
  214. package/cjs/object/everyKey.js.map +1 -1
  215. package/cjs/object/facade.js +1 -2
  216. package/cjs/object/facade.js.map +1 -1
  217. package/cjs/object/filterKey.js +1 -2
  218. package/cjs/object/filterKey.js.map +1 -1
  219. package/cjs/object/findKey.js +1 -2
  220. package/cjs/object/findKey.js.map +1 -1
  221. package/cjs/object/forEachKey.js +1 -2
  222. package/cjs/object/forEachKey.js.map +1 -1
  223. package/cjs/object/getField.js +1 -2
  224. package/cjs/object/getField.js.map +1 -1
  225. package/cjs/object/hasKey.js +1 -2
  226. package/cjs/object/hasKey.js.map +1 -1
  227. package/cjs/object/hasProperty.js +1 -2
  228. package/cjs/object/hasProperty.js.map +1 -1
  229. package/cjs/object/index.d.ts +6 -6
  230. package/cjs/object/index.d.ts.map +1 -1
  231. package/cjs/object/index.js.map +1 -1
  232. package/cjs/object/is_not_object.d.ts +23 -19
  233. package/cjs/object/is_not_object.d.ts.map +1 -1
  234. package/cjs/object/is_object.d.ts +23 -19
  235. package/cjs/object/is_object.d.ts.map +1 -1
  236. package/cjs/object/left_join.d.ts +1 -1
  237. package/cjs/object/left_join.d.ts.map +1 -1
  238. package/cjs/object/mapKey.js +1 -2
  239. package/cjs/object/mapKey.js.map +1 -1
  240. package/cjs/object/mapProperties.js +1 -2
  241. package/cjs/object/mapProperties.js.map +1 -1
  242. package/cjs/object/merge.d.ts +54 -48
  243. package/cjs/object/merge.d.ts.map +1 -1
  244. package/cjs/object/omit.js +1 -2
  245. package/cjs/object/omit.js.map +1 -1
  246. package/cjs/object/pick.js +1 -2
  247. package/cjs/object/pick.js.map +1 -1
  248. package/cjs/object/properties.d.ts +29 -4
  249. package/cjs/object/properties.d.ts.map +1 -1
  250. package/cjs/object/properties.js +1 -0
  251. package/cjs/object/properties.js.map +1 -1
  252. package/cjs/object/record.js +1 -2
  253. package/cjs/object/record.js.map +1 -1
  254. package/cjs/object/reduceKey.js +2 -2
  255. package/cjs/object/reduceKey.js.map +1 -1
  256. package/cjs/object/replaceProperty.js +1 -2
  257. package/cjs/object/replaceProperty.js.map +1 -1
  258. package/cjs/object/someKey.js +1 -2
  259. package/cjs/object/someKey.js.map +1 -1
  260. package/cjs/object/split.js +1 -2
  261. package/cjs/object/split.js.map +1 -1
  262. package/cjs/object/typeOverrideIncompatible.d.ts.map +1 -1
  263. package/cjs/object/typeOverrideIncompatible.js +1 -2
  264. package/cjs/object/typeOverrideIncompatible.js.map +1 -1
  265. package/cjs/predicates/CanAssign.js +1 -2
  266. package/cjs/predicates/CanAssign.js.map +1 -1
  267. package/cjs/predicates/assignable.d.ts +23 -25
  268. package/cjs/predicates/assignable.d.ts.map +1 -1
  269. package/cjs/predicates/index.d.ts +1 -1
  270. package/cjs/predicates/index.d.ts.map +1 -1
  271. package/cjs/predicates/index.js.map +1 -1
  272. package/cjs/predicates/not_assignable.d.ts +24 -26
  273. package/cjs/predicates/not_assignable.d.ts.map +1 -1
  274. package/cjs/promise/MaybePromise.js +2 -2
  275. package/cjs/promise/MaybePromise.js.map +1 -1
  276. package/cjs/promise/index.d.ts +1 -1
  277. package/cjs/promise/index.d.ts.map +1 -1
  278. package/cjs/promise/index.js +1 -1
  279. package/cjs/promise/index.js.map +1 -1
  280. package/cjs/promise/isPromise.js +2 -3
  281. package/cjs/promise/isPromise.js.map +1 -1
  282. package/cjs/promise/mapSeries.js +1 -2
  283. package/cjs/promise/mapSeries.js.map +1 -1
  284. package/cjs/string/$extract_manipulated_string.d.ts.map +1 -1
  285. package/cjs/string/_string_type.d.ts.map +1 -1
  286. package/cjs/string/is_not_string.d.ts +20 -17
  287. package/cjs/string/is_not_string.d.ts.map +1 -1
  288. package/cjs/string/is_not_string_literal.d.ts +25 -22
  289. package/cjs/string/is_not_string_literal.d.ts.map +1 -1
  290. package/cjs/string/is_not_template_literal.d.ts +18 -13
  291. package/cjs/string/is_not_template_literal.d.ts.map +1 -1
  292. package/cjs/string/is_string.d.ts +20 -16
  293. package/cjs/string/is_string.d.ts.map +1 -1
  294. package/cjs/string/is_string_literal.d.ts +25 -22
  295. package/cjs/string/is_string_literal.d.ts.map +1 -1
  296. package/cjs/string/is_template_literal.d.ts +18 -13
  297. package/cjs/string/is_template_literal.d.ts.map +1 -1
  298. package/cjs/symbol/is_not_symbol.d.ts +15 -9
  299. package/cjs/symbol/is_not_symbol.d.ts.map +1 -1
  300. package/cjs/symbol/is_symbol.d.ts +15 -9
  301. package/cjs/symbol/is_symbol.d.ts.map +1 -1
  302. package/cjs/testing/stub.d.ts +2 -3
  303. package/cjs/testing/stub.d.ts.map +1 -1
  304. package/cjs/testing/stub.js +1 -2
  305. package/cjs/testing/stub.js.map +1 -1
  306. package/cjs/testing/test_type.d.ts +1 -1
  307. package/cjs/testing/test_type.d.ts.map +1 -1
  308. package/cjs/tuple/drop.js +1 -2
  309. package/cjs/tuple/drop.js.map +1 -1
  310. package/cjs/tuple/is_not_tuple.d.ts +18 -13
  311. package/cjs/tuple/is_not_tuple.d.ts.map +1 -1
  312. package/cjs/tuple/is_tuple.d.ts +18 -13
  313. package/cjs/tuple/is_tuple.d.ts.map +1 -1
  314. package/cjs/tuple/tuple_plus.common_prop_keys.d.ts +1 -1
  315. package/cjs/tuple/tuple_plus.common_prop_keys.d.ts.map +1 -1
  316. package/cjs/tuple/tuple_plus.drop_match.d.ts +1 -1
  317. package/cjs/tuple/tuple_plus.drop_match.d.ts.map +1 -1
  318. package/cjs/tuple/tuple_plus.find.d.ts +1 -1
  319. package/cjs/tuple/tuple_plus.find.d.ts.map +1 -1
  320. package/cjs/type-guard/is_type.d.ts +3 -3
  321. package/cjs/type-guard/is_type.d.ts.map +1 -1
  322. package/cjs/type-guard/is_type.js +1 -2
  323. package/cjs/type-guard/is_type.js.map +1 -1
  324. package/cjs/undefined/has_undefined.d.ts +4 -5
  325. package/cjs/undefined/has_undefined.d.ts.map +1 -1
  326. package/cjs/undefined/is_not_undefined.d.ts +15 -9
  327. package/cjs/undefined/is_not_undefined.d.ts.map +1 -1
  328. package/cjs/undefined/is_undefined.d.ts +15 -9
  329. package/cjs/undefined/is_undefined.d.ts.map +1 -1
  330. package/cjs/union/union_to_intersection.js +1 -2
  331. package/cjs/union/union_to_intersection.js.map +1 -1
  332. package/cjs/unknown/is_not_unknown.d.ts +15 -14
  333. package/cjs/unknown/is_not_unknown.d.ts.map +1 -1
  334. package/cjs/unknown/is_unknown.d.ts +15 -14
  335. package/cjs/unknown/is_unknown.d.ts.map +1 -1
  336. package/cjs/unknown/not_unknown_or.d.ts +1 -1
  337. package/cjs/unknown/not_unknown_or.d.ts.map +1 -1
  338. package/cjs/utils/Widen.d.ts +9 -2
  339. package/cjs/utils/Widen.d.ts.map +1 -1
  340. package/cjs/utils/as.d.ts +1 -1
  341. package/cjs/utils/as.d.ts.map +1 -1
  342. package/cjs/utils/as.js +3 -4
  343. package/cjs/utils/as.js.map +1 -1
  344. package/cjs/utils/excessive.d.ts +12 -0
  345. package/cjs/utils/excessive.d.ts.map +1 -0
  346. package/cjs/utils/excessive.js +3 -0
  347. package/cjs/utils/excessive.js.map +1 -0
  348. package/cjs/utils/inspect.js +1 -2
  349. package/cjs/utils/inspect.js.map +1 -1
  350. package/cjs/{type → utils}/no_infer.d.ts +9 -7
  351. package/cjs/utils/no_infer.d.ts.map +1 -0
  352. package/cjs/{type → utils}/no_infer.js.map +1 -1
  353. package/cjs/void/is_not_void.d.ts +17 -10
  354. package/cjs/void/is_not_void.d.ts.map +1 -1
  355. package/cjs/void/is_void.d.ts +17 -10
  356. package/cjs/void/is_void.d.ts.map +1 -1
  357. package/{cjs/type_plus → esm/$type}/$resolve_options.d.ts +2 -2
  358. package/esm/$type/$resolve_options.d.ts.map +1 -0
  359. package/esm/$type/$resolve_options.js.map +1 -0
  360. package/esm/$type/$type.d.ts +34 -0
  361. package/esm/$type/$type.d.ts.map +1 -0
  362. package/esm/{type_plus → $type}/$type.js.map +1 -1
  363. package/{cjs/type_plus → esm/$type}/branch/$branch.d.ts +3 -3
  364. package/esm/$type/branch/$branch.d.ts.map +1 -0
  365. package/esm/$type/branch/$branch.js.map +1 -0
  366. package/{cjs/type_plus → esm/$type}/branch/$input_options.d.ts +2 -1
  367. package/esm/$type/branch/$input_options.d.ts.map +1 -0
  368. package/esm/$type/branch/$input_options.js.map +1 -0
  369. package/esm/$type/branch/$resolve_branch.d.ts +22 -0
  370. package/esm/$type/branch/$resolve_branch.d.ts.map +1 -0
  371. package/esm/$type/branch/$resolve_branch.js.map +1 -0
  372. package/esm/$type/branch/$selection.d.ts +161 -0
  373. package/esm/$type/branch/$selection.d.ts.map +1 -0
  374. package/esm/$type/branch/$selection.js.map +1 -0
  375. package/esm/$type/distributive/$distributive.d.ts +27 -0
  376. package/esm/$type/distributive/$distributive.d.ts.map +1 -0
  377. package/esm/$type/distributive/$distributive.js.map +1 -0
  378. package/esm/$type/errors/$error.d.ts +23 -0
  379. package/esm/$type/errors/$error.d.ts.map +1 -0
  380. package/esm/{type_plus → $type/errors}/$error.js.map +1 -1
  381. package/{cjs/type_plus → esm/$type/errors}/$infer_error.d.ts +7 -6
  382. package/esm/$type/errors/$infer_error.d.ts.map +1 -0
  383. package/esm/$type/errors/$infer_error.js.map +1 -0
  384. package/{cjs/type → esm/$type/errors}/failed.d.ts +4 -0
  385. package/esm/$type/errors/failed.d.ts.map +1 -0
  386. package/esm/{type → $type/errors}/failed.js.map +1 -1
  387. package/esm/$type/exact/$exact.d.ts +27 -0
  388. package/esm/$type/exact/$exact.d.ts.map +1 -0
  389. package/esm/{type_plus/branch → $type/exact}/$exact.js.map +1 -1
  390. package/esm/$type/special/$any.d.ts +36 -0
  391. package/esm/$type/special/$any.d.ts.map +1 -0
  392. package/esm/$type/special/$any.js +2 -0
  393. package/esm/$type/special/$any.js.map +1 -0
  394. package/esm/$type/special/$never.d.ts +52 -0
  395. package/esm/$type/special/$never.d.ts.map +1 -0
  396. package/esm/$type/special/$never.js +2 -0
  397. package/esm/$type/special/$never.js.map +1 -0
  398. package/esm/$type/special/$special.d.ts +31 -0
  399. package/esm/$type/special/$special.d.ts.map +1 -0
  400. package/esm/$type/special/$special.js +2 -0
  401. package/esm/$type/special/$special.js.map +1 -0
  402. package/esm/$type/special/$unknown.d.ts +37 -0
  403. package/esm/$type/special/$unknown.d.ts.map +1 -0
  404. package/esm/$type/special/$unknown.js +2 -0
  405. package/esm/$type/special/$unknown.js.map +1 -0
  406. package/esm/$type/special/$void.d.ts +46 -0
  407. package/esm/$type/special/$void.d.ts.map +1 -0
  408. package/esm/$type/special/$void.js +2 -0
  409. package/esm/$type/special/$void.js.map +1 -0
  410. package/esm/$type/utils/$merge_options.d.ts +14 -0
  411. package/esm/$type/utils/$merge_options.d.ts.map +1 -0
  412. package/esm/$type/utils/$merge_options.js.map +1 -0
  413. package/esm/any/is_any.d.ts +23 -20
  414. package/esm/any/is_any.d.ts.map +1 -1
  415. package/esm/any/is_not_any.d.ts +15 -14
  416. package/esm/any/is_not_any.d.ts.map +1 -1
  417. package/esm/array/array.reverse.d.ts +1 -1
  418. package/esm/array/array.reverse.d.ts.map +1 -1
  419. package/esm/array/array.some.d.ts +1 -1
  420. package/esm/array/array.some.d.ts.map +1 -1
  421. package/esm/array/array_plus.common_prop_keys.d.ts +1 -1
  422. package/esm/array/array_plus.common_prop_keys.d.ts.map +1 -1
  423. package/esm/array/array_plus.filter.d.ts +2 -2
  424. package/esm/array/array_plus.filter.d.ts.map +1 -1
  425. package/esm/array/array_plus.find.d.ts +2 -2
  426. package/esm/array/array_plus.find.d.ts.map +1 -1
  427. package/esm/array/array_plus.index_at.d.ts +16 -10
  428. package/esm/array/array_plus.index_at.d.ts.map +1 -1
  429. package/esm/array/array_plus.index_at.js.map +1 -1
  430. package/esm/array/array_plus.is_readonly.d.ts +3 -3
  431. package/esm/array/array_plus.is_readonly.d.ts.map +1 -1
  432. package/esm/array/head.d.ts +3 -3
  433. package/esm/array/head.d.ts.map +1 -1
  434. package/esm/array/is_array.d.ts +23 -19
  435. package/esm/array/is_array.d.ts.map +1 -1
  436. package/esm/array/is_not_array.d.ts +23 -19
  437. package/esm/array/is_not_array.d.ts.map +1 -1
  438. package/esm/array/last.d.ts +5 -3
  439. package/esm/array/last.d.ts.map +1 -1
  440. package/esm/assertion/assert_type.d.ts +1 -1
  441. package/esm/assertion/assert_type.d.ts.map +1 -1
  442. package/esm/assertion/assert_type.js +0 -2
  443. package/esm/assertion/assert_type.js.map +1 -1
  444. package/esm/bigint/is_bigint.d.ts +20 -16
  445. package/esm/bigint/is_bigint.d.ts.map +1 -1
  446. package/esm/bigint/is_bigint_literal.d.ts +18 -13
  447. package/esm/bigint/is_bigint_literal.d.ts.map +1 -1
  448. package/esm/bigint/is_not_bigint.d.ts +20 -16
  449. package/esm/bigint/is_not_bigint.d.ts.map +1 -1
  450. package/esm/bigint/is_not_bigint_literal.d.ts +19 -13
  451. package/esm/bigint/is_not_bigint_literal.d.ts.map +1 -1
  452. package/esm/binary/_binary.d.ts +2 -1
  453. package/esm/binary/_binary.d.ts.map +1 -1
  454. package/esm/binary/_binary.js +2 -1
  455. package/esm/binary/_binary.js.map +1 -1
  456. package/esm/binary/bit.d.ts +26 -0
  457. package/esm/binary/bit.d.ts.map +1 -0
  458. package/esm/binary/bit.js +2 -0
  459. package/esm/binary/bit.js.map +1 -0
  460. package/esm/boolean/is_boolean.d.ts +20 -16
  461. package/esm/boolean/is_boolean.d.ts.map +1 -1
  462. package/esm/boolean/is_false.d.ts +15 -9
  463. package/esm/boolean/is_false.d.ts.map +1 -1
  464. package/esm/boolean/is_not_boolean.d.ts +21 -16
  465. package/esm/boolean/is_not_boolean.d.ts.map +1 -1
  466. package/esm/boolean/is_not_false.d.ts +16 -9
  467. package/esm/boolean/is_not_false.d.ts.map +1 -1
  468. package/esm/boolean/is_not_true.d.ts +15 -9
  469. package/esm/boolean/is_not_true.d.ts.map +1 -1
  470. package/esm/boolean/is_true.d.ts +15 -9
  471. package/esm/boolean/is_true.d.ts.map +1 -1
  472. package/esm/equal/equal.d.ts +189 -74
  473. package/esm/equal/equal.d.ts.map +1 -1
  474. package/esm/equal/identity_equal.d.ts +5 -1
  475. package/esm/equal/identity_equal.d.ts.map +1 -1
  476. package/esm/equal/is_equal.d.ts +102 -0
  477. package/esm/equal/is_equal.d.ts.map +1 -0
  478. package/esm/equal/is_equal.js +2 -0
  479. package/esm/equal/is_equal.js.map +1 -0
  480. package/esm/function/extract_function.d.ts.map +1 -1
  481. package/esm/function/is_function.d.ts +28 -5
  482. package/esm/function/is_function.d.ts.map +1 -1
  483. package/esm/function/is_not_function.d.ts +1 -1
  484. package/esm/function/is_not_function.d.ts.map +1 -1
  485. package/esm/function/is_not_strict_function.d.ts +15 -13
  486. package/esm/function/is_not_strict_function.d.ts.map +1 -1
  487. package/esm/function/is_strict_function.d.ts +22 -17
  488. package/esm/function/is_strict_function.d.ts.map +1 -1
  489. package/esm/functional/Maybe.d.ts +1 -1
  490. package/esm/functional/Maybe.d.ts.map +1 -1
  491. package/esm/functional/compose.d.ts.map +1 -1
  492. package/esm/functional/compose.js +1 -3
  493. package/esm/functional/compose.js.map +1 -1
  494. package/esm/index.d.ts +21 -22
  495. package/esm/index.d.ts.map +1 -1
  496. package/esm/index.js.map +1 -1
  497. package/esm/json.js +1 -1
  498. package/esm/json.js.map +1 -1
  499. package/esm/logical/logical.d.ts +35 -0
  500. package/esm/logical/logical.d.ts.map +1 -0
  501. package/esm/{predicates → logical}/logical.js.map +1 -1
  502. package/esm/math/abs.d.ts +1 -1
  503. package/esm/math/abs.d.ts.map +1 -1
  504. package/esm/math/numeric_struct.d.ts.map +1 -1
  505. package/esm/mix_types/box.d.ts +2 -2
  506. package/esm/mix_types/box.d.ts.map +1 -1
  507. package/esm/mix_types/is_any_or_never.d.ts +2 -3
  508. package/esm/mix_types/is_any_or_never.d.ts.map +1 -1
  509. package/esm/mix_types/merge.d.ts +18 -6
  510. package/esm/mix_types/merge.d.ts.map +1 -1
  511. package/esm/mix_types/merge.js.map +1 -1
  512. package/esm/never/is_never.d.ts +16 -15
  513. package/esm/never/is_never.d.ts.map +1 -1
  514. package/esm/never/is_not_never.d.ts +16 -15
  515. package/esm/never/is_not_never.d.ts.map +1 -1
  516. package/esm/null/is_not_null.d.ts +15 -9
  517. package/esm/null/is_not_null.d.ts.map +1 -1
  518. package/esm/null/is_null.d.ts +15 -9
  519. package/esm/null/is_null.d.ts.map +1 -1
  520. package/esm/number/is_not_number.d.ts +20 -16
  521. package/esm/number/is_not_number.d.ts.map +1 -1
  522. package/esm/number/is_not_number_literal.d.ts +18 -13
  523. package/esm/number/is_not_number_literal.d.ts.map +1 -1
  524. package/esm/number/is_number.d.ts +20 -16
  525. package/esm/number/is_number.d.ts.map +1 -1
  526. package/esm/number/is_number_literal.d.ts +18 -13
  527. package/esm/number/is_number_literal.d.ts.map +1 -1
  528. package/esm/numeric/is_integer.d.ts +18 -12
  529. package/esm/numeric/is_integer.d.ts.map +1 -1
  530. package/esm/numeric/is_negative.d.ts +19 -13
  531. package/esm/numeric/is_negative.d.ts.map +1 -1
  532. package/esm/numeric/is_not_integer.d.ts +13 -7
  533. package/esm/numeric/is_not_integer.d.ts.map +1 -1
  534. package/esm/numeric/is_not_negative.d.ts +15 -9
  535. package/esm/numeric/is_not_negative.d.ts.map +1 -1
  536. package/esm/numeric/is_not_numeric.d.ts +1 -1
  537. package/esm/numeric/is_not_numeric.d.ts.map +1 -1
  538. package/esm/numeric/is_not_positive.d.ts +13 -7
  539. package/esm/numeric/is_not_positive.d.ts.map +1 -1
  540. package/esm/numeric/is_numeric.d.ts +28 -5
  541. package/esm/numeric/is_numeric.d.ts.map +1 -1
  542. package/esm/numeric/is_positive.d.ts +19 -13
  543. package/esm/numeric/is_positive.d.ts.map +1 -1
  544. package/esm/object/ANotB.d.ts +1 -1
  545. package/esm/object/ANotB.d.ts.map +1 -1
  546. package/esm/object/adjust_exact_optional_props.d.ts +6 -3
  547. package/esm/object/adjust_exact_optional_props.d.ts.map +1 -1
  548. package/esm/object/index.d.ts +6 -6
  549. package/esm/object/index.d.ts.map +1 -1
  550. package/esm/object/index.js.map +1 -1
  551. package/esm/object/is_not_object.d.ts +23 -19
  552. package/esm/object/is_not_object.d.ts.map +1 -1
  553. package/esm/object/is_object.d.ts +23 -19
  554. package/esm/object/is_object.d.ts.map +1 -1
  555. package/esm/object/left_join.d.ts +1 -1
  556. package/esm/object/left_join.d.ts.map +1 -1
  557. package/esm/object/merge.d.ts +54 -48
  558. package/esm/object/merge.d.ts.map +1 -1
  559. package/esm/object/properties.d.ts +29 -4
  560. package/esm/object/properties.d.ts.map +1 -1
  561. package/esm/object/properties.js +1 -0
  562. package/esm/object/properties.js.map +1 -1
  563. package/esm/object/typeOverrideIncompatible.d.ts.map +1 -1
  564. package/esm/predicates/assignable.d.ts +23 -25
  565. package/esm/predicates/assignable.d.ts.map +1 -1
  566. package/esm/predicates/index.d.ts +1 -1
  567. package/esm/predicates/index.d.ts.map +1 -1
  568. package/esm/predicates/index.js.map +1 -1
  569. package/esm/predicates/not_assignable.d.ts +24 -26
  570. package/esm/predicates/not_assignable.d.ts.map +1 -1
  571. package/esm/promise/index.d.ts +1 -1
  572. package/esm/promise/index.d.ts.map +1 -1
  573. package/esm/promise/index.js +1 -1
  574. package/esm/promise/index.js.map +1 -1
  575. package/esm/promise/isPromise.js +1 -1
  576. package/esm/promise/isPromise.js.map +1 -1
  577. package/esm/string/$extract_manipulated_string.d.ts.map +1 -1
  578. package/esm/string/_string_type.d.ts.map +1 -1
  579. package/esm/string/is_not_string.d.ts +20 -17
  580. package/esm/string/is_not_string.d.ts.map +1 -1
  581. package/esm/string/is_not_string_literal.d.ts +25 -22
  582. package/esm/string/is_not_string_literal.d.ts.map +1 -1
  583. package/esm/string/is_not_template_literal.d.ts +18 -13
  584. package/esm/string/is_not_template_literal.d.ts.map +1 -1
  585. package/esm/string/is_string.d.ts +20 -16
  586. package/esm/string/is_string.d.ts.map +1 -1
  587. package/esm/string/is_string_literal.d.ts +25 -22
  588. package/esm/string/is_string_literal.d.ts.map +1 -1
  589. package/esm/string/is_template_literal.d.ts +18 -13
  590. package/esm/string/is_template_literal.d.ts.map +1 -1
  591. package/esm/symbol/is_not_symbol.d.ts +15 -9
  592. package/esm/symbol/is_not_symbol.d.ts.map +1 -1
  593. package/esm/symbol/is_symbol.d.ts +15 -9
  594. package/esm/symbol/is_symbol.d.ts.map +1 -1
  595. package/esm/testing/stub.d.ts +2 -3
  596. package/esm/testing/stub.d.ts.map +1 -1
  597. package/esm/testing/stub.js.map +1 -1
  598. package/esm/testing/test_type.d.ts +1 -1
  599. package/esm/testing/test_type.d.ts.map +1 -1
  600. package/esm/tuple/is_not_tuple.d.ts +18 -13
  601. package/esm/tuple/is_not_tuple.d.ts.map +1 -1
  602. package/esm/tuple/is_tuple.d.ts +18 -13
  603. package/esm/tuple/is_tuple.d.ts.map +1 -1
  604. package/esm/tuple/tuple_plus.common_prop_keys.d.ts +1 -1
  605. package/esm/tuple/tuple_plus.common_prop_keys.d.ts.map +1 -1
  606. package/esm/tuple/tuple_plus.drop_match.d.ts +1 -1
  607. package/esm/tuple/tuple_plus.drop_match.d.ts.map +1 -1
  608. package/esm/tuple/tuple_plus.find.d.ts +1 -1
  609. package/esm/tuple/tuple_plus.find.d.ts.map +1 -1
  610. package/esm/type-guard/is_type.d.ts +3 -3
  611. package/esm/type-guard/is_type.d.ts.map +1 -1
  612. package/esm/undefined/has_undefined.d.ts +4 -5
  613. package/esm/undefined/has_undefined.d.ts.map +1 -1
  614. package/esm/undefined/is_not_undefined.d.ts +15 -9
  615. package/esm/undefined/is_not_undefined.d.ts.map +1 -1
  616. package/esm/undefined/is_undefined.d.ts +15 -9
  617. package/esm/undefined/is_undefined.d.ts.map +1 -1
  618. package/esm/unknown/is_not_unknown.d.ts +15 -14
  619. package/esm/unknown/is_not_unknown.d.ts.map +1 -1
  620. package/esm/unknown/is_unknown.d.ts +15 -14
  621. package/esm/unknown/is_unknown.d.ts.map +1 -1
  622. package/esm/unknown/not_unknown_or.d.ts +1 -1
  623. package/esm/unknown/not_unknown_or.d.ts.map +1 -1
  624. package/esm/utils/Widen.d.ts +9 -2
  625. package/esm/utils/Widen.d.ts.map +1 -1
  626. package/esm/utils/as.d.ts +1 -1
  627. package/esm/utils/as.d.ts.map +1 -1
  628. package/esm/utils/excessive.d.ts +12 -0
  629. package/esm/utils/excessive.d.ts.map +1 -0
  630. package/esm/utils/excessive.js +2 -0
  631. package/esm/utils/excessive.js.map +1 -0
  632. package/esm/{type → utils}/no_infer.d.ts +9 -7
  633. package/esm/utils/no_infer.d.ts.map +1 -0
  634. package/esm/{type → utils}/no_infer.js.map +1 -1
  635. package/esm/void/is_not_void.d.ts +17 -10
  636. package/esm/void/is_not_void.d.ts.map +1 -1
  637. package/esm/void/is_void.d.ts +17 -10
  638. package/esm/void/is_void.d.ts.map +1 -1
  639. package/package.json +18 -22
  640. package/readme.md +74 -74
  641. package/src/{type_plus → $type}/$resolve_options.ts +4 -2
  642. package/src/$type/$type.ts +37 -0
  643. package/src/{type_plus → $type}/branch/$branch.ts +4 -2
  644. package/src/{type_plus → $type}/branch/$input_options.ts +2 -1
  645. package/src/$type/branch/$resolve_branch.ts +46 -0
  646. package/src/$type/branch/$selection.ts +170 -0
  647. package/src/$type/branch/readme.md +78 -0
  648. package/src/$type/distributive/$distributive.ts +34 -0
  649. package/src/$type/distributive/readme.md +26 -0
  650. package/src/$type/errors/$error.ts +20 -0
  651. package/src/{type_plus → $type/errors}/$infer_error.ts +7 -8
  652. package/src/{type → $type/errors}/failed.ts +4 -0
  653. package/src/$type/errors/readme.md +60 -0
  654. package/src/$type/exact/$exact.ts +34 -0
  655. package/src/$type/exact/readme.md +27 -0
  656. package/src/$type/readme.md +23 -0
  657. package/src/$type/special/$any.ts +34 -0
  658. package/src/$type/special/$never.ts +51 -0
  659. package/src/$type/special/$special.ts +40 -0
  660. package/src/$type/special/$unknown.ts +35 -0
  661. package/src/$type/special/$void.ts +44 -0
  662. package/src/$type/special/readme.md +51 -0
  663. package/src/$type/utils/$merge_options.ts +11 -0
  664. package/src/$type/utils/readme.md +10 -0
  665. package/src/any/is_any.ts +23 -20
  666. package/src/any/is_not_any.ts +15 -14
  667. package/src/any/readme.md +30 -19
  668. package/src/array/array.reverse.ts +2 -5
  669. package/src/array/array.some.ts +1 -1
  670. package/src/array/array_plus.common_prop_keys.ts +1 -1
  671. package/src/array/array_plus.filter.ts +2 -2
  672. package/src/array/array_plus.find.ts +2 -2
  673. package/src/array/array_plus.index_at.ts +23 -29
  674. package/src/array/array_plus.is_readonly.ts +3 -3
  675. package/src/array/head.ts +3 -3
  676. package/src/array/is_array.ts +30 -23
  677. package/src/array/is_not_array.ts +30 -23
  678. package/src/array/last.ts +6 -14
  679. package/src/array/readme.md +3 -3
  680. package/src/assertion/assert_type.ts +1 -3
  681. package/src/bigint/is_bigint.ts +28 -21
  682. package/src/bigint/is_bigint_literal.ts +25 -17
  683. package/src/bigint/is_not_bigint.ts +27 -20
  684. package/src/bigint/is_not_bigint_literal.ts +26 -17
  685. package/src/bigint/readme.md +25 -8
  686. package/src/binary/_binary.ts +2 -1
  687. package/src/binary/bit.ts +29 -0
  688. package/src/binary/readme.md +11 -0
  689. package/src/boolean/is_boolean.ts +30 -23
  690. package/src/boolean/is_false.ts +18 -9
  691. package/src/boolean/is_not_boolean.ts +30 -22
  692. package/src/boolean/is_not_false.ts +19 -9
  693. package/src/boolean/is_not_true.ts +18 -9
  694. package/src/boolean/is_true.ts +18 -9
  695. package/src/equal/equal.ts +307 -89
  696. package/src/equal/identity_equal.ts +3 -7
  697. package/src/equal/is_equal.ts +150 -0
  698. package/src/equal/readme.md +20 -1
  699. package/src/function/is_function.ts +37 -5
  700. package/src/function/is_not_function.ts +1 -1
  701. package/src/function/is_not_strict_function.ts +16 -14
  702. package/src/function/is_strict_function.ts +29 -21
  703. package/src/functional/Maybe.ts +1 -1
  704. package/src/functional/compose.ts +1 -3
  705. package/src/index.ts +21 -22
  706. package/src/json.ts +1 -1
  707. package/src/logical/logical.ts +52 -0
  708. package/src/logical/readme.md +53 -0
  709. package/src/math/abs.ts +1 -1
  710. package/src/math/numeric_struct.ts +6 -6
  711. package/src/mix_types/box.ts +2 -2
  712. package/src/mix_types/is_any_or_never.ts +2 -3
  713. package/src/mix_types/merge.ts +22 -17
  714. package/src/never/is_never.ts +16 -15
  715. package/src/never/is_not_never.ts +16 -15
  716. package/src/null/is_not_null.ts +18 -9
  717. package/src/null/is_null.ts +18 -9
  718. package/src/number/is_not_number.ts +27 -20
  719. package/src/number/is_not_number_literal.ts +25 -17
  720. package/src/number/is_number.ts +27 -20
  721. package/src/number/is_number_literal.ts +25 -17
  722. package/src/numeric/is_integer.ts +29 -30
  723. package/src/numeric/is_negative.ts +29 -20
  724. package/src/numeric/is_not_integer.ts +19 -10
  725. package/src/numeric/is_not_negative.ts +25 -13
  726. package/src/numeric/is_not_numeric.ts +1 -1
  727. package/src/numeric/is_not_positive.ts +19 -9
  728. package/src/numeric/is_numeric.ts +37 -5
  729. package/src/numeric/is_positive.ts +29 -21
  730. package/src/object/ANotB.ts +1 -1
  731. package/src/object/adjust_exact_optional_props.ts +10 -1
  732. package/src/object/index.ts +6 -6
  733. package/src/object/is_not_object.ts +29 -22
  734. package/src/object/is_object.ts +29 -22
  735. package/src/object/left_join.ts +1 -1
  736. package/src/object/merge.ts +53 -49
  737. package/src/object/properties.ts +35 -2
  738. package/src/predicates/assignable.ts +23 -25
  739. package/src/predicates/index.ts +1 -1
  740. package/src/predicates/not_assignable.ts +24 -26
  741. package/src/promise/index.ts +1 -1
  742. package/src/promise/isPromise.ts +1 -1
  743. package/src/string/$extract_manipulated_string.ts +32 -28
  744. package/src/string/_string_type.ts +9 -8
  745. package/src/string/is_not_string.ts +29 -23
  746. package/src/string/is_not_string_literal.ts +36 -30
  747. package/src/string/is_not_template_literal.ts +24 -16
  748. package/src/string/is_string.ts +27 -20
  749. package/src/string/is_string_literal.ts +36 -30
  750. package/src/string/is_template_literal.ts +24 -16
  751. package/src/symbol/is_not_symbol.ts +18 -9
  752. package/src/symbol/is_symbol.ts +18 -9
  753. package/src/testing/stub.ts +0 -1
  754. package/src/testing/test_type.ts +1 -1
  755. package/src/tuple/is_not_tuple.ts +26 -17
  756. package/src/tuple/is_tuple.ts +25 -17
  757. package/src/tuple/tuple_plus.common_prop_keys.ts +1 -1
  758. package/src/tuple/tuple_plus.drop_match.ts +1 -1
  759. package/src/tuple/tuple_plus.find.ts +1 -1
  760. package/src/type-guard/is_type.ts +1 -1
  761. package/src/undefined/has_undefined.ts +5 -6
  762. package/src/undefined/is_not_undefined.ts +18 -9
  763. package/src/undefined/is_undefined.ts +18 -9
  764. package/src/unknown/is_not_unknown.ts +15 -14
  765. package/src/unknown/is_unknown.ts +15 -14
  766. package/src/unknown/not_unknown_or.ts +1 -1
  767. package/src/utils/Widen.ts +9 -2
  768. package/src/utils/excessive.ts +11 -0
  769. package/src/{type → utils}/no_infer.ts +13 -7
  770. package/src/utils/readme.md +17 -0
  771. package/src/void/is_not_void.ts +20 -10
  772. package/src/void/is_void.ts +20 -10
  773. package/cjs/any/any.d.ts +0 -49
  774. package/cjs/any/any.d.ts.map +0 -1
  775. package/cjs/any/any.js.map +0 -1
  776. package/cjs/binary/Bit.d.ts +0 -6
  777. package/cjs/binary/Bit.d.ts.map +0 -1
  778. package/cjs/binary/Bit.js.map +0 -1
  779. package/cjs/binary/index.d.ts +0 -3
  780. package/cjs/binary/index.d.ts.map +0 -1
  781. package/cjs/binary/index.js +0 -6
  782. package/cjs/binary/index.js.map +0 -1
  783. package/cjs/never/never.d.ts +0 -75
  784. package/cjs/never/never.d.ts.map +0 -1
  785. package/cjs/never/never.js.map +0 -1
  786. package/cjs/predicates/logical.d.ts +0 -5
  787. package/cjs/predicates/logical.d.ts.map +0 -1
  788. package/cjs/type/failed.d.ts.map +0 -1
  789. package/cjs/type/no_infer.d.ts.map +0 -1
  790. package/cjs/type_plus/$equality.d.ts +0 -12
  791. package/cjs/type_plus/$equality.d.ts.map +0 -1
  792. package/cjs/type_plus/$equality.js +0 -3
  793. package/cjs/type_plus/$equality.js.map +0 -1
  794. package/cjs/type_plus/$error.d.ts +0 -8
  795. package/cjs/type_plus/$error.d.ts.map +0 -1
  796. package/cjs/type_plus/$infer_error.d.ts.map +0 -1
  797. package/cjs/type_plus/$infer_error.js.map +0 -1
  798. package/cjs/type_plus/$merge_options.d.ts +0 -11
  799. package/cjs/type_plus/$merge_options.d.ts.map +0 -1
  800. package/cjs/type_plus/$merge_options.js.map +0 -1
  801. package/cjs/type_plus/$resolve_options.d.ts.map +0 -1
  802. package/cjs/type_plus/$resolve_options.js.map +0 -1
  803. package/cjs/type_plus/$special_type.d.ts +0 -19
  804. package/cjs/type_plus/$special_type.d.ts.map +0 -1
  805. package/cjs/type_plus/$special_type.js +0 -3
  806. package/cjs/type_plus/$special_type.js.map +0 -1
  807. package/cjs/type_plus/$type.d.ts +0 -11
  808. package/cjs/type_plus/$type.d.ts.map +0 -1
  809. package/cjs/type_plus/branch/$branch.d.ts.map +0 -1
  810. package/cjs/type_plus/branch/$branch.js.map +0 -1
  811. package/cjs/type_plus/branch/$distributive.d.ts +0 -19
  812. package/cjs/type_plus/branch/$distributive.d.ts.map +0 -1
  813. package/cjs/type_plus/branch/$distributive.js.map +0 -1
  814. package/cjs/type_plus/branch/$exact.d.ts +0 -21
  815. package/cjs/type_plus/branch/$exact.d.ts.map +0 -1
  816. package/cjs/type_plus/branch/$input_options.d.ts.map +0 -1
  817. package/cjs/type_plus/branch/$input_options.js.map +0 -1
  818. package/cjs/type_plus/branch/$is_distributive.d.ts +0 -6
  819. package/cjs/type_plus/branch/$is_distributive.d.ts.map +0 -1
  820. package/cjs/type_plus/branch/$is_distributive.js +0 -3
  821. package/cjs/type_plus/branch/$is_distributive.js.map +0 -1
  822. package/cjs/type_plus/branch/$override.d.ts +0 -21
  823. package/cjs/type_plus/branch/$override.d.ts.map +0 -1
  824. package/cjs/type_plus/branch/$override.js +0 -3
  825. package/cjs/type_plus/branch/$override.js.map +0 -1
  826. package/cjs/type_plus/branch/$resolve_branch.d.ts +0 -29
  827. package/cjs/type_plus/branch/$resolve_branch.d.ts.map +0 -1
  828. package/cjs/type_plus/branch/$resolve_branch.js.map +0 -1
  829. package/cjs/type_plus/branch/$select.d.ts +0 -77
  830. package/cjs/type_plus/branch/$select.d.ts.map +0 -1
  831. package/cjs/type_plus/branch/$select.js +0 -3
  832. package/cjs/type_plus/branch/$select.js.map +0 -1
  833. package/cjs/type_plus/branch/$select_invert.d.ts +0 -75
  834. package/cjs/type_plus/branch/$select_invert.d.ts.map +0 -1
  835. package/cjs/type_plus/branch/$select_invert.js +0 -3
  836. package/cjs/type_plus/branch/$select_invert.js.map +0 -1
  837. package/cjs/type_plus/branch/$select_invert_strict.d.ts +0 -75
  838. package/cjs/type_plus/branch/$select_invert_strict.d.ts.map +0 -1
  839. package/cjs/type_plus/branch/$select_invert_strict.js +0 -3
  840. package/cjs/type_plus/branch/$select_invert_strict.js.map +0 -1
  841. package/cjs/type_plus/branch/$select_strict.d.ts +0 -76
  842. package/cjs/type_plus/branch/$select_strict.d.ts.map +0 -1
  843. package/cjs/type_plus/branch/$select_strict.js +0 -3
  844. package/cjs/type_plus/branch/$select_strict.js.map +0 -1
  845. package/cjs/type_plus/branch/$selection.d.ts +0 -127
  846. package/cjs/type_plus/branch/$selection.d.ts.map +0 -1
  847. package/cjs/type_plus/branch/$selection.js.map +0 -1
  848. package/cjs/type_plus/branch/$selection_options.d.ts +0 -37
  849. package/cjs/type_plus/branch/$selection_options.d.ts.map +0 -1
  850. package/cjs/type_plus/branch/$selection_options.js +0 -3
  851. package/cjs/type_plus/branch/$selection_options.js.map +0 -1
  852. package/cjs/unknown/unknown.d.ts +0 -55
  853. package/cjs/unknown/unknown.d.ts.map +0 -1
  854. package/cjs/unknown/unknown.js +0 -3
  855. package/cjs/unknown/unknown.js.map +0 -1
  856. package/esm/any/any.d.ts +0 -49
  857. package/esm/any/any.d.ts.map +0 -1
  858. package/esm/any/any.js +0 -2
  859. package/esm/any/any.js.map +0 -1
  860. package/esm/binary/Bit.d.ts +0 -6
  861. package/esm/binary/Bit.d.ts.map +0 -1
  862. package/esm/binary/Bit.js +0 -2
  863. package/esm/binary/Bit.js.map +0 -1
  864. package/esm/binary/index.d.ts +0 -3
  865. package/esm/binary/index.d.ts.map +0 -1
  866. package/esm/binary/index.js +0 -3
  867. package/esm/binary/index.js.map +0 -1
  868. package/esm/never/never.d.ts +0 -75
  869. package/esm/never/never.d.ts.map +0 -1
  870. package/esm/never/never.js +0 -2
  871. package/esm/never/never.js.map +0 -1
  872. package/esm/predicates/logical.d.ts +0 -5
  873. package/esm/predicates/logical.d.ts.map +0 -1
  874. package/esm/type/failed.d.ts.map +0 -1
  875. package/esm/type/no_infer.d.ts.map +0 -1
  876. package/esm/type_plus/$equality.d.ts +0 -12
  877. package/esm/type_plus/$equality.d.ts.map +0 -1
  878. package/esm/type_plus/$equality.js +0 -2
  879. package/esm/type_plus/$equality.js.map +0 -1
  880. package/esm/type_plus/$error.d.ts +0 -8
  881. package/esm/type_plus/$error.d.ts.map +0 -1
  882. package/esm/type_plus/$infer_error.d.ts.map +0 -1
  883. package/esm/type_plus/$infer_error.js.map +0 -1
  884. package/esm/type_plus/$merge_options.d.ts +0 -11
  885. package/esm/type_plus/$merge_options.d.ts.map +0 -1
  886. package/esm/type_plus/$merge_options.js.map +0 -1
  887. package/esm/type_plus/$resolve_options.d.ts.map +0 -1
  888. package/esm/type_plus/$resolve_options.js.map +0 -1
  889. package/esm/type_plus/$special_type.d.ts +0 -19
  890. package/esm/type_plus/$special_type.d.ts.map +0 -1
  891. package/esm/type_plus/$special_type.js +0 -2
  892. package/esm/type_plus/$special_type.js.map +0 -1
  893. package/esm/type_plus/$type.d.ts +0 -11
  894. package/esm/type_plus/$type.d.ts.map +0 -1
  895. package/esm/type_plus/branch/$branch.d.ts.map +0 -1
  896. package/esm/type_plus/branch/$branch.js.map +0 -1
  897. package/esm/type_plus/branch/$distributive.d.ts +0 -19
  898. package/esm/type_plus/branch/$distributive.d.ts.map +0 -1
  899. package/esm/type_plus/branch/$distributive.js.map +0 -1
  900. package/esm/type_plus/branch/$exact.d.ts +0 -21
  901. package/esm/type_plus/branch/$exact.d.ts.map +0 -1
  902. package/esm/type_plus/branch/$input_options.d.ts.map +0 -1
  903. package/esm/type_plus/branch/$input_options.js.map +0 -1
  904. package/esm/type_plus/branch/$is_distributive.d.ts +0 -6
  905. package/esm/type_plus/branch/$is_distributive.d.ts.map +0 -1
  906. package/esm/type_plus/branch/$is_distributive.js +0 -2
  907. package/esm/type_plus/branch/$is_distributive.js.map +0 -1
  908. package/esm/type_plus/branch/$override.d.ts +0 -21
  909. package/esm/type_plus/branch/$override.d.ts.map +0 -1
  910. package/esm/type_plus/branch/$override.js +0 -2
  911. package/esm/type_plus/branch/$override.js.map +0 -1
  912. package/esm/type_plus/branch/$resolve_branch.d.ts +0 -29
  913. package/esm/type_plus/branch/$resolve_branch.d.ts.map +0 -1
  914. package/esm/type_plus/branch/$resolve_branch.js.map +0 -1
  915. package/esm/type_plus/branch/$select.d.ts +0 -77
  916. package/esm/type_plus/branch/$select.d.ts.map +0 -1
  917. package/esm/type_plus/branch/$select.js +0 -2
  918. package/esm/type_plus/branch/$select.js.map +0 -1
  919. package/esm/type_plus/branch/$select_invert.d.ts +0 -75
  920. package/esm/type_plus/branch/$select_invert.d.ts.map +0 -1
  921. package/esm/type_plus/branch/$select_invert.js +0 -2
  922. package/esm/type_plus/branch/$select_invert.js.map +0 -1
  923. package/esm/type_plus/branch/$select_invert_strict.d.ts +0 -75
  924. package/esm/type_plus/branch/$select_invert_strict.d.ts.map +0 -1
  925. package/esm/type_plus/branch/$select_invert_strict.js +0 -2
  926. package/esm/type_plus/branch/$select_invert_strict.js.map +0 -1
  927. package/esm/type_plus/branch/$select_strict.d.ts +0 -76
  928. package/esm/type_plus/branch/$select_strict.d.ts.map +0 -1
  929. package/esm/type_plus/branch/$select_strict.js +0 -2
  930. package/esm/type_plus/branch/$select_strict.js.map +0 -1
  931. package/esm/type_plus/branch/$selection.d.ts +0 -127
  932. package/esm/type_plus/branch/$selection.d.ts.map +0 -1
  933. package/esm/type_plus/branch/$selection.js.map +0 -1
  934. package/esm/type_plus/branch/$selection_options.d.ts +0 -37
  935. package/esm/type_plus/branch/$selection_options.d.ts.map +0 -1
  936. package/esm/type_plus/branch/$selection_options.js +0 -2
  937. package/esm/type_plus/branch/$selection_options.js.map +0 -1
  938. package/esm/unknown/unknown.d.ts +0 -55
  939. package/esm/unknown/unknown.d.ts.map +0 -1
  940. package/esm/unknown/unknown.js +0 -2
  941. package/esm/unknown/unknown.js.map +0 -1
  942. package/src/any/any.ts +0 -46
  943. package/src/binary/Bit.ts +0 -6
  944. package/src/binary/index.ts +0 -2
  945. package/src/never/never.ts +0 -78
  946. package/src/predicates/logical.ts +0 -19
  947. package/src/type/readme.md +0 -36
  948. package/src/type_plus/$equality.ts +0 -12
  949. package/src/type_plus/$error.ts +0 -8
  950. package/src/type_plus/$merge_options.ts +0 -8
  951. package/src/type_plus/$special_type.ts +0 -26
  952. package/src/type_plus/$type.ts +0 -10
  953. package/src/type_plus/branch/$distributive.ts +0 -19
  954. package/src/type_plus/branch/$exact.ts +0 -28
  955. package/src/type_plus/branch/$is_distributive.ts +0 -15
  956. package/src/type_plus/branch/$override.ts +0 -22
  957. package/src/type_plus/branch/$resolve_branch.ts +0 -71
  958. package/src/type_plus/branch/$select.ts +0 -89
  959. package/src/type_plus/branch/$select_invert.ts +0 -83
  960. package/src/type_plus/branch/$select_invert_strict.ts +0 -83
  961. package/src/type_plus/branch/$select_strict.ts +0 -88
  962. package/src/type_plus/branch/$selection.ts +0 -134
  963. package/src/type_plus/branch/$selection_options.ts +0 -36
  964. package/src/type_plus/readme.md +0 -25
  965. package/src/unknown/unknown.ts +0 -57
  966. /package/cjs/{type_plus → $type}/$resolve_options.js +0 -0
  967. /package/cjs/{type_plus → $type}/$type.js +0 -0
  968. /package/cjs/{type_plus → $type}/branch/$branch.js +0 -0
  969. /package/cjs/{type_plus → $type}/branch/$input_options.js +0 -0
  970. /package/cjs/{type_plus → $type}/branch/$resolve_branch.js +0 -0
  971. /package/cjs/{type_plus → $type}/branch/$selection.js +0 -0
  972. /package/cjs/{type_plus/branch → $type/distributive}/$distributive.js +0 -0
  973. /package/cjs/{type_plus → $type/errors}/$error.js +0 -0
  974. /package/cjs/{type_plus → $type/errors}/$infer_error.js +0 -0
  975. /package/cjs/{type → $type/errors}/failed.js +0 -0
  976. /package/cjs/{type_plus/branch → $type/exact}/$exact.js +0 -0
  977. /package/cjs/{type_plus → $type/utils}/$merge_options.js +0 -0
  978. /package/cjs/{predicates → logical}/logical.js +0 -0
  979. /package/cjs/{type → utils}/no_infer.js +0 -0
  980. /package/esm/{type_plus → $type}/$resolve_options.js +0 -0
  981. /package/esm/{type_plus → $type}/$type.js +0 -0
  982. /package/esm/{type_plus → $type}/branch/$branch.js +0 -0
  983. /package/esm/{type_plus → $type}/branch/$input_options.js +0 -0
  984. /package/esm/{type_plus → $type}/branch/$resolve_branch.js +0 -0
  985. /package/esm/{type_plus → $type}/branch/$selection.js +0 -0
  986. /package/esm/{type_plus/branch → $type/distributive}/$distributive.js +0 -0
  987. /package/esm/{type_plus → $type/errors}/$error.js +0 -0
  988. /package/esm/{type_plus → $type/errors}/$infer_error.js +0 -0
  989. /package/esm/{type → $type/errors}/failed.js +0 -0
  990. /package/esm/{type_plus/branch → $type/exact}/$exact.js +0 -0
  991. /package/esm/{type_plus → $type/utils}/$merge_options.js +0 -0
  992. /package/esm/{predicates → logical}/logical.js +0 -0
  993. /package/esm/{type → utils}/no_infer.js +0 -0
@@ -1,8 +1,14 @@
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
4
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
5
+ import type { $Exact } from '../$type/exact/$exact.js'
6
+ import type { $Any } from '../$type/special/$any.js'
7
+ import type { $Never } from '../$type/special/$never.js'
8
+ import type { $Unknown } from '../$type/special/$unknown.js'
9
+ import type { $Void } from '../$type/special/$void.js'
1
10
  import type { IsBigint } from '../bigint/is_bigint.js'
2
11
  import type { IsNumber } from '../number/is_number.js'
3
- import type { $Equality } from '../type_plus/$equality.js'
4
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
5
- import type { $Else, $Then } from '../type_plus/branch/$selection.js'
6
12
 
7
13
  /**
8
14
  * Is `T` not a positive numeric type.
@@ -33,18 +39,22 @@ export type IsNotPositive<T, $O extends IsNotPositive.$Options = {}> = IsBigint<
33
39
  : IsNumber<Exclude<T, bigint>, { distributive: $O['distributive']; $then: $Then; $else: $Else }> extends infer R
34
40
  ? R extends $Then
35
41
  ? IsNotPositive._Negative<T, number, $O>
36
- : $ResolveBranch<Exclude<T, number | bigint>, $O, [$Then]>
42
+ : $ResolveBranch<$O, [$Then], Exclude<T, number | bigint>>
37
43
  : never
38
44
  : never
39
45
 
40
46
  export namespace IsNotPositive {
41
- export type $Options = $Equality.$Options
42
- export type $Branch<$O extends $Options = {}> = $Equality.$Branch<$O>
47
+ export type $Options = $Selection.Options &
48
+ $Distributive.Options &
49
+ $Exact.Options &
50
+ $InputOptions<$Any | $Unknown | $Never | $Void>
51
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
52
+
43
53
  export type _Negative<T, U extends number | bigint, $O extends IsNotPositive.$Options> = T extends U
44
54
  ? `${T}` extends `-${string}`
45
- ? $ResolveBranch<T, $O, [$Then]>
55
+ ? $ResolveBranch<$O, [$Then], T>
46
56
  : U extends T
47
- ? $ResolveBranch<T, $O, [$Then]> | $ResolveBranch<T, $O, [$Else]>
48
- : $ResolveBranch<T, $O, [$Else]>
57
+ ? $ResolveBranch<$O, [$Then], T> | $ResolveBranch<$O, [$Else]>
58
+ : $ResolveBranch<$O, [$Else]>
49
59
  : never
50
60
  }
@@ -1,4 +1,15 @@
1
- import type { $Select } from '../type_plus/branch/$select.js'
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection } from '../$type/branch/$selection.js'
4
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
5
+ import type { $Exact } from '../$type/exact/$exact.js'
6
+ import type { $Any } from '../$type/special/$any.js'
7
+ import type { $Never } from '../$type/special/$never.js'
8
+ import type { $Special } from '../$type/special/$special.js'
9
+ import type { $Unknown } from '../$type/special/$unknown.js'
10
+ import type { $Void } from '../$type/special/$void.js'
11
+ import type { $MergeOptions } from '../$type/utils/$merge_options.js'
12
+ import type { Assignable } from '../predicates/assignable.js'
2
13
 
3
14
  /**
4
15
  * Is `T` numeric.
@@ -11,10 +22,31 @@ import type { $Select } from '../type_plus/branch/$select.js'
11
22
  * type R = IsNumeric<unknown> // false
12
23
  * ```
13
24
  */
14
- export type IsNumeric<T, $O extends IsNumeric.$Options = {}> = $Select<T, number | bigint, $O>
25
+ export type IsNumeric<T, $O extends IsNumeric.$Options = {}> = $Special<
26
+ T,
27
+ $MergeOptions<
28
+ $O,
29
+ {
30
+ $then: $ResolveBranch<$O, [$Else]>
31
+ $else: IsNumeric.$<T, $O>
32
+ }
33
+ >
34
+ >
15
35
 
16
36
  export namespace IsNumeric {
17
- export type $Options = $Select.$Options
18
- export type $Default = $Select.$Default
19
- export type $Branch = $Select.$Branch
37
+ export type $Options = $Selection.Options &
38
+ $Distributive.Options &
39
+ $Exact.Options &
40
+ $InputOptions<$Any | $Unknown | $Never | $Void>
41
+ export type $Default = $Selection.Predicate & $Distributive.Default & $Exact.Default
42
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
43
+ /**
44
+ * 🧰 *type util*
45
+ *
46
+ * Validate if `T` is `Function`.
47
+ *
48
+ * This is a type util for building custom types.
49
+ * It does not check against special types.
50
+ */
51
+ export type $<T, $O extends Assignable.$UtilOptions> = Assignable.$<T, number | bigint, $O>
20
52
  }
@@ -1,8 +1,14 @@
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
4
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
5
+ import type { $Exact } from '../$type/exact/$exact.js'
6
+ import type { $Any } from '../$type/special/$any.js'
7
+ import type { $Never } from '../$type/special/$never.js'
8
+ import type { $Unknown } from '../$type/special/$unknown.js'
9
+ import type { $Void } from '../$type/special/$void.js'
1
10
  import type { IsBigint } from '../bigint/is_bigint.js'
2
11
  import type { IsNumber } from '../number/is_number.js'
3
- import type { $Equality } from '../type_plus/$equality.js'
4
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
5
- import type { $Else, $Then } from '../type_plus/branch/$selection.js'
6
12
 
7
13
  /**
8
14
  * Is `T` a positive numeric type.
@@ -23,29 +29,31 @@ export type IsPositive<T, $O extends IsPositive.$Options = {}> = IsBigint<
23
29
  T,
24
30
  {
25
31
  distributive: $O['distributive']
26
- $then: $Then
27
- $else: $Else
32
+ $then: IsPositive._Positive<T, bigint, $O>
33
+ $else: IsNumber<
34
+ Exclude<T, bigint>,
35
+ {
36
+ distributive: $O['distributive']
37
+ $then: IsPositive._Positive<T, number, $O>
38
+ $else: $ResolveBranch<$O, [$Else]>
39
+ }
40
+ >
28
41
  }
29
- > extends infer R
30
- ? R extends $Then
31
- ? IsPositive._Positive<T, bigint, $O>
32
- : IsNumber<Exclude<T, bigint>, { distributive: $O['distributive']; $then: $Then; $else: $Else }> extends infer R
33
- ? R extends $Then
34
- ? IsPositive._Positive<T, number, $O>
35
- : $ResolveBranch<T, $O, [$Else]>
36
- : never
37
- : never
38
-
42
+ >
39
43
  export namespace IsPositive {
40
- export type $Options = $Equality.$Options
41
- export type $Branch<$O extends $Options = {}> = $Equality.$Branch<$O>
44
+ export type $Options = $Selection.Options &
45
+ $Distributive.Options &
46
+ $Exact.Options &
47
+ $InputOptions<$Any | $Unknown | $Never | $Void>
48
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
49
+
42
50
  export type _Positive<T, U extends number | bigint, $O extends IsPositive.$Options> = T extends U & infer R
43
51
  ? `${T}` extends `-${string}`
44
- ? $ResolveBranch<T, $O, [$Else]>
52
+ ? $ResolveBranch<$O, [$Else]>
45
53
  : U extends T
46
- ? $ResolveBranch<T, $O, [$Then]> | $ResolveBranch<T, $O, [$Else]>
54
+ ? $ResolveBranch<$O, [$Then], T> | $ResolveBranch<$O, [$Else]>
47
55
  : [T, R] extends [R, T]
48
- ? $ResolveBranch<T, $O, [$Then]>
49
- : $ResolveBranch<number, $O, [$Then]> | $ResolveBranch<T, $O, [$Else]>
56
+ ? $ResolveBranch<$O, [$Then], T>
57
+ : $ResolveBranch<$O, [$Then], T> | $ResolveBranch<$O, [$Else]>
50
58
  : never
51
59
  }
@@ -1,4 +1,4 @@
1
- import type { IsEqual } from '../equal/equal.js'
1
+ import type { IsEqual } from '../equal/is_equal.js'
2
2
  import type { AnyRecord } from './any_record.js'
3
3
  import type { IsDisjoint } from './IsDisjoint.js'
4
4
  import type { KeysWithDiffType } from './KeysWithDiffType.js'
@@ -10,5 +10,14 @@ import type { RequiredKeys } from './RequiredKeys.js'
10
10
  * It adds `undefined` to optional properties.
11
11
  */
12
12
  export type AdjustExactOptionalProps<T extends AnyRecord> = T extends object
13
- ? { [K in OptionalKeys<T>]?: T[K] | undefined } & { [K in RequiredKeys<T>]: T[K] }
13
+ ? [{ [K in OptionalKeys<T>]?: T[K] | undefined }, { [K in RequiredKeys<T>]: T[K] }] extends [
14
+ infer O extends AnyRecord,
15
+ infer R extends AnyRecord,
16
+ ]
17
+ ? keyof O extends never
18
+ ? R
19
+ : keyof R extends never
20
+ ? O
21
+ : O & R
22
+ : never
14
23
  : never
@@ -1,8 +1,8 @@
1
- export type * from './adjust_exact_optional_props.js'
2
1
  export type { ANotB, BNotA } from './ANotB.js'
2
+ export type * from './adjust_exact_optional_props.js'
3
3
  export type { AnyRecord } from './any_record.js'
4
- export * from './everyKey.js'
5
4
  export type { ExcludePropType } from './ExcludePropType.js'
5
+ export * from './everyKey.js'
6
6
  export * from './facade.js'
7
7
  export * from './filterKey.js'
8
8
  export * from './findKey.js'
@@ -25,15 +25,15 @@ export type * from './optional_key.js'
25
25
  export type { Partial, PartialExcept, PartialOmit, PartialPick } from './Partial.js'
26
26
  export * from './pick.js'
27
27
  export type { Properties } from './properties.js'
28
- export * from './record.js'
29
- export type { RecursivePartial } from './recursive_partial.js'
30
28
  export type { RecursiveIntersect } from './RecursiveIntersect.js'
31
29
  export type { RecursiveRequired } from './RecursiveRequired.js'
30
+ export type { RequiredKeys } from './RequiredKeys.js'
31
+ export * from './record.js'
32
+ export type { RecursivePartial } from './recursive_partial.js'
32
33
  export * from './reduceKey.js'
33
34
  export * from './replaceProperty.js'
34
- export type { RequiredKeys } from './RequiredKeys.js'
35
+ export type { SpreadRecord } from './SpreadRecord.js'
35
36
  export * from './someKey.js'
36
37
  export * from './split.js'
37
- export type { SpreadRecord } from './SpreadRecord.js'
38
38
  export * from './typeOverrideIncompatible.js'
39
39
  export type { ValueOf } from './ValueOf.js'
@@ -1,14 +1,18 @@
1
+ import type { $ResolveOptions } from '../$type/$resolve_options.js'
2
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
3
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
4
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
5
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
6
+ import type { $Exact } from '../$type/exact/$exact.js'
7
+ import type { $Any } from '../$type/special/$any.js'
8
+ import type { $Never } from '../$type/special/$never.js'
9
+ import type { $Special } from '../$type/special/$special.js'
10
+ import type { $Unknown } from '../$type/special/$unknown.js'
11
+ import type { $Void } from '../$type/special/$void.js'
12
+ import type { $MergeOptions } from '../$type/utils/$merge_options.js'
1
13
  import type { IdentityEqual } from '../equal/identity_equal.js'
2
14
  import type { IsNever } from '../never/is_never.js'
3
15
  import type { NotAssignable } from '../predicates/not_assignable.js'
4
- import type { $Equality } from '../type_plus/$equality.js'
5
- import type { $MergeOptions } from '../type_plus/$merge_options.js'
6
- import type { $ResolveOptions } from '../type_plus/$resolve_options.js'
7
- import type { $SpecialType } from '../type_plus/$special_type.js'
8
- import type { $ExactDefault, $ExactOptions } from '../type_plus/branch/$exact.js'
9
- import type { $IsDistributive } from '../type_plus/branch/$is_distributive.js'
10
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
11
- import type { $Else, $Then } from '../type_plus/branch/$selection.js'
12
16
 
13
17
  /**
14
18
  * Is `T` not an `object`.
@@ -89,19 +93,22 @@ import type { $Else, $Then } from '../type_plus/branch/$selection.js'
89
93
  * type R = IsNotObject<string, $SelectionBranch> // $Then
90
94
  * ```
91
95
  */
92
- export type IsNotObject<T, $O extends IsNotObject.$Options = {}> = $SpecialType<
96
+ export type IsNotObject<T, $O extends IsNotObject.$Options = {}> = $Special<
93
97
  T,
94
98
  $MergeOptions<
95
99
  $O,
96
100
  {
97
- $then: $ResolveBranch<T, $O, [$Then]>
101
+ $then: $ResolveBranch<$O, [$Then], T>
98
102
  $else: IsNotObject.$<T, $O>
99
103
  }
100
104
  >
101
105
  >
102
106
  export namespace IsNotObject {
103
- export type $Options = $Equality.$Options & $ExactOptions
104
- export type $Branch<$O extends $Options = {}> = $Equality.$Branch<$O>
107
+ export type $Options = $Selection.Options &
108
+ $Distributive.Options &
109
+ $Exact.Options &
110
+ $InputOptions<$Any | $Unknown | $Never | $Void>
111
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
105
112
 
106
113
  /**
107
114
  * 🧰 *type util*
@@ -111,29 +118,29 @@ export namespace IsNotObject {
111
118
  * This is a type util for building custom types.
112
119
  * It does not check against special types.
113
120
  */
114
- export type $<T, $O extends $UtilOptions> = $ResolveOptions<[$O['exact'], $ExactDefault]> extends true
115
- ? $IsDistributive<$O, { $then: _D<T, $O>; $else: _N<T, $O> }>
121
+ export type $<T, $O extends $UtilOptions> = $ResolveOptions<[$O['exact'], $Exact.Default]> extends true
122
+ ? $Distributive.Parse<$O, { $then: _D<T, $O>; $else: _N<T, $O> }>
116
123
  : NotAssignable.$<T, object, $O>
117
- export type $UtilOptions = NotAssignable.$UtilOptions & $ExactOptions
124
+ export type $UtilOptions = NotAssignable.$UtilOptions & $Exact.Options
118
125
 
119
126
  export type _D<T, $O extends $UtilOptions> = T extends object
120
127
  ? IdentityEqual<
121
128
  T,
122
129
  {},
123
- $ResolveBranch<T, $O, [$Then]>,
130
+ $ResolveBranch<$O, [$Then], T>,
124
131
  IsNever<
125
132
  keyof T,
126
133
  {
127
- $then: $ResolveBranch<T, $O, [$Else]>
128
- $else: $ResolveBranch<T, $O, [$Then]>
134
+ $then: $ResolveBranch<$O, [$Else]>
135
+ $else: $ResolveBranch<$O, [$Then], T>
129
136
  }
130
137
  >
131
138
  >
132
- : $ResolveBranch<T, $O, [$Then]>
139
+ : $ResolveBranch<$O, [$Then], T>
133
140
 
134
141
  export type _N<T, $O extends $UtilOptions> = [T] extends [object & infer U]
135
142
  ? U extends object
136
- ? $ResolveBranch<T, $O, [$Then]>
137
- : $ResolveBranch<T, $O, [$Else]>
138
- : $ResolveBranch<T, $O, [$Then]>
143
+ ? $ResolveBranch<$O, [$Then], T>
144
+ : $ResolveBranch<$O, [$Else]>
145
+ : $ResolveBranch<$O, [$Then], T>
139
146
  }
@@ -1,14 +1,18 @@
1
+ import type { $ResolveOptions } from '../$type/$resolve_options.js'
2
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
3
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
4
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
5
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
6
+ import type { $Exact } from '../$type/exact/$exact.js'
7
+ import type { $Any } from '../$type/special/$any.js'
8
+ import type { $Never } from '../$type/special/$never.js'
9
+ import type { $Special } from '../$type/special/$special.js'
10
+ import type { $Unknown } from '../$type/special/$unknown.js'
11
+ import type { $Void } from '../$type/special/$void.js'
12
+ import type { $MergeOptions } from '../$type/utils/$merge_options.js'
1
13
  import type { IdentityEqual } from '../equal/identity_equal.js'
2
14
  import type { IsNever } from '../never/is_never.js'
3
15
  import type { Assignable } from '../predicates/assignable.js'
4
- import type { $Equality } from '../type_plus/$equality.js'
5
- import type { $MergeOptions } from '../type_plus/$merge_options.js'
6
- import type { $ResolveOptions } from '../type_plus/$resolve_options.js'
7
- import type { $SpecialType } from '../type_plus/$special_type.js'
8
- import type { $ExactDefault, $ExactOptions } from '../type_plus/branch/$exact.js'
9
- import type { $IsDistributive } from '../type_plus/branch/$is_distributive.js'
10
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
11
- import type { $Else, $Then } from '../type_plus/branch/$selection.js'
12
16
 
13
17
  /**
14
18
  * 🎭 *predicate*
@@ -76,20 +80,23 @@ import type { $Else, $Then } from '../type_plus/branch/$selection.js'
76
80
  * type R = IsObject<string, $SelectionBranch> // $Else
77
81
  * ```
78
82
  */
79
- export type IsObject<T, $O extends IsObject.$Options = {}> = $SpecialType<
83
+ export type IsObject<T, $O extends IsObject.$Options = {}> = $Special<
80
84
  T,
81
85
  $MergeOptions<
82
86
  $O,
83
87
  {
84
- $then: $ResolveBranch<T, $O, [$Else]>
88
+ $then: $ResolveBranch<$O, [$Else]>
85
89
  $else: IsObject.$<T, $O>
86
90
  }
87
91
  >
88
92
  >
89
93
 
90
94
  export namespace IsObject {
91
- export type $Options = $Equality.$Options & $ExactOptions
92
- export type $Branch<$O extends $Options = {}> = $Equality.$Branch<$O>
95
+ export type $Options = $Selection.Options &
96
+ $Distributive.Options &
97
+ $Exact.Options &
98
+ $InputOptions<$Any | $Unknown | $Never | $Void>
99
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
93
100
 
94
101
  /**
95
102
  * 🧰 *type util*
@@ -99,29 +106,29 @@ export namespace IsObject {
99
106
  * This is a type util for building custom types.
100
107
  * It does not check against special types.
101
108
  */
102
- export type $<T, $O extends $UtilOptions> = $ResolveOptions<[$O['exact'], $ExactDefault]> extends true
103
- ? $IsDistributive<$O, { $then: _D<T, $O>; $else: _N<T, $O> }>
109
+ export type $<T, $O extends $UtilOptions> = $ResolveOptions<[$O['exact'], $Exact.Default]> extends true
110
+ ? $Distributive.Parse<$O, { $then: _D<T, $O>; $else: _N<T, $O> }>
104
111
  : Assignable.$<T, object, $O>
105
- export type $UtilOptions = Assignable.$UtilOptions & $ExactOptions
112
+ export type $UtilOptions = Assignable.$UtilOptions & $Exact.Options
106
113
 
107
114
  export type _D<T, $O extends $UtilOptions> = T extends object
108
115
  ? IdentityEqual<
109
116
  T,
110
117
  {},
111
- $ResolveBranch<T, $O, [$Else]>,
118
+ $ResolveBranch<$O, [$Else]>,
112
119
  IsNever<
113
120
  keyof T,
114
121
  {
115
- $then: $ResolveBranch<T, $O, [$Then]>
116
- $else: $ResolveBranch<T, $O, [$Else]>
122
+ $then: $ResolveBranch<$O, [$Then], T>
123
+ $else: $ResolveBranch<$O, [$Else]>
117
124
  }
118
125
  >
119
126
  >
120
- : $ResolveBranch<T, $O, [$Else]>
127
+ : $ResolveBranch<$O, [$Else]>
121
128
 
122
129
  export type _N<T, $O extends $UtilOptions> = [T] extends [object & infer U]
123
130
  ? U extends object
124
- ? $ResolveBranch<T, $O, [$Else]>
125
- : $ResolveBranch<T, $O, [$Then]>
126
- : $ResolveBranch<T, $O, [$Else]>
131
+ ? $ResolveBranch<$O, [$Else]>
132
+ : $ResolveBranch<$O, [$Then], T>
133
+ : $ResolveBranch<$O, [$Else]>
127
134
  }
@@ -1,4 +1,4 @@
1
- import type { IsEqual } from '../equal/equal.js'
1
+ import type { IsEqual } from '../equal/is_equal.js'
2
2
  import type { AnyRecord } from './any_record.js'
3
3
  import type { IsDisjoint } from './IsDisjoint.js'
4
4
  import type { Properties } from './properties.js'
@@ -1,10 +1,10 @@
1
+ import type { $Never } from '../$type/special/$never.js'
1
2
  import type { IsAny } from '../any/is_any.js'
2
3
  import type { NonComposableTypes } from '../composable_types.js'
4
+ import type { Or } from '../logical/logical.js'
3
5
  import type { IsNever } from '../never/is_never.js'
4
6
  import type { IsNotNever } from '../never/is_not_never.js'
5
- import type { $Never } from '../never/never.js'
6
7
  import type { IsLiteral } from '../predicates/literal.js'
7
- import type { Or } from '../predicates/logical.js'
8
8
  import type { AnyRecord } from './any_record.js'
9
9
  import type { IsDisjoint } from './IsDisjoint.js'
10
10
  import type { KeyTypes } from './KeyTypes.js'
@@ -29,56 +29,60 @@ export type Merge<
29
29
  > = Or<
30
30
  IsAny<A>,
31
31
  IsAny<B>,
32
- any,
33
- Or<
34
- IsNever<A>,
35
- IsNever<B>,
36
- never,
37
- IsDisjoint<A, B> extends true
38
- ? A & B
39
- : [keyof A, keyof B] extends [infer KA extends KeyTypes, infer KB extends KeyTypes]
40
- ? IsLiteral<KA> extends true
41
- ? IsLiteral<KB> extends true
42
- ? [OptionalKeys<A>, OptionalKeys<B>] extends [infer PKA extends KeyTypes, infer PKB extends KeyTypes]
43
- ? // property is optional when both A[k] and B[k] are optional
44
- (IsNotNever<PKA & PKB, { selection: 'filter' }> extends infer R extends KeyTypes
45
- ? { [k in R]?: A[k] | B[k] }
46
- : unknown) &
47
- // properties only in A excluding partials is A[k]
48
- (IsNotNever<Exclude<KA, PKA | KB>, { selection: 'filter' }> extends infer R extends KeyTypes
32
+ {
33
+ $then: any
34
+ $else: Or<
35
+ IsNever<A>,
36
+ IsNever<B>,
37
+ {
38
+ $then: never
39
+ $else: IsDisjoint<A, B> extends true
40
+ ? A & B
41
+ : [keyof A, keyof B] extends [infer KA extends KeyTypes, infer KB extends KeyTypes]
42
+ ? IsLiteral<KA> extends true
43
+ ? IsLiteral<KB> extends true
44
+ ? [OptionalKeys<A>, OptionalKeys<B>] extends [infer PKA extends KeyTypes, infer PKB extends KeyTypes]
45
+ ? // property is optional when both A[k] and B[k] are optional
46
+ (IsNotNever<PKA & PKB, { selection: 'filter' }> extends infer R extends KeyTypes
47
+ ? { [k in R]?: A[k] | B[k] }
48
+ : unknown) &
49
+ // properties only in A excluding partials is A[k]
50
+ (IsNotNever<Exclude<KA, PKA | KB>, { selection: 'filter' }> extends infer R extends KeyTypes
51
+ ? { [k in R]: A[k] }
52
+ : unknown) &
53
+ // properties only in B excluding partials is B[k]
54
+ (IsNotNever<Exclude<KB, PKB>, { selection: 'filter' }> extends infer R extends KeyTypes
55
+ ? { [k in R]: B[k] }
56
+ : unknown) &
57
+ // properties is required in A but optional in B is unionized without undefined
58
+ (IsNotNever<Exclude<KA & PKB, PKA>, { selection: 'filter' }> extends infer R extends KeyTypes
59
+ ? { [k in R]: A[k] | Exclude<B[k], undefined> }
60
+ : unknown)
61
+ : never
62
+ : (IsNotNever<Exclude<KA, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
49
63
  ? { [k in R]: A[k] }
50
64
  : unknown) &
51
- // properties only in B excluding partials is B[k]
52
- (IsNotNever<Exclude<KB, PKB>, { selection: 'filter' }> extends infer R extends KeyTypes
53
- ? { [k in R]: B[k] }
65
+ (IsNotNever<Exclude<KB, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
66
+ ? { [k in R]: B[k] }
67
+ : unknown) &
68
+ (IsNotNever<KA & KB, { selection: 'filter' }> extends infer R extends KeyTypes
69
+ ? { [k in R]: A[k] | B[k] }
70
+ : unknown)
71
+ : IsLiteral<KB> extends true
72
+ ? { [k in Exclude<KA, KB>]: A[k] } & { [k in keyof B]: B[k] }
73
+ : (IsNotNever<Exclude<KA, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
74
+ ? { [k in R]: A[k] }
54
75
  : unknown) &
55
- // properties is required in A but optional in B is unionized without undefined
56
- (IsNotNever<Exclude<KA & PKB, PKA>, { selection: 'filter' }> extends infer R extends KeyTypes
57
- ? { [k in R]: A[k] | Exclude<B[k], undefined> }
58
- : unknown)
59
- : never
60
- : (IsNotNever<Exclude<KA, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
61
- ? { [k in R]: A[k] }
62
- : unknown) &
63
- (IsNotNever<Exclude<KB, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
64
- ? { [k in R]: B[k] }
65
- : unknown) &
66
- (IsNotNever<KA & KB, { selection: 'filter' }> extends infer R extends KeyTypes
67
- ? { [k in R]: A[k] | B[k] }
68
- : unknown)
69
- : IsLiteral<KB> extends true
70
- ? { [k in Exclude<KA, KB>]: A[k] } & { [k in keyof B]: B[k] }
71
- : (IsNotNever<Exclude<KA, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
72
- ? { [k in R]: A[k] }
73
- : unknown) &
74
- (IsNotNever<Exclude<KB, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
75
- ? { [k in R]: B[k] }
76
- : unknown) &
77
- (IsNotNever<KA & KB, { selection: 'filter' }> extends infer R extends KeyTypes
78
- ? { [k in R]: A[k] | B[k] }
79
- : unknown)
80
- : never
81
- >
76
+ (IsNotNever<Exclude<KB, KA & KB>, { selection: 'filter' }> extends infer R extends KeyTypes
77
+ ? { [k in R]: B[k] }
78
+ : unknown) &
79
+ (IsNotNever<KA & KB, { selection: 'filter' }> extends infer R extends KeyTypes
80
+ ? { [k in R]: A[k] | B[k] }
81
+ : unknown)
82
+ : never
83
+ }
84
+ >
85
+ }
82
86
  >
83
87
 
84
88
  export namespace Merge {
@@ -1,4 +1,37 @@
1
+ import type { IsAny } from '../any/is_any.js'
2
+ import type { IsUnknown } from '../unknown/is_unknown.js'
3
+
1
4
  /**
2
- * Gets the properties of an object type.
5
+ * Extracts the property map of a type: an object type with the same keys and
6
+ * value types as `T`, preserving optional and readonly modifiers.
7
+ *
8
+ * - For object types: returns `{ [k in keyof T]: T[k] }`.
9
+ * - For `any` and `unknown`: returns the input type unchanged.
10
+ * - For function types (e.g. `() => void`): returns `{}` because call signatures
11
+ * are not indexable; for `Function`, returns the interface of methods.
12
+ * - For intersections: merges properties from all branches.
13
+ *
14
+ * @typeParam T - The type whose properties to extract.
15
+ *
16
+ * @example
17
+ * ```ts
18
+ * type T = { a: number; b?: string }
19
+ * type R = Properties<T> // { a: number; b?: string }
20
+ *
21
+ * type Merged = Properties<{ a: 1 } & { b: 2 }> // { a: 1; b: 2 }
22
+ * ```
3
23
  */
4
- export type Properties<T> = { [k in keyof T]: T[k] } // & {}
24
+ export type Properties<T> = IsAny<
25
+ T,
26
+ {
27
+ $then: T
28
+ $else: IsUnknown<
29
+ T,
30
+ {
31
+ $then: T
32
+ $else: { [k in keyof T]: T[k] } // & {}
33
+ }
34
+ >
35
+ }
36
+ >
37
+ // [unknown] extends [T] ? unknown : { [k in keyof T]: T[k] } // & {}