mml 2.4.3 → 2.4.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.
Files changed (46) hide show
  1. checksums.yaml +4 -4
  2. data/lib/mml/base/content/annotation.rb +2 -0
  3. data/lib/mml/base/content/annotation_xml.rb +2 -0
  4. data/lib/mml/base/content/apply.rb +2 -0
  5. data/lib/mml/base/content/arith.rb +2 -0
  6. data/lib/mml/base/content/bind.rb +2 -0
  7. data/lib/mml/base/content/bvar.rb +2 -0
  8. data/lib/mml/base/content/calculus.rb +2 -0
  9. data/lib/mml/base/content/cbytes.rb +2 -0
  10. data/lib/mml/base/content/cerror.rb +2 -0
  11. data/lib/mml/base/content/ci.rb +2 -0
  12. data/lib/mml/base/content/cn.rb +2 -0
  13. data/lib/mml/base/content/condition.rb +2 -0
  14. data/lib/mml/base/content/constants.rb +2 -0
  15. data/lib/mml/base/content/cs.rb +2 -0
  16. data/lib/mml/base/content/csymbol.rb +2 -0
  17. data/lib/mml/base/content/declare.rb +2 -0
  18. data/lib/mml/base/content/degree.rb +2 -0
  19. data/lib/mml/base/content/elementary_functions.rb +2 -0
  20. data/lib/mml/base/content/fn.rb +2 -0
  21. data/lib/mml/base/content/functions.rb +2 -0
  22. data/lib/mml/base/content/interval.rb +2 -0
  23. data/lib/mml/base/content/inverse.rb +2 -0
  24. data/lib/mml/base/content/lambda.rb +2 -0
  25. data/lib/mml/base/content/linear_algebra.rb +2 -0
  26. data/lib/mml/base/content/logic.rb +2 -0
  27. data/lib/mml/base/content/otherwise.rb +2 -0
  28. data/lib/mml/base/content/piece.rb +2 -0
  29. data/lib/mml/base/content/piecewise.rb +2 -0
  30. data/lib/mml/base/content/relations.rb +2 -0
  31. data/lib/mml/base/content/reln.rb +2 -0
  32. data/lib/mml/base/content/semantics.rb +2 -0
  33. data/lib/mml/base/content/sep.rb +2 -0
  34. data/lib/mml/base/content/sets.rb +2 -0
  35. data/lib/mml/base/content/share.rb +2 -0
  36. data/lib/mml/base/content/statistics.rb +2 -0
  37. data/lib/mml/base/content/vector_calculus.rb +2 -0
  38. data/lib/mml/base/content/wildcard_attributes.rb +23 -0
  39. data/lib/mml/base/content_loader.rb +1 -0
  40. data/lib/mml/base/universal_presentation_attributes.rb +2 -0
  41. data/lib/mml/opal.rb +1 -2
  42. data/lib/mml/version.rb +1 -1
  43. data/mml.gemspec +1 -1
  44. metadata +5 -6
  45. data/lib/mml/v3/version.rb +0 -7
  46. data/lib/mml/v4/version.rb +0 -7
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f2ceed2663265e233553c9545d55aba20fd2c3d6b35e6ee3b7fdd2649d9ea779
4
- data.tar.gz: 9c2e6fe91813bf181b968be1f2470f03c93e88dbadd0755da50d782066777b10
3
+ metadata.gz: 49c3264f3a2f8ecd700bad9a27411c3f886e56050a964aaad276ac3b14f5aa01
4
+ data.tar.gz: 2394ab9334de9de7382de20293d9bab3bf917a1df3f9afde4e97655c8586bb4c
5
5
  SHA512:
6
- metadata.gz: 887114641a9b57f242302c3d75bd40bb6911d41d427d3afa5d09505dcb73cc06c061c3e56c48df4d3507eb7cf8edca0dae59b5f32d91b3b46af00de14029c60f
7
- data.tar.gz: d01b619568ccc20403c313aa44f1c2c97461fdc3d014f21189ce28d138659b7d6f56eb7fd81127a37ea6648503df4dad65213380487290ed1d900d4e890b967c
6
+ metadata.gz: 29ccb1fd1b8e5f82b8b1bf9715ec7fe1d5293a6adbff69866d474f2bc31a651008579e2b5f2af2cd377f227d3a629312e01795bbb0ddc90e11f216ad2e438335
7
+ data.tar.gz: ce7c2833c7d9a17ad822625c391de16f524470b56d3092d5f8427e5327fee9849b13c81d4a7ea6ad1ade876d0eba35967e56017a81b06c4f4b4d4e01beb12633
@@ -8,6 +8,8 @@ module Mml
8
8
  module Annotation
9
9
  def self.included(klass)
10
10
  klass.class_eval do
11
+ include WildcardAttributes
12
+
11
13
  attribute :definition_url, :string
