Improved read more design.
This commit is contained in:
parent
1c6a33cd0f
commit
f9a8ac4317
@ -17,7 +17,7 @@ class ReadMore extends IgniteElement {
|
||||
}),
|
||||
collapsed: true,
|
||||
collapsedValue: null,
|
||||
collapseButtonClass: "btn btn-none ps-2 text-primary"
|
||||
collapseButtonClass: "btn btn-none p-0 d-block text-primary"
|
||||
};
|
||||
}
|
||||
|
||||
@ -28,7 +28,7 @@ class ReadMore extends IgniteElement {
|
||||
new button()
|
||||
.show([this.value, this.limit], (value, limit) => value && value.length > limit)
|
||||
.class(this.collapseButtonClass)
|
||||
.innerText(this.collapsed, collapsed => collapsed ? "read more" : "read less")
|
||||
.innerText(this.collapsed, collapsed => collapsed ? "Read more" : "Read less")
|
||||
.onClick(() => this.collapsed = !this.collapsed)
|
||||
)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user