Small styling tweaks
This commit is contained in:
parent
c2f79570b7
commit
cd09efca94
2 changed files with 5 additions and 4 deletions
|
@ -27,7 +27,7 @@ export default class Toggleable extends Combine {
|
|||
|
||||
constructor(title: Title | BaseUIElement, content: BaseUIElement) {
|
||||
super([title, content])
|
||||
content.SetClass("animate-height border-l-4 pl-2")
|
||||
content.SetClass("animate-height border-l-4 pl-2 block")
|
||||
title.SetClass("background-subtle rounded-lg")
|
||||
const self = this
|
||||
this.onClick(() => self.isVisible.setData(!self.isVisible.data))
|
||||
|
@ -53,7 +53,8 @@ export default class Toggleable extends Combine {
|
|||
|
||||
this.isVisible.addCallbackAndRun(isVisible => {
|
||||
if (isVisible) {
|
||||
contentElement.style.maxHeight = "100vh"
|
||||
contentElement.style.maxHeight = "8gs0vh"
|
||||
contentElement.style.overflowY = "auto"
|
||||
contentElement.style["-webkit-mask-image"] = "unset"
|
||||
} else {
|
||||
contentElement.style["-webkit-mask-image"] = "-webkit-gradient(linear, left top, left bottom, from(rgba(0,0,0,1)), to(rgba(0,0,0,0)))"
|
||||
|
|
|
@ -54,7 +54,7 @@ export class PreviewPanel extends Combine implements FlowStep<{ features: { prop
|
|||
}
|
||||
|
||||
const uniqueCount = new Set(values).size
|
||||
if (uniqueCount !== values.length) {
|
||||
if (uniqueCount !== values.length && uniqueCount < 15) {
|
||||
attributeOverview.push()
|
||||
// There are some overlapping values: histogram time!
|
||||
let hist: BaseUIElement =
|
||||
|
@ -84,7 +84,7 @@ export class PreviewPanel extends Combine implements FlowStep<{ features: { prop
|
|||
continue
|
||||
}
|
||||
|
||||
// All values are different, we add a boring (but collapsable) list
|
||||
// All values are different or too much unique values, we add a boring (but collapsable) list
|
||||
attributeOverview.push(new Toggleable(
|
||||
new Title(key + "=*"),
|
||||
new Combine([
|
||||
|
|
Loading…
Reference in a new issue