nokodiff 1.0.0 → 1.1.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9b38060ba01f5d6e38c752d5b3736072cfb7ddb867b3f9ab85292ef731946695
4
- data.tar.gz: 333e94464a25ee00c03c00c54210ef1a5c07f52804d1e8299a84cd20338c5a22
3
+ metadata.gz: 856dc58d68b66f6af795512bb66066cc50c10a7a11efc6b20b138f656cf50c1b
4
+ data.tar.gz: d7d345134c3e9d588a71873ffbc680b2e4ba67e0d1c9f76ba34a98050ace98cb
5
5
  SHA512:
6
- metadata.gz: e1fd5d24c4c18f1d61b3f12afe10a1358a15b5504c2dd6ce1d28baadc37d156826b2dc45c309722c933691f4ae2f1a4e019dbdc4396dfece72e590772fbf5084
7
- data.tar.gz: f962ce7effdf2bb103fe28c07c936fd8694e6edbb4e72059d0c46671887513bfcaf2d6ee31109446014dc7841332e34ba255b263c3712280e5cb75eaf711d401
6
+ metadata.gz: ee93167f9ed499b49fccd29048e9544ca0daa306ee7fd7d9bf00ce6a28603ab4a93620148cf31d1ffb3de83cc8ce3ba8f8d2621b00727f182735e5fe8d5a576c
7
+ data.tar.gz: 50e10242d8a451712ad138add211346d278f967a6ea1e0e8e4c4277481c71689462cd1e55891157bf0b91b8d47fc7fa855c9faf11aef6bbaaab798fdf193bf69
@@ -357,8 +357,16 @@ $comparison-sidebar-offset: $comparison-sidebar-width + $comparison-sidebar-padd
357
357
  ol.steps {
358
358
  @extend .steps;
359
359
 
360
- &:has(>span.diff) {
360
+ &:has(>span.diff.del) {
361
361
  @include diff-block;
362
+
363
+ background: $removed-color;
364
+ }
365
+
366
+ &:has(>span.diff.ins) {
367
+ @include diff-block;
368
+
369
+ background: $added-color;
362
370
  }
363
371
 
364
372
  margin-left: -$comparison-sidebar-padding;
@@ -417,9 +425,9 @@ $comparison-sidebar-offset: $comparison-sidebar-width + $comparison-sidebar-padd
417
425
  overflow-x: visible;
418
426
  }
419
427
 
420
- // This element is generated before new tables
421
- // We need to remove it from the display and
422
- // style the table that follows it as a new element
428
+ // These elements are generated before new and removed dtables
429
+ // We need to remove them from the display and
430
+ // style the tables that follows them as a new/removed element
423
431
  & > span.diff.ins {
424
432
  display: none;
425
433
 
@@ -438,8 +446,11 @@ $comparison-sidebar-offset: $comparison-sidebar-width + $comparison-sidebar-padd
438
446
  & + table {
439
447
  @include diff-block;
440
448
 
449
+ background: $removed-color;
450
+
441
451
  &:before {
442
452
  content: "−";
453
+ background: $removed-color;
443
454
  }
444
455
  }
445
456
  }
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Nokodiff
4
- VERSION = "1.0.0"
4
+ VERSION = "1.1.0"
5
5
  end
data/lib/nokodiff.rb CHANGED
@@ -2,7 +2,6 @@
2
2
 
3
3
  require "nokogiri"
4
4
  require "diff-lcs"
5
- require "byebug"
6
5
 
7
6
  require_relative "nokodiff/formatting_helpers"
8
7
  require_relative "nokodiff/version"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nokodiff
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GOV.UK Dev
@@ -156,7 +156,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
156
156
  - !ruby/object:Gem::Version
157
157
  version: '0'
158
158
  requirements: []
159
- rubygems_version: 4.0.21
159
+ rubygems_version: 4.0.22
160
160
  specification_version: 4
161
161
  summary: A Ruby Gem to highlight additions, deletions and character level changes
162
162
  while preserving original HTML