Equity (Details) - USD ($)
$ / shares in Units, $ in Thousands
1 Months Ended 12 Months Ended
Jul. 20, 2018
Jul. 31, 2018
Dec. 31, 2019
Dec. 31, 2018
Aug. 01, 2019
Jun. 30, 2018
Apr. 30, 2018
Feb. 28, 2018
Jan. 31, 2018
Equity                  
Common stock, authorized (in shares) 150,000,000   150,000,000 150,000,000   79,000,000 78,800,000 75,000,000 65,000,000
Shares authorized 160,000,000                
Common stock, par value (in dollars per share) $ 0.001   $ 0.001 $ 0.001          
Preferred stock, share authorized (in shares) 10,000,000   10,000,000 10,000,000          
Preferred stock, par value (in dollars per share) $ 0.001   $ 0.001 $ 0.001          
Net proceeds after deducting underwriting discounts and commissions and other offering costs       $ 257,866          
Common stock                  
Equity                  
Shares issued (in shares)       12,055,450          
Conversion of Stock, Shares Issued 51,845,438                
Conversion of redeemable convertible preferred stock to common stock (in shares) 51,845,438 51,845,438   51,845,438          
IPO                  
Equity                  
Shares issued (in shares) 12,055,450                
Net proceeds after deducting underwriting discounts and commissions and other offering costs $ 254,300                
Conversion of redeemable convertible preferred stock to common stock (in shares)   131,273              
Overallotment                  
Equity                  
Shares issued (in shares) 1,572,450                
At the market offering                  
Equity                  
Shares issued (in shares)     0            
Percentage of commission         3.00%        
Aggregate offering price         $ 100,000