import Component from '@ember/component';
import { computed } from '@ember/object';
import { alias, or } from '@ember/object/computed';
import { htmlSafe } from '@ember/template';

export default Component.extend({
  tagName: '',
  flight: alias('nearFlight.flight'),
  igcFile: alias('flight.igcFile'),
  pilot: alias('flight.pilot'),
  pilotName: or('flight.{pilot.name,pilotName}'),
  copilot: alias('flight.copilot'),
  copilotName: or('flight.{copilot.name,copilotName}'),
  times: alias('nearFlight.times'),

  colorStripeStyle: computed('nearFlight.color', function () {
    return htmlSafe(`background-color: ${this.nearFlight.color}`);
  }),
});

@@ -189,16 +189,30 @@
 default 
+class extends 
 Componen
@@ -216,16 +216,9 @@
 nent
-.extend(
+ 
 %7B%0A  
@@ -228,24 +228,19 @@
 Name
-: '',%0A  flight: 
+ = '';%0A%0A  @
 alia
@@ -265,21 +265,20 @@
 ht')
-,%0A  igcFile: 
+ flight;%0A  @
 alia
@@ -300,19 +300,21 @@
 le')
-,%0A  pilot: 
+ igcFile;%0A  @
 alia
@@ -334,23 +334,19 @@
 ot')
-,%0A 
  pilot
-Name: 
+;%0A  @
 or('
@@ -380,21 +380,23 @@
 e%7D')
-,%0A  copilot: 
+ pilotName;%0A  @
 alia
@@ -418,19 +418,16 @@
 ot')
-,%0A 
  copilot
 Name
@@ -426,14 +426,13 @@
 ilot
-Name: 
+;%0A  @
 or('
@@ -470,19 +470,25 @@
 e%7D')
-,%0A  times: 
+ copilotName;%0A  @
 alia
@@ -512,31 +512,20 @@
 es')
-,%0A%0A  colorStripeStyle: 
+ times;%0A%0A  @
 comp
@@ -551,19 +551,32 @@
 lor'
-, function 
+)%0A  get colorStripeStyle
 () %7B
@@ -650,11 +650,7 @@
 %0A  %7D
-),%0A%7D);
+%0A%7D
 %0A

Convert to ES6 class