metanorma-iso 1.5.5 → 1.5.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/lib/asciidoctor/iso/basicdoc.rng +23 -0
  3. data/lib/asciidoctor/iso/front.rb +9 -15
  4. data/lib/asciidoctor/iso/isodoc.rng +121 -15
  5. data/lib/asciidoctor/iso/isostandard.rng +8 -1
  6. data/lib/asciidoctor/iso/section.rb +0 -7
  7. data/lib/isodoc/iso/html/isodoc.css +16 -4
  8. data/lib/isodoc/iso/html/isodoc.scss +18 -4
  9. data/lib/isodoc/iso/html/style-human.css +1 -1
  10. data/lib/isodoc/iso/html/style-iso.css +1 -1
  11. data/lib/isodoc/iso/iso.amendment.xsl +982 -291
  12. data/lib/isodoc/iso/iso.international-standard.xsl +982 -291
  13. data/lib/isodoc/iso/isosts_convert.rb +31 -0
  14. data/lib/isodoc/iso/xref.rb +7 -11
  15. data/lib/metanorma-iso.rb +1 -0
  16. data/lib/metanorma/iso/processor.rb +4 -1
  17. data/lib/metanorma/iso/version.rb +1 -1
  18. data/metanorma-iso.gemspec +2 -2
  19. data/spec/asciidoctor-iso/amd_spec.rb +7 -39
  20. data/spec/asciidoctor-iso/base_spec.rb +122 -6
  21. data/spec/asciidoctor-iso/cleanup_spec.rb +30 -30
  22. data/spec/asciidoctor-iso/table_spec.rb +111 -111
  23. data/spec/asciidoctor-iso/validate_spec.rb +35 -15
  24. data/spec/assets/xref_error.adoc +7 -0
  25. data/spec/isodoc/amd_spec.rb +32 -23
  26. data/spec/isodoc/blocks_spec.rb +1 -1
  27. data/spec/isodoc/i18n_spec.rb +17 -4
  28. data/spec/isodoc/inline_spec.rb +1 -1
  29. data/spec/isodoc/iso_spec.rb +5 -5
  30. data/spec/isodoc/metadata_spec.rb +2 -16
  31. data/spec/isodoc/postproc_spec.rb +4 -1
  32. data/spec/isodoc/ref_spec.rb +5 -2
  33. data/spec/isodoc/section_spec.rb +2 -2
  34. data/spec/isodoc/table_spec.rb +1 -1
  35. data/spec/isodoc/terms_spec.rb +1 -1
  36. data/spec/isodoc/xref_spec.rb +11 -11
  37. data/spec/metanorma/processor_spec.rb +1 -1
  38. data/spec/spec_helper.rb +5 -1
  39. metadata +8 -6
@@ -0,0 +1,31 @@
1
+ require "isodoc"
2
+ require "mn2sts"
3
+
4
+ module IsoDoc
5
+ module Iso
6
+
7
+ # A {Converter} implementation that generates HTML output, and a document
8
+ # schema encapsulation of the document for validation
9
+ #
10
+ class IsoStsConvert < IsoDoc::XslfoPdfConvert
11
+ def initialize(options)
12
+ @libdir = File.dirname(__FILE__)
13
+ @format = :isosts
14
+ @suffix = "isosts.xml"
15
+ end
16
+
17
+ def convert(input_filename, file = nil, debug = false, output_filename = nil)
18
+ file = File.read(input_filename, encoding: "utf-8") if file.nil?
19
+ docxml, filename, dir = convert_init(file, input_filename, debug)
20
+ /\.xml$/.match(input_filename) or
21
+ input_filename = Tempfile.open([filename, ".xml"], encoding: "utf-8") do |f|
22
+ f.write file
23
+ f.path
24
+ end
25
+ FileUtils.rm_rf dir
26
+ Mn2sts.convert(input_filename, output_filename || "#{filename}.#{@suffix}", iso: true)
27
+ end
28
+ end
29
+ end
30
+ end
31
+
@@ -1,20 +1,16 @@
1
1
  module IsoDoc
2
2
  module Iso
3
3
  class Xref < IsoDoc::Xref
