npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@affino/datagrid-orchestration

v0.2.0

Published

Framework-agnostic orchestration primitives for Affino DataGrid adapters

Readme

@affino/datagrid-orchestration

Framework-agnostic orchestration primitives shared by DataGrid adapters.

This package contains pure TypeScript logic (state commands, interaction policies, transformation helpers) that should be reused by Vue/Laravel/React adapters.

Layer role

  • @affino/datagrid-core: data/row/column runtime and deterministic model contracts.
  • @affino/datagrid-orchestration: adapter-agnostic interaction policies and UI orchestration primitives.
  • @affino/datagrid-vue: Vue bindings, refs, templates and framework lifecycle wiring.

New orchestration primitives

  • useDataGridLinkedPaneScrollSync: high-velocity linked-pane sync with a single scroll source-of-truth.
    • modes: direct-transform and css-var.
  • useDataGridResizeClickGuard: resize interaction guard that blocks accidental header-sort click after resize.
  • useDataGridInitialViewportRecovery: post-mount/resize recovery loop for virtual viewport stabilization.
  • useDataGridRowSelectionModel: anchor + shift-range row selection model with reconcile helpers for filtering/virtualization flows.
  • useDataGridScrollIdleGate: lightweight scroll-activity gate for deferring non-critical sync work until scroll idle.
  • useDataGridScrollPerfTelemetry: runtime frame telemetry for active scroll sessions (fps, dropped frames, long-task frames) with a minimal quality classification (good/degraded).

Scroll ownership contract

useDataGridManagedWheelScroll supports explicit ownership release for nested containers:

  • resolveWheelPropagationMode() supports policy modes:
    • retain
    • release-at-boundary-when-unconsumed
    • release-when-unconsumed
  • resolveShouldPropagateWheelEvent(result) remains available as a callback override for custom contracts.
  • Propagation decisions are ownership-based (handled) to preserve managed-wheel stability under pending/clamped deltas.
  • Optional hard-stop behavior: resolveStopImmediatePropagation() enables stopImmediatePropagation() for handled events when required by nested listener topology.
  • resolvePreventDefaultWhenHandled() keeps managed behavior deterministic for handled wheel input.

This enables controlled wheel chaining in layouts like grid -> modal -> page without losing managed wheel behavior inside the grid.

Quick example

import {
	useDataGridLinkedPaneScrollSync,
	useDataGridResizeClickGuard,
	useDataGridInitialViewportRecovery,
	useDataGridRowSelectionModel,
} from "@affino/datagrid-orchestration"

const linkedSync = useDataGridLinkedPaneScrollSync({
	resolveSourceScrollTop: () => bodyViewport.scrollTop,
	mode: "css-var",
	resolveCssVarHost: () => gridRoot,
})

const resizeGuard = useDataGridResizeClickGuard()

const viewportRecovery = useDataGridInitialViewportRecovery({
	resolveShouldRecover: () => totalRows > 1 && renderedRows <= 1,
	runRecoveryStep: () => syncViewportMetrics(),
})

const rowSelection = useDataGridRowSelectionModel({
	resolveFilteredRows: () => filteredRows,
	resolveRowId: row => String(row.rowId),
	resolveAllRows: () => allRows,
})

const scrollIdleGate = useDataGridScrollIdleGate({
	resolveIdleDelayMs: () => 80,
})

scrollIdleGate.markScrollActivity()
scrollIdleGate.runWhenScrollIdle(() => {
	// defer heavy non-critical sync while user is actively scrolling
	recomputeSelectionSummary()
})