Comments

4 comments

  • Avatar
    Frank (Workflowy Support)

    Hi Tuang,

    Please copy the below code and replace the existing code in the Tampermonkey WorkFlowyStylableTags script with it:

     

    // ==UserScript==
    // @name WorkflowyStylableTags (II)
    // @description Gives each tag it's own CSS style, so you can style them with CSS.
    // @author LukeMT
    // @include http*://*workflowy.com/*
    // @version 1.1
    // ==/UserScript==
    String.prototype.endsWith = function(suffix) {
    return this.indexOf(suffix, this.length - suffix.length) !== -1;
    };
    var customClasses = function(index, old){
    var classes = old.split(" ");
    var custom = [];
    for( i = 0; i < classes.length; i++){
    if(classes[i].endsWith("-proj")){ custom.push(classes[i]);}
    }
    return custom.join(" ");
    };
    var StylableTagsCounter = 1;
    setInterval(function(){
    StylableTagsCounter ++;
    if( StylableTagsCounter >= 3){
    $('.project').removeClass(customClasses);
    $('.pageContainer').removeClass(customClasses);
    StylableTagsCounter = 0;
    }
    $('span > .contentTagText').map( function(){
    var x = $(this).text().toLowerCase();
    $(this).closest('.project').addClass(x+"-proj");}
    );
    },10);

     

    2
    Comment actions Permalink
  • Avatar
    James

    Thanks, I had the same problem and I copied this script and it worked. Actually I first removed it from Firefox and then added it again.

    0
    Comment actions Permalink
  • Avatar
    Tuang Dheandhanoo

    @Frank It's working now. Thank you so much :D

    0
    Comment actions Permalink
  • Avatar
    Frank (Workflowy Support)

    All of my protégés are most welcome! 

     

    0
    Comment actions Permalink

Please sign in to leave a comment.