Socket
Socket
Sign inDemoInstall

scroll-into-view-if-needed

Package Overview
Dependencies
Maintainers
1
Versions
83
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

scroll-into-view-if-needed - npm Package Compare versions

Comparing version 3.0.2 to 3.0.3

4

dist/index.d.ts

@@ -5,3 +5,3 @@ import type { Options as Options_2 } from 'compute-scroll-into-view'

/** @public */
export declare interface CustomBehaviorOptions<T> extends Options_2 {
export declare interface CustomBehaviorOptions<T = unknown> extends Options_2 {
behavior: CustomScrollBehaviorCallback<T>

@@ -16,3 +16,3 @@ }

/** @public */
export declare type Options<T> =
export declare type Options<T = unknown> =
| StandardBehaviorOptions

@@ -19,0 +19,0 @@ | CustomBehaviorOptions<T>

{
"name": "scroll-into-view-if-needed",
"version": "3.0.2",
"version": "3.0.3",
"description": "Ponyfill for upcoming Element.scrollIntoView() APIs like scrollMode: if-needed, behavior: smooth and block: center",

@@ -5,0 +5,0 @@ "keywords": [

@@ -8,3 +8,5 @@ import compute from 'compute-scroll-into-view'

/** @public */
export type Options<T> = StandardBehaviorOptions | CustomBehaviorOptions<T>
export type Options<T = unknown> =
| StandardBehaviorOptions
| CustomBehaviorOptions<T>

@@ -20,3 +22,3 @@ /** @public */

/** @public */
export interface CustomBehaviorOptions<T> extends BaseOptions {
export interface CustomBehaviorOptions<T = unknown> extends BaseOptions {
behavior: CustomScrollBehaviorCallback<T>

@@ -35,3 +37,3 @@ }

let isCustomScrollBehavior = <T>(
let isCustomScrollBehavior = <T = unknown>(
options: any

@@ -70,3 +72,3 @@ ): options is CustomBehaviorOptions<T> =>

/** @public */
export default function scrollIntoView<T>(
export default function scrollIntoView<T = unknown>(
target: Element,

@@ -73,0 +75,0 @@ options?: StandardBehaviorOptions | CustomBehaviorOptions<T> | boolean

Sorry, the diff of this file is not supported yet

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