Discourse 谁在线

:discourse2: 摘要 Discourse Who’s Online 显示当前在网站上活跃的用户列表
:hammer_and_wrench: 仓库链接 https://github.com/discourse/discourse-whos-online
:open_book: 安装指南 如何在 Discourse 中安装插件

功能

:information_source: 在安装此插件之前请仔细考虑。Discourse 的设计目的是进行异步讨论,而在线用户列表可能对某些社区有害。

:information_source: 此插件是为拥有 <100 个并发登录用户的社区构建的。在更大的网站上安装是可能的,但可能会对整个论坛的性能产生负面影响。

它还可以选择显示用户头像上的在线状态。可以选择使用“圆环”、“发光”或在左上角使用“徽章”图标。

该插件使用 MessageBus 保持最新状态,因此用户状态会实时反映。启用了“隐藏个人资料和在线状态”设置的将不会显示。您可以使用可用的站点设置和语言字符串自定义许多内容:

配置

这些可在管理员设置面板的“插件”部分中找到。

  • whos_online_active_timeago: 用户被视为在线的最大“最后可见”时间(分钟)
  • whos_online_collapse_threshold: 头像开始相互重叠的用户数量(参见上面的 gif)。设置为非常高的值以禁用此功能
  • whos_online_maximum_display: 要显示的最大头像数量。数字计数器仍将计算高于此值的数量。目前谁被显示是不一致的
  • whos_online minimum_display: 要显示的最小头像数量。低于此值时,将显示“没有在线用户”的消息
  • whos_online_hide_below_minimum_display: 如果启用,当用户数量少于 minimum_display 时,小部件将被完全隐藏
  • whos_online_display_public: 是否应显示给未登录的人?默认为 true。
  • whos_online_display_min_trust_level: 显示此插件的最小信任级别。默认为 0
  • whos_online_avatar_indicator: 选择如何在用户头像上显示在线状态。默认为“圆环”
  • whos_online_avatar_indicator_topic_lists: 在 mobile 主题列表和“类别与最新”视图中显示头像指示器。默认为关闭。
  • whos_online_count_only: 启用时,仅显示计数。在线用户的身份将不会泄露

:speech_balloon: 前端语言字符串

这些可在管理员面板下的 自定义文本内容 中找到(搜索 whos_online)。这些包括:

  • js.whos_online.no_users | “当前没有在线用户”:当用户数量 < whos online minimum display 设置时显示的消息。
  • js.whos_online.title | “在线 ({{count}})”:头像列表之前显示的文本。{{count}} 是在线用户的数量。
  • js.whos_online.tooltip | “过去 5 分钟内看到的用户”:鼠标悬停在文本上时显示的文本。
152 个赞
[Paid] "What's Going On?" plugin. [COMPLETE]
How do I bring back my community that was very active 10 years ago?
Quick Messages Plugin
Do you display the list of live forum users on your counterpart website?
Who's online "action"
Split profile hiding and presence
Can I activate my plugin only for those registered on the site?
No online status in Topic List
Change Online (x) text to pulsing green dot
MKJ's Opinionated Discourse Deployment Configuration
Need cool plugin feedback suggestions?
Who's online crazy load
Advice for getting my little game dev community "out there?"
Contributor Interviews – David Taylor
Community Network Visualisation
Why you should use Discourse internally for your company/team instead of Slack (4 years use case)
Babble Chat
Forum with user diary/blog/profile
Category Banners
Topic Author
How does group messaging work in Discourse?
Group PM “pick up where you left off”
What happens next?
Failed to construct 'Notification': Illegal constructor
How minimal is your forum?
How to show a user’s online status?
TavoWEB theme for Discourse
Correct way to build components
[Paid] "What's Going On?" plugin. [COMPLETE]
How serious is "site is under extreme load, search is disabled, try again later"
User reporting unable to hide presence
List of all the pages that users are in
My discourse speed is very slow
Any way to show live stats to users?
Original Poster Avatars not working well with Who's Online
Where are topics related to WordPress integrations where Discourse is a paid subscription?
Babble Chat
User card huge avatar outline appears on plugins and components
How does the online presence work?
Why is the green tick a red exclamation?
Must have plugins and components for Discourse?
Bundling more popular plugins with Discourse core
Loading slider issues
Homepage plugin for displaying recent topics, latest members, popular threads, and similar elements
Possible to show number of visitors in real time?
Who's Online doesn't work for me