4
- def parse(docxml)
5
- if @klass.amd(docxml)
6
- back_anchor_names(docxml)
7
- note_anchor_names(docxml.xpath(ns("//annex//table | //annex//figure")))
8
- note_anchor_names(docxml.xpath(ns("//annex")))
9
- example_anchor_names(docxml.xpath(ns("//annex")))
10
- list_anchor_names(docxml.xpath(ns("//annex")))
4
+ def initial_anchor_names(d)
5
+ if @klass.amd(d)
6
+ d.xpath(ns("//preface/*")).each { |c| c.element? and preface_names(c) }
7
+ sequential_asset_names(d.xpath(ns("//preface/*")))
8
+ middle_section_asset_names(d)
9
+ termnote_anchor_names(d)
10
+ termexample_anchor_names(d)
11
11
  else
12
12
  super
13
13
  end
14
- end
15
-
16
- def initial_anchor_names(d)
17
- super
18
14
  introduction_names(d.at(ns("//introduction")))
19
15
  end
20
16
 
@@ -5,6 +5,7 @@ require_relative "isodoc/iso/html_convert"
5
5
  require_relative "isodoc/iso/word_convert"
6
6
  require_relative "isodoc/iso/pdf_convert"
7
7
  require_relative "isodoc/iso/sts_convert"
8
+ require_relative "isodoc/iso/isosts_convert"
8
9
  require_relative "isodoc/iso/presentation_xml_convert"
9
10
  require "asciidoctor/extensions"
10
11
 
@@ -25,7 +25,8 @@ module Metanorma
25
25
  html_alt: "alt.html",
26
26
  doc: "doc",
27
27
  pdf: "pdf",
28
- sts: "sts.xml"
28
+ sts: "sts.xml",
29
+ isosts: "iso.sts.xml"
29
30
  )
30
31
  end
31
32
 
@@ -50,6 +51,8 @@ module Metanorma
50
51
  IsoDoc::Iso::PdfConvert.new(options).convert(inname, isodoc_node, nil, outname)
51
52
  when :sts
52
53
  IsoDoc::Iso::StsConvert.new(options).convert(inname, isodoc_node, nil, outname)
54
+ when :isosts
55
+ IsoDoc::Iso::IsoStsConvert.new(options).convert(inname, isodoc_node, nil, outname)
53
56
  when :presentation
54
57
  IsoDoc::Iso::PresentationXMLConvert.new(options).convert(inname, isodoc_node, nil, outname)
55
58
  else
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module ISO
3
- VERSION = "1.5.5".freeze
3
+ VERSION = "1.5.10".freeze
4
4
  end
5
5
  end
@@ -31,10 +31,10 @@ Gem::Specification.new do |spec|
31
31
 
32
32
  spec.add_dependency "ruby-jing"
33
33
  spec.add_dependency "isodoc", "~> 1.2.0"
34
- spec.add_dependency "metanorma-standoc", "~> 1.5.0"
34
+ spec.add_dependency "metanorma-standoc", "~> 1.6.0"
35
35
  spec.add_dependency "tokenizer", "~> 0.3.0"
36
36
  spec.add_dependency "twitter_cldr"
37
- spec.add_dependency "mn2sts", "~> 1.2.0"
37
+ spec.add_dependency "mn2sts", "~> 1.5.0"
38
38
 
39
39
  spec.add_development_dependency "byebug"
40
40
  spec.add_development_dependency "sassc", "2.4.0"
@@ -2,22 +2,6 @@ require "spec_helper"
2
2
  require "fileutils"
3
3
 
4
4
  RSpec.describe Asciidoctor::ISO do
5
- it "validates amendment document against distinct ISO XML schema" do
6
- FileUtils.rm_f "test.err"
7
- Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true)
8
- = Document title
9
- Author
10
- :docfile: test.adoc
11
- :nodoc:
12
- :no-isobib:
13
- :doctype: amendment
14
-
15
- [change=mid-air]
16
- == Para
17
- INPUT
18
- expect(File.read("test.err")).to include 'value of attribute "change" is invalid; must be equal to'
19
- end
20
-
21
5
  it "processes amendment sections" do
22
6
  expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
23
7
  #{AMD_BLANK_HDR}
@@ -147,22 +131,6 @@ end
147
131
  OUTPUT
148
132
  end
149
133
 
