eruda-dom / src /style.scss
soiz1's picture
Upload folder using huggingface_hub
3fe7ea8 verified
@mixin overflow-auto($direction: 'both') {
@if $direction == 'both' {
overflow: auto;
} @else {
overflow-#{$direction}: auto;
}
-webkit-overflow-scrolling: touch;
}
.dom {
padding-bottom: 40px;
.dom-tree {
@include overflow-auto(y);
overflow-x: hidden;
word-wrap: break-word;
padding: 10px 10px 10px 25px;
font-size: 12px;
height: 100%;
font-family: Consolas, Lucida Console, Monaco, MonoSpace;
cursor: default;
& * {
user-select: text;
}
.tree-item {
line-height: 16px;
min-height: 16px;
position: relative;
z-index: 10;
.toggle-btn {
position: absolute;
display: block;
width: 12px;
height: 12px;
left: -12px;
top: 2px;
}
.selection {
position: absolute;
display: none;
left: -10000px;
right: -10000px;
top: 0;
bottom: 0;
z-index: -1;
background: var(--contrast);
}
&.selected {
&.expandable.expanded:before {
border-left-color: transparent;
}
.selection {
display: block;
}
}
.html-tag {
color: var(--tag-name-color);
.tag-name {
color: var(--tag-name-color);
}
.attribute-name {
color: var(--attribute-name-color);
}
.attribute-value {
color: var(--string-color);
&.attribute-underline {
text-decoration: underline;
}
}
}
.html-comment {
color: var(--comment-color);
}
&.expandable:before {
content: '';
width: 0;
height: 0;
border: 4px solid transparent;
position: absolute;
border-left-color: var(--foreground);
left: -10px;
top: 4px;
}
&.expandable.expanded:before {
border-top-color: var(--foreground);
border-left-color: transparent;
left: -12px;
top: 6px;
}
}
.children {
padding-left: 15px;
}
}
.inspect {
position: absolute;
left: 0;
bottom: 0;
color: var(--foreground);
border-top: 1px solid var(--border);
width: 100%;
background: var(--darker-background);
display: block;
height: 40px;
line-height: 40px;
text-decoration: none;
text-align: center;
margin-top: 10px;
transition: background 0.3s;
&:active {
color: var(--select-foreground);
}
}
}