@digilogiclabs/saas-factory-ui 2.8.0 → 2.8.1
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/index.d.mts +7 -2
- package/dist/index.d.ts +7 -2
- package/dist/index.js +119 -66
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +119 -66
- package/dist/index.mjs.map +1 -1
- package/dist/web/index.d.mts +7 -2
- package/dist/web/index.d.ts +7 -2
- package/dist/web/index.js +119 -66
- package/dist/web/index.js.map +1 -1
- package/dist/web/index.mjs +119 -66
- package/dist/web/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/web/index.mjs
CHANGED
|
@@ -30759,17 +30759,13 @@ function DiceRoller({
|
|
|
30759
30759
|
const starts = currentPositionsRef.current ?? defaultPositions(w, h, clampedCount);
|
|
30760
30760
|
const frames = simulateDice(w, h, effectiveSize, starts, clampedCount);
|
|
30761
30761
|
for (let i = 0; i < clampedCount; i++) {
|
|
30762
|
-
|
|
30763
|
-
|
|
30764
|
-
|
|
30765
|
-
|
|
30766
|
-
|
|
30767
|
-
|
|
30768
|
-
|
|
30769
|
-
);
|
|
30770
|
-
} else {
|
|
30771
|
-
writeCubeRotation(i, 0, 0, (Math.random() - 0.5) * 720, false);
|
|
30772
|
-
}
|
|
30762
|
+
writeCubeRotation(
|
|
30763
|
+
i,
|
|
30764
|
+
(Math.random() - 0.5) * 720,
|
|
30765
|
+
(Math.random() - 0.5) * 720,
|
|
30766
|
+
(Math.random() - 0.5) * 720,
|
|
30767
|
+
false
|
|
30768
|
+
);
|
|
30773
30769
|
const el = dieWrapperRefs.current[i];
|
|
30774
30770
|
if (el) el.style.transition = "none";
|
|
30775
30771
|
const shadow = shadowRefs.current[i];
|
|
@@ -30830,8 +30826,10 @@ function DiceRoller({
|
|
|
30830
30826
|
const lz = (Math.random() > 0.5 ? 1 : -1) * 360;
|
|
30831
30827
|
writeCubeRotation(i, lx, ly, lz, true, tilt);
|
|
30832
30828
|
} else {
|
|
30829
|
+
const lx = (Math.random() > 0.5 ? 1 : -1) * 720;
|
|
30830
|
+
const ly = (Math.random() > 0.5 ? 1 : -1) * 360;
|
|
30833
30831
|
const lz = (Math.random() > 0.5 ? 1 : -1) * 720 + tilt;
|
|
30834
|
-
writeCubeRotation(i,
|
|
30832
|
+
writeCubeRotation(i, lx, ly, lz, true);
|
|
30835
30833
|
}
|
|
30836
30834
|
}
|
|
30837
30835
|
});
|
|
@@ -30990,60 +30988,115 @@ function DiceRoller({
|
|
|
30990
30988
|
)) : (() => {
|
|
30991
30989
|
const shape = POLY_SHAPES[sides];
|
|
30992
30990
|
const shown = results?.[d] ?? sides;
|
|
30993
|
-
|
|
30994
|
-
"
|
|
30995
|
-
|
|
30996
|
-
|
|
30997
|
-
|
|
30998
|
-
|
|
30999
|
-
|
|
31000
|
-
|
|
31001
|
-
|
|
31002
|
-
|
|
31003
|
-
|
|
31004
|
-
|
|
31005
|
-
|
|
31006
|
-
|
|
31007
|
-
|
|
31008
|
-
|
|
31009
|
-
|
|
31010
|
-
|
|
31011
|
-
|
|
31012
|
-
|
|
31013
|
-
|
|
31014
|
-
|
|
31015
|
-
|
|
31016
|
-
|
|
31017
|
-
|
|
31018
|
-
|
|
31019
|
-
|
|
31020
|
-
|
|
31021
|
-
|
|
31022
|
-
|
|
31023
|
-
|
|
31024
|
-
|
|
31025
|
-
|
|
31026
|
-
|
|
31027
|
-
|
|
31028
|
-
|
|
31029
|
-
|
|
31030
|
-
|
|
31031
|
-
|
|
31032
|
-
|
|
31033
|
-
|
|
31034
|
-
|
|
31035
|
-
|
|
31036
|
-
|
|
31037
|
-
|
|
31038
|
-
|
|
31039
|
-
|
|
31040
|
-
|
|
31041
|
-
|
|
31042
|
-
|
|
31043
|
-
|
|
31044
|
-
|
|
31045
|
-
|
|
31046
|
-
|
|
30991
|
+
const cardFaceStyle = {
|
|
30992
|
+
position: "absolute",
|
|
30993
|
+
inset: 0,
|
|
30994
|
+
display: "block",
|
|
30995
|
+
overflow: "visible",
|
|
30996
|
+
backfaceVisibility: "hidden"
|
|
30997
|
+
};
|
|
30998
|
+
return /* @__PURE__ */ jsxs86(Fragment30, { children: [
|
|
30999
|
+
/* @__PURE__ */ jsxs86(
|
|
31000
|
+
"svg",
|
|
31001
|
+
{
|
|
31002
|
+
viewBox: "0 0 100 100",
|
|
31003
|
+
width: "100%",
|
|
31004
|
+
height: "100%",
|
|
31005
|
+
style: cardFaceStyle,
|
|
31006
|
+
"aria-hidden": "true",
|
|
31007
|
+
children: [
|
|
31008
|
+
/* @__PURE__ */ jsx113(
|
|
31009
|
+
"polygon",
|
|
31010
|
+
{
|
|
31011
|
+
points: shape.points,
|
|
31012
|
+
fill: colors.face,
|
|
31013
|
+
stroke: colors.faceBorder,
|
|
31014
|
+
strokeWidth: 2.5,
|
|
31015
|
+
strokeLinejoin: "round",
|
|
31016
|
+
style: { transition: "fill 0.3s, stroke 0.3s" }
|
|
31017
|
+
}
|
|
31018
|
+
),
|
|
31019
|
+
/* @__PURE__ */ jsx113(
|
|
31020
|
+
"polygon",
|
|
31021
|
+
{
|
|
31022
|
+
points: shape.points,
|
|
31023
|
+
fill: "none",
|
|
31024
|
+
stroke: colors.faceBorder,
|
|
31025
|
+
strokeWidth: 1.5,
|
|
31026
|
+
strokeLinejoin: "round",
|
|
31027
|
+
opacity: 0.55,
|
|
31028
|
+
transform: "translate(50 50) scale(0.76) translate(-50 -50)"
|
|
31029
|
+
}
|
|
31030
|
+
),
|
|
31031
|
+
/* @__PURE__ */ jsx113(
|
|
31032
|
+
"text",
|
|
31033
|
+
{
|
|
31034
|
+
ref: getNumeralSetter(d),
|
|
31035
|
+
x: 50,
|
|
31036
|
+
y: shape.textY,
|
|
31037
|
+
textAnchor: "middle",
|
|
31038
|
+
dominantBaseline: "central",
|
|
31039
|
+
fontSize: 100 * shape.fontScale,
|
|
31040
|
+
fontWeight: 800,
|
|
31041
|
+
fill: colors.pip,
|
|
31042
|
+
style: {
|
|
31043
|
+
fontVariantNumeric: "tabular-nums",
|
|
31044
|
+
transition: "fill 0.3s",
|
|
31045
|
+
userSelect: "none"
|
|
31046
|
+
},
|
|
31047
|
+
children: formatDieValue(shown, sides)
|
|
31048
|
+
}
|
|
31049
|
+
)
|
|
31050
|
+
]
|
|
31051
|
+
}
|
|
31052
|
+
),
|
|
31053
|
+
/* @__PURE__ */ jsxs86(
|
|
31054
|
+
"svg",
|
|
31055
|
+
{
|
|
31056
|
+
viewBox: "0 0 100 100",
|
|
31057
|
+
width: "100%",
|
|
31058
|
+
height: "100%",
|
|
31059
|
+
style: {
|
|
31060
|
+
...cardFaceStyle,
|
|
31061
|
+
transform: "rotateY(180deg)"
|
|
31062
|
+
},
|
|
31063
|
+
"aria-hidden": "true",
|
|
31064
|
+
children: [
|
|
31065
|
+
/* @__PURE__ */ jsx113(
|
|
31066
|
+
"polygon",
|
|
31067
|
+
{
|
|
31068
|
+
points: shape.points,
|
|
31069
|
+
fill: colors.face,
|
|
31070
|
+
stroke: colors.faceBorder,
|
|
31071
|
+
strokeWidth: 2.5,
|
|
31072
|
+
strokeLinejoin: "round",
|
|
31073
|
+
style: { transition: "fill 0.3s, stroke 0.3s" }
|
|
31074
|
+
}
|
|
31075
|
+
),
|
|
31076
|
+
/* @__PURE__ */ jsx113(
|
|
31077
|
+
"polygon",
|
|
31078
|
+
{
|
|
31079
|
+
points: shape.points,
|
|
31080
|
+
fill: "none",
|
|
31081
|
+
stroke: colors.faceBorder,
|
|
31082
|
+
strokeWidth: 1.5,
|
|
31083
|
+
strokeLinejoin: "round",
|
|
31084
|
+
opacity: 0.55,
|
|
31085
|
+
transform: "translate(50 50) scale(0.76) translate(-50 -50)"
|
|
31086
|
+
}
|
|
31087
|
+
),
|
|
31088
|
+
/* @__PURE__ */ jsx113(
|
|
31089
|
+
"polygon",
|
|
31090
|
+
{
|
|
31091
|
+
points: shape.points,
|
|
31092
|
+
fill: "#000",
|
|
31093
|
+
opacity: 0.14
|
|
31094
|
+
}
|
|
31095
|
+
)
|
|
31096
|
+
]
|
|
31097
|
+
}
|
|
31098
|
+
)
|
|
31099
|
+
] });
|
|
31047
31100
|
})()
|
|
31048
31101
|
}
|
|
31049
31102
|
)
|