@tehw0lf/git-portfolio 0.0.1 → 0.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (24) hide show
  1. package/README.md +1 -20
  2. package/{esm2015/index.js → esm2020/index.mjs} +0 -0
  3. package/esm2020/lib/git-portfolio.component.mjs +138 -0
  4. package/{esm2015/lib/git-portfolio.module.js → esm2020/lib/git-portfolio.module.mjs} +5 -5
  5. package/esm2020/lib/git-provider.service.mjs +69 -0
  6. package/{esm2015/lib/octicon.directive.js → esm2020/lib/octicon.directive.mjs} +4 -4
  7. package/esm2020/lib/repo-card/repo-card.component.mjs +44 -0
  8. package/{esm2015/lib/types/git-provider-config-type.js → esm2020/lib/types/git-provider-config-type.mjs} +0 -0
  9. package/{esm2015/lib/types/git-providers-type.js → esm2020/lib/types/git-providers-type.mjs} +0 -0
  10. package/{esm2015/lib/types/git-repositories-type.js → esm2020/lib/types/git-repositories-type.mjs} +0 -0
  11. package/{esm2015/lib/types/git-repository-type.js → esm2020/lib/types/git-repository-type.mjs} +0 -0
  12. package/{esm2015/tehw0lf-git-portfolio.js → esm2020/tehw0lf-git-portfolio.mjs} +0 -0
  13. package/fesm2015/tehw0lf-git-portfolio.mjs +350 -0
  14. package/fesm2015/tehw0lf-git-portfolio.mjs.map +1 -0
  15. package/fesm2020/tehw0lf-git-portfolio.mjs +349 -0
  16. package/fesm2020/tehw0lf-git-portfolio.mjs.map +1 -0
  17. package/package.json +28 -14
  18. package/bundles/tehw0lf-git-portfolio.umd.js +0 -393
  19. package/bundles/tehw0lf-git-portfolio.umd.js.map +0 -1
  20. package/esm2015/lib/git-portfolio.component.js +0 -140
  21. package/esm2015/lib/git-provider.service.js +0 -70
  22. package/esm2015/lib/repo-card/repo-card.component.js +0 -49
  23. package/fesm2015/tehw0lf-git-portfolio.js +0 -357
  24. package/fesm2015/tehw0lf-git-portfolio.js.map +0 -1