12
14
  attribute :encoding_value, :string
13
15
  attribute :value, :string
@@ -8,6 +8,8 @@ module Mml
8
8
  module AnnotationXml
9
9
  def self.included(klass)
10
10
  klass.class_eval do
11
+ include WildcardAttributes
12
+
11
13
  attribute :definitionURL, :string
12
14
  attribute :annotation_xml_encoding, :string
13
15
  attribute :cd, :string
@@ -8,6 +8,8 @@ module Mml
8
8
  module Apply
9
9
  def self.included(klass)
10
10
  klass.class_eval do
11
+ include WildcardAttributes
12
+
11
13
  attribute :definition_url, :string
12
14
  attribute :encoding_value, :string
13
15
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Arith
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -8,6 +8,8 @@ module Mml
8
8
  module Bind
9
9
  def self.included(klass)
10
10
  klass.class_eval do
11
+ include WildcardAttributes
12
+
11
13
  attribute :definition_url, :string
12
14
  attribute :encoding_value, :string
13
15
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Bvar
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "bvar"
@@ -7,6 +7,8 @@ module Mml
7
7
  module Calculus
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -6,6 +6,8 @@ module Mml
6
6
  module Cbytes
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  attribute :encoding_value, :string
10
12
  attribute :value, :string
11
13
 
@@ -8,6 +8,8 @@ module Mml
8
8
  module Cerror
9
9
  def self.included(klass)
10
10
  klass.class_eval do
11
+ include WildcardAttributes
12
+
11
13
  attribute :csymbol_value, :csymbol, collection: true
12
14
 
13
15
  xml do
@@ -6,6 +6,8 @@ module Mml
6
6
  module Ci
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  attribute :type, :string
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
@@ -6,6 +6,8 @@ module Mml
6
6
  module Cn
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  attribute :type, :string
10
12
  attribute :definition_url, :string
11
13
  attribute :enc, :string
@@ -7,6 +7,8 @@ module Mml
7
7
  module Condition
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "condition"
@@ -7,6 +7,8 @@ module Mml
7
7
  module Constant
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -6,6 +6,8 @@ module Mml
6
6
  module Cs
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  attribute :value, :string
10
12
 
11
13
  xml do
@@ -6,6 +6,8 @@ module Mml
6
6
  module Csymbol
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  attribute :type, :string
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
@@ -7,6 +7,8 @@ module Mml
7
7
  module Declare
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
  attribute :type, :string
@@ -7,6 +7,8 @@ module Mml
7
7
  module Degree
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "degree"
@@ -7,6 +7,8 @@ module Mml
7
7
  module ElementaryFunctions
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -6,6 +6,8 @@ module Mml
6
6
  module Fn
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  attribute :definition_url, :string
10
12
  attribute :encoding_value, :string
11
13
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Functions
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Interval
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :closure, :string
11
13
 
12
14
  xml do
@@ -7,6 +7,8 @@ module Mml
7
7
  module Inverse
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Lambda
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "lambda"
@@ -7,6 +7,8 @@ module Mml
7
7
  module LinearAlgebra
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Logic
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Otherwise
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "otherwise"
@@ -7,6 +7,8 @@ module Mml
7
7
  module Piece
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "piece"
@@ -7,6 +7,8 @@ module Mml
7
7
  module Piecewise
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "piecewise"
@@ -7,6 +7,8 @@ module Mml
7
7
  module Relation
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -6,6 +6,8 @@ module Mml
6
6
  module Reln
7
7
  def self.included(klass)
8
8
  klass.class_eval do
9
+ include WildcardAttributes
10
+
9
11
  xml do
10
12
  namespace Mml::Namespace
11
13
  element "reln"
@@ -8,6 +8,8 @@ module Mml
8
8
  module Semantics
9
9
  def self.included(klass)
10
10
  klass.class_eval do
11
+ include WildcardAttributes
12
+
11
13
  attribute :definition_url, :string
12
14
  attribute :semantics_encoding, :string
13
15
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Sep
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  xml do
11
13
  namespace Mml::Namespace
12
14
  element "sep"
@@ -7,6 +7,8 @@ module Mml
7
7
  module Sets
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module Share
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :src, :string
11
13
 
12
14
  xml do
@@ -7,6 +7,8 @@ module Mml
7
7
  module Statistics
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -7,6 +7,8 @@ module Mml
7
7
  module VectorCalculus
8
8
  def self.included(klass)
9
9
  klass.class_eval do
10
+ include WildcardAttributes
11
+
10
12
  attribute :definition_url, :string
11
13
  attribute :encoding_value, :string
