mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-04-28 21:39:46 +00:00
Allow additional styles & fixes missed min. width
This commit is contained in:
parent
91975d0b28
commit
d08be4103e
@ -1,6 +1,6 @@
|
||||
@inherits MSGComponentBase
|
||||
|
||||
<div class="@this.Classes" style="flex-grow: 1; overflow: hidden;">
|
||||
<div class="@this.Classes" style="@this.Styles">
|
||||
@if (this.HeaderContent is not null)
|
||||
{
|
||||
<div>
|
||||
|
@ -27,6 +27,9 @@ public partial class InnerScrolling : MSGComponentBase
|
||||
[Parameter]
|
||||
public string? MinWidth { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public string Style { get; set; } = string.Empty;
|
||||
|
||||
[CascadingParameter]
|
||||
private MainLayout MainLayout { get; set; } = null!;
|
||||
|
||||
@ -68,8 +71,12 @@ public partial class InnerScrolling : MSGComponentBase
|
||||
|
||||
private string MinWidthStyle => string.IsNullOrWhiteSpace(this.MinWidth) ? string.Empty : $"min-width: {this.MinWidth}; ";
|
||||
|
||||
private string TerminatedStyles => string.IsNullOrWhiteSpace(this.Style) ? string.Empty : $"{this.Style}; ";
|
||||
|
||||
private string Classes => this.FillEntireHorizontalSpace ? $"{this.Class} d-flex flex-column flex-grow-1" : $"{this.Class} d-flex flex-column";
|
||||
|
||||
private string Styles => $"flex-grow: 1; overflow: hidden; {this.TerminatedStyles}{this.MinWidthStyle}";
|
||||
|
||||
public async Task ScrollToBottom()
|
||||
{
|
||||
await this.AnchorAfterChildContent.ScrollIntoViewAsync(this.JsRuntime);
|
||||
|
Loading…
Reference in New Issue
Block a user