analytica-frontend-lib 1.0.80 → 1.0.82

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.mjs CHANGED
@@ -4167,6 +4167,112 @@ var CardTest = forwardRef9(
4167
4167
  );
4168
4168
  }
4169
4169
  );
4170
+ var SIMULATION_TYPE_STYLES = {
4171
+ enem: {
4172
+ background: "bg-exam-1",
4173
+ badge: "exam1",
4174
+ text: "Enem"
4175
+ },
4176
+ prova: {
4177
+ background: "bg-exam-2",
4178
+ badge: "exam2",
4179
+ text: "Prova"
4180
+ },
4181
+ simulado: {
4182
+ background: "bg-exam-3",
4183
+ badge: "exam3",
4184
+ text: "Simulado"
4185
+ },
4186
+ vestibular: {
4187
+ background: "bg-exam-4",
4188
+ badge: "exam4",
4189
+ text: "Vestibular"
4190
+ }
4191
+ };
4192
+ var CardSimulationHistory = forwardRef9(({ data, onSimulationClick, className, ...props }, ref) => {
4193
+ return /* @__PURE__ */ jsx23(
4194
+ "div",
4195
+ {
4196
+ ref,
4197
+ className: `w-full max-w-[992px] h-auto ${className}`,
4198
+ ...props,
4199
+ children: /* @__PURE__ */ jsxs18("div", { className: "flex flex-col gap-0", children: [
4200
+ data.map((section, sectionIndex) => /* @__PURE__ */ jsx23("div", { className: "flex flex-col", children: /* @__PURE__ */ jsxs18(
4201
+ "div",
4202
+ {
4203
+ className: `
4204
+ flex flex-row justify-center items-start px-4 py-6 gap-2 w-full bg-white
4205
+ ${sectionIndex === 0 ? "rounded-t-3xl" : ""}
4206
+ `,
4207
+ children: [
4208
+ /* @__PURE__ */ jsx23(
4209
+ Text_default,
4210
+ {
4211
+ size: "xs",
4212
+ weight: "bold",
4213
+ className: "text-text-800 w-11 flex-shrink-0",
4214
+ children: section.date
4215
+ }
4216
+ ),
4217
+ /* @__PURE__ */ jsx23("div", { className: "flex flex-col gap-2 flex-1", children: section.simulations.map((simulation) => {
4218
+ const typeStyles = SIMULATION_TYPE_STYLES[simulation.type];
4219
+ return /* @__PURE__ */ jsx23(
4220
+ CardBase,
4221
+ {
4222
+ layout: "horizontal",
4223
+ padding: "medium",
4224
+ minHeight: "none",
4225
+ cursor: "pointer",
4226
+ className: `
4227
+ ${typeStyles.background} rounded-xl hover:shadow-soft-shadow-2
4228
+ transition-shadow duration-200 h-auto min-h-[61px]
4229
+ `,
4230
+ onClick: () => onSimulationClick?.(simulation),
4231
+ children: /* @__PURE__ */ jsxs18("div", { className: "flex justify-between items-center w-full gap-2", children: [
4232
+ /* @__PURE__ */ jsxs18("div", { className: "flex flex-col gap-2 flex-1 min-w-0", children: [
4233
+ /* @__PURE__ */ jsx23(
4234
+ Text_default,
4235
+ {
4236
+ size: "lg",
4237
+ weight: "bold",
4238
+ className: "text-text-950 truncate",
4239
+ children: simulation.title
4240
+ }
4241
+ ),
4242
+ /* @__PURE__ */ jsxs18("div", { className: "flex items-center gap-2", children: [
4243
+ /* @__PURE__ */ jsx23(
4244
+ Badge_default,
4245
+ {
4246
+ variant: "examsOutlined",
4247
+ action: typeStyles.badge,
4248
+ size: "medium",
4249
+ children: typeStyles.text
4250
+ }
4251
+ ),
4252
+ /* @__PURE__ */ jsx23(Text_default, { size: "sm", className: "text-text-800 truncate", children: simulation.info })
4253
+ ] })
4254
+ ] }),
4255
+ /* @__PURE__ */ jsx23(
4256
+ CaretRight,
4257
+ {
4258
+ size: 24,
4259
+ className: "text-text-800 flex-shrink-0",
4260
+ "data-testid": "caret-icon"
4261
+ }
4262
+ )
4263
+ ] })
4264
+ },
4265
+ simulation.id
4266
+ );
4267
+ }) })
4268
+ ]
4269
+ }
4270
+ ) }, section.date)),
4271
+ data.length > 0 && /* @__PURE__ */ jsx23("div", { className: "w-full h-6 bg-white rounded-b-3xl" })
4272
+ ] })
4273
+ }
4274
+ );
4275
+ });
4170
4276
 
4171
4277
  // src/components/Accordation/Accordation.tsx
4172
4278
  import { CaretRight as CaretRight2 } from "phosphor-react";
@@ -6155,6 +6261,7 @@ export {
6155
6261
  CardQuestions,
6156
6262
  CardResults,
6157
6263
  CardSimulado,
6264
+ CardSimulationHistory,
6158
6265
  CardStatus,
6159
6266
  CardTest,
6160
6267
  CardTopic,