Add BlueWest.Frontend as submodule

This commit is contained in:
CodeLiturgy 2022-08-20 03:47:32 +01:00
parent 3a66d08ddc
commit b13a5ac392
34 changed files with 233 additions and 1622 deletions

3
.gitmodules vendored
View File

@ -4,3 +4,6 @@
[submodule "include/Math-Expression-Evaluator"] [submodule "include/Math-Expression-Evaluator"]
path = include/Math-Expression-Evaluator path = include/Math-Expression-Evaluator
url = git@git.codeliturgy.com:CodeLiturgy/Math-Expression-Evaluator.git url = git@git.codeliturgy.com:CodeLiturgy/Math-Expression-Evaluator.git
[submodule "BlueWest.Frontend"]
path = BlueWest.Frontend
url = git@git.codeliturgy.com:P0/BlueWest.Frontend.git

View File

@ -25,8 +25,4 @@
</ItemGroup> </ItemGroup>
<ItemGroup>
<Folder Include="Startup" />
</ItemGroup>
</Project> </Project>

View File

@ -1,20 +1,20 @@
using BlueWest.Data; using BlueWest.Data;
using BlueWest.WebApi.MySQL.Model;
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Configuration;
namespace BlueWest.WebApi.MySQL; namespace BlueWest.WebApi.MySQL
/// <summary>
/// Countries and Currencies
/// </summary>
public class CountryDbContext : DbContext
{ {
/// <summary>
/// Countries and Currencies
/// </summary>
public sealed class CountryDbContext : DbContext
{
public DbSet<Country> Countries { get; set; } public DbSet<Country> Countries { get; set; }
public DbSet<Currency> Currencies { get; set; } public DbSet<Currency> Currencies { get; set; }
public DbSet<User> Users { get; set; }
public IConfiguration Configuration; public IConfiguration Configuration;
@ -29,14 +29,6 @@ public class CountryDbContext : DbContext
} }
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
/*optionsBuilder.UseMySql(
Configuration.GetConnectionString("LocalMySQL"),
new MySqlServerVersion(new Version(8, 0, 11))
);*/
}
/// <summary> /// <summary>
/// The country number is the primary key /// The country number is the primary key
/// The currency code is the primary key /// The currency code is the primary key
@ -45,6 +37,7 @@ public class CountryDbContext : DbContext
protected override void OnModelCreating(ModelBuilder modelBuilder) protected override void OnModelCreating(ModelBuilder modelBuilder)
{ {
base.OnModelCreating(modelBuilder); base.OnModelCreating(modelBuilder);
modelBuilder.ProjectDatabaseModel(); modelBuilder.ConfigureCurrentDbModel();
}
} }
} }

View File

@ -1,4 +1,5 @@
using BlueWest.Data; using BlueWest.Data;
using BlueWest.WebApi.MySQL.Model;
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
namespace BlueWest.WebApi.MySQL namespace BlueWest.WebApi.MySQL
@ -6,9 +7,10 @@ namespace BlueWest.WebApi.MySQL
/// <summary> /// <summary>
/// Finance operations table /// Finance operations table
/// </summary> /// </summary>
public class FinanceDbContext : DbContext public sealed class FinanceDbContext : DbContext
{ {
public DbSet<FinanceOp> Transactions { get; set; } public DbSet<FinanceOp> Transactions { get; set; }
public DbSet<FinanceOpType> TransactionTypes { get; set; } public DbSet<FinanceOpType> TransactionTypes { get; set; }
/// <summary> /// <summary>
@ -23,7 +25,7 @@ namespace BlueWest.WebApi.MySQL
protected override void OnModelCreating(ModelBuilder modelBuilder) protected override void OnModelCreating(ModelBuilder modelBuilder)
{ {
base.OnModelCreating(modelBuilder); base.OnModelCreating(modelBuilder);
modelBuilder.ProjectDatabaseModel(); modelBuilder.ConfigureCurrentDbModel();
} }
} }
} }

View File

