cm-graphql 0.0.3 → 0.0.5

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: 7bfab7b28788ebbc885ae022e0968183caaae84a666dc3368dd9139b671188ce
4
- data.tar.gz: b392401f10dd7227b968d35000df97d98def50880cced1fe3922742908b4c70b
3
+ metadata.gz: 399397ce48d209a73cae1bce70fd001bef2c90257da752f15d96bb2fd9cfd48a
4
+ data.tar.gz: 3ecbfb7570da22557b9ff06a4eb09118b8aa5ad3b6683668568a8ef99bf94ed7
5
5
  SHA512:
6
- metadata.gz: b6bdaa32b7d99300a3d78a4397024eb7d34cea339ad0dd3e0b27895d718e99d8327c6592578f9cbb971d1705f7f484a10d3773220db8a998fd8e0e600b30a2fb
7
- data.tar.gz: f5a5aeb6e08e3272a7ab2a3534c089e4d2ed3f2c3e352391ff925c2d61449bb63ed9bec646af6743a5b8e99ffc6d4210721fccd5e8529401dfd8ed3ebb38ba56
6
+ metadata.gz: 05c6cf5b383aac925bfa67885a589eac1fc274b922f2523a54398dcbd79d89582bd19fd20aac378382eb194a497a2385a1de3fc9fa4e558d56ccaf3f40772c80
7
+ data.tar.gz: 997ce8c7ae2213b1007b21a9f4ac8f1d8d002b5ef2d0f50fc5a392dc19d24a3a04b717050898fb40d75ad68f86f389afe6032c616c32166618dfdbd10b2e9402
data/Gemfile CHANGED
@@ -1,4 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source 'https://rubygems.org'
2
- source 'https://rails-assets.org'
3
4
 
4
- gemspec
5
+ gemspec
data/Gemfile.lock CHANGED
@@ -1,50 +1,61 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cm-graphql (0.0.3)
5
- graphiql-rails (~> 1.8.0)
6
- graphql (~> 1.13.1)
7
- graphql-errors (~> 0.4.0)
8
- graphql-rails_logger (~> 1.2.3)
9
- kaminari (~> 1.2.2)
4
+ cm-graphql (0.0.5)
5
+ graphiql-rails (~> 1.9)
6
+ graphql (~> 2.2, >= 2.2.5)
7
+ graphql-rails_logger (~> 1.2, >= 1.2.4)
8
+ kaminari (~> 1.2, >= 1.2.2)
10
9
 
11
10
  GEM
12
11
  remote: https://rubygems.org/
13
- remote: https://rails-assets.org/
14
12
  specs:
15
- actionpack (7.0.5.1)
16
- actionview (= 7.0.5.1)
17
- activesupport (= 7.0.5.1)
18
- rack (~> 2.0, >= 2.2.4)
13
+ actionpack (7.1.2)
14
+ actionview (= 7.1.2)
15
+ activesupport (= 7.1.2)
16
+ nokogiri (>= 1.8.5)
17
+ racc
18
+ rack (>= 2.2.4)
19
+ rack-session (>= 1.0.1)
19
20
  rack-test (>= 0.6.3)
20
- rails-dom-testing (~> 2.0)
21
- rails-html-sanitizer (~> 1.0, >= 1.2.0)
22
- actionview (7.0.5.1)
23
- activesupport (= 7.0.5.1)
21
+ rails-dom-testing (~> 2.2)
22
+ rails-html-sanitizer (~> 1.6)
23
+ actionview (7.1.2)
24
+ activesupport (= 7.1.2)
24
25
  builder (~> 3.1)
25
- erubi (~> 1.4)
26
- rails-dom-testing (~> 2.0)
27
- rails-html-sanitizer (~> 1.1, >= 1.2.0)
28
- activemodel (7.0.5.1)
29
- activesupport (= 7.0.5.1)
30
- activerecord (7.0.5.1)
31
- activemodel (= 7.0.5.1)
32
- activesupport (= 7.0.5.1)
33
- activesupport (7.0.5.1)
26
+ erubi (~> 1.11)
27
+ rails-dom-testing (~> 2.2)
28
+ rails-html-sanitizer (~> 1.6)
29
+ activemodel (7.1.2)
30
+ activesupport (= 7.1.2)
31
+ activerecord (7.1.2)
32
+ activemodel (= 7.1.2)
33
+ activesupport (= 7.1.2)
34
+ timeout (>= 0.4.0)
35
+ activesupport (7.1.2)
36
+ base64
37
+ bigdecimal
34
38
  concurrent-ruby (~> 1.0, >= 1.0.2)
