From 7c9c407f5915707dd46d53077e4515d9791fd5dd Mon Sep 17 00:00:00 2001 From: Daniel Asher Resnick Date: Wed, 12 Mar 2025 13:02:50 -0500 Subject: [PATCH] . --- coord_tripler.pl | 1 - grid-tester.pl | 37 +++---------------------------------- 2 files changed, 3 insertions(+), 35 deletions(-) diff --git a/coord_tripler.pl b/coord_tripler.pl index 9b6cf22..11da2d5 100644 --- a/coord_tripler.pl +++ b/coord_tripler.pl @@ -25,7 +25,6 @@ open (my $input_fh, $input_file); my $output_file = shift // "$input_file.out"; open (my $output_fh, ">$output_file"); -$regions{holes}{bg} = '#000000'; while (my $line = <$input_fh>) { my @fields = split '; ', $line; diff --git a/grid-tester.pl b/grid-tester.pl index dd34c91..185e0c3 100644 --- a/grid-tester.pl +++ b/grid-tester.pl @@ -3,6 +3,7 @@ use rlib '.'; use HexGrid; use HexGrid::Pin; +use HexGrid::Dynamic; use Carp; use Data::Dumper; @@ -31,38 +32,6 @@ while (my $line = <$test_fh>) } } -# say $grid->render; -say wrap_in_html($grid); +say $grid->render; +# say HexGrid::Dynamic::render_html($grid->render, {}); close $test_fh; - -sub wrap_in_html($grid) -{ - my $html_builder = ""; - $html_builder .= "\n\n"; - $html_builder .= "\n" . < - function clickPin(pinId, containerId) { - let popup = document.getElementById(pinId + '-popup'); - popup.style.visibility = popup.style.visibility == 'visible' ? 'hidden' : 'visible'; - } - -EOS - if(1) - { - $html_builder .= < - function toggleCoords(show) { - for (var elem of document.getElementsByClassName('coords')) { - elem.style.visibility = show ? 'visible' : 'hidden'; - } - } - - - -EOS - } - $html_builder .= "\n" . $grid->render; - $html_builder .= "\n\n"; - return $html_builder; -} -