@ -6,15 +6,18 @@ using BlueWest.WebApi.MySQL;
namespace BlueWest.WebApi.Interfaces namespace BlueWest.WebApi.Interfaces
{ {
public struct ExchangeEvent { } public struct ExchangeEvent { }
public class ExchangeInterface : EventListener<ExchangeEvent>, IDisposable, IAsyncDisposable /// <summary>
/// Interface for getting and storing exchange rates data
/// </summary>
///
public sealed class ExchangeInterface : EventListener<ExchangeEvent>, IDisposable, IAsyncDisposable
{ {
private readonly EventManager _eventManager; private readonly EventManager _eventManager;
private readonly CountryDbContext _countryDbContext; private readonly CountryDbContext _countryDbContext;
private readonly FinanceDbContext _financeDbContext; private readonly FinanceDbContext _financeDbContext;
private readonly UserDbContext _userDbContext; private readonly UserDbContext _userDbContext;
#region Initialization
public ExchangeInterface( public ExchangeInterface(
CountryDbContext countryDbContext, CountryDbContext countryDbContext,
FinanceDbContext financeDbContext, FinanceDbContext financeDbContext,
@ -33,11 +36,15 @@ namespace BlueWest.WebApi.Interfaces
private void Init() private void Init()
{ {
_eventManager.EventStartListening<ExchangeEvent>(this); _eventManager.EventStartListening<ExchangeEvent>(this);
_eventManager.TriggerEvent<ExchangeEvent>(new ExchangeEvent());
Console.WriteLine($"{nameof(ExchangeInterface)} Just started!"); Console.WriteLine($"{nameof(ExchangeInterface)} Just started!");
} }
#endregion
/// <summary>
/// On Exchange Event
/// </summary>
/// <param name="eventType"></param>
public void OnEvent(ExchangeEvent eventType) public void OnEvent(ExchangeEvent eventType)
{ {
Console.WriteLine($"Service received exchange {nameof(ExchangeEvent)}"); Console.WriteLine($"Service received exchange {nameof(ExchangeEvent)}");

View File

@ -1,63 +0,0 @@
using BlueWest.Data;
using Microsoft.EntityFrameworkCore;
namespace BlueWest.WebApi.MySQL
{
public static class ModelBuilderExtensions
{
public static void ProjectDatabaseModel(this ModelBuilder modelBuilder)
{
// Keys
CountryCurrencyModel(modelBuilder);
UserModel(modelBuilder);
}
private static void CountryCurrencyModel(ModelBuilder modelBuilder)
{
modelBuilder.Entity<Country>(builder =>
{
builder.HasKey(x => x.Code);
});
modelBuilder.Entity<Currency>(builder =>
{
builder.HasKey(x => x.Num);
});
// Relationships
modelBuilder.Entity<Currency>()
.HasMany(ub => ub.Countries)
.WithMany(au => au.Currencies);
modelBuilder.Entity<Country>()
.HasMany(ub => ub.Currencies)
.WithMany(au => au.Countries);
}
private static ModelBuilder UserModel(ModelBuilder modelBuilder)
{
modelBuilder
.Entity<User>(builder => builder
.HasOne<Country>()
.WithMany(co => co.Users));
modelBuilder.Entity<Country>(builder => builder
.HasMany<User>()
.WithOne(co => co.Country)
.HasForeignKey(x => x.CountryId));
modelBuilder.Entity<FinanceOp>(builder =>
{
builder.HasOne<User>()
.WithMany(x => x.FinanceTransactions)
.HasForeignKey(x => x.UserId);
});
return modelBuilder;
}
}
}

View File

@ -1,12 +1,12 @@
using System;
using BlueWest.Data; using BlueWest.Data;
using BlueWest.WebApi.MySQL.Model;
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Configuration;
namespace BlueWest.WebApi.MySQL namespace BlueWest.WebApi.MySQL
{ {
public class UserDbContext : DbContext public sealed class UserDbContext : DbContext
{ {
public DbSet<User> Users { get; set; } public DbSet<User> Users { get; set; }
@ -34,7 +34,7 @@ namespace BlueWest.WebApi.MySQL
protected override void OnModelCreating(ModelBuilder modelBuilder) protected override void OnModelCreating(ModelBuilder modelBuilder)
{ {
base.OnModelCreating(modelBuilder); base.OnModelCreating(modelBuilder);
modelBuilder.ProjectDatabaseModel(); modelBuilder.ConfigureCurrentDbModel();
} }
} }
} }

View File

@ -71,7 +71,7 @@ namespace BlueWest.WebApi.Controllers
if (country != null) if (country != null)
{ {
var updatedCountry = new Country(countryToUpdate, countryCode, null, null); var updatedCountry = new Country(countryToUpdate, countryCode, country.Currencies, country.Users);
_dbContext.Countries.Update(updatedCountry); _dbContext.Countries.Update(updatedCountry);
return Ok(updatedCountry); return Ok(updatedCountry);
} }

View File

@ -17,6 +17,7 @@ namespace BlueWest.WebApi.Controllers
{ {
private readonly CountryDbContext _dbContext; private readonly CountryDbContext _dbContext;
public CurrencyController(CountryDbContext dbContext) public CurrencyController(CountryDbContext dbContext)
{ {
_dbContext = dbContext; _dbContext = dbContext;

View File

@ -0,0 +1,92 @@
using BlueWest.Data;
using Microsoft.EntityFrameworkCore;
namespace BlueWest.WebApi.MySQL.Model
{
/// <summary>
/// Database model configuration extensions
/// </summary>
public static class ModelBuilderExtensions
{
/// <summary>
/// Setup the database model
/// </summary>
/// <param name="modelBuilder"></param>
public static void ConfigureCurrentDbModel(this ModelBuilder modelBuilder)
{
modelBuilder
.ConfigureDatabaseKeys()
.CountryCurrencyModel()
.ConfigureUserModel();
}
private static ModelBuilder ConfigureDatabaseKeys(this ModelBuilder modelBuilder)
{
// User PK
modelBuilder.Entity<User>(builder => builder
.HasKey(user => user.Id));
// Country PK
modelBuilder.Entity<Country>(builder => builder
.HasKey(country => country.Code));
// Currency PK
modelBuilder.Entity<Currency>(builder => builder
.HasKey(currency => currency.Num));
// FinanceOp PK
return
modelBuilder.Entity<FinanceOp>(builder => builder
.HasKey(financeOp => financeOp.Id));
}
private static ModelBuilder CountryCurrencyModel(this ModelBuilder modelBuilder)
{
// Relationships
modelBuilder
.Entity<Currency>()
.HasMany(ub => ub.Countries)
.WithMany(au => au.Currencies);
modelBuilder.Entity<Country>()
.HasMany(ub => ub.Currencies)
.WithMany(au => au.Countries);
return modelBuilder;
}
private static ModelBuilder ConfigureUserModel(this ModelBuilder modelBuilder)
{
// User => Country
modelBuilder
.Entity<User>(builder => builder
.HasOne<Country>()
.WithMany(co => co.Users));
// Country => User
modelBuilder
.Entity<Country>(builder => builder
.HasMany<User>()
.WithOne(u => u.Country)
.HasForeignKey(x => x.CountryId));
// FinanceOp => User
modelBuilder
.Entity<FinanceOp>(builder => builder
.HasOne<User>()
.WithMany(ft => ft.FinanceTransactions)
.HasForeignKey(x => x.UserId));
return modelBuilder;
}
}
}

View File

@ -19,13 +19,15 @@ namespace BlueWest.WebApi
/// </summary> /// </summary>
/// <param name="optionsBuilder"></param> /// <param name="optionsBuilder"></param>
/// <param name="configuration"></param> /// <param name="configuration"></param>
public static void GetMySqlSettings( /// <param name="environment"></param>
private static DbContextOptionsBuilder GetMySqlSettings(
this DbContextOptionsBuilder optionsBuilder, this DbContextOptionsBuilder optionsBuilder,
IConfiguration configuration, IConfiguration configuration,
IWebHostEnvironment environment) IWebHostEnvironment environment)
{ {
var optionsBuilderRef = optionsBuilder.UseMySql(configuration.GetConnectionString("LocalMySQL"), var optionsBuilderRef = optionsBuilder.UseMySql(configuration.GetConnectionString("LocalMySQL"),
new MySqlServerVersion(new Version(8, 0, 11))); new MySqlServerVersion(new Version(8, 0, 11)));
// The following three options help with debugging, but should // The following three options help with debugging, but should
// be changed or removed for production. // be changed or removed for production.
if (environment.IsDevelopment()) if (environment.IsDevelopment())
@ -35,6 +37,8 @@ namespace BlueWest.WebApi
.EnableSensitiveDataLogging() .EnableSensitiveDataLogging()
.EnableDetailedErrors(); .EnableDetailedErrors();
} }
return optionsBuilderRef;
} }
/// <summary> /// <summary>
@ -42,13 +46,15 @@ namespace BlueWest.WebApi
/// </summary> /// </summary>
/// <param name="serviceCollection"></param> /// <param name="serviceCollection"></param>
/// <param name="configuration"></param> /// <param name="configuration"></param>
/// <param name="environment"></param>
/// <returns></returns> /// <returns></returns>
public static IServiceCollection PrepareDatabasePool(this IServiceCollection serviceCollection, public static IServiceCollection PrepareDatabasePool(this IServiceCollection serviceCollection,
IConfiguration configuration, IWebHostEnvironment environment) IConfiguration configuration, IWebHostEnvironment environment)
{ {
return serviceCollection return serviceCollection
.AddDbContextPool<CountryDbContext>(options => options.GetMySqlSettings(configuration, environment))
.AddDbContextPool<UserDbContext>(options => options.GetMySqlSettings(configuration, environment)) .AddDbContextPool<UserDbContext>(options => options.GetMySqlSettings(configuration, environment))
.AddDbContextPool<CountryDbContext>(options => options.GetMySqlSettings(configuration, environment))
.AddDbContextPool<FinanceDbContext>(options => options.GetMySqlSettings(configuration, environment)); .AddDbContextPool<FinanceDbContext>(options => options.GetMySqlSettings(configuration, environment));
} }
} }

View File

@ -0,0 +1,46 @@
using System;
using System.IO;
using System.Reflection;
using BlueWest.WebApi.Tools;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.OpenApi.Models;
using Swashbuckle.AspNetCore.SwaggerGen;
namespace BlueWest.WebApi.Extensions
{
public static class SwaggerExtensions
{
/// <summary>
/// Swagger documentation provider options
/// </summary>
/// <param name="swaggerGenOptions"></param>
public static void ConfigureSwaggerOptions(this SwaggerGenOptions swaggerGenOptions)
{
swaggerGenOptions.SchemaFilter<SwaggerEnumSchemaFilter>();
swaggerGenOptions.SwaggerDoc("v1", new OpenApiInfo
{
Title = "BlueWest.Api.App",
Version = "v1",
Description = "BlueWest.Api.App",
TermsOfService = new Uri("https://git.codeliturgy.com/terms-of-service"),
Contact = new OpenApiContact
{
Name = "Benny",
Email = string.Empty,
Url = new Uri("https://git.codeliturgy.com"),
},
License = new OpenApiLicense
{
Name = "Use under LICX",
Url = new Uri("https://git.codeliturgy.com/license"),
}
});
// Set the comments path for the Swagger JSON and UI.
var xmlFile = $"{Assembly.GetExecutingAssembly().GetName().Name}.xml";
var xmlPath = Path.Combine(AppContext.BaseDirectory, xmlFile);
swaggerGenOptions.IncludeXmlComments(xmlPath);
}
}
}

View File

@ -15,6 +15,9 @@ namespace BlueWest.WebApi
{ {
public class Program public class Program
{ {
/// <summary>
/// Event Manager class
/// </summary>
public static EventManager EventManager { get; set; } public static EventManager EventManager { get; set; }
private static ThreadServer _threadServer; private static ThreadServer _threadServer;
@ -43,25 +46,8 @@ namespace BlueWest.WebApi
var tryGetEventManager = Host1.Services.GetService(typeof(EventManager)); var tryGetEventManager = Host1.Services.GetService(typeof(EventManager));
try
{
_ = Host1.Services.GetService(typeof(ExchangeInterface)); _ = Host1.Services.GetService(typeof(ExchangeInterface));
}
catch (Exception e)
{
if (e is InvalidOperationException exception)
{
if (e.Source == "Pomelo.EntityFrameworkCore.MySql")
{
throw new InvalidOperationException("MySQL Error");
}
}
throw;
}
if(tryGetEventManager == null) Console.WriteLine($"Failed to get {nameof(EventManager)} Service."); if(tryGetEventManager == null) Console.WriteLine($"Failed to get {nameof(EventManager)} Service.");

View File

@ -1,43 +1,29 @@
using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting; using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.HttpsPolicy;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Logging;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Text.Json.Serialization; using System.Text.Json.Serialization;
using System.Threading.Tasks;
using BlueWest.Tools; using BlueWest.Tools;
using BlueWest.WebApi.Extensions;
using BlueWest.WebApi.Interfaces; using BlueWest.WebApi.Interfaces;
using BlueWest.WebApi.MySQL;
using BlueWest.WebApi.Tools;
using Microsoft.EntityFrameworkCore;
using Microsoft.OpenApi.Models;
namespace BlueWest.WebApi namespace BlueWest.WebApi
{ {
/// <summary>
/// Startup class for the API.
/// </summary>
public class Startup public class Startup
{ {
private readonly IConfiguration _configuration;
public IConfiguration Configuration { get; }
private readonly IWebHostEnvironment _environment; private readonly IWebHostEnvironment _environment;
private readonly string MyAllowSpecificOrigins = "_myAllowSpecificOrigins"; private readonly string MyAllowSpecificOrigins = "_myAllowSpecificOrigins";
/// <summary> /// <summary>
/// Startup configuration of the API /// Startup configuration of the API
/// </summary> /// </summary>
public Startup(IConfiguration configuration, IWebHostEnvironment hostEnvironment) public Startup(IConfiguration configuration, IWebHostEnvironment hostEnvironment)
{ {
Configuration = configuration; _configuration = configuration;
_environment = hostEnvironment; _environment = hostEnvironment;
} }
@ -59,56 +45,26 @@ namespace BlueWest.WebApi
});*/ });*/
}); });
services.AddControllers() services
.AddJsonOptions(options => .AddControllers()
{ .AddJsonOptions(options => options.JsonSerializerOptions.ReferenceHandler = ReferenceHandler.Preserve);
options.JsonSerializerOptions.ReferenceHandler = ReferenceHandler.Preserve;
});
/*services
.AddNewtonsoftJson(options =>
options.SerializerSettings.Converters.Add(new StringEnumConverter()));
// order is vital, this *must* be called *after* AddNewtonsoftJson()
services.AddSwaggerGenNewtonsoftSupport();*/
services.AddSwaggerGen(options =>
{
options.SchemaFilter<SwaggerEnumSchemaFilter>();
options.SwaggerDoc("v1", new OpenApiInfo
{
Title = "BlueWest.Api Documentation",
Version = "v1",
Description = "A simple example ASP.NET Core Web API",
TermsOfService = new Uri("https://example.com/terms"),
Contact = new OpenApiContact
{
Name = "Benny",
Email = string.Empty,
Url = new Uri("https://git.codeliturgy.com"),
},
License = new OpenApiLicense
{
Name = "Use under LICX",
Url = new Uri("https://git.codeliturgy.com/license"),
}
});
// Set the comments path for the Swagger JSON and UI.
var xmlFile = $"{Assembly.GetExecutingAssembly().GetName().Name}.xml";
var xmlPath = Path.Combine(AppContext.BaseDirectory, xmlFile);
options.IncludeXmlComments(xmlPath);
});
services
.AddSwaggerGen(options => options.ConfigureSwaggerOptions());
services services
.AddSingleton<EventManager>() .AddSingleton<EventManager>()
.PrepareDatabasePool(Configuration, _environment) .PrepareDatabasePool(_configuration, _environment)
.AddSingleton<ExchangeInterface>(); .AddScoped<ExchangeInterface>();
// services.AddGrpc(); // services.AddGrpc();
} }
/// <summary>
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. /// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
/// </summary>
/// <param name="app">Object with the necessary data to configure an application's request pipeline</param>
/// <param name="env">Provides information about the web hosting environment an application is running in.</param>
public void Configure(IApplicationBuilder app, IWebHostEnvironment env) public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{ {
@ -120,21 +76,17 @@ namespace BlueWest.WebApi
{ {
c.RoutePrefix = "swagger"; c.RoutePrefix = "swagger";
c.SwaggerEndpoint("/swagger/v1/swagger.json", "BlueWest.Api v1"); c.SwaggerEndpoint("/swagger/v1/swagger.json", "BlueWest.Api v1");
}); });
//app.UseHttpsRedirection(); //app.UseHttpsRedirection();
app.UseRouting(); app.UseRouting();
app.UseCors(MyAllowSpecificOrigins); app.UseCors(MyAllowSpecificOrigins);
app.UseAuthorization(); app.UseAuthorization();
app.UseEndpoints(endpoints => app.UseEndpoints(endpoints =>
{ {
endpoints.MapControllers(); endpoints.MapControllers();
// endpoints.MapGrpcService<GreeterService>(); // endpoints.MapGrpcService<GreeterService>();
}); });
} }
} }

View File

@ -1,4 +1,5 @@
using System; using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using MapTo; using MapTo;
@ -9,9 +10,10 @@ namespace BlueWest.Data
{ {
public int UserId { get; set; } public int UserId { get; set; }
[Key] public TimeSpan CreationDate { get; set; } [Key] public int Id;
public TimeSpan CreationDate { get; set; }
public Currency Currency { get; } [Required] public Currency Currency { get; }
public FinanceOpType Type {get;} public FinanceOpType Type {get;}

View File

@ -7,9 +7,7 @@ using MapTo;
namespace BlueWest.Data namespace BlueWest.Data
{ {
[MapFrom( typeof(UserCreate))] [MapFrom( typeof(UserCreate))]
/*
[UseUpdate] [UseUpdate]
*/
public partial class User public partial class User
{ {
public int Id { get; set; } public int Id { get; set; }
@ -19,7 +17,7 @@ namespace BlueWest.Data
public Country Country { get; set; } public Country Country { get; set; }
[ForeignKey("Country")] [ForeignKey("Countries")]
public int CountryId { get; set; } public int CountryId { get; set; }
public User(int id, string name) public User(int id, string name)

1
BlueWest.Frontend Submodule

@ -0,0 +1 @@
Subproject commit 8f656cbcc1c5782b1c5983600568704b6244b1ef

View File

@ -1,6 +0,0 @@
.DS_Store
node_modules
/build
/.svelte-kit
/package
.env

View File

@ -1,38 +0,0 @@
# create-svelte
Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/master/packages/create-svelte);
## Creating a project
If you're seeing this, you've probably already done this step. Congrats!
```bash
# create a new project in the current directory
npm init svelte@next
# create a new project in my-app
npm init svelte@next my-app
```
> Note: the `@next` is temporary
## Developing
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
```bash
npm run dev
# or start the server and open the app in a new browser tab
npm run dev -- --open
```
## Building
Before creating a production version of your app, install an [adapter](https://kit.svelte.dev/docs#adapters) for your target environment. Then:
```bash
npm run build
```
> You can preview the built app with `npm run preview`, regardless of whether you installed an adapter. This should _not_ be used to serve your app in production.

View File

@ -1,10 +0,0 @@
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"$lib": ["src/lib"],
"$lib/*": ["src/lib/*"]
}
},
"include": ["src/**/*.d.ts", "src/**/*.js", "src/**/*.svelte"]
}

View File

@ -1,987 +0,0 @@
{
"name": "bluewest.frontend",
"version": "0.0.1",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "bluewest.frontend",
"version": "0.0.1",
"dependencies": {
"klinecharts": "^8.1.0"
},
"devDependencies": {
"@sveltejs/kit": "next",
"svelte": "^3.42.6"
}
},
"node_modules/@rollup/pluginutils": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-4.1.1.tgz",
"integrity": "sha512-clDjivHqWGXi7u+0d2r2sBi4Ie6VLEAzWMIkvJLnDmxoOhBYOTfzGbOQBA32THHm11/LiJbd01tJUpJsbshSWQ==",
"dev": true,
"dependencies": {
"estree-walker": "^2.0.1",
"picomatch": "^2.2.2"
},
"engines": {
"node": ">= 8.0.0"
}
},
"node_modules/@sveltejs/kit": {
"version": "1.0.0-next.198",
"resolved": "https://registry.npmjs.org/@sveltejs/kit/-/kit-1.0.0-next.198.tgz",
"integrity": "sha512-BgXVrCOn0sYNAvmSIXxfztntGzb4ZhaO3KSmJzkSeQQg20+aQGqyOJnhTQ+wDX+YhyKURxVOhjTWHjeO6d7gdw==",
"dev": true,
"dependencies": {
"@sveltejs/vite-plugin-svelte": "^1.0.0-next.30",
"cheap-watch": "^1.0.4",
"sade": "^1.7.4",
"vite": "^2.6.12"
},
"bin": {
"svelte-kit": "svelte-kit.js"
},
"engines": {
"node": ">=14.13"
},
"peerDependencies": {
"svelte": "^3.44.0"
}
},
"node_modules/@sveltejs/vite-plugin-svelte": {
"version": "1.0.0-next.30",
"resolved": "https://registry.npmjs.org/@sveltejs/vite-plugin-svelte/-/vite-plugin-svelte-1.0.0-next.30.tgz",
"integrity": "sha512-YQqdMxjL1VgSFk4/+IY3yLwuRRapPafPiZTiaGEq1psbJYSNYUWx9F1zMm32GMsnogg3zn99mGJOqe3ld3HZSg==",
"dev": true,
"dependencies": {
"@rollup/pluginutils": "^4.1.1",
"debug": "^4.3.2",
"kleur": "^4.1.4",
"magic-string": "^0.25.7",
"require-relative": "^0.8.7",
"svelte-hmr": "^0.14.7"
},
"engines": {
"node": "^14.13.1 || >= 16"
},
"peerDependencies": {
"diff-match-patch": "^1.0.5",
"svelte": "^3.44.0",
"vite": "^2.6.0"
},
"peerDependenciesMeta": {
"diff-match-patch": {
"optional": true
}
}
},
"node_modules/cheap-watch": {
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/cheap-watch/-/cheap-watch-1.0.4.tgz",
"integrity": "sha512-QR/9FrtRL5fjfUJBhAKCdi0lSRQ3rVRRum3GF9wDKp2TJbEIMGhUEr2yU8lORzm9Isdjx7/k9S0DFDx+z5VGtw==",
"dev": true,
"engines": {
"node": ">=8"
}
},
"node_modules/debug": {
"version": "4.3.2",
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.2.tgz",
"integrity": "sha512-mOp8wKcvj7XxC78zLgw/ZA+6TSgkoE2C/ienthhRD298T7UNwAg9diBpLRxC0mOezLl4B0xV7M0cCO6P/O0Xhw==",
"dev": true,
"dependencies": {
"ms": "2.1.2"
},
"engines": {
"node": ">=6.0"
},
"peerDependenciesMeta": {
"supports-color": {
"optional": true
}
}
},
"node_modules/esbuild": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.13.15.tgz",
"integrity": "sha512-raCxt02HBKv8RJxE8vkTSCXGIyKHdEdGfUmiYb8wnabnaEmHzyW7DCHb5tEN0xU8ryqg5xw54mcwnYkC4x3AIw==",
"dev": true,
"hasInstallScript": true,
"bin": {
"esbuild": "bin/esbuild"
},
"optionalDependencies": {
"esbuild-android-arm64": "0.13.15",
"esbuild-darwin-64": "0.13.15",
"esbuild-darwin-arm64": "0.13.15",
"esbuild-freebsd-64": "0.13.15",
"esbuild-freebsd-arm64": "0.13.15",
"esbuild-linux-32": "0.13.15",
"esbuild-linux-64": "0.13.15",
"esbuild-linux-arm": "0.13.15",
"esbuild-linux-arm64": "0.13.15",
"esbuild-linux-mips64le": "0.13.15",
"esbuild-linux-ppc64le": "0.13.15",
"esbuild-netbsd-64": "0.13.15",
"esbuild-openbsd-64": "0.13.15",
"esbuild-sunos-64": "0.13.15",
"esbuild-windows-32": "0.13.15",
"esbuild-windows-64": "0.13.15",
"esbuild-windows-arm64": "0.13.15"
}
},
"node_modules/esbuild-android-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.13.15.tgz",
"integrity": "sha512-m602nft/XXeO8YQPUDVoHfjyRVPdPgjyyXOxZ44MK/agewFFkPa8tUo6lAzSWh5Ui5PB4KR9UIFTSBKh/RrCmg==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"android"
]
},
"node_modules/esbuild-darwin-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.13.15.tgz",
"integrity": "sha512-ihOQRGs2yyp7t5bArCwnvn2Atr6X4axqPpEdCFPVp7iUj4cVSdisgvEKdNR7yH3JDjW6aQDw40iQFoTqejqxvQ==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"darwin"
]
},
"node_modules/esbuild-darwin-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.13.15.tgz",
"integrity": "sha512-i1FZssTVxUqNlJ6cBTj5YQj4imWy3m49RZRnHhLpefFIh0To05ow9DTrXROTE1urGTQCloFUXTX8QfGJy1P8dQ==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"darwin"
]
},
"node_modules/esbuild-freebsd-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.13.15.tgz",
"integrity": "sha512-G3dLBXUI6lC6Z09/x+WtXBXbOYQZ0E8TDBqvn7aMaOCzryJs8LyVXKY4CPnHFXZAbSwkCbqiPuSQ1+HhrNk7EA==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"freebsd"
]
},
"node_modules/esbuild-freebsd-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.13.15.tgz",
"integrity": "sha512-KJx0fzEDf1uhNOZQStV4ujg30WlnwqUASaGSFPhznLM/bbheu9HhqZ6mJJZM32lkyfGJikw0jg7v3S0oAvtvQQ==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"freebsd"
]
},
"node_modules/esbuild-linux-32": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.13.15.tgz",
"integrity": "sha512-ZvTBPk0YWCLMCXiFmD5EUtB30zIPvC5Itxz0mdTu/xZBbbHJftQgLWY49wEPSn2T/TxahYCRDWun5smRa0Tu+g==",
"cpu": [
"ia32"
],
"dev": true,
"optional": true,
"os": [
"linux"
]
},
"node_modules/esbuild-linux-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.13.15.tgz",
"integrity": "sha512-eCKzkNSLywNeQTRBxJRQ0jxRCl2YWdMB3+PkWFo2BBQYC5mISLIVIjThNtn6HUNqua1pnvgP5xX0nHbZbPj5oA==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"linux"
]
},
"node_modules/esbuild-linux-arm": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.13.15.tgz",
"integrity": "sha512-wUHttDi/ol0tD8ZgUMDH8Ef7IbDX+/UsWJOXaAyTdkT7Yy9ZBqPg8bgB/Dn3CZ9SBpNieozrPRHm0BGww7W/jA==",
"cpu": [
"arm"
],
"dev": true,
"optional": true,
"os": [
"linux"
]
},
"node_modules/esbuild-linux-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.13.15.tgz",
"integrity": "sha512-bYpuUlN6qYU9slzr/ltyLTR9YTBS7qUDymO8SV7kjeNext61OdmqFAzuVZom+OLW1HPHseBfJ/JfdSlx8oTUoA==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"linux"
]
},
"node_modules/esbuild-linux-mips64le": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.13.15.tgz",
"integrity": "sha512-KlVjIG828uFPyJkO/8gKwy9RbXhCEUeFsCGOJBepUlpa7G8/SeZgncUEz/tOOUJTcWMTmFMtdd3GElGyAtbSWg==",
"cpu": [
"mips64el"
],
"dev": true,
"optional": true,
"os": [
"linux"
]
},
"node_modules/esbuild-linux-ppc64le": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.13.15.tgz",
"integrity": "sha512-h6gYF+OsaqEuBjeesTBtUPw0bmiDu7eAeuc2OEH9S6mV9/jPhPdhOWzdeshb0BskRZxPhxPOjqZ+/OqLcxQwEQ==",
"cpu": [
"ppc64"
],
"dev": true,
"optional": true,
"os": [
"linux"
]
},
"node_modules/esbuild-netbsd-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.13.15.tgz",
"integrity": "sha512-3+yE9emwoevLMyvu+iR3rsa+Xwhie7ZEHMGDQ6dkqP/ndFzRHkobHUKTe+NCApSqG5ce2z4rFu+NX/UHnxlh3w==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"netbsd"
]
},
"node_modules/esbuild-openbsd-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.13.15.tgz",
"integrity": "sha512-wTfvtwYJYAFL1fSs8yHIdf5GEE4NkbtbXtjLWjM3Cw8mmQKqsg8kTiqJ9NJQe5NX/5Qlo7Xd9r1yKMMkHllp5g==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"openbsd"
]
},
"node_modules/esbuild-sunos-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.13.15.tgz",
"integrity": "sha512-lbivT9Bx3t1iWWrSnGyBP9ODriEvWDRiweAs69vI+miJoeKwHWOComSRukttbuzjZ8r1q0mQJ8Z7yUsDJ3hKdw==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"sunos"
]
},
"node_modules/esbuild-windows-32": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.13.15.tgz",
"integrity": "sha512-fDMEf2g3SsJ599MBr50cY5ve5lP1wyVwTe6aLJsM01KtxyKkB4UT+fc5MXQFn3RLrAIAZOG+tHC+yXObpSn7Nw==",
"cpu": [
"ia32"
],
"dev": true,
"optional": true,
"os": [
"win32"
]
},
"node_modules/esbuild-windows-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.13.15.tgz",
"integrity": "sha512-9aMsPRGDWCd3bGjUIKG/ZOJPKsiztlxl/Q3C1XDswO6eNX/Jtwu4M+jb6YDH9hRSUflQWX0XKAfWzgy5Wk54JQ==",
"cpu": [
"x64"
],
"dev": true,
"optional": true,
"os": [
"win32"
]
},
"node_modules/esbuild-windows-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.13.15.tgz",
"integrity": "sha512-zzvyCVVpbwQQATaf3IG8mu1IwGEiDxKkYUdA4FpoCHi1KtPa13jeScYDjlW0Qh+ebWzpKfR2ZwvqAQkSWNcKjA==",
"cpu": [
"arm64"
],
"dev": true,
"optional": true,
"os": [
"win32"
]
},
"node_modules/estree-walker": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz",
"integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==",
"dev": true
},
"node_modules/fsevents": {
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
"integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
"dev": true,
"hasInstallScript": true,
"optional": true,
"os": [
"darwin"
],
"engines": {
"node": "^8.16.0 || ^10.6.0 || >=11.0.0"
}
},
"node_modules/function-bind": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
"integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
"dev": true
},
"node_modules/has": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
"integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
"dev": true,
"dependencies": {
"function-bind": "^1.1.1"
},
"engines": {
"node": ">= 0.4.0"
}
},
"node_modules/is-core-module": {
"version": "2.8.0",
"resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.8.0.tgz",
"integrity": "sha512-vd15qHsaqrRL7dtH6QNuy0ndJmRDrS9HAM1CAiSifNUFv4x1a0CCVsj18hJ1mShxIG6T2i1sO78MkP56r0nYRw==",
"dev": true,
"dependencies": {
"has": "^1.0.3"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/kleur": {
"version": "4.1.4",
"resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.4.tgz",
"integrity": "sha512-8QADVssbrFjivHWQU7KkMgptGTl6WAcSdlbBPY4uNF+mWr6DGcKrvY2w4FQJoXch7+fKMjj0dRrL75vk3k23OA==",
"dev": true,
"engines": {
"node": ">=6"
}
},
"node_modules/klinecharts": {
"version": "8.1.0",
"resolved": "https://registry.npmjs.org/klinecharts/-/klinecharts-8.1.0.tgz",
"integrity": "sha512-LNRa3eRs81nmhuepLxsnDj1s2uj/17Ta4rA71SlMApu1YHGjs4LBcNSwuNRRCLpdCfHi2LQ3KWSpVwrBHoDTUQ=="
},
"node_modules/magic-string": {
"version": "0.25.7",
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.7.tgz",
"integrity": "sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA==",
"dev": true,
"dependencies": {
"sourcemap-codec": "^1.4.4"
}
},
"node_modules/mri": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/mri/-/mri-1.2.0.tgz",
"integrity": "sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==",
"dev": true,
"engines": {
"node": ">=4"
}
},
"node_modules/ms": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
"dev": true
},
"node_modules/nanoid": {
"version": "3.1.30",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.30.tgz",
"integrity": "sha512-zJpuPDwOv8D2zq2WRoMe1HsfZthVewpel9CAvTfc/2mBD1uUT/agc5f7GHGWXlYkFvi1mVxe4IjvP2HNrop7nQ==",
"dev": true,
"bin": {
"nanoid": "bin/nanoid.cjs"
},
"engines": {
"node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1"
}
},
"node_modules/path-parse": {
"version": "1.0.7",
"resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
"integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
"dev": true
},
"node_modules/picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
"integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==",
"dev": true
},
"node_modules/picomatch": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz",
"integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==",
"dev": true,
"engines": {
"node": ">=8.6"
},
"funding": {
"url": "https://github.com/sponsors/jonschlinkert"
}
},
"node_modules/postcss": {
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.3.11.tgz",
"integrity": "sha512-hCmlUAIlUiav8Xdqw3Io4LcpA1DOt7h3LSTAC4G6JGHFFaWzI6qvFt9oilvl8BmkbBRX1IhM90ZAmpk68zccQA==",
"dev": true,
"dependencies": {
"nanoid": "^3.1.30",
"picocolors": "^1.0.0",
"source-map-js": "^0.6.2"
},
"engines": {
"node": "^10 || ^12 || >=14"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/postcss/"
}
},
"node_modules/require-relative": {
"version": "0.8.7",
"resolved": "https://registry.npmjs.org/require-relative/-/require-relative-0.8.7.tgz",
"integrity": "sha1-eZlTn8ngR6N5KPoZb44VY9q9Nt4=",
"dev": true
},
"node_modules/resolve": {
"version": "1.20.0",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz",
"integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==",
"dev": true,
"dependencies": {
"is-core-module": "^2.2.0",
"path-parse": "^1.0.6"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/rollup": {
"version": "2.60.1",
"resolved": "https://registry.npmjs.org/rollup/-/rollup-2.60.1.tgz",
"integrity": "sha512-akwfnpjY0rXEDSn1UTVfKXJhPsEBu+imi1gqBA1ZkHGydUnkV/fWCC90P7rDaLEW8KTwBcS1G3N4893Ndz+jwg==",
"dev": true,
"bin": {
"rollup": "dist/bin/rollup"
},
"engines": {
"node": ">=10.0.0"
},
"optionalDependencies": {
"fsevents": "~2.3.2"
}
},
"node_modules/sade": {
"version": "1.7.4",
"resolved": "https://registry.npmjs.org/sade/-/sade-1.7.4.tgz",
"integrity": "sha512-y5yauMD93rX840MwUJr7C1ysLFBgMspsdTo4UVrDg3fXDvtwOyIqykhVAAm6fk/3au77773itJStObgK+LKaiA==",
"dev": true,
"dependencies": {
"mri": "^1.1.0"
},
"engines": {
"node": ">= 6"
}
},
"node_modules/source-map-js": {
"version": "0.6.2",
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-0.6.2.tgz",
"integrity": "sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug==",
"dev": true,
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/sourcemap-codec": {
"version": "1.4.8",
"resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz",
"integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==",
"dev": true
},
"node_modules/svelte": {
"version": "3.44.2",
"resolved": "https://registry.npmjs.org/svelte/-/svelte-3.44.2.tgz",
"integrity": "sha512-jrZhZtmH3ZMweXg1Q15onb8QlWD+a5T5Oca4C1jYvSURp2oD35h4A5TV6t6MEa93K4LlX6BkafZPdQoFjw/ylA==",
"dev": true,
"engines": {
"node": ">= 8"
}
},
"node_modules/svelte-hmr": {
"version": "0.14.7",
"resolved": "https://registry.npmjs.org/svelte-hmr/-/svelte-hmr-0.14.7.tgz",
"integrity": "sha512-pDrzgcWSoMaK6AJkBWkmgIsecW0GChxYZSZieIYfCP0v2oPyx2CYU/zm7TBIcjLVUPP714WxmViE9Thht4etog==",
"dev": true,
"peerDependencies": {
"svelte": ">=3.19.0"
}
},
"node_modules/vite": {
"version": "2.6.14",
"resolved": "https://registry.npmjs.org/vite/-/vite-2.6.14.tgz",
"integrity": "sha512-2HA9xGyi+EhY2MXo0+A2dRsqsAG3eFNEVIo12olkWhOmc8LfiM+eMdrXf+Ruje9gdXgvSqjLI9freec1RUM5EA==",
"dev": true,
"dependencies": {
"esbuild": "^0.13.2",
"postcss": "^8.3.8",
"resolve": "^1.20.0",
"rollup": "^2.57.0"
},
"bin": {
"vite": "bin/vite.js"
},
"engines": {
"node": ">=12.2.0"
},
"optionalDependencies": {
"fsevents": "~2.3.2"
},
"peerDependencies": {
"less": "*",
"sass": "*",
"stylus": "*"
},
"peerDependenciesMeta": {
"less": {
"optional": true
},
"sass": {
"optional": true
},
"stylus": {
"optional": true
}
}
}
},
"dependencies": {
"@rollup/pluginutils": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-4.1.1.tgz",
"integrity": "sha512-clDjivHqWGXi7u+0d2r2sBi4Ie6VLEAzWMIkvJLnDmxoOhBYOTfzGbOQBA32THHm11/LiJbd01tJUpJsbshSWQ==",
"dev": true,
"requires": {
"estree-walker": "^2.0.1",
"picomatch": "^2.2.2"
}
},
"@sveltejs/kit": {
"version": "1.0.0-next.198",
"resolved": "https://registry.npmjs.org/@sveltejs/kit/-/kit-1.0.0-next.198.tgz",
"integrity": "sha512-BgXVrCOn0sYNAvmSIXxfztntGzb4ZhaO3KSmJzkSeQQg20+aQGqyOJnhTQ+wDX+YhyKURxVOhjTWHjeO6d7gdw==",
"dev": true,
"requires": {
"@sveltejs/vite-plugin-svelte": "^1.0.0-next.30",
"cheap-watch": "^1.0.4",
"sade": "^1.7.4",
"vite": "^2.6.12"
}
},
"@sveltejs/vite-plugin-svelte": {
"version": "1.0.0-next.30",
"resolved": "https://registry.npmjs.org/@sveltejs/vite-plugin-svelte/-/vite-plugin-svelte-1.0.0-next.30.tgz",
"integrity": "sha512-YQqdMxjL1VgSFk4/+IY3yLwuRRapPafPiZTiaGEq1psbJYSNYUWx9F1zMm32GMsnogg3zn99mGJOqe3ld3HZSg==",
"dev": true,
"requires": {
"@rollup/pluginutils": "^4.1.1",
"debug": "^4.3.2",
"kleur": "^4.1.4",
"magic-string": "^0.25.7",
"require-relative": "^0.8.7",
"svelte-hmr": "^0.14.7"
}
},
"cheap-watch": {
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/cheap-watch/-/cheap-watch-1.0.4.tgz",
"integrity": "sha512-QR/9FrtRL5fjfUJBhAKCdi0lSRQ3rVRRum3GF9wDKp2TJbEIMGhUEr2yU8lORzm9Isdjx7/k9S0DFDx+z5VGtw==",
"dev": true
},
"debug": {
"version": "4.3.2",
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.2.tgz",
"integrity": "sha512-mOp8wKcvj7XxC78zLgw/ZA+6TSgkoE2C/ienthhRD298T7UNwAg9diBpLRxC0mOezLl4B0xV7M0cCO6P/O0Xhw==",
"dev": true,
"requires": {
"ms": "2.1.2"
}
},
"esbuild": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.13.15.tgz",
"integrity": "sha512-raCxt02HBKv8RJxE8vkTSCXGIyKHdEdGfUmiYb8wnabnaEmHzyW7DCHb5tEN0xU8ryqg5xw54mcwnYkC4x3AIw==",
"dev": true,
"requires": {
"esbuild-android-arm64": "0.13.15",
"esbuild-darwin-64": "0.13.15",
"esbuild-darwin-arm64": "0.13.15",
"esbuild-freebsd-64": "0.13.15",
"esbuild-freebsd-arm64": "0.13.15",
"esbuild-linux-32": "0.13.15",
"esbuild-linux-64": "0.13.15",
"esbuild-linux-arm": "0.13.15",
"esbuild-linux-arm64": "0.13.15",
"esbuild-linux-mips64le": "0.13.15",
"esbuild-linux-ppc64le": "0.13.15",
"esbuild-netbsd-64": "0.13.15",
"esbuild-openbsd-64": "0.13.15",
"esbuild-sunos-64": "0.13.15",
"esbuild-windows-32": "0.13.15",
"esbuild-windows-64": "0.13.15",
"esbuild-windows-arm64": "0.13.15"
}
},
"esbuild-android-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-android-arm64/-/esbuild-android-arm64-0.13.15.tgz",
"integrity": "sha512-m602nft/XXeO8YQPUDVoHfjyRVPdPgjyyXOxZ44MK/agewFFkPa8tUo6lAzSWh5Ui5PB4KR9UIFTSBKh/RrCmg==",
"dev": true,
"optional": true
},
"esbuild-darwin-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-darwin-64/-/esbuild-darwin-64-0.13.15.tgz",
"integrity": "sha512-ihOQRGs2yyp7t5bArCwnvn2Atr6X4axqPpEdCFPVp7iUj4cVSdisgvEKdNR7yH3JDjW6aQDw40iQFoTqejqxvQ==",
"dev": true,
"optional": true
},
"esbuild-darwin-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.13.15.tgz",
"integrity": "sha512-i1FZssTVxUqNlJ6cBTj5YQj4imWy3m49RZRnHhLpefFIh0To05ow9DTrXROTE1urGTQCloFUXTX8QfGJy1P8dQ==",
"dev": true,
"optional": true
},
"esbuild-freebsd-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-64/-/esbuild-freebsd-64-0.13.15.tgz",
"integrity": "sha512-G3dLBXUI6lC6Z09/x+WtXBXbOYQZ0E8TDBqvn7aMaOCzryJs8LyVXKY4CPnHFXZAbSwkCbqiPuSQ1+HhrNk7EA==",
"dev": true,
"optional": true
},
"esbuild-freebsd-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.13.15.tgz",
"integrity": "sha512-KJx0fzEDf1uhNOZQStV4ujg30WlnwqUASaGSFPhznLM/bbheu9HhqZ6mJJZM32lkyfGJikw0jg7v3S0oAvtvQQ==",
"dev": true,
"optional": true
},
"esbuild-linux-32": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-32/-/esbuild-linux-32-0.13.15.tgz",
"integrity": "sha512-ZvTBPk0YWCLMCXiFmD5EUtB30zIPvC5Itxz0mdTu/xZBbbHJftQgLWY49wEPSn2T/TxahYCRDWun5smRa0Tu+g==",
"dev": true,
"optional": true
},
"esbuild-linux-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-64/-/esbuild-linux-64-0.13.15.tgz",
"integrity": "sha512-eCKzkNSLywNeQTRBxJRQ0jxRCl2YWdMB3+PkWFo2BBQYC5mISLIVIjThNtn6HUNqua1pnvgP5xX0nHbZbPj5oA==",
"dev": true,
"optional": true
},
"esbuild-linux-arm": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm/-/esbuild-linux-arm-0.13.15.tgz",
"integrity": "sha512-wUHttDi/ol0tD8ZgUMDH8Ef7IbDX+/UsWJOXaAyTdkT7Yy9ZBqPg8bgB/Dn3CZ9SBpNieozrPRHm0BGww7W/jA==",
"dev": true,
"optional": true
},
"esbuild-linux-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-arm64/-/esbuild-linux-arm64-0.13.15.tgz",
"integrity": "sha512-bYpuUlN6qYU9slzr/ltyLTR9YTBS7qUDymO8SV7kjeNext61OdmqFAzuVZom+OLW1HPHseBfJ/JfdSlx8oTUoA==",
"dev": true,
"optional": true
},
"esbuild-linux-mips64le": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.13.15.tgz",
"integrity": "sha512-KlVjIG828uFPyJkO/8gKwy9RbXhCEUeFsCGOJBepUlpa7G8/SeZgncUEz/tOOUJTcWMTmFMtdd3GElGyAtbSWg==",
"dev": true,
"optional": true
},
"esbuild-linux-ppc64le": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.13.15.tgz",
"integrity": "sha512-h6gYF+OsaqEuBjeesTBtUPw0bmiDu7eAeuc2OEH9S6mV9/jPhPdhOWzdeshb0BskRZxPhxPOjqZ+/OqLcxQwEQ==",
"dev": true,
"optional": true
},
"esbuild-netbsd-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-netbsd-64/-/esbuild-netbsd-64-0.13.15.tgz",
"integrity": "sha512-3+yE9emwoevLMyvu+iR3rsa+Xwhie7ZEHMGDQ6dkqP/ndFzRHkobHUKTe+NCApSqG5ce2z4rFu+NX/UHnxlh3w==",
"dev": true,
"optional": true
},
"esbuild-openbsd-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-openbsd-64/-/esbuild-openbsd-64-0.13.15.tgz",
"integrity": "sha512-wTfvtwYJYAFL1fSs8yHIdf5GEE4NkbtbXtjLWjM3Cw8mmQKqsg8kTiqJ9NJQe5NX/5Qlo7Xd9r1yKMMkHllp5g==",
"dev": true,
"optional": true
},
"esbuild-sunos-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-sunos-64/-/esbuild-sunos-64-0.13.15.tgz",
"integrity": "sha512-lbivT9Bx3t1iWWrSnGyBP9ODriEvWDRiweAs69vI+miJoeKwHWOComSRukttbuzjZ8r1q0mQJ8Z7yUsDJ3hKdw==",
"dev": true,
"optional": true
},
"esbuild-windows-32": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-windows-32/-/esbuild-windows-32-0.13.15.tgz",
"integrity": "sha512-fDMEf2g3SsJ599MBr50cY5ve5lP1wyVwTe6aLJsM01KtxyKkB4UT+fc5MXQFn3RLrAIAZOG+tHC+yXObpSn7Nw==",
"dev": true,
"optional": true
},
"esbuild-windows-64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.13.15.tgz",
"integrity": "sha512-9aMsPRGDWCd3bGjUIKG/ZOJPKsiztlxl/Q3C1XDswO6eNX/Jtwu4M+jb6YDH9hRSUflQWX0XKAfWzgy5Wk54JQ==",
"dev": true,
"optional": true
},
"esbuild-windows-arm64": {
"version": "0.13.15",
"resolved": "https://registry.npmjs.org/esbuild-windows-arm64/-/esbuild-windows-arm64-0.13.15.tgz",
"integrity": "sha512-zzvyCVVpbwQQATaf3IG8mu1IwGEiDxKkYUdA4FpoCHi1KtPa13jeScYDjlW0Qh+ebWzpKfR2ZwvqAQkSWNcKjA==",
"dev": true,
"optional": true
},
"estree-walker": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz",
"integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==",
"dev": true
},
"fsevents": {
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
"integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
"dev": true,
"optional": true
},
"function-bind": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
"integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
"dev": true
},
"has": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
"integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
"dev": true,
"requires": {
"function-bind": "^1.1.1"
}
},
"is-core-module": {
"version": "2.8.0",
"resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.8.0.tgz",
"integrity": "sha512-vd15qHsaqrRL7dtH6QNuy0ndJmRDrS9HAM1CAiSifNUFv4x1a0CCVsj18hJ1mShxIG6T2i1sO78MkP56r0nYRw==",
"dev": true,
"requires": {
"has": "^1.0.3"
}
},
"kleur": {
"version": "4.1.4",
"resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.4.tgz",
"integrity": "sha512-8QADVssbrFjivHWQU7KkMgptGTl6WAcSdlbBPY4uNF+mWr6DGcKrvY2w4FQJoXch7+fKMjj0dRrL75vk3k23OA==",
"dev": true
},
"klinecharts": {
"version": "8.1.0",
"resolved": "https://registry.npmjs.org/klinecharts/-/klinecharts-8.1.0.tgz",
"integrity": "sha512-LNRa3eRs81nmhuepLxsnDj1s2uj/17Ta4rA71SlMApu1YHGjs4LBcNSwuNRRCLpdCfHi2LQ3KWSpVwrBHoDTUQ=="
},
"magic-string": {
"version": "0.25.7",
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.7.tgz",
"integrity": "sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA==",
"dev": true,
"requires": {
"sourcemap-codec": "^1.4.4"
}
},
"mri": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/mri/-/mri-1.2.0.tgz",
"integrity": "sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==",
"dev": true
},
"ms": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
"dev": true
},
"nanoid": {
"version": "3.1.30",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.30.tgz",
"integrity": "sha512-zJpuPDwOv8D2zq2WRoMe1HsfZthVewpel9CAvTfc/2mBD1uUT/agc5f7GHGWXlYkFvi1mVxe4IjvP2HNrop7nQ==",
"dev": true
},
"path-parse": {
"version": "1.0.7",
"resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
"integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
"dev": true
},
"picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
"integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==",
"dev": true
},
"picomatch": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz",
"integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==",
"dev": true
},
"postcss": {
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.3.11.tgz",
"integrity": "sha512-hCmlUAIlUiav8Xdqw3Io4LcpA1DOt7h3LSTAC4G6JGHFFaWzI6qvFt9oilvl8BmkbBRX1IhM90ZAmpk68zccQA==",
"dev": true,
"requires": {
"nanoid": "^3.1.30",
"picocolors": "^1.0.0",
"source-map-js": "^0.6.2"
}
},
"require-relative": {
"version": "0.8.7",
"resolved": "https://registry.npmjs.org/require-relative/-/require-relative-0.8.7.tgz",
"integrity": "sha1-eZlTn8ngR6N5KPoZb44VY9q9Nt4=",
"dev": true
},
"resolve": {
"version": "1.20.0",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz",
"integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==",
"dev": true,
"requires": {
"is-core-module": "^2.2.0",
"path-parse": "^1.0.6"
}
},
"rollup": {
"version": "2.60.1",
"resolved": "https://registry.npmjs.org/rollup/-/rollup-2.60.1.tgz",
"integrity": "sha512-akwfnpjY0rXEDSn1UTVfKXJhPsEBu+imi1gqBA1ZkHGydUnkV/fWCC90P7rDaLEW8KTwBcS1G3N4893Ndz+jwg==",
"dev": true,
"requires": {
"fsevents": "~2.3.2"
}
},
"sade": {
"version": "1.7.4",
"resolved": "https://registry.npmjs.org/sade/-/sade-1.7.4.tgz",
"integrity": "sha512-y5yauMD93rX840MwUJr7C1ysLFBgMspsdTo4UVrDg3fXDvtwOyIqykhVAAm6fk/3au77773itJStObgK+LKaiA==",
"dev": true,
"requires": {
"mri": "^1.1.0"
}
},
"source-map-js": {
"version": "0.6.2",
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-0.6.2.tgz",
"integrity": "sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug==",
"dev": true
},
"sourcemap-codec": {
"version": "1.4.8",
"resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz",
"integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==",
"dev": true
},
"svelte": {
"version": "3.44.2",
"resolved": "https://registry.npmjs.org/svelte/-/svelte-3.44.2.tgz",
"integrity": "sha512-jrZhZtmH3ZMweXg1Q15onb8QlWD+a5T5Oca4C1jYvSURp2oD35h4A5TV6t6MEa93K4LlX6BkafZPdQoFjw/ylA==",
"dev": true
},
"svelte-hmr": {
"version": "0.14.7",
"resolved": "https://registry.npmjs.org/svelte-hmr/-/svelte-hmr-0.14.7.tgz",
"integrity": "sha512-pDrzgcWSoMaK6AJkBWkmgIsecW0GChxYZSZieIYfCP0v2oPyx2CYU/zm7TBIcjLVUPP714WxmViE9Thht4etog==",
"dev": true,
"requires": {}
},
"vite": {
"version": "2.6.14",
"resolved": "https://registry.npmjs.org/vite/-/vite-2.6.14.tgz",
"integrity": "sha512-2HA9xGyi+EhY2MXo0+A2dRsqsAG3eFNEVIo12olkWhOmc8LfiM+eMdrXf+Ruje9gdXgvSqjLI9freec1RUM5EA==",
"dev": true,
"requires": {
"esbuild": "^0.13.2",
"fsevents": "~2.3.2",
"postcss": "^8.3.8",
"resolve": "^1.20.0",
"rollup": "^2.57.0"
}
}
}
}

