A platform for community discussion. Free, open, simple.
UX: Poll style fix, button classes
Krisbe5e889b1b55
diff --git a/plugins/poll/assets/javascripts/widgets/discourse-poll.js.es6 b/plugins/poll/assets/javascripts/widgets/discourse-poll.js.es6index 39d4d16049b..f3ae85f855b 100644--- a/plugins/poll/assets/javascripts/widgets/discourse-poll.js.es6+++ b/plugins/poll/assets/javascripts/widgets/discourse-poll.js.es6@@ -420,7 +420,9 @@ createWidget("discourse-poll-buttons", {const castVotesDisabled = !attrs.canCastVotes;contents.push(this.attach("button", {- className: `btn cast-votes ${castVotesDisabled ? "" : "btn-primary"}`,+ className: `btn cast-votes ${+ castVotesDisabled ? "btn-default" : "btn-primary"+ }`,label: "poll.cast-votes.label",title: "poll.cast-votes.title",disabled: castVotesDisabled,@@ -433,7 +435,7 @@ createWidget("discourse-poll-buttons", {if (attrs.showResults || hideResultsDisabled) {contents.push(this.attach("button", {- className: "btn toggle-results",+ className: "btn btn-default toggle-results",label: "poll.hide-results.label",title: "poll.hide-results.title",icon: "far-eye-slash",@@ -449,7 +451,7 @@ createWidget("discourse-poll-buttons", {} else {contents.push(this.attach("button", {- className: "btn toggle-results",+ className: "btn btn-default toggle-results",label: "poll.show-results.label",title: "poll.show-results.title",icon: "far-eye",@@ -492,7 +494,7 @@ createWidget("discourse-poll-buttons", {if (!attrs.isAutomaticallyClosed) {contents.push(this.attach("button", {- className: "btn toggle-status",+ className: "btn btn-default toggle-status",label: "poll.open.label",title: "poll.open.title",icon: "unlock-alt",diff --git a/plugins/poll/assets/stylesheets/common/poll.scss b/plugins/poll/assets/stylesheets/common/poll.scssindex 63f671d9eeb..c66bb0f1d8a 100644--- a/plugins/poll/assets/stylesheets/common/poll.scss+++ b/plugins/poll/assets/stylesheets/common/poll.scss@@ -59,6 +59,10 @@ div.poll {margin: 0.25em 0;color: $primary-medium;}+ .info-text + .info-text,+ button + .info-text {+ margin-left: 0.5em;+ }}.poll-voters:not(:empty) {diff --git a/plugins/poll/config/locales/client.en.yml b/plugins/poll/config/locales/client.en.ymlindex a44a852cb6a..a57c3eb1aad 100644--- a/plugins/poll/config/locales/client.en.yml+++ b/plugins/poll/config/locales/client.en.yml@@ -72,7 +72,7 @@ en:confirm: "Are you sure you want to close this poll?"automatic_close:- closes_in: "closes in <strong>%{timeLeft}</strong>"+ closes_in: "Closes in <strong>%{timeLeft}</strong>."age: "closed <strong>%{age}</strong>"error_while_toggling_status: "Sorry, there was an error toggling the status of this poll."