Socket
Socket
Sign inDemoInstall

@radix-ui/react-separator

Package Overview
Dependencies
Maintainers
5
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 0.0.9 to 0.0.10

2

dist/index.js

@@ -1,2 +0,2 @@

function e(e,r,t){Object.defineProperty(e,r,{get:t,enumerable:!0})}var r,t=require("@radix-ui/react-primitive").Primitive,n=require("react"),o=n.forwardRef,i=n.createElement,a=(r=require("@babel/runtime/helpers/extends"))&&r.__esModule?r.default:r,u={};const l="horizontal",c=["horizontal","vertical"],p=o(((e,r)=>{const{decorative:n,orientation:o=l,...u}=e,c=d(o)?o:l;return i(t,a({},n?{role:"none"}:{"aria-orientation":"vertical"===c?c:void 0,role:"separator"},{"data-orientation":c},u,{ref:r}))}));function d(e){return c.includes(e)}exports.Separator=p,p.displayName="Separator",p.propTypes={orientation:function(e,r,t){const n=e[r],o=String(n);return n&&!d(n)?new Error(function(e,r){return`Invalid prop \`orientation\` of value \`${e}\` supplied to \`${r}\`, expected one of:\n - horizontal\n - vertical\n\nDefaulting to \`${l}\`.`}(o,t)):null}};const f=p;exports.Root=f,e(u,"Root",(function(){return f})),e(u,"Separator",(function(){return p}));
var e,r,t,o=require("@radix-ui/react-primitive").Primitive,n=(e={},r=require("react"),Object.keys(r).forEach((function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(e,t,{enumerable:!0,get:function(){return r[t]}})})),e),i=(t=require("@babel/runtime/helpers/extends"))&&t.__esModule?t.default:t;const a="horizontal",l=["horizontal","vertical"],u=n.forwardRef(((e,r)=>{const{decorative:t,orientation:l=a,...u}=e,p=c(l)?l:a,d=t?{role:"none"}:{"aria-orientation":"vertical"===p?p:void 0,role:"separator"};return n.createElement(o,i({},d,{"data-orientation":p},u,{ref:r}))}));function c(e){return l.includes(e)}exports.Separator=u,u.displayName="Separator",u.propTypes={orientation(e,r,t){const o=e[r],n=String(o);return o&&!c(o)?new Error(function(e,r){return`Invalid prop \`orientation\` of value \`${e}\` supplied to \`${r}\`, expected one of:\n - horizontal\n - vertical\n\nDefaulting to \`${a}\`.`}(n,t)):null}};const p=u;exports.Root=p;
//# sourceMappingURL=index.js.map

@@ -1,2 +0,2 @@

function r(r,t,o){Object.defineProperty(r,t,{get:o,enumerable:!0})}import{Primitive as t}from"@radix-ui/react-primitive";import{forwardRef as o,createElement as e}from"react";import n from"@babel/runtime/helpers/esm/extends";var a={};const i="horizontal",p=["horizontal","vertical"];export const Separator=o(((r,o)=>{const{decorative:a,orientation:p=i,...u}=r,l=c(p)?p:i;return e(t,n({},a?{role:"none"}:{"aria-orientation":"vertical"===l?l:void 0,role:"separator"},{"data-orientation":l},u,{ref:o}))}));function c(r){return p.includes(r)}Separator.displayName="Separator",Separator.propTypes={orientation:function(r,t,o){const e=r[t],n=String(e);return e&&!c(e)?new Error(function(r,t){return`Invalid prop \`orientation\` of value \`${r}\` supplied to \`${t}\`, expected one of:\n - horizontal\n - vertical\n\nDefaulting to \`${i}\`.`}(n,o)):null}};export const Root=Separator;r(a,"Root",(function(){return Root})),r(a,"Separator",(function(){return Separator}));
import{Primitive as r}from"@radix-ui/react-primitive";import*as o from"react";import t from"@babel/runtime/helpers/esm/extends";const e="horizontal",n=["horizontal","vertical"];export const Separator=o.forwardRef(((n,i)=>{const{decorative:p,orientation:l=e,...c}=n,s=a(l)?l:e,u=p?{role:"none"}:{"aria-orientation":"vertical"===s?s:void 0,role:"separator"};return o.createElement(r,t({},u,{"data-orientation":s},c,{ref:i}))}));function a(r){return n.includes(r)}Separator.displayName="Separator",Separator.propTypes={orientation(r,o,t){const n=r[o],i=String(n);return n&&!a(n)?new Error(function(r,o){return`Invalid prop \`orientation\` of value \`${r}\` supplied to \`${o}\`, expected one of:\n - horizontal\n - vertical\n\nDefaulting to \`${e}\`.`}(i,t)):null}};export const Root=Separator;
//# sourceMappingURL=index.module.js.map
{
"name": "@radix-ui/react-separator",
"version": "0.0.9",
"version": "0.0.10",
"license": "MIT",

@@ -21,4 +21,4 @@ "source": "src/index.ts",

"@babel/runtime": "^7.13.10",
"@radix-ui/react-polymorphic": "0.0.8",
"@radix-ui/react-primitive": "0.0.9"
"@radix-ui/react-polymorphic": "0.0.9",
"@radix-ui/react-primitive": "0.0.10"
},

@@ -25,0 +25,0 @@ "peerDependencies": {

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