kopia lustrzana https://gitlab.com/gridtracker.org/gridtracker
Merge branch 'pre-linting' into 'master'
Correct HTML tags and file names in preparation for automatic linting See merge request gridtracker.org/gridtracker!11merge-requests/31/head
commit
e29d693de3
|
@ -8,3 +8,4 @@ debian/*-stamp
|
|||
debian/*.substvars
|
||||
debian/tmp
|
||||
.DS_Store
|
||||
node_modules
|
||||
|
|
|
@ -0,0 +1,10 @@
|
|||
node_modules/
|
||||
macos/
|
||||
debian/
|
||||
build/
|
||||
package.nw/lib/ol.js
|
||||
package.nw/lib/moment-with-locales.js
|
||||
package.nw/lib/moment-timezone-with-data.js
|
||||
package.nw/lib/datepicker.js
|
||||
package.nw/lib/third-party.js
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"printWidth": 80,
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["*.html"],
|
||||
"options": {
|
||||
"printWidth": 120
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
27
README.md
27
README.md
|
@ -2,12 +2,29 @@
|
|||
|
||||
# Developing GridTracker
|
||||
|
||||
GridTracker runs using [NWJS](https://nwjs.io/), a tools that wraps both Chrome windows and node processes into a native application.
|
||||
GridTracker runs using [NWJS](https://nwjs.io/), a tools that wraps both Chrome windows and node processes into
|
||||
a native application.
|
||||
|
||||
To work on GridTracker you need to clone this git repository and then invoke NWJS with the contents of `package.nw`.
|
||||
|
||||
NWJS comes in two flavors, "normal" and "sdk". GridTracker is distributed with the normal flavor, but for development work
|
||||
we recommend the SDK flavor because it provides access to Chrome's Developer Tools, among other things.
|
||||
NWJS comes in two flavors, "normal" and "sdk". GridTracker is distributed with the normal flavor,
|
||||
but for development work we recommend the SDK flavor because it provides access to Chrome's Developer Tools,
|
||||
among other things.
|
||||
|
||||
### Code Formatting
|
||||
We use `prettier` to enforce code formatting rules, and we follow
|
||||
the [JavaScript Standard Style](https://standardjs.com/)
|
||||
|
||||
You can use all kinds of plugins and configurations in your text editor to verify these rules, and even reformat code
|
||||
automatically, but if you want to run on the command line, you can (after running `npm install`) run the
|
||||
`npm run prettier-check` command to verify the formatting of all files, or `npm run prettier-write` to reformat
|
||||
all files to match the standard.
|
||||
|
||||
If you want to know more about why these tools are useful,
|
||||
[watch this talk](https://www.youtube.com/watch?v=kuHfMw8j4xk)
|
||||
|
||||
|
||||
# Developer Environment Setup
|
||||
|
||||
## Developing on Windows
|
||||
|
||||
|
@ -19,7 +36,7 @@ To access the Developer Tools, right-click on an unused area of a window, or pre
|
|||
|
||||
## Developing on Mac
|
||||
|
||||
We suggest using the `macos/run.sh` script to launch GridTracker while developing. It will download the sdk flavor of NWJS if needed,
|
||||
and use it to run the app.
|
||||
We suggest using the `macos/run.sh` script to launch GridTracker while developing. It will download the sdk flavor
|
||||
of NWJS if needed, and use it to run the app.
|
||||
|
||||
To access the Developer Tools, right-click on an unused area of a window, or press F12.
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
"name": "gridtracker-development",
|
||||
"requires": true,
|
||||
"lockfileVersion": 1,
|
||||
"dependencies": {
|
||||
"prettier": {
|
||||
"version": "2.1.2",
|
||||
"resolved": "https://registry.npmjs.org/prettier/-/prettier-2.1.2.tgz",
|
||||
"integrity": "sha512-16c7K+x4qVlJg9rEbXl7HEGmQyZlG4R9AgP+oHKRMsMsuk8s+ATStlf1NpDqyBI1HpVyfjLOeMhH2LvuNvV5Vg==",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"name": "gridtracker-development",
|
||||
"devDependencies": {
|
||||
"prettier": "2.1.2"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "npm run prettier-check",
|
||||
"prettier-check": "npx prettier --check package.nw",
|
||||
"prettier-write": "npx prettier --write package.nw"
|
||||
}
|
||||
}
|
|
@ -534,7 +534,7 @@
|
|||
<tr>
|
||||
<td><div style="display:none" id="importSettingsButton" class="button" onclick="importSettings();">Import Settings</div></td>
|
||||
</tr>
|
||||
<tr><td><font style="display:none" id="importSettingsFile"></font></td></td>
|
||||
<tr><td><font style="display:none" id="importSettingsFile"></font></td>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
|
@ -1384,7 +1384,7 @@
|
|||
<br/>
|
||||
<div class="mapItem">
|
||||
<table align="center" title="Alert when new 'Wanted Row(s)' appear in the Call Roster">
|
||||
<tr><td colspan=2>Audio Alert On <b>New Wanted</b></td></td>
|
||||
<tr><td colspan=2>Audio Alert On <b>New Wanted</b></td>
|
||||
<tr>
|
||||
<td colspan=2>
|
||||
<input type="checkbox" id="huntRoster" onchange="wantedChanged(this);"/>
|
||||
|
@ -1600,10 +1600,10 @@
|
|||
<td colspan=2 ><input type="checkbox" id="onlyRoundUp" onchange="noRoundUp.checked=false; exceptionValuesChanged();">Only Round-Up</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan=2 > <div id="usesLoTWDiv" style="display:none"><input type="checkbox" id="usesLoTW" onchange="exceptionValuesChanged();">Uses LoTW<div></td>
|
||||
<td colspan=2 > <div id="usesLoTWDiv" style="display:none"><input type="checkbox" id="usesLoTW" onchange="exceptionValuesChanged();">Uses LoTW</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan=2 > <div id="useseQSLDiv" style="display:none"><input type="checkbox" id="useseQSL" onchange="exceptionValuesChanged();">Uses eQSL<div></td>
|
||||
<td colspan=2 > <div id="useseQSLDiv" style="display:none"><input type="checkbox" id="useseQSL" onchange="exceptionValuesChanged();">Uses eQSL</div></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
|
@ -1831,12 +1831,10 @@
|
|||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div id="upToDateDiv" style="margin: 0 auto; left: 0; right: 0;top:0;height:100%;width:100%;display:none;background-color:black;text-align:center;vertical-align:middle;position:absolute;z-index:800;white-space: nowrap;overflow:hidden;" >
|
||||
<h2>GridTracker is up to date!</h2>
|
||||
<div class="button" onclick="closeUpdateToDateDiv();">OK</div>
|
||||
</div>
|
||||
<div id="selectNodeDiv" style="-webkit-user-select:text;display:block;zIndex:-10000"></div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -46,4 +46,4 @@
|
|||
<option value="V4">V4</option>
|
||||
<option value="VOI">VOI</option>
|
||||
<option value="WINMOR">WINMOR</option>
|
||||
<option value="WSPR">WSPR</option>
|
||||
<option value="WSPR">WSPR</option>
|
|
@ -146,7 +146,7 @@ window.opener.onMyKeyDown(event);
|
|||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -200,7 +200,7 @@
|
|||
<table >
|
||||
<tr >
|
||||
<td >
|
||||
<input type="checkbox" id="useRegex" title="Callsign Regular Expression" onchange="valuesChanged();"> <a title="Regular Expressions 101" href="https://regex101.com/?flavor=javascript" target='_blank'>Regex</a></input>
|
||||
<label><input type="checkbox" id="useRegex" title="Callsign Regular Expression" onchange="valuesChanged();" /> <a title="Regular Expressions 101" href="https://regex101.com/?flavor=javascript" target='_blank'>Regex</a></label>
|
||||
<input type="text" class="inputTextValue" size="12" id="callsignRegex" onfocus="g_regFocus=true;" onblur="g_regFocus=false;" oninput="valuesChanged();" style='display:none;background-color:green;color:yellow;margin:0' onkeydown="checkForEnter(this);" />
|
||||
</td>
|
||||
</tr>
|
||||
|
|
Ładowanie…
Reference in New Issue