@stackshift-ui/sheet 1.0.0-beta.4 → 1.0.0-beta.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@stackshift-ui/sheet",
3
3
  "description": "Extends the Dialog component to display content that complements the main content of the screen.",
4
- "version": "1.0.0-beta.4",
4
+ "version": "1.0.0-beta.6",
5
5
  "private": false,
6
6
  "sideEffects": false,
7
7
  "main": "./dist/index.js",
@@ -38,11 +38,11 @@
38
38
  "@radix-ui/react-dialog": "^1.1.14",
39
39
  "classnames": "^2.5.1",
40
40
  "lucide-react": "^0.468.0",
41
- "@stackshift-ui/scripts": "6.1.0-beta.2",
42
- "@stackshift-ui/system": "6.1.0-beta.3"
41
+ "@stackshift-ui/system": "7.0.0-beta.5",
42
+ "@stackshift-ui/scripts": "7.0.0-beta.4"
43
43
  },
44
44
  "peerDependencies": {
45
- "@stackshift-ui/system": ">=6.1.0-beta.3",
45
+ "@stackshift-ui/system": ">=7.0.0-beta.5",
46
46
  "@types/react": "16.8 - 19",
47
47
  "next": "10 - 14",
48
48
  "react": "16.8 - 19",
package/src/sheet.tsx CHANGED
@@ -100,7 +100,7 @@ function SheetContent({
100
100
  )}
101
101
  {...props}>
102
102
  {children}
103
- <SheetPrimitive.Close className="ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none">
103
+ <SheetPrimitive.Close className="ring-offset-background focus-visible:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-hidden disabled:pointer-events-none">
104
104
  <XIcon className="size-4" />
105
105
  <span className="sr-only">Close</span>
106
106
  </SheetPrimitive.Close>
@@ -1 +0,0 @@
1
- var g=Object.create;var f=Object.defineProperty;var h=Object.getOwnPropertyDescriptor;var i=Object.getOwnPropertyNames;var j=Object.getPrototypeOf,k=Object.prototype.hasOwnProperty;var m=(a=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(a,{get:(b,c)=>(typeof require!="undefined"?require:b)[c]}):a)(function(a){if(typeof require!="undefined")return require.apply(this,arguments);throw Error('Dynamic require of "'+a+'" is not supported')});var n=(a,b)=>()=>(b||a((b={exports:{}}).exports,b),b.exports);var l=(a,b,c,e)=>{if(b&&typeof b=="object"||typeof b=="function")for(let d of i(b))!k.call(a,d)&&d!==c&&f(a,d,{get:()=>b[d],enumerable:!(e=h(b,d))||e.enumerable});return a};var o=(a,b,c)=>(c=a!=null?g(j(a)):{},l(b||!a||!a.__esModule?f(c,"default",{value:a,enumerable:!0}):c,a));export{m as a,n as b,o as c};
@@ -1 +0,0 @@
1
- import*as o from"@radix-ui/react-dialog";import{XIcon as b}from"lucide-react";import*as p from"react";import{cn as r,DefaultComponent as i,useStackShiftUIComponents as n}from"@stackshift-ui/system";import{jsx as s,jsxs as m}from"react/jsx-runtime";var d="Sheet",c="SheetTrigger",h="SheetPortal",f="SheetClose",u="SheetOverlay",y="SheetContent",S="SheetHeader",P="SheetFooter",C="SheetTitle",g="SheetDescription",x=p.forwardRef(({...e},t)=>{let{[d]:a=i}=n();return s(a,{as:o.Root,ref:t,"data-slot":"sheet",...e})});x.displayName=d;function T({...e}){let{[c]:t=i}=n();return s(t,{as:o.Trigger,"data-slot":"sheet-trigger",...e})}T.displayName=c;function w({...e}){let{[f]:t=i}=n();return s(t,{as:o.Close,"data-slot":"sheet-close",...e})}w.displayName=f;function v({...e}){let{[h]:t=i}=n();return s(t,{as:o.Portal,"data-slot":"sheet-portal",...e})}v.displayName=h;var N=p.forwardRef(({className:e,...t},a)=>{let{[u]:l=i}=n();return s(l,{as:o.Overlay,ref:a,"data-slot":"sheet-overlay",className:r("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...t})});N.displayName=u;function D({className:e,children:t,side:a="right",...l}){let{[y]:R=i}=n();return m(v,{children:[s(N,{}),m(R,{as:o.Content,"data-slot":"sheet-content",className:r("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",a==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",a==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",a==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",a==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",e),...l,children:[t,m(o.Close,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[s(b,{className:"size-4"}),s("span",{className:"sr-only",children:"Close"})]})]})]})}D.displayName=y;function O({className:e,...t}){let{[S]:a=i}=n();return s(a,{"data-slot":"sheet-header",className:r("flex flex-col gap-1.5 p-4",e),...t})}O.displayName=S;function k({className:e,...t}){let{[P]:a=i}=n();return s(a,{"data-slot":"sheet-footer",className:r("mt-auto flex flex-col gap-2 p-4",e),...t})}k.displayName=P;function z({className:e,...t}){let{[C]:a=i}=n();return s(a,{as:o.Title,"data-slot":"sheet-title",className:r("text-foreground font-semibold",e),...t})}z.displayName=C;function F({className:e,...t}){let{[g]:a=i}=n();return s(a,{as:o.Description,"data-slot":"sheet-description",className:r("text-muted-foreground text-sm",e),...t})}F.displayName=g;export{x as a,T as b,w as c,D as d,O as e,k as f,z as g,F as h};
package/dist/index.d.ts DELETED
@@ -1 +0,0 @@
1
- export * from "./sheet";
package/dist/index.js DELETED
@@ -1,2 +0,0 @@
1
- "use client";
2
- "use strict";var H=Object.create;var l=Object.defineProperty;var E=Object.getOwnPropertyDescriptor;var I=Object.getOwnPropertyNames;var W=Object.getPrototypeOf,U=Object.prototype.hasOwnProperty;var X=(e,t)=>{for(var a in t)l(e,a,{get:t[a],enumerable:!0})},p=(e,t,a,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of I(t))!U.call(e,n)&&n!==a&&l(e,n,{get:()=>t[n],enumerable:!(r=E(t,n))||r.enumerable});return e};var d=(e,t,a)=>(a=e!=null?H(W(e)):{},p(t||!e||!e.__esModule?l(a,"default",{value:e,enumerable:!0}):a,e)),q=e=>p(l({},"__esModule",{value:!0}),e);var A={};X(A,{Sheet:()=>R,SheetClose:()=>x,SheetContent:()=>D,SheetDescription:()=>F,SheetFooter:()=>k,SheetHeader:()=>O,SheetTitle:()=>z,SheetTrigger:()=>b});module.exports=q(A);var i=d(require("@radix-ui/react-dialog")),c=require("lucide-react"),m=d(require("react")),o=require("@stackshift-ui/system"),s=require("react/jsx-runtime"),h="Sheet",f="SheetTrigger",u="SheetPortal",y="SheetClose",S="SheetOverlay",P="SheetContent",C="SheetHeader",g="SheetFooter",v="SheetTitle",N="SheetDescription",R=m.forwardRef(({...e},t)=>{let{[h]:a=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(a,{as:i.Root,ref:t,"data-slot":"sheet",...e})});R.displayName=h;function b({...e}){let{[f]:t=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(t,{as:i.Trigger,"data-slot":"sheet-trigger",...e})}b.displayName=f;function x({...e}){let{[y]:t=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(t,{as:i.Close,"data-slot":"sheet-close",...e})}x.displayName=y;function T({...e}){let{[u]:t=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(t,{as:i.Portal,"data-slot":"sheet-portal",...e})}T.displayName=u;var w=m.forwardRef(({className:e,...t},a)=>{let{[S]:r=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(r,{as:i.Overlay,ref:a,"data-slot":"sheet-overlay",className:(0,o.cn)("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...t})});w.displayName=S;function D({className:e,children:t,side:a="right",...r}){let{[P]:n=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsxs)(T,{children:[(0,s.jsx)(w,{}),(0,s.jsxs)(n,{as:i.Content,"data-slot":"sheet-content",className:(0,o.cn)("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",a==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",a==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",a==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",a==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",e),...r,children:[t,(0,s.jsxs)(i.Close,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[(0,s.jsx)(c.XIcon,{className:"size-4"}),(0,s.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}D.displayName=P;function O({className:e,...t}){let{[C]:a=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(a,{"data-slot":"sheet-header",className:(0,o.cn)("flex flex-col gap-1.5 p-4",e),...t})}O.displayName=C;function k({className:e,...t}){let{[g]:a=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(a,{"data-slot":"sheet-footer",className:(0,o.cn)("mt-auto flex flex-col gap-2 p-4",e),...t})}k.displayName=g;function z({className:e,...t}){let{[v]:a=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(a,{as:i.Title,"data-slot":"sheet-title",className:(0,o.cn)("text-foreground font-semibold",e),...t})}z.displayName=v;function F({className:e,...t}){let{[N]:a=o.DefaultComponent}=(0,o.useStackShiftUIComponents)();return(0,s.jsx)(a,{as:i.Description,"data-slot":"sheet-description",className:(0,o.cn)("text-muted-foreground text-sm",e),...t})}F.displayName=N;0&&(module.exports={Sheet,SheetClose,SheetContent,SheetDescription,SheetFooter,SheetHeader,SheetTitle,SheetTrigger});
package/dist/index.mjs DELETED
@@ -1,2 +0,0 @@
1
- "use client";
2
- "use strict";import{a as e,b as o,c as r,d as t,e as c,f,g as i,h as l}from"./chunk-URL6WFJR.mjs";import"./chunk-3EYN2AKU.mjs";export{e as Sheet,r as SheetClose,t as SheetContent,l as SheetDescription,f as SheetFooter,c as SheetHeader,i as SheetTitle,o as SheetTrigger};
@@ -1,2 +0,0 @@
1
- import '@testing-library/jest-dom';
2
- export {};