tb_core 1.5.3 → 1.5.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7be83cc72ea702d72548da1c9bf4d25eb632e154169ef241e11bfa845d842a3f
4
- data.tar.gz: 191e53b35d46f8f5b91acef66b14015cfb69fc6dd6cd57ae68db1ac9d8e6540e
3
+ metadata.gz: 685a39f5f0708976182b94ca4eba53159105aae179377c82506808ac3c0140aa
4
+ data.tar.gz: 8281b2db3cd5ec6ff3c68b564ebc2b30d5fb4e90b1e1fd2d5966ad18b967ab49
5
5
  SHA512:
6
- metadata.gz: 3eb99e7178bd58e87539f5ffec183614fccd1a1aa801a7c531d962d0a4a8408228736007b62172f04bd344f402bbed45c7771b768eb1278b14218fa9a3d46b4a
7
- data.tar.gz: 04016da2d6563e8857c02c924b08878ecf238da9f63a871dd991498fc6f4765792a16c965b2053eb4add1ab75a71287af73d01475b52afa4596655ac2f8ee0d6
6
+ metadata.gz: 30658044ef646b5daffa80b31eaf80b6408d9336189e01671ab523a89d85edf86da366bf09d6b8ac0842a6c787718e5570452c461f98505ce79616ddc0e81efd
7
+ data.tar.gz: 78b94c0636177d2e71249dceaf11b153c1680f39597360393aa1b8b98defccae365f1509ae19295295e6db3aa58e5fe172125aeada933bfd98ef2f50efa5398f
@@ -4,7 +4,13 @@ tb.editor = {};
4
4
 
5
5
  var editor = tb.editor;
6
6
 
7
- editor.tinymce = {loaded:false};
7
+ /*
8
+ * Use tb.editor.overrides to set custom configs in your application
9
+ *
10
+ * tb.editor.overrides = { menubar: true }
11
+ *
12
+ */
13
+ editor.overrides = {};
8
14
 
9
15
  var registeredPlugins = [
10
16
  'autolink','lists','image','link','media','paste', 'code'
@@ -23,19 +29,22 @@ tb.editor = {};
23
29
  "iframe[src|width|height|name|align|frameborder|allowfullscreen]"
24
30
  ];
25
31
 
26
- editor.init = function(options) {
32
+ editor.init = function(args) {
27
33
  editor.unload();
28
34
 
29
- options = options || { selector: 'textarea.tinymce' };
35
+ var selector = args ? args.selector : 'textarea.tinymce';
30
36
 
31
- tinymce.init({
32
- selector: options.selector,
37
+ var options = Object.assign({
38
+ selector: selector,
33
39
  height: 400,
34
40
  menubar: false,
35
41
  toolbar: registeredButtons.join(' '),
36
42
  plugins: registeredPlugins.join(' '),
37
- extended_valid_elements: extendedValidElements.join(",")
38
- })
43
+ extended_valid_elements: extendedValidElements.join(","),
44
+ convert_urls: false
45
+ }, editor.overrides);
46
+
47
+ tinymce.init(options)
39
48
  };
40
49
 
41
50
  editor.unload = function() {
@@ -1,3 +1,3 @@
1
1
  module TbCore
2
- VERSION = '1.5.3'.freeze
2
+ VERSION = '1.5.4'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tb_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.3
4
+ version: 1.5.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Greg Woods
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-01-11 00:00:00.000000000 Z
11
+ date: 2021-02-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: authlogic