-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(builder): improve user experience
The user experience of the builder was absolutely abysmal, this commit aims to improve the UI of the rotation builder. Implements #7
- Loading branch information
1 parent
448e917
commit 771d8f2
Showing
27 changed files
with
691 additions
and
285 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { TestBed } from '@angular/core/testing'; | ||
|
||
import { RotationService } from './rotation.service'; | ||
|
||
describe('RotationService', () => { | ||
let service: RotationService; | ||
|
||
beforeEach(() => { | ||
TestBed.configureTestingModule({}); | ||
service = TestBed.inject(RotationService); | ||
}); | ||
|
||
it('should be created', () => { | ||
expect(service).toBeTruthy(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import {Injectable} from '@angular/core'; | ||
import {Observable, ReplaySubject, Subject} from "rxjs"; | ||
import {Rotation} from "../../modules/api/interfaces/rotation"; | ||
import {ApiService} from "../../modules/api/services/api.service"; | ||
import {RotationCreate} from "../../modules/api/interfaces/rotation-create"; | ||
|
||
@Injectable({ | ||
providedIn: 'root' | ||
}) | ||
export class RotationService { | ||
|
||
public readonly activeRotation$: Subject<Rotation | null> = new ReplaySubject(1); | ||
|
||
public constructor(private readonly apiService: ApiService) { | ||
} | ||
|
||
public saveRotation(rotation: RotationCreate): Observable<Rotation> { | ||
return this.apiService.createRotation(rotation); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 6 additions & 8 deletions
14
src/app/modules/actions/components/action/action.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.