Feroze Mohideen 2 år sedan
förälder
incheckning
36742e6f82

+ 3 - 3
dashboard/src/main/home/app-dashboard/app-view/RevisionsList.tsx

@@ -390,7 +390,7 @@ const RevisionHeader = styled.div`
     cursor: pointer;
     border-radius: 20px;
     transform: ${(props: { showRevisions: boolean; isCurrent: boolean }) =>
-      props.showRevisions ? "" : "rotate(-90deg)"};
+    props.showRevisions ? "" : "rotate(-90deg)"};
     transition: transform 0.1s ease;
   }
 `;
@@ -431,7 +431,7 @@ const Tr = styled.tr`
     props.selected ? "#ffffff11" : ""};
   :hover {
     background: ${(props: { disableHover?: boolean; selected?: boolean }) =>
-      props.disableHover ? "" : "#ffffff22"};
+    props.disableHover ? "" : "#ffffff22"};
   }
 `;
 
@@ -463,7 +463,7 @@ const RollbackButton = styled.div`
     props.disabled ? "#aaaabbee" : "#616FEEcc"};
   :hover {
     background: ${(props: { disabled: boolean }) =>
-      props.disabled ? "" : "#405eddbb"};
+    props.disabled ? "" : "#405eddbb"};
   }
 `;
 

+ 3 - 4
dashboard/src/main/home/app-dashboard/create-app/CreateApp.tsx

@@ -143,7 +143,7 @@ const CreateApp: React.FC<CreateAppProps> = ({ history }) => {
       const validatedAppProto = await validateApp(data);
       setValidatedAppProto(validatedAppProto);
 
-      if (source?.type === "github") {
+      if (source.type === "github") {
         setShowGHAModal(true);
         return;
       }
@@ -447,9 +447,8 @@ const CreateApp: React.FC<CreateAppProps> = ({ history }) => {
                             }
                           >
                             {detectedServices.count > 0
-                              ? `Detected ${detectedServices.count} service${
-                                  detectedServices.count > 1 ? "s" : ""
-                                } from porter.yaml.`
+                              ? `Detected ${detectedServices.count} service${detectedServices.count > 1 ? "s" : ""
+                              } from porter.yaml.`
                               : `Could not detect any services from porter.yaml. Make sure it exists in the root of your repo.`}
                           </Text>
                         </AppearingDiv>

+ 1 - 4
dashboard/src/main/home/app-dashboard/validate-apply/services-settings/tabs/CustomDomains.tsx

@@ -1,19 +1,16 @@
 import React from "react";
 import Button from "components/porter/Button";
 import styled from "styled-components";
-import Input from "components/porter/Input";
 import Spacer from "components/porter/Spacer";
 import { useFieldArray, useFormContext } from "react-hook-form";
 import { PorterAppFormData } from "lib/porter-apps";
-import { ClientDomains } from "lib/porter-apps/values";
 import { ControlledInput } from "components/porter/ControlledInput";
 
 interface Props {
   index: number;
-  customDomains: ClientDomains;
 }
 
-const CustomDomains: React.FC<Props> = ({ index, customDomains }) => {
+const CustomDomains: React.FC<Props> = ({ index }) => {
   const { control, register } = useFormContext<PorterAppFormData>();
   const { remove, append, fields } = useFieldArray({
     control,

+ 1 - 1
dashboard/src/main/home/app-dashboard/validate-apply/services-settings/tabs/Health.tsx

@@ -56,7 +56,7 @@ const Health: React.FC<HealthProps> = ({ index, service }) => {
               "You may only edit this field in your porter.yaml."
             }
           >
-            <Text color="helper">Enable Liveness Probe</Text>
+            <Text color="helper">Enable health checks</Text>
           </Checkbox>
         )}
       />

+ 3 - 4
dashboard/src/main/home/app-dashboard/validate-apply/services-settings/tabs/Networking.tsx

@@ -6,7 +6,6 @@ import { Controller, useFormContext } from "react-hook-form";
 import { PorterAppFormData } from "lib/porter-apps";
 import Checkbox from "components/porter/Checkbox";
 import Text from "components/porter/Text";
-import AnimateHeight from "react-animate-height";
 import CustomDomains from "./CustomDomains";
 
 type NetworkingProps = {
@@ -66,7 +65,7 @@ const Networking: React.FC<NetworkingProps> = ({ index, service }) => {
         control={control}
         render={({ field: { value, onChange } }) => (
           <Checkbox
-            checked={value}
+            checked={!value}
             disabled={service.config.private.readOnly}
             toggleChecked={() => {
               onChange(!value);
@@ -75,7 +74,7 @@ const Networking: React.FC<NetworkingProps> = ({ index, service }) => {
               "You may only edit this field in your porter.yaml."
             }
           >
-            <Text color="helper">Private Service</Text>
+            <Text color="helper">Expose to external traffic</Text>
           </Checkbox>
         )}
       />
@@ -94,7 +93,7 @@ const Networking: React.FC<NetworkingProps> = ({ index, service }) => {
             </a>
           </Text>
           <Spacer y={0.5} />
-          <CustomDomains index={index} customDomains={service.config.domains} />
+          <CustomDomains index={index} />
           <Spacer y={0.5} />
         </>
       )}