@mhamz.01/easyflow-texteditor 0.1.47 → 0.1.49

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/dist/index.mjs CHANGED
@@ -303,7 +303,8 @@ function SidebarProvider({
303
303
  ...style
304
304
  },
305
305
  className: cn(
306
- "group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",
306
+ // CHANGED: removed min-h-svh, added h-full and relative positioning
307
+ "group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex h-full w-full relative",
307
308
  className
308
309
  ),
309
310
  ...props,
@@ -383,7 +384,8 @@ function Sidebar({
383
384
  {
384
385
  "data-slot": "sidebar-container",
385
386
  className: cn(
386
- "fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex",
387
+ // CHANGED: fixed → absolute, inset-y-0 → top-0 bottom-0, h-svh h-full
388
+ "absolute top-0 bottom-0 z-10 hidden h-full w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex",
387
389
  side === "left" ? "left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]" : "right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",
388
390
  // Adjust the padding for floating and inset variants.
389
391
  variant === "floating" || variant === "inset" ? "p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l",
@@ -539,7 +541,7 @@ function EditorShell({ children }) {
539
541
  return /* @__PURE__ */ jsx7(
540
542
  "div",
541
543
  {
542
- className: "\r\n relative\r\n w-full\r\n h-full\r\n overflow-hidden\r\n border\r\n rounded-md\r\n bg-background\r\n ",
544
+ className: "\r\n relative w-full h-full flex flex-col min-h-0 isolate\r\n ",
543
545
  "data-easyflow-editor": true,
544
546
  children: /* @__PURE__ */ jsx7(SidebarProvider, { children })
545
547
  }
@@ -1190,7 +1192,7 @@ function EditorLayout({ children, onChange, initialTabs, onTabsChange }) {
1190
1192
  editorContent: editor,
1191
1193
  setEditorContent: setEditor,
1192
1194
  debouncedSave
1193
- }, children: /* @__PURE__ */ jsx11(SidebarProvider, { children: /* @__PURE__ */ jsxs6("div", { className: "flex h-screen w-full min-h-0", children: [
1195
+ }, children: /* @__PURE__ */ jsx11(SidebarProvider, { children: /* @__PURE__ */ jsxs6("div", { className: "flex h-full w-full min-h-0 relative", children: [
1194
1196
  /* @__PURE__ */ jsx11(
1195
1197
  AppSidebar,
1196
1198
  {
@@ -1207,9 +1209,9 @@ function EditorLayout({ children, onChange, initialTabs, onTabsChange }) {
1207
1209
  onDeleteSubTab: deleteSubTab
1208
1210
  }
1209
1211
  ),
1210
- /* @__PURE__ */ jsxs6(SidebarInset, { className: "flex flex-col flex-1 min-h-0", children: [
1211
- /* @__PURE__ */ jsx11("header", { className: "h-12 flex-shrink-0 border-b", children: /* @__PURE__ */ jsx11(SidebarTrigger, {}) }),
1212
- children
1212
+ /* @__PURE__ */ jsxs6(SidebarInset, { className: "flex flex-col flex-1 min-h-0 overflow-hidden", children: [
1213
+ /* @__PURE__ */ jsx11("header", { className: "h-12 flex-shrink-0 border-b flex items-center px-4", children: /* @__PURE__ */ jsx11(SidebarTrigger, {}) }),
1214
+ /* @__PURE__ */ jsx11("div", { className: "flex-1 min-h-0 overflow-auto", children })
1213
1215
  ] })
1214
1216
  ] }) }) });
1215
1217
  }
@@ -7726,9 +7728,20 @@ function SimpleEditor() {
7726
7728
  }
7727
7729
 
7728
7730
  // src/components/editor/editor.tsx
7731
+ import clsx2 from "clsx";
7729
7732
  import { jsx as jsx77 } from "react/jsx-runtime";
7730
7733
  function Editor({ onChange, className, style, onTabsChange, initialTabs }) {
7731
- return /* @__PURE__ */ jsx77("div", { className, style, children: /* @__PURE__ */ jsx77(EditorShell, { children: /* @__PURE__ */ jsx77(EditorLayout, { onChange, initialTabs, onTabsChange, children: /* @__PURE__ */ jsx77(SimpleEditor, {}) }) }) });
7734
+ return /* @__PURE__ */ jsx77(
7735
+ "div",
7736
+ {
7737
+ className: clsx2(
7738
+ "flex flex-col flex-1 min-h-0 overflow-hidden",
7739
+ className
7740
+ ),
7741
+ style,
7742
+ children: /* @__PURE__ */ jsx77(EditorShell, { children: /* @__PURE__ */ jsx77(EditorLayout, { onChange, initialTabs, onTabsChange, children: /* @__PURE__ */ jsx77(SimpleEditor, {}) }) })
7743
+ }
7744
+ );
7732
7745
  }
7733
7746
 
7734
7747
  // src/hooks/use-scrolling.ts