@pie-element/match 7.4.2-next.5 → 7.5.0

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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [7.5.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match@7.4.1...@pie-element/match@7.5.0) (2024-03-26)
7
+
8
+
9
+ ### Features
10
+
11
+ * Replace math-rendering package with math-rendering-accessible-package for accessibility PD-1870 ([a416664](https://github.com/pie-framework/pie-elements/commit/a41666452b86426a35e8501ab2a4ac95f327ad53))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [7.4.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match@7.4.0...@pie-element/match@7.4.1) (2024-03-21)
7
18
 
8
19
 
@@ -3,6 +3,14 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [6.8.2](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@6.8.1...@pie-element/match-configure@6.8.2) (2024-03-26)
7
+
8
+ **Note:** Version bump only for package @pie-element/match-configure
9
+
10
+
11
+
12
+
13
+
6
14
  ## [6.8.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@6.8.0...@pie-element/match-configure@6.8.1) (2024-03-21)
7
15
 
8
16
 
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pie-element/match-configure",
3
3
  "private": true,
4
- "version": "6.8.1",
4
+ "version": "6.8.2",
5
5
  "description": "",
6
6
  "main": "lib/index.js",
7
7
  "module": "src/index.js",
@@ -10,7 +10,7 @@
10
10
  "@material-ui/core": "^3.9.2",
11
11
  "@material-ui/icons": "^3.0.1",
12
12
  "@pie-framework/pie-configure-events": "^1.3.0",
13
- "@pie-lib/pie-toolbox": "1.11.1",
13
+ "@pie-lib/pie-toolbox": "1.12.1",
14
14
  "classnames": "^2.2.5",
15
15
  "debug": "^3.1.0",
16
16
  "lodash": "^4.17.15",
@@ -3,6 +3,14 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [6.3.2](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-controller@6.3.1...@pie-element/match-controller@6.3.2) (2024-03-26)
7
+
8
+ **Note:** Version bump only for package @pie-element/match-controller
9
+
10
+
11
+
12
+
13
+
6
14
  ## [6.3.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-controller@6.3.0...@pie-element/match-controller@6.3.1) (2024-03-21)
7
15
 
8
16
 
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pie-element/match-controller",
3
3
  "private": true,
4
- "version": "6.3.1",
4
+ "version": "6.3.2",
5
5
  "description": "",
6
6
  "main": "lib/index.js",
7
7
  "module": "src/index.js",
@@ -9,7 +9,7 @@
9
9
  "test": "./node_modules/.bin/jest"
10
10
  },
11
11
  "dependencies": {
12
- "@pie-lib/pie-toolbox": "1.11.1",
12
+ "@pie-lib/pie-toolbox": "1.12.1",
13
13
  "debug": "^3.1.0"
14
14
  },
15
15
  "devDependencies": {
package/lib/index.js CHANGED
@@ -35,7 +35,7 @@ var _main = _interopRequireDefault(require("./main"));
35
35
 
36
36
  var _piePlayerEvents = require("@pie-framework/pie-player-events");
37
37
 
38
- var _mathRendering = require("@pie-lib/pie-toolbox/math-rendering");
38
+ var _mathRenderingAccessible = require("@pie-lib/pie-toolbox/math-rendering-accessible");
39
39
 
40
40
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
41
41
 
@@ -123,7 +123,7 @@ var Match = /*#__PURE__*/function (_HTMLElement) {
123
123
  });
124
124
 
125
125
  _reactDom["default"].render(el, this, function () {
126
- (0, _mathRendering.renderMath)(_this);
126
+ (0, _mathRenderingAccessible.renderMath)(_this);
127
127
  });
128
128
  }
