mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-04 00:20:20 +08:00
Currently all our preinstalled plugins use the default "gear" icon from fontawesome — this PR adds unique icons for each of them using a new plugin API method, `setAdminPluginIcon()`. Plugins without an icon defined will still fall back to the gear icon. Before: <img width="250" alt="image" src="https://github.com/user-attachments/assets/06b5c6e7-0aae-44f8-b8ee-1486b98bfc6b" /> After: <img width="250" alt="image" src="https://github.com/user-attachments/assets/46d45d4b-6c75-4473-ae53-1a0e71c4d6fb" />
23 lines
718 B
Ruby
23 lines
718 B
Ruby
# frozen_string_literal: true
|
|
|
|
# name: discourse-rss-polling
|
|
# about: This plugin enables support for importing embedded content from multiple RSS/ATOM feeds
|
|
# version: 0.0.1
|
|
# authors: xrav3nz
|
|
# url: https://github.com/discourse/discourse/tree/main/plugins/discourse-rss-polling
|
|
|
|
enabled_site_setting :rss_polling_enabled
|
|
add_admin_route "rss_polling.title", "rss_polling"
|
|
register_asset "stylesheets/rss-polling.scss"
|
|
register_svg_icon "floppy-disk"
|
|
register_svg_icon "rss"
|
|
|
|
module ::DiscourseRssPolling
|
|
PLUGIN_NAME = "discourse_rss_polling"
|
|
end
|
|
|
|
require_relative "lib/discourse_rss_polling/engine"
|
|
|
|
Discourse::Application.routes.append do
|
|
mount DiscourseRssPolling::Engine, at: "/admin/plugins/rss_polling"
|
|
end
|