alchemy_cms 8.2.8 → 8.2.9

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 15844e64546633908fff8dba970ab929e40d6044a0be2a7cced0c8597dff7fe1
4
- data.tar.gz: 4801714707a3773127714d3dcc5058a4a54f9d30567a50685a0088d2a528d3c9
3
+ metadata.gz: 46f26bda82a9bdca30c217a8652427693c1db6285c123fa28ffc158705713fa4
4
+ data.tar.gz: 91d8ba88681532ff23d6fe3a28b89fe5492384b9bb163d1d10f204a0a6e6a510
5
5
  SHA512:
6
- metadata.gz: 0e773361f910a147d5f3430e07d28d53b2797d4838bc8a9710305a8c7ae6358cd6c5f9de14503118f3003a34cd36decb2ed20e3e50cb227ce460925e2ce75c28
7
- data.tar.gz: be3a4416c757c31a384c3e3c9e6cce73002811963c0267160ae4ab063ec42d328004be12f342cec1db1122236fb393e63aeab13155dd5d044f8ff7aa92821b4d
6
+ metadata.gz: 5099b8d902af668ddabc3ae982a3d87ee33d9a18a2296e048f5c09189575f933f6d02bdc1baaa3c53e944b6ffcca56f5fbad89d70a87db161ac94d5918698d5d
7
+ data.tar.gz: ebe759bb002879896538b680b8b807873ffca292b95e4637402a1500337d3629f4c1318f2ce040809fed8c7d13bc6294fca41ac23bf2b1d8538c602873271da8
@@ -16,7 +16,7 @@ module Alchemy
16
16
  end
17
17
 
18
18
  def call
19
- value.html_safe
19
+ h(value)
20
20
  end
21
21
 
22
22
  def render?
@@ -68,7 +68,7 @@ module Alchemy
68
68
  def caption
69
69
  return unless show_caption?
70
70
 
71
- @_caption ||= content_tag(:figcaption, ingredient.caption.html_safe)
71
+ @_caption ||= content_tag(:figcaption, sanitize(ingredient.caption))
72
72
  end
73
73
 
74
74
  def src
@@ -18,7 +18,7 @@ module Alchemy
18
18
 
19
19
  def call
20
20
  if disable_link?
21
- dom_id.present? ? anchor : value
21
+ dom_id.present? ? anchor : h(value)
22
22
  else
23
23
  link_to(value, url_for(link), {
24
24
  id: dom_id.presence,
@@ -26,7 +26,7 @@ module Alchemy
26
26
  target: link_target_value(link_target),
27
27
  rel: link_rel_value(link_target)
28
28
  }.merge(html_options))
29
- end.html_safe
29
+ end
30
30
  end
31
31
 
32
32
  private
data/config/importmap.rb CHANGED
@@ -13,12 +13,18 @@ pin "@rails/ujs", to: "rails-ujs.min.js", preload: true # @7.1.2
13
13
  pin "tinymce", to: "tinymce.min.js", preload: true
14
14
 
15
15
  pin "alchemy_admin", to: "alchemy/alchemy_admin.min.js", preload: true
16
- pin "alchemy_admin/components/remote_select", to: "alchemy/alchemy_admin.min.js"
17
- pin "alchemy_admin/components/page_select", to: "alchemy/alchemy_admin.min.js"
18
- pin "alchemy_admin/components/attachment_select", to: "alchemy/alchemy_admin.min.js"
19
- pin "alchemy_admin/components/element_select", to: "alchemy/alchemy_admin.min.js"
20
- pin "alchemy_admin/components/tags_autocomplete", to: "alchemy/alchemy_admin.min.js"
21
- pin "alchemy_admin/components/tinymce", to: "alchemy/alchemy_admin.min.js"
16
+ # Individually importable admin components. These resolve to their source
17
+ # files (not the bundle) so host engines can import a single component without
18
+ # loading and executing the whole admin bundle. Not preloaded, so they add no
19
+ # fetches to normal admin page loads (which import the bundle instead).
20
+ pin "alchemy_admin/components/page_select"
21
+ pin "alchemy_admin/components/attachment_select"
22
+ pin "alchemy_admin/components/element_select"
23
+ pin "alchemy_admin/components/tags_autocomplete"
24
+ pin "alchemy_admin/components/tinymce"
25
+ pin "alchemy_admin/components/remote_select"
26
+ pin "alchemy_admin/components/select"
27
+ pin "alchemy_admin/i18n"
22
28
  pin "alchemy_admin/image_cropper", to: "alchemy/alchemy_admin.min.js"
23
29
  pin "alchemy_admin/image_overlay", to: "alchemy/alchemy_admin.min.js"
24
30
  pin "alchemy_admin/picture_selector", to: "alchemy/alchemy_admin.min.js"
@@ -0,0 +1,14 @@
1
+ class AddIndexToElementsPagesJoinTable < ActiveRecord::Migration[7.2]
2
+ disable_ddl_transaction! if connection.adapter_name.match?(/postgres/i)
3
+
4
+ def change
5
+ add_index :alchemy_elements_alchemy_pages, :element_id, if_not_exists: true, algorithm: algorithm
6
+ add_index :alchemy_elements_alchemy_pages, :page_id, if_not_exists: true, algorithm: algorithm
7
+ end
8
+
9
+ private
10
+
11
+ def algorithm
12
+ connection.adapter_name.match?(/postgres/i) ? :concurrently : nil
13
+ end
14
+ end
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Alchemy
4
- VERSION = "8.2.8"
4
+ VERSION = "8.2.9"
5
5
 
6
6
  def self.version
7
7
  VERSION
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: alchemy_cms
3
3
  version: !ruby/object:Gem::Version
4
- version: 8.2.8
4
+ version: 8.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas von Deyen
@@ -1285,6 +1285,7 @@ files:
1285
1285
  - db/migrate/20260102121232_add_metadata_to_page_versions.rb
1286
1286
  - db/migrate/20260115164704_add_publication_timestamps_to_alchemy_elements.rb
1287
1287
  - db/migrate/20260115164705_add_index_to_element_publication_timestamps.rb
1288
+ - db/migrate/20260702090038_add_index_to_elements_pages_join_table.rb
1288
1289
  - lib/alchemy.rb
1289
1290
  - lib/alchemy/ability_helper.rb
1290
1291
  - lib/alchemy/admin/locale.rb
@@ -1490,7 +1491,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
1490
1491
  version: '0'
1491
1492
  requirements:
1492
1493
  - ImageMagick (libmagick), v6.6 or greater.
1493
- rubygems_version: 4.0.10
1494
+ rubygems_version: 4.0.16
1494
1495
  specification_version: 4
1495
1496
  summary: A powerful, userfriendly and flexible CMS for Rails
1496
1497
  test_files: []