150
- it "processes section attributes" do
151
- expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true)))).to be_equivalent_to xmlpp(<<~"OUTPUT")
152
- #{AMD_BLANK_HDR}
153
- [change=delete,locality="clause=introduction,paragraph=4-7",inline-header="true"]
154
- == Clause 1
155
-
156
- INPUT
157
- #{BLANK_HDR.sub(%r{<doctype>article</doctype>}, "<doctype>amendment</doctype>")}
158
- <sections><clause id="_" obligation="normative" change="delete" locality="clause=introduction,paragraph=4-7">
159
- <title>Clause 1</title>
160
- </clause>
161
- </sections>
162
- </iso-standard>
163
- OUTPUT
164
- end
165
-
166
134
  it "processes default metadata, amendment" do
167
135
  expect(xmlpp(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true).sub(%r{<boilerplate>.*</boilerplate>}m, ""))).to be_equivalent_to xmlpp(<<~"OUTPUT")
168
136
  = Document title
@@ -215,7 +183,7 @@ OUTPUT
215
183
  :doctype: amendment
216
184
  :updates-document-type: international-standard
217
185
  INPUT
218
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
186
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
219
187
  <bibdata type='standard'>
220
188
  <title language='en' format='text/plain' type='main'>Introduction — Main Title — Title — Title Part — Mass fraction of
221
189
  extraneous matter, milled rice (nonglutinous), sample dividers and
@@ -330,7 +298,7 @@ Author
330
298
  :updates: ISO 17301-1:2030
331
299
  :amendment-number: 1
332
300
  INPUT
333
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
301
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
334
302
  <bibdata type='standard'>
335
303
  <docidentifier type='ISO'>ISO 17301-1:2030/CD Amd 1</docidentifier>
336
304
  <docidentifier type='iso-with-lang'>ISO 17301-1:2030/CD Amd 1(E)</docidentifier>
@@ -398,7 +366,7 @@ Author
398
366
  :updates: ISO 17301-1:2030
399
367
  :amendment-number: 1
400
368
  INPUT
401
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
369
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
402
370
  <bibdata type='standard'>
403
371
  <docidentifier type='ISO'>ISO 17301-1:2030/DAmd 1</docidentifier>
404
372
  <docidentifier type='iso-with-lang'>ISO 17301-1:2030/DAmd 1(E)</docidentifier>
@@ -465,7 +433,7 @@ Author
465
433
  :updates: ISO 17301-1:2030
466
434
  :amendment-number: 1
467
435
  INPUT
468
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
436
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
469
437
  <bibdata type='standard'>
470
438
  <docidentifier type='ISO'>ISO 17301-1:2030/Amd 1</docidentifier>
471
439
  <docidentifier type='iso-with-lang'>ISO 17301-1:2030/Amd 1(E)</docidentifier>
@@ -533,7 +501,7 @@ Author
533
501
  :updates: ISO 17301-1:2030
534
502
  :corrigendum-number: 3
535
503
  INPUT
536
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
504
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
537
505
  <bibdata type='standard'>
538
506
  <docidentifier type='ISO'>ISO 17301-1:2030/CD Cor.3</docidentifier>
539
507
  <docidentifier type='iso-with-lang'>ISO 17301-1:2030/CD Cor.3(E)</docidentifier>
@@ -601,7 +569,7 @@ Author
601
569
  :updates: ISO 17301-1:2030
602
570
  :corrigendum-number: 3
603
571
  INPUT
604
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
572
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
605
573
  <bibdata type='standard'>
606
574
  <docidentifier type='ISO'>ISO 17301-1:2030/FDCor.3</docidentifier>
607
575
  <docidentifier type='iso-with-lang'>ISO 17301-1:2030/FDCor.3(E)</docidentifier>
@@ -668,7 +636,7 @@ Author
668
636
  :updates: ISO 17301-1:2030
669
637
  :corrigendum-number: 3
670
638
  INPUT
671
- <iso-standard xmlns='https://www.metanorma.org/ns/iso'>
639
+ <iso-standard xmlns='https://www.metanorma.org/ns/iso' type="semantic" version="#{Metanorma::ISO::VERSION}">
672
640
  <bibdata type='standard'>
673
641
  <docidentifier type='ISO'>ISO 17301-1:2030/Cor.3</docidentifier>
674
642
  <docidentifier type='iso-with-lang'>ISO 17301-1:2030/Cor.3(E)</docidentifier>
@@ -91,7 +91,7 @@ RSpec.describe Asciidoctor::ISO do
91
91
  :copyright-year: 2000
92
92
  INPUT