@@ -0,0 +1,349 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Injectable, Directive, Input, EventEmitter, Component, Output, NgModule } from '@angular/core';
3
+ import { BehaviorSubject, zip, of, Subject } from 'rxjs';
4
+ import { tap, map, takeUntil } from 'rxjs/operators';
5
+ import * as i1 from '@angular/common/http';
6
+ import { HttpClientModule } from '@angular/common/http';
7
+ import * as i2$1 from '@angular/material/progress-spinner';
8
+ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
9
+ import * as i1$1 from '@angular/material/card';
10
+ import { MatCardModule } from '@angular/material/card';
11
+ import * as i2 from '@angular/material/button';
12
+ import { MatButtonModule } from '@angular/material/button';
13
+ import * as i4 from '@angular/common';
14
+ import { CommonModule } from '@angular/common';
15
+ import * as i4$1 from '@angular/flex-layout/extended';
16
+ import * as i5 from '@angular/flex-layout/flex';
17
+ import * as i7 from '@angular/cdk/clipboard';
18
+ import { ClipboardModule } from '@angular/cdk/clipboard';
19
+ import { FlexLayoutModule } from '@angular/flex-layout';
20
+ import { BrowserModule } from '@angular/platform-browser';
21
+ import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
22
+
23
+ /* eslint-disable @typescript-eslint/naming-convention */
24
+ class GitRepository {
25
+ }
26
+
27
+ class GitProviderService {
28
+ constructor(http) {
29
+ this.http = http;
30
+ this.loadingStateSubject = new BehaviorSubject(true);
31
+ this.repositorySubject = new BehaviorSubject({});
32
+ }
33
+ get loading() {
34
+ return this.loadingStateSubject.asObservable();
35
+ }
36
+ getRepositories(gitProviderUserNames) {
37
+ if (this.repositorySubject.value.github === undefined &&
38
+ this.repositorySubject.value.gitlab === undefined) {
39
+ this.fetchRepositories(gitProviderUserNames)
40
+ .pipe(tap((repositories) => {
41
+ this.repositorySubject.next(repositories);
42
+ this.loadingStateSubject.next(false);
43
+ }))
44
+ .subscribe();
45
+ }
46
+ return this.repositorySubject.asObservable();
47
+ }
48
+ fetchRepositories(gitProviderUserNames) {
49
+ return zip(this.fetchGithubRepositories(gitProviderUserNames?.github ?? ''), this.fetchGitlabRepositories(gitProviderUserNames?.gitlab ?? '')).pipe(map((gitRepositoryArray) => {
50
+ const repositories = {
51
+ github: this.filterAndSortGitRepositories(gitRepositoryArray[0]),
52
+ gitlab: this.filterAndSortGitRepositories(gitRepositoryArray[1])
53
+ };
54
+ return repositories;
55
+ }));
56
+ }
57
+ filterAndSortGitRepositories(gitRepositoryArray) {
58
+ return {
59
+ own: gitRepositoryArray
60
+ .filter((gitRepository) => !gitRepository.fork)
61
+ .sort((repoA, repoB) => (repoB.stargazers_count ?? 0) - (repoA.stargazers_count ?? 0)),
62
+ forked: gitRepositoryArray
63
+ .filter((gitRepository) => gitRepository.fork)
64
+ .sort((repoA, repoB) => (repoB.stargazers_count ?? 0) - (repoA.stargazers_count ?? 0))
65
+ };
66
+ }
67
+ fetchGithubRepositories(githubUser) {
68
+ if (githubUser !== '') {
69
+ return this.http.get(`https://api.github.com/users/${githubUser}/repos`);
70
+ }
71
+ return of([new GitRepository()]);
72
+ }
73
+ fetchGitlabRepositories(gitlabUser) {
74
+ if (gitlabUser !== '') {
75
+ return this.http.get(`https://gitlab.com/api/v4/users/${gitlabUser}/projects`);
76
+ }
77
+ return of([new GitRepository()]);
78
+ }
79
+ }
80
+ GitProviderService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitProviderService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
81
+ GitProviderService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitProviderService, providedIn: 'root' });
82
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitProviderService, decorators: [{
83
+ type: Injectable,
84
+ args: [{
85
+ providedIn: 'root'
86
+ }]
87
+ }], ctorParameters: function () { return [{ type: i1.HttpClient }]; } });
88
+
89
+ /* eslint-disable no-shadow */
90
+ var GitProviders;
91
+ (function (GitProviders) {
92
+ GitProviders["github"] = "GitHub";
93
+ GitProviders["gitlab"] = "GitLab";
94
+ })(GitProviders || (GitProviders = {}));
95
+
96
+ // eslint-disable-next-line @typescript-eslint/no-var-requires
97
+ const octicons = require('@primer/octicons');
98
+ class OcticonDirective {
99
+ constructor(elementRef, renderer) {
100
+ this.elementRef = elementRef;
101
+ this.renderer = renderer;
102
+ }
103
+ ngOnInit() {
104
+ const el = this.elementRef.nativeElement;
105
+ if (this.octicon) {
106
+ if (octicons[this.octicon] !== undefined) {
107
+ el.innerHTML = octicons[this.octicon].toSVG();
108
+ const icon = el.firstChild;
109
+ if (this.color && icon) {
110
+ this.renderer.setStyle(icon, 'fill', this.color);
111
+ }
112
+ if (this.width && icon) {
113
+ this.renderer.setStyle(icon, 'width', this.width);
114
+ this.renderer.setStyle(icon, 'height', this.width);
115
+ }
116
+ }
117
+ else {
118
+ el.innerHTML = octicons['alert'].toSVG();
119
+ this.renderer.setStyle(el.firstChild, 'fill', 'red');
120
+ }
121
+ }
122
+ }
123
+ }
124
+ OcticonDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OcticonDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
125
+ OcticonDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0", type: OcticonDirective, selector: "[octicon]", inputs: { octicon: "octicon", color: "color", width: "width" }, ngImport: i0 });
126
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OcticonDirective, decorators: [{
127
+ type: Directive,
128
+ args: [{
129
+ // eslint-disable-next-line @angular-eslint/directive-selector
130
+ selector: '[octicon]'
131
+ }]
132
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }]; }, propDecorators: { octicon: [{
133
+ type: Input
134
+ }], color: [{
135
+ type: Input
136
+ }], width: [{
137
+ type: Input
138
+ }] } });
139
+
140
+ // eslint-disable-next-line @typescript-eslint/no-var-requires
141
+ const githubLanguageColors = require('github-language-colors/colors.json');
142
+ class RepoCardComponent {
143
+ constructor() {
144
+ this.isCopied = false;
145
+ this.copiedToClipboardEvent = new EventEmitter();
146
+ this.githubLanguageColors = githubLanguageColors;
147
+ //
148
+ }
149
+ copiedToClipboard() {
150
+ this.copiedToClipboardEvent.emit();
151
+ }
152
+ }
153
+ RepoCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: RepoCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
154
+ RepoCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.0", type: RepoCardComponent, selector: "repo-card", inputs: { backgroundColor: "backgroundColor", backdropFilter: "backdropFilter", buttonColor: "buttonColor", cardColor: "cardColor", gitRepo: "gitRepo", isCopied: "isCopied" }, outputs: { copiedToClipboardEvent: "copiedToClipboardEvent" }, ngImport: i0, template: "<mat-card\n [ngStyle]=\"{\n color: cardColor,\n 'background-color': backgroundColor,\n 'backdrop-filter': backdropFilter\n }\"\n>\n <mat-card-header>\n <div\n mat-card-avatar\n [ngStyle]=\"{\n 'background-image':\n 'url(' +\n (gitRepo.owner?.avatar_url || gitRepo.namespace?.avatar_url) +\n ')',\n 'background-size': 'cover',\n 'border-radius': 0\n }\"\n ></div>\n <mat-card-title\n ><a\n mat-button\n [ngStyle]=\"{ color: buttonColor }\"\n target=\"_blank\"\n href=\"{{ gitRepo.html_url || gitRepo.web_url }}\"\n >\n {{ gitRepo.name }}\n </a>\n </mat-card-title>\n <mat-card-subtitle fxLayout=\"row\" fxLayoutGap=\"12px\">\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div\n [ngStyle]=\"{\n 'background-color':\n gitRepo.language !== undefined\n ? githubLanguageColors[gitRepo.language]\n : 'transparent'\n }\"\n class=\"language-icon\"\n ></div>\n <div>{{ gitRepo.language }}</div>\n </div>\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div octicon=\"star\" color=\"gold\"></div>\n <div>{{ gitRepo.stargazers_count || gitRepo.star_count || 0 }}</div>\n </div>\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div octicon=\"repo-forked\" color=\"#437da8\"></div>\n <div>{{ gitRepo.forks_count }}</div>\n </div>\n <div\n *ngIf=\"gitRepo.open_issues_count\"\n class=\"info-item\"\n fxLayout=\"row\"\n fxLayoutGap=\"5px\"\n >\n <div octicon=\"issue-opened\" color=\"rgb(56, 224, 56)\"></div>\n <div>{{ gitRepo.open_issues_count }}</div>\n </div>\n </mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <p>{{ gitRepo.description }}</p>\n </mat-card-content>\n <mat-card-footer fxLayout=\"row\" fxLayoutGap=\"12px\">\n <span class=\"mat-footer-cell\" fxFlex>\n <span class=\"footer-span\" [ngStyle]=\"{ color: cardColor }\"\n >Created: {{ gitRepo.created_at | date }}</span\n >\n <span class=\"footer-span\" [ngStyle]=\"{ color: cardColor }\"\n >Updated:\n {{ gitRepo.pushed_at || gitRepo.last_activity_at | date }}</span\n >\n </span>\n <span class=\"mat-footer-cell\">\n <button\n [ngStyle]=\"{ color: buttonColor }\"\n mat-button\n [cdkCopyToClipboard]=\"\n gitRepo.clone_url || gitRepo.http_url_to_repo || ''\n \"\n (cdkCopyToClipboardCopied)=\"copiedToClipboard()\"\n class=\"clipboard-button\"\n >\n <span class=\"mat-button-wrapper\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div\n *ngIf=\"isCopied\"\n octicon=\"check\"\n color=\"#38e038\"\n width=\"24\"\n ></div>\n <div octicon=\"paste\" color=\"#cc7832\" width=\"24px\"></div>\n <span>Copy URL</span>\n </span>\n </button>\n </span>\n </mat-card-footer>\n</mat-card>\n", styles: [".clipboard-button{line-height:24px!important;padding:0;margin-bottom:0}.clipboard-button span{font-size:20px}.mat-button{vertical-align:middle;line-height:36px;font-size:24px;margin:0 10px 0 0;text-align:center;text-decoration:none}.mat-card{display:flex;flex-direction:column;width:450px}.mat-card-avatar{height:53px;width:53px}.mat-card-subtitle{padding-left:16px}.mat-card-header{flex-shrink:0}.mat-card-content{flex-grow:1;overflow:auto}.mat-card-footer{padding:16px}.footer-span{display:block;font-size:12px}.language-icon{height:12px;width:12px;border-radius:50%;margin-top:2px}\n"], components: [{ type: i1$1.MatCard, selector: "mat-card", exportAs: ["matCard"] }, { type: i1$1.MatCardHeader, selector: "mat-card-header" }, { type: i2.MatAnchor, selector: "a[mat-button], a[mat-raised-button], a[mat-icon-button], a[mat-fab], a[mat-mini-fab], a[mat-stroked-button], a[mat-flat-button]", inputs: ["disabled", "disableRipple", "color", "tabIndex"], exportAs: ["matButton", "matAnchor"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i4.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i4$1.DefaultStyleDirective, selector: " [ngStyle], [ngStyle.xs], [ngStyle.sm], [ngStyle.md], [ngStyle.lg], [ngStyle.xl], [ngStyle.lt-sm], [ngStyle.lt-md], [ngStyle.lt-lg], [ngStyle.lt-xl], [ngStyle.gt-xs], [ngStyle.gt-sm], [ngStyle.gt-md], [ngStyle.gt-lg]", inputs: ["ngStyle", "ngStyle.xs", "ngStyle.sm", "ngStyle.md", "ngStyle.lg", "ngStyle.xl", "ngStyle.lt-sm", "ngStyle.lt-md", "ngStyle.lt-lg", "ngStyle.lt-xl", "ngStyle.gt-xs", "ngStyle.gt-sm", "ngStyle.gt-md", "ngStyle.gt-lg"] }, { type: i1$1.MatCardAvatar, selector: "[mat-card-avatar], [matCardAvatar]" }, { type: i1$1.MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { type: i1$1.MatCardSubtitle, selector: "mat-card-subtitle, [mat-card-subtitle], [matCardSubtitle]" }, { type: i5.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { type: i5.DefaultLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg]", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { type: OcticonDirective, selector: "[octicon]", inputs: ["octicon", "color", "width"] }, { type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.MatCardContent, selector: "mat-card-content, [mat-card-content], [matCardContent]" }, { type: i1$1.MatCardFooter, selector: "mat-card-footer" }, { type: i5.DefaultFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg]", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }, { type: i7.CdkCopyToClipboard, selector: "[cdkCopyToClipboard]", inputs: ["cdkCopyToClipboard", "cdkCopyToClipboardAttempts"], outputs: ["cdkCopyToClipboardCopied"] }], pipes: { "date": i4.DatePipe } });
155
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: RepoCardComponent, decorators: [{
156
+ type: Component,
157
+ args: [{ selector: 'repo-card', template: "<mat-card\n [ngStyle]=\"{\n color: cardColor,\n 'background-color': backgroundColor,\n 'backdrop-filter': backdropFilter\n }\"\n>\n <mat-card-header>\n <div\n mat-card-avatar\n [ngStyle]=\"{\n 'background-image':\n 'url(' +\n (gitRepo.owner?.avatar_url || gitRepo.namespace?.avatar_url) +\n ')',\n 'background-size': 'cover',\n 'border-radius': 0\n }\"\n ></div>\n <mat-card-title\n ><a\n mat-button\n [ngStyle]=\"{ color: buttonColor }\"\n target=\"_blank\"\n href=\"{{ gitRepo.html_url || gitRepo.web_url }}\"\n >\n {{ gitRepo.name }}\n </a>\n </mat-card-title>\n <mat-card-subtitle fxLayout=\"row\" fxLayoutGap=\"12px\">\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div\n [ngStyle]=\"{\n 'background-color':\n gitRepo.language !== undefined\n ? githubLanguageColors[gitRepo.language]\n : 'transparent'\n }\"\n class=\"language-icon\"\n ></div>\n <div>{{ gitRepo.language }}</div>\n </div>\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div octicon=\"star\" color=\"gold\"></div>\n <div>{{ gitRepo.stargazers_count || gitRepo.star_count || 0 }}</div>\n </div>\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div octicon=\"repo-forked\" color=\"#437da8\"></div>\n <div>{{ gitRepo.forks_count }}</div>\n </div>\n <div\n *ngIf=\"gitRepo.open_issues_count\"\n class=\"info-item\"\n fxLayout=\"row\"\n fxLayoutGap=\"5px\"\n >\n <div octicon=\"issue-opened\" color=\"rgb(56, 224, 56)\"></div>\n <div>{{ gitRepo.open_issues_count }}</div>\n </div>\n </mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <p>{{ gitRepo.description }}</p>\n </mat-card-content>\n <mat-card-footer fxLayout=\"row\" fxLayoutGap=\"12px\">\n <span class=\"mat-footer-cell\" fxFlex>\n <span class=\"footer-span\" [ngStyle]=\"{ color: cardColor }\"\n >Created: {{ gitRepo.created_at | date }}</span\n >\n <span class=\"footer-span\" [ngStyle]=\"{ color: cardColor }\"\n >Updated:\n {{ gitRepo.pushed_at || gitRepo.last_activity_at | date }}</span\n >\n </span>\n <span class=\"mat-footer-cell\">\n <button\n [ngStyle]=\"{ color: buttonColor }\"\n mat-button\n [cdkCopyToClipboard]=\"\n gitRepo.clone_url || gitRepo.http_url_to_repo || ''\n \"\n (cdkCopyToClipboardCopied)=\"copiedToClipboard()\"\n class=\"clipboard-button\"\n >\n <span class=\"mat-button-wrapper\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div\n *ngIf=\"isCopied\"\n octicon=\"check\"\n color=\"#38e038\"\n width=\"24\"\n ></div>\n <div octicon=\"paste\" color=\"#cc7832\" width=\"24px\"></div>\n <span>Copy URL</span>\n </span>\n </button>\n </span>\n </mat-card-footer>\n</mat-card>\n", styles: [".clipboard-button{line-height:24px!important;padding:0;margin-bottom:0}.clipboard-button span{font-size:20px}.mat-button{vertical-align:middle;line-height:36px;font-size:24px;margin:0 10px 0 0;text-align:center;text-decoration:none}.mat-card{display:flex;flex-direction:column;width:450px}.mat-card-avatar{height:53px;width:53px}.mat-card-subtitle{padding-left:16px}.mat-card-header{flex-shrink:0}.mat-card-content{flex-grow:1;overflow:auto}.mat-card-footer{padding:16px}.footer-span{display:block;font-size:12px}.language-icon{height:12px;width:12px;border-radius:50%;margin-top:2px}\n"] }]
158
+ }], ctorParameters: function () { return []; }, propDecorators: { backgroundColor: [{
159
+ type: Input
160
+ }], backdropFilter: [{
161
+ type: Input
162
+ }], buttonColor: [{
163
+ type: Input
164
+ }], cardColor: [{
165
+ type: Input
166
+ }], gitRepo: [{
167
+ type: Input
168
+ }], isCopied: [{
169
+ type: Input
170
+ }], copiedToClipboardEvent: [{
171
+ type: Output
172
+ }] } });
173
+
174
+ class GitPortfolioComponent {
175
+ constructor(gitProviderService) {
176
+ this.gitProviderService = gitProviderService;
177
+ this.backgroundColor = 'rgba(34, 34, 34, 0.75)';
178
+ this.backdropFilter = 'blur(50px)';
179
+ this.buttonColor = '#cc7832';
180
+ this.cardColor = 'lightgray';
181
+ this.gitProviderConfig = {
182
+ github: 'tehw0lf',
183
+ gitlab: 'tehw0lf'
184
+ };
185
+ this.showForked = true;
186
+ this.showOwn = true;
187
+ this.gitProviders = GitProviders;
188
+ this.unsubscribe$ = new Subject();
189
+ this.loading = this.gitProviderService.loading;
190
+ }
191
+ ngOnInit() {
192
+ this.getRepositories();
193
+ }
194
+ ngOnDestroy() {
195
+ this.unsubscribe$.next();
196
+ this.unsubscribe$.complete();
197
+ }
198
+ copyToClipboard(githubRepo) {
199
+ this.currentRepo = githubRepo;
200
+ }
201
+ isCopiedToClipboard(githubRepo) {
202
+ if (!this.currentRepo) {
203
+ return false;
204
+ }
205
+ return this.currentRepo.id === githubRepo.id ? true : false;
206
+ }
207
+ getRepositories() {
208
+ this.gitRepositories$ = this.gitProviderService
209
+ .getRepositories(this.gitProviderConfig)
210
+ .pipe(takeUntil(this.unsubscribe$));
211
+ }
212
+ getOwnGitRepositories(gitRepositories, gitProvider) {
213
+ if (gitRepositories) {
214
+ switch (gitProvider) {
215
+ case 'github':
216
+ if (gitRepositories.github) {
217
+ return gitRepositories.github.own;
218
+ }
219
+ else {
220
+ return [];
221
+ }
222
+ case 'gitlab':
223
+ if (gitRepositories.gitlab) {
224
+ return gitRepositories.gitlab.own;
225
+ }
226
+ else {
227
+ return [];
228
+ }
229
+ default:
230
+ return [];
231
+ }
232
+ }
233
+ else {
234
+ return [];
235
+ }
236
+ }
237
+ getForkedGitRepositories(gitRepositories, gitProvider) {
238
+ if (gitRepositories) {
239
+ switch (gitProvider) {
240
+ case 'github':
241
+ if (gitRepositories.github) {
242
+ return gitRepositories.github.forked;
243
+ }
244
+ else {
245
+ return [];
246
+ }
247
+ case 'gitlab':
248
+ if (gitRepositories.gitlab) {
249
+ return gitRepositories.gitlab.forked;
250
+ }
251
+ else {
252
+ return [];
253
+ }
254
+ default:
255
+ return [];
256
+ }
257
+ }
258
+ else {
259
+ return [];
260
+ }
261
+ }
262
+ hasRepositories(gitRepositories, gitProvider, type) {
263
+ if (gitRepositories) {
264
+ switch (gitProvider) {
265
+ case 'github':
266
+ if (gitRepositories.github) {
267
+ return gitRepositories.github[type].length > 0;
268
+ }
269
+ break;
270
+ case 'gitlab':
271
+ if (gitRepositories.gitlab) {
272
+ return gitRepositories.gitlab[type].length > 0;
273
+ }
274
+ break;
275
+ }
276
+ }
277
+ return false;
278
+ }
279
+ }
280
+ GitPortfolioComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitPortfolioComponent, deps: [{ token: GitProviderService }], target: i0.ɵɵFactoryTarget.Component });
281
+ GitPortfolioComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.0", type: GitPortfolioComponent, selector: "git-portfolio", inputs: { backgroundColor: "backgroundColor", backdropFilter: "backdropFilter", buttonColor: "buttonColor", cardColor: "cardColor", gitProviderConfig: "gitProviderConfig", showForked: "showForked", showOwn: "showOwn" }, ngImport: i0, template: "<div *ngIf=\"gitRepositories$ | async as gitRepositories\">\n <div *ngFor=\"let gitProvider of gitProviders | keyvalue\">\n <h1>{{ gitProvider.value }}</h1>\n <div *ngIf=\"showOwn\">\n <h2 class=\"mat-headline\">Own Repos</h2>\n <div\n fxLayout=\"row wrap\"\n fxLayout.lt-sm=\"column\"\n fxLayoutAlign=\"flex-start\"\n >\n <div *ngIf=\"(loading | async) === true\">\n <mat-spinner></mat-spinner>\n </div>\n <repo-card\n *ngFor=\"\n let gitRepo of getOwnGitRepositories(\n gitRepositories,\n gitProvider.key\n )\n \"\n [backgroundColor]=\"backgroundColor\"\n [backdropFilter]=\"backdropFilter\"\n [buttonColor]=\"buttonColor\"\n [cardColor]=\"cardColor\"\n [gitRepo]=\"gitRepo\"\n [isCopied]=\"isCopiedToClipboard(gitRepo)\"\n (copiedToClipboardEvent)=\"copyToClipboard(gitRepo)\"\n class=\"repository-card\"\n fxFlex=\"0 1 calc(33.3% - 32px)\"\n fxFlex.lt-md=\"0 1 calc(50% - 32px)\"\n fxFlex.lt-sm=\"100%\"\n fxLayoutAlign=\"stretch\"\n >\n </repo-card>\n <div\n *ngIf=\"\n (loading | async) === false &&\n !hasRepositories(gitRepositories, gitProvider.key, 'own')\n \"\n >\n This user has not created any repositories yet\n </div>\n </div>\n </div>\n <div *ngIf=\"showForked\">\n <h2 class=\"mat-headline\">Forked Repos</h2>\n <div\n fxLayout=\"row wrap\"\n fxLayout.lt-sm=\"column\"\n fxLayoutAlign=\"flex-start\"\n >\n <div *ngIf=\"(loading | async) === true\">\n <mat-spinner></mat-spinner>\n </div>\n <repo-card\n *ngFor=\"\n let gitRepo of getForkedGitRepositories(\n gitRepositories,\n gitProvider.key\n )\n \"\n [backgroundColor]=\"backgroundColor\"\n [backdropFilter]=\"backdropFilter\"\n [buttonColor]=\"buttonColor\"\n [cardColor]=\"cardColor\"\n [gitRepo]=\"gitRepo\"\n [isCopied]=\"isCopiedToClipboard(gitRepo)\"\n (copiedToClipboardEvent)=\"copyToClipboard(gitRepo)\"\n class=\"repository-card\"\n fxFlex=\"0 1 calc(33.3% - 32px)\"\n fxFlex.lt-md=\"0 1 calc(50% - 32px)\"\n fxFlex.lt-sm=\"100%\"\n fxLayoutAlign=\"stretch\"\n ></repo-card>\n <div\n *ngIf=\"\n (loading | async) === false &&\n !hasRepositories(gitRepositories, gitProvider.key, 'forked')\n \"\n >\n This user has not forked any repositories yet\n </div>\n </div>\n </div>\n </div>\n</div>\n", styles: [".repository-card{max-width:450px;margin:0 32px 32px 0}\n"], components: [{ type: i2$1.MatSpinner, selector: "mat-spinner", inputs: ["color"] }, { type: RepoCardComponent, selector: "repo-card", inputs: ["backgroundColor", "backdropFilter", "buttonColor", "cardColor", "gitRepo", "isCopied"], outputs: ["copiedToClipboardEvent"] }], directives: [{ type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { type: i5.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { type: i5.DefaultFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg]", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }], pipes: { "async": i4.AsyncPipe, "keyvalue": i4.KeyValuePipe } });
282
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitPortfolioComponent, decorators: [{
283
+ type: Component,
284
+ args: [{ selector: 'git-portfolio', template: "<div *ngIf=\"gitRepositories$ | async as gitRepositories\">\n <div *ngFor=\"let gitProvider of gitProviders | keyvalue\">\n <h1>{{ gitProvider.value }}</h1>\n <div *ngIf=\"showOwn\">\n <h2 class=\"mat-headline\">Own Repos</h2>\n <div\n fxLayout=\"row wrap\"\n fxLayout.lt-sm=\"column\"\n fxLayoutAlign=\"flex-start\"\n >\n <div *ngIf=\"(loading | async) === true\">\n <mat-spinner></mat-spinner>\n </div>\n <repo-card\n *ngFor=\"\n let gitRepo of getOwnGitRepositories(\n gitRepositories,\n gitProvider.key\n )\n \"\n [backgroundColor]=\"backgroundColor\"\n [backdropFilter]=\"backdropFilter\"\n [buttonColor]=\"buttonColor\"\n [cardColor]=\"cardColor\"\n [gitRepo]=\"gitRepo\"\n [isCopied]=\"isCopiedToClipboard(gitRepo)\"\n (copiedToClipboardEvent)=\"copyToClipboard(gitRepo)\"\n class=\"repository-card\"\n fxFlex=\"0 1 calc(33.3% - 32px)\"\n fxFlex.lt-md=\"0 1 calc(50% - 32px)\"\n fxFlex.lt-sm=\"100%\"\n fxLayoutAlign=\"stretch\"\n >\n </repo-card>\n <div\n *ngIf=\"\n (loading | async) === false &&\n !hasRepositories(gitRepositories, gitProvider.key, 'own')\n \"\n >\n This user has not created any repositories yet\n </div>\n </div>\n </div>\n <div *ngIf=\"showForked\">\n <h2 class=\"mat-headline\">Forked Repos</h2>\n <div\n fxLayout=\"row wrap\"\n fxLayout.lt-sm=\"column\"\n fxLayoutAlign=\"flex-start\"\n >\n <div *ngIf=\"(loading | async) === true\">\n <mat-spinner></mat-spinner>\n </div>\n <repo-card\n *ngFor=\"\n let gitRepo of getForkedGitRepositories(\n gitRepositories,\n gitProvider.key\n )\n \"\n [backgroundColor]=\"backgroundColor\"\n [backdropFilter]=\"backdropFilter\"\n [buttonColor]=\"buttonColor\"\n [cardColor]=\"cardColor\"\n [gitRepo]=\"gitRepo\"\n [isCopied]=\"isCopiedToClipboard(gitRepo)\"\n (copiedToClipboardEvent)=\"copyToClipboard(gitRepo)\"\n class=\"repository-card\"\n fxFlex=\"0 1 calc(33.3% - 32px)\"\n fxFlex.lt-md=\"0 1 calc(50% - 32px)\"\n fxFlex.lt-sm=\"100%\"\n fxLayoutAlign=\"stretch\"\n ></repo-card>\n <div\n *ngIf=\"\n (loading | async) === false &&\n !hasRepositories(gitRepositories, gitProvider.key, 'forked')\n \"\n >\n This user has not forked any repositories yet\n </div>\n </div>\n </div>\n </div>\n</div>\n", styles: [".repository-card{max-width:450px;margin:0 32px 32px 0}\n"] }]
285
+ }], ctorParameters: function () { return [{ type: GitProviderService }]; }, propDecorators: { backgroundColor: [{
286
+ type: Input
287
+ }], backdropFilter: [{
288
+ type: Input
289
+ }], buttonColor: [{
290
+ type: Input
291
+ }], cardColor: [{
292
+ type: Input
293
+ }], gitProviderConfig: [{
294
+ type: Input
295
+ }], showForked: [{
296
+ type: Input
297
+ }], showOwn: [{
298
+ type: Input
299
+ }] } });
300
+
301
+ class GitPortfolioModule {
302
+ }
303
+ GitPortfolioModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitPortfolioModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
304
+ GitPortfolioModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitPortfolioModule, declarations: [GitPortfolioComponent, RepoCardComponent, OcticonDirective], imports: [CommonModule,
305
+ BrowserModule,
306
+ BrowserAnimationsModule,
307
+ HttpClientModule,
308
+ MatCardModule,
309
+ MatButtonModule,
310
+ MatProgressSpinnerModule,
311
+ ClipboardModule,
312
+ FlexLayoutModule], exports: [GitPortfolioComponent, OcticonDirective] });
313
+ GitPortfolioModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitPortfolioModule, providers: [GitProviderService], imports: [[
314
+ CommonModule,
315
+ BrowserModule,
316
+ BrowserAnimationsModule,
317
+ HttpClientModule,
318
+ MatCardModule,
319
+ MatButtonModule,
320
+ MatProgressSpinnerModule,
321
+ ClipboardModule,
322
+ FlexLayoutModule
323
+ ]] });
324
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: GitPortfolioModule, decorators: [{
325
+ type: NgModule,
326
+ args: [{
327
+ declarations: [GitPortfolioComponent, RepoCardComponent, OcticonDirective],
328
+ imports: [
329
+ CommonModule,
330
+ BrowserModule,
331
+ BrowserAnimationsModule,
332
+ HttpClientModule,
333
+ MatCardModule,
334
+ MatButtonModule,
335
+ MatProgressSpinnerModule,
336
+ ClipboardModule,
337
+ FlexLayoutModule
338
+ ],
339
+ exports: [GitPortfolioComponent, OcticonDirective],
340
+ providers: [GitProviderService]
341
+ }]
342
+ }] });
343
+
344
+ /**
345
+ * Generated bundle index. Do not edit.
346
+ */
347
+
348
+ export { GitPortfolioComponent, GitPortfolioModule, OcticonDirective };
349
+ //# sourceMappingURL=tehw0lf-git-portfolio.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tehw0lf-git-portfolio.mjs","sources":["../../../../libs/git-portfolio/src/lib/types/git-repository-type.ts","../../../../libs/git-portfolio/src/lib/git-provider.service.ts","../../../../libs/git-portfolio/src/lib/types/git-providers-type.ts","../../../../libs/git-portfolio/src/lib/octicon.directive.ts","../../../../libs/git-portfolio/src/lib/repo-card/repo-card.component.ts","../../../../libs/git-portfolio/src/lib/repo-card/repo-card.component.html","../../../../libs/git-portfolio/src/lib/git-portfolio.component.ts","../../../../libs/git-portfolio/src/lib/git-portfolio.component.html","../../../../libs/git-portfolio/src/lib/git-portfolio.module.ts","../../../../libs/git-portfolio/src/tehw0lf-git-portfolio.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/naming-convention */\nexport class GitRepository {\n id: number | undefined;\n clone_url?: string;\n http_url_to_repo?: string;\n created_at: string | undefined;\n description: string | undefined;\n fork?: boolean;\n forks_count: number | undefined;\n html_url?: string;\n web_url?: string;\n language?: string;\n license?: {\n key: string;\n name: string;\n node_id: string;\n spdx_id: string;\n url: string;\n };\n name: string | undefined;\n open_issues_count?: number;\n owner?: {\n avatar_url: string;\n };\n namespace?: {\n avatar_url: string;\n };\n pushed_at?: string;\n last_activity_at?: string;\n stargazers_count?: number;\n star_count?: number;\n}\n","import { HttpClient } from '@angular/common/http';\nimport { Injectable } from '@angular/core';\nimport { BehaviorSubject, Observable, of, zip } from 'rxjs';\nimport { map, tap } from 'rxjs/operators';\n\nimport { GitProviderConfig } from './types/git-provider-config-type';\nimport { GitRepositories } from './types/git-repositories-type';\nimport { GitRepository } from './types/git-repository-type';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class GitProviderService {\n private loadingStateSubject = new BehaviorSubject<boolean>(true);\n private repositorySubject = new BehaviorSubject<GitRepositories>({});\n\n constructor(private http: HttpClient) {}\n\n get loading(): Observable<boolean> {\n return this.loadingStateSubject.asObservable();\n }\n\n getRepositories(\n gitProviderUserNames?: GitProviderConfig\n ): Observable<GitRepositories> {\n if (\n this.repositorySubject.value.github === undefined &&\n this.repositorySubject.value.gitlab === undefined\n ) {\n this.fetchRepositories(gitProviderUserNames)\n .pipe(\n tap((repositories: GitRepositories) => {\n this.repositorySubject.next(repositories);\n this.loadingStateSubject.next(false);\n })\n )\n .subscribe();\n }\n return this.repositorySubject.asObservable();\n }\n\n fetchRepositories(\n gitProviderUserNames?: GitProviderConfig\n ): Observable<GitRepositories> {\n return zip(\n this.fetchGithubRepositories(gitProviderUserNames?.github ?? ''),\n this.fetchGitlabRepositories(gitProviderUserNames?.gitlab ?? '')\n ).pipe(\n map((gitRepositoryArray: [GitRepository[], GitRepository[]]) => {\n const repositories: GitRepositories = {\n github: this.filterAndSortGitRepositories(gitRepositoryArray[0]),\n gitlab: this.filterAndSortGitRepositories(gitRepositoryArray[1])\n };\n return repositories;\n })\n );\n }\n\n private filterAndSortGitRepositories(gitRepositoryArray: GitRepository[]): {\n own: GitRepository[];\n forked: GitRepository[];\n } {\n return {\n own: gitRepositoryArray\n .filter((gitRepository: GitRepository) => !gitRepository.fork)\n .sort(\n (repoA: GitRepository, repoB: GitRepository) =>\n (repoB.stargazers_count ?? 0) - (repoA.stargazers_count ?? 0)\n ),\n forked: gitRepositoryArray\n .filter((gitRepository: GitRepository) => gitRepository.fork)\n .sort(\n (repoA: GitRepository, repoB: GitRepository) =>\n (repoB.stargazers_count ?? 0) - (repoA.stargazers_count ?? 0)\n )\n };\n }\n\n private fetchGithubRepositories(\n githubUser: string\n ): Observable<GitRepository[]> {\n if (githubUser !== '') {\n return this.http.get<GitRepository[]>(\n `https://api.github.com/users/${githubUser}/repos`\n );\n }\n return of([new GitRepository()]);\n }\n private fetchGitlabRepositories(\n gitlabUser: string\n ): Observable<GitRepository[]> {\n if (gitlabUser !== '') {\n return this.http.get<GitRepository[]>(\n `https://gitlab.com/api/v4/users/${gitlabUser}/projects`\n );\n }\n return of([new GitRepository()]);\n }\n}\n","/* eslint-disable no-shadow */\nexport enum GitProviders {\n github = 'GitHub',\n gitlab = 'GitLab'\n}\n","import { Directive, ElementRef, Input, OnInit, Renderer2 } from '@angular/core';\n\n// eslint-disable-next-line @typescript-eslint/no-var-requires\nconst octicons = require('@primer/octicons');\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[octicon]'\n})\nexport class OcticonDirective implements OnInit {\n @Input() octicon: string | undefined;\n @Input() color: string | undefined;\n @Input() width: string | undefined;\n\n constructor(private elementRef: ElementRef, private renderer: Renderer2) {}\n\n ngOnInit(): void {\n const el: HTMLElement = this.elementRef.nativeElement;\n if (this.octicon) {\n if (octicons[this.octicon] !== undefined) {\n el.innerHTML = octicons[this.octicon].toSVG();\n\n const icon: Node | null = el.firstChild;\n\n if (this.color && icon) {\n this.renderer.setStyle(icon, 'fill', this.color);\n }\n if (this.width && icon) {\n this.renderer.setStyle(icon, 'width', this.width);\n this.renderer.setStyle(icon, 'height', this.width);\n }\n } else {\n el.innerHTML = octicons['alert'].toSVG();\n this.renderer.setStyle(el.firstChild, 'fill', 'red');\n }\n }\n }\n}\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\n\nimport { GitRepository } from '../types/git-repository-type';\n\n// eslint-disable-next-line @typescript-eslint/no-var-requires\nconst githubLanguageColors = require('github-language-colors/colors.json');\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'repo-card',\n templateUrl: './repo-card.component.html',\n styleUrls: ['./repo-card.component.scss']\n})\nexport class RepoCardComponent {\n @Input() backgroundColor!: string;\n @Input() backdropFilter!: string;\n @Input() buttonColor!: string;\n @Input() cardColor!: string;\n\n @Input()\n gitRepo!: GitRepository;\n\n @Input()\n public isCopied = false;\n\n @Output()\n public copiedToClipboardEvent: EventEmitter<boolean> = new EventEmitter<boolean>();\n\n public githubLanguageColors = githubLanguageColors;\n\n constructor() {\n //\n }\n copiedToClipboard(): void {\n this.copiedToClipboardEvent.emit();\n }\n}\n","<mat-card\n [ngStyle]=\"{\n color: cardColor,\n 'background-color': backgroundColor,\n 'backdrop-filter': backdropFilter\n }\"\n>\n <mat-card-header>\n <div\n mat-card-avatar\n [ngStyle]=\"{\n 'background-image':\n 'url(' +\n (gitRepo.owner?.avatar_url || gitRepo.namespace?.avatar_url) +\n ')',\n 'background-size': 'cover',\n 'border-radius': 0\n }\"\n ></div>\n <mat-card-title\n ><a\n mat-button\n [ngStyle]=\"{ color: buttonColor }\"\n target=\"_blank\"\n href=\"{{ gitRepo.html_url || gitRepo.web_url }}\"\n >\n {{ gitRepo.name }}\n </a>\n </mat-card-title>\n <mat-card-subtitle fxLayout=\"row\" fxLayoutGap=\"12px\">\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div\n [ngStyle]=\"{\n 'background-color':\n gitRepo.language !== undefined\n ? githubLanguageColors[gitRepo.language]\n : 'transparent'\n }\"\n class=\"language-icon\"\n ></div>\n <div>{{ gitRepo.language }}</div>\n </div>\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div octicon=\"star\" color=\"gold\"></div>\n <div>{{ gitRepo.stargazers_count || gitRepo.star_count || 0 }}</div>\n </div>\n <div class=\"info-item\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div octicon=\"repo-forked\" color=\"#437da8\"></div>\n <div>{{ gitRepo.forks_count }}</div>\n </div>\n <div\n *ngIf=\"gitRepo.open_issues_count\"\n class=\"info-item\"\n fxLayout=\"row\"\n fxLayoutGap=\"5px\"\n >\n <div octicon=\"issue-opened\" color=\"rgb(56, 224, 56)\"></div>\n <div>{{ gitRepo.open_issues_count }}</div>\n </div>\n </mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <p>{{ gitRepo.description }}</p>\n </mat-card-content>\n <mat-card-footer fxLayout=\"row\" fxLayoutGap=\"12px\">\n <span class=\"mat-footer-cell\" fxFlex>\n <span class=\"footer-span\" [ngStyle]=\"{ color: cardColor }\"\n >Created: {{ gitRepo.created_at | date }}</span\n >\n <span class=\"footer-span\" [ngStyle]=\"{ color: cardColor }\"\n >Updated:\n {{ gitRepo.pushed_at || gitRepo.last_activity_at | date }}</span\n >\n </span>\n <span class=\"mat-footer-cell\">\n <button\n [ngStyle]=\"{ color: buttonColor }\"\n mat-button\n [cdkCopyToClipboard]=\"\n gitRepo.clone_url || gitRepo.http_url_to_repo || ''\n \"\n (cdkCopyToClipboardCopied)=\"copiedToClipboard()\"\n class=\"clipboard-button\"\n >\n <span class=\"mat-button-wrapper\" fxLayout=\"row\" fxLayoutGap=\"5px\">\n <div\n *ngIf=\"isCopied\"\n octicon=\"check\"\n color=\"#38e038\"\n width=\"24\"\n ></div>\n <div octicon=\"paste\" color=\"#cc7832\" width=\"24px\"></div>\n <span>Copy URL</span>\n </span>\n </button>\n </span>\n </mat-card-footer>\n</mat-card>\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\nimport { Observable, Subject } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\n\nimport { GitProviderService } from './git-provider.service';\nimport { GitProviderConfig } from './types/git-provider-config-type';\nimport { GitProviders } from './types/git-providers-type';\nimport { GitRepositories } from './types/git-repositories-type';\nimport { GitRepository } from './types/git-repository-type';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'git-portfolio',\n templateUrl: './git-portfolio.component.html',\n styleUrls: ['./git-portfolio.component.scss']\n})\nexport class GitPortfolioComponent implements OnInit, OnDestroy {\n @Input()\n backgroundColor = 'rgba(34, 34, 34, 0.75)';\n\n @Input()\n backdropFilter = 'blur(50px)';\n\n @Input()\n buttonColor = '#cc7832';\n\n @Input()\n cardColor = 'lightgray';\n\n @Input()\n gitProviderConfig: GitProviderConfig = {\n github: 'tehw0lf',\n gitlab: 'tehw0lf'\n };\n\n @Input()\n showForked = true;\n\n @Input()\n showOwn = true;\n\n loading: Observable<boolean>;\n gitProviders = GitProviders;\n currentRepo: GitRepository | undefined;\n gitRepositories$: Observable<GitRepositories> | undefined;\n private unsubscribe$ = new Subject<void>();\n\n constructor(private gitProviderService: GitProviderService) {\n this.loading = this.gitProviderService.loading;\n }\n\n ngOnInit(): void {\n this.getRepositories();\n }\n\n ngOnDestroy(): void {\n this.unsubscribe$.next();\n this.unsubscribe$.complete();\n }\n\n copyToClipboard(githubRepo: GitRepository): void {\n this.currentRepo = githubRepo;\n }\n\n isCopiedToClipboard(githubRepo: GitRepository): boolean {\n if (!this.currentRepo) {\n return false;\n }\n return this.currentRepo.id === githubRepo.id ? true : false;\n }\n\n getRepositories(): void {\n this.gitRepositories$ = this.gitProviderService\n .getRepositories(this.gitProviderConfig)\n .pipe(takeUntil(this.unsubscribe$));\n }\n\n getOwnGitRepositories(\n gitRepositories: GitRepositories,\n gitProvider: string\n ): GitRepository[] {\n if (gitRepositories) {\n switch (gitProvider) {\n case 'github':\n if (gitRepositories.github) {\n return gitRepositories.github.own;\n } else {\n return [];\n }\n\n case 'gitlab':\n if (gitRepositories.gitlab) {\n return gitRepositories.gitlab.own;\n } else {\n return [];\n }\n\n default:\n return [];\n }\n } else {\n return [];\n }\n }\n\n getForkedGitRepositories(\n gitRepositories: GitRepositories,\n gitProvider: string\n ): GitRepository[] {\n if (gitRepositories) {\n switch (gitProvider) {\n case 'github':\n if (gitRepositories.github) {\n return gitRepositories.github.forked;\n } else {\n return [];\n }\n\n case 'gitlab':\n if (gitRepositories.gitlab) {\n return gitRepositories.gitlab.forked;\n } else {\n return [];\n }\n\n default:\n return [];\n }\n } else {\n return [];\n }\n }\n\n hasRepositories(\n gitRepositories: GitRepositories,\n gitProvider: string,\n type: 'own' | 'forked'\n ): boolean {\n if (gitRepositories) {\n switch (gitProvider) {\n case 'github':\n if (gitRepositories.github) {\n return gitRepositories.github[type].length > 0;\n }\n break;\n\n case 'gitlab':\n if (gitRepositories.gitlab) {\n return gitRepositories.gitlab[type].length > 0;\n }\n break;\n }\n }\n return false;\n }\n}\n","<div *ngIf=\"gitRepositories$ | async as gitRepositories\">\n <div *ngFor=\"let gitProvider of gitProviders | keyvalue\">\n <h1>{{ gitProvider.value }}</h1>\n <div *ngIf=\"showOwn\">\n <h2 class=\"mat-headline\">Own Repos</h2>\n <div\n fxLayout=\"row wrap\"\n fxLayout.lt-sm=\"column\"\n fxLayoutAlign=\"flex-start\"\n >\n <div *ngIf=\"(loading | async) === true\">\n <mat-spinner></mat-spinner>\n </div>\n <repo-card\n *ngFor=\"\n let gitRepo of getOwnGitRepositories(\n gitRepositories,\n gitProvider.key\n )\n \"\n [backgroundColor]=\"backgroundColor\"\n [backdropFilter]=\"backdropFilter\"\n [buttonColor]=\"buttonColor\"\n [cardColor]=\"cardColor\"\n [gitRepo]=\"gitRepo\"\n [isCopied]=\"isCopiedToClipboard(gitRepo)\"\n (copiedToClipboardEvent)=\"copyToClipboard(gitRepo)\"\n class=\"repository-card\"\n fxFlex=\"0 1 calc(33.3% - 32px)\"\n fxFlex.lt-md=\"0 1 calc(50% - 32px)\"\n fxFlex.lt-sm=\"100%\"\n fxLayoutAlign=\"stretch\"\n >\n </repo-card>\n <div\n *ngIf=\"\n (loading | async) === false &&\n !hasRepositories(gitRepositories, gitProvider.key, 'own')\n \"\n >\n This user has not created any repositories yet\n </div>\n </div>\n </div>\n <div *ngIf=\"showForked\">\n <h2 class=\"mat-headline\">Forked Repos</h2>\n <div\n fxLayout=\"row wrap\"\n fxLayout.lt-sm=\"column\"\n fxLayoutAlign=\"flex-start\"\n >\n <div *ngIf=\"(loading | async) === true\">\n <mat-spinner></mat-spinner>\n </div>\n <repo-card\n *ngFor=\"\n let gitRepo of getForkedGitRepositories(\n gitRepositories,\n gitProvider.key\n )\n \"\n [backgroundColor]=\"backgroundColor\"\n [backdropFilter]=\"backdropFilter\"\n [buttonColor]=\"buttonColor\"\n [cardColor]=\"cardColor\"\n [gitRepo]=\"gitRepo\"\n [isCopied]=\"isCopiedToClipboard(gitRepo)\"\n (copiedToClipboardEvent)=\"copyToClipboard(gitRepo)\"\n class=\"repository-card\"\n fxFlex=\"0 1 calc(33.3% - 32px)\"\n fxFlex.lt-md=\"0 1 calc(50% - 32px)\"\n fxFlex.lt-sm=\"100%\"\n fxLayoutAlign=\"stretch\"\n ></repo-card>\n <div\n *ngIf=\"\n (loading | async) === false &&\n !hasRepositories(gitRepositories, gitProvider.key, 'forked')\n \"\n >\n This user has not forked any repositories yet\n </div>\n </div>\n </div>\n </div>\n</div>\n","import { ClipboardModule } from '@angular/cdk/clipboard';\nimport { CommonModule } from '@angular/common';\nimport { HttpClientModule } from '@angular/common/http';\nimport { NgModule } from '@angular/core';\nimport { FlexLayoutModule } from '@angular/flex-layout';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatCardModule } from '@angular/material/card';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\nimport { BrowserModule } from '@angular/platform-browser';\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { GitPortfolioComponent } from './git-portfolio.component';\nimport { GitProviderService } from './git-provider.service';\nimport { OcticonDirective } from './octicon.directive';\nimport { RepoCardComponent } from './repo-card/repo-card.component';\n\n@NgModule({\n declarations: [GitPortfolioComponent, RepoCardComponent, OcticonDirective],\n imports: [\n CommonModule,\n BrowserModule,\n BrowserAnimationsModule,\n HttpClientModule,\n MatCardModule,\n MatButtonModule,\n MatProgressSpinnerModule,\n ClipboardModule,\n FlexLayoutModule\n ],\n exports: [GitPortfolioComponent, OcticonDirective],\n providers: [GitProviderService]\n})\nexport class GitPortfolioModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA;MACa,aAAa;;;MCWb,kBAAkB;IAI7B,YAAoB,IAAgB;QAAhB,SAAI,GAAJ,IAAI,CAAY;QAH5B,wBAAmB,GAAG,IAAI,eAAe,CAAU,IAAI,CAAC,CAAC;QACzD,sBAAiB,GAAG,IAAI,eAAe,CAAkB,EAAE,CAAC,CAAC;KAE7B;IAExC,IAAI,OAAO;QACT,OAAO,IAAI,CAAC,mBAAmB,CAAC,YAAY,EAAE,CAAC;KAChD;IAED,eAAe,CACb,oBAAwC;QAExC,IACE,IAAI,CAAC,iBAAiB,CAAC,KAAK,CAAC,MAAM,KAAK,SAAS;YACjD,IAAI,CAAC,iBAAiB,CAAC,KAAK,CAAC,MAAM,KAAK,SAAS,EACjD;YACA,IAAI,CAAC,iBAAiB,CAAC,oBAAoB,CAAC;iBACzC,IAAI,CACH,GAAG,CAAC,CAAC,YAA6B;gBAChC,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;gBAC1C,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;aACtC,CAAC,CACH;iBACA,SAAS,EAAE,CAAC;SAChB;QACD,OAAO,IAAI,CAAC,iBAAiB,CAAC,YAAY,EAAE,CAAC;KAC9C;IAED,iBAAiB,CACf,oBAAwC;QAExC,OAAO,GAAG,CACR,IAAI,CAAC,uBAAuB,CAAC,oBAAoB,EAAE,MAAM,IAAI,EAAE,CAAC,EAChE,IAAI,CAAC,uBAAuB,CAAC,oBAAoB,EAAE,MAAM,IAAI,EAAE,CAAC,CACjE,CAAC,IAAI,CACJ,GAAG,CAAC,CAAC,kBAAsD;YACzD,MAAM,YAA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AAE,iBAAiB,EAAE,gBAAgB,aAEvE,YAAY;QACZ,aAAa;QACb,uBAAuB;QACvB,gBAAgB;QAChB,aAAa;QACb,eAAe;QACf,wBAAwB;QACxB,eAAe;QACf,gBAAgB,aAER,qBAAqB,EAAE,gBAAgB;gHAGtC,kBAAkB,aAFlB,CAAC,kBAAkB,CAAC,YAZtB;YACP,YAAY;YACZ,aAAa;YACb,uBAAuB;YACvB,gBAAgB;YAChB,aAAa;YACb,eAAe;YACf,wBAAwB;YACxB,eAAe;YACf,gBAAgB;SACjB;2FAIU,kBAAkB;kBAhB9B,QAAQ;mBAAC;oBACR,YAAY,EAAE,CAAC,qBAAqB,EAAE,iBAAiB,EAAE,gBAAgB,CAAC;oBAC1E,OAAO,EAAE;wBACP,YAAY;wBACZ,aAAa;wBACb,uBAAuB;wBACvB,gBAAgB;wBAChB,aAAa;wBACb,eAAe;wBACf,wBAAwB;wBACxB,eAAe;wBACf,gBAAgB;qBACjB;oBACD,OAAO,EAAE,CAAC,qBAAqB,EAAE,gBAAgB,CAAC;oBAClD,SAAS,EAAE,CAAC,kBAAkB,CAAC;iBAChC;;;AC/BD;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tehw0lf/git-portfolio",
3
- "version": "0.0.1",
3
+ "version": "0.0.5",
4
4
  "license": "MIT",
