|
25 | 25 | <!-- Gradient overlay for better text contrast --> |
26 | 26 | <div style="position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: linear-gradient(135deg, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.1) 100%);"></div> |
27 | 27 |
|
| 28 | + <!-- Help button for how to join --> |
| 29 | + <div class="help-tooltip-container" style="position: absolute; top: 20px; right: 20px; z-index: 10;"> |
| 30 | + <a class="btn-floating white z-depth-2 pulse" id="how-to-join-btn" style="height: 42px; width: 42px; display: flex; align-items: center; justify-content: center;"> |
| 31 | + <i class="material-icons <%= @accent_color %>-text">help_outline</i> |
| 32 | + </a> |
| 33 | + </div> |
| 34 | + |
28 | 35 | <!-- Art Fight 2025 header info --> |
29 | 36 | <div style="position: absolute; top: 40px; left: 40px; z-index: 1; max-width: 60%;"> |
30 | 37 | <div> |
|
328 | 335 | // Initialize with "All" selected |
329 | 336 | filterLinks[0].style.backgroundColor = '<%= @accent_color == "grey" ? "#9e9e9e" : "var(--#{@accent_color}-lighten-4)" %>'; |
330 | 337 | filterLinks[0].style.fontWeight = '500'; |
| 338 | + |
| 339 | + // How to join modal |
| 340 | + document.getElementById('how-to-join-btn').addEventListener('click', function() { |
| 341 | + // Show modal |
| 342 | + var modalHtml = ` |
| 343 | + <div id="how-to-join-modal" class="modal modal-how-to-join"> |
| 344 | + <div class="modal-content"> |
| 345 | + <h4><i class="material-icons <%= @accent_color %>-text left" style="margin-right: 10px;">info</i> How to join this showcase</h4> |
| 346 | + <p>Want your content to appear on this page? Follow these steps:</p> |
| 347 | + <ol> |
| 348 | + <li>Add the <span class="highlight">ArtFight2025</span> tag to your content</li> |
| 349 | + <li>Set your content's privacy to <span class="highlight">Public</span> in the privacy toggle</li> |
| 350 | + <li>That's it! Your content will appear here automatically</li> |
| 351 | + </ol> |
| 352 | + <p class="grey-text" style="font-size: 14px;">Note: It may take a few minutes for new content to appear.</p> |
| 353 | + </div> |
| 354 | + <div class="modal-footer"> |
| 355 | + <a href="#!" class="modal-close waves-effect waves-light <%= @accent_color %> btn-flat white-text">Got it</a> |
| 356 | + </div> |
| 357 | + </div> |
| 358 | + `; |
| 359 | + |
| 360 | + // Add modal to DOM if it doesn't exist |
| 361 | + if (!document.getElementById('how-to-join-modal')) { |
| 362 | + document.body.insertAdjacentHTML('beforeend', modalHtml); |
| 363 | + } |
| 364 | + |
| 365 | + // Initialize and open modal |
| 366 | + var modalElement = document.getElementById('how-to-join-modal'); |
| 367 | + var modalInstance = M.Modal.init(modalElement, {opacity: 0.6}); |
| 368 | + modalInstance.open(); |
| 369 | + }); |
331 | 370 | }); |
332 | 371 | <% end %> |
333 | 372 |
|
334 | 373 | <!-- Add CSS variables for colors --> |
335 | 374 | <style> |
| 375 | + /* Help modal for how to join */ |
| 376 | + .modal-how-to-join { |
| 377 | + border-radius: 8px; |
| 378 | + max-width: 500px; |
| 379 | + } |
| 380 | + |
| 381 | + .modal-how-to-join h4 { |
| 382 | + margin-top: 0; |
| 383 | + font-size: 20px; |
| 384 | + font-weight: 500; |
| 385 | + } |
| 386 | + |
| 387 | + .modal-how-to-join ol { |
| 388 | + padding-left: 25px; |
| 389 | + } |
| 390 | + |
| 391 | + .modal-how-to-join li { |
| 392 | + margin-bottom: 10px; |
| 393 | + } |
| 394 | + |
| 395 | + .modal-how-to-join .highlight { |
| 396 | + background-color: #f3e5f5; |
| 397 | + padding: 2px 5px; |
| 398 | + border-radius: 3px; |
| 399 | + } |
| 400 | + |
336 | 401 | :root { |
337 | 402 | --purple: #9c27b0; |
338 | 403 | --purple-lighten-1: #ab47bc; |
|
384 | 449 | margin-bottom: 0; |
385 | 450 | } |
386 | 451 |
|
387 | | - /* Make all cards in a row the same height */ |
| 452 | + /* Make all cards in a row the same height and align left */ |
388 | 453 | .js-content-cards-list { |
389 | 454 | display: flex; |
390 | 455 | flex-wrap: wrap; |
391 | 456 | margin-left: -0.75rem; |
392 | 457 | margin-right: -0.75rem; |
| 458 | + justify-content: flex-start; |
393 | 459 | } |
394 | 460 |
|
395 | 461 | /* Make sure card containers take their full column width */ |
|
0 commit comments