Compare commits

..

81 Commits

Author SHA1 Message Date
syuilo 98f25c9159 6.3.2 2018-08-18 03:37:56 +09:00
syuilo ae9c13df66 6.3.1 2018-08-18 03:37:10 +09:00
syuilo 9f8d21b2bc Fix #2298 2018-08-18 03:36:13 +09:00
syuilo cd09fa5a28 Merge pull request #2297 from syuilo/update-readme
:v::sunny::umbrella::cloud::snowflake:✌️
2018-08-17 23:20:58 +09:00
Aya Morisawa 9ca9757418 :v::sunny::umbrella::cloud::snowflake:✌️ 2018-08-17 23:19:24 +09:00
syuilo 1fae2ffc37 Merge branch 'master' of https://github.com/syuilo/misskey 2018-08-17 23:07:01 +09:00
syuilo 71657ddb98 🎨 2018-08-17 23:06:58 +09:00
syuilo 63845e0ba7 Merge pull request #2294 from acid-chicken/patch-1
Resolve #2291
2018-08-17 22:38:40 +09:00
Acid Chicken (硫酸鶏) 6781b68d33 Delete README.foot.md 2018-08-17 22:37:11 +09:00
Acid Chicken (硫酸鶏) d058eff59a Update and rename README.head.md to README.md 2018-08-17 22:36:38 +09:00
syuilo 42addfed85 Merge pull request #2292 from syuilo/patch-2271
Resolve #2271
2018-08-17 21:43:15 +09:00
greenkeeper[bot] 0dd6494ab9 fix(package): update url-loader to version 1.1.1 2018-08-17 21:41:42 +09:00
Aya Morisawa 9f4c6a3aef Resolve #2271 2018-08-17 21:40:08 +09:00
Aya Morisawa ad0d06c0d8 #332 2018-08-17 21:29:06 +09:00
syuilo fbf43c1450 Fix bug 2018-08-17 19:38:39 +09:00
syuilo 35a1fa5bf0 6.3.0 2018-08-17 19:37:06 +09:00
syuilo 8d3f71d490 Fix bug 2018-08-17 19:35:05 +09:00
syuilo 9776d8e06b Merge pull request #2283 from sei0o/patch-2266
fix #2266
2018-08-17 19:24:10 +09:00
syuilo 10f845ae76 Merge branch 'master' of https://github.com/syuilo/misskey 2018-08-17 19:17:36 +09:00
syuilo 2c8f962889 #2214 #2155 2018-08-17 19:17:23 +09:00
syuilo 1721a82352 Merge pull request #2284 from acid-chicken/acid-chicken-patch-3
Auto-generate README
2018-08-17 18:50:17 +09:00
Acid Chicken (硫酸鶏) 59bec546e4 Create README.foot.md 2018-08-17 18:34:35 +09:00
Acid Chicken (硫酸鶏) 86503f2d69 Create README.head.md 2018-08-17 18:33:49 +09:00
sei0o e4b8c688bb fix #2266: デフォルト値を設定 2018-08-17 17:16:27 +09:00
sei0o 4535ab4c43 fix #2266 2018-08-17 16:35:04 +09:00
syuilo dcdb57df9d Merge pull request #2270 from syuilo/l10n_master
New Crowdin translations
2018-08-17 14:57:51 +09:00
syuilo cfc2808c56 New translations ja.yml (English) 2018-08-17 14:51:21 +09:00
syuilo 4a3d74c608 Merge branch 'master' into l10n_master 2018-08-17 14:48:38 +09:00
syuilo e18655d18f Merge pull request #2279 from syuilo/enhance-note-footer
Enhance note footer
2018-08-17 14:43:25 +09:00
syuilo 12b4b78763 New translations ja.yml (Catalan) 2018-08-17 13:21:27 +09:00
syuilo 550a528fc1 New translations ja.yml (Portuguese) 2018-08-17 13:21:25 +09:00
syuilo 4e3429a5c7 New translations ja.yml (Korean) 2018-08-17 13:21:22 +09:00
syuilo ef98383075 New translations ja.yml (Polish) 2018-08-17 13:21:20 +09:00
syuilo d66d1f142f New translations ja.yml (Chinese Simplified) 2018-08-17 13:21:17 +09:00
syuilo c896055cb1 New translations ja.yml (Italian) 2018-08-17 13:21:15 +09:00
syuilo 2e8b2e0cf9 New translations ja.yml (Russian) 2018-08-17 13:21:13 +09:00
syuilo 59012b5693 New translations ja.yml (English) 2018-08-17 13:21:11 +09:00
syuilo dfb51e8d26 New translations ja.yml (Spanish) 2018-08-17 13:21:09 +09:00
syuilo 5107824352 New translations ja.yml (German) 2018-08-17 13:21:07 +09:00
syuilo bf7ec18316 New translations ja.yml (French) 2018-08-17 13:21:04 +09:00
syuilo 77d82d2d17 Merge pull request #2282 from sei0o/improve-login-failed-message
ログイン失敗時のメッセージを改善
2018-08-17 13:19:41 +09:00
syuilo 2777460150 Merge pull request #2278 from mei23/mei-0817-announce3
Misskey => Misskey で renote 出来ない件修正
2018-08-17 13:18:11 +09:00
sei0o 9476a240d9 ログイン失敗時のメッセージを改善 2018-08-17 12:34:07 +09:00
syuilo bddb878931 New translations ja.yml (English) 2018-08-17 10:01:12 +09:00
syuilo b0768d8a4a New translations ja.yml (English) 2018-08-17 09:51:19 +09:00
syuilo 46bb7f9efb New translations ja.yml (English) 2018-08-17 09:41:18 +09:00
Aya Morisawa a507b7c0b0 Enhance note footer 2018-08-17 07:16:56 +09:00
mei23 939c0dc5f9 Fix indent 2018-08-17 06:46:32 +09:00
mei23 a89c206572 Fix Announce Activity 2018-08-17 06:40:50 +09:00
syuilo 8b55263e72 New translations ja.yml (Catalan) 2018-08-17 06:11:53 +09:00
syuilo f2ad1e4639 New translations ja.yml (Portuguese) 2018-08-17 06:11:51 +09:00
syuilo 0fbcec1c16 New translations ja.yml (Korean) 2018-08-17 06:11:48 +09:00
syuilo ec2b73d076 New translations ja.yml (Polish) 2018-08-17 06:11:46 +09:00
syuilo 6630bb0b39 New translations ja.yml (Chinese Simplified) 2018-08-17 06:11:43 +09:00
syuilo bef0d4c8bd New translations ja.yml (Italian) 2018-08-17 06:11:41 +09:00
syuilo a57cb3bd31 New translations ja.yml (Russian) 2018-08-17 06:11:38 +09:00
syuilo 1e4577a988 New translations ja.yml (English) 2018-08-17 06:11:36 +09:00
syuilo fe792b5bbb New translations ja.yml (Spanish) 2018-08-17 06:11:33 +09:00
syuilo d4005133d0 New translations ja.yml (German) 2018-08-17 06:11:31 +09:00
syuilo abe8e80268 New translations ja.yml (French) 2018-08-17 06:11:28 +09:00
syuilo e38e4940b4 Merge pull request #2277 from syuilo/patch-2276
Resolve #2276
2018-08-17 06:06:07 +09:00
Aya Morisawa 48dc1678c3 Resolve #2276 2018-08-17 06:04:09 +09:00
Aya Morisawa 431383ab54 Clean up 2018-08-17 05:33:20 +09:00
syuilo 7a8d252f63 Merge pull request #2272 from mei23/mei-0817-debuglog
production以外のときに`npm run debug`が効かないのを修正
2018-08-17 04:04:18 +09:00
syuilo 04525e2997 New translations ja.yml (Catalan) 2018-08-17 03:52:03 +09:00
syuilo a2f96f3f20 New translations ja.yml (Portuguese) 2018-08-17 03:52:01 +09:00
syuilo a81ecb0b28 New translations ja.yml (Korean) 2018-08-17 03:51:59 +09:00
syuilo 1122368ee0 New translations ja.yml (Polish) 2018-08-17 03:51:56 +09:00
syuilo 6c54328391 New translations ja.yml (Chinese Simplified) 2018-08-17 03:51:54 +09:00
syuilo 1a26816f7a New translations ja.yml (Italian) 2018-08-17 03:51:52 +09:00
syuilo 8538334d08 New translations ja.yml (Russian) 2018-08-17 03:51:50 +09:00
syuilo 9387ebc569 New translations ja.yml (English) 2018-08-17 03:51:48 +09:00
syuilo c99dce68ed New translations ja.yml (Spanish) 2018-08-17 03:51:46 +09:00
syuilo 6dea84c6d2 New translations ja.yml (German) 2018-08-17 03:51:44 +09:00
mei23 39060374c2 Fix npm run debug not working 2018-08-17 03:51:42 +09:00
syuilo d3ebb5d13f New translations ja.yml (French) 2018-08-17 03:51:41 +09:00
syuilo 4e7c10d3d9 Merge pull request #2269 from syuilo/verified-user-ja
Update verified-user in ja.yml
2018-08-17 03:47:58 +09:00
Aya Morisawa e93ea66d2d Update verified-user in ja.yml 2018-08-17 03:47:08 +09:00
syuilo 152dd70ea5 Merge pull request #2268 from syuilo/space-between-words
Add a space between the words
2018-08-17 03:18:52 +09:00
Aya Morisawa 7b94cf9f84 Add a space between the words 2018-08-17 03:08:17 +09:00
syuilo d70e27a865 Provide id in announce activity 2018-08-17 02:37:20 +09:00
39 changed files with 437 additions and 98 deletions
+69
View File
@@ -0,0 +1,69 @@
<img src="https://github.com/syuilo/misskey/blob/b3f42e62af698a67c2250533c437569559f1fdf9/src/himasaku/resources/himasaku.png?raw=true" align="right" width="320px"/>
[![Misskey](/assets/title.png)](https://misskey.xyz/)
================================================================
[![][travis-badge]][travis-link]
[![][dependencies-badge]][dependencies-link]
[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com) [![Greenkeeper badge](https://badges.greenkeeper.io/syuilo/misskey.svg)](https://greenkeeper.io/)
[Misskey](https://misskey.xyz) is an **advanced**, **redefined**, and ultimately **sophisticated** microblogging platform.
<a href="https://www.patreon.com/syuilo"><img src="https://c5.patreon.com/external/logo/become_a_patron_button@2x.png" alt="Become a Patron!" width="160" /></a>
![](https://ja.mstdn.wiki/images/e/ed/Deck.jpg)
:sparkles: Features
----------------------------------------------------------------
* Rich text contents
* Reactions
* User lists
* Customizable column view (called MisskeyDeck)
* and widgets!
* Private messages
* ActivityPub support
and more! You can see it with your own eyes at [misskey.xyz](https://misskey.xyz).
:package: Create your instance
----------------------------------------------------------------
If you want to run your own instance of Misskey,
please see [Setup and installation guide](./docs/setup.en.md).
:wrench: Contribute
----------------------------------------------------------------
**[PR](https://github.com/syuilo/misskey/pulls)s welcome!**
If you want to...
* i18n ... please see [Translation guide](./docs/translate.en.md).
* l10n ... please visit https://crowdin.com/project/misskey
:heart: Backers & Sponsors
----------------------------------------------------------------
<!-- __PATREON__ -->
:four_leaf_clover: Copyright
----------------------------------------------------------------
> Copyright (c) 2014-2018 syuilo
Misskey is an open-source software licensed under the [GNU AGPLv3](LICENSE).
[![][agpl-3.0-badge]][AGPL-3.0]
[agpl-3.0]: https://www.gnu.org/licenses/agpl-3.0.en.html
[agpl-3.0-badge]: https://img.shields.io/badge/license-AGPL--3.0-444444.svg?style=flat-square
[travis-link]: https://travis-ci.org/syuilo/misskey
[travis-badge]: http://img.shields.io/travis/syuilo/misskey/master.svg?style=flat-square
[dependencies-link]: https://david-dm.org/syuilo/misskey
[dependencies-badge]: https://img.shields.io/david/syuilo/misskey.svg?style=flat-square
[backer-url]: #backers
[backer-badge]: https://opencollective.com/misskey/backers/badge.svg
[backers-image]: https://opencollective.com/misskey/backers.svg
[sponsor-url]: #sponsors
[sponsor-badge]: https://opencollective.com/misskey/sponsors/badge.svg
[sponsors-image]: https://opencollective.com/misskey/sponsors.svg
[support-url]: https://opencollective.com/misskey#support
[syuilo-link]: https://syuilo.com
[syuilo-icon]: https://avatars2.githubusercontent.com/u/4439005?v=3&s=70
+1 -2
View File
@@ -9,8 +9,7 @@
**Microblogging. Redefined.**
**[Misskey](https://misskey.xyz)** is a completely open source,
ultimately sophisticated professional microblogging software.
[Misskey](https://misskey.xyz) is an **advanced**, **redefined**, and ultimately **sophisticated** microblogging platform.
<a href="https://www.patreon.com/syuilo"><img src="https://c5.patreon.com/external/logo/become_a_patron_button@2x.png" alt="Become a Patron!" width="160" /></a>
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "あなたのトークンが更新されたのでサインアウトします。"
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
drawn: "引き分け"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "ユーザー名"
checking: "確認しています..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "Dein Token wurde generiert. Du wirst jetzt abgemeldet."
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
drawn: "引き分け"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "Anmelden"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "Benutzername"
checking: "Überprüfung..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "Kreisförmige Icons"
gradient-window-header: "Übergang in Fensterköpfen"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "Zeige Antworten"
show-my-renotes: "Zeige meine Reposts auf der Zeitleiste"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+13 -11
View File
@@ -72,9 +72,9 @@ common:
a: "What are you doing?"
b: "What's happening?"
c: "Whats on your mind?"
d: "What do you wish to say?"
d: "Would you post any words?"
e: "Write here"
f: "Waiting for your writing..."
f: "Waiting for your writing."
search: "Search"
delete: "Delete"
loading: "Loading"
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "Your token has been regenerated, so you will be signed out."
i-like-sushi: "I prefer sushi rather than pudding"
show-reversi-board-labels: "Show row and column labels in Reversi"
verified-user: "Authorized User"
verified-user: "Verified account"
disable-animated-mfm: "Disable animated texts in a post"
reversi:
drawn: "Draw"
@@ -278,7 +278,7 @@ common/views/components/poll-editor.vue:
add: "+ Add a choice"
destroy: "Discard the poll"
common/views/components/reaction-picker.vue:
choose-reaction: "Express a reaction"
choose-reaction: "Send a reaction"
common/views/components/signin.vue:
username: "Username"
password: "Password"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "Sign in"
or: "Or"
signin-with-twitter: "Log in with Twitter"
login-failed: "Log in failed. Make sure you have entered your correct username and password."
common/views/components/signup.vue:
username: "Username"
checking: "Confirming..."
@@ -347,7 +348,7 @@ common/views/widgets/calendar.vue:
this-year: "This year: "
common/views/widgets/donation.vue:
title: "Request for donations"
text: "To keep Misskey up and running, we have to spend money on our domain name, the server costs and so on. Since we don't receive money from advertisements, we count on donations from all of you. If you're interested in helping, contact {}. Thank you for your contribution!"
text: "To keep Misskey up and running, there have to happen some expense for the domain name, the server and so on. Since our policy is not to display any advertisements, we count on your donations. If you're interested in helping, contact {}. Thank you for your contribution!"
common/views/widgets/photo-stream.vue:
title: "Photo stream"
no-photos: "No photos"
@@ -625,12 +626,13 @@ desktop/views/components/settings.vue:
circle-icons: "Use circle icons"
gradient-window-header: "Use gradients on window headers"
post-form-on-timeline: "Display post form at the top of the timeline"
suggest-recent-hashtags: "Show recent popular hashtags on the post form"
show-reply-target: "Display reply target"
show-my-renotes: "Show my renotes in the timeline"
show-renoted-my-notes: "Show renoted my posts in timelines"
show-local-renotes: "Show renoted local posts in timelines"
show-maps: "Display a map to show the location"
show-maps-desc: "Automatically show the location on the map attached to this post."
show-maps-desc: "If there comes a post contains location information, show a map to display the location."
sound: "Sound"
enable-sounds: "Enable sound"
enable-sounds-desc: "Play a sound when you receive a post/message. This setting is stored in the browser."
@@ -769,7 +771,7 @@ desktop/views/components/received-follow-requests-window.vue:
reject: "Reject"
desktop/views/components/user-lists-window.vue:
title: "User lists"
create-list: "Create new list"
create-list: "Create list"
list-name: "List name"
desktop/views/components/user-preview.vue:
notes: "Posts"
@@ -1013,7 +1015,7 @@ mobile/views/components/ui.nav.vue:
user-lists: "Lists"
widgets: "Widgets"
game: "Games"
darkmode: "Dark mode"
darkmode: "Dark theme"
settings: "Settings"
about: "About Misskey"
mobile/views/components/user-timeline.vue:
@@ -1141,8 +1143,8 @@ mobile/views/pages/user.vue:
timeline: "Timeline"
media: "Media"
is-suspended: "This account has been suspended."
is-remote: "This user is a remote user, so the information you see here is not complete."
view-remote: "See their complete profile"
is-remote: "The user is a remote user. The profile that you see here may not complete."
view-remote: "See his/her complete profile"
mobile/views/pages/user/home.vue:
recent-notes: "Recent notes"
images: "Images"
@@ -1166,7 +1168,7 @@ mobile/views/pages/user/home.photos.vue:
no-photos: "No photos"
docs:
edit-this-page-on-github: "Found a mistake or want to contribute for the documentation?"
edit-this-page-on-github-link: "Edit this page on Github!"
edit-this-page-on-github-link: "Edit this page at GitHub!"
api:
entities:
properties: "Properties"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "Tu token se ha regenerado vas a ser desconectado."
i-like-sushi: "Prefiero sushi a pudín"
show-reversi-board-labels: "Mostrar etiquetas de filas y columnas en Reversi"
verified-user: "Usuario verificado"
verified-user: "公式アカウント"
disable-animated-mfm: "Desactivar texto animado en una publicación"
reversi:
drawn: "Empatado"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "Entra"
or: "O"
signin-with-twitter: "Ingresar con Twitter"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "Usuario"
checking: "Comprobando..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "Usar iconos circulares"
gradient-window-header: "Usar degradados en las cabeceras de las páginas"
post-form-on-timeline: "Mostrar el formulario de las entradas encima de la línea de tiempo"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "Votre token vient d'être généré, vous allez maintenant être déconnecté."
i-like-sushi: "Je préfère les sushis (au pudding)"
show-reversi-board-labels: "Afficher les étiquettes des lignes et colonnes dans Reversi"
verified-user: "Utilisateur·trice vérifié·e"
verified-user: "公式アカウント"
disable-animated-mfm: "Désactiver les textes animés dans les publications"
reversi:
drawn: "Partie nulle"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "Se connecter"
or: "Ou"
signin-with-twitter: "Se connecter via Twitter"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "Nom d'utilisateur"
checking: "Vérification"
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "Utiliser des icônes circulaires"
gradient-window-header: "Utiliser les dégradés sur la barre de titre de la fenêtre"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "Afficher les réponses"
show-my-renotes: "Afficher mes republications dans le fil"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "あなたのトークンが更新されたのでサインアウトします。"
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
drawn: "引き分け"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "ユーザー名"
checking: "確認しています..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+11 -1
View File
@@ -90,7 +90,7 @@ common:
my-token-regenerated: "あなたのトークンが更新されたのでサインアウトします。"
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
@@ -314,8 +314,11 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
invitation-code: "招待コード"
invitation-info: "招待コードをお持ちでない方は、<a href=\"{}\">管理者</a>までご連絡ください。"
username: "ユーザー名"
checking: "確認しています..."
available: "利用できます"
@@ -707,6 +710,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
@@ -910,6 +914,7 @@ desktop/views/pages/admin/admin.dashboard.vue:
original-users: "このインスタンスのユーザー"
all-notes: "全てのノート"
original-notes: "このインスタンスのノート"
invite: "招待"
desktop/views/pages/admin/admin.suspend-user.vue:
suspend-user: "ユーザーの凍結"
@@ -921,6 +926,11 @@ desktop/views/pages/admin/admin.unsuspend-user.vue:
unsuspend: "凍結の解除"
unsuspended: "凍結を解除しました"
desktop/views/pages/admin/admin.verify-user.vue:
verify-user: "ユーザーの公式アカウント設定"
verify: "公式アカウントにする"
verified: "公式アカウントにしました"
desktop/views/pages/deck/deck.tl-column.vue:
is-media-only: "メディア投稿のみ"
is-media-view: "メディアビュー"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "당신의 토큰이 업데이트되어 있기 때문에 로그 아웃합니다."
i-like-sushi: "나는(푸딩보다 오히려)스시가 좋아"
show-reversi-board-labels: "리버시 보드의 행과 열 레이블을 표시"
verified-user: "인증 된 사용자"
verified-user: "公式アカウント"
disable-animated-mfm: "게시물의 문자 애니메이션을 비활성화 할"
reversi:
drawn: "무승부"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "ユーザー名"
checking: "確認しています..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "Twój token został wygenerowany. Zostaniesz wylogowany."
i-like-sushi: "Wolę sushi od puddingu"
show-reversi-board-labels: "Pokazuj podpisy wierszy i kolumn w Reversi"
verified-user: "Zweryfikowany użytkownik"
verified-user: "公式アカウント"
disable-animated-mfm: "Wyłącz animowany tekst we wpisach"
reversi:
drawn: "Remis"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "Zaloguj"
or: "または"
signin-with-twitter: "Zaloguj się za pomocą Twittera"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "Nazwa użytkownika"
checking: "Sprawdzanie…"
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "Używaj okrągłych ikon"
gradient-window-header: "Używaj gradientów na pasku tytułu okna"
post-form-on-timeline: "Wyświetlaj formularz tworzenia wpisu w górnej części osi czasu"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "Pokazuj cel odpowiedzi"
show-my-renotes: "Pokazuj moje udostępnienia na osi czasu"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "あなたのトークンが更新されたのでサインアウトします。"
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
drawn: "引き分け"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "ユーザー名"
checking: "確認しています..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "あなたのトークンが更新されたのでサインアウトします。"
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
drawn: "引き分け"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "ユーザー名"
checking: "確認しています..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -1
View File
@@ -84,7 +84,7 @@ common:
my-token-regenerated: "あなたのトークンが更新されたのでサインアウトします。"
i-like-sushi: "私は(プリンよりむしろ)寿司が好き"
show-reversi-board-labels: "リバーシのボードの行と列のラベルを表示"
verified-user: "認証済みのユーザー"
verified-user: "公式アカウント"
disable-animated-mfm: "投稿内の動きのあるテキストを無効にする"
reversi:
drawn: "引き分け"
@@ -287,6 +287,7 @@ common/views/components/signin.vue:
signin: "サインイン"
or: "または"
signin-with-twitter: "Twitterでログイン"
login-failed: "ログインできませんでした。ユーザー名とパスワードを確認してください。"
common/views/components/signup.vue:
username: "ユーザー名"
checking: "確認しています..."
@@ -625,6 +626,7 @@ desktop/views/components/settings.vue:
circle-icons: "円形のアイコンを使用"
gradient-window-header: "ウィンドウのタイトルバーにグラデーションを使用"
post-form-on-timeline: "タイムライン上部に投稿フォームを表示する"
suggest-recent-hashtags: "最近のハッシュタグを投稿フォームに表示する"
show-reply-target: "リプライ先を表示する"
show-my-renotes: "自分の行ったRenoteをタイムラインに表示する"
show-renoted-my-notes: "自分の投稿のRenoteをタイムラインに表示する"
+3 -3
View File
@@ -1,8 +1,8 @@
{
"name": "misskey",
"author": "syuilo <i@syuilo.com>",
"version": "6.2.0",
"clientVersion": "1.0.8417",
"version": "6.3.2",
"clientVersion": "1.0.8498",
"codename": "nighthike",
"main": "./built/index.js",
"private": true,
@@ -201,7 +201,7 @@
"typescript": "2.9.2",
"typescript-eslint-parser": "18.0.0",
"uglify-es": "3.3.9",
"url-loader": "1.1.0",
"url-loader": "1.1.1",
"uuid": "3.3.2",
"v-animate-css": "0.0.2",
"vue": "2.5.17",
@@ -12,7 +12,7 @@
</ui-input>
<ui-input v-if="user && user.twoFactorEnabled" v-model="token" type="number" required/>
<ui-button type="submit" :disabled="signing">{{ signing ? '%i18n:@signing-in%' : '%i18n:@signin%' }}</ui-button>
<p style="margin: 8px 0;" v-if="twitterIntegration">%i18n:@or%<a :href="`${apiUrl}/signin/twitter`">%i18n:@signin-with-twitter%</a></p>
<p style="margin: 8px 0;" v-if="twitterIntegration">%i18n:@or% <a :href="`${apiUrl}/signin/twitter`">%i18n:@signin-with-twitter%</a></p>
</form>
</template>
@@ -60,7 +60,7 @@ export default Vue.extend({
}).then(() => {
location.reload();
}).catch(() => {
alert('something happened');
alert('%i18n:@login-failed%');
this.signing = false;
});
}
@@ -1,5 +1,10 @@
<template>
<form class="mk-signup" @submit.prevent="onSubmit" :autocomplete="Math.random()">
<ui-input v-if="meta.disableRegistration" v-model="invitationCode" type="text" :autocomplete="Math.random()" spellcheck="false" required>
<span>%i18n:@invitation-code%</span>
<span slot="prefix">%fa:id-card-alt%</span>
<p slot="text" v-html="'%i18n:@invitation-info%'.replace('{}', meta.maintainer.url)"></p>
</ui-input>
<ui-input v-model="username" type="text" pattern="^[a-zA-Z0-9_]{1,20}$" :autocomplete="Math.random()" spellcheck="false" required @input="onChangeUsername">
<span>%i18n:@username%</span>
<span slot="prefix">@</span>
@@ -46,11 +51,13 @@ export default Vue.extend({
username: '',
password: '',
retypedPassword: '',
invitationCode: '',
url,
recaptchaSitekey,
usernameState: null,
passwordStrength: '',
passwordRetypeState: null
passwordRetypeState: null,
meta: null
}
},
computed: {
@@ -61,6 +68,11 @@ export default Vue.extend({
this.usernameState != 'max-range');
}
},
created() {
(this as any).os.getMeta().then(meta => {
this.meta = meta;
});
},
methods: {
onChangeUsername() {
if (this.username == '') {
@@ -110,6 +122,7 @@ export default Vue.extend({
(this as any).api('signup', {
username: this.username,
password: this.password,
invitationCode: this.invitationCode,
'g-recaptcha-response': recaptchaSitekey != null ? (window as any).grecaptcha.getResponse() : null
}).then(() => {
(this as any).api('signin', {
@@ -44,7 +44,12 @@ import Vue from 'vue';
import * as anime from 'animejs';
export default Vue.extend({
props: ['source', 'compact', 'v'],
props: ['source', 'compact'],
data() {
return {
v: this.$store.state.device.visibility || 'public'
}
},
mounted() {
this.$nextTick(() => {
const popover = this.$refs.popover as any;
@@ -92,6 +97,7 @@ export default Vue.extend({
},
methods: {
choose(visibility) {
this.$store.commit('device/setVisibility', visibility);
this.$emit('chosen', visibility);
this.$destroy();
},
@@ -55,15 +55,15 @@
</div>
<footer>
<mk-reactions-viewer :note="p"/>
<button @click="reply" title="">
<button class="replyButton" @click="reply" title="">
<template v-if="p.reply">%fa:reply-all%</template>
<template v-else>%fa:reply%</template>
<p class="count" v-if="p.repliesCount > 0">{{ p.repliesCount }}</p>
</button>
<button @click="renote" title="%i18n:@renote%">
<button class="renoteButton" @click="renote" title="%i18n:@renote%">
%fa:retweet%<p class="count" v-if="p.renoteCount > 0">{{ p.renoteCount }}</p>
</button>
<button :class="{ reacted: p.myReaction != null }" @click="react" ref="reactButton" title="%i18n:@add-reaction%">
<button class="reactionButton" :class="{ reacted: p.myReaction != null }" @click="react" ref="reactButton" title="%i18n:@add-reaction%">
%fa:plus%<p class="count" v-if="p.reactions_count > 0">{{ p.reactions_count }}</p>
</button>
<button @click="menu" ref="menuButton">
@@ -372,15 +372,24 @@ root(isDark)
cursor pointer
&:hover
color isDark ? #9198af : #666
color isDark ? #a1a8bf : #444
&.replyButton:hover
color #0af
&.renoteButton:hover
color #8d0
&.reactionButton:hover
color #fa0
> .count
display inline
margin 0 0 0 8px
color #999
&.reacted
color $theme-color
&.reacted, &.reacted:hover
color #fa0
> .replies
> *
@@ -42,15 +42,15 @@
</div>
<footer>
<mk-reactions-viewer :note="p" ref="reactionsViewer"/>
<button @click="reply" title="%i18n:@reply%">
<button class="replyButton" @click="reply" title="%i18n:@reply%">
<template v-if="p.reply">%fa:reply-all%</template>
<template v-else>%fa:reply%</template>
<p class="count" v-if="p.repliesCount > 0">{{ p.repliesCount }}</p>
</button>
<button @click="renote" title="%i18n:@renote%">
<button class="renoteButton" @click="renote" title="%i18n:@renote%">
%fa:retweet%<p class="count" v-if="p.renoteCount > 0">{{ p.renoteCount }}</p>
</button>
<button :class="{ reacted: p.myReaction != null }" @click="react" ref="reactButton" title="%i18n:@add-reaction%">
<button class="reactionButton" :class="{ reacted: p.myReaction != null }" @click="react" ref="reactButton" title="%i18n:@add-reaction%">
%fa:plus%<p class="count" v-if="p.reactions_count > 0">{{ p.reactions_count }}</p>
</button>
<button @click="menu" ref="menuButton">
@@ -487,20 +487,24 @@ root(isDark)
cursor pointer
&:hover
color isDark ? #9198af : #666
color isDark ? #a1a8bf : #444
&.replyButton:hover
color #0af
&.renoteButton:hover
color #8d0
&.reactionButton:hover
color #fa0
> .count
display inline
margin 0 0 0 8px
color #999
&.reacted
color $theme-color
&:last-child
position absolute
right 0
margin 0
&.reacted, &.reacted:hover
color #fa0
> .detail
padding-top 4px
@@ -10,7 +10,7 @@
<span v-for="u in visibleUsers">{{ u | userName }}<a @click="removeVisibleUser(u)">[x]</a></span>
<a @click="addVisibleUser">%i18n:@add-visible-user%</a>
</div>
<div class="hashtags" v-if="recentHashtags.length > 0">
<div class="hashtags" v-if="recentHashtags.length > 0 && $store.state.settings.suggestRecentHashtags">
<b>%i18n:@recent-tags%:</b>
<a v-for="tag in recentHashtags.slice(0, 5)" @click="addTag(tag)" title="%@click-to-tagging%">#{{ tag }}</a>
</div>
@@ -99,7 +99,7 @@ export default Vue.extend({
useCw: false,
cw: null,
geo: null,
visibility: 'public',
visibility: this.$store.state.device.visibility || 'public',
visibleUsers: [],
autocomplete: null,
draghover: false,
@@ -326,8 +326,7 @@ export default Vue.extend({
setVisibility() {
const w = (this as any).os.new(MkVisibilityChooser, {
source: this.$refs.visibilityButton,
v: this.visibility
source: this.$refs.visibilityButton
});
w.$once('chosen', v => {
this.visibility = v;
@@ -48,6 +48,7 @@
<mk-switch v-model="$store.state.settings.iLikeSushi" @change="onChangeILikeSushi" text="%i18n:common.i-like-sushi%"/>
</div>
<mk-switch v-model="$store.state.settings.showPostFormOnTopOfTl" @change="onChangeShowPostFormOnTopOfTl" text="%i18n:@post-form-on-timeline%"/>
<mk-switch v-model="$store.state.settings.suggestRecentHashtags" @change="onChangeSuggestRecentHashtags" text="%i18n:@suggest-recent-hashtags%"/>
<mk-switch v-model="$store.state.settings.showReplyTarget" @change="onChangeShowReplyTarget" text="%i18n:@show-reply-target%"/>
<mk-switch v-model="$store.state.settings.showMyRenotes" @change="onChangeShowMyRenotes" text="%i18n:@show-my-renotes%"/>
<mk-switch v-model="$store.state.settings.showRenotedMyNotes" @change="onChangeShowRenotedMyNotes" text="%i18n:@show-renoted-my-notes%"/>
@@ -336,6 +337,12 @@ export default Vue.extend({
value: v
});
},
onChangeSuggestRecentHashtags(v) {
this.$store.dispatch('settings/set', {
key: 'suggestRecentHashtags',
value: v
});
},
onChangeShowReplyTarget(v) {
this.$store.dispatch('settings/set', {
key: 'showReplyTarget',
@@ -7,6 +7,10 @@
<p><b>%i18n:@all-notes%</b>: <span>{{ stats.notesCount | number }}</span></p>
<p><b>%i18n:@original-notes%</b>: <span>{{ stats.originalNotesCount | number }}</span></p>
</div>
<div>
<button class="ui" @click="invite">%i18n:@invite%</button>
<p v-if="inviteCode">Code: <code>{{ inviteCode }}</code></p>
</div>
</div>
</template>
@@ -16,13 +20,21 @@ import Vue from "vue";
export default Vue.extend({
data() {
return {
stats: null
stats: null,
inviteCode: null
};
},
created() {
(this as any).api('stats').then(stats => {
this.stats = stats;
});
},
methods: {
invite() {
(this as any).api('admin/invite').then(x => {
this.inviteCode = x.code;
});
}
}
});
</script>
@@ -0,0 +1,51 @@
<template>
<div>
<header>%i18n:@verify-user%</header>
<input v-model="username" type="text" class="ui"/>
<button class="ui" @click="verifyUser" :disabled="verifying">%i18n:@verify%</button>
</div>
</template>
<script lang="ts">
import Vue from "vue";
import parseAcct from "../../../../../../misc/acct/parse";
export default Vue.extend({
data() {
return {
username: null,
verifying: false
};
},
methods: {
async verifyUser() {
this.verifying = true;
const user = await (this as any).os.api(
"users/show",
parseAcct(this.username)
);
await (this as any).os.api("admin/verify-user", {
userId: user.id
});
this.verifying = false;
(this as any).os.apis.dialog({ text: "%i18n:@verified%" });
}
}
});
</script>
<style lang="stylus" scoped>
@import '~const.styl'
header
margin 10px 0
button
margin 16px 0
</style>
@@ -15,6 +15,7 @@
<div v-if="page == 'users'">
<x-suspend-user/>
<x-unsuspend-user/>
<x-verify-user/>
</div>
<div v-if="page == 'drive'"></div>
<div v-if="page == 'update'"></div>
@@ -27,12 +28,14 @@ import Vue from "vue";
import XDashboard from "./admin.dashboard.vue";
import XSuspendUser from "./admin.suspend-user.vue";
import XUnsuspendUser from "./admin.unsuspend-user.vue";
import XVerifyUser from "./admin.verify-user.vue";
export default Vue.extend({
components: {
XDashboard,
XSuspendUser,
XUnsuspendUser
XUnsuspendUser,
XVerifyUser
},
data() {
return {
@@ -90,6 +93,14 @@ export default Vue.extend({
width 100%
padding 16px 32px
> div
> div
margin-bottom 16px
padding 32px
max-width 800px
background #fff
box-shadow 0 2px 8px rgba(#000, 0.1)
header
margin 10px 0
+1 -1
View File
@@ -95,7 +95,7 @@ export default Vue.extend({
callbackUrl: this.cb,
permission: this.permission
}).then(() => {
location.href = '/apps';
location.href = '/dev/apps';
}).catch(() => {
alert('アプリの作成に失敗しました。再度お試しください。');
});
@@ -45,7 +45,7 @@
<input ref="file" class="file" type="file" accept="image/*" multiple="multiple" @change="onChangeFile"/>
</div>
</div>
<div class="hashtags" v-if="recentHashtags.length > 0">
<div class="hashtags" v-if="recentHashtags.length > 0 && $store.state.settings.suggestRecentHashtags">
<a v-for="tag in recentHashtags.slice(0, 5)" @click="addTag(tag)">#{{ tag }}</a>
</div>
</div>
@@ -94,7 +94,7 @@ export default Vue.extend({
files: [],
poll: false,
geo: null,
visibility: 'public',
visibility: this.$store.state.device.visibility || 'public',
visibleUsers: [],
useCw: false,
cw: null,
@@ -240,8 +240,7 @@ export default Vue.extend({
setVisibility() {
const w = (this as any).os.new(MkVisibilityChooser, {
source: this.$refs.visibilityButton,
compact: true,
v: this.visibility
compact: true
});
w.$once('chosen', v => {
this.visibility = v;
+5
View File
@@ -11,6 +11,7 @@ const defaultSettings = {
fetchOnScroll: true,
showMaps: true,
showPostFormOnTopOfTl: false,
suggestRecentHashtags: true,
circleIcons: true,
gradientWindowHeader: false,
showReplyTarget: true,
@@ -109,6 +110,10 @@ export default (os: MiOS) => new Vuex.Store({
src: x.src,
arg: x.arg
};
},
setVisibility(state, visibility) {
state.visibility = visibility;
}
}
},
+2 -2
View File
@@ -28,7 +28,7 @@ import { Config } from './config/types';
const clusterLog = debug('misskey:cluster');
const ev = new Xev();
if (process.env.NODE_ENV != 'production') {
if (process.env.NODE_ENV != 'production' && process.env.DEBUG == null) {
debug.enable('misskey');
}
@@ -112,7 +112,7 @@ async function workerMain() {
async function init(): Promise<Config> {
Logger.info('Welcome to Misskey!');
(new Logger('Deps')).info(`Node.js ${process.version}`);
new Logger('Deps').info(`Node.js ${process.version}`);
MachineInfo.show();
EnvironmentInfo.show();
new DependencyInfo().showAll();
+1
View File
@@ -11,4 +11,5 @@ export type IMeta = {
usersCount: number;
originalUsersCount: number;
};
disableRegistration: boolean;
};
+12
View File
@@ -0,0 +1,12 @@
import * as mongo from 'mongodb';
import db from '../db/mongodb';
const RegistrationTicket = db.get<IRegistrationTicket>('registrationTickets');
RegistrationTicket.createIndex('code', { unique: true });
export default RegistrationTicket;
export interface IRegistrationTicket {
_id: mongo.ObjectID;
createdAt: Date;
code: string;
}
@@ -40,11 +40,13 @@ export default async function(resolver: Resolver, actor: IRemoteUser, activity:
if (!note.to.includes('https://www.w3.org/ns/activitystreams#Public')) {
if (note.cc.includes('https://www.w3.org/ns/activitystreams#Public')) {
visibility = 'home';
} else if (note.to.includes(`${actor.uri}/followers`)) { // TODO: person.followerと照合するべき?
visibility = 'followers';
} else {
visibility = 'specified';
visibleUsers = await Promise.all(note.to.map(uri => resolvePerson(uri)));
}
} if (activity.cc.length == 0) visibility = 'followers';
}
//#endergion
await post(actor, {
+15 -4
View File
@@ -1,4 +1,15 @@
export default (object: any) => ({
type: 'Announce',
object
});
import config from '../../../config';
import { INote } from '../../../models/note';
export default (object: any, note: INote) => {
const attributedTo = `${config.url}/users/${note.userId}`;
return {
id: `${config.url}/notes/${note._id}`,
type: 'Announce',
published: note.createdAt.toISOString(),
to: ['https://www.w3.org/ns/activitystreams#Public'],
cc: [attributedTo, `${attributedTo}/followers`],
object
};
};
+26
View File
@@ -0,0 +1,26 @@
import rndstr from 'rndstr';
import RegistrationTicket from '../../../../models/registration-tickets';
export const meta = {
desc: {
ja: '招待コードを発行します。'
},
requireCredential: true,
requireAdmin: true,
params: {}
};
export default (params: any) => new Promise(async (res, rej) => {
const code = rndstr({ length: 5, chars: '0-9' });
await RegistrationTicket.insert({
createdAt: new Date(),
code: code
});
res({
code: code
});
});
+30 -30
View File
@@ -4,43 +4,43 @@ import getParams from '../../get-params';
import User from '../../../../models/user';
export const meta = {
desc: {
ja: '指定したユーザーを凍結します。',
en: 'Suspend a user.'
},
desc: {
ja: '指定したユーザーを凍結します。',
en: 'Suspend a user.'
},
requireCredential: true,
requireAdmin: true,
requireCredential: true,
requireAdmin: true,
params: {
userId: $.type(ID).note({
desc: {
ja: '対象のユーザーID',
en: 'The user ID which you want to suspend'
}
}),
}
params: {
userId: $.type(ID).note({
desc: {
ja: '対象のユーザーID',
en: 'The user ID which you want to suspend'
}
}),
}
};
export default (params: any) => new Promise(async (res, rej) => {
const [ps, psErr] = getParams(meta, params);
if (psErr) return rej(psErr);
const [ps, psErr] = getParams(meta, params);
if (psErr) return rej(psErr);
const user = await User.findOne({
_id: ps.userId
});
const user = await User.findOne({
_id: ps.userId
});
if (user == null) {
return rej('user not found');
}
if (user == null) {
return rej('user not found');
}
await User.findOneAndUpdate({
_id: user._id
}, {
$set: {
isSuspended: true
}
});
await User.findOneAndUpdate({
_id: user._id
}, {
$set: {
isSuspended: true
}
});
res();
res();
});
@@ -0,0 +1,46 @@
import $ from 'cafy';
import ID from '../../../../misc/cafy-id';
import getParams from '../../get-params';
import User from '../../../../models/user';
export const meta = {
desc: {
ja: '指定したユーザーを公式アカウントにします。',
en: 'Mark a user as verified.'
},
requireCredential: true,
requireAdmin: true,
params: {
userId: $.type(ID).note({
desc: {
ja: '対象のユーザーID',
en: 'The user ID which you want to verify'
}
}),
}
};
export default (params: any) => new Promise(async (res, rej) => {
const [ps, psErr] = getParams(meta, params);
if (psErr) return rej(psErr);
const user = await User.findOne({
_id: ps.userId
});
if (user == null) {
return rej('user not found');
}
await User.findOneAndUpdate({
_id: user._id
}, {
$set: {
isVerified: true
}
});
res();
});
+2 -1
View File
@@ -28,6 +28,7 @@ export default () => new Promise(async (res, rej) => {
model: os.cpus()[0].model,
cores: os.cpus().length
},
broadcasts: meta.broadcasts
broadcasts: meta.broadcasts,
disableRegistration: meta.disableRegistration
});
});
+24
View File
@@ -6,6 +6,7 @@ import User, { IUser, validateUsername, validatePassword, pack } from '../../../
import generateUserToken from '../common/generate-native-user-token';
import config from '../../../config';
import Meta from '../../../models/meta';
import RegistrationTicket from '../../../models/registration-tickets';
if (config.recaptcha) {
recaptcha.init({
@@ -29,6 +30,29 @@ export default async (ctx: Koa.Context) => {
const username = body['username'];
const password = body['password'];
const invitationCode = body['invitationCode'];
const meta = await Meta.findOne({});
if (meta && meta.disableRegistration) {
if (invitationCode == null || typeof invitationCode != 'string') {
ctx.status = 400;
return;
}
const ticket = await RegistrationTicket.findOne({
code: invitationCode
});
if (ticket == null) {
ctx.status = 400;
return;
}
RegistrationTicket.remove({
_id: ticket._id
});
}
// Validate username
if (!validateUsername(username)) {
+1 -1
View File
@@ -235,7 +235,7 @@ export default async (user: IUser, data: Option, silent = false) => new Promise<
async function renderActivity(data: Option, note: INote) {
const content = data.renote && data.text == null
? renderAnnounce(data.renote.uri ? data.renote.uri : await renderNote(data.renote))
? renderAnnounce(data.renote.uri ? data.renote.uri : await renderNote(data.renote), note)
: renderCreate(await renderNote(note));
return packAp(content);