Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

Some style fixes

Joshen Lim95c77e1fbd52
diff --git a/studio/components/interfaces/Billing/EnterpriseRequest.tsx b/studio/components/interfaces/Billing/EnterpriseRequest.tsx
index 6e91502b44f..8fe599509d9 100644
--- a/studio/components/interfaces/Billing/EnterpriseRequest.tsx
+++ b/studio/components/interfaces/Billing/EnterpriseRequest.tsx
@@ -84,39 +84,37 @@ const EnterpriseRequest: FC<Props> = ({ onSelectBack }) => {
enterTo="transform opacity-100 translate-x-0"
>
<div className="space-y-8 w-4/5">
- <div className="relative">
- <BackButton onClick={() => onSelectBack()} />
- <div className="space-y-1">
- <h4 className="text-lg">Customised plans tailored for your business needs</h4>
- <p className="text-scale-1100">
- Let us know a few details and our team will get back to you as soon as possible.
- </p>
- </div>
- <Form
- validateOnBlur
- initialValues={initialValues}
- validate={onValidate}
- onSubmit={onSubmit}
- >
- {({ isSubmitting }: { isSubmitting: boolean }) => (
- <div className="space-y-12 py-16">
- <div className="space-y-4 w-3/5">
- <Input layout="horizontal" label="Name" id="name" name="name" />
- <Input layout="horizontal" label="Email" id="email" name="email" />
- <Input layout="horizontal" label="Company" id="company" name="company" />
- </div>
- <Input.TextArea
- id="message"
- name="message"
- label="Let us know what you intend to use Supabase for"
- />
- <Button htmlType="submit" loading={isSubmitting}>
- Submit request
- </Button>
- </div>
- )}
- </Form>
+ <BackButton onClick={() => onSelectBack()} />
+ <div className="space-y-1">
+ <h4 className="text-lg">Customised plans tailored for your business needs</h4>
+ <p className="text-scale-1100">
+ Let us know a few details and our team will get back to you as soon as possible.
+ </p>
</div>
+ <Form
+ validateOnBlur
+ initialValues={initialValues}
+ validate={onValidate}
+ onSubmit={onSubmit}
+ >
+ {({ isSubmitting }: { isSubmitting: boolean }) => (
+ <div className="space-y-12">
+ <div className="space-y-4 w-3/5">
+ <Input layout="horizontal" label="Name" id="name" name="name" />
+ <Input layout="horizontal" label="Email" id="email" name="email" />
+ <Input layout="horizontal" label="Company" id="company" name="company" />
+ </div>
+ <Input.TextArea
+ id="message"
+ name="message"
+ label="Let us know what you intend to use Supabase for"
+ />
+ <Button htmlType="submit" loading={isSubmitting}>
+ Submit request
+ </Button>
+ </div>
+ )}
+ </Form>
</div>
</Transition>
)
diff --git a/studio/components/interfaces/Billing/PlanSelection/Plans/Plans.tsx b/studio/components/interfaces/Billing/PlanSelection/Plans/Plans.tsx
index d2351bf886c..ec9151ccf62 100644
--- a/studio/components/interfaces/Billing/PlanSelection/Plans/Plans.tsx
+++ b/studio/components/interfaces/Billing/PlanSelection/Plans/Plans.tsx
@@ -49,26 +49,16 @@ const Plans: FC<Props> = ({ plans, currentPlan, onSelectPlan }) => {
(plan.id === STRIPE_PRODUCT_IDS.PRO && currentPlan?.prod_id === STRIPE_PRODUCT_IDS.PRO) ||
(plan.id === STRIPE_PRODUCT_IDS.PRO && currentPlan?.prod_id === STRIPE_PRODUCT_IDS.PAYG)
- const pointers = plan.metadata.features.split('\\n').map((x: string) => x.trim())
-
- console.log('STRIPE_PRODUCT_IDS', STRIPE_PRODUCT_IDS)
- console.log('plans', plans)
-
- // return null
-
return (
- <div
- key={PRICING_META[plan.id].name}
- className="
- relative
- "
- >
- <div className="absolute overflow-hidden w-full h-full left-0 bottom-0 opacity-50">
- {plan.id === STRIPE_PRODUCT_IDS.PRO && <AnimatedGradientBackground />}
- </div>
- <div className="flex flex-col rounded border overflow-hidden">
+ <div key={PRICING_META[plan.id].name} className="relative h-full">
+ {plan.id === STRIPE_PRODUCT_IDS.PRO && (
+ <div className="absolute overflow-hidden w-full h-full left-0 bottom-0 opacity-50">
+ <AnimatedGradientBackground />
+ </div>
+ )}
+ <div className="flex flex-col rounded border overflow-hidden h-full">
{isCurrentPlan && <CurrentSubscriptionBanner />}
- <div className="h-64 px-8 pt-6 bg-white dark:bg-scale-300">
+ <div className="px-8 py-6 bg-white dark:bg-scale-300">
<span
className="inline-flex text-cd font-normal tracking-wide rounded-full text-base text-scale-1200"
id="tier-standard"
@@ -76,12 +66,12 @@ const Plans: FC<Props> = ({ plans, currentPlan, onSelectPlan }) => {
{PRICING_META[plan.id].name}
</span>
<div className="flex items-baseline mt-2">
- <div className="flex flex-col">
+ <div className="flex space-x-2">
{PRICING_META[plan.id].priceMonthly !== undefined ? (
<>
<div className="flex items-end gap-1">
{PRICING_META[plan.id].from && (
- <span className="text-base font-medium text-scale-900">From</span>
+ <span className="text-base font-medium text-scale-1200">From</span>
)}
<div>
<span className="text-2xl">${PRICING_META[plan.id].priceMonthly}</span>
@@ -111,24 +101,12 @@ const Plans: FC<Props> = ({ plans, currentPlan, onSelectPlan }) => {
<p className="text-sm text-scale-1100">{PRICING_META[plan.id].description}</p>
</div>
<div
- className="
- flex-col justify-between flex-1
-
- space-y-6
- border-t
- dark:border-scale-400
-
- bg-scale-100
- dark:bg-scale-300
-
- px-8
- py-6
-
- h-full
-
- hidden
- lg:flex
- "
+ className={[
+ 'flex-col justify-between flex-1',
+ 'space-y-6 border-t dark:border-scale-400',
+ 'bg-scale-100 dark:bg-scale-300',
+ 'px-8 py-6 h-full hidden lg:flex',
+ ].join(' ')}
>
{PRICING_META[plan.id].preface && (
<p className="text-sm text-scale-1200">{PRICING_META[plan.id].preface}</p>
diff --git a/studio/components/interfaces/Billing/Subscription/Subscription.tsx b/studio/components/interfaces/Billing/Subscription/Subscription.tsx
index d24711f5db4..1f184435194 100644
--- a/studio/components/interfaces/Billing/Subscription/Subscription.tsx
+++ b/studio/components/interfaces/Billing/Subscription/Subscription.tsx
@@ -7,12 +7,11 @@ import { Dictionary } from '@supabase/grid'
import { formatBytes } from 'lib/helpers'
import { STRIPE_PRODUCT_IDS } from 'lib/constants'
-import { useStore, useFlag, useSubscriptionStats } from 'hooks'
+import { useStore, useSubscriptionStats } from 'hooks'
import CostBreakdownRow from './CostBreakdownRow'
import { StripeSubscription } from './Subscription.types'
import { deriveFeatureCost, deriveProductCost } from '../PAYGUsage/PAYGUsage.utils'
import { chargeableProducts } from '../PAYGUsage/PAYGUsage.constants'
-import UpgradeButton from './UpgradeButton'
interface Props {
project: any
@@ -80,13 +79,6 @@ const Subscription: FC<Props> = ({
</p>
)}
</div>
- {/* ) : (
- <UpgradeButton
- paid={paid}
- projectRef={project.ref}
- subscriptionStats={subscriptionStats}
- />
- )} */}
</div>
{paid && (
<div className="px-6 pt-4">
diff --git a/studio/components/interfaces/Billing/Subscription/UpgradeButton.tsx b/studio/components/interfaces/Billing/Subscription/UpgradeButton.tsx
index d39467cfcf3..1a8af78ba64 100644
--- a/studio/components/interfaces/Billing/Subscription/UpgradeButton.tsx
+++ b/studio/components/interfaces/Billing/Subscription/UpgradeButton.tsx
@@ -11,7 +11,8 @@ import { CancellationReasons } from './SubcriptionCancellation.constants'
/**
* Generates a Stripe Billing Portal link for a project.
- * To be deprecate after native billing is completely rolled out
+ * This is now deprecated since 180422 since we have native billing
+ * Feel free to delete this file if we'd reckon we no longer need this fallback
*
* @param {Object} props.projectRef Project Ref
* @param {Boolean} props.paid Tier name
diff --git a/studio/components/layouts/BillingLayout.tsx b/studio/components/layouts/BillingLayout.tsx
index 09e4ed4aab6..b0ae2569529 100644
--- a/studio/components/layouts/BillingLayout.tsx
+++ b/studio/components/layouts/BillingLayout.tsx
@@ -15,7 +15,7 @@ const BillingLayout: FC<Props> = ({ children }) => {
<BaseLayout hideHeader hideIconBar>
<div className="flex flex-col h-full w-full">
{/* Header */}
- <div className="h-16 py-2 border-b dark:border-dark flex items-center space-x-3 px-5">
+ <div className="py-4 border-b dark:border-dark flex items-center space-x-3 px-5">
<Link href={`/project/${ui.selectedProject?.ref}/settings/billing`} passHref>
<a className="transition-colors text-scale-900 hover:text-scale-1200">
<IconX size={16} strokeWidth={1.5} />