| @@ -16,10 +16,10 @@ | ||
| 16 | 16 | /* Base */ |
| 17 | 17 | --sd-font-size: 16px; |
| 18 | 18 | |
| 19 | 19 | /* Colors - Primary */ |
| 20 | - --sd-color-scheme-primary: #10b981; | |
| 21 | - --sd-color-scheme-primary-hover: #059669; | |
| 20 | + --sd-color-scheme-primary: #1293B6; | |
| 21 | + --sd-color-scheme-primary-hover: #0F6E8C; | |
| 22 | 22 | |
| 23 | 23 | /* Colors - Input */ |
| 24 | 24 | --sd-color-input-text: #1f2937; |
| 25 | 25 | --sd-color-input-label: #1f2937; |
| @@ -28,10 +28,10 @@ | ||
| 28 | 28 | --sd-color-input-background: #ffffff; |
| 29 | 29 | --sd-color-input-background-hover: #f9fafb; |
| 30 | 30 | --sd-color-input-border: #d1d5db; |
| 31 | 31 | --sd-color-input-border-hover: #9ca3af; |
| 32 | - --sd-color-input-border-focus-glow: rgba(16, 185, 129, 0.15); | |
| 33 | - --sd-color-input-selected: rgba(16, 185, 129, 0.05); | |
| 32 | + --sd-color-input-border-focus-glow: rgba(18, 147, 182, 0.15); | |
| 33 | + --sd-color-input-selected: rgba(18, 147, 182, 0.1); | |
| 34 | 34 | --sd-color-multi-choice-svg: #9ca3af; |
| 35 | 35 | --sd-color-input-prefix: #6b7280; |
| 36 | 36 | |
| 37 | 37 | /* Colors - Error */ |
| @@ -44,9 +44,9 @@ | ||
| 44 | 44 | --sd-col-gap-between-fields: 16px; |
| 45 | 45 | --sd-row-gap-between-blocks: 18px; |
| 46 | 46 | |
| 47 | 47 | /* Input Field */ |
| 48 | - --sd-input-height: 40px; | |
| 48 | + --sd-input-height: 44px; | |
| 49 | 49 | --sd-input-field-font-size: 16px; |
| 50 | 50 | --sd-input-field-font-weight: 400; |
| 51 | 51 | --sd-input-field-line-height: 1.5; |
| 52 | 52 | --sd-input-field-padding: 10px 14px; |
| @@ -87,15 +87,47 @@ | ||
| 87 | 87 | --sd-btn-border-radius: 6px; |
| 88 | 88 | } |
| 89 | 89 | |
| 90 | 90 | /* ========================================================================== |
| 91 | + Hide WordPress Default Post Summary Panel | |
| 92 | + ========================================================================== */ | |
| 93 | + | |
| 94 | +body.post-type-suredonation_form .editor-post-summary { | |
| 95 | + display: none !important; | |
| 96 | +} | |
| 97 | + | |
| 98 | +body.post-type-suredonation_form .edit-post-post-status { | |
| 99 | + display: none !important; | |
| 100 | +} | |
| 101 | + | |
| 102 | +/* Description panel — remove card padding */ | |
| 103 | +.sd-single-form-settings-description .block-editor-block-card { | |
| 104 | + padding: 0; | |
| 105 | +} | |
| 106 | + | |
| 107 | +/* Form settings panel — flush tabs against panel edges */ | |
| 108 | +.sd-form-settings-panel .sd-inspector-tabs-container { | |
| 109 | + margin: -16px -16px 0; | |
| 110 | +} | |
| 111 | + | |
| 112 | +/* Hide the panel toggle title — tabs replace it */ | |
| 113 | +.sd-form-settings-panel > .components-panel__body-title { | |
| 114 | + display: none; | |
| 115 | +} | |
| 116 | + | |
| 117 | +/* Add breathing room between tab bar and settings content */ | |
| 118 | +.sd-form-settings-panel .sd-inspector-tab { | |
| 119 | + padding-top: 16px; | |
| 120 | +} | |
| 121 | + | |
| 122 | +/* ========================================================================== | |
| 91 | 123 | Editor Block Wrapper - Root Container Flex Layout |
| 92 | 124 | ========================================================================== */ |
| 93 | 125 | |
| 94 | 126 | /* Make the root container a flex container for block width support */ |
| 95 | 127 | /* Target any editor containing SD blocks */ |
| 96 | -.is-root-container.block-editor-block-list__layout:has([data-type^="sd/"]), | |
| 97 | -.block-editor-inner-blocks .block-editor-block-list__layout:has([data-type^="sd/"]) { | |
| 128 | +.is-root-container.block-editor-block-list__layout:has([data-type^="suredonation/"]), | |
| 129 | +.block-editor-inner-blocks .block-editor-block-list__layout:has([data-type^="suredonation/"]) { | |
| 98 | 130 | display: flex; |
| 99 | 131 | flex-wrap: wrap; |
| 100 | 132 | gap: var(--sd-row-gap-between-blocks, 18px) var(--sd-col-gap-between-fields, 16px); |
| 101 | 133 | padding: 0; |
| @@ -102,17 +134,18 @@ | ||
| 102 | 134 | max-width: 620px; |
| 103 | 135 | margin: 0 auto; |
| 104 | 136 | } |
| 105 | 137 | |
| 106 | -/* Override padding from built editor.css that causes width calculation issues */ | |
| 138 | +/* Match SureForms block padding (0 6px) — gives breathing room for selection outline */ | |
| 107 | 139 | body.post-type-suredonation_form div.is-root-container.block-editor-block-list__layout .block-editor-block-list__block, |
| 108 | 140 | body.post-type-suredonation_form div.is-root-container.block-editor-block-list__layout .block-list-appender { |
| 109 | - padding: 0 !important; | |
| 141 | + padding: 0 6px !important; | |
| 142 | + box-sizing: border-box; | |
| 110 | 143 | } |
| 111 | 144 | |
| 112 | 145 | /* Ensure box-sizing for all SD blocks - critical for height calculations */ |
| 113 | -.is-root-container [data-type^="sd/"] *, | |
| 114 | -.editor-styles-wrapper [data-type^="sd/"] * { | |
| 146 | +.is-root-container [data-type^="suredonation/"] *, | |
| 147 | +.editor-styles-wrapper [data-type^="suredonation/"] * { | |
| 115 | 148 | box-sizing: border-box; |
| 116 | 149 | } |
| 117 | 150 | |
| 118 | 151 | .editor-styles-wrapper .sd-block-single { |
| @@ -122,14 +155,14 @@ | ||
| 122 | 155 | margin-bottom: 0; |
| 123 | 156 | } |
| 124 | 157 | |
| 125 | 158 | /* Block placeholder styles - remove margin since gap handles it */ |
| 126 | -.editor-styles-wrapper [data-type^="sd/"] { | |
| 159 | +.editor-styles-wrapper [data-type^="suredonation/"] { | |
| 127 | 160 | margin: 0; |
| 128 | 161 | } |
| 129 | 162 | |
| 130 | 163 | /* Reset margin for last child compatibility */ |
| 131 | -.editor-styles-wrapper [data-type^="sd/"]:last-child { | |
| 164 | +.editor-styles-wrapper [data-type^="suredonation/"]:last-child { | |
| 132 | 165 | margin-bottom: 0; |
| 133 | 166 | } |
| 134 | 167 | |
| 135 | 168 | /* ========================================================================== |
| @@ -159,8 +192,20 @@ | ||
| 159 | 192 | margin-top: var(--sd-description-margin-top); |
| 160 | 193 | margin-bottom: var(--sd-input-label-gap, 6px); |
| 161 | 194 | } |
| 162 | 195 | |
| 196 | +.editor-styles-wrapper .sd-block-legend { | |
| 197 | + display: block; | |
| 198 | + font-size: var(--sd-label-font-size, 14px); | |
| 199 | + font-weight: var(--sd-label-font-weight); | |
| 200 | + line-height: var(--sd-label-line-height, 20px); | |
| 201 | + color: var(--sd-color-input-label, #1f2937); | |
| 202 | + word-break: break-word; | |
| 203 | + margin: 0; | |
| 204 | + padding: 0; | |
| 205 | + margin-bottom: var(--sd-input-label-gap, 6px); | |
| 206 | +} | |
| 207 | + | |
| 163 | 208 | /* ========================================================================== |
| 164 | 209 | Input Fields (Editor) - Matches SureForms editor input styles |
| 165 | 210 | ========================================================================== */ |
| 166 | 211 | |
| @@ -172,9 +217,9 @@ | ||
| 172 | 217 | .editor-styles-wrapper .sd-input-common { |
| 173 | 218 | display: block; |
| 174 | 219 | width: 100%; |
| 175 | 220 | height: var(--sd-input-height, 44px); |
| 176 | - /* padding: var(--sd-input-field-padding, 10px 14px); */ | |
| 221 | + padding: var(--sd-input-field-padding, 10px 14px); | |
| 177 | 222 | font-family: inherit; |
| 178 | 223 | font-size: var(--sd-input-field-font-size, 16px); |
| 179 | 224 | font-weight: var(--sd-input-field-font-weight); |
| 180 | 225 | line-height: var(--sd-input-field-line-height, 1.5); |
| @@ -241,30 +286,41 @@ | ||
| 241 | 286 | color: var(--sd-error-color); |
| 242 | 287 | margin-top: 6px; |
| 243 | 288 | } |
| 244 | 289 | |
| 290 | +.editor-styles-wrapper .sd-error-wrap { | |
| 291 | + height: var(--sd-error-line-height, 16px); | |
| 292 | +} | |
| 293 | + | |
| 245 | 294 | /* ========================================================================== |
| 246 | 295 | Checkbox Block (Editor) - Matches SureForms checkbox editor styles |
| 247 | 296 | ========================================================================== */ |
| 248 | 297 | |
| 249 | -.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-wrap { | |
| 298 | +.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-wrap, | |
| 299 | +.editor-styles-wrapper .sd-cover-fees-block .sd-checkbox-wrap, | |
| 300 | +.editor-styles-wrapper .sd-anonymous-donation-block .sd-checkbox-wrap { | |
| 250 | 301 | display: flex; |
| 251 | - align-items: flex-start; | |
| 302 | + align-items: center; | |
| 252 | 303 | } |
| 253 | 304 | |
| 254 | -.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-label { | |
| 305 | +.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-label, | |
| 306 | +.editor-styles-wrapper .sd-cover-fees-block .sd-checkbox-label, | |
| 307 | +.editor-styles-wrapper .sd-anonymous-donation-block .sd-checkbox-label { | |
| 255 | 308 | position: relative; |
| 256 | 309 | display: flex; |
| 257 | - align-items: flex-start; | |
| 310 | + align-items: center; | |
| 258 | 311 | gap: 10px; |
| 259 | 312 | cursor: default; |
| 260 | 313 | } |
| 261 | 314 | |
| 262 | -.editor-styles-wrapper .sd-checkbox-block .sd-input-checkbox { | |
| 315 | +.editor-styles-wrapper .sd-checkbox-block .sd-input-checkbox, | |
| 316 | +.editor-styles-wrapper .sd-cover-fees-block .sd-input-checkbox, | |
| 317 | +.editor-styles-wrapper .sd-anonymous-donation-block .sd-input-checkbox { | |
| 263 | 318 | position: relative; |
| 264 | 319 | flex-shrink: 0; |
| 265 | 320 | width: var(--sd-checkbox-size, 18px); |
| 266 | 321 | height: var(--sd-checkbox-size, 18px); |
| 322 | + padding: 0; | |
| 267 | 323 | border: 1px solid var(--sd-color-input-border, #d1d5db); |
| 268 | 324 | border-radius: var(--sd-checkbox-input-border-radius); |
| 269 | 325 | background-color: var(--sd-color-input-background, #ffffff); |
| 270 | 326 | -webkit-appearance: none; |
| @@ -273,15 +329,19 @@ | ||
| 273 | 329 | margin: 0; |
| 274 | 330 | pointer-events: none; |
| 275 | 331 | } |
| 276 | 332 | |
| 277 | -.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-text { | |
| 333 | +.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-text, | |
| 334 | +.editor-styles-wrapper .sd-cover-fees-block .sd-checkbox-text, | |
| 335 | +.editor-styles-wrapper .sd-anonymous-donation-block .sd-checkbox-text { | |
| 278 | 336 | font-size: var(--sd-input-field-font-size, 16px); |
| 279 | 337 | line-height: var(--sd-input-field-line-height, 1.5); |
| 280 | 338 | color: var(--sd-color-input-text, #1f2937); |
| 281 | 339 | } |
| 282 | 340 | |
| 283 | -.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-text .sd-required { | |
| 341 | +.editor-styles-wrapper .sd-checkbox-block .sd-checkbox-text .sd-required, | |
| 342 | +.editor-styles-wrapper .sd-cover-fees-block .sd-checkbox-text .sd-required, | |
| 343 | +.editor-styles-wrapper .sd-anonymous-donation-block .sd-checkbox-text .sd-required { | |
| 284 | 344 | color: var(--sd-error-color); |
| 285 | 345 | } |
| 286 | 346 | |
| 287 | 347 | /* ========================================================================== |
| @@ -291,8 +351,9 @@ | ||
| 291 | 351 | .editor-styles-wrapper .sd-multi-choice-block .sd-multi-choice-wrap { |
| 292 | 352 | display: flex; |
| 293 | 353 | flex-wrap: wrap; |
| 294 | 354 | margin: 0 -4px; |
| 355 | + width: calc(100% + 8px); | |
| 295 | 356 | padding: var(--sd-multi-choice-outer-padding, 0) 0; |
| 296 | 357 | } |
| 297 | 358 | |
| 298 | 359 | /* Layout variations - class on wrap div (matching SureForms pattern) */ |
| @@ -362,10 +423,10 @@ | ||
| 362 | 423 | } |
| 363 | 424 | |
| 364 | 425 | /* Selected state */ |
| 365 | 426 | .editor-styles-wrapper .sd-multi-choice-block .sd-multi-choice-single.sd-selected .sd-block-content-wrap { |
| 366 | - border-color: var(--sd-color-input-border-hover, #9ca3af); | |
| 367 | - background-color: var(--sd-color-input-selected, #f0fdf4); | |
| 427 | + border-color: var(--sd-color-scheme-primary, #1293B6); | |
| 428 | + background-color: var(--sd-color-input-selected, rgba(18, 147, 182, 0.1)); | |
| 368 | 429 | } |
| 369 | 430 | |
| 370 | 431 | /* Option container */ |
| 371 | 432 | .editor-styles-wrapper .sd-multi-choice-block .sd-option-container { |
| @@ -417,9 +478,9 @@ | ||
| 417 | 478 | /* Selected state - show checked icon, hide unchecked icon */ |
| 418 | 479 | .editor-styles-wrapper .sd-multi-choice-block .sd-multi-choice-single.sd-selected .sd-multi-choice-icon { |
| 419 | 480 | opacity: 1; |
| 420 | 481 | width: auto; |
| 421 | - color: var(--sd-color-scheme-primary, #10b981); | |
| 482 | + color: var(--sd-color-scheme-primary, #1293B6); | |
| 422 | 483 | } |
| 423 | 484 | |
| 424 | 485 | .editor-styles-wrapper .sd-multi-choice-block .sd-multi-choice-single.sd-selected .sd-multi-choice-icon-unchecked { |
| 425 | 486 | opacity: 0; |
| @@ -493,8 +554,49 @@ | ||
| 493 | 554 | color: #92400e; |
| 494 | 555 | font-size: var(--sd-description-font-size, 13px); |
| 495 | 556 | } |
| 496 | 557 | |
| 558 | +/* Payment field wrapper in editor — matches SureForms .srfm-payment-block-wrap */ | |
| 559 | +.editor-styles-wrapper .sd-payment-field-wrapper { | |
| 560 | + border: 1px dashed rgba(30, 30, 30, 0.25); | |
| 561 | + border-radius: 6px; | |
| 562 | + padding: 16px; | |
| 563 | + margin-top: var(--sd-input-label-gap, 6px); | |
| 564 | + display: flex; | |
| 565 | + flex-direction: column; | |
| 566 | + gap: 12px; | |
| 567 | +} | |
| 568 | + | |
| 569 | +.editor-styles-wrapper .sd-payment-field-wrapper > p { | |
| 570 | + font-weight: 400; | |
| 571 | + font-size: 14px; | |
| 572 | + line-height: 20px; | |
| 573 | + margin: 0; | |
| 574 | + padding: 0; | |
| 575 | + color: rgba(30, 30, 30, 0.65); | |
| 576 | +} | |
| 577 | + | |
| 578 | +.editor-styles-wrapper .sd-stripe-payment-error-text { | |
| 579 | + color: #dc2626; | |
| 580 | +} | |
| 581 | + | |
| 582 | +.editor-styles-wrapper .sd-stripe-connect-button { | |
| 583 | + background-color: transparent; | |
| 584 | + border-radius: 4px; | |
| 585 | + cursor: pointer; | |
| 586 | + font-size: 12px; | |
| 587 | + font-weight: 600; | |
| 588 | + color: #111827; | |
| 589 | + padding: 8px; | |
| 590 | + width: fit-content; | |
| 591 | + border: 1px solid #d1d5db; | |
| 592 | + box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.05); | |
| 593 | +} | |
| 594 | + | |
| 595 | +.editor-styles-wrapper .sd-payment-field-wrapper .sd-offline-info-text { | |
| 596 | + color: #1e40af; | |
| 597 | +} | |
| 598 | + | |
| 497 | 599 | /* Submit Button Preview */ |
| 498 | 600 | .editor-styles-wrapper .sd-payment-submit { |
| 499 | 601 | margin-top: 8px; |
| 500 | 602 | } |
| @@ -509,9 +611,9 @@ | ||
| 509 | 611 | font-size: var(--sd-btn-font-size, 16px); |
| 510 | 612 | font-weight: var(--sd-btn-font-weight); |
| 511 | 613 | line-height: var(--sd-btn-line-height, 1.5); |
| 512 | 614 | color: #ffffff; |
| 513 | - background-color: var(--sd-color-scheme-primary, #10b981); | |
| 615 | + background-color: var(--sd-color-scheme-primary, #1293B6); | |
| 514 | 616 | border: none; |
| 515 | 617 | border-radius: var(--sd-btn-border-radius); |
| 516 | 618 | cursor: default; |
| 517 | 619 | pointer-events: none; |
| @@ -520,15 +622,15 @@ | ||
| 520 | 622 | /* ========================================================================== |
| 521 | 623 | Block Selection States |
| 522 | 624 | ========================================================================== */ |
| 523 | 625 | |
| 524 | -.editor-styles-wrapper [data-type^="sd/"].is-selected .sd-block-single, | |
| 525 | -.editor-styles-wrapper [data-type^="sd/"].has-child-selected .sd-block-single { | |
| 626 | +.editor-styles-wrapper [data-type^="suredonation/"].is-selected .sd-block-single, | |
| 627 | +.editor-styles-wrapper [data-type^="suredonation/"].has-child-selected .sd-block-single { | |
| 526 | 628 | position: relative; |
| 527 | 629 | } |
| 528 | 630 | |
| 529 | 631 | /* Subtle highlight on selection */ |
| 530 | -.editor-styles-wrapper [data-type^="sd/"].is-selected::after { | |
| 632 | +.editor-styles-wrapper [data-type^="suredonation/"].is-selected::after { | |
| 531 | 633 | content: ''; |
| 532 | 634 | position: absolute; |
| 533 | 635 | top: -4px; |
| 534 | 636 | left: -4px; |
| @@ -533,9 +635,9 @@ | ||
| 533 | 635 | top: -4px; |
| 534 | 636 | left: -4px; |
| 535 | 637 | right: -4px; |
| 536 | 638 | bottom: -4px; |
| 537 | - border: 2px solid var(--sd-color-scheme-primary, #10b981); | |
| 639 | + border: 2px solid var(--sd-color-scheme-primary, #1293B6); | |
| 538 | 640 | border-radius: 4px; |
| 539 | 641 | pointer-events: none; |
| 540 | 642 | opacity: 0.5; |
| 541 | 643 | } |
| @@ -545,9 +647,9 @@ | ||
| 545 | 647 | ========================================================================== */ |
| 546 | 648 | |
| 547 | 649 | /* Style for SD blocks in the inserter */ |
| 548 | 650 | .block-editor-block-types-list__list-item[class*="sd-"] .block-editor-block-types-list__item-icon { |
| 549 | - color: var(--sd-color-scheme-primary, #10b981); | |
| 651 | + color: var(--sd-color-scheme-primary, #1293B6); | |
| 550 | 652 | } |
| 551 | 653 | |
| 552 | 654 | /* ========================================================================== |
| 553 | 655 | Responsive Preview |
| @@ -632,14 +734,14 @@ | ||
| 632 | 734 | transition: border-color 0.2s; |
| 633 | 735 | } |
| 634 | 736 | |
| 635 | 737 | .sd-gateway-option:hover { |
| 636 | - border-color: var(--sd-color-scheme-primary, #10b981); | |
| 738 | + border-color: var(--sd-color-scheme-primary, #1293B6); | |
| 637 | 739 | } |
| 638 | 740 | |
| 639 | 741 | .sd-gateway-option.is-selected { |
| 640 | - border-color: var(--sd-color-scheme-primary, #10b981); | |
| 641 | - background-color: rgba(16, 185, 129, 0.05); | |
| 742 | + border-color: var(--sd-color-scheme-primary, #1293B6); | |
| 743 | + background-color: rgba(18, 147, 182, 0.05); | |
| 642 | 744 | } |
| 643 | 745 | |
| 644 | 746 | .sd-gateway-option svg { |
| 645 | 747 | width: 24px; |
| @@ -656,9 +758,9 @@ | ||
| 656 | 758 | color: var(--sd-color-input-description, #6b7280); |
| 657 | 759 | } |
| 658 | 760 | |
| 659 | 761 | .sd-gateway-option-status.is-configured { |
| 660 | - color: var(--sd-color-scheme-primary, #10b981); | |
| 762 | + color: var(--sd-color-scheme-primary, #1293B6); | |
| 661 | 763 | } |
| 662 | 764 | |
| 663 | 765 | /* ========================================================================== |
| 664 | 766 | Test Mode Banner |