activeadmin_quill_editor 0.3.0 → 1.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a4c64ad878e1367dbc40efb644f4372e3cc85e726a2dafa9e602f16311f59ba3
4
- data.tar.gz: c35421055ae083865000d9c02525e715f2a273502c60e026796233a686fce96f
3
+ metadata.gz: e375a2fb59c984b11edb01fcd2fe96105f6d4ed7799265ab7807f0643128e364
4
+ data.tar.gz: 8d66f041b8f72232f9ac9f71f4d26062c77770249f03a1b3603d8f8426f99fdf
5
5
  SHA512:
6
- metadata.gz: ae07acc5c4c31c1d67b7f53056b571c3daaad81d29793cb7a3cb79ae05cc2a8686cced1a899df4e204f9d18b4336d6e324d7daff2490bbe56b9696a7d8508b9a
7
- data.tar.gz: a46ca361536d05ba54166df559448230c3283a3a9477ead220aece61cc54d6341d3af28fb7e01ac6fbf650e080721f7ca1c2096f78fb650da8d09411f52cb257
6
+ metadata.gz: a1efd9801f1b6cd50fefdbdc8f9dda6107fad108b72707be9d893d67e473c85c3012be31f7c54e7b603d3e0da8bce394165c24433b195fa9edd90d861375e6ab
7
+ data.tar.gz: 333d51a8e177b7243ed71e6765d6c4031c5c076616dbd996fb604625656d799aabb21e32c3c890a483b14e0783414707cff23ddc80e4c275c655bcd123da5339
data/LICENSE.txt CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2017-2020 Mattia Roccoberton
1
+ Copyright (c) 2017-2022 Mattia Roccoberton
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -1,14 +1,23 @@
1
- # ActiveAdmin Quill Editor [![Gem Version](https://badge.fury.io/rb/activeadmin_quill_editor.svg)](https://badge.fury.io/rb/activeadmin_quill_editor) [![CircleCI](https://circleci.com/gh/blocknotes/activeadmin_quill_editor.svg?style=svg)](https://circleci.com/gh/blocknotes/activeadmin_quill_editor)
1
+ # ActiveAdmin Quill Editor
2
+ [![gem version](https://badge.fury.io/rb/activeadmin_quill_editor.svg)](https://badge.fury.io/rb/activeadmin_quill_editor)
3
+ [![gem downloads](https://badgen.net/rubygems/dt/activeadmin_quill_editor)](https://rubygems.org/gems/activeadmin_quill_editor)
4
+ [![linters](https://github.com/blocknotes/activeadmin_quill_editor/actions/workflows/linters.yml/badge.svg)](https://github.com/blocknotes/activeadmin_quill_editor/actions/workflows/linters.yml)
5
+ [![specs Rails 6.1](https://github.com/blocknotes/activeadmin_quill_editor/actions/workflows/specs_rails61.yml/badge.svg)](https://github.com/blocknotes/activeadmin_quill_editor/actions/workflows/specs_rails61.yml)
6
+ [![specs Rails 7.0](https://github.com/blocknotes/activeadmin_quill_editor/actions/workflows/specs_rails70.yml/badge.svg)](https://github.com/blocknotes/activeadmin_quill_editor/actions/workflows/specs_rails70.yml)
2
7
 
3
8
  An Active Admin plugin to use [Quill Rich Text Editor](https://github.com/quilljs/quill) in form fields.
4
9
 
5
- ![screenshot](screenshot.png)
10
+ ![screenshot](extra/screenshot.png)
11
+
12
+ Please :star: if you like it.
6
13
 
7
14
  ## Install
15
+
8
16
  After installing Active Admin, add to your Gemfile: `gem 'activeadmin_quill_editor'` (and execute *bundle*)
9
17
 
10
18
  If you installed Active Admin without Webpacker support (default for now):
11
19
 
20
+ - Add a SASS/SCSS gem to your Gemfile (ex. `gem 'sassc'`)
12
21
  - Add at the end of your Active Admin styles (_app/assets/stylesheets/active_admin.scss_):
13
22
  ```scss
14
23
  @import 'activeadmin/quill_editor/quill.snow';
@@ -34,6 +43,7 @@ require('activeadmin_quill_editor')
34
43
  ```
35
44
 
36
45
  ## Usage
46
+
37
47
  In your Active Admin models, form configuration, set the text inputs with `as: :quill_editor` where needed.
38
48
 
39
49
  **data-options**: permits to set *quill editor* options directly - see [options list](https://quilljs.com/docs/configuration/)
@@ -61,6 +71,7 @@ f.input :description, as: :quill_editor, input_html: { data: { options: { module
61
71
  ```
62
72
 
63
73
  ### ImageUploader plugin
74
+
64
75
  This plugin allows to upload images to the server (instead of storing them in *base64* by default), reference [here](https://github.com/NoelOConnell/quill-image-uploader).
65
76
 
66
77
  ```ruby
@@ -86,14 +97,21 @@ Consider that this is just a basic example: images are uploaded as soon as they
86
97
  the *upload_admin_post_path*) and it doesn't provide a way to remove images (just deleting them from
87
98
  the editor will not destroy them, you'll need to implement a purge logic for that).
88
99
 
100
+ ## Changelog
101
+
102
+ The changelog is available [here](CHANGELOG.md).
103
+
89
104
  ## Do you like it? Star it!
90
- If you use this component just star it. A developer is more motivated to improve a project when there is some interest.
91
105
 
92
- Take a look at [other Active Admin components](https://github.com/blocknotes?utf8=✓&tab=repositories&q=activeadmin&type=source) that I made if you are curious.
106
+ If you use this component just star it. A developer is more motivated to improve a project when there is some interest. My other [Active Admin components](https://github.com/blocknotes?utf8=✓&tab=repositories&q=activeadmin&type=source).
107
+
108
+ Or consider offering me a coffee, it's a small thing but it is greatly appreciated: [about me](https://www.blocknot.es/about-me).
93
109
 
94
110
  ## Contributors
111
+
95
112
  - [Mattia Roccoberton](http://blocknot.es): author
96
113
  - The good guys that opened issues and pull requests from time to time
97
114
 
98
115
  ## License
116
+
99
117
  The gem is available as open-source under the terms of the [MIT](LICENSE.txt).
data/Rakefile CHANGED
@@ -5,7 +5,10 @@ require 'bundler/gem_tasks'
5
5
  begin
6
6
  require 'rspec/core/rake_task'
7
7
 
8
- RSpec::Core::RakeTask.new(:spec)
8
+ RSpec::Core::RakeTask.new(:spec) do |t|
9
+ # t.ruby_opts = %w[-w]
10
+ t.rspec_opts = ['--color', '--format documentation']
11
+ end
9
12
 
10
13
  task default: :spec
11
14
  rescue LoadError
@@ -85,11 +85,7 @@
85
85
  }
86
86
 
87
87
  // --- events ------------------------------------------------------------------
88
- $(document).ready(() => {
89
- initQuillEditors()
90
- })
91
-
92
- $(document).on('has_many_add:after', '.has_many_container', () => {
93
- initQuillEditors()
94
- })
88
+ $(document).ready(initQuillEditors)
89
+ $(document).on('has_many_add:after', '.has_many_container', initQuillEditors)
90
+ $(document).on('turbolinks:load', initQuillEditors)
95
91
  })()
@@ -29,6 +29,7 @@ body.active_admin [data-aa-quill-editor] {
29
29
  max-height: 300px;
30
30
  min-height: 150px;
31
31
  padding: 10px;
32
+ word-break: break-all;
32
33
 
33
34
  ol {
34
35
  list-style-type: decimal;
@@ -2,6 +2,7 @@
2
2
 
3
3
  module ActiveAdmin
4
4
  module QuillEditor
5
- VERSION = '0.3.0'
5
+ VERSION = '1.0.0'
6
+ QUILL_VERSION = '1.3.7'
6
7
  end
7
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activeadmin_quill_editor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mattia Roccoberton
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-01 00:00:00.000000000 Z
11
+ date: 2022-04-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activeadmin
@@ -25,131 +25,19 @@ dependencies:
25
25
  - !ruby/object:Gem::Version
26
26
  version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
- name: activestorage
28
+ name: appraisal
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 6.0.3.2
33
+ version: '2.4'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 6.0.3.2
41
- - !ruby/object:Gem::Dependency
42
- name: capybara
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: 3.33.0
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: 3.33.0
55
- - !ruby/object:Gem::Dependency
56
- name: pry
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: 0.13.1
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: 0.13.1
69
- - !ruby/object:Gem::Dependency
70
- name: puma
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: 4.3.5
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: 4.3.5
83
- - !ruby/object:Gem::Dependency
84
- name: rspec_junit_formatter
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - "~>"
88
- - !ruby/object:Gem::Version
89
- version: 0.4.1
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - "~>"
95
- - !ruby/object:Gem::Version
96
- version: 0.4.1
97
- - !ruby/object:Gem::Dependency
98
- name: rspec-rails
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: 4.0.1
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: 4.0.1
111
- - !ruby/object:Gem::Dependency
112
- name: rubocop
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: 0.90.0
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - "~>"
123
- - !ruby/object:Gem::Version
124
- version: 0.90.0
125
- - !ruby/object:Gem::Dependency
126
- name: selenium-webdriver
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - "~>"
130
- - !ruby/object:Gem::Version
131
- version: 3.142.7
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - "~>"
137
- - !ruby/object:Gem::Version
138
- version: 3.142.7
139
- - !ruby/object:Gem::Dependency
140
- name: sqlite3
141
- requirement: !ruby/object:Gem::Requirement
142
- requirements:
143
- - - "~>"
144
- - !ruby/object:Gem::Version
145
- version: 1.4.2
146
- type: :development
147
- prerelease: false
148
- version_requirements: !ruby/object:Gem::Requirement
149
- requirements:
150
- - - "~>"
151
- - !ruby/object:Gem::Version
152
- version: 1.4.2
40
+ version: '2.4'
153
41
  description: An Active Admin plugin to use Quill Rich Text Editor
154
42
  email: mat@blocknot.es
155
43
  executables: []
@@ -177,7 +65,11 @@ files:
177
65
  homepage: https://github.com/blocknotes/activeadmin_quill_editor
178
66
  licenses:
179
67
  - MIT
180
- metadata: {}
68
+ metadata:
69
+ homepage_uri: https://github.com/blocknotes/activeadmin_quill_editor
70
+ changelog_uri: https://github.com/blocknotes/activeadmin_quill_editor/blob/master/CHANGELOG.md
71
+ source_code_uri: https://github.com/blocknotes/activeadmin_quill_editor
72
+ rubygems_mfa_required: 'true'
181
73
  post_install_message:
182
74
  rdoc_options: []
183
75
  require_paths:
@@ -186,14 +78,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
186
78
  requirements:
187
79
  - - ">="
188
80
  - !ruby/object:Gem::Version
189
- version: '0'
81
+ version: 2.6.0
190
82
  required_rubygems_version: !ruby/object:Gem::Requirement
191
83
  requirements:
192
84
  - - ">="
193
85
  - !ruby/object:Gem::Version
194
86
  version: '0'
195
87
  requirements: []
196
- rubygems_version: 3.0.3
88
+ rubygems_version: 3.1.6
197
89
  signing_key:
198
90
  specification_version: 4
199
91
  summary: Quill Editor for ActiveAdmin