Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address Issues Found on Hacker News #957

Merged
merged 7 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ public/tle/TLEAltNemo*
classfd.tle
public/audio/samples
public/img/wallpaper/.archive
public/img/*.xcf

# Jest Coverage
coverage/
Expand Down
139 changes: 139 additions & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,145 @@

All notable changes to this project will be documented in this file. Dates are displayed in UTC.

#### v10.2.0

>

- Sateliot
- fix: :bug: fix debris screening menu being available without a satellite selected
- feature: new sateliot satellite model
- feat: :sparkles: add localization for spanish and german
- feat: :sparkles: add collapsable sections in the sat-infobox
- feature: created a new satellite model based on a s6u with solar pannels.
- refactor: :fire: remove jquery!
- fix: :bug: fix styling issues with sat-infobox and search drop down
- feat: :sparkles: update new calendar component
- refactor: :fire: remove unused fonts
- feat: :lipstick: new ui
- feat: :heavy_minus_sign: remove jquery-ui-bundle dependencies for calendar
- refactor: :lipstick: update styling for new theme
- refactor: :recycle: rename css variables to match home page
- feat: :sparkles: add flags
- feat: :sparkles: add new camera widget in eci coordinates
- refactor: :bug: fix class name error caused by minification
- build: :green_heart: fix build hanging
- feat: :sparkles: expand features of tip plugin and fix bug with fetch source
- test: :white_check_mark: update tests to match new plugin architecture
- fix: :bug: fix type in .gitignore
- build: :fire: remove old deployment pipeline
- feat: :sparkles: add geo satellite transponder info
- fix: :lipstick: fix ui issues caused by input-field not having margin
- feat: :globe_with_meridians: add localization to calendar for es and de
- feat: :sparkles: add sateliot preset
- fix: :lipstick: fix stf menu ui
- refactor: :wastebasket: remove deprecated style code
- refactor: :recycle: migrate to storage.keeptrack.space
- feat: :sparkles: add camera reset function
- feat: :sparkles: add tv satellites to constellations plugin
- feat: :sparkles: add colorbox header
- feat: :sparkles: add links to satellite owner websites
- build: :construction_worker: remove codecov from cicd
- refactor: :recycle: remove deprecated settings and names
- feat: :sparkles: add new logo always on
- fix: :bug: fix export function of transponders plugin
- refactor: :lipstick: more color updates
- fix: :bug: fix flickering on mobile
- feat: :sparkles: update screenshot to use new logo instead of text
- feat: :sparkles: add clear message when no lookangles correctly displayed
- feat: :sparkles: add different logic for rotation reset vs full camera reset
- fix: :bug: fix bug caused by satellite that propagates into the earth
- fix: :bug: fix bug where satellite timeline only visible if watchlist sats
- refactor: :lipstick: more changes to ui color
- fix: :bug: fix color of buttons in multi-site lookangles settings
- fix: :bug: fix bug where some plugins reenable in mobile mode
- fix: :bug: fix bug in processLimitedSats_ that caused duplicated ids
- refactor: :recycle: refactor the satellite cone mesh distance from earth to settings
- build: :construction_worker: remove unnecessary artifacts
- fix: :lipstick: fix collapsing sat-infobox on mobile
- fix: :lipstick: fix duplicate shadow effect
- fix: :bug: fix bug with shift being tracked as down after window loses focus
- fix: :bug: fix missing id parameters
- build: :heavy_minus_sign: remove old dependencies
- feat: :sparkles: add new splash screens
- fix: :bug: fix new launch showing error even when it works
- refactor: :lipstick: change color of polar plot to match new theme
- feat: :lipstick: shrink sat-info-box when multiple menus are collapsed
- fix: :bug: fix dark-clouds preset
- refactor: :children_crossing: increase zoom speed
- fix: :bug: fix bug where no references availalbe for historical RCS est
- fix: :bug: fix transponder menu being enabled incorrectly
- refactor: :heavy_minus_sign: remove unused dependencies
- test: :white_check_mark: fix colorbox test
- fix: :bug: fix sensor-list side menu size
- refactor: :recycle: change default search size
- feat: :lipstick: add iss flag
- fix: :bug: fix bug where polar plot could be opened without a sensor selected
- ci: :green_heart: switch trufflehog action
- fix: :bug: fix create sensor from context menu not working
- fix: :bug: fix search bar being clipped when sat-infobox moved
- fix: :lock: fix security issue in dependencies
- fix: :bug: fix unknown countries showing up as Grenada
- refactor: :recycle: allow closer zoom on satellite models
- fix: :ambulance: fix error when no satellite selected
- fix: :bug: fix typo in locales.ts
- feat: :sparkles: update logo image
- fix: :lipstick: fix custom sensor plugin menu width
- fix: :lipstick: fix missing nav-bar-height on mobile
- feat: :sparkles: update logos
- refactor: :lock: fix security issue with dependencies

#### v10.2.0-0

#### v10.1.0

>

- feat: :sparkles: add localization for spanish and german
- refactor: :fire: remove jquery!
- feat: :sparkles: update new calendar component
- refactor: :fire: remove unused fonts
- feat: :heavy_minus_sign: remove jquery-ui-bundle dependencies for calendar
- feat: :sparkles: add flags
- refactor: :bug: fix class name error caused by minification
- feat: :sparkles: expand features of tip plugin and fix bug with fetch source
- test: :white_check_mark: update tests to match new plugin architecture
- fix: :bug: fix type in .gitignore
- build: :fire: remove old deployment pipeline
- feat: :globe_with_meridians: add localization to calendar for es and de
- refactor: :recycle: migrate to storage.keeptrack.space
- fix: :bug: fix flickering on mobile
- fix: :bug: fix missing id parameters
- refactor: :heavy_minus_sign: remove unused dependencies
- fix: :bug: fix typo in locales.ts
- refactor: :lock: fix security issue with dependencies

#### v10.1.0-2

>

- build: :heavy_minus_sign: remove old dependencies

#### v10.1.0-1

>

- fix: :bug: disable husky

#### v10.1.0-0

>

- refactor: :recycle: abstract text from plugins
- feat: :construction: first attempt at providing localization
- refactor: :recycle: refactor data out of sensorList and multisiteLookangles
- feat: :sparkles: add ability to push to npm again
- docs: :memo: update changelog
- fix: :bug: fix missing rmb items
- fix: :goal_net: add try/catch for bad plugins
- fix: :rotating_light: fix linter errors with package.json
- fix: :bug: fix rmb events firing twice
- fix: :bug: fix getSensorList logic

#### v10.0.2

>
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "keeptrack.space",
"version": "10.1.0",
"version": "10.2.0",
"type": "module",
"description": "Complex astrodynamics tools designed for non-engineers to make learning about orbital mechanics and satellite operations more accessible.",
"author": "Theodore Kruczek",
Expand Down
5 changes: 3 additions & 2 deletions public/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,8 @@ ul {
#keeptrack-canvas {
background: var(--colorBlack);
/* Inconsistent brightness without this */
z-index: 0;
position: absolute;
z-index: -1;
top: 0;
left: 0;
bottom: 0;
Expand Down Expand Up @@ -242,7 +243,7 @@ ul {
}

