mirror of
https://github.com/opelly27/WinStudentGoalTracker.git
synced 2026-05-20 07:37:38 +00:00
Desktop Update
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
<div class="card">
|
||||
<p class="content">{{ event().content }}</p>
|
||||
<div class="action-icons">
|
||||
<button class="icon-btn" title="Edit">✎</button>
|
||||
<button class="icon-btn" title="Delete">🗑</button>
|
||||
</div>
|
||||
<span class="author">{{ event().createdByName }}</span>
|
||||
<span class="date">{{ event().createdAt | date:'MMM d, y' }}</span>
|
||||
</div>
|
||||
@@ -0,0 +1,61 @@
|
||||
:host {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.card {
|
||||
background: #fff;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
|
||||
padding: 1.25rem 1.5rem;
|
||||
display: grid;
|
||||
grid-template-columns: 1fr auto;
|
||||
grid-template-rows: auto auto;
|
||||
gap: 0.75rem 1rem;
|
||||
}
|
||||
|
||||
.content {
|
||||
grid-column: 1;
|
||||
grid-row: 1;
|
||||
margin: 0;
|
||||
font-size: 0.9375rem;
|
||||
color: #333;
|
||||
line-height: 1.6;
|
||||
}
|
||||
|
||||
.action-icons {
|
||||
grid-column: 2;
|
||||
grid-row: 1;
|
||||
display: flex;
|
||||
gap: 0.5rem;
|
||||
align-self: start;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.author {
|
||||
grid-column: 1;
|
||||
grid-row: 2;
|
||||
font-size: 0.8125rem;
|
||||
font-weight: 600;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
.date {
|
||||
grid-column: 2;
|
||||
grid-row: 2;
|
||||
font-size: 0.8125rem;
|
||||
color: #888;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.icon-btn {
|
||||
background: none;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
font-size: 1rem;
|
||||
color: #888;
|
||||
padding: 0.125rem;
|
||||
}
|
||||
|
||||
.icon-btn:hover {
|
||||
color: #4f46e5;
|
||||
}
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { ProgressItem } from './progress-item';
|
||||
|
||||
describe('ProgressItem', () => {
|
||||
let component: ProgressItem;
|
||||
let fixture: ComponentFixture<ProgressItem>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
imports: [ProgressItem]
|
||||
})
|
||||
.compileComponents();
|
||||
|
||||
fixture = TestBed.createComponent(ProgressItem);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,26 @@
|
||||
import { Component, input } from '@angular/core';
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { ProgressEventDto } from '../../../shared/classes/progress-event.dto';
|
||||
|
||||
@Component({
|
||||
selector: 'app-progress-item',
|
||||
imports: [DatePipe],
|
||||
templateUrl: './progress-item.html',
|
||||
styleUrl: './progress-item.scss',
|
||||
})
|
||||
export class ProgressItem {
|
||||
|
||||
// ************************** Constructor **************************
|
||||
|
||||
// ************************** Declarations *************************
|
||||
|
||||
readonly event = input.required<ProgressEventDto>();
|
||||
|
||||
// ************************** Properties ***************************
|
||||
|
||||
// ************************ Public Methods *************************
|
||||
|
||||
// ************************ Event Handlers *************************
|
||||
|
||||
// ********************** Support Procedures ***********************
|
||||
}
|
||||
Reference in New Issue
Block a user