39
+ connection_pool (>= 2.2.5)
40
+ drb
35
41
  i18n (>= 1.6, < 2)
36
42
  minitest (>= 5.1)
43
+ mutex_m
37
44
  tzinfo (~> 2.0)
45
+ base64 (0.2.0)
46
+ bigdecimal (3.1.5)
38
47
  builder (3.2.4)
39
48
  concurrent-ruby (1.2.2)
49
+ connection_pool (2.4.1)
40
50
  crass (1.0.6)
51
+ drb (2.2.0)
52
+ ruby2_keywords
41
53
  erubi (1.12.0)
42
- graphiql-rails (1.8.0)
54
+ graphiql-rails (1.9.0)
43
55
  railties
44
56
  sprockets-rails
45
- graphql (1.13.19)
46
- graphql-errors (0.4.0)
47
- graphql (>= 1.6.0, < 2)
57
+ graphql (2.2.5)
58
+ racc (~> 1.4)
48
59
  graphql-rails_logger (1.2.4)
49
60
  actionpack (> 5.0)
50
61
  activesupport (> 5.0)
@@ -52,6 +63,10 @@ GEM
52
63
  rouge (~> 3.0)
53
64
  i18n (1.14.1)
54
65
  concurrent-ruby (~> 1.0)
66
+ io-console (0.7.1)
67
+ irb (1.11.1)
68
+ rdoc
69
+ reline (>= 0.4.2)
55
70
  kaminari (1.2.2)
56
71
  activesupport (>= 4.1.0)
57
72
  kaminari-actionview (= 1.2.2)
@@ -64,46 +79,69 @@ GEM
64
79
  activerecord
65
80
  kaminari-core (= 1.2.2)
66
81
  kaminari-core (1.2.2)
67
- loofah (2.21.3)
82
+ loofah (2.22.0)
68
83
  crass (~> 1.0.2)
69
84
  nokogiri (>= 1.12.0)
70
- method_source (1.0.0)
71
- minitest (5.18.1)
72
- nokogiri (1.15.2-arm64-darwin)
85
+ mini_portile2 (2.8.5)
86
+ minitest (5.20.0)
87
+ mutex_m (0.2.0)
88
+ nokogiri (1.16.0)
89
+ mini_portile2 (~> 2.8.2)
90
+ racc (~> 1.4)
91
+ nokogiri (1.16.0-arm64-darwin)
73
92
  racc (~> 1.4)
74
- racc (1.7.1)
75
- rack (2.2.7)
93
+ psych (5.1.2)
94
+ stringio
95
+ racc (1.7.3)
96
+ rack (3.0.8)
97
+ rack-session (2.0.0)
98
+ rack (>= 3.0.0)
76
99
  rack-test (2.1.0)
77
100
  rack (>= 1.3)
78
- rails-dom-testing (2.0.3)
79
- activesupport (>= 4.2.0)
101
+ rackup (2.1.0)
102
+ rack (>= 3)
103
+ webrick (~> 1.8)
104
+ rails-dom-testing (2.2.0)
105
+ activesupport (>= 5.0.0)
106
+ minitest
80
107
  nokogiri (>= 1.6)
81
108
  rails-html-sanitizer (1.6.0)
82
109
  loofah (~> 2.21)
83
110
  nokogiri (~> 1.14)
84
- railties (7.0.5.1)
85
- actionpack (= 7.0.5.1)
86
- activesupport (= 7.0.5.1)
87
- method_source
111
+ railties (7.1.2)
112
+ actionpack (= 7.1.2)
113
+ activesupport (= 7.1.2)
114
+ irb
115
+ rackup (>= 1.0.0)
88
116
  rake (>= 12.2)
89
- thor (~> 1.0)
90
- zeitwerk (~> 2.5)
91
- rake (13.0.6)
117
+ thor (~> 1.0, >= 1.2.2)
118
+ zeitwerk (~> 2.6)
119
+ rake (13.1.0)
120
+ rdoc (6.6.2)
121
+ psych (>= 4.0.0)
122
+ reline (0.4.2)
123
+ io-console (~> 0.5)
92
124
  rouge (3.30.0)
