@pie-element/multi-trait-rubric 8.1.2-next.29 → 8.1.2-next.30
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/dist/browser/{Typography-f7AYth_Y.js → Typography-B5wfbADL.js} +366 -327
- package/dist/browser/{Typography-f7AYth_Y.js.map → Typography-B5wfbADL.js.map} +1 -1
- package/dist/browser/author/index.js +7373 -7372
- package/dist/browser/author/index.js.map +1 -1
- package/dist/browser/delivery/index.js +71 -71
- package/dist/browser/editor-runtime/{Typography-DO1kiW3x.js → Typography-st4LVE7N.js} +366 -327
- package/dist/browser/editor-runtime/{Typography-DO1kiW3x.js.map → Typography-st4LVE7N.js.map} +1 -1
- package/dist/browser/editor-runtime/author/index.js +3485 -3484
- package/dist/browser/editor-runtime/author/index.js.map +1 -1
- package/dist/browser/editor-runtime/delivery/index.js +70 -70
- package/dist/index.iife.js +21 -21
- package/package.json +6 -6
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as e,
|
|
1
|
+
import { C as e, D as t, Dt as n, F as r, Mt as i, T as a, U as o, _ as s, at as c, bt as l, gt as u, i as d, n as f, nt as p, pt as m, r as h, st as g, t as _, ut as v, vt as y, x as b, xt as x, yt as S } from "../Typography-st4LVE7N.js";
|
|
2
2
|
import * as C from "react";
|
|
3
3
|
import w from "react";
|
|
4
4
|
import { createRoot as T } from "react-dom/client";
|
|
@@ -37,11 +37,11 @@ var O = class e extends CustomEvent {
|
|
|
37
37
|
});
|
|
38
38
|
//#endregion
|
|
39
39
|
//#region src/delivery/trait.tsx
|
|
40
|
-
var k = /* @__PURE__ */
|
|
41
|
-
color:
|
|
40
|
+
var k = /* @__PURE__ */ i(n(), 1), A = g("td")({
|
|
41
|
+
color: c.primaryDark(),
|
|
42
42
|
verticalAlign: "middle"
|
|
43
|
-
}), j =
|
|
44
|
-
color:
|
|
43
|
+
}), j = g("div")({
|
|
44
|
+
color: c.secondaryBackground(),
|
|
45
45
|
textAlign: "center"
|
|
46
46
|
}), M = (e) => {
|
|
47
47
|
let { trait: t, traitIndex: n, scaleIndex: r, showStandards: i, showDescription: a, scorePointsValues: o } = e, { name: s, standards: c, scorePointsDescriptors: l, description: u } = t || {};
|
|
@@ -75,17 +75,17 @@ M.propTypes = {
|
|
|
75
75
|
};
|
|
76
76
|
//#endregion
|
|
77
77
|
//#region src/delivery/scale.tsx
|
|
78
|
-
var N =
|
|
78
|
+
var N = g("div")({
|
|
79
79
|
display: "flex",
|
|
80
80
|
position: "relative"
|
|
81
|
-
}), P =
|
|
81
|
+
}), P = g("div")({
|
|
82
82
|
width: "100%",
|
|
83
83
|
overflow: "auto"
|
|
84
|
-
}), F =
|
|
84
|
+
}), F = g("table")(({ theme: e }) => ({
|
|
85
85
|
borderSpacing: 0,
|
|
86
86
|
marginBottom: e.spacing(2),
|
|
87
87
|
borderRadius: "4px",
|
|
88
|
-
color:
|
|
88
|
+
color: c.text(),
|
|
89
89
|
fontSize: e.typography.fontSize,
|
|
90
90
|
lineHeight: "16px",
|
|
91
91
|
overflow: "unset",
|
|
@@ -96,7 +96,7 @@ var N = h("div")({
|
|
|
96
96
|
"& th": {
|
|
97
97
|
padding: e.spacing(2),
|
|
98
98
|
textAlign: "left",
|
|
99
|
-
backgroundColor:
|
|
99
|
+
backgroundColor: c.secondaryBackground(),
|
|
100
100
|
verticalAlign: "bottom"
|
|
101
101
|
},
|
|
102
102
|
"& th div": { width: "200px" },
|
|
@@ -105,12 +105,12 @@ var N = h("div")({
|
|
|
105
105
|
padding: `${e.spacing(2)} ${e.spacing(1)}`,
|
|
106
106
|
verticalAlign: "top"
|
|
107
107
|
}
|
|
108
|
-
})), I =
|
|
108
|
+
})), I = g("table")({ "& td": {
|
|
109
109
|
border: 0,
|
|
110
110
|
padding: 0,
|
|
111
111
|
textAlign: "center",
|
|
112
112
|
minWidth: "200px"
|
|
113
|
-
} }), L =
|
|
113
|
+
} }), L = g("div")({ marginBottom: "4px" }), R = g("td")({ fontWeight: "normal" }), z = ({ show: e, onClick: t, extraStyles: n, children: r }) => /* @__PURE__ */ E("div", {
|
|
114
114
|
style: {
|
|
115
115
|
height: "calc(100% - 1px)",
|
|
116
116
|
top: "1px",
|
|
@@ -151,17 +151,17 @@ var B = class extends w.Component {
|
|
|
151
151
|
});
|
|
152
152
|
};
|
|
153
153
|
render() {
|
|
154
|
-
let { showRight: e, showLeft: t } = this.state, { scale: n, scaleIndex: r, showDescription: i, showPointsLabels: a, showStandards: o, arrowsDisabled: s } = this.props, { excludeZero:
|
|
154
|
+
let { showRight: e, showLeft: t } = this.state, { scale: n, scaleIndex: r, showDescription: i, showPointsLabels: a, showStandards: o, arrowsDisabled: s } = this.props, { excludeZero: l, maxPoints: u, traitLabel: d, traits: p, scorePointsLabels: m } = n || {}, g = [], _, v, y;
|
|
155
155
|
try {
|
|
156
|
-
for (let e =
|
|
157
|
-
let { traitStandards: e, traitDescriptions: t } =
|
|
156
|
+
for (let e = u; +(e >= l); --e) g.push(e);
|
|
157
|
+
let { traitStandards: e, traitDescriptions: t } = p.reduce((e, t) => ({
|
|
158
158
|
traitStandards: [...e.traitStandards, ...t.standards || []],
|
|
159
159
|
traitDescriptions: [...e.traitDescriptions, ...t.description || []]
|
|
160
160
|
}), {
|
|
161
161
|
traitStandards: [],
|
|
162
162
|
traitDescriptions: []
|
|
163
163
|
});
|
|
164
|
-
_ = i && t.length, v = a &&
|
|
164
|
+
_ = i && t.length, v = a && m.length, y = o && e.length;
|
|
165
165
|
} catch {
|
|
166
166
|
_ = !1, v = !1, y = !1;
|
|
167
167
|
}
|
|
@@ -171,9 +171,9 @@ var B = class extends w.Component {
|
|
|
171
171
|
onClick: this.scrollLeft,
|
|
172
172
|
extraStyles: {
|
|
173
173
|
left: 0,
|
|
174
|
-
background: `linear-gradient(to right, white, ${
|
|
174
|
+
background: `linear-gradient(to right, white, ${c.background()})`
|
|
175
175
|
},
|
|
176
|
-
children: /* @__PURE__ */ E(
|
|
176
|
+
children: /* @__PURE__ */ E(h, {})
|
|
177
177
|
}),
|
|
178
178
|
/* @__PURE__ */ D(P, {
|
|
179
179
|
ref: (e) => {
|
|
@@ -186,26 +186,26 @@ var B = class extends w.Component {
|
|
|
186
186
|
});
|
|
187
187
|
},
|
|
188
188
|
children: [s && (e || t) ? /* @__PURE__ */ E("div", { children: "The item is too large to fit in print mode." }) : null, /* @__PURE__ */ D(F, { children: [/* @__PURE__ */ E("thead", { children: /* @__PURE__ */ D("tr", { children: [
|
|
189
|
-
/* @__PURE__ */ E("th", { children: /* @__PURE__ */ E("div", { dangerouslySetInnerHTML: { __html:
|
|
189
|
+
/* @__PURE__ */ E("th", { children: /* @__PURE__ */ E("div", { dangerouslySetInnerHTML: { __html: d } }) }),
|
|
190
190
|
y ? /* @__PURE__ */ E("th", { children: /* @__PURE__ */ E("div", { children: "Standard(s)" }) }) : null,
|
|
191
191
|
_ ? /* @__PURE__ */ E("th", { children: /* @__PURE__ */ E("div", { children: "Description" }) }) : null,
|
|
192
|
-
|
|
192
|
+
g && g.map((e, t) => {
|
|
193
193
|
let n = "";
|
|
194
194
|
try {
|
|
195
|
-
n =
|
|
195
|
+
n = m[g.length - t - 1] || "";
|
|
196
196
|
} catch {
|
|
197
197
|
n = "";
|
|
198
198
|
}
|
|
199
199
|
return /* @__PURE__ */ E("th", { children: /* @__PURE__ */ E(I, { children: /* @__PURE__ */ D("thead", { children: [v ? /* @__PURE__ */ E("tr", { children: /* @__PURE__ */ E("td", { children: /* @__PURE__ */ E(L, { dangerouslySetInnerHTML: { __html: n } }) }) }) : null, /* @__PURE__ */ E("tr", { children: /* @__PURE__ */ E(R, { children: e === 1 ? `${e} point` : `${e} points` }) })] }) }) }, `table-header-${t}`);
|
|
200
200
|
})
|
|
201
|
-
] }) }), /* @__PURE__ */ E("tbody", { children:
|
|
201
|
+
] }) }), /* @__PURE__ */ E("tbody", { children: p && p.map((e, t) => /* @__PURE__ */ E(M, {
|
|
202
202
|
trait: e,
|
|
203
203
|
traitIndex: t,
|
|
204
204
|
showDescription: !!_,
|
|
205
205
|
showStandards: !!y,
|
|
206
206
|
scaleIndex: r,
|
|
207
|
-
scorePointsValues:
|
|
208
|
-
excludeZero:
|
|
207
|
+
scorePointsValues: g,
|
|
208
|
+
excludeZero: l
|
|
209
209
|
}, `trait_${r}_${t}`)) })] }, `scale-${r}`)]
|
|
210
210
|
}),
|
|
211
211
|
/* @__PURE__ */ E(z, {
|
|
@@ -213,9 +213,9 @@ var B = class extends w.Component {
|
|
|
213
213
|
onClick: this.scrollRight,
|
|
214
214
|
extraStyles: {
|
|
215
215
|
right: 0,
|
|
216
|
-
background: `linear-gradient(to left, white, ${
|
|
216
|
+
background: `linear-gradient(to left, white, ${c.background()})`
|
|
217
217
|
},
|
|
218
|
-
children: /* @__PURE__ */ E(
|
|
218
|
+
children: /* @__PURE__ */ E(f, {})
|
|
219
219
|
})
|
|
220
220
|
] });
|
|
221
221
|
}
|
|
@@ -242,9 +242,9 @@ B.propTypes = {
|
|
|
242
242
|
//#endregion
|
|
243
243
|
//#region ../../../node_modules/.bun/@mui+material@7.3.11+eb26afe407ed7030/node_modules/@mui/material/esm/Link/linkClasses.js
|
|
244
244
|
function V(e) {
|
|
245
|
-
return
|
|
245
|
+
return S("MuiLink", e);
|
|
246
246
|
}
|
|
247
|
-
var H =
|
|
247
|
+
var H = y("MuiLink", [
|
|
248
248
|
"root",
|
|
249
249
|
"underlineNone",
|
|
250
250
|
"underlineHover",
|
|
@@ -254,11 +254,11 @@ var H = o("MuiLink", [
|
|
|
254
254
|
]), U = ({ theme: e, ownerState: t }) => {
|
|
255
255
|
let n = t.color;
|
|
256
256
|
if ("colorSpace" in e && e.colorSpace) {
|
|
257
|
-
let r =
|
|
257
|
+
let r = x(e, `palette.${n}.main`) || x(e, `palette.${n}`) || t.color;
|
|
258
258
|
return e.alpha(r, .4);
|
|
259
259
|
}
|
|
260
|
-
let r =
|
|
261
|
-
return "vars" in e && i ? `rgba(${i} / 0.4)` :
|
|
260
|
+
let r = x(e, `palette.${n}.main`, !1) || x(e, `palette.${n}`, !1) || t.color, i = x(e, `palette.${n}.mainChannel`) || x(e, `palette.${n}Channel`);
|
|
261
|
+
return "vars" in e && i ? `rgba(${i} / 0.4)` : u(r, .4);
|
|
262
262
|
}, W = {
|
|
263
263
|
primary: !0,
|
|
264
264
|
secondary: !0,
|
|
@@ -270,25 +270,25 @@ var H = o("MuiLink", [
|
|
|
270
270
|
textSecondary: !0,
|
|
271
271
|
textDisabled: !0
|
|
272
272
|
}, G = (e) => {
|
|
273
|
-
let { classes: t, component: n, focusVisible:
|
|
274
|
-
return
|
|
273
|
+
let { classes: t, component: n, focusVisible: i, underline: a } = e;
|
|
274
|
+
return m({ root: [
|
|
275
275
|
"root",
|
|
276
|
-
`underline${
|
|
276
|
+
`underline${r(a)}`,
|
|
277
277
|
n === "button" && "button",
|
|
278
|
-
|
|
278
|
+
i && "focusVisible"
|
|
279
279
|
] }, V, t);
|
|
280
|
-
}, K =
|
|
280
|
+
}, K = g(_, {
|
|
281
281
|
name: "MuiLink",
|
|
282
282
|
slot: "Root",
|
|
283
283
|
overridesResolver: (e, t) => {
|
|
284
284
|
let { ownerState: n } = e;
|
|
285
285
|
return [
|
|
286
286
|
t.root,
|
|
287
|
-
t[`underline${
|
|
287
|
+
t[`underline${r(n.underline)}`],
|
|
288
288
|
n.component === "button" && t.button
|
|
289
289
|
];
|
|
290
290
|
}
|
|
291
|
-
})(
|
|
291
|
+
})(o(({ theme: e }) => ({ variants: [
|
|
292
292
|
{
|
|
293
293
|
props: { underline: "none" },
|
|
294
294
|
style: { textDecoration: "none" }
|
|
@@ -315,7 +315,7 @@ var H = o("MuiLink", [
|
|
|
315
315
|
props: ({ underline: e, ownerState: t }) => e === "always" && t.color === "inherit",
|
|
316
316
|
style: e.colorSpace ? { textDecorationColor: e.alpha("currentColor", .4) } : null
|
|
317
317
|
},
|
|
318
|
-
...Object.entries(e.palette).filter(
|
|
318
|
+
...Object.entries(e.palette).filter(b()).map(([t]) => ({
|
|
319
319
|
props: {
|
|
320
320
|
underline: "always",
|
|
321
321
|
color: t
|
|
@@ -364,38 +364,38 @@ var H = o("MuiLink", [
|
|
|
364
364
|
}
|
|
365
365
|
}
|
|
366
366
|
] }))), q = /*#__PURE__*/ C.forwardRef(function(t, n) {
|
|
367
|
-
let r =
|
|
367
|
+
let r = p({
|
|
368
368
|
props: t,
|
|
369
369
|
name: "MuiLink"
|
|
370
|
-
}), i =
|
|
371
|
-
e(t.target) ||
|
|
372
|
-
},
|
|
373
|
-
e(t.target) &&
|
|
374
|
-
},
|
|
370
|
+
}), i = v(), { className: a, color: o = "primary", component: s = "a", onBlur: c, onFocus: u, TypographyClasses: d, underline: f = "always", variant: m = "inherit", sx: h, ...g } = r, [_, y] = C.useState(!1), b = (t) => {
|
|
371
|
+
e(t.target) || y(!1), c && c(t);
|
|
372
|
+
}, x = (t) => {
|
|
373
|
+
e(t.target) && y(!0), u && u(t);
|
|
374
|
+
}, S = {
|
|
375
375
|
...r,
|
|
376
376
|
color: o,
|
|
377
377
|
component: s,
|
|
378
|
-
focusVisible:
|
|
379
|
-
underline:
|
|
380
|
-
variant:
|
|
378
|
+
focusVisible: _,
|
|
379
|
+
underline: f,
|
|
380
|
+
variant: m
|
|
381
381
|
};
|
|
382
382
|
return /*#__PURE__*/ E(K, {
|
|
383
383
|
color: o,
|
|
384
|
-
className:
|
|
385
|
-
classes:
|
|
384
|
+
className: l(G(S).root, a),
|
|
385
|
+
classes: d,
|
|
386
386
|
component: s,
|
|
387
|
-
onBlur:
|
|
388
|
-
onFocus:
|
|
387
|
+
onBlur: b,
|
|
388
|
+
onFocus: x,
|
|
389
389
|
ref: n,
|
|
390
|
-
ownerState:
|
|
391
|
-
variant:
|
|
392
|
-
...
|
|
393
|
-
sx: [...W[o] === void 0 ? [{ color: o }] : [], ...Array.isArray(
|
|
390
|
+
ownerState: S,
|
|
391
|
+
variant: m,
|
|
392
|
+
...g,
|
|
393
|
+
sx: [...W[o] === void 0 ? [{ color: o }] : [], ...Array.isArray(h) ? h : [h]],
|
|
394
394
|
style: {
|
|
395
|
-
...
|
|
396
|
-
...
|
|
395
|
+
...g.style,
|
|
396
|
+
...f === "always" && o !== "inherit" && !W[o] && { "--Link-underlineColor": U({
|
|
397
397
|
theme: i,
|
|
398
|
-
ownerState:
|
|
398
|
+
ownerState: S
|
|
399
399
|
}) }
|
|
400
400
|
}
|
|
401
401
|
});
|
|
@@ -408,7 +408,7 @@ function J(e) {
|
|
|
408
408
|
function Y(e, t) {
|
|
409
409
|
return !e || J(e) ? e : J(e.default) ? e.default : t && J(e[t]) ? e[t] : t && J(e[t]?.default) ? e[t].default : e;
|
|
410
410
|
}
|
|
411
|
-
var X = Y(
|
|
411
|
+
var X = Y(s, "UiLayout") || Y(ee.UiLayout, "UiLayout"), Z = d, Q = Z.default, ee = Q && typeof Q == "object" ? Q : Z, $ = class extends w.Component {
|
|
412
412
|
constructor(e) {
|
|
413
413
|
super(e), this.state = {
|
|
414
414
|
rubricOpen: !1,
|
|
@@ -419,14 +419,14 @@ var X = Y(a, "UiLayout") || Y(ee.UiLayout, "UiLayout"), Z = u, Q = Z.default, ee
|
|
|
419
419
|
this.setState({ rubricOpen: !this.state.rubricOpen }), this.setState({ linkPrefix: this.state.rubricOpen ? "Show" : "Hide" });
|
|
420
420
|
}
|
|
421
421
|
render() {
|
|
422
|
-
let { model: e } = this.props, { animationsDisabled: n } = this.props, { extraCSSRules: r, halfScoring: i, scales: a, visible: o, pointLabels: s, description:
|
|
422
|
+
let { model: e } = this.props, { animationsDisabled: n } = this.props, { extraCSSRules: r, halfScoring: i, scales: a, visible: o, pointLabels: s, description: l, standards: u, arrowsDisabled: d } = e || {};
|
|
423
423
|
if (n ||= e.animationsDisabled, !a || !o) return null;
|
|
424
424
|
let f = /* @__PURE__ */ D(X, {
|
|
425
425
|
extraCSSRules: r,
|
|
426
426
|
style: {
|
|
427
427
|
fontFamily: "Cerebri Sans",
|
|
428
|
-
color:
|
|
429
|
-
backgroundColor:
|
|
428
|
+
color: c.text(),
|
|
429
|
+
backgroundColor: c.background()
|
|
430
430
|
},
|
|
431
431
|
children: [i ? /* @__PURE__ */ E("div", {
|
|
432
432
|
style: { marginBottom: "16px" },
|
|
@@ -435,19 +435,19 @@ var X = Y(a, "UiLayout") || Y(ee.UiLayout, "UiLayout"), Z = u, Q = Z.default, ee
|
|
|
435
435
|
scale: e,
|
|
436
436
|
scaleIndex: t,
|
|
437
437
|
showPointsLabels: s,
|
|
438
|
-
showDescription:
|
|
439
|
-
showStandards:
|
|
440
|
-
arrowsDisabled:
|
|
438
|
+
showDescription: l,
|
|
439
|
+
showStandards: u,
|
|
440
|
+
arrowsDisabled: d
|
|
441
441
|
}, `scale_${t}`))]
|
|
442
442
|
});
|
|
443
443
|
return n ? f : /* @__PURE__ */ D(X, {
|
|
444
444
|
extraCSSRules: r,
|
|
445
445
|
style: {
|
|
446
|
-
color:
|
|
447
|
-
backgroundColor:
|
|
446
|
+
color: c.text(),
|
|
447
|
+
backgroundColor: c.background()
|
|
448
448
|
},
|
|
449
449
|
children: [/* @__PURE__ */ D(q, {
|
|
450
|
-
style: { backgroundColor:
|
|
450
|
+
style: { backgroundColor: c.background() },
|
|
451
451
|
href: this.dudUrl,
|
|
452
452
|
onClick: this.toggleRubric,
|
|
453
453
|
children: [this.state.linkPrefix, " Rubric"]
|
|
@@ -494,7 +494,7 @@ var te = class extends HTMLElement {
|
|
|
494
494
|
}
|
|
495
495
|
_scheduleMathRender = () => {
|
|
496
496
|
this._mathRenderPending || (this._mathRenderPending = !0, requestAnimationFrame(() => {
|
|
497
|
-
this._mathObserver && this._mathObserver.disconnect(),
|
|
497
|
+
this._mathObserver && this._mathObserver.disconnect(), a(this), this._mathRenderPending = !1, setTimeout(() => {
|
|
498
498
|
this._mathObserver && this._mathObserver.observe(this, {
|
|
499
499
|
childList: !0,
|
|
500
500
|
subtree: !0
|