BUGFIX: date of the post in the share dialog is now properly bound

CLEANUP: removed all unused handlebars helpers
REFACTOR: removed 'unbound' prefix (for performance reasons, helpers are unbound by default)
REFACTOR: added 'bound' prefix to bound helpers
REFACTOR: renamed helper using 'foo-bar-foo' syntax (instead of camel case)
This commit is contained in:
Régis Hanol 2014-06-10 19:04:31 +02:00
parent 580a1bf8b0
commit 3b6b2770f3
45 changed files with 129 additions and 188 deletions

View file

@ -12,7 +12,7 @@
{{#each backup in model}} {{#each backup in model}}
<tr> <tr>
<td>{{backup.filename}}</td> <td>{{backup.filename}}</td>
<td>{{humanSize backup.size}}</td> <td>{{human-size backup.size}}</td>
<td> <td>
<div class="pull-right"> <div class="pull-right">
<a {{bind-attr href="backup.link"}} class="btn download" title="{{i18n admin.backups.operations.download.title}}"><i class="fa fa-download"></i>{{i18n admin.backups.operations.download.text}}</a> <a {{bind-attr href="backup.link"}} class="btn download" title="{{i18n admin.backups.operations.download.title}}"><i class="fa fa-download"></i>{{i18n admin.backups.operations.download.text}}</a>

View file

@ -19,7 +19,7 @@
{{#each model}} {{#each model}}
<tr> <tr>
<td>{{unboundDate created_at}}</td> <td>{{date created_at}}</td>
<td> <td>
{{#if user}} {{#if user}}
{{#link-to 'adminUser' user}}{{avatar user imageSize="tiny"}}{{/link-to}} {{#link-to 'adminUser' user}}{{avatar user imageSize="tiny"}}{{/link-to}}

View file

@ -19,7 +19,7 @@
{{#each model}} {{#each model}}
<tr> <tr>
<td>{{unboundDate created_at}}</td> <td>{{date created_at}}</td>
<td> <td>
{{#if user}} {{#if user}}
{{#link-to 'adminUser' user}}{{avatar user imageSize="tiny"}}{{/link-to}} {{#link-to 'adminUser' user}}{{avatar user imageSize="tiny"}}{{/link-to}}

View file

@ -19,7 +19,7 @@
{{#each model}} {{#each model}}
<tr> <tr>
<td>{{unboundDate created_at}}</td> <td>{{date created_at}}</td>
<td> <td>
{{#if user}} {{#if user}}
{{#link-to 'adminUser' user}}{{avatar user imageSize="tiny"}}{{/link-to}} {{#link-to 'adminUser' user}}{{avatar user imageSize="tiny"}}{{/link-to}}

View file

@ -51,7 +51,7 @@
{{#link-to 'adminUser' this.user}}{{avatar this.user imageSize="small"}} {{/link-to}} {{#link-to 'adminUser' this.user}}{{avatar this.user imageSize="small"}} {{/link-to}}
</td> </td>
<td> <td>
{{unboundDate this.flaggedAt}} {{date this.flaggedAt}}
</td> </td>
<td> <td>
{{this.flagType}} {{this.flagType}}

View file

@ -3,8 +3,8 @@
</div> </div>
<div class="col action">{{actionName}}</div> <div class="col action">{{actionName}}</div>
<div class="col match_count">{{match_count}}</div> <div class="col match_count">{{match_count}}</div>
<div class="col last_match_at">{{unboundAgeWithTooltip last_match_at}}</div> <div class="col last_match_at">{{age-with-tooltip last_match_at}}</div>
<div class="col created_at">{{unboundAgeWithTooltip created_at}}</div> <div class="col created_at">{{age-with-tooltip created_at}}</div>
<div class="col ip_address">{{ip_address}}</div> <div class="col ip_address">{{ip_address}}</div>
<div class="col action"><button class="btn" {{action clearBlock this}}><i class='fa fa-check'></i> {{i18n admin.logs.screened_emails.actions.allow}}</button></div> <div class="col action"><button class="btn" {{action clearBlock this}}><i class='fa fa-check'></i> {{i18n admin.logs.screened_emails.actions.allow}}</button></div>
<div class="clearfix"></div> <div class="clearfix"></div>

View file

@ -12,10 +12,10 @@
<div class="col match_count">{{match_count}}</div> <div class="col match_count">{{match_count}}</div>
<div class="col last_match_at"> <div class="col last_match_at">
{{#if last_match_at}} {{#if last_match_at}}
{{unboundAgeWithTooltip last_match_at}} {{age-with-tooltip last_match_at}}
{{/if}} {{/if}}
</div> </div>
<div class="col created_at">{{unboundAgeWithTooltip created_at}}</div> <div class="col created_at">{{age-with-tooltip created_at}}</div>
<div class="col actions"> <div class="col actions">
{{#unless editing}} {{#unless editing}}
<button class="btn btn-danger" {{action destroy this}}><i class="fa fa-trash-o"></i> {{i18n admin.logs.delete}}</button> <button class="btn btn-danger" {{action destroy this}}><i class="fa fa-trash-o"></i> {{i18n admin.logs.delete}}</button>

View file

@ -3,6 +3,6 @@
</div> </div>
<div class="col action">{{actionName}}</div> <div class="col action">{{actionName}}</div>
<div class="col match_count">{{match_count}}</div> <div class="col match_count">{{match_count}}</div>
<div class="col last_match_at">{{unboundAgeWithTooltip last_match_at}}</div> <div class="col last_match_at">{{age-with-tooltip last_match_at}}</div>
<div class="col created_at">{{unboundAgeWithTooltip created_at}}</div> <div class="col created_at">{{age-with-tooltip created_at}}</div>
<div class="clearfix"></div> <div class="clearfix"></div>

View file

@ -14,7 +14,7 @@
<a {{action filterBySubject subject}} {{bind-attr title="subject"}} class="btn btn-small">{{subject}}</a> <a {{action filterBySubject subject}} {{bind-attr title="subject"}} class="btn btn-small">{{subject}}</a>
{{/if}} {{/if}}
</div> </div>
<div class="col value created_at">{{unboundAgeWithTooltip created_at}}</div> <div class="col value created_at">{{age-with-tooltip created_at}}</div>
<div class="col value details"> <div class="col value details">
{{{formattedDetails}}} {{{formattedDetails}}}
{{#if useCustomModalForDetails}} {{#if useCustomModalForDetails}}

View file

@ -42,7 +42,7 @@
{{granted_by.username}} {{granted_by.username}}
{{/link-to}} {{/link-to}}
</td> </td>
<td>{{unboundAgeWithTooltip granted_at}}</td> <td>{{age-with-tooltip granted_at}}</td>
<td> <td>
<button class='btn' {{action revokeBadge this}}>{{i18n admin.badges.revoke}}</button> <button class='btn' {{action revokeBadge this}}>{{i18n admin.badges.revoke}}</button>
</td> </td>

View file

@ -2,7 +2,7 @@
<div {{bind-attr class=":dashboard-stats :version-check versionCheck.critical_updates:critical:normal"}}> <div {{bind-attr class=":dashboard-stats :version-check versionCheck.critical_updates:critical:normal"}}>
<table class="table table-condensed table-hover"> <table class="table table-condensed table-hover">
<thead> <thead>
{{customHTML 'upgrade-header'}} {{custom-html 'upgrade-header'}}
<tr> <tr>
<th>&nbsp;</th> <th>&nbsp;</th>
<th>{{i18n admin.dashboard.installed_version}}</th> <th>{{i18n admin.dashboard.installed_version}}</th>

View file

@ -5,7 +5,7 @@ function templateFunction() {
"<ul>" + "<ul>" +
"{{#each options}}" + "{{#each options}}" +
"<li>" + "<li>" +
"{{categoryLinkRaw this allowUncategorized=true}}" + "{{category-link-raw this allowUncategorized=true}}" +
"</li>" + "</li>" +
"{{/each}}" + "{{/each}}" +
"</ul>" + "</ul>" +

View file

@ -1,21 +1,3 @@
/**
Breaks up a long string
@method breakUp
@for Handlebars
**/
Handlebars.registerHelper('breakUp', function(property, hint, options) {
var prop = Ember.Handlebars.get(this, property, options);
if (!prop) return "";
if (typeof(hint) === 'string') {
hint = Ember.Handlebars.get(this, hint, options);
} else {
hint = undefined;
}
return new Handlebars.SafeString(Discourse.Formatter.breakUp(prop, hint));
});
// helper function for dates // helper function for dates
function daysSinceEpoch(dt) { function daysSinceEpoch(dt) {
// 1000 * 60 * 60 * 24 = days since epoch // 1000 * 60 * 60 * 24 = days since epoch
@ -25,9 +7,10 @@ function daysSinceEpoch(dt) {
/** /**
Converts a date to a coldmap class Converts a date to a coldmap class
@method coldDate @method cold-age-class
@for Handlebars
**/ **/
Handlebars.registerHelper('coldAgeClass', function(property, options) { Handlebars.registerHelper('cold-age-class', function(property, options) {
var dt = Em.Handlebars.get(this, property, options); var dt = Em.Handlebars.get(this, property, options);
if (!dt) { return 'age'; } if (!dt) { return 'age'; }
@ -56,10 +39,10 @@ Handlebars.registerHelper('shorten', function(property, options) {
/** /**
Produces a link to a topic Produces a link to a topic
@method topicLink @method topic-link
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('topicLink', function(property, options) { Handlebars.registerHelper('topic-link', function(property, options) {
var topic = Ember.Handlebars.get(this, property, options), var topic = Ember.Handlebars.get(this, property, options),
title = topic.get('fancy_title'); title = topic.get('fancy_title');
return "<a href='" + topic.get('lastUnreadUrl') + "' class='title'>" + title + "</a>"; return "<a href='" + topic.get('lastUnreadUrl') + "' class='title'>" + title + "</a>";
@ -90,18 +73,18 @@ function categoryLinkHTML(category, options) {
/** /**
Produces a link to a category Produces a link to a category
@method categoryLink @method category-link
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('categoryLink', function(property, options) { Handlebars.registerHelper('category-link', function(property, options) {
return categoryLinkHTML(Ember.Handlebars.get(this, property, options), options); return categoryLinkHTML(Ember.Handlebars.get(this, property, options), options);
}); });
Handlebars.registerHelper('categoryLinkRaw', function(property, options) { Handlebars.registerHelper('category-link-raw', function(property, options) {
return categoryLinkHTML(property, options); return categoryLinkHTML(property, options);
}); });
Handlebars.registerHelper('categoryBadge', function(property, options) { Handlebars.registerHelper('category-badge', function(property, options) {
options.hash.link = false; options.hash.link = false;
return categoryLinkHTML(Ember.Handlebars.get(this, property, options), options); return categoryLinkHTML(Ember.Handlebars.get(this, property, options), options);
}); });
@ -110,18 +93,18 @@ Handlebars.registerHelper('categoryBadge', function(property, options) {
/** /**
Produces a bound link to a category Produces a bound link to a category
@method boundCategoryLink @method bound-category-link
@for Handlebars @for Handlebars
**/ **/
Ember.Handlebars.registerBoundHelper('boundCategoryLink', categoryLinkHTML); Em.Handlebars.helper('bound-category-link', categoryLinkHTML);
/** /**
Produces a link to a route with support for i18n on the title Produces a link to a route with support for i18n on the title
@method titledLinkTo @method titled-link-to
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('titledLinkTo', function(name, object) { Handlebars.registerHelper('titled-link-to', function(name, object) {
var options = [].slice.call(arguments, -1)[0]; var options = [].slice.call(arguments, -1)[0];
if (options.hash.titleKey) { if (options.hash.titleKey) {
options.hash.title = I18n.t(options.hash.titleKey); options.hash.title = I18n.t(options.hash.titleKey);
@ -139,7 +122,7 @@ Handlebars.registerHelper('titledLinkTo', function(name, object) {
@method shortenUrl @method shortenUrl
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('shortenUrl', function(property, options) { Handlebars.registerHelper('shorten-url', function(property, options) {
var url, matches; var url, matches;
url = Ember.Handlebars.get(this, property, options); url = Ember.Handlebars.get(this, property, options);
// Remove trailing slash if it's a top level URL // Remove trailing slash if it's a top level URL
@ -152,22 +135,6 @@ Handlebars.registerHelper('shortenUrl', function(property, options) {
return url.substring(0,80); return url.substring(0,80);
}); });
/**
Display a property in lower case
@method lower
@for Handlebars
**/
Handlebars.registerHelper('lower', function(property, options) {
var o;
o = Ember.Handlebars.get(this, property, options);
if (o && typeof o === 'string') {
return o.toLowerCase();
} else {
return "";
}
});
/** /**
Show an avatar for a user, intelligently making use of available properties Show an avatar for a user, intelligently making use of available properties
@ -217,10 +184,10 @@ Handlebars.registerHelper('avatar', function(user, options) {
/** /**
Bound avatar helper. Bound avatar helper.
@method boundAvatar @method bound-avatar
@for Handlebars @for Handlebars
**/ **/
Ember.Handlebars.registerBoundHelper('boundAvatar', function(user, size, uploadId) { Em.Handlebars.helper('bound-avatar', function(user, size, uploadId) {
var username = Em.get(user, 'username'); var username = Em.get(user, 'username');
@ -239,7 +206,7 @@ Ember.Handlebars.registerBoundHelper('boundAvatar', function(user, size, uploadI
/* /*
* Used when we only have a template * Used when we only have a template
*/ */
Ember.Handlebars.registerBoundHelper('boundAvatarTemplate', function(avatarTemplate, size) { Em.Handlebars.helper('bound-avatar-template', function(avatarTemplate, size) {
return new Handlebars.SafeString(Discourse.Utilities.avatarImg({ return new Handlebars.SafeString(Discourse.Utilities.avatarImg({
size: size, size: size,
avatarTemplate: avatarTemplate avatarTemplate: avatarTemplate
@ -249,21 +216,31 @@ Ember.Handlebars.registerBoundHelper('boundAvatarTemplate', function(avatarTempl
/** /**
Nicely format a date without binding or returning HTML Nicely format a date without binding or returning HTML
@method rawDate @method raw-date
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('rawDate', function(property, options) { Handlebars.registerHelper('raw-date', function(property, options) {
var dt = new Date(Ember.Handlebars.get(this, property, options)); var dt = new Date(Ember.Handlebars.get(this, property, options));
return Discourse.Formatter.longDate(dt); return Discourse.Formatter.longDate(dt);
}); });
/** /**
Live refreshing age helper Nicely format a bound date without returning HTML
@method unboundAge @method bound-raw-date
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('unboundAge', function(property, options) { Em.Handlebars.helper('bound-raw-date', function (date) {
return Discourse.Formatter.longDate(new Date(date));
});
/**
Live refreshing age helper
@method age
@for Handlebars
**/
Handlebars.registerHelper('age', function(property, options) {
var dt = new Date(Ember.Handlebars.get(this, property, options)); var dt = new Date(Ember.Handlebars.get(this, property, options));
return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(dt)); return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(dt));
}); });
@ -271,50 +248,14 @@ Handlebars.registerHelper('unboundAge', function(property, options) {
/** /**
Live refreshing age helper, with a tooltip showing the date and time Live refreshing age helper, with a tooltip showing the date and time
@method unboundAgeWithTooltip @method age-with-tooltip
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('unboundAgeWithTooltip', function(property, options) { Handlebars.registerHelper('age-with-tooltip', function(property, options) {
var dt = new Date(Ember.Handlebars.get(this, property, options)); var dt = new Date(Ember.Handlebars.get(this, property, options));
return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(dt, {title: true})); return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(dt, {title: true}));
}); });
/**
Display a date related to an edit of a post
@method editDate
@for Handlebars
**/
Handlebars.registerHelper('editDate', function(property, options) {
// autoupdating this is going to be painful
var date = new Date(Ember.Handlebars.get(this, property, options));
return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(date, {format: 'medium', title: true, leaveAgo: true, wrapInSpan: false}));
});
/**
Displays a percentile based on a `percent_rank` field
@method percentile
@for Ember.Handlebars
**/
Ember.Handlebars.registerHelper('percentile', function(property, options) {
var percentile = Ember.Handlebars.get(this, property, options);
return Math.round((1.0 - percentile) * 100);
});
/**
Displays a float nicely
@method float
@for Ember.Handlebars
**/
Ember.Handlebars.registerHelper('float', function(property, options) {
var x = Ember.Handlebars.get(this, property, options);
if (!x) return "0";
if (Math.round(x) === x) return x;
return x.toFixed(3);
});
/** /**
Display logic for numbers. Display logic for numbers.
@ -351,10 +292,10 @@ Handlebars.registerHelper('number', function(property, options) {
Display logic for dates. It is unbound in Ember but will use jQuery to Display logic for dates. It is unbound in Ember but will use jQuery to
update the dates on a regular interval. update the dates on a regular interval.
@method unboundDate @method date
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('unboundDate', function(property, options) { Handlebars.registerHelper('date', function(property, options) {
var leaveAgo; var leaveAgo;
if (property.hash) { if (property.hash) {
if (property.hash.leaveAgo) { if (property.hash.leaveAgo) {
@ -372,7 +313,7 @@ Handlebars.registerHelper('unboundDate', function(property, options) {
} }
}); });
Ember.Handlebars.registerBoundHelper('date', function(dt) { Em.Handlebars.helper('bound-date', function(dt) {
return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(new Date(dt), {format: 'medium', title: true })); return new Handlebars.SafeString(Discourse.Formatter.autoUpdatingRelativeAge(new Date(dt), {format: 'medium', title: true }));
}); });
@ -380,10 +321,10 @@ Ember.Handlebars.registerBoundHelper('date', function(dt) {
Look for custom html content using `Discourse.HTML`. If none exists, look for a template Look for custom html content using `Discourse.HTML`. If none exists, look for a template
to render with that name. to render with that name.
@method customHTML @method custom-html
@for Handlebars @for Handlebars
**/ **/
Handlebars.registerHelper('customHTML', function(name, contextString, options) { Handlebars.registerHelper('custom-html', function(name, contextString, options) {
var html = Discourse.HTML.getCustomHTML(name); var html = Discourse.HTML.getCustomHTML(name);
if (html) { return html; } if (html) { return html; }
@ -394,7 +335,7 @@ Handlebars.registerHelper('customHTML', function(name, contextString, options) {
} }
}); });
Ember.Handlebars.registerBoundHelper('humanSize', function(size) { Em.Handlebars.helper('human-size', function(size) {
return new Handlebars.SafeString(I18n.toHumanSize(size)); return new Handlebars.SafeString(I18n.toHumanSize(size));
}); });

View file

@ -21,7 +21,7 @@
{{avatar user imageSize="large"}} {{avatar user imageSize="large"}}
<div class="details"> <div class="details">
<span class="username">{{user.username}}</span> <span class="username">{{user.username}}</span>
{{unboundDate granted_at}} {{date granted_at}}
</div> </div>
</div> </div>
{{/link-to}} {{/link-to}}

View file

@ -37,7 +37,7 @@
{{#unless controller.hideCategory}} {{#unless controller.hideCategory}}
<td class="category"> <td class="category">
{{categoryLink topic.category showParent=true}} {{category-link topic.category showParent=true}}
</td> </td>
{{/unless}} {{/unless}}
@ -65,14 +65,14 @@
{{#if topic.bumped}} {{#if topic.bumped}}
<td class='num activity'> <td class='num activity'>
<a href="{{unbound topic.url}}" class='{{coldAgeClass created_at}}' title='{{i18n first_post}}: {{{rawDate topic.created_at}}}' >{{unboundAge topic.created_at}}</a> <a href="{{unbound topic.url}}" class='{{cold-age-class created_at}}' title='{{i18n first_post}}: {{{raw-date topic.created_at}}}' >{{age topic.created_at}}</a>
</td> </td>
<td class='num activity last'> <td class='num activity last'>
<a href="{{unbound topic.lastPostUrl}}" class='{{coldAgeClass bumped_at}}' title='{{i18n last_post}}: {{{rawDate topic.bumped_at}}}'>{{unboundAge topic.bumped_at}}</a> <a href="{{unbound topic.lastPostUrl}}" class='{{cold-age-class bumped_at}}' title='{{i18n last_post}}: {{{raw-date topic.bumped_at}}}'>{{age topic.bumped_at}}</a>
</td> </td>
{{else}} {{else}}
<td class='num activity'> <td class='num activity'>
<a href="{{unbound topic.url}}" class='age' title='{{i18n first_post}}: {{{rawDate topic.created_at}}}'>{{unboundAge topic.created_at}}</a> <a href="{{unbound topic.url}}" class='age' title='{{i18n first_post}}: {{{raw-date topic.created_at}}}'>{{age topic.created_at}}</a>
</td> </td>
<td class="activity"></td> <td class="activity"></td>
{{/if}} {{/if}}

View file

@ -20,6 +20,6 @@
{{#if subCategory}} {{#if subCategory}}
<div class='cat'><a {{bind-attr href=noCategoriesUrl}} data-drop-close="true" class='badge-category home'>{{i18n categories.no_subcategory}}</a></div> <div class='cat'><a {{bind-attr href=noCategoriesUrl}} data-drop-close="true" class='badge-category home'>{{i18n categories.no_subcategory}}</a></div>
{{/if}} {{/if}}
{{#each categories}}<div class='cat'>{{categoryLink this allowUncategorized=true}}</div>{{/each}} {{#each categories}}<div class='cat'>{{category-link this allowUncategorized=true}}</div>{{/each}}
</section> </section>
{{/if}} {{/if}}

View file

@ -7,17 +7,17 @@
<section {{bind-attr class=":map mapCollapsed"}}> <section {{bind-attr class=":map mapCollapsed"}}>
<ul class="clearfix"> <ul class="clearfix">
<li> <li>
<a href='{{unbound topic.url}}' class='{{coldAgeClass topic.created_at}}'> <a href='{{unbound topic.url}}' class='{{cold-age-class topic.created_at}}'>
<h4>{{i18n created}}</h4> <h4>{{i18n created}}</h4>
{{avatar details.created_by imageSize="tiny"}} {{avatar details.created_by imageSize="tiny"}}
{{unboundDate topic.created_at}} {{date topic.created_at}}
</a> </a>
</li> </li>
<li> <li>
<a {{bind-attr href="topic.lastPostUrl"}}> <a {{bind-attr href="topic.lastPostUrl"}}>
<h4>{{i18n last_post}}</h4> <h4>{{i18n last_post}}</h4>
{{avatar details.last_poster imageSize="tiny"}} {{avatar details.last_poster imageSize="tiny"}}
{{unboundDate topic.last_posted_at}} {{date topic.last_posted_at}}
</a> </a>
</li> </li>
<li> <li>
@ -62,7 +62,7 @@
<li> <li>
<span class='badge badge-notification clicks' title='{{i18n topic_map.clicks count=clicks}}'>{{clicks}}</span> <span class='badge badge-notification clicks' title='{{i18n topic_map.clicks count=clicks}}'>{{clicks}}</span>
<a href="{{unbound url}}" target="_blank" class='topic-link track-link' data-user-id="{{unbound user_id}}" data-ignore-post-id="true" title="{{unbound url}}"> <a href="{{unbound url}}" target="_blank" class='topic-link track-link' data-user-id="{{unbound user_id}}" data-ignore-post-id="true" title="{{unbound url}}">
{{#if title}}{{title}}{{else}}{{shortenUrl url}}{{/if}} {{#if title}}{{title}}{{else}}{{shorten-url url}}{{/if}}
</a> </a>
{{link-domain this}} {{link-domain this}}
</li> </li>

View file

@ -3,6 +3,6 @@
<ul class='topics'> <ul class='topics'>
{{#each similarTopics}} {{#each similarTopics}}
<li>{{{topicLink this}}} <span class='posts-count'>({{{i18n topic.filters.n_posts count="posts_count"}}})</span></li> <li>{{{topic-link this}}} <span class='posts-count'>({{{i18n topic.filters.n_posts count="posts_count"}}})</span></li>
{{/each}} {{/each}}
</ul> </ul>

View file

@ -1,5 +1,5 @@
<div class='container'> <div class='container'>
{{customHTML "top"}} {{custom-html "top"}}
{{Discourse.globalNotice}} {{Discourse.globalNotice}}
</div> </div>

View file

@ -18,7 +18,7 @@
<div> <div>
<div class="pull-left"> <div class="pull-left">
{{#if controller.ordering}}<i class="fa fa-bars"></i>{{/if}} {{#if controller.ordering}}<i class="fa fa-bars"></i>{{/if}}
{{categoryLink this allowUncategorized=true extraClasses="bigger"}} {{category-link this allowUncategorized=true extraClasses="bigger"}}
{{#if unreadTopics}} {{#if unreadTopics}}
<a href={{unbound unreadUrl}} class='badge new-posts badge-notification' title='{{i18n topic.unread_topics count="unreadTopics"}}'>{{unbound unreadTopics}}</a> <a href={{unbound unreadUrl}} class='badge new-posts badge-notification' title='{{i18n topic.unread_topics count="unreadTopics"}}'>{{unbound unreadTopics}}</a>
{{/if}} {{/if}}
@ -41,7 +41,7 @@
{{#if subcategories}} {{#if subcategories}}
<div class='subcategories'> <div class='subcategories'>
{{#each subcategories}} {{#each subcategories}}
{{categoryLink this showParent=true}} {{category-link this showParent=true}}
{{#if unreadTopics}} {{#if unreadTopics}}
<a href={{unbound unreadUrl}} class='badge new-posts badge-notification' title='{{i18n topic.unread_topics count="unreadTopics"}}'>{{unbound unreadTopics}}</a> <a href={{unbound unreadUrl}} class='badge new-posts badge-notification' title='{{i18n topic.unread_topics count="unreadTopics"}}'>{{unbound unreadTopics}}</a>
{{/if}} {{/if}}
@ -70,11 +70,11 @@
{{#if controller.latestTopicOnly}} {{#if controller.latestTopicOnly}}
<div class='last-user-info'> <div class='last-user-info'>
{{i18n categories.latest_by}} <a href="{{{unbound lastPosterUrl}}}">{{unbound last_poster.username}}</a> {{i18n categories.latest_by}} <a href="{{{unbound lastPosterUrl}}}">{{unbound last_poster.username}}</a>
<a href="{{unbound lastPostUrl}}">{{unboundAge last_posted_at}}</a> <a href="{{unbound lastPostUrl}}">{{age last_posted_at}}</a>
</div> </div>
{{else}} {{else}}
&nbsp; &nbsp;
<a href="{{unbound lastPostUrl}}" class="last-posted-at">{{unboundAge last_posted_at}}</a> <a href="{{unbound lastPostUrl}}" class="last-posted-at">{{age last_posted_at}}</a>
{{/if}} {{/if}}
</div> </div>
{{/each}} {{/each}}

View file

@ -10,7 +10,7 @@
<div class="topic-meta-data"> <div class="topic-meta-data">
<h5 {{bind-attr class="staff new_user"}}><a href='{{unbound usernameUrl}}'>{{{unbound username}}}</a></h5> <h5 {{bind-attr class="staff new_user"}}><a href='{{unbound usernameUrl}}'>{{{unbound username}}}</a></h5>
{{#if view.parentView.previousPost}}<a href='{{unbound url}}' class="post-info arrow" title="{{i18n topic.jump_reply_up}}"><i class='fa fa-arrow-up'></i></a>{{/if}} {{#if view.parentView.previousPost}}<a href='{{unbound url}}' class="post-info arrow" title="{{i18n topic.jump_reply_up}}"><i class='fa fa-arrow-up'></i></a>{{/if}}
<div class='post-info post-date'>{{unboundAgeWithTooltip created_at}}</div> <div class='post-info post-date'>{{age-with-tooltip created_at}}</div>
</div> </div>
{{{unbound cooked}}} {{{unbound cooked}}}
{{#unless view.parentView.previousPost}}<a href='{{unbound url}}' class="arrow" title="{{i18n topic.jump_reply_down}}"><i class='fa fa-arrow-down'></i></a>{{/unless}} {{#unless view.parentView.previousPost}}<a href='{{unbound url}}' class="arrow" title="{{i18n topic.jump_reply_down}}"><i class='fa fa-arrow-down'></i></a>{{/unless}}

View file

@ -1,7 +1,7 @@
<table id='topic-list'> <table id='topic-list'>
<tr> <tr>
<th class="main-link"> <th class="main-link">
{{categoryLink this allowUncategorized=true}} {{category-link this allowUncategorized=true}}
<div class='posters'> <div class='posters'>
{{#each featured_users}} {{#each featured_users}}
@ -26,7 +26,7 @@
<td class='main-link'> <td class='main-link'>
<div class='topic-inset'> <div class='topic-inset'>
{{topic-status topic=this}} {{topic-status topic=this}}
{{{topicLink this}}} {{{topic-link this}}}
{{#if unread}} {{#if unread}}
<a href="{{unbound lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unbound unread}}</a> <a href="{{unbound lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unbound unread}}</a>
@ -52,7 +52,7 @@
</div> </div>
</td> </td>
<td class='num posts'><span class='badge-posts'>{{number posts_count}}</span></td> <td class='num posts'><span class='badge-posts'>{{number posts_count}}</span></td>
<td class='num age'><span class="{{coldAgeClass created_at}}" title='{{rawDate created_at}}'>{{{unboundAge created_at}}}</span></td> <td class='num age'><span class="{{cold-age-class created_at}}" title='{{raw-date created_at}}'>{{{age created_at}}}</span></td>
</tr> </tr>
{{/each}} {{/each}}
@ -62,7 +62,7 @@
<div class='subcategories'> <div class='subcategories'>
{{i18n categories.subcategories}} {{i18n categories.subcategories}}
{{#each subcategory in subcategories}} {{#each subcategory in subcategories}}
{{categoryLink subcategory showParent=true}} {{category-link subcategory showParent=true}}
{{/each}} {{/each}}
</div> </div>
</td> </td>

View file

@ -3,7 +3,7 @@
<div class='item'> <div class='item'>
<div class='clearfix info'> <div class='clearfix info'>
{{#link-to 'user' user class="avatar-link"}}<div class='avatar-wrapper'>{{avatar user imageSize="large" extraClasses="actor" ignoreTitle="true"}}</div>{{/link-to}} {{#link-to 'user' user class="avatar-link"}}<div class='avatar-wrapper'>{{avatar user imageSize="large" extraClasses="actor" ignoreTitle="true"}}</div>{{/link-to}}
<span class='time'>{{unboundDate path="created_at" leaveAgo="true"}}</span> <span class='time'>{{date path="created_at" leaveAgo="true"}}</span>
<span class="title"> <span class="title">
<a href="{{unbound url}}">{{unbound title}}</a> <a href="{{unbound url}}">{{unbound title}}</a>
</span> </span>

View file

@ -13,7 +13,7 @@
<p>{{name}}</p> <p>{{name}}</p>
</td> </td>
<td> <td>
<span class='last-seen-at'>{{date last_seen_at}}</span> <span class='last-seen-at'>{{bound-date last_seen_at}}</span>
</td> </td>
</tr> </tr>
</div> </div>

View file

@ -14,9 +14,9 @@
<span class="private-message-glyph">{{icon envelope}}</span> <span class="private-message-glyph">{{icon envelope}}</span>
{{/if}} {{/if}}
{{#if topic.category.parentCategory}} {{#if topic.category.parentCategory}}
{{boundCategoryLink topic.category.parentCategory}} {{bound-category-link topic.category.parentCategory}}
{{/if}} {{/if}}
{{boundCategoryLink topic.category}} {{bound-category-link topic.category}}
{{#if topic.details.loaded}} {{#if topic.details.loaded}}
{{topic-status topic=topic}} {{topic-status topic=topic}}
<a class='topic-link' href='{{unbound topic.url}}' {{action jumpToTopPost}}>{{{topic.fancy_title}}}</a> <a class='topic-link' href='{{unbound topic.url}}' {{action jumpToTopPost}}>{{{topic.fancy_title}}}</a>
@ -104,7 +104,7 @@
href="#" href="#"
title='{{i18n user.avatar.title}}' title='{{i18n user.avatar.title}}'
id="current-user"> id="current-user">
{{boundAvatar currentUser "medium"}} {{bound-avatar currentUser "medium"}}
</a> </a>
</li> </li>
{{/if}} {{/if}}

View file

@ -12,7 +12,7 @@
<td class='main-link clearfix' {{bind-attr colspan="titleColSpan"}}> <td class='main-link clearfix' {{bind-attr colspan="titleColSpan"}}>
{{topic-status topic=this.model}} {{topic-status topic=this.model}}
{{{topicLink this}}} {{{topic-link this}}}
{{#if unread}} {{#if unread}}
<a href="{{lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unread}}</a> <a href="{{lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unread}}</a>
{{/if}} {{/if}}
@ -37,7 +37,7 @@
</td> </td>
{{#unless hideCategory}} {{#unless hideCategory}}
<td class='category'>{{boundCategoryLink category showParent=true}}</td> <td class='category'>{{bound-category-link category showParent=true}}</td>
{{/unless}} {{/unless}}
<td class='posters'> <td class='posters'>
@ -58,14 +58,14 @@
{{#if bumped}} {{#if bumped}}
<td class='num activity'> <td class='num activity'>
<a href="{{url}}" class="{{coldAgeClass created_at}}" title='{{i18n first_post}}: {{{rawDate created_at}}}' >{{unboundAge created_at}}</a> <a href="{{url}}" class="{{cold-age-class created_at}}" title='{{i18n first_post}}: {{{raw-date created_at}}}' >{{age created_at}}</a>
</td> </td>
<td class='num activity last'> <td class='num activity last'>
<a href="{{lastPostUrl}}" class="{{coldAgeClass bumped_at}}" title='{{i18n last_post}}: {{{rawDate bumped_at}}}'>{{unboundAge bumped_at}}</a> <a href="{{lastPostUrl}}" class="{{cold-age-class bumped_at}}" title='{{i18n last_post}}: {{{raw-date bumped_at}}}'>{{age bumped_at}}</a>
</td> </td>
{{else}} {{else}}
<td class='num activity'> <td class='num activity'>
<a href="{{url}}" class="{{coldAgeClass created_at}}" title='{{i18n first_post}}: {{{rawDate created_at}}}'>{{unboundAge created_at}}</a> <a href="{{url}}" class="{{cold-age-class created_at}}" title='{{i18n first_post}}: {{{raw-date created_at}}}'>{{age created_at}}</a>
</td> </td>
<td class='activity'></td> <td class='activity'></td>
{{/if}} {{/if}}

View file

@ -6,7 +6,7 @@
<td> <td>
<div class='main-link clearfix'> <div class='main-link clearfix'>
{{topic-status topic=this}} {{topic-status topic=this}}
{{{topicLink this}}} {{{topic-link this}}}
{{#if unread}} {{#if unread}}
<a href="{{lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unread}}</a> <a href="{{lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unread}}</a>
{{/if}} {{/if}}
@ -42,17 +42,17 @@
{{/if}} {{/if}}
{{#if bumped}} {{#if bumped}}
<div class='num activity last'> <div class='num activity last'>
<a href="{{lastPostUrl}}" class='age' title='{{i18n last_post}}: {{{rawDate bumped_at}}}'>{{unboundAge bumped_at}}</a> <a href="{{lastPostUrl}}" class='age' title='{{i18n last_post}}: {{{raw-date bumped_at}}}'>{{age bumped_at}}</a>
</div> </div>
{{else}} {{else}}
<div class='num activity last'> <div class='num activity last'>
<a href="{{url}}" class='age' title='{{i18n first_post}}: {{{rawDate created_at}}}'>{{unboundAge created_at}}</a> <a href="{{url}}" class='age' title='{{i18n first_post}}: {{{raw-date created_at}}}'>{{age created_at}}</a>
</div> </div>
{{/if}} {{/if}}
</div> </div>
{{#unless controller.hideCategory}} {{#unless controller.hideCategory}}
<div class='category'> <div class='category'>
{{categoryLink category showParent=true}} {{category-link category showParent=true}}
</div> </div>
{{/unless}} {{/unless}}
{{#if controller.showParticipants}} {{#if controller.showParticipants}}

View file

@ -1,7 +1,7 @@
<td> <td>
<div class='main-link clearfix'> <div class='main-link clearfix'>
{{topic-status topic=this}} {{topic-status topic=this}}
{{{topicLink this}}} {{{topic-link this}}}
{{#if unread}} {{#if unread}}
<a href="{{lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unread}}</a> <a href="{{lastUnreadUrl}}" class='badge unread badge-notification' title='{{i18n topic.unread_posts count="unread"}}'>{{unread}}</a>
{{/if}} {{/if}}
@ -28,7 +28,7 @@
<div class="topic-item-stats clearfix"> <div class="topic-item-stats clearfix">
{{#unless controller.hideCategory}} {{#unless controller.hideCategory}}
<div class='category'> <div class='category'>
{{categoryLink category showParent=true}} {{category-link category showParent=true}}
</div> </div>
{{/unless}} {{/unless}}
@ -41,13 +41,13 @@
{{#if bumped}} {{#if bumped}}
<div class='num activity last'> <div class='num activity last'>
<a href="{{lastPostUrl}}" title='{{i18n last_post}}: {{{rawDate bumped_at}}}'>{{last_poster_username}}</a> <a href="{{lastPostUrl}}" title='{{i18n last_post}}: {{{raw-date bumped_at}}}'>{{last_poster_username}}</a>
<a href="{{lastPostUrl}}" class='age' title='{{i18n last_post}}: {{{rawDate bumped_at}}}'>{{unboundAge bumped_at}}</a> <a href="{{lastPostUrl}}" class='age' title='{{i18n last_post}}: {{{raw-date bumped_at}}}'>{{age bumped_at}}</a>
</div> </div>
{{else}} {{else}}
<div class='num activity last'> <div class='num activity last'>
<a href="{{url}}" title='{{i18n last_post}}: {{{rawDate bumped_at}}}'>{{last_poster_username}}</a> <a href="{{url}}" title='{{i18n last_post}}: {{{raw-date bumped_at}}}'>{{last_poster_username}}</a>
<a href="{{url}}" class='age' title='{{i18n first_post}}: {{{rawDate created_at}}}'>{{unboundAge created_at}}</a> <a href="{{url}}" class='age' title='{{i18n first_post}}: {{{raw-date created_at}}}'>{{age created_at}}</a>
</div> </div>
{{/if}} {{/if}}
</div> </div>

View file

@ -2,11 +2,11 @@
<div> <div>
<div> <div>
<input type="radio" id="system-avatar" name="avatar" value="system" {{action useSystem}}> <input type="radio" id="system-avatar" name="avatar" value="system" {{action useSystem}}>
<label class="radio" for="system-avatar">{{boundAvatar controller "large" system_avatar_upload_id}} {{{i18n user.change_avatar.letter_based}}}</label> <label class="radio" for="system-avatar">{{bound-avatar controller "large" system_avatar_upload_id}} {{{i18n user.change_avatar.letter_based}}}</label>
</div> </div>
<div> <div>
<input type="radio" id="gravatar" name="avatar" value="gravatar" {{action useGravatar}}> <input type="radio" id="gravatar" name="avatar" value="gravatar" {{action useGravatar}}>
<label class="radio" for="gravatar">{{boundAvatar controller "large" gravatar_avatar_upload_id}} {{{i18n user.change_avatar.gravatar}}} {{email}}</label> <label class="radio" for="gravatar">{{bound-avatar controller "large" gravatar_avatar_upload_id}} {{{i18n user.change_avatar.gravatar}}} {{email}}</label>
<button href="#" {{action refreshGravatar}} title="{{i18n user.change_avatar.refresh_gravatar_title}}" {{bind-attr enabled="view.gravatarRefreshEnabled"}} class="btn no-text"><i class="fa fa-refresh"></i></button> <button href="#" {{action refreshGravatar}} title="{{i18n user.change_avatar.refresh_gravatar_title}}" {{bind-attr enabled="view.gravatarRefreshEnabled"}} class="btn no-text"><i class="fa fa-refresh"></i></button>
</div> </div>
<div> <div>
@ -14,9 +14,9 @@
<label class="radio" for="uploaded_avatar"> <label class="radio" for="uploaded_avatar">
{{#if view.hasUploadedAvatar}} {{#if view.hasUploadedAvatar}}
{{#if view.uploadedAvatarTemplate}} {{#if view.uploadedAvatarTemplate}}
{{boundAvatarTemplate view.uploadedAvatarTemplate "large"}} {{bound-avatar-template view.uploadedAvatarTemplate "large"}}
{{else}} {{else}}
{{boundAvatar controller "large" custom_avatar_upload_id}} {{i18n user.change_avatar.uploaded_avatar}} {{bound-avatar controller "large" custom_avatar_upload_id}} {{i18n user.change_avatar.uploaded_avatar}}
{{/if}} {{/if}}
{{else}} {{else}}
{{i18n user.change_avatar.uploaded_avatar_empty}} {{i18n user.change_avatar.uploaded_avatar_empty}}

View file

@ -70,7 +70,7 @@
{{#if tosAcceptRequired}} {{#if tosAcceptRequired}}
<div class="tos-agree"> <div class="tos-agree">
{{input type="checkbox" checked=tosAccepted}} {{input type="checkbox" checked=tosAccepted}}
{{customHTML "tos_signup_form_message"}} {{custom-html "tos_signup_form_message"}}
</div> </div>
{{/if}} {{/if}}
<button class='btn btn-large btn-primary' {{bind-attr disabled="submitDisabled"}} {{action createAccount}}>{{i18n create_account.title}}</button> <button class='btn btn-large btn-primary' {{bind-attr disabled="submitDisabled"}} {{action createAccount}}>{{i18n create_account.title}}</button>

View file

@ -25,7 +25,7 @@
{{#if subCategories}} {{#if subCategories}}
<label>{{i18n categories.subcategories}}</label> <label>{{i18n categories.subcategories}}</label>
{{#each subCategories}} {{#each subCategories}}
{{categoryBadge this}} {{category-badge this}}
{{/each}} {{/each}}
{{else}} {{else}}
<label>{{i18n category.parent}}</label> <label>{{i18n category.parent}}</label>

View file

@ -17,7 +17,7 @@
</div> </div>
</div> </div>
<div id="revision-details"> <div id="revision-details">
{{i18n post.revisions.details.edited_by}} {{boundAvatarTemplate content.avatar_template "small"}} {{username}} <span class="date">{{date created_at}}</span> {{#if edit_reason}} &mdash; <span class="edit-reason">{{edit_reason}}</span>{{/if}} {{i18n post.revisions.details.edited_by}} {{bound-avatar-template content.avatar_template "small"}} {{username}} <span class="date">{{bound-date created_at}}</span> {{#if edit_reason}} &mdash; <span class="edit-reason">{{edit_reason}}</span>{{/if}}
</div> </div>
<div id="revisions"> <div id="revisions">
{{#if title_changes}} {{#if title_changes}}
@ -32,7 +32,7 @@
{{/if}} {{/if}}
{{#if user_changes}} {{#if user_changes}}
<div class="row"> <div class="row">
{{boundAvatarTemplate user_changes.previous.avatar_template "small"}} {{user_changes.previous.username}}{{boundAvatarTemplate user_changes.current.avatar_template "small"}} {{user_changes.current.username}} {{bound-avatar-template user_changes.previous.avatar_template "small"}} {{user_changes.previous.username}}{{bound-avatar-template user_changes.current.avatar_template "small"}} {{user_changes.current.username}}
</div> </div>
{{/if}} {{/if}}
{{#if wiki_changes}} {{#if wiki_changes}}

View file

@ -4,7 +4,7 @@
{{#each navItem in navItems}} {{#each navItem in navItems}}
{{navigation-item content=navItem filterMode=filterMode}} {{navigation-item content=navItem filterMode=filterMode}}
{{/each}} {{/each}}
{{customHTML "extraNavItem"}} {{custom-html "extraNavItem"}}
</ul> </ul>
{{#if canCreateCategory}} {{#if canCreateCategory}}

View file

@ -4,7 +4,7 @@
{{#each navItem in navItems}} {{#each navItem in navItems}}
{{navigation-item content=navItem filterMode=filterMode}} {{navigation-item content=navItem filterMode=filterMode}}
{{/each}} {{/each}}
{{customHTML "extraNavItem"}} {{custom-html "extraNavItem"}}
</ul> </ul>
{{#if canChangeCategoryNotificationLevel}} {{#if canChangeCategoryNotificationLevel}}

View file

@ -4,7 +4,7 @@
{{#each navItem in navItems}} {{#each navItem in navItems}}
{{navigation-item content=navItem filterMode=filterMode}} {{navigation-item content=navItem filterMode=filterMode}}
{{/each}} {{/each}}
{{customHTML "extraNavItem"}} {{custom-html "extraNavItem"}}
</ul> </ul>
{{#if canCreateTopic}} {{#if canCreateTopic}}

View file

@ -40,17 +40,17 @@
<div class='topic-meta-data'> <div class='topic-meta-data'>
{{poster-name post=this expandAction="showPosterExpansion"}} {{poster-name post=this expandAction="showPosterExpansion"}}
<div class='post-info'> <div class='post-info'>
<a class='post-date' {{bind-attr href="shareUrl" data-share-url="shareUrl" data-post-number="post_number"}}>{{unboundAgeWithTooltip created_at}}</a> <a class='post-date' {{bind-attr href="shareUrl" data-share-url="shareUrl" data-post-number="post_number"}}>{{age-with-tooltip created_at}}</a>
</div> </div>
{{#if hasHistory}} {{#if hasHistory}}
<div class='post-info edits'> <div class='post-info edits'>
{{#if can_view_edit_history}} {{#if can_view_edit_history}}
<a href='#' class="{{unbound historyHeat}}" {{action showHistory this}} title="{{i18n post.last_edited_on}} {{rawDate updated_at}}"> <a href='#' class="{{unbound historyHeat}}" {{action showHistory this}} title="{{i18n post.last_edited_on}} {{raw-date updated_at}}">
{{editCount}} {{editCount}}
<i class='fa fa-pencil'></i> <i class='fa fa-pencil'></i>
</a> </a>
{{else}} {{else}}
<span class="{{unbound historyHeat}}" title="{{i18n post.last_edited_on}} {{rawDate updated_at}}"> <span class="{{unbound historyHeat}}" title="{{i18n post.last_edited_on}} {{raw-date updated_at}}">
{{editCount}} {{editCount}}
<i class='fa fa-pencil'></i> <i class='fa fa-pencil'></i>
</span> </span>

View file

@ -1,5 +1,5 @@
{{#if model}} {{#if model}}
{{#link-to 'user' user}}{{boundAvatar model "huge"}}{{/link-to}} {{#link-to 'user' user}}{{bound-avatar model "huge"}}{{/link-to}}
<div class="names"> <div class="names">
<h1 {{bind-attr class="staff new_user"}}><a {{bind-attr href="usernameUrl"}}>{{username}}</a></h1> <h1 {{bind-attr class="staff new_user"}}><a {{bind-attr href="usernameUrl"}}>{{username}}</a></h1>
@ -24,8 +24,8 @@
{{#if user}} {{#if user}}
<div class="metadata"> <div class="metadata">
{{#if user.location}}<h3><i class="fa fa-map-marker"></i> {{{user.location}}}</h3>{{/if}} {{#if user.location}}<h3><i class="fa fa-map-marker"></i> {{{user.location}}}</h3>{{/if}}
<h3>{{i18n last_post}} {{unboundDate path="user.last_posted_at" leaveAgo="true"}}</h3> <h3>{{i18n last_post}} {{date path="user.last_posted_at" leaveAgo="true"}}</h3>
<h3>{{i18n joined}} {{unboundDate path="user.created_at" leaveAgo="true"}}</h3> <h3>{{i18n joined}} {{date path="user.created_at" leaveAgo="true"}}</h3>
{{groups-list groups=user.custom_groups}} {{groups-list groups=user.custom_groups}}
</div> </div>

View file

@ -1,7 +1,7 @@
<h3>{{view.title}}</h3> <h3>{{view.title}}</h3>
{{#if date}} {{#if date}}
<span class="date">{{rawDate date}}</span> <span class="date">{{bound-raw-date date}}</span>
{{/if}} {{/if}}
<div><input type='text' /></div> <div><input type='text' /></div>

View file

@ -1,4 +1,4 @@
{{categoryLink this allowUncategorized=true showParent=true}} {{category-link this allowUncategorized=true showParent=true}}
{{#if showBadges}} {{#if showBadges}}
{{#if unreadTopics}} {{#if unreadTopics}}
<a href={{unbound unreadUrl}} class='badge unread-posts badge-notification' title='{{i18n topic.unread_topics count="unreadTopics"}}'>{{unreadTopics}}</a> <a href={{unbound unreadUrl}} class='badge unread-posts badge-notification' title='{{i18n topic.unread_topics count="unreadTopics"}}'>{{unreadTopics}}</a>

View file

@ -1 +1 @@
{{#titledLinkTo "discovery.latest" (query-params ascending="false" order="default") titleKey="filters.latest.help" class="latest-topics-link"}}{{i18n filters.latest.title}}{{/titledLinkTo}} {{#titled-link-to "discovery.latest" (query-params ascending="false" order="default") titleKey="filters.latest.help" class="latest-topics-link"}}{{i18n filters.latest.title}}{{/titled-link-to}}

View file

@ -1,5 +1,5 @@
<div class='container'> <div class='container'>
{{customHTML "top"}} {{custom-html "top"}}
{{Discourse.globalNotice}} {{Discourse.globalNotice}}
</div> </div>
@ -28,9 +28,9 @@
<h1> <h1>
<span class="private-message-glyph"><i class='fa fa-envelope'></i></span> <span class="private-message-glyph"><i class='fa fa-envelope'></i></span>
{{#if category.parentCategory}} {{#if category.parentCategory}}
{{boundCategoryLink category.parentCategory}} {{bound-category-link category.parentCategory}}
{{/if}} {{/if}}
{{boundCategoryLink category}} {{bound-category-link category}}
{{#if details.loaded}} {{#if details.loaded}}
{{topic-status topic=model}} {{topic-status topic=model}}
<a href='{{unbound url}}' {{action jumpTop}}> <a href='{{unbound url}}' {{action jumpTop}}>

View file

@ -32,9 +32,9 @@
{{#link-to 'user' invite.user}}{{avatar invite.user imageSize="tiny"}}{{/link-to}} {{#link-to 'user' invite.user}}{{avatar invite.user imageSize="tiny"}}{{/link-to}}
{{#link-to 'user' invite.user}}{{invite.user.username}}{{/link-to}} {{#link-to 'user' invite.user}}{{invite.user.username}}{{/link-to}}
</td> </td>
<td>{{unboundDate invite.redeemed_at}}</td> <td>{{date invite.redeemed_at}}</td>
{{#if can_see_invite_details}} {{#if can_see_invite_details}}
<td>{{unboundDate invite.user.last_seen_at}}</td> <td>{{date invite.user.last_seen_at}}</td>
<td>{{number invite.user.topics_entered}}</td> <td>{{number invite.user.topics_entered}}</td>
<td>{{number invite.user.posts_read_count}}</td> <td>{{number invite.user.posts_read_count}}</td>
<td>{{{unbound invite.user.time_read}}}</td> <td>{{{unbound invite.user.time_read}}}</td>

View file

@ -79,7 +79,7 @@
<div class="control-group"> <div class="control-group">
<label class="control-label">{{i18n user.avatar.title}}</label> <label class="control-label">{{i18n user.avatar.title}}</label>
<div class="controls"> <div class="controls">
{{boundAvatar model "large"}} {{bound-avatar model "large"}}
{{#if allowAvatarUpload}} {{#if allowAvatarUpload}}
<button {{action showAvatarSelector}} class="btn pad-left no-text"><i class="fa fa-pencil"></i></button> <button {{action showAvatarSelector}} class="btn pad-left no-text"><i class="fa fa-pencil"></i></button>
{{else}} {{else}}

View file

@ -2,10 +2,10 @@
<div {{bind-attr class=":item hidden deleted moderator_action"}}> <div {{bind-attr class=":item hidden deleted moderator_action"}}>
<div class='clearfix info'> <div class='clearfix info'>
<a href="{{unbound userUrl}}" class='avatar-link'><div class='avatar-wrapper'>{{avatar this imageSize="large" extraClasses="actor" ignoreTitle="true"}}</div></a> <a href="{{unbound userUrl}}" class='avatar-link'><div class='avatar-wrapper'>{{avatar this imageSize="large" extraClasses="actor" ignoreTitle="true"}}</div></a>
<span class='time'>{{unboundDate path="created_at" leaveAgo="true"}}</span> <span class='time'>{{date path="created_at" leaveAgo="true"}}</span>
<span class="title"> <span class="title">
<a href="{{unbound postUrl}}">{{unbound title}}</a> <a href="{{unbound postUrl}}">{{unbound title}}</a>
{{categoryLink category}} {{category-link category}}
</span> </span>
<span class="type">{{unbound descriptionHtml}}</span> <span class="type">{{unbound descriptionHtml}}</span>
</div> </div>

View file

@ -1,5 +1,5 @@
<div class='container'> <div class='container'>
{{customHTML "top"}} {{custom-html "top"}}
{{Discourse.globalNotice}} {{Discourse.globalNotice}}
</div> </div>
@ -64,7 +64,7 @@
<div class='details'> <div class='details'>
<div class='primary'> <div class='primary'>
{{boundAvatar model "huge"}} {{bound-avatar model "huge"}}
<div class="primary-textual"> <div class="primary-textual">
<h1>{{username}} {{{statusIcon}}}</h1> <h1>{{username}} {{{statusIcon}}}</h1>
@ -93,13 +93,13 @@
<dt>{{i18n user.website}}</dt><dd><a {{bind-attr href="website"}} target="_blank">{{websiteName}}</a></dd> <dt>{{i18n user.website}}</dt><dd><a {{bind-attr href="website"}} target="_blank">{{websiteName}}</a></dd>
{{/if}} {{/if}}
{{#if created_at}} {{#if created_at}}
<dt>{{i18n user.created}}</dt><dd>{{date created_at}}</dd> <dt>{{i18n user.created}}</dt><dd>{{bound-date created_at}}</dd>
{{/if}} {{/if}}
{{#if last_posted_at}} {{#if last_posted_at}}
<dt>{{i18n user.last_posted}}</dt><dd>{{date last_posted_at}}</dd> <dt>{{i18n user.last_posted}}</dt><dd>{{bound-date last_posted_at}}</dd>
{{/if}} {{/if}}
{{#if last_seen_at}} {{#if last_seen_at}}
<dt>{{i18n user.last_seen}}</dt><dd>{{date last_seen_at}}</dd> <dt>{{i18n user.last_seen}}</dt><dd>{{bound-date last_seen_at}}</dd>
{{/if}} {{/if}}
{{#if invited_by}} {{#if invited_by}}
<dt>{{i18n user.invited_by}}</dt><dd>{{#link-to 'user' invited_by}}{{invited_by.username}}{{/link-to}}</dd> <dt>{{i18n user.invited_by}}</dt><dd>{{#link-to 'user' invited_by}}{{invited_by.username}}{{/link-to}}</dd>