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

@types/d3-selection

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/d3-selection - npm Package Compare versions

Comparing version 0.0.3 to 1.0.4

41

d3-selection/index.d.ts

@@ -1,2 +0,2 @@

// Type definitions for D3JS d3-selection module 1.0.0
// Type definitions for D3JS d3-selection module v1.0.2
// Project: https://github.com/d3/d3-selection/

@@ -132,5 +132,25 @@ // Definitions by: Tom Wanzek <https://github.com/tomwanzek>, Alex Ford <https://github.com/gustavderdrache>, Boris Yankov <https://github.com/borisyankov>

property(name: string): any;
/**
* Look up a local variable on the first node of this selection. Note that this is not equivalent to `local.get(selection.node())` in that it will not look up locals set on the parent node(s).
*
* @param name The `d3.local` variable to look up.
*/
property<T>(name: Local<T>): T | undefined;
property(name: string, value: ValueFn<GElement, Datum, any>): this;
property(name: string, value: null): this;
property(name: string, value: any): this;
/**
* Store a value in a `d3.local` variable. This is equivalent to `selection.each(function (d, i, g) { name.set(this, value.call(this, d, i, g)); })` but more concise.
*
* @param name A `d3.local` variable
* @param value A callback that returns the value to store
*/
property<T>(name: Local<T>, value: ValueFn<GElement, Datum, T>): this;
/**
* Store a value in a `d3.local` variable for each node in the selection. This is equivalent to `selection.each(function () { name.set(this, value); })` but more concise.
*
* @param name A `d3.local` variable
* @param value A callback that returns the value to store
*/
property<T>(name: Local<T>, value: T): this;

@@ -266,7 +286,18 @@ text(): string;

export interface Local {
get(node: Element): any;
export interface Local<T> {
/**
* Retrieves a local variable stored on the node (or one of its parents).
*/
get(node: Element): T | undefined;
/**
* Deletes the value associated with the given node. Values stored on ancestors are not affected, meaning that child nodes will still see inherited values.
*
* This function returns true if there was a value stored directly on the node, and false otherwise.
*/
remove(node: Element): boolean;
set(node: Element, value: any): Element;
/**
* Store a value for this local variable. Calling `.get()` on children of this node will also retrieve the variable's value.
*/
set(node: Element, value: T): Element;
/**
* Obtain a string with the internally assigned property name for the local

@@ -281,3 +312,3 @@ * which is used to store the value on a node

*/
export function local(): Local;
export function local<T>(): Local<T>;

@@ -284,0 +315,0 @@ // ---------------------------------------------------------------------------

7

d3-selection/package.json
{
"name": "@types/d3-selection",
"version": "0.0.3",
"description": "TypeScript definitions for D3JS d3-selection module 1.0.0",
"version": "1.0.4",
"description": "TypeScript definitions for D3JS d3-selection module v1.0.2",
"license": "MIT",

@@ -14,3 +14,4 @@ "author": "Tom Wanzek <https://github.com/tomwanzek>, Alex Ford <https://github.com/gustavderdrache>, Boris Yankov <https://github.com/borisyankov>",

"dependencies": {},
"typings": "index.d.ts"
"typings": "index.d.ts",
"typesPublisherContentHash": "7c5da8c494b1947f57ca10c3fb4631c257cdb85ed8a8212f6692d68792a41364"
}

@@ -5,3 +5,3 @@ # Installation

# Summary
This package contains type definitions for D3JS d3-selection module 1.0.0 (https://github.com/d3/d3-selection/).
This package contains type definitions for D3JS d3-selection module v1.0.2 (https://github.com/d3/d3-selection/).

@@ -12,3 +12,3 @@ # Details

Additional Details
* Last updated: Thu, 25 Aug 2016 16:56:03 GMT
* Last updated: Mon, 12 Sep 2016 19:00:00 GMT
* File structure: ProperModule

@@ -15,0 +15,0 @@ * Library Dependencies: none

@@ -6,5 +6,5 @@ {

"moduleDependencies": [],
"libraryMajorVersion": "0",
"libraryMajorVersion": "1",
"libraryMinorVersion": "0",
"libraryName": "D3JS d3-selection module 1.0.0",
"libraryName": "D3JS d3-selection module v1.0.2",
"typingsPackageName": "d3-selection",

@@ -23,3 +23,3 @@ "projectName": "https://github.com/d3/d3-selection/",

"hasPackageJson": false,
"contentHash": "3b6e874ccd990dc714bd122c5592014400fc116b8f179c3b769b908a1647ed4b"
"contentHash": "7c5da8c494b1947f57ca10c3fb4631c257cdb85ed8a8212f6692d68792a41364"
}
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