3 个帖子被拆分到一个新主题:Who’s Online 的更详细信息

请注意,此插件(至少在我们的论坛上)会显示以下消息。当我们关闭该插件时,消息就会消失。还有其他人遇到此问题吗?我们的服务器足以应对活跃用户数量。正在使用 Lightsail 8 GB RAM、2 vCPU、160 GB SSD Ubuntu


1 个赞

这个插件非常好用,特别是开启聊天功能后。不过,我想问一下是否可以添加一项功能,与个人用户设置集成,以隐藏自己的个人状态,这与其他聊天应用程序类似。

5 个赞

@bksubhuti 您是指这个吗?

1 个赞

我认为这个选项有点过了。在在线指示器方面,“隐身”是一项相当标准的功能,不应要求完全禁用您的个人资料。这也是我没有为非管理员用户启用此插件的原因之一。

3 个赞

我没看到那个属性,但快速谷歌了一下,发现它在界面里。
我可能会发个帖子建议 discourse 的开发者将隐藏个人资料的功能放到个人资料标题下。这似乎更合乎逻辑。界面更多地与布局和设置相关。

是的,它正如你所说的那样工作。

我真的很喜欢你的插件,也很感谢你的工作和快速响应。我们是一个拥有 100 多名用户的小型 discourse 社区,同时在线的用户很少超过 4 人,但能有这个功能和聊天功能很有趣。

1 个赞

2 篇帖子已拆分为新主题:允许用户隐藏在线状态

简单来说,只有将个人资料设置为私密的用户才不会显示在“在线用户”列表中,这是出于隐私设置的考虑。

1 个赞

3 篇帖子已合并到现有主题:Right now,I am in TL1. Can anyone tell me a boy trust level thing?

想知道是否可以将此作为主题组件来显示基本信息,而不是所有这些详细信息,\n例如,仅显示过去 5 或 10 分钟的访客人数。\n\n谢谢

设置 whos_online_active_timeagowhos_online_count_only

嘿,@david
感谢这个很棒的插件。
有一些建议:

  • 是否可以显示所有登录用户的数量,而不仅仅是活跃用户?现在,如果有人登录但没有发帖/回复,他们就不会被计算在内。
  • 是否可以添加访客(未登录用户)的数量?

感谢您的辛勤工作!希望您可以考虑这些增强功能,不确定是否可能/容易实现。

5 个赞

Can this be used on Discourse hosted by Discourse?

I tried adding it to components and get an error. I’m new to this but get it quick

此内容是否可以在由 Discourse 托管的 Discourse 上使用?

我尝试将其添加到组件中,但出现错误。我对此是新手,但很快就会明白。

这是一个插件,而不是 Discourse 主题/组件。您需要检查您注册的套餐是否包含此功能。

3 个赞

这是一个 Customization > Plugin(插件),而非 Customization > Theme(主题)或 Customization > Theme component(主题组件)。

您被允许使用的插件取决于您的托管计划。

您需要企业级托管才能使用此插件。

4 个赞

有在线用户组件吗?这是一个非常老式和基本论坛的功能?似乎不应该被限制在更高级别的订阅中?

1 个赞

欢迎大家随时纠正我。

我能想到的最接近 Customization > Theme component 的是这个:

2 个赞

是否有地方像插件一样列出所有组件? 谢谢!

所有 TC 均位于 Customization > Theme component 类别中,您可以通过标签(例如 official)进一步筛选。

1 个赞