93
- sprockets (4.2.0)
125
+ ruby2_keywords (0.0.5)
126
+ sprockets (4.2.1)
94
127
  concurrent-ruby (~> 1.0)
95
128
  rack (>= 2.2.4, < 4)
96
129
  sprockets-rails (3.4.2)
97
130
  actionpack (>= 5.2)
98
131
  activesupport (>= 5.2)
99
132
  sprockets (>= 3.0.0)
100
- thor (1.2.2)
133
+ stringio (3.1.0)
134
+ thor (1.3.0)
135
+ timeout (0.4.1)
101
136
  tzinfo (2.0.6)
102
137
  concurrent-ruby (~> 1.0)
103
- zeitwerk (2.6.8)
138
+ webrick (1.8.1)
139
+ zeitwerk (2.6.12)
104
140
 
105
141
  PLATFORMS
106
142
  arm64-darwin-20
143
+ arm64-darwin-22
144
+ ruby
107
145
 
108
146
  DEPENDENCIES
109
147
  cm-graphql!
@@ -3,6 +3,7 @@ module Types::Objects::Base
3
3
  field :id, Int, nil, null: false
4
4
  field :filename, String, nil, null: false
5
5
  field :url, String, nil, null: false
6
+ field :base64, String, nil, null: false
6
7
 
7
8
  def id
8
9
  if object.class.eql?(ActiveStorage::Variant)
@@ -29,5 +30,14 @@ module Types::Objects::Base
29
30
  object.url
30
31
  end
31
32
  end
33
+
34
+ def base64
35
+ data = if object.class.eql?(ActiveStorage::Variant)
36
+ Base64.strict_encode64(object.blob.download)
37
+ else
38
+ Base64.strict_encode64(object.download)
39
+ end
40
+ "data:#{object.content_type};base64,#{data}"
41
+ end
32
42
  end
33
43
  end
data/cm-graphql.gemspec CHANGED
@@ -1,25 +1,25 @@
1
+ # frozen_string_literal: true
2
+
1
3
  Gem::Specification.new do |spec|
2
- spec.name = 'cm-graphql'
3
- spec.version = '0.0.3'
4
- spec.date = '2022-09-14'
5
- spec.summary = "A gem to setup grapqhl basics like pagination, file upload"
6
- spec.description = "A gem to setup grapqhl basics like pagination, file upload"
7
- spec.authors = ["Anbazhagan Palani"]
8
- spec.email = 'anbu@commutatus.com'
9
- spec.homepage =
10
- 'https://github.com/commutatus/template-paging-api'
4
+ spec.name = 'cm-graphql'
5
+ spec.version = '0.0.5'
6
+ spec.date = '2022-09-14'
7
+ spec.summary = 'A gem to setup grapqhl basics like pagination, file upload'
8
+ spec.description = 'A gem to setup grapqhl basics like pagination, file upload'
9
+ spec.authors = ['Aditya Tiwari', 'Anbazhagan Palani']
10
+ spec.email = ['taditya.tiwari007@gmail.com', 'anbu@commutatus.com']
11
+ spec.homepage = 'https://github.com/commutatus/template-paging-api'
11
12
  spec.license = 'MIT'
