effective_bootstrap 0.9.29 → 0.9.34

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: c7962cda76a99f9a2af980a67a9f876223b722d83ecafee967bc15cbd3da22a2
4
- data.tar.gz: 7adf1ba3532157b54039e67a6faeb2675a5f6826c88271a0597aca25dfb121d7
3
+ metadata.gz: 58f7d739c4c9d00ead21293bee0bcceefbca0b57e8ac958bec112f5aadeee535
4
+ data.tar.gz: 9a069cd5fefdce47db3f69095fef7e0f8eed3829036c264bf1ee3c3b36f36f51
5
5
  SHA512:
6
- metadata.gz: '079863a2874583e9d3080aea824fd847e1026c0d7c7ac6591a13a6b7927633e25c4f5ada8278d0aed219facebff6901ab06498d7c34794d256300701fb5b8e9e'
7
- data.tar.gz: 352ccfac174eb0fed1f10627a881407e9f9f331a23968c72a259dac329e4abe46521588cb5aa0d40a4b280e86a2fcdaab0b9f8e84024a8f196eb5c701c24a877
6
+ metadata.gz: 513dcea0768e7af3828d1742d0929e021b02ce7041ebbd5e24208a7a452f109ad62a8367bed9f851b01b43f5cc82d102bc6d7c680036333ee94eb9fbda743d66
7
+ data.tar.gz: 82c31a8d062c6070bdc6d146150f169757be27979a4d429218af739f7d45cba797a22e0e5ed11263eb3b920a02c68476e9269cbc80e50950fcba7363bbaac913
@@ -18,8 +18,13 @@ if <%= !!EffectiveBootstrap.use_custom_data_confirm %> && (window.Rails || $.rai
18
18
  , 4000)
19
19
  false # don't show the confirmation dialog
20
20
 
21
- (window.Rails || $.rails).confirm = (message) -> true
22
- (window.Rails || $.rails).effective_bootstrap_custom_data_confirm = true
21
+ if window.Rails
22
+ window.Rails.confirm = (message) -> true
23
+ window.Rails.effective_bootstrap_custom_data_confirm = true
24
+
25
+ if $.rails
26
+ $.rails.confirm = (message) -> true
27
+ $.rails.effective_bootstrap_custom_data_confirm = true
23
28
 
24
29
  $(document).on 'confirm:complete', (event) -> $(event.target).data('confirmed')
25
30
 
@@ -0,0 +1,3 @@
1
+ // Styles for the article editor iframe body content
2
+ // This file is included by the article editor iframe.
3
+ body { padding-top: 0px !important; }
@@ -1 +1,5 @@
1
- @import 'overrides';
1
+ // Styles for the article editor look and feel
2
+ // Use this to customize the textarea input, toolbar, etc
3
+ // Does not affect the article editor iframe contents
4
+
5
+ .indented-list { list-style-type: none !important; }
@@ -1,5 +1,6 @@
1
1
  @import 'effective_bootstrap/base';
2
2
 
3
+ @import 'effective_article_editor/input';
3
4
  @import 'effective_checks/input';
4
5
  @import 'effective_datetime/input';
5
6
  @import 'effective_file/input';
@@ -1 +1 @@
1
- @import 'effective_article_editor/input';
1
+ @import 'effective_article_editor/content';
@@ -2,18 +2,11 @@ module Effective
2
2
  module FormInputs
3
3
  class ArticleEditor < Effective::FormInput
4
4
 
5
- def build_input(&block)
6
- @builder.super_text_area(name, options[:input])
7
- end
8
-
9
- def input_html_options
10
- { class: 'effective_article_editor form-control', id: unique_id, autocomplete: 'off' }
11
- end
12
-
13
- def input_js_options
5
+ # https://imperavi.com/article/docs/settings/
6
+ def self.defaults
14
7
  {
15
- active_storage: active_storage,
16
- css: '/assets/effective_article_editor/',
8
+ active_storage: nil,
9
+ css: '/assets/article_editor/',
17
10
  custom: {
18
11
  css: ['/assets/application.css', '/assets/effective_bootstrap_article_editor.css']
19
12
  },
@@ -47,7 +40,7 @@ module Effective
47
40
  '12': 'col-sm-12'
48
41
  }
49
42
  },
50
- plugins: ['blockcode', 'imageposition', 'imageresize', 'inlineformat', 'removeformat', 'reorder', 'style'],
43
+ plugins: ['blockcode', 'cellcolor', 'imageposition', 'imageresize', 'inlineformat', 'removeformat', 'reorder', 'style'],
51
44
  quote: {
52
45
  template: '<blockquote><p></p></blockquote>'
53
46
  },
@@ -58,10 +51,33 @@ module Effective
58
51
  'small': { title: 'Small', classname: 'table-sm' },
59
52
  'striped': { title: 'Striped', classname: 'table-striped' },
60
53
  }
54
+ },
55
+ cellcolors: {
56
+ 'primary': { title: 'Primary', classname: 'table-primary' },
57
+ 'secondary': { title: 'Secondary', classname: 'table-secondary' },
58
+ 'active': { title: 'Active', classname: 'table-active' },
59
+ 'success': { title: 'Success', classname: 'table-success' },
60
+ 'danger': { title: 'Danger', classname: 'table-danger' },
61
+ 'warning': { title: 'Warning', classname: 'table-warning' },
62
+ 'info': { title: 'Info', classname: 'table-info' },
63
+ 'light': { title: 'Light', classname: 'table-light' },
64
+ 'dark': { title: 'Dark', classname: 'table-dark' }
61
65
  }
62
66
  }
63
67
  end
64
68
 
69
+ def build_input(&block)
70
+ @builder.super_text_area(name, options[:input])
71
+ end
72
+
73
+ def input_html_options
74
+ { class: 'effective_article_editor form-control', id: unique_id, autocomplete: 'off' }
75
+ end
76
+
77
+ def input_js_options
78
+ self.class.defaults.merge(active_storage: active_storage)
79
+ end
80
+
65
81
  def active_storage
66
82
  return @active_storage unless @active_storage.nil?
67
83
 
@@ -1,3 +1,3 @@
1
1
  module EffectiveBootstrap
2
- VERSION = '0.9.29'.freeze
2
+ VERSION = '0.9.34'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_bootstrap
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.29
4
+ version: 0.9.34
5
5
  platform: ruby
6
6
  authors:
7
7
  - Code and Effect
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-09 00:00:00.000000000 Z
11
+ date: 2021-06-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -611,8 +611,8 @@ files:
611
611
  - app/assets/javascripts/moment/locale/zh-hk.js
612
612
  - app/assets/javascripts/moment/locale/zh-tw.js
613
613
  - app/assets/javascripts/moment/moment.js
614
+ - app/assets/stylesheets/effective_article_editor/content.scss
614
615
  - app/assets/stylesheets/effective_article_editor/input.scss
615
- - app/assets/stylesheets/effective_article_editor/overrides.scss
616
616
  - app/assets/stylesheets/effective_bootstrap.scss
617
617
  - app/assets/stylesheets/effective_bootstrap/base.scss
618
618
  - app/assets/stylesheets/effective_bootstrap/forms.scss
@@ -1 +0,0 @@
1
- body { padding-top: 0px !important; }