fix(dashboard): noCompactor + note edit/preview toggle + widget border
- dashboard-grid: add noCompactor to prevent auto-compaction on drag - note-widget: edit/preview toggle button (pencil icon), isEditing state, hideToolbar in preview mode - widget-wrapper: border-primary/20 accent border - dashboard-store: console.error on widget add/remove/layout-save failures Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { useEffect, useRef, useState } from 'react';
|
||||
import { Responsive } from 'react-grid-layout';
|
||||
import { Responsive, noCompactor } from 'react-grid-layout';
|
||||
import type { ResponsiveLayouts } from 'react-grid-layout';
|
||||
import 'react-grid-layout/css/styles.css';
|
||||
import 'react-resizable/css/styles.css';
|
||||
@@ -97,6 +97,7 @@ export function DashboardGrid({
|
||||
resizeConfig={{
|
||||
enabled: isEditMode,
|
||||
}}
|
||||
compactor={noCompactor}
|
||||
onLayoutChange={(_currentLayout, allLayouts) => onLayoutChange(allLayouts)}
|
||||
>
|
||||
{widgets.map((widget) => {
|
||||
|
||||
Reference in New Issue
Block a user