@alexgorbatchev/shadcn 0.0.120 → 0.0.121

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.
@@ -45,6 +45,11 @@ interface ISplitViewProps {
45
45
  * image, stays in view above it.
46
46
  */
47
47
  drawerHeight?: "tall" | "half";
48
+ /**
49
+ * With the "drawer" narrow layout, a CSS length from the viewport's top where the drawer's top edge sits instead of
50
+ * `drawerHeight`, such as "3rem" to start it right under a phone's top bar, so no cut slice of the page shows above it.
51
+ */
52
+ drawerTopInset?: string;
48
53
  /** Called when a "sheet" or "drawer" narrow layout asks to open or close the sidebar, such as on Escape or a swipe. */
49
54
  onSidebarOpenChange?: (open: boolean) => void;
50
55
  /**
@@ -58,5 +63,5 @@ interface ISplitViewProps {
58
63
  * open sidebar take over the content's place. The sidebar and content render into slots that move between the
59
64
  * layouts, so their state survives resizing across the breakpoint and opening or closing the sidebar.
60
65
  */
61
- export declare function SplitView({ sidebar, children, storageKey, sidebarPosition, sidebarOpen, storage, sidebarLabel, contentLabel, resizeLabel, defaultSidebarSize, sidebarPadding, contentPadding, layout: layoutMode, minSidebarSize, maxSidebarSize, wideQuery, narrowLayout, sidebarExpanded, drawerHeight, onSidebarOpenChange, sidebarFinalFocus, }: ISplitViewProps): ReactElement;
66
+ export declare function SplitView({ sidebar, children, storageKey, sidebarPosition, sidebarOpen, storage, sidebarLabel, contentLabel, resizeLabel, defaultSidebarSize, sidebarPadding, contentPadding, layout: layoutMode, minSidebarSize, maxSidebarSize, wideQuery, narrowLayout, sidebarExpanded, drawerHeight, drawerTopInset, onSidebarOpenChange, sidebarFinalFocus, }: ISplitViewProps): ReactElement;
62
67
  export {};
@@ -116,6 +116,7 @@ function SplitView({
116
116
  narrowLayout = "stack",
117
117
  sidebarExpanded = false,
118
118
  drawerHeight = "tall",
119
+ drawerTopInset,
119
120
  onSidebarOpenChange,
120
121
  sidebarFinalFocus
121
122
  }) {
@@ -266,7 +267,8 @@ function SplitView({
266
267
  children: /* @__PURE__ */ jsxs(DrawerContent2, {
267
268
  "aria-label": sidebarLabel,
268
269
  finalFocus: sidebarFinalFocus,
269
- className: cn2(narrowLayout === "drawer" && "data-[swipe-axis=y]:[--drawer-content-max-height:100dvh] data-[swipe-axis=y]:rounded-t-none", narrowLayout === "drawer" && (sidebarExpanded ? "h-dvh" : drawerHeight === "half" ? "h-[50dvh]" : "h-[85dvh]")),
270
+ className: cn2(narrowLayout === "drawer" && "data-[swipe-axis=y]:[--drawer-content-max-height:100dvh] data-[swipe-axis=y]:rounded-t-none", narrowLayout === "drawer" && (sidebarExpanded ? "h-dvh" : drawerTopInset ? "h-[calc(100dvh-var(--split-view-drawer-top))]" : drawerHeight === "half" ? "h-[50dvh]" : "h-[85dvh]")),
271
+ style: drawerTopInset ? { ["--split-view-drawer-top"]: drawerTopInset } : undefined,
270
272
  children: [
271
273
  narrowLayout === "sheet" && /* @__PURE__ */ jsxs("div", {
272
274
  className: "flex shrink-0 items-center justify-between gap-2 p-panel pb-0",
package/dist/prototype.js CHANGED
@@ -2051,7 +2051,7 @@ var program = new Command;
2051
2051
  // package.json
2052
2052
  var package_default = {
2053
2053
  name: "@alexgorbatchev/shadcn",
2054
- version: "0.0.120",
2054
+ version: "0.0.121",
2055
2055
  description: "Sharp, monospace React components with compact and comfortable densities.",
2056
2056
  license: "MIT",
2057
2057
  repository: {
package/dist/theme.css CHANGED
@@ -131,7 +131,7 @@
131
131
  --border: #353b44;
132
132
  --input: #6f7783;
133
133
  --ring: #ff5cd6;
134
- --frame-edge: rgb(255 255 255 / 0.24);
134
+ --frame-edge: rgb(255 255 255 / 0.34);
135
135
  --media-edge: var(--input);
136
136
  --frame-halo: rgb(0 0 0 / 0.92);
137
137
  --backdrop: rgb(4 5 7 / 0.7);
@@ -171,7 +171,7 @@
171
171
  --border: #353b44;
172
172
  --input: #6f7783;
173
173
  --ring: #ff5cd6;
174
- --frame-edge: rgb(255 255 255 / 0.24);
174
+ --frame-edge: rgb(255 255 255 / 0.34);
175
175
  --media-edge: var(--input);
176
176
  --frame-halo: rgb(0 0 0 / 0.92);
177
177
  --backdrop: rgb(4 5 7 / 0.7);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexgorbatchev/shadcn",
3
- "version": "0.0.120",
3
+ "version": "0.0.121",
4
4
  "description": "Sharp, monospace React components with compact and comfortable densities.",
5
5
  "license": "MIT",
6
6
  "repository": {