5
5
  "homepage": "https://github.com/tehw0lf/tehwol.fi.git",
6
6
  "repository": {
@@ -8,16 +8,17 @@
8
8
  "url": "https://github.com/tehw0lf/tehwol.fi.git"
9
9
  },
10
10
  "peerDependencies": {
11
- "@angular/animations": "^12.2.11",
12
- "@angular/cdk": "^12.2.11",
13
- "@angular/common": "^12.2.11",
14
- "@angular/core": "^12.2.11",
15
- "@angular/flex-layout": "^12.0.0-beta.35",
16
- "@angular/material": "^12.2.11",
17
- "github-language-colors": "^1.0.0",
11
+ "@angular/animations": "^13.1.0",
12
+ "@angular/cdk": "^13.1.0",
13
+ "@angular/common": "^13.1.0",
14
+ "@angular/core": "^13.1.0",
15
+ "@angular/flex-layout": "^13.0.0-beta.36",
16
+ "@angular/material": "^13.1.0",
18
17
  "@primer/octicons": "^16.1.1",
18
+ "github-language-colors": "^1.0.0",
19
19
  "rxjs": "~7.4.0",
20
- "@angular/platform-browser": "12.2.11"
20
+ "@angular/platform-browser": "13.1.0",
21
+ "@angular/platform-browser-dynamic": "13.1.0"
21
22
  },
