diff --git a/Blazor/Blazor/Components/Inventory.razor b/Blazor/Blazor/Components/Inventory.razor
index 3914e05..690eaa8 100644
--- a/Blazor/Blazor/Components/Inventory.razor
+++ b/Blazor/Blazor/Components/Inventory.razor
@@ -20,4 +20,7 @@
-
\ No newline at end of file
+
+
+
+
diff --git a/Blazor/Blazor/Components/Inventory.razor.cs b/Blazor/Blazor/Components/Inventory.razor.cs
index b9fa5bd..637750e 100644
--- a/Blazor/Blazor/Components/Inventory.razor.cs
+++ b/Blazor/Blazor/Components/Inventory.razor.cs
@@ -3,7 +3,8 @@ using Blazor.Pages;
using Microsoft.AspNetCore.Components;
using Microsoft.JSInterop;
using System.Collections.ObjectModel;
-
+using System.Collections.Specialized;
+
namespace Blazor.Components
{
partial class Inventory
@@ -17,7 +18,8 @@ namespace Blazor.Components
public Inventory()
{
- Actions = new ObservableCollection();
+ Actions = new ObservableCollection();
+ Actions.CollectionChanged += OnActionsCollectionChanged;
}
public void update()
{
@@ -25,6 +27,9 @@ namespace Blazor.Components
return;
}
-
+ private void OnActionsCollectionChanged(object? sender, NotifyCollectionChangedEventArgs e)
+ {
+ JavaScriptRuntime.InvokeVoidAsync("Crafting.AddActions", e.NewItems);
+ }
}
}
diff --git a/Blazor/Blazor/Components/Inventory.razor.css b/Blazor/Blazor/Components/Inventory.razor.css
index 3407b0e..38c95cd 100644
--- a/Blazor/Blazor/Components/Inventory.razor.css
+++ b/Blazor/Blazor/Components/Inventory.razor.css
@@ -5,8 +5,6 @@
width: 40%;
}
-
-
.actions {
border: 1px solid black;
height: 250px;
diff --git a/Blazor/Blazor/Components/InventoryList.razor b/Blazor/Blazor/Components/InventoryList.razor
index 6e5ca1f..785d700 100644
--- a/Blazor/Blazor/Components/InventoryList.razor
+++ b/Blazor/Blazor/Components/InventoryList.razor
@@ -11,7 +11,7 @@
-
+