@histoire/vendors 0.8.4 → 0.9.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.
Files changed (254) hide show
  1. package/dist/client/b-floating-vue.d.ts +3 -0
  2. package/dist/client/{floating-vue.js → b-floating-vue.js} +13 -18
  3. package/dist/client/b-iconify.d.ts +1 -0
  4. package/dist/client/{iconify.js → b-iconify.js} +0 -0
  5. package/dist/client/b-pinia.d.ts +1 -0
  6. package/dist/client/{pinia.js → b-pinia.js} +41 -8
  7. package/dist/client/b-scroll.d.ts +2 -0
  8. package/dist/client/{scroll.js → b-scroll.js} +1 -1
  9. package/dist/client/b-vue-router.d.ts +1 -0
  10. package/dist/client/{vue-router.js → b-vue-router.js} +279 -158
  11. package/dist/client/b-vue-use.d.ts +1 -0
  12. package/dist/client/{vue-use.js → b-vue-use.js} +1070 -603
  13. package/dist/client/b-vue.d.ts +1 -0
  14. package/dist/client/{vue.js → b-vue.js} +1 -1
  15. package/dist/client/node_modules/@babel/parser/package.json +46 -0
  16. package/dist/client/node_modules/@babel/parser/typings/babel-parser.d.ts +214 -0
  17. package/dist/client/node_modules/@floating-ui/core/index.d.ts +1 -0
  18. package/dist/client/node_modules/@floating-ui/core/package.json +70 -0
  19. package/dist/client/node_modules/@floating-ui/core/src/_babel.d.ts +1 -0
  20. package/dist/client/node_modules/@floating-ui/core/src/computeCoordsFromPlacement.d.ts +4 -0
  21. package/dist/client/node_modules/@floating-ui/core/src/computePosition.d.ts +2 -0
  22. package/dist/client/node_modules/@floating-ui/core/src/detectOverflow.d.ts +9 -0
  23. package/dist/client/node_modules/@floating-ui/core/src/enums.d.ts +4 -0
  24. package/dist/client/node_modules/@floating-ui/core/src/index.d.ts +11 -0
  25. package/dist/client/node_modules/@floating-ui/core/src/middleware/arrow.d.ts +6 -0
  26. package/dist/client/node_modules/@floating-ui/core/src/middleware/autoPlacement.d.ts +9 -0
  27. package/dist/client/node_modules/@floating-ui/core/src/middleware/flip.d.ts +10 -0
  28. package/dist/client/node_modules/@floating-ui/core/src/middleware/hide.d.ts +2 -0
  29. package/dist/client/node_modules/@floating-ui/core/src/middleware/inline.d.ts +5 -0
  30. package/dist/client/node_modules/@floating-ui/core/src/middleware/offset.d.ts +21 -0
  31. package/dist/client/node_modules/@floating-ui/core/src/middleware/shift.d.ts +32 -0
  32. package/dist/client/node_modules/@floating-ui/core/src/middleware/size.d.ts +6 -0
  33. package/dist/client/node_modules/@floating-ui/core/src/types.d.ts +148 -0
  34. package/dist/client/node_modules/@floating-ui/core/src/utils/expandPaddingObject.d.ts +2 -0
  35. package/dist/client/node_modules/@floating-ui/core/src/utils/getAlignment.d.ts +2 -0
  36. package/dist/client/node_modules/@floating-ui/core/src/utils/getAlignmentSides.d.ts +5 -0
  37. package/dist/client/node_modules/@floating-ui/core/src/utils/getBasePlacement.d.ts +2 -0
  38. package/dist/client/node_modules/@floating-ui/core/src/utils/getCrossAxis.d.ts +2 -0
  39. package/dist/client/node_modules/@floating-ui/core/src/utils/getExpandedPlacements.d.ts +2 -0
  40. package/dist/client/node_modules/@floating-ui/core/src/utils/getLengthFromAxis.d.ts +2 -0
  41. package/dist/client/node_modules/@floating-ui/core/src/utils/getMainAxisFromPlacement.d.ts +2 -0
  42. package/dist/client/node_modules/@floating-ui/core/src/utils/getOppositeAlignmentPlacement.d.ts +2 -0
  43. package/dist/client/node_modules/@floating-ui/core/src/utils/getOppositePlacement.d.ts +1 -0
  44. package/dist/client/node_modules/@floating-ui/core/src/utils/getPaddingObject.d.ts +2 -0
  45. package/dist/client/node_modules/@floating-ui/core/src/utils/math.d.ts +2 -0
  46. package/dist/client/node_modules/@floating-ui/core/src/utils/rectToClientRect.d.ts +2 -0
  47. package/dist/client/node_modules/@floating-ui/core/src/utils/within.d.ts +1 -0
  48. package/dist/client/node_modules/@floating-ui/dom/index.d.ts +1 -0
  49. package/dist/client/node_modules/@floating-ui/dom/package.json +75 -0
  50. package/dist/client/node_modules/@floating-ui/dom/src/index.d.ts +7 -0
  51. package/dist/client/node_modules/@floating-ui/dom/src/platform.d.ts +2 -0
  52. package/dist/client/node_modules/@floating-ui/dom/src/types.d.ts +27 -0
  53. package/dist/client/node_modules/@floating-ui/dom/src/utils/contains.d.ts +1 -0
  54. package/dist/client/node_modules/@floating-ui/dom/src/utils/convertOffsetParentRelativeRectToViewportRelativeRect.d.ts +6 -0
  55. package/dist/client/node_modules/@floating-ui/dom/src/utils/getBoundingClientRect.d.ts +2 -0
  56. package/dist/client/node_modules/@floating-ui/dom/src/utils/getClippingClientRect.d.ts +6 -0
  57. package/dist/client/node_modules/@floating-ui/dom/src/utils/getComputedStyle.d.ts +1 -0
  58. package/dist/client/node_modules/@floating-ui/dom/src/utils/getDimensions.d.ts +2 -0
  59. package/dist/client/node_modules/@floating-ui/dom/src/utils/getDocumentElement.d.ts +1 -0
  60. package/dist/client/node_modules/@floating-ui/dom/src/utils/getDocumentRect.d.ts +2 -0
  61. package/dist/client/node_modules/@floating-ui/dom/src/utils/getNodeName.d.ts +1 -0
  62. package/dist/client/node_modules/@floating-ui/dom/src/utils/getNodeScroll.d.ts +2 -0
  63. package/dist/client/node_modules/@floating-ui/dom/src/utils/getOffsetParent.d.ts +1 -0
  64. package/dist/client/node_modules/@floating-ui/dom/src/utils/getParentNode.d.ts +1 -0
  65. package/dist/client/node_modules/@floating-ui/dom/src/utils/getRectRelativeToOffsetParent.d.ts +2 -0
  66. package/dist/client/node_modules/@floating-ui/dom/src/utils/getScrollParent.d.ts +1 -0
  67. package/dist/client/node_modules/@floating-ui/dom/src/utils/getScrollParents.d.ts +1 -0
  68. package/dist/client/node_modules/@floating-ui/dom/src/utils/getViewportRect.d.ts +2 -0
  69. package/dist/client/node_modules/@floating-ui/dom/src/utils/getWindowScrollBarX.d.ts +1 -0
  70. package/dist/client/node_modules/@floating-ui/dom/src/utils/is.d.ts +15 -0
  71. package/dist/client/node_modules/@floating-ui/dom/src/utils/math.d.ts +3 -0
  72. package/dist/client/node_modules/@floating-ui/dom/src/utils/window.d.ts +2 -0
  73. package/dist/client/node_modules/@iconify/vue/dist/iconify.d.ts +680 -0
  74. package/dist/client/node_modules/@iconify/vue/dist/offline.d.ts +347 -0
  75. package/dist/client/node_modules/@iconify/vue/offline/package.json +14 -0
  76. package/dist/client/node_modules/@iconify/vue/package.json +61 -0
  77. package/dist/client/node_modules/@types/web-bluetooth/index.d.ts +176 -0
  78. package/dist/client/node_modules/@types/web-bluetooth/package.json +40 -0
  79. package/dist/client/node_modules/@vue/compiler-core/dist/compiler-core.d.ts +1198 -0
  80. package/dist/client/node_modules/@vue/compiler-core/package.json +43 -0
  81. package/dist/client/node_modules/@vue/compiler-dom/dist/compiler-dom.d.ts +66 -0
  82. package/dist/client/node_modules/@vue/compiler-dom/package.json +43 -0
  83. package/dist/client/node_modules/@vue/compiler-sfc/dist/compiler-sfc.d.ts +321 -0
  84. package/dist/client/node_modules/@vue/compiler-sfc/package.json +59 -0
  85. package/dist/client/node_modules/@vue/compiler-ssr/dist/compiler-ssr.d.ts +6 -0
  86. package/dist/client/node_modules/@vue/compiler-ssr/package.json +34 -0
  87. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/api.d.ts +108 -0
  88. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/app.d.ts +1 -0
  89. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/component.d.ts +77 -0
  90. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/context.d.ts +5 -0
  91. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/hooks.d.ts +179 -0
  92. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/index.d.ts +6 -0
  93. package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/util.d.ts +4 -0
  94. package/dist/client/node_modules/@vue/devtools-api/lib/esm/const.d.ts +2 -0
  95. package/dist/client/node_modules/@vue/devtools-api/lib/esm/env.d.ts +15 -0
  96. package/dist/client/node_modules/@vue/devtools-api/lib/esm/index.d.ts +18 -0
  97. package/dist/client/node_modules/@vue/devtools-api/lib/esm/plugin.d.ts +47 -0
  98. package/dist/client/node_modules/@vue/devtools-api/lib/esm/proxy.d.ts +20 -0
  99. package/dist/client/node_modules/@vue/devtools-api/lib/esm/time.d.ts +2 -0
  100. package/dist/client/node_modules/@vue/devtools-api/package.json +37 -0
  101. package/dist/client/node_modules/@vue/reactivity/dist/reactivity.d.ts +347 -0
  102. package/dist/client/node_modules/@vue/reactivity/package.json +41 -0
  103. package/dist/client/node_modules/@vue/reactivity-transform/dist/reactivity-transform.d.ts +33 -0
  104. package/dist/client/node_modules/@vue/reactivity-transform/package.json +41 -0
  105. package/dist/client/node_modules/@vue/runtime-core/dist/runtime-core.d.ts +2018 -0
  106. package/dist/client/node_modules/@vue/runtime-core/package.json +38 -0
  107. package/dist/client/node_modules/@vue/runtime-dom/dist/runtime-dom.d.ts +1522 -0
  108. package/dist/client/node_modules/@vue/runtime-dom/package.json +42 -0
  109. package/dist/client/node_modules/@vue/server-renderer/dist/server-renderer.d.ts +100 -0
  110. package/dist/client/node_modules/@vue/server-renderer/package.json +41 -0
  111. package/dist/client/node_modules/@vue/shared/dist/shared.d.ts +356 -0
  112. package/dist/client/node_modules/@vue/shared/package.json +33 -0
  113. package/dist/client/node_modules/@vueuse/core/index.d.ts +4305 -0
  114. package/dist/client/node_modules/@vueuse/core/metadata.d.ts +1 -0
  115. package/dist/client/node_modules/@vueuse/core/node_modules/@vueuse/shared/index.d.ts +874 -0
  116. package/dist/client/node_modules/@vueuse/core/node_modules/@vueuse/shared/package.json +50 -0
  117. package/dist/client/node_modules/@vueuse/core/node_modules/vue-demi/lib/index.d.ts +22 -0
  118. package/dist/client/node_modules/@vueuse/core/node_modules/vue-demi/lib/v2/index.d.ts +31 -0
  119. package/dist/client/node_modules/@vueuse/core/node_modules/vue-demi/lib/v2.7/index.d.ts +52 -0
  120. package/dist/client/node_modules/@vueuse/core/node_modules/vue-demi/lib/v3/index.d.ts +22 -0
  121. package/dist/client/node_modules/@vueuse/core/node_modules/vue-demi/package.json +47 -0
  122. package/dist/client/node_modules/@vueuse/core/package.json +59 -0
  123. package/dist/client/node_modules/@vueuse/metadata/index.d.ts +75 -0
  124. package/dist/client/node_modules/@vueuse/metadata/package.json +39 -0
  125. package/dist/client/node_modules/compute-scroll-into-view/package.json +90 -0
  126. package/dist/client/node_modules/compute-scroll-into-view/typings/index.d.ts +19 -0
  127. package/dist/client/node_modules/csstype/index.d.ts +38372 -0
  128. package/dist/client/node_modules/csstype/package.json +57 -0
  129. package/dist/client/node_modules/estree-walker/dist/esm/package.json +1 -0
  130. package/dist/client/node_modules/estree-walker/package.json +37 -0
  131. package/dist/client/node_modules/estree-walker/src/package.json +1 -0
  132. package/dist/client/node_modules/estree-walker/types/async.d.ts +53 -0
  133. package/dist/client/node_modules/estree-walker/types/index.d.ts +56 -0
  134. package/dist/client/node_modules/estree-walker/types/sync.d.ts +53 -0
  135. package/dist/client/node_modules/estree-walker/types/walker.d.ts +37 -0
  136. package/dist/client/node_modules/floating-vue/dist/components/Dropdown.vue.d.ts +25 -0
  137. package/dist/client/node_modules/floating-vue/dist/components/Menu.vue.d.ts +25 -0
  138. package/dist/client/node_modules/floating-vue/dist/components/Popper.d.ts +375 -0
  139. package/dist/client/node_modules/floating-vue/dist/components/Popper.vue.d.ts +367 -0
  140. package/dist/client/node_modules/floating-vue/dist/components/PopperContent.vue.d.ts +48 -0
  141. package/dist/client/node_modules/floating-vue/dist/components/PopperMethods.d.ts +9 -0
  142. package/dist/client/node_modules/floating-vue/dist/components/PopperWrapper.vue.d.ts +28 -0
  143. package/dist/client/node_modules/floating-vue/dist/components/ThemeClass.d.ts +6 -0
  144. package/dist/client/node_modules/floating-vue/dist/components/Tooltip.vue.d.ts +25 -0
  145. package/dist/client/node_modules/floating-vue/dist/components/TooltipDirective.vue.d.ts +28 -0
  146. package/dist/client/node_modules/floating-vue/dist/config.d.ts +11 -0
  147. package/dist/client/node_modules/floating-vue/dist/directives/v-close-popper.d.ts +13 -0
  148. package/dist/client/node_modules/floating-vue/dist/directives/v-tooltip.d.ts +27 -0
  149. package/dist/client/node_modules/floating-vue/dist/directives/v-tooltip.spec.d.ts +1 -0
  150. package/dist/client/node_modules/floating-vue/dist/index.d.ts +415 -0
  151. package/dist/client/node_modules/floating-vue/dist/util/assign-deep.d.ts +1 -0
  152. package/dist/client/node_modules/floating-vue/dist/util/env.d.ts +2 -0
  153. package/dist/client/node_modules/floating-vue/dist/util/events.d.ts +12 -0
  154. package/dist/client/node_modules/floating-vue/dist/util/frame.d.ts +1 -0
  155. package/dist/client/node_modules/floating-vue/dist/util/lang.d.ts +1 -0
  156. package/dist/client/node_modules/floating-vue/dist/util/popper.d.ts +3 -0
  157. package/dist/client/node_modules/floating-vue/package.json +71 -0
  158. package/dist/client/node_modules/floating-vue/src/global-shim.d.ts +1 -0
  159. package/dist/client/node_modules/floating-vue/src/vue-shim.d.ts +5 -0
  160. package/dist/client/node_modules/magic-string/index.d.ts +221 -0
  161. package/dist/client/node_modules/magic-string/package.json +52 -0
  162. package/dist/client/node_modules/nanoid/async/index.d.ts +56 -0
  163. package/dist/client/node_modules/nanoid/async/package.json +12 -0
  164. package/dist/client/node_modules/nanoid/index.d.ts +91 -0
  165. package/dist/client/node_modules/nanoid/non-secure/index.d.ts +33 -0
  166. package/dist/client/node_modules/nanoid/non-secure/package.json +6 -0
  167. package/dist/client/node_modules/nanoid/package.json +60 -0
  168. package/dist/client/node_modules/nanoid/url-alphabet/package.json +6 -0
  169. package/dist/client/node_modules/picocolors/package.json +25 -0
  170. package/dist/client/node_modules/picocolors/picocolors.d.ts +5 -0
  171. package/dist/client/node_modules/pinia/dist/pinia.d.ts +963 -0
  172. package/dist/client/node_modules/pinia/node_modules/vue-demi/lib/index.d.ts +22 -0
  173. package/dist/client/node_modules/pinia/node_modules/vue-demi/lib/v2/index.d.ts +31 -0
  174. package/dist/client/node_modules/pinia/node_modules/vue-demi/lib/v2.7/index.d.ts +52 -0
  175. package/dist/client/node_modules/pinia/node_modules/vue-demi/lib/v3/index.d.ts +22 -0
  176. package/dist/client/node_modules/pinia/node_modules/vue-demi/package.json +47 -0
  177. package/dist/client/node_modules/pinia/package.json +101 -0
  178. package/dist/client/node_modules/postcss/lib/at-rule.d.ts +106 -0
  179. package/dist/client/node_modules/postcss/lib/comment.d.ts +56 -0
  180. package/dist/client/node_modules/postcss/lib/container.d.ts +442 -0
  181. package/dist/client/node_modules/postcss/lib/css-syntax-error.d.ts +239 -0
  182. package/dist/client/node_modules/postcss/lib/declaration.d.ts +124 -0
  183. package/dist/client/node_modules/postcss/lib/document.d.ts +57 -0
  184. package/dist/client/node_modules/postcss/lib/fromJSON.d.ts +5 -0
  185. package/dist/client/node_modules/postcss/lib/input.d.ts +150 -0
  186. package/dist/client/node_modules/postcss/lib/lazy-result.d.ts +176 -0
  187. package/dist/client/node_modules/postcss/lib/list.d.ts +51 -0
  188. package/dist/client/node_modules/postcss/lib/no-work-result.d.ts +37 -0
  189. package/dist/client/node_modules/postcss/lib/node.d.ts +478 -0
  190. package/dist/client/node_modules/postcss/lib/parse.d.ts +5 -0
  191. package/dist/client/node_modules/postcss/lib/postcss.d.ts +473 -0
  192. package/dist/client/node_modules/postcss/lib/previous-map.d.ts +72 -0
  193. package/dist/client/node_modules/postcss/lib/processor.d.ts +102 -0
  194. package/dist/client/node_modules/postcss/lib/result.d.ts +196 -0
  195. package/dist/client/node_modules/postcss/lib/root.d.ts +73 -0
  196. package/dist/client/node_modules/postcss/lib/rule.d.ts +104 -0
  197. package/dist/client/node_modules/postcss/lib/stringifier.d.ts +37 -0
  198. package/dist/client/node_modules/postcss/lib/stringify.d.ts +5 -0
  199. package/dist/client/node_modules/postcss/lib/warning.d.ts +138 -0
  200. package/dist/client/node_modules/postcss/package.json +85 -0
  201. package/dist/client/node_modules/scroll-into-view-if-needed/package.json +144 -0
  202. package/dist/client/node_modules/scroll-into-view-if-needed/typings/index.d.ts +13 -0
  203. package/dist/client/node_modules/scroll-into-view-if-needed/typings/types.d.ts +19 -0
  204. package/dist/client/node_modules/source-map/package.json +73 -0
  205. package/dist/client/node_modules/source-map/source-map.d.ts +98 -0
  206. package/dist/client/node_modules/source-map-js/package.json +71 -0
  207. package/dist/client/node_modules/source-map-js/source-map.d.ts +115 -0
  208. package/dist/client/node_modules/sourcemap-codec/dist/types/sourcemap-codec.d.ts +5 -0
  209. package/dist/client/node_modules/sourcemap-codec/package.json +53 -0
  210. package/dist/client/node_modules/vue/compiler-sfc/index.d.ts +1 -0
  211. package/dist/client/node_modules/vue/compiler-sfc/package.json +5 -0
  212. package/dist/client/node_modules/vue/dist/vue.d.ts +9 -0
  213. package/dist/client/node_modules/vue/macros-global.d.ts +19 -0
  214. package/dist/client/node_modules/vue/macros.d.ts +110 -0
  215. package/dist/client/node_modules/vue/package.json +75 -0
  216. package/dist/client/node_modules/vue/ref-macros.d.ts +2 -0
  217. package/dist/client/node_modules/vue/server-renderer/index.d.ts +1 -0
  218. package/dist/client/node_modules/vue/server-renderer/package.json +5 -0
  219. package/dist/client/node_modules/vue-resize/package.json +77 -0
  220. package/dist/client/node_modules/vue-router/dist/vue-router.d.ts +1491 -0
  221. package/dist/client/node_modules/vue-router/package.json +114 -0
  222. package/dist/client/vue.runtime.esm-bundler.js +24 -19
  223. package/entries.js +7 -7
  224. package/floating-vue.d.ts +3 -0
  225. package/iconify.d.ts +3 -0
  226. package/package.json +14 -5
  227. package/pinia.d.ts +3 -0
  228. package/rollup.config.mjs +117 -0
  229. package/scroll.d.ts +3 -0
  230. package/src/client/b-floating-vue.ts +3 -0
  231. package/src/client/b-iconify.ts +1 -0
  232. package/src/client/b-pinia.ts +1 -0
  233. package/src/client/b-scroll.ts +2 -0
  234. package/src/client/b-vue-router.ts +1 -0
  235. package/src/client/b-vue-use.ts +1 -0
  236. package/src/client/b-vue.ts +1 -0
  237. package/vue-router.d.ts +3 -0
  238. package/vue-use.d.ts +3 -0
  239. package/vue.d.ts +3 -0
  240. package/dist/client/floating-vue.d.ts +0 -2
  241. package/dist/client/iconify.d.ts +0 -1
  242. package/dist/client/pinia.d.ts +0 -1
  243. package/dist/client/scroll.d.ts +0 -1
  244. package/dist/client/vue-router.d.ts +0 -1
  245. package/dist/client/vue-use.d.ts +0 -1
  246. package/dist/client/vue.d.ts +0 -1
  247. package/rollup.config.js +0 -37
  248. package/src/client/floating-vue.ts +0 -2
  249. package/src/client/iconify.ts +0 -1
  250. package/src/client/pinia.ts +0 -1
  251. package/src/client/scroll.ts +0 -1
  252. package/src/client/vue-router.ts +0 -1
  253. package/src/client/vue-use.ts +0 -1
  254. package/src/client/vue.ts +0 -1
