diff --git a/packages/tldraw/src/lib/ui.css b/packages/tldraw/src/lib/ui.css index d19a40d0d..9d3fb5fc5 100644 --- a/packages/tldraw/src/lib/ui.css +++ b/packages/tldraw/src/lib/ui.css @@ -1067,7 +1067,6 @@ min-width: 200px; display: flex; flex-direction: row; - gap: var(--space-3); background-color: var(--color-panel); box-shadow: var(--shadow-2); border-radius: var(--radius-3); @@ -1079,23 +1078,13 @@ max-width: 280px; } -.tlui-toast__main:nth-child(1) > .tlui-toast__content { - padding-left: var(--space-4); -} - .tlui-toast__content { - padding-left: 0px; - padding-top: var(--space-4); - padding-bottom: var(--space-4); + padding: var(--space-4); display: flex; flex-direction: column; gap: var(--space-3); } -.tlui-toast__content:not(:only-child) { - padding-bottom: var(--space-2); -} - .tlui-toast__title { font-weight: bold; color: var(--color-text-1); @@ -1109,7 +1098,6 @@ } .tlui-toast__icon + .tlui-toast__main > .tlui-toast__actions { - margin-left: -12px; padding-left: 0px; } diff --git a/packages/tldraw/src/lib/ui/components/DebugPanel.tsx b/packages/tldraw/src/lib/ui/components/DebugPanel.tsx index 5bb8c21b8..da913c8d5 100644 --- a/packages/tldraw/src/lib/ui/components/DebugPanel.tsx +++ b/packages/tldraw/src/lib/ui/components/DebugPanel.tsx @@ -97,7 +97,40 @@ const DebugMenuContent = track(function DebugMenuContent({ id: uniqueId(), title: 'Something happened', description: 'Hey, attend to this thing over here. It might be important!', - keepOpen: false, + keepOpen: true, + // icon?: string + // title?: string + // description?: string + // actions?: TLUiToastAction[] + }) + addToast({ + id: uniqueId(), + title: 'Something happened', + description: 'Hey, attend to this thing over here. It might be important!', + keepOpen: true, + actions: [ + { + label: 'Primary', + type: 'primary', + onClick: () => { + void null + }, + }, + { + label: 'Normal', + type: 'normal', + onClick: () => { + void null + }, + }, + { + label: 'Danger', + type: 'danger', + onClick: () => { + void null + }, + }, + ], // icon?: string // title?: string // description?: string