12
-
13
- spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
13
+ spec.files = Dir.chdir(File.expand_path(__dir__)) do
14
14
  `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
15
15
  end
16
- spec.bindir = "exe"
16
+ spec.bindir = 'exe'
17
17
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
18
- spec.require_paths = ["lib"]
18
+ spec.require_paths = ['lib']
19
+ spec.required_ruby_version = '>= 3.0.0'
19
20
 
20
- spec.add_runtime_dependency 'graphql', '~> 1.13.1'
21
- spec.add_runtime_dependency 'graphql-errors', '~> 0.4.0'
22
- spec.add_runtime_dependency 'graphql-rails_logger', '~> 1.2.3'
23
- spec.add_runtime_dependency 'graphiql-rails', '~> 1.8.0'
24
- spec.add_runtime_dependency 'kaminari', '~> 1.2.2'
21
+ spec.add_runtime_dependency 'graphiql-rails', '~> 1.9'
22
+ spec.add_runtime_dependency 'graphql', '~> 2.2', '>= 2.2.5'
23
+ spec.add_runtime_dependency 'graphql-rails_logger', '~> 1.2', '>= 1.2.4'
24
+ spec.add_runtime_dependency 'kaminari', '~> 1.2', '>= 1.2.2'
25
25
  end
metadata CHANGED
@@ -1,9 +1,10 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cm-graphql
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
+ - Aditya Tiwari
7
8
  - Anbazhagan Palani
8
9
  autorequire:
9
10
  bindir: exe
@@ -11,66 +12,67 @@ cert_chain: []
11
12
  date: 2022-09-14 00:00:00.000000000 Z
12
13
  dependencies:
13
14
  - !ruby/object:Gem::Dependency
14
- name: graphql
15
+ name: graphiql-rails
15
16
  requirement: !ruby/object:Gem::Requirement
16
17
  requirements:
17
18
  - - "~>"
18
19
  - !ruby/object:Gem::Version
19
- version: 1.13.1
20
+ version: '1.9'
20
21
  type: :runtime
21
22
  prerelease: false
22
23
  version_requirements: !ruby/object:Gem::Requirement
23
24
  requirements:
24
25
  - - "~>"
25
26
  - !ruby/object:Gem::Version
26
- version: 1.13.1
27
+ version: '1.9'
27
28
  - !ruby/object:Gem::Dependency
28
- name: graphql-errors
29
+ name: graphql
29
30
  requirement: !ruby/object:Gem::Requirement
30
31
  requirements:
31
32
  - - "~>"
32
33
  - !ruby/object:Gem::Version
33
- version: 0.4.0
34
+ version: '2.2'
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ version: 2.2.5
34
38
  type: :runtime
35
39
  prerelease: false
36
40
  version_requirements: !ruby/object:Gem::Requirement
37
41
  requirements:
38
42
  - - "~>"
39
43
  - !ruby/object:Gem::Version
40
- version: 0.4.0
44
+ version: '2.2'
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: 2.2.5
41
48
  - !ruby/object:Gem::Dependency
42
49
  name: graphql-rails_logger
43
50
  requirement: !ruby/object:Gem::Requirement
44
51
  requirements:
45
52
  - - "~>"
46
53
  - !ruby/object:Gem::Version
47
- version: 1.2.3
48
- type: :runtime
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: 1.2.3
55
- - !ruby/object:Gem::Dependency
56
- name: graphiql-rails
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
54
+ version: '1.2'
55
+ - - ">="
60
56
  - !ruby/object:Gem::Version
61
- version: 1.8.0
57
+ version: 1.2.4
62
58
  type: :runtime
63
59
  prerelease: false
64
60
  version_requirements: !ruby/object:Gem::Requirement
65
61
  requirements:
66
62
  - - "~>"
67
63
  - !ruby/object:Gem::Version
68
- version: 1.8.0
64
+ version: '1.2'
65
+ - - ">="
66
+ - !ruby/object:Gem::Version
67
+ version: 1.2.4
69
68
  - !ruby/object:Gem::Dependency
70
69
  name: kaminari
71
70
  requirement: !ruby/object:Gem::Requirement
72
71
  requirements:
73
72
  - - "~>"
73
+ - !ruby/object:Gem::Version
74
+ version: '1.2'
75
+ - - ">="
74
76
  - !ruby/object:Gem::Version
75
77
  version: 1.2.2
76
78
  type: :runtime
@@ -78,10 +80,15 @@ dependencies:
78
80
  version_requirements: !ruby/object:Gem::Requirement
79
81
  requirements:
80
82
  - - "~>"
83
+ - !ruby/object:Gem::Version
84
+ version: '1.2'
85
+ - - ">="
81
86
  - !ruby/object:Gem::Version
82
87
  version: 1.2.2
83
88
  description: A gem to setup grapqhl basics like pagination, file upload
84
- email: anbu@commutatus.com
89
+ email:
90
+ - taditya.tiwari007@gmail.com
91
+ - anbu@commutatus.com
85
92
  executables: []
86
93
  extensions: []
87
94
  extra_rdoc_files: []
@@ -127,7 +134,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
127
134
  requirements:
128
135
  - - ">="
129
136
  - !ruby/object:Gem::Version
130
- version: '0'
137
+ version: 3.0.0
131
138
  required_rubygems_version: !ruby/object:Gem::Requirement
132
139
  requirements:
133
140
  - - ">="