Unverified Commit f6d94dc0 authored by Cameron Ball's avatar Cameron Ball
Browse files

MDL-57321 theme_boost: Consistently apply attributes on elements

parent 0f59b6dd
......@@ -38,5 +38,5 @@
}
}}
<div class="form-text defaultsnext">
<input type="text" name="{{name}}" value="{{value}}" size="{{size}}" id="{{id}}" class="{{#forceltr}}text-ltr{{/forceltr}}" {{#attributes}} {{name}}="{{value}}"{{/attributes}}>
<input type="text" name="{{name}}" value="{{value}}" size="{{size}}" id="{{id}}" class="{{#forceltr}}text-ltr{{/forceltr}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
</div>
......@@ -52,11 +52,11 @@
}
}}
{{^disabled}}
<a href="{{{url}}}" id="{{id}}" class="{{classes}}" {{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}} {{/attributes}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{{text}}}</a>
<a href="{{{url}}}" id="{{id}}" class="{{classes}}"{{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{{text}}}</a>
{{#hasactions}}
{{> core/actions }}
{{/hasactions}}
{{/disabled}}
{{#disabled}}
<span class="currentlink {{classes}}" {{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}} {{/attributes}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{{text}}}</span>
<span class="currentlink {{classes}}"{{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{{text}}}</span>
{{/disabled}}
......@@ -30,10 +30,10 @@
}
}
}}
<div class="{{classes}}" {{#attributes}}{{name}}="{{value}}"{{/attributes}}>
<div class="{{classes}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
{{#primary}}
<ul class="{{classes}}" {{#attributes}}{{name}}="{{value}}"{{/attributes}}>
<ul class="{{classes}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
{{#prioritise}}<li role="presentation">{{> core/action_menu_trigger }}</li>{{/prioritise}}<!--
......@@ -46,7 +46,7 @@
{{/primary}}
{{#secondary}}
<ul class="{{classes}}" {{#attributes}}{{name}}="{{value}}"{{/attributes}}>
<ul class="{{classes}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
{{#items}}<li role="presentation">{{> core/action_menu_item }}</li>{{/items}}
</ul>
{{/secondary}}
......
......@@ -29,7 +29,7 @@
}
}}
{{^disabled}}
<a href="{{url}}" class="{{classes}}" {{#attributes}}{{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}} {{#showtext}}aria-labelledby="actionmenuaction-{{instance}}"{{/showtext}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{#showtext}}<span class="menu-action-text" id="actionmenuaction-{{instance}}">{{{text}}}</span>{{/showtext}}</a>
<a href="{{url}}" class="{{classes}}"{{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}} {{#showtext}}aria-labelledby="actionmenuaction-{{instance}}"{{/showtext}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{#showtext}}<span class="menu-action-text" id="actionmenuaction-{{instance}}">{{{text}}}</span>{{/showtext}}</a>
{{/disabled}}
{{#disabled}}
<span class="currentlink" role="menuitem">{{#icon}}{{>core/pix_icon}}{{/icon}}{{{text}}}</span>
......
......@@ -40,4 +40,4 @@
}
}}
<img {{#attributes}}{{name}}="{{value}}" {{/attributes}}/>
\ No newline at end of file
<img{{#attributes}} {{name}}="{{value}}"{{/attributes}}/>
\ No newline at end of file
......@@ -31,7 +31,7 @@
}
}}
<label for="{{id}}" class="accesshide">{{label}}</label>
<select name="{{name}}" id="{{id}}" {{#attributes}} {{name}}="{{value}}"{{/attributes}}>
<select name="{{name}}" id="{{id}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
{{#options}}
<option value="{{value}}" {{#selected}}selected{{/selected}}>{{name}}</option>
{{/options}}
......
......@@ -88,7 +88,7 @@
<input type="hidden" name="{{name}}" value="{{value}}">
{{/params}}
{{#label}}
<label for="{{id}}" {{#labelattributes}}{{name}}="{{value}}" {{/labelattributes}}>
<label for="{{id}}"{{#labelattributes}} {{name}}="{{value}}"{{/labelattributes}}>
{{{label}}}
</label>
{{/label}}
......
......@@ -27,7 +27,7 @@
<input type="hidden" name="sesskey" value="{{sesskey}}">
<div class="form-group">
{{#label}}
<label for="{{id}}" {{#labelattributes}}{{name}}="{{value}}" {{/labelattributes}}>
<label for="{{id}}"{{#labelattributes}} {{name}}="{{value}}"{{/labelattributes}}>
{{label}}
</label>
{{/label}}
......
......@@ -30,10 +30,10 @@
}
}
}}
<div class="action-menu {{classes}}" {{#attributes}}{{name}}="{{value}}"{{/attributes}}>
<div class="action-menu {{classes}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
{{#primary}}
<div class="{{classes}}" {{#attributes}}{{name}}="{{value}}"{{/attributes}}>
<div class="{{classes}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}>
{{#prioritise}}{{> core/action_menu_trigger }}{{/prioritise}}{{!
......
......@@ -27,7 +27,7 @@
}
}}
{{^disabled}}
<a href="{{url}}" class="{{classes}}" {{#attributes}}{{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}} {{#showtext}}aria-labelledby="actionmenuaction-{{instance}}"{{/showtext}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{#showtext}}<span class="menu-action-text" id="actionmenuaction-{{instance}}">{{{text}}}</span>{{/showtext}}</a>
<a href="{{url}}" class="{{classes}}"{{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}} {{#showtext}}aria-labelledby="actionmenuaction-{{instance}}"{{/showtext}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{#showtext}}<span class="menu-action-text" id="actionmenuaction-{{instance}}">{{{text}}}</span>{{/showtext}}</a>
{{/disabled}}
{{#disabled}}
<span class="currentlink" role="menuitem">{{#icon}}{{>core/pix_icon}}{{/icon}}{{{text}}}</span>
......
......@@ -20,9 +20,9 @@
<span class="dropdown">
<a href="#" class="dropdown-toggle" id="dropdown-{{instance}}" title="{{title}}" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">{{{actiontext}}}{{{menutrigger}}}{{#icon}}{{> core/pix_icon}}{{/icon}}{{#rawicon}}{{{.}}}{{/rawicon}}{{#menutrigger}}<b class="caret"></b>{{/menutrigger}}</a>
{{#secondary}}
<div class="dropdown-menu dropdown-menu-right {{classes}}" {{#attributes}}{{name}}="{{value}}"{{/attributes}} aria-labelledby="dropdown-{{instance}}">
<span class="dropdown-menu dropdown-menu-right {{classes}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}} aria-labelledby="dropdown-{{instance}}">
{{#items}}{{!
}}{{#actionmenulink}}<a href="{{url}}" class="dropdown-item {{classes}}" {{#attributes}}{{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}} {{#showtext}}aria-labelledby="actionmenuaction-{{instance}}"{{/showtext}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{#showtext}}<span class="menu-action-text" id="actionmenuaction-{{instance}}">{{{text}}}</span>{{/showtext}}</a>{{/actionmenulink}}{{!
}}{{#actionmenulink}}<a href="{{url}}" class="dropdown-item {{classes}}"{{#attributes}} {{name}}={{#quote}}{{value}}{{/quote}}{{/attributes}} {{#showtext}}aria-labelledby="actionmenuaction-{{instance}}"{{/showtext}}>{{#icon}}{{>core/pix_icon}}{{/icon}}{{#showtext}}<span class="menu-action-text" id="actionmenuaction-{{instance}}">{{{text}}}</span>{{/showtext}}</a>{{/actionmenulink}}{{!
}}{{#actionmenufiller}}<div class="dropdown-divider"></div>{{/actionmenufiller}}{{!
}}{{^actionmenulink}}{{^actionmenufiller}}<div class="dropdown-item">{{> core/action_menu_item }}</div>{{/actionmenufiller}}{{/actionmenulink}}{{!
}}{{/items}}
......
......@@ -39,4 +39,4 @@
}
}}
<img class="icon {{extraclasses}}" {{#attributes}}{{name}}="{{value}}" {{/attributes}}/>
<img class="icon {{extraclasses}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}}/>
......@@ -31,7 +31,7 @@
}
}}
<label for="{{id}}" class="sr-only">{{label}}</label>
<select name="{{name}}" id="{{id}}" {{#attributes}} {{name}}="{{value}}"{{/attributes}} class="form-control">
<select name="{{name}}" id="{{id}}"{{#attributes}} {{name}}="{{value}}"{{/attributes}} class="form-control">
{{#options}}
<option value="{{value}}" {{#selected}}selected{{/selected}}>{{name}}</option>
{{/options}}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment