diff --git a/api.http b/api.http index 4c66189..501605c 100644 --- a/api.http +++ b/api.http @@ -49,7 +49,7 @@ Accept: application/json Authorization: Bearer {{$auth.token("oauth2_api")}} ### API travel -GET {{base_url}}/api/travels/DWWWE211125 +GET {{base_url}}/api/travels/SBW131225 Accept: application/json Authorization: Bearer {{$auth.token("oauth2_api")}} diff --git a/assets/images/bg_6.jpg b/assets/images/bg_6.jpg new file mode 100755 index 0000000..b4098fa Binary files /dev/null and b/assets/images/bg_6.jpg differ diff --git a/assets/images/bg_7.jpg b/assets/images/bg_7.jpg new file mode 100755 index 0000000..8d7016f Binary files /dev/null and b/assets/images/bg_7.jpg differ diff --git a/assets/images/bg_sbw.jpg b/assets/images/bg_sbw.jpg new file mode 100644 index 0000000..d3372a5 Binary files /dev/null and b/assets/images/bg_sbw.jpg differ diff --git a/assets/images/logo.svg b/assets/images/logo_ep.svg similarity index 100% rename from assets/images/logo.svg rename to assets/images/logo_ep.svg diff --git a/assets/images/logo_sbw.svg b/assets/images/logo_sbw.svg new file mode 100644 index 0000000..64d3561 --- /dev/null +++ b/assets/images/logo_sbw.svg @@ -0,0 +1,673 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assets/images/logo_ser.svg b/assets/images/logo_ser.svg new file mode 100644 index 0000000..05ab197 --- /dev/null +++ b/assets/images/logo_ser.svg @@ -0,0 +1,58 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assets/images/logo_snz.svg b/assets/images/logo_snz.svg new file mode 100644 index 0000000..7b534d9 --- /dev/null +++ b/assets/images/logo_snz.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/assets/styles/_base.css b/assets/styles/_base.css index 681ff5d..7d1f8e9 100644 --- a/assets/styles/_base.css +++ b/assets/styles/_base.css @@ -53,6 +53,14 @@ background-image: url('../images/bg_5.jpg'), linear-gradient(190deg, rgba(24, 82, 123, 1) 0%, rgba(22, 88, 131, 1) 62%, rgba(0, 112, 224, 1) 100%);; } +.sbw .bg-outer--2 { + background-image: url('../images/bg_7.jpg'), linear-gradient(190deg, rgba(24, 82, 123, 1) 0%, rgba(22, 88, 131, 1) 62%, rgba(0, 112, 224, 1) 100%);; +} + +.snz .bg-outer--2 { + background-image: url('../images/bg_6.jpg'), linear-gradient(190deg, rgba(24, 82, 123, 1) 0%, rgba(22, 88, 131, 1) 62%, rgba(0, 112, 224, 1) 100%);; +} + .bg-inner { background-image: linear-gradient(190deg, rgba(24, 82, 123, 0.8) 0%, rgba(22, 88, 131, 0.8) 62%, rgba(0, 112, 224, 0.8) 100%);; } diff --git a/assets/styles/components/button.css b/assets/styles/components/button.css index 4984eb9..4a568e7 100644 --- a/assets/styles/components/button.css +++ b/assets/styles/components/button.css @@ -9,8 +9,14 @@ @apply px-2 py-1 md:px-4 text-xs sm:text-sm; } -.button--full { - @apply block w-full; +.button--primary { + background: linear-gradient(120deg, #960167 0%, #9e036a 40%, #fa1a8c 100%); + @apply text-white; + @apply hover:bg-none hover:bg-pink/80; +} + +.button[disabled] { + @apply cursor-not-allowed; } .button--secondary { @@ -18,20 +24,38 @@ @apply hover:bg-primary-light/80; } -.button--primary { - background: linear-gradient(120deg, #960167 0%, #9e036a 40%, #fa1a8c 100%); - @apply text-white; - @apply hover:bg-none hover:bg-pink/80; +.sbw { + .button--primary { + @apply bg-none bg-sbw-secondary text-white; + @apply hover:bg-none hover:bg-sbw-primary/80; + } + + .button--secondary { + @apply bg-none bg-sbw-primary-dark text-white; + @apply hover:bg-none hover:bg-sbw-primary/80; + } } -.button--muted { - @apply bg-zinc-300 hover:bg-zinc-300; +.snz { + .button--primary { + @apply bg-none bg-snz-secondary text-white; + @apply hover:bg-none hover:bg-snz-primary/80; + } + + .button--secondary { + @apply bg-none bg-snz-primary-dark text-white; + @apply hover:bg-none hover:bg-snz-primary/80; + } } -.button--dark { - @apply bg-primary-dark; -} +.ser { + .button--primary { + @apply bg-none bg-ser-secondary text-white; + @apply hover:bg-none hover:bg-ser-primary/80; + } -.button[disabled] { - @apply cursor-not-allowed; + .button--secondary { + @apply bg-none bg-ser-primary text-white; + @apply hover:bg-none hover:bg-ser-primary/80; + } } diff --git a/assets/styles/components/forms.css b/assets/styles/components/forms.css index eb7d901..5c97701 100644 --- a/assets/styles/components/forms.css +++ b/assets/styles/components/forms.css @@ -33,3 +33,24 @@ select[readonly] { input[readonly] { @apply cursor-not-allowed; } + +.sbw { + .form-checkbox, + .form-radio { + @apply text-sbw-secondary; + } +} + +.snz { + .form-checkbox, + .form-radio { + @apply text-snz-primary; + } +} + +.ser { + .form-checkbox, + .form-radio { + @apply text-ser-secondary; + } +} diff --git a/assets/styles/components/pagination.css b/assets/styles/components/pagination.css index bcaf9ed..2343aaa 100644 --- a/assets/styles/components/pagination.css +++ b/assets/styles/components/pagination.css @@ -58,3 +58,33 @@ a.pagination-item__border > .pagination-item__inner:hover { /* No left/bottom-left border on overlapping edge, no right border */ clip-path: polygon(0 0, 100% 0, 100% 100%, var(--pagination-skew) 100%); } + +.sbw { + .pagination-item__border { + @apply bg-sbw-primary-dark/10; + } + + a.pagination-item__border > .pagination-item__inner:hover { + @apply bg-sbw-primary; + } +} + +.snz { + .pagination-item__border { + @apply bg-snz-primary-dark/10; + } + + a.pagination-item__border > .pagination-item__inner:hover { + @apply bg-snz-primary; + } +} + +.ser { + .pagination-item__border { + @apply bg-ser-primary/10; + } + + a.pagination-item__border > .pagination-item__inner:hover { + @apply bg-ser-primary; + } +} diff --git a/assets/styles/components/tooltip.css b/assets/styles/components/tooltip.css index 4cd1f4c..7efff73 100644 --- a/assets/styles/components/tooltip.css +++ b/assets/styles/components/tooltip.css @@ -3,7 +3,6 @@ .tippy-box { background-color: theme('colors.primary'); } - .tippy-box[data-placement^='top'] > .tippy-arrow::before { border-top-color: theme('colors.primary'); } @@ -16,3 +15,57 @@ .tippy-box[data-placement^='right'] > .tippy-arrow::before { border-right-color: theme('colors.primary'); } + +.sbw { + .tippy-box { + background-color: theme('colors.sbw.secondary'); + } + .tippy-box[data-placement^='top'] > .tippy-arrow::before { + border-top-color: theme('colors.sbw.secondary'); + } + .tippy-box[data-placement^='bottom'] > .tippy-arrow::before { + border-bottom-color: theme('colors.sbw.secondary'); + } + .tippy-box[data-placement^='left'] > .tippy-arrow::before { + border-left-color: theme('colors.sbw.secondary'); + } + .tippy-box[data-placement^='right'] > .tippy-arrow::before { + border-right-color: theme('colors.sbw.secondary'); + } +} + +.snz { + .tippy-box { + background-color: theme('colors.snz.primary-dark'); + } + .tippy-box[data-placement^='top'] > .tippy-arrow::before { + border-top-color: theme('colors.snz.primary-dark'); + } + .tippy-box[data-placement^='bottom'] > .tippy-arrow::before { + border-bottom-color: theme('colors.snz.primary-dark'); + } + .tippy-box[data-placement^='left'] > .tippy-arrow::before { + border-left-color: theme('colors.snz.primary-dark'); + } + .tippy-box[data-placement^='right'] > .tippy-arrow::before { + border-right-color: theme('colors.snz.primary-dark'); + } +} + +.ser { + .tippy-box { + background-color: theme('colors.ser.secondary'); + } + .tippy-box[data-placement^='top'] > .tippy-arrow::before { + border-top-color: theme('colors.ser.secondary'); + } + .tippy-box[data-placement^='bottom'] > .tippy-arrow::before { + border-bottom-color: theme('colors.ser.secondary'); + } + .tippy-box[data-placement^='left'] > .tippy-arrow::before { + border-left-color: theme('colors.ser.secondary'); + } + .tippy-box[data-placement^='right'] > .tippy-arrow::before { + border-right-color: theme('colors.ser.secondary'); + } +} diff --git a/package-lock.json b/package-lock.json index d643421..b6c5e11 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,15 +1,11 @@ { - "name": "myep-next", + "name": "myep", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "myep-next", + "name": "myep", "license": "WTFPL", - "dependencies": { - "tippy.js": "^6.3.7", - "toastify-js": "^1.12.0" - }, "devDependencies": { "@babel/core": "^7.17.0", "@babel/preset-env": "^7.16.0", @@ -27,6 +23,8 @@ "postcss-loader": "^8.1.1", "regenerator-runtime": "^0.13.9", "tailwindcss": "^3.4.15", + "tippy.js": "^6.3.7", + "toastify-js": "^1.12.0", "webpack": "^5.74.0", "webpack-cli": "^5.1.0", "webpack-notifier": "^1.15.0" @@ -1637,35 +1635,50 @@ "@hotwired/stimulus": ">= 3.0" } }, - "node_modules/@jest/schemas": { - "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", - "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "node_modules/@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", "dev": true, "license": "MIT", "dependencies": { - "@sinclair/typebox": "^0.27.8" + "@types/node": "*", + "jest-regex-util": "30.0.1" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@sinclair/typebox": "^0.34.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/@jest/types": { - "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", - "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, "license": "MIT", "dependencies": { - "@jest/schemas": "^29.6.3", - "@types/istanbul-lib-coverage": "^2.0.0", - "@types/istanbul-reports": "^3.0.0", + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", "@types/node": "*", - "@types/yargs": "^17.0.8", - "chalk": "^4.0.0" + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/@jest/types/node_modules/ansi-styles": { @@ -1867,6 +1880,7 @@ "version": "2.11.8", "resolved": "https://registry.npmjs.org/@popperjs/core/-/core-2.11.8.tgz", "integrity": "sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==", + "dev": true, "license": "MIT", "funding": { "type": "opencollective", @@ -1874,9 +1888,9 @@ } }, "node_modules/@sinclair/typebox": { - "version": "0.27.8", - "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", - "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "version": "0.34.41", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.41.tgz", + "integrity": "sha512-6gS8pZzSXdyRHTIqoqSVknxolr1kzfy4/CeDnrzsVz8TTIWUbOBr6gnzOmTYJ3eXQNh4IYHIGi5aIL7sOZ2G/g==", "dev": true, "license": "MIT" }, @@ -2161,9 +2175,9 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "24.10.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-24.10.1.tgz", - "integrity": "sha512-GNWcUTRBgIRJD5zj+Tq0fKOJ5XZajIiBroOF0yvj2bSU1WvNdYS/dn9UxwsujGW4JX06dnHyjV2y9rRaybH0iQ==", + "version": "25.0.1", + "resolved": "https://registry.npmjs.org/@types/node/-/node-25.0.1.tgz", + "integrity": "sha512-czWPzKIAXucn9PtsttxmumiQ9N0ok9FrBwgRWrwmVLlp86BrMExzvXRLFYRJ+Ex3g6yqj+KuaxfX1JTgV2lpfg==", "dev": true, "license": "MIT", "dependencies": { @@ -2226,6 +2240,13 @@ "@types/node": "*" } }, + "node_modules/@ungap/structured-clone": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.3.0.tgz", + "integrity": "sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==", + "dev": true, + "license": "ISC" + }, "node_modules/@webassemblyjs/ast": { "version": "1.14.1", "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.14.1.tgz", @@ -2654,6 +2675,19 @@ "node": ">= 8" } }, + "node_modules/anymatch/node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, "node_modules/arch": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/arch/-/arch-2.2.0.tgz", @@ -2872,9 +2906,9 @@ "license": "MIT" }, "node_modules/baseline-browser-mapping": { - "version": "2.8.32", - "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.8.32.tgz", - "integrity": "sha512-OPz5aBThlyLFgxyhdwf/s2+8ab3OvT7AdTNvKHBwpXomIYeXqpUUuT8LrdtxZSsWJ4R4CU1un4XGh5Ez3nlTpw==", + "version": "2.9.6", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.6.tgz", + "integrity": "sha512-v9BVVpOTLB59C9E7aSnmIF8h7qRsFpx+A2nugVMTszEOMcfjlZMsXRm4LF23I3Z9AJxc8ANpIvzbzONoX9VJlg==", "dev": true, "license": "Apache-2.0", "bin": { @@ -2949,9 +2983,9 @@ } }, "node_modules/browserslist": { - "version": "4.28.0", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.0.tgz", - "integrity": "sha512-tbydkR/CxfMwelN0vwdP/pLkDwyAASZ+VfWm4EOwlB6SWhx1sYnWLqo8N5j0rAzPfzfRaxt0mM/4wPU/Su84RQ==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.1.tgz", + "integrity": "sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==", "dev": true, "funding": [ { @@ -2969,11 +3003,11 @@ ], "license": "MIT", "dependencies": { - "baseline-browser-mapping": "^2.8.25", - "caniuse-lite": "^1.0.30001754", - "electron-to-chromium": "^1.5.249", + "baseline-browser-mapping": "^2.9.0", + "caniuse-lite": "^1.0.30001759", + "electron-to-chromium": "^1.5.263", "node-releases": "^2.0.27", - "update-browserslist-db": "^1.1.4" + "update-browserslist-db": "^1.2.0" }, "bin": { "browserslist": "cli.js" @@ -3099,9 +3133,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001757", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001757.tgz", - "integrity": "sha512-r0nnL/I28Zi/yjk1el6ilj27tKcdjLsNqAOZr0yVjWPrSQyHgKI2INaEWw21bAQSv2LXRt1XuCS/GomNpWOxsQ==", + "version": "1.0.30001760", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001760.tgz", + "integrity": "sha512-7AAMPcueWELt1p3mi13HR/LHH0TJLT11cnwDJEs3xA4+CK/PLKeO9Kl1oru24htkyUKtkGCvAx4ohB0Ttry8Dw==", "dev": true, "funding": [ { @@ -3506,15 +3540,15 @@ } }, "node_modules/css-minimizer-webpack-plugin": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/css-minimizer-webpack-plugin/-/css-minimizer-webpack-plugin-7.0.2.tgz", - "integrity": "sha512-nBRWZtI77PBZQgcXMNqiIXVshiQOVLGSf2qX/WZfG8IQfMbeHUMXaBWQmiiSTmPJUflQxHjZjzAmuyO7tpL2Jg==", + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/css-minimizer-webpack-plugin/-/css-minimizer-webpack-plugin-7.0.4.tgz", + "integrity": "sha512-2iACis+P8qdLj1tHcShtztkGhCNIRUajJj7iX0IM9a5FA0wXGwjV8Nf6+HsBjBfb4LO8TTAVoetBbM54V6f3+Q==", "dev": true, "license": "MIT", "dependencies": { "@jridgewell/trace-mapping": "^0.3.25", "cssnano": "^7.0.4", - "jest-worker": "^29.7.0", + "jest-worker": "^30.0.5", "postcss": "^8.4.40", "schema-utils": "^4.2.0", "serialize-javascript": "^6.0.2" @@ -3780,9 +3814,9 @@ "license": "CC0-1.0" }, "node_modules/cypress": { - "version": "15.7.0", - "resolved": "https://registry.npmjs.org/cypress/-/cypress-15.7.0.tgz", - "integrity": "sha512-1C81zKxnQckYm2XGi37rPV4rN0bzUoWhydhKdOyshJn5gJKszEx5as9VLSZI0jp0ye49QxmnbU4TtMpcD+OmGQ==", + "version": "15.7.1", + "resolved": "https://registry.npmjs.org/cypress/-/cypress-15.7.1.tgz", + "integrity": "sha512-U3sYnJ+Cnpgr6IPycxsznTg//mGVXfPGeGV+om7VQCyp5XyVkhG4oPr3X3hTq1+OB0Om0O5DxusYmt7cbvwqMQ==", "dev": true, "hasInstallScript": true, "license": "MIT", @@ -4087,9 +4121,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.5.262", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.262.tgz", - "integrity": "sha512-NlAsMteRHek05jRUxUR0a5jpjYq9ykk6+kO0yRaMi5moe7u0fVIOeQ3Y30A8dIiWFBNUoQGi1ljb1i5VtS9WQQ==", + "version": "1.5.267", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.267.tgz", + "integrity": "sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw==", "dev": true, "license": "ISC" }, @@ -4121,9 +4155,9 @@ } }, "node_modules/enhanced-resolve": { - "version": "5.18.3", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.18.3.tgz", - "integrity": "sha512-d4lC8xfavMeBjzGr2vECC3fsGXziXZQyJxD868h2M/mBI3PwAuODxAkLkq5HYuvrPYcUtiLzsTo8U3PgX3Ocww==", + "version": "5.18.4", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.18.4.tgz", + "integrity": "sha512-LgQMM4WXU3QI+SYgEc2liRgznaD5ojbmY3sb8LxyguVkIg5FxdpTkvk72te2R38/TGKxH634oLxXRGY6d7AP+Q==", "dev": true, "license": "MIT", "dependencies": { @@ -4517,6 +4551,24 @@ "pend": "~1.2.0" } }, + "node_modules/fdir": { + "version": "6.5.0", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz", + "integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12.0.0" + }, + "peerDependencies": { + "picomatch": "^3 || ^4" + }, + "peerDependenciesMeta": { + "picomatch": { + "optional": true + } + } + }, "node_modules/figures": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", @@ -5241,22 +5293,32 @@ "dev": true, "license": "MIT" }, + "node_modules/jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, "node_modules/jest-util": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", - "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", "dev": true, "license": "MIT", "dependencies": { - "@jest/types": "^29.6.3", + "@jest/types": "30.2.0", "@types/node": "*", - "chalk": "^4.0.0", - "ci-info": "^3.2.0", - "graceful-fs": "^4.2.9", - "picomatch": "^2.2.3" + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/jest-util/node_modules/ansi-styles": { @@ -5292,22 +5354,6 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/jest-util/node_modules/ci-info": { - "version": "3.9.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", - "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/sibiraj-s" - } - ], - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/jest-util/node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", @@ -5352,19 +5398,20 @@ } }, "node_modules/jest-worker": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", - "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-30.2.0.tgz", + "integrity": "sha512-0Q4Uk8WF7BUwqXHuAjc23vmopWJw5WH7w2tqBoUOZpOjW/ZnR44GXXd1r82RvnmI2GZge3ivrYXk/BE2+VtW2g==", "dev": true, "license": "MIT", "dependencies": { "@types/node": "*", - "jest-util": "^29.7.0", + "@ungap/structured-clone": "^1.3.0", + "jest-util": "30.2.0", "merge-stream": "^2.0.0", - "supports-color": "^8.0.0" + "supports-color": "^8.1.1" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/jest-worker/node_modules/has-flag": { @@ -5890,6 +5937,19 @@ "node": ">=8.6" } }, + "node_modules/micromatch/node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, "node_modules/mime-db": { "version": "1.52.0", "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", @@ -6352,13 +6412,13 @@ "license": "ISC" }, "node_modules/picomatch": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", - "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", "engines": { - "node": ">=8.6" + "node": ">=12" }, "funding": { "url": "https://github.com/sponsors/jonschlinkert" @@ -7406,6 +7466,19 @@ "node": ">=8.10.0" } }, + "node_modules/readdirp/node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, "node_modules/rechoir": { "version": "0.8.0", "resolved": "https://registry.npmjs.org/rechoir/-/rechoir-0.8.0.tgz", @@ -8276,9 +8349,9 @@ } }, "node_modules/tailwindcss": { - "version": "3.4.18", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.18.tgz", - "integrity": "sha512-6A2rnmW5xZMdw11LYjhcI5846rt9pbLSabY5XPxo+XWdxwZaFEn47Go4NzFiHu9sNNmr/kXivP1vStfvMaK1GQ==", + "version": "3.4.19", + "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.19.tgz", + "integrity": "sha512-3ofp+LL8E+pK/JuPLPggVAIaEuhvIz4qNcf3nA1Xn2o/7fb7s/TYpHhwGDv1ZU3PkBluUVaF8PyCHcm48cKLWQ==", "dev": true, "license": "MIT", "dependencies": { @@ -8371,9 +8444,9 @@ } }, "node_modules/terser-webpack-plugin": { - "version": "5.3.14", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.14.tgz", - "integrity": "sha512-vkZjpUjb6OMS7dhV+tILUW6BhpDR7P2L/aQSAv+Uwk+m8KATX9EccViHTJR2qDtACKPIYndLGCyl3FMo+r2LMw==", + "version": "5.3.16", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.16.tgz", + "integrity": "sha512-h9oBFCWrq78NyWWVcSwZarJkZ01c2AyGrzs1crmHZO3QUg9D61Wu4NPjBy69n7JqylFF5y+CsUZYmYEIZ3mR+Q==", "dev": true, "license": "MIT", "dependencies": { @@ -8567,41 +8640,11 @@ "url": "https://github.com/sponsors/SuperchupuDev" } }, - "node_modules/tinyglobby/node_modules/fdir": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz", - "integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12.0.0" - }, - "peerDependencies": { - "picomatch": "^3 || ^4" - }, - "peerDependenciesMeta": { - "picomatch": { - "optional": true - } - } - }, - "node_modules/tinyglobby/node_modules/picomatch": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", - "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, "node_modules/tippy.js": { "version": "6.3.7", "resolved": "https://registry.npmjs.org/tippy.js/-/tippy.js-6.3.7.tgz", "integrity": "sha512-E1d3oP2emgJ9dRQZdf3Kkn0qJgI6ZLpyS5z6ZkY1DF3kaQaBsGZsndEpHwx+eC+tYM41HaSNvNtLx8tU57FzTQ==", + "dev": true, "license": "MIT", "dependencies": { "@popperjs/core": "^2.9.0" @@ -8654,6 +8697,7 @@ "version": "1.12.0", "resolved": "https://registry.npmjs.org/toastify-js/-/toastify-js-1.12.0.tgz", "integrity": "sha512-HeMHCO9yLPvP9k0apGSdPUWrUbLnxUKNFzgUoZp1PHCLploIX/4DSQ7V8H25ef+h4iO9n0he7ImfcndnN6nDrQ==", + "dev": true, "license": "MIT" }, "node_modules/tough-cookie": { @@ -8795,9 +8839,9 @@ } }, "node_modules/update-browserslist-db": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.4.tgz", - "integrity": "sha512-q0SPT4xyU84saUX+tomz1WLkxUbuaJnR1xWt17M7fJtEJigJeWUNGUqrauFXsHnqev9y9JTRGwk13tFBuKby4A==", + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.2.tgz", + "integrity": "sha512-E85pfNzMQ9jpKkA7+TJAi4TJN+tBCuWh5rUcS/sv6cFi+1q9LYDwDI5dpUL0u/73EElyQ8d3TEaeW4sPedBqYA==", "dev": true, "funding": [ { diff --git a/package.json b/package.json index 6ca55d0..85d5991 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "myep-next", + "name": "myep", "devDependencies": { "@babel/core": "^7.17.0", "@babel/preset-env": "^7.16.0", @@ -17,6 +17,8 @@ "postcss-loader": "^8.1.1", "regenerator-runtime": "^0.13.9", "tailwindcss": "^3.4.15", + "tippy.js": "^6.3.7", + "toastify-js": "^1.12.0", "webpack": "^5.74.0", "webpack-cli": "^5.1.0", "webpack-notifier": "^1.15.0" @@ -29,9 +31,5 @@ "watch": "encore dev --watch", "build": "encore production --progress", "cy:open": "cypress open" - }, - "dependencies": { - "tippy.js": "^6.3.7", - "toastify-js": "^1.12.0" } } diff --git a/src/Controller/Booking/Create/IndexController.php b/src/Controller/Booking/Create/IndexController.php index c87fed1..8409133 100644 --- a/src/Controller/Booking/Create/IndexController.php +++ b/src/Controller/Booking/Create/IndexController.php @@ -72,6 +72,9 @@ class IndexController extends AbstractController // Store optional return URL in session (defaults to main EP site) $this->bookingService->storeReturnUrl($request, $params->returnUrl); + // Store theme for consistent styling throughout the booking flow + $this->bookingService->storeTheme($request, $params->theme); + // Create fresh booking session with the provided parameters $bookingDto = $this->bookingService->startFreshBooking($request, $dateId, $hotelId, $agencyId); diff --git a/src/Form/Service/ParticipantFieldOptionsProvider.php b/src/Form/Service/ParticipantFieldOptionsProvider.php index 9c6b3cf..a5ddee4 100644 --- a/src/Form/Service/ParticipantFieldOptionsProvider.php +++ b/src/Form/Service/ParticipantFieldOptionsProvider.php @@ -158,7 +158,6 @@ class ParticipantFieldOptionsProvider extends AbstractFieldOptionsProvider if (true === $service->mandatory) { $attributes['checked'] = true; $attributes['readonly'] = true; - $attributes['class'] = 'text-pink'; $attributes['data-tooltip'] = 'Diese Leistung ist nicht abwählbar'; } diff --git a/src/Model/BookingQueryParams.php b/src/Model/BookingQueryParams.php index 11e7a6e..a9cf1aa 100644 --- a/src/Model/BookingQueryParams.php +++ b/src/Model/BookingQueryParams.php @@ -25,5 +25,6 @@ readonly class BookingQueryParams #[SerializedName('r')] public ?string $returnUrl = null, - ) {} + ) { + } } diff --git a/src/Service/BookingService.php b/src/Service/BookingService.php index 50be9f7..5a58229 100644 --- a/src/Service/BookingService.php +++ b/src/Service/BookingService.php @@ -20,6 +20,8 @@ class BookingService public const BOOKING_EDIT_KEY = 'booking_edit'; public const RETURN_URL_KEY = 'booking_return_url'; public const DEFAULT_RETURN_URL = 'https://www.ep-reisen.de'; + public const THEME_KEY = 'booking_theme'; + public const DEFAULT_THEME = 'base'; public function __construct( private readonly TravelDataService $travelDataService, @@ -188,6 +190,33 @@ class BookingService return $request->getSession()->get(self::RETURN_URL_KEY, self::DEFAULT_RETURN_URL); } + /** + * Stores the theme identifier in the session. + * + * Sanitizes the theme value to allow only alphanumeric characters and hyphens. + * Falls back to the default theme if empty or invalid. + */ + public function storeTheme(Request $request, string $theme): void + { + $sanitized = preg_replace('/[^a-zA-Z0-9-]/', '', $theme); + + if ('' === $sanitized) { + $sanitized = self::DEFAULT_THEME; + } + + $request->getSession()->set(self::THEME_KEY, $sanitized); + } + + /** + * Retrieves the theme identifier from the session. + * + * Returns the default theme if not set in session. + */ + public function getTheme(Request $request): string + { + return $request->getSession()->get(self::THEME_KEY, self::DEFAULT_THEME); + } + /** * Creates a fresh booking session with the provided travel parameters. * diff --git a/src/Twig/AppExtension.php b/src/Twig/AppExtension.php index a5fe3f1..b942f81 100644 --- a/src/Twig/AppExtension.php +++ b/src/Twig/AppExtension.php @@ -30,6 +30,7 @@ class AppExtension extends AbstractExtension new TwigFunction('is_static_text', [AppRuntime::class, 'isStaticText']), new TwigFunction('is_hidden', [AppRuntime::class, 'isHidden']), new TwigFunction('collect_invalid_field_labels', [AppRuntime::class, 'collectInvalidFieldLabels']), + new TwigFunction('booking_theme', [AppRuntime::class, 'getBookingTheme']), ]; } } diff --git a/src/Twig/AppRuntime.php b/src/Twig/AppRuntime.php index 01cec6f..cabf7c0 100644 --- a/src/Twig/AppRuntime.php +++ b/src/Twig/AppRuntime.php @@ -6,8 +6,10 @@ use App\BusProNet\DataProvider\CountryDataProvider; use App\Form\Model\BookingDto; use App\Form\Service\CreateFieldStateProvider; use App\Form\Service\EditFieldStateProvider; +use App\Service\BookingService; use App\Service\ParticipantEligibilityService; use Symfony\Component\Form\FormView; +use Symfony\Component\HttpFoundation\RequestStack; use Twig\Environment; use Twig\Extension\RuntimeExtensionInterface; use Twig\Extra\Intl\IntlExtension; @@ -20,6 +22,7 @@ class AppRuntime implements RuntimeExtensionInterface private readonly ParticipantEligibilityService $participantEligibilityService, private readonly CreateFieldStateProvider $createFieldStateProvider, private readonly EditFieldStateProvider $editFieldStateProvider, + private readonly RequestStack $requestStack, private readonly string $environment, ) { } @@ -211,6 +214,21 @@ class AppRuntime implements RuntimeExtensionInterface return $labels; } + /** + * Returns the current booking theme from session. + * + * Defaults to 'base' if no theme is set. + */ + public function getBookingTheme(): string + { + $request = $this->requestStack->getCurrentRequest(); + if (null === $request) { + return BookingService::DEFAULT_THEME; + } + + return $request->getSession()->get(BookingService::THEME_KEY, BookingService::DEFAULT_THEME); + } + /** * Gets the appropriate field state provider based on booking mode. * diff --git a/tailwind.config.js b/tailwind.config.js index 30696f6..1e9e9cd 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -22,6 +22,22 @@ module.exports = { 'primary-medium': '#165883', 'primary-dark': '#18527b', pink: '#fa1a8c', + sbw: { + primary: '#B3820F', + secondary: '#E91C26', + 'primary-dark': '#8D7207', + overlay: '#c20000', + }, + snz: { + primary: '#82c3c6', + secondary: '#f9c33d', + 'primary-dark': '#82c3c6', + }, + ser: { + primary: '#006fb6', + secondary: '#DE2C1B', + 'primary-light': '#04A4CC', + }, }, backgroundImage: { 'badge-gradient': 'linear-gradient(120deg, rgba(150,1,103,1) 0%, rgba(158,3,106,1) 40%, rgba(250,26,140,1) 100%)', diff --git a/templates/_partials/_header.html.twig b/templates/_partials/_header.html.twig index 40ef207..97e8254 100644 --- a/templates/_partials/_header.html.twig +++ b/templates/_partials/_header.html.twig @@ -1,6 +1,14 @@
- + {% if booking_theme() == 'sbw' %} + + {% elseif booking_theme() == 'ser' %} + + {% elseif booking_theme() == 'snz' %} + + {% else %} + + {% endif %}
{% if is_granted('ROLE_USER') %} diff --git a/templates/_partials/_loading_indicator.html.twig b/templates/_partials/_loading_indicator.html.twig index 72b6643..8379087 100644 --- a/templates/_partials/_loading_indicator.html.twig +++ b/templates/_partials/_loading_indicator.html.twig @@ -1,6 +1,11 @@