The latest release of the Wordcount plugin provides a few options that are not yet available as options in the Drupal plugin. It would be nice, if these options could be added to the Drupal plugin as well:

  • showRemaining (default: false)
  • countBytesAsChars (default: false)
  • countLineBreaks (default: false)
  • hardLimit (default: true)

Comments

FeyP created an issue. See original summary.

feyp’s picture

Assigned: feyp » Unassigned
Status: Active » Needs review
StatusFileSize
new5.4 KB

Attached is a patch against 8.x-1.x-dev.

feyp’s picture

StatusFileSize
new5.25 KB

Sorry, accidentally included another modification that shouldn't have been in the patch... Here is the correct one.

feyp’s picture

StatusFileSize
new5.14 KB

Sorry again, I guess it just isn't my day today...

saivaishnavijupudi’s picture

StatusFileSize
new6.05 KB

I have found the following phpcs standard errors

saivaishnavijupudi’s picture

StatusFileSize
new9.59 KB

patch for the coding standard errors

kevinquillen’s picture

Assigned: Unassigned » kevinquillen
martijn de wit’s picture

//off topic
@kevinquillen maybe you can enable Automated testing for this module. Would be nice to add tests to the patches.

giuseppe87’s picture

StatusFileSize
new5.14 KB
new1.6 KB

I couldn't apply the #6 patch so I rerolled #4 patch because of a small error on hard_limit:

!empty($settings['plugins']['wordcount']['hard_limit'])

always returned true, being the not-default value = 0, so that option actually didn't work.

kevinquillen’s picture

Project tests enabled.

kevinquillen’s picture

StatusFileSize
new6.05 KB

Patch does not apply, also does not update the config schema. Rerolling. This applied for me in 9.1 and the interface was updated.

kevinquillen’s picture

Status: Needs review » Reviewed & tested by the community

Patches apply on D8/D9. RTBC.

kevinquillen’s picture

Status: Reviewed & tested by the community » Needs work
kevinquillen’s picture

StatusFileSize
new6.03 KB

Fixing the last 4 coding standards messages from #11.

kevinquillen’s picture

Status: Needs work » Reviewed & tested by the community

Marking RTBC. Builds complete, patch applies, coding standards resolved.

  • kevinquillen committed ed4e319 on 8.x-1.x
    Issue #2963731 by FeyP, kevinquillen, saivaishnavijupudi, Giuseppe87:...
kevinquillen’s picture

Committed. Thanks all!

kevinquillen’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.