Add styling to or create a better submit "button"

Created on 27 July 2020, over 4 years ago
Updated 10 June 2024, 7 months ago

Problem/Motivation

The "Post as [user]" isn't designed well enough to indicate "click here to post the comment". Installation went smooth, however my first test was like "Type into the box, cool, OK how do I submit it??" (Mouse over the "Post as ..." Huh, nothing happens... What if I click? OOOoohhh, gotta click "Post as ..." to get it to submit... Well that's not going to be confusing for people. Wonder if I can theme it...)

Steps to reproduce

Install the module, visit page with comments enabled.

Proposed resolution

Option A) Create better styling to show that the text is the actual "button".

Option B) Add a text field in the settings (/admin/config/react_comments) that will allow the text to be changed to whatever the site maintainer desires. Example they could type: "Post Comment Now", or "Post Now", or "Comment Now". Whatever they feel makes sense for their user base.

Remaining tasks

User interface changes

Here's some loose styling I came up with:

button.rc_add-comment {
  background-color: #2196F3;
  color: #fff;
  border-radius: 3px;
  transition: .125s ease-in;
  height: 30px !important;
  margin-right: 8px;
}

button.rc_add-comment:hover {
  background-color: #555;
}

.rc_is-open .rc_input-actions {
  height: 50px;
  display: flex;
  align-items: center;
}

Note: I chose to make the button area bigger in favor making the entire comment box bigger. The module does a great job of expanding on CR, so I didn't see the need to make the box allow 2 lines before a CR expansion.

Attached image of suggested before & after

API changes

Data model changes

Release notes snippet

✨ Feature request
Status

Closed: outdated

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States philsward

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024