news

Saturday, September 11, 2021

Victoria Myers

Good morning lovely yarners!  I hope you are all enjoying this lovely cool morning and settling into fall routines!  In all honestly, I sort of hate to write things on this particular day, but as this is a Saturday tradition, I thought I had better not skip.  And I have some time sensitive stuff to say!

FIRST - did you know that it is 105 days until Christmas?  OH MY!  It really like to sneak up on us!  But, this means that our 10Row/100 Day Challenge will be starting in just 5 days!  I can't seem to attach a file to this post, so if you can't come in before Thursday to pick up your sheet, drop me an email and I'll email you a PDF!  This is a super fun event that keeps people VERY productive through the busy season!  You'll have so much fun!

Next - happily still celebrating our 15 years in business - Noro Taiyo is now BOGO FREE off its already discounted price with code TAIYOBOGO  This is just through Friday the 17th or while supplied last.  We've had Taiyo in the shop for almost all of those 15 years, but since Noro has been bringing out some AMAZING yarns lately, we thought it was time to give a nice little kiss goodbye to Taiyo.  Get it fast!

We also brought in a boatload of NEW MAD BALLS this week!  Don't forget - each Mad Ball comes with a download code for 12 FREE patterns!!  Check them out!

There are a couple of spots still open in our Moebius Cast on class that is next weekend.  Just 2 I think, so be quick!

And lastly, we received some gorgeous Lucky from Trendsetter this week - I didn't get it online yet (busybusy morning) but this is a GORGEOUS yarn!  HUGE 240 gram balls of a fluffy chainette ply - I LOVE it!  Come and see!  Ok - I went back and rushed - here it is!

Island Yarn 
189 Main Street
Maynard, MA  01754
Hours: Wednesday to Saturday, 12-5

Leave a Comment

Please note, comments must be approved before they are published

const selectVariantByClickingImage = { // Create variant images from productJson object _createVariantImage: function (product) { const variantImageObject = {}; product.variants.forEach((variant) => { if ( typeof variant.featured_image !== 'undefined' && variant.featured_image !== null ) { const variantImage = variant.featured_image.src .split('?')[0] .replace(/http(s)?:/, ''); variantImageObject[variantImage] = variantImageObject[variantImage] || {}; product.options.forEach((option, index) => { const optionValue = variant.options[index]; const optionKey = `option-${index}`; if ( typeof variantImageObject[variantImage][optionKey] === 'undefined' ) { variantImageObject[variantImage][optionKey] = optionValue; } else { const oldValue = variantImageObject[variantImage][optionKey]; if (oldValue !== null && oldValue !== optionValue) { variantImageObject[variantImage][optionKey] = null; } } }); } }); return variantImageObject; }, _updateVariant: function (event, id, product, variantImages) { const arrImage = event.target.src .split('?')[0] .replace(/http(s)?:/, '') .split('.'); const strExtention = arrImage.pop(); const strRemaining = arrImage.pop().replace(/_[a-zA-Z0-9@]+$/, ''); const strNewImage = `${arrImage.join('.')}.${strRemaining}.${strExtention}`; if (typeof variantImages[strNewImage] !== 'undefined') { product.variants.forEach((option, index) => { const optionValue = variantImages[strNewImage][`option-${index}`]; if (optionValue !== null && optionValue !== undefined) { const selects = document.querySelectorAll('#'+ id + ' [class*=single-option-selector]'); const options = selects[index].options; for (let option, n = 0; (option = options[n]); n += 1) { if (option.value === optionValue) { selects[index].selectedIndex = n; selects[index].dispatchEvent(new Event('change')); break; } } } }); } }, _selectVariant: function() { const productJson = document.querySelectorAll('[id^=ProductJson-'); if (productJson.length > 0) { productJson.forEach((product) => { const sectionId = product.id.replace("ProductJson-", "shopify-section-"); const thumbnails = document.querySelectorAll('#'+ sectionId + ' img[src*="/products/"]'); if (thumbnails.length > 1) { const productObject = JSON.parse(product.innerHTML); const variantImages = this._createVariantImage(productObject); // need to check variants > 1 if (productObject.variants.length > 1) { thumbnails.forEach((thumbnail) => { thumbnail.addEventListener('click', (e) => this._updateVariant(e, sectionId, productObject, variantImages), ); }); } } }); } }, }; if (document.readyState !== 'loading') { selectVariantByClickingImage._selectVariant(); } else { document.addEventListener( 'DOMContentLoaded', selectVariantByClickingImage._selectVariant(), ); }