93
93
  <?xml version="1.0" encoding="UTF-8"?>
94
- <iso-standard xmlns="https://www.metanorma.org/ns/iso">
94
+ <iso-standard xmlns="https://www.metanorma.org/ns/iso" type="semantic" version="#{Metanorma::ISO::VERSION}">
95
95
  <bibdata type="standard">
96
96
  <title language="en" format="text/plain" type="main">Introduction — Main Title — Title — Title Part</title>
97
97
  <title language="en" format="text/plain" type="title-intro">Introduction</title>
@@ -173,7 +173,7 @@ RSpec.describe Asciidoctor::ISO do
173
173
 
174
174
 
175
175
  it "processes complex metadata" do
176
- expect(xmlpp(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true).sub(%r{<boilerplate>.*</boilerplate>}m, ""))).to be_equivalent_to xmlpp(<<~'OUTPUT')
176
+ expect(xmlpp(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true).sub(%r{<boilerplate>.*</boilerplate>}m, ""))).to be_equivalent_to xmlpp(<<~"OUTPUT")
177
177
  = Document title
178
178
  Author
179
179
  :docfile: test.adoc
@@ -189,9 +189,15 @@ RSpec.describe Asciidoctor::ISO do
189
189
  :copyright-holder: ISO,IETF
190
190
  :copyright-year: 2001
191
191
  :doctype: technical-report
192
+ :pub-address: 1 Infinity Loop + \
193
+ California
194
+ :pub-phone: 3333333
195
+ :pub-fax: 4444444
196
+ :pub-email: x@example.com
197
+ :pub-uri: http://www.example.com
192
198
  INPUT
193
199
  <?xml version="1.0" encoding="UTF-8"?>
194
- <iso-standard xmlns="https://www.metanorma.org/ns/iso">
200
+ <iso-standard xmlns="https://www.metanorma.org/ns/iso" type="semantic" version="#{Metanorma::ISO::VERSION}">
195
201
  <bibdata type="standard">
196
202
  <docidentifier type="ISO">ISO/IEC/IETF/TR 1000-1-1:2001</docidentifier>
197
203
  <docidentifier type='iso-with-lang'>ISO/IEC/IETF/TR 1000-1-1:2001(X)</docidentifier>
@@ -280,6 +286,116 @@ RSpec.describe Asciidoctor::ISO do
280
286
  OUTPUT
281
287
  end
282
288
 