#sat-hoverbox {
display: flex;
display: none;
background: var(--color-dark-background) !important;
cursor: default;
color: white;
Expand Down
Binary file modified public/img/textLogoMd.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/img/textLogoXl.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 6 additions & 1 deletion src/keeptrack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ import { settingsManager, SettingsManagerOverride } from './settings/settings';
import { VERSION } from './settings/version.js';
import { VERSION_DATE } from './settings/versionDate.js';
import { Camera } from './singletons/camera';
import { CameraControlWidget } from './singletons/camera-control-widget';
import { CatalogManager } from './singletons/catalog-manager';
import { ColorSchemeManager } from './singletons/color-scheme-manager';
import { DemoManager } from './singletons/demo-mode';
Expand Down Expand Up @@ -167,6 +168,10 @@ export class KeepTrack {
keepTrackContainer.registerSingleton(Singletons.SensorMath, sensorMathInstance);
const mainCameraInstance = new Camera();

const cameraControlWidget = new CameraControlWidget();

console.log(cameraControlWidget);

keepTrackContainer.registerSingleton(Singletons.MainCamera, mainCameraInstance);
const hoverManagerInstance = new HoverManager();

Expand Down Expand Up @@ -239,7 +244,7 @@ export class KeepTrack {
</div>
<figcaption id="info-overlays">
<div id="camera-status-box" class="start-hidden status-box">Earth Centered Camera Mode</div>
<div id="propRate-status-box" class="start-hidden status-box">Propagation Rate: 1.00x</div>
<div id="propRate-status-box" class="start-hidden status-box">Propagation Rate: 1.00x</div>
</figcaption>
</main>
<footer id="nav-footer" class="page-footer resizable">
Expand Down
18 changes: 3 additions & 15 deletions src/plugins/debris-screening/debris-screening.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ import { showLoading } from '@app/lib/showLoading';
import { CoordinateTransforms } from '@app/static/coordinate-transforms';
import { SatMath } from '@app/static/sat-math';
import aboutPng from '@public/img/icons/about.png';
import { BaseObject, DetailedSatellite, EciVec3, Hours, Kilometers, Milliseconds, Minutes, Seconds, Sgp4 } from 'ootk';
import { DetailedSatellite, EciVec3, Hours, Kilometers, Milliseconds, Minutes, Seconds, Sgp4 } from 'ootk';
import { KeepTrackPlugin } from '../KeepTrackPlugin';
import { SelectSatManager } from '../select-sat-manager/select-sat-manager';

export class DebrisScreening extends KeepTrackPlugin {
readonly id = 'DebrisScreening';
dependencies_ = [SelectSatManager.name];
private selectSatManager_: SelectSatManager;
private readonly selectSatManager_: SelectSatManager;

constructor() {
super();
Expand Down Expand Up @@ -114,6 +114,7 @@ export class DebrisScreening extends KeepTrackPlugin {
</div>
`;

isRequireSatelliteSelected = true;
isIconDisabledOnLoad = true;
isIconDisabled = true;

Expand All @@ -138,18 +139,6 @@ export class DebrisScreening extends KeepTrackPlugin {
});
},
});

keepTrackApi.register({
event: KeepTrackApiEvents.selectSatData,
cbName: this.id,
cb: (sat: BaseObject): void => {
if (sat) {
this.setBottomIconToEnabled();
} else {
this.setBottomIconToDisabled();
}
},
});
}

onVisClick(): void {
Expand Down Expand Up @@ -221,7 +210,6 @@ export class DebrisScreening extends KeepTrackPlugin {
const ric = CoordinateTransforms.sat2ric({ position: satSv.position, velocity: satSv.velocity }, { position: sat2Sv.position, velocity: sat2Sv.velocity });

if (Math.abs(ric.position[0]) < uVal && Math.abs(ric.position[1]) < vVal && Math.abs(ric.position[2]) < wVal) {
console.log(`${sat2.sccNum} at ${new Date(now)}`);
searchList.push(sat2.sccNum);
// Remove from possible sats
possibleSats.splice(idx, 1);
Expand Down
28 changes: 28 additions & 0 deletions src/plugins/settings-menu/settings-menu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,13 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
Show Agencies
</label>
</div>
<div class="switch row">
<label data-position="top" data-delay="50" data-tooltip="Disable this to hide the camera widget">
<input id="settings-drawCameraWidget" type="checkbox" checked/>
<span class="lever"></span>
Show Camera Widget
</label>
</div>
<div class="switch row">
<label data-position="top" data-delay="50" data-tooltip="Disable this to hide orbit lines">
<input id="settings-drawOrbits" type="checkbox" checked/>
Expand Down Expand Up @@ -464,6 +471,12 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
(<HTMLInputElement>getEl('settings-showDebris')).checked = settingsManager.isShowDebris;
(<HTMLInputElement>getEl('settings-showAgencies')).checked = settingsManager.isShowAgencies;
(<HTMLInputElement>getEl('settings-drawOrbits')).checked = settingsManager.isDrawOrbits;
(<HTMLInputElement>getEl('settings-drawCameraWidget')).checked = settingsManager.drawCameraWidget;
if (!settingsManager.drawCameraWidget) {
getEl('camera-control-widget').style.display = 'none';
} else {
getEl('camera-control-widget').style.display = 'block';
}
(<HTMLInputElement>getEl('settings-drawTrailingOrbits')).checked = settingsManager.isDrawTrailingOrbits;
(<HTMLInputElement>getEl('settings-drawEcf')).checked = settingsManager.isOrbitCruncherInEcf;
(<HTMLInputElement>getEl('settings-isDrawInCoverageLines')).checked = settingsManager.isDrawInCoverageLines;
Expand Down Expand Up @@ -494,6 +507,7 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_ROCKET_BODIES, settingsManager.isShowRocketBodies.toString());
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_DEBRIS, settingsManager.isShowDebris.toString());
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_AGENCIES, settingsManager.isShowAgencies.toString());
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_DRAW_CAMERA_WIDGET, settingsManager.drawCameraWidget.toString());
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_DRAW_ORBITS, settingsManager.isDrawOrbits.toString());
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_DRAW_TRAILING_ORBITS, settingsManager.isDrawTrailingOrbits.toString());
PersistenceManager.getInstance().saveItem(StorageKey.SETTINGS_DRAW_ECF, settingsManager.isOrbitCruncherInEcf.toString());
Expand Down Expand Up @@ -550,6 +564,7 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
case 'settings-showDebris':
case 'settings-showAgencies':
case 'settings-drawOrbits':
case 'settings-drawCameraWidget':
case 'settings-drawTrailingOrbits':
case 'settings-drawEcf':
case 'settings-isDrawInCoverageLines':
Expand Down Expand Up @@ -594,6 +609,7 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
}

private static resetToDefaults_() {
keepTrackApi.getSoundManager().play(SoundNames.BUTTON_CLICK);
settingsManager.isShowLeoSats = true;
settingsManager.isShowHeoSats = true;
settingsManager.isShowMeoSats = true;
Expand All @@ -603,6 +619,7 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
settingsManager.isShowDebris = true;
settingsManager.isShowAgencies = false;
settingsManager.isDrawOrbits = true;
settingsManager.drawCameraWidget = true;
settingsManager.isDrawTrailingOrbits = false;
settingsManager.isOrbitCruncherInEcf = false;
settingsManager.isDrawInCoverageLines = true;
Expand Down Expand Up @@ -653,6 +670,17 @@ export class SettingsMenuPlugin extends KeepTrackPlugin {
const isDrawAtmosphereChanged = settingsManager.isDrawAtmosphere !== (<HTMLInputElement>getEl('settings-drawAtmosphere')).checked;
const isDrawAuroraChanged = settingsManager.isDrawAurora !== (<HTMLInputElement>getEl('settings-drawAurora')).checked;

settingsManager.drawCameraWidget = (<HTMLInputElement>getEl('settings-drawCameraWidget')).checked;
const ccWidgetCanvas = getEl('camera-control-widget');

if (ccWidgetCanvas) {
if (settingsManager.drawCameraWidget) {
ccWidgetCanvas.style.display = 'block';
} else {
ccWidgetCanvas.style.display = 'none';
}
}

settingsManager.isBlackEarth = (<HTMLInputElement>getEl('settings-drawBlackEarth')).checked;
settingsManager.isDrawAtmosphere = (<HTMLInputElement>getEl('settings-drawAtmosphere')).checked;
settingsManager.isDrawAurora = (<HTMLInputElement>getEl('settings-drawAurora')).checked;
Expand Down
18 changes: 8 additions & 10 deletions src/plugins/timeline-satellite/satellite-timeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,21 +160,19 @@ export class SatelliteTimeline extends KeepTrackPlugin {
event: KeepTrackApiEvents.selectSatData,
cbName: this.id,
cb: (sat: BaseObject) => {
if (!this.isMenuButtonActive) {
return;
}

if (sat) {
this.ctxStatic_.reset();
this.updateTimeline();
this.canvas_.style.display = 'block';
}

if (!sat && keepTrackApi.getPlugin(WatchlistPlugin).watchlistList.length === 0) {
this.setBottomIconToDisabled();
} else if (this.verifySensorSelected(false)) {
this.setBottomIconToEnabled();
}

if (this.isMenuButtonActive) {
if (sat) {
this.ctxStatic_.reset();
this.updateTimeline();
this.canvas_.style.display = 'block';
}
}
},
});
keepTrackApi.register({
Expand Down
Loading
Loading