**AccordionList** ExpanderList BitAccordionList is an advanced version of the BitAccordion that renders a list of expandable items from a single collection and manages their expand/collapse state.
**Basic**:
private readonly List
basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**Multiple**:
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**DefaultExpanded**:
private readonly List keyedItems =
[
new()
{
Key = "general",
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Key = "users",
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Key = "advanced",
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**Events**:
Last expanded: @expandedTitle
Last collapsed: @collapsedTitle
Last toggled: @toggledTitle
Item click count: @clickCounter
private int clickCounter;
private string? expandedTitle;
private string? collapsedTitle;
private string? toggledTitle;
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private List eventsItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
protected override void OnInitialized()
{
foreach (var item in eventsItems)
{
item.OnClick = _ => { clickCounter++; StateHasChanged(); };
}
}
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**ExpandAll & CollapseAll**:
Expand all
Collapse all
private BitAccordionList accordionListRef = default!;
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**Binding**:
Bound expanded key: @boundExpandedKey
private string? boundExpandedKey = "users";
private List bindingButtons =>
[
new() { Key = "general", Text = "General" },
new() { Key = "users", Text = "Users" },
new() { Key = "advanced", Text = "Advanced" },
];
private readonly List keyedItems =
[
new()
{
Key = "general",
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Key = "users",
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Key = "advanced",
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**ExpanderIcon**:
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private readonly List iconItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
ExpanderIconName = BitIconName.Settings,
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
ExpanderIconName = BitIconName.Contact,
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
ExpanderIconName = BitIconName.Ringer,
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**Background & Border**:
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**Templates**:
@item.Title
@item.Description
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**Style & Class**:
private readonly List basicItems =
[
new()
{
Title = "General settings",
Description = "The general settings of the application",
Body = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Title = "Users",
Description = "You are currently not an owner",
Body = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Title = "Advanced settings",
Description = "Filtering has been entirely disabled",
Body = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);
**RTL**:
private readonly List rtlItems =
[
new()
{
Title = "تنظیمات عمومی",
Description = "تنظیمات کلی برنامه",
Body = BodyFor("لورم ایپسوم متن ساختگی با تولید سادگی نامفهوم از صنعت چاپ است.")
},
new()
{
Title = "کاربران",
Description = "شما در حال حاضر مالک نیستید",
Body = BodyFor("لورم ایپسوم متن ساختگی با تولید سادگی نامفهوم از صنعت چاپ است.")
},
];
private static RenderFragment BodyFor(string? text) => item => builder => builder.AddContent(0, text);**Basic**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment
? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**Multiple**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**DefaultExpanded**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List keyedItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**Events**:
Last expanded: @expandedTitle
Last collapsed: @collapsedTitle
Last toggled: @toggledTitle
Item click count: @clickCounter
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private int clickCounter;
private string? expandedTitle;
private string? collapsedTitle;
private string? toggledTitle;
private List eventsItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
protected override void OnInitialized()
{
foreach (var item in eventsItems)
{
item.Clicked = _ => { clickCounter++; StateHasChanged(); };
}
}
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**ExpandAll & CollapseAll**:
Expand all
Collapse all
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private BitAccordionList accordionListRef = default!;
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**Binding**:
Bound expanded key: @boundExpandedKey
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private string? boundExpandedKey = "users";
private List bindingButtons =>
[
new() { Key = "general", Text = "General" },
new() { Key = "users", Text = "Users" },
new() { Key = "advanced", Text = "Advanced" },
];
private readonly List keyedItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**ExpanderIcon**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private readonly List iconItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Image = BitIconName.Settings,
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Image = BitIconName.Contact,
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Image = BitIconName.Ringer,
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**Background & Border**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**Templates**:
@item.Name
@item.Info
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**Style & Class**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List basicItems =
[
new()
{
Id = "general",
Name = "General settings",
Info = "The general settings of the application",
Content = BodyFor("Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.")
},
new()
{
Id = "users",
Name = "Users",
Info = "You are currently not an owner",
Content = BodyFor("Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.")
},
new()
{
Id = "advanced",
Name = "Advanced settings",
Info = "Filtering has been entirely disabled",
Content = BodyFor("In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);
**RTL**:
public class Section
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Info { get; set; }
public bool IsEnabled { get; set; } = true;
public string? Class { get; set; }
public string? Style { get; set; }
public string? Image { get; set; }
public RenderFragment? Content { get; set; }
public Action? Clicked { get; set; }
}
private readonly BitAccordionListNameSelectors nameSelectors = new()
{
Key = { Selector = i => i.Id },
Title = { Selector = i => i.Name },
Description = { Selector = i => i.Info },
IsEnabled = { Selector = i => i.IsEnabled },
ExpanderIconName = { Selector = i => i.Image },
Style = { Selector = i => i.Style },
Class = { Selector = i => i.Class },
OnClick = { Selector = i => i.Clicked },
Body = { Selector = i => i.Content },
};
private readonly List rtlItems =
[
new()
{
Id = "general",
Name = "تنظیمات عمومی",
Info = "تنظیمات کلی برنامه",
Content = BodyFor("لورم ایپسوم متن ساختگی با تولید سادگی نامفهوم از صنعت چاپ است.")
},
new()
{
Id = "users",
Name = "کاربران",
Info = "شما در حال حاضر مالک نیستید",
Content = BodyFor("لورم ایپسوم متن ساختگی با تولید سادگی نامفهوم از صنعت چاپ است.")
},
];
private static RenderFragment BodyFor(string? text) => section => builder => builder.AddContent(0, text);**Basic**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
**Multiple**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
**DefaultExpanded**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
**Events**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Last expanded: @expandedTitle
Last collapsed: @collapsedTitle
Last toggled: @toggledTitle
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Item click count: @clickCounter
private int clickCounter;
private string? expandedTitle;
private string? collapsedTitle;
private string? toggledTitle;
**ExpandAll & CollapseAll**:
Expand all
Collapse all
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
private BitAccordionList
accordionListRef = default!;
**Binding**:
Bound expanded key: @boundExpandedKey
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
private string? boundExpandedKey = "users";
private List bindingButtons =>
[
new() { Key = "general", Text = "General" },
new() { Key = "users", Text = "Users" },
new() { Key = "advanced", Text = "Advanced" },
];
**ExpanderIcon**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
**Background & Border**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
**Templates**:
@option.Title
The general settings of the application
@option.Title
You are currently not an owner
@option.Title
Filtering has been entirely disabled
**Style & Class**:
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
Once upon a time, stories wove connections between people, a symphony of voices crafting shared dreams.
Every story starts with a blank canvas, a quiet space waiting to be filled with ideas, emotions, and dreams.
In the beginning, there is silence a blank canvas yearning to be filled, a quiet space where creativity waits to awaken.
**RTL**:
لورم ایپسوم متن ساختگی با تولید سادگی نامفهوم از صنعت چاپ است.
لورم ایپسوم متن ساختگی با تولید سادگی نامفهوم از صنعت چاپ است.