Back to Devexpress

GlobalOptions.SizeMode Property

blazor-devexpress-dot-blazor-dot-configuration-dot-globaloptions.md

latest4.3 KB
Original Source

GlobalOptions.SizeMode Property

Specifies DevExpress Blazor components’ size mode.

Namespace : DevExpress.Blazor.Configuration

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
[DefaultValue(SizeMode.Medium)]
public SizeMode SizeMode { get; set; }

Property Value

TypeDefaultDescription
SizeModeMedium

A SizeMode enumeration value.

|

Available values:

NameDescription
Small

Small size.

| | Medium |

Medium size.

| | Large |

Large size.

|

Remarks

Use the SizeMode global option to specify size mode for Blazor components whose size mode is not defined (set to NULL).

Do any of the following to specify this option:

For additional information, refer to Size Modes.

The following code snippets (auto-collected from DevExpress Examples) contain references to the SizeMode property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

blazor-gridlayout-create-adaptive-dashboard-layout/CS/DxGridLayoutAdaptivity.Wasm/Program.cs#L18

csharp
builder.Services.AddTransient(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) });
builder.Services.AddDevExpressBlazor(configure => configure.SizeMode = DevExpress.Blazor.SizeMode.Small);

blazor-charts-update-chart-data-based-on-grid-focus/CS/Charts/Program.cs#L12

csharp
builder.Services.AddDevExpressBlazor(options => {
    options.SizeMode = DevExpress.Blazor.SizeMode.Medium;
});

blazor-grid-detect-row-editing-cancellation/CS/ShowConfirmationDialog/Program.cs#L12

csharp
builder.Services.AddDevExpressBlazor(options => {
    options.SizeMode = DevExpress.Blazor.SizeMode.Medium;
});

blazor-grid-bind-to-data-with-entity-framework-core/CS/Program.cs#L13

csharp
builder.Services.AddDevExpressBlazor(options => {
    options.SizeMode = DevExpress.Blazor.SizeMode.Medium;
});

blazor-grid-custom-validation/CS/Program.cs#L12

csharp
builder.Services.AddDevExpressBlazor(options => {
    options.SizeMode = DevExpress.Blazor.SizeMode.Medium;
});

See Also

GlobalOptions Class

GlobalOptions Members

DevExpress.Blazor.Configuration Namespace