mirror of
https://github.com/Kareadita/Kavita.git
synced 2026-03-06 17:15:23 -05:00
* SeriesGroup tag can now have comma separated value to allow a series to be a part of multiple collections. * Added a missing unit test * Refactored how collection tags are created to work in the scan loop reliably. * Added a unit test for RemoveTagsWithoutSeries * Fixed a bug in reading list title generation to avoid Volume 0 if the underlying file had a title set. Fixed a misconfigured unit test. * On User stats page, don't show the user selector on reading history, despite if youre an admin. Cleaned up how we show days with 0 reading events to be more clear. * Refactored the name of a component to reflect what it does * Removed plugin not using * Fix an issue where coalescing a key in epub might have multiple html files ending with the key. In this case, let's take the first. * Added PikaPods to the Readme * Tried to fix layout shift for charts, but need Robbie's help * Chart styling # Added: - Added: Added styling to force charts into their respective containers. # Removed: - Removed: Removed code blocking charts from being visible on mobile. * Merge conflict --------- Co-authored-by: Robbie Davis <robbie@therobbiedavis.com>
54 lines
2.5 KiB
HTML
54 lines
2.5 KiB
HTML
<ng-container>
|
|
<div class="dashboard-card-content">
|
|
<div class="row g-0 mb-2 align-items-center">
|
|
<div class="col-4">
|
|
<h4>Top Readers</h4>
|
|
</div>
|
|
<div class="col-8">
|
|
<form [formGroup]="formGroup" class="d-inline-flex float-end">
|
|
<div class="d-flex me-1" *ngIf="isAdmin && !individualUserMode">
|
|
<label for="time-select-read-by-day" class="form-check-label"></label>
|
|
<select id="time-select-read-by-day" class="form-select" formControlName="users"
|
|
[class.is-invalid]="formGroup.get('users')?.invalid && formGroup.get('users')?.touched">
|
|
<option [value]="0">All Users</option>
|
|
<option *ngFor="let item of users$ | async" [value]="item.id">{{item.username}}</option>
|
|
</select>
|
|
</div>
|
|
<div class="d-flex">
|
|
<label for="time-select-top-reads" class="form-check-label"></label>
|
|
<select id="time-select-top-reads" class="form-select" formControlName="days"
|
|
[class.is-invalid]="formGroup.get('days')?.invalid && formGroup.get('days')?.touched">
|
|
<option *ngFor="let item of timePeriods" [value]="item.value">{{item.title}}</option>
|
|
</select>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
<div class="row g-0">
|
|
<ng-container *ngIf="data$ | async as data">
|
|
<ngx-charts-line-chart
|
|
*ngIf="data.length > 0; else noData"
|
|
class="dark"
|
|
[legend]="true"
|
|
legendTitle="Formats"
|
|
[showXAxisLabel]="true"
|
|
[showYAxisLabel]="true"
|
|
[xAxis]="true"
|
|
[yAxis]="true"
|
|
[showGridLines]="false"
|
|
[showRefLines]="true"
|
|
[roundDomains]="true"
|
|
[autoScale]="true"
|
|
xAxisLabel="Time"
|
|
yAxisLabel="Reading Activity"
|
|
[timeline]="false"
|
|
[results]="data"
|
|
>
|
|
</ngx-charts-line-chart>
|
|
</ng-container>
|
|
</div>
|
|
<ng-template #noData>
|
|
No Reading progress
|
|
</ng-template>
|
|
</div>
|
|
</ng-container> |