Skip to content

Commit fc491d5

Browse files
authored
release: 14.0.0 (#7)
1 parent 668de18 commit fc491d5

File tree

8 files changed

+67
-68
lines changed

8 files changed

+67
-68
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
- name: checkout
1010
uses: actions/checkout@master
1111

12-
- uses: borales/actions-yarn@v2.3.0
12+
- uses: borales/actions-yarn@v3.0.0
1313
with:
1414
cmd: install
1515

@@ -23,7 +23,7 @@ jobs:
2323
- name: checkout
2424
uses: actions/checkout@master
2525

26-
- uses: borales/actions-yarn@v2.3.0
26+
- uses: borales/actions-yarn@v3.0.0
2727
with:
2828
cmd: install
2929

@@ -40,7 +40,7 @@ jobs:
4040
- name: checkout
4141
uses: actions/checkout@master
4242

43-
- uses: borales/actions-yarn@v2.3.0
43+
- uses: borales/actions-yarn@v3.0.0
4444
with:
4545
cmd: install
4646

@@ -54,13 +54,13 @@ jobs:
5454
- name: checkout
5555
uses: actions/checkout@master
5656

57-
- uses: borales/actions-yarn@v2.3.0
57+
- uses: borales/actions-yarn@v3.0.0
5858
with:
5959
cmd: install
6060

6161
- name: build
6262
run: |
63-
node --max_old_space_size=5120 ./node_modules/@angular/cli/bin/ng build --prod --base-href /ng-github-button/
63+
node --max_old_space_size=5120 ./node_modules/@angular/cli/bin/ng build --base-href /ng-github-button/
6464
cp ./dist/index.html ./dist/404.html
6565
ls ./dist
6666

angular.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,7 @@
101101
}
102102
}
103103
},
104-
"defaultProject": "ng-github-button",
105104
"cli": {
106-
"defaultCollection": "@angular-eslint/schematics"
105+
"schematicCollections": "@angular-eslint/schematics"
107106
}
108107
}

