Skip to content

Commit fe699bc

Browse files
committed
v0.4.0
1 parent bd67c72 commit fe699bc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+3636
-845
lines changed

README.md

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ A number of useful constants are exported as enums. They are as follows:
6161
| `ADD_ARGUMENT` | Allows the user add an argument to a function definition | `{type: EXTRA_TYPES.ADD_ARGUMENT, argumentType: 'hatType'}` |
6262
| `ADD_ARGUMENT_GROUP` | A macro for specifying arguments that can be added to a function definition | `{type: EXTRA_TYPES.ADD_ARGUMENT_GROUP, allowed: ['hatType','bootType']}` |
6363
| `DEBUG_TOGGLE` | Shows the data for a given block, useful in debugging | `EXTRA_TYPES.DEBUG_TOGGLE` |
64+
| `DIVIDER` | Shows a simple divider to separate groups | `EXTRA_TYPES.DIVIDER` |
65+
| `LABEL` | Shows a simple, non-interactive label | `{type: EXTRA_TYPES.LABEL}, label: 'Sizes'` |
6466

6567
### Store Data
6668

@@ -171,14 +173,24 @@ const properties = {
171173
}
172174
/* A field called 'Speed' that stores a numerical
173175
value in each instance's `properties.speed` field.
174-
It must be between 0 and 2, and is by default 1.
176+
It must be between 0 and 20, and is by default 1.
177+
It is visually scaled by 0.1, so appears to the user
178+
to range between 0 and 2, incrementing by steps of 0.1.
179+
Units are in 'm/s'. Visual Precision indicates the
180+
number of decimal places to use when displaying
181+
the number to the users, so this would show values
182+
to one decimal place.
175183
*/
176184
speed: {
177185
name: "Speed",
178186
type: SIMPLE_PROPERTY_TYPES.NUMBER,
179187
default: 1,
180188
min: 0,
181-
max: 2
189+
max: 20,
190+
step: 1,
191+
units: 'm/s',
192+
visualScaling: 0.1,
193+
visualPrecision: 1
182194
},
183195
/* A field called 'Do Funky' that stores a boolean
184196
value in each instance's `properties.doFunky` field.

dist/components/Block/ExpandCarrot.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,16 @@ var _web = require("@react-spring/web");
1616
var _reactSpring = require("react-spring");
1717

1818
var ExpandCarrot = function ExpandCarrot(_ref) {
19-
var expanded = _ref.expanded;
19+
var expanded = _ref.expanded,
20+
onClick = _ref.onClick;
2021
var carrotStyle = (0, _web.useSpring)({
2122
rotate: expanded ? '90deg' : '0deg',
2223
config: _reactSpring.config.wobbly,
2324
height: 20,
2425
width: 20
2526
});
2627
return /*#__PURE__*/_react.default.createElement(_web.animated.div, {
28+
onClick: onClick,
2729
style: carrotStyle
2830
}, /*#__PURE__*/_react.default.createElement(_fi.FiChevronRight, null));
2931
};

0 commit comments

Comments
 (0)