Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
@types/react-canvas-draw
Advanced tools
Readme
npm install --save @types/react-canvas-draw
This package contains type definitions for react-canvas-draw (https://embiem.github.io/react-canvas-draw/).
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-canvas-draw.
import * as React from "react";
export interface CanvasDrawProps {
onChange?: ((canvas: CanvasDraw) => void) | null | undefined;
loadTimeOffset?: number | undefined;
lazyRadius?: number | undefined;
brushRadius?: number | undefined;
brushColor?: string | undefined;
catenaryColor?: string | undefined;
gridColor?: string | undefined;
backgroundColor?: string | undefined;
hideGrid?: boolean | undefined;
canvasWidth?: number | string | undefined;
canvasHeight?: number | string | undefined;
disabled?: boolean | undefined;
imgSrc?: string | undefined;
saveData?: string | undefined;
immediateLoading?: boolean | undefined;
hideInterface?: boolean | undefined;
gridSizeX?: number | undefined;
gridSizeY?: number | undefined;
gridLineWidth?: number | undefined;
hideGridX?: boolean | undefined;
hideGridY?: boolean | undefined;
enablePanAndZoom?: boolean | undefined;
mouseZoomFactor?: number | undefined;
zoomExtents?: { min: number; max: number } | undefined;
clampLinesToDocument?: boolean | undefined;
className?: string | undefined;
style?: React.CSSProperties | undefined;
}
export default class CanvasDraw extends React.Component<CanvasDrawProps> {
/**
* Returns the drawing's save-data as a stringified object.
*/
getSaveData(): string;
/**
* Loads a previously saved drawing using the saveData string, as well as an optional boolean
* flag to load it immediately, instead of live-drawing it.
*/
loadSaveData(saveData: string, immediate?: boolean): void;
/**
* Clears the canvas completely.
*/
clear(): void;
/**
* Removes the latest change to the drawing. This includes everything drawn since the last MouseDown event.
*/
undo(): void;
}
These definitions were written by Kamil Socha.
FAQs
TypeScript definitions for react-canvas-draw
The npm package @types/react-canvas-draw receives a total of 6,151 weekly downloads. As such, @types/react-canvas-draw popularity was classified as popular.
We found that @types/react-canvas-draw demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.