trmnl_preview 0.5.8 → 0.5.10

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: a9fb3cbe39aa3d0e8677b94b1bf224296d09ba045fac80e34b4d7438838a7c9c
4
- data.tar.gz: 290000660480be5eca61e6a100dd9d737460e41daccdc2bbaa1088c330a3968c
3
+ metadata.gz: 1284d072dad9c13fd87baa49b1f98c58983413fd498662e958c5b911186db022
4
+ data.tar.gz: bf31cbce6a209ea388e43893f5a5c2a31eea6ce84543cf9ca4b0aa9bf5292fcf
5
5
  SHA512:
6
- metadata.gz: '078876141ae2f419ae91dc343a2375a0aee31fcb18eb127324d280c0286dfab6b1785f4a79d92a06ed3c4bdece76f8d989d4d92b1dba928c2948b75cb4a374f7'
7
- data.tar.gz: fb0fb7099bdb48ed80568448fa322f202e593d7089f4504546c38c6dade57929a580384a307203225a018abf45a7f1187c577391c64df25cd6a36f6e881a5ff9
6
+ metadata.gz: 242011496ca09a5072ee9adbc97904b7eedadc1871ab0c7c195b634d352d6b8436a40a1316a477bc781e258f11a70768211abd7cc109b2429ac0d187ceb31508
7
+ data.tar.gz: e45fa96ea8020fd09b2710894cb4e3107b86959a2a41ff3c62437ce6ad750c5f8e047bd96e086e398b3108dd5f87e8ae1e8c44ecece3137df271e91e0864979a
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.5.10
4
+
5
+ - Fix interpolation of multi-line polling URLs with custom fields
6
+
7
+ ## 0.5.9
8
+
9
+ - Add `pathname` dependency
10
+
3
11
  ## 0.5.8
4
12
 
5
13
  - Improve Docker commands in `bin/trmnlp` (@jrand0m, @jbarreiros)
@@ -28,7 +28,7 @@ module TRMNLP
28
28
 
29
29
  return [] if urls.nil?
30
30
 
31
- urls.strip.split("\n").map { |url| with_custom_fields(url.strip) }
31
+ with_custom_fields(urls).strip.split("\n")
32
32
  end
33
33
 
34
34
  def polling_url_text = polling_urls.join("\r\n") # for {{ trmnl }}
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module TRMNLP
4
- VERSION = "0.5.8".freeze
4
+ VERSION = "0.5.10".freeze
5
5
  end
@@ -59,6 +59,7 @@ Gem::Specification.new do |spec|
59
59
  spec.add_dependency "thor", "~> 1.3"
60
60
  spec.add_dependency "oj", "~> 3.16.9"
61
61
  spec.add_dependency "tzinfo-data", "~> 1.2025"
62
+ spec.add_dependency "pathname", "~> 0.4"
62
63
 
63
64
  # For more information and examples about making a new gem, check out our
64
65
  # guide at: https://bundler.io/guides/creating_gem.html
data/web/public/index.js CHANGED
@@ -24,7 +24,7 @@ trmnlp.connectLiveRender = function () {
24
24
 
25
25
  trmnlp.setFrameColor = function () {
26
26
  const value = trmnlp.caseSelect.value;
27
- document.querySelector("trmnl-frame").setAttribute("color", value);
27
+ trmnlp.frame.setAttribute("color", value);
28
28
  localStorage.setItem("trmnlp-case", value);
29
29
  };
30
30
 
@@ -36,7 +36,7 @@ trmnlp.setPreviewFormat = function () {
36
36
  };
37
37
 
38
38
  trmnlp.setFrameSrc = function (src) {
39
- document.querySelector(".spinner").style.display = "inline-block";
39
+ trmnlp.spinner.style.display = "inline-block";
40
40
  trmnlp.frame.setSrc(src);
41
41
  };
42
42
 
@@ -46,6 +46,7 @@ document.addEventListener("DOMContentLoaded", function () {
46
46
  trmnlp.caseSelect = document.querySelector(".select-case");
47
47
  trmnlp.formatSelect = document.querySelector(".select-format");
48
48
  trmnlp.userData = document.getElementById("user-data");
49
+ trmnlp.spinner = document.querySelector(".spinner");
49
50
  trmnlp.isLiveReloadEnabled =
50
51
  document.querySelector("meta[name='live-reload']").content === "true";
51
52
 
@@ -67,7 +68,7 @@ document.addEventListener("DOMContentLoaded", function () {
67
68
  });
68
69
 
69
70
  trmnlp.frame._iframe.addEventListener("load", () => {
70
- document.querySelector(".spinner").style.display = "none";
71
+ trmnlp.spinner.style.display = "none";
71
72
 
72
73
  // On page load, trmnl-frame loads "about:blank", so wait for that to load
73
74
  // before updating the src to the preview.
data/web/views/index.erb CHANGED
@@ -35,7 +35,7 @@
35
35
  <select class="select-case">
36
36
  <option value="white">White</option>
37
37
  <option value="black">Black</option>
38
- <option value="mint">Mint</option>
38
+ <option value="mint">Sage</option>
39
39
  <option value="gray">Gray</option>
40
40
  <option value="wood">Wood</option>
41
41
  </select>
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trmnl_preview
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.8
4
+ version: 0.5.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rockwell Schrock
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-08-26 00:00:00.000000000 Z
10
+ date: 2025-11-21 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: sinatra
@@ -233,6 +233,20 @@ dependencies:
233
233
  - - "~>"
234
234
  - !ruby/object:Gem::Version
235
235
  version: '1.2025'
236
+ - !ruby/object:Gem::Dependency
237
+ name: pathname
238
+ requirement: !ruby/object:Gem::Requirement
239
+ requirements:
240
+ - - "~>"
241
+ - !ruby/object:Gem::Version
242
+ version: '0.4'
243
+ type: :runtime
244
+ prerelease: false
245
+ version_requirements: !ruby/object:Gem::Requirement
246
+ requirements:
247
+ - - "~>"
248
+ - !ruby/object:Gem::Version
249
+ version: '0.4'
236
250
  description: Automatically rebuild and preview TRNML plugins in multiple views
237
251
  email:
238
252
  - rockwell@schrock.me