-
Notifications
You must be signed in to change notification settings - Fork 27
Update 7.08.2017
Stian Håklev edited this page Aug 7, 2017
·
5 revisions
Since a lot of work has happened while Louis was away, and also some while Romain was away, I thought I’d look over the changes, and do a quick recap of what has changed, status of various projects, unresolved questions etc.
- createActivity became createPackage, and can create activities and operators (needs a bit more testing)
- removed autopublish. However, we're still publishing all collections to all users (only distinguishing between teacher and others), should restrict this further.
- all ac/op have shortDesc and description added to packages. When choosing new ac/op, shortDesc is shown, and can be expanded. Search is also provided (full-text for title/shortDesc/description).
- Activities can have exampleData, an array of title + config + activityData, which is used for preview. Activities can be previewed from the selector. ActivityData is run through the mergeFunction. You can also see exactly what the data structure is like (including the reactive data after the merge function, or after interacting with the activity)
- When configuring an activity, you can preview the activity with that exact config, if the activity is “green” (no problems, mainly to ensure that the config is correct). This let’s you merge the config with the activityData from the exampleData
- Currently the exampleData mix config and activity data. This makes it messy when we try to provide different example data in activity-specific preview... One option is to disentangle, provide one list of activityData, and one list of config... Makes preview UI a bit more complex, and also - do all configs go with all example data? So far, I think so?
- There are a bunch of different functions that validate graphs, these work on pure data. Some simple ones check that all activity types actually exist in the current FROG instance, etc. Others, like types and social structure are described below.
- Currently the graph validator is called anytime refreshUpdate() or addHistory() is called in the graph (refreshUpdate() is used from the sidepanel, to avoid adding to the undo history of the graph), and the result is stored in the store
- The result is a list of issues, with id: of component involved, severity (error | warning), error text, and error type. The error text does not include the type (operator | activity) and name of the node. This data is reflected in multiple places:
- a central indicator showing red (errors) or yellow (only warnings). Mousing-over shows a list of all errors/warnings (errors first), with node type and name appended.
- a similar indicator (same component) is shown in the side panel for operators/activities, showing only warnings/errors relevant to that node
- nodes (ac / op) have a red border color if there are any warnings/errors associated.
- The code for the UI (Validator.js etc) is getting quite convoluted, and should be refactored, although not urgent. Not sure it makes sense to use SVG instead of a simple div.
- We're adding a lot of color coding to nodes, and we might add more in the future - should probably rethink a bit at some point. Previously the border color changed to show whether an activity was selected, currently the border color reflects error status, and there's an additional border, a few pixels out, added when selected. Works, but maybe not perfect.