Commit Graph

51 Commits

Author SHA1 Message Date
Joakim Jäderberg
a4f1a55e56 Merged in feat/SW-3549-handle-unlinked-account (pull request #3019)
fix(SW-3549): update social session management functions for clarity and consistency

* refactor(SW-3549): rename session management functions for clarity and consistency

* merge


Approved-by: Hrishikesh Vaipurkar
2025-10-28 09:51:30 +00:00
Joakim Jäderberg
3b3e7308cc Merged in feat/SW-3549-pass-scandic-token (pull request #2989)
Feat/SW-3549 pass scandic token

* WIP pass scandic token

* pass scandic token when booking

* Merge branch 'master' of bitbucket.org:scandic-swap/web into feat/SW-3549-pass-scandic-token

* pass user token when doing availability search

* undo changes

* merge

* Merged in fix/sw-3551-rsc-bookingflowconfig (pull request #2988)

fix(SW-3551): Fix issue with BookingConfigProvider in RSC

* wip move config to pages

* Move config providing to pages

* Merged in fix/update-promo-error-modal-text (pull request #2990)

fix: update promo error modal text

* fix: update promo error modal text


Approved-by: Emma Zettervall

* Merged in fix/sw-3514-missing-membership-input-for-multiroom (pull request #2991)

fix(SW-3514): Show join Scandic Friends card for SAS multiroom

* Show join card for room 2+


Approved-by: Hrishikesh Vaipurkar

* Merged in feat/lokalise-rebuild (pull request #2993)

Feat/lokalise rebuild

* chore(lokalise): update translation ids

* chore(lokalise): easier to switch between projects

* chore(lokalise): update translation ids

* .

* .

* .

* .

* .

* .

* chore(lokalise): update translation ids

* chore(lokalise): update translation ids

* .

* .

* .

* chore(lokalise): update translation ids

* chore(lokalise): update translation ids

* .

* .

* chore(lokalise): update translation ids

* chore(lokalise): update translation ids

* chore(lokalise): new translations

* merge

* switch to errors for missing id's

* merge

* sync translations


Approved-by: Linus Flood

* Merged in feat/SW-3552-logout-from-social-session-when- (pull request #2994)

feat(SW-3552): Removed scandic session on logout

Approved-by: Joakim Jäderberg

* merge

* replace getRedemptionTokenSafely() with context based instead

* Refactor user verification and error handling across multiple components; implement safeTry utility for safer async calls

* Refactor user verification and error handling across multiple components; implement safeTry utility for safer async calls

* merge

* Merge branch 'master' of bitbucket.org:scandic-swap/web into feat/SW-3549-pass-scandic-token

* add booking scope

remove unused getMembershipNumber()


Approved-by: Anton Gunnarsson
Approved-by: Hrishikesh Vaipurkar
2025-10-24 13:17:02 +00:00
Joakim Jäderberg
17df3ee71a Merged in feature/SW-3516-pass-eurobonus-number-on-booking (pull request #2902)
* feat(SW-3516): Include partnerLoyaltyNumber on bookings

- Added user context to BookingFlowProviders for user state management.
- Updated booking input and output schemas to accommodate new user data.
- Refactored booking mutation logic to include user-related information.
- Improved type definitions for better TypeScript support across booking components.


Approved-by: Anton Gunnarsson
2025-10-08 10:48:42 +00:00
Linus Flood
a60c613756 Merged in fix/log-spam (pull request #2919)
fix(logging): changed unauthorized logs to debug instead of info

* fix(logging): changed unauthorized logs to debug instead of info


Approved-by: Joakim Jäderberg
2025-10-07 06:23:37 +00:00
Matilda Landström
0e30a2d218 Merged in feat/LOY-361-add-promo-campaign-page-type (pull request #2826)
Feat/LOY-361 add promo campaign page type

* feat(LOY-361): add Pomo Campaign page type

* chore(SW-361): remove campaign page flag

* fix(LOY-361): cleanup

* fix(LOY-361): add promo code


Approved-by: Erik Tiekstra
Approved-by: Chuma Mcphoy (We Ahead)
2025-09-19 07:20:17 +00:00
Anton Gunnarsson
08804e8675 Merged in chore/cleanup-scandic-web (pull request #2831)
chore: Cleanup scandic-web

* Remove unused files

* Remove unused and add missing packages

* Remove unused exports


Approved-by: Linus Flood
2025-09-18 15:33:00 +00:00
Linus Flood
fd0198f57b Merged in feat/SW-2999-cleanup (pull request #2810)
feat(SW-2999): cleanup current web

* feat(SW-2999): cleanup current web

* Merge master

* Removed unused fonts


Approved-by: Joakim Jäderberg
2025-09-16 11:28:57 +00:00
Joakim Jäderberg
7dee6d5083 Merged in chore/move-enter-details (pull request #2778)
Chore/move enter details

Approved-by: Anton Gunnarsson
2025-09-11 07:16:24 +00:00
Hrishikesh Vaipurkar
260a544c99 Merged in chore/SW-3381-move-loginbutton-to-ds- (pull request #2752)
chore(SW-3381) Moved LoginButton to design system

* chore(SW-3381) Moved LoginButton to design system


Approved-by: Anton Gunnarsson
2025-09-03 09:11:28 +00:00
Anton Gunnarsson
87402a2092 Merged in feat/sw-2873-move-selecthotel-to-booking-flow (pull request #2727)
feat(SW-2873): Move select-hotel to booking flow

* crude setup of select-hotel in partner-sas

* wip

* Fix linting

* restructure tracking files

* Remove dependency on trpc in tracking hooks

* Move pageview tracking to common

* Fix some lint and import issues

* Add AlternativeHotelsPage

* Add SelectHotelMapPage

* Add AlternativeHotelsMapPage

* remove next dependency in tracking store

* Remove dependency on react in tracking hooks

* move isSameBooking to booking-flow

* Inject searchParamsComparator into tracking store

* Move useTrackHardNavigation to common

* Move useTrackSoftNavigation to common

* Add TrackingSDK to partner-sas

* call serverclient in layout

* Remove unused css

* Update types

* Move HotelPin type

* Fix todos

* Merge branch 'master' into feat/sw-2873-move-selecthotel-to-booking-flow

* Merge branch 'master' into feat/sw-2873-move-selecthotel-to-booking-flow

* Fix component


Approved-by: Joakim Jäderberg
2025-09-01 08:37:00 +00:00
Linus Flood
007025313b Merged in feat/sw-3269-info-logs (pull request #2657)
feat/#sw-3269 fix: info logs

* feat/#sw-3269 fix: info logs


Approved-by: Joakim Jäderberg
2025-08-15 07:10:21 +00:00
Anton Gunnarsson
1bd8fe6821 Merged in feat/sw-2879-booking-widget-to-booking-flow-package (pull request #2532)
feat(SW-2879): Move BookingWidget to booking-flow package

* Fix lockfile

* Fix styling

* a tiny little booking widget test

* Tiny fixes

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package

* Remove unused scripts

* lint:fix

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package

* Tiny lint fixes

* update test

* Update Input in booking-flow

* Clean up comments etc

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package

* Setup tracking context for booking-flow

* Add missing use client

* Fix temp tracking function

* Pass booking to booking-widget

* Remove comment

* Add use client to booking widget tracking provider

* Add use client to tracking functions

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package

* Move debug page

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package

* Merge branch 'master' into feat/sw-2879-booking-widget-to-booking-flow-package


Approved-by: Bianca Widstam
2025-08-05 09:20:20 +00:00
Joakim Jäderberg
daf765f3d5 Merged in feature/wrap-logging (pull request #2511)
Feature/wrap logging

* feat: change all logging to go through our own logger function so that we can control log levels

* move packages/trpc to using our own logger

* merge


Approved-by: Linus Flood
2025-07-03 12:37:04 +00:00
Anton Gunnarsson
be25be7bb5 Merged in feat/sw-3125-move-client-trpc-setup (pull request #2493)
feat(SW-3125): Move client trpc setup

* Move client trpc to package

* Client setup in partner-sas

* Add todo


Approved-by: Linus Flood
2025-07-01 12:41:28 +00:00
Anton Gunnarsson
6eeaa1cd40 Merged in feat/sw-2872-dependency-inject-app-context-in-trpc-package (pull request #2478)
feat(SW-2872) Dependency inject app context in trpc package

* Move appRouter to trpc package

* WIP Move serverClient to trpc package

Doesn't handle errors yet

* Don't use global

* Use trpc everywhere


Approved-by: Linus Flood
2025-07-01 08:49:33 +00:00
Anton Gunnarsson
01ca2b4897 Merged in feat/sw-2867-move-user-router-to-trpc-package (pull request #2428)
Move user router to trpc package

* Move more schemas in hotel router

* Fix deps

* fix getNonContentstackUrls

* Fix import error

* Fix entry error handling

* Fix generateMetadata metrics

* Fix alertType enum

* Fix duplicated types

* lint:fix

* Merge branch 'master' into feat/sw-2863-move-contentstack-router-to-trpc-package

* Fix broken imports

* Move booking router to trpc package

* Move partners router to trpc package

* Move autocomplete router to trpc package

* Move booking router to trpc package

* Remove translations from My Pages navigation trpc procedure

* Move navigation router to trpc package

* Move user router to trpc package

* Merge branch 'master' into feat/sw-2862-move-booking-router-to-trpc-package

* Merge branch 'feat/sw-2862-move-booking-router-to-trpc-package' into feat/sw-2865-move-navigation-router-to-trpc-package

* Merge branch 'master' into feat/sw-2865-move-navigation-router-to-trpc-package

* Merge branch 'master' into feat/sw-2865-move-navigation-router-to-trpc-package

* Merge branch 'master' into feat/sw-2865-move-navigation-router-to-trpc-package

* Merge branch 'feat/sw-2865-move-navigation-router-to-trpc-package' into feat/sw-2867-move-user-router-to-trpc-package

* Merge branch 'master' into feat/sw-2867-move-user-router-to-trpc-package


Approved-by: Linus Flood
2025-06-27 07:07:49 +00:00
Anton Gunnarsson
5f8ac8cdeb Merged in feat/sw-2861-move-autocomplete-router-to-trpc-package (pull request #2417)
feat(SW-2861): Move autocomplete router to trpc package

* Apply lint rules

* Use direct imports from trpc package

* Add lint-staged config to trpc

* Move lang enum to common

* Restructure trpc package folder structure

* WIP first step

* update internal imports in trpc

* Fix most errors in scandic-web

Just 100 left...

* Move Props type out of trpc

* Fix CategorizedFilters types

* Move more schemas in hotel router

* Fix deps

* fix getNonContentstackUrls

* Fix import error

* Fix entry error handling

* Fix generateMetadata metrics

* Fix alertType enum

* Fix duplicated types

* lint:fix

* Merge branch 'master' into feat/sw-2863-move-contentstack-router-to-trpc-package

* Fix broken imports

* Move booking router to trpc package

* Move partners router to trpc package

* Move autocomplete router to trpc package

* Merge branch 'master' into feat/sw-2861-move-autocomplete-router-to-trpc-package


Approved-by: Linus Flood
2025-06-26 12:40:45 +00:00
Anton Gunnarsson
bbcabfa0ba Merged in feat/sw-2864-move-hotels-router-to-trpc-package (pull request #2410)
feat (SW-2864): Move booking router to trpc package

* Add env to trpc package

* Add eslint to trpc package

* Apply lint rules

* Use direct imports from trpc package

* Add lint-staged config to trpc

* Move lang enum to common

* Restructure trpc package folder structure

* WIP first step

* update internal imports in trpc

* Fix most errors in scandic-web

Just 100 left...

* Move Props type out of trpc

* Fix CategorizedFilters types

* Move more schemas in hotel router

* Fix deps

* fix getNonContentstackUrls

* Fix import error

* Fix entry error handling

* Fix generateMetadata metrics

* Fix alertType enum

* Fix duplicated types

* lint:fix

* Merge branch 'master' into feat/sw-2863-move-contentstack-router-to-trpc-package

* Fix broken imports

* Move booking router to trpc package

* Merge branch 'master' into feat/sw-2864-move-hotels-router-to-trpc-package


Approved-by: Linus Flood
2025-06-26 09:02:59 +00:00
Anton Gunnarsson
002d093af4 Merged in feat/sw-2863-move-contentstack-router-to-trpc-package (pull request #2389)
feat(SW-2863): Move contentstack router to trpc package

* Add exports to packages and lint rule to prevent relative imports

* Add env to trpc package

* Add eslint to trpc package

* Apply lint rules

* Use direct imports from trpc package

* Add lint-staged config to trpc

* Move lang enum to common

* Restructure trpc package folder structure

* WIP first step

* update internal imports in trpc

* Fix most errors in scandic-web

Just 100 left...

* Move Props type out of trpc

* Fix CategorizedFilters types

* Move more schemas in hotel router

* Fix deps

* fix getNonContentstackUrls

* Fix import error

* Fix entry error handling

* Fix generateMetadata metrics

* Fix alertType enum

* Fix duplicated types

* lint:fix

* Merge branch 'master' into feat/sw-2863-move-contentstack-router-to-trpc-package

* Fix broken imports

* Merge branch 'master' into feat/sw-2863-move-contentstack-router-to-trpc-package


Approved-by: Linus Flood
2025-06-26 07:53:01 +00:00
Erik Tiekstra
891108791c feat(SW-2264): Added campaign overview page
Approved-by: Matilda Landström
2025-06-19 15:19:56 +00:00
Anton Gunnarsson
846fd904a6 Merged in feat/sw-2859-set-up-shared-trpc-package (pull request #2319)
feat(SW-2859): Create trpc package

* Add isEdge, safeTry and dataCache to new common package

* Add eslint and move prettier config

* Clean up tests

* Create trpc package and move initialization

* Move errors and a few procedures

* Move telemetry to common package

* Move tokenManager to common package

* Add Sentry to procedures

* Clean up procedures

* Fix self-referencing imports

* Add exports to packages and lint rule to prevent relative imports

* Add env to trpc package

* Add eslint to trpc package

* Apply lint rules

* Use direct imports from trpc package

* Add lint-staged config to trpc

* Move lang enum to common

* Restructure trpc package folder structure

* Fix lang imports


Approved-by: Linus Flood
2025-06-18 12:14:20 +00:00
Erik Tiekstra
ace5519869 feat(SW-2265): Added campaign-page
Approved-by: Matilda Landström
2025-06-10 06:35:43 +00:00
Anton Gunnarsson
cbf9e7b7c2 Merged in chore/next15 (pull request #1999)
chore (SW-834): Upgrade to Next 15

* wip: apply codemod and upgrade swc plugin

* wip: design-system to react 19, fix issues from async (search)params

* wip: fix remaining issues from codemod

serverClient is now async because context use headers()
getLang is now async because it uses headers()

* Minor cleanup

* Inline react-material-symbols package

Package is seemingly not maintained any more and doesn't support
React 19. This copies the package source into `design-system`,
makes the necessary changes for 19 and export it for others to use.

* Fix missing awaits

* Disable modal exit animations

Enabling modal exit animations via isExiting prop is causing
modals to be rendered in "hidden" state and never unmount.
Seems to be an issue with react-aria-components,
see https://github.com/adobe/react-spectrum/issues/7563.
Can probably be fixed by rewriting to a solution similar to
https://react-spectrum.adobe.com/react-aria/examples/framer-modal-sheet.html

* Remove unstable cache implementation and use in memory cache locally

* Fix ref type in SelectFilter

* Use cloneElement to add key prop to element


Approved-by: Linus Flood
2025-06-02 11:11:50 +00:00
Simon Emanuelsson
5ca30d02a0 feat: keep inventory of bedselections 2025-05-22 09:37:52 +00:00
Joakim Jäderberg
ec29664a60 Merged in fix/capture-errors-in-trpc (pull request #2103)
Fix/capture errors in trpc

* fix: import @sentry/nextjs, not @sentry/node

* add sentry logging for errors in trpc


Approved-by: Linus Flood
2025-05-16 11:44:25 +00:00
Joakim Jäderberg
31d75ffa74 Merged in fix/default-page-settings (pull request #2076)
fix: default page settings when invalid or missing

* fix: default page settings when invalid or missing since most pages don't have pageSettings


Approved-by: Anton Gunnarsson
2025-05-15 10:41:16 +00:00
Michael Zetterberg
b910b6a313 feat(SW-2116): Use refId instead of confirmationNumber 2025-05-05 12:26:37 +00:00
Linus Flood
d49ecdae1f Merged in feat/sw-2323-find-booking3 (pull request #1928)
Feat/sw-2323 New Find booking endpoint

* wip

* wip


Approved-by: Anton Gunnarsson
2025-05-02 13:21:00 +00:00
Linus Flood
6979ac0c3b Merged in revert-pr-1925 (pull request #1927)
Revert "Feat/sw 2323 find booking (pull request #1925)"

Approved-by: Anton Gunnarsson
2025-05-02 13:05:42 +00:00
Linus Flood
f450f2a5db Merge master 2025-05-02 14:01:50 +02:00
Arvid Norlin
74d37dad93 feat(SW-2116): RefId instead of confirmationNumber 2025-05-02 12:44:07 +02:00
Linus Flood
7c26e2955e wip 2025-05-02 12:17:18 +02:00
Simon Emanuelsson
ec087a3d15 feat: refactor of my stay 2025-04-28 12:40:52 +00:00
Michael Zetterberg
af65fbf7f4 fix: rename trpc route for get booking 2025-04-15 05:20:24 +00:00
Simon Emanuelsson
d72c84d949 feat: filters work together 2025-04-14 06:51:44 +00:00
Linus Flood
40f18c915b Merged in fix/hide-bookingwidget-flag (pull request #1764)
fix: bookingwidget - hide BW if either pageSettings or siteConfig wants to hide it

* fix: bookingwidget - hide BW if either pageSettings or siteConfig wants to hide it

* Refactor


Approved-by: Michael Zetterberg
2025-04-14 05:37:46 +00:00
Simon Emanuelsson
afb37d0cc5 feat: bedtypes is selectable again 2025-04-12 08:32:42 +00:00
Anton Gunnarsson
5cb19dfccd Merged in feat/sw-1313-show-sas-points (pull request #1682)
SW-1313 - Add support for getting SAS EB points

Approved-by: Joakim Jäderberg
2025-04-08 11:03:38 +00:00
Michael Zetterberg
4aeb5b071d fix(SW-1446): use existing functions for url data 2025-04-08 05:52:10 +00:00
Michael Zetterberg
9e84da45bc feat(SW-1446): add Jump to functionality to Destination Overview Page 2025-04-08 05:52:10 +00:00
Linus Flood
e4907d4b47 Merged in fix/destinations-speed-test (pull request #1704)
Feat(destination pages): Performance improvements

* fix/destinations: try cache full response

* Added more caching

* Removed unsed env car

* wip

* merge master

* wip

* wip

* wip

* Renaming


Approved-by: Michael Zetterberg
2025-04-02 11:37:22 +00:00
Joakim Jäderberg
87d97db324 Merged in fix/pageview-tracking (pull request #1687)
Fix/pageview tracking

* Restructure pageview tracking

* Update trpc version and turn off batching

* Remove unused state and remove logs

* cleanup

* remove unused code and console.logs


Approved-by: Linus Flood
2025-04-01 06:43:54 +00:00
Simon Emanuelsson
ebaea78fb3 feat(SW-1717): rewrite select-rate to show all variants of rate-cards 2025-03-28 17:07:54 +00:00
Michael Zetterberg
65f75c11ef fix: improve loading on destination overview page
- Only load data from Contentstack
- Use static JSON for destination list
- Some logic improvements to data handling and types
2025-03-27 13:49:28 +00:00
Erik Tiekstra
2c08b141b2 feat(SW-1534): Added booking code functionality from either searchParams or pageSettings
Approved-by: Christian Andolf
2025-03-25 07:36:43 +00:00
Hrishikesh Vaipurkar
c5e294c7ea Merged in feat/SW-1356-reward-night-booking-2- (pull request #1559)
feat: SW-1356 Reward night bookingflow

* feat: SW-1356 Reward night bookingflow

* feat: SW-1356 Removed extra param booking call

* feat: SW-1356 Optimized as review comments

* feat: SW-1356 Schema validation updates

* feat: SW-1356 Fix after rebase

* feat: SW-1356 Optimised price.redemptions check

* feat: SW-1356 Updated Props naming


Approved-by: Arvid Norlin
2025-03-24 08:54:02 +00:00
Erik Tiekstra
19bb965298 Merged in feat/SW-1745-language-switcher-non-contentstack-pages (pull request #1501)
feat(SW-1745): Query for language switcher returns just current pathname for non-contentstack pages except for hotelreservation paths

* feat(SW-1745): Query for language switcher returns just current pathname for non-contentstack pages except for hotelreservation paths


Approved-by: Linus Flood
2025-03-10 09:06:19 +00:00
Erik Tiekstra
f045fe4a8a Merged in feat/SW-1555-jobylon-integration (pull request #1484)
Feat/SW-1555 jobylon integration

* feat(SW-1555): Added jobylon feed query

* feat(SW-1555): Added jobylon feed component


Approved-by: Fredrik Thorsson
Approved-by: Matilda Landström
2025-03-06 13:31:37 +00:00
Joakim Jäderberg
f36b90e474 Merged in feature/bookingwidget-client-side (pull request #1481)
Move more of BookingWidget to client SW-1639

* feat: move getLocations in booking widget to client side so that it's also cached on the client reducing the blinking when switching urls (and reducing duplicate calls)


Approved-by: Linus Flood
2025-03-05 13:37:33 +00:00
Linus Flood
0c498d82ca Merged in feat/trackingsdk-client (pull request #1420)
feat: trackingsdk as client component

* feat: trackingsdk as client component

* Cleanup

* Merge changes from feat/trackingsdk-client

* revert yarn.lock

* Added lcpTime and wait with tracking until we have the values


Approved-by: Joakim Jäderberg
2025-02-27 07:22:58 +00:00