Material Bank logo
Not a registered user? Register
Thank you for using
Material Bank.
kitchen & bath
Discover the best kitchen and bath materials
Curated Collections
Themed material roundups to match any mood.
Saved
Colorway
Delivery
Try before you specify with Lending Library.
Get hands-on with this product for up to 10 days to see if it suits your needs.
We'll send an email when the product is in stock
`; this.toggleMaterials(mit.removeSpecialCharAndSpaces(group), productId); }, toggleMaterials(group, productId) { let el = document.getElementById('material_' + productId), selectedItem = document.querySelector('.' + group + '.item-material.selected'); el.classList.add('selected'); if (selectedItem !== null) { selectedItem.classList.remove('selected'); } }, addToCart(item) { const self = this; if (!item.product_id) { dispatchMessages([ { type: 'error', text: 'Product not found' } ], 5000); } if (this.projectList && this.projectList.length <= 0) { this.dispatchCreateProject(item); } else { this.dispatchAddToCart( item, self.customer.current_project, self.customer.current_project_name, self.customer.current_project_type ); } }, dispatchCreateProject(item) { const self = this; self.openCreateProject(); window.addEventListener("res-create-project", (res)=> { if (res.detail.status === 'success') { self.dispatchAddToCart( item, res.detail['project_id'], res.detail['project_title'], res.detail['project_type'] ); } }); }, openCreateProject() { window.dispatchEvent( new CustomEvent( "open-create-project-modal" ) ); }, isRecommendationsModalEnabled() { const browserStorage = JSON.parse(hyva.getBrowserStorage()?.getItem('recommendations-modal-settings')); if (!browserStorage) { return false; } const allowedGroups = browserStorage.hasOwnProperty('allowed-groups') ? browserStorage['allowed-groups'] : []; return allowedGroups.includes((this.customer.groupId).toString()); }, openRecommendationsModal(data, project, inProgress = false) { const inventoryProduct = this.inventory ? Object.values(this.inventory).find(item => item.product_id == data.productId ) : null; const controlRuleId = data.hasOwnProperty('modal_data') ? data.modal_data?.[0]?.control_rule_id || null : null; const detail = { inProgress: inProgress, serverMessage: data?.message ?? null, isInRealTimeStock: inventoryProduct?.qty > 0, skus: [data.product_id], bagProject: project, addedMaterialImage: data.photo ?? null, controlRuleId: controlRuleId }; window.dispatchEvent( new CustomEvent('open-recommendations-modal', { detail: detail }) ); }, dispatchAddToCart(item, projectId, projectName, projectType) { const self = this, productId = item.product_id; self.disableBtn = true; self.startLoader(true); if (this.isRecommendationsModalEnabled() && !this.blockRecommendationsModal) { const project = { 'project_title': projectName, 'project_type': projectType, 'project_id': projectId }; this.openRecommendationsModal(item, project, true); } let associatedProductData = ''; if (Object.keys(this.parentProduct).length) { associatedProductData = '&related_product[0]=' + this.parentProduct.brand + ': ' + this.parentProduct.name + '&related_product_id[0]=' + this.parentProduct.id; if (typeof pdpUrlParams !== 'undefined') { const listParams = { item_list_id: pdpUrlParams.get('itemListId'), item_list_name: pdpUrlParams.get('itemListName') ? decodeURI(pdpUrlParams.get('itemListName')) : null, index: pdpUrlParams.get('index') ? parseInt(pdpUrlParams.get('index')) : null, }; associatedProductData += `&item_list_id[0]=${listParams.item_list_id}&item_list_name[0]=${listParams.item_list_name}&index[0]=${listParams.index}`; } } fetch(self.addToCartUrl, { method: 'POST', body:'product_id[0]=' + productId + '&' + 'project_id[0]=' + projectId + '&' + 'project_name[0]=' + projectName + '&' + 'project_type[0]=' + projectType + '&' + 'qty[0]=1' + associatedProductData, headers: { 'Content-type': 'application/x-www-form-urlencoded' } }).then(response => { return response.json(); }).then(res => { if (res.status === 'success') { this.gtmTrackAddToCart(item); if (this.isRecommendationsModalEnabled() && !this.blockRecommendationsModal) { const project = { 'project_title': projectName, 'project_type': projectType, 'project_id': projectId }; this.openRecommendationsModal(item, project); window.dispatchEvent(new CustomEvent("block-recommendations-modal")); } else { setTimeout(() => { hyva.setCookie('mage-cache-sessid', '', -1, true); // remove the cookie to force customer section window.dispatchEvent(new CustomEvent("reload-customer-section-data")); }, 1000); self.itemAdded = productId; if (res.hasOwnProperty('message') && res.message) { window.dispatchEvent( new CustomEvent('show-control-rules-modal', { detail: { data: res } }) ); } else { dispatchMessages([ { type: 'success', text: 'Added to cart' } ], 5000); if (self.customer && (self.customer.groupId === 1 || self.customer.groupId === 2)) { /* window.dispatchEvent( new CustomEvent("show-brand-package-text", { detail: { hideAfter: 5000 } }) ); */ } } } } else { dispatchMessages([ { type: 'error', text: res && res.message ? res.message : 'Some error occurred' } ], 5000); } }).finally(() => { self.startLoader(false); self.disableBtn = false; setTimeout(() => { self.itemAdded = false; }, 2000); }); }, loadFavoriteList(items) { this.boardList = items ? items : []; }, getInventory (data) { this.inventory = data; }, responseSaveToBoard(detail) { const self = this; const response = detail.response; if (response.hasOwnProperty('items')) { response.items.forEach((newItem) => { if (self.boardList.find( (item) => item && (Number(item.item_id) === Number(newItem.item_id)) ) === undefined) { self.boardList.push(newItem); } }); clearTimeout(self.timeout); self.disableBtn = false; } else if (response.id) { if (self.boardList.find( (item) => item && (Number(item.item_id) === Number(response.item_id)) ) === undefined) { self.boardList.push(response); } } // force update boardList self.boardList.push({id:1}); }, isSaved(productId) { return this.boardList.find( (item) => item && (Number(item.item_id) === Number(productId)) ) !== undefined; }, openBoardModal(productId) { window.dispatchEvent( new CustomEvent('open-save-to-board-modal', { detail: {itemIds: [productId]} }) ); }, receiveData(data) { if (data.customer?.firstname) { this.cart = data.cart; this.customer = data.customer; this.mapCartItems(data.cart.items); } }, mapCartItems(items) { const self = this; items.forEach(item => { self.cartItemList.push({ 'product_sku' : item.product_sku }); }); }, updateClass(listTitle, index) { if (index > 9) { return 'hide-finishes-on-mobile ' + mit.removeSpecialCharAndSpaces(listTitle); } return mit.removeSpecialCharAndSpaces(listTitle); }, seeMore() { document.getElementsByClassName('hide-finishes-on-mobile').forEach(el => { el.classList.remove('hide-finishes-on-mobile'); }); }, /** Dispatch event to open mini pdp modal **/ openMiniPdp(productId) { window.dispatchEvent( new CustomEvent( "open-mini-pdp", { detail: productId } ) ); }, getProjects(projectList) { this.projectList = projectList; }, startLoader(isLoading) { window.dispatchEvent( new CustomEvent( "start-loader", { detail: isLoading } ) ); }, gtmTrackAddToCart(item) { const listParams = { item_list_id: pdpUrlParams.get('itemListId'), item_list_name: pdpUrlParams.get('itemListName') ? decodeURI(pdpUrlParams.get('itemListName')) : null, index: pdpUrlParams.get('index') ? parseInt(pdpUrlParams.get('index')) : null, }; item = this.prepareGTMItemData({ ...item, ...listParams }); mitGTM.addToCart([item], 'Product detail page'); }, prepareGTMItemData(item) { const itemCategory = []; const itemCategory2 = []; const itemCategory3 = []; if (item.hasOwnProperty('taxonomy')) { const taxonomies = item.taxonomy.split('|'); for (const taxonomy of taxonomies) { const splittedTaxonomy = taxonomy.split('.'); if (splittedTaxonomy[0] && !itemCategory.includes(splittedTaxonomy[0])) { itemCategory.push(splittedTaxonomy[0]); } if (splittedTaxonomy[1] && !itemCategory2.includes(splittedTaxonomy[1])) { itemCategory2.push(splittedTaxonomy[1]); } if (splittedTaxonomy[2] && !itemCategory3.includes(splittedTaxonomy[2])) { itemCategory3.push(splittedTaxonomy[2]); } } } return { 'item_name': item.hasOwnProperty('title') ? item.title : null, 'item_id': item.hasOwnProperty('sku') ? item.sku : null, 'item_brand': item.hasOwnProperty('brand') ? item.brand : null, 'item_type': mitGTM.getItemType(item), 'item_category': itemCategory.join(', '), 'item_category2': itemCategory2.join(', '), 'item_category3': itemCategory3.join(', '), 'item_variant': item.hasOwnProperty('color') ? item.color : null, 'item_list_id': item?.item_list_id || null, 'item_list_name': item?.item_list_name || null, 'index': item?.index || null, 'quantity': 1, 'price': 0, } }, /* MB activeChild Param */ preselectActiveChild() { let productId = mit.getUrlParameter('activeChild'), self = this; if (!productId && typeof window.productConfigurableJson !== 'undefined') { productId = window.productConfigurableJson['first_child_id']; } if ( productId && typeof window.productConfigurableJson !== 'undefined' && window.productConfigurableJson['child_list'][productId] ) { const parentProduct = window.productConfigurableJson['child_list'][productId]; this.parentProduct = { id: parentProduct.product_id.value, name: parentProduct.name.value, brand: parentProduct.manufacturer.value, }; } }, } }
Select an Associated Product
Sign Out
My Profile
Contact Info
- First Name
- Last Name
- Office Phone
- Mobile Phone
- Company Name
- Website
- Company Type
- Primary Area of Specialization
- Job Type
- University/School Name
- University/School Website Link
- Position
- University/School Program/Degree
- Your anticipated graduation
- Country
- City
- Zip
Preferences
- Preferred Contact Method
-
Urgent Order Notification
Receive urgent text notifications related to your order
Edit Profile
You entered
We Recommend