metanorma-plugin-glossarist 0.2.2 → 0.2.3

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: 891bcd6d1ffd87c66fd4d6901e26dde46ee52b93a8feee0e04b4f6f5e0a8d588
4
- data.tar.gz: 7cf700c07b974e0b4e17bb02117cfaf38cc6d1b0d7b6fc578025da3faa497412
3
+ metadata.gz: daa2bea1e77bfd5f4bf2ec230949e1b553f977df76078f98cad24d24b471cd2c
4
+ data.tar.gz: 4f2387682fcca5c77a82a377ce7f739632adfa92656c289a69cd6b5e7e947724
5
5
  SHA512:
6
- metadata.gz: a78d34c2063ca08e785f99e2ddcddd93321ea78f9243d1fa537d80dbbbf4aee56639b5739c5ef04e495717a7752d53a43ae4ca530938ef037d8aeec2b9eb4876
7
- data.tar.gz: f7f93f41b8883f7648b079f157b2085c5a0300e36b6962a4f08a2fb3a00f4acf8c82c7cadcefe50e7605fa05a10560ad4e4e33986f7ccf35a356231afa65c203
6
+ metadata.gz: 2106de661a748c6f9026889236f3e6b53bc5cb1cbbad24ef0870210173f09ae0ba730afe2469bb7d55b57845ee5693efdee68c14efec608ae3c45961bcaac27b
7
+ data.tar.gz: c1280bae939146a0bda8c7c1904c9187dd1e922e9087cc14b5b1cd7b5a7fe43bc8b47fb5e87a921b1637f635a023de83824bc0896339b760efdc5fa4ed10c293
@@ -8,24 +8,20 @@ module Liquid
8
8
  # rubocop:disable Lint/MissingSuper
9
9
  def initialize(managed_concept_collection, filters = {})
10
10
  @concepts_collection = managed_concept_collection
11
- @concepts_map = {}
12
-
13
- filtered_concepts(@concepts_collection, filters).each do |concept|
14
- @concepts_map[concept["term"]] = concept
15
- end
11
+ @concepts = filtered_concepts(@concepts_collection, filters)
16
12
  end
17
13
  # rubocop:enable Lint/MissingSuper
18
14
 
19
15
  def concepts
20
- @concepts_map
16
+ @concepts
21
17
  end
22
18
 
23
19
  def [](concept_name)
24
- @concepts_map[concept_name]
20
+ @concepts.find { |c| c["term"] == concept_name }
25
21
  end
26
22
 
27
23
  def each(&block)
28
- @concepts_map.values.each(&block)
24
+ @concepts.each(&block)
29
25
  end
30
26
 
31
27
  private
@@ -200,7 +200,7 @@ module Metanorma
200
200
  dataset = @datasets[dataset_name]
201
201
 
202
202
  liquid_doc.add_content(
203
- dataset.concepts.map do |_concept_name, concept|
203
+ dataset.concepts.map do |concept|
204
204
  concept_bibliography(concept)
205
205
  end.compact.sort.join("\n"),
206
206
  )
@@ -1,7 +1,7 @@
1
1
  module Metanorma
2
2
  module Plugin
3
3
  module Glossarist
4
- VERSION = "0.2.2".freeze
4
+ VERSION = "0.2.3".freeze
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-plugin-glossarist
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-11-18 00:00:00.000000000 Z
11
+ date: 2024-11-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: asciidoctor