Skip to content

Commit 5a9a0a0

Browse files
Use jupyterlab css variables for the selected suggestions (#733)
* Use jupyterlab css variables for the selected suggestions. * Add relevant css rules for the icons of the toolbar of the selection elements of the suggestion panel. * Add a css rule for the text color of the anonymous user name. Add missing line breaks in base.css.
1 parent 284fb0a commit 5a9a0a0

File tree

3 files changed

+17
-2
lines changed

3 files changed

+17
-2
lines changed

packages/base/src/tools.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ export const visibilityIcon = new LabIcon({
3535
name: 'jupytercad:visibilityIcon',
3636
svgstr: visibilitySvg
3737
});
38+
3839
export const visibilityOffIcon = new LabIcon({
3940
name: 'jupytercad:visibilityOffIcon',
4041
svgstr: visibilityOffSvg
Lines changed: 1 addition & 1 deletion
Loading

python/jupytercad_lab/style/base.css

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,7 @@ div.jpcad-toolbar-widget > div.jp-Toolbar-item:last-child {
199199
display: flex;
200200
flex-direction: row-reverse;
201201
}
202+
202203
.jpcad-toolbar-react-widget {
203204
display: flex;
204205
flex-direction: row;
@@ -398,10 +399,12 @@ div.jpcad-toolbar-widget > div.jp-Toolbar-item:last-child {
398399
.highlight {
399400
background-color: var(--jp-layout-color2) !important;
400401
}
402+
401403
.jupytercad-notebook-widget {
402404
height: 600px;
403405
width: 100%;
404406
}
407+
405408
.jupytercad-notebook-widget > div {
406409
height: 100%;
407410
width: 100%;
@@ -439,8 +442,14 @@ div.jpcad-toolbar-widget > div.jp-Toolbar-item:last-child {
439442
}
440443

441444
.jpcad-control-panel-suggestion.selected {
442-
background-color: rgba(0, 122, 255, 0.23);
445+
color: var(--jp-ui-inverse-font-color1);
446+
background: var(--jp-brand-color1);
443447
}
448+
449+
.jpcad-control-panel-suggestion.selected .jp-icon-selectable[fill] {
450+
fill: #fff;
451+
}
452+
444453
.jcad-suggestion-tree-node-icon {
445454
display: flex;
446455
flex-direction: column;
@@ -459,18 +468,22 @@ div.jpcad-toolbar-widget > div.jp-Toolbar-item:last-child {
459468
vertical-align: middle;
460469
border-radius: 100%;
461470
}
471+
462472
.jcad-suggestion-tree-node-user span {
463473
width: 20px;
464474
text-align: center;
465475
font-size: 12px;
476+
color: var(--jp-ui-font-color1);
466477
}
478+
467479
span.jcad-suggestion-tree-node-label {
468480
white-space: nowrap;
469481
text-overflow: ellipsis;
470482
overflow-x: hidden;
471483
flex-grow: 1;
472484
padding-left: 5px;
473485
}
486+
474487
.jpcad-SplitSlider {
475488
position: absolute;
476489
cursor: ew-resize;
@@ -489,6 +502,7 @@ span.jcad-suggestion-tree-node-label {
489502
body[data-jp-theme-light='false'] {
490503
--jcad-splitview-background: #120b07;
491504
}
505+
492506
body[data-jp-theme-light='true'] {
493507
--jcad-splitview-background: #edf4f8;
494508
}

0 commit comments

Comments
 (0)