docs: added a feedback component in quickstart guides (#2894)

* docs: added a feedback component in quickstart guides

* docs: added feedback to admin docs
This commit is contained in:
Shahed Nasser
2022-12-23 16:54:18 +02:00
committed by GitHub
parent 1de91693fc
commit b0e5769e27
53 changed files with 162 additions and 101 deletions

View File

@@ -14,7 +14,7 @@ Through Medusa's flexible plugin system, it is possible to add a search engine t
### Medusa Components
It is required to have a Medusa server installed before starting with this documentation. If not, please follow along with the [quickstart guide](../quickstart/quick-start.md) to get started in minutes.
It is required to have a Medusa server installed before starting with this documentation. If not, please follow along with the [quickstart guide](../quickstart/quick-start.mdx) to get started in minutes.
Furthermore, its highly recommended to ensure your Medusa server is configured to work with Redis. As Medusa uses Redis for the event queue internally, configuring Redis ensures that the search indices in Algolia are updated whenever products on the Medusa server are updated. You can follow [this documentation to install Redis](../tutorial/0-set-up-your-development-environment.mdx#redis) and then [configure it on your Medusa server](../usage/configurations.md#redis).
@@ -152,7 +152,7 @@ This feature is only available if you have Redis installed and configured with y
## Add Search to your Storefront
In this section, youll learn how to add the UI on your storefront to allow searching with Algolia. This section has instructions for Medusas [Next.js](../starters/nextjs-medusa-starter.md) storefront as well as React-based frameworks such as the [Gatsby](../starters/gatsby-medusa-starter.md) storefront.
In this section, youll learn how to add the UI on your storefront to allow searching with Algolia. This section has instructions for Medusas [Next.js](../starters/nextjs-medusa-starter.mdx) storefront as well as React-based frameworks such as the [Gatsby](../starters/gatsby-medusa-starter.mdx) storefront.
### Storefront Prerequisites
@@ -160,7 +160,7 @@ It is assumed you already have a storefront set up and working with the Medusa s
:::tip
If you dont have a storefront set up, you can use the [Gatsby](../starters/gatsby-medusa-starter.md) or [Next.js](../starters/nextjs-medusa-starter.md) storefronts Medusa provides.
If you dont have a storefront set up, you can use the [Gatsby](../starters/gatsby-medusa-starter.mdx) or [Next.js](../starters/nextjs-medusa-starter.mdx) storefronts Medusa provides.
:::

View File

@@ -12,9 +12,9 @@ You can integrate Klarna into Medusa using the [official plugin](https://github.
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../quickstart/quick-start.md).
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../quickstart/quick-start.mdx).
In addition, youll need to use the [Medusa Admin](../admin/quickstart.md) to enable the payment provider in later steps. You can alternatively use the [REST APIs](/api/admin/#tag/Region/operation/PostRegionsRegionPaymentProviders).
In addition, youll need to use the [Medusa Admin](../admin/quickstart.mdx) to enable the payment provider in later steps. You can alternatively use the [REST APIs](/api/admin/#tag/Region/operation/PostRegionsRegionPaymentProviders).
### Needed Accounts

View File

@@ -14,7 +14,7 @@ Through Medusa's flexible plugin system, it is possible to add a search engine t
### Medusa Components
It is required to have a Medusa server installed before starting with this documentation. If not, please follow along with the [quickstart guide](../quickstart/quick-start.md) to get started in minutes.
It is required to have a Medusa server installed before starting with this documentation. If not, please follow along with the [quickstart guide](../quickstart/quick-start.mdx) to get started in minutes.
Furthermore, its highly recommended to ensure your Medusa server is configured to work with Redis. As Medusa uses Redis for the event queue internally, configuring Redis ensures that the search indices in MeiliSearch are updated whenever products on the Medusa server are updated. You can follow [this documentation to install Redis](../tutorial/0-set-up-your-development-environment.mdx#redis) and then [configure it on your Medusa server](../usage/configurations.md#redis).
@@ -107,7 +107,7 @@ This feature is only available if you have Redis installed and configured with y
## Add Search to your Storefront
In this section, youll learn how to add the UI on your storefront to allow searching with MeiliSearch. This section has instructions for Medusas [Next.js](../starters/nextjs-medusa-starter.md) storefront as well as React-based frameworks such as the [Gatsby storefront](../starters/gatsby-medusa-starter.md).
In this section, youll learn how to add the UI on your storefront to allow searching with MeiliSearch. This section has instructions for Medusas [Next.js](../starters/nextjs-medusa-starter.mdx) storefront as well as React-based frameworks such as the [Gatsby storefront](../starters/gatsby-medusa-starter.mdx).
### Storefront Prerequisites
@@ -115,7 +115,7 @@ It is assumed you already have a storefront set up and working with the Medusa s
:::tip
If you dont have a storefront set up, you can use the [Gatsby](../starters/gatsby-medusa-starter.md) or [Next.js](../starters/nextjs-medusa-starter.md) storefronts Medusa provides.
If you dont have a storefront set up, you can use the [Gatsby](../starters/gatsby-medusa-starter.mdx) or [Next.js](../starters/nextjs-medusa-starter.mdx) storefronts Medusa provides.
:::

View File

@@ -10,7 +10,7 @@ Medusa provides three different options to handle your file storage. This docume
## Prerequisites
A Medusa server is required to be set up before following along with this document. You can follow the [quickstart guide](../quickstart/quick-start.md) to get started in minutes.
A Medusa server is required to be set up before following along with this document. You can follow the [quickstart guide](../quickstart/quick-start.mdx) to get started in minutes.
## Set up MinIO
@@ -117,7 +117,7 @@ If you have multiple storage plugins configured, the last plugin declared in the
## Test it Out
Run your Medusa server alongside the [Medusa Admin](../admin/quickstart.md) to try out your new file service. Upon editing or creating products, you can now upload thumbnails and images, that are stored in a MinIO server.
Run your Medusa server alongside the [Medusa Admin](../admin/quickstart.mdx) to try out your new file service. Upon editing or creating products, you can now upload thumbnails and images, that are stored in a MinIO server.
![Image Uploaded on Admin](https://res.cloudinary.com/dza7lstvk/image/upload/v1668000429/Medusa%20Docs/MinIO/alabX2i_dzg2mh.png)
@@ -183,7 +183,7 @@ Then, add two new options to the plugins options in `medusa-config.js`:
## Next.js Storefront Configuration
If youre using a [Next.js](../starters/nextjs-medusa-starter.md) storefront, you need to add an additional configuration that adds the MinIO domain name into the configured images domain names. This is because all URLs of product images will be from the MinIO server.
If youre using a [Next.js](../starters/nextjs-medusa-starter.mdx) storefront, you need to add an additional configuration that adds the MinIO domain name into the configured images domain names. This is because all URLs of product images will be from the MinIO server.
If this configuration is not added, youll receive the error ["next/image Un-configured Host”](https://nextjs.org/docs/messages/next-image-unconfigured-host).

View File

@@ -20,7 +20,7 @@ Webhooks are used in scenarios where the customer might leave the page during th
Additionally, you need a Medusa server installed and set up. If not, you can follow the [quickstart guide](https://docs.medusajs.com/quickstart/quick-start) to get started.
You also need [Medusa Admin](../admin/quickstart.md) installed to enable PayPal as a payment provider. You can alternatively use the [REST APIs](https://docs.medusajs.com/api/admin).
You also need [Medusa Admin](../admin/quickstart.mdx) installed to enable PayPal as a payment provider. You can alternatively use the [REST APIs](https://docs.medusajs.com/api/admin).
## Medusa Server
@@ -76,7 +76,7 @@ This step is required for you to be able to use PayPal as a payment provider in
### Admin Prerequisites
If you dont have a Medusa admin installed, make sure to follow along with [the guide on how to install it](../admin/quickstart.md) before continuing with this section.
If you dont have a Medusa admin installed, make sure to follow along with [the guide on how to install it](../admin/quickstart.mdx) before continuing with this section.
### Add PayPal to Regions
@@ -115,7 +115,7 @@ In Medusa, by default, payments are authorized during checkout, but the payment
### Add to Next.js Storefront
Medusa has a Next.js storefront that you can easily use with your Medusa server. If you dont have the storefront installed, you can follow [this quickstart guide](../starters/nextjs-medusa-starter.md).
Medusa has a Next.js storefront that you can easily use with your Medusa server. If you dont have the storefront installed, you can follow [this quickstart guide](../starters/nextjs-medusa-starter.mdx).
In your `.env.local` file (or the file youre using for your environment variables), add the following variable:
@@ -133,7 +133,7 @@ You can test out the payment with PayPal using your sandbox account.
### Add to Gatsby Storefront
Medusa also has a Gatsby storefront that you can use as your ecommerce storefront. If you dont have the storefront installed, you can follow [this quickstart guide](../starters/gatsby-medusa-starter.md).
Medusa also has a Gatsby storefront that you can use as your ecommerce storefront. If you dont have the storefront installed, you can follow [this quickstart guide](../starters/gatsby-medusa-starter.mdx).
In your `.env.development` file (or the file youre using for your environment variables) add the following variable with its value set to the Client ID:

View File

@@ -12,7 +12,7 @@ Medusa provides three different options to handle your file storage. This docume
### Medusa Server
A Medusa server is required to be set up before following along with this document. You can follow the [quickstart guide](../quickstart/quick-start.md) to get started in minutes.
A Medusa server is required to be set up before following along with this document. You can follow the [quickstart guide](../quickstart/quick-start.mdx) to get started in minutes.
### Required Accounts
@@ -165,7 +165,7 @@ Run your Medusa server with the following command:
npm run start
```
Then, you can either test the plugin using the [REST APIs](https://docs.medusajs.com/api/store) or using the [Medusa Admin](../admin/quickstart.md).
Then, you can either test the plugin using the [REST APIs](https://docs.medusajs.com/api/store) or using the [Medusa Admin](../admin/quickstart.mdx).
On the Medusa Admin, create a new product and, in the Images section, upload an image then click Save. If the integration was successful, the product image will be uploaded successfully.
@@ -177,7 +177,7 @@ You can also check that the image was uploaded on the S3 buckets page.
## Next.js Storefront Configuration
If youre using a [Next.js](../starters/nextjs-medusa-starter.md) storefront, you need to add an additional configuration that adds the S3 bucket domain name into the configured images domain names. This is because all URLs of product images will be from the S3 bucket.
If youre using a [Next.js](../starters/nextjs-medusa-starter.mdx) storefront, you need to add an additional configuration that adds the S3 bucket domain name into the configured images domain names. This is because all URLs of product images will be from the S3 bucket.
If this configuration is not added, youll receive the error ["next/image Un-configured Host”](https://nextjs.org/docs/messages/next-image-unconfigured-host).
@@ -205,4 +205,4 @@ Where `<BUCKET_NAME>` is the name of the S3 bucket youre using.
- Check out [more plugins](https://github.com/medusajs/medusa/tree/master/packages) you can add to your store.
- Learn how to [deploy the Medusa server](../deployments/server/index.mdx).
- Learn about the [Next.js](../starters/nextjs-medusa-starter.md) and [Gatsby](../starters/gatsby-medusa-starter.md) storefronts.
- Learn about the [Next.js](../starters/nextjs-medusa-starter.mdx) and [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts.

View File

@@ -40,7 +40,7 @@ Check out the [Event Reference](../advanced/backend/subscribers/events-list.md)
### Medusa Server
It is assumed you already have a Medusa server installed. If not, please follow the [Quickstart guide](../quickstart/quick-start.md) to get started in minutes.
It is assumed you already have a Medusa server installed. If not, please follow the [Quickstart guide](../quickstart/quick-start.mdx) to get started in minutes.
In addition, make sure to have Redis installed and configured with your Medusa server. If not, follow [this documentation](../tutorial/0-set-up-your-development-environment.mdx#redis) to install Redis and then [configure it](../usage/configurations.md#redis).
@@ -122,7 +122,7 @@ Run your server with the following command:
npm run start
```
Then, try triggering one of the [mentioned events earlier in this document](#events-that-the-segment-plugin-tracks). For example, you can place an order either using the [REST APIs](https://docs.medusajs.com/api/store) or using the [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](../starters/gatsby-medusa-starter.md) storefronts.
Then, try triggering one of the [mentioned events earlier in this document](#events-that-the-segment-plugin-tracks). For example, you can place an order either using the [REST APIs](https://docs.medusajs.com/api/store) or using the [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts.
After you place an order, on the Segment source that you created, click on the Debugger tab. You should see at least one event triggered for each order you place. If you click on the event, you can see the order details are passed to the event.

View File

@@ -22,7 +22,7 @@ By integrating SendGrid with Medusa, youll be sending email notifications to
## Prerequisites
Before going further with this guide make sure you have a Medusa server set up. You can follow the [Quickstart guide](../quickstart/quick-start.md).
Before going further with this guide make sure you have a Medusa server set up. You can follow the [Quickstart guide](../quickstart/quick-start.mdx).
You also must have [Redis configured on your Medusa server](/tutorial/set-up-your-development-environment#redis). Sending emails is done through Subscribers, which uses Redis as the event queue. If you dont set up Redis, the plugin will not send emails.
@@ -3953,7 +3953,7 @@ To test it out, perform an action that would trigger one of the emails being sen
:::tip
If you dont have a storefront installed, check out the [Gatsby](../starters/gatsby-medusa-starter.md) or [Next.js](../starters/nextjs-medusa-starter.md) starters to create a storefront in minutes.
If you dont have a storefront installed, check out the [Gatsby](../starters/gatsby-medusa-starter.mdx) or [Next.js](../starters/nextjs-medusa-starter.mdx) starters to create a storefront in minutes.
:::

View File

@@ -25,7 +25,7 @@ To follow along with this guide, you need to have a Slack account with a connect
### Medusa Server
This tutorial assumes you already have a Medusa server installed. If you dont, please follow along with the [quickstart guide](../quickstart/quick-start.md).
This tutorial assumes you already have a Medusa server installed. If you dont, please follow along with the [quickstart guide](../quickstart/quick-start.mdx).
### Redis

View File

@@ -18,7 +18,7 @@ Medusa provides three different options to handle your file storage. This docume
### Medusa Server
A Medusa server is required to be set up before following along with this document. You can follow the [quickstart guide](../quickstart/quick-start.md) to get started in minutes.
A Medusa server is required to be set up before following along with this document. You can follow the [quickstart guide](../quickstart/quick-start.mdx) to get started in minutes.
### Required Accounts
@@ -125,7 +125,7 @@ Run your Medusa server with the following command:
npm run start
```
Then, you can either test the plugin using the [REST APIs](https://docs.medusajs.com/api/store) or using the [Medusa Admin](../admin/quickstart.md).
Then, you can either test the plugin using the [REST APIs](https://docs.medusajs.com/api/store) or using the [Medusa Admin](../admin/quickstart.mdx).
On the Medusa Admin, create a new product and, in the Images section, upload an image then click Save. If the integration was successful, the product image will be uploaded successfully.
@@ -137,7 +137,7 @@ You can also check that the image was uploaded on the Spaces page.
## Next.js Storefront Configuration
If youre using a [Next.js](../starters/nextjs-medusa-starter.md) storefront, you need to add an additional configuration that adds the Spaces domain name into the configured images domain names. This is because all URLs of product images will be from the Space.
If youre using a [Next.js](../starters/nextjs-medusa-starter.mdx) storefront, you need to add an additional configuration that adds the Spaces domain name into the configured images domain names. This is because all URLs of product images will be from the Space.
If this configuration is not added, youll receive the error ["next/image Un-configured Host”](https://nextjs.org/docs/messages/next-image-unconfigured-host).
@@ -165,4 +165,4 @@ Where `<YOUR_SPACE_DOMAIN>` is the domain name for your Space which can be retri
- Check out [more plugins](https://github.com/medusajs/medusa/tree/master/packages) you can add to your store.
- Learn how to [deploy the Medusa server on DigitalOcean](../deployments/server/deploying-on-digital-ocean.md).
- Learn about the [Next.js](../starters/nextjs-medusa-starter.md) and [Gatsby](../starters/gatsby-medusa-starter.md) storefronts.
- Learn about the [Next.js](../starters/nextjs-medusa-starter.mdx) and [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts.

View File

@@ -16,7 +16,7 @@ This plugin only gives you access to the Twilio SMS API but does not implement s
## Prerequisites
Before going further with this guide make sure you have a Medusa server set up. You can follow the [Quickstart guide](../quickstart/quick-start.md) if you dont.
Before going further with this guide make sure you have a Medusa server set up. You can follow the [Quickstart guide](../quickstart/quick-start.mdx) if you dont.
You also must have a [Twilio account created](https://www.twilio.com/sms) so if you dont already please go ahead and create one.
@@ -110,7 +110,7 @@ If you create an order now on your storefront, you should receive a message from
:::tip
If you dont have a storefront set up yet, you can install one of the [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](../starters/gatsby-medusa-starter.md) storefronts.
If you dont have a storefront set up yet, you can install one of the [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts.
:::
@@ -125,4 +125,4 @@ If youre on a Twilio trial make sure that the phone number you entered on che
## Whats Next
- Learn more about how [Notifications work in Medusa](../advanced/backend/notification/overview.md).
- Install the [Medusa admin](../admin/quickstart.md) for functionalities like Gift Cards creation, swaps, claims, order return requests, and more.
- Install the [Medusa admin](../admin/quickstart.mdx) for functionalities like Gift Cards creation, swaps, claims, order return requests, and more.

View File

@@ -1,3 +1,5 @@
import Feedback from '@site/src/components/Feedback';
# Medusa Admin Quickstart
This document will guide you through setting up the Medusa admin in minutes, as well as some of its features.
@@ -53,6 +55,13 @@ Then, install the dependencies:
npm install
```
<Feedback
event="survey_admin_quickstart"
question="Did you set up the admin successfully?"
positiveQuestion="Is there anything that should improved?"
negativeQuestion="Please describe the issue you faced."
/>
## Test it Out
Before running your Medusa admin, make sure that your Medusa server is running.
@@ -136,5 +145,5 @@ You can learn more about Medusa admin and its features in the [User Guide](../us
## Whats Next
- Learn how to [Customize Medusa Admin](./development.md)
- Install the [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](../starters/gatsby-medusa-starter.md) storefront starters.
- Install the [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](../starters/gatsby-medusa-starter.mdx) storefront starters.
- [Learn how you can use `create-medusa-app` to install all of Medusas 3 components.](../usage/create-medusa-app.mdx)

View File

@@ -19,7 +19,7 @@ Importing prices into a price list removes all existing prices in the price list
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### Redis

View File

@@ -13,7 +13,7 @@ Using Medusas [Batch Job Admin APIs](https://docs.medusajs.com/api/admin/#tag
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### Redis

View File

@@ -33,7 +33,7 @@ You can use Medusas Admin APIs to achieve more functionalities as well. Check
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### JS Client

View File

@@ -31,7 +31,7 @@ You can use Medusas Admin APIs to achieve more functionalities as well. Check
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### JS Client

View File

@@ -56,7 +56,7 @@ You can perform other functionalities related to order editing. To learn more, c
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### JS Client

View File

@@ -19,7 +19,7 @@ This guide covers how to use these APIs to perform these tasks.
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### JS Client

View File

@@ -21,7 +21,7 @@ This documentation helps you learn how to create a batch job strategy. The batch
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.mdx) to get started.
### Redis

View File

@@ -12,7 +12,7 @@ Although this documentation specifically targets import strategies, you can use
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.mdx) to get started.
### Redis

View File

@@ -10,7 +10,7 @@ If youre unfamiliar with the Notification architecture in Medusa, it is recom
## Prerequisites
Before you start creating a Notification Provider, you need to install a [Medusa server](../../../quickstart/quick-start.md).
Before you start creating a Notification Provider, you need to install a [Medusa server](../../../quickstart/quick-start.mdx).
You also need to [setup Redis](../../../tutorial/0-set-up-your-development-environment.mdx#redis) and [configure it with the Medusa server](../../../usage/configurations.md#redis).
@@ -249,7 +249,7 @@ Then, place an order either using the [REST APIs](https://docs.medusajs.com/api/
:::tip
If you dont have a storefront installed you can get started with either the [Next.js](../../../starters/nextjs-medusa-starter.md) or [Gatsby](../../../starters/gatsby-medusa-starter.md) starter storefronts in minutes.
If you dont have a storefront installed you can get started with either the [Next.js](../../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../../starters/gatsby-medusa-starter.mdx) starter storefronts in minutes.
:::

View File

@@ -428,7 +428,7 @@ This method returns an array of saved payment methods retrieved from the third-p
:::note
If youre using Medusas [Next.js](../../../starters/nextjs-medusa-starter.md) or [Gatsby](../../../starters/gatsby-medusa-starter.md) storefront starters, note that the presentation of this method is not implemented. Youll need to implement the UI and pages for this method based on your implementation and the provider you are using.
If youre using Medusas [Next.js](../../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../../starters/gatsby-medusa-starter.mdx) storefront starters, note that the presentation of this method is not implemented. Youll need to implement the UI and pages for this method based on your implementation and the provider you are using.
:::

View File

@@ -30,7 +30,7 @@ As a developer, you will mainly work with the Payment Provider when integrating
When you run your Medusa server, the Payment Provider will be registered on your server if it hasnt been already.
Once the Payment Provider is added to the server, the store operator will be able to choose on the [Medusa Admin](../../../admin/quickstart.md) the payment providers available in a region. These payment providers are shown to the customer at checkout to choose from and use.
Once the Payment Provider is added to the server, the store operator will be able to choose on the [Medusa Admin](../../../admin/quickstart.mdx) the payment providers available in a region. These payment providers are shown to the customer at checkout to choose from and use.
:::caution

View File

@@ -15,7 +15,7 @@ This document doesn't cover what price lists are and their basics. If youre i
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.mdx) to get started.
### JS Client

View File

@@ -23,7 +23,7 @@ This guide explains how to perform all these operations using the Admin APIs.
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../../quickstart/quick-start.mdx) to get started.
### Enabled Feature Flags

View File

@@ -12,7 +12,7 @@ This guide explains how to create a scheduled job on your Medusa server. The sch
### Medusa Components
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../../quickstart/quick-start.md) to get started.
It is assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../../quickstart/quick-start.mdx) to get started.
### Redis

View File

@@ -37,7 +37,7 @@ As a developer, you will mainly work with the Fulfillment Provider when integrat
When you run your Medusa server, the Fulfillment Provider will be registered on your server if it hasnt been already.
Once the Fulfillment Provider is added to the server, the store operator will be able to associate on the [Medusa Admin](../../../quickstart/quick-start.md) the Fulfillment Provider with shipping options.
Once the Fulfillment Provider is added to the server, the store operator will be able to associate on the [Medusa Admin](../../../quickstart/quick-start.mdx) the Fulfillment Provider with shipping options.
### FulfillmentProvider Entity Overview

View File

@@ -18,7 +18,7 @@ In this document, youll learn how to handle the `order-update-token.created`
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.mdx) to get started.
### Redis

View File

@@ -48,9 +48,9 @@ You can perform other functionalities related to order editing. To learn more, c
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.md) or [Gatsby](../../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -21,9 +21,9 @@ Its recommended to go through the [Shipping Architecture Overview](../backend
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.md) or [Gatsby](../../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -36,9 +36,9 @@ In this document, youll learn how to implement two parts of this flow:
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow the [quickstart guide](../../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.md) or [Gatsby](../../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -25,9 +25,9 @@ You want to implement discount functionality in your store to allow customers to
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.md) or [Gatsby](../../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -23,9 +23,9 @@ You want to implement the following in your storefront:
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.md) or [Gatsby](../../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -15,9 +15,9 @@ This guide explains how to perform these operations using the Storefront APIs.
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.md) or [Gatsby](../../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../../starters/nextjs-medusa-starter.mdx) or [Gatsby](../../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -16,7 +16,7 @@ Alternatively, you can use this button to deploy the Medusa Admin to Netlify dir
### Medusa Components
Before proceeding with this documentation, it is assumed you already have a Medusa Admin installed locally. If not, please go through the [quickstart guide](../../admin/quickstart.md) first.
Before proceeding with this documentation, it is assumed you already have a Medusa Admin installed locally. If not, please go through the [quickstart guide](../../admin/quickstart.mdx) first.
Additionally, this documentation does not cover how to deploy the Medusa server. If you want to deploy the Medusa server, check out one of the [deployment documentation related to the Medusa server](../server/index.mdx).

View File

@@ -12,7 +12,7 @@ DigitalOcean is a reliable hosting provider that provides different ways to host
### Medusa Server
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.md).
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.mdx).
Furthermore, your Medusa server should be configured to work with PostgreSQL and Redis. You can follow the [Configure your Server documentation](../../usage/configurations.md) to learn how to do that.

View File

@@ -26,7 +26,7 @@ Alternatively, you can use this button to deploy the Medusa server to Heroku dir
### Medusa Server
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.md).
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.mdx).
Furthermore, your Medusa server should be configured to work with PostgreSQL and Redis. You can follow the [Configure your Server documentation](../../usage/configurations.md) to learn how to do that.

View File

@@ -20,7 +20,7 @@ This tutorial explains how to deploy Medusa to a Qovery organization with an AWS
### Medusa Server
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.md).
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.mdx).
Furthermore, your Medusa server should be configured to work with PostgreSQL and Redis. You can follow the [Configure your Server documentation](../../usage/configurations.md) to learn how to do that.

View File

@@ -16,7 +16,7 @@ Railway provides a free plan that allows you to deploy your Medusa server along
### Medusa Server
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.md).
It is assumed that you already have a Medusa server installed locally. If you dont, please follow the [quickstart guide](../../quickstart/quick-start.mdx).
Furthermore, your Medusa server should be configured to work with PostgreSQL and Redis. You can follow the [Configure your Server documentation](./../../usage/configurations.md) to learn how to do that.

View File

@@ -16,7 +16,7 @@ Alternatively, you can use this button to deploy the Gatsby Storefront to Netlif
### Medusa Components
Before proceeding with this documentation, it is assumed you already have the Gatsby storefront installed locally. If not, please go through the [quickstart guide](../../starters/gatsby-medusa-starter.md) first.
Before proceeding with this documentation, it is assumed you already have the Gatsby storefront installed locally. If not, please go through the [quickstart guide](../../starters/gatsby-medusa-starter.mdx) first.
Additionally, this documentation does not cover how to deploy the Medusa server. If you want to deploy the Medusa server, [check out one of the deployment documentation related to the Medusa server](../server/index.mdx).

View File

@@ -25,9 +25,9 @@ This document does not cover implementing the checkout flow. You can refer to [t
### Medusa Components
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../quickstart/quick-start.md) to get started.
It's assumed that you already have a Medusa server installed and set up. If not, you can follow our [quickstart guide](../quickstart/quick-start.mdx) to get started.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](../starters/gatsby-medusa-starter.md) storefronts.
It is also assumed you already have a storefront set up. It can be a custom storefront or one of Medusas storefronts. If you dont have a storefront set up, you can install either the [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts.
### JS Client

View File

@@ -1,3 +1,5 @@
import Feedback from '@site/src/components/Feedback';
# Quickstart using Docker
In this document, you will learn how to make a container of Medusa's app on Docker. Docker is an open source platform for building, deploying, and managing containerized applications.
@@ -61,6 +63,12 @@ Running the above command does the following:
1. Build images for your Medusa project, a PostgreSQL database, and a Redis server
2. Run migrations for your newly created database
<Feedback
event="survey_server_docker_quickstart"
question="Did you set up the server successfully?"
positiveQuestion="Is there anything that should improved?"
negativeQuestion="Please describe the issue you faced."
/>
## Test Your Server
@@ -100,7 +108,7 @@ You can learn more about configuring your server and loading environment variabl
## What's Next
- Install the [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](../starters/gatsby-medusa-starter.md) storefronts to set up your ecommerce storefront quickly.
- Install the [Medusa Admin](../admin/quickstart.md) to supercharge your ecommerce experience with easy access to configurations and features.
- Install the [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts to set up your ecommerce storefront quickly.
- Install the [Medusa Admin](../admin/quickstart.mdx) to supercharge your ecommerce experience with easy access to configurations and features.
- Check out the [API reference](https://docs.medusajs.com/api/store) to learn more about available endpoints available on your Medusa server.
- Install [plugins](https://github.com/medusajs/medusa/tree/master/packages) for features like Payment, CMS, and Notifications, among other features.

View File

@@ -1,3 +1,5 @@
import Feedback from '@site/src/components/Feedback';
# Quickstart
This document will guide you through setting up your Medusa server in a few minutes.
@@ -45,6 +47,13 @@ If you run into any errors while installing the CLI tool, check out the [trouble
medusa develop
```
<Feedback
event="survey_server_quickstart"
question="Did you set up the server successfully?"
positiveQuestion="Is there anything that should improved?"
negativeQuestion="Please describe the issue you faced."
/>
### Test Your Server
After these three steps and in only a couple of minutes, you now have a complete commerce engine running locally. You can test it out by sending a request using a tool like Postman or through the command line:
@@ -87,7 +96,7 @@ To upload product images to your Medusa server, you must install and configure o
## What's Next
- Install the [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](../starters/gatsby-medusa-starter.md) storefronts to set up your ecommerce storefront.
- Install the [Medusa Admin](../admin/quickstart.md) to supercharge your ecommerce experience with easy access to configurations and features.
- Install the [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](../starters/gatsby-medusa-starter.mdx) storefronts to set up your ecommerce storefront.
- Install the [Medusa Admin](../admin/quickstart.mdx) to supercharge your ecommerce experience with easy access to configurations and features.
- Check out the [API reference](https://docs.medusajs.com/api/store) to learn more about available endpoints available on your Medusa server.
- Install [plugins](https://github.com/medusajs/medusa/tree/master/packages) for features like Payment, CMS, Notifications, among other features.

View File

@@ -1,3 +1,5 @@
import Feedback from '@site/src/components/Feedback';
# Gatsby Storefront Quickstart
This document guides you to install and set up the Gatsby Storefront for your Medusa Server.
@@ -14,7 +16,7 @@ Instead of manually following this guide to install then later deploy the Gatsby
## Prerequisites
This document assumes you already have a Medusa server installed. If you dont, please follow the [Quickstart guide for the Medusa server](../quickstart/quick-start.md) to learn how to do it.
This document assumes you already have a Medusa server installed. If you dont, please follow the [Quickstart guide for the Medusa server](../quickstart/quick-start.mdx) to learn how to do it.
You should also have the Gatsby CLI installed:
@@ -51,6 +53,13 @@ npm run start
Your Gatsby storefront is now running at `localhost:8000`!
<Feedback
event="survey_gatsby_quickstart"
question="Did you set up the storefront successfully?"
positiveQuestion="Is there anything that should improved?"
negativeQuestion="Please describe the issue you faced."
/>
## Development Notes
### Customization

View File

@@ -1,3 +1,5 @@
import Feedback from '@site/src/components/Feedback';
# Next.js Storefront Quickstart
This document guides you to install and set up the Next.js Storefront for your Medusa Server.
@@ -14,7 +16,7 @@ Instead of manually following this guide to install then later deploy the Next.j
## Prerequisites
This document assumes you already have a Medusa server installed. If you dont, please follow the [Quickstart guide for the Medusa server](../quickstart/quick-start.md) to learn how to do it.
This document assumes you already have a Medusa server installed. If you dont, please follow the [Quickstart guide for the Medusa server](../quickstart/quick-start.mdx) to learn how to do it.
## Installation
@@ -24,13 +26,13 @@ It is recommended to use [Yarn](https://yarnpkg.com/getting-started/install) for
:::
1\. Create a new Next.js project using the [Medusa starter template](https://github.com/medusajs/nextjs-starter-medusa):
1\. Create a new Next.js project using the [Medusa starter template](https://github.com/medusajs/nextjs-starter-medusa):
```bash
npx create-next-app -e https://github.com/medusajs/nextjs-starter-medusa my-medusa-storefront
```
2\. Change to the newly created directory `my-medusa-storefront` and rename the template environment variable file to use environment variables in development:
2\. Change to the newly created directory `my-medusa-storefront` and rename the template environment variable file to use environment variables in development:
```bash
cd my-medusa-storefront
@@ -43,7 +45,14 @@ mv .env.template .env.local
npm run dev
```
Your Next.js storefront is now running at `localhost:8000`!
Your Next.js storefront is now running at `localhost:8000`!
<Feedback
event="survey_nextjs_quickstart"
question="Did you set up the storefront successfully?"
positiveQuestion="Is there anything that should improved?"
negativeQuestion="Please describe the issue you faced."
/>
## Development Notes
@@ -183,9 +192,9 @@ To customize the styles of the storefront, you can customize the `src/styles` di
### Change Port
By default, the Next.js storefront runs on port `8000`.
By default, the Next.js storefront runs on port `8000`.
To change the port, change the `develop` command in `package.json` to the following:
To change the port, change the `develop` command in `package.json` to the following:
```json
"scripts": {
@@ -194,9 +203,9 @@ To change the port, change the `develop` command in `package.json` to the fo
}
```
Make sure to replace `<PORT>` with the port number you want the storefront to run on. For example, `3000`.
Make sure to replace `<PORT>` with the port number you want the storefront to run on. For example, `3000`.
Then, on your server, update the environment variable `STORE_CORS` to the URL with the new port:
Then, on your server, update the environment variable `STORE_CORS` to the URL with the new port:
```bash
STORE_CORS=http://localhost:<PORT>
@@ -222,5 +231,5 @@ You can learn more about development with Next.js through [their documentation](
## Whats Next
- Check the [Storefront API reference](https://docs.medusajs.com/api/store) for a full list of REST APIs to use on your storefront.
- Learn [how to install Medusa Admin](../admin/quickstart.md).
- Check the [Storefront API reference](https://docs.medusajs.com/api/store) for a full list of REST APIs to use on your storefront.
- Learn [how to install Medusa Admin](../admin/quickstart.mdx).

View File

@@ -271,5 +271,5 @@ To install Redis without Homebrew you can check out [Rediss guide on installi
## Whats Next
- Learn how to [configure your Medusa server](../usage/configurations.md).
- Learn how to install a storefront with [Next.js](../starters/nextjs-medusa-starter.md) or [Gatsby](./../starters/gatsby-medusa-starter.md).
- Learn how to install the [Medusa Admin](../admin/quickstart.md).
- Learn how to install a storefront with [Next.js](../starters/nextjs-medusa-starter.mdx) or [Gatsby](./../starters/gatsby-medusa-starter.mdx).
- Learn how to install the [Medusa Admin](../admin/quickstart.mdx).

View File

@@ -4,7 +4,7 @@ In this document, youll learn what configurations you can add to your Medusa
## Prerequisites
This document assumes you already followed along with the [“Set up your development environment” documentation](../tutorial/0-set-up-your-development-environment.mdx) and have [installed a Medusa server](../quickstart/quick-start.md#create-a-medusa-server).
This document assumes you already followed along with the [“Set up your development environment” documentation](../tutorial/0-set-up-your-development-environment.mdx) and have [installed a Medusa server](../quickstart/quick-start.mdx#create-a-medusa-server).
## Medusa Configurations File
@@ -332,6 +332,6 @@ It is recommended to use environment variables to store values of options instea
## Whats Next
- Check out the [Next.js](../starters/nextjs-medusa-starter.md) and [Gatsby](../starters/gatsby-medusa-starter.md) starter storefronts.
- Install the [Medusa admin](../admin/quickstart.md).
- Check out the [Next.js](../starters/nextjs-medusa-starter.mdx) and [Gatsby](../starters/gatsby-medusa-starter.mdx) starter storefronts.
- Install the [Medusa admin](../admin/quickstart.mdx).
- Learn about [deploying the Medusa server](../deployments/server/index.mdx).

View File

@@ -77,7 +77,7 @@ If you choose an option other than `None`, a storefront will be installed under
:::tip
Learn more about the [Next.js](../starters/nextjs-medusa-starter.md) and [Gatsby](../starters/gatsby-medusa-starter.md) starter storefronts.
Learn more about the [Next.js](../starters/nextjs-medusa-starter.mdx) and [Gatsby](../starters/gatsby-medusa-starter.mdx) starter storefronts.
:::

View File

@@ -191,7 +191,10 @@ const config = {
href: 'https://github.com/medusajs/medusa'
},
],
reportCodeLinkPrefix: 'https://github.com/medusajs/medusa/issues/new?assignees=&labels=type%3A+docs&template=docs.yml'
reportCodeLinkPrefix: 'https://github.com/medusajs/medusa/issues/new?assignees=&labels=type%3A+docs&template=docs.yml',
footerFeedback: {
event: 'survey'
}
},
presets: [
[

View File

@@ -1,6 +1,7 @@
.feedback-container {
padding-top: var(--ifm-base-margin-vertical);
padding-bottom: var(--ifm-base-margin-vertical);
border-top: 1px solid var(--ifm-doc-footer-border-color);
}

View File

@@ -5,7 +5,16 @@ import './index.css';
import useIsBrowser from '@docusaurus/useIsBrowser';
import {useLocation} from '@docusaurus/router';
export default function Feedback () {
export default function Feedback ({
event,
question = 'Was this page helpful?',
positiveBtn = 'Yes',
negativeBtn = 'No',
positiveQuestion = 'What was most helpful?',
negativeQuestion = 'What can we improve?',
submitBtn = 'Submit',
submitMessage = 'Thank you for helping improve our documentation!'
}) {
const [showForm, setShowForm] = useState(false);
const [submittedFeedback, setSubmittedFeedback] = useState(false);
const [loading, setLoading] = useState(false);
@@ -28,7 +37,7 @@ export default function Feedback () {
if (isBrowser) {
if (window.analytics) {
setLoading(true);
window.analytics.track('survey', {
window.analytics.track(event, {
url: location.pathname,
label: document.title,
feedback: positiveFeedback ? 'yes' : 'no',
@@ -63,21 +72,21 @@ export default function Feedback () {
<>
{(!showForm && !submittedFeedback) && (
<div className='inline-feedback' ref={inlineFeedbackRef}>
<span>Was this page helpful?</span>
<button className='positive feedback-btn' onClick={handleFeedback}>Yes</button>
<button className='negative feedback-btn' onClick={handleFeedback}>No</button>
<span>{question}</span>
<button className='positive feedback-btn' onClick={handleFeedback}>{positiveBtn}</button>
<button className='negative feedback-btn' onClick={handleFeedback}>{negativeBtn}</button>
</div>
)}
{(showForm && !submittedFeedback) && (
<div className='inline-question' ref={inlineQuestionRef}>
<span>{positiveFeedback ? 'What was most helpful?' : 'What can we improve?'}</span>
<span>{positiveFeedback ? positiveQuestion : negativeQuestion}</span>
<textarea rows={4} value={message} onChange={(e) => setMessage(e.target.value)}></textarea>
<button className='feedback-btn' onClick={submitFeedback} disabled={loading}>Submit</button>
<button className='feedback-btn' onClick={submitFeedback} disabled={loading}>{submitBtn}</button>
</div>
)}
{submittedFeedback && (
<div className='feedback-message' ref={inlineMessageRef}>
Thank you for helping improve our documentation!
{submitMessage}
</div>
)}
</>

View File

@@ -83,7 +83,7 @@ kbd {
}
.theme-doc-footer {
margin-top: var(--ifm-base-margin-vertical) !important;
margin-top: 0 !important;
border-top: 1px solid var(--ifm-doc-footer-border-color) !important;
padding-top: var(--ifm-base-margin-vertical);
}

View File

@@ -2,15 +2,19 @@ import React from 'react';
import Footer from '@theme-original/DocItem/Footer';
import Feedback from '../../../components/Feedback';
import { useDoc } from '@docusaurus/theme-common/internal';
import {useThemeConfig} from '@docusaurus/theme-common';
export default function FooterWrapper(props) {
const { metadata } = useDoc()
const { footerFeedback = { event: '' } } = useThemeConfig();
console.log(footerFeedback)
return (
<>
{!metadata.frontMatter?.hide_footer && (
<div className='docusaurus-mt-lg doc-footer'>
<Feedback />
<Feedback {...footerFeedback} />
<Footer {...props} />
</div>
)}