Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions samples/charts/category-chart/marker-options/App.razor
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
Label="Marker Type"
ShouldOverrideDefaultEditor="true"
ValueType="PropertyEditorValueType.EnumValue"
DropDownValues="@(new string[] { "Circle", "Automatic", "Triangle", "Pyramid", "Square", "Diamond", "Pentagon", "Hexagon", "Tetragram", "Pentagram", "Hexagram", "None" })"
DropDownNames="@(new string[] { "Circle", "Automatic", "Triangle", "Pyramid", "Square", "Diamond", "Pentagon", "Hexagon", "Tetragram", "Pentagram", "Hexagram", "None" })"
DropDownValues="@(new string[] { "Circle", "Checkmark", "Automatic", "Triangle", "Pyramid", "Square", "Diamond", "Pentagon", "Hexagon", "Tetragram", "Pentagram", "Hexagram", "None" })"
DropDownNames="@(new string[] { "Circle", "Checkmark", "Automatic", "Triangle", "Pyramid", "Square", "Diamond", "Pentagon", "Hexagon", "Tetragram", "Pentagram", "Hexagram", "None" })"
PrimitiveValue="@("Circle")"
Changed="EditorChangeUpdateMarkerType">
</IgbPropertyEditorPropertyDescription>
Expand Down
113 changes: 113 additions & 0 deletions samples/charts/data-chart/range-bar-chart/App.razor
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
@using IgniteUI.Blazor.Controls

<div class="container vertical">
<div class="legend-title">
Monthly Temperature Range in LA and NYC
</div>
<div class="legend">
<IgbLegend
Name="legend"
@ref="legend"
Orientation="LegendOrientation.Horizontal">
</IgbLegend>

</div>
<div class="container vertical fill">
<IgbDataChart
Name="chart"
@ref="chart"
IsHorizontalZoomEnabled="false"
IsVerticalZoomEnabled="false">
<IgbCategoryYAxis
Name="yAxis"
@ref="yAxis"
Label="Month"
Interval="1"
DataSource="TemperatureRangeData">
</IgbCategoryYAxis>

<IgbNumericXAxis
Name="xAxis"
@ref="xAxis"
Title="Temperature (in Celsius)"
TitleAngle="0"
TitleTopMargin="10">
</IgbNumericXAxis>

<IgbRangeBarSeries
Name="RangeBarSeries1"
@ref="rangeBarSeries1"
XAxisName="xAxis"
YAxisName="yAxis"
Title="Los Angeles"
LowMemberPath="LowLA"
HighMemberPath="HighLA"
ShowDefaultTooltip="false"
DataSource="TemperatureRangeData">
</IgbRangeBarSeries>

<IgbRangeBarSeries
Name="RangeBarSeries2"
@ref="rangeBarSeries2"
XAxisName="xAxis"
YAxisName="yAxis"
Title="New York"
LowMemberPath="LowNY"
HighMemberPath="HighNY"
ShowDefaultTooltip="false"
DataSource="TemperatureRangeData">
</IgbRangeBarSeries>

<IgbDataToolTipLayer
Name="dataToolTipLayer"
@ref="dataToolTipLayer">
</IgbDataToolTipLayer>

</IgbDataChart>

</div>
</div>

@code {

private Action BindElements { get; set; }

protected override async Task OnAfterRenderAsync(bool firstRender)
{
var legend = this.legend;
var chart = this.chart;
var yAxis = this.yAxis;
var xAxis = this.xAxis;
var rangeBarSeries1 = this.rangeBarSeries1;
var rangeBarSeries2 = this.rangeBarSeries2;
var dataToolTipLayer = this.dataToolTipLayer;

this.BindElements = () => {
chart.Legend = this.legend;
};
this.BindElements();

}

private IgbLegend legend;
private IgbDataChart chart;
private IgbCategoryYAxis yAxis;
private IgbNumericXAxis xAxis;
private IgbRangeBarSeries rangeBarSeries1;
private IgbRangeBarSeries rangeBarSeries2;
private IgbDataToolTipLayer dataToolTipLayer;

private TemperatureRangeData _temperatureRangeData = null;
public TemperatureRangeData TemperatureRangeData
{
get
{
if (_temperatureRangeData == null)
{
_temperatureRangeData = new TemperatureRangeData();
}
return _temperatureRangeData;
}
}

}
21 changes: 21 additions & 0 deletions samples/charts/data-chart/range-bar-chart/BlazorClientApp.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly">

<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<RazorLangVersion>3.0</RazorLangVersion>
<AssemblyName>Infragistics.Samples</AssemblyName>
<RootNamespace>Infragistics.Samples</RootNamespace>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<NoWarn>1701;1702,IDE0028,BL0005,0219,CS1998</NoWarn>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="IgniteUI.Blazor.Trial" Version="25.2.83" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="10.0.1" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="10.0.1" />
<PackageReference Include="System.Net.Http.Json" Version="10.0.1" />
</ItemGroup>

</Project>
25 changes: 25 additions & 0 deletions samples/charts/data-chart/range-bar-chart/BlazorClientApp.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29613.14
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BlazorClientApp", "BlazorClientApp.csproj", "{F69CC3F0-BCD1-4CE6-9F39-CBED14E7FA78}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{F69CC3F0-BCD1-4CE6-9F39-CBED14E7FA78}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F69CC3F0-BCD1-4CE6-9F39-CBED14E7FA78}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F69CC3F0-BCD1-4CE6-9F39-CBED14E7FA78}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F69CC3F0-BCD1-4CE6-9F39-CBED14E7FA78}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {FC52AAC8-4488-40AE-9621-75F6BA744B18}
EndGlobalSection
EndGlobal
32 changes: 32 additions & 0 deletions samples/charts/data-chart/range-bar-chart/Program.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
using System;
using System.Net.Http;
using System.Collections.Generic;
using System.Threading.Tasks;
using System.Text;
using Microsoft.AspNetCore.Components.WebAssembly.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using IgniteUI.Blazor.Controls; // for registering Ignite UI modules

