-
Notifications
You must be signed in to change notification settings - Fork 214
Feature/tailwind v4 migration #3087
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,5 @@ | ||
| module.exports = { | ||
| plugins: { | ||
| tailwindcss: {}, | ||
| autoprefixer: {}, | ||
| } | ||
| } | ||
| plugins: { | ||
| '@tailwindcss/postcss': {}, | ||
| }, | ||
| }; |
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,2 @@ | ||
| @use '../base-tailwind'; | ||
| @config './tailwind.config.js'; | ||
|
|
||
| //@import "@getdokan/dokan-ui/dist/dokan-ui.css"; | ||
| /* Module-specific styles - Tailwind loaded via dokan-tailwind bundle */ | ||
| /* No custom styles for this module */ |
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,2 @@ | ||
| @use '../base-tailwind'; | ||
| @config './status-tailwind.config.js'; | ||
| //@import "@getdokan/dokan-ui/dist/dokan-ui.css"; | ||
| /* Module-specific styles - Tailwind loaded via dokan-tailwind bundle */ | ||
| /* No custom styles for this module */ |
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +0,0 @@ | ||
| @import '@getdokan/dokan-ui/dist/dokan-ui.css'; | ||
| @config './dashboard-banner-tailwind.config.js'; | ||
| @import './../../base-tailwind'; | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,2 @@ | ||
| @config './tailwind-category-commission.config.js'; | ||
| @tailwind base; | ||
| @tailwind components; | ||
| @tailwind utilities; | ||
| /* Module-specific styles - Tailwind loaded via dokan-tailwind bundle */ | ||
| /* No custom styles for this module */ |
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,2 @@ | ||
| @use '../../base-tailwind'; | ||
| @config './header-tailwind.config.js'; | ||
| /* Module-specific styles - Tailwind loaded via dokan-tailwind bundle */ | ||
| /* No custom styles for this module */ |
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,2 @@ | ||
| @config './panel-switcher-tailwind.config.js'; | ||
| @import './../../base-tailwind'; | ||
| /* Module-specific styles - Tailwind loaded via dokan-tailwind bundle */ | ||
| /* No custom styles for this module */ |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,95 @@ | ||
| @layer theme, base, components, utilities; | ||
| @import "tailwindcss/theme.css" layer(theme); | ||
| /* ============================================ | ||
| Tailwind v4 Theme Configuration | ||
| Simplified color system with CSS variable support | ||
| ============================================ */ | ||
| @theme { | ||
| /* Custom breakpoints */ | ||
| --breakpoint-d-xs: 360px; | ||
|
|
||
| /* Primary Colors - Single source of truth */ | ||
| --color-primary: var(--dokan-primary-color, #7047eb); | ||
| --color-primary-hover: var(--dokan-primary-hover-color, #502bbf); | ||
| --color-primary-light: var(--dokan-primary-light-color, #daceff); | ||
| --color-primary-dark: var(--dokan-primary-dark-color, #322067); | ||
|
|
||
| /* Text colors on colored backgrounds (for contrast) */ | ||
| --color-on-primary: var(--dokan-on-primary-color, #ffffff); | ||
| --color-on-info: var(--dokan-on-info-color, #ffffff); | ||
| --color-on-success: var(--dokan-on-success-color, #ffffff); | ||
| --color-on-warning: var(--dokan-on-warning-color, #ffffff); | ||
| --color-on-danger: var(--dokan-on-danger-color, #ffffff); | ||
|
|
||
| /* Neutral Colors */ | ||
| --color-neutral-50: #fafafa; | ||
| --color-neutral-100: #f5f5f5; | ||
| --color-neutral-200: #e5e5e5; | ||
| --color-neutral-300: #d4d4d4; | ||
| --color-neutral-400: #a3a3a3; | ||
| --color-neutral-500: #737373; | ||
| --color-neutral-600: #525252; | ||
| --color-neutral-700: #404040; | ||
| --color-neutral-800: #262626; | ||
| --color-neutral-900: #171717; | ||
|
|
||
| /* Border Colors */ | ||
| --color-border: var(--dokan-border-color, #e5e5e5); | ||
| --color-border-light: var(--dokan-border-light-color, #f5f5f5); | ||
| --color-border-dark: var(--dokan-border-dark-color, #d4d4d4); | ||
|
|
||
| /* Semantic Colors */ | ||
| --color-info: #0b76b7; | ||
| --color-info-light: #e9f9ff; | ||
| --color-info-hover: #2795d7; | ||
|
|
||
| --color-success: #07a67e; | ||
| --color-success-light: #daf8e6; | ||
| --color-success-hover: #11b68c; | ||
|
|
||
| --color-warning: #e9a905; | ||
| --color-warning-light: #fffbeb; | ||
| --color-warning-hover: #fbbf24; | ||
|
|
||
| --color-danger: #e3050c; | ||
| --color-danger-light: #fef3f3; | ||
| --color-danger-hover: #f23030; | ||
|
|
||
| /* Sidebar Colors */ | ||
| --color-sidebar: var(--dokan-sidebar-bg, #322067); | ||
| --color-sidebar-hover: var(--dokan-sidebar-hover-bg, #7047eb); | ||
| --color-sidebar-text: var(--dokan-sidebar-text, #daceff); | ||
| --color-sidebar-text-hover: var(--dokan-sidebar-text-hover, #ffffff); | ||
| } | ||
|
|
||
| /* Base layer styles */ | ||
| @layer base { | ||
| :root { | ||
| --colors-primary-500: var(--color-primary); | ||
| --wp-components-color-accent: var(--color-primary); | ||
| --wp-components-color-accent-darker-20: var(--color-primary-hover); | ||
| } | ||
|
|
||
| /* Headless UI portal visibility fix */ | ||
| #headlessui-portal-root { | ||
| display: none; | ||
| } | ||
|
|
||
| /* Z-index for popover/modal layers */ | ||
| div[data-radix-popper-content-wrapper], | ||
| div[data-headlessui-state="open"][role="dialog"] { | ||
| z-index: 999 !important; | ||
| } | ||
| } | ||
|
|
||
| .dokan-layout { | ||
| @import "tailwindcss/preflight.css" layer(base); | ||
| @import "tailwindcss/utilities.css"; | ||
|
|
||
| /* Import custom component styles */ | ||
| @import './dokan-components.css'; | ||
|
|
||
| border-color: var(--color-border); | ||
|
|
||
| } | ||
| @import '@getdokan/dokan-ui/dist/dokan-ui.css'; | ||
|
Comment on lines
+85
to
+95
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: # First, let's examine the complete src/base-tailwind.css file to understand the context
wc -l src/base-tailwind.cssRepository: getdokan/dokan Length of output: 172 🏁 Script executed: # Read the file to see the actual import structure and context around lines 85-95
cat -n src/base-tailwind.css | head -100Repository: getdokan/dokan Length of output: 3863 Move all
🐛 Proposed fix `@layer` theme, base, components, utilities;
`@import` "tailwindcss/theme.css" layer(theme);
+@import "tailwindcss/preflight.css" layer(base);
+@import "tailwindcss/utilities.css";
+@import './dokan-components.css';
+@import '@getdokan/dokan-ui/dist/dokan-ui.css';
/* ============================================
Tailwind v4 Theme Configuration
...
`@layer` base {
...
}
.dokan-layout {
- `@import` "tailwindcss/preflight.css" layer(base);
- `@import` "tailwindcss/utilities.css";
-
- /* Import custom component styles */
- `@import` './dokan-components.css';
-
border-color: var(--color-border);
}
-@import '@getdokan/dokan-ui/dist/dokan-ui.css';🧰 Tools🪛 Biome (2.1.2)[error] 95-95: This Any (lint/correctness/noInvalidPositionAtImportRule) 🤖 Prompt for AI Agents |
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 98
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 102
🏁 Script executed:
sed -n '640,660p' ./includes/Admin/Dashboard/Dashboard.phpRepository: getdokan/dokan
Length of output: 878
🏁 Script executed:
sed -n '620,650p' ./includes/Admin/Dashboard/Dashboard.phpRepository: getdokan/dokan
Length of output: 1290
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 1151
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 5269
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 593
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 679
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 1103
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 200
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 901
🏁 Script executed:
Repository: getdokan/dokan
Length of output: 809
Add
rel="noopener noreferrer"for the external rating link and localize the user-facing string.target="_blank"withoutrelenables reverse-tabnabbing on external pages. Additionally, the footer text should be localized usingesc_html__()with the'dokan-lite'text domain for consistency with the plugin's localization pattern.Proposed fix
🤖 Prompt for AI Agents