Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
11cb6746
V
vscode
项目概览
xxadev
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
11cb6746
编写于
7月 01, 2020
作者:
M
Miguel Solorio
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Update notebook color token names (fixes #98984)
上级
4c7d5640
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
63 addition
and
26 deletion
+63
-26
src/vs/workbench/contrib/notebook/browser/media/notebook.css
src/vs/workbench/contrib/notebook/browser/media/notebook.css
+23
-10
src/vs/workbench/contrib/notebook/browser/notebookEditorWidget.ts
...orkbench/contrib/notebook/browser/notebookEditorWidget.ts
+40
-16
未找到文件。
src/vs/workbench/contrib/notebook/browser/media/notebook.css
浏览文件 @
11cb6746
...
...
@@ -215,29 +215,42 @@
.monaco-workbench
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-top
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-bottom
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:after
{
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:after
{
content
:
""
;
position
:
absolute
;
width
:
100%
;
height
:
1px
;
background-color
:
rgba
(
255
,
255
,
255
,
0.12
);
}
/* top border */
.monaco-workbench
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-top
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:before
{
top
:
0
;
border-top
:
1px
solid
transparent
;
}
.monaco-workbench.hc-black
.notebookOverlay
.monaco-list
.monaco-list-row.focused.cell-editor-focus
.cell-focus-indicator-top
:before
,
.monaco-workbench.hc-black
.notebookOverlay
.monaco-list
.markdown-cell-row.focused.cell-editor-focus
:before
{
border-top-style
:
dashed
;
}
/* bottom border */
.monaco-workbench
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-bottom
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:after
{
bottom
:
0px
;
border-bottom
:
1px
solid
transparent
;
}
.monaco-workbench.hc-black
.notebookOverlay
.monaco-list
.monaco-list-row.focused.cell-editor-focus
.cell-focus-indicator-bottom
:before
,
.monaco-workbench.hc-black
.notebookOverlay
.monaco-list
.markdown-cell-row.focused.cell-editor-focus
:after
{
border-bottom-style
:
dashed
;
}
/* border color on light theme */
.monaco-workbench.vs
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-top
:before
,
.monaco-workbench.vs
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-bottom
:before
,
.monaco-workbench.vs
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:before
,
.monaco-workbench.vs
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:after
{
background-color
:
rgba
(
0
,
0
,
0
,
0.12
);
.monaco-workbench
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-top
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:before
{
top
:
0
;
}
.monaco-workbench
.notebookOverlay
.monaco-list
.monaco-list-row.focused
.cell-focus-indicator-bottom
:before
,
.monaco-workbench
.notebookOverlay
.monaco-list
.markdown-cell-row.focused
:after
{
bottom
:
0px
;
}
.monaco-workbench
.notebookOverlay
>
.cell-list-container
>
.monaco-list
>
.monaco-scrollable-element
>
.monaco-list-rows
>
.monaco-list-row
.menu.mouseover
,
...
...
src/vs/workbench/contrib/notebook/browser/notebookEditorWidget.ts
浏览文件 @
11cb6746
...
...
@@ -1312,11 +1312,11 @@ export const notebookCellBorder = registerColor('notebook.cellBorderColor', {
hc
:
PANEL_BORDER
},
nls
.
localize
(
'
notebook.cellBorderColor
'
,
"
The border color for notebook cells.
"
));
export
const
focusedEditor
Indicator
=
registerColor
(
'
notebook.focusedEditorIndicato
r
'
,
{
export
const
focusedEditor
BorderColor
=
registerColor
(
'
notebook.focusedEditorBorde
r
'
,
{
light
:
focusBorder
,
dark
:
focusBorder
,
hc
:
focusBorder
},
nls
.
localize
(
'
notebook.focusedEditor
Indicator
'
,
"
The color of the notebook cell editor indicato
r.
"
));
},
nls
.
localize
(
'
notebook.focusedEditor
Border
'
,
"
The color of the notebook cell editor borde
r.
"
));
export
const
cellStatusIconSuccess
=
registerColor
(
'
notebookStatusSuccessIcon.foreground
'
,
{
light
:
debugIconStartForeground
,
...
...
@@ -1349,17 +1349,29 @@ export const CELL_TOOLBAR_SEPERATOR = registerColor('notebook.cellToolbarSeperat
hc
:
contrastBorder
},
nls
.
localize
(
'
cellToolbarSeperator
'
,
"
The color of the seperator in the cell bottom toolbar
"
));
export
const
cellFocusBackground
=
registerColor
(
'
notebook.cellFocus
Background
'
,
{
export
const
focusedCellBackground
=
registerColor
(
'
notebook.focusedCell
Background
'
,
{
dark
:
transparent
(
PANEL_BORDER
,
.
4
),
light
:
transparent
(
listFocusBackground
,
.
4
),
hc
:
PANEL_BORDER
},
nls
.
localize
(
'
cellFocusBackground
'
,
"
The background color of focused or hovered cells
"
));
hc
:
null
},
nls
.
localize
(
'
focusedCellBackground
'
,
"
The background color of focused cells.
"
));
export
const
cellHoverBackground
=
registerColor
(
'
notebook.cellHoverBackground
'
,
{
dark
:
transparent
(
focusedCellBackground
,
.
5
),
light
:
transparent
(
focusedCellBackground
,
.
7
),
hc
:
null
},
nls
.
localize
(
'
notebook.cellHoverBackground
'
,
"
The background color of hovered cells.
"
));
export
const
focusedCellBorder
=
registerColor
(
'
notebook.focusedCellBorder
'
,
{
dark
:
Color
.
white
.
transparent
(
0.12
),
light
:
Color
.
black
.
transparent
(
0.12
),
hc
:
focusBorder
},
nls
.
localize
(
'
notebook.focusedCellBorder
'
,
"
The color of focused cells.
"
));
export
const
focusedCellShadow
=
registerColor
(
'
notebook.focusedCellShadow
'
,
{
dark
:
transparent
(
widgetShadow
,
0.6
),
light
:
transparent
(
widgetShadow
,
0.4
),
hc
:
Color
.
transparent
},
nls
.
localize
(
'
c
ellShadow
'
,
"
The color of the shadow on the focused or hovered cell
"
));
},
nls
.
localize
(
'
notebook.focusedC
ellShadow
'
,
"
The color of the shadow on the focused or hovered cell
"
));
export
const
cellStatusBarItemHover
=
registerColor
(
'
notebook.cellStatusBarItemHoverBackground
'
,
{
light
:
new
Color
(
new
RGBA
(
0
,
0
,
0
,
0.08
)),
...
...
@@ -1456,18 +1468,30 @@ registerThemingParticipant((theme, collector) => {
collector
.
addRule
(
`.notebookOverlay .monaco-list-row > .monaco-toolbar { border: solid 1px
${
cellToolbarSeperator
}
; }`
);
}
const
cellFocusBackgroundColor
=
theme
.
getColor
(
cellFocusBackground
);
if
(
cellFocusBackgroundColor
)
{
collector
.
addRule
(
`.notebookOverlay .code-cell-row:hover .cell-focus-indicator,
.notebookOverlay .code-cell-row.focused .cell-focus-indicator,
.notebookOverlay .code-cell-row.cell-output-hover .cell-focus-indicator { background-color:
${
cellFocusBackgroundColor
}
!important; }`
);
collector
.
addRule
(
`.notebookOverlay .markdown-cell-row:hover,
.notebookOverlay .markdown-cell-row.focused { background-color:
${
cellFocusBackgroundColor
}
!important; }`
);
const
focusedCellBackgroundColor
=
theme
.
getColor
(
focusedCellBackground
);
if
(
focusedCellBackgroundColor
)
{
collector
.
addRule
(
`.notebookOverlay .code-cell-row.focused .cell-focus-indicator,
.notebookOverlay .markdown-cell-row.focused { background-color:
${
focusedCellBackgroundColor
}
!important; }`
);
}
const
cellHoverBackgroundColor
=
theme
.
getColor
(
cellHoverBackground
);
if
(
cellHoverBackgroundColor
)
{
collector
.
addRule
(
`.notebookOverlay .code-cell-row:not(.focused):hover .cell-focus-indicator,
.notebookOverlay .code-cell-row:not(.focused).cell-output-hover .cell-focus-indicator,
.notebookOverlay .markdown-cell-row:not(.focused):hover { background-color:
${
cellHoverBackgroundColor
}
!important; }`
);
}
const
focusedEditorIndicatorColor
=
theme
.
getColor
(
focusedEditorIndicator
);
if
(
focusedEditorIndicatorColor
)
{
collector
.
addRule
(
`.notebookOverlay .monaco-list-row.cell-editor-focus .cell-editor-part:before { outline: solid 1px
${
focusedEditorIndicatorColor
}
; }`
);
const
focusedCellBorderColor
=
theme
.
getColor
(
focusedCellBorder
);
collector
.
addRule
(
`.monaco-workbench .notebookOverlay .monaco-list .monaco-list-row.focused .cell-focus-indicator-top:before,
.monaco-workbench .notebookOverlay .monaco-list .monaco-list-row.focused .cell-focus-indicator-bottom:before,
.monaco-workbench .notebookOverlay .monaco-list .markdown-cell-row.focused:before,
.monaco-workbench .notebookOverlay .monaco-list .markdown-cell-row.focused:after {
border-color:
${
focusedCellBorderColor
}
!important;
}`
);
const
focusedEditorBorderColorColor
=
theme
.
getColor
(
focusedEditorBorderColor
);
if
(
focusedEditorBorderColorColor
)
{
collector
.
addRule
(
`.notebookOverlay .monaco-list-row.cell-editor-focus .cell-editor-part:before { outline: solid 1px
${
focusedEditorBorderColorColor
}
; }`
);
}
const
editorBorderColor
=
theme
.
getColor
(
notebookCellBorder
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录