Dash Keyboard

$42.00
$45.00 حفظ $3.00
بيع بالتجزئة $45.00
people are viewing this right now
Free worldwide shipping
Free returns
Sustainably made
Secure payments
وصف
The minimalist Dash Sleeve for Magic Keyboard protects your keyboard in transit or when not in use. Durable exterior, super-soft interior give your keyboard a safe, snug fit. Convenient back mesh pocket for cable and cords.
حدد المنتج
محدد 0 العنصر (s)
Blue
Black
Red
Grey
function updateQueryStringParameter(uri, key, value) { if(!value) { return uri; } let re = new RegExp('([?&])' + key + '=.*?(&|$)', 'i'); let separator = uri.indexOf('?') !== -1 ? '&' : '?'; return uri.match(re) ? uri.replace(re, '$1' + key + '=' + value + '$2') : uri + separator + key + '=' + value; } function addEventListenerRedirect(data) { if (data.type === 'checkout_redirect_login') { let { pathname, search } = window.location; let order_id = data.order_id || ''; let newSearch = updateQueryStringParameter(search, 'order_id', order_id); let return_Url = `${pathname}${newSearch}`; let redirect_Url = `${data.url}?_returnUrl=${encodeURIComponent(return_Url)}`; return Promise.resolve(redirect_Url) } if (data.type === 'checkout_redirect') { return Promise.resolve(data.url); } if (data.type === 'checkout_reload') { let { pathname } = window.location; return Promise.resolve(pathname); } return Promise.reject({}); } function addEventListenerMask(data) { if (data.type === 'checkout_mask' && data.show_mask) { return Promise.resolve({}); } return Promise.reject({}); } function addEventListenerMaskClose(data) { if (data.type === 'checkout_mask' && !data.show_mask) { return Promise.resolve({}); } return Promise.reject({}); } function handleUpdateCheckout(data) { let message = { type:'theme_variant_list_update' } return Promise.resolve(message); } function addEventListeneFullFixed(data) { if (data.type === 'checkout_full_screen') { return Promise.resolve(data.is_full_screen); } return Promise.reject({}); } function addEventListenerTproduct(data) { if (data.type === 'checkout_kick_items') { return Promise.resolve(data); } return Promise.reject({}); } function handleCheckOrderIdChange(data) { if ((data.data && data.data.order_token) || data.order_id) { let new_order_token = (data.data && data.data.order_token) || data.order_id ; let checkout_iframe_template = document.getElementById('checkout_iframe_template'); let old_oder_token = checkout_iframe_template.getAttribute('data-order-id'); if (!old_oder_token) { checkout_iframe_template.setAttribute('data-order-id', new_order_token); } let isRerenderCheckout = new_order_token == old_oder_token; let obj = { order_id: new_order_token, once: isRerenderCheckout } if (!isRerenderCheckout) { checkout_iframe_template.setAttribute('data-order-id', new_order_token); } return Promise.resolve(obj); } return Promise.reject(); } function addEventListeneScollToCheckout(data) { if (data.type === 'scroll_to_checkout') { return Promise.resolve(); } return Promise.reject(); } function handleGetOrderInfo(data) { if (data.order_id) { let api = `/api/checkout/order/info?order_id=${data.order_id}`; return Promise.resolve(api); } return Promise.reject({}); } function handleToggleStickyCheckoutBtn(data) { if (data.type === 'checkout_submit_visible') { return Promise.resolve(!data.visible); } return Promise.reject({}); } function handleSetStickyCheckoutBtnDisabled(data) { if (data.type === 'checkout_submit_disable') { return Promise.resolve(data.disable); } return Promise.reject({}); } function stickyCheckoutBtnPostMessage(data) { let message = { type: 'theme_submit_click' } return Promise.resolve(message); } function handleShowChecktoutToast(data) { if (data.type === 'checkout_toast') { return Promise.resolve(data.message); } return Promise.reject({}); } exportFunction('handleGetOrderInfo', handleGetOrderInfo) exportFunction('handleCheckOrderIdChange', handleCheckOrderIdChange) exportFunction('addEventListenerRedirect', addEventListenerRedirect) exportFunction('addEventListenerMask', addEventListenerMask) exportFunction('addEventListenerMaskClose', addEventListenerMaskClose) exportFunction('handleUpdateCheckout', handleUpdateCheckout) exportFunction('addEventListeneFullFixed', addEventListeneFullFixed) exportFunction('addEventListenerTproduct', addEventListenerTproduct) exportFunction('addEventListeneScollToCheckout', addEventListeneScollToCheckout) exportFunction('handleToggleStickyCheckoutBtn', handleToggleStickyCheckoutBtn) exportFunction('handleSetStickyCheckoutBtnDisabled', handleSetStickyCheckoutBtnDisabled) exportFunction('stickyCheckoutBtnPostMessage', stickyCheckoutBtnPostMessage) exportFunction('handleShowChecktoutToast', handleShowChecktoutToast)
function handleSetObserver() { let iframeEle = document.getElementById('checkout_iframe'); var observer = new MutationObserver((mutations) => { let is_dom_change = false mutations.forEach((item) => { if (item.type === 'childList') { is_dom_change = true } }); const clientHeight = iframeEle.contentWindow.document.body.clientHeight; if (is_dom_change) { iframeEle.style.height = `${clientHeight ? (clientHeight) : 1400 }px`; } }); const options = { "childList" : true, "attributes" : false, "characterData" : false, "subtree" : true, "attributeOldValue" : false, "characterDataOldValue" : false }; iframeEle.contentWindow.addEventListener('DOMContentLoaded', function(e) { try { if (iframeEle.contentWindow.document.readyState === "interactive") { observer.observe(iframeEle.contentWindow.document, options); const iframe = document.getElementById("checkout_iframe"); iframe.addEventListener("load", function(e) { if (iframe.contentWindow.location.href.indexOf('thank_you') > -1) { window.location.href = iframe.contentWindow.location.href; } }); } } catch (err) {} }); } function handleAddListenerCheckoutIframe() { let checkout_iframe_render_elem = document.getElementById('checkout_iframe_render_1634493037563'); checkout_iframe_render_elem.addEventListener('spz:dom-update', (e) => { handleSetObserver(); }) } handleAddListenerCheckoutIframe();