289
+ it "processes subdivisions" do
290
+ expect(xmlpp(strip_guid(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true).sub(%r{<boilerplate>.*</boilerplate>}m, "")))).to be_equivalent_to xmlpp(<<~"OUTPUT")
291
+ = Document title
292
+ Author
293
+ :docfile: test.adoc
294
+ :nodoc:
295
+ :novalid:
296
+ :revdate: 2000-01
297
+ :published-date: 1000-01
298
+ :docnumber: 1000
299
+ :partnumber: 1-1
300
+ :tc-docnumber: 2000
301
+ :language: el
302
+ :script: Grek
303
+ :subdivision: Subdivision
304
+ :subdivision-abbr: SD
305
+ :doctype: This is a DocType
306
+ :pub-address: 1 Infinity Loop + \\
307
+ California
308
+ :pub-phone: 3333333
309
+ :pub-fax: 4444444
310
+ :pub-email: x@example.com
311
+ :pub-uri: http://www.example.com
312
+
313
+ INPUT
314
+ <iso-standard xmlns="https://www.metanorma.org/ns/iso" type="semantic" version="#{Metanorma::ISO::VERSION}">
315
+ <bibdata type='standard'>
316
+ <docidentifier type='ISO'>SD 1000-1-1</docidentifier>
317
+ <docidentifier type='iso-with-lang'>SD 1000-1-1(X)</docidentifier>
318
+ <docidentifier type='iso-reference'>SD 1000-1-1(X)</docidentifier>
319
+ <docidentifier type='iso-tc'>2000</docidentifier>
320
+ <docnumber>1000</docnumber>
321
+ <date type='published'>
322
+ <on>1000-01</on>
323
+ </date>
324
+ <contributor>
325
+ <role type='author'/>
326
+ <organization>
327
+ <name>International Organization for Standardization</name>
328
+ <subdivision>Subdivision</subdivision>
329
+ <abbreviation>SD</abbreviation>
330
+ <address>
331
+ <formattedAddress>1 Infinity Loop <br/>California</formattedAddress>
332
+ </address>
333
+ <phone>3333333</phone>
334
+ <phone type='fax'>4444444</phone>
335
+ <email>x@example.com</email>
336
+ <uri>http://www.example.com</uri>
337
+ </organization>
338
+ </contributor>
339
+ <contributor>
340
+ <role type='publisher'/>
341
+ <organization>
342
+ <name>International Organization for Standardization</name>
343
+ <subdivision>Subdivision</subdivision>
344
+ <abbreviation>SD</abbreviation>
345
+ <address>
346
+ <formattedAddress>1 Infinity Loop <br/>California</formattedAddress>
347
+ </address>
348
+ <phone>3333333</phone>
349
+ <phone type='fax'>4444444</phone>
350
+ <email>x@example.com</email>
351
+ <uri>http://www.example.com</uri>
352
+ </organization>
353
+ </contributor>
354
+ <version>
355
+ <revision-date>2000-01</revision-date>
356
+ </version>
357
+ <language>el</language>
358
+ <script>Grek</script>
359
+ <status>
360
+ <stage abbreviation='IS'>60</stage>
361
+ <substage>60</substage>
362
+ </status>
363
+ <copyright>
364
+ <from>2020</from>
365
+ <owner>
366
+ <organization>
367
+ <name>International Organization for Standardization</name>
368
+ <subdivision>Subdivision</subdivision>
369
+ <abbreviation>SD</abbreviation>
370
+ <address>
371
+ <formattedAddress>1 Infinity Loop <br/>California</formattedAddress>
372
+ </address>
373
+ <phone>3333333</phone>
374
+ <phone type='fax'>4444444</phone>
375
+ <email>x@example.com</email>
376
+ <uri>http://www.example.com</uri>
377
+ </organization>
378
+ </owner>
379
+ </copyright>
380
+ <ext>
381
+ <doctype>this-is-a-doctype</doctype>
382
+ <editorialgroup>
383
+ <technical-committee/>
384
+ <subcommittee/>
385
+ <workgroup/>
386
+ </editorialgroup>
387
+ <structuredidentifier>
388
+ <project-number part='1' subpart='1'>SD 1000</project-number>
389
+ </structuredidentifier>
390
+ <stagename>International standard</stagename>
391
+ </ext>
392
+ </bibdata>
393
+ <sections> </sections>
394
+ </iso-standard>
395
+
396
+ OUTPUT
397
+ end
398
+
283
399
  it "defaults substage, defines iteration on stage 50, gives stage 50 on technical specification" do
284
400
  expect(xmlpp(Asciidoctor.convert(<<~"INPUT", backend: :iso, header_footer: true).sub(%r{<boilerplate>.*</boilerplate>}m, ""))).to be_equivalent_to xmlpp(<<~"OUTPUT")
285
401
  = Document title
@@ -294,7 +410,7 @@ RSpec.describe Asciidoctor::ISO do
294
410
  :doctype: technical-specification
295
411
  :iteration: 2
296
412
  INPUT
297
- <iso-standard xmlns="https://www.metanorma.org/ns/iso">
413
+ <iso-standard xmlns="https://www.metanorma.org/ns/iso" type="semantic" version="#{Metanorma::ISO::VERSION}">
298
414
  <bibdata type="standard">
299
415
  <docidentifier type="ISO">ISO/DTS 1000.2</docidentifier>
300
416
  <docidentifier type='iso-with-lang'>ISO/DTS 1000.2(F)</docidentifier>
@@ -360,7 +476,7 @@ OUTPUT
360
476
  :docnumber: 1000
361
477
  :docstage: 60
362
478
  INPUT
363
- <iso-standard xmlns="https://www.metanorma.org/ns/iso">
479
+ <iso-standard xmlns="https://www.metanorma.org/ns/iso" type="semantic" version="#{Metanorma::ISO::VERSION}">
364
480
  <bibdata type="standard">
365
481
  <docidentifier type="ISO">ISO 1000</docidentifier>
366
482
  <docidentifier type='iso-with-lang'>ISO 1000(E)</docidentifier>
@@ -426,7 +542,7 @@ OUTPUT
426
542
  :docstage: 60
427
543
  :docsubstage: 00
428
544
  INPUT
