User:CenPop/CenPopLayout.js

/** * Layout Code for CenPop Script * * @license * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * @version 1.0 * @author Jacob Alperin-Sheriff, Joeytje50 */ var temp_state_list=["AL", "AK", "AZ", "AR", "CA", "CO", "CT", "DE", "DC", "FL", "GA", "HI", "ID", "IL", "IN", "IA", "KS", "KY", "LA", "ME", "MD", "MA", "MI", "MN", "MS", "MO", "MT", "NE", "NV", "NH", "NJ", "NM", "NY", "NC", "ND", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VT", "VA", "WA", "WV", "WI", "WY"]; var temp_fips_list=["01","02","04","05","06","08","09","10","11","12","13","15","16","17","18","19","20","21","22", "23","24","25","26","27","28","29","30","31","32","33","34","35","36","37","38","39",	"40","41","42","44","45","46","47","48","49","50","51","53","54","55","56"]; var stateAddingStr=''; for(let i=0; i < temp_state_list.length;i++) stateAddingStr = stateAddingStr + ''+temp_state_list[i]+' '; CenPop.layoutHTML={body: ' '+ ''+ ' '+				''+ ' '+					' '+'Failed to add'+' '+ ' '+CenPop.msg('tab-nowebsite')+' '+ ' '+				''+ ''+ ' '+ ' '+				' '+				''+ ''+ ' '+ ' '+				' '+				' '+				' '+					' '+						' '+CenPop.msg('tab-editing')+' '+ ' '+CenPop.msg('tab-cen-fields')+' '+ ' '+CenPop.msg('tab-debug')+' '+ ' '+CenPop.msg('tab-upload')+' '+ ' '+'Log'+' '+ ' '+					' '+ ' '+ ' '+ ' '+ ' '+ ' done '+ ' '+				''+ ''+CenPop.msg('editbox-caption')+' ( 0 )&emsp;'+ '<textarea id="editBoxArea"> '+ ' '+			' '+		' '+		' '+			CenPop.msg('stat-new')+ ' 0 ;&emsp;'+ CenPop.msg('stat-modhist')+' 0 ;&emsp;'+ CenPop.msg('stat-geoinfo')+' 0 ;&emsp;'+ CenPop.msg('stat-modinfobox')+' 0 ;&emsp;'+ CenPop.msg('stat-save')+' 0 ;&emsp;'+ CenPop.msg('stat-null')+' 0 ;&emsp;'+ 'Fail:'+' 0 ;&emsp;'+ ' '+		' ',	censusinputfields:' Historical Census Info '+ ' '+	'<div id="est_or_census_div">'+ '<span class="to_add_span">'+ '<label class="load_label">Type: '+ '<label class="radio_label"><input type="radio" class="my_radio estorcensus" name="estorcensus" value="Estimate" checked>Estimate '+ '<label class="radio_label"><input type="radio" class="my_radio estorcensus" name="estorcensus" value="Decennial">Decennial '+ ' '+		' '+			'<label title="'+CenPop.msg('begin-year-tip')+'" style="display:block;">'+'begin_year='+' <input type="text" class="beginYearText"/> '+ '<label title="'+CenPop.msg('est-year-tip')+'" style="display:block;">'+'estyear='+' <input type="text" class="estYearText"/> ' + '<label style="display:block;">'+'estref='+' <input type="text" class="estRefText"/> '+ '<label style="display:block;">'+'footnote='+' <input type="text" class="footnoteText"/> '+ ' ',	census_load_str:'<div id="select_div">'+'<div class="to_add_div" id="state_div">'+'<span class="to_add_span">State '+ '<select id="stateAdding" title="State to add updates from">'+stateAddingStr+' '+ '<div class="to_add_div" id="geo_div">'+'<span class="to_add_span">Geo Level '+ '<select id="geoAdding" title="Geography level to add updates from">'+ ' '+'County'+' '+' '+'Place'+' '+ '<option value="incplace" selected>'+'Inc. Place'+' '+ ' '+'County Sub.'+' '+ ' '+			'<div class="to_add_div" id="county_div">'+ '<span class="to_add_span">County '+ '<input type="text" id="county_fips" title="County FIPS code" maxlength="3">'+ ' '+			'<div class="to_add_div" id="fips_div">'+ '<span class="to_add_span">Start FIPS '+ '<input type="text" id="min_fips" title="Minimum FIPS code for locality to start adding from" maxlength="5">'+ ' '+		' '		,		findreplace:' '+ '<label style="display:block;" id="summaryLabel">Summary:<input class="fullwidth" type="text" id="summary" maxlength="170"> '+ ' ' }; CenPop.layoutHTML.datatab1='<div id="load_from_div">'+ '<span class="to_add_span">'+ '<label id="load_label">Load From: '+ '<label class="radio_label"><input type="radio" class="my_radio" name="load_from" value="census" checked>Census Bureau '+ '<label class="radio_label"><input type="radio" class="my_radio" name="load_from" value="file">Internal File '+ ' '+		' '+		'<div id="load_details">'+CenPop.layoutHTML.census_load_str+' '+ '<div class="check_div">'+ '<span class="to_add_span">'+ ' <input type="checkbox" id="autosave"> '+CenPop.msg('auto-save')+' '+ '<label title="'+CenPop.msg('tip-save-interval')+'" class="divisor">'+ CenPop.msg('save-interval', '<input type="number" min="0" value="0" style="width:50px" id="throttle" disabled>')+ ' '+			' '+		'<span class="to_add_span">'+ ' <input type="checkbox" id="overwrite"> '+'Overwrite'+' '+ ' '+		'<span class="to_add_span">'+ '<label title="'+CenPop.msg('tip-only-fips')+'"><input type="checkbox" id="tryfipsonly" /> Try FIPS only '+ ' '+		'<span class="to_add_span">'+ '<label title="'+CenPop.msg('tip-add-images')+'"><input type="checkbox" id="addimages" />Add images '+ ' '+		'<div id="button_div">'+ '<button class="editbutton" id="nextButton" disabled accesskey="n" title="['+CenPop.tooltip+'n]">'+'Next'+' '+ '<button class="editbutton" id="submitButton" disabled accesskey="s" title="['+CenPop.tooltip+'s]">'+CenPop.msg('editbutton-save')+' '+ '<button class="editbutton" id="previewButton" disabled accesskey="p" title="['+CenPop.tooltip+'p]">'+CenPop.msg('editbutton-preview')+' '+ '<button class="editbutton" id="diffButton" disabled accesskey="d" title="['+CenPop.tooltip+'d]">'+CenPop.msg('editbutton-diff')+' '+ ' '+		' '+		' '+			'<button id="startbutton" accesskey="a" title="Start and load data">'+CenPop.msg('editbutton-start')+' '+ ' '+			'<button id="stopbutton" disabled accesskey="q" title="['+CenPop.tooltip+'q]">'+CenPop.msg('editbutton-stop')+' '+ ' '+			'<button id="runButton" disabled>'+CenPop.msg('editbutton-run')+' '+ ' '+		CenPop.layoutHTML.findreplace;