Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@oku-ui/utils

Package Overview
Dependencies
Maintainers
2
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@oku-ui/utils - npm Package Compare versions

Comparing version 0.6.0 to 0.6.1

dist/composeEventHandlers.d.ts

80

dist/index.d.ts

@@ -1,72 +0,8 @@

import { Ref } from 'vue';
declare function clamp(value: number, [min, max]: [number, number]): number;
declare function composeEventHandlers<E>(originalEventHandler?: (event: E) => void, ourEventHandler?: (event: E) => void, { checkForDefaultPrevented }?: {
checkForDefaultPrevented?: boolean | undefined;
}): (event: E) => void;
/**
* Checks whether a given VNode is a render-vialble element.
*/
declare function isValidVNodeElement(input: any): boolean;
type Measurable = {
getBoundingClientRect(): DOMRect;
};
type CallbackFn = (rect: DOMRect) => void;
/**
* Observes an element's rectangle on screen (getBoundingClientRect)
* This is useful to track elements on the screen and attach other elements
* that might be in different layers, etc.
*/
declare function observeElementRect(
/** The element whose rect to observe */
elementToObserve: Measurable,
/** The callback which will be called when the rect changes */
callback: CallbackFn): () => void;
declare const isOn: (key: any) => boolean;
/**
* Void function
*/
type Fn = () => void;
/**
* Any function
*/
type AnyFn = (...args: any[]) => any;
/**
* A ref that allow to set null or undefined
*/
type RemovableRef<T> = Omit<Ref<T>, 'value'> & {
get value(): T;
set value(value: T | null | undefined);
};
/**
* Maybe it's a ref, or a plain value
*
* ```ts
* type MaybeRef<T> = T | Ref<T>
* ```
*/
type MaybeRef<T> = T | Ref<T>;
/**
* Maybe it's a ref, or a plain value, or a getter function
*
* ```ts
* type MaybeRefOrGetter<T> = (() => T) | T | Ref<T> | ComputedRef<T>
* ```
*/
type MaybeRefOrGetter<T> = MaybeRef<T> | (() => T);
/**
* Get the value of value/ref/getter.
*/
declare function toValue<T>(r: MaybeRefOrGetter<T>): T;
/**
* @deprecated use `toValue` instead
*/
declare const resolveUnref: typeof toValue;
export { type AnyFn, type Fn, type MaybeRef, type MaybeRefOrGetter, type Measurable, type RemovableRef, clamp, composeEventHandlers, isOn, isValidVNodeElement, observeElementRect, resolveUnref, toValue };
export { clamp } from './number';
export { composeEventHandlers } from './composeEventHandlers';
export { isValidVNodeElement } from './isValidVNodeElement';
export { observeElementRect } from './observeElementRect';
export type { Measurable } from './observeElementRect';
export * from './isOn';
export * from './types';
export * from './toValue';
{
"name": "@oku-ui/utils",
"type": "module",
"version": "0.6.0",
"version": "0.6.1",
"license": "MIT",

@@ -41,4 +41,6 @@ "source": "src/index.ts",

"release": "pnpm build && pnpm bumpp --commit='version(utils): release %s' --no-tag && pnpm publish",
"release:beta": "pnpm release --tag beta",
"release:alpha": "pnpm release --tag alpha",
"clean": "rimraf ./dist && rimraf ./node_modules"
}
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc