diff options
| -rw-r--r-- | Pages/Gallery.razor | 8 | ||||
| -rw-r--r-- | Pages/ViewMedia.razor | 2 | ||||
| -rw-r--r-- | Server.csproj | 15 | ||||
| -rw-r--r-- | appsettings.Development.json | 3 | ||||
| -rw-r--r-- | wwwroot/js/keyboard.js | 5 |
5 files changed, 25 insertions, 8 deletions
diff --git a/Pages/Gallery.razor b/Pages/Gallery.razor index c037979..704b73d 100644 --- a/Pages/Gallery.razor +++ b/Pages/Gallery.razor @@ -29,9 +29,8 @@ <img src="/media/thumb/@(media.Guid)?h=200" width=@width height="200"/> </a> } + <div id="canary" style="height:1px;"></div> </div> - - <div id="canary"/> } <script suppress-error="BL9992"> @@ -42,7 +41,10 @@ await dotNetObject.invokeMethodAsync('LoadMedia', false); } }, - { threshold: [1] }); + { + root: document.getElementById('content'), + threshold: 0 + }); scrollObserver.observe(document.getElementById("canary")); } </script> diff --git a/Pages/ViewMedia.razor b/Pages/ViewMedia.razor index ce9d608..b5a33a2 100644 --- a/Pages/ViewMedia.razor +++ b/Pages/ViewMedia.razor @@ -67,7 +67,7 @@ @(file.LastWriteTime?.ToString("d") ?? "N/A") </td> <td title=@file.UploadTime>@(file.UploadTime.ToString("d"))</td> - <td title=@file.Filename> + <td title=@(file.Path is not null ? $"{file.Path.Replace('\\', '/')}/{file.Filename}" : file.Filename)> @if(sourceUrl is not null) { <a class="nondecorated" target="_blank" href=@sourceUrl>@file.Filename</a> } else { diff --git a/Server.csproj b/Server.csproj index 7ce894a..8396e3d 100644 --- a/Server.csproj +++ b/Server.csproj @@ -6,9 +6,9 @@ <ImplicitUsings>enable</ImplicitUsings> <AssemblyName>HyperBooru</AssemblyName> <RootNamespace>HyperBooru</RootNamespace> - <AssemblyVersion>0.2.0.0</AssemblyVersion> + <AssemblyVersion>0.3.0.0</AssemblyVersion> <FileVersion>$(AssemblyVersion)</FileVersion> - <Version>0.2-alpha</Version> + <Version>0.3-alpha</Version> <UserSecretsId>2907567f-4640-4581-8f4d-0977952d26bd</UserSecretsId> </PropertyGroup> @@ -20,6 +20,17 @@ <NoWarn>1701;1702;8618</NoWarn> </PropertyGroup> + <PropertyGroup> + <DefaultItemExcludes>$(DefaultItemExcludes);Data/**</DefaultItemExcludes> + </PropertyGroup> + + <ItemGroup> + <Compile Remove="Data/**" /> + <Content Remove="Data/**" /> + <EmbeddedResource Remove="Data/**" /> + <None Remove="Data/**" /> + </ItemGroup> + <ItemGroup> <PackageReference Include="Magick.NET-Q16-AnyCPU" Version="14.10.4" /> <PackageReference Include="Microsoft.EntityFrameworkCore" Version="8.0.23" /> diff --git a/appsettings.Development.json b/appsettings.Development.json index 6860045..5e5d828 100644 --- a/appsettings.Development.json +++ b/appsettings.Development.json @@ -6,5 +6,6 @@ "Microsoft.AspNetCore": "Warning", "HyperBooru.Services.OcrService": "Debug" } - } + }, + "DisableOcr": true } diff --git a/wwwroot/js/keyboard.js b/wwwroot/js/keyboard.js index 72ed3cb..59eec4c 100644 --- a/wwwroot/js/keyboard.js +++ b/wwwroot/js/keyboard.js @@ -11,7 +11,10 @@ async function keyDownHandler(e) { var element = document.activeElement; while(element = element.parentElement) { if(element.tagName == 'FORM') { - element.submit(); + element + .querySelectorAll('input,textarea') + .forEach(e => e.dispatchEvent(new Event('change'))); + element.requestSubmit(); e.preventDefault(); return; } |
