As Kris mentioned, only some icons need special treatment. Notifications are one of those, so that’s why you needed to use notification.solved.accepted_notification. In the case of the solved icon in the post controls, it’s using the generic icon name, so you will only be able to change it globally when using the replaceIcon method.
If you want to get really specific, I think you will need to override the addPostMenuButton function that’s defined in the solved plugin. Try this:
<script type="text/discourse-plugin" version="0.8">
const { iconNode } = require("discourse-common/lib/icon-library");
api.addPostMenuButton("solved", attrs => {
const currentUser = api.getCurrentUser();
const canAccept = attrs.can_accept_answer;
const canUnaccept = attrs.can_unaccept_answer;
const accepted = attrs.accepted_answer;
const isOp = currentUser && currentUser.id === attrs.topicCreatedById;
const position =
!accepted && canAccept && !isOp ? "second-last-hidden" : "first";
if (canAccept) {
return {
action: "acceptAnswer",
icon: "far-check-square",
className: "unaccepted",
title: "solved.accept_answer",
label: "solved.solution",
position
};
} else if (canUnaccept && accepted) {
const title = canUnaccept
? "solved.unaccept_answer"
: "solved.accepted_answer";
return {
action: "unacceptAnswer",
icon: "thumbs-up", // MODIFIED HERE
title,
className: "accepted fade-out",
position,
label: "solved.solution"
};
} else if (!canAccept && accepted) {
return {
className: "hidden",
disabled: "true",
position,
beforeButton(h) {
return h(
"span.accepted-text",
{
title: I18n.t("solved.accepted_description")
},
[
h("span", iconNode("thumbs-up")), // MODIFIED HERE
h("span.accepted-label", I18n.t("solved.solution"))
]
);
}
};
}
});
</script>