@pie-element/number-line 6.9.3-next.41 → 6.9.3-next.56
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -40,13 +40,16 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
40
40
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
41
41
|
|
|
42
42
|
var Point = _numberLine.pointChooser.Point;
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
43
|
+
|
|
44
|
+
var styles = function styles(theme) {
|
|
45
|
+
return {
|
|
46
|
+
displayToggles: {
|
|
47
|
+
paddingTop: theme.spacing.unit * 2.5,
|
|
48
|
+
'& > :first-child': {
|
|
49
|
+
marginRight: theme.spacing.unit
|
|
50
|
+
}
|
|
48
51
|
}
|
|
49
|
-
}
|
|
52
|
+
};
|
|
50
53
|
};
|
|
51
54
|
|
|
52
55
|
var PointConfig = /*#__PURE__*/function (_React$Component) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/point-config.jsx"],"names":["Point","pointChooser","styles","displayToggles","paddingTop","marginRight","PointConfig","props","state","selection","point","update","_stateUpdate","value","display","types","reduce","acc","setState","onSelectionChange","classes","icons","map","toLowerCase","toggle","bind","active","toggleAll","React","Component","PropTypes","func","object","name"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AACA,IAAQA,KAAR,GAAkBC,wBAAlB,CAAQD,KAAR
|
|
1
|
+
{"version":3,"sources":["../src/point-config.jsx"],"names":["Point","pointChooser","styles","theme","displayToggles","paddingTop","spacing","unit","marginRight","PointConfig","props","state","selection","point","update","_stateUpdate","value","display","types","reduce","acc","setState","onSelectionChange","classes","icons","map","toLowerCase","toggle","bind","active","toggleAll","React","Component","PropTypes","func","object","name"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AACA,IAAQA,KAAR,GAAkBC,wBAAlB,CAAQD,KAAR;;AAEA,IAAME,MAAM,GAAG,SAATA,MAAS,CAACC,KAAD;AAAA,SAAY;AACzBC,IAAAA,cAAc,EAAE;AACdC,MAAAA,UAAU,EAAEF,KAAK,CAACG,OAAN,CAAcC,IAAd,GAAqB,GADnB;AAEd,0BAAoB;AAClBC,QAAAA,WAAW,EAAEL,KAAK,CAACG,OAAN,CAAcC;AADT;AAFN;AADS,GAAZ;AAAA,CAAf;;IASME,W;;;;;AAMJ,uBAAYC,KAAZ,EAAmB;AAAA;;AAAA;AACjB,8BAAMA,KAAN;AACA,UAAKC,KAAL,GAAa;AACXC,MAAAA,SAAS,EAAEF,KAAK,CAACE;AADN,KAAb;AAFiB;AAKlB;;;;WAED,gBAAOC,KAAP,EAAc;AACZ,UAAMC,MAAM,qBAAQ,KAAKH,KAAL,CAAWC,SAAnB,CAAZ;;AACAE,MAAAA,MAAM,CAACD,KAAD,CAAN,GAAgB,CAACC,MAAM,CAACD,KAAD,CAAvB;;AACA,WAAKE,YAAL,CAAkBD,MAAlB;AACD;;;WAED,mBAAUE,KAAV,EAAiB;AACf,UAAMC,OAAO,GAAG,oCAAIR,WAAW,CAACS,KAAhB,EAAuBC,MAAvB,CAA8B,UAACC,GAAD,EAAMP,KAAN,EAAgB;AAC5DO,QAAAA,GAAG,CAACP,KAAD,CAAH,GAAaG,KAAb;AAEA,eAAOI,GAAP;AACD,OAJe,EAIb,EAJa,CAAhB;;AAMA,WAAKL,YAAL,CAAkBE,OAAlB;AACD;;;WAED,sBAAaL,SAAb,EAAwB;AAAA;;AACtB,WAAKS,QAAL,CAAc;AAAET,QAAAA,SAAS,EAATA;AAAF,OAAd,EAA6B,YAAM;AACjC,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EAAAA,SAAS,EAAEqB,sBAAUE,MAFJ;AAGjBZ,EAAAA,OAAO,EAAEU,sBAAUE;AAHF,C;AAoErB1B,WAAW,CAACS,KAAZ,GAAoB,CAAC,IAAD,EAAO,KAAP,EAAc,KAAd,EAAqB,KAArB,EAA4B,KAA5B,EAAmC,KAAnC,EAA0C,KAA1C,EAAiD,KAAjD,EAAwD,KAAxD,CAApB;;eAEe,wBAAWhB,MAAX,EAAmB;AAAEkC,EAAAA,IAAI,EAAE;AAAR,CAAnB,EAA4C3B,WAA5C,C","sourcesContent":["import Button from '@material-ui/core/Button';\nimport React from 'react';\nimport { pointChooser } from '@pie-element/number-line';\nimport { withStyles } from '@material-ui/core/styles';\nimport PropTypes from 'prop-types';\nconst { Point } = pointChooser;\n\nconst styles = (theme) => ({\n displayToggles: {\n paddingTop: theme.spacing.unit * 2.5,\n '& > :first-child': {\n marginRight: theme.spacing.unit,\n },\n },\n});\n\nclass PointConfig extends React.Component {\n static propTypes = {\n onSelectionChange: PropTypes.func,\n selection: PropTypes.object,\n classes: PropTypes.object,\n };\n constructor(props) {\n super(props);\n this.state = {\n selection: props.selection,\n };\n }\n\n toggle(point) {\n const update = { ...this.state.selection };\n update[point] = !update[point];\n this._stateUpdate(update);\n }\n\n toggleAll(value) {\n const display = [...PointConfig.types].reduce((acc, point) => {\n acc[point] = value;\n\n return acc;\n }, {});\n\n this._stateUpdate(display);\n }\n\n _stateUpdate(selection) {\n this.setState({ selection }, () => {\n this.props.onSelectionChange(this.state.selection);\n });\n }\n\n active(point) {\n return this.state.selection[point] === true; // ? 'active' : '';\n }\n\n render() {\n const { classes } = this.props;\n\n const icons = PointConfig.types.map((point) => {\n return (\n <Point\n iconKey={point.toLowerCase()}\n key={point.toLowerCase()}\n onClick={this.toggle.bind(this, point)}\n active={this.active(point)}\n />\n );\n });\n\n return (\n <div>\n <div>{icons}</div>\n <div className={classes.displayToggles}>\n <Button variant=\"outlined\" size=\"small\" onClick={this.toggleAll.bind(this, true)}>\n Display All\n </Button>\n <Button variant=\"outlined\" size=\"small\" onClick={this.toggleAll.bind(this, false)}>\n None\n </Button>\n </div>\n </div>\n );\n }\n}\n\nPointConfig.types = ['PF', 'LFF', 'LEF', 'LFE', 'LEE', 'RFN', 'RFP', 'REN', 'REP'];\n\nexport default withStyles(styles, { name: 'PointConfig' })(PointConfig);\n"],"file":"point-config.js"}
|
package/configure/package.json
CHANGED
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
"dependencies": {
|
|
8
8
|
"@material-ui/core": "^3.9.2",
|
|
9
9
|
"@pie-framework/pie-configure-events": "^1.3.0",
|
|
10
|
-
"@pie-lib/config-ui": "^11.5.
|
|
11
|
-
"@pie-lib/editable-html": "^9.5.
|
|
10
|
+
"@pie-lib/config-ui": "^11.5.5",
|
|
11
|
+
"@pie-lib/editable-html": "^9.5.17",
|
|
12
12
|
"react": "^16.8.1",
|
|
13
13
|
"react-dom": "^16.8.1"
|
|
14
14
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/number-line/point-chooser/styles.js"],"names":["iconHeight","iconWidth","noselect","styleElement","index","display","width","height","position","top","cursor","background","img","backgroundPosition","textDecoration","pointChooser","
|
|
1
|
+
{"version":3,"sources":["../../../src/number-line/point-chooser/styles.js"],"names":["iconHeight","iconWidth","noselect","styleElement","index","display","width","height","position","top","cursor","background","img","backgroundPosition","textDecoration","pointChooser","justifyContent","borderRadius","padding","deleteIconHolder","deleteIcon","fill","transition","opacity","elementSelector","Object","assign","controls","paddingTop","pf","lff","lef","lfe","lee","rfn","rfp","ren","rep"],"mappings":";;;;;;;;;AAGA;;AAHA,IAAMA,UAAU,GAAG,EAAnB;AACA,IAAMC,SAAS,GAAG,EAAlB;;AAIA,IAAMC,QAAQ,GAAG,SAAXA,QAAW;AAAA,SAAO;AACtB,6BAAyB;AAAO;AADV;AAEtB,2BAAuB;AAAO;AAFR;AAGtB,0BAAsB;AAAO;AAHP;AAItB,wBAAoB;AAAO;A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ADT;AAEEY,IAAAA,OAAO,EAAE;AAFX,GADe,EAKfhB,QAAQ,EALO,CApBJ;AA2BbyB,EAAAA,QAAQ,EAAE;AACRtB,IAAAA,OAAO,EAAE,MADD;AAERuB,IAAAA,UAAU,EAAE;AAFJ,GA3BG;AA+BbC,EAAAA,EAAE,EAAE1B,YAAY,CAAC,CAAD,CA/BH;AAgCb2B,EAAAA,GAAG,EAAE3B,YAAY,CAAC,CAAD,CAhCJ;AAiCb4B,EAAAA,GAAG,EAAE5B,YAAY,CAAC,CAAD,CAjCJ;AAkCb6B,EAAAA,GAAG,EAAE7B,YAAY,CAAC,CAAD,CAlCJ;AAmCb8B,EAAAA,GAAG,EAAE9B,YAAY,CAAC,CAAD,CAnCJ;AAoCb+B,EAAAA,GAAG,EAAE/B,YAAY,CAAC,CAAD,CApCJ;AAqCbgC,EAAAA,GAAG,EAAEhC,YAAY,CAAC,CAAD,CArCJ;AAsCbiC,EAAAA,GAAG,EAAEjC,YAAY,CAAC,CAAD,CAtCJ;AAuCbkC,EAAAA,GAAG,EAAElC,YAAY,CAAC,CAAD;AAvCJ,C","sourcesContent":["const iconHeight = 41;\nconst iconWidth = 42;\n\nimport img from './img';\n\nconst noselect = () => ({\n '-webkit-touch-callout': 'none' /* iOS Safari */,\n '-webkit-user-select': 'none' /* Safari */,\n '-khtml-user-select': 'none' /* Konqueror HTML */,\n '-moz-user-select': 'none' /* Firefox */,\n '-ms-user-select': 'none' /* Internet Explorer/Edge */,\n 'user-select': 'none' /* Non-prefixed version, currently\n supported by Chrome and Opera */,\n});\n\nconst styleElement = (index) => ({\n display: 'inline-block',\n width: iconWidth,\n height: iconHeight,\n position: 'relative',\n top: '1px',\n cursor: 'pointer',\n background: `url(${img}) -${index * iconWidth}px 0px`,\n '&.active, &.active:hover': {\n backgroundPosition: `-${index * iconWidth}px -${2 * iconHeight}px`,\n },\n '&:hover': {\n textDecoration: 'none',\n backgroundPosition: `-${index * iconWidth}px -${iconHeight}px`,\n },\n});\n\nexport default {\n pointChooser: {\n display: 'flex',\n justifyContent: 'space-between',\n borderRadius: '4px',\n padding: '1px',\n },\n deleteIconHolder: {\n position: 'relative',\n top: '3px',\n width: '30px',\n },\n deleteIcon: {\n fill: 'black',\n cursor: 'pointer',\n transition: 'opacity 100ms linear',\n '&:hover': {\n opacity: '0.5',\n },\n },\n elementSelector: Object.assign(\n {\n width: '55%',\n padding: '1px',\n },\n noselect(),\n ),\n controls: {\n display: 'flex',\n paddingTop: '7px',\n },\n pf: styleElement(0),\n lff: styleElement(1),\n lef: styleElement(2),\n lfe: styleElement(3),\n lee: styleElement(4),\n rfn: styleElement(5),\n rfp: styleElement(6),\n ren: styleElement(7),\n rep: styleElement(8),\n};\n"],"file":"styles.js"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pie-element/number-line",
|
|
3
|
-
"version": "6.9.3-next.
|
|
3
|
+
"version": "6.9.3-next.56+d8bf26886",
|
|
4
4
|
"repository": "pie-framework/pie-elements",
|
|
5
5
|
"description": "",
|
|
6
6
|
"publishConfig": {
|
|
@@ -8,11 +8,11 @@
|
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"@material-ui/core": "^3.9.2",
|
|
11
|
-
"@pie-lib/correct-answer-toggle": "^2.3.
|
|
11
|
+
"@pie-lib/correct-answer-toggle": "^2.3.67",
|
|
12
12
|
"@pie-lib/feedback": "^0.4.42",
|
|
13
13
|
"@pie-lib/icons": "^2.4.42",
|
|
14
|
-
"@pie-lib/math-rendering": "^2.5.
|
|
15
|
-
"@pie-lib/render-ui": "^4.14.
|
|
14
|
+
"@pie-lib/math-rendering": "^2.5.13",
|
|
15
|
+
"@pie-lib/render-ui": "^4.14.17",
|
|
16
16
|
"classnames": "^2.2.5",
|
|
17
17
|
"d3-scale": "^3.2.1",
|
|
18
18
|
"d3-selection": "^1.4.1",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
},
|
|
28
28
|
"author": "pie framework developers",
|
|
29
29
|
"license": "ISC",
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "d8bf268864c1023d6595698b86fb1f7ea82c39d4",
|
|
31
31
|
"scripts": {
|
|
32
32
|
"postpublish": "../../scripts/postpublish"
|
|
33
33
|
},
|