Mauricio Araujo 2 anni fa
parent
commit
43761de81c

+ 1 - 1
api/server/handlers/billing/plan.go

@@ -17,7 +17,7 @@ type ListPlansHandler struct {
 	handlers.PorterHandlerWriter
 }
 
-// NewListCreditsHandler will create a new ListPlansHandler
+// NewListPlansHandler will create a new ListPlansHandler
 func NewListPlansHandler(
 	config *config.Config,
 	writer shared.ResultWriter,

+ 2 - 0
api/types/billing_metronome.go

@@ -60,11 +60,13 @@ type ListCreditGrantsRequest struct {
 	EffectiveBefore string `json:"effective_before,omitempty"`
 }
 
+// ListCreditGrantsResponse returns the total remaining and granted credits for a customer.
 type ListCreditGrantsResponse struct {
 	RemainingCredits float64 `json:"remaining_credits"`
 	GrantedCredits   float64 `json:"granted_credits"`
 }
 
+// EmbeddableDashboardRequest requests an embeddable customer dashboard to Metronome
 type EmbeddableDashboardRequest struct {
 	// CustomerID is the id of the customer
 	CustomerID uuid.UUID `json:"customer_id,omitempty"`

+ 2 - 2
dashboard/src/main/home/project-settings/BillingPage.tsx

@@ -231,13 +231,14 @@ function BillingPage(): JSX.Element {
                     </Container>
                   </Container>
                 </Fieldset>
+                <Spacer y={2} />
                 <Text size={16}>Current Usage</Text>
                 <Spacer y={1} />
                 <Text color="helper">
                   View the current usage of this billing period.
                 </Text>
                 <Spacer y={1} />{" "}
-                <Container row style={{ width: "100%", height: "70vh" }}>
+                <Container row style={{ width: "100%", height: "80vh" }}>
                   <ParentSize>
                     {({ width, height }) => (
                       <iframe
@@ -255,7 +256,6 @@ function BillingPage(): JSX.Element {
             ) : (
               <Text>This project doesn't have an active billing plan.</Text>
             )}
-            <Spacer y={2} />
           </div>
         </div>
       ) : (