Skip to content

Commit 6c4bf46

Browse files
committed
Refine UI
Signed-off-by: Ryan Wang <i@ryanc.cc>
1 parent feaef21 commit 6c4bf46

4 files changed

Lines changed: 5 additions & 34 deletions

File tree

packages/comment-widget/src/comment-editor.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ export class CommentEditor extends LitElement {
7777
extensions: [
7878
StarterKit.configure({
7979
heading: false,
80+
link: {
81+
openOnClick: false,
82+
},
8083
}),
8184
Placeholder.configure({
8285
placeholder: msg('Write a comment'),
@@ -104,7 +107,7 @@ export class CommentEditor extends LitElement {
104107
protected override render() {
105108
return html` ${this.renderSkeleton()}
106109
<div
107-
class="border rounded-md border-solid border-gray-200 focus-within:border-blue-500 transition-all"
110+
class="border rounded-md border-solid border-[var(--component-form-input-border-color)] focus-within:border-[var(--component-form-input-border-color-focus)] transition-all"
108111
?hidden=${this.loading}
109112
>
110113
<div

packages/comment-widget/src/comment-widget.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ export class CommentWidget extends LitElement {
152152
try {
153153
await this.fetchGlobalInfo();
154154
await this.fetchConfigMapData();
155+
await this.fetchCurrentUser();
155156
} catch (error) {
156157
if (error instanceof Error) {
157158
this.toastManager?.show(error.message, 'error');
@@ -160,7 +161,6 @@ export class CommentWidget extends LitElement {
160161
} finally {
161162
this.isInitialized = true;
162163
}
163-
await this.fetchCurrentUser();
164164
this.initAvatarProvider();
165165
this.initAvatarPolicy();
166166
}

packages/comment-widget/src/emoji-button.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import './icons/icon-loading';
2-
import './icons/icon-emoji';
32
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
43
//@ts-ignore
54
import en from '@emoji-mart/data/i18n/en.json';

packages/comment-widget/src/icons/icon-emoji.ts

Lines changed: 0 additions & 31 deletions
This file was deleted.

0 commit comments

Comments
 (0)