未验证 提交 dd4dd938 编写于 作者: R RotPublic 提交者: GitHub

Optimize visual effects

Co-authored-by: Nwuzewu <wuzewu@baidu.com>
上级 6fdfcdea
html { html {
text-size-adjust: 100%; text-size-adjust: 100%;
text-rendering: optimizeLegibility; text-rendering: optimizeLegibility;
} }
body { body {
overflow: hidden; overflow: hidden;
margin: 0; margin: 0;
width: 100vw; width: 100vw;
height: 100vh; height: 100vh;
font-family: -apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'Ubuntu', 'Droid Sans', sans-serif, font-family: -apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'Ubuntu', 'Droid Sans', sans-serif,
'PingFang SC'; 'PingFang SC';
font-size: 12px; font-size: 12px;
text-rendering: geometricPrecision; text-rendering: geometricPrecision;
background-color: #fff; background-color: #fff;
&.dark { &.dark {
background-color: #1d1d1f; background-color: #1d1d1f;
} }
} }
.graph { .graph {
overflow: auto; overflow: auto;
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.canvas { .canvas {
display: block; display: block;
// position: absolute; // position: absolute;
text-rendering: geometricPrecision; text-rendering: geometricPrecision;
user-select: none; user-select: none;
cursor: grab; cursor: grab;
} }
path { path {
stroke: #666; stroke: #666;
stroke-width: 1px; stroke-width: 1px;
fill: none; fill: none;
} }
line { line {
stroke: #666; stroke: #666;
stroke-width: 1px; stroke-width: 1px;
fill: #666; fill: #666;
} }
text { text {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'Ubuntu', 'Droid Sans', sans-serif, font-family: -apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'Ubuntu', 'Droid Sans', sans-serif,
'PingFang SC'; 'PingFang SC';
font-size: 11px; font-size: 11px;
text-rendering: geometricPrecision; text-rendering: geometricPrecision;
fill: #000; fill: #000;
.dark & { .dark & {
fill: #cfcfd1; fill: #cfcfd1;
} }
} }
.node-item { .node-item {
path { path {
fill: #fff; fill: #fff;
fill-opacity: 1; fill-opacity: 1;
stroke: none; stroke: none;
transition: fill 0.075s ease-in, fill-opacity 0.075s ease-in; transition: fill 0.075s ease-in, fill-opacity 0.075s ease-in;
} }
text { text {
transition: fill 0.075s ease-in; transition: fill 0.075s ease-in;
} }
&:hover { &:hover {
path { path {
fill: #2932e1; fill: #2932e1;
fill-opacity: 1; fill-opacity: 1;
} }
text { text {
fill: #fff; fill: #fff;
} }
} }
} }
.node-item-function path { .node-item-function path {
fill: #9bb9e8; fill: #9bb9e8;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type { .node-item-type {
cursor: pointer; cursor: pointer;
path { path {
fill: #8bb8ff; fill: #8bb8ff;
fill-opacity: 0.9; fill-opacity: 0.9;
} }
} }
.node-item-type-constant path { .node-item-type-constant path {
fill: #b4ccb7; fill: #b4ccb7;
} }
.node-item-type-control path { .node-item-type-control path {
fill: #a8e9b8; fill: #a8e9b8;
} }
.node-item-type-layer path { .node-item-type-layer path {
fill: #db989a; fill: #db989a;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-container path { .node-item-type-container path {
fill: #db989a; fill: #db989a;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-wrapper path { .node-item-type-wrapper path {
fill: #6dcde4; fill: #6dcde4;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-conv path { .node-item-type-conv path {
fill: #6dcde4; fill: #6dcde4;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-activation path { .node-item-type-activation path {
fill: #93c2ca; fill: #93c2ca;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-pool path { .node-item-type-pool path {
fill: #de7cce; fill: #de7cce;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-normalization path { .node-item-type-normalization path {
fill: #da96bc; fill: #da96bc;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-dropout path { .node-item-type-dropout path {
fill: #309e51; fill: #309e51;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-pad path { .node-item-type-pad path {
fill: #309e51; fill: #309e51;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-shape path { .node-item-type-shape path {
fill: #d6c482; fill: #d6c482;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-tensor path { .node-item-type-tensor path {
fill: #6d7ce4; fill: #6d7ce4;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-transform path { .node-item-type-transform path {
fill: #cdcb74; fill: #cdcb74;
} }
.node-item-type-sequence path { .node-item-type-sequence path {
fill: #cdcb74; fill: #cdcb74;
} }
.node-item-type-data path { .node-item-type-data path {
fill: #2576ad; fill: #2576ad;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-type-custom path { .node-item-type-custom path {
fill: #e46d6d; fill: #e46d6d;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.node-item-input { .node-item-input {
cursor: pointer; cursor: pointer;
path { path {
fill: #fff; fill: #fff;
} }
} }
.node-item-constant { .node-item-constant {
cursor: pointer; cursor: pointer;
path { path {
fill: #eee; fill: #eee;
} }
} }
.node-item-undefined { .node-item-undefined {
cursor: pointer; cursor: pointer;
path { path {
fill: #ca5353; fill: #ca5353;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
} }
.node-attribute { .node-attribute {
cursor: pointer; cursor: pointer;
text { text {
font-size: 9px; font-size: 9px;
font-weight: normal; font-weight: normal;
} }
} }
.node-attribute path { .node-attribute path {
fill: #fff; fill: #fff;
stroke-width: 0; stroke-width: 0;
.dark & { .dark & {
fill: #262629; fill: #262629;
} }
} }
.graph-item-input { .graph-item-input {
cursor: pointer; cursor: pointer;
path { path {
fill: #e49d6d; fill: #e49d6d;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
} }
.graph-item-output { .graph-item-output {
cursor: pointer; cursor: pointer;
path { path {
fill: #e4e06d; fill: #e4e06d;
fill-opacity: 0.9; fill-opacity: 0.9;
} }
} }
.edge-label text { .edge-label text {
font-size: 10px; font-size: 10px;
} }
.edge-path { .edge-path {
stroke: #666; stroke: #666;
stroke-width: 1px; stroke-width: 1px;
fill: none; fill: none;
} }
#arrowhead-vee path { #arrowhead-vee path {
fill: #666; fill: #666;
} }
.edge-path-control-dependency { .edge-path-control-dependency {
stroke-dasharray: 3, 2; stroke-dasharray: 3, 2;
} }
.cluster .clusterGroup { .cluster .clusterGroup {
fill: #dce9ff; fill: #dce9ff;
stroke: #666; stroke: #666;
stroke-width: 1px; stroke-width: 1px;
} }
.node-item-function path { .node-item-function path {
fill: #9bb9e8; fill: #9bb9e8;
fill-opacity: 0.7; fill-opacity: 0.7;
} }
.cluster .clusterGroup-constant { .cluster .clusterGroup-constant {
fill: #e8efe9; fill: #e8efe9;
} }
.cluster .clusterGroup-control { .cluster .clusterGroup-control {
fill: #e4f8e9; fill: #e4f8e9;
} }
.cluster .clusterGroup-layer { .cluster .clusterGroup-layer {
fill: #f4e0e0; fill: #f4e0e0;
} }
.cluster .clusterGroup-conv { .cluster .clusterGroup-conv {
fill: #d3f0f6; fill: #d3f0f6;
} }
.cluster .clusterGroup-container { .cluster .clusterGroup-container {
fill: #f4e0e0; fill: #f4e0e0;
} }
.cluster .clusterGroup-wrapper { .cluster .clusterGroup-wrapper {
fill: #d3f0f6; fill: #d3f0f6;
} }
.cluster .clusterGroup-activation { .cluster .clusterGroup-activation {
fill: #deecef; fill: #deecef;
} }
.cluster .clusterGroup-pool { .cluster .clusterGroup-pool {
fill: #f5d7f0; fill: #f5d7f0;
} }
.cluster .clusterGroup-normalization { .cluster .clusterGroup-normalization {
fill: #f3dfea; fill: #f3dfea;
} }
.cluster .clusterGroup-dropout { .cluster .clusterGroup-dropout {
fill: #c0e1ca; fill: #c0e1ca;
} }
.cluster .clusterGroup-pad { .cluster .clusterGroup-pad {
fill: #c0e1ca; fill: #c0e1ca;
} }
.cluster .clusterGroup-shape { .cluster .clusterGroup-shape {
fill: #f2edd9; fill: #f2edd9;
} }
.cluster .clusterGroup-tensor { .cluster .clusterGroup-tensor {
fill: #d3d7f6; fill: #d3d7f6;
} }
.cluster .clusterGroup-transform { .cluster .clusterGroup-transform {
fill: #f0efd5; fill: #f0efd5;
} }
.cluster .clusterGroup-sequence { .cluster .clusterGroup-sequence {
fill: #f0efd5; fill: #f0efd5;
} }
.cluster .clusterGroup-data { .cluster .clusterGroup-data {
fill: #bdd5e6; fill: #bdd5e6;
} }
.cluster .clusterGroup-custom { .cluster .clusterGroup-custom {
fill: #f6d3d3; fill: #f6d3d3;
} }
.cluster .clusterButton { .cluster .clusterButton {
fill-opacity: 0.3;
fill-opacity: 0;
fill: #db989a; fill: #db989a;
stroke: #999; stroke: #999;
cursor: pointer; cursor: pointer;
} }
.cluster .button-text { .cluster .button-text {
fill: #999; fill: #999;
} }
.cluster.border { .cluster.border {
display: none; display: none;
} }
.select { .select {
&.edge-path { &.edge-path {
stroke: #1527c2; stroke: #1527c2;
stroke-width: 2px; stroke-width: 2px;
stroke-dasharray: 6px 3px; stroke-dasharray: 6px 3px;
stroke-dashoffset: 0; stroke-dashoffset: 0;
animation: pulse 4s infinite linear; animation: pulse 4s infinite linear;
} }
.node.border { .node.border {
stroke: #1527c2; stroke: #1527c2;
stroke-width: 2px; stroke-width: 2px;
stroke-dasharray: 6px 3px; stroke-dasharray: 6px 3px;
stroke-dashoffset: 0; stroke-dashoffset: 0;
animation: pulse 4s infinite linear; animation: pulse 4s infinite linear;
} }
.cluster.border { .cluster.border {
display: block; display: block;
stroke: #1527c2; stroke: #1527c2;
stroke-width: 2px; stroke-width: 2px;
stroke-dasharray: 6px 3px; stroke-dasharray: 6px 3px;
stroke-dashoffset: 0; stroke-dashoffset: 0;
animation: pulse 4s infinite linear; animation: pulse 4s infinite linear;
} }
} }
@keyframes pulse { @keyframes pulse {
from { from {
stroke-dashoffset: 100px; stroke-dashoffset: 100px;
} }
to { to {
stroke-dashoffset: 0; stroke-dashoffset: 0;
} }
} }
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册