diff --git a/src/lib/components/labelCard.svelte b/src/lib/components/labelCard.svelte index 8c5ab9bc80..6ee4b6f246 100644 --- a/src/lib/components/labelCard.svelte +++ b/src/lib/components/labelCard.svelte @@ -38,9 +38,11 @@ {disabled} title={title ?? slotTitle?.innerText} bind:group> -

- -

+ {#if $$slots.default} +

+ +

+ {/if} {tooltipText} diff --git a/src/lib/layout/wizard.svelte b/src/lib/layout/wizard.svelte index 1e8dcaca11..fe037c4124 100644 --- a/src/lib/layout/wizard.svelte +++ b/src/lib/layout/wizard.svelte @@ -3,6 +3,7 @@ import { trackEvent } from '$lib/actions/analytics'; import WizardExitModal from './wizardExitModal.svelte'; import { goto } from '$app/navigation'; + import { wizard } from '$lib/stores/wizard'; type $$Props = | { @@ -13,6 +14,7 @@ invertColumns?: boolean; hideAside?: boolean; hideFooter?: boolean; + onExit?: () => void; } | { title: string; @@ -22,6 +24,7 @@ invertColumns?: boolean; hideAside?: boolean; hideFooter?: boolean; + onExit?: () => void; }; export let title: $$Props['title'] = ''; @@ -31,6 +34,7 @@ export let invertColumns: $$Props['invertColumns'] = false; export let hideAside = false; export let hideFooter = false; + export let onExit: $$Props['onExit'] = undefined; function handleKeydown(event: KeyboardEvent) { if (event.key === 'Escape') { @@ -83,6 +87,14 @@ trackEvent('wizard_exit', { from: 'prompt' }); + + wizard.hide(); + if (onExit) { + onExit(); + + // clear exit + onExit = null; + } }}> Are you sure you want to exit from this process? All data will be deleted. This action diff --git a/src/routes/(console)/project-[project]/overview/onboard.svelte b/src/routes/(console)/project-[project]/overview/onboard.svelte index d700bb299c..9aa8269347 100644 --- a/src/routes/(console)/project-[project]/overview/onboard.svelte +++ b/src/routes/(console)/project-[project]/overview/onboard.svelte @@ -1,8 +1,7 @@ + +
+
+
+ +
+ {#if status} + + + {/if} +
+ +
+
+
+ + diff --git a/src/routes/(console)/project-[project]/overview/platforms/components/OnboardingPlatformCard.svelte b/src/routes/(console)/project-[project]/overview/platforms/components/OnboardingPlatformCard.svelte new file mode 100644 index 0000000000..126a08b6e2 --- /dev/null +++ b/src/routes/(console)/project-[project]/overview/platforms/components/OnboardingPlatformCard.svelte @@ -0,0 +1,63 @@ + + +
+
+ +
+
+ + diff --git a/src/routes/(console)/project-[project]/overview/platforms/createAndroid.svelte b/src/routes/(console)/project-[project]/overview/platforms/createAndroid.svelte index 2f9bf8322f..928d56810d 100644 --- a/src/routes/(console)/project-[project]/overview/platforms/createAndroid.svelte +++ b/src/routes/(console)/project-[project]/overview/platforms/createAndroid.svelte @@ -1,46 +1,247 @@ - + +
+ + + {#if !isPlatformCreated} +
+ + + + + + + + + + +
+ {:else} + + + + + + + {$createPlatform.name} ({$createPlatform.key}) + + + + + + {/if} + + + {#if isPlatformCreated} +
+ + + 1. Clone the starter kit from GitHub using the terminal or Android + Studio. + + + +
+ +
+ + 2. Open the file and update the configuration + settings. + + +
+ +
+ + 3. Run the app on a connected device or emulator, then click the button to verify the setup. +
+
+ {/if} +
+ + + + + + + + + + + + + + {#if !connectionSuccessful} + + Waiting for connection... + {:else} + +
+ Congratulations! + + You connected your app successfully. +
+ {/if} +
+
+
+
+ + + + +
+ + diff --git a/src/routes/(console)/project-[project]/overview/platforms/createApple.svelte b/src/routes/(console)/project-[project]/overview/platforms/createApple.svelte index 9da9fd9347..011435d210 100644 --- a/src/routes/(console)/project-[project]/overview/platforms/createApple.svelte +++ b/src/routes/(console)/project-[project]/overview/platforms/createApple.svelte @@ -1,47 +1,271 @@ - + +
+ + + + {#each Object.entries(platforms) as [key, value]} +
+ + +
+ {/each} +
+ + + {#if !isPlatformCreated} +
+ + + + + + + + + + +
+ {:else} + + + + + + + {$createPlatform.name} ({$createPlatform.key}) + + + + + + {/if} + + + {#if isPlatformCreated} +
+ + + 1. Clone the starter kit from GitHub using the terminal or XCode. + + + +
+ +
+ + 2. Open the file and + update the configuration settings. + + +
+ +
+ + 3. Run the app on a connected device or simulator, then click the button to verify the setup. +
+
+ {/if} +
+ + + + + + + + + + + + + + {#if !connectionSuccessful} + + Waiting for connection... + {:else} + +
+ Congratulations! + + You connected your app successfully. +
+ {/if} +
+
+
+
+ + + + +
+ + diff --git a/src/routes/(console)/project-[project]/overview/platforms/createFlutter.svelte b/src/routes/(console)/project-[project]/overview/platforms/createFlutter.svelte index 3a6bac0322..adbd189a98 100644 --- a/src/routes/(console)/project-[project]/overview/platforms/createFlutter.svelte +++ b/src/routes/(console)/project-[project]/overview/platforms/createFlutter.svelte @@ -1,47 +1,329 @@ - + +
+ + + + {#each Object.entries(platforms) as [key, value]} +
+ + +
+ {/each} +
+ + + {#if !isPlatformCreated} +
+ + + + + + + + + + +
+ {:else} + + + + + + + {$createPlatform.name} ({$createPlatform.key}) + + + + + + {/if} + + + {#if isPlatformCreated} +
+ + + 1. Clone the starter kit from GitHub using the terminal, Android Studio + or VSCode. + + + +
+ +
+ + 2. Open the file and update the configuration settings. + + +
+ +
+ + 3. Run the app on a connected device or simulator, then click the button to verify the setup. +
+
+ {/if} +
+ + + + + + + + + + + + + + {#if !connectionSuccessful} + + Waiting for connection... + {:else} + +
+ Congratulations! + + You connected your app successfully. +
+ {/if} +
+
+
+
+ + + + +
+ + diff --git a/src/routes/(console)/project-[project]/overview/platforms/createReactNative.svelte b/src/routes/(console)/project-[project]/overview/platforms/createReactNative.svelte index 1751468bfc..325b6b3c5d 100644 --- a/src/routes/(console)/project-[project]/overview/platforms/createReactNative.svelte +++ b/src/routes/(console)/project-[project]/overview/platforms/createReactNative.svelte @@ -1,47 +1,296 @@ - + +
+ + + + {#each Object.entries(platforms) as [key, value]} +
+ + +
+ {/each} +
+ + + {#if !isPlatformCreated} +
+ + + + + + + + + + +
+ {:else} + + + + + + + {$createPlatform.name} ({$createPlatform.key}) + + + + + + {/if} + + + {#if isPlatformCreated} +
+ + + 1. Clone the starter kit from GitHub using the terminal or VSCode. + + + +
+ +
+ + 2. Open the file and update the configuration settings. + + +
+ +
+ + 3. Run the app on a connected device or simulator, then click the button to verify the setup. +
+
+ {/if} +
+ + + + + + + + + + + + + + {#if !connectionSuccessful} + + Waiting for connection... + {:else} + +
+ Congratulations! + + You connected your app successfully. +
+ {/if} +
+
+
+
+ + + + +
+ + diff --git a/src/routes/(console)/project-[project]/overview/platforms/createWeb.svelte b/src/routes/(console)/project-[project]/overview/platforms/createWeb.svelte deleted file mode 100644 index ca38a161f0..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/createWeb.svelte +++ /dev/null @@ -1,47 +0,0 @@ - - - diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step1.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step1.svelte deleted file mode 100644 index bdd6b79a15..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step1.svelte +++ /dev/null @@ -1,60 +0,0 @@ - - - - Android registration - - - - - diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step2.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step2.svelte deleted file mode 100644 index a2c5dd1fb2..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step2.svelte +++ /dev/null @@ -1,18 +0,0 @@ - - - - Install -

First, add this to your root level build.gradle file.

- -

And add this to your project's build.gradle file.

- -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step3.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step3.svelte deleted file mode 100644 index e2c956664b..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/android/step3.svelte +++ /dev/null @@ -1,41 +0,0 @@ - - - - Initialize - -

Initialize your SDK

-

- Initialize your SDK by pointing the client to your Appwrite project using your Project ID. -

-
- -
-
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step1.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step1.svelte deleted file mode 100644 index adc7e5a04d..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step1.svelte +++ /dev/null @@ -1,83 +0,0 @@ - - - - Apple registration - - -

Choose an Apple platform

-
- (platform = PlatformType.Appleios)} - selected={platform === PlatformType.Appleios}> - iOS - - (platform = PlatformType.Applemacos)} - selected={platform === PlatformType.Applemacos}> - macOS - - (platform = PlatformType.Applewatchos)} - selected={platform === PlatformType.Applewatchos}> - watchOS - - (platform = PlatformType.Appletvos)} - selected={platform === PlatformType.Appletvos}> - tvOS - -
- - -
-
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step2.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step2.svelte deleted file mode 100644 index d77381e5bb..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step2.svelte +++ /dev/null @@ -1,81 +0,0 @@ - - - - Install -
- (method = Method.Xcode)} selected={method === Method.Xcode}> - Xcode - - (method = Method.Swift)} selected={method === Method.Swift}> - Swift Packages - -
-
- {#if method === Method.Xcode} -
    -
  1. - - In the menu bar under Select File, select Add Packages - -
  2. -
  3. - - Search for the Appwrite SDK with the URL - - https://github.com/appwrite/sdk-for-apple - - -
  4. -
  5. - In the right panel, select your target project and add your desired version - rules -
  6. -
  7. - - Select Add Package and wait for package resolution to complete - -
  8. -
  9. - - Make sure the Appwrite package product is checked and select Add Package - again - -
  10. -
- {:else if method === Method.Swift} -

Add this to your Package.swift file.

- -

Then add the dependency to your target.

- - {/if} -
-
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step3.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step3.svelte deleted file mode 100644 index 8ae1e3d869..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/apple/step3.svelte +++ /dev/null @@ -1,48 +0,0 @@ - - - - Initialize - -

Initialize your SDK

-

- Initialize your SDK by pointing the client to your Appwrite project using your - Project ID - . -

- -

- Before sending any API calls to your new Appwrite project, make sure your device or emulator - has network access to your Appwrite project's hostname or IP address. -

- {#if showAlert && !isCloud} -
- (showAlert = false)}> - For self-hosted solutions - When connecting to a locally hosted Appwrite project from an emulator or a mobile device, - you should use the private IP of the device running your Appwrite project as the hostname - of the endpoint instead of localhost. You can also use a service like ngrok to proxy - the Appwrite server. - -
- {/if} -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step1.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step1.svelte deleted file mode 100644 index e9bb561654..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step1.svelte +++ /dev/null @@ -1,199 +0,0 @@ - - - - {registee} registration - -
- (platform = PlatformType.Flutterandroid)} - selected={platform === PlatformType.Flutterandroid}> - Android - - (platform = PlatformType.Flutterios)} - selected={platform === PlatformType.Flutterios}> - iOS - - (platform = PlatformType.Flutterlinux)} - selected={platform === PlatformType.Flutterlinux}> - Linux - - (platform = PlatformType.Fluttermacos)} - selected={platform === PlatformType.Fluttermacos}> - macOS - - (platform = PlatformType.Flutterwindows)} - selected={platform === PlatformType.Flutterwindows}> - Windows - - (platform = PlatformType.Flutterweb)} - selected={platform === PlatformType.Flutterweb}> - Web - -
-
- - - - {#if platform === PlatformType.Flutterweb} -
- - -
- {#each suggestions as suggestion} - ($createPlatform.hostname = suggestion)}> - {suggestion} - - {/each} -
-
- {:else} - - {/if} -
-
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step2.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step2.svelte deleted file mode 100644 index 27d4667f33..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step2.svelte +++ /dev/null @@ -1,25 +0,0 @@ - - - - Install - -

- Add Appwrite SDK to your package's pubspec.yaml file. You can - view an example here. -

- -

- You can also install the SDK using the Dart package manager from your terminal. -

-
- -
-
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step3.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step3.svelte deleted file mode 100644 index 2a0a1b97f8..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/flutter/step3.svelte +++ /dev/null @@ -1,57 +0,0 @@ - - - - Initialize - -

Initialize your SDK

-

- Initialize your SDK by pointing the client to your Appwrite project using your - Project ID -

-
- -
-

- Before sending any API calls to your new Appwrite project, make sure your device or emulator - has network access to your Appwrite project's hostname or IP address. -

- {#if showAlert && !isCloud} -
- (showAlert = false)}> - For self-hosted solutions - When connecting to a locally hosted Appwrite project from an emulator or a mobile device, - you should use the private IP of the device running your Appwrite project as the hostname - of the endpoint instead of localhost. You can also use a service like ngrok to proxy - the Appwrite server. - -
- {/if} -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step1.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step1.svelte deleted file mode 100644 index 77b2daf346..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step1.svelte +++ /dev/null @@ -1,106 +0,0 @@ - - - - {registee} registration - -
- (platform = PlatformType.Reactnativeandroid)} - selected={platform === PlatformType.Reactnativeandroid}> - Android - - (platform = PlatformType.Reactnativeios)} - selected={platform === PlatformType.Reactnativeios}> - iOS - -
-
- - - - - -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step2.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step2.svelte deleted file mode 100644 index 76b2bdb3cd..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step2.svelte +++ /dev/null @@ -1,13 +0,0 @@ - - - - Install - -

Install the Appwrite SDK for React Native and required dependencies.

- -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step3.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step3.svelte deleted file mode 100644 index 13d20b5a0d..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/react-native/step3.svelte +++ /dev/null @@ -1,58 +0,0 @@ - - - - Initialize - -

Initialize your SDK

-

- Initialize your SDK by pointing the client to your Appwrite project using your Project ID -

-
- -
-

- Before sending any API calls to your new Appwrite project, make sure your device or emulator - has network access to your Appwrite project's hostname or IP address. -

- {#if showAlert && !isCloud} -
- (showAlert = false)}> - For self-hosted solutions - When connecting to a locally hosted Appwrite project from an emulator or a mobile device, - you should use the private IP of the device running your Appwrite project as the hostname - of the endpoint instead of localhost. You can also use a service like ngrok to proxy - the Appwrite server. - -
- {/if} -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step1.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step1.svelte deleted file mode 100644 index 661b2472de..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step1.svelte +++ /dev/null @@ -1,84 +0,0 @@ - - - - Hostname registration - - -
- -
- {#each suggestions as suggestion} - ($createPlatform.hostname = suggestion)}> - {suggestion} - - {/each} -
-
- - Using wildcard hostnames in production can become insecure. You can read about - - Cross-Origin Resource Sharing (CORS) for more information. - -
-
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step2.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step2.svelte deleted file mode 100644 index 9c21ccc48a..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step2.svelte +++ /dev/null @@ -1,64 +0,0 @@ - - - - Install - - Choose your preferred method of installation -
- (method = Method.NPM)} selected={method === Method.NPM}> - NPM - - (method = Method.CDN)} selected={method === Method.CDN}> - CDN - -
-
- {#if method === Method.NPM} -

- Use NPM (node package manager) from your command line to add Appwrite SDK - to your project. -

- -

- If you're using a bundler like Vite - or - Rollup, import Appwrite as a module. -

- - {:else if method === Method.CDN} -

Add the following script tags to install Appwrite with a CDN.

- - {/if} -
diff --git a/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step3.svelte b/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step3.svelte deleted file mode 100644 index e9b8202087..0000000000 --- a/src/routes/(console)/project-[project]/overview/platforms/wizard/web/step3.svelte +++ /dev/null @@ -1,38 +0,0 @@ - - - - Initialize SDK - -

Initialize your SDK

-

- Initialize your SDK by pointing the client to your Appwrite project using your Project ID. -

-
- -
-