View File

@ -1,17 +0,0 @@
{
"name": "bluewest.frontend",
"version": "0.0.1",
"scripts": {
"dev": "svelte-kit dev",
"build": "svelte-kit build",
"preview": "svelte-kit preview"
},
"devDependencies": {
"@sveltejs/kit": "next",
"svelte": "^3.42.6"
},
"type": "module",
"dependencies": {
"klinecharts": "^8.1.0"
}
}

View File

@ -1,14 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8"/>
<link rel="icon" href="/favicon.png"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<link href="https://cdn.jsdelivr.net/npm/beercss@1.2.9/dist/cdn/beer.min.css" rel="stylesheet"/>
<script src="https://cdn.jsdelivr.net/npm/beercss@1.2.9/dist/cdn/beer.min.js" type="text/javascript"></script>
%svelte.head%
</head>
<body>
<div id="svelte" class="container max">%svelte.body%</div>
</body>
</html>

View File

@ -1,21 +0,0 @@
<script>
var chart = klinecharts.init('chart')
// 创建一个主图技术指标
chart.createTechnicalIndicator('MA', false, { id: 'candle_pane' })
// 创建一个副图技术指标VOL
chart.createTechnicalIndicator('VOL')
// 创建一个副图技术指标MACD
chart.createTechnicalIndicator('MACD')
// 加载数据
var chartDataList = kLineDataList.map(function (data) {
return {
timestamp: new Date(data[0]).getTime(),
open: +data[1],
high: +data[2],
low: +data[3],
close: +data[4],
volume: Math.ceil(+data[5]),
}
})
chart.applyNewData(chartDataList)
</script>

