Skip to content

Commit 0445dc3

Browse files
marcin-hoaDamianBrzezinskiHoA
authored andcommitted
feat: added theme in gh-giscus component
1 parent 9329dcd commit 0445dc3

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

libs/blog/articles/feature-comments/src/lib/giscus-comments/giscus-comments.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
[attr.strict]="config.strict ? '1' : '0'"
1212
[attr.emitmetadata]="config.emitMetadata ? '1' : '0'"
1313
[attr.inputposition]="config.inputPosition"
14-
[attr.theme]="config.theme"
14+
[attr.theme]="theme()"
1515
src="https://giscus.app/client.js"
1616
crossorigin="anonymous"
1717
async

libs/blog/articles/feature-comments/src/lib/giscus-comments/giscus-comments.component.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ import {
1414
GISCUS_CONFIG,
1515
provideComments,
1616
} from '@angular-love/blog/articles/data-access';
17+
import { AppThemeStore } from '@angular-love/data-access-app-theme';
1718

1819
@Component({
1920
selector: 'al-giscus-comments',
20-
imports: [],
2121
templateUrl: './giscus-comments.component.html',
2222
styleUrl: './giscus-comments.component.scss',
2323
changeDetection: ChangeDetectionStrategy.OnPush,
@@ -30,6 +30,7 @@ import {
3030
export class GiscusCommentsComponent {
3131
readonly config = inject(GISCUS_CONFIG);
3232
readonly translocoService = inject(TranslocoService);
33+
readonly theme = inject(AppThemeStore).theme;
3334

3435
readonly lang = toSignal(this.translocoService.langChanges$, {
3536
initialValue: this.translocoService.getActiveLang(),

0 commit comments

Comments
 (0)