Socket
Socket
Sign inDemoInstall

@radix-ui/react-separator

Package Overview
Dependencies
Maintainers
6
Versions
161
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@radix-ui/react-separator - npm Package Compare versions

Comparing version 1.1.0-rc.3 to 1.1.0-rc.4

5

dist/index.d.ts
import * as React from 'react';
import * as Radix from '@radix-ui/react-primitive';
import { Primitive } from '@radix-ui/react-primitive';
declare const ORIENTATIONS: readonly ["horizontal", "vertical"];
declare type Orientation = typeof ORIENTATIONS[number];
declare type PrimitiveDivProps = Radix.ComponentPropsWithoutRef<typeof Primitive.div>;
type Orientation = (typeof ORIENTATIONS)[number];
type PrimitiveDivProps = React.ComponentPropsWithoutRef<typeof Primitive.div>;
interface SeparatorProps extends PrimitiveDivProps {

@@ -9,0 +8,0 @@ /**

@@ -61,19 +61,2 @@ "use strict";

Separator.displayName = NAME;
Separator.propTypes = {
orientation(props, propName, componentName) {
const propValue = props[propName];
const strVal = String(propValue);
if (propValue && !isValidOrientation(propValue)) {
return new Error(getInvalidOrientationError(strVal, componentName));
}
return null;
}
};
function getInvalidOrientationError(value, componentName) {
return `Invalid prop \`orientation\` of value \`${value}\` supplied to \`${componentName}\`, expected one of:
- horizontal
- vertical
Defaulting to \`${DEFAULT_ORIENTATION}\`.`;
}
function isValidOrientation(orientation) {

@@ -80,0 +63,0 @@ return ORIENTATIONS.includes(orientation);

8

package.json
{
"name": "@radix-ui/react-separator",
"version": "1.1.0-rc.3",
"version": "1.1.0-rc.4",
"license": "MIT",

@@ -31,3 +31,3 @@ "exports": {

"dependencies": {
"@radix-ui/react-primitive": "1.1.0-rc.3"
"@radix-ui/react-primitive": "2.0.0-rc.1"
},

@@ -37,4 +37,4 @@ "peerDependencies": {

"@types/react-dom": "*",
"react": "^16.8 || ^17.0 || ^18.0",
"react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0"
},

@@ -41,0 +41,0 @@ "peerDependenciesMeta": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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