Daily Stories
const categories = [
“PSA”,”Calendar”,”Careers”,”Caregivers”,”Cars”,”Charity”,
“Churches”,”Citizens”,”Classifieds”,”Classrooms”,”Commerce”,
“Community”,”Construction”,”Cool Spots”,”Cosmetologists”,
“Cottages”,”Coupons”,”Courier News”,”Crafts”,”Cruises”,
“Cuisine”,
“Available”,”Available”,”Available”,
“Available”,”Available”,”Available”,
“Available”,”Available”,”Available”
];
const communities = [
“Chassahowitzka 48”,
“Homosassa 46”,
“Homosassa Springs 48”,
“Ozello 29”,
“Crystal River 28”,
“Red Level 49”,
“Dunnellon 33”,
“Citrus Springs 34”,
“Pine Ridge 65”,
“Lecanto 61”,
“Hernando 42”,
“Inverness 53”,
“The Cove 50”,
“Pleasant Grove 52”,
“Floral City 36”,
“OPEN”
];
const app = document.getElementById(“ccc-app”);
const page = document.createElement(“div”);
page.className = “ccc-page”;
communities.forEach(community => {
const town = document.createElement(“div”);
town.className = “ccc-town”;
const heading = document.createElement(“h3”);
heading.textContent = community;
const ribbon = document.createElement(“div”);
ribbon.className = “ccc-ribbon”;
categories.forEach(category => {
const slugCommunity = community.toLowerCase().replace(/\s+/g,”-“);
const slugCategory = category.toLowerCase().replace(/\s+/g,”-“);
const slot = document.createElement(“a”);
slot.className = “ccc-slot”;
slot.href = `/ccc/${slugCommunity}/${slugCategory}`;
const media = document.createElement(“div”);
media.className = “media”;
media.textContent = “image / video”;
const label = document.createElement(“div”);
label.className = “label”;
label.textContent = category;
slot.appendChild(media);
slot.appendChild(label);
ribbon.appendChild(slot);
});
town.appendChild(heading);
town.appendChild(ribbon);
page.appendChild(town);
});
app.appendChild(page);
