Skip to content

Commit

Permalink
Merge pull request #6 from ryanjagdfeld/dev
Browse files Browse the repository at this point in the history
Version 1.0.2
  • Loading branch information
ryanjagdfeld authored Oct 24, 2024
2 parents b9a4192 + 9f80e17 commit 89a4771
Show file tree
Hide file tree
Showing 9 changed files with 51 additions and 20 deletions.
1 change: 1 addition & 0 deletions Client/Modules/RyanJagdfeld.Module.GitHubCard/Edit.razor
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
private string _username;
private string _repo;
private string _createdby;
private string _theme = "default";

private DateTime _createdon;
private string _modifiedby;
Expand Down
8 changes: 6 additions & 2 deletions Client/Modules/RyanJagdfeld.Module.GitHubCard/Index.razor
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ else
}
@if (_GitHubCards.Count != 0)
{
<Pager Items="@_GitHubCards" Format="Grid" ColumnClass="@_columnClasses">
<Pager Items="@_GitHubCards" Format="Grid" Class="@_classes" RowClass="@_rowClasses" ColumnClass="@_columnClasses">
<Row>
@OutputTemplate(context)
<div class="m-auto">
Expand All @@ -48,6 +48,8 @@ else
};

List<GitHubCard> _GitHubCards;
string _classes;
string _rowClasses;
string _columnClasses;
string _userTemplate;
string _repoTemplate;
Expand All @@ -58,7 +60,9 @@ else
try
{
_GitHubCards = await GitHubCardService.GetGitHubCardsAsync(ModuleState.ModuleId);
_columnClasses = SettingService.GetSetting(ModuleState.Settings, "ColumnClasses", "col-xl-4 col-lg-6 col-12");
_classes = SettingService.GetSetting(ModuleState.Settings, "Classes", "container-fluid");
_rowClasses = SettingService.GetSetting(ModuleState.Settings, "RowClasses", "row");
_columnClasses = SettingService.GetSetting(ModuleState.Settings, "ColumnClasses", "col-lg-6 col-12");
_userTemplate = SettingService.GetSetting(ModuleState.Settings, "UserTemplate", TemplateHelper.DefaultUserTemplate());
_repoTemplate = SettingService.GetSetting(ModuleState.Settings, "RepoTemplate", TemplateHelper.DefaultRepoTemplate());
_accessToken = SettingService.GetSetting(ModuleState.Settings, "AccessToken", string.Empty);
Expand Down
4 changes: 2 additions & 2 deletions Client/Modules/RyanJagdfeld.Module.GitHubCard/ModuleInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ public class ModuleInfo : IModule
{
Name = "GitHubCard",
Description = "A module for displaying GitHub cards by lepture.",
Version = "1.0.1",
Version = "1.0.2",
ServerManagerType = "RyanJagdfeld.Module.GitHubCard.Manager.GitHubCardManager, RyanJagdfeld.Module.GitHubCard.Server.Oqtane",
ReleaseVersions = "1.0.0,1.0.1",
ReleaseVersions = "1.0.0,1.0.1,1.0.2",
Dependencies = "RyanJagdfeld.Module.GitHubCard.Shared.Oqtane",
PackageName = "RyanJagdfeld.Module.GitHubCard"
};
Expand Down
16 changes: 15 additions & 1 deletion Client/Modules/RyanJagdfeld.Module.GitHubCard/Settings.razor
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,15 @@

<div class="container">
<div class="row mb-1 align-items-center">
<Label Class="col-sm-3" For="columnClasses" HelpText="Bootstrap classes for each column in the grid. NOTE: The card width can outgrow the box of the grid." ResourceKey="ColumnClass" ResourceType="@resourceType">Column CSS Class: </Label>
<Label Class="col-sm-3" For="classes" HelpText="Bootstrap class(es) for the parent div tag of the grid." ResourceKey="Class" ResourceType="@resourceType">Parent CSS Class: </Label>
<div class="col-sm-9">
<input id="classes" type="text" class="form-control" @bind="@_classes" />
</div>
<Label Class="col-sm-3" For="rowClasses" HelpText="Bootstrap class(es) for the parent row of the grid." ResourceKey="RowClass" ResourceType="@resourceType">Row CSS Class: </Label>
<div class="col-sm-9">
<input id="rowClasses" type="text" class="form-control" @bind="@_rowClasses" />
</div>
<Label Class="col-sm-3" For="columnClasses" HelpText="Bootstrap class(es) for each column in the grid." ResourceKey="ColumnClass" ResourceType="@resourceType">Column CSS Class: </Label>
<div class="col-sm-9">
<input id="columnClasses" type="text" class="form-control" @bind="@_columnClasses" />
</div>
Expand All @@ -32,6 +40,8 @@
public override string Title => "GitHubCard Settings";

string _accessToken;
string _classes;
string _rowClasses;
string _columnClasses;
string _userTemplate;
string _repoTemplate;
Expand All @@ -41,6 +51,8 @@
try
{
Dictionary<string, string> settings = await SettingService.GetModuleSettingsAsync(ModuleState.ModuleId);
_classes = SettingService.GetSetting(settings, "Classes", "container-fluid");
_rowClasses = SettingService.GetSetting(settings, "RowClasses", "row");
_columnClasses = SettingService.GetSetting(settings, "ColumnClasses", "col-lg-6 col-12");
_userTemplate = SettingService.GetSetting(settings, "UserTemplate", TemplateHelper.DefaultUserTemplate());
_repoTemplate = SettingService.GetSetting(settings, "RepoTemplate", TemplateHelper.DefaultRepoTemplate());
Expand All @@ -57,6 +69,8 @@
try
{
Dictionary<string, string> settings = await SettingService.GetModuleSettingsAsync(ModuleState.ModuleId);
SettingService.SetSetting(settings, "Classes", _classes);
SettingService.SetSetting(settings, "RowClasses", _rowClasses);
SettingService.SetSetting(settings, "ColumnClasses", _columnClasses);
SettingService.SetSetting(settings, "UserTemplate", _userTemplate);
SettingService.SetSetting(settings, "RepoTemplate", _repoTemplate);
Expand Down
14 changes: 13 additions & 1 deletion Client/Resources/RyanJagdfeld.Module.GitHubCard/Settings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
<value>Column CSS Class:</value>
</data>
<data name="ColumnClass.HelpText" xml:space="preserve">
<value>Bootstrap classes for each column in the grid. NOTE: The card width can outgrow the box of the grid.</value>
<value>Bootstrap class(es) for each column in the grid. </value>
</data>
<data name="UserTemplate.Text" xml:space="preserve">
<value>User Template:</value>
Expand All @@ -144,4 +144,16 @@
<data name="TokenCaution" xml:space="preserve">
<value>Please only use the token for server hosted applications or development purposes. It will be exposed to clients if used in WebAssembly (client). </value>
</data>
<data name="RowClasses.Text" xml:space="preserve">
<value>Row CSS Class:</value>
</data>
<data name="RowClasses.HelpText" xml:space="preserve">
<value>Bootstrap class(es) for the parent row of the grid.</value>
</data>
<data name="Classes.Text" xml:space="preserve">
<value>Parent CSS Class</value>
</data>
<data name="Classes.HelpText" xml:space="preserve">
<value>Bootstrap class(es) for the parent div tag of the grid.</value>
</data>
</root>
14 changes: 7 additions & 7 deletions Client/RyanJagdfeld.Module.GitHubCard.Client.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Version>1.0.1</Version>
<Version>1.0.2</Version>
<Authors>RyanJagdfeld</Authors>
<Company>RyanJagdfeld</Company>
<Description>A module for displaying GitHub cards by lepture.</Description>
Expand All @@ -13,12 +13,12 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.8" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Authentication" Version="8.0.8" />
<PackageReference Include="Microsoft.Extensions.Localization" Version="8.0.3" />
<PackageReference Include="System.Net.Http.Json" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Http" Version="8.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Localization" Version="2.2.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.10" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Authentication" Version="8.0.10" />
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="8.0.10" />
<PackageReference Include="Microsoft.Extensions.Localization" Version="8.0.10" />
<PackageReference Include="System.Net.Http.Json" Version="8.0.1" />
<PackageReference Include="Microsoft.Extensions.Http" Version="8.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion Package/RyanJagdfeld.Module.GitHubCard.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>RyanJagdfeld.Module.GitHubCard</id>
<version>1.0.1</version>
<version>1.0.2</version>
<authors>RyanJagdfeld</authors>
<owners>RyanJagdfeld</owners>
<title>GitHubCard</title>
Expand Down
10 changes: 5 additions & 5 deletions Server/RyanJagdfeld.Module.GitHubCard.Server.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<AddRazorSupportForMvc>true</AddRazorSupportForMvc>
<Version>1.0.1</Version>
<Version>1.0.2</Version>
<Product>RyanJagdfeld.Module.GitHubCard</Product>
<Authors>RyanJagdfeld</Authors>
<Company>RyanJagdfeld</Company>
Expand All @@ -19,10 +19,10 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Server" Version="8.0.8" />
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="8.0.8" />
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="8.0.8" />
<PackageReference Include="Microsoft.Extensions.Localization" Version="8.0.3" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Server" Version="8.0.10" />
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="8.0.10" />
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="8.0.10" />
<PackageReference Include="Microsoft.Extensions.Localization" Version="8.0.10" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion Shared/RyanJagdfeld.Module.GitHubCard.Shared.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Version>1.0.1</Version>
<Version>1.0.2</Version>
<Product>RyanJagdfeld.Module.GitHubCard</Product>
<Authors>RyanJagdfeld</Authors>
<Company>RyanJagdfeld</Company>
Expand Down

0 comments on commit 89a4771

Please sign in to comment.