mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-12 11:56:30 +00:00
Workshop - Manage entries after installing them
Workshop - Auto-enable plugins after installing them Workshop - Show the latest release above the details page
This commit is contained in:
1 parent
966ca47335
commit
86f78940b1
23 files changed
+401
-190
No files matched your search
@@ -8,6 +8,10 @@
|
||||
x:Class="Artemis.UI.Screens.Workshop.Profile.ProfileDescriptionView"
|
||||
x:DataType="profile:ProfileDescriptionViewModel">
|
||||
<StackPanel Spacing="10">
|
||||
<Border Classes="card">
|
||||
<ContentControl Content="{CompiledBinding ReleaseInfoViewModel}"/>
|
||||
</Border>
|
||||
|
||||
<Border Classes="card">
|
||||
<mdxaml:MarkdownScrollViewer Markdown="{CompiledBinding Entry.Description}" MarkdownStyleName="FluentAvalonia" Name="MarkdownScrollViewer" >
|
||||
<mdxaml:MarkdownScrollViewer.Styles>
|
||||
|
||||
@@ -5,6 +5,7 @@ using System.Linq;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Artemis.UI.Screens.Workshop.Entries.List;
|
||||
using Artemis.UI.Screens.Workshop.EntryReleases;
|
||||
using Artemis.UI.Shared.Routing;
|
||||
using Artemis.WebClient.Workshop;
|
||||
using PropertyChanged.SourceGenerator;
|
||||
@@ -18,12 +19,16 @@ public partial class ProfileDescriptionViewModel : RoutableScreen
|
||||
[Notify] private IEntryDetails? _entry;
|
||||
[Notify] private List<EntryListItemViewModel>? _dependencies;
|
||||
|
||||
public ProfileDescriptionViewModel(IWorkshopClient client, Func<IEntrySummary, EntryListItemViewModel> getEntryListViewModel)
|
||||
public ProfileDescriptionViewModel(IWorkshopClient client, EntryReleaseInfoViewModel releaseInfoViewModel, Func<IEntrySummary, EntryListItemViewModel> getEntryListViewModel)
|
||||
{
|
||||
_client = client;
|
||||
_getEntryListViewModel = getEntryListViewModel;
|
||||
ReleaseInfoViewModel = releaseInfoViewModel;
|
||||
ReleaseInfoViewModel.InDetailsScreen = false;
|
||||
}
|
||||
|
||||
public EntryReleaseInfoViewModel ReleaseInfoViewModel { get; }
|
||||
|
||||
public async Task SetEntry(IEntryDetails? entry, CancellationToken cancellationToken)
|
||||
{
|
||||
Entry = entry;
|
||||
|
||||
@@ -65,5 +65,6 @@ public partial class ProfileDetailsViewModel : RoutableHostScreen<RoutableScreen
|
||||
EntryImagesViewModel = Entry != null ? _getEntryImagesViewModel(Entry) : null;
|
||||
|
||||
await _profileDescriptionViewModel.SetEntry(Entry, cancellationToken);
|
||||
_profileDescriptionViewModel.ReleaseInfoViewModel.Release = result.Data?.Entry?.LatestRelease;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user