mozilla
Your Search Results

    Template:cssinitialshorthand

    <%
    // $0 is the name of the definition (property or data type), without < > or ''
    // $1 is a string containing the list of the associated longhand properties
     
    // Read the word of the parameters and store them in an array
    var values = $1.split(" ");  // Array
    
    // wiki.pageIgnoreCacheControl forces a fetch from the last cached rendering 
    // of the page, regardless of shift-refresh
    var page = wiki.pageIgnoreCacheControl(mdn.localString({
        "en-US": "en-US/docs/Web/CSS/CSS_values_syntax",
        "de": "de/docs/CSS/CSS_werte_syntax",
        "fr": "fr/docs/Web/CSS/CSS_values_syntax",
        "ja": "ja/docs/Web/CSS/CSS_values_syntax"
    }));
    
    var s_str = mdn.localString({
        "en-US": [
          "the concatenation of the initial values of its longhand properties:",
          "is itself a shorthand, its initial value is the concatenation of its own longhand properties"
        ],
        "de": [
          "Die Verkettung der Initialwerte der Landform Eigenschaften:",
          "Ist selbst eine Kurzform, ihr Initialwert ist die Verkettung ihrer Langform Eigenschaften"
        ],
        "ja": [
          "以下の各ロングハンドプロパティの初期値が使用されます:",
          "is itself a shorthand, its initial value is the concatenation of its own longhand properties"
        ],
        "fr": [
          "La concaténation des valeurs initiales des propriétés associées :",
          "est elle-même une propriété raccourcie. Sa valeur initiale est la concaténation de ses propres propriétés associées"
        ]
    });
    
    var s_result = s_str[0] + '<ul>';
    var s_desc = "";
    
    for (var i = 0, len = values.length; i < len; i++) {
        var re = new RegExp("<\\s*(span|div)\\s+id\\s*=\\s*"+'"initial-'+values[i]+'"'+"[^>]*>(.*)<\\s*/\\s*(span|div)\\s*\\>","igm");
        var prop = re.exec(page);
    
        if (prop) {
            s_desc = prop[2];
        } else {    // If not found, it is a shorthand itself
            s_desc = s_str[1];
        }
    
        s_result += '<li><code>' + values[i] + '</code>: ' + s_desc +'</li>';
    }
    s_result += '</ul>';
    
    var result = '<span id="initial-' + $0 + '">' + s_result + '</span>';
    
    %><%- result %>
    Search for pages that use Template:cssinitialshorthand to see example use cases and how many pages use this macro.

    Document Tags and Contributors

    Contributors to this page: lorchard_mozilla, teoli, ethertank, Marsf, Sebastianz, Jeremie
    Last updated by: Sebastianz,