Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
@vx/group is a part of the vx (now known as visx) collection of low-level visualization components for React. It provides a way to group multiple SVG elements together, making it easier to manage and transform them as a single unit. This is particularly useful in creating complex visualizations where you need to apply transformations or styles to a collection of elements.
Grouping SVG Elements
This feature allows you to group multiple SVG elements together and apply transformations such as translation. In this example, a circle and a rectangle are grouped together and translated 100 units down and 50 units to the right.
const Group = require('@vx/group').Group;
<Group top={100} left={50}>
<circle cx={0} cy={0} r={20} fill="blue" />
<rect x={-10} y={-10} width={20} height={20} fill="red" />
</Group>
Applying Transformations
This feature allows you to apply transformations like rotation to a group of SVG elements. In this example, a circle and a rectangle are grouped together and rotated by 45 degrees.
const Group = require('@vx/group').Group;
<Group transform="rotate(45)">
<circle cx={50} cy={50} r={20} fill="green" />
<rect x={40} y={40} width={20} height={20} fill="yellow" />
</Group>
d3-selection is a part of the D3.js library that allows you to select and manipulate DOM elements. It provides similar functionality to @vx/group in terms of grouping and transforming elements, but it is more general-purpose and not specifically designed for React.
react-konva is a React wrapper for the Konva.js library, which is used for creating 2D canvas graphics. It provides similar grouping and transformation functionalities but is designed for canvas elements rather than SVG.
react-spring is a spring-physics-based animation library for React. While it is primarily used for animations, it also provides functionalities for grouping and transforming elements, making it a versatile alternative to @vx/group.
<Group />
provides a simplified API for SVG <g />
elements, which are containers for other SVG
objects. You may pass in a top
and left
margin (instead of transform={translate(...)}
) and a
className
.
npm install --save @vx/group
v0.0.199
rangeRound
field in the input of scaleLinear()
, scaleLog()
, scalePoint()
, scalePower()
, scaleSqrt()
, scaleTime()
and scaleUtc()
. #766
Instead of
scaleLinear({ rangeRound: xxx })
Do this instead
scaleLinear({ range: xxx, round: true });
ticks
and tickFormat
in the input of scaleQuantize()
. It was not really doing anything anyway as both scale.ticks()
and scale.tickFormat()
do not mutate the scale. #766scale.type
field that was attached to the d3 scales. #766@vx/grid
components now accept D3 Scale as generic type instead of ScaleInput
. Developers should not expect to specify this generic type as it can be inferred from the passed scale. #775GridColumnProps
=> GridColumnsProps
(+s
) to match GridRowsProps
. #787<Marker />
implementation of a Line and some Text. #783AnyD3Scale
, InferD3ScaleOutput
, InferD3ScaleDiscreteInput
, InferD3ScaleThresholdInput
and ScaleInput
. Add new utilities functions: getTicks
, coerceNumber
and toString
. #773@vx/legend
shapes from the index
for convenience / non-deep imports. #772children
prop to GridRows
+ GridColumns
to support animated rendering. #787<BarRounded />
shape. #774d3-shape
and export as part of vx/shape
(arc
, area
, line
, pie
, radialLine
),
similar to vx/scale
has factories for d3-scale
. #776SplitLinePath
component to @vx/shape
that allows you to create a line path split into multiple smaller line paths that can be styled independently. #778vx/scale
and vx/axis
. More fields passed to child render props of Axis
. #773Axis
is refactored to accept a ticksComponent
which allows us to animate them. #779values
to tickFormat(value, index, values)
so that format logic can more easily leverage all ticks (because numTicks
is approximate, lib consumers do not know how many tick values exist a priori). #779<Marker />
that matches actual SVG <marker>
. #783<MarkerArrow />
, <MarkerCross />
, <MarkerX />
, <MarkerCircle />
, <MarkerLine />
. #783@vx/react-spring
that includes react-spring
as a peerDep
and can be a home for things that depend on react-spring
. #779<AnimatedAxis />
and <AnimatedTicksRender />
in @vx/react-spring
. #779vx-demo/axis
demo to use <AnimatedAxis />
. #779AnimatedGridRows
+ AnimatedGridColumns
. #787AnimatedTicks/useAnimatedTicksConfig
to spring-configs/useAnimatedLineTransitionConfig
so it can power both animated tick + grid lines. #787animationTrajectory=outside | inside | min | max
to AnimatedAxis
and AnimatedGridRows/Columns
. #787enableDebounceLeadingCall
prop being passed into div
. #763vx/scale
package has 100% test coverage. #766<Marker>
. #783/axis
demo to include AnimatedGrid*
and a animationTrajectory
config. #787 - @vx/annotation: 0.0.198 => 0.0.199
- @vx/axis: 0.0.198 => 0.0.199
- @vx/bounds: 0.0.198 => 0.0.199
- @vx/brush: 0.0.198 => 0.0.199
- @vx/chord: 0.0.198 => 0.0.199
- @vx/clip-path: 0.0.198 => 0.0.199
- @vx/curve: 0.0.198 => 0.0.199
- @vx/demo: 0.0.198 => 0.0.199
- @vx/drag: 0.0.198 => 0.0.199
- @vx/event: 0.0.198 => 0.0.199
- @vx/geo: 0.0.198 => 0.0.199
- @vx/glyph: 0.0.198 => 0.0.199
- @vx/gradient: 0.0.198 => 0.0.199
- @vx/grid: 0.0.198 => 0.0.199
- @vx/group: 0.0.198 => 0.0.199
- @vx/heatmap: 0.0.198 => 0.0.199
- @vx/hierarchy: 0.0.198 => 0.0.199
- @vx/legend: 0.0.198 => 0.0.199
- @vx/marker: 0.0.198 => 0.0.199
- @vx/mock-data: 0.0.198 => 0.0.199
- @vx/network: 0.0.198 => 0.0.199
- @vx/pattern: 0.0.198 => 0.0.199
- @vx/point: 0.0.198 => 0.0.199
- @vx/react-spring: 0.0.198 => 0.0.199
- @vx/responsive: 0.0.198 => 0.0.199
- @vx/scale: 0.0.198 => 0.0.199
- @vx/shape: 0.0.198 => 0.0.199
- @vx/stats: 0.0.198 => 0.0.199
- @vx/text: 0.0.198 => 0.0.199
- @vx/threshold: 0.0.198 => 0.0.199
- @vx/tooltip: 0.0.198 => 0.0.199
- @vx/voronoi: 0.0.198 => 0.0.199
- @vx/vx: 0.0.198 => 0.0.199
- @vx/xychart: 0.0.0 => 0.0.199 (private)
- @vx/zoom: 0.0.198 => 0.0.199
FAQs
vx group
The npm package @vx/group receives a total of 29,909 weekly downloads. As such, @vx/group popularity was classified as popular.
We found that @vx/group demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers 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
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.