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

fix(schema): Make label & description optional for hidden actions #69

Merged
merged 2 commits into from
Sep 24, 2019

Conversation

xavdid
Copy link
Contributor

@xavdid xavdid commented Sep 21, 2019

Noticed the other day that hidden triggers needed label/description. This loosens that requirement.

The one thing I still need to test is that the editor plays nicely with this. I'll do that before I merge it.

@xavdid xavdid requested a review from eliangcs as a code owner September 21, 2019 02:45
Copy link
Member

@eliangcs eliangcs left a comment

Choose a reason for hiding this comment

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

Two suggestions, otherwise it's good to merge. 👍

new jsonschema.ValidationError(
`visible actions must have a label and description`,
action,
`/${_.capitalize(actionType)}Schema`,
Copy link
Member

Choose a reason for hiding this comment

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

Should we link to BasicDisplaySchema instead?

`visible actions must have a label and description`,
action,
`/${_.capitalize(actionType)}Schema`,
`instance.${key}.key`,
Copy link
Member

Choose a reason for hiding this comment

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

Ideally, I think the path should be instance.${key}.display.label or instance.${key}.display.description to be more accurate, but I'm ok with instance.${key}.display too.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

went with instance.creates.foo.display, which is the path to where the dev will need to fix the issue. Good catch!

@xavdid
Copy link
Contributor Author

xavdid commented Sep 24, 2019

confirmed locally this works without issue in the editor!

@xavdid xavdid merged commit 8328a0d into master Sep 24, 2019
@xavdid xavdid deleted the non-required-label branch September 24, 2019 04:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants