publify_core 10.0.3 → 11.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (201) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +249 -53
  3. data/app/assets/javascripts/publify.js +0 -1
  4. data/app/assets/javascripts/publify_admin.js +10 -9
  5. data/app/assets/stylesheets/accounts.css.scss +0 -2
  6. data/app/assets/stylesheets/administration_structure.css.scss +0 -4
  7. data/app/assets/stylesheets/publify.css.scss +0 -1
  8. data/app/assets/stylesheets/publify_admin.css.scss +0 -2
  9. data/app/assets/stylesheets/sidebar_admin.css.scss +0 -6
  10. data/app/controllers/admin/articles_controller.rb +1 -1
  11. data/app/controllers/admin/base_controller.rb +2 -2
  12. data/app/controllers/admin/redirects_controller.rb +2 -2
  13. data/app/controllers/admin/resources_controller.rb +1 -1
  14. data/app/controllers/admin/seo_controller.rb +2 -2
  15. data/app/controllers/admin/settings_controller.rb +2 -2
  16. data/app/controllers/admin/tags_controller.rb +1 -1
  17. data/app/controllers/admin/users_controller.rb +2 -2
  18. data/app/controllers/articles_controller.rb +2 -5
  19. data/app/controllers/authors_controller.rb +0 -2
  20. data/app/controllers/comments_controller.rb +5 -2
  21. data/app/controllers/content_controller.rb +0 -4
  22. data/app/controllers/notes_controller.rb +1 -6
  23. data/app/controllers/setup_controller.rb +1 -1
  24. data/app/controllers/tags_controller.rb +0 -1
  25. data/app/controllers/users/registrations_controller.rb +1 -0
  26. data/app/helpers/admin/base_helper.rb +20 -13
  27. data/app/helpers/admin/feedback_helper.rb +4 -4
  28. data/app/helpers/base_helper.rb +10 -6
  29. data/app/helpers/xml_helper.rb +4 -0
  30. data/app/models/article.rb +7 -7
  31. data/app/models/blog.rb +3 -3
  32. data/app/models/comment.rb +1 -1
  33. data/app/models/config_manager.rb +1 -3
  34. data/app/models/content.rb +4 -5
  35. data/app/models/content_base.rb +4 -3
  36. data/app/models/feedback.rb +1 -1
  37. data/app/models/note.rb +74 -8
  38. data/app/models/page.rb +1 -1
  39. data/app/models/redirect.rb +0 -4
  40. data/app/models/resource.rb +1 -0
  41. data/app/models/sidebar.rb +6 -14
  42. data/app/models/tag.rb +2 -2
  43. data/app/models/text_filter.rb +2 -2
  44. data/app/models/trigger.rb +1 -1
  45. data/app/models/user.rb +12 -21
  46. data/app/uploaders/resource_uploader.rb +11 -4
  47. data/app/views/admin/articles/_form.html.erb +99 -105
  48. data/app/views/admin/articles/index.html.erb +15 -23
  49. data/app/views/admin/dashboard/_comment.html.erb +1 -1
  50. data/app/views/admin/dashboard/_comments.html.erb +4 -6
  51. data/app/views/admin/dashboard/_drafts.html.erb +4 -6
  52. data/app/views/admin/dashboard/_overview.html.erb +2 -5
  53. data/app/views/admin/dashboard/_welcome.html.erb +19 -19
  54. data/app/views/admin/dashboard/index.html.erb +3 -3
  55. data/app/views/admin/feedback/_button.html.erb +7 -13
  56. data/app/views/admin/feedback/article.html.erb +17 -17
  57. data/app/views/admin/feedback/edit.html.erb +17 -21
  58. data/app/views/admin/feedback/index.html.erb +8 -8
  59. data/app/views/admin/notes/_form.html.erb +5 -5
  60. data/app/views/admin/notes/_list.html.erb +1 -1
  61. data/app/views/admin/notes/_note.html.erb +1 -1
  62. data/app/views/admin/notes/edit.html.erb +1 -1
  63. data/app/views/admin/notes/index.html.erb +1 -1
  64. data/app/views/admin/pages/_form.html.erb +23 -27
  65. data/app/views/admin/post_types/_index_and_form.html.erb +5 -5
  66. data/app/views/admin/redirects/_index_and_form.html.erb +2 -2
  67. data/app/views/admin/resources/index.html.erb +20 -8
  68. data/app/views/admin/seo/_general.html.erb +36 -36
  69. data/app/views/admin/seo/_permalinks.html.erb +22 -14
  70. data/app/views/admin/seo/_titles.html.erb +63 -63
  71. data/app/views/admin/settings/display.html.erb +23 -23
  72. data/app/views/admin/settings/feedback.html.erb +29 -29
  73. data/app/views/admin/settings/index.html.erb +21 -21
  74. data/app/views/admin/settings/write.html.erb +18 -18
  75. data/app/views/admin/shared/_flash.html.erb +6 -0
  76. data/app/views/admin/shared/_menu.html.erb +56 -68
  77. data/app/views/admin/sidebar/_config.html.erb +15 -19
  78. data/app/views/admin/sidebar/_target.html.erb +3 -3
  79. data/app/views/admin/sidebar/_target_sidebar.html.erb +14 -13
  80. data/app/views/admin/sidebar/index.html.erb +2 -2
  81. data/app/views/admin/tags/_index_and_form.html.erb +3 -3
  82. data/app/views/admin/themes/index.html.erb +21 -19
  83. data/app/views/admin/users/_form.html.erb +79 -79
  84. data/app/views/articles/search.html.erb +1 -1
  85. data/app/views/layouts/accounts.html.erb +7 -9
  86. data/app/views/layouts/administration.html.erb +2 -2
  87. data/app/views/notes/show.html.erb +15 -0
  88. data/app/views/setup/index.html.erb +1 -1
  89. data/app/views/shared/_atom_item_article.atom.builder +1 -3
  90. data/app/views/shared/_rss_item_article.rss.builder +1 -2
  91. data/config/i18n-tasks.yml +0 -1
  92. data/config/locales/ar.yml +3 -2
  93. data/config/locales/da.yml +3 -2
  94. data/config/locales/de.yml +3 -2
  95. data/config/locales/en.yml +3 -2
  96. data/config/locales/es-MX.yml +3 -2
  97. data/config/locales/fr.yml +3 -2
  98. data/config/locales/he.yml +3 -2
  99. data/config/locales/it.yml +3 -2
  100. data/config/locales/ja.yml +3 -2
  101. data/config/locales/lt.yml +3 -2
  102. data/config/locales/nb.yml +3 -2
  103. data/config/locales/nl.yml +3 -2
  104. data/config/locales/pl.yml +3 -2
  105. data/config/locales/pt-BR.yml +3 -2
  106. data/config/locales/ro.yml +3 -2
  107. data/config/locales/ru.yml +3 -2
  108. data/config/locales/zh-CN.yml +3 -2
  109. data/config/locales/zh-TW.yml +3 -2
  110. data/config/routes.rb +0 -11
  111. data/db/migrate/114_fixes_buggy_articles_and_notes.rb +2 -2
  112. data/db/migrate/20150807134129_simplify_redirect_relations.rb +1 -1
  113. data/db/migrate/20160605154632_remove_profiles.rb +1 -1
  114. data/db/migrate/20190208152646_move_text_filter_to_name.rb +2 -2
  115. data/lib/format.rb +2 -2
  116. data/lib/publify_core/engine.rb +10 -0
  117. data/lib/publify_core/string_ext.rb +1 -13
  118. data/lib/publify_core/testing_support/fixtures/like_plain.html +2 -0
  119. data/lib/publify_core/text_filter/markdown.rb +5 -1
  120. data/lib/publify_core/text_filter/markdown_smartquotes.rb +6 -1
  121. data/lib/publify_core/version.rb +1 -1
  122. data/lib/publify_core.rb +2 -2
  123. data/lib/text_filter_plugin.rb +20 -22
  124. data/lib/theme.rb +56 -37
  125. metadata +101 -397
  126. data/app/assets/javascripts/bootstrap/affix.js +0 -164
  127. data/app/assets/javascripts/bootstrap/alert.js +0 -95
  128. data/app/assets/javascripts/bootstrap/button.js +0 -125
  129. data/app/assets/javascripts/bootstrap/collapse.js +0 -212
  130. data/app/assets/javascripts/bootstrap/dropdown.js +0 -165
  131. data/app/assets/javascripts/bootstrap/modal.js +0 -358
  132. data/app/assets/javascripts/bootstrap/tab.js +0 -155
  133. data/app/assets/javascripts/bootstrap/transition.js +0 -59
  134. data/app/assets/javascripts/bootstrap-sprockets.js +0 -8
  135. data/app/assets/javascripts/lightbox.js +0 -350
  136. data/app/assets/stylesheets/_bootstrap-compass.scss +0 -9
  137. data/app/assets/stylesheets/_bootstrap-mincer.scss +0 -19
  138. data/app/assets/stylesheets/_bootstrap-sprockets.scss +0 -9
  139. data/app/assets/stylesheets/_bootstrap.scss +0 -42
  140. data/app/assets/stylesheets/bootstrap/_alerts.scss +0 -73
  141. data/app/assets/stylesheets/bootstrap/_button-groups.scss +0 -242
  142. data/app/assets/stylesheets/bootstrap/_buttons.scss +0 -168
  143. data/app/assets/stylesheets/bootstrap/_close.scss +0 -37
  144. data/app/assets/stylesheets/bootstrap/_code.scss +0 -69
  145. data/app/assets/stylesheets/bootstrap/_component-animations.scss +0 -38
  146. data/app/assets/stylesheets/bootstrap/_dropdowns.scss +0 -213
  147. data/app/assets/stylesheets/bootstrap/_forms.scss +0 -586
  148. data/app/assets/stylesheets/bootstrap/_grid.scss +0 -94
  149. data/app/assets/stylesheets/bootstrap/_labels.scss +0 -66
  150. data/app/assets/stylesheets/bootstrap/_media.scss +0 -66
  151. data/app/assets/stylesheets/bootstrap/_mixins.scss +0 -37
  152. data/app/assets/stylesheets/bootstrap/_modals.scss +0 -150
  153. data/app/assets/stylesheets/bootstrap/_navbar.scss +0 -479
  154. data/app/assets/stylesheets/bootstrap/_navs.scss +0 -242
  155. data/app/assets/stylesheets/bootstrap/_normalize.scss +0 -427
  156. data/app/assets/stylesheets/bootstrap/_pagination.scss +0 -86
  157. data/app/assets/stylesheets/bootstrap/_panels.scss +0 -222
  158. data/app/assets/stylesheets/bootstrap/_print.scss +0 -99
  159. data/app/assets/stylesheets/bootstrap/_scaffolding.scss +0 -160
  160. data/app/assets/stylesheets/bootstrap/_tables.scss +0 -234
  161. data/app/assets/stylesheets/bootstrap/_theme.scss +0 -224
  162. data/app/assets/stylesheets/bootstrap/_type.scss +0 -296
  163. data/app/assets/stylesheets/bootstrap/_utilities.scss +0 -55
  164. data/app/assets/stylesheets/bootstrap/_variables.scss +0 -638
  165. data/app/assets/stylesheets/bootstrap/_wells.scss +0 -29
  166. data/app/assets/stylesheets/bootstrap/mixins/_alerts.scss +0 -15
  167. data/app/assets/stylesheets/bootstrap/mixins/_background-variant.scss +0 -12
  168. data/app/assets/stylesheets/bootstrap/mixins/_border-radius.scss +0 -18
  169. data/app/assets/stylesheets/bootstrap/mixins/_buttons.scss +0 -56
  170. data/app/assets/stylesheets/bootstrap/mixins/_center-block.scss +0 -7
  171. data/app/assets/stylesheets/bootstrap/mixins/_clearfix.scss +0 -22
  172. data/app/assets/stylesheets/bootstrap/mixins/_forms.scss +0 -82
  173. data/app/assets/stylesheets/bootstrap/mixins/_gradients.scss +0 -56
  174. data/app/assets/stylesheets/bootstrap/mixins/_grid-framework.scss +0 -81
  175. data/app/assets/stylesheets/bootstrap/mixins/_grid.scss +0 -122
  176. data/app/assets/stylesheets/bootstrap/mixins/_hide-text.scss +0 -21
  177. data/app/assets/stylesheets/bootstrap/mixins/_image.scss +0 -28
  178. data/app/assets/stylesheets/bootstrap/mixins/_labels.scss +0 -12
  179. data/app/assets/stylesheets/bootstrap/mixins/_nav-divider.scss +0 -10
  180. data/app/assets/stylesheets/bootstrap/mixins/_nav-vertical-align.scss +0 -9
  181. data/app/assets/stylesheets/bootstrap/mixins/_opacity.scss +0 -7
  182. data/app/assets/stylesheets/bootstrap/mixins/_pagination.scss +0 -24
  183. data/app/assets/stylesheets/bootstrap/mixins/_panels.scss +0 -20
  184. data/app/assets/stylesheets/bootstrap/mixins/_reset-filter.scss +0 -8
  185. data/app/assets/stylesheets/bootstrap/mixins/_resize.scss +0 -6
  186. data/app/assets/stylesheets/bootstrap/mixins/_responsive-visibility.scss +0 -17
  187. data/app/assets/stylesheets/bootstrap/mixins/_size.scss +0 -10
  188. data/app/assets/stylesheets/bootstrap/mixins/_tab-focus.scss +0 -9
  189. data/app/assets/stylesheets/bootstrap/mixins/_table-row.scss +0 -28
  190. data/app/assets/stylesheets/bootstrap/mixins/_text-emphasis.scss +0 -12
  191. data/app/assets/stylesheets/bootstrap/mixins/_text-overflow.scss +0 -8
  192. data/app/assets/stylesheets/bootstrap/mixins/_vendor-prefixes.scss +0 -222
  193. data/app/assets/stylesheets/lightbox.css +0 -63
  194. data/app/controllers/theme_controller.rb +0 -63
  195. data/app/views/notes/show_in_reply.html.erb +0 -18
  196. data/app/views/theme/static_view_test.html.erb +0 -1
  197. data/lib/publify_core/text_filter/twitterfilter.rb +0 -55
  198. data/lib/tasks/manifest.rake +0 -30
  199. /data/app/views/layouts/{default.html.erb → application.html.erb} +0 -0
  200. /data/themes/plain/javascripts/{theme.js → plain/theme.js} +0 -0
  201. /data/themes/plain/stylesheets/{theme.css → plain/theme.css} +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b3e5084922bf07bd1308c17a903b8d97773f92b4068a02aedbddb77ee3e4d86c
