activeadmin_medium_editor 0.2.0 → 0.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.rubocop.yml +73 -0
- data/Gemfile +0 -1
- data/Rakefile +2 -2
- data/activeadmin_medium_editor.gemspec +4 -2
- data/app/assets/javascripts/activeadmin/medium_editor_input.js +4 -4
- data/lib/activeadmin/medium_editor.rb +2 -0
- data/lib/activeadmin/medium_editor/engine.rb +2 -0
- data/lib/activeadmin/medium_editor/version.rb +3 -1
- data/lib/activeadmin_medium_editor.rb +2 -0
- data/lib/formtastic/inputs/medium_editor_input.rb +3 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 1584ab7bff1f752c1d93bf42300abfd3a64d04d3da03810408f332aca1187f44
|
4
|
+
data.tar.gz: 5f6d6f6f43db3f8849902a0b0106b17e7ba703ee371f4118c1f3c85ca6dc8dd4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af3a6057f90d75f30a1cf1233fc8aa7178ffab8b7bae24e14f6b96084fa2d02b363d81cad7a76ff9b12fc5762cbeb03dfc260987a4de3ea1ce303d9738d3967f
|
7
|
+
data.tar.gz: e12a525672fac9ba6250d560b268595dbf2c1151291cf3ef17b535567ef0464054be2dd0022f6e74095ce04d736ef897baf3b8f94c25672d22471a5fa58889af
|
data/.rubocop.yml
ADDED
@@ -0,0 +1,73 @@
|
|
1
|
+
require:
|
2
|
+
- rubocop-rspec
|
3
|
+
|
4
|
+
Rails:
|
5
|
+
Enabled: true
|
6
|
+
|
7
|
+
AllCops:
|
8
|
+
TargetRubyVersion: 2.3.8
|
9
|
+
TargetRailsVersion: 5.2
|
10
|
+
Exclude:
|
11
|
+
- db/schema.rb
|
12
|
+
- bin/*
|
13
|
+
- node_modules/**/*
|
14
|
+
# Temporary files
|
15
|
+
- tmp/**/*
|
16
|
+
|
17
|
+
Rails/InverseOf:
|
18
|
+
Enabled: false
|
19
|
+
|
20
|
+
Style/Documentation:
|
21
|
+
Enabled: false
|
22
|
+
|
23
|
+
Metrics/ClassLength:
|
24
|
+
# Default value is 100
|
25
|
+
Max: 150
|
26
|
+
|
27
|
+
Metrics/LineLength:
|
28
|
+
# Default is 80
|
29
|
+
Max: 120
|
30
|
+
|
31
|
+
Metrics/ModuleLength:
|
32
|
+
# Default is 100
|
33
|
+
Max: 150
|
34
|
+
|
35
|
+
Metrics/ParameterLists:
|
36
|
+
# Default is 5
|
37
|
+
Max: 6
|
38
|
+
|
39
|
+
RSpec/ExampleLength:
|
40
|
+
# Default is 10
|
41
|
+
Max: 20
|
42
|
+
|
43
|
+
Style/FrozenStringLiteralComment:
|
44
|
+
# Deface DOES edit strings in place
|
45
|
+
Exclude:
|
46
|
+
- 'app/overrides/**/*'
|
47
|
+
|
48
|
+
RSpec/MultipleExpectations:
|
49
|
+
# Default is 3
|
50
|
+
Max: 5
|
51
|
+
|
52
|
+
RSpec/NestedGroups:
|
53
|
+
# Default is 3
|
54
|
+
Max: 6
|
55
|
+
|
56
|
+
Metrics/AbcSize:
|
57
|
+
Max: 25
|
58
|
+
|
59
|
+
Metrics/BlockLength:
|
60
|
+
# This value double the rubocop default
|
61
|
+
Max: 50
|
62
|
+
|
63
|
+
Metrics/CyclomaticComplexity:
|
64
|
+
# This value double the rubocop default
|
65
|
+
Max: 12
|
66
|
+
|
67
|
+
Metrics/MethodLength:
|
68
|
+
# This value double the rubocop default
|
69
|
+
Max: 20
|
70
|
+
|
71
|
+
Metrics/PerceivedComplexity:
|
72
|
+
# Default is 7
|
73
|
+
Max: 10
|
data/Gemfile
CHANGED
data/Rakefile
CHANGED
@@ -1,3 +1,3 @@
|
|
1
|
-
#
|
1
|
+
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require
|
3
|
+
require 'bundler/gem_tasks'
|
@@ -1,4 +1,6 @@
|
|
1
|
-
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
lib = File.expand_path('lib', __dir__)
|
2
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
3
5
|
require 'activeadmin/medium_editor/version'
|
4
6
|
|
@@ -15,5 +17,5 @@ Gem::Specification.new do |spec|
|
|
15
17
|
spec.files = `git ls-files -z`.split("\x0")
|
16
18
|
spec.require_paths = ['lib']
|
17
19
|
|
18
|
-
spec.add_runtime_dependency 'activeadmin', '
|
20
|
+
spec.add_runtime_dependency 'activeadmin', '>= 1.0'
|
19
21
|
end
|
@@ -1,6 +1,6 @@
|
|
1
1
|
function initMediumEditors() {
|
2
|
-
$('.medium-editor').each(function
|
3
|
-
if
|
2
|
+
$('.medium-editor').each(function() {
|
3
|
+
if(!$(this).hasClass('medium-editor--active')) {
|
4
4
|
var options = {};
|
5
5
|
options = $.extend({}, options, $(this).data('options'));
|
6
6
|
new MediumEditor($(this), options);
|
@@ -9,10 +9,10 @@ function initMediumEditors() {
|
|
9
9
|
});
|
10
10
|
}
|
11
11
|
|
12
|
-
$(document).on('has_many_add:after', function
|
12
|
+
$(document).on('has_many_add:after', function() {
|
13
13
|
initMediumEditors();
|
14
14
|
});
|
15
15
|
|
16
|
-
$(document).ready(
|
16
|
+
$(document).ready(function() {
|
17
17
|
initMediumEditors();
|
18
18
|
});
|
metadata
CHANGED
@@ -1,27 +1,27 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activeadmin_medium_editor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mattia Roccoberton
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-06-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activeadmin
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '1.0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - "
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '1.0'
|
27
27
|
description: An Active Admin plugin to use Medium Editor
|
@@ -31,6 +31,7 @@ extensions: []
|
|
31
31
|
extra_rdoc_files: []
|
32
32
|
files:
|
33
33
|
- ".gitignore"
|
34
|
+
- ".rubocop.yml"
|
34
35
|
- Gemfile
|
35
36
|
- LICENSE.txt
|
36
37
|
- README.md
|
@@ -81,8 +82,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
81
82
|
- !ruby/object:Gem::Version
|
82
83
|
version: '0'
|
83
84
|
requirements: []
|
84
|
-
|
85
|
-
rubygems_version: 2.6.14
|
85
|
+
rubygems_version: 3.0.2
|
86
86
|
signing_key:
|
87
87
|
specification_version: 4
|
88
88
|
summary: medium-editor for ActiveAdmin
|