decidim-api 0.28.0 → 0.28.2

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: 95f18e6ccdcc794b7e57462e34144872e5f4c364ed8a29181ccb4ae05f9763d1
4
- data.tar.gz: c5078a6a5222d82885cfe77084e7852a1a2ef82df5ed6d9d7547c5da29295351
3
+ metadata.gz: bfc163b3464d9c6c0e338f0696ed973109f91ecc3afe8a69102521517b1fda36
4
+ data.tar.gz: cf99822454e41597390c2df809bc5976d54b0a2e5de7aca957acf8a97b7f6db9
5
5
  SHA512:
6
- metadata.gz: 442556fecc82c7d2e546223d4dfe50fbbba60357c53a25f28e9e742fa00602d218bee326dc8b2ae4b015d3ec0e87d18fd5031d44b8a6bb66b131050e42b7f289
7
- data.tar.gz: 115a8aec1e657cb23edb222619e1f8523a2ff7d7a743f7b2ef2aa90fec31101dbd097f2bb410d7cb1c9bdaf167ebb65a2cc7db8edf897f31cb0bec96e271dc22
6
+ metadata.gz: 1c8536ee5c6ea50a30cbd1a66805b5988729b20f1872e5d845099a565e32a30120ee2c5e8e29bef8c7c391c1d56e1cade748885d738d94358ea16903361495ab
7
+ data.tar.gz: 216ed5e3f45b3812ca21dcf8ebdf83521bf5e61196f00d4cc53387e433367eef35ff691750cbbf59b5f330ec57f4de52d40fc063cdc57630a9f0aee526bb6369
@@ -0,0 +1,45 @@
1
+ # frozen_string_literal: true
2
+
3
+ $LOAD_PATH.push File.expand_path("lib", __dir__)
4
+
5
+ # Maintain your gem's version:
6
+ require "decidim/api/version"
7
+
8
+ # Describe your gem and declare its dependencies:
9
+ Gem::Specification.new do |s|
10
+ s.version = Decidim::Api.version
11
+ s.authors = ["Josep Jaume Rey Peroy", "Marc Riera Casals", "Oriol Gual Oliva"]
12
+ s.email = ["josepjaume@gmail.com", "mrc2407@gmail.com", "oriolgual@gmail.com"]
13
+ s.license = "AGPL-3.0"
14
+ s.homepage = "https://decidim.org"
15
+ s.metadata = {
16
+ "bug_tracker_uri" => "https://github.com/decidim/decidim/issues",
17
+ "documentation_uri" => "https://docs.decidim.org/",
18
+ "funding_uri" => "https://opencollective.com/decidim",
19
+ "homepage_uri" => "https://decidim.org",
20
+ "source_code_uri" => "https://github.com/decidim/decidim"
21
+ }
22
+ s.required_ruby_version = "~> 3.1.0"
23
+
24
+ s.name = "decidim-api"
25
+ s.summary = "Decidim API module"
26
+ s.description = "API engine for decidim"
27
+
28
+ s.files = Dir.chdir(__dir__) do
29
+ `git ls-files -z`.split("\x0").select do |f|
30
+ (File.expand_path(f) == __FILE__) ||
31
+ f.start_with?(*%w(app/ config/ docs/ lib/ Rakefile README.md))
32
+ end
33
+ end
34
+
35
+ s.add_dependency "commonmarker", "~> 0.23.0", ">= 0.23.9"
36
+ s.add_dependency "decidim-core", Decidim::Api.version
37
+ # Graphql version 2.1 breaks graphql-client compatibility See https://github.com/github/graphql-client/pull/310
38
+ s.add_dependency "graphql", "~> 2.0.0"
39
+ s.add_dependency "graphql-docs", "~> 3.0.1"
40
+ s.add_dependency "rack-cors", "~> 1.0"
41
+
42
+ s.add_development_dependency "decidim-comments", Decidim::Api.version
43
+ s.add_development_dependency "decidim-dev", Decidim::Api.version
44
+ s.add_development_dependency "decidim-participatory_processes", Decidim::Api.version
45
+ end
data/docs/usage.md CHANGED
@@ -16,6 +16,8 @@ Typically (although some particular installations may change that) you will find
16
16
 
