-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This theme-component was recently moved from my personal profile (`/keegangeorge/discourse-copy-post`) to the Discourse org profile. Along with that move, we want to make some modernizations to prepare this theme-component to become #official. This PR handles those modernizations. In particular we: - update linting, configs, workflows, etc. - remove widget in favour of Glimmer `.gjs` component - update API usage to use `valueTransformer` instead of `decorateWidget` to add the post menu button - make improvements to behaviour by way of introducing new settings: - choosing between Markdown / HTML for the copied post - using `allowed_groups` setting instead of trust level setting - remove acceptance test in favour of system spec
- Loading branch information
1 parent
f9ba5bf
commit 02f1983
Showing
31 changed files
with
4,496 additions
and
2,652 deletions.
There are no files selected for viewing
Empty file.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
name: Discourse Theme | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
jobs: | ||
ci: | ||
uses: discourse/.github/.github/workflows/discourse-theme.yml@v1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
engine-strict = true | ||
auto-install-peers = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
inherit_gem: | ||
rubocop-discourse: stree-compat.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--print-width=100 | ||
--plugins=plugin/trailing_comma,plugin/disable_auto_ternary |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1 @@ | ||
module.exports = { | ||
plugins: ["ember-template-lint-plugin-discourse"], | ||
extends: "discourse:recommended", | ||
}; | ||
module.exports = require("@discourse/lint-configs/template-lint"); |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# frozen_string_literal: true | ||
|
||
source "https://rubygems.org" | ||
|
||
group :development do | ||
gem "rubocop-discourse" | ||
gem "syntax_tree" | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
GEM | ||
remote: https://rubygems.org/ | ||
specs: | ||
activesupport (7.2.2.1) | ||
base64 | ||
benchmark (>= 0.3) | ||
bigdecimal | ||
concurrent-ruby (~> 1.0, >= 1.3.1) | ||
connection_pool (>= 2.2.5) | ||
drb | ||
i18n (>= 1.6, < 2) | ||
logger (>= 1.4.2) | ||
minitest (>= 5.1) | ||
securerandom (>= 0.3) | ||
tzinfo (~> 2.0, >= 2.0.5) | ||
ast (2.4.2) | ||
base64 (0.2.0) | ||
benchmark (0.4.0) | ||
bigdecimal (3.1.9) | ||
concurrent-ruby (1.3.4) | ||
connection_pool (2.5.0) | ||
drb (2.2.1) | ||
i18n (1.14.6) | ||
concurrent-ruby (~> 1.0) | ||
json (2.9.1) | ||
language_server-protocol (3.17.0.3) | ||
logger (1.6.5) | ||
minitest (5.25.4) | ||
parallel (1.26.3) | ||
parser (3.3.6.0) | ||
ast (~> 2.4.1) | ||
racc | ||
prettier_print (1.2.1) | ||
racc (1.8.1) | ||
rack (3.1.8) | ||
rainbow (3.1.1) | ||
regexp_parser (2.10.0) | ||
rubocop (1.69.2) | ||
json (~> 2.3) | ||
language_server-protocol (>= 3.17.0) | ||
parallel (~> 1.10) | ||
parser (>= 3.3.0.2) | ||
rainbow (>= 2.2.2, < 4.0) | ||
regexp_parser (>= 2.9.3, < 3.0) | ||
rubocop-ast (>= 1.36.2, < 2.0) | ||
ruby-progressbar (~> 1.7) | ||
unicode-display_width (>= 2.4.0, < 4.0) | ||
rubocop-ast (1.37.0) | ||
parser (>= 3.3.1.0) | ||
rubocop-capybara (2.21.0) | ||
rubocop (~> 1.41) | ||
rubocop-discourse (3.9.2) | ||
activesupport (>= 6.1) | ||
rubocop (>= 1.59.0) | ||
rubocop-capybara (>= 2.0.0) | ||
rubocop-factory_bot (>= 2.0.0) | ||
rubocop-rails (>= 2.25.0) | ||
rubocop-rspec (>= 3.0.1) | ||
rubocop-rspec_rails (>= 2.30.0) | ||
rubocop-factory_bot (2.26.1) | ||
rubocop (~> 1.61) | ||
rubocop-rails (2.28.0) | ||
activesupport (>= 4.2.0) | ||
rack (>= 1.1) | ||
rubocop (>= 1.52.0, < 2.0) | ||
rubocop-ast (>= 1.31.1, < 2.0) | ||
rubocop-rspec (3.3.0) | ||
rubocop (~> 1.61) | ||
rubocop-rspec_rails (2.30.0) | ||
rubocop (~> 1.61) | ||
rubocop-rspec (~> 3, >= 3.0.1) | ||
ruby-progressbar (1.13.0) | ||
securerandom (0.4.1) | ||
syntax_tree (6.2.0) | ||
prettier_print (>= 1.2.0) | ||
tzinfo (2.0.6) | ||
concurrent-ruby (~> 1.0) | ||
unicode-display_width (3.1.3) | ||
unicode-emoji (~> 4.0, >= 4.0.4) | ||
unicode-emoji (4.0.4) | ||
|
||
PLATFORMS | ||
arm64-darwin-22 | ||
ruby | ||
|
||
DEPENDENCIES | ||
rubocop-discourse | ||
syntax_tree | ||
|
||
BUNDLED WITH | ||
2.5.22 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) Civilized Discourse Construction Kit, Inc. | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
Oops, something went wrong.