@@ -18,7 +18,7 @@ export const contractorStyles: Record<string, { color: string; mergedInto?: stri
1818const contractorKeyOrder = [
1919 'Northrop Grumman' , 'Boeing' , 'North American Aviation' , 'Douglas Aircraft' ,
2020 'Lockheed Martin' , 'Lockheed Propulsion Co.' , 'Aerojet Rocketdyne' , 'Rocketdyne' ,
21- 'Teledyne Brown Engineering' , 'IBM' ,
21+ 'Teledyne Brown Engineering' , 'IBM' , 'SpaceX' ,
2222] ;
2323
2424export const contractorKey : {
@@ -248,6 +248,10 @@ export function getRocketPriceTotal(parts: Record<string, { priceGroup?: string
248248 return Array . from ( uniquePriceGroups ) . reduce ( ( total , group ) => total + priceGroups [ group ] . amount , 0 ) ;
249249}
250250
251+ export function hasRocketPrices ( parts : Record < string , { priceGroup ?: string } > ) : boolean {
252+ return Object . values ( parts ) . some ( ( part ) => Boolean ( part . priceGroup ) && Boolean ( priceGroups [ part . priceGroup ] ) ) ;
253+ }
254+
251255export function escapeAttr ( value : unknown ) : string {
252256 return String ( value ) . replace ( / & / g, '&' ) . replace ( / " / g, '"' ) ;
253257}
@@ -363,4 +367,14 @@ export const rockets = [
363367 hiddenPartGroups : apolloHiddenPartGroups ,
364368 parts : apolloParts ,
365369 } ,
370+ {
371+ slug : 'falcon' ,
372+ label : 'Falcon 9' ,
373+ title : 'Falcon 9 vertical integration diagram' ,
374+ desc : 'Interactive Falcon 9 diagram colored to show SpaceX vertical integration.' ,
375+ svgPath : path . join ( process . cwd ( ) , 'public' , 'rockets' , 'falcon' , 'falcon-9-diagram-01.svg' ) ,
376+ hiddenPartIds : new Set < string > ( ) ,
377+ hiddenPartGroups : new Set < string > ( ) ,
378+ parts : falconParts ,
379+ } ,
366380] ;
0 commit comments