update astronaut image/bio info
This commit is contained in:
parent
bb5926fd1a
commit
200d86976a
3 changed files with 13 additions and 9 deletions
|
@ -10,7 +10,7 @@ Minimal **Kotlin Multiplatform** project using Jetpack Compose and SwiftUI. Cur
|
|||
* JVM (small Ktor back end service + `Main.kt` in `common` module)
|
||||
|
||||
It makes use of basic API (http://open-notify.org/Open-Notify-API/People-In-Space/) to show list of people currently in
|
||||
space (inspired by https://kousenit.org/2019/12/19/a-few-astronomical-examples-in-kotlin/)! The list is shown on Android
|
||||
space and also the position of the International Space Station (inspired by https://kousenit.org/2019/12/19/a-few-astronomical-examples-in-kotlin/)! The list is shown on Android
|
||||
using **Jetpack Compose**, on iOS using **SwiftUI** and on Web using Kotlin/JS React wrapper.
|
||||
|
||||
Related posts:
|
||||
|
|
|
@ -13,7 +13,11 @@ val personImages = mapOf(
|
|||
"Soichi Noguchi" to "https://pbs.twimg.com/media/Em5EbSoVcAA3R2F?format=jpg&name=medium",
|
||||
"Mark Vande Hei" to "https://www.esa.int/var/esa/storage/images/esa_multimedia/images/2016/09/mark_vande_hei/16121862-1-eng-GB/Mark_Vande_Hei_pillars.jpg",
|
||||
"Oleg Novitskiy" to "https://spaceflight101.com/iss-expedition-50/wp-content/uploads/sites/118/2016/11/jsc2016e165868.jpg",
|
||||
"Pyotr Dubrov" to "https://www.nasa.gov/sites/default/files/styles/full_width_feature/public/thumbnails/image/jsc2021e010288.jpg"
|
||||
"Pyotr Dubrov" to "https://www.nasa.gov/sites/default/files/styles/full_width_feature/public/thumbnails/image/jsc2021e010288.jpg",
|
||||
"Shane Kimbrough" to "https://www.nasa.gov/sites/default/files/styles/full_width_feature/public/thumbnails/image/jsc2021e010824.jpg",
|
||||
"Megan McArthur" to "https://www.nasa.gov/sites/default/files/styles/full_width_feature/public/thumbnails/image/jsc2021e010823.jpg",
|
||||
"Akihiko Hoshide" to "https://www.nasa.gov/sites/default/files/styles/full_width_feature/public/thumbnails/image/jsc2021e010825.jpg",
|
||||
"Thomas Pesquet" to "https://www.nasa.gov/sites/default/files/styles/full_width_feature/public/thumbnails/image/jsc2021e010826.jpg",
|
||||
)
|
||||
|
||||
val personBios = mapOf(
|
||||
|
@ -29,5 +33,9 @@ val personBios = mapOf(
|
|||
"Soichi Noguchi" to "Soichi Noguchi (野口 聡一, Noguchi Sōichi, born 15 April 1965 in Yokohama, Japan) is a Japanese aeronautical engineer and JAXA astronaut. His first spaceflight was as a Mission Specialist aboard STS-114 on 26 July 2005 for NASA's first \"return to flight\" Space Shuttle mission after the Columbia disaster. He was also in space as part of the Soyuz TMA-17 crew and Expedition 22 to the International Space Station (ISS), returning to Earth on 2 June 2010. He is the fifth Japanese astronaut to fly in space and the fourth to fly on the space shuttle. His third flight is onboard the Dragon 2 capsule for the SpaceX Crew-1 mission which launched successfully on November 15, 2020. This makes him one of only three astronauts to fly on three different launch systems.",
|
||||
"Mark Vande Hei" to "Mark Thomas Vande Hei (born November 10, 1966) is a retired United States Army officer and NASA astronaut who served as a flight Engineer for Expedition 53 and 54 on the International Space Station.",
|
||||
"Oleg Novitskiy" to "Oleg Viktorovich Novitskiy (Russian: Олег Викторович Новицкий; born October 12, 1971 in Červień, Belarus) is a former Lieutenant Colonel in the Russian Air Force who logged over 700 hours of flight time and was awarded for bravery. He is currently serving as a Russian cosmonaut with Roskosmos and has participated in multiple expeditions, during which he has spent over 340 days in space.",
|
||||
"Pyotr Dubrov" to "Pyotr Valerievich Dubrov (Russian: Пётр Валерьевич Дубров; born 30 January 1978) is a Russian engineer and cosmonaut selected by Roscosmos in 2012."
|
||||
"Pyotr Dubrov" to "Pyotr Valerievich Dubrov (Russian: Пётр Валерьевич Дубров; born 30 January 1978) is a Russian engineer and cosmonaut selected by Roscosmos in 2012.",
|
||||
"Shane Kimbrough" to "Robert Shane Kimbrough (born June 4, 1967) is a retired United States Army officer, and a NASA astronaut. He was part of the first group of candidates selected for NASA astronaut training following the Space Shuttle Columbia disaster. Kimbrough is a veteran of two spaceflights, the first being a Space Shuttle flight, and the second being a six-month mission to the ISS on board a Russian Soyuz craft. He was the commander of the International Space Station for Expedition 50, and returned to Earth in April 2017.",
|
||||
"Megan McArthur" to "Katherine Megan McArthur (born August 30, 1971) is an American oceanographer, engineer, and a National Aeronautics and Space Administration (NASA) astronaut. She has served as a Capsule Communicator (CAPCOM) for both the space shuttle and space station. Megan McArthur has flown one space shuttle mission, STS-125. She is known as the last person to be hands on with the Hubble Space Telescope via the Canadarm. McArthur has served in a number of positions including working in the Shuttle Avionics Laboratory (SAIL).",
|
||||
"Akihiko Hoshide" to "Akihiko Hoshide (星出 彰彦, Hoshide Akihiko, born December 28, 1968) is a Japanese engineer and JAXA astronaut. On August 30, 2012, Hoshide became the third Japanese astronaut to walk in space.",
|
||||
"Thomas Pesquet" to "Thomas Gautier Pesquet (French pronunciation: \u200B[tɔma gotje pɛskɛ]; born 27 February 1978 in Rouen) is a French aerospace engineer, pilot, and European Space Agency astronaut. Pesquet was selected by ESA as a candidate in May 2009, and he successfully completed his basic training in November 2010. From November 2016 to June 2017, Pesquet was part of Expedition 50 and Expedition 51 as a flight engineer.Pesquet returned to space in April 2021 on board the SpaceX Crew Dragon for a second six-month stay on the ISS.",
|
||||
)
|
||||
|
|
|
@ -59,13 +59,9 @@ class PeopleInSpaceRepository : KoinComponent {
|
|||
// Used by web client atm
|
||||
suspend fun fetchPeople() = peopleInSpaceApi.fetchPeople().people
|
||||
|
||||
fun getPersonBio(personName: String): String {
|
||||
return personBios[personName] ?: ""
|
||||
}
|
||||
fun getPersonBio(personName: String) = personBios[personName] ?: ""
|
||||
fun getPersonImage(personName: String) = personImages[personName] ?: ""
|
||||
|
||||
fun getPersonImage(personName: String): String {
|
||||
return personImages[personName] ?: ""
|
||||
}
|
||||
|
||||
// called from Kotlin/Native clients
|
||||
fun startObservingPeopleUpdates(success: (List<Assignment>) -> Unit) {
|
||||
|
|
Loading…
Reference in a new issue