diff --git a/package-lock.json b/package-lock.json index 2fc31fab0..2990b060e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7,8 +7,8 @@ "name": "@appwrite/console", "dependencies": { "@appwrite.io/console": "^0.5.0", - "@appwrite.io/pink": "0.11.0", - "@appwrite.io/pink-icons": "0.11.0", + "@appwrite.io/pink": "0.16.0", + "@appwrite.io/pink-icons": "0.16.0", "@popperjs/core": "^2.11.8", "@sentry/svelte": "^7.66.0", "@sentry/tracing": "^7.66.0", @@ -167,19 +167,19 @@ } }, "node_modules/@appwrite.io/pink": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@appwrite.io/pink/-/pink-0.11.0.tgz", - "integrity": "sha512-0/ztJxeV6Cy1FnXy2ClLELzDnR4eRtGAhQ24napCg0VwOFevSIc0S7jcRrWVyA6WRuwex4eGiEn2JeYMTq70Xg==", + "version": "0.16.0", + "resolved": "https://registry.npmjs.org/@appwrite.io/pink/-/pink-0.16.0.tgz", + "integrity": "sha512-KprOd+36I0w6PC0x6NJclvyJNpCsjAPcrCHL3QixSX0dZ66wqFE6NitF/KiVVCxbuBaNgjrm7oQ0hr7dt1Sm5Q==", "dependencies": { - "@appwrite.io/pink-icons": "0.11.0", + "@appwrite.io/pink-icons": "0.16.0", "normalize.css": "^8.0.1", "the-new-css-reset": "^1.11.2" } }, "node_modules/@appwrite.io/pink-icons": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@appwrite.io/pink-icons/-/pink-icons-0.11.0.tgz", - "integrity": "sha512-FOvP87m4S17QRQPrLzsSlwrbIeJNJi5RliGUQYONIhmI0PiwE4Xm5LXFE+NqFYsR56w2X3jYdJIHdIdZlH3XjA==" + "version": "0.16.0", + "resolved": "https://registry.npmjs.org/@appwrite.io/pink-icons/-/pink-icons-0.16.0.tgz", + "integrity": "sha512-tWaG5lFXnKzbFbGf4SlxoFYj2yH7kQDejFq+UHdfzBrqteSfZpxIxdNmKHIea1ztcmsat4y+R0ZbVX9iOv+oPw==" }, "node_modules/@babel/code-frame": { "version": "7.23.5", diff --git a/package.json b/package.json index 863f04765..9ff2f2d46 100644 --- a/package.json +++ b/package.json @@ -19,8 +19,8 @@ }, "dependencies": { "@appwrite.io/console": "^0.5.0", - "@appwrite.io/pink": "0.11.0", - "@appwrite.io/pink-icons": "0.11.0", + "@appwrite.io/pink": "0.16.0", + "@appwrite.io/pink-icons": "0.16.0", "@popperjs/core": "^2.11.8", "@sentry/svelte": "^7.66.0", "@sentry/tracing": "^7.66.0", diff --git a/src/lib/elements/forms/label.svelte b/src/lib/elements/forms/label.svelte index 17c1fb922..89adc3f70 100644 --- a/src/lib/elements/forms/label.svelte +++ b/src/lib/elements/forms/label.svelte @@ -6,6 +6,7 @@ hide?: boolean; tooltip?: string; for?: string; + class?: string; } export let required: $$Props['required'] = false; @@ -13,12 +14,14 @@ export let optionalText: $$Props['optionalText'] = undefined; export let hide: $$Props['hide'] = false; export let tooltip: $$Props['tooltip'] = null; + let classes: string = undefined; + export { classes as class }; diff --git a/src/lib/layout/index.ts b/src/lib/layout/index.ts index cf1bd6e4b..afc33bb2c 100644 --- a/src/lib/layout/index.ts +++ b/src/lib/layout/index.ts @@ -19,3 +19,7 @@ export { default as GridHeader } from './gridHeader.svelte'; export { default as ContainerHeader } from './containerHeader.svelte'; export { default as HeaderAlert } from './headerAlert.svelte'; export { default as ContainerButton } from './containerButton.svelte'; +export { default as WizardSecondaryContainer } from './wizardSecondaryContainer.svelte'; +export { default as WizardSecondaryContent } from './wizardSecondaryContent.svelte'; +export { default as WizardSecondaryHeader } from './wizardSecondaryHeader.svelte'; +export { default as WizardSecondaryFooter } from './wizardSecondaryFooter.svelte'; diff --git a/src/lib/layout/wizardSecondaryContainer.svelte b/src/lib/layout/wizardSecondaryContainer.svelte new file mode 100644 index 000000000..7952cbbe8 --- /dev/null +++ b/src/lib/layout/wizardSecondaryContainer.svelte @@ -0,0 +1,20 @@ +
+
+ +
+
+ + diff --git a/src/lib/layout/wizardSecondaryContent.svelte b/src/lib/layout/wizardSecondaryContent.svelte new file mode 100644 index 000000000..6b69d488a --- /dev/null +++ b/src/lib/layout/wizardSecondaryContent.svelte @@ -0,0 +1,11 @@ +
+
+ +
+
+
+
+ +
+
+
diff --git a/src/lib/layout/wizardSecondaryFooter.svelte b/src/lib/layout/wizardSecondaryFooter.svelte new file mode 100644 index 000000000..69e3f8667 --- /dev/null +++ b/src/lib/layout/wizardSecondaryFooter.svelte @@ -0,0 +1,8 @@ +
+
+ +
+
+ +
+
diff --git a/src/lib/layout/wizardSecondaryHeader.svelte b/src/lib/layout/wizardSecondaryHeader.svelte new file mode 100644 index 000000000..e7971f533 --- /dev/null +++ b/src/lib/layout/wizardSecondaryHeader.svelte @@ -0,0 +1,17 @@ + + +
+
+ + +
+ {#if $$slots.description} +

+ {/if} +
diff --git a/src/lib/stores/billing.ts b/src/lib/stores/billing.ts index 81675b4f6..678a10138 100644 --- a/src/lib/stores/billing.ts +++ b/src/lib/stores/billing.ts @@ -114,7 +114,7 @@ export type TierData = { export const tierFree: TierData = { name: 'Starter', - description: 'For personal, passion projects.' + description: 'For personal hobby projects of small scale and students.' }; export const tierPro: TierData = { diff --git a/src/routes/console/create-organization/+page.svelte b/src/routes/console/create-organization/+page.svelte new file mode 100644 index 000000000..2a16c4eef --- /dev/null +++ b/src/routes/console/create-organization/+page.svelte @@ -0,0 +1,93 @@ + + + + Create organization + +
console.log('test')}> + + + + +
    +
  • + + +
    +

    + {tierFree.name} +

    +

    {tierFree.description}

    +

    + {formatCurrency(freePlan?.price ?? 0)} +

    +
    +
    +
    +
  • + +
  • + + +
    +

    + {tierPro.name} +

    +

    + {tierPro.description} +

    +

    + {formatCurrency(proPlan?.price ?? 0)} per member/month + usage +

    +
    +
    +
    +
  • +
+
+ +
+ Lorem ipsum dolor sit amet consectetur adipisicing elit. Recusandae, incidunt! +
+
+
+ + + + + +
diff --git a/src/routes/console/create-organization/store.ts b/src/routes/console/create-organization/store.ts new file mode 100644 index 000000000..613259fe0 --- /dev/null +++ b/src/routes/console/create-organization/store.ts @@ -0,0 +1,28 @@ +import { BillingPlan } from '$lib/constants'; +import type { WizardStepsType } from '$lib/layout/wizard.svelte'; +import type { Tier } from '$lib/stores/billing'; +import { writable } from 'svelte/store'; + +export const createOrgSteps = writable(new Map()); +export const createOrganizationFinalAction = writable('Start trial'); + +export const createOrganization = writable<{ + id?: string; + name: string; + billingPlan: Tier; + paymentMethodId: string; + billingAddressId: string; + collaborators?: string[]; + billingBudget?: number; + taxId?: string; + couponCode?: string; +}>({ + id: null, + name: null, + billingPlan: BillingPlan.PRO, + paymentMethodId: null, + collaborators: [], + billingAddressId: null, + taxId: null, + couponCode: null +});