New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

regl-worldview

Package Overview
Dependencies
Maintainers
12
Versions
81
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

regl-worldview - npm Package Compare versions

Comparing version 0.13.2 to 0.13.3

2

package.json
{
"name": "regl-worldview",
"version": "0.13.2",
"version": "0.13.3",
"description": "A reusable component for rendering 2D and 3D views using regl",

@@ -5,0 +5,0 @@ "license": "Apache-2.0",

@@ -47,2 +47,10 @@ // Copyright (c) 2018-present, GM Cruise LLC

const withSingleColor = (triangle, color) => {
return {
...triangle,
colors: undefined,
color,
};
};
const Example = ({ triangles }) => (

@@ -58,2 +66,10 @@ <Container cameraState={{ perspective: true, phi: 1.83, thetaOffset: -1.1 }}>

.add("<Triangles> with instancing", () => <Example triangles={[instancedTriangles(0, 0, 0)]} />)
.add("<Triangles> with single color", () => (
<Example
triangles={[
withSingleColor(singleTriangle(0, 0, 0), { r: 1, g: 1, b: 0, a: 1 }),
withSingleColor(singleTriangle(5.0, 0.1, 0), { r: 0, g: 1, b: 1, a: 1 }),
]}
/>
))
.add("<Triangles> with custom depth and blend values", () => (

@@ -64,2 +80,10 @@ <Example triangles={withCustomRenderStates([singleTriangle(0, 0, 0)], [singleTriangle(5, 0, 0.1)])} />

<Example triangles={withCustomRenderStates([instancedTriangles(0, 0, 0)], [instancedTriangles(5, 0, 0.1)])} />
))
.add("<Triangles> with single color and custom render states", () => (
<Example
triangles={withCustomRenderStates(
[withSingleColor(singleTriangle(0, 0, 0), { r: 1, g: 1, b: 0, a: 1 })],
[withSingleColor(singleTriangle(5.0, 0.1, 0), { r: 0, g: 1, b: 1, a: 1 })]
)}
/>
));

@@ -31,5 +31,6 @@ // @flow

// will use the originalMarker property instead. If no custom render states
// are present, use the default ones to make sure the hitmap works correctly.
const depth = props.depth || props.originalMarker?.depth || defaultReglDepth;
const blend = props.blend || props.originalMarker?.blend || defaultReglBlend;
// are present, use either the ones provided in the command or the default ones. We do
// need to provide valid objects in order to make sure the hitmap works correctly.
const depth = props.depth || props.originalMarker?.depth || reglCommand.depth || defaultReglDepth;
const blend = props.blend || props.originalMarker?.blend || reglCommand.blend || defaultReglBlend;
memoizedRender({ depth, blend })(props);

@@ -36,0 +37,0 @@ };

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

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