jquery-bracket icon indicating copy to clipboard operation
jquery-bracket copied to clipboard

Is there a way to get round header and info?

Open lorenanderson-itrellis opened this issue 7 years ago • 3 comments

At the top of each round, is there a way to insert a title and other info such as dates?

I am looking for something like: "Round 1" "Matches happen between Mon. and Wed."

Similar to this photo: https://res.cloudinary.com/cmgverticals/image/upload/f_auto,q_80/v1491278076/ncaa_bracket_final_piwaax.jpg

lorenanderson-itrellis avatar Aug 22 '18 15:08 lorenanderson-itrellis

Did anyone ever figure this out?

hansoncaleb avatar Oct 10 '19 22:10 hansoncaleb

I was able to do this

function infoWhereWhen() {
      const matches = document.getElementsByClassName("teamContainer");
      const tijdenknockout = !{JSON.stringify(tijdenknockout)};
      const veldnamen = !{JSON.stringify(veldnamen)};

      for (let i = 0; i < matches.length; i++) {

        const div = document.createElement("div");
        div.style.position = "relative"
        div.style.width = "0"
        div.style.height = "0"

        const label = document.createElement("label");
        label.style.position = "absolute"
        label.style.width = "250px"
        label.style.fontSize = "85%"
        label.style.left = "10px"
        label.style.top = "-20px"
        label.style.padding = "0"
        label.style.color = 'rgba(0,0,0,0.6)'
        label.innerHTML = veldnamen[i] + "&nbsp&nbsp|&nbsp&nbsp" + tijdenknockout[i];

        div.append(label)
        matches[i].append(div)
      }

}

I had to mess around for a bit before i was happy with the result tho... You can view the result here Screenshot from 2022-05-21 20-56-41

RenautMestdagh avatar May 21 '22 18:05 RenautMestdagh