429
- <iso-standard xmlns="https://www.metanorma.org/ns/iso">
545
+ <iso-standard xmlns="https://www.metanorma.org/ns/iso" type="semantic" version="#{Metanorma::ISO::VERSION}">
430
546
  <bibdata type="standard">
431
547
  <docidentifier type="ISO">ISO 1000</docidentifier>
432
548
  <docidentifier type='iso-with-lang'>ISO 1000(E)</docidentifier>
@@ -425,9 +425,9 @@ RSpec.describe Asciidoctor::ISO do
425
425
  <sections><table id="_">
426
426
  <tbody>
427
427
  <tr>
428
- <td align="left">a</td>
429
- <td align="left">b</td>
430
- <td align="left">c</td>
428
+ <td valign="top" align="left">a</td>
429
+ <td valign="top" align="left">b</td>
430
+ <td valign="top" align="left">c</td>
431
431
  </tr>
432
432
  </tbody>
433
433
  <dl id="_">
@@ -456,23 +456,23 @@ RSpec.describe Asciidoctor::ISO do
456
456
  #{BLANK_HDR}
457
457
  <sections>
458
458
  <table id="_"><thead><tr>
459
- <th align="left">a</th>
460
- <th align="left">b</th>
461
- <th align="left">c</th>
459
+ <th valign="top" align="left">a</th>
460
+ <th valign="top" align="left">b</th>
461
+ <th valign="top" align="left">c</th>
462
462
  </tr><tr>
463
- <th align="left">a</th>
464
- <th align="left">b</th>
465
- <th align="left">c</th>
463
+ <th valign="top" align="left">a</th>
464
+ <th valign="top" align="left">b</th>
465
+ <th valign="top" align="left">c</th>
466
466
  </tr><tr>
467
- <th align="left">a</th>
468
- <th align="left">b</th>
469
- <th align="left">c</th>
467
+ <th valign="top" align="left">a</th>
468
+ <th valign="top" align="left">b</th>
469
+ <th valign="top" align="left">c</th>
470
470
  </tr></thead>
471
471
  <tbody>
472
472
  <tr>
473
- <td align="left">a</td>
474
- <td align="left">b</td>
475
- <td align="left">c</td>
473
+ <td valign="top" align="left">a</td>
474
+ <td valign="top" align="left">b</td>
475
+ <td valign="top" align="left">c</td>
476
476
  </tr>
477
477
  </tbody>
478
478
  </table>
@@ -498,26 +498,26 @@ RSpec.describe Asciidoctor::ISO do
498
498
  <table id="_">
499
499
  <thead>
500
500
  <tr>
501
- <th align="left">a</th>
502
- <th align="left">b</th>
503
- <th align="left">c</th>
501
+ <th valign="top" align="left">a</th>
502
+ <th valign="top" align="left">b</th>
503
+ <th valign="top" align="left">c</th>
504
504
  </tr>
505
505
  <tr>
506
- <th align="left">a</th>
507
- <th align="left">b</th>
508
- <th align="left">c</th>
506
+ <th valign="top" align="left">a</th>
507
+ <th valign="top" align="left">b</th>
508
+ <th valign="top" align="left">c</th>
509
509
  </tr><tr>
510
- <th align="left">a</th>
511
- <th align="left">b</th>
512
- <th align="left">c</th>
510
+ <th valign="top" align="left">a</th>
511
+ <th valign="top" align="left">b</th>
512
+ <th valign="top" align="left">c</th>
513
513
  </tr></thead>
514
514
  <tbody>
515
515
 
516
516
 
517
517
  <tr>
518
- <td align="left">a</td>
519
- <td align="left">b</td>
520
- <td align="left">c</td>
518
+ <td valign="top" align="left">a</td>
519
+ <td valign="top" align="left">b</td>
520
+ <td valign="top" align="left">c</td>
521
521
  </tr>
522
522
  </tbody>
523
523
  </table>
@@ -541,9 +541,9 @@ RSpec.describe Asciidoctor::ISO do
541
541
  <sections><table id="_">
542
542
  <tbody>
543
543
  <tr>
544
- <td align="left">a</td>
545
- <td align="left">b</td>
546
- <td align="left">c</td>
544
+ <td valign="top" align="left">a</td>
545
+ <td valign="top" align="left">b</td>
546
+ <td valign="top" align="left">c</td>
547
547
  </tr>
548
548
  </tbody>
549
549
  <note id="_">