View File

@ -1,15 +0,0 @@
<div class="menu left border no-space grey-text m l">
<div class="large-space"></div>
<div class="medium-space"></div>
<div class="space"></div>
<a href="/" class="active"><i class="outlined">home</i>
<div class="tooltip right">Blue West</div>
</a>
<a href="/users" class="active"><i class="outlined">person</i>
<div class="tooltip right">Users</div>
</a>
<a href="/binance" class="active"><i class="outlined">bar_chart</i>
<div class="tooltip right">Binance</div>
</a>
</div>

View File

@ -1 +0,0 @@
/// <reference types="@sveltejs/kit" />

View File

@ -1,50 +0,0 @@
<script>
import Menu from "../components/Menu.svelte";
</script>
<Menu/>
<div class="menu top border">
<div class="row no-wrap middle-align">
<div class="col">
<nav class="padding">
<button data-ui="#modal-expanded" class="none color-2-text m l"><i>menu</i></button>
<a><i class="outlined">bar_chart</i></a></nav>
</div>
<div class="col">
<div class="field round suffix prefix small no-margin m l"><i class="front">search</i><input type="text"
class="white black-text"><i
class="front">mic</i></div>
</div>
<div class="col">
<nav class="right-align">
<button data-ui="#modal-search" class="none color-2-text s"><i>search</i></button>
<button data-ui="#dropdown-add" class="none color-2-text m l"><i>video_call</i>
<div id="dropdown-add" data-ui="#dropdown-add" class="dropdown left no-wrap"><a class="row no-wrap">
<div class="col min"><i>upload</i></div>
<div class="col">Send a video</div>
</a><a class="row no-wrap">
<div class="col min"><i>sensors</i></div>
<div class="col">Broadcast live</div>
</a></div>
</button>
<button data-ui="#dropdown-apps" class="none color-2-text m l"><i>apps</i>
<div id="dropdown-apps" data-ui="#dropdown-apps" class="dropdown left no-wrap"><a
class="row no-wrap">
<div class="col min"><img src="/youtube.png"></div>
<div class="col">Youtube TV</div>
</a>
<div class="divider"></div>
<a class="row no-wrap">
<div class="col min"><img src="/youtube.png"></div>
<div class="col">Youtube Music</div>
</a><a class="row no-wrap">
<div class="col min"><img src="/youtube.png"></div>
<div class="col">Youtube Kids</div>
</a></div>
</button>
<button data-ui="#modal-notifications" class="none color-2-text active"><i>notifications</i></button>
<a href="/"><img src="/favicon.png" class="circle"></a></nav>
</div>
</div>
</div>