22
23
  "dependencies": {
23
24
  "tslib": "^2.2.0"
@@ -26,11 +27,24 @@
26
27
  "ng-add": {
27
28
  "save": "dependencies"
28
29
  },
29
- "main": "bundles/tehw0lf-git-portfolio.umd.js",
30
- "module": "fesm2015/tehw0lf-git-portfolio.js",
31
- "es2015": "fesm2015/tehw0lf-git-portfolio.js",
32
- "esm2015": "esm2015/tehw0lf-git-portfolio.js",
33
- "fesm2015": "fesm2015/tehw0lf-git-portfolio.js",
30
+ "module": "fesm2015/tehw0lf-git-portfolio.mjs",
31
+ "es2020": "fesm2020/tehw0lf-git-portfolio.mjs",
32
+ "esm2020": "esm2020/tehw0lf-git-portfolio.mjs",
33
+ "fesm2020": "fesm2020/tehw0lf-git-portfolio.mjs",
34
+ "fesm2015": "fesm2015/tehw0lf-git-portfolio.mjs",
34
35
  "typings": "tehw0lf-git-portfolio.d.ts",
36
+ "exports": {
37
+ "./package.json": {
38
+ "default": "./package.json"
39
+ },
40
+ ".": {
41
+ "types": "./tehw0lf-git-portfolio.d.ts",
42
+ "esm2020": "./esm2020/tehw0lf-git-portfolio.mjs",
43
+ "es2020": "./fesm2020/tehw0lf-git-portfolio.mjs",
44
+ "es2015": "./fesm2015/tehw0lf-git-portfolio.mjs",
45
+ "node": "./fesm2015/tehw0lf-git-portfolio.mjs",
46
+ "default": "./fesm2020/tehw0lf-git-portfolio.mjs"
47
+ }
48
+ },
35
49
  "sideEffects": false
36
50
  }