feat(entry): County, CQ, ITU and DXCC on the freed row
Comment and Note moving onto one line left the right column two rows shorter
than the left, and this fills it: county, both zones and the ADIF entity
number. All four are filled by the lookup and were only visible after opening a
tab — the wrong place for values an operator wants to SEE are right before
pressing Log.
County is a name, not a code ("St. Tammany Parish"), so it takes the flexible
width and the three numbers get fixed narrow boxes.
Cleared numeric fields store undefined, not 0. Zero is a real DXCC number and a
real zone, so an empty box has to stay empty rather than assert something the
operator did not type.
State stays up on the geography line beside QTH and the locator, which is how
the lookup fills them and how they are read.
This commit is contained in:
+41
-3
@@ -4448,6 +4448,41 @@ export default function App() {
|
||||
onChange={(e) => setDetails((d) => ({ ...d, state: e.target.value.toUpperCase() }))} />
|
||||
</div>
|
||||
);
|
||||
// County beside State: the lookup fills QTH, State, County and the locator
|
||||
// together, and they are read together. Wider than State because a county name
|
||||
// is a name — "St. Tammany Parish", not a code.
|
||||
// The row Comment/Note freed by moving onto one line: county, zones and the
|
||||
// ADIF entity number. All four are filled by the lookup and were previously
|
||||
// only visible after opening a tab — which is the wrong place for values an
|
||||
// operator wants to SEE are right before pressing Log.
|
||||
//
|
||||
// A numeric field stores undefined when cleared, not 0: zero is a real DXCC
|
||||
// number for "no entity" and a real answer for a zone, so an empty box must
|
||||
// stay empty rather than assert something.
|
||||
const num = (v: string): number | undefined => {
|
||||
const s = v.replace(/[^0-9]/g, '');
|
||||
return s === '' ? undefined : parseInt(s, 10);
|
||||
};
|
||||
const geoDetailRow = (
|
||||
<div className="flex gap-4 items-end">
|
||||
<div className="flex flex-col flex-1 min-w-0"><Label className="mb-1 h-3.5">{t('field.cnty')}</Label>
|
||||
<Input value={details.cnty ?? ''}
|
||||
onChange={(e) => setDetails((d) => ({ ...d, cnty: e.target.value }))} />
|
||||
</div>
|
||||
<div className="flex flex-col w-[64px] shrink-0"><Label className="mb-1 h-3.5">{t('field.cqz')}</Label>
|
||||
<Input value={details.cqz ?? ''} className="font-mono"
|
||||
onChange={(e) => setDetails((d) => ({ ...d, cqz: num(e.target.value) }))} />
|
||||
</div>
|
||||
<div className="flex flex-col w-[64px] shrink-0"><Label className="mb-1 h-3.5">{t('field.ituz')}</Label>
|
||||
<Input value={details.ituz ?? ''} className="font-mono"
|
||||
onChange={(e) => setDetails((d) => ({ ...d, ituz: num(e.target.value) }))} />
|
||||
</div>
|
||||
<div className="flex flex-col w-[72px] shrink-0"><Label className="mb-1 h-3.5">{t('field.dxcc')}</Label>
|
||||
<Input value={details.dxcc ?? ''} className="font-mono"
|
||||
onChange={(e) => setDetails((d) => ({ ...d, dxcc: num(e.target.value) }))} />
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
const gridBlock = (
|
||||
<div className="flex flex-col w-[76px] shrink-0"><Label className="mb-1 h-3.5">{t('field.grid')}</Label>
|
||||
<Input value={grid} placeholder="JN05" className="font-mono" onChange={(e) => { setGrid(e.target.value); markEdited('grid'); }} />
|
||||
@@ -5913,9 +5948,12 @@ export default function App() {
|
||||
{modeRow}
|
||||
{countryRow}
|
||||
</div>
|
||||
<div className="flex gap-4 flex-1 min-w-0">
|
||||
<div className="flex-1 min-w-0">{commentLine}</div>
|
||||
<div className="flex-1 min-w-0">{noteLine}</div>
|
||||
<div className="flex flex-col gap-1.5 flex-1 min-w-0">
|
||||
<div className="flex gap-4">
|
||||
<div className="flex-1 min-w-0">{commentLine}</div>
|
||||
<div className="flex-1 min-w-0">{noteLine}</div>
|
||||
</div>
|
||||
{geoDetailRow}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@ const en: Dict = {
|
||||
'tab.main': 'Main', 'main.splitTip': 'Drag to resize the panes — double-click to even them out', 'tab.recent': 'Recent QSOs', 'tab.cluster': 'Cluster', 'tab.worked': 'Worked before',
|
||||
'tab.awards': 'Awards', 'tab.bandmap': 'Band Map', 'tab.contest': 'Contest', 'tab.net': 'Net',
|
||||
// Entry form
|
||||
'field.callsign': 'Callsign', 'field.name': 'Name', 'field.qth': 'QTH', 'field.state': 'State', 'field.grid': 'Grid',
|
||||
'field.callsign': 'Callsign', 'field.name': 'Name', 'field.qth': 'QTH', 'field.state': 'State', 'field.cnty': 'County', 'field.cqz': 'CQ', 'field.ituz': 'ITU', 'field.dxcc': 'DXCC', 'field.grid': 'Grid',
|
||||
'field.band': 'Band', 'field.mode': 'Mode', 'field.country': 'Country', 'field.comment': 'Comment',
|
||||
'field.note': 'Note', 'field.rstTx': 'RST tx', 'field.rstRx': 'RST rx',
|
||||
'field.txFreq': 'TX Freq (MHz)', 'field.freqTuneHint': 'Type a frequency and press Enter to tune the radio here.', 'field.freq': 'Freq (MHz)', 'field.rxFreq': 'RX Freq (MHz)', 'field.rxBand': 'RX Band',
|
||||
@@ -482,7 +482,7 @@ const fr: Dict = {
|
||||
'profileScope.saved': 'Enregistré pour le profil', 'profileScope.switch': "— change de profil pour éditer une autre identité.",
|
||||
'tab.main': 'Principal', 'main.splitTip': 'Faites glisser pour redimensionner les volets — double-clic pour les égaliser', 'tab.recent': 'QSO récents', 'tab.cluster': 'Cluster', 'tab.worked': 'Déjà contacté',
|
||||
'tab.awards': 'Diplômes', 'tab.bandmap': 'Carte de bande', 'tab.contest': 'Contest', 'tab.net': 'NET',
|
||||
'field.callsign': 'Indicatif', 'field.name': 'Nom', 'field.qth': 'QTH', 'field.state': 'État', 'field.grid': 'Locator',
|
||||
'field.callsign': 'Indicatif', 'field.name': 'Nom', 'field.qth': 'QTH', 'field.state': 'État', 'field.cnty': 'Comté', 'field.cqz': 'CQ', 'field.ituz': 'ITU', 'field.dxcc': 'DXCC', 'field.grid': 'Locator',
|
||||
'field.band': 'Bande', 'field.mode': 'Mode', 'field.country': 'Pays', 'field.comment': 'Commentaire',
|
||||
'field.note': 'Note', 'field.rstTx': 'RST tx', 'field.rstRx': 'RST rx',
|
||||
'field.txFreq': 'Fréq TX (MHz)', 'field.freqTuneHint': 'Tape une fréquence et appuie sur Entrée pour y accorder la radio.', 'field.freq': 'Fréq (MHz)', 'field.rxFreq': 'Fréq RX (MHz)', 'field.rxBand': 'Bande RX',
|
||||
|
||||
Reference in New Issue
Block a user