repltalk 4.0.0 → 4.0.1
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 +4 -4
- data/lib/repltalk.rb +1 -1
- data/lib/repltalk/client.rb +3 -2
- data/lib/repltalk/graphql.rb +7 -5
- data/lib/repltalk/structures.rb +2 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ca32c6abe912a479dc7c61817f187201159673fbb1552709ba6ea2430d6eaa9c
|
4
|
+
data.tar.gz: 52227cb7b963b6c1a1f5398ce8352dd223c70dd1a0e089bf6f175fbe253fa6cb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2c02a0b643517276ecb60d843345dae996855ff0b726f576a824000b1cc21d16fb0d6522d56d87839c12730a488aa616dc1617bdee703d0a524d1b3f4d306abb
|
7
|
+
data.tar.gz: 98ada7dd72a0646fe6b4312a18b33ad71c36b45cc14f0e0c9bf13759d5cf0da079aa939481b8410c5aca599edc7fe07183aebbca90b26e9b643960a8a4b75119
|
data/lib/repltalk.rb
CHANGED
data/lib/repltalk/client.rb
CHANGED
@@ -154,10 +154,11 @@ module ReplTalk
|
|
154
154
|
r["featuredRepls"].map { |repl| Repl.new(self, repl) }
|
155
155
|
end
|
156
156
|
|
157
|
-
def get_trending_tags
|
157
|
+
def get_trending_tags(count: nil)
|
158
158
|
t = graphql(
|
159
159
|
"ExploreFeed",
|
160
|
-
GQL::Queries::GET_TRENDING_TAGS
|
160
|
+
GQL::Queries::GET_TRENDING_TAGS,
|
161
|
+
count: count
|
161
162
|
)
|
162
163
|
t["trendingTagsFeed"]["initialTags"].map { |tag| Tag.new(self, tag) }
|
163
164
|
end
|
data/lib/repltalk/graphql.rb
CHANGED
@@ -380,17 +380,19 @@ module ReplTalk
|
|
380
380
|
"
|
381
381
|
|
382
382
|
GET_TRENDING_TAGS = "
|
383
|
-
query
|
384
|
-
|
385
|
-
|
383
|
+
query ExploreFeed($count: Int) {
|
384
|
+
trendingTagsFeed(initialTagsCount: $count) {
|
385
|
+
initialTags {
|
386
|
+
#{Fields::TAG}
|
387
|
+
}
|
386
388
|
}
|
387
389
|
}
|
388
390
|
"
|
389
391
|
|
390
392
|
GET_TAGS_REPLS = "
|
391
|
-
query ExploreTrendingRepls($tag: String!, $after: String) {
|
393
|
+
query ExploreTrendingRepls($tag: String!, $count: Int, $after: String) {
|
392
394
|
tag(id: $tag) {
|
393
|
-
repls(after: $after) {
|
395
|
+
repls(limit: $count, after: $after) {
|
394
396
|
items {
|
395
397
|
#{Fields::REPL}
|
396
398
|
}
|
data/lib/repltalk/structures.rb
CHANGED
@@ -87,11 +87,12 @@ module ReplTalk
|
|
87
87
|
@repls_tagged_today_count = tag["replsTaggedTodayCount"]
|
88
88
|
end
|
89
89
|
|
90
|
-
def get_repls(after: nil)
|
90
|
+
def get_repls(count: nil, after: nil)
|
91
91
|
r = @client.graphql(
|
92
92
|
"ExploreTrendingRepls",
|
93
93
|
GQL::Queries::GET_TAGS_REPLS,
|
94
94
|
tag: @id,
|
95
|
+
count: count,
|
95
96
|
after: after
|
96
97
|
)
|
97
98
|
r["tag"]["repls"]["items"].map { |repl| Repl.new(@client, repl) }
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: repltalk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.0.
|
4
|
+
version: 4.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- CodingCactus
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-05-
|
11
|
+
date: 2021-05-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: http
|