Skip to content

Commit

Permalink
各種ソーシャルメディアへのリンクを追加
Browse files Browse the repository at this point in the history
  • Loading branch information
shimbaco committed Apr 10, 2024
1 parent 34a919b commit 0ab0558
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 35 deletions.
1 change: 1 addition & 0 deletions .env.development
Expand Up @@ -3,6 +3,7 @@ ANNICT_ASSET_URL=http://annict.test:3000
ANNICT_BASIC_AUTH_NAME=el-psy
ANNICT_BASIC_AUTH_PASSWORD=congroo
ANNICT_BASIC_AUTH=off
ANNICT_COMMUNITY_URL=https://github.com/annict/annict/blob/main/docs/community.md
ANNICT_CURRENT_SEASON=2019-spring
ANNICT_DISCORD_INVITE_URL=https://discord.gg/Uqbeq8t
ANNICT_DOMAIN=annict.test
Expand Down
19 changes: 1 addition & 18 deletions app/components/deprecated/footers/main_footer_component.rb
Expand Up @@ -17,16 +17,6 @@ def render
h.tag :div, class: "c-footer__description mb-3 small" do
h.text "A platform for anime addicts."
end

h.tag :div, class: "c-footer__social-links row" do
social_urls.each do |url, icon_name|
h.tag :div, class: "col col-auto" do
h.tag :a, aria_label: icon_name.humanize, href: url, class: "h2", target: "_blank", rel: "noopener" do
h.tag :i, class: "fab fa-#{icon_name}"
end
end
end
end
end

h.tag :div, class: "col-12 col-sm-3 mb-3 mb-sm-0" do
Expand Down Expand Up @@ -119,14 +109,6 @@ def render

private

def social_urls
[
["https://twitter.com/#{view_context.twitter_username}", "twitter"],
["https://github.com/annict", "github"],
[ENV.fetch("ANNICT_DISCORD_INVITE_URL"), "discord"]
]
end

def service_urls
[
[view_context.userland_path, t("noun.annict_userland")],
Expand All @@ -139,6 +121,7 @@ def service_urls

def content_urls
[
[view_context.community_path, t("noun.community"), true],
[view_context.faq_path, t("noun.faq"), true],
[view_context.terms_path, t("noun.terms_of_use"), true],
[view_context.privacy_path, t("noun.privacy_policy"), true],
Expand Down
7 changes: 7 additions & 0 deletions app/controllers/communities_controller.rb
@@ -0,0 +1,7 @@
# frozen_string_literal: true

class CommunitiesController < ApplicationV6Controller
def show
redirect_to(ENV.fetch("ANNICT_COMMUNITY_URL"), allow_other_host: true)
end
end
1 change: 1 addition & 0 deletions config/locales/noun.en.yml
Expand Up @@ -48,6 +48,7 @@ en:
comment_alt: Comment
comments_count: Comments
comments_count_shorten: Comments
community: Community
contents: Contents
column: Column
completed: Completed
Expand Down
1 change: 1 addition & 0 deletions config/locales/noun.ja.yml
Expand Up @@ -48,6 +48,7 @@ ja:
comment_alt: 感想
comments_count: 感想数
comments_count_shorten: コメント
community: コミュニティ
contents: コンテンツ
column: 項目
completed: 見たアニメ
Expand Down
1 change: 1 addition & 0 deletions config/routes.rb
Expand Up @@ -86,6 +86,7 @@
match "/collections/:collection_id/edit", via: :get, as: :edit_collection, to: "collections#edit"
match "/collections", via: :post, as: :collection_list, to: "collections#create"
match "/collections/new", via: :get, as: :new_collection, to: "collections#new"
match "/community", via: :get, as: :community, to: "communities#show"
match "/db", via: :get, as: :db_root, to: "db/home#show"
match "/db/activities", via: :get, as: :db_activity_list, to: "db/activities#index"
match "/db/casts/:id", via: :delete, as: :db_cast_detail, to: "db/casts#destroy"
Expand Down
8 changes: 8 additions & 0 deletions docs/community.md
@@ -0,0 +1,8 @@
# コミュニティ

Annictに関することは以下のソーシャルメディアで発信しています。

- [Mewst](https://mewst.com/@annict)
- [Bluesky](https://bsky.app/profile/annict.com)
- [Discord](https://discord.gg/PVJRUKP)
- [Threads](https://www.threads.net/@annictcom)
18 changes: 2 additions & 16 deletions docs/faq.md
Expand Up @@ -6,9 +6,8 @@

以下のいずれかよりご連絡ください。

- [フォーラム](https://annict.jp/forum)
- [Twitter](https://twitter.com/AnnictJP)
- [Discord](https://discord.gg/PVJRUKP)
- [フォーラム](https://annict.com/forum)
- [各種ソーシャルメディア](https://annict.com/community)
- メール: hello@annict.com

### 対応ブラウザは何ですか?
Expand Down Expand Up @@ -47,19 +46,6 @@
</details>


## Twitter連携に関する質問

### 記録やレビューがTwitterにシェアできなくなったのですが?

<details>
<summary>回答</summary>

TwitterからAnnictのTwitterアプリケーションが削除された可能性があります。AnnictのTwitterアプリケーションを削除すると、AnnictからTwitterが提供するWeb APIにアクセスできるなくなるため、Annictを経由したツイートができなくなります。
Twitterのアプリは[こちら](https://twitter.com/settings/connected_apps)から確認することができます。

</details>


## 機能追加・要望に関する質問

### 要望はどこから伝えれば良いですか?
Expand Down
2 changes: 1 addition & 1 deletion public/maintenance.html
Expand Up @@ -47,7 +47,7 @@
<h1>(`・ω・´)</h1>
<div class="message">
現在サーバメンテナンスを行っています。<br>
終わり次第 <a href="https://twitter.com/AnnictJP" target="_blank">@AnnictJP</a> でお知らせします。
終わり次第<a href="/community" target="_blank">各種ソーシャルメディア</a>でお知らせします。
</div>
</div>
</div>
Expand Down

0 comments on commit 0ab0558

Please sign in to comment.