mirror of
https://github.com/docmost/docmost.git
synced 2026-08-31 19:05:29 +08:00
fix(base): drop outer panel border on inline embed grid
The .grid had a 1px outer border + small radius drawing a rounded rectangle around the whole table. In standalone full-page mode that reads as a panel and is fine. In an inline embed it looked like a floating box, especially with the leftward padded area inside the border. Make the outer border and radius CSS vars; the embed wrapper sets them to none/0 so inline databases get only cell-level gridlines, matching Notion's document-style rendering. Standalone bases get the default 1px panel frame as before.
This commit is contained in:
@@ -28,6 +28,10 @@ function applyExtension(wrapper: HTMLDivElement) {
|
||||
wrapper.style.setProperty("--embed-extend-l", `${extendLeft}px`);
|
||||
wrapper.style.setProperty("--embed-extend-r", `${extendRight}px`);
|
||||
wrapper.style.setProperty("--embed-grid-pad-left", `${extendLeft}px`);
|
||||
// Drop the standalone "panel" frame: inline databases read as part
|
||||
// of the document, with only cell separators as gridlines.
|
||||
wrapper.style.setProperty("--grid-outer-border", "none");
|
||||
wrapper.style.setProperty("--grid-outer-radius", "0");
|
||||
}
|
||||
|
||||
export function BaseEmbedView({ node }: NodeViewProps) {
|
||||
|
||||
Reference in New Issue
Block a user