12
14
 
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Mml
4
+ module Base
5
+ module Content
6
+ # MathML 4 wildcard attributes on content elements: every attribute
7
+ # not explicitly mapped (data-*, on*, aria-*, ...) is captured into
8
+ # `other_attributes` and emitted back on serialize (plurimath/mml#23).
9
+ module WildcardAttributes
10
+ def self.included(klass)
11
+ klass.class_eval do
12
+ attribute :other_attributes, :hash
13
+
14
+ xml do
15
+ namespace Mml::Namespace
16
+ map_all_attributes to: :other_attributes
17
+ end
18
+ end
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -4,6 +4,7 @@ module Mml
4
4
  module Base
5
5
  # Content MathML elements autoloader
6
6
  module Content
7
+ autoload :WildcardAttributes, "#{__dir__}/content/wildcard_attributes"
7
8
  autoload :Cn, "#{__dir__}/content/cn"
8
9
  autoload :Ci, "#{__dir__}/content/ci"
9
10
  autoload :Csymbol, "#{__dir__}/content/csymbol"
@@ -33,11 +33,13 @@ module Mml
33
33
  klass.class_eval do
34
34
  attribute :intent, :string
35
35
  attribute :arg, :string
36
+ attribute :other_attributes, :hash
36
37
 
37
38
  xml do
38
39
  namespace Mml::Namespace
39
40
  map_attribute "intent", to: :intent
40
41
  map_attribute "arg", to: :arg
42
+ map_all_attributes to: :other_attributes
41
43
  end
42
44
  end
43
45
  end
data/lib/mml/opal.rb CHANGED
@@ -43,6 +43,7 @@ require "mml/base/v3_only/table_attrs"
43
43
 
44
44
  # Base content loader + content modules
45
45
  require "mml/base/content_loader"
46
+ require "mml/base/content/wildcard_attributes"
46
47
  require "mml/base/content/annotation"
47
48
  require "mml/base/content/annotation_xml"
48
49
  require "mml/base/content/apply"
@@ -280,7 +281,6 @@ require "mml/v3/semantics"
280
281
  require "mml/v3/sets"
281
282
  require "mml/v3/statistics"
282
283
  require "mml/v3/vector_calculus"
283
- require "mml/v3/version"
284
284
 
285
285
  # v3 module (already autoloaded above)
286
286
  require "mml/v3"
@@ -360,7 +360,6 @@ require "mml/v4/sets"
360
360
  require "mml/v4/statistics"
361
361
  require "mml/v4/tendsto"
362
362
  require "mml/v4/vector_calculus"
363
- require "mml/v4/version"
364
363
 
365
364
  # v4 module (already autoloaded above)
366
365
  require "mml/v4"
data/lib/mml/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Mml
4
- VERSION = "2.4.3"
4
+ VERSION = "2.4.5"
5
5
  end
data/mml.gemspec CHANGED
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
29
29
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
30
30
  spec.require_paths = ["lib"]
31
31
 
32
- spec.add_dependency "lutaml-model", "~> 0.8.65"
32
+ spec.add_dependency "lutaml-model", "~> 0.8.138"
33
33
  spec.add_dependency "moxml"
34
34
  spec.metadata["rubygems_mfa_required"] = "true"
35
35
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mml
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.4.3
4
+ version: 2.4.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-10-09 00:00:00.000000000 Z
11
+ date: 2026-10-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: lutaml-model
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.8.65
19
+ version: 0.8.138
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.8.65
26
+ version: 0.8.138
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: moxml
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -113,6 +113,7 @@ files:
113
113
  - lib/mml/base/content/share.rb
114
114
  - lib/mml/base/content/statistics.rb
115
115
  - lib/mml/base/content/vector_calculus.rb
116
+ - lib/mml/base/content/wildcard_attributes.rb
116
117
  - lib/mml/base/content_loader.rb
117
118
  - lib/mml/base/deprecated_font_attributes.rb
118
119
  - lib/mml/base/maction.rb
@@ -319,7 +320,6 @@ files:
319
320
  - lib/mml/v3/sets.rb
320
321
  - lib/mml/v3/statistics.rb
321
322
  - lib/mml/v3/vector_calculus.rb
322
- - lib/mml/v3/version.rb
323
323
  - lib/mml/v4.rb
324
324
  - lib/mml/v4/a.rb
325
325
  - lib/mml/v4/annotation.rb
@@ -394,7 +394,6 @@ files:
394
394
  - lib/mml/v4/statistics.rb
395
395
  - lib/mml/v4/tendsto.rb
396
396
  - lib/mml/v4/vector_calculus.rb
397
- - lib/mml/v4/version.rb
398
397
  - lib/mml/version.rb
399
398
  - lib/mml/versioned_parser.rb
400
399
  - mml.gemspec
@@ -1,7 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Mml
4
- module V3
5
- VERSION = "2.1.0"
6
- end
7
- end
@@ -1,7 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Mml
4
- module V4
5
- VERSION = "2.1.0"
6
- end
7
- end