1. This area is dedicated to the support of our xF1 add-ons. For xF2, please use the dedicated area: HERE.
Dismiss Notice
We have just posted about our product policy for XF2.
Click HERE to view it.

Support Bracket/Tournament List colour problems.

Discussion in 'Tournament' started by Hecter, Aug 4, 2018.

  1. MtoR

    MtoR Freaky Coder
    Staff Member

    Joined:
    Nov 14, 2015
    Messages:
    4,302
    Likes Received:
    646
    Ok, in fact I looked into the doc of the script and there are parameters to achieve what you did instead of the css.

    So I would recommend you to revert the modification and edit the xfa_tourn_tournament_bracket template.

    Search for:
    Code:
        $('.tournamentBracket').bracket({
            init: bracketData,
            centerConnectors: true,
            skipConsolationRound: {xen:if '{$tournament.third_place}', false, true},
            skipGrandFinalComeback:  {xen:if '{$tournament.mode} == "consolation"', true, false},
            <xen:if is="{$canEditTournament}">
            save: function(){}, /* without save() labels are disabled */
            </xen:if>
            decorator: {edit: edit_fn, render: render_fn}
        });
    
    You would need to add additional parameters to the call, eg.:
    Code:
        $('.tournamentBracket').bracket({
            init: bracketData,
            teamWidth: 60,
            scoreWidth: 20,
            matchMargin: 10,
            roundMargin: 50,
            centerConnectors: true,
            skipConsolationRound: {xen:if '{$tournament.third_place}', false, true},
            skipGrandFinalComeback:  {xen:if '{$tournament.mode} == "consolation"', true, false},
            <xen:if is="{$canEditTournament}">
            save: function(){}, /* without save() labels are disabled */
            </xen:if>
            decorator: {edit: edit_fn, render: render_fn}
        });
    
    These are some default parameters given on the script description page, you have to adapt them to your needs.

    Clément
     
  2. MtoR

    MtoR Freaky Coder
    Staff Member

    Joined:
    Nov 14, 2015
    Messages:
    4,302
    Likes Received:
    646
    If you confirm it works might be able to provide that as style properties in a new version.
     
  3. Hecter

    Hecter Member

    Joined:
    Jan 16, 2016
    Messages:
    83
    Likes Received:
    5
    Worked perfectly, it could do with some tidying but for now I am more than happy to use as is.
     
  4. MtoR

    MtoR Freaky Coder
    Staff Member

    Joined:
    Nov 14, 2015
    Messages:
    4,302
    Likes Received:
    646
    I should have read the doc in the first place ^^
     
    Hecter likes this.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice