dato-rails 0.10.0 → 0.11.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: 1973ec82f04620deeaf8b94c8b8fe4816c60f5c00cf0ccfba93ab38e938af5fb
4
- data.tar.gz: 1f83767d11f764f199b4bf394da6d216a237d22a37fee001542413f5f183ab61
3
+ metadata.gz: 99e4d154a2bfbaafddf661cf61fdb093eb93e2270809e5628b367500a5a6d382
4
+ data.tar.gz: 9d7a872b53ce27aceb1b9865bff5124642711cf4a757a130b1d592eb1087cf48
5
5
  SHA512:
6
- metadata.gz: 69b37b143b7e6f422c28f3b74677991d876a5bd181e3ebf97e9bc93d31165404bc39c32991cdbf3cd635c640fde730cc564a00c002ff4cf725870ec2703282c4
7
- data.tar.gz: b9f95b4994a61b6801a781ba3369e679a1dbfc012d356a213de48b30bbab8a54ca2282d33a7754368c3b12b594b8b22ec265dc89b4776c083c0086707cf97dea
6
+ metadata.gz: ce096652ef057e9a4f24ef857034b07215be0a797376f2de03e6a66b1a5048d75521da6637c0ff4a0f3b62d33425780cea6c9052a6c6d9f95efa41a1688f93a2
7
+ data.tar.gz: 8a8a0bab330cfe44805f57b51062c83adcff8fc919d3f278c081ad1731d7140fd554159111d229fa0ba4d1139b5ddf3a389ef5d4deff059a64a4524936839f9d
data/README.md CHANGED
@@ -101,7 +101,7 @@ and [live updates](https://www.datocms.com/docs/real-time-updates-api) features
101
101
  ```ruby
102
102
  Dato::Client.new(preview: true) # to fetch draft versions
103
103
 
104
- client = Dato::Client.new(live: true) # => to fetch a live straming URL
104
+ client = Dato::Client.new(live: true) # => to fetch a live straming URL
105
105
  client.live!(your_query)
106
106
  # => { url: 'https://your_event_source_url' }
107
107
  ```
@@ -308,6 +308,17 @@ Completed 200 OK in 365ms (Views: 109.5ms | ActiveRecord: 0.7ms (4 queries, 0 ca
308
308
 
309
309
  this is useful to identify if the bottleneck is in the fetching of the data from Dato CMS.
310
310
 
311
+ ## Styles
312
+ ### Highlighting
313
+
314
+ By default, highlighted text `background-color` is set to `yellow`. This can be changed by setting the css `--dato-highlight-color` variable in your stylesheet:
315
+
316
+ ```css
317
+ :root {
318
+ --dato-highlight-color: red;
319
+ }
320
+ ```
321
+
311
322
  ## Development
312
323
 
313
324
  After checking out the repo, run `bundle install` to install dependencies.
@@ -333,7 +344,7 @@ and push the `.gem` file to [rubygems.org](https://rubygems.org).
333
344
  ## Contributing
334
345
 
335
346
  Bug reports and pull requests are welcome on GitHub at https://github.com/renuo/dato-rails.
336
- This project is intended to be a safe, welcoming space for collaboration.
347
+ This project is intended to be a safe, welcoming space for collaboration.
337
348
 
338
349
  Try to be a decent human being while interacting with other people.
339
350
 
@@ -11,7 +11,7 @@ class Dato::Span < Dato::DastNode
11
11
  mapping = {
12
12
  emphasis: "font-style: italic",
13
13
  strong: "font-weight: bold",
14
- highlight: "background-color: #FFFF00"
14
+ highlight: "background-color: var(--dato-highlight-color, yellow)",
15
15
  }.with_indifferent_access
16
16
 
17
17
  text_decoration_mappings = {
data/lib/dato/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Dato
2
- VERSION = "0.10.0"
2
+ VERSION = "0.11.0"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dato-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alessandro Rodi
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-02-27 00:00:00.000000000 Z
10
+ date: 2025-08-28 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: rspec-rails