-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Fix documentation and add showcases
- Fix object scaling based on radius
- Loading branch information
1 parent
0e88666
commit 8b91d60
Showing
149 changed files
with
1,769 additions
and
958 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { addons } from '@storybook/manager-api'; | ||
import customTheme from './theme'; | ||
|
||
addons.setConfig({ | ||
theme: customTheme, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { Meta, Story, Controls } from '@storybook/blocks'; | ||
|
||
import * as Stories from "./HorseshoeOrbit.stories"; | ||
|
||
<Meta title="Showcase/Horseshoe Orbit/2010 SO16" /> | ||
|
||
# 2010 SO16 | ||
|
||
[2010 SO16](https://en.wikipedia.org/wiki/(419624)_2010_SO16) is a sub-kilometer asteriod in a co-orbital configuration with Earth that looks like a horseshoe in a non-rotating frame of reference. | ||
|
||
<center> | ||
<img src="https://upload.wikimedia.org/wikipedia/commons/5/53/Animation_of_%28419624%29_2010_SO16_orbit.gif" alt="2010 SO16 orbit" width="400"/> | ||
<img src="https://upload.wikimedia.org/wikipedia/commons/3/39/Animation_of_%28419624%29_2010_SO16_orbit_around_Sun.gif" alt="2010 SO16 orbit around Sun" width="400"/> | ||
|
||
GIFs from Wiki Commons - <a title="Phoenix7777, CC BY-SA 4.0 <https://creativecommons.org/licenses/by-sa/4.0>, via Wikimedia Commons" href="https://commons.wikimedia.org/wiki/File:Animation_of_(419624)_2010_SO16_orbit.gif">gif1</a>, | ||
<a title="Phoenix7777, CC BY-SA 4.0 <https://creativecommons.org/licenses/by-sa/4.0>, via Wikimedia Commons" href="https://commons.wikimedia.org/wiki/File:Animation_of_(419624)_2010_SO16_orbit_around_Sun.gif">gif2</a> | ||
</center> | ||
|
||
The initial configurations of Sun, Earth and the asteriod have been setup, recorded at 20000000x speed for about 13.5 minutes of playback. Use the speed control below to change the playback speed. You can also try changing the frame of reference to see the horseshoe orbit from different perspectives. | ||
|
||
<Controls of={Stories.SO16} /> | ||
<center><Story of={Stories.SO16} /></center> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,22 @@ | ||
import { Meta, Story } from '@storybook/blocks'; | ||
import { Meta, Story, Controls } from '@storybook/blocks'; | ||
|
||
import * as Stories from "./HorseshoeOrbit.stories"; | ||
|
||
<Meta title="Showcase/HorseshoeOrbit/54509 YORP" /> | ||
<Meta title="Showcase/Horseshoe Orbit/54509 YORP" /> | ||
|
||
# 54509 YORP | ||
|
||
54509 YORP is an Earth co-orbital asteroid that follows a horse shoe orbit | ||
[54509 YORP](https://en.wikipedia.org/wiki/54509_YORP) is an Earth co-orbital asteroid that follows a flattened horse shoe orbit that looks like the following in frames of refernce snapped to sun-earth and sun respectively: | ||
|
||
<center> | ||
<img src="https://upload.wikimedia.org/wikipedia/commons/d/dd/Animation_of_54509_YORP_orbit.gif" alt="54509 YORP orbit" width="400"/> | ||
<img src="https://upload.wikimedia.org/wikipedia/commons/6/60/Animation_of_54509_YORP_orbit_around_Sun.gif" alt="54509 YORP orbit around Sun" width="400"/> | ||
|
||
GIFs from Wiki Commons - <a title="Phoenix7777, CC BY-SA 4.0 <https://creativecommons.org/licenses/by-sa/4.0>, via Wikimedia Commons" href="https://commons.wikimedia.org/wiki/File:Animation_of_54509_YORP_orbit.gif">gif1</a>, | ||
<a title="Phoenix7777, CC BY-SA 4.0 <https://creativecommons.org/licenses/by-sa/4.0>, via Wikimedia Commons" href="https://commons.wikimedia.org/wiki/File:Animation_of_54509_YORP_orbit_around_Sun.gif">gif2</a> | ||
</center> | ||
|
||
<Story of={Stories.YORP} /> | ||
The initial configurations of Sun, Earth and the asteriod have been setup, recorded at 20000000x speed for about 5.5 minutes of playback. Use the speed control below to change the playback speed. You can also try changing the frame of reference to see the horseshoe orbit from different perspectives. | ||
|
||
<Controls of={Stories.YORP} /> | ||
<center><Story of={Stories.YORP} /></center> |
11 changes: 0 additions & 11 deletions
11
.storybook/stories/Showcase/HorseshoeOrbit/HorseshoeOrbit.mdx
This file was deleted.
Oops, something went wrong.
47 changes: 26 additions & 21 deletions
47
.storybook/stories/Showcase/HorseshoeOrbit/HorseshoeOrbit.stories.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,43 @@ | ||
import type { Meta, StoryObj } from "@storybook/react"; | ||
import { Simulation } from "../../Simulation"; | ||
import { horseshoe } from "./HorseshoeOrbit"; | ||
import { HorseshoeOrbit, yorp, so16 } from "./HorseshoeOrbit"; | ||
|
||
const meta = { | ||
title: "Showcase/Horseshoe Orbit", | ||
component: Simulation, | ||
component: HorseshoeOrbit, | ||
parameters: { | ||
layout: "centered", | ||
controls: { | ||
disable: true, | ||
}, | ||
}, | ||
tags: [], | ||
argTypes: {}, | ||
argTypes: { | ||
obj: { | ||
table: { | ||
disable: true, | ||
} | ||
}, | ||
name: { | ||
table: { | ||
disable: true, | ||
} | ||
}, | ||
}, | ||
args: {}, | ||
} satisfies Meta<typeof Simulation>; | ||
} satisfies Meta<typeof HorseshoeOrbit>; | ||
|
||
export default meta; | ||
type Story = StoryObj<typeof meta>; | ||
|
||
export const YORP: Story = { | ||
args: { | ||
storyName: "Horseshoe Orbit YORP", | ||
universe: [horseshoe.yorp], | ||
showDebugInfo: true, | ||
controller: "ui", | ||
visType: "3D", | ||
width: 800, | ||
playSpeed: 2, | ||
showTrails: true, | ||
record: true, | ||
looped: true, | ||
recordFor: 332, | ||
recordSpeed: 20000000, | ||
maxTrailLength: 2000, | ||
name: "Horseshoe Orbit YORP", | ||
frameOfRef: "sun-earth", | ||
obj: yorp | ||
}, | ||
}; | ||
|
||
export const SO16: Story = { | ||
args: { | ||
name: "Horseshoe Orbit SO16", | ||
frameOfRef: "sun-earth", | ||
obj: so16, | ||
}, | ||
}; |
Oops, something went wrong.