Revert "UX: replace closed topic icon with discourse-no-entry"

This reverts commit 040b8c00a4.

We decided to keep status quo for now
This commit is contained in:
Sam Saffron 2020-04-25 13:01:25 +10:00
parent d516a88b4c
commit 1f6eaf26a1
No known key found for this signature in database
GPG Key ID: B9606168D2FFD9F5
10 changed files with 21 additions and 33 deletions

View File

@ -23,17 +23,15 @@ export default Component.extend({
@discourseComputed("topic.closed", "topic.archived")
topicClosedArchived(closed, archived) {
if (closed && archived) {
this._set("closedArchived", "discourse-no-entry", "locked_and_archived");
this._set("closedArchived", "lock", "locked_and_archived");
this._reset("closed");
this._reset("archived");
return true;
} else {
this._reset("closedArchived");
closed
? this._set("closed", "discourse-no-entry", "locked")
: this._reset("closed");
closed ? this._set("closed", "lock", "locked") : this._reset("closed");
archived
? this._set("archived", "discourse-no-entry", "archived")
? this._set("archived", "lock", "archived")
: this._reset("archived");
return false;
}

View File

@ -30,7 +30,7 @@ addBulkButton("showChangeCategory", "change_category", {
class: "btn-default"
});
addBulkButton("closeTopics", "close_topics", {
icon: "discourse-no-entry",
icon: "lock",
class: "btn-default"
});
addBulkButton("archiveTopics", "archive_topics", {

View File

@ -10,10 +10,10 @@ export default ArrayProxy.extend({
};
if (topic.get("closed") && topic.get("archived")) {
renderIcon("discourse-no-entry", "locked_and_archived");
renderIcon("lock", "locked_and_archived");
} else {
renderIconIf("closed", "discourse-no-entry", "locked");
renderIconIf("archived", "discourse-no-entry", "archived");
renderIconIf("closed", "lock", "locked");
renderIconIf("archived", "lock", "archived");
}
this.forEach(args => renderIconIf(...args));

View File

@ -38,14 +38,11 @@ export default EmberObject.extend({
}
if (topic.get("closed") && topic.get("archived")) {
results.push({
icon: "discourse-no-entry",
key: "locked_and_archived"
});
results.push({ icon: "lock", key: "locked_and_archived" });
} else if (topic.get("closed")) {
results.push({ icon: "discourse-no-entry", key: "locked" });
results.push({ icon: "lock", key: "locked" });
} else if (topic.get("archived")) {
results.push({ icon: "discourse-no-entry", key: "archived" });
results.push({ icon: "lock", key: "archived" });
}
if (topic.get("pinned")) {

View File

@ -233,7 +233,7 @@
{{#if showNotificationsTab}}
<li>
{{#link-to 'userNotifications'}}
{{d-icon "discourse-comment" class="glyph"}}{{i18n 'user.notifications'}}
{{d-icon "comment" class="glyph"}}{{i18n 'user.notifications'}}
{{/link-to}}
</li>
{{/if}}

View File

@ -32,8 +32,10 @@ export function actionDescription(actionCode, createdAt, username) {
}
const icons = {
"closed.enabled": "discourse-no-entry",
"autoclosed.enabled": "discourse-no-entry",
"closed.enabled": "lock",
"closed.disabled": "unlock-alt",
"autoclosed.enabled": "lock",
"autoclosed.disabled": "unlock-alt",
"archived.enabled": "folder",
"archived.disabled": "folder-open",
"pinned.enabled": "thumbtack",
@ -50,7 +52,7 @@ const icons = {
user_left: "minus-circle",
removed_user: "minus-circle",
removed_group: "minus-circle",
public_topic: "discourse-comment",
public_topic: "comment",
private_topic: "envelope",
autobumped: "hand-point-right"
};

View File

@ -165,7 +165,7 @@ export default createWidget("topic-admin-menu", {
className: "topic-admin-open",
buttonClass: "btn-default",
action: "toggleClosed",
icon: "discourse-comment",
icon: "unlock",
label: "actions.open"
});
} else {
@ -173,7 +173,7 @@ export default createWidget("topic-admin-menu", {
className: "topic-admin-close",
buttonClass: "btn-default",
action: "toggleClosed",
icon: "discourse-no-entry",
icon: "lock",
label: "actions.close"
});
}
@ -239,7 +239,7 @@ export default createWidget("topic-admin-menu", {
action: isPrivateMessage
? "convertToPublicTopic"
: "convertToPrivateMessage",
icon: isPrivateMessage ? "discourse-comment" : "envelope",
icon: isPrivateMessage ? "comment" : "envelope",
label: isPrivateMessage
? "actions.make_public"
: "actions.make_private"

View File

@ -62,8 +62,6 @@ module SvgSprite
"discourse-bell-one",
"discourse-bell-slash",
"discourse-compress",
"discourse-comment",
"discourse-no-entry",
"discourse-expand",
"download",
"ellipsis-h",

View File

@ -12,7 +12,7 @@ widgetTest("basics", {
});
},
test(assert) {
assert.ok(find(".topic-status .d-icon-discourse-no-entry").length);
assert.ok(find(".topic-status .d-icon-discourse-comment-slash").length);
}
});

View File

@ -19,7 +19,7 @@ Additional SVG icons
<symbol id='discourse-bell-exclamation' viewBox="0 0 448 512">
<path d="M439.4 362.3c-19.3-20.8-55.5-52-55.5-154.3 0-77.7-54.5-139.9-127.9-155.2V32c0-17.7-14.3-32-32-32s-32 14.3-32 32v20.8C118.6 68.1 64.1 130.3 64.1 208c0 102.3-36.2 133.5-55.5 154.3-6 6.4-8.6 14.1-8.6 21.7.1 16.4 13 32 32.1 32h383.8c19.1 0 32-15.6 32.1-32 .1-7.6-2.6-15.3-8.6-21.7zM201.7 116.6h44.6c6.5 0 11.7 5.5 11.4 12l-6.5 123.8c-.3 6.1-5.3 10.9-11.4 10.9h-31.6c-6.1 0-11.1-4.8-11.4-10.9l-6.5-123.8c-.3-6.6 4.9-12 11.4-12zM224 361.3c-18.6 0-33.7-15.1-33.7-33.7s15.1-33.7 33.7-33.7 33.7 15.1 33.7 33.7-15.1 33.7-33.7 33.7zM224 512c35.3 0 64-28.7 64-64H160c0 35.3 28.7 64 64 64z"/>
</symbol>
<!-- "Discourse Bell One" is a Discourse derivative of https://fontawesome.com/icons/bell -->
<!-- Discourse Bell One" is a Discourse derivative of https://fontawesome.com/icons/bell -->
<symbol id='discourse-bell-one' viewBox="0 0 448 512">
<path d="M224 512c35.3 0 64-28.7 64-64H160c0 35.3 28.7 64 64 64zM439.4 362.3c-19.3-20.8-55.5-52-55.5-154.3 0-77.7-54.5-139.9-127.9-155.2V32c0-17.7-14.3-32-32-32s-32 14.3-32 32v20.8C118.6 68.1 64.1 130.3 64.1 208c0 102.3-36.2 133.5-55.5 154.3-6 6.4-8.6 14.1-8.6 21.7.1 16.4 13 32 32.1 32h383.8c19.1 0 32-15.6 32.1-32 .1-7.6-2.6-15.3-8.6-21.7zm-145.2-28c0 8.6-7 15.5-15.5 15.5h-97c-8.6 0-15.5-7-15.5-15.5v-15.8c0-8.6 7-15.5 15.5-15.5h27.1V192.5l-5.1 3.1c-6 6.1-15.9 6.2-22 .1l-11.2-11.1c-6.1-6-6.2-15.9-.1-22l31.6-31.9c3.2-3.2 7.4-4.7 11.5-4.6h26.6c8.6 0 11.5 7 11.5 15.5v161.3h27.1c8.6 0 15.5 7 15.5 15.5v15.9z"/>
</symbol>
@ -27,11 +27,4 @@ Additional SVG icons
<symbol id='discourse-bell-slash' viewBox="0 0 448 512">
<path d="M442.7 396.2L36.5 70.7c-6.9-5.5-17-4.4-22.5 2.5L4 85.6c-5.5 6.9-4.4 17 2.5 22.5l406.2 325.5c6.9 5.5 17 4.4 22.5-2.5l10-12.5c5.5-6.9 3.7-17.7-3.2-23.2l.7.8zM67.5 368c16.7-22 34.5-55.8 41.4-110.6l-45.5-35.6C60.2 312.6 27 342.5 8.6 362.3 2.6 368.7 0 376.4 0 384c.1 16.4 13 32 32.1 32h279.7l-61.4-48H67.5zM224 96c61.9 0 112 50.1 112 112 0 .2-.1.4-.1.6 0 16.8 1.2 31.8 2.8 45.7l59.5 46.5c-8.3-22.1-14.3-51.5-14.3-92.9 0-77.7-54.5-139.9-127.9-155.2V32c0-17.7-14.3-32-32-32s-32 14.3-32 32v20.8c-26 5.4-49.4 16.9-69.1 32.7l38.2 29.8C179 103.2 200.6 96 224 96zm0 416c35.3 0 64-28.6 64-64H160c0 35.4 28.7 64 64 64z"/>
</symbol>
<!-- "Discourse Comment" is a Discourse derivative of https://fontawesome.com/icons/comment?style=regular that has been built to be a bit more legible at small sizes -->
<symbol id='discourse-comment' viewBox="0 0 550 512">
<path d="M26 479.3c-7.5 0-14.8-3.3-19.8-9.2-6.5-7.6-8-18.3-4-27.4l54.6-123.2c-17-28.9-23.2-66.1-18.6-110.7C44.6 146.2 77.8 90.2 131.6 51 184.4 12.4 251.1-5.2 319.2 1.3c72.8 7 139.6 41.5 183.3 94.9 38.4 46.8 56.3 104.4 50.3 162-6.5 62.5-39.6 118.5-93.4 157.7-45.7 33.3-101.7 51-160 51-9.2 0-18.4-.4-27.6-1.3-32.8-3.1-64.2-11.7-93.4-25.4L32.6 478.4c-2.2.6-4.4.9-6.6.9zm155.2-92.7c4.1 0 8.2 1 11.9 2.9 25.9 13.4 54 21.6 83.6 24.4 7.5.7 15 1.1 22.5 1.1 104 0 192.3-69.1 201.9-162 4.5-43.8-9.3-87.7-38.8-123.7-35-42.7-89-70.4-148-76.1-113.5-10.9-214.1 61.4-224.4 161-3.9 38.1 1.8 67.3 17 86.9 5.9 7.6 7.1 17.7 3.2 26.5l-38.5 87 102.9-27c2.3-.7 4.5-1 6.7-1z"/>
</symbol>
<symbol id='discourse-no-entry' viewBox="0 0 496 496">
<path d="M248 0C111 0 0 111 0 248s111 248 248 248 248-111 248-248S385 0 248 0zm161.3 299.9H86.6c-11.4 0-20.6-10.1-20.6-22.5v-58.7c0-12.4 9.2-22.5 20.6-22.5h322.5c11.4 0 20.7 10.2 20.7 22.7v58.5c.1 12.4-9.1 22.5-20.5 22.5z"/>
</symbol>
</svg>

Before

Width:  |  Height:  |  Size: 5.2 KiB

After

Width:  |  Height:  |  Size: 4.1 KiB