4
- data.tar.gz: d8689c538a7fad96f040adc776cc55b9f489a5bcfaef8dfa6ca7b4a31aa3a385
3
+ metadata.gz: 9ce0abf6a55254193cdc6475dd86481f250201069155275d9178b17f87fb5e9e
4
+ data.tar.gz: fe986ec81f387a6bd29a91a7be4d62d7f3655bbd19523ad12c02ba4e1b7cf292
5
5
  SHA512:
6
- metadata.gz: aeeeb16cf53b8f6fd74cfd04ac9c960a25f05fd603e4d127cbee813d37a8ddd2675ed6f082aa2ea59155aa3ab407297c6a733d8ce0f124d4a9affd98163a52e7
7
- data.tar.gz: 80b5de3c4bd37f72ccbce5d27d10fbff4519d3bca84a30eee988e389b48b83b6969320c90db38590aeae40a46be5708e838ea066855ea6aef4a254f50cb2632f
6
+ metadata.gz: 93aaa5759263e4e8fb3fe8cb56f33e3469a0ed085503e10d6b37c12c6ca45816c56f567424283ea171d8109b0968679b4cebf0fc97c0217db32172dcb095ca1d
7
+ data.tar.gz: 1d954da004caa610dd8f306f5c482a415887cde00f9b0a2ad4ea7e2d5ab67ade36bb3f90826071ac101d1f7e7525d435724e5f5bc89cc7ec52c97be19c0573cb
data/CHANGELOG.md CHANGED
@@ -1,5 +1,173 @@
1
1
  # Changelog