@@ -0,0 +1,874 @@
1
+ import * as vue_demi from 'vue-demi';
2
+ import { WatchOptionsBase, Ref, ComputedRef, WritableComputedRef, WatchSource, ComputedGetter, WritableComputedOptions, ShallowUnwrapRef as ShallowUnwrapRef$1, WatchOptions, UnwrapRef, ToRefs, WatchCallback, WatchStopHandle } from 'vue-demi';
3
+ import { MaybeRef as MaybeRef$1 } from '@vueuse/shared';
4
+
5
+ declare function computedEager<T>(fn: () => T, options?: WatchOptionsBase): Readonly<Ref<T>>;
6
+
7
+ interface ComputedWithControlRefExtra {
8
+ /**
9
+ * Force update the computed value.
10
+ */
11
+ trigger(): void;
12
+ }
13
+ interface ComputedRefWithControl<T> extends ComputedRef<T>, ComputedWithControlRefExtra {
14
+ }
15
+ interface WritableComputedRefWithControl<T> extends WritableComputedRef<T>, ComputedWithControlRefExtra {
16
+ }
17
+ declare function computedWithControl<T, S>(source: WatchSource<S> | WatchSource<S>[], fn: ComputedGetter<T>): ComputedRefWithControl<T>;
18
+ declare function computedWithControl<T, S>(source: WatchSource<S> | WatchSource<S>[], fn: WritableComputedOptions<T>): WritableComputedRefWithControl<T>;
19
+
20
+ /**
21
+ * The source code for this function was inspired by vue-apollo's `useEventHook` util
22
+ * https://github.com/vuejs/vue-apollo/blob/v4/packages/vue-apollo-composable/src/util/useEventHook.ts
23
+ */
24
+ declare type EventHookOn<T = any> = (fn: (param: T) => void) => {
25
+ off: () => void;
26
+ };
27
+ declare type EventHookOff<T = any> = (fn: (param: T) => void) => void;
28
+ declare type EventHookTrigger<T = any> = (param: T) => void;
29
+ interface EventHook<T = any> {
30
+ on: EventHookOn<T>;
31
+ off: EventHookOff<T>;
32
+ trigger: EventHookTrigger<T>;
33
+ }
34
+ /**
35
+ * Utility for creating event hooks
36
+ *
37
+ * @see https://vueuse.org/createEventHook
38
+ */
39
+ declare function createEventHook<T = any>(): EventHook<T>;
40
+
41
+ declare type CreateGlobalStateReturn<T> = () => T;
42
+ /**
43
+ * Keep states in the global scope to be reusable across Vue instances.
44
+ *
45
+ * @see https://vueuse.org/createGlobalState
46
+ * @param stateFactory A factory function to create the state
47
+ */
48
+ declare function createGlobalState<T>(stateFactory: () => T): CreateGlobalStateReturn<T>;
49
+
50
+ /**
51
+ * Create global state that can be injected into components.
52
+ *
53
+ * @see https://vueuse.org/createInjectionState
54
+ *
55
+ */
56
+ declare function createInjectionState<Arguments extends Array<any>, Return>(composable: (...args: Arguments) => Return): readonly [useProvidingState: (...args: Arguments) => void, useInjectedState: () => Return | undefined];
57
+
58
+ /**
59
+ * Make a composable function usable with multiple Vue instances.
60
+ *
61
+ * @see https://vueuse.org/createSharedComposable
62
+ */
63
+ declare function createSharedComposable<Fn extends ((...args: any[]) => any)>(composable: Fn): Fn;
64
+
65
+ interface ExtendRefOptions<Unwrap extends boolean = boolean> {
66
+ /**
67
+ * Is the extends properties enumerable
68
+ *
69
+ * @default false
70
+ */
71
+ enumerable?: boolean;
72
+ /**
73
+ * Unwrap for Ref properties
74
+ *
75
+ * @default true
76
+ */
77
+ unwrap?: Unwrap;
78
+ }
79
+ /**
80
+ * Overlad 1: Unwrap set to false
81
+ */
82
+ declare function extendRef<R extends Ref<any>, Extend extends object, Options extends ExtendRefOptions<false>>(ref: R, extend: Extend, options?: Options): ShallowUnwrapRef$1<Extend> & R;
83
+ /**
84
+ * Overlad 2: Unwrap unset or set to true
85
+ */
86
+ declare function extendRef<R extends Ref<any>, Extend extends object, Options extends ExtendRefOptions>(ref: R, extend: Extend, options?: Options): Extend & R;
87
+
88
+ declare const isClient: boolean;
89
+ declare const isDef: <T = any>(val?: T | undefined) => val is T;
90
+ declare const assert: (condition: boolean, ...infos: any[]) => void;
91
+ declare const isBoolean: (val: any) => val is boolean;
92
+ declare const isFunction: <T extends Function>(val: any) => val is T;
93
+ declare const isNumber: (val: any) => val is number;
94
+ declare const isString: (val: unknown) => val is string;
95
+ declare const isObject: (val: any) => val is object;
96
+ declare const isWindow: (val: any) => val is Window;
97
+ declare const now: () => number;
98
+ declare const timestamp: () => number;
99
+ declare const clamp: (n: number, min: number, max: number) => number;
100
+ declare const noop: () => void;
101
+ declare const rand: (min: number, max: number) => number;
102
+ declare const isIOS: boolean | "";
103
+
104
+ /**
105
+ * Any function
106
+ */
107
+ declare type Fn = () => void;
108
+ /**
109
+ * A ref that allow to set null or undefined
110
+ */
111
+ declare type RemovableRef<T> = Omit<Ref<T>, 'value'> & {
112
+ get value(): T;
113
+ set value(value: T | null | undefined);
114
+ };
115
+ /**
116
+ * @deprecated Use `RemovableRef`
117
+ */
118
+ declare type RemoveableRef<T> = RemovableRef<T>;
119
+ /**
120
+ * Maybe it's a ref, or a plain value
121
+ *
122
+ * ```ts
123
+ * type MaybeRef<T> = T | Ref<T>
124
+ * ```
125
+ */
126
+ declare type MaybeRef<T> = T | Ref<T>;
127
+ /**
128
+ * Maybe it's a ref, or a getter function
129
+ *
130
+ * ```ts
131
+ * type MaybeRef<T> = T | Ref<T>
132
+ * ```
133
+ */
134
+ declare type MaybeComputedRef<T> = T extends Function ? never : (() => T) | MaybeRef<T>;
135
+ /**
136
+ * Make all the nested attributes of an object or array to MaybeRef<T>
137
+ *
138
+ * Good for accepting options that will be wrapped with `reactive` or `ref`
139
+ *
140
+ * ```ts
141
+ * UnwrapRef<DeepMaybeRef<T>> === T
142
+ * ```
143
+ */
144
+ declare type DeepMaybeRef<T> = T extends Ref<infer V> ? MaybeRef<V> : T extends Array<any> | object ? {
145
+ [K in keyof T]: DeepMaybeRef<T[K]>;
146
+ } : MaybeRef<T>;
147
+ /**
148
+ * Infers the element type of an array
149
+ */
150
+ declare type ElementOf<T> = T extends (infer E)[] ? E : never;
151
+ declare type ShallowUnwrapRef<T> = T extends Ref<infer P> ? P : T;
152
+ declare type Awaitable<T> = Promise<T> | T;
153
+ interface Pausable {
154
+ /**
155
+ * A ref indicate whether a pusable instance is active
156
+ */
157
+ isActive: Ref<boolean>;
158
+ /**
159
+ * Temporary pause the effect from executing
160
+ */
161
+ pause: Fn;
162
+ /**
163
+ * Resume the effects
164
+ */
165
+ resume: Fn;
166
+ }
167
+ interface Stoppable {
168
+ /**
169
+ * A ref indicate whether a stoppable instance is executing
170
+ */
171
+ isPending: Ref<boolean>;
172
+ /**
173
+ * Stop the effect from executing
174
+ */
175
+ stop: Fn;
176
+ /**
177
+ * Start the effects
178
+ */
179
+ start: Fn;
180
+ }
181
+ /**
182
+ * @deprecated Use `Stoppable`
183
+ */
184
+ declare type Stopable = Stoppable;
185
+ interface ConfigurableFlush {
186
+ /**
187
+ * Timing for monitoring changes, refer to WatchOptions for more details
188
+ *
189
+ * @default 'pre'
190
+ */
191
+ flush?: WatchOptions['flush'];
192
+ }
193
+ interface ConfigurableFlushSync {
194
+ /**
195
+ * Timing for monitoring changes, refer to WatchOptions for more details.
196
+ * Unlike `watch()`, the default is set to `sync`
197
+ *
198
+ * @default 'sync'
199
+ */
200
+ flush?: WatchOptions['flush'];
201
+ }
202
+ declare type MapSources<T> = {
203
+ [K in keyof T]: T[K] extends WatchSource<infer V> ? V : never;
204
+ };
205
+ declare type MapOldSources<T, Immediate> = {
206
+ [K in keyof T]: T[K] extends WatchSource<infer V> ? Immediate extends true ? V | undefined : V : never;
207
+ };
208
+
209
+ declare type FunctionArgs<Args extends any[] = any[], Return = void> = (...args: Args) => Return;
210
+ interface FunctionWrapperOptions<Args extends any[] = any[], This = any> {
211
+ fn: FunctionArgs<Args, This>;
212
+ args: Args;
213
+ thisArg: This;
214
+ }
215
+ declare type EventFilter<Args extends any[] = any[], This = any> = (invoke: Fn, options: FunctionWrapperOptions<Args, This>) => void;
216
+ interface ConfigurableEventFilter {
217
+ /**
218
+ * Filter for if events should to be received.
219
+ *
220
+ * @see https://vueuse.org/guide/config.html#event-filters
221
+ */
222
+ eventFilter?: EventFilter;
223
+ }
224
+ interface DebounceFilterOptions {
225
+ /**
226
+ * The maximum time allowed to be delayed before it's invoked.
227
+ * In milliseconds.
228
+ */
229
+ maxWait?: number;
230
+ }
231
+ /**
232
+ * @internal
233
+ */
234
+ declare function createFilterWrapper<T extends FunctionArgs>(filter: EventFilter, fn: T): T;
235
+ declare const bypassFilter: EventFilter;
236
+ /**
237
+ * Create an EventFilter that debounce the events
238
+ *
239
+ * @param ms
240
+ * @param [maxWait=null]
241
+ */
242
+ declare function debounceFilter(ms: MaybeRef<number>, options?: DebounceFilterOptions): EventFilter<any[], any>;
243
+ /**
244
+ * Create an EventFilter that throttle the events
245
+ *
246
+ * @param ms
247
+ * @param [trailing=true]
248
+ * @param [leading=true]
249
+ */
250
+ declare function throttleFilter(ms: MaybeRef<number>, trailing?: boolean, leading?: boolean): EventFilter<any[], any>;
251
+ /**
252
+ * EventFilter that gives extra controls to pause and resume the filter
253
+ *
254
+ * @param extendFilter Extra filter to apply when the PausableFilter is active, default to none
255
+ *
256
+ */
257
+ declare function pausableFilter(extendFilter?: EventFilter): Pausable & {
258
+ eventFilter: EventFilter;
259
+ };
260
+
261
+ declare function __onlyVue3(name?: string): void;
262
+ declare const directiveHooks: {
263
+ mounted: "mounted";
264
+ updated: "updated";
265
+ unmounted: "unmounted";
266
+ };
267
+
268
+ declare function promiseTimeout(ms: number, throwOnTimeout?: boolean, reason?: string): Promise<void>;
269
+ declare function identity<T>(arg: T): T;
270
+ interface SingletonPromiseReturn<T> {
271
+ (): Promise<T>;
272
+ /**
273
+ * Reset current staled promise.
274
+ * await it to have proper shutdown.
275
+ */
276
+ reset: () => Promise<void>;
277
+ }
278
+ /**
279
+ * Create singleton promise function
280
+ *
281
+ * @example
282
+ * ```
283
+ * const promise = createSingletonPromise(async () => { ... })
284
+ *
285
+ * await promise()
286
+ * await promise() // all of them will be bind to a single promise instance
287
+ * await promise() // and be resolved together
288
+ * ```
289
+ */
290
+ declare function createSingletonPromise<T>(fn: () => Promise<T>): SingletonPromiseReturn<T>;
291
+ declare function invoke<T>(fn: () => T): T;
292
+ declare function containsProp(obj: object, ...props: string[]): boolean;
293
+ /**
294
+ * Increase string a value with unit
295
+ *
296
+ * @example '2px' + 1 = '3px'
297
+ * @example '15em' + (-2) = '13em'
298
+ */
299
+ declare function increaseWithUnit(target: number, delta: number): number;
300
+ declare function increaseWithUnit(target: string, delta: number): string;
301
+ declare function increaseWithUnit(target: string | number, delta: number): string | number;
302
+ /**
303
+ * Create a new subset object by giving keys
304
+ *
305
+ * @category Object
306
+ */
307
+ declare function objectPick<O, T extends keyof O>(obj: O, keys: T[], omitUndefined?: boolean): Pick<O, T>;
308
+
309
+ /**
310
+ * Shorthand for accessing `ref.value`
311
+ */
312
+ declare function get<T>(ref: MaybeRef<T>): T;
313
+ declare function get<T, K extends keyof T>(ref: MaybeRef<T>, key: K): T[K];
314
+
315
+ declare function isDefined<T>(v: Ref<T>): v is Ref<Exclude<T, null | undefined>>;
316
+ declare function isDefined<T>(v: ComputedRef<T>): v is ComputedRef<Exclude<T, null | undefined>>;
317
+ declare function isDefined<T>(v: T): v is Exclude<T, null | undefined>;
318
+
319
+ /**
320
+ * `AND` conditions for refs.
321
+ *
322
+ * @see https://vueuse.org/logicAnd
323
+ */
324
+ declare function logicAnd(...args: MaybeRef<any>[]): ComputedRef<boolean>;
325
+
326
+ /**
327
+ * `NOT` conditions for refs.
328
+ *
329
+ * @see https://vueuse.org/logicNot
330
+ */
331
+ declare function logicNot(v: MaybeRef<any>): ComputedRef<boolean>;
332
+
333
+ /**
334
+ * `OR` conditions for refs.
335
+ *
336
+ * @see https://vueuse.org/logicOr
337
+ */
338
+ declare function logicOr(...args: MaybeRef<any>[]): ComputedRef<boolean>;
339
+
340
+ declare function makeDestructurable<T extends Record<string, unknown>, A extends readonly any[]>(obj: T, arr: A): T & A;
341
+
342
+ declare type Reactify<T> = T extends (...args: infer A) => infer R ? (...args: {
343
+ [K in keyof A]: MaybeRef<A[K]>;
344
+ }) => ComputedRef<R> : never;
345
+ /**
346
+ * Converts plain function into a reactive function.
347
+ * The converted function accepts refs as it's arguments
348
+ * and returns a ComputedRef, with proper typing.
349
+ *
350
+ * @param fn - Source function
351
+ */
352
+ declare function reactify<T extends Function>(fn: T): Reactify<T>;
353
+
354
+ declare type ReactifyNested<T, Keys extends keyof T = keyof T> = {
355
+ [K in Keys]: T[K] extends (...args: any[]) => any ? Reactify<T[K]> : T[K];
356
+ };
357
+ interface ReactifyObjectOptions {
358
+ /**
359
+ * Includes names from Object.getOwnPropertyNames
360
+ *
361
+ * @default true
362
+ */
363
+ includeOwnProperties?: boolean;
364
+ }
365
+ /**
366
+ * Apply `reactify` to an object
367
+ */
368
+ declare function reactifyObject<T extends object, Keys extends keyof T>(obj: T, keys?: (keyof T)[]): ReactifyNested<T, Keys>;
369
+ declare function reactifyObject<T extends object>(obj: T, options?: ReactifyObjectOptions): ReactifyNested<T>;
370
+
371
+ /**
372
+ * Computed reactive object.
373
+ */
374
+ declare function reactiveComputed<T extends {}>(fn: () => T): T;
375
+
376
+ /**
377
+ * Reactively omit fields from a reactive object
378
+ *
379
+ * @see https://vueuse.js.org/reactiveOmit
380
+ */
381
+ declare function reactiveOmit<T extends object, K extends keyof T>(obj: T, ...keys: (K | K[])[]): Omit<T, K>;
382
+
383
+ /**
384
+ * Reactively pick fields from a reactive object
385
+ *
386
+ * @see https://vueuse.js.org/reactivePick
387
+ */
388
+ declare function reactivePick<T extends object, K extends keyof T>(obj: T, ...keys: (K | K[])[]): {
389
+ [S in K]: UnwrapRef<T[S]>;
390
+ };
391
+
392
+ /**
393
+ * Create a ref which will be reset to the default value after some time.
394
+ *
395
+ * @see https://vueuse.org/refAutoReset
396
+ * @param defaultValue The value which will be set.
397
+ * @param afterMs A zero-or-greater delay in milliseconds.
398
+ */
399
+ declare function refAutoReset<T>(defaultValue: T, afterMs?: MaybeRef$1<number>): Ref<T>;
400
+
401
+ /**
402
+ * Debounce updates of a ref.
403
+ *
404
+ * @return A new debounced ref.
405
+ */
406
+ declare function refDebounced<T>(value: Ref<T>, ms?: number, options?: DebounceFilterOptions): Readonly<Ref<T>>;
407
+
408
+ /**
409
+ * Apply default value to a ref.
410
+ *
411
+ * @param source source ref
412
+ * @param targets
413
+ */
414
+ declare function refDefault<T>(source: Ref<T | undefined | null>, defaultValue: T): Ref<T>;
415
+
416
+ /**
417
+ * Throttle execution of a function. Especially useful for rate limiting
418
+ * execution of handlers on events like resize and scroll.
419
+ *
420
+ * @param value Ref value to be watched with throttle effect
421
+ * @param delay A zero-or-greater delay in milliseconds. For event callbacks, values around 100 or 250 (or even higher) are most useful.
422
+ * @param [trailing=true] if true, update the value again after the delay time is up
423
+ * @param [leading=true] if true, update the value on the leading edge of the ms timeout
424
+ */
425
+ declare function refThrottled<T>(value: Ref<T>, delay?: number, trailing?: boolean, leading?: boolean): Ref<T>;
426
+
427
+ interface ControlledRefOptions<T> {
428
+ /**
429
+ * Callback function before the ref changing.
430
+ *
431
+ * Returning `false` to dismiss the change.
432
+ */
433
+ onBeforeChange?: (value: T, oldValue: T) => void | boolean;
434
+ /**
435
+ * Callback function after the ref changed
436
+ *
437
+ * This happends synchronously, with less overhead compare to `watch`
438
+ */
439
+ onChanged?: (value: T, oldValue: T) => void;
440
+ }
441
+ /**
442
+ * Explicitly define the deps of computed.
443
+ *
444
+ * @param source
445
+ * @param fn
446
+ */
447
+ declare function refWithControl<T>(initial: T, options?: ControlledRefOptions<T>): vue_demi.ShallowUnwrapRef<{
448
+ get: (tracking?: boolean) => T;
449
+ set: (value: T, triggering?: boolean) => void;
450
+ untrackedGet: () => T;
451
+ silentSet: (v: T) => void;
452
+ peek: () => T;
453
+ lay: (v: T) => void;
454
+ }> & vue_demi.Ref<T>;
455
+ /**
456
+ * Alias for `refWithControl`
457
+ */
458
+ declare const controlledRef: typeof refWithControl;
459
+
460
+ /**
461
+ * Normalize value/ref/getter to `ref` or `computed`.
462
+ */
463
+ declare function resolveRef<T>(r: MaybeComputedRef<T>): ComputedRef<T>;
464
+ declare function resolveRef<T>(r: MaybeRef<T>): Ref<T>;
465
+
466
+ /**
467
+ * Normalize value/ref/getter to `ref` or `computed`.
468
+ */
469
+ declare function resolveUnref<T>(r: MaybeComputedRef<T>): T;
470
+
471
+ declare function set<T>(ref: Ref<T>, value: T): void;
472
+ declare function set<O extends object, K extends keyof O>(target: O, key: K, value: O[K]): void;
473
+
474
+ interface SyncRefOptions extends ConfigurableFlushSync {
475
+ /**
476
+ * Watch deeply
477
+ *
478
+ * @default false
479
+ */
480
+ deep?: boolean;
481
+ /**
482
+ * Sync values immediately
483
+ *
484
+ * @default true
485
+ */
486
+ immediate?: boolean;
487
+ /**
488
+ * Direction of syncing
489
+ *
490
+ * @default 'both'
491
+ */
492
+ direction?: 'ltr' | 'rtl' | 'both';
493
+ }
494
+ /**
495
+ * Two-way refs synchronization.
496
+ *
497
+ * @param left
498
+ * @param right
499
+ */
500
+ declare function syncRef<R extends Ref<any>>(left: R, right: R, options?: SyncRefOptions): () => void;
501
+
502
+ interface SyncRefsOptions extends ConfigurableFlushSync {
503
+ /**
504
+ * Watch deeply
505
+ *
506
+ * @default false
507
+ */
508
+ deep?: boolean;
509
+ /**
510
+ * Sync values immediately
511
+ *
512
+ * @default true
513
+ */
514
+ immediate?: boolean;
515
+ }
516
+ /**
517
+ * Keep target ref(s) in sync with the source ref
518
+ *
519
+ * @param source source ref
520
+ * @param targets
521
+ */
522
+ declare function syncRefs<T>(source: WatchSource<T>, targets: Ref<T> | Ref<T>[], options?: SyncRefsOptions): vue_demi.WatchStopHandle;
523
+
524
+ /**
525
+ * Converts ref to reactive.
526
+ *
527
+ * @see https://vueuse.org/toReactive
528
+ * @param objectRef A ref of object
529
+ */
530
+ declare function toReactive<T extends object>(objectRef: MaybeRef<T>): T;
531
+
532
+ /**
533
+ * Extended `toRefs` that also accepts refs of an object.
534
+ *
535
+ * @see https://vueuse.org/toRefs
536
+ * @param objectRef A ref or normal object or array.
537
+ */
538
+ declare function toRefs<T extends object>(objectRef: MaybeRef<T>): ToRefs<T>;
539
+
540
+ /**
541
+ * Call onBeforeMount() if it's inside a component lifecycle, if not, just call the function
542
+ *
543
+ * @param fn
544
+ * @param sync if set to false, it will run in the nextTick() of Vue
545
+ */
546
+ declare function tryOnBeforeMount(fn: Fn, sync?: boolean): void;
547
+
548
+ /**
549
+ * Call onBeforeUnmount() if it's inside a component lifecycle, if not, do nothing
550
+ *
551
+ * @param fn
552
+ */
553
+ declare function tryOnBeforeUnmount(fn: Fn): void;
554
+
555
+ /**
556
+ * Call onMounted() if it's inside a component lifecycle, if not, just call the function
557
+ *
558
+ * @param fn
559
+ * @param sync if set to false, it will run in the nextTick() of Vue
560
+ */
561
+ declare function tryOnMounted(fn: Fn, sync?: boolean): void;
562
+
563
+ /**
564
+ * Call onScopeDispose() if it's inside a effect scope lifecycle, if not, do nothing
565
+ *
566
+ * @param fn
567
+ */
568
+ declare function tryOnScopeDispose(fn: Fn): boolean;
569
+
570
+ /**
571
+ * Call onUnmounted() if it's inside a component lifecycle, if not, do nothing
572
+ *
573
+ * @param fn
574
+ */
575
+ declare function tryOnUnmounted(fn: Fn): void;
576
+
577
+ interface UntilToMatchOptions {
578
+ /**
579
+ * Milliseconds timeout for promise to resolve/reject if the when condition does not meet.
580
+ * 0 for never timed out
581
+ *
582
+ * @default 0
583
+ */
584
+ timeout?: number;
585
+ /**
586
+ * Reject the promise when timeout
587
+ *
588
+ * @default false
589
+ */
590
+ throwOnTimeout?: boolean;
591
+ /**
592
+ * `flush` option for internal watch
593
+ *
594
+ * @default 'sync'
595
+ */
596
+ flush?: WatchOptions['flush'];
597
+ /**
598
+ * `deep` option for internal watch
599
+ *
600
+ * @default 'false'
601
+ */
602
+ deep?: WatchOptions['deep'];
603
+ }
604
+ interface UntilBaseInstance<T, Not extends boolean = false> {
605
+ toMatch<U extends T = T>(condition: (v: T) => v is U, options?: UntilToMatchOptions): Not extends true ? Promise<Exclude<T, U>> : Promise<U>;
606
+ toMatch(condition: (v: T) => boolean, options?: UntilToMatchOptions): Promise<T>;
607
+ changed(options?: UntilToMatchOptions): Promise<T>;
608
+ changedTimes(n?: number, options?: UntilToMatchOptions): Promise<T>;
609
+ }
610
+ declare type Falsy = false | void | null | undefined | 0 | 0n | '';
611
+ interface UntilValueInstance<T, Not extends boolean = false> extends UntilBaseInstance<T, Not> {
612
+ readonly not: UntilValueInstance<T, Not extends true ? false : true>;
613
+ toBe<P = T>(value: MaybeRef<P>, options?: UntilToMatchOptions): Not extends true ? Promise<T> : Promise<P>;
614
+ toBeTruthy(options?: UntilToMatchOptions): Not extends true ? Promise<T & Falsy> : Promise<Exclude<T, Falsy>>;
615
+ toBeNull(options?: UntilToMatchOptions): Not extends true ? Promise<Exclude<T, null>> : Promise<null>;
616
+ toBeUndefined(options?: UntilToMatchOptions): Not extends true ? Promise<Exclude<T, undefined>> : Promise<undefined>;
617
+ toBeNaN(options?: UntilToMatchOptions): Promise<T>;
618
+ }
619
+ interface UntilArrayInstance<T> extends UntilBaseInstance<T> {
620
+ readonly not: UntilArrayInstance<T>;
621
+ toContains(value: MaybeRef<ElementOf<ShallowUnwrapRef<T>>>, options?: UntilToMatchOptions): Promise<T>;
622
+ }
623
+ /**
624
+ * Promised one-time watch for changes
625
+ *
626
+ * @see https://vueuse.org/until
627
+ * @example
628
+ * ```
629
+ * const { count } = useCounter()
630
+ *
631
+ * await until(count).toMatch(v => v > 7)
632
+ *
633
+ * alert('Counter is now larger than 7!')
634
+ * ```
635
+ */
636
+ declare function until<T extends unknown[]>(r: WatchSource<T> | MaybeRef<T>): UntilArrayInstance<T>;
637
+ declare function until<T>(r: WatchSource<T> | MaybeRef<T>): UntilValueInstance<T>;
638
+
639
+ interface UseCounterOptions {
640
+ min?: number;
641
+ max?: number;
642
+ }
643
+ /**
644
+ * Basic counter with utility functions.
645
+ *
646
+ * @see https://vueuse.org/useCounter
647
+ * @param [initialValue=0]
648
+ * @param {Object} options
649
+ */
650
+ declare function useCounter(initialValue?: number, options?: UseCounterOptions): {
651
+ count: vue_demi.Ref<number>;
652
+ inc: (delta?: number) => number;
653
+ dec: (delta?: number) => number;
654
+ get: () => number;
655
+ set: (val: number) => number;
656
+ reset: (val?: number) => number;
657
+ };
658
+
659
+ declare type DateLike = Date | number | string | undefined;
660
+ declare const formatDate: (date: Date, formatStr: string) => string;
661
+ declare const normalizeDate: (date: DateLike) => Date;
662
+ /**
663
+ * Get the formatted date according to the string of tokens passed in.
664
+ *
665
+ * @see https://vueuse.org/useDateFormat
666
+ * @param date
667
+ * @param formatStr
668
+ */
669
+ declare function useDateFormat(date: MaybeRef$1<DateLike>, formatStr?: MaybeRef$1<string>): vue_demi.ComputedRef<string>;
670
+ declare type UseDateFormatReturn = ReturnType<typeof useDateFormat>;
671
+
672
+ /**
673
+ * Debounce execution of a function.
674
+ *
675
+ * @param fn A function to be executed after delay milliseconds debounced.
676
+ * @param ms A zero-or-greater delay in milliseconds. For event callbacks, values around 100 or 250 (or even higher) are most useful.
677
+ * @param opts options
678
+ *
679
+ * @return A new, debounce, function.
680
+ */
681
+ declare function useDebounceFn<T extends FunctionArgs>(fn: T, ms?: MaybeRef<number>, options?: DebounceFilterOptions): T;
682
+
683
+ interface IntervalOptions<Controls extends boolean> {
684
+ /**
685
+ * Expose more controls
686
+ *
687
+ * @default false
688
+ */
689
+ controls?: Controls;
690
+ /**
691
+ * Exccute the update immediately on calling
692
+ *
693
+ * @default true
694
+ */
695
+ immediate?: boolean;
696
+ }
697
+ declare function useInterval(interval?: MaybeRef<number>, options?: IntervalOptions<false>): Ref<number>;
698
+ declare function useInterval(interval: MaybeRef<number>, options: IntervalOptions<true>): {
699
+ counter: Ref<number>;
700
+ } & Pausable;
701
+
702
+ interface IntervalFnOptions {
703
+ /**
704
+ * Start the timer immediately
705
+ *
706
+ * @default true
707
+ */
708
+ immediate?: boolean;
709
+ /**
710
+ * Execute the callback immediate after calling this function
711
+ *
712
+ * @default false
713
+ */
714
+ immediateCallback?: boolean;
715
+ }
716
+ /**
717
+ * Wrapper for `setInterval` with controls
718
+ *
719
+ * @param cb
720
+ * @param interval
721
+ * @param options
722
+ */
723
+ declare function useIntervalFn(cb: Fn, interval?: MaybeRef<number>, options?: IntervalFnOptions): Pausable;
724
+
725
+ interface UseLastChangedOptions<Immediate extends boolean, InitialValue extends number | null | undefined = undefined> extends WatchOptions<Immediate> {
726
+ initialValue?: InitialValue;
727
+ }
728
+ /**
729
+ * Records the timestamp of the last change
730
+ *
731
+ * @see https://vueuse.org/useLastChanged
732
+ */
733
+ declare function useLastChanged(source: WatchSource, options?: UseLastChangedOptions<false>): Ref<number | null>;
734
+ declare function useLastChanged(source: WatchSource, options: UseLastChangedOptions<true>): Ref<number>;
735
+ declare function useLastChanged(source: WatchSource, options: UseLastChangedOptions<boolean, number>): Ref<number>;
736
+
737
+ /**
738
+ * Throttle execution of a function. Especially useful for rate limiting
739
+ * execution of handlers on events like resize and scroll.
740
+ *
741
+ * @param fn A function to be executed after delay milliseconds. The `this` context and all arguments are passed through, as-is,
742
+ * to `callback` when the throttled-function is executed.
743
+ * @param ms A zero-or-greater delay in milliseconds. For event callbacks, values around 100 or 250 (or even higher) are most useful.
744
+ *
745
+ * @param [trailing=true] if true, call fn again after the time is up
746
+ *
747
+ * @param [leading=true] if true, call fn on the leading edge of the ms timeout
748
+ *
749
+ * @return A new, throttled, function.
750
+ */
751
+ declare function useThrottleFn<T extends FunctionArgs>(fn: T, ms?: MaybeRef<number>, trailing?: boolean, leading?: boolean): T;
752
+
753
+ interface TimeoutFnOptions {
754
+ /**
755
+ * Start the timer immediate after calling this function
756
+ *
757
+ * @default true
758
+ */
759
+ immediate?: boolean;
760
+ }
761
+ /**
762
+ * Wrapper for `setTimeout` with controls.
763
+ *
764
+ * @param cb
765
+ * @param interval
766
+ * @param immediate
767
+ */
768
+ declare function useTimeoutFn(cb: (...args: unknown[]) => any, interval: MaybeRef<number>, options?: TimeoutFnOptions): Stoppable;
769
+
770
+ interface TimeoutOptions<Controls extends boolean> extends TimeoutFnOptions {
771
+ /**
772
+ * Expose more controls
773
+ *
774
+ * @default false
775
+ */
776
+ controls?: Controls;
777
+ }
778
+ /**
779
+ * Update value after a given time with controls.
780
+ *
781
+ * @see {@link https://vueuse.org/useTimeout}
782
+ * @param interval
783
+ * @param immediate
784
+ */
785
+ declare function useTimeout(interval?: number, options?: TimeoutOptions<false>): ComputedRef<boolean>;
786
+ declare function useTimeout(interval: number, options: TimeoutOptions<true>): {
787
+ ready: ComputedRef<boolean>;
788
+ } & Stoppable;
789
+
790
+ interface UseToggleOptions<Truthy, Falsy> {
791
+ truthyValue?: MaybeRef<Truthy>;
792
+ falsyValue?: MaybeRef<Falsy>;
793
+ }
794
+ declare function useToggle<Truthy, Falsy, T = Truthy | Falsy>(initialValue: Ref<T>, options?: UseToggleOptions<Truthy, Falsy>): (value?: T) => T;
795
+ declare function useToggle<Truthy = true, Falsy = false, T = Truthy | Falsy>(initialValue?: T, options?: UseToggleOptions<Truthy, Falsy>): [Ref<T>, (value?: T) => T];
796
+
797
+ declare type WatchArrayCallback<V = any, OV = any> = (value: V, oldValue: OV, added: V, removed: OV, onCleanup: (cleanupFn: () => void) => void) => any;
798
+ /**
799
+ * Watch for an array with additions and removals.
800
+ *
801
+ * @see https://vueuse.org/watchArray
802
+ */
803
+ declare function watchArray<T, Immediate extends Readonly<boolean> = false>(source: WatchSource<T[]> | T[], cb: WatchArrayCallback<T[], Immediate extends true ? T[] | undefined : T[]>, options?: WatchOptions<Immediate>): vue_demi.WatchStopHandle;
804
+
805
+ interface WatchWithFilterOptions<Immediate> extends WatchOptions<Immediate>, ConfigurableEventFilter {
806
+ }
807
+ declare function watchWithFilter<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options?: WatchWithFilterOptions<Immediate>): WatchStopHandle;
808
+ declare function watchWithFilter<T, Immediate extends Readonly<boolean> = false>(source: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchWithFilterOptions<Immediate>): WatchStopHandle;
809
+ declare function watchWithFilter<T extends object, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchWithFilterOptions<Immediate>): WatchStopHandle;
810
+
811
+ interface WatchAtMostOptions<Immediate> extends WatchWithFilterOptions<Immediate> {
812
+ count: MaybeRef<number>;
813
+ }
814
+ interface WatchAtMostReturn {
815
+ stop: WatchStopHandle;
816
+ count: Ref<number>;
817
+ }
818
+ declare function watchAtMost<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options: WatchAtMostOptions<Immediate>): WatchAtMostReturn;
819
+ declare function watchAtMost<T, Immediate extends Readonly<boolean> = false>(sources: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options: WatchAtMostOptions<Immediate>): WatchAtMostReturn;
820
+
821
+ interface WatchDebouncedOptions<Immediate> extends WatchOptions<Immediate>, DebounceFilterOptions {
822
+ debounce?: MaybeRef<number>;
823
+ }
824
+ declare function watchDebounced<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options?: WatchDebouncedOptions<Immediate>): WatchStopHandle;
825
+ declare function watchDebounced<T, Immediate extends Readonly<boolean> = false>(source: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchDebouncedOptions<Immediate>): WatchStopHandle;
826
+ declare function watchDebounced<T extends object, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchDebouncedOptions<Immediate>): WatchStopHandle;
827
+
828
+ declare type IgnoredUpdater = (updater: () => void) => void;
829
+ interface WatchIgnorableReturn {
830
+ ignoreUpdates: IgnoredUpdater;
831
+ ignorePrevAsyncUpdates: () => void;
832
+ stop: WatchStopHandle;
833
+ }
834
+ declare function watchIgnorable<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options?: WatchWithFilterOptions<Immediate>): WatchIgnorableReturn;
835
+ declare function watchIgnorable<T, Immediate extends Readonly<boolean> = false>(source: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchWithFilterOptions<Immediate>): WatchIgnorableReturn;
836
+ declare function watchIgnorable<T extends object, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchWithFilterOptions<Immediate>): WatchIgnorableReturn;
837
+
838
+ declare function watchOnce<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(source: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options?: WatchOptions<Immediate>): void;
839
+ declare function watchOnce<T, Immediate extends Readonly<boolean> = false>(sources: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchOptions<Immediate>): void;
840
+
841
+ interface WatchPausableReturn extends Pausable {
842
+ stop: WatchStopHandle;
843
+ }
844
+ declare function watchPausable<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options?: WatchWithFilterOptions<Immediate>): WatchPausableReturn;
845
+ declare function watchPausable<T, Immediate extends Readonly<boolean> = false>(source: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchWithFilterOptions<Immediate>): WatchPausableReturn;
846
+ declare function watchPausable<T extends object, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchWithFilterOptions<Immediate>): WatchPausableReturn;
847
+
848
+ interface WatchThrottledOptions<Immediate> extends WatchOptions<Immediate> {
849
+ throttle?: MaybeRef<number>;
850
+ trailing?: boolean;
851
+ leading?: boolean;
852
+ }
853
+ declare function watchThrottled<T extends Readonly<WatchSource<unknown>[]>, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T>, MapOldSources<T, Immediate>>, options?: WatchThrottledOptions<Immediate>): WatchStopHandle;
854
+ declare function watchThrottled<T, Immediate extends Readonly<boolean> = false>(source: WatchSource<T>, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchThrottledOptions<Immediate>): WatchStopHandle;
855
+ declare function watchThrottled<T extends object, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<T, Immediate extends true ? T | undefined : T>, options?: WatchThrottledOptions<Immediate>): WatchStopHandle;
856
+
857
+ interface WatchTriggerableReturn<FnReturnT = void> extends WatchIgnorableReturn {
858
+ /** Execute `WatchCallback` immediately */
859
+ trigger: () => FnReturnT;
860
+ }
861
+ declare type OnCleanup = (cleanupFn: () => void) => void;
862
+ declare type WatchTriggerableCallback<V = any, OV = any, R = void> = (value: V, oldValue: OV, onCleanup: OnCleanup) => R;
863
+ declare function watchTriggerable<T extends Readonly<WatchSource<unknown>[]>, FnReturnT>(sources: [...T], cb: WatchTriggerableCallback<MapSources<T>, MapOldSources<T, true>, FnReturnT>, options?: WatchWithFilterOptions<boolean>): WatchTriggerableReturn<FnReturnT>;
864
+ declare function watchTriggerable<T, FnReturnT>(source: WatchSource<T>, cb: WatchTriggerableCallback<T, T | undefined, FnReturnT>, options?: WatchWithFilterOptions<boolean>): WatchTriggerableReturn<FnReturnT>;
865
+ declare function watchTriggerable<T extends object, FnReturnT>(source: T, cb: WatchTriggerableCallback<T, T | undefined, FnReturnT>, options?: WatchWithFilterOptions<boolean>): WatchTriggerableReturn<FnReturnT>;
866
+
867
+ /**
868
+ * Shorthand for watching value to be truthy
869
+ *
870
+ * @see https://vueuse.js.org/whenever
871
+ */
872
+ declare function whenever<T>(source: WatchSource<T | false | null | undefined>, cb: WatchCallback<T>, options?: WatchOptions): vue_demi.WatchStopHandle;
873
+
874
+ export { Awaitable, ComputedRefWithControl, ComputedWithControlRefExtra, ConfigurableEventFilter, ConfigurableFlush, ConfigurableFlushSync, ControlledRefOptions, CreateGlobalStateReturn, DateLike, DebounceFilterOptions, DeepMaybeRef, ElementOf, EventFilter, EventHook, EventHookOff, EventHookOn, EventHookTrigger, ExtendRefOptions, Fn, FunctionArgs, FunctionWrapperOptions, IgnoredUpdater, IntervalFnOptions, IntervalOptions, MapOldSources, MapSources, MaybeComputedRef, MaybeRef, Pausable, Reactify, ReactifyNested, ReactifyObjectOptions, RemovableRef, RemoveableRef, ShallowUnwrapRef, SingletonPromiseReturn, Stopable, Stoppable, SyncRefOptions, SyncRefsOptions, TimeoutFnOptions, TimeoutOptions, UntilArrayInstance, UntilBaseInstance, UntilToMatchOptions, UntilValueInstance, UseCounterOptions, UseDateFormatReturn, UseLastChangedOptions, UseToggleOptions, WatchArrayCallback, WatchAtMostOptions, WatchAtMostReturn, WatchDebouncedOptions, WatchIgnorableReturn, WatchPausableReturn, WatchThrottledOptions, WatchTriggerableCallback, WatchTriggerableReturn, WatchWithFilterOptions, WritableComputedRefWithControl, __onlyVue3, logicAnd as and, assert, refAutoReset as autoResetRef, bypassFilter, clamp, computedEager, computedWithControl, containsProp, computedWithControl as controlledComputed, controlledRef, createEventHook, createFilterWrapper, createGlobalState, createInjectionState, reactify as createReactiveFn, createSharedComposable, createSingletonPromise, debounceFilter, refDebounced as debouncedRef, watchDebounced as debouncedWatch, directiveHooks, computedEager as eagerComputed, extendRef, formatDate, get, identity, watchIgnorable as ignorableWatch, increaseWithUnit, invoke, isBoolean, isClient, isDef, isDefined, isFunction, isIOS, isNumber, isObject, isString, isWindow, logicAnd, logicNot, logicOr, makeDestructurable, noop, normalizeDate, logicNot as not, now, objectPick, logicOr as or, pausableFilter, watchPausable as pausableWatch, promiseTimeout, rand, reactify, reactifyObject, reactiveComputed, reactiveOmit, reactivePick, refAutoReset, refDebounced, refDefault, refThrottled, refWithControl, resolveRef, resolveUnref, set, syncRef, syncRefs, throttleFilter, refThrottled as throttledRef, watchThrottled as throttledWatch, timestamp, toReactive, toRefs, tryOnBeforeMount, tryOnBeforeUnmount, tryOnMounted, tryOnScopeDispose, tryOnUnmounted, until, useCounter, useDateFormat, refDebounced as useDebounce, useDebounceFn, useInterval, useIntervalFn, useLastChanged, refThrottled as useThrottle, useThrottleFn, useTimeout, useTimeoutFn, useToggle, watchArray, watchAtMost, watchDebounced, watchIgnorable, watchOnce, watchPausable, watchThrottled, watchTriggerable, watchWithFilter, whenever };