-
Notifications
You must be signed in to change notification settings - Fork 153
feat: add card grid UI for payment gateway selection #1830
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1603,3 +1603,101 @@ body.wpuf-modal-open { | |
| .wpuf-login-settings-row.hidden { | ||
| display: none !important; | ||
| } | ||
| .wpuf-gateway-cards { | ||
| display: flex; | ||
| flex-wrap: wrap; | ||
| gap: 12px; | ||
| } | ||
| .wpuf-gateway-card { | ||
| position: relative; | ||
| display: flex; | ||
| flex-direction: column; | ||
| align-items: center; | ||
| justify-content: center; | ||
| width: 150px; | ||
| padding: 20px 16px 14px; | ||
| border: 2px solid #e0e0e0; | ||
| border-radius: 6px; | ||
| background: #fff; | ||
| cursor: pointer; | ||
| transition: border-color 0.15s ease, box-shadow 0.15s ease; | ||
| } | ||
| .wpuf-gateway-card:hover { | ||
| border-color: #c3c4c7; | ||
| box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06); | ||
| } | ||
| .wpuf-gateway-card--active:hover { | ||
| border-color: #10b981; | ||
| } | ||
| .wpuf-gateway-card--focused { | ||
| border-color: #10b981; | ||
| box-shadow: 0 0 0 1px #10b981; | ||
| } | ||
| .wpuf-gateway-card--focused:hover { | ||
| border-color: #10b981; | ||
| } | ||
| .wpuf-gateway-card--pro-locked { | ||
| opacity: 0.6; | ||
| cursor: not-allowed; | ||
| } | ||
| .wpuf-gateway-card__checkbox { | ||
| position: absolute; | ||
| opacity: 0; | ||
| width: 0; | ||
| height: 0; | ||
| pointer-events: none; | ||
| } | ||
| .wpuf-gateway-card__toggle { | ||
| position: absolute; | ||
| top: 4px; | ||
| right: 4px; | ||
| cursor: pointer; | ||
| line-height: 1; | ||
| padding: 4px; | ||
| z-index: 2; | ||
| } | ||
| .wpuf-gateway-card__toggle:hover { | ||
| opacity: 0.8; | ||
| } | ||
|
Comment on lines
+1625
to
+1661
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. Locked cards still look clickable.
Proposed CSS adjustment .wpuf-gateway-card--pro-locked {
opacity: 0.6;
cursor: not-allowed;
}
+.wpuf-gateway-card--pro-locked:hover,
+.wpuf-gateway-card--pro-locked.wpuf-gateway-card--focused {
+ border-color: `#e0e0e0`;
+ box-shadow: none;
+}
+.wpuf-gateway-card--pro-locked .wpuf-gateway-card__toggle,
+.wpuf-gateway-card--pro-locked .wpuf-gateway-card__toggle:hover {
+ cursor: not-allowed;
+ opacity: 1;
+}🤖 Prompt for AI Agents |
||
| .wpuf-gateway-card__check-on { | ||
| display: none; | ||
| } | ||
| .wpuf-gateway-card__check-off { | ||
| display: block; | ||
| } | ||
| .wpuf-gateway-card--active .wpuf-gateway-card__check-on { | ||
| display: block; | ||
| } | ||
| .wpuf-gateway-card--active .wpuf-gateway-card__check-off { | ||
| display: none; | ||
| } | ||
| .wpuf-gateway-card__icon { | ||
| display: flex; | ||
| align-items: center; | ||
| justify-content: center; | ||
| width: 100%; | ||
| height: 48px; | ||
| margin-bottom: 8px; | ||
| } | ||
| .wpuf-gateway-card__icon img { | ||
| max-width: 100px; | ||
| max-height: 48px; | ||
| object-fit: contain; | ||
| } | ||
| .wpuf-gateway-card__icon svg { | ||
| max-width: 48px; | ||
| max-height: 48px; | ||
| } | ||
| .wpuf-gateway-card__name { | ||
| font-size: 13px; | ||
| font-weight: 500; | ||
| color: #1d2327; | ||
| text-align: center; | ||
| line-height: 1.3; | ||
| } | ||
| tr.wpuf-gateway-setting-row { | ||
| transition: opacity 0.15s ease; | ||
| } | ||
| tr.wpuf-gateway-setting-row.wpuf-gateway-setting-hidden { | ||
| display: none; | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -937,6 +937,9 @@ body #wpuf-payment-gateway ul.wpuf-payment-gateways { | |
| body #wpuf-payment-gateway ul.wpuf-payment-gateways li { | ||
| margin: 0; | ||
| } | ||
| body #wpuf-payment-gateway ul.wpuf-payment-gateways li.wpuf-gateway-paypal img { | ||
| max-width: 15px; | ||
| } | ||
|
Comment on lines
+940
to
+942
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: # Check for Tailwind configuration and package.json
fd -t f -e json "tailwind|package" | head -20Repository: weDevsOfficial/wp-user-frontend Length of output: 233 🏁 Script executed: # Search for Tailwind CSS imports or configuration
rg -i "tailwind|daisyui" --type json --type js --type css -A 3 | head -50Repository: weDevsOfficial/wp-user-frontend Length of output: 2404 🏁 Script executed: # Check the structure of the CSS file to understand styling approach
cat -n assets/css/frontend-forms.css | head -50Repository: weDevsOfficial/wp-user-frontend Length of output: 1598 🏁 Script executed: # Check if there are any Tailwind or CSS imports in the HTML/PHP files
rg -i "tailwind|scoped.*preflight" --type php --type html | head -20Repository: weDevsOfficial/wp-user-frontend Length of output: 890 🏁 Script executed: # Check the beginning of frontend-forms.css to see if it has `@tailwind` directives
head -20 assets/css/frontend-forms.cssRepository: weDevsOfficial/wp-user-frontend Length of output: 585 🏁 Script executed: # Look at context around lines 940-942
sed -n '935,950p' assets/css/frontend-forms.cssRepository: weDevsOfficial/wp-user-frontend Length of output: 534 🏁 Script executed: # Check if frontend-forms.css has any Tailwind directives
rg "@tailwind|@layer" assets/css/frontend-forms.cssRepository: weDevsOfficial/wp-user-frontend Length of output: 57 🏁 Script executed: # Check package.json for build scripts and Tailwind configuration
cat package.json | head -100Repository: weDevsOfficial/wp-user-frontend Length of output: 2457 🏁 Script executed: # Verify if tailwind.config.js references assets/css or src/css
cat tailwind.config.js | head -50Repository: weDevsOfficial/wp-user-frontend Length of output: 1840 🏁 Script executed: # Check if frontend-forms.css exists in src/ directory
find . -name "frontend-forms.css" -o -name "*frontend-forms*" | grep -v node_modulesRepository: weDevsOfficial/wp-user-frontend Length of output: 140 🏁 Script executed: # Check Gruntfile for Tailwind build configuration
fd -t f "Gruntfile" | xargs cat | head -100Repository: weDevsOfficial/wp-user-frontend Length of output: 3396 🏁 Script executed: # Check if assets/css files are in git or generated
git status assets/css/ 2>/dev/null | head -20Repository: weDevsOfficial/wp-user-frontend Length of output: 140 🏁 Script executed: # Look for a build config that might compile src/ to assets/
rg "tailwind|src/css|assets/css" Gruntfile.js -A 5 -B 5 2>/dev/null | head -50Repository: weDevsOfficial/wp-user-frontend Length of output: 1821 Avoid adding styles to the legacy LESS pipeline; migrate to Tailwind CSS instead. The rule at lines 940-942 is being added to 🤖 Prompt for AI Agents |
||
| body #wpuf-payment-gateway ul.wpuf-payment-gateways li .wpuf-payment-instruction { | ||
| padding: 8px 10px; | ||
| margin: 0 10px; | ||
|
|
||
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.
Replace the placeholder
@sincevalue.@since WPUF_SINCEshould be replaced with the actual release version before merge.🤖 Prompt for AI Agents