From 63aea62d7a06812fa0fabc5eff06412b568fc168 Mon Sep 17 00:00:00 2001
From: Shahed Nasser
Date: Tue, 26 Sep 2023 15:08:30 +0300
Subject: [PATCH] docs: improve tailwind configuration (#5215)
---
.../admin/currencies/list-currencies.ts | 3 +
.../admin/currencies/update-currency.ts | 3 +
.../api-reference/app/api/[area]/layout.tsx | 4 +-
.../Security/Description/index.tsx | 7 +-
.../CodeSection/Responses/Sample/index.tsx | 2 +-
.../Tags/Operation/CodeSection/index.tsx | 7 +-
.../DescriptionSection/Parameters/index.tsx | 4 +-
.../Operation/DescriptionSection/index.tsx | 2 +-
.../Tags/Operation/Parameters/Name/index.tsx | 2 +-
.../Operation/Parameters/Nested/index.tsx | 4 +-
.../Parameters/Types/OneOf/index.tsx | 2 -
www/apps/api-reference/css/globals.css | 6 +-
.../components/DocSidebarItemIcon/index.tsx | 10 +-
.../components/Footer/SocialLinks/index.tsx | 8 +-
.../docs/src/components/LargeCard/index.tsx | 18 +-
.../components/LearningPath/Finish/index.tsx | 2 +-
.../components/LearningPath/Icon/index.tsx | 2 +-
.../components/LearningPath/Steps/index.tsx | 8 +-
.../src/components/LearningPath/index.tsx | 16 +-
www/apps/docs/src/css/_docusaurus.css | 23 +-
www/apps/docs/src/css/_variables.css | 104 +----
www/apps/docs/src/css/components/sidebar.css | 14 +-
www/apps/docs/src/css/components/toc.css | 12 +-
www/apps/docs/src/css/components/tooltip.css | 2 +-
www/apps/docs/src/css/custom.css | 74 +---
www/apps/docs/src/theme/Admonition/index.tsx | 14 +-
.../AnnouncementBar/CloseButton/index.tsx | 2 +-
.../theme/AnnouncementBar/Content/index.tsx | 4 +-
.../docs/src/theme/AnnouncementBar/index.tsx | 8 +-
.../src/theme/CodeBlock/Content/String.tsx | 6 +-
www/apps/docs/src/theme/DocCard/index.tsx | 19 +-
.../docs/src/theme/DocItem/Footer/index.tsx | 2 +-
.../theme/DocPage/Layout/Sidebar/index.tsx | 4 +-
.../docs/src/theme/Footer/Layout/index.tsx | 2 +-
www/apps/docs/src/theme/MDXComponents/A.tsx | 2 +-
.../theme/Navbar/ColorModeToggle/index.tsx | 4 +-
.../docs/src/theme/Navbar/Content/index.tsx | 28 +-
.../Navbar/MobileSidebar/Header/index.tsx | 2 +-
.../Navbar/MobileSidebar/Toggle/index.tsx | 8 +-
www/apps/docs/src/theme/Tabs/index.tsx | 14 +-
www/apps/ui/public/images/figma.png | Bin 1955 -> 1315 bytes
.../ui/src/app/(content)/[[...slug]]/page.tsx | 9 +-
www/apps/ui/src/app/layout.tsx | 2 +-
www/apps/ui/src/components/colors.tsx | 16 +-
.../ui/src/components/component-example.tsx | 3 +-
.../ui/src/components/component-props.tsx | 2 +-
www/apps/ui/src/components/feedback.tsx | 5 +-
www/apps/ui/src/components/figma-icon.tsx | 11 +-
www/apps/ui/src/components/hook-table.tsx | 6 +-
www/apps/ui/src/components/hook-values.tsx | 2 +-
www/apps/ui/src/components/icon-search.tsx | 3 +-
www/apps/ui/src/components/mdx-components.tsx | 29 +-
www/apps/ui/src/components/props-table.tsx | 6 +-
www/apps/ui/src/components/scroll-area.tsx | 4 +-
www/apps/ui/src/components/tabs.tsx | 1 -
www/apps/ui/src/styles/globals.css | 4 +-
.../docs-ui/src/components/Badge/index.tsx | 24 +-
.../docs-ui/src/components/Bordered/index.tsx | 2 +-
.../src/components/BorderedIcon/index.tsx | 4 +-
.../docs-ui/src/components/Button/index.tsx | 38 +-
.../docs-ui/src/components/Card/index.tsx | 8 +-
.../src/components/CodeBlock/index.tsx | 12 +-
.../docs-ui/src/components/CodeTabs/index.tsx | 12 +-
.../src/components/Details/Summary/index.tsx | 7 +-
.../docs-ui/src/components/Details/index.tsx | 2 +-
.../src/components/InlineCode/index.tsx | 13 +-
.../src/components/Input/Text/index.tsx | 18 +-
.../docs-ui/src/components/Kbd/index.tsx | 6 +-
.../docs-ui/src/components/Label/index.tsx | 2 +-
.../docs-ui/src/components/Link/index.tsx | 1 -
.../docs-ui/src/components/Loading/index.tsx | 2 +-
.../src/components/Modal/Footer/index.tsx | 2 +-
.../src/components/Modal/Header/index.tsx | 10 +-
.../docs-ui/src/components/Modal/index.tsx | 6 +-
.../Navbar/ColorModeToggle/index.tsx | 8 +-
.../src/components/Navbar/Link/index.tsx | 6 +-
.../Navbar/MobileMenu/Button/index.tsx | 8 +-
.../docs-ui/src/components/Navbar/index.tsx | 2 +-
.../docs-ui/src/components/NextLink/index.tsx | 1 -
.../Item/Layout/Default/index.tsx | 21 +-
.../components/Notification/Item/index.tsx | 2 +-
.../docs-ui/src/components/Rating/index.tsx | 2 +-
.../Search/Hits/GroupName/index.tsx | 2 +-
.../src/components/Search/Hits/index.tsx | 12 +-
.../src/components/Search/Modal/index.tsx | 36 +-
.../components/Search/ModalOpener/index.tsx | 4 +-
.../src/components/Search/NoResults/index.tsx | 2 +-
.../components/Search/Suggestions/index.tsx | 9 +-
.../src/components/Select/Badge/index.tsx | 25 +-
.../src/components/Select/Dropdown/index.tsx | 12 +-
.../src/components/Select/Input/index.tsx | 22 +-
.../src/components/Sidebar/Item/index.tsx | 16 +-
.../docs-ui/src/components/Sidebar/index.tsx | 2 +-
.../docs-ui/src/components/TextArea/index.tsx | 18 +-
.../docs-ui/src/components/Tooltip/index.tsx | 6 +-
.../docs-ui/src/providers/Modal/index.tsx | 2 +-
www/packages/tailwind/base.tailwind.config.js | 395 ++++--------------
www/packages/tailwind/theme-presets.js | 194 +++++++++
98 files changed, 643 insertions(+), 894 deletions(-)
create mode 100644 www/packages/tailwind/theme-presets.js
diff --git a/packages/medusa/src/api/routes/admin/currencies/list-currencies.ts b/packages/medusa/src/api/routes/admin/currencies/list-currencies.ts
index f1f64d1a60..11f28d1312 100644
--- a/packages/medusa/src/api/routes/admin/currencies/list-currencies.ts
+++ b/packages/medusa/src/api/routes/admin/currencies/list-currencies.ts
@@ -42,6 +42,9 @@ import { FeatureFlagDecorators } from "../../../../utils/feature-flag-decorators
* source: |
* curl -X POST '{backend_url}/admin/currencies' \
* -H 'Authorization: Bearer {api_token}'
+ * security:
+ * - api_token: []
+ * - cookie_auth: []
* tags:
* - Currencies
* responses:
diff --git a/packages/medusa/src/api/routes/admin/currencies/update-currency.ts b/packages/medusa/src/api/routes/admin/currencies/update-currency.ts
index 9ddcb75418..8329a3dae9 100644
--- a/packages/medusa/src/api/routes/admin/currencies/update-currency.ts
+++ b/packages/medusa/src/api/routes/admin/currencies/update-currency.ts
@@ -43,6 +43,9 @@ import { EntityManager } from "typeorm"
* --data-raw '{
* "includes_tax": true
* }'
+ * security:
+ * - api_token: []
+ * - cookie_auth: []
* tags:
* - Currencies
* responses:
diff --git a/www/apps/api-reference/app/api/[area]/layout.tsx b/www/apps/api-reference/app/api/[area]/layout.tsx
index c693332aed..72260b0d39 100644
--- a/www/apps/api-reference/app/api/[area]/layout.tsx
+++ b/www/apps/api-reference/app/api/[area]/layout.tsx
@@ -33,8 +33,8 @@ export default function RootLayout({
className={clsx(
inter.variable,
robotoMono.variable,
- "bg-docs-bg dark:bg-docs-bg-dark font-base text-medium h-full w-full",
- "text-medusa-fg-subtle dark:text-medusa-fg-subtle-dark"
+ "bg-docs-bg font-base text-medium h-full w-full",
+ "text-medusa-fg-subtle"
)}
>
diff --git a/www/apps/api-reference/components/MDXComponents/Security/Description/index.tsx b/www/apps/api-reference/components/MDXComponents/Security/Description/index.tsx
index 906e923af1..1345fc3e93 100644
--- a/www/apps/api-reference/components/MDXComponents/Security/Description/index.tsx
+++ b/www/apps/api-reference/components/MDXComponents/Security/Description/index.tsx
@@ -39,12 +39,7 @@ const SecurityDescription = ({
{getSecuritySchemaTypeName(securitySchema)}
{(securitySchema.type === "http" || securitySchema.type === "apiKey") && (
-
+
{securitySchema.type === "http"
? "HTTP Authorization Scheme"
diff --git a/www/apps/api-reference/components/Tags/Operation/CodeSection/Responses/Sample/index.tsx b/www/apps/api-reference/components/Tags/Operation/CodeSection/Responses/Sample/index.tsx
index 86b863bcf2..37615bef4c 100644
--- a/www/apps/api-reference/components/Tags/Operation/CodeSection/Responses/Sample/index.tsx
+++ b/www/apps/api-reference/components/Tags/Operation/CodeSection/Responses/Sample/index.tsx
@@ -91,7 +91,7 @@ const TagsOperationCodeSectionResponsesSample = ({
examples.find((ex) => ex.value === event.target.value)
)
}
- className="border-medusa-border-base dark:border-medusa-border-base-dark my-1 w-full rounded-sm border p-0.5"
+ className="border-medusa-border-base my-1 w-full rounded-sm border p-0.5"
>
{examples.map((example, index) => (