lib/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ng-github-button",
3-
"version": "13.0.0",
3+
"version": "14.0.0",
44
"description": "Unofficial GitHub buttons in Angular.",
55
"author": "cipchk <[email protected]>",
66
"license": "MIT",
@@ -17,7 +17,8 @@
1717
"angular-github-button",
1818
"angular2-github-button",
1919
"github-button",
20-
"github button"
20+
"github button",
21+
"angular standalone library"
2122
],
2223
"repository": {
2324
"type": "git",

lib/src/component.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,18 @@ import {
1010
} from '@angular/core';
1111
import { GithubButtonService } from './service';
1212
import { Subscription } from 'rxjs';
13+
import { CommonModule } from '@angular/common';
1314

1415
const isSSR = !(typeof document === 'object' && !!document);
1516

1617
@Component({
1718
selector: 'github-button',
1819
template: `
19-
<a class="gh-btn" href="{{ repo_url }}" target="_blank">
20+
<a class="gh-btn" [href]="repo_url" target="_blank">
2021
<span class="gh-ico" aria-hidden="true"></span>
2122
<span class="gh-text">{{ typeToLabel[type] }}</span>
2223
</a>
23-
<a class="gh-count" target="_blank" href="{{ count_url }}" [ngStyle]="{ display: showZero || count > 0 ? 'block' : 'none' }">
24+
<a class="gh-count" target="_blank" [href]="count_url" [ngStyle]="{ display: showZero || count > 0 ? 'block' : 'none' }">
2425
{{ count }}
2526
</a>
2627
<ng-content></ng-content>
@@ -32,6 +33,8 @@ const isSSR = !(typeof document === 'object' && !!document);
3233
encapsulation: ViewEncapsulation.Emulated,
3334
preserveWhitespaces: false,
3435
changeDetection: ChangeDetectionStrategy.OnPush,
36+
standalone: true,
37+
imports: [CommonModule],
3538
})
3639
export class GithubButtonComponent implements OnChanges, OnInit, OnDestroy {
3740
private notify$: Subscription | null = null;

lib/src/module.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
1-
import { CommonModule } from '@angular/common';
21
import { NgModule } from '@angular/core';
32

43
import { GithubButtonComponent } from './component';
54

65
@NgModule({
7-
imports: [CommonModule],
8-
declarations: [GithubButtonComponent],
6+
imports: [GithubButtonComponent],
97
exports: [GithubButtonComponent],
108
})
119
export class GithubButtonModule {}

package.json

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ng-github-button",
3-
"version": "13.0.0",
3+
"version": "14.0.0",
44
"description": "Unofficial GitHub buttons in Angular.",
55
"keywords": [
66
"angular",
@@ -11,7 +11,8 @@
1111
"angular-github-button",
1212
"angular2-github-button",
1313
"github-button",
14-
"github button"
14+
"github button",
15+
"angular standalone library"
1516
],
1617
"author": "cipchk <[email protected]>",
1718
"license": "MIT",
@@ -25,48 +26,47 @@
2526
"homepage": "https://cipchk.github.io/ng-github-button/",
2627
"scripts": {
2728
"analyze": "ng b --stats-json --source-map",
28-
"lint": "ng l",
29+
"lint": "ng lint",
2930
"test": "ng t --no-progress --browsers=ChromeHeadlessCI --code-coverage --no-watch",
3031
"build": "node scripts/build.js",
3132
"release:next": "npm run build && cd publish && npm publish --access public --tag next",
3233
"release": "npm run build && cd publish && npm publish --access public"
3334
},
3435
"dependencies": {
35-
"@angular/animations": "~13.1.1",
36-
"@angular/common": "~13.1.1",
37-
"@angular/compiler": "~13.1.1",
38-
"@angular/core": "~13.1.1",
39-
"@angular/forms": "~13.1.1",
40-
"@angular/platform-browser": "~13.1.1",
41-
"@angular/platform-browser-dynamic": "~13.1.1",
42-
"@angular/router": "~13.1.1",
43-
"rxjs": "~7.4.0",
44-
"tslib": "^2.3.1",
36+
"@angular/animations": "^14.0.0",
37+
"@angular/common": "^14.0.0",
38+
"@angular/compiler": "^14.0.0",
39+
"@angular/core": "^14.0.0",
40+
"@angular/forms": "^14.0.0",
41+
"@angular/platform-browser": "^14.0.0",
42+
"@angular/platform-browser-dynamic": "^14.0.0",
43+
"@angular/router": "^14.0.0",
44+
"rxjs": "~7.5.0",
45+
"tslib": "^2.3.0",
4546
"zone.js": "~0.11.4"
4647
},
4748
"devDependencies": {
48-
"@angular-devkit/build-angular": "~13.1.2",
49-
"@angular/cli": "~13.1.2",
50-
"@angular/compiler-cli": "~13.1.0",
51-
"@types/jasmine": "~3.10.0",
52-
"@types/node": "^12.11.1",
53-
"jasmine-core": "~3.10.0",
49+
"@angular-devkit/build-angular": "^14.0.3",
50+
"@angular/cli": "~14.0.3",
51+
"@angular/compiler-cli": "^14.0.0",
52+
"@types/jasmine": "~4.0.0",
53+
"jasmine-core": "~4.1.0",
5454
"karma": "~6.3.0",
55-
"karma-chrome-launcher": "~3.1.0",
56-
"karma-coverage": "~2.1.0",
57-
"karma-jasmine": "~4.0.0",
55+
"karma-chrome-launcher": "~3.1.1",
56+
"karma-coverage": "~2.2.0",
57+
"karma-jasmine": "~5.1.0",
5858
"karma-jasmine-html-reporter": "~1.7.0",
59-
"typescript": "~4.5.2",
60-
"@angular-eslint/builder": "^13.0.1",
61-
"@angular-eslint/eslint-plugin": "^13.0.1",
62-
"@angular-eslint/eslint-plugin-template": "^13.0.1",
63-
"@angular-eslint/schematics": "^13.0.1",
64-
"@angular-eslint/template-parser": "^13.0.1",
65-
"@typescript-eslint/eslint-plugin": "^5.8.1",
66-
"@typescript-eslint/parser": "^5.8.1",
59+
"typescript": "~4.7.4",
60+
"@angular-eslint/builder": "^14.0.0",
61+
"@angular-eslint/eslint-plugin": "^14.0.0",
62+
"@angular-eslint/eslint-plugin-template": "^14.0.0",
63+
"@angular-eslint/schematics": "^14.0.0",
64+
"@angular-eslint/template-parser": "^14.0.0",
65+
"@typescript-eslint/eslint-plugin": "^5.29.0",
66+
"@typescript-eslint/parser": "^5.29.0",
6767
"codecov": "^3.8.3",
68-
"eslint": "^8.5.0",
69-
"ng-packagr": "^13.1.2",
70-
"ngx-highlight-js": "^13.0.0"
68+
"eslint": "^8.18.0",
69+
"ng-packagr": "^14.0.2",
70+
"ngx-highlight-js": "^14.0.0"
7171
}
7272
}

src/index.html

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
1-
<!doctype html>
1+
<!DOCTYPE html>
22
<html>
3+
<head>
4+
<meta charset="utf-8" />
5+
<title>ng-github-button | Unofficial GitHub buttons in Angular.</title>
6+
<meta name="viewport" content="width=device-width, initial-scale=1" />
7+
<base href="./" />
8+
<link rel="icon" href="data:;base64,iVBORw0KGgo=" />
9+
<link rel="stylesheet" href="//cdn.jsdelivr.net/gh/highlightjs/cdn-release/build/styles/atom-one-dark.min.css" />
10+
<script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release/build/highlight.min.js"></script>
11+
</head>
312

4-
<head>
5-
<meta charset="utf-8">
6-
<title>ng-github-button | Unofficial GitHub buttons in Angular.</title>
7-
<meta name="viewport" content="width=device-width, initial-scale=1">
8-
<base href="./">
9-
<link rel="icon" href="data:;base64,iVBORw0KGgo=">
10-
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.11.0/styles/atom-one-dark.min.css">
11-
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.11.0/highlight.min.js"></script>
12-
</head>
13-
14-
<body>
15-
<div class="container-fluid">
16-
<app-root>Loading...</app-root>
17-
</div>
18-
<a href="//github.com/cipchk/ng-github-button" target="_blank">
19-
<img style="position: fixed; top: 0; right: 0; border: 0;" src="./assets/fork.png" alt="Fork me on GitHub">
20-
</a>
21-
</body>
22-
13+
<body>
14+
<div class="container-fluid">
15+
<app-root>Loading...</app-root>
16+
</div>
17+
<a href="//github.com/cipchk/ng-github-button" target="_blank">
18+
<img style="position: fixed; top: 0; right: 0; border: 0" src="./assets/fork.png" alt="Fork me on GitHub" />
19+
</a>
20+
</body>
2321
</html>

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"experimentalDecorators": true,
1717
"moduleResolution": "node",
1818
"importHelpers": true,
19-
"target": "es2017",
19+
"target": "es2020",
2020
"module": "es2020",
2121
"lib": [
2222
"es2020",

0 commit comments

Comments
 (0)