17
17
  The GraphQL format is a JSON formatted text that is specified in a query. Response is a JSON object as well. For details about specification check the official [GraphQL site](https://graphql.org/learn/).
18
18
 
19
+ Exercise caution when utilizing the output of this API, as it may include HTML that has not been escaped. Take particular care in handling this data, specially if you intend to render it on a webpage.
20
+
19
21
  For instance, you can check the version of a Decidim installation by using `curl` in the terminal:
20
22
 
21
23
  ```bash
@@ -35,9 +35,9 @@ module Decidim
35
35
  initializer "decidim_api.graphiql" do
36
36
  Decidim::GraphiQL::Rails.config.tap do |config|
37
37
  config.query_params = true
38
- config.initial_query = File.read(
39
- File.join(__dir__, "graphiql-initial-query.txt")
40
- ).html_safe
38
+ config.initial_query = ERB::Util.html_escape(
39
+ File.read(File.join(__dir__, "graphiql-initial-query.txt"))
40
+ )
41
41
  end
42
42
  end
43
43
 
@@ -4,7 +4,7 @@ module Decidim
4
4
  # This holds the decidim-api version.
5
5
  module Api
6
6
  def self.version
7
- "0.28.0"
7
+ "0.28.2"
8
8
  end
9
9
  end
10
10
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.28.0
4
+ version: 0.28.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josep Jaume Rey Peroy
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2023-12-20 00:00:00.000000000 Z
13
+ date: 2024-07-16 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: commonmarker
@@ -32,6 +32,20 @@ dependencies:
32
32
  - - ">="
33
33
  - !ruby/object:Gem::Version
34
34
  version: 0.23.9
35
+ - !ruby/object:Gem::Dependency
36
+ name: decidim-core
37
+ requirement: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - '='
40
+ - !ruby/object:Gem::Version
41
+ version: 0.28.2
42
+ type: :runtime
43
+ prerelease: false
44
+ version_requirements: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - '='
47
+ - !ruby/object:Gem::Version
48
+ version: 0.28.2
35
49
  - !ruby/object:Gem::Dependency
36
50
  name: graphql
37
51
  requirement: !ruby/object:Gem::Requirement
@@ -80,56 +94,42 @@ dependencies:
80
94
  requirements:
81
95
  - - '='
82
96
  - !ruby/object:Gem::Version
83
- version: 0.28.0
97
+ version: 0.28.2
84
98
  type: :development
85
99
  prerelease: false
86
100
  version_requirements: !ruby/object:Gem::Requirement
87
101
  requirements:
88
102
  - - '='
89
103
  - !ruby/object:Gem::Version
90
- version: 0.28.0
91
- - !ruby/object:Gem::Dependency
92
- name: decidim-core
93
- requirement: !ruby/object:Gem::Requirement
94
- requirements:
95
- - - '='
96
- - !ruby/object:Gem::Version
97
- version: 0.28.0
98
- type: :development
99
- prerelease: false
100
- version_requirements: !ruby/object:Gem::Requirement
101
- requirements:
102
- - - '='
103
- - !ruby/object:Gem::Version
104
- version: 0.28.0
104
+ version: 0.28.2
105
105
  - !ruby/object:Gem::Dependency
106
106
  name: decidim-dev
107
107
  requirement: !ruby/object:Gem::Requirement
108
108
  requirements:
109
109
  - - '='
110
110
  - !ruby/object:Gem::Version
111
- version: 0.28.0
111
+ version: 0.28.2
112
112
  type: :development
113
113
  prerelease: false
114
114
  version_requirements: !ruby/object:Gem::Requirement
115
115
  requirements:
116
116
  - - '='
117
117
  - !ruby/object:Gem::Version
118
- version: 0.28.0
118
+ version: 0.28.2
119
119
  - !ruby/object:Gem::Dependency
120
120
  name: decidim-participatory_processes
121
121
  requirement: !ruby/object:Gem::Requirement
122
122
  requirements:
123
123
  - - '='
124
124
  - !ruby/object:Gem::Version
125
- version: 0.28.0
125
+ version: 0.28.2
126
126
  type: :development
127
127
  prerelease: false
128
128
  version_requirements: !ruby/object:Gem::Requirement
129
129
  requirements:
130
130
  - - '='
131
131
  - !ruby/object:Gem::Version
132
- version: 0.28.0
132
+ version: 0.28.2
133
133
  description: API engine for decidim
134
134
  email:
135
135
  - josepjaume@gmail.com
@@ -154,8 +154,8 @@ files:
154
154
  - app/views/decidim/api/graphiql/show.html.erb
155
155
  - app/views/layouts/decidim/api/documentation.html.erb
156
156
  - config/assets.rb
157
- - config/environment.rb
158
157
  - config/routes.rb
158
+ - decidim-api.gemspec
159
159
  - docs/usage.md
160
160
  - lib/decidim/api.rb
161
161
  - lib/decidim/api/engine.rb
@@ -195,16 +195,16 @@ require_paths:
195
195
  - lib
196
196
  required_ruby_version: !ruby/object:Gem::Requirement
197
197
  requirements:
198
- - - ">="
198
+ - - "~>"
199
199
  - !ruby/object:Gem::Version
200
- version: '3.1'
200
+ version: 3.1.0
201
201
  required_rubygems_version: !ruby/object:Gem::Requirement
202
202
  requirements:
203
203
  - - ">="
204
204
  - !ruby/object:Gem::Version
205
205
  version: '0'
206
206
  requirements: []
207
- rubygems_version: 3.4.22
207
+ rubygems_version: 3.3.7
208
208
  signing_key:
209
209
  specification_version: 4
210
210
  summary: Decidim API module
@@ -1,3 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Empty line for playing nice with tpope/vim-rails