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

corners

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

corners - npm Package Compare versions

Comparing version 0.0.14 to 0.1.0

dist/index.d.mts

4

dist/index.d.ts

@@ -99,7 +99,7 @@ import * as react from 'react';

} | null;
className: string;
className?: string;
};
type CornerOptions = {
cornerSize: number;
noClipping: boolean;
useClipPath: boolean;
above: Scraps<Layer>;

@@ -106,0 +106,0 @@ below: Scraps<Layer>;

@@ -174,3 +174,3 @@ var __create = Object.create;

var DEFAULT_LAYER = {
color: `black`,
color: `transparent`,
blur: 0,

@@ -183,3 +183,3 @@ spread: 0,

var DEFAULT_OPTIONS = {
noClipping: false,
useClipPath: true,
cornerSize: 15,

@@ -402,7 +402,6 @@ above: null,

function withCorners(WrappedComponent, options, ...corners2) {
const { cornerSize, noClipping, above, below } = options;
const clipPathfinder = noClipping ? null : createClipPathfinder(cornerSize, ...corners2);
const { cornerSize, useClipPath, above, below } = options;
const clipPathfinder = useClipPath ? createClipPathfinder(cornerSize, ...corners2) : null;
const pathfinder = above || below ? createPathfinder(cornerSize, ...corners2) : null;
const WithCorners = (props) => {
var _a;
const pathId = import_react2.useId ? (0, import_react2.useId)() : Math.random().toString();

@@ -420,4 +419,3 @@ const nodeRef = (0, import_react2.useRef)(null);

...props.style,
clipPath: clipPathfinder ? `url(#${pathId})` : void 0,
background: noClipping ? `none` : (_a = props.style) == null ? void 0 : _a.background
clipPath: clipPathfinder ? `url(#${pathId})` : void 0
}

@@ -424,0 +422,0 @@ },

{
"name": "corners",
"version": "0.0.14",
"version": "0.1.0",
"files": [

@@ -9,17 +9,4 @@ "dist"

"types": "dist/index.d.ts",
"scripts": {
"dev": "esbuild example/client.tsx --outfile=example/web/client.js --servedir=example/web --serve=6144 --bundle --minify --sourcemap",
"build:example": "esbuild example/client.tsx --outfile=example/web/client.js --bundle --minify --sourcemap",
"predeploy": "yarn build:example",
"deploy": "gh-pages -d example/web",
"build": "tsup src/index.ts --format cjs,esm --dts",
"test": "vitest",
"test:once": "vitest run",
"lint": "eslint \"{src,test}/**/*.ts{,x}\"",
"lint:fix": "yarn lint -- --fix",
"release": "yarn build && changeset publish",
"notes": "changeset"
},
"dependencies": {
"@react-hook/resize-observer": "^1.2.5"
"@react-hook/resize-observer": "1.2.6"
},

@@ -31,27 +18,17 @@ "peerDependencies": {

"devDependencies": {
"@banka/eslint-config-react": "1.4.0",
"@changesets/cli": "2.26.1",
"@emotion/react": "11.11.1",
"@emotion/styled": "11.11.0",
"@types/react": "18.2.11",
"@types/react-dom": "18.2.4",
"c8": "7.14.0",
"esbuild": "0.18.0",
"eslint": "8.42.0",
"@types/react": "18.2.14",
"@types/react-dom": "18.2.6",
"c8": "8.0.0",
"esbuild": "0.18.10",
"gh-pages": "5.0.0",
"husky": "8.0.3",
"jsdom": "22.1.0",
"lint-staged": "13.2.2",
"prettier": "2.8.8",
"react": "18.2.0",
"react-dom": "18.2.0",
"tsconfig-paths": "4.2.0",
"tsup": "6.7.0",
"typescript": "5.1.3",
"tsup": "7.1.0",
"vite-tsconfig-paths": "4.2.0",
"vitest": "0.32.0"
"vitest": "0.32.2"
},
"lint-staged": {
"*.ts{,x}": "yarn lint"
},
"eslintConfig": {

@@ -62,6 +39,12 @@ "extends": [

},
"homepage": "https://github.com/jeremybanka/corners#readme",
"bugs": {
"url": "https://github.com/jeremybanka/corners/issues"
"scripts": {
"dev": "esbuild example/client.tsx --outfile=example/web/client.js --servedir=example/web --serve=6144 --bundle --minify --sourcemap",
"build:example": "esbuild example/client.tsx --outfile=example/web/client.js --bundle --minify --sourcemap",
"build:package": "tsup src/index.ts --format cjs,esm --dts",
"build": "pnpm run build:package & pnpm run build:example",
"test": "vitest",
"test:once": "vitest run",
"lint": "eslint \"{src,test}/**/*.ts{,x}\"",
"lint:fix": "pnpm run lint -- --fix"
}
}
}

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