Skip to content

Commit

Permalink
tweak css
Browse files Browse the repository at this point in the history
  • Loading branch information
Alan Fleming committed Nov 10, 2024
1 parent e8a4d53 commit 7ce9973
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
5 changes: 4 additions & 1 deletion ipylab/widgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import asyncio
from typing import TYPE_CHECKING

from ipywidgets import Box, DOMWidget, TypedTuple, register, widget_serialization
from ipywidgets import Box, DOMWidget, Layout, TypedTuple, register, widget_serialization
from ipywidgets.widgets.trait_types import InstanceDict
from traitlets import Container, Dict, Instance, Unicode, observe

Expand Down Expand Up @@ -108,6 +108,9 @@ class SplitPanel(Panel):
_model_name = Unicode("SplitPanelModel").tag(sync=True)
_view_name = Unicode("SplitPanelView").tag(sync=True)
orientation = Unicode("vertical").tag(sync=True)
layout = InstanceDict(Layout, kw={"width": "100%", "height": "100%", "overflow": "hidden"}).tag(
sync=True, **widget_serialization
)
_force_update_in_progress = False

# ============== Start temp fix =============
Expand Down
1 change: 1 addition & 0 deletions src/widgets/shell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ export class ShellModel extends IpylabModel {
if (args.asDocument && !(widget instanceof DocumentWidget)) {
const jfem = await IpylabModel.JFEM.getModelByVpath(args.vpath);
const context = jfem.context as any;
widget.addClass('ipylab-Document');
const w = (widget = new DocumentWidget({ context, content: widget }));
w.node.removeChild(w.toolbar.node);
}
Expand Down
14 changes: 5 additions & 9 deletions style/widget.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,23 @@
.ipylab-Panel {
box-sizing: border-box;
display: flex;
height: 100%;
width: 100%;
margin: 0;
flex-direction: column;
overflow: auto;
}

.ipylab-SplitPanel {
box-sizing: border-box;
margin: 0;
display: flex;
height: 100%;
width: 100%;
overflow: hidden;
}

/* Default Split Handle Color */
.ipylab-SplitPanel .lm-SplitPanel-handle {
background-color: var(--jp-border-color2);
}

.ipylab-MainArea {
box-sizing: border-box;
display: flex;
margin: 0;
.ipylab-Document {
height: 100%;
width: 100%;
}

0 comments on commit 7ce9973

Please sign in to comment.