2
2
 
3
+ ## 11.0.0 / 2026-10-04
4
+
5
+ This major release updates Rails to version 7.2, and updates supported Ruby
6
+ versions to 3.2 through 4.0. It also includes breaking changes to theming
7
+ support.
8
+
9
+ ### Security
10
+
11
+ * Refuse attempts to upload a file detected as text with an html extension ([#268] by [mvz])
12
+
13
+ ### Ruby support
14
+
15
+ PublifyCore 11.0 supports Ruby 3.2 through 4.0, dropping support for older versions:
16
+
17
+ * Support Ruby 3.0 and up ([#136] by [mvz])
18
+ * Add Ruby 3.4 to the GitHub Actions matrix ([#167] by [mvz])
19
+ * Drop support for Ruby 3.0 and 3.1 ([#189] by [mvz])
20
+ * Test with Ruby 4.0 in CI ([#221] by [mvz])
21
+
22
+ ### Rails support
23
+
24
+ PublifyCore 11.0 supports Rails 7.1 and 7.2:
25
+
26
+ * Drop support for Rails 6.1 ([#195] by [mvz])
27
+ * Set explicit coder for serialized attributes ([#198] by [mvz])
28
+ * Support Rails 7.2 ([#261] by [mvz])
29
+ * Handle Rails 7.1 deprecation warnings ([#222] by [mvz])
30
+ * Drop support for Rails 7.0 ([#215] by [mvz])
31
+ * Make old migration work with Postgres in Rails 7.2 ([#262] by [mvz])
32
+
33
+ ### Theming
34
+
35
+ This release includes breaking changes to theming. Themes must now use the
36
+ default Rails layout name, `application`. All theme assets are served via the
37
+ asset pipeline. To avoid asset name conflicts, themes must namespace their
38
+ assets with the theme name.
39
+
40
+ For example for a theme named 'foo', this results in the following setup:
41
+
42
+ * Layout in `themes/foo/views/layouts/application.html.erb`
43
+ * In the layout, links to style sheets and javascript files that automatically
44
+ prefix the theme name:
45
+
46
+ ```erb
47
+ <%= themeable_stylesheet_link_tag :theme %>
48
+ <%= themeable_javascript_include_tag :theme %>
49
+ ```
50
+
51
+ * Asset files:
52
+ * `themes/foo/javascripts/foo/theme.js`
53
+ * `themes/foo/stylesheets/foo/theme.css`
54
+
55
+ Related pull requests:
56
+
57
+ * Simplify derivation of a theme's name from its path ([#240] by [mvz])
58
+ * Remove translation only used in Typographic theme ([#245] by [mvz])
59
+ * Always use the standard Rails layout name for the content pages ([#244] by [mvz])
60
+ * Use the asset pipeline for theme assets ([#247] by [mvz])
61
+
62
+ ### Dependencies
63
+
64
+ * Port Admin views to Bootstrap 4 ([#178] by [mvz])
65
+ * Upgrade to commonmarker version 2.3 ([#193] by [mvz])
66
+ * Upgrade to bootstrap 5.3 ([#234] by [mvz])
67
+ * Update Devise to version 5.0.4 ([#226] by [mvz])
68
+
69
+ ### Miscellaneous
70
+
71
+ * Upgrade `html_pipeline` to version 3.2 and port custom filters ([#211] by [mvz])
72
+ * Replace `devise_zxcvbn` with direct integration of `zxcvbn` ([#217] by [mvz])
73
+ * Add specs for `ContentBase#excerpt_text` ([#228] by [mvz])
74
+ * Remove monkey-patched `String#strip_html` method ([#231] by [mvz])
75
+ * Clean up deprecations ([#233] by [mvz])
76
+ * Remove EkkoLightbox ([#235] by [mvz])
77
+ * Remove old password fallback mechanism ([#236] by [mvz])
78
+ * Clean up textfilter macro methods ([#238] by [mvz])
79
+ * Replace ad-hoc excerpt code with `#excerpt_text` ([#239] by [mvz])
80
+ * Remove useless `Redirect#to_url` method ([#252] by [mvz])
81
+ * Remove html tags the Rails way when generating permalinks ([#249] by [mvz])
82
+
83
+ ### Internal
84
+
85
+ * Allow starting the GitHub Actions workflow manually ([#140] by [mvz])
86
+ * Pull in latest changes from 10-0-stable ([#164] by [mvz])
87
+ * Pull in latest changes from 10-0-stable ([#152] by [mvz])
88
+ * Fix linting job in GitHub Actions ([#158] by [mvz])
89
+ * Provide needed graphics processing dependency in CI ([#169] by [mvz])
90
+ * Test with all supported Rails versions in CI ([#168] by [mvz])
91
+ * Use rake-manifest to generate the manifest ([#170] by [mvz])
92
+ * Prevent manifest task definition from being loaded in dependent projects
93
+ ([11727f5] by [mvz])
94
+ * Update RuboCop dependencies and configuration and fix new offenses ([#173] by [mvz])
95
+ * Clarify logic in `CommentsController#recaptcha_ok_for?` ([#174] by [mvz])
96
+ * Switch to weekly dependabot updates ([#188] by [mvz])
97
+ * Use new official name for `erb_lint` ([#190] by [mvz])
98
+ * Remove scheduled CI runs ([#204] by [mvz])
99
+ * Pull in changelog for version 10.0.3 ([#194] by [mvz])
100
+ * Remove obsolete `before_action` ([#196] by [mvz])
101
+ * Remove exceptions from `login_required` before_action ([#197] by [mvz])
102
+ * Refactor notes rendering ([#210] by [mvz])
103
+ * Remove any permissions from `GITHUB_TOKEN` in CI ([#253] by [mvz])
104
+ * Remove dummy application layout view ([#246] by [mvz])
105
+ * Make 'rails server' work with the dummy test app ([#216] by [mvz])
106
+ * Update rubocop dependencies and handle new offenses ([#223] by [mvz])
107
+ * Remove dependency on pry ([#165] by [mvz])
108
+ * Loosen development dependencies ([#266] by [mvz])
109
+
110
+ [#136]: https://github.com/publify/publify_core/pull/136
111
+ [#140]: https://github.com/publify/publify_core/pull/140
112
+ [#152]: https://github.com/publify/publify_core/pull/152
113
+ [#158]: https://github.com/publify/publify_core/pull/158
114
+ [#164]: https://github.com/publify/publify_core/pull/164
115
+ [#165]: https://github.com/publify/publify_core/pull/165
116
+ [#167]: https://github.com/publify/publify_core/pull/167
117
+ [#168]: https://github.com/publify/publify_core/pull/168
118
+ [#169]: https://github.com/publify/publify_core/pull/169
119
+ [#170]: https://github.com/publify/publify_core/pull/170
120
+ [#173]: https://github.com/publify/publify_core/pull/173
121
+ [#174]: https://github.com/publify/publify_core/pull/174
122
+ [#178]: https://github.com/publify/publify_core/pull/178
123
+ [#188]: https://github.com/publify/publify_core/pull/188
124
+ [#189]: https://github.com/publify/publify_core/pull/189
125
+ [#190]: https://github.com/publify/publify_core/pull/190
126
+ [#193]: https://github.com/publify/publify_core/pull/193
127
+ [#194]: https://github.com/publify/publify_core/pull/194
128
+ [#195]: https://github.com/publify/publify_core/pull/195
129
+ [#196]: https://github.com/publify/publify_core/pull/196
130
+ [#197]: https://github.com/publify/publify_core/pull/197
131
+ [#198]: https://github.com/publify/publify_core/pull/198
132
+ [#204]: https://github.com/publify/publify_core/pull/204
133
+ [#210]: https://github.com/publify/publify_core/pull/210
134
+ [#211]: https://github.com/publify/publify_core/pull/211
135
+ [#215]: https://github.com/publify/publify_core/pull/215
136
+ [#216]: https://github.com/publify/publify_core/pull/216
137
+ [#217]: https://github.com/publify/publify_core/pull/217
138
+ [#221]: https://github.com/publify/publify_core/pull/221
139
+ [#222]: https://github.com/publify/publify_core/pull/222
140
+ [#223]: https://github.com/publify/publify_core/pull/223
141
+ [#226]: https://github.com/publify/publify_core/pull/226
142
+ [#228]: https://github.com/publify/publify_core/pull/228
143
+ [#231]: https://github.com/publify/publify_core/pull/231
144
+ [#233]: https://github.com/publify/publify_core/pull/233
145
+ [#234]: https://github.com/publify/publify_core/pull/234
146
+ [#235]: https://github.com/publify/publify_core/pull/235
147
+ [#236]: https://github.com/publify/publify_core/pull/236
148
+ [#238]: https://github.com/publify/publify_core/pull/238
149
+ [#239]: https://github.com/publify/publify_core/pull/239
150
+ [#240]: https://github.com/publify/publify_core/pull/240
151
+ [#244]: https://github.com/publify/publify_core/pull/244
152
+ [#245]: https://github.com/publify/publify_core/pull/245
153
+ [#246]: https://github.com/publify/publify_core/pull/246
154
+ [#247]: https://github.com/publify/publify_core/pull/247
155
+ [#249]: https://github.com/publify/publify_core/pull/249
156
+ [#252]: https://github.com/publify/publify_core/pull/252
157
+ [#253]: https://github.com/publify/publify_core/pull/253
158
+ [#261]: https://github.com/publify/publify_core/pull/261
159
+ [#262]: https://github.com/publify/publify_core/pull/262
160
+ [#266]: https://github.com/publify/publify_core/pull/266
161
+ [#268]: https://github.com/publify/publify_core/pull/268
162
+
163
+ [11727f5]: https://github.com/publify/publify_core/commit/11727f5a2826ea351964c2367d36a979dfab212d
164
+
165
+ ## 10.0.4 / 2026-10-04
166
+
167
+ * Refuse attempts to upload a file detected as text with an html extension ([#267] by [mvz])
168
+
169
+ [#267]: https://github.com/publify/publify_core/pull/267
170
+
3
171
  ## 10.0.3 / 2025-03-28
4
172
 
5
173
  * Limit accepted parameters for Sidebar update in Admin ([#159] by [mvz])
@@ -78,60 +246,88 @@
78
246
 
79
247
  ### Breaking changes
80
248
 
81
- * Remove support for Textile as a text format [publify#1001](https://github.com/publify/publify/pull/1001)
249
+ * Remove support for Textile as a text format
250
+ [publify#1001](https://github.com/publify/publify/pull/1001)
82
251
 
83
252
  ### Other changes
84
253
 
85
254
  * Improve feedback listings [publify#1005](https://github.com/publify/publify/pull/1005)
86
- * Link to article from article feedback admin page [publify#1007](https://github.com/publify/publify/pull/1007)
255
+ * Link to article from article feedback admin page
256
+ [publify#1007](https://github.com/publify/publify/pull/1007)
87
257
  * Link to blog from admin menu [publify#1008](https://github.com/publify/publify/pull/1008)
88
- * Handle markdown links in notes correctly [publify#1009](https://github.com/publify/publify/pull/1009)
89
- * Make notes twitterfilter robust [publify#1010](https://github.com/publify/publify/pull/1010)
258
+ * Handle markdown links in notes correctly
259
+ [publify#1009](https://github.com/publify/publify/pull/1009)
260
+ * Make notes twitterfilter robust
261
+ [publify#1010](https://github.com/publify/publify/pull/1010)
90
262
  * Miscellaneous admin fixes [publify#1012](https://github.com/publify/publify/pull/1012)
91
- * Add arabic language to the project [publify#1060](https://github.com/publify/publify/pull/1060) by [ahmedhamid13](https://github.com/ahmedhamid13)
263
+ * Add arabic language to the project
264
+ [publify#1060](https://github.com/publify/publify/pull/1060) by [ahmedhamid13](https://github.com/ahmedhamid13)
92
265
 
93
266
  ### Internal changes
94
267
 
95
268
  * Remove use of 'notextile' [publify#1002](https://github.com/publify/publify/pull/1002)
96
- * Remove `TextFilter.filter_text` in favor of `#filter_text` [publify#1003](https://github.com/publify/publify/pull/1003)
97
- * Replace BlueCloth with CommonMarker for Markdown processing [publify#810](https://github.com/publify/publify/pull/810)
98
- * Rename Admin::ContentController to Admin::ArticlesController [publify#1004](https://github.com/publify/publify/pull/1004)
99
- * Remove unneeded wrapping elements from admin layout [publify#1006](https://github.com/publify/publify/pull/1006)
100
- * Split the factories into individual files [publify#1031](https://github.com/publify/publify/pull/1031) by [VictorPS](https://github.com/VictorPS)
101
- * Ensure `auto_link` helper is loaded on time [publify#1040](https://github.com/publify/publify/pull/1040)
102
- * Remove `sitealizer` table [publify#1089](https://github.com/publify/publify/pull/1089) by [SupriyaMedankar](https://github.com/SupriyaMedankar)
103
- * Remove itunes fields from resources [publify#1092](https://github.com/publify/publify/pull/1092) by [SupriyaMedankar](https://github.com/SupriyaMedankar)
104
- * Remove `page_caches` table [publify#1090](https://github.com/publify/publify/pull/1090) by [SupriyaMedankar](https://github.com/SupriyaMedankar)
105
- * Remove obsolete Sidebar code [publify_core#58](https://github.com/publify/publify_core/pull/58)
269
+ * Remove `TextFilter.filter_text` in favor of `#filter_text`
270
+ [publify#1003](https://github.com/publify/publify/pull/1003)
271
+ * Replace BlueCloth with CommonMarker for Markdown processing
272
+ [publify#810](https://github.com/publify/publify/pull/810)
273
+ * Rename Admin::ContentController to Admin::ArticlesController
274
+ [publify#1004](https://github.com/publify/publify/pull/1004)
275
+ * Remove unneeded wrapping elements from admin layout
276
+ [publify#1006](https://github.com/publify/publify/pull/1006)
277
+ * Split the factories into individual files
278
+ [publify#1031](https://github.com/publify/publify/pull/1031) by [VictorPS](https://github.com/VictorPS)
279
+ * Ensure `auto_link` helper is loaded on time
280
+ [publify#1040](https://github.com/publify/publify/pull/1040)
281
+ * Remove `sitealizer` table
282
+ [publify#1089](https://github.com/publify/publify/pull/1089) by [SupriyaMedankar](https://github.com/SupriyaMedankar)
283
+ * Remove itunes fields from resources
284
+ [publify#1092](https://github.com/publify/publify/pull/1092) by [SupriyaMedankar](https://github.com/SupriyaMedankar)
285
+ * Remove `page_caches` table
286
+ [publify#1090](https://github.com/publify/publify/pull/1090) by [SupriyaMedankar](https://github.com/SupriyaMedankar)
287
+ * Remove obsolete Sidebar code
288
+ [publify_core#58](https://github.com/publify/publify_core/pull/58)
106
289
 
107
290
  ## 9.2.10 / 2023-01-08
108
291
 
109
292
  * Bump Rails version to 5.2.8.1 [publify#1070](https://github.com/publify/publify/pull/1070)
110
- * Limit length of settings values [publify#1072](https://github.com/publify/publify/pull/1072)
111
- * Require login to stay unique when updating a User [publify#1073](https://github.com/publify/publify/pull/1073)
112
- * Validate lengths of string attributes [publify#1077](https://github.com/publify/publify/pull/1077)
113
- * Strip EXIF data from resource uploads [publify#1078](https://github.com/publify/publify/pull/1078)
114
- * Require user passwords to be strong [publify#1086](https://github.com/publify/publify/pull/1086)
293
+ * Limit length of settings values
294
+ [publify#1072](https://github.com/publify/publify/pull/1072)
295
+ * Require login to stay unique when updating a User
296
+ [publify#1073](https://github.com/publify/publify/pull/1073)
297
+ * Validate lengths of string attributes
298
+ [publify#1077](https://github.com/publify/publify/pull/1077)
299
+ * Strip EXIF data from resource uploads
300
+ [publify#1078](https://github.com/publify/publify/pull/1078)
301
+ * Require user passwords to be strong
302
+ [publify#1086](https://github.com/publify/publify/pull/1086)
115
303
 
116
304
  ## 9.2.9 / 2022-05-22
117
305
 
118
- * Fix admin article access control [publify#1065](https://github.com/publify/publify/pull/1065)
119
- * Refuse html files as resources even if declared to be plain text [publify#1066](https://github.com/publify/publify/pull/1066)
306
+ * Fix admin article access control
307
+ [publify#1065](https://github.com/publify/publify/pull/1065)
308
+ * Refuse html files as resources even if declared to be plain text
309
+ [publify#1066](https://github.com/publify/publify/pull/1066)
120
310
 
121
311
  ## 9.2.8 / 2022-05-14
122
312
 
123
- * Fix password protected article reveal [publify#1049](https://github.com/publify/publify/pull/1049)
124
- * Disallow comments on draft articles [publify#1048](https://github.com/publify/publify/pull/1048)
313
+ * Fix password protected article reveal
314
+ [publify#1049](https://github.com/publify/publify/pull/1049)
315
+ * Disallow comments on draft articles
316
+ [publify#1048](https://github.com/publify/publify/pull/1048)
125
317
  * Clean up Feedback validation [publify#1051](https://github.com/publify/publify/pull/1051)
126
318
  * Disallow images in comments [publify#1054](https://github.com/publify/publify/pull/1054)
127
319
  * Fix password reset process [publify#1055](https://github.com/publify/publify/pull/1055)
128
- * Hide bodies of password-protected articles in search results [publify#1057](https://github.com/publify/publify/pull/1057)
129
- * Provide correct `article_id` input in bulkops form [publify#1058](https://github.com/publify/publify/pull/1058)
130
- * Do not create article meta description for password-protected articles [publify#1061](https://github.com/publify/publify/pull/1061)
320
+ * Hide bodies of password-protected articles in search results
321
+ [publify#1057](https://github.com/publify/publify/pull/1057)
322
+ * Provide correct `article_id` input in bulkops form
323
+ [publify#1058](https://github.com/publify/publify/pull/1058)
324
+ * Do not create article meta description for password-protected articles
325
+ [publify#1061](https://github.com/publify/publify/pull/1061)
131
326
 
132
327
  ## 9.2.7 / 2022-02-07
133
328
 
134
- * Fix setting the article password from the Admin [publify#1044](https://github.com/publify/publify/pull/1044)
329
+ * Fix setting the article password from the Admin
330
+ [publify#1044](https://github.com/publify/publify/pull/1044)
135
331
 
136
332
  ## 9.2.6 / 2022-01-07
137
333
 
@@ -226,41 +422,41 @@ Additionally, it includes the following changes:
226
422
  * Let first-run users pick their own password instead of generating one (mvz)
227
423
 
228
424
  * Dependencies
229
- - Update dependencies (mvz)
230
- - Drop support for Ruby 2.1 (mvz)
425
+ * Update dependencies (mvz)
426
+ * Drop support for Ruby 2.1 (mvz)
231
427
 
232
428
  * Removing of old/outdated functionality
233
- - Remove support for feedburner (mvz)
234
- - Drop old redirects (mvz)
235
- - Remove RSD end point (mvz)
429
+ * Remove support for feedburner (mvz)
430
+ * Drop old redirects (mvz)
431
+ * Remove RSD end point (mvz)
236
432
 
237
433
  * Feedback
238
- - Stop sending trackbacks and pingbacks (mvz)
239
- - Stop accepting trackbacks (mvz)
434
+ * Stop sending trackbacks and pingbacks (mvz)
435
+ * Stop accepting trackbacks (mvz)
240
436
 
241
437
  * Improve Atom/RSS feeds
242
- - Fix URLs used for resources (mvz)
243
- - Fix URL/alternate links to not just point to the site root (mvz)
244
- - Unify comment and trackback feeds into feedback feed (mvz)
245
- - Add caching for feeds (mvz)
246
- - Fix atom entry publication date (mvz)
247
- - Fix ordering of feedback feed by using created_at (mvz)
438
+ * Fix URLs used for resources (mvz)
439
+ * Fix URL/alternate links to not just point to the site root (mvz)
440
+ * Unify comment and trackback feeds into feedback feed (mvz)
441
+ * Add caching for feeds (mvz)
442
+ * Fix atom entry publication date (mvz)
443
+ * Fix ordering of feedback feed by using created_at (mvz)
248
444
 
249
445
  * Bug fixes
250
- - Fix user resource image display when using Fog (mvz)
251
- - Fix sending of welcome email (mvz)
252
- - Fix Tag page description (mvz)
253
- - Handle setting published_at to blank (mvz)
254
- - Handle preview of articles without publication date (mvz)
255
- - Include CSRF meta tag so remote forms work (mvz)
256
- - Fix sidebar field rendering in admin (mvz)
257
- - Fix formatting of settings forms in admin (mvz)
446
+ * Fix user resource image display when using Fog (mvz)
447
+ * Fix sending of welcome email (mvz)
448
+ * Fix Tag page description (mvz)
449
+ * Handle setting published_at to blank (mvz)
450
+ * Handle preview of articles without publication date (mvz)
451
+ * Include CSRF meta tag so remote forms work (mvz)
452
+ * Fix sidebar field rendering in admin (mvz)
453
+ * Fix formatting of settings forms in admin (mvz)
258
454
 
259
455
  * Code improvements
260
- - Performance improvements (mvz)
261
- - Improve tags controller (mvz)
262
- - Clean up archives and authors page code (mvz)
263
- - Unify content models more to improve performance when mixing models (mvz)
456
+ * Performance improvements (mvz)
457
+ * Improve tags controller (mvz)
458
+ * Clean up archives and authors page code (mvz)
459
+ * Unify content models more to improve performance when mixing models (mvz)
264
460
 
265
461
  ## 9.0.0.pre6 / 2016-12-23
266
462
 
@@ -5,7 +5,6 @@
5
5
  //= require rails-timeago-all
6
6
  //= require set-timeago-lang
7
7
  //= require jquery_ujs
8
- //= require lightbox
9
8
  //= require markup_help_popup
10
9
  //= require observe
11
10
  //= require optional_field_toggle
@@ -3,13 +3,13 @@
3
3
  //= require jquery
4
4
  //= require jquery_ujs
5
5
  //= require jquery-ui
6
+ //= require popper
6
7
  //= require bootstrap-sprockets
7
8
  //= require quicktags
8
9
  //= require tagmanager
9
10
  //= require typeahead
10
11
  //= require sidebar
11
12
  //= require spinnable
12
- //= require lightbox
13
13
  //
14
14
  //= require_self
15
15
 
@@ -69,12 +69,13 @@ $(document).ready(function() {
69
69
  $('#article_form').each(function(e){tag_manager()});
70
70
  $('#checkall').click(function(e){check_all(e.target)});
71
71
 
72
- // DropDown
73
- $(".dropdown-toggle").dropdown();
72
+ const lightboxModal = document.getElementById('image-lightbox-modal');
73
+ if (lightboxModal) {
74
+ lightboxModal.addEventListener('show.bs.modal', event => {
75
+ const triggerElem = event.relatedTarget;
76
+ const imageUrl = triggerElem.getAttribute('data-bs-imageurl');
77
+ const imageElem = lightboxModal.querySelector('.modal-body img')
78
+ imageElem.src = imageUrl;
79
+ })
80
+ }
74
81
  });
75
-
76
- $(document).delegate('*[data-toggle="lightbox"]', 'click',
77
- function(event) {
78
- event.preventDefault();
79
- $(this).ekkoLightbox();
80
- });
@@ -1,5 +1,3 @@
1
- // "bootstrap-sprockets" must be imported before "bootstrap" and "bootstrap/variables"
2
- @import "bootstrap-sprockets";
3
1
  @import "bootstrap";
4
2
 
5
3
  body {
@@ -58,10 +58,6 @@ tr .action {
58
58
  .page-title { display:inline-block }
59
59
  /* Classes for menu icons */
60
60
 
61
- .btn-action {
62
- padding: 4px;
63
- }
64
-
65
61
  #article_title,
66
62
  #page_title {
67
63
  font-size: 2.3em;
@@ -1,6 +1,5 @@
1
1
  /*
2
2
  *= require coderay
3
- *= require lightbox
4
3
  */
5
4
 
6
5
  .statuses_sidebar {
@@ -4,6 +4,4 @@
4
4
  *= require tagmanager
5
5
  *= require sidebar_admin
6
6
  */
7
- // "bootstrap-sprockets" must be imported before "bootstrap" and "bootstrap/variables"
8
- @import "bootstrap-sprockets";
9
7
  @import "bootstrap";
@@ -27,10 +27,4 @@
27
27
  h3 {
28
28
  margin-top: 0;
29
29
  }
30
- .deletion_link {
31
- position: absolute;
32
- top: 20px;
33
- right: 20px;
34
- display: inline-block;
35
- }
36
30
  }
@@ -116,7 +116,7 @@ class Admin::ArticlesController < Admin::BaseController
116
116
  @article.text_filter_name ||= default_text_filter
117
117
 
118
118
  if @article.title.blank?
119
- lastid = Article.order("id desc").first.id
119
+ lastid = Article.order(id: :desc).first.id
120
120
  @article.title = "Draft article #{lastid}"
121
121
  end
122
122
 
@@ -9,7 +9,7 @@ class Admin::BaseController < BaseController
9
9
  @@look_for_migrations = true
10
10
  layout "administration"
11
11
 
12
- before_action :login_required, except: [:login, :signup]
12
+ before_action :login_required
13
13
  before_action :no_caching
14
14
 
15
15
  private
@@ -18,7 +18,7 @@ class Admin::BaseController < BaseController
18
18
  @record = klass_to_destroy.find(params[:id])
19
19
  if @record.respond_to?(:access_by?) && !@record.access_by?(current_user)
20
20
  flash[:error] = I18n.t("admin.base.not_allowed")
21
- return(redirect_to action: "index")
21
+ return redirect_to action: "index"
22
22
  end
23
23
  @record.destroy
24
24
  flash[:notice] = I18n.t("admin.base.successfully_deleted",
@@ -4,13 +4,13 @@ class Admin::RedirectsController < Admin::BaseController
4
4
  before_action :set_redirect, only: [:edit, :update, :destroy]
5
5
 
6
6
  def index
7
- @redirects = Redirect.where(content_id: nil).order("id desc").page(params[:page])
7
+ @redirects = Redirect.where(content_id: nil).order(id: :desc).page(params[:page])
8
8
  .per(this_blog.admin_display_elements)
9
9
  @redirect = Redirect.new
10
10
  end
11
11
 
12
12
  def edit
13
- @redirects = Redirect.where(content_id: nil).order("id desc").page(params[:page])
13
+ @redirects = Redirect.where(content_id: nil).order(id: :desc).page(params[:page])
14
14
  .per(this_blog.admin_display_elements)
15
15
  end
16
16
 
@@ -18,7 +18,7 @@ class Admin::ResourcesController < Admin::BaseController
18
18
 
19
19
  def index
20
20
  @r = Resource.new
21
- @resources = Resource.order("created_at DESC").page(params[:page])
21
+ @resources = Resource.order(created_at: :desc).page(params[:page])
22
22
  .per(this_blog.admin_display_elements)
23
23
  end
24
24
 
@@ -4,6 +4,8 @@ class Admin::SeoController < Admin::BaseController
4
4
  before_action :set_setting
5
5
  before_action :set_section
6
6
 
7
+ VALID_SECTIONS = %w(general titles permalinks).freeze
8
+
7
9
  def show
8
10
  if @setting.permalink_format != "/%year%/%month%/%day%/%title%" &&
9
11
  @setting.permalink_format != "/%year%/%month%/%title%" &&
@@ -37,8 +39,6 @@ class Admin::SeoController < Admin::BaseController
37
39
  @setting.settings_keys + [:custom_permalink]
38
40
  end
39
41
 
40
- VALID_SECTIONS = %w(general titles permalinks).freeze
41
-
42
42
  def set_section
43
43
  section = params[:section]
44
44
  @section = VALID_SECTIONS.include?(section) ? section : "general"
@@ -1,6 +1,8 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class Admin::SettingsController < Admin::BaseController
4
+ VALID_ACTIONS = %w(index write feedback display).freeze
5
+
4
6
  def index
5
7
  this_blog.base_url = blog_base_url if this_blog.base_url.blank?
6
8
  load_settings
@@ -33,8 +35,6 @@ class Admin::SettingsController < Admin::BaseController
33
35
 
34
36
  private
35
37
 
36
- VALID_ACTIONS = %w(index write feedback display).freeze
37
-
38
38
  def settings_params
39
39
  @settings_params ||= params.require(:setting).permit(@setting.settings_keys)
40
40
  end
@@ -51,7 +51,7 @@ class Admin::TagsController < Admin::BaseController
51
51
  end
52
52
 
53
53
  def fetch_tags
54
- @tags = Tag.order("display_name").page(params[:page])
54
+ @tags = Tag.order(:display_name).page(params[:page])
55
55
  .per(this_blog.admin_display_elements)
56
56
  end
57
57
  end
@@ -4,7 +4,7 @@ class Admin::UsersController < Admin::BaseController
4
4
  before_action :set_user, only: [:edit, :update, :destroy]
5
5
 
6
6
  def index
7
- @users = User.order("login asc").page(params[:page])
7
+ @users = User.order(:login).page(params[:page])
8
8
  .per(this_blog.admin_display_elements)
9
9
  end
10
10
 
@@ -38,7 +38,7 @@ class Admin::UsersController < Admin::BaseController
38
38
  end
39
39
 
40
40
  def destroy
41
- @user.destroy if User.where("profile = ? and id != ?", User::ADMIN, @user.id).count > 1
41
+ @user.destroy if User.where("profile = ? and id != ?", User::ADMIN, @user.id).many?
42
42
  redirect_to admin_users_url
43
43
  end
44
44
 
@@ -5,9 +5,6 @@ class ArticlesController < ContentController
5
5
 
6
6
  before_action :login_required, only: [:preview, :preview_page]
7
7
  before_action :verify_config
8
- before_action :auto_discovery_feed, only: [:show, :index]
9
-
10
- layout :theme_layout, except: [:trackback]
11
8
 
12
9
  helper :"admin/base"
13
10
 
@@ -98,7 +95,7 @@ class ArticlesController < ContentController
98
95
  r = Redirect.find_by!(from_path: from)
99
96
  # TODO: If linked to article, directly redirect to the article.
100
97
  # Let redirection made outside of the blog on purpose (deal with it, Brakeman!)
101
- redirect_to r.full_to_path, status: :moved_permanently if r
98
+ redirect_to r.full_to_path, allow_other_host: true, status: :moved_permanently if r
102
99
  end
103
100
 
104
101
  def archives
@@ -154,7 +151,7 @@ class ArticlesController < ContentController
154
151
  def verify_config
155
152
  if !this_blog.configured?
156
153
  redirect_to controller: "setup", action: "index"
157
- elsif User.count == 0
154
+ elsif User.none?
158
155
  redirect_to new_user_registration_path
159
156
  else
160
157
  true
@@ -1,8 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class AuthorsController < ContentController
4
- layout :theme_layout
5
-
6
4
  def show
7
5
  @author = User.find_by(login: params[:id])
8
6
  raise ActiveRecord::RecordNotFound unless @author
@@ -31,8 +31,11 @@ class CommentsController < BaseController
31
31
  private
32
32
 
33
33
  def recaptcha_ok_for?(comment)
34
- use_recaptcha = comment.blog.use_recaptcha
35
- (use_recaptcha && verify_recaptcha(model: comment)) || !use_recaptcha
34
+ if comment.blog.use_recaptcha
35
+ verify_recaptcha(model: comment)
36
+ else
37
+ true
38
+ end
36
39
  end
37
40
 
38
41
  def new_comment_defaults