View File

@ -1,9 +0,0 @@
<script>
import Menu from "../components/Menu.svelte";
</script>
<svelte:head>
<title>Blue West - Start</title>
</svelte:head>
<Menu/>

View File

@ -1,170 +0,0 @@
<svelte:head>
<title>Blue West - Users</title>
</svelte:head>
<script>
import {onMount} from "svelte";
import {AddUser, DeleteUser, GetUsers, UpdateUser} from "../tools/RestExtensions";
import {UserUpdateDto} from "../tools/Dtos";
import Menu from "../components/Menu.svelte";
let users;
let loaded = false;
let addUserEnabled = false;
let userEditTemp = undefined;
const menuDefinition = {
title: 'Add User',
cb: onAddUserClicked
}
function addUser(user){
users = [...users, user]
}
function removeUser(id ) {
users = users.filter((u) => u.id !== id);
}
let isSafari;
onMount(async () => {
await GetUsers().then(res => {
users = res;
if(users.length)
loaded = true;
})
})
function onEditUserClicked(user) {
userEditTemp = user;
}
function onAddUserClicked(userId) {
userEditTemp = new UserUpdateDto();
addUserEnabled = true;
}
function onAddUserSaveClicked(userId) {
AddUser(userEditTemp);
addUser(userEditTemp);
userEditTemp = undefined;
addUserEnabled = false;
}
function onAddUserCancelClicked(userId) {
addUserEnabled = false;
}
function onRemoveUserClicked(userId) {
DeleteUser(userId);
removeUser(userId);
}
function onSaveUserClicked(userId) {
let userUpdateDto = UserUpdateDto.ConvertFromUser(userEditTemp);
UpdateUser(userId, userUpdateDto);
userEditTemp = undefined;
}
function onSaveUserCancelClicked(userId) {
userEditTemp = undefined;
}
</script>
<Menu menuDefinition={menuDefinition}/>
<div class="table-container">
{#if !loaded}
<a class="loader large"></a>
{/if}
{#if loaded}
<table class="pure-table">
<tr>
<th>ID</th>
<th>Name</th>
<th>Address</th>
<th>BTC Address</th>
<th>BTC Amount</th>
<th>LTC Address</th>
<th>LTC Amount</th>
<th></th>
</tr>
{#each users as user}
{#if userEditTemp !== undefined && userEditTemp.id === user.id && !addUserEnabled}
<tr>
<td>{user.id}</td>
<td><input type="text" bind:value={userEditTemp['name']}></td>
<td><input type="text" bind:value={userEditTemp['address']}></td>
<td><input type="text" bind:value={userEditTemp['btcAddress']}></td>
<td><input type="text" bind:value={userEditTemp['btcAmount']}></td>
<td><input type="text" bind:value={userEditTemp['ltcAddress']}></td>
<td><input type="text" bind:value={userEditTemp['ltcAmount']} ></td>
<td>
<button class="pure-button" on:click={() => onSaveUserClicked(user.id)}>Save</button>
<button class="pure-button" on:click={() => onSaveUserCancelClicked()}>Cancel</button>
</td>
</tr>
{:else}
<tr>
<td>{user.id}</td>
<td>{user.name}</td>
<td>{user.address}</td>
<td>{user.btcAddress}</td>
<td>{user.btcAmount}</td>
<td>{user.ltcAddress}</td>
<td>{user.ltcAmount}</td>
<td>
<div class="buttons-container">
<div class="table-button" on:click={() => onEditUserClicked(user)}>
<i class="large">edit</i>
</div>
<div class="table-button" on:click={() => onRemoveUserClicked(user.id)}>
<i class="large">remove</i>
</div>
</div>
</td>
</tr>
{/if}
{/each}
{#if addUserEnabled}
<tr>
<td></td>
<td><input type="text" bind:value={userEditTemp['name']}></td>
<td><input type="text" bind:value={userEditTemp['address']}></td>
<td><input type="text" bind:value={userEditTemp['btcAddress']}></td>
<td><input type="text" bind:value={userEditTemp['btcAmount']}></td>
<td><input type="text" bind:value={userEditTemp['ltcAddress']}></td>
<td><input type="text" bind:value={userEditTemp['ltcAmount']} ></td>
<td>
<button class="pure-button" on:click={() => onAddUserSaveClicked()}>Save</button>
<button class="pure-button" on:click={() => onAddUserCancelClicked()}>Cancel</button>
</td>
</tr>
{/if}
</table>
{/if}
</div>
<style>
.table-container {
width: 100%;
justify-content: center;
display: flex;
}
input {
max-width: 100px;
}
.buttons-container{
display: flex;
}
</style>

View File

@ -1,14 +0,0 @@
export class UserUpdateDto{
constructor(name='', address='', btcAddress='', ltcAddress='', btcAmount='', ltcAmount='') {
this.name = name;
this.address = address;
this.btcAddress = btcAddress;
this.ltcAddress = ltcAddress;
this.btcAmount = btcAmount;
this.ltcAmount = ltcAmount;
}
static ConvertFromUser(user) {
return new UserUpdateDto(user.name, user.address, user.btcAddress, user.ltcAddress, user.btcAmount, user.ltcAmount);
}
}

View File

@ -1,50 +0,0 @@
async function RestRequest(url = '', type = 'get', data = {}) {
let answerData =
{
"credentials": "omit",
"headers": {
"Sec-Fetch-Dest": "empty",
"Sec-Fetch-Mode": "no-cors",
"Sec-Fetch-Site": "cross-site",
"Pragma": "no-cache",
"Cache-Control": "no-cache"
}
}
if (type.toLowerCase() === 'post' || type.toLowerCase() === 'put') {
answerData['headers']['Content-Type'] = "application/json-patch+json";
answerData['body'] = JSON.stringify(data);
}
answerData['method'] = type.toUpperCase();
let response = await fetch(url, answerData);
return response.json();
}
export function UpdateUser(userId, userData) {
return RestRequest(`https://localhost:5001/User/${userId}`, 'put', userData);
}
export function DeleteUser(userId) {
return RestRequest(`https://localhost:5001/User/${userId}`, 'delete');
}
export function AddUser(userData) {
console.log(userData)
return RestRequest(`https://localhost:5001/User`, 'post', userData);
}
export function GetUsers() {
return RestRequest("https://localhost:5001/User");
}
export function GetUserById(id) {
RestRequest(`http://localhost:5000/User/${id}`).then((res) => {
return res;
});
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

View File

@ -1,9 +0,0 @@
/** @type {import('@sveltejs/kit').Config} */
const config = {
kit: {
// hydrate the <div id="svelte"> element in src/app.html
target: '#svelte'
}
};
export default config;