This site uses cookies to personalise your experience, analyse site traffic and keep track of items stored in your shopping basket. By Clicking ACCEPT or continuing to browse the site you are agreeing to our use of cookies.
See our Privacy Policy here
Galaxy S25 plus device is seen being held and YouTube is active on the main screen. The side button is long pressed to Ask Google Gemini using natural language to list the places mentioned in a video and save it as a Note. It will go through various applications to search online and then create and save a Note.
The most advanced AI ProVisual Engine,
Two subjects play basketball in the evening. The footage is clear thanks to Galaxy S25 plus's camera.
The most powerful processor, customised for Galaxy
Customised for Galaxy AP is seen floating above the chip board before it rests on top. Various rays of light come out from the AP before transforming into Galaxy S25 plus device. The device is seen horizontal from side profile before rotating to show a scene from Wuthering Waves game on the main screen.
"Personalization is one of the best things of new AI features on Galaxy S25 Series"
ZDNET
"Galaxy S Series continues to be some of the world's best designed technology"
The Independent
Simple. Impactful
Galaxy S25 plus in Navy flies into view and is seen from the rear. Then, Galaxy S25 in Icyblue, which is smaller in size, appears next to it in the front view.
Meet Galaxy S25 and S25+. A sleek, premium design wrapped in a strong aluminum frame with an immersive screen, sophisticated camera and now slimmed down for a more comfortable grip.,
Big and Bigger
Thinner design, greater choice. Galaxy S25 and S25+ both feature our most powerful, custom-made processor, optimised battery life and our most innovative AI. Go even bigger and bolder with Galaxy S25+'s 6.7 inch display.,
Now Bar enters from right to left with an alert from Now Brief. Now Bar then moves to the bottom of the main screen of Galaxy S25 plus that comes into focus. Three other alerts from Now Bar appear stacked above the first one, timer, music and exercise.
Ring in the next era of mobile AI with an AI companion who's one step ahead of your every need. Just let natural conversation guide the way to checking off everyday tasks with ease.
Press, talk, done
Galaxy S25 plus device is seen being held and YouTube is active on the main screen. The side button is long pressed to Ask Google Gemini using natural language to list the places mentioned in a video and save it as a Note. It will go through various applications to search online and then create and save a Note.
Seamlessly complete your tasks without having to switch between various apps. Simply press and hold the side button to access Google Gemini for help.1
Seamlessly complete your tasks without having to switch between various apps. Simply tell Google Gemini what you need using natural language and it'll take care of things in one go.
Go live, get answers
Google Gemini Live is active and Talk Live is selected. Next, an image is sent as an attachment to Gemini Live. Gemini Live analyzes the image and you can talk back and forth about the contents using natural language.
Have free-flowing conversation with Gemini Live to brainstorm ideas or prepare for presentations by attaching images and getting real-time responses that adapt to your conversation style.
Personalised briefings for your day
Now Brief sends personalized briefs throughout the day. Morning brief includes weather and Energy Score updates, Midday brief includes driving tips and expiring coupon updates and Evening brief includes a recap of the day with pictures from your gallery and daily activity highlights.
Get personalised briefings throughout the day from the all-new Now Brief. Start your morning with a run-down of the day ahead, such as checking your latest Energy Score and reminders of a busy schedule. Then, recap on the day's events in the evening with daily activity insights.
Circle it, find it. Hear it, find it
Circle to Search with Google allows you to search anything on your screen and get information faster with AI Overviews. Just circle an object—including images, videos, or text—with your finger, and you'll get results immediately. You can even search for a song that you hear in the moment without switching apps.
A sound studio at your fingertips
Footage of subjects is seen with soundwaves across the middle. In Audio Eraser, selected unwanted noise can be reduced from 0 to minus 100. At minus 100, Mute is highlighted.
Easily get rid of unwanted background noise from your videos and make them share-worthy with Audio Eraser. Fine-tune your audio by adjusting different types of sound including voices, music, wind and more.
Highlight reels made easy
Highlights from a number of different videos are seen being edited together using Auto Trim.
Effortlessly create reels by collating your videos and simply hitting Auto Trim. AI will detect the key activity and trim them into highlight-ready clips that you can easily modify to your desired length.
The future of health, now made personal
Keep up with your health goals by tracking your Energy Score. Sync with Galaxy Watch and receive personalised insights and coaching such as an analysis of your sleep, activity and heart rate.,
The Personal Data Engine combines and processes your primary data and provides tailored suggestions. It encrypts this data and saves it on your device with Knox Vault, making it inaccessible to anyone else.
Have control over your Galaxy AI. You can decide where to process it, either on-device or in the cloud.
We've further improved security across Galaxy connected devices with Knox Matrix Trust Chain technology. Now you can monitor the security of other devices right from your Galaxy smartphone.
Galaxy S25 plus's camera lenses are seen coming into view and the full device rotates to show its rear view. Another device is seen behind from the main screen to show the front camera.
Our ProVisual Engine is now boosted by our powerful processor. Experience our advanced creative system for capturing, viewing and editing that you have to see to believe.,
Front Camera
12 MPSelfie Camera
Rear Camera
12 MPUltra Wide
50 MPWide-angle2x Optical Quality Zoom
10 MPTelephoto3x Optical Zoom
Compare camera
Optical Zoom 3x, Optical Quality Zoom 2x, Digital Zoom up to 30x,,
Hybrid Optic Zoom at 3x, Digital Zoom up to 30x,,
Optical Zoom at 3x, Digital Zoom up to 30x,,
Stunning Nightography video. Less noise, more clarity
Two subjects play basketball in the evening. The footage is clear thanks to Galaxy S25 plus's camera.
Now you can shoot in improved 10-bit HDR for a more stunning videography experience. Our advanced AP also delivers more precise noise removal meaning you won't have to worry about grainy night footage again.,
Epic portraits, every single time
We see you. And so does our camera with enhanced Object-aware Engine that can adapt to various lighting environments. Capture skin tones and textures exactly as your eyes see them.
Filters just for you
Bring your pics to life with your own personalised filters. Galaxy AI will analyse your favorite photo and create a filter that captures the scene. Use it instantly or customise further to suit your mood with tweaks to the saturation, brightness and more.
Shots captured at lightning speed
Our advanced ProVisual Engine and sensor come together to provide high-quality images, even at fast shutter speeds, so you can capture moving subjects with more clarity.
The most powerful processor, customised for Galaxy
Customised for Galaxy AP is seen floating above the chip board before it rests on top. Various rays of light come out from the AP before transforming into Galaxy S25 plus device. The device is seen horizontal from side profile before rotating to show a scene from Wuthering Waves game on the main screen. Powered by Snapdragon 8 Elite for Galaxy.
Introducing our most powerful processor, customised for Galaxy. With improved real-time ray tracing and Vulkan optimization, dive deep into the action with ultra-smooth gameplay thanks to Snapdragon® 8 Elite Mobile Platform for Galaxy.,,,
Snapdragon® 8 Elite for Galaxy
Upscaled with precision. See the difference
A before and after comparison on the display of Galaxy device depicts ProScaler effects. ProScaler delivers more detailed graphics.
Display image quality is even more stunning with our built-in ProScaler. AI-algorithm processing is used to deliver a viewing experience in high definition without having to adjust the display settings.,
Up to 512 GB storage
Store it all with 12 GB of memory and up to 128 GB, 256 GB or 512 GB of storage with Galaxy S25 or choose between 256 GB or 512 GB of storage with Galaxy S25+.
All new One UI 7, built for AI
Now Bar
Get direct access to your Now Brief alerts, music, timer and more from the all-new Now Bar without having to unlock your phone.
Now Bar is active on the bottom of the main screen of a Galaxy smartphone. An alert from Now Brief slides up and behind a stack of other Now Bar notifications from active apps. Next is music, exercise, timer and then back to Now Brief.
Widget
The new home screen is yours to control with highly-customisable layouts and redesigned widgets.
Various widgets including weather, clock, sleep score and gallery slide into view from the left and right.
Notification
See what's in action right now. Live notifications let you monitor on-going activities such as timers and voice recordings on the Now Bar, status bar or even at the top of your regular notification panel.
Notifications are swiped down on the main screen of Galaxy device to show live notifications of active apps at the top.
What goes around, comes around. We focus on energy efficiency and resource circularity in all product lifecycles. Every little bit helps and we're committed to doing more.
Keep it covered, make it yours
Designed to fit your style, whatever the case. Get functional accessories with big personality. **S Pen only included and compatible with Galaxy S25 Ultra.
Galaxy S25 and S25+ use AI to get your apps working together with a single ask. They also come with extra AI features such as Now Brief, Google Gemini Live and Audio Eraser. Thanks to the upgraded One UI 7, these features work seamlessly on Galaxy S25 and S25+.,,,,
Galaxy S25 has a 6.2" display and a 4,000 mAh battery capacity whereas Galaxy S25+ has a 6.7" display and a 4,900 mAh battery capacity. Galaxy S25 has three storage options to choose from including 128 GB, 256 GB or 512 GB whereas Galaxy S25+ has two storage options: 256 GB or 512 GB.,,
With our Object-aware Engine that detects lighting environments, you can capture more accurate skin tones and textures just as you see them in real life.
Galaxy S25 Series presents the very first 3 nm processor custom-designed for Galaxy smartphones. Snapdragon® 8 Elite Mobile Platform for Galaxy integrates ray tracing and Vulkan optimization for an improved gaming experience. And with a larger Vapor Chamber and new thermal interface material (TIM), you’ll get a smoother and cooler experience so you can fully immerse yourself into the game for longer.21,22,24
Galaxy S25 and S25+ are fortified with a strong Armor Aluminum frame, Corning® Gorilla® Glass Victus® 2 glass and an IP68 rating to protect from daily scuffs, dust and water.,,
Thanks to our enhanced AP, Nightography has improved on Galaxy S25 and S25+ allowing you to capture videos even more clearly at night time. You can also take life-like portraits thanks to Object-aware Engine's ability to detect and adapt to lighting environments.,
Galaxy AI processes personalised data securely on your device through the Personal Data Engine. The data is then encrypted to restrict random access by other applications. In Controls, you can also choose how Galaxy AI processes your data, such as on your device or on the cloud, delete personalised data or opt out of personalisation.
Gemini is a trademark of Google LLC. Results for illustrative purposes. Requires internet connection and Google Account login. Service availability may vary by country, language, device model. Works on compatible apps. Features may differ depending on subscription and results may vary. Set up may be required for certain functions or apps. Accuracy of results is not guaranteed.
Results may vary depending on shooting conditions including multiple subjects, being out of focus or moving subjects.
Compared to previous models.
Actual battery life varies by network environment, features and apps used, frequency of calls and messages, the number of times charged, and many other factors Estimated against the average usage profile compiled by UX Connect Research Independently assessed by UX Connect Research in US with pre release versions of the device under default setting using LTE and 5 G Sub 6 networks NOT tested under 5 G mmWave Network.
Armor Aluminum Frame does not include volume and side keys or SIM tray.
Measured diagonally in full rectangle. Actual viewable area is less due to rounded corners and/or camera hole. Measured diagonally, Galaxy S25's screen size is 6.2” in the full rectangle and 6.0” accounting for the rounded corners, Galaxy S25+'s screen size is 6.7” in the full rectangle and 6.5” accounting for the rounded corners, and Galaxy S25 Ultra's screen size is 6.9” in the full rectangle and 6.8” accounting for the rounded corners; actual viewable area is less due to the rounded corners and/or camera hole.
Typical value tested under third-party laboratory condition. Typical value is the estimated average value considering the deviation in battery capacity among the battery samples tested under IEC 61960 standard. Rated capacity is 3885 mAh for Galaxy S25, 4755 mAh for Galaxy S25+ and 4855 mAh for Galaxy S25 Ultra.
Colour availability may vary depending on country or carrier.
Exclusively available on Samsung.com.
Corning® Gorilla® Glass Victus® 2 is applied to the front and rear of the device.
Based on lab test conditions for submersion in up to 1.5 meters of freshwater for up to 30 minutes. No ingress of dust; complete protection against contact (dust-tight). Water and dust resistance of device is not permanent and may diminish over time because of normal wear and tear.
Gemini is a trademark of Google LLC. Results for illustrative purposes. Gemini Live feature requires internet connection and Google Account login. Service availability may vary by country, language, device model. Features may differ depending on subscription and results may vary. Compatible with certain features and certain accounts. Only available to users 18 years or older. Accuracy of results is not guaranteed.
Now Brief feature requires Samsung Account login. Service availability may vary by country, language, device model, apps. Some features may require a network connection. Modes and Routines need to be enabled to use Personal Data Engine for context-based Routines suggestions. User needs to consent to access permissions such as photos, videos, audio files, and calendar events. May not display moments depending upon exposure policy. The description of photos provided by moments may not align with the user's intent. Events schedule notification is supported with calendar apps that utilize Android calendar database and available if Samsung Calendar is installed. Notifications for coupons only available for coupons added to Samsung Wallet with expiration date. To check the Energy Score, the health data tracked from Samsung Galaxy Watch or Samsung Galaxy Ring must be synchronized with the Samsung Health App. The result is for your personal reference only and is not intended for medical purposes.
Circle to Search is a trademark of Google LLC. Sequences shortened and simulated. Results for illustrative purposes only. Service availability may vary by country, language, device model. Requires internet connection. Users may need to update Android and Google app to the latest version. Results may vary depending on visual or audio matches. Accuracy of results is not guaranteed. Works on compatible apps and surfaces, and with ambient music only. Will not identify music coming through headphones or if phone volume is off.
Results may vary per video depending on how sounds present in the video. Samsung Account login required. Certain types of sound can be detected such as voices, music, wind, nature, crowd and noise. The actual sound detection may vary depending on audio source, and the condition of the video. Accuracy of results is not guaranteed.
Maximum length per clip to be edited using Auto Trim for Photo Assist is 90 minutes. Maximum length of combined clips to be edited using Auto Trim for Photo Assist is 180 minutes. Maximum number of clips to be edited per video project is 60 clips. Accuracy of results is not guaranteed.
Energy Score is available on Android phones (Android 11 or above) and requires Samsung Health app (v6.27 or above). Samsung Account login required. Service availability may vary by country, region and language. To check the Energy Score, the health data tracked from Samsung Galaxy Watch (Galaxy Watch4 series and later models using OS 5.0 or above) or Samsung Galaxy Ring must be synchronized with the Samsung Health App. Needs at least the previous day’s activity data and sleep, and heart rate data during sleep. Not intended for use in detection, diagnosis, treatment of any medical condition. The result is for your personal reference only. Please consult a medical professional for advice.
Galaxy Watch devices sold separately.
Knox Matrix is supported on Galaxy smartphones and tablets One UI 7.0 or above. Availability may vary by country or region.
Optical quality zoom is enabled by the Adaptive Pixel sensor.
Compared to Galaxy S24 and S24+.
AP performance improvements apply to Galaxy S25+ and are compared to Galaxy S24+. Actual performance will depend on user environment, conditions and pre-installed software and applications.
Snapdragon branded products are products of Qualcomm Technologies, Inc. and/or its subsidiaries.
ProScaler feature is supported on Galaxy S25+ and Ultra models. Image quality can be enhanced up to QHD+, depending on the screen resolution setting of the device.
Storage options and availability may vary by carrier, country or region. Actual storage availability may vary depending on pre-installed software.
Some functional widgets may require a network connection and/or Samsung Account login. Availability of functions supported within the apps may vary by country.
Wired transfers from Android™ devices require the receiving device to have Android™ 4.3 or later and the sending device to have Android 4.3™ or later. Transfers can be completed without a cable through a wireless connection. For wireless connections, the receiving device must have Android™ 4.0 or later and the sending device must have Android™ 4.0 or later. Open Smart Switch Mobile in “Settings” on the receiving Galaxy device or download the Smart Switch Mobile app from the Galaxy Store. Data, content and apps available for transfer may vary by transmission method.
Wired transfers from iOS require the receiving device to have Android™ 4.3 or later and the sending device to have iOS 5 or later. Transfers can be completed without a cable through a wireless connection or iCloud. For wireless connections, the receiving device must have Android™ 4.0 or later and the sending device must have iOS 12 or later. iCloud transfers require the receiving device to have Android™ 4.0 or later and the sending device to have iOS 5 or later. Open Smart Switch Mobile in “Settings” on the receiving Galaxy device or download the Smart Switch Mobile app from the Galaxy Store. For wireless transfers, download Smart Switch for iOS from the App Store on your iPhone or iPad. Data, content and apps available for transfer may vary by transmission method. Contacts, gallery, videos, calendars and reminders can be transferred wirelessly from an iOS device.
It is recommended to use a wired connection when transferring diverse sets of data at once.
Galaxy Buds3 Pro, Galaxy Watch7 and Galaxy Tab S10 devices sold separately.
Weight may vary by country or region.
Terms and conditions apply. Samsung Care+ coverage, service type and promotion details may vary by country/region and deductible (service fee) may apply. To be eligible for Samsung Care+ promotion benefit, registration may be required. For detailed Samsung Care+ information, please visit https://www.samsung.com/samsung-care-plus/.
3x distance is optical zoom. 2x distance is optical quality zoom.
30x Space Zoom includes 3x Optical Zoom and 30x Digital Zoom with Super Resolution technology. Zoom distances past 3x Zoom may express some image deterioration.
AI Zoom is applied to distances between Digital Zoom lengths. Accuracy of results is not guaranteed.
`;
target.insertAdjacentHTML('beforeend', viewrHTML);
res();
});
};
const bindEvents = function () {
eventHandler.viewerEvents();
eventHandler.click();
eventHandler.mousedown();
eventHandler.mouseup();
if (!isLow) {
eventList.setScene();
}
};
const eventHandler = {
viewerEvents: function () {
window.addEventListener('introPoseReady', eventList.introPoseReady);
window.addEventListener('viewerLoadEnd', eventList.viewerLoadEnd);
},
click: function () {
els.resetBtn && els.resetBtn.addEventListener('click', eventList.clickReset);
els.presetOpen && els.presetOpen.addEventListener('click', eventList.openPresetPopup);
for (let i = 0; i < els.angleCta.length; i++) {
els.angleCta[i].addEventListener('click', eventList.setAngle);
}
els.contents.addEventListener('click', function (e) {
if (e.target.classList.contains('js-reset-btn') || e.target.classList.contains('js-fold-btn') || e.target.classList.contains('js-preset-open') || e.target.closest('.js-preset-layer')) return;
eventList.closePresetPopup();
});
},
scroll: function () {
window.addEventListener('scroll', eventList.runIntroPose);
},
mousedown: function () {
els.presetOpen.addEventListener('mousedown', eventList.presetOpenDown);
els.presetOpen.addEventListener('touchstart', eventList.presetOpenDown);
},
mouseup: function () {
els.presetOpen.addEventListener('mouseup', eventList.presetOpenUp);
els.presetOpen.addEventListener('touchend', eventList.presetOpenUp);
},
presetOpen: function () {
window.addEventListener('focusin', eventList.focusInPreset);
},
presetClose: function () {
window.removeEventListener('focusin', eventList.focusInPreset);
}
};
const eventList = {
viewerLoadEnd: function () {
pdViewer.hideLoader();
eventList.setViewerAltText();
isViewerLoaded = true;
},
introPoseReady: function () {
if (!isLow) {
els.viewerParent.isIntroposeReady = true;
eventHandler.scroll();
eventList.runIntroPose();
} else {
els.viewerParent && pdViewer.runIntroPoseAll();
}
},
setScene: function () {
els.sceneObj = SCROLLER({
trackElement: els.section,
useFixed: false
});
},
runIntroPose: function () {
els.sceneObj.trackAnimation(function () {
let progress = currDevice.indexOf('mobile') > -1 ? 50 : 30;
if (this.progress >= progress && !!els.viewerParent.isIntroposeReady) {
els.viewerParent && pdViewer.runIntroPoseAll();
window.removeEventListener('scroll', eventList.runIntroPose);
}
});
},
clickReset: function () {
if (!isViewerLoaded) return;
pdViewer.reset();
},
presetOpenDown: function () {
isPresetOpenDown = true;
},
presetOpenUp: function () {
isPresetOpenDown = false;
},
focusInPreset: function () {
if (isPresetOpenDown) return;
const isAngleCtaFocus = Array.from(els.angleCta).find((el) => el === document.activeElement);
if (els.presetClose !== document.activeElement && !isAngleCtaFocus) {
eventList.closePresetPopup();
}
},
openPresetPopup: function () {
if (!els.presetLayer.classList.contains('is-active')) {
els.presetOpen.classList.add('is-open');
els.presetLayer.classList.add('is-active');
els.presetOpen.setAttribute('aria-expanded', true);
els.presetClose.focus();
eventHandler.presetOpen();
} else {
eventList.closePresetPopup();
}
els.presetClose && els.presetClose.addEventListener('click', eventList.closePresetPopup);
},
closePresetPopup: function (e) {
if (els.presetLayer.classList.contains('is-active')) {
els.presetOpen.classList.remove('is-open');
els.presetLayer.classList.remove('is-active');
els.presetOpen.setAttribute('aria-expanded', false);
if (e && e.target.classList.contains('js-preset-close')) {
els.presetOpen.focus();
}
eventHandler.presetClose();
}
},
setAngle: function () {
if (!isViewerLoaded) return;
let target = this,
targetAngle = target.getAttribute('data-js-angle');
pdViewer.setModelDirection(targetAngle);
accessibility.selected(target);
},
setViewerAltText: function () {
let altText = '';
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
const activeModel = els.viewerSection.getAttribute('data-product-name');
altText = activeModel === 'galaxy-s25-plus' ? LOCAL_VARI.viewer.altTextPlus : LOCAL_VARI.viewer.altTextBasic;
}
pdViewer.setCanvasAltText(altText);
}
};
const accessibility = {
selected: function (target) {
for (let i = 0; i < els.angleCta.length; i++) {
els.angleCta[i].removeAttribute('title');
if (els.angleCta[i].classList.contains('is-selected')) {
els.angleCta[i].classList.remove('is-selected');
}
}
if (!target.classList.contains('is-selected')) {
target.classList.add('is-selected');
}
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
target.setAttribute('title', LOCAL_VARI.selected);
} else {
target.setAttribute('title', 'Selected');
}
}
};
return {
init: init
}
})();
})();
(function () {
window.flagship.features.colors = (function () {
const utils = window.flagship.common.utils;
let els = {},
colorchips = document.querySelectorAll('.js-colorchip'),
isViewerLoaded = utils.isLowNetwork ? true : false;
const init = function () {
els.section = document.querySelector('.js-colors');
for (let i = 0; i < colorchips.length; i++) {
colorchips[i].type = colorchips[i].parentElement.classList.contains('js-popup-colorchip') ? 'popup' : 'colors';
colorchips[i].isStatic = colorchips[i].parentElement.getAttribute('data-static');
flagship.features.colorchip(colorchips[i]);
}
setElements();
bindEvents();
initialize();
eventList.setActiveModel(els.viewerSection.getAttribute('data-product-name'));
}
const setElements = function () {
// model group
els.modelGroupBtns = els.section.querySelectorAll('.js-model-button');
// panel
els.panelWrap = els.section.querySelector('.js-panel-wrap');
els.panelInner = els.section.querySelectorAll('.js-panel-inner');
// viewer
els.viewerSection = els.section.querySelector('.js-colors-viewer');
els.viewerWrap = els.viewerSection.querySelector('.features-colors__viewer360-content');
// colorchip
els.allColorchip = els.section.querySelectorAll('.features-colors__colorchip');
els.allColorchipButtons = els.section.querySelectorAll('.js-colorchip-button');
els.highColorchipWrap = els.section.querySelector('.features-colors__colorchip--high');
els.highColorchipButtons = els.highColorchipWrap.querySelectorAll('.js-colorchip-button');
els.lowColorchipWrap = els.section.querySelector('.features-colors__colorchip--low');
els.colorchipNameBtns = els.section.querySelectorAll('.features-colors__chip-product-text');
els.colorchipButtons = els.lowColorchipWrap.querySelectorAll('.js-colorchip-button');
};
const bindEvents = function () {
eventHandler.click();
eventHandler.viewerEvents();
}
const initialize = function () {
if (els.modelGroupBtns.length === 0) {
els.allColorchip.forEach((colorchipWrap) => colorchipWrap.classList.add('is-single'));
}
}
const eventHandler = {
click: function () {
for (let i = 0; i < els.modelGroupBtns.length; i++) {
els.modelGroupBtns[i].addEventListener('click', eventList.clickModelButton);
}
},
viewerEvents: function () {
if (!PDVIEWER.getViewer()) return;
window.addEventListener('viewerLoadEnd', eventList.viewerLoadEnd);
}
}
const eventList = {
clickModelButton: async function () {
if (!isViewerLoaded) return;
const modelName = this.getAttribute('data-model-name');
if (modelName === els.viewerSection.getAttribute('data-product-name')) return;
if (!utils.isLowNetwork()) {
const viewerObj = PDVIEWER.getViewer();
if (!viewerObj || viewerObj.viewer.isChanging) return;
const activeColorchipEl = Array.from(els.highColorchipButtons).find((el) => el.classList.contains('is-active'));
const colorName = activeColorchipEl.getAttribute('data-colors');
viewerObj.showLoader();
await viewerObj.fadeChangeModel(modelName, colorName);
viewerObj.hideLoader();
}
els.viewerSection.setAttribute('data-product-name', modelName);
eventList.setActiveModel(modelName);
},
setActiveModel: function (activeName) {
eventList.fadeOut(activeName);
eventList.setModelName(activeName);
eventList.setColorchip(activeName);
eventList.setColorchipName(activeName);
if (!utils.isLowNetwork()) {
eventList.setCanvasAltText(activeName);
}
},
setModelName: function (activeName) {
for (let i = 0; i < els.modelGroupBtns.length; i++) {
const targetBtn = els.modelGroupBtns[i];
targetBtn.classList.remove('is-active');
targetBtn.removeAttribute('title');
if (targetBtn.getAttribute('data-model-name') === activeName) {
targetBtn.classList.add('is-active');
accessibility.selected(targetBtn);
}
}
},
setPanel: function (activeName) {
for (let i = 0; i < els.panelInner.length; i++) {
const panel = els.panelInner[i];
const panelModelName = panel.getAttribute('data-panel-model');
if (panelModelName === activeName) {
panel.classList.add('is-active');
eventList.setPanelItem(panel);
} else {
panel.classList.remove('is-active');
accessibility.inactivePanel(panel)
}
}
},
setPanelItem: function (panelInnerEl) {
const activeColorchip = Array.from(els.colorchipButtons).find((el) => el.classList.contains('is-active'));
const activeColorName = activeColorchip.getAttribute('data-colors');
const panelItems = panelInnerEl.querySelectorAll('.js-panel-item');
for (let i = 0; i < panelItems.length; i++) {
const item = panelItems[i];
if (item.classList.contains('is-active')) item.classList.remove('is-active');
if (item.getAttribute('id') === activeColorName) item.classList.add('is-active');
}
accessibility.activePanel(panelInnerEl, activeColorName);
},
setColorchip: function (activeName) {
for (let i = 0; i < els.allColorchipButtons.length; i++) {
const colorchipWrap = els.allColorchipButtons[i].parentElement;
const enableModels = colorchipWrap.getAttribute('data-active-model').split(',');
const isEnableModel = enableModels.find((name) => name === activeName);
if (!isEnableModel) {
colorchipWrap.style.display = 'none';
} else {
colorchipWrap.style.display = 'block';
}
}
},
setColorchipName: function (activeName) {
for (let i = 0; i < els.colorchipNameBtns.length; i++) {
const chipNameBtn = els.colorchipNameBtns[i];
const chipModel = chipNameBtn.getAttribute('data-color-model');
if (chipModel === activeName) {
chipNameBtn.classList.add('is-active');
} else {
chipNameBtn.classList.remove('is-active');
}
}
},
fadeOut: function (activeName) {
if (utils.isLowNetwork()) {
els.panelWrap.removeEventListener('transitionend', eventList.fadeIn.bind(null, activeName));
els.panelWrap.removeEventListener('transitionend', eventList.onFadeIn);
els.panelWrap.style.transition = 'opacity .3s ease-in-out';
els.panelWrap.style.opacity = 0;
els.panelWrap.addEventListener('transitionend', eventList.fadeIn.bind(null, activeName));
}
},
fadeIn: function (activeName) {
if (utils.isLowNetwork()) {
eventList.setPanel(activeName);
els.panelWrap.style.opacity = 1;
els.panelWrap.removeEventListener('transitionend', eventList.fadeIn.bind(null, activeName));
els.panelWrap.addEventListener('transitionend', eventList.onFadeIn);
}
},
onFadeIn: function () {
if (utils.isLowNetwork()) {
els.panelWrap.style.transition = '';
els.panelWrap.removeEventListener('transitionend', eventList.onFadeIn);
}
},
setCanvasAltText: function (activeName) {
let altText = '';
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
altText = activeName === 'galaxy-s25-plus' ? LOCAL_VARI.viewer.altTextPlus : LOCAL_VARI.viewer.altTextBasic;
}
if (PDVIEWER.getViewer()) PDVIEWER.getViewer().setCanvasAltText(altText);
},
viewerLoadEnd: function () {
isViewerLoaded = true;
}
};
const accessibility = {
selected: function (target) {
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
target.setAttribute('title', LOCAL_VARI.selected);
} else {
target.setAttribute('title', 'Selected');
}
},
activePanel: function (activePanel, activeColor) {
const panelItems = activePanel.querySelectorAll('.js-panel-item');
for (let i = 0; i < panelItems.length; i++) {
const item = panelItems[i];
if (item.getAttribute('id') === activeColor) {
item.setAttribute('aria-hidden', false);
} else {
item.setAttribute('aria-hidden', true);
}
}
},
inactivePanel: function (panel) {
const panelItems = panel.querySelectorAll('.js-panel-item');
for (let i = 0; i < panelItems.length; i++) {
panelItems[i].setAttribute('aria-hidden', true);
}
}
}
return {
init: init
}
})();
window.flagship.features.colorchip = function (colorchipWrap) {
const utils = window.flagship.common.utils,
resize = window.flagship.common.resize;
let els = {},
activeClass = 'is-active',
middleClass = 'is-middle',
endClass = 'is-end',
currentDevice = resize.checkResolution(),
prevDevice = null,
currentSlidesPerView = currentDevice.indexOf('mobile') > -1 ? 5 : 7,
isViewerLoaded = utils.isLowNetwork ? true : false;
const init = function () {
els.section = document.querySelector('.js-colors');
els.popup = document.querySelector('.js-viewer');
if (colorchipWrap.type == 'popup') {
colorchipWrap.contentWrap = els.popup;
} else {
colorchipWrap.contentWrap = els.section;
}
setElements();
setProperty();
bindEvents();
};
const setElements = function () {
// panel
els.panelWrap = els.section.querySelector('.js-panel-wrap');
els.panelInner = els.panelWrap.querySelectorAll('.js-panel-inner');
// colorchip
els.swiperContainer = colorchipWrap.querySelector('.js-colorchip-container');
els.colorchipButtons = colorchipWrap.querySelectorAll('.js-colorchip-button');
els.swiperArrowWrap = colorchipWrap.querySelector('.js-arrow-wrap');
els.swiperNextArrow = colorchipWrap.querySelector('.js-colorchip-next');
els.swiperPrevArrow = colorchipWrap.querySelector('.js-colorchip-prev');
els.colorchipNames = colorchipWrap.querySelectorAll('.js-colorchip-name');
// viewer
els.viewerSection = els.section.querySelector('.js-colors-viewer');
els.viewerWrap = els.viewerSection.querySelector('.features-colors__viewer360-content');
};
const setProperty = function () {
for (let i = 0; i < els.colorchipButtons.length; i++) {
els.colorchipButtons[i].index = i;
}
};
const bindEvents = function () {
eventList.checkColorchipSwiper();
if (colorchipWrap.type != 'popup') eventList.setColors(0);
eventHandler.click();
eventHandler.keydown();
resize.add(eventList.resize);
eventHandler.scroll();
eventHandler.viewerEvents();
if (!utils.isLowNetwork()) {
eventHandler.clickHighColorchip();
}
};
const eventHandler = {
click: function () {
for (let i = 0; i < els.colorchipButtons.length; i++) {
els.colorchipButtons[i].addEventListener('click', eventList.clickColorchip);
}
els.swiperNextArrow.addEventListener('click', accessibility.clickArrow);
els.swiperPrevArrow.addEventListener('click', accessibility.clickArrow);
},
keydown: function () {
els.swiperNextArrow.addEventListener('keydown', accessibility.clickArrow);
els.swiperPrevArrow.addEventListener('keydown', accessibility.clickArrow);
},
scroll: function () {
window.addEventListener('scroll', eventList.scroll);
},
viewerEvents: function () {
if (!PDVIEWER.getViewer()) return;
window.addEventListener('viewerLoadEnd', eventList.viewerLoadEnd);
},
clickHighColorchip: function () {
els.swiperContainer.addEventListener('click', eventList.colorchipsEnable);
}
};
const eventList = {
scroll: function () {
let winOffsetBottom = window.pageYOffset + window.innerHeight,
kv = document.querySelector('.features-kv'),
kvHeight = kv.getBoundingClientRect().height + utils.getNavHeight();
if (winOffsetBottom >= kvHeight) {
// bg load
colorchipWrap.bgImgs = colorchipWrap.querySelectorAll('.js-bg-img');
if (!!colorchipWrap.bgImgs) bgLoader.setResponsiveMedia(colorchipWrap.bgImgs);
window.removeEventListener('scroll', eventList.scroll);
}
},
checkColorchipSwiper: function () {
let colorchipSwiperLength = currentDevice.indexOf('mobile') > -1 ? 6 : 8;
if (els.colorchipButtons.length >= colorchipSwiperLength) {
if (els.swiperArrowWrap.style.display == 'none') {
els.swiperArrowWrap.style.display = '';
}
swiperEvents.set();
} else {
if (els.swiperArrowWrap.style.display != 'none') {
els.swiperArrowWrap.style.display = 'none';
}
if (els.colorchipSwiper != null) {
swiperEvents.destroy();
}
}
},
setColors: function (activeIndex) {
eventList.setColorchip(activeIndex);
eventList.setPanel(activeIndex);
eventList.setColorName(activeIndex);
// viewer
if (PDVIEWER.getViewer()) {
eventList.setViewerColor(activeIndex)
}
},
resize: function (currRes) {
currentDevice = currRes;
if (currentDevice !== prevDevice) {
currentSlidesPerView = currentDevice.indexOf('mobile') > -1 ? 5 : 7;
prevDevice = currentDevice;
eventList.checkColorchipSwiper();
}
},
clickColorchip: async function () {
if (!isViewerLoaded) return;
if (!utils.isLowNetwork() && PDVIEWER.getViewer()) {
if (PDVIEWER.getViewer().viewer.isChanging) return;
}
const targetColor = this;
eventList.setColors(targetColor.index);
},
setViewerColor: async function (activeIndex) {
const modelName = els.viewerSection.getAttribute('data-product-name');
const colorName = els.colorchipButtons[activeIndex].getAttribute('data-colors');
await PDVIEWER.getViewer().changeColor(modelName, colorName);
},
setColorchip: function (activeIndex) {
let targetcolorchipButton = els.colorchipButtons[activeIndex];
for (let i = 0; i < els.colorchipButtons.length; i++) {
els.colorchipButtons[i].classList.remove(activeClass);
els.colorchipButtons[i].removeAttribute('title');
}
if (!targetcolorchipButton.classList.contains(activeClass)) {
targetcolorchipButton.classList.add(activeClass);
accessibility.selected(targetcolorchipButton);
}
},
setPanel: function (activeIndex) {
if (!colorchipWrap.isStatic) return;
const activePanelInner = Array.from(els.panelInner).find((el) => el.classList.contains('is-active'));
if (!activePanelInner) return;
const panelItems = activePanelInner.querySelectorAll('.js-panel-item');
for (let i = 0; i < panelItems.length; i++) {
if (panelItems[i].classList.contains(activeClass)) {
panelItems[i].classList.remove(activeClass);
panelItems[i].setAttribute('aria-hidden', true);
}
}
if (!panelItems[activeIndex].classList.contains(activeClass)) {
panelItems[activeIndex].classList.add(activeClass);
panelItems[activeIndex].setAttribute('aria-hidden', false);
}
},
setColorName: function (activeIndex) {
for (let i = 0; i < els.colorchipNames.length; i++) {
if (i !== activeIndex) {
utils.onAccessibility(els.colorchipNames[i]);
}
if (els.colorchipNames[i].classList.contains(activeClass)) {
els.colorchipNames[i].classList.remove(activeClass);
}
}
if (!els.colorchipNames[activeIndex].classList.contains(activeClass)) {
els.colorchipNames[activeIndex].classList.add(activeClass);
utils.offAccessibility(els.colorchipNames[activeIndex]);
}
},
viewerLoadEnd: function () {
isViewerLoaded = true;
},
colorchipsEnable: function () {
if (!PDVIEWER.getViewer().viewer.isChanging) {
els.section.classList.remove('is-viewer-loading');
}
}
};
const swiperEvents = {
set: function () {
if (els.colorchipSwiper == null) {
els.colorchipSwiper = new Swiper(els.swiperContainer, {
init: false,
navigation: {
nextEl: els.swiperNextArrow,
prevEl: els.swiperPrevArrow,
},
slidesPerView: currentSlidesPerView,
speed: 300,
});
els.colorchipSwiper.on('init', swiperEvents.init);
els.colorchipSwiper.on('slideChange', swiperEvents.slideChange);
els.colorchipSwiper.init();
}
},
init: function () {
let notification = this.el.querySelector('.swiper-notification');
if (!!notification) this.el.removeChild(notification);
els.swiperPrevArrow.removeAttribute('aria-label');
els.swiperPrevArrow.removeAttribute('role');
els.swiperNextArrow.removeAttribute('aria-label');
els.swiperNextArrow.removeAttribute('role');
accessibility.colorchip(els.colorchipSwiper);
accessibility.colorchipArrow(els.colorchipSwiper);
},
slideChange: function () {
accessibility.colorchip(els.colorchipSwiper);
accessibility.colorchipArrow(els.colorchipSwiper);
},
destroy: function () {
els.colorchipSwiper.destroy(true);
els.colorchipSwiper = null;
},
};
const accessibility = {
clickArrow: function (e) {
let arrowTimeout = null,
arrowStyleTimeout = null;
if ((e.type == 'keydown' && e.keyCode == 13) || e.type == 'click') {
e.preventDefault();
if (els.colorchipSwiper.isBeginning && !els.colorchipSwiper.isEnd) {
els.swiperContainer.parentElement.classList.remove(middleClass);
els.swiperContainer.parentElement.classList.remove(endClass);
clearTimeout(arrowTimeout);
arrowTimeout = setTimeout(function () {
els.swiperNextArrow.focus();
}, 300);
clearTimeout(arrowStyleTimeout);
arrowStyleTimeout = setTimeout(function () {
els.swiperPrevArrow.style.display = '';
}, 400);
} else if (!els.colorchipSwiper.isBeginning && els.colorchipSwiper.isEnd) {
els.swiperContainer.parentElement.classList.remove(middleClass);
els.swiperContainer.parentElement.classList.add(endClass);
clearTimeout(arrowTimeout);
arrowTimeout = setTimeout(function () {
els.swiperPrevArrow.focus();
}, 300);
clearTimeout(arrowStyleTimeout);
arrowStyleTimeout = setTimeout(function () {
els.swiperNextArrow.style.display = '';
}, 400);
}
if (!els.colorchipSwiper.isBeginning && !els.colorchipSwiper.isEnd) {
els.swiperContainer.parentElement.classList.remove(endClass);
els.swiperContainer.parentElement.classList.add(middleClass);
}
}
},
colorchip: function (swiperObj) {
let isNotActivedColorchips = null;
for (let i = 0; i < swiperObj.slides.length; i++) {
if (currentDevice.indexOf('mobile') > -1) {
isNotActivedColorchips = (i != swiperObj.activeIndex) && (i > swiperObj.activeIndex + 4) || (swiperObj.activeIndex > i);
} else {
isNotActivedColorchips = (i != swiperObj.activeIndex) && (i > swiperObj.activeIndex + 6) || (swiperObj.activeIndex > i);
}
if (isNotActivedColorchips) {
utils.onAccessibility(swiperObj.slides[i]);
setTimeout(function () {
utils.onAccessibility(swiperObj.slides[i]);
}, 300);
} else {
utils.offAccessibility(swiperObj.slides[i]);
setTimeout(function () {
utils.offAccessibility(swiperObj.slides[i]);
}, 300);
}
}
},
colorchipArrow: function (swiperObj) {
if (swiperObj.isBeginning && !swiperObj.isEnd) {
utils.onAccessibility(els.swiperPrevArrow);
utils.offAccessibility(els.swiperNextArrow);
} else if (!swiperObj.isBeginning && !swiperObj.isEnd) {
utils.offAccessibility(els.swiperPrevArrow);
utils.offAccessibility(els.swiperNextArrow);
} else {
utils.onAccessibility(els.swiperNextArrow);
utils.offAccessibility(els.swiperPrevArrow);
}
},
selected: function (target) {
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
target.setAttribute('title', LOCAL_VARI.selected);
} else {
target.setAttribute('title', 'Selected');
}
}
};
return init(colorchipWrap);
};
})();
(function () {
window.flagship.features.compares = (function () {
const init = function () {
const compares = document.querySelectorAll('.js-compare');
for (let i = 0; i < compares.length; i++) {
compares[i].type = compares[i].getAttribute('data-compare-type') || null;
flagship.features.compare(compares[i]);
}
}
return {
init: init
}
})();
window.flagship.features.compare = function (compareWrap) {
const resize = window.flagship.common.resize,
compareOption = window.flagship.features.compareOption;
let els = {},
prevDevice = null,
currDevice = resize.checkResolution(),
isMousedown = false;
els.currentOldValue = null,
els.compareOldValue = null;
const compareData = {
'SM-S931': {
modelName: 'galaxy-s25',
modelText: 'Galaxy S25',
weight: {
A: 162,
B: 162,
},
thickness: 7.2,
hrs: {
A: 29,
B: 29,
}
},
'SM-S936': {
modelName: 'galaxy-s25-plus',
modelText: 'Galaxy S25+',
weight: {
A: 190,
B: 190,
},
thickness: 7.3,
hrs: {
A: 30,
B: 30,
}
},
'SM-S916': {
modelName: 'galaxy-s23-plus',
modelText: 'Galaxy S23+',
weight: {
A: 196,
B: 195,
},
thickness: 7.6,
hrs: {
A: 27,
B: 27,
}
},
'SM-S911': {
modelName: 'galaxy-s23',
modelText: 'Galaxy S23',
weight: {
A: 168,
B: 168,
},
thickness: 7.6,
hrs: {
A: 22,
B: 22,
}
},
'SM-S906': {
modelName: 'galaxy-s22-plus',
modelText: 'Galaxy S22+',
weight: {
A: 196,
B: 195,
},
thickness: 7.6,
hrs: {
A: 21,
B: 22,
}
},
'SM-S901': {
modelName: 'galaxy-s22',
modelText: 'Galaxy S22',
weight: {
A: 168,
B: 167,
},
thickness: 7.6,
hrs: {
A: 18,
B: 19,
}
},
'SM-G996': {
modelName: 'galaxy-s21-plus',
modelText: 'Galaxy S21+ 5G',
weight: {
A: 202,
B: 200,
},
thickness: 7.8,
hrs: {
A: 22,
B: 22,
}
},
'SM-G991': {
modelName: 'galaxy-s21',
modelText: 'Galaxy S21 5G',
weight: {
A: 171,
B: 169,
},
thickness: 7.9,
hrs: {
A: 19,
B: 20,
}
}
}
const init = function () {
els.section = compareWrap;
if (!!els.section) {
setElements();
setProperty();
bindEvents();
eventList.setCompareVari();
eventList.getDeviceInfo().then((modelCode) => {
if (!modelCode || !Object.keys(compareData).find((sku) => sku === modelCode) || (modelCode === 'SM-S931' || 'SM-S936')) {
modelCode = 'SM-G996';
}
const currentModel = 'SM-S936';
eventList.setDefault(els.currentVisual, currentModel);
eventList.selectItem(els.currentVisual, currentModel);
eventList.setDefault(els.compareVisual, modelCode);
eventList.selectItem(els.compareVisual, modelCode);
});
}
};
const setElements = function () {
els.visualEls = [];
els.currentVisual = els.section.querySelector('.js-current-visual');
els.compareVisual = els.section.querySelector('.js-compare-visual');
els.visualEls.push(els.currentVisual, els.compareVisual);
els.visualEls.forEach((visualEl) => visualEl.dropdown = visualEl.querySelector('.js-dropdown'));
if (els.section.type === 'camera') {
els.zoomTexts = els.section.querySelectorAll('.js-copy-zoom');
} else if (els.section.type === 'design') {
els.thicknessTexts = els.section.querySelectorAll('.js-copy-thickness');
els.weightTexts = els.section.querySelectorAll('.js-copy-weight');
els.visualEls.forEach((visualEl) => {
visualEl.compareThickness = visualEl.querySelector('.js-thickness-value');
visualEl.compareWeight = visualEl.querySelector('.js-weight-value');
visualEl.thicknessUnits = visualEl.querySelectorAll('.js-thickness-unit');
visualEl.weightUnits = visualEl.querySelectorAll('.js-weight-unit');
});
} else if (els.section.type === 'battery') {
els.playbackTexts = els.section.querySelectorAll('.js-copy-playback');
els.visualEls.forEach((visualEl) => {
visualEl.compareHrs = visualEl.querySelector('.js-hrs-value');
visualEl.batteryUnits = visualEl.querySelectorAll('.js-battery-unit');
})
}
};
const setProperty = function () {
els.visualEls.forEach((visualEl) => {
visualEl.dropdown.selectBox = visualEl.dropdown.querySelector('.js-select-box');
visualEl.dropdown.button = visualEl.dropdown.querySelector('.js-select-button');
visualEl.dropdown.list = visualEl.dropdown.querySelector('.js-select-list');
visualEl.dropdown.listItem = visualEl.dropdown.list.querySelectorAll('.js-select-item');
});
if (els.section.type === 'camera') {
els.zoomTexts.forEach((textEl) => {
textEl.key = 'zoom';
textEl.defaultText = 'Zoom';
})
} else if (els.section.type === 'design') {
els.thicknessTexts.forEach((textEl) => {
textEl.key = 'thickness';
textEl.defaultText = 'Thickness';
});
els.weightTexts.forEach((textEl) => {
textEl.key = 'weight';
textEl.defaultText = 'Weight';
});
els.visualEls.forEach((visualEl) => {
for (let i = 0; i < visualEl.thicknessUnits.length; i++) {
visualEl.thicknessUnits[i].key = 'mm';
visualEl.thicknessUnits[i].defaultText = 'mm';
}
for (let i = 0; i < visualEl.weightUnits.length; i++) {
visualEl.weightUnits[i].key = 'g';
visualEl.weightUnits[i].defaultText = 'g';
}
});
} else if (els.section.type === 'battery') {
els.playbackTexts.forEach((textEl) => {
textEl.key = 'playback'
textEl.defaultText = 'Video Playback';
});
els.visualEls.forEach((visualEl) => {
for (let i = 0; i < visualEl.batteryUnits.length; i++) {
visualEl.batteryUnits[i].key = 'hrs';
visualEl.batteryUnits[i].defaultText = 'hrs';
}
});
}
};
const bindEvents = function () {
resize.add(eventList.resize);
eventHandler.click();
eventHandler.mousedown();
eventHandler.mouseup();
eventHandler.change();
eventHandler.resize();
eventHandler.offFocusSelect()
};
const eventHandler = {
click: function () {
els.section.addEventListener('click', function (event) {
const isButton = event.target.classList.contains('js-select-button');
const isOption = event.target.classList.contains('js-select-item');
if (isButton) {
eventHandler.dropdownClickCheck(event);
eventList.dropdowntoggle(event);
accessibility.changeAriaHidden();
} else if (isOption) {
eventList.clickCompareModel(event.target);
eventList.clickOption(event.target);
eventList.dropdownClose();
accessibility.dropdownFocus(event.target);
}
});
els.visualEls.forEach((visualEl) => visualEl.dropdown.selectBox.addEventListener("click", eventList.clickSelect));
},
change: function () {
els.visualEls.forEach((visualEl) => {
visualEl.dropdown.selectBox.addEventListener('change', function (event) {
eventList.clickOption(event.target);
eventList.changeSelectBox(event.target);
});
});
},
resize: function () {
window.addEventListener('resize', function () {
accessibility.changeAriaHidden();
});
},
mousedown: function () {
els.visualEls.forEach((visualEl) => {
visualEl.dropdown.button.addEventListener('mousedown', function () {
isMousedown = true;
});
});
},
mouseup: function () {
els.visualEls.forEach((visualEl) => {
visualEl.dropdown.button.addEventListener('mouseup', function () {
isMousedown = false;
});
});
},
dropdownClickCheck: function () {
document.addEventListener('click', eventList.checkDropdownClick);
},
offDropdownClickCheck: function () {
document.removeEventListener('click', eventList.checkDropdownClick);
},
onFocusInDropdown: function () {
eventHandler.offFocusInDropdown();
document.addEventListener('focusin', eventList.focusInDropdown);
},
offFocusInDropdown: function () {
document.removeEventListener('focusin', eventList.focusInDropdown);
},
offFocusSelect: function () {
els.visualEls.forEach((visualEl) => {
visualEl.dropdown.selectBox.addEventListener('blur', eventList.offFocusSelect)
});
}
}
const eventList = {
isDropdownSelect: function () {
return els.visualEls.every((visualEl) => visualEl.dropdown.selectBox.clientHeight > 0);
},
dropdowntoggle: function (event) {
const isExpanded = event.target.getAttribute('aria-expanded') === 'true';
event.target.setAttribute('aria-expanded', !isExpanded);
if (!isExpanded) {
event.target.classList.add('is-active');
eventHandler.onFocusInDropdown();
setTagging.close(event.target);
} else {
event.target.classList.remove('is-active');
setTagging.open(event.target);
}
},
checkDropdownClick: function (event) {
const isButton = event.target.classList.contains('js-select-button');
const isOption = event.target.classList.contains('js-select-item');
if (!isButton && !isOption) {
eventList.dropdownClose();
}
},
dropdownClose: function () {
els.visualEls.forEach((visualEl) => {
visualEl.dropdown.button.setAttribute('aria-expanded', 'false');
visualEl.dropdown.button.classList.remove('is-active');
const button = visualEl.dropdown.button;
if (!(button.getAttribute('aria-expanded') === 'true')) {
setTagging.open(button);
}
});
eventHandler.mouseup();
eventHandler.offDropdownClickCheck();
eventHandler.offFocusInDropdown();
accessibility.changeAriaHidden();
},
focusInDropdown: function (event) {
const isInList = event.target.closest('.js-select-list');
const isButton = event.target.classList.contains('js-select-button');
if (!isInList && !(isButton && isMousedown)) {
eventList.dropdownClose();
}
},
clickOption: function (target) {
const targetParent = target.closest('.js-dropdown');
targetParent.selectBoxButton = targetParent.querySelector('.js-select-button');
if (eventList.isDropdownSelect()) {
const selectIndex = targetParent.selectBox.selectedIndex,
optionList = targetParent.selectBox.options;
Array.from(optionList).forEach(option => option.removeAttribute('selected'));
optionList[selectIndex].setAttribute('selected', true)
targetParent.button.textContent = optionList[selectIndex].textContent;
} else {
const selectItemDataValue = target.getAttribute('data-value');
Array.from(targetParent.selectBox.children).forEach((optionEl) => {
const value = optionEl.getAttribute('value');
if (value !== selectItemDataValue) {
optionEl.removeAttribute('selected');
} else {
optionEl.setAttribute('selected', 'true');
}
});
targetParent.selectBox.value = selectItemDataValue;
targetParent.button.textContent = target.textContent;
}
},
setDefault: function (visualEl, modelValue) {
const {
modelText
} = compareData[modelValue];
visualEl.dropdown.button.innerText = modelText;
accessibility.changeAriaHidden();
},
changeDescription: function (modelValue, visualEl) {
const textLists = visualEl.querySelectorAll('.js-camera-text-change');
if (textLists.length > 0) {
textLists.forEach(function (list) {
const matchDataItems = list.dataset.value.split(' ');
const isMatched = matchDataItems.some(item => item === modelValue);
!isMatched ? accessibility.ariaHiddenTrue(list) : accessibility.ariaHiddenFalse(list);
if (isMatched && !els.targetOldValue) {
list.classList.add('is-init');
} else if (els.targetOldValue && els.targetOldValue !== modelValue) {
list.classList.remove('is-active');
list.classList.remove('is-show');
list.classList.remove('is-init');
if (isMatched) {
accessibility.ariaHiddenFalse(list);
list.classList.add('is-show');
setTimeout(function () {
list.classList.add('is-active');
})
}
}
})
}
},
clickCompareModel: function (optionEl) {
const modelValue = optionEl.getAttribute('data-value') || '';
const targetVisualEl = els.visualEls.find((visualEl) => Array.from(visualEl.dropdown.listItem).includes(optionEl));
eventList.selectItem(targetVisualEl, modelValue);
},
changeSelectBox: function (selectEl) {
const targetVisualEl = els.visualEls.find((visualEl) => visualEl.dropdown.selectBox === selectEl);
const selectedEl = Array.from(selectEl.childNodes).find((el) => el.selected);
const modelValue = selectedEl.value;
eventList.selectItem(targetVisualEl, modelValue);
},
resize: function (currRes) {
currDevice = currRes;
if (currDevice != prevDevice) {
eventList.responsive();
prevDevice = currDevice;
}
eventList.dropdownClose();
els.visualEls.forEach((visualEl) => visualEl.dropdown.selectBox.classList.remove("is-active"));
},
responsive: function () {},
getDeviceInfo: function () {
return new Promise((resolve, reject) => {
if (navigator.userAgentData) {
navigator.userAgentData.getHighEntropyValues(['model']).then((uaData) => {
const modelCode = uaData.model ? uaData.model.slice(0, 7) : null;
resolve(modelCode);
}).catch((err) => reject(err));
} else {
const compareModelList = Object.keys(compareData);
const sku = compareModelList.find((sku) => navigator.userAgent.includes(sku));
resolve(sku);
}
});
},
setCompareVari: function () {
let targetTexts = [];
if (els.section.type === 'design') {
targetTexts = Array.from(els.thicknessTexts).concat(Array.from(els.weightTexts));
els.visualEls.forEach((visualEl) => {
targetTexts = targetTexts.concat(Array.from(visualEl.thicknessUnits))
.concat(Array.from(visualEl.weightUnits))
});
} else if (els.section.type === 'camera') {
targetTexts = Array.from(els.zoomTexts);
} else if (els.section.type === 'battery') {
targetTexts = Array.from(els.playbackTexts);
els.visualEls.forEach((visualEl) => {
targetTexts = targetTexts.concat(Array.from(visualEl.batteryUnits))
})
}
targetTexts.forEach((el) => {
const {
key,
defaultText
} = el;
if (typeof COMPARE_VARI != 'undefined' && !!COMPARE_VARI) {
el.innerText = COMPARE_VARI[key] || defaultText;
} else {
el.innerText = defaultText;
}
});
},
setCompareValueText: function (visualEl, modelValue) {
const {
thickness,
weight,
hrs
} = compareData[modelValue];
if (els.section.type === 'design') {
const weightType = weight[compareOption.type] ? weight[compareOption.type] : weight['B'];
visualEl.compareThickness.innerText = thickness;
visualEl.compareWeight.innerText = weightType;
} else if (els.section.type === 'camera') {
eventList.changeDescription(modelValue, visualEl);
} else if (els.section.type === 'battery') {
const hrsType = hrs[compareOption.type] ? hrs[compareOption.type] : hrs['B'];
visualEl.compareHrs.innerText = hrsType;
}
},
selectItem: function (visualEl, modelValue) {
els.targetOldValue = visualEl.classList.contains('js-current-visual') ? els.currentOldValue : els.compareOldValue;
eventList.setCompareValueText(visualEl, modelValue);
if (els.targetOldValue && els.targetOldValue !== modelValue) {
const textAreaList = visualEl.querySelectorAll('.js-text-change');
textAreaList.forEach((textEl) => textEl.classList.remove('is-active'));
setTimeout(() => textAreaList.forEach((textEl) => textEl.classList.add('is-active')), 0);
}
accessibility.changeSelected(visualEl, modelValue);
if (els.targetOldValue === els.currentOldValue) {
els.currentOldValue = modelValue;
} else {
els.compareOldValue = modelValue;
}
},
clickSelect: function (event) {
event.target.classList.toggle("is-active");
},
offFocusSelect: function () {
els.visualEls.forEach((visualEl) => {
if (visualEl.dropdown.selectBox.classList.contains("is-active")) {
visualEl.dropdown.selectBox.classList.remove("is-active");
}
});
}
};
const accessibility = {
changeSelected: function (visualEl, modelCode) {
const targetDropdownItem = visualEl.querySelectorAll('.js-select-item');
const target = Array.from(targetDropdownItem).find((el) => el.getAttribute('data-value') === modelCode);
const selectBoxOptions = visualEl.querySelector('.js-select-box').options;
for (let i = 0; i < selectBoxOptions.length; i++) {
const optionValue = selectBoxOptions[i].getAttribute('value');
if (optionValue !== modelCode) {
selectBoxOptions[i].removeAttribute('selected');
} else {
selectBoxOptions[i].setAttribute('selected', true)
}
}
for (let i = 0; i < targetDropdownItem.length; i++) {
if (targetDropdownItem[i] !== target) {
targetDropdownItem[i].removeAttribute('title');
} else {
accessibility.selected(target);
}
}
},
changeAriaHidden: function () {
els.visualEls.forEach((visualEl) => {
eventList.isDropdownSelect();
if (eventList.isDropdownSelect()) {
accessibility.ariaHiddenTrue(visualEl.dropdown.list);
accessibility.ariaHiddenTrue(visualEl.dropdown.button);
if (visualEl.dropdown.selectBox.hasAttribute('aria-hidden')) {
accessibility.ariaHiddenFalse(visualEl.dropdown.selectBox);
}
} else {
const isOpened = visualEl.dropdown.button.getAttribute('aria-expanded') === 'true';
setTimeout(() => {
// Console warning on aria-hidden on focus element
accessibility.ariaHiddenTrue(visualEl.dropdown.selectBox);
accessibility.ariaHiddenFalse(visualEl.dropdown.button);
if (isOpened) {
accessibility.ariaHiddenFalse(visualEl.dropdown.list);
} else {
accessibility.ariaHiddenTrue(visualEl.dropdown.list);
}
});
}
});
},
ariaHiddenTrue: function (element) {
element.setAttribute('aria-hidden', true);
element.setAttribute('tabindex', '-1');
},
ariaHiddenFalse: function (element) {
element.removeAttribute('aria-hidden');
element.removeAttribute('tabindex');
},
dropdownFocus: function (target) {
const targetVisual = target.closest('.js-current-visual') ? target.closest('.js-current-visual') : target.closest('.js-compare-visual')
targetVisual.dropdown.button.focus();
},
selected: function (target) {
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
target.setAttribute('title', LOCAL_VARI.selected);
} else {
target.setAttribute('title', 'Selected');
}
}
}
const setTagging = {
open: function (target) {
if (target.hasAttribute('data-omni')) {
let dataOmni = target.getAttribute('data-omni').toLowerCase();
target.setAttribute('data-omni', dataOmni.replace('close', 'open'));
}
if (target.hasAttribute('ga-la')) {
let gaLa = target.getAttribute('ga-la').toLowerCase();
target.setAttribute('ga-la', gaLa.replace('close', 'open'));
}
},
close: function (target) {
if (target.hasAttribute('data-omni')) {
let dataOmni = target.getAttribute('data-omni').toLowerCase();
target.setAttribute('data-omni', dataOmni.replace('open', 'close'));
}
if (target.hasAttribute('ga-la')) {
let gaLa = target.getAttribute('ga-la').toLowerCase();
target.setAttribute('ga-la', gaLa.replace('open', 'close'));
}
}
};
return init(compareWrap);
};
})();
(function () {
window.flagship.features.designSpec = (function () {
const utils = window.flagship.common.utils;
let els = {};
let status = {};
const init = function () {
els.section = document.querySelector('.features-design-spec');
els.layerPopup = document.querySelector('.js-compare-popup');
if (!!els.section && !!els.layerPopup) {
setElements();
setStatus();
bindEvents();
}
};
const setElements = function () {
els.contents = document.querySelector('#contents');
els.popupDimmed = document.querySelector('.js-compare-popup__dimmed');
els.openCta = document.querySelector('.js-compare-popup-opener');
els.closeCta = document.querySelectorAll('.js-compare-popop__close-cta');
els.popupWrapper = document.querySelector('.features-design-spec-popup__wrapper');
els.supClicker = els.layerPopup.querySelectorAll('a.click_sup');
els.hashPopupOpener = null;
};
const setStatus = function () {
status.isHash = false;
}
const bindEvents = function () {
eventList.setPopup();
for (let i = 0; i < els.supClicker.length; i++) {
if (!!els.supClicker) {
els.supClicker[i].addEventListener('click', eventList.onClickSup);
}
}
};
const eventList = {
setPopup: function () {
utils.layerPopup({
layerPopup: els.layerPopup,
layerPopupClass: '.js-compare-popup',
openerEvent: {
element: els.openCta,
},
closeCtas: els.closeCta,
dimmed: els.popupDimmed,
moveTarget: document.documentElement,
contents: els.contents,
show: {
start: function () {
els.layerPopup.removeAttribute('aria-hidden');
els.layerPopup.removeAttribute('tabindex');
els.layerPopup.classList.add('is-init');
if (`#${els.openCta.getAttribute('data-hash')}` == window.location.hash) {
status.isHash = true;
els.hashPopupOpener = els.openCta;
}
},
end: function () {
els.layerPopup.classList.add('is-open');
},
},
hide: {
start: function () {
els.layerPopup.classList.remove('is-open');
},
end: function (target) {
if (utils.detector.isIosDevice)
target.openerCta.style.display = '';
setTimeout(function () {
els.layerPopup.classList.remove('is-init');
}, 300);
if (els.popupWrapper) {
els.popupWrapper.scrollTop = 0;
}
if (status.isHash && els.hashPopupOpener) {
els.hashPopupOpener.focus();
setTimeout(function () {
els.hashPopupOpener.focus();
status.isHash = false;
els.hashPopupOpener = null;
}, 300);
}
}
}
});
},
onClickSup: function () {
els.layerPopup.hide();
},
};
return {
init: init,
}
})();
})();
(function () {
window.flagship = window.flagship || {};
window.flagship.features = window.flagship.features || {};
window.flagship.features.display = (function () {
const utils = window.flagship.common.utils;
const resize = window.flagship.common.resize;
let els = {};
let objs = {};
let status = {};
let currDevice = resize.checkResolution();
let prevDevice = null;
const init = function () {
els.section = document.querySelector('.features-display');
if (!!els.section) {
setElements();
setStatus();
bindEvents();
}
};
const setElements = function () {
els.resizeTimeout = null;
els.displayBarWrap = els.section.querySelector('.features-display__bar');
els.displayBar = els.displayBarWrap.querySelector('.features-display__bar-line');
els.displayImage = els.section.querySelector('.features-display__image');
els.displayCoverImage = els.section.querySelector('.features-display__cover');
els.isGrab = false;
els.isAction = false;
els.displayCoverLeftWrap = els.section.querySelector('.features-display__tap--left');
els.displayCoverLeftBtn = els.section.querySelector('.features-display__tap--left button');
els.displayCoverRightBtn = els.section.querySelector('.features-display__tap--right button');
els.controller = els.section.querySelector('.features-display__button');
els.imgWrap = els.section.querySelector('.features-display__image-inner');
els.tabWrap = els.section.querySelector('.features-display__tap-wrap');
maxPercent = currDevice === 'mobileS' ? 0.805 : currDevice === 'mobile' ? 0.845 : 0.985;
minPercent = currDevice === 'mobileS' ? 0.193 : currDevice === 'mobile' ? 0.155 : 0.015;
};
const setStatus = function () {
status.isTabMove = false;
};
const bindEvents = function () {
window.addEventListener('DOMContentLoaded', onLoadHandler, {
once: true
});
window.addEventListener('scroll', onScrollHandler);
els.section.addEventListener('click', grabEventHandler.onMoveEvent);
els.section.addEventListener('mousedown', grabEventHandler.onStart);
els.section.addEventListener('mousemove', grabEventHandler.onMove);
els.section.addEventListener('mouseup', grabEventHandler.onEnd);
els.section.addEventListener('mouseleave', grabEventHandler.onEnd);
els.section.addEventListener('touchstart', grabEventHandler.onStart);
els.section.addEventListener('touchmove', grabEventHandler.onMove);
els.section.addEventListener('touchend', grabEventHandler.onEnd);
els.section.addEventListener('touchcancel', grabEventHandler.onEnd);
els.section.addEventListener('touchmove', grabEventHandler.moveDisabled);
els.section.addEventListener('mousemove', grabEventHandler.moveDisabled);
els.section.addEventListener('click', grabEventHandler.moveDisabled);
resize.add(onResizeHandler);
}
const setAnimations = function () {
let minValue = currDevice.indexOf('mobile') > -1 ? 27.5 : 25;
let maxValue = currDevice.indexOf('mobile') > -1 ? 72.5 : 75;
TweenMax.set(els.displayBar, {
left: `${minValue}%`,
ease: Power2.easeOut
});
TweenMax.set(els.controller, {
left: `${minValue}%`,
ease: Power2.easeOut
});
TweenMax.set(els.displayCoverImage, {
width: `${minValue}%`,
ease: Power2.easeOut
});
objs.barAnim = new TimelineLite();
objs.barAnim
.to(els.displayBar, 1, {
left: `${maxValue}%`,
ease: Power2.easeOut
})
.to(els.displayBar, 1, {
left: 50 + '%',
ease: Power2.easeOut
});
objs.buttonAnim = new TimelineLite();
objs.buttonAnim
.to(els.controller, 1, {
left: `${maxValue}%`,
ease: Power2.easeOut
})
.to(els.controller, 1, {
left: 50 + '%',
ease: Power2.easeOut
});
objs.imgAnim = new TimelineLite();
objs.imgAnim
.to(els.displayCoverImage, 1, {
width: `${maxValue}%`,
ease: Power2.easeOut
})
.to(els.displayCoverImage, 1, {
width: 50 + '%',
ease: Power2.easeOut
});
TweenMax.set(els.displayCoverLeftWrap, {
width: `${minValue}%`,
ease: Power2.easeOut
});
objs.imgAnim = new TimelineLite();
objs.imgAnim
.to(els.displayCoverLeftWrap, 1, {
width: `${maxValue}%`,
ease: Power2.easeOut
})
.to(els.displayCoverLeftWrap, 1, {
width: 50 + '%',
ease: Power2.easeOut
});
};
const onLoadHandler = function () {
onScrollHandler();
};
const onResizeHandler = function (currRes) {
currDevice = currRes;
clearTimeout(els.resizeTimeout);
els.resizeTimeout = setTimeout(function () {
onScrollHandler();
}, 150);
if (currDevice != prevDevice) {
onResponsiveHandler();
prevDevice = currDevice;
}
};
const onResponsiveHandler = function () {
maxPercent = currDevice === 'mobileS' ? 0.805 : currDevice === 'mobile' ? 0.845 : 0.985;
minPercent = currDevice === 'mobileS' ? 0.193 : currDevice === 'mobile' ? 0.155 : 0.015;
TweenMax.set(els.displayBar, {
left: 50 + '%'
});
TweenMax.set(els.controller, {
left: 50 + '%'
});
TweenMax.set(els.displayCoverImage, {
width: 50 + '%'
});
TweenMax.set(els.displayCoverLeftWrap, {
width: 50 + '%'
});
};
const onScrollHandler = function () {
let winOffsetTop = window.pageYOffset + utils.getNavHeight();
let winOffsetBottom = window.pageYOffset + window.innerHeight;
let targetRect = els.displayImage.getBoundingClientRect();
let targetOffsetTop = window.pageYOffset + targetRect.top;
let targetOffsetBottom = window.pageYOffset + targetRect.bottom;
if ((winOffsetBottom - (window.innerHeight * 0.25) > targetOffsetTop &&
winOffsetTop + (window.innerHeight * 0.25) < targetOffsetBottom) && !els.isAction) {
setAnimations();
els.isAction = true;
}
};
const grabEventHandler = {
onStart: function (e) {
e.target.matches('.features-display__button') && (els.isGrab = true);
},
onEnd: function () {
els.isGrab = false;
},
onMove: function (e) {
if (els.isGrab) {
e && e.preventDefault();
let wrapRect = els.displayBarWrap.getBoundingClientRect();
let wrapMaxWidth = wrapRect.width * maxPercent;
let wrapMinWidth = wrapRect.width * minPercent;
let xPosition = !e.touches ? e.pageX : e.touches[0].pageX;
let barPosition = xPosition - wrapRect.left;
if (barPosition > wrapMaxWidth) barPosition = wrapMaxWidth;
else if (barPosition < wrapMinWidth) barPosition = wrapMinWidth;
let barPercent = ((barPosition / wrapRect.width) * 100);
els.displayBar.style.left = barPercent + '%';
els.controller.style.left = barPercent + '%';
els.displayCoverImage.style.width = barPercent + '%';
grabEventHandler.setArrowSize(barPercent);
}
},
onMoveEvent: function (e) {
let wrapRect = els.displayBarWrap.getBoundingClientRect();
let wrapMaxWidth = wrapRect.width * maxPercent;
let wrapMinWidth = wrapRect.width * minPercent;
let barRect = els.displayBar.getBoundingClientRect();
let barPosition = barRect.left - wrapRect.left;
let moveValue = Math.ceil(wrapMaxWidth / ((currDevice.indexOf('desktop') > -1) ? 8 : 5.5));
let isMove = e.target.classList.contains('features-display__tap-button') || e.target.classList.contains('features-display__button');
if (isMove) {
status.isTabMove = true;
if (e.type == 'click' && e.target.classList.contains('features-display__tap-button')) {
let leftBtn = 'features-display__tap--left';
let rightBtn = 'features-display__tap--right';
if (e.target.parentElement.classList.contains(leftBtn)) {
barPosition -= moveValue;
} else if (e.target.parentElement.classList.contains(rightBtn)) {
barPosition += moveValue;
}
}
if (e.target.classList.contains('features-display__button') && (e.keyCode == 39 || e.keyCode == 37)) {
e && e.preventDefault();
if (e.keyCode == 39) barPosition += moveValue;
else if (e.keyCode == 37) barPosition -= moveValue;
}
if (barPosition < wrapMinWidth) barPosition = wrapMinWidth;
else if (barPosition > wrapMaxWidth) barPosition = wrapMaxWidth;
let barPercent = ((barPosition / wrapRect.width) * 100);
TweenMax.to(els.displayBar, 0.3, {
left: barPercent + '%',
ease: Power2.easeOut
});
TweenMax.to(els.controller, 0.3, {
left: barPercent + '%',
ease: Power2.easeOut
});
TweenMax.to(els.displayCoverImage, 0.3, {
width: barPercent + '%',
ease: Power2.easeOut
});
grabEventHandler.setArrowSize(barPercent);
}
},
moveDisabled: function () {
const controllerObserver = new MutationObserver(() => {
setTimeout(() => {
const leftValue = els.controller.style.left;
if (leftValue >= Math.trunc(maxPercent * 100) + "%") {
els.displayCoverRightBtn.disabled = true;
if(els.displayCoverRightBtn.disabled == true) {
utils.onAccessibility(els.displayCoverRightBtn);
els.displayCoverLeftBtn.focus();
}
} else if (leftValue == minPercent * 100 + "%") {
els.displayCoverLeftBtn.disabled = true;
if(els.displayCoverLeftBtn.disabled == true) {
utils.onAccessibility(els.displayCoverLeftBtn);
els.displayCoverRightBtn.focus();
}
} else {
els.displayCoverRightBtn.removeAttribute("disabled");
els.displayCoverLeftBtn.removeAttribute("disabled");
utils.offAccessibility(els.displayCoverRightBtn);
utils.offAccessibility(els.displayCoverLeftBtn);
}
}, 0);
});
controllerObserver.observe(els.controller, {
attributes: true,
attributeFilter: ['style']
});
},
setArrowSize: function (barPercent) {
let imgWidth = els.imgWrap.getBoundingClientRect().width;
let tabWidth = els.tabWrap.getBoundingClientRect().width;
let imgValue = imgWidth * (barPercent * (1 / 100));
let tabValue = (imgWidth - tabWidth) / 2;
let moveTabBtnValue = Math.floor(imgValue - tabValue);
if (status.isTabMove) {
TweenMax.to(els.displayCoverLeftWrap, 0.3, {
width: moveTabBtnValue + 'px',
ease: Power2.easeOut
});
status.isTabMove = false;
} else {
els.displayCoverLeftWrap.style.width = moveTabBtnValue + 'px';
}
}
};
return {
init: init
}
})();
})();
;
(function () {
window.flagship.features.faq = (function () {
const resize = window.flagship.common.resize,
utils = window.flagship.common.utils;
let els = {},
prevDevice = null,
currDevice = resize.checkResolution();
const init = function () {
els.section = document.querySelector('.js-faq');
if (!!els.section) {
setElements();
bindEvents();
}
};
const setElements = function () {
els.faqList = els.section.querySelector('.js-faq-list');
};
const bindEvents = function () {
resize.add(eventList.resize);
eventList.setAccordion();
};
const eventList = {
resize: function (currRes) {
currDevice = currRes;
if (currDevice != prevDevice) {
eventList.responsive();
prevDevice = currDevice;
}
},
responsive: function () {
let isOpenedItems = els.faqList.querySelectorAll('.js-faq-item.is-open');
if (isOpenedItems.length > 0) {
for (let i = 0; i < isOpenedItems.length; i++) {
let isOpenedItemContent = isOpenedItems[i].querySelector('.js-faq-answer'),
clientHeight = isOpenedItemContent.children[0].clientHeight;
isOpenedItemContent.style.height = `${clientHeight}px`;
}
}
},
setAccordion: function () {
els.accordion = new window.flagship.common.accordion({
wrap: els.faqList,
classList: {
item: 'js-faq-item',
button: 'js-faq-open',
contents: 'js-faq-answer',
activeClass: 'is-open'
},
open: {
start: function (target) {
let targetInnerCta = target.querySelector('.js-featue-cta');
if (targetInnerCta) targetInnerCta.addEventListener('click', accessibility.moveFocus);
}
}
});
els.accordion.init();
},
};
const accessibility = {
moveFocus: function (e) {
if (this.getAttribute('href').indexOf('#') > -1) {
e.preventDefault();
let sectionId = this.getAttribute('href'),
section = document.querySelector(`${sectionId}`),
sectionTop = section.getBoundingClientRect().top,
movePosition = (sectionTop + window.pageYOffset) - utils.getNavHeight(),
clickable = section.querySelectorAll('a, button'),
title = section.querySelector('h2') || section.querySelector('h3');
if (!!title) {
let _focusOut = function () {
title.removeAttribute('tabindex');
title.removeEventListener('focusout', _focusOut);
};
title.addEventListener('focusout', _focusOut);
title.setAttribute('tabindex', 0);
title.focus();
} else {
clickable[0].focus();
}
window.scrollTo(0, movePosition);
}
}
};
return {
init: init
}
})();
})();
(function () {
window.flagship = window.flagship || {};
window.flagship.features = window.flagship.features || {};
window.flagship.features.highlightsZone = (function () {
const utils = window.flagship.common.utils;
const resize = window.flagship.common.resize;
const Swiper = window.flagship.Swiper;
let els = {};
let prevDevice;
let swiperObj = {};
let pointerOffset = {};
let currDevice = resize.checkResolution();
let ctaPlayStatus = true;
let scrollProgress = null;
let lowNetwork = document.documentElement.classList.contains('low_network');
const init = function () {
els.section = document.querySelector('.features-highlights');
if (!!els.section) {
setElements();
setProperty();
bindEvents();
}
};
const setElements = function () {
els.mainContainer = els.section.querySelector('.js-highlights-main-container');
els.mainSwiperSlides = els.mainContainer.querySelectorAll('.swiper-slide');
els.mediaWrap = els.mainContainer.querySelectorAll('.features-highlights__content');
els.indication = els.section.querySelector('.common-carousel__pagination');
els.prevArrow = els.mainContainer.parentElement.querySelector('.swiper-button-prev');
els.nextArrow = els.mainContainer.parentElement.querySelector('.swiper-button-next');
els.featureTagging = els.mainContainer.getAttribute('data-tagging-feature');
els.scrollbar = els.section.querySelector('.js-highlights-scrollbar');
};
const setProperty = function () {
els.mainContainer.autoPlay = true;
for (let i = 0; i < els.mediaWrap.length; i++) {
els.mediaWrap[i].isVideo = els.mediaWrap[i].classList.contains('is-video');
els.mediaWrap[i].isImage = els.mediaWrap[i].classList.contains('is-image');
if (els.mediaWrap[i].isVideo) {
els.mediaWrap[i].videoWrap = els.mediaWrap[i].querySelector('.js-video-wrap');
els.mediaWrap[i].video = els.mediaWrap[i].querySelector('.common-video__video');
els.mediaWrap[i].coverImageHighband = els.mediaWrap[i].querySelector('.common-video__cover-image--highband');
els.mediaWrap[i].coverImageLowband = els.mediaWrap[i].querySelector('.common-video__cover-image--lowband');
els.mediaWrap[i].controller = els.mediaWrap[i].querySelector('.js-video-control');
els.mediaWrap[i].controller.video = els.mediaWrap[i].video;
els.mediaWrap[i].progressBar = els.mediaWrap[i].querySelector('.common-video__control-progress-bar');
els.mediaWrap[i].startPoint = els.mediaWrap[i].getAttribute('data-start-point');
els.mediaWrap[i].reversePoint = els.mediaWrap[i].getAttribute('data-reverse-point');
els.mediaWrap[i].moStartPoint = els.mediaWrap[i].getAttribute('data-mo-start-point');
els.mediaWrap[i].moReversePoint = els.mediaWrap[i].getAttribute('data-mo-reverse-point');
} else if (els.mediaWrap[i].isImage) {
els.mediaWrap[i].img = els.mediaWrap[i].querySelector('.js-image-wrap > img');
}
}
};
const bindEvents = function () {
eventList.load();
eventHandler.click();
eventHandler.scroll();
eventHandler.flickSwiper();
resize.add(eventList.resize);
};
const eventHandler = {
flickSwiper: function () {
els.mainContainer.addEventListener('touchstart', function (e) {
pointerOffset.start = null;
pointerOffset.current = null;
pointerOffset.start = e.touches[0].clientX;
els.mainContainer.addEventListener('touchmove', eventList.getPointerMoveSize);
});
els.mainContainer.addEventListener('touchend', function () {
if (pointerOffset.start == null) return;
els.mainContainer.autoPlay = false;
els.mainContainer.removeEventListener('touchmove', eventList.getPointerMoveSize);
});
els.mainContainer.addEventListener('mousedown', function (e) {
pointerOffset.start = null;
pointerOffset.current = null;
pointerOffset.start = e.offsetX;
els.mainContainer.addEventListener('mousemove', eventList.getPointerMoveSize);
});
els.mainContainer.addEventListener('mouseup', function () {
els.mainContainer.autoPlay = false;
els.mainContainer.removeEventListener('mousemove', eventList.getPointerMoveSize);
});
els.mainContainer.addEventListener('mouseleave', function () {
if (pointerOffset.start == null) return;
pointerOffset.start = null;
pointerOffset.current = null;
els.mainContainer.removeEventListener('mousemove', eventList.getPointerMoveSize);
});
els.scrollbar.addEventListener('mousedown', function () {
els.mainContainer.autoPlay = false;
});
els.scrollbar.addEventListener('mouseleave', function () {
els.mainContainer.autoPlay = false;
});
},
click: function () {
for (let i = 0; i < els.mediaWrap.length; i++) {
if (els.mediaWrap[i].isVideo) {
els.mediaWrap[i].controller.addEventListener('click', eventList.clickVideoCta);
els.mediaWrap[i].controller.addEventListener('click', eventList.stopAutoPlay);
}
}
if (els.prevArrow && els.nextArrow) {
els.nextArrow.addEventListener('click', function (e) {
eventList.stopAutoPlay(e);
eventList.swiperArrow(e);
});
els.prevArrow.addEventListener('click', function (e) {
eventList.stopAutoPlay(e);
eventList.swiperArrow(e);
});
}
els.scrollbar.addEventListener('click', function (e) {
eventList.stopAutoPlay(e);
});
},
scroll: function () {
window.addEventListener('scroll', eventList.scroll);
}
}
const eventList = {
load: function () {
swiperEvents.set();
swiperObj.main.init();
eventList.setVideo();
eventList.setScene();
eventList.scroll();
},
resize: function () {
currDevice = resize.checkResolution();
if (prevDevice != currDevice) {
eventList.responsive();
prevDevice = currDevice;
}
},
responsive: function () {
swiperObj.main.slideTo(0, false);
},
setVideo: function () {
for (let i = 0; i < els.mediaWrap.length; i++) {
if (els.mediaWrap[i].isVideo) {
utils.videoHandler({
playType: 'scrollPlay',
startPoint: (currDevice.indexOf('mobile') > -1) ? els.mediaWrap[i].moStartPoint : els.mediaWrap[i].startPoint,
reversePoint: (currDevice.indexOf('mobile') > -1) ? els.mediaWrap[i].moReversePoint : els.mediaWrap[i].reversePoint,
wrap: els.mediaWrap[i].videoWrap,
video: els.mediaWrap[i].video,
controller: els.mediaWrap[i].controller,
playCallback: function () {
setTagging.pause(this.controller);
this.video.timeupdateEvent = function () {
if (this.currentTime > 0) {
if (!this.videoHandler.wrap.classList.contains('is-started', 'is-playing')) {
this.videoHandler.wrap.classList.add('is-started', 'is-playing');
}
eventList.setProgerssDuration(i);
this.removeEventListener('timeupdate', this.timeupdateEvent);
}
}
this.video.addEventListener('timeupdate', this.video.timeupdateEvent);
this.video.removeEventListener('canplay', eventList.playVideoOnce);
},
pauseCallback: function () {
setTagging.play(this.controller);
},
endCallback: function () {
eventList.autoSlideNext(1000);
}
});
}
}
},
autoSlideNext: function (time) {
if (els.mainContainer.autoPlay) {
if (scrollProgress > 40 && scrollProgress < 55) {
clearTimeout(swiperObj.main.videoTiming);
swiperObj.main.videoTiming = setTimeout(() => {
swiperObj.main.slideNext();
}, time);
} else {
clearTimeout(swiperObj.main.videoTiming);
}
}
},
playVideoOnce: function () {
this.play();
},
playVideo: function (video) {
for (let i = 0; i < els.mediaWrap.length; i++) {
if (els.mediaWrap[i].isVideo && video.readyState >= 1) {
video.play();
} else {
video.addEventListener('canplay', eventList.playVideoOnce, {
once: true
});
}
}
},
clickVideoCta: function (e) {
if (e.target == e.currentTarget) {
if (e.currentTarget.video.paused) {
eventList.playVideo(e.currentTarget.video);
ctaPlayStatus = true;
} else {
e.currentTarget.video.pause();
ctaPlayStatus = false;
}
}
},
stopAutoPlay: function (e) {
if (e.target.classList.contains('js-video-control') ||
e.target.classList.contains('swiper-button-next') ||
e.target.classList.contains('swiper-button-prev') ||
e.target.classList.contains('common-carousel__pagination-button') ||
e.target.classList.contains('js-highlights-scrollbar')
) {
els.mainContainer.autoPlay = false;
}
},
swiperArrowVisibility: function () {
let mainSlidesLength = els.mainSwiperSlides.length - 1;
let mainSwiper = swiperObj.main;
let prevArrow = mainSwiper.previousIndex > mainSwiper.realIndex;
let nextArrow = mainSwiper.previousIndex < mainSwiper.realIndex;
if (els.prevArrow && els.nextArrow) {
if (prevArrow) {
if (mainSwiper.realIndex == (mainSlidesLength - 1)) {
if (els.nextArrow.style.display == 'none') els.nextArrow.style.display = '';
} else if (mainSwiper.realIndex == 0) {
els.prevArrow.style.display = 'none';
}
}
if (nextArrow) {
if (mainSwiper.realIndex == 1) {
if (els.prevArrow.style.display == 'none') els.prevArrow.style.display = '';
} else if (mainSwiper.realIndex == mainSlidesLength) {
els.nextArrow.style.display = 'none';
}
}
}
},
swiperArrow: function (e) {
let mainSwiper = swiperObj.main;
let mainSlidesLength = els.mainSwiperSlides.length - 1;
let prevArrow = e.target.classList.contains('swiper-button-prev');
let nextArrow = e.target.classList.contains('swiper-button-next');
if (prevArrow) {
clearTimeout(swiperObj.main.videoTiming);
mainSwiper.slidePrev();
if (mainSwiper.realIndex == 0) {
setTimeout(() => {
els.nextArrow.blur();
els.nextArrow.focus();
}, 300);
}
}
if (nextArrow) {
clearTimeout(swiperObj.main.videoTiming);
mainSwiper.slideNext();
if (mainSwiper.realIndex == mainSlidesLength) {
setTimeout(() => {
els.prevArrow.blur();
els.prevArrow.focus();
}, 300);
}
}
},
scroll: function () {
let isIndex = swiperObj.main.realIndex;
els.section.scene.trackAnimation(function () {
scrollProgress = this.progress;
if (els.mediaWrap[isIndex].isVideo) {
let isMainVideoHandler = els.mediaWrap[isIndex].video.videoHandler;
if (!lowNetwork && ctaPlayStatus) isMainVideoHandler.scrollActive(scrollProgress);
} else if (els.mediaWrap[isIndex].isImage) {
eventList.slideVideoPlay();
}
})
},
slideVideoPlay: function () {
let isIndex = swiperObj.main.realIndex;
if (els.mediaWrap[isIndex].isVideo) {
let isMainVideoHandler = els.mediaWrap[isIndex].video.videoHandler;
isMainVideoHandler.eventList.reset.call(isMainVideoHandler);
els.mediaWrap[isIndex].videoWrap.classList.remove('is-started');
setTimeout(function () {
if (ctaPlayStatus) {
eventList.playVideo(els.mediaWrap[isIndex].video);
setTimeout(function () {
if (els.mainContainer.autoPlay) isMainVideoHandler.controller.blur();
if (els.mainContainer.autoPlay) isMainVideoHandler.controller.focus();
if (isIndex == (swiperObj.main.slides.length)) {
els.mainContainer.autoPlay = false;
}
}, 900);
}
}, 50);
} else if (els.mediaWrap[isIndex].isImage && ctaPlayStatus) {
eventList.autoSlideNext(3000);
}
},
setProgerssDuration: function (index) {
let isDuration = els.mediaWrap[index].video.duration;
if (!!!els.mediaWrap[index].durationSet) {
els.mediaWrap[index].progressBar.style.animationDuration = `${isDuration}s`;
els.mediaWrap[index].durationSet = true;
}
},
setMedia: function (index) {
let videoLength = els.mainSwiperSlides.length - 1;
let isIndex = index + 1;
let loadIndex = isIndex < videoLength ? isIndex : videoLength;
let mainVideoloadComplateLength = els.mainContainer.querySelectorAll('.is-video-load-complete').length - 1;
for (let i = 0; i <= loadIndex; i++) {
if (els.mediaWrap[i].isVideo) {
if (mainVideoloadComplateLength != videoLength && !els.mediaWrap[i].video.classList.contains('is-video-load-complete')) {
if (!els.mediaWrap[i].video.classList.contains('is-mp4video-load-complete')) {
if (!!els.mediaWrap[i].video) videoLoader.setResponsiveMedia([els.mediaWrap[i].video]);
if (!lowNetwork) {
if (!!els.mediaWrap[i].coverImageHighband) imageLoader.setResponsiveMedia([els.mediaWrap[i].coverImageHighband]);
} else {
if (!!els.mediaWrap[i].coverImageLowband) imageLoader.setResponsiveMedia([els.mediaWrap[i].coverImageLowband]);
}
}
}
}
}
},
pauseVideo: function (swiper) {
for (let i = 0; i < swiper.slides.length; i++) {
if (els.mediaWrap[i].isVideo) {
let slideVideo = swiper.slides[i].querySelector('video');
if (!slideVideo.paused) {
slideVideo.pause();
}
}
}
},
getCarouselSizeInfo: function (swiper) {
let slideLength = swiper.slides.length;
let slideWidth = swiper.slides[0].clientWidth;
let slideMargin = parseInt(window.getComputedStyle(swiper.slides[0]).margin.split(' ')[1]);
let slideSize = slideWidth + slideMargin;
let maxMoveSize = ((slideSize * slideLength) - slideMargin) - swiper.wrapperEl.clientWidth;
let viewWidth = swiper.wrapperEl.clientWidth;
let viewLength = parseInt((viewWidth + slideMargin) / slideSize);
let lastBeforeSize = slideLength == 2 ? 0 : Math.abs((maxMoveSize - slideSize)) + Math.abs((viewWidth - slideWidth));
let isMoveSize = Math.abs(parseInt(window.getComputedStyle(swiper.wrapperEl).transform.split(',')[4]));
return {
slideWidth: slideWidth,
slideMargin: slideMargin,
slideSize: slideSize,
maxMoveSize: maxMoveSize,
viewWidth: viewWidth,
viewLength: viewLength,
lastBeforeSize: lastBeforeSize,
isMoveSize: isMoveSize
}
},
setScene: function () {
els.section.scene = SCROLLER({
trackElement: els.section,
useFixed: false
});
},
getPointerMoveSize: function (e) {
if (!!e.touches) {
pointerOffset.current = e.touches[0].clientX;
} else {
pointerOffset.current = e.offsetX;
}
}
}
const swiperEvents = {
set: function () {
if (swiperObj.main == null) {
swiperObj.main = new Swiper(els.mainContainer, {
init: false,
speed: 600,
slidesPerView: 'auto',
scrollbar: {
el: els.scrollbar,
},
pagination: {
el: els.indication,
clickable: true,
renderBullet: function (index, className) {
const slide = this.slides[index];
const slideTitle = slide.getAttribute('data-slide-title') || '';
const tagging = {
omniType: "microsite_gallery",
actionType: "gallery",
contentType: "feature gallery",
taggingValue: els.featureTagging + ":sldr-dots:" + `${index + 1}`
}
this.slideTitle = slideTitle;
return `
`;
}
},
a11y: false,
});
swiperObj.main.on('init', swiperEvents.init);
swiperObj.main.on('slideChange', swiperEvents.slideChange);
swiperObj.main.on('transitionEnd', swiperEvents.transitionEnd);
swiperObj.main.on('paginationUpdate', swiperEvents.paginationUpdate);
}
if (els.prevArrow) {
els.prevArrow.style.display = 'none';
}
},
init: function () {
if (els.prevArrow && els.nextArrow) {
let isNextArrow = this.el.parentElement.querySelector('.swiper-button-next');
let isPrevArrow = this.el.parentElement.querySelector('.swiper-button-prev');
isNextArrow.removeAttribute('aria-label');
isNextArrow.removeAttribute('role');
isPrevArrow.removeAttribute('aria-label');
isPrevArrow.removeAttribute('role');
}
accessibility.slide(this);
},
paginationUpdate: function () {
const bullets = this.pagination.bullets;
const slides = this.slides;
for (let i = 0; i < bullets.length; i++) {
const slideTitle = i < slides.length ? this.slides[i].getAttribute('data-slide-title') : "";
const bullet = bullets[i];
const button = bullet.querySelector('button');
const isActive = bullet.classList.contains('swiper-pagination-bullet-active');
const selected = isActive ? ` ${LOCAL_VARI.selected}` : '';
button.setAttribute('aria-label', `${LOCAL_VARI.slide}${i + 1}${selected}: ${slideTitle}`);
}
},
slideChange: function () {
accessibility.slide(this);
eventList.pauseVideo(this);
if (this.realIndex > 0) eventList.setMedia(this.realIndex);
if (!lowNetwork) eventList.slideVideoPlay();
eventList.swiperArrowVisibility();
},
transitionEnd: function () {
setTimeout(() => {
let carouselInfo = eventList.getCarouselSizeInfo(this);
let lastIndex = this.slides.length - 1;
let lastSlide = this.slides[lastIndex];
let lastBeforeSlide = this.slides[lastIndex - 1];
let secondSlide = this.slides[lastIndex - 2];
let lastSlideIsVideo = lastSlide.querySelector('.features-highlights__content.is-video');
let lastBeforeSlideIsVideo = lastBeforeSlide.querySelector('.features-highlights__content.is-video');
let isIndex = swiperObj.main.previousIndex;
let isMoveSize = currDevice != 'mobile' ? carouselInfo.isMoveSize : carouselInfo.isMoveSize + Math.abs(carouselInfo.slideMargin);
if (els.mediaWrap[isIndex].isVideo) els.mediaWrap[isIndex].video.pause();
if (carouselInfo.lastBeforeSize + (carouselInfo.slideWidth / 2) < isMoveSize && carouselInfo.maxMoveSize - (carouselInfo.slideWidth / 2) <= isMoveSize) {
if (currDevice.indexOf('mobile') > -1) {
eventList.pauseVideo(this);
if (!lowNetwork && ctaPlayStatus && lastSlideIsVideo) {
lastSlide.querySelector('video').play();
}
lastSlide.classList.add('swiper-slide-active');
lastBeforeSlide.classList.add('swiper-slide-prev');
lastSlide.classList.remove('swiper-slide-next');
lastBeforeSlide.classList.remove('swiper-slide-active');
secondSlide.classList.remove('swiper-slide-prev');
if (els.nextArrow) {
if (els.nextArrow.style.display != 'none') {
els.nextArrow.style.display = 'none';
setTimeout(() => {
els.prevArrow.blur();
els.prevArrow.focus();
}, 300);
}
}
utils.offAccessibility(this.slides[lastIndex]);
utils.onAccessibility(this.slides[lastIndex - 1]);
}
} else if (carouselInfo.lastBeforeSize <= carouselInfo.isMoveSize) {
if (currDevice.indexOf('mobile') > -1) {
eventList.pauseVideo(this);
if (!lowNetwork && ctaPlayStatus && lastBeforeSlideIsVideo) {
lastBeforeSlide.querySelector('video').play();
}
lastSlide.classList.add('swiper-slide-next');
lastBeforeSlide.classList.add('swiper-slide-active');
secondSlide.classList.add('swiper-slide-prev');
lastSlide.classList.remove('swiper-slide-active');
lastBeforeSlide.classList.remove('swiper-slide-prev');
if (els.nextArrow) {
if (els.nextArrow.style.display == 'none') els.nextArrow.style.display = '';
}
utils.onAccessibility(this.slides[lastIndex]);
utils.offAccessibility(this.slides[lastIndex - 1]);
}
}
}, 0);
},
destroy: function (swiper) {
if (swiper != null) {
swiper.navigation.destroy(true);
swiper.destroy(true);
swiper = null;
}
}
};
const setTagging = {
play: function (targetController) {
if (targetController.hasAttribute('data-omni')) {
let dataOmni = targetController.getAttribute('data-omni').toLowerCase();
targetController.setAttribute('data-omni', dataOmni.replace('pause', 'play'));
}
if (targetController.hasAttribute('ga-la')) {
let gaLa = targetController.getAttribute('ga-la').toLowerCase();
targetController.setAttribute('ga-la', gaLa.replace('pause', 'play'));
}
},
pause: function (targetController) {
if (targetController.hasAttribute('data-omni')) {
let dataOmni = targetController.getAttribute('data-omni').toLowerCase();
targetController.setAttribute('data-omni', dataOmni.replace('play', 'pause'));
}
if (targetController.hasAttribute('ga-la')) {
let gaLa = targetController.getAttribute('ga-la').toLowerCase();
targetController.setAttribute('ga-la', gaLa.replace('play', 'pause'));
}
}
};
const accessibility = {
slide: function (swiper) {
for (let i = 0; i < swiper.slides.length; i++) {
if (i != swiper.activeIndex) {
utils.onAccessibility(swiper.slides[i]);
} else {
utils.offAccessibility(swiper.slides[i]);
}
}
}
};
return {
init: init,
};
})();
})();
;
(function () {
window.flagship.features.kv = (function () {
let els = {}
const init = function () {
els.section = document.querySelector('.js-kv');
els.hasOffer = document.querySelector('.feature-kv__anchor');
if (!!els.section && !!els.hasOffer) {
setElements();
bindEvents();
}
};
const setElements = function () {
els.kvDropdown = els.section.querySelector('.js-kv-dropdown');
els.kvDropdownItem = els.section.querySelector('.features-kv__description');
els.kvDropdownSpan = els.section.querySelector('.js-button-text');
els.kvDropdownDataOmni = els.kvDropdown.getAttribute('data-omni');
els.kvDropdownGaLa = els.kvDropdown.getAttribute('ga-la');
};
const bindEvents = function () {
eventHandler.click();
eventList.defaultText();
};
const eventHandler = {
click: function () {
els.kvDropdown.addEventListener('click', eventList.click);
}
}
const eventList = {
defaultText: function () {
const openText = els.kvDropdownSpan.getAttribute('data-open-text');
els.kvDropdownSpan.textContent = openText;
},
click: function () {
const openText = els.kvDropdownSpan.getAttribute('data-open-text');
const closeText = els.kvDropdownSpan.getAttribute('data-close-text');
if (els.kvDropdownItem.classList.contains('is-open')) {
els.kvDropdownItem.classList.remove('is-open');
els.kvDropdown.classList.remove('is-active');
els.kvDropdown.setAttribute('ga-la', els.kvDropdownDataOmni.replace('close', 'open'));
els.kvDropdown.setAttribute('data-omni', els.kvDropdownGaLa.replace('close', 'open'));
els.kvDropdownSpan.textContent = openText;
} else {
els.kvDropdownItem.classList.add('is-open');
els.kvDropdown.classList.add('is-active');
els.kvDropdown.setAttribute('ga-la', els.kvDropdownDataOmni.replace('open', 'close'));
els.kvDropdown.setAttribute('data-omni', els.kvDropdownGaLa.replace('open', 'close'));
els.kvDropdownSpan.textContent = closeText;
}
}
};
return {
init: init
}
})();
})();
(function () {
window.flagship.features.proVisual = (function () {
const utils = window.flagship.common.utils;
resize = flagship.common.resize;
let els = {};
let currDevice = resize.checkResolution();
const init = function () {
setElements();
bindEvents();
};
const setElements = function () {
els.cameraSpec = document.querySelectorAll('.features-provisual-engine__spec-item');
};
const bindEvents = function () {
resize.add(eventList.resize);
eventList.setTextScene();
eventList.textMotion();
eventHandler.scroll();
};
const eventHandler = {
scroll: function () {
window.addEventListener('scroll', eventList.textMotion);
}
};
const eventList = {
resize: function (currRes) {
currDevice = currRes;
},
textMotion: function () {
for (let i = 0; i < els.cameraSpec.length; i++) {
els.cameraSpec[i].sceneObj.trackAnimation(function () {
if (10 <= this.progress && this.progress <= 100) {
els.cameraSpec[i].classList.add('is-active');
}
if (this.progress < 0) {
els.cameraSpec[i].classList.remove('is-active');
}
});
}
},
setTextScene: function () {
for (let i = 0; i < els.cameraSpec.length; i++) {
els.cameraSpec[i].sceneObj = SCROLLER({
trackElement: els.cameraSpec[i],
useFixed: false,
useStrictMode: false
});
}
}
};
return {
init: init
}
})();
})();
(function () {
window.flagship.features.howtoPopup = (function () {
const utils = window.flagship.common.utils;
const Swiper = window.flagship.Swiper;
resize = window.flagship.common.resize;
let els = {};
let currDevice = resize.checkResolution();
prevDevice = null,
currOpener = null;
const init = function () {
els.layerPopup = document.querySelector('.js-howto-popup');
if (!!els.layerPopup) {
setElements();
setAttribute();
bindEvents();
eventList.setPopup();
}
};
const setElements = function () {
els.contents = document.querySelector('#contents');
els.openCtas = document.querySelectorAll('.js-howto-popup-opener');
els.openCta = document.querySelectorAll("[data-howto-slide]:not(.js-howto-popup [data-howto-slide])");
// popup content
els.closeCta = document.querySelectorAll('.js-howto-popup-close-cta');
els.ytIframe = els.layerPopup.querySelector('iframe');
els.ytDesc = els.layerPopup.querySelector('.js-howto-popup-youtube-desc');
els.dimmed = els.layerPopup.querySelector('.js-howto-popup-dimmed');
// swiper
els.swiperContainer = els.layerPopup.querySelector('.swiper-container');
els.featureTagging = els.swiperContainer.getAttribute('data-tagging-feature');
els.buttonWrap = els.swiperContainer.querySelectorAll('.swiper-slide');
els.thumbList = els.swiperContainer.querySelectorAll("[data-howto-slide]");
els.arrowWrap = els.swiperContainer.querySelector('.js-howto-popup-arrow-wrap');
els.indication = els.swiperContainer.querySelector('.common-carousel__pagination');
els.scrollbar = els.swiperContainer.querySelector('.js-howto-popup-scrollbar');
};
const setAttribute = function () {
els.openCta.forEach((cta)=> {
const howtoAtrr = cta.getAttribute("data-howto-slide");
els.thumbList.forEach((thumb)=>{
if(thumb.getAttribute("data-howto-slide") === howtoAtrr) {
thumb.openerCta = cta;
thumb.button = thumb.querySelector('button');
thumb.button.openerCta = thumb.openerCta;
cta.thumb = thumb;
}
});
});
};
const bindEvents = function () {
eventHandler.buttonsClick();
resize.add(eventList.resize);
};
const eventHandler = {
buttonsClick: function () {
for (let i = 0; i < els.buttonWrap.length; i++) {
els.buttonWrap[i].button.addEventListener('click', function () {
eventList.setYoutube(els.buttonWrap[i]);
});
}
}
};
const eventList = {
setPopup: function () {
for (let i = 0; i < els.thumbList.length; i++) {
utils.layerPopup({
layerPopup: els.layerPopup,
layerPopupClass: '.js-howto-popup',
openerEvent: {
element: els.openCtas[i],
},
closeCtas: els.closeCta,
dimmed: els.dimmed,
moveTarget: document.documentElement,
contents: els.contents,
show: {
start: function (target) {
let allVideos = document.querySelectorAll('video');
for (let i = 0; i < allVideos.length; i++) {
if (!allVideos[i].paused) allVideos[i].pause();
}
els.layerPopup.removeAttribute('aria-hidden');
els.layerPopup.removeAttribute('tabindex');
els.layerPopup.classList.add('is-init');
currOpener = target.openerCta;
eventList.itemImageLoader();
swiperEventList.activeCheck();
},
end: function (target) {
els.layerPopup.classList.add('is-open');
eventList.setYoutube(target);
}
},
hide: {
start: function () {
els.layerPopup.classList.remove('is-open');
},
end: function (target) {
if (utils.detector.isIosDevice) target.openerCta.style.display = '';
setTimeout(function () {
els.layerPopup.classList.remove('is-init');
eventList.removeYoutube();
accessibility.removeTitle();
swiperEventList.destroy();
els.layerPopup.children[0].scrollTop = 0;
}, 300);
}
}
});
}
},
setYoutube: function (target) {
let opener = target.openerCta,
ytSrc = 'htt' + 'ps://www.youtube.com/embed/' + opener.getAttribute('data-youtube-id') + '?wmode=opaque&rel=0&enablejsapi=1&version=3&autoplay=1',
ytTitle = opener.getAttribute('data-youtube-title'),
ytBlind = opener.querySelector('.blind').innerHTML;
els.ytIframe.setAttribute('src', ytSrc);
els.ytIframe.setAttribute('title', ytTitle);
els.ytDesc.innerHTML = ytBlind;
let oldActive = els.swiperContainer.querySelector('.swiper-slide.is-active');
if (!!oldActive) {
oldActive.classList.remove('is-active');
oldActive.button.removeAttribute('title');
}
opener.thumb.classList.add('is-active');
accessibility.setTitle(opener.thumb);
},
removeYoutube: function () {
els.ytIframe.removeAttribute('src');
els.ytDesc.innerHTML = '';
},
resize: function (currRes) {
currDevice = currRes;
if (prevDevice != currDevice) {
if (els.layerPopup.classList.contains('is-open')) {
swiperEventList.activeCheck();
}
prevDevice = currDevice;
}
},
itemImageLoader: function () {
for (let i = 0; i < els.buttonWrap.length; i++) {
if (!els.buttonWrap[i].querySelector('img').classList.contains('is-img-load-complete')) {
imageLoader.setResponsiveMedia([els.buttonWrap[i].querySelector('img')]);
}
}
}
};
const swiperEventList = {
set: function () {
if (els.swiperContainer.swiper == null) {
els.swiperContainer.swiper = new Swiper(els.swiperContainer, {
init: false,
slidesPerView: 'auto',
scrollbar: {
el: els.scrollbar,
draggable: true
},
pagination: {
el: els.indication,
clickable: true,
renderBullet: function (index, className) {
const slide = this.slides[index];
const slideTitle = slide.getAttribute('data-slide-title') || '';
const tagging = {
omniType: "microsite_gallery",
actionType: "gallery",
contentType: "feature gallery",
taggingValue: els.featureTagging + ":sldr-dots:" + `${index + 1}`
}
this.slideTitle = slideTitle;
return `
`;
}
},
a11y: false,
});
els.swiperContainer.swiper.on('init', swiperEventList.init);
els.swiperContainer.swiper.on('slideChange', swiperEventList.slideChange);
els.swiperContainer.swiper.on('paginationUpdate', swiperEventList.paginationUpdate);
els.swiperContainer.swiper.init();
}
},
destroy: function () {
if (els.swiperContainer.swiper != null) {
els.swiperContainer.swiper.scrollbar.dragEl.style = '';
els.swiperContainer.swiper.scrollbar.destroy(true);
els.swiperContainer.swiper.navigation.destroy(true);
els.swiperContainer.swiper.destroy(true);
els.swiperContainer.swiper = null;
}
},
init: function () {
let self = this,
notification = self.el.querySelector('.swiper-notification');
if (!!notification) self.el.removeChild(notification);
setTimeout(function () {
accessibility.slide();
}, 500);
},
paginationUpdate: function () {
const bullets = this.pagination.bullets;
const slides = this.slides;
let arrSlidesTitle = [];
for (let i = 0; i < slides.length; i++) {
arrSlidesTitle.push(slides[i].dataset.slideTitle)
}
for (let i = 0; i < bullets.length; i++) {
const bullet = bullets[i];
const button = bullet.querySelector('button');
const isActive = bullet.classList.contains('swiper-pagination-bullet-active');
const selected = isActive ? ` ${LOCAL_VARI.selected}` : '';
if (currDevice.indexOf('mobile') > -1) {
button.setAttribute('aria-label', `${LOCAL_VARI.slide}${i + 1}${selected}: ${arrSlidesTitle[i]}, ${arrSlidesTitle[i+1]}`);
} else {
button.setAttribute('aria-label', `${LOCAL_VARI.slide}${i + 1}${selected}: ${arrSlidesTitle[i]}, ${arrSlidesTitle[i+1]}, ${arrSlidesTitle[i+2]}, ${arrSlidesTitle[i+3]}`);
}
}
},
slideChange: function () {
accessibility.slide();
},
activeCheck: function () {
let isSlide = ((currDevice.indexOf('mobile') > -1) && (els.buttonWrap.length >= 3)) ||
((currDevice.indexOf('desktop') > -1 || currDevice == 'tablet') && (els.buttonWrap.length >= 5));
if (isSlide) {
els.scrollbar.style.display = 'block';
swiperEventList.set();
let buttonIndex;
for(let i=0; i < els.buttonWrap.length; i++) {
if (els.buttonWrap[i] === currOpener.thumb) {
buttonIndex = i;
}
}
const changeSlide = buttonIndex - 1;
if (currOpener != null) {
els.swiperContainer.swiper.slideTo(changeSlide, 0);
}
} else {
els.scrollbar.style.display = 'none';
swiperEventList.destroy();
}
}
};
const accessibility = {
setTitle: function (target) {
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
target.button.setAttribute('title', LOCAL_VARI.selected);
} else {
target.button.setAttribute('title', 'Selected');
}
},
removeTitle: function () {
for(let i = 0; i < els.buttonWrap.length; i++) {
if (typeof LOCAL_VARI != 'undefined' && !!LOCAL_VARI) {
els.buttonWrap[i].button.removeAttribute('title', LOCAL_VARI.selected);
} else {
els.buttonWrap[i].button.removeAttribute('title', 'Selected')
}
};
},
slide: function () {
let slidePerviewValue = currDevice.indexOf('mobile') > -1 ? 2 : 4;
let getPerviewIndex = function () {
return slidePerviewValue - 1;
}
for (let i = 0; i < els.swiperContainer.swiper.slides.length; i++) {
if (i >= els.swiperContainer.swiper.activeIndex && i <= (els.swiperContainer.swiper.activeIndex + getPerviewIndex())) {
utils.offAccessibility(els.swiperContainer.swiper.slides[i]);
} else {
utils.onAccessibility(els.swiperContainer.swiper.slides[i]);
}
}
}
};
return {
init: init,
}
})();
})();
flagship.features.initialize = (function () {
window.flagship.common.resize.bindEvent();
const init = function () {
flagship.features.highlightsZone.init();
flagship.features.carousel.init();
flagship.features.clickToVideo.init();
flagship.features.howtoPopup.init();
flagship.features.headline.init();
flagship.features.scrollVideo.init();
flagship.features.aiOverview.init();
flagship.features.faq.init();
flagship.features.colorsViewer.init();
flagship.features.colors.init();
flagship.features.arBanner.init();
flagship.features.accordion.init();
flagship.features.designSpec.init();
flagship.features.display.init();
flagship.features.proVisual.init();
flagship.features.kv.init();
flagship.features.compares.init();
};
return {
init: init
}
})();
flagship.features.initialize.init();
});
Product Registration
Quick and easy product registration.. Receive up-to-date personalized services and tips.
Serial Number/IMEI
Enter your Serial Number/IMEI
QR Scan
Scan the QR code on your products for easy registration.
* This feature can only be supported on Samsung Home Appliances and non-smart B2C monitors.
Enter your Serial Number/IMEI
Quick and easy product registration.
Please enter the 11 or 15- digit number.
This product is already registered. Make sure you entered the right serial number or IMEI.
Type
Subtype
Category
Back view
The serial number and model name are printed on the label located on the lower left side of the device’s exterior, near the front. They are also on a second label, inside the refrigerator compartment on a side wall above the top shelf.
Back view
The serial number and model name are printed on the label located on the lower left side of the device’s exterior, near the front. They are also on a second label, inside the refrigerator compartment on a side wall above the top shelf.
Product registration is almost complete!!
You've entered a valid S/N or IMEI. Now select the model of your product.
Suggested Searches
No result. Please try again.
Galaxy Book3 Ultra
SM-G996BZKGEUA
Serial Number: R3CR508WNAH
The device you are currently using does not support the camera function.