analytica-frontend-lib 1.0.72 → 1.0.73
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/Accordation/index.js +119 -0
- package/dist/Accordation/index.js.map +1 -1
- package/dist/Accordation/index.mjs +119 -0
- package/dist/Accordation/index.mjs.map +1 -1
- package/dist/Card/index.d.mts +10 -1
- package/dist/Card/index.d.ts +10 -1
- package/dist/Card/index.js +121 -0
- package/dist/Card/index.js.map +1 -1
- package/dist/Card/index.mjs +120 -0
- package/dist/Card/index.mjs.map +1 -1
- package/dist/index.css +48 -0
- package/dist/index.css.map +1 -1
- package/dist/index.js +119 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +119 -0
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +48 -0
- package/dist/styles.css.map +1 -1
- package/package.json +1 -1
|
@@ -1584,6 +1584,125 @@ var CardSimulado = (0, import_react.forwardRef)(
|
|
|
1584
1584
|
);
|
|
1585
1585
|
}
|
|
1586
1586
|
);
|
|
1587
|
+
var CardTest = (0, import_react.forwardRef)(
|
|
1588
|
+
({
|
|
1589
|
+
title,
|
|
1590
|
+
duration,
|
|
1591
|
+
questionsCount,
|
|
1592
|
+
additionalInfo,
|
|
1593
|
+
selected = false,
|
|
1594
|
+
onSelect,
|
|
1595
|
+
className = "",
|
|
1596
|
+
...props
|
|
1597
|
+
}, ref) => {
|
|
1598
|
+
const handleClick = () => {
|
|
1599
|
+
if (onSelect) {
|
|
1600
|
+
onSelect(!selected);
|
|
1601
|
+
}
|
|
1602
|
+
};
|
|
1603
|
+
const handleKeyDown = (event) => {
|
|
1604
|
+
if ((event.key === "Enter" || event.key === " ") && onSelect) {
|
|
1605
|
+
event.preventDefault();
|
|
1606
|
+
onSelect(!selected);
|
|
1607
|
+
}
|
|
1608
|
+
};
|
|
1609
|
+
const isSelectable = !!onSelect;
|
|
1610
|
+
const getQuestionsText = (count) => {
|
|
1611
|
+
const singular = count === 1 ? "quest\xE3o" : "quest\xF5es";
|
|
1612
|
+
return `${count} ${singular}`;
|
|
1613
|
+
};
|
|
1614
|
+
const displayInfo = questionsCount ? getQuestionsText(questionsCount) : additionalInfo || "";
|
|
1615
|
+
const baseClasses = "flex flex-row items-center p-4 gap-2 w-full max-w-full bg-background shadow-soft-shadow-1 rounded-xl isolate border-0 text-left";
|
|
1616
|
+
const interactiveClasses = isSelectable ? "cursor-pointer focus:outline-none focus:ring-2 focus:ring-primary-950 focus:ring-offset-2" : "";
|
|
1617
|
+
const selectedClasses = selected ? "ring-2 ring-primary-950 ring-offset-2" : "";
|
|
1618
|
+
if (isSelectable) {
|
|
1619
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1620
|
+
"button",
|
|
1621
|
+
{
|
|
1622
|
+
ref,
|
|
1623
|
+
type: "button",
|
|
1624
|
+
className: `${baseClasses} ${interactiveClasses} ${selectedClasses} ${className}`.trim(),
|
|
1625
|
+
onClick: handleClick,
|
|
1626
|
+
onKeyDown: handleKeyDown,
|
|
1627
|
+
"aria-pressed": selected,
|
|
1628
|
+
...props,
|
|
1629
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-col justify-between gap-[27px] flex-grow min-h-[67px] w-full min-w-0", children: [
|
|
1630
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1631
|
+
Text_default,
|
|
1632
|
+
{
|
|
1633
|
+
size: "md",
|
|
1634
|
+
weight: "bold",
|
|
1635
|
+
className: "text-text-950 tracking-[0.2px] leading-[19px] truncate",
|
|
1636
|
+
children: title
|
|
1637
|
+
}
|
|
1638
|
+
),
|
|
1639
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-row justify-start items-end gap-4 w-full", children: [
|
|
1640
|
+
duration && /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-row items-center gap-1 flex-shrink-0", children: [
|
|
1641
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_phosphor_react2.Clock, { size: 16, className: "text-text-700" }),
|
|
1642
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1643
|
+
Text_default,
|
|
1644
|
+
{
|
|
1645
|
+
size: "sm",
|
|
1646
|
+
className: "text-text-700 leading-[21px] whitespace-nowrap",
|
|
1647
|
+
children: duration
|
|
1648
|
+
}
|
|
1649
|
+
)
|
|
1650
|
+
] }),
|
|
1651
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1652
|
+
Text_default,
|
|
1653
|
+
{
|
|
1654
|
+
size: "sm",
|
|
1655
|
+
className: "text-text-700 leading-[21px] flex-grow truncate",
|
|
1656
|
+
children: displayInfo
|
|
1657
|
+
}
|
|
1658
|
+
)
|
|
1659
|
+
] })
|
|
1660
|
+
] })
|
|
1661
|
+
}
|
|
1662
|
+
);
|
|
1663
|
+
}
|
|
1664
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1665
|
+
"div",
|
|
1666
|
+
{
|
|
1667
|
+
ref,
|
|
1668
|
+
className: `${baseClasses} ${className}`.trim(),
|
|
1669
|
+
...props,
|
|
1670
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-col justify-between gap-[27px] flex-grow min-h-[67px] w-full min-w-0", children: [
|
|
1671
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1672
|
+
Text_default,
|
|
1673
|
+
{
|
|
1674
|
+
size: "md",
|
|
1675
|
+
weight: "bold",
|
|
1676
|
+
className: "text-text-950 tracking-[0.2px] leading-[19px] truncate",
|
|
1677
|
+
children: title
|
|
1678
|
+
}
|
|
1679
|
+
),
|
|
1680
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-row justify-start items-end gap-4 w-full", children: [
|
|
1681
|
+
duration && /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-row items-center gap-1 flex-shrink-0", children: [
|
|
1682
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_phosphor_react2.Clock, { size: 16, className: "text-text-700" }),
|
|
1683
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1684
|
+
Text_default,
|
|
1685
|
+
{
|
|
1686
|
+
size: "sm",
|
|
1687
|
+
className: "text-text-700 leading-[21px] whitespace-nowrap",
|
|
1688
|
+
children: duration
|
|
1689
|
+
}
|
|
1690
|
+
)
|
|
1691
|
+
] }),
|
|
1692
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1693
|
+
Text_default,
|
|
1694
|
+
{
|
|
1695
|
+
size: "sm",
|
|
1696
|
+
className: "text-text-700 leading-[21px] flex-grow truncate min-w-0",
|
|
1697
|
+
children: displayInfo
|
|
1698
|
+
}
|
|
1699
|
+
)
|
|
1700
|
+
] })
|
|
1701
|
+
] })
|
|
1702
|
+
}
|
|
1703
|
+
);
|
|
1704
|
+
}
|
|
1705
|
+
);
|
|
1587
1706
|
|
|
1588
1707
|
// src/components/Accordation/Accordation.tsx
|
|
1589
1708
|
var import_phosphor_react3 = require("phosphor-react");
|