Skip to content

Commit 0554dd8

Browse files
committed
enhance(client): DM作成時にメンションも含むように
1 parent 1ef6bec commit 0554dd8

File tree

3 files changed

+14
-2
lines changed

3 files changed

+14
-2
lines changed

CHANGELOG.md

+9-1
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,19 @@
55
-
66
77
### Bugfixes
8-
x
8+
-
99
1010
You should also include the user name that made the change.
1111
-->
1212

13+
## 13.x.x (unreleased)
14+
15+
### Improvements
16+
- enhance(client): DM作成時にメンションも含むように
17+
18+
### Bugfixes
19+
-
20+
1321
## 13.9.2 (2023/03/06)
1422

1523
### Improvements

packages/frontend/src/components/MkPostForm.vue

+4
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,10 @@ function pushVisibleUser(user) {
422422
function addVisibleUser() {
423423
os.selectUser().then(user => {
424424
pushVisibleUser(user);
425+
426+
if (!text.includes(`@${user.username}`)) {
427+
text = `@${Acct.toString(user)} ${text}`;
428+
}
425429
});
426430
}
427431

packages/frontend/src/scripts/get-user-menu.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ export function getUserMenu(user: misskey.entities.UserDetailed, router: Router
111111
icon: 'ti ti-mail',
112112
text: i18n.ts.sendMessage,
113113
action: () => {
114-
os.post({ specified: user });
114+
os.post({ specified: user, initialText: `@${user.username} ` });
115115
},
116116
}, null, {
117117
type: 'parent',

0 commit comments

Comments
 (0)