129
129
  }]);
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.js"],"names":["isComplete","session","model","ids","rows","map","r","id","reduce","acc","arr","answers","hasChoice","Array","isArray","includes","Match","m","_model","config","_render","_session","s","complete","dispatchEvent","SessionChangedEvent","tagName","toLowerCase","el","React","createElement","Main","onSessionChange","sessionChanged","bind","ReactDOM","render","HTMLElement"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAIO,IAAMA,UAAU,GAAG,SAAbA,UAAa,CAACC,OAAD,EAAUC,KAAV,EAAoB;AAAA;;AAC5C,MAAMC,GAAG,GAAG,CAAAD,KAAK,SAAL,IAAAA,KAAK,WAAL,2BAAAA,KAAK,CAAEE,IAAP,4DAAaC,GAAb,CAAiB,UAACC,CAAD;AAAA,WAAOA,CAAC,CAACC,EAAT;AAAA,GAAjB,MAAiC,EAA7C;AAEA,SAAOJ,GAAG,CAACK,MAAJ,CAAW,UAACC,GAAD,EAAMF,EAAN,EAAa;AAC7B,QAAI,CAACE,GAAL,EAAU;AACR,aAAO,KAAP;AACD;;AAED,QAAMC,GAAG,GAAGT,OAAO,CAACU,OAAR,IAAmBV,OAAO,CAACU,OAAR,CAAgBJ,EAAhB,CAA/B;AACA,QAAMK,SAAS,GAAGC,KAAK,CAACC,OAAN,CAAcJ,GAAd,KAAsBA,GAAG,CAACK,QAAJ,CAAa,IAAb,CAAxC;AAEA,WAAOH,SAAS,IAAIH,GAApB;AACD,GATM,EASJ,IATI,CAAP;AAUD,CAbM;;;;IAecO,K;;;;;AACnB,mBAAc;AAAA;AAAA;AAEb;;;;SAED,aAAUC,CAAV,EAAa;AACX;AACA;AACA,WAAKC,MAAL,mCAAmBD,CAAnB,GAA0B,CAAAA,CAAC,SAAD,IAAAA,CAAC,WAAD,YAAAA,CAAC,CAAEE,MAAH,KAAa,EAAvC;;AACA,WAAKC,OAAL;AACD;;;SAOD,eAAc;AACZ,aAAO,KAAKC,QAAZ;AACD,K;SAPD,aAAYC,CAAZ,EAAe;AACb,WAAKD,QAAL,GAAgBC,CAAhB;;AACA,WAAKF,OAAL;AACD;;;WAMD,wBAAeE,CAAf,EAAkB;AAChB,WAAKD,QAAL,CAAcV,OAAd,GAAwBW,CAAC,CAACX,OAA1B;AACA,UAAMY,QAAQ,GAAGvB,UAAU,CAAC,KAAKqB,QAAN,EAAgB,KAAKH,MAArB,CAA3B;AAEA,WAAKM,aAAL,CAAmB,IAAIC,oCAAJ,CAAwB,KAAKC,OAAL,CAAaC,WAAb,EAAxB,EAAoDJ,QAApD,CAAnB;;AAEA,WAAKH,OAAL;AACD;;;WAED,6BAAoB;AAClB,WAAKA,OAAL;AACD;;;WAED,mBAAU;AAAA;;AACR,UAAI,CAAC,KAAKF,MAAN,IAAgB,CAAC,KAAKG,QAA1B,EAAoC;AAClC;AACD;;AAED,UAAMO,EAAE,gBAAGC,kBAAMC,aAAN,CAAoBC,gBAApB,EAA0B;AACnC7B,QAAAA,KAAK,EAAE,KAAKgB,MADuB;AAEnCjB,QAAAA,OAAO,EAAE,KAAKoB,QAFqB;AAGnCW,QAAAA,eAAe,EAAE,KAAKC,cAAL,CAAoBC,IAApB,CAAyB,IAAzB;AAHkB,OAA1B,CAAX;;AAMAC,2BAASC,MAAT,CAAgBR,EAAhB,EAAoB,IAApB,EAA0B,YAAM;AAC9B,uCAAW,KAAX;AACD,OAFD;AAGD;;;kDAhDgCS,W","sourcesContent":["import React from 'react';\nimport ReactDOM from 'react-dom';\nimport Main from './main';\nimport { SessionChangedEvent } from '@pie-framework/pie-player-events';\nimport { renderMath } from '@pie-lib/pie-toolbox/math-rendering';\n\nexport { Main as Component };\n\nexport const isComplete = (session, model) => {\n const ids = model?.rows?.map((r) => r.id) || [];\n\n return ids.reduce((acc, id) => {\n if (!acc) {\n return false;\n }\n\n const arr = session.answers && session.answers[id];\n const hasChoice = Array.isArray(arr) && arr.includes(true);\n\n return hasChoice && acc;\n }, true);\n};\n\nexport default class Match extends HTMLElement {\n constructor() {\n super();\n }\n\n set model(m) {\n // config object props should be part of the model props\n // model.config should be no longer used\n this._model = { ...m, ...(m?.config || {}) };\n this._render();\n }\n\n set session(s) {\n this._session = s;\n this._render();\n }\n\n get session() {\n return this._session;\n }\n\n sessionChanged(s) {\n this._session.answers = s.answers;\n const complete = isComplete(this._session, this._model);\n\n this.dispatchEvent(new SessionChangedEvent(this.tagName.toLowerCase(), complete));\n\n this._render();\n }\n\n connectedCallback() {\n this._render();\n }\n\n _render() {\n if (!this._model || !this._session) {\n return;\n }\n\n const el = React.createElement(Main, {\n model: this._model,\n session: this._session,\n onSessionChange: this.sessionChanged.bind(this),\n });\n\n ReactDOM.render(el, this, () => {\n renderMath(this);\n });\n }\n}\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../src/index.js"],"names":["isComplete","session","model","ids","rows","map","r","id","reduce","acc","arr","answers","hasChoice","Array","isArray","includes","Match","m","_model","config","_render","_session","s","complete","dispatchEvent","SessionChangedEvent","tagName","toLowerCase","el","React","createElement","Main","onSessionChange","sessionChanged","bind","ReactDOM","render","HTMLElement"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAIO,IAAMA,UAAU,GAAG,SAAbA,UAAa,CAACC,OAAD,EAAUC,KAAV,EAAoB;AAAA;;AAC5C,MAAMC,GAAG,GAAG,CAAAD,KAAK,SAAL,IAAAA,KAAK,WAAL,2BAAAA,KAAK,CAAEE,IAAP,4DAAaC,GAAb,CAAiB,UAACC,CAAD;AAAA,WAAOA,CAAC,CAACC,EAAT;AAAA,GAAjB,MAAiC,EAA7C;AAEA,SAAOJ,GAAG,CAACK,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0B;AACnC7B,QAAAA,KAAK,EAAE,KAAKgB,MADuB;AAEnCjB,QAAAA,OAAO,EAAE,KAAKoB,QAFqB;AAGnCW,QAAAA,eAAe,EAAE,KAAKC,cAAL,CAAoBC,IAApB,CAAyB,IAAzB;AAHkB,OAA1B,CAAX;;AAMAC,2BAASC,MAAT,CAAgBR,EAAhB,EAAoB,IAApB,EAA0B,YAAM;AAC9B,iDAAW,KAAX;AACD,OAFD;AAGD;;;kDAhDgCS,W","sourcesContent":["import React from 'react';\nimport ReactDOM from 'react-dom';\nimport Main from './main';\nimport { SessionChangedEvent } from '@pie-framework/pie-player-events';\nimport { renderMath } from '@pie-lib/pie-toolbox/math-rendering-accessible';\n\nexport { Main as Component };\n\nexport const isComplete = (session, model) => {\n const ids = model?.rows?.map((r) => r.id) || [];\n\n return ids.reduce((acc, id) => {\n if (!acc) {\n return false;\n }\n\n const arr = session.answers && session.answers[id];\n const hasChoice = Array.isArray(arr) && arr.includes(true);\n\n return hasChoice && acc;\n }, true);\n};\n\nexport default class Match extends HTMLElement {\n constructor() {\n super();\n }\n\n set model(m) {\n // config object props should be part of the model props\n // model.config should be no longer used\n this._model = { ...m, ...(m?.config || {}) };\n this._render();\n }\n\n set session(s) {\n this._session = s;\n this._render();\n }\n\n get session() {\n return this._session;\n }\n\n sessionChanged(s) {\n this._session.answers = s.answers;\n const complete = isComplete(this._session, this._model);\n\n this.dispatchEvent(new SessionChangedEvent(this.tagName.toLowerCase(), complete));\n\n this._render();\n }\n\n connectedCallback() {\n this._render();\n }\n\n _render() {\n if (!this._model || !this._session) {\n return;\n }\n\n const el = React.createElement(Main, {\n model: this._model,\n session: this._session,\n onSessionChange: this.sessionChanged.bind(this),\n });\n\n ReactDOM.render(el, this, () => {\n renderMath(this);\n });\n }\n}\n"],"file":"index.js"}
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "access": "public"
5
5
  },
6
6
  "repository": "pie-framework/pie-elements",
7
- "version": "7.4.2-next.5+96cce1e36",
7
+ "version": "7.5.0",
8
8
  "main": "lib/index.js",
9
9
  "description": "",
10
10
  "scripts": {
@@ -13,7 +13,7 @@
13
13
  "dependencies": {
14
14
  "@material-ui/core": "^3.9.2",
15
15
  "@pie-framework/pie-player-events": "^0.1.0",
16
- "@pie-lib/pie-toolbox": "1.11.1",
16
+ "@pie-lib/pie-toolbox": "1.12.1",
17
17
  "classnames": "^2.2.5",
18
18
  "debug": "^4.1.1",
19
19
  "lodash": "^4.17.10",
@@ -23,6 +23,6 @@
23
23
  },
24
24
  "author": "",
25
25
  "license": "ISC",
26
- "gitHead": "96cce1e3652d26891d49386372ddbff4e88f3409",
26
+ "gitHead": "c65f2206a61f3195c7f9d66462b5d82be321705f",
27
27
  "module": "src/index.js"
28
28
  }