trix-genius 0.0.5a → 0.0.5

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: 135cb33725790904d8681630bc1170d7c100a9941d1dcc105d4c6356e8ec2aa5
4
- data.tar.gz: 0ea0098cdce2770ecb74cc0119ffc0f2631c263f70348aed41457287d20012fe
3
+ metadata.gz: d25f1567cc5fa06b21e7409fe6b262be50b9cbd175b80b36aec273a74576fb7e
4
+ data.tar.gz: ae1fea00b204489a22feebf04c28f2f2db1f7cabb9050134d09bf289ac06a72a
5
5
  SHA512:
6
- metadata.gz: eb2a7e7127fab2f11f11728e9568656074bcef188ab9d755f7bf92716e820b4de83b2a9968cac18c2d0ddfa4f1a70ba50a576b98c061c3f2466debe3bcadb7a1
7
- data.tar.gz: d1857789b062ddd3c98701bea4e7b31b6e4f8d5695076853abcd26bc52425cef7928e88945a1de8ac0726783622b9e25df519a659d5f114736ad501617f99e72
6
+ metadata.gz: b6d6e93d8205fa99030b61575a643c19329173627185add96303ee7d66cc2400dd96eb601281e88da2c36a3f7e9a149fbf6995bf571398f8578d4ddc120268ca
7
+ data.tar.gz: a04585743449e0c0705d1287b5e2acb3895c5f99d043751dc2eda82720bdc066bb735826d22283f762ec5a20266abd192008dfb15631cb6077f6769c377e552e
@@ -6,7 +6,7 @@ module TrixGenius
6
6
  source_root File.expand_path("templates", __dir__)
7
7
 
8
8
  def create_initializer
9
- initializer "trix_genius.rb", <<~RUBY
9
+ initializer "trix_genius", <<~RUBY
10
10
  TrixGenius.configure do |config|
11
11
  config.deepseek_api_key=ENV['DEEPSEEK_API_KEY']
12
12
  end
@@ -14,42 +14,22 @@ module TrixGenius
14
14
  end
15
15
 
16
16
  def update_applications_js
17
- js_application_path = "app/javascript/application.js"
18
- application_lines = ["import \"controllers\"", "import \"trix\"", "import \"@rails/actiontext\""]
19
-
20
- if File.exists?(js_application_path)
21
- application_file = File.read(js_application_path)
22
- update_file application_lines, application_file
23
- else
24
- say_status("error", "Could not find #{js_application_path}", :red)
25
- end
26
-
27
-
28
- js_application_controller_path ="app/javascript/controllers/application.js"
29
- application_controller_lines = ["import TrixController from \"controllers/trix-controller"\", "application.register(\"trix\", TrixController)"]
30
-
31
- if File.exists?(js_application_controller_path)
32
- application_controller_file = File.read(js_application_controller_path)
33
- update_file application_controller_lines, application_controller_file
34
- else
35
- say_status("error", "Could not find #{js_application_path}", :red)
36
- end
17
+ # app/javascript/application.js
18
+
19
+ # import "controllers"
20
+ # import "trix"
21
+ # import "@rails/actiontext"
22
+
23
+
24
+ # app/javascript/controllers/application.js
25
+ # import TrixController from "controllers/trix-controller"
26
+ # application.register("trix", TrixController)
37
27
  end
38
28
 
39
29
  def create_stimulus_controller
40
30
  copy_file "trix_genius_controller.js", "app/javascript/controllers/trix_genius_controller.js"
41
31
  end
42
32
 
43
- def update_file lines, file_content
44
- lines.each do |line|
45
- unless application_file.include?(line)
46
- append_to_file js_application_path, "\n#{line}\n"
47
- else
48
- say_status("skipped", "Import already present in application.js", :yellow)
49
- end
50
- end
51
- end
52
-
53
33
  end
54
34
  end
55
35
  end
metadata CHANGED
@@ -1,54 +1,54 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trix-genius
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5a
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Giménez Silva Germán Alberto https://rubystacknews.com/
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-04-07 00:00:00.000000000 Z
10
+ date: 2025-04-01 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: rails
14
14
  requirement: !ruby/object:Gem::Requirement
15
15
  requirements:
16
- - - "~>"
16
+ - - ">="
17
17
  - !ruby/object:Gem::Version
18
18
  version: '6.0'
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
- - - "~>"
23
+ - - ">="
24
24
  - !ruby/object:Gem::Version
25
25
  version: '6.0'
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: stimulus-rails
28
28
  requirement: !ruby/object:Gem::Requirement
29
29
  requirements:
30
- - - "~>"
30
+ - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: '1.3'
32
+ version: 1.3.4
33
33
  type: :runtime
34
34
  prerelease: false
35
35
  version_requirements: !ruby/object:Gem::Requirement
36
36
  requirements:
37
- - - "~>"
37
+ - - ">="
38
38
  - !ruby/object:Gem::Version
39
- version: '1.3'
39
+ version: 1.3.4
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: actiontext
42
42
  requirement: !ruby/object:Gem::Requirement
43
43
  requirements:
44
- - - "~>"
44
+ - - ">="
45
45
  - !ruby/object:Gem::Version
46
46
  version: '8.0'
47
47
  type: :runtime
48
48
  prerelease: false
49
49
  version_requirements: !ruby/object:Gem::Requirement
50
50
  requirements:
51
- - - "~>"
51
+ - - ">="
52
52
  - !ruby/object:Gem::Version
53
53
  version: '8.0'
54
54
  description: Trix-Genius adds AI-powered buttons and other custom controls to Trix
@@ -73,7 +73,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
73
73
  requirements:
74
74
  - - ">="
75
75
  - !ruby/object:Gem::Version
76
- version: '3.0'
76
+ version: '0'
77
77
  required_rubygems_version: !ruby/object:Gem::Requirement
78
78
  requirements:
79
79
  - - ">="