Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion assets/css/admin/subscriptions.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/css/forms-list.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/css/frontend-subscriptions.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/ai-form-builder.min.js

Large diffs are not rendered by default.

28 changes: 14 additions & 14 deletions assets/js/forms-list.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/forms-list.min.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions assets/js/frontend-subscriptions.min.js

Large diffs are not rendered by default.

32 changes: 16 additions & 16 deletions assets/js/subscriptions.min.js

Large diffs are not rendered by default.

20 changes: 20 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@
"prettier-plugin-tailwindcss": "^0.5.11",
"tailwindcss": "^3.3.5",
"vitawind": "^2.3.0",
"vite": "^5.1.4"
"vite": "^5.1.4",
"tailwindcss-scoped-preflight": "^3.4.12"
},
"dependencies": {
"@headlessui/vue": "^1.7.23",
Expand Down
16 changes: 16 additions & 0 deletions tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
const colors = require('tailwindcss/colors');

import {
scopedPreflightStyles,
isolateInsideOfContainer,
} from 'tailwindcss-scoped-preflight';
Comment on lines +3 to +6
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Mixed module syntax may cause issues.

This file mixes ES module syntax (import) with CommonJS syntax (require on lines 1, 32-33, 44). While some build tools support this, it can lead to compatibility issues or unexpected behavior.

Consider using consistent module syntax throughout the file. Apply this diff to convert to CommonJS:

-import {
-    scopedPreflightStyles,
-    isolateInsideOfContainer,
-} from 'tailwindcss-scoped-preflight';
+const {
+    scopedPreflightStyles,
+    isolateInsideOfContainer,
+} = require('tailwindcss-scoped-preflight');
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
import {
scopedPreflightStyles,
isolateInsideOfContainer,
} from 'tailwindcss-scoped-preflight';
const {
scopedPreflightStyles,
isolateInsideOfContainer,
} = require('tailwindcss-scoped-preflight');
🤖 Prompt for AI Agents
In tailwind.config.js around lines 3 to 6 (and note existing CommonJS usage at
lines 1, 32-33, 44), the file mixes ES module import syntax with CommonJS
requires; convert the ES imports to CommonJS by replacing the import statement
with a const { scopedPreflightStyles, isolateInsideOfContainer } =
require('tailwindcss-scoped-preflight'); and ensure the rest of the file
continues to use module.exports/require consistently (or alternatively convert
all require usages to import/export if you prefer ESM), keeping a single module
system throughout.


/** @type {import('tailwindcss').Config} */
module.exports = {
prefix: 'wpuf-',
Expand All @@ -26,6 +31,17 @@ module.exports = {
plugins: [
require('@tailwindcss/forms'),
require('daisyui'),
scopedPreflightStyles( {
isolationStrategy: isolateInsideOfContainer(
[
'.wpuf_packs',
'#wpuf-subscription-page',
'#wpuf-form-builder',
'#wpuf-profile-forms-list-table-view'
], {}
),
} ),
require('@tailwindcss/forms'),
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

Remove duplicate plugin registration.

The @tailwindcss/forms plugin is already registered on line 32. This duplicate registration on line 44 will cause the plugin to be loaded twice, which may lead to unexpected behavior or warnings.

Apply this diff to remove the duplicate:

         scopedPreflightStyles( {
             isolationStrategy: isolateInsideOfContainer(
                 [
                     '.wpuf_packs',
                     '#wpuf-subscription-page',
                     '#wpuf-form-builder',
                     '#wpuf-profile-forms-list-table-view'
                 ], {}
             ),
         } ),
-        require('@tailwindcss/forms'),
     ],
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
require('@tailwindcss/forms'),
scopedPreflightStyles( {
isolationStrategy: isolateInsideOfContainer(
[
'.wpuf_packs',
'#wpuf-subscription-page',
'#wpuf-form-builder',
'#wpuf-profile-forms-list-table'
], {}
),
} ),
],
🤖 Prompt for AI Agents
In tailwind.config.js around line 44, the @tailwindcss/forms plugin is
registered twice (also at line 32); remove the duplicate
require('@tailwindcss/forms') entry at line 44 so the plugin is only listed once
in the plugins array, keeping the original registration at line 32 intact.

],
daisyui: {
themes: [],
Expand Down
Loading