bmi-next-brokers 1.0.9 → 1.1.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.
@@ -1 +1 @@
1
- ._badge_lzevs_1{display:flex;justify-content:center;align-items:center;width:100%;gap:4px;border-radius:28px;box-sizing:border-box;padding:4px 6px;transition:128ms cubic-bezier(.6,0,.4,1);position:relative}._medium_lzevs_14{padding:3px 8px}._small_lzevs_18{padding:2px 4px}
1
+ ._badge_c0j5t_1{display:flex;justify-content:center;align-items:center;width:fit-content;gap:4px;border-radius:28px;box-sizing:border-box;padding:4px 12px;transition:128ms cubic-bezier(.6,0,.4,1);position:relative}._fullWidth_c0j5t_14{width:100%}._medium_c0j5t_18{padding:3px 8px}._small_c0j5t_22{padding:2px 4px}
@@ -26,6 +26,7 @@ interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
26
26
  iconBefore?: IconProps;
27
27
  loading?: boolean;
28
28
  outline?: boolean;
29
+ fullWidth?: boolean;
29
30
  }
30
31
  /**
31
32
  * Componente Badge para mostrar texto o botón con estilos según variante y tamaño,
@@ -1,21 +1,23 @@
1
- import { jsxs as w, Fragment as F, jsx as r } from "react/jsx-runtime";
2
- import { Icon as c } from "../../icons/Icon.js";
3
- import '../../assets/index.css';const I = "_badge_lzevs_1", k = "_medium_lzevs_14", p = "_small_lzevs_18", v = {
4
- badge: I,
5
- medium: k,
6
- small: p
7
- }, S = ({
8
- variant: t,
1
+ import { jsxs as F, Fragment as I, jsx as v } from "react/jsx-runtime";
2
+ import { Icon as s } from "../../icons/Icon.js";
3
+ import '../../assets/index.css';const k = "_badge_c0j5t_1", p = "_fullWidth_c0j5t_14", _ = "_medium_c0j5t_18", P = "_small_c0j5t_22", o = {
4
+ badge: k,
5
+ fullWidth: p,
6
+ medium: _,
7
+ small: P
8
+ }, $ = ({
9
+ variant: e,
9
10
  style: f,
10
- size: e = "large",
11
+ size: t = "large",
11
12
  iconAfter: n,
12
13
  iconBefore: a,
13
14
  outline: l = !1,
14
15
  className: d,
15
16
  children: g,
16
- ...C
17
+ fullWidth: C = !1,
18
+ ...A
17
19
  }) => {
18
- const A = {
20
+ const m = {
19
21
  small: "small5Medium",
20
22
  medium: "small3Medium",
21
23
  large: "small3Medium"
@@ -56,7 +58,7 @@ import '../../assets/index.css';const I = "_badge_lzevs_1", k = "_medium_lzevs_1
56
58
  default: "var(--Content-Disabled-Default, #CBD5E1)",
57
59
  outline: "var(--Fill-Disabled-Default, #F8FAFC)"
58
60
  }
59
- }, s = {
61
+ }, c = {
60
62
  brand: {
61
63
  default: "var(--Content-Brand-Inverted-Active)",
62
64
  outline: "var(--Content-Brand-Default-Active)"
@@ -89,7 +91,7 @@ import '../../assets/index.css';const I = "_badge_lzevs_1", k = "_medium_lzevs_1
89
91
  default: "var(--Content-Neutral-Default-Default)",
90
92
  outline: "var(--Content-Disabled-Default, #CBD5E1)"
91
93
  }
92
- }, m = {
94
+ }, D = {
93
95
  brand: "var(--Stroke-Brand-Active)",
94
96
  info: "var(--Stroke-Info-Active)",
95
97
  new: "var(--Stroke-New-Active)",
@@ -97,43 +99,43 @@ import '../../assets/index.css';const I = "_badge_lzevs_1", k = "_medium_lzevs_1
97
99
  positive: "var(--Stroke-Positive-Active)",
98
100
  warning: "var(--Stroke-Warning-Active)",
99
101
  negative: "var(--Stroke-Negative-Active)",
100
- disabled: "var(--Stroke-Disabled-Default), #CBD5E1"
101
- }, D = l ? u[t].outline : u[t].default, o = l ? s[t].outline : s[t].default, b = l ? m[t] : "transparent", N = `${A[e]} ${v.badge} ${v[e]} ${l ? v.outline : ""} ${d || ""}`, h = /* @__PURE__ */ w(F, { children: [
102
- a && /* @__PURE__ */ r(
103
- c,
102
+ disabled: "var(--Stroke-Disabled-Default, #CBD5E1)"
103
+ }, b = l ? u[e].outline : u[e].default, r = l ? c[e].outline : c[e].default, h = l ? D[e] : "transparent", N = `${m[t]} ${o.badge} ${o[t]} ${l ? o.outline : ""} ${C ? o.fullWidth : ""} ${d || ""}`, w = /* @__PURE__ */ F(I, { children: [
104
+ a && /* @__PURE__ */ v(
105
+ s,
104
106
  {
105
107
  name: a.name,
106
- width: a.width ?? i[e],
107
- height: a.height ?? i[e],
108
- fill: a.fill ?? o
108
+ width: a.width ?? i[t],
109
+ height: a.height ?? i[t],
110
+ fill: a.fill ?? r
109
111
  }
110
112
  ),
111
113
  g,
112
- n && /* @__PURE__ */ r(
113
- c,
114
+ n && /* @__PURE__ */ v(
115
+ s,
114
116
  {
115
117
  name: n.name,
116
- width: n.width ?? i[e],
117
- height: n.height ?? i[e],
118
- fill: n.fill ?? o
118
+ width: n.width ?? i[t],
119
+ height: n.height ?? i[t],
120
+ fill: n.fill ?? r
119
121
  }
120
122
  )
121
123
  ] });
122
- return /* @__PURE__ */ r(
124
+ return /* @__PURE__ */ v(
123
125
  "span",
124
126
  {
125
127
  className: N,
126
128
  style: {
127
- color: o,
128
- backgroundColor: D,
129
- border: `1px solid ${b}`,
129
+ color: r,
130
+ backgroundColor: b,
131
+ border: `1px solid ${h}`,
130
132
  ...f
131
133
  },
132
- ...C,
133
- children: h
134
+ ...A,
135
+ children: w
134
136
  }
135
137
  );
136
138
  };
137
139
  export {
138
- S as Badge
140
+ $ as Badge
139
141
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "bmi-next-brokers",
3
3
  "description": "Componentes de UI para proyecto BMI Next Brokers",
4
- "version": "1.0.9",
4
+ "version": "1.1.1",
5
5
  "author": "BMI Ahorro España",
6
6
  "contributors": [
7
7
  "José Ramón Jiménez <jrjimenez@bmicos.com>",