Check Latest Jewelry Collections

Oh what a feeling!

Show me the Collection...

 

 

// Define an array of collections const collections = ['Collection A', 'Collection B', 'Collection C']; // Function to generate a random mystery box code function generateMysteryBoxCode() { // Generate a random integer between 0 and the length of the collections array const randomIndex = Math.floor(Math.random() * collections.length); // Use the random index to select a collection const collection = collections[randomIndex]; // Generate a random 4-digit code const code = Math.floor(Math.random() * 9000) + 1000; // Return the code and the associated collection return `${collection} - ${code}`; } // Add a click event listener to the "Draw" button document.getElementById('draw-btn').addEventListener('click', function() { // Generate a mystery box code const mysteryBoxCode = generateMysteryBoxCode(); // Display the code in the "mystery-box" paragraph element document.getElementById('mystery-box').textContent = mysteryBoxCode; });

Your title

// Define an array of collections const collections = ['Collection A', 'Collection B', 'Collection C']; // Function to generate a random mystery box code function generateMysteryBoxCode() { // Generate a random integer between 0 and the length of the collections array const randomIndex = Math.floor(Math.random() * collections.length); // Use the random index to select a collection const collection = collections[randomIndex]; // Generate a random 4-digit code const code = Math.floor(Math.random() * 9000) + 1000; // Return the code and the associated collection return `${collection} - ${code}`; } // Add a click event listener to the "Draw" button document.getElementById('draw-btn').addEventListener('click', function() { // Generate a mystery box code const mysteryBoxCode = generateMysteryBoxCode(); // Display the code in the "mystery-box" paragraph element document.getElementById('mystery-box').textContent = mysteryBoxCode; });

Featured Rings

View all

Newsletter

A short sentence describing what someone will receive by subscribing