Skip to content
This repository has been archived by the owner on Jul 11, 2023. It is now read-only.

Add ability to specify field constraints #270

Open
chris48s opened this issue Sep 3, 2020 · 0 comments
Open

Add ability to specify field constraints #270

chris48s opened this issue Sep 3, 2020 · 0 comments
Labels

Comments

@chris48s
Copy link
Member

chris48s commented Sep 3, 2020

Overview

It would be useful if datapackage-ui exposed the constraints concept from the tableschema spec
https://specs.frictionlessdata.io/table-schema/#constraints

At a code level, this would require us to

  • Add a ConstraintField component. Each instance of EditorField my optionally have a ConstraintField.
  • One level down we would then need corresponding UPDATE_CONSTRAINT and REMOVE_CONSTRAINT reducers.

AFAICT as long as we build up the schema correctly on input datapackage-js should handle the additional validation for us.

The bigger challenge is probably how to present it visually. EditorField is already a bit squished with 4 UI elements and supporting constraint fully requires an additional 8 interface elements

(Feature request arising from the eLife Innovation Sprint 2020)


Please preserve this line to notify @roll (lead of this repository)

@roll roll added the feature label Sep 10, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants