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

Modify attr-name regex to include fields with arguments #1711

Merged
merged 2 commits into from
Jan 17, 2019
Merged

Modify attr-name regex to include fields with arguments #1711

merged 2 commits into from
Jan 17, 2019

Conversation

kuldar
Copy link
Contributor

@kuldar kuldar commented Jan 17, 2019

I'm very green at Prism themes and Regex, so I'd love if someone would sanity-check this. But it seems like the current GraphQL component doesn't apply attr-name class to schema fields with attributes (e.g. user(id: ID!): User).

I did my best Googling and tried to modify the regex syntax to also include cases where colon appears after a set of parenthesis.

screenshot 2019-01-17 at 16 51 34

I'm very green at Prism themes and Regex, so I'd love if someone would sanity-check this. But it seems like the current GraphQL component doesn't apply `attr-name` class to schema fields with attributes (e.g. `user(id: ID!): User`).

I did my best Googling and tried to modify the regex syntax to also include cases where colon is after a set of parenthesis.
Copy link
Member

@RunDevelopment RunDevelopment left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for contributing!

I left you a little comment concerning your regex.
You also have to run npx gulp (Gulp) to create the minified files.

components/prism-graphql.js Outdated Show resolved Hide resolved
@RunDevelopment RunDevelopment merged commit 44aeffb into PrismJS:master Jan 17, 2019
@RunDevelopment
Copy link
Member

Thank you for contributing!

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

Successfully merging this pull request may close these issues.

None yet

2 participants