namespace Infragistics.Samples
{
public class Program
{
public static async Task Main(string[] args)
{
var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("app");
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) });
// registering Ignite UI modules
builder.Services.AddIgniteUIBlazor(
typeof(IgbDataChartCoreModule),
typeof(IgbDataChartCategoryModule),
typeof(IgbDataChartInteractivityModule),
typeof(IgbDataChartAnnotationModule),
typeof(IgbLegendModule)
);
await builder.Build().RunAsync();
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:4200",
"sslPort": 44385
}
},
"profiles": {
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"BlazorSamples": {
"commandName": "Project",
"launchBrowser": true,
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"applicationUrl": "https://localhost:5001;http://localhost:4200"
}
}
}
30 changes: 30 additions & 0 deletions samples/charts/data-chart/range-bar-chart/TemperatureRangeData.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
using System;
using System.Collections.Generic;
public class TemperatureRangeDataItem
{
public string Month { get; set; }
public double HighNY { get; set; }
public double LowNY { get; set; }
public double HighLA { get; set; }
public double LowLA { get; set; }
}

public class TemperatureRangeData
: List<TemperatureRangeDataItem>
{
public TemperatureRangeData()
{
this.Add(new TemperatureRangeDataItem() { Month = @"Jan", HighNY = 10.6, LowNY = -6.6, HighLA = 28.3, LowLA = 7.8 });
this.Add(new TemperatureRangeDataItem() { Month = @"Feb", HighNY = 7.8, LowNY = -9.9, HighLA = 31.1, LowLA = 5.6 });
this.Add(new TemperatureRangeDataItem() { Month = @"Mar", HighNY = 12.2, LowNY = -3.8, HighLA = 27.8, LowLA = 8.3 });
this.Add(new TemperatureRangeDataItem() { Month = @"Apr", HighNY = 11.7, LowNY = 2.2, HighLA = 33.9, LowLA = 10.6 });
this.Add(new TemperatureRangeDataItem() { Month = @"May", HighNY = 19.4, LowNY = 1.1, HighLA = 35, LowLA = 13.9 });
this.Add(new TemperatureRangeDataItem() { Month = @"Jun", HighNY = 23.3, LowNY = 10.6, HighLA = 36.7, LowLA = 16.1 });
this.Add(new TemperatureRangeDataItem() { Month = @"Jul", HighNY = 27.2, LowNY = 19.4, HighLA = 33.3, LowLA = 15.6 });
this.Add(new TemperatureRangeDataItem() { Month = @"Aug", HighNY = 25.6, LowNY = 16.7, HighLA = 36.7, LowLA = 15.6 });
this.Add(new TemperatureRangeDataItem() { Month = @"Sep", HighNY = 22.8, LowNY = 8.9, HighLA = 43.9, LowLA = 16.1 });
this.Add(new TemperatureRangeDataItem() { Month = @"Oct", HighNY = 17.8, LowNY = 0, HighLA = 38.3, LowLA = 11.1 });
this.Add(new TemperatureRangeDataItem() { Month = @"Nov", HighNY = 17.8, LowNY = -1, HighLA = 32.8, LowLA = 6.7 });
this.Add(new TemperatureRangeDataItem() { Month = @"Dec", HighNY = 8.3, LowNY = -6.6, HighLA = 28.9, LowLA = 5.6 });
}
}
9 changes: 9 additions & 0 deletions samples/charts/data-chart/range-bar-chart/_Imports.razor
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
// these namespaces are global to the app
@using System.Net.Http
@using System.Net.Http.Json
@using Microsoft.AspNetCore.Components.Forms
@using Microsoft.AspNetCore.Components.Routing
@using Microsoft.AspNetCore.Components.Web
@using Microsoft.AspNetCore.Components.WebAssembly.Http
@using Microsoft.JSInterop
@using Infragistics.Samples
4 changes: 4 additions & 0 deletions samples/charts/data-chart/range-bar-chart/wwwroot/index.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/*
CSS styles are loaded from the shared CSS file located at:
https://dl.infragistics.com/x/css/samples/shared.v6.css
*/
30 changes: 30 additions & 0 deletions samples/charts/data-chart/range-bar-chart/wwwroot/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<!DOCTYPE html>
<html>

<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<meta name="description" content="Explore samples of IgniteUI for Blazor components.">
<meta name="keywords" content="Sample, Example, Blazor, IgniteUI for Blazor, Components, Infragistics">
<meta name="author" content="Infragistics">
<title>Samples | IgniteUI for Blazor | Infragistics</title>
<base href="/" />
<link href="https://dl.infragistics.com/x/img/browsers/blazor.ico" rel="icon" type="image/x-icon">
<link href="https://dl.infragistics.com/x/css/samples/shared.v6.css" rel="stylesheet" />
<link href="https://dl.infragistics.com/x/css/samples/blazor.css" rel="stylesheet" />
<link href="index.css" rel="stylesheet" />
</head>

<body>
<app class="app"><img class="app-loading" src="https://dl.infragistics.com/x/img/browsers/loading.gif" /></app>
<div class="app-error-ui">
An unhandled error has occurred.
<a href="" class="reload">Reload</a>
<a class="app-error-dismiss">🗙</a>
</div>
<!-- importing blazor bundle for IG controls: -->
<script src="_content/IgniteUI.Blazor/app.bundle.js"></script>
<script src="_framework/blazor.webassembly.js"></script>
</body>

</html>
Loading