mirror of
https://github.com/booklore-app/booklore.git
synced 2026-02-18 00:17:53 +01:00
Fix showstopper bugs in v1.18.0 (#2399)
- Fix issue with hardcover toggle not being selectable - Resolve syncing problem with Booklore toggle - Address CSS warnings for cleaner styling Co-authored-by: acx10 <acx10@users.noreply.github.com>
This commit is contained in:
21
.github/workflows/draft-release.yml
vendored
21
.github/workflows/draft-release.yml
vendored
@@ -1,21 +0,0 @@
|
||||
name: Draft Release
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
draft-release:
|
||||
name: Update Draft Release
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
pull-requests: read
|
||||
|
||||
steps:
|
||||
- name: Draft Release Notes
|
||||
uses: release-drafter/release-drafter@v6
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
@@ -12,4 +12,5 @@ public class KoreaderUser {
|
||||
private String password;
|
||||
private String passwordMD5;
|
||||
private boolean syncEnabled;
|
||||
private boolean syncWithBookloreReader;
|
||||
}
|
||||
|
||||
@@ -4,14 +4,18 @@ import com.adityachandel.booklore.model.dto.KoreaderUser;
|
||||
import com.adityachandel.booklore.service.koreader.KoreaderUserService;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.mockito.*;
|
||||
import org.mockito.InjectMocks;
|
||||
import org.mockito.Mock;
|
||||
import org.mockito.MockitoAnnotations;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.*;
|
||||
import static org.mockito.Mockito.*;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.assertNull;
|
||||
import static org.mockito.Mockito.doNothing;
|
||||
import static org.mockito.Mockito.when;
|
||||
|
||||
class KoreaderUserControllerTest {
|
||||
|
||||
@@ -26,7 +30,7 @@ class KoreaderUserControllerTest {
|
||||
@BeforeEach
|
||||
void setUp() {
|
||||
try (AutoCloseable mocks = MockitoAnnotations.openMocks(this)) {
|
||||
user = new KoreaderUser(1L, "testuser", "pass", "md5", true);
|
||||
user = new KoreaderUser(1L, "testuser", "pass", "md5", true, true);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
|
||||
@@ -53,7 +53,7 @@ class KoreaderUserServiceTest {
|
||||
entity.setBookLoreUser(ownerEntity);
|
||||
entity.setUsername("kvUser");
|
||||
|
||||
dto = new KoreaderUser(10L, "kvUser", null, null, false);
|
||||
dto = new KoreaderUser(10L, "kvUser", null, null, false, true);
|
||||
when(koreaderUserMapper.toDto(any(KoreaderUserEntity.class))).thenReturn(dto);
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ class KoreaderUserServiceTest {
|
||||
|
||||
when(koreaderUserMapper.toDto(any(KoreaderUserEntity.class))).thenAnswer(invocation -> {
|
||||
KoreaderUserEntity u = invocation.getArgument(0);
|
||||
return new KoreaderUser(u.getId(), u.getUsername(), u.getPassword(), u.getPasswordMD5(), u.isSyncEnabled());
|
||||
return new KoreaderUser(u.getId(), u.getUsername(), u.getPassword(), u.getPasswordMD5(), u.isSyncEnabled(), u.isSyncWithBookloreReader());
|
||||
});
|
||||
|
||||
KoreaderUser result = service.upsertUser("userA", "passA");
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
@use 'sass:color';
|
||||
|
||||
// Variables
|
||||
$footer-bg: #1a1a1a;
|
||||
$text-primary: rgba(255, 255, 255, 0.95);
|
||||
@@ -95,7 +97,7 @@ $transition-fast: 150ms ease;
|
||||
}
|
||||
|
||||
&:hover:not(:disabled) {
|
||||
background: darken($active-color, 10%);
|
||||
background: color.adjust($active-color, $lightness: -10%);
|
||||
}
|
||||
|
||||
&:disabled {
|
||||
@@ -289,7 +291,7 @@ $transition-fast: 150ms ease;
|
||||
transition: all 0.2s ease;
|
||||
|
||||
&:hover:not(:disabled) {
|
||||
background: darken($active-color, 10%);
|
||||
background: color.adjust($active-color, $lightness: -10%);
|
||||
}
|
||||
|
||||
&:disabled {
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
@use 'sass:color';
|
||||
|
||||
// Variables
|
||||
$panel-bg: #1a1a1a;
|
||||
$text-primary: rgba(255, 255, 255, 0.95);
|
||||
@@ -134,7 +136,7 @@ $transition-normal: 200ms ease;
|
||||
background: rgba(255, 255, 255, 0.2);
|
||||
|
||||
&.active {
|
||||
background: lighten($active-color, 5%);
|
||||
background: color.adjust($active-color, $lightness: 5%);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -77,23 +77,21 @@
|
||||
</p-toggleswitch>
|
||||
<label class="setting-label">Hardcover</label>
|
||||
</div>
|
||||
@if (hardcoverEnabled) {
|
||||
<div class="setting-options">
|
||||
<div class="config-field">
|
||||
<div class="config-label-row">
|
||||
<label class="config-label">API Token</label>
|
||||
<app-external-doc-link docType="hardcover"></app-external-doc-link>
|
||||
</div>
|
||||
<input
|
||||
type="text"
|
||||
pInputText
|
||||
placeholder="Enter Hardcover API token"
|
||||
[(ngModel)]="hardcoverToken"
|
||||
(ngModelChange)="onTokenChange($event)"
|
||||
class="config-input"/>
|
||||
<div class="setting-options">
|
||||
<div class="config-field">
|
||||
<div class="config-label-row">
|
||||
<label class="config-label">API Token</label>
|
||||
<app-external-doc-link docType="hardcover"></app-external-doc-link>
|
||||
</div>
|
||||
<input
|
||||
type="text"
|
||||
pInputText
|
||||
placeholder="Enter Hardcover API token"
|
||||
[(ngModel)]="hardcoverToken"
|
||||
(ngModelChange)="onTokenChange($event)"
|
||||
class="config-input"/>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="setting-item">
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.author-universe-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.book-formats-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.language-chart-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.metadata-score-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.page-count-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.publication-timeline-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.publication-trend-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.reading-journey-container {
|
||||
width: 100%;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@import '../../../_chart-shared';
|
||||
@use '../../../_chart-shared';
|
||||
|
||||
.top-items-container {
|
||||
width: 100%;
|
||||
|
||||
Reference in New Issue
Block a user