Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Indicators in capitalization rule do not work with title case #898

Open
1 task done
DominikaK opened this issue Sep 18, 2024 · 0 comments
Open
1 task done

Indicators in capitalization rule do not work with title case #898

DominikaK opened this issue Sep 18, 2024 · 0 comments

Comments

@DominikaK
Copy link

Check for existing issues

  • Completed

Environment

OS: macOS
Install method: Homebrew
Vale version: 3.7.1

Describe the bug / provide steps to reproduce it

When using a capitalization rule, indicators functions correctly with a $title match, but not with a $sentence match.

The following rule (Vale Studio: https://studio.vale.sh/s/bb9890c4782f80c8c30a88007219574c):

extends: capitalization
message: "'%s' should be in sentence case"
level: warning
scope: heading
match: $sentence
indicators:
    - ":"

correctly shows # Heading One to be incorrect, but # Heading: One to be correct - capital letter is ignored after the colon indicator.

However, when I change match to $title (Vale Studio: https://studio.vale.sh/s/28ca0c60b15db662d53caa8375e6f47e):

extends: capitalization
message: "'%s' should be in title case"
level: warning
scope: heading
match: $title
indicators:
    - ":"

both # Heading one and # Heading: one are marked as mistakes - the colon indicator does not make the rule ignore the lowercase "one".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant