package SGN::View::Mason::Commands;
use strict;
use vars qw($m $c);
HTML::Mason::Component::FileBased->new(
'code' => sub {
use utf8; local $SGN::View::Mason::Commands::m = $HTML::Mason::Commands::m;
HTML::Mason::Exception::Params->throw
    ( error =>
      "Odd number of parameters passed to component expecting name/value pairs"
    ) if @_ % 2;
my ( $map_version_id, @hilite_markers, $map_items, $force, $size, $basepath, $tempdir, $message, $overview_image, $map_url );
{
    my %pos;
    for ( my $x = 0; $x < @_; $x += 2 )
    {
        $pos{ $_[$x] } = $x + 1;
    }

    foreach my $arg ( qw( map_version_id basepath tempdir overview_image map_url ) )
    {
        HTML::Mason::Exception::Params->throw
            ( error => "no value sent for required parameter '$arg'" )
                unless exists $pos{$arg};
    }
#line 49 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
    $map_version_id = $_[ $pos{'map_version_id'} ];
#line 50 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
     @hilite_markers = exists $pos{'hilite_markers'} ? HTML::Mason::Tools::coerce_to_array( $_[ $pos{'hilite_markers'} ], '@hilite_markers') :  ();
#line 51 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
     $map_items = exists $pos{'map_items'} ? $_[ $pos{'map_items'} ] :  '';
#line 52 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
     $force = exists $pos{'force'} ? $_[ $pos{'force'} ] :  0;
#line 53 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
     $size = exists $pos{'size'} ? $_[ $pos{'size'} ] :  1;
#line 54 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
    $basepath = $_[ $pos{'basepath'} ];
#line 55 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
    $tempdir = $_[ $pos{'tempdir'} ];
#line 56 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
     $message = exists $pos{'message'} ? $_[ $pos{'message'} ] :  '';
#line 57 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
    $overview_image = $_[ $pos{'overview_image'} ];
#line 58 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
    $map_url = $_[ $pos{'map_url'} ];
}
$m->debug_hook( $m->current_comp->path ) if ( HTML::Mason::Compiler::IN_PERL_DB() );

#line 1 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '
' );
#line 47 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '
' );
#line 60 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '
' );
#line 61 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"


use CXGN::Page::FormattingHelpers qw | tooltipped_text |;
#
# add the input box and form for the hilite marker feature
#
my $hilite_tooltip = tooltipped_text("Highlight marker(s)", "You can highlight markers on the overview graphic by entering them here, separated by spaces");
my $size_tooltip = tooltipped_text("Image size", "You can increase the size of the overview graph by clicking on the (+) button and decrease it by clicking on (-).");

my $hilite = join " ", @hilite_markers;

my $message_html = "";

if ($message) {  $message_html = qq | <div class="boxbgcolor2">$message<br /></div> |; }


my $shrink_button_disabled = '';
my $enlarge_button_disabled = '';
my $smaller_size;
my $larger_size;

if ($size <= 0) {
  $size = 0;
  $shrink_button_disabled = qq { disabled="1" };
  $smaller_size = $size;
}
else {
  $smaller_size = $size - 1;
}

if ($size>=10) {
  $size=10; 
  $enlarge_button_disabled = qq { disabled="1" };
  $larger_size = $size;
}
else {
  $larger_size = $size+ 1;
}

$larger_size = 10 if $larger_size > 10;



#line 105 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '
<div class="well" style="overflow:scroll">
  <center>
    ' );
#line 108 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $message_html  );
#line 108 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '
    ' );
#line 109 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $overview_image  );
#line 109 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '

    <br/>
  </center>

  <div class="row">
    <div class="col-sm-1 col-md-1 col-lg-2">
    </div>
    <div class="col-sm-10 col-md-10 col-lg-8">
      <div class="row">
        <div class="col-sm-7 col-md-8 col-lg-8">
 
	<form action="' );
#line 121 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_url  );
#line 121 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" class="form-horizontal" role="form">
    	  <div class="form-group">
      	    <label class="col-sm-3 control-label">' );
#line 123 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $hilite_tooltip  );
#line 123 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( ': </label>
      	    <div class="col-sm-9">
              <input type="hidden" name="map_items" value="' );
#line 125 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_items  );
#line 125 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
  	      <input type="hidden" name="map_version_id" value="' );
#line 126 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_version_id  );
#line 126 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
  	      <input type="hidden" name="size" value="' );
#line 127 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $size  );
#line 127 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
	      <div class="input-group">
	        <input class="form-control" type="text" name="hilite" value="' );
#line 129 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $hilite  );
#line 129 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" aria-describedby="basic-addon1"/>
  	  	<span class="input-group-btn" id="basic-addon1"><button class="btn btn-info" type="submit" value="Highlight">Highlight</button></span>
	      </div>
      	    </div>
    	  </div>
  	</form>

        </div>
	<div class="col-sm-5 col-md-4 col-lg-4">

      	  <label style="float:left" >' );
#line 139 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $size_tooltip  );
#line 139 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( ':&nbsp;&nbsp;</label>

          <form style="float:left" action="' );
#line 141 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_url  );
#line 141 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '"
            <input type="hidden" name="map_items" value="' );
#line 142 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_items  );
#line 142 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <input type="hidden" name="map_version_id" value="' );
#line 143 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_version_id  );
#line 143 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <input type="hidden" name="size" value="' );
#line 144 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $smaller_size  );
#line 144 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <input type="hidden" name="hilite" value="' );
#line 145 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $hilite  );
#line 145 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <button class="btn btn-default" type="submit" value="-" ' );
#line 146 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $shrink_button_disabled  );
#line 146 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( ' > - </button>
    	  </form>
	  <form style="float:left" action="' );
#line 148 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_url  );
#line 148 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" >
    	    <input type="hidden" name="map_items" value="' );
#line 149 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_items  );
#line 149 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <input type="hidden" name="map_version_id" value="' );
#line 150 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $map_version_id  );
#line 150 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <input type="hidden" name="hilite" value="' );
#line 151 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $hilite  );
#line 151 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <input type="hidden" name="size" value="' );
#line 152 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $larger_size  );
#line 152 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( '" />
    	    <button class="btn btn-default" type="submit" value="+" ' );
#line 153 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print(  $enlarge_button_disabled  );
#line 153 "/home/production/cxgn/sgn/mason/cview/map/overview.mas"
$m->print( ' > + </button>
    	  </form>

        </div>
      </div>
    </div>
    <div class="col-sm-1 col-md-1 col-lg-2">
    </div>
  </div>
</div>



' );
;return;
},
'declared_args' => {
  '$basepath' => { default => undef },
  '$force' => { default => ' 0' },
  '$map_items' => { default => ' \'\'' },
  '$map_url' => { default => undef },
  '$map_version_id' => { default => undef },
  '$message' => { default => ' \'\'' },
  '$overview_image' => { default => undef },
  '$size' => { default => ' 1' },
  '$tempdir' => { default => undef },
  '@hilite_markers' => { default => ' ()' }
},
'load_time' => 1763166043,

)
;