mirror of
https://github.com/garraflavatra/rolens.git
synced 2025-07-18 22:04:05 +00:00
More UI improvements
This commit is contained in:
@ -105,9 +105,9 @@
|
||||
|
||||
<style>
|
||||
.grid {
|
||||
background-color: #fff;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: #fff;
|
||||
}
|
||||
.grid.contained {
|
||||
border: 1px solid #ccc;
|
||||
@ -152,6 +152,8 @@
|
||||
button.toggle {
|
||||
color: inherit;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: contents;
|
||||
}
|
||||
button.toggle :global(svg) {
|
||||
width: 15px;
|
||||
|
@ -28,7 +28,6 @@
|
||||
}
|
||||
else {
|
||||
items = dissectObject(data);
|
||||
console.log(items);
|
||||
}
|
||||
}
|
||||
|
||||
@ -55,11 +54,13 @@
|
||||
}
|
||||
|
||||
function dissectObject(object) {
|
||||
return Object.entries(object).map(([ key, value ]) => {
|
||||
const entries = [ ...Array.isArray(object) ? object.entries() : Object.entries(object) ];
|
||||
return entries.map(([ key, value ]) => {
|
||||
key = key + '';
|
||||
const type = getType(value);
|
||||
const child = { key, value, type };
|
||||
|
||||
if (type.startsWith('object')) {
|
||||
if (type.startsWith('object') || type.startsWith('array')) {
|
||||
child.children = dissectObject(value);
|
||||
}
|
||||
|
||||
|
@ -44,6 +44,7 @@
|
||||
border-bottom: none;
|
||||
border-radius: 5px 5px 0 0;
|
||||
cursor: pointer;
|
||||
background-color: #fff;
|
||||
}
|
||||
.tabs li.active button {
|
||||
color: #fff;
|
||||
|
Reference in New Issue
Block a user