ckeditor5 1.33.2 → 1.34.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.
- checksums.yaml +4 -4
- data/README.md +10 -8
- data/lib/ckeditor5/rails/context/helpers.rb +6 -1
- data/lib/ckeditor5/rails/editor/helpers/editor_helpers.rb +13 -3
- data/lib/ckeditor5/rails/version.rb +2 -2
- data/npm_package/package.json +1 -1
- data/spec/lib/ckeditor5/rails/editor/helpers/editor_helpers_spec.rb +27 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: bbf5bf1d21459d7a2d6332d15e1dfc999a93140172c7688e9e50125671e52c7a
|
|
4
|
+
data.tar.gz: 556e87e3a5c9578172e9033f2e6bf1e53592c824e2873a00a4a3cf3c11b46dfa
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0fb356c3938f3dc1ba66164ab01180ee31215c4f4020eada3c735831e39d3c0dc8d9c826416dd858aa8aebf742d777405e6a4a784b53f2bff008d983261f5f0e
|
|
7
|
+
data.tar.gz: 5b7cec818f2d689d194499531b4f56f2fba8bc2f0b3d06118e700a5a309916bfdf3200999d9880775d2fcf0d2de242dec569929e668ea3f9472adddd7bfe6b4e
|
data/README.md
CHANGED
|
@@ -96,7 +96,7 @@ CKEditor5::Rails.configure do
|
|
|
96
96
|
|
|
97
97
|
# Optionally, you can specify version of CKEditor 5 to use.
|
|
98
98
|
# If it's not specified the default version specified in the gem will be used.
|
|
99
|
-
# version '47.
|
|
99
|
+
# version '47.3.0'
|
|
100
100
|
|
|
101
101
|
# Upload images to the server using the simple upload adapter, instead of Base64 encoding.
|
|
102
102
|
# simple_upload_adapter
|
|
@@ -223,7 +223,7 @@ You can create your own by defining it in the `config/initializers/ckeditor5.rb`
|
|
|
223
223
|
|
|
224
224
|
CKEditor5::Rails.configure do
|
|
225
225
|
# It's possible to override the default preset right in the initializer.
|
|
226
|
-
version '47.
|
|
226
|
+
version '47.3.0'
|
|
227
227
|
|
|
228
228
|
# New presets inherit properties from the default preset defined in the initializer.
|
|
229
229
|
# In this example, the custom preset inherits everything from default but disables the menubar:
|
|
@@ -233,7 +233,7 @@ CKEditor5::Rails.configure do
|
|
|
233
233
|
|
|
234
234
|
# In order to define preset from scratch, you can use the `inherit: false` option.
|
|
235
235
|
presets.define :blank_preset, inherit: false do
|
|
236
|
-
version '47.
|
|
236
|
+
version '47.3.0'
|
|
237
237
|
|
|
238
238
|
# It tells the integration to fetch the newest security patches and bug fixes.
|
|
239
239
|
# It may be disabled, but it's highly recommended to keep it enabled to avoid
|
|
@@ -355,7 +355,7 @@ Defines the version of CKEditor 5 to be used. The example below shows how to set
|
|
|
355
355
|
CKEditor5::Rails.configure do
|
|
356
356
|
# ... other configuration
|
|
357
357
|
|
|
358
|
-
version '47.
|
|
358
|
+
version '47.3.0'
|
|
359
359
|
end
|
|
360
360
|
```
|
|
361
361
|
|
|
@@ -367,7 +367,7 @@ In order to disable default patches, you can pass the `apply_patches: false` key
|
|
|
367
367
|
CKEditor5::Rails.configure do
|
|
368
368
|
# ... other configuration
|
|
369
369
|
|
|
370
|
-
version '47.
|
|
370
|
+
version '47.3.0', apply_patches: false
|
|
371
371
|
end
|
|
372
372
|
```
|
|
373
373
|
|
|
@@ -1347,7 +1347,7 @@ It may be useful when you want to define a preset based on the current user or r
|
|
|
1347
1347
|
class ApplicationController < ActionController::Base
|
|
1348
1348
|
def show
|
|
1349
1349
|
@preset = ckeditor5_preset do
|
|
1350
|
-
version '47.
|
|
1350
|
+
version '47.3.0'
|
|
1351
1351
|
|
|
1352
1352
|
toolbar :sourceEditing, :|, :bold, :italic, :underline, :strikethrough,
|
|
1353
1353
|
:subscript, :superscript, :removeFormat, :|, :bulletedList, :numberedList,
|
|
@@ -1382,7 +1382,7 @@ If you want to override the preset defined in the initializer, you can search fo
|
|
|
1382
1382
|
class ApplicationController < ActionController::Base
|
|
1383
1383
|
def show
|
|
1384
1384
|
@preset = ckeditor5_preset(:default).override do
|
|
1385
|
-
version '47.
|
|
1385
|
+
version '47.3.0'
|
|
1386
1386
|
|
|
1387
1387
|
toolbar :sourceEditing, :|, :bold, :italic, :underline, :strikethrough,
|
|
1388
1388
|
:subscript, :superscript, :removeFormat, :|, :bulletedList, :numberedList,
|
|
@@ -1555,7 +1555,7 @@ In that scenario it's recommended to add `gpl` method to the initializer along w
|
|
|
1555
1555
|
|
|
1556
1556
|
CKEditor5::Rails.configure do
|
|
1557
1557
|
gpl
|
|
1558
|
-
version '47.
|
|
1558
|
+
version '47.3.0'
|
|
1559
1559
|
end
|
|
1560
1560
|
```
|
|
1561
1561
|
|
|
@@ -2374,6 +2374,8 @@ If you're looking for similar stuff, check these out:
|
|
|
2374
2374
|
* [ckeditor5-livewire](https://github.com/Mati365/ckeditor5-livewire)
|
|
2375
2375
|
Drop-in CKEditor 5 solution for Laravel + Livewire apps. Works great with Blade forms too. Includes JS hooks, flexible config, and easy customization.
|
|
2376
2376
|
|
|
2377
|
+
* [ckeditor5-symfony](https://github.com/Mati365/ckeditor5-symfony)
|
|
2378
|
+
Native CKEditor 5 integration for Symfony. Works with Symfony 6.x+, standard forms and Twig. Supports custom builds, multiple editor configurations, asset management, and localization. Designed to be simple, predictable, and framework-native.
|
|
2377
2379
|
|
|
2378
2380
|
## Trademarks 📜
|
|
2379
2381
|
|
|
@@ -31,7 +31,12 @@ module CKEditor5::Rails::Context
|
|
|
31
31
|
|
|
32
32
|
tags = []
|
|
33
33
|
tags << ckeditor5_inline_plugins_tags(preset)
|
|
34
|
-
tags << tag.public_send(
|
|
34
|
+
tags << tag.public_send(
|
|
35
|
+
:'ckeditor-context-component',
|
|
36
|
+
'data-turbo-temporary': true,
|
|
37
|
+
**context_props.to_attributes,
|
|
38
|
+
&block
|
|
39
|
+
)
|
|
35
40
|
|
|
36
41
|
safe_join(tags)
|
|
37
42
|
end
|
|
@@ -85,7 +85,7 @@ module CKEditor5::Rails
|
|
|
85
85
|
|
|
86
86
|
tag_attributes = html_attributes.merge(editor_props.to_attributes)
|
|
87
87
|
|
|
88
|
-
tag.public_send(:'ckeditor-component', **tag_attributes, &block)
|
|
88
|
+
tag.public_send(:'ckeditor-component', 'data-turbo-temporary': true, **tag_attributes, &block)
|
|
89
89
|
end
|
|
90
90
|
|
|
91
91
|
# Creates an editable area for multiroot or decoupled editors.
|
|
@@ -96,7 +96,12 @@ module CKEditor5::Rails
|
|
|
96
96
|
# @example Creating a named editable area in multiroot editor
|
|
97
97
|
# <%= ckeditor5_editable 'content', style: 'border: 1px solid gray' %>
|
|
98
98
|
def ckeditor5_editable(name = nil, **kwargs, &block)
|
|
99
|
-
tag.public_send(
|
|
99
|
+
tag.public_send(
|
|
100
|
+
:'ckeditor-editable-component',
|
|
101
|
+
'data-turbo-temporary': true,
|
|
102
|
+
name: name,
|
|
103
|
+
**kwargs, &block
|
|
104
|
+
)
|
|
100
105
|
end
|
|
101
106
|
|
|
102
107
|
# Creates a UI part component for the editor (toolbar, menubar).
|
|
@@ -107,7 +112,12 @@ module CKEditor5::Rails
|
|
|
107
112
|
# @example Creating a toolbar component
|
|
108
113
|
# <%= ckeditor5_ui_part 'toolbar' %>
|
|
109
114
|
def ckeditor5_ui_part(name, **kwargs, &block)
|
|
110
|
-
tag.public_send(
|
|
115
|
+
tag.public_send(
|
|
116
|
+
:'ckeditor-ui-part-component',
|
|
117
|
+
'data-turbo-temporary': true,
|
|
118
|
+
name: name,
|
|
119
|
+
**kwargs, &block
|
|
120
|
+
)
|
|
111
121
|
end
|
|
112
122
|
|
|
113
123
|
# Creates a toolbar component for decoupled editor.
|
data/npm_package/package.json
CHANGED
|
@@ -238,6 +238,13 @@ RSpec.describe CKEditor5::Rails::Editor::Helpers::Editor do
|
|
|
238
238
|
expect(result).to include('preset-license-key')
|
|
239
239
|
end
|
|
240
240
|
end
|
|
241
|
+
|
|
242
|
+
context 'turbo temporary attribute' do
|
|
243
|
+
it 'includes data-turbo-temporary attribute in the editor component' do
|
|
244
|
+
result = helper.ckeditor5_editor
|
|
245
|
+
expect(result).to include('data-turbo-temporary="true"')
|
|
246
|
+
end
|
|
247
|
+
end
|
|
241
248
|
end
|
|
242
249
|
|
|
243
250
|
describe '#ckeditor5_editable' do
|
|
@@ -247,6 +254,11 @@ RSpec.describe CKEditor5::Rails::Editor::Helpers::Editor do
|
|
|
247
254
|
with: { name: 'content' }
|
|
248
255
|
)
|
|
249
256
|
end
|
|
257
|
+
|
|
258
|
+
it 'includes data-turbo-temporary attribute in the editable component' do
|
|
259
|
+
result = helper.ckeditor5_editable('content')
|
|
260
|
+
expect(result).to include('data-turbo-temporary="true"')
|
|
261
|
+
end
|
|
250
262
|
end
|
|
251
263
|
|
|
252
264
|
describe '#ckeditor5_ui_part' do
|
|
@@ -256,6 +268,11 @@ RSpec.describe CKEditor5::Rails::Editor::Helpers::Editor do
|
|
|
256
268
|
with: { name: 'toolbar' }
|
|
257
269
|
)
|
|
258
270
|
end
|
|
271
|
+
|
|
272
|
+
it 'includes data-turbo-temporary attribute in the ui part component' do
|
|
273
|
+
result = helper.ckeditor5_ui_part('toolbar')
|
|
274
|
+
expect(result).to include('data-turbo-temporary="true"')
|
|
275
|
+
end
|
|
259
276
|
end
|
|
260
277
|
|
|
261
278
|
describe '#ckeditor5_toolbar' do
|
|
@@ -265,6 +282,11 @@ RSpec.describe CKEditor5::Rails::Editor::Helpers::Editor do
|
|
|
265
282
|
with: { name: 'toolbar' }
|
|
266
283
|
)
|
|
267
284
|
end
|
|
285
|
+
|
|
286
|
+
it 'includes data-turbo-temporary attribute in the toolbar component' do
|
|
287
|
+
result = helper.ckeditor5_toolbar
|
|
288
|
+
expect(result).to include('data-turbo-temporary="true"')
|
|
289
|
+
end
|
|
268
290
|
end
|
|
269
291
|
|
|
270
292
|
describe '#ckeditor5_menubar' do
|
|
@@ -274,5 +296,10 @@ RSpec.describe CKEditor5::Rails::Editor::Helpers::Editor do
|
|
|
274
296
|
with: { name: 'menuBarView' }
|
|
275
297
|
)
|
|
276
298
|
end
|
|
299
|
+
|
|
300
|
+
it 'includes data-turbo-temporary attribute in the menubar component' do
|
|
301
|
+
result = helper.ckeditor5_menubar
|
|
302
|
+
expect(result).to include('data-turbo-temporary="true"')
|
|
303
|
+
end
|
|
277
304
|
end
|
|
278
305
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ckeditor5
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.34.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Mateusz Bagiński
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date:
|
|
12
|
+
date: 2026-01-05 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: rails
|