Skip to content

Commit

Permalink
Merge pull request #28 from irohalab/history-page-bugfix
Browse files Browse the repository at this point in the history
Bugfix for history page
  • Loading branch information
EverettSummer authored Jan 14, 2024
2 parents f77b369 + 974bf81 commit 2e1d834
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "mira-ui",
"version": "2.8.0",
"version": "2.8.1",
"scripts": {
"ng": "ng",
"start": "ng serve",
Expand Down
2 changes: 1 addition & 1 deletion src/app/home/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ <h2>{{siteTitle}}</h2>
</main>

<footer id="page-footer" [ngClass]="currentRouteName + (sidebarActive === 'active' ? ' sidebar-active': '')"
*ngIf="currentRouteName !== 'Bangumi' && currentRouteName !== 'Favorite'">
*ngIf="currentRouteName !== 'Bangumi' && currentRouteName !== 'Favorite' && currentRouteName !== 'History'">
<div class="copyright-content">&copy;2020 - {{today | date:'y'}} Iroha Lab, All rights reserved.</div>
<div class="credits">Powered By <a target="_blank" href="https://github.com/irohalab/Albireo">Project Mira</a></div>
<div class="ui horizontal bulleted link list" [ngClass]="{inverted: isDarkTheme}">
Expand Down
2 changes: 2 additions & 0 deletions src/app/home/home.less
Original file line number Diff line number Diff line change
Expand Up @@ -132,13 +132,15 @@

&.Default.sidebar-active,
&.Bangumi.sidebar-active,
&.History.sidebar-active,
&.BangumiDetail.sidebar-active {
padding-left: 15em;
}

@media (max-width: 1330px) {
&.Default.sidebar-active,
&.Bangumi.sidebar-active,
&.History.sidebar-active,
&.BangumiDetail.sidebar-active {
padding-left: 0;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,9 @@ export class HistoryCardComponent implements OnInit, OnDestroy {

private setImage(): void {
const videoFile = this.watchProgress.video_file;
if (!videoFile.kf_image_path_list || videoFile.kf_image_path_list.length === 0) {
return;
}
const tileSize = videoFile.kf_tile_size;
const scaledX = getRemPixel(THUMBNAIL_WIDTH);
const scaledY = getRemPixel(THUMBNAIL_HEIGHT);
Expand Down
2 changes: 1 addition & 1 deletion src/app/home/my-history/my-history.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export class MyHistoryComponent implements OnInit, OnDestroy {
this._watchService.list_history(offset, this.countPerPage)
.subscribe({
next: ({data, total}) => {
this.watchProgressList = data;
this.watchProgressList = data.concat(data).concat(data);
this.total = total;
this.isLoading = false;
},
Expand Down
1 change: 1 addition & 0 deletions src/app/home/my-history/my-history.less
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
padding-top: 2rem;
width: 100%;
height: 100%;
overflow-y: auto;
background-color: #f0f0f0;

&.dark-theme {
Expand Down

0 comments on commit 2e1d834

Please sign in to comment.