@telefonica/mistica 15.9.0 → 15.11.0

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.
Files changed (114) hide show
  1. package/css/mistica.css +1 -1
  2. package/dist/boxed.css-mistica.js +35 -2
  3. package/dist/boxed.css.d.ts +29 -0
  4. package/dist/boxed.d.ts +6 -4
  5. package/dist/boxed.js +30 -24
  6. package/dist/button-group.css-mistica.js +14 -5
  7. package/dist/button-group.css.d.ts +3 -0
  8. package/dist/button-group.d.ts +2 -1
  9. package/dist/button-group.js +29 -16
  10. package/dist/button-layout.css-mistica.js +7 -7
  11. package/dist/button-layout.css.d.ts +1 -1
  12. package/dist/button-layout.js +9 -9
  13. package/dist/button.d.ts +4 -24
  14. package/dist/button.js +6 -4
  15. package/dist/card.d.ts +8 -1
  16. package/dist/card.js +567 -501
  17. package/dist/carousel.css-mistica.js +19 -16
  18. package/dist/carousel.css.d.ts +1 -0
  19. package/dist/carousel.js +41 -39
  20. package/dist/chip.js +37 -44
  21. package/dist/circle.d.ts +11 -4
  22. package/dist/circle.js +10 -11
  23. package/dist/community/advanced-data-card.css-mistica.js +24 -21
  24. package/dist/community/advanced-data-card.css.d.ts +1 -0
  25. package/dist/community/advanced-data-card.d.ts +1 -0
  26. package/dist/community/advanced-data-card.js +20 -17
  27. package/dist/counter.js +26 -22
  28. package/dist/cover-hero-media.d.ts +12 -0
  29. package/dist/cover-hero-media.js +44 -0
  30. package/dist/cover-hero.css-mistica.js +56 -0
  31. package/dist/cover-hero.css.d.ts +14 -0
  32. package/dist/cover-hero.css.ts.vanilla.css-mistica.js +11 -0
  33. package/dist/cover-hero.d.ts +38 -0
  34. package/dist/cover-hero.js +296 -0
  35. package/dist/empty-state.js +6 -6
  36. package/dist/grid-layout.css-mistica.js +11 -8
  37. package/dist/grid-layout.css.d.ts +1 -0
  38. package/dist/grid-layout.d.ts +12 -22
  39. package/dist/grid-layout.js +63 -49
  40. package/dist/header.js +18 -18
  41. package/dist/highlighted-card.d.ts +1 -0
  42. package/dist/highlighted-card.js +22 -18
  43. package/dist/icon-button.d.ts +7 -6
  44. package/dist/image.js +69 -48
  45. package/dist/index.d.ts +4 -1
  46. package/dist/index.js +15 -0
  47. package/dist/list.d.ts +1 -0
  48. package/dist/navigation-bar.d.ts +1 -1
  49. package/dist/navigation-bar.js +1 -1
  50. package/dist/package-version.js +1 -1
  51. package/dist/select.js +16 -12
  52. package/dist/skins/movistar.d.ts +13 -0
  53. package/dist/skins/movistar.js +112 -99
  54. package/dist/spinner.js +19 -18
  55. package/dist/table.css-mistica.js +58 -0
  56. package/dist/table.css.d.ts +13 -0
  57. package/dist/table.css.ts.vanilla.css-mistica.js +11 -0
  58. package/dist/table.d.ts +39 -0
  59. package/dist/table.js +269 -0
  60. package/dist/text.d.ts +1 -1
  61. package/dist/theme.d.ts +20 -0
  62. package/dist/theme.js +80 -20
  63. package/dist/timer.css-mistica.js +39 -0
  64. package/dist/timer.css.d.ts +8 -0
  65. package/dist/timer.css.ts.vanilla.css-mistica.js +11 -0
  66. package/dist/timer.d.ts +27 -0
  67. package/dist/timer.js +370 -0
  68. package/dist/tooltip.js +13 -13
  69. package/dist/touchable.d.ts +2 -0
  70. package/dist/touchable.js +35 -31
  71. package/dist/utils/helpers.js +32 -32
  72. package/dist-es/boxed.css-mistica.js +29 -2
  73. package/dist-es/boxed.js +37 -31
  74. package/dist-es/button-group.css-mistica.js +2 -2
  75. package/dist-es/button-group.js +37 -24
  76. package/dist-es/button-layout.css-mistica.js +2 -2
  77. package/dist-es/button-layout.js +16 -16
  78. package/dist-es/button.js +24 -22
  79. package/dist-es/card.js +681 -618
  80. package/dist-es/carousel.css-mistica.js +7 -7
  81. package/dist-es/carousel.js +75 -73
  82. package/dist-es/chip.js +57 -64
  83. package/dist-es/circle.js +15 -16
  84. package/dist-es/community/advanced-data-card.css-mistica.js +4 -4
  85. package/dist-es/community/advanced-data-card.js +59 -56
  86. package/dist-es/counter.js +62 -58
  87. package/dist-es/cover-hero-media.js +30 -0
  88. package/dist-es/cover-hero.css-mistica.js +9 -0
  89. package/dist-es/cover-hero.css.ts.vanilla.css-mistica.js +2 -0
  90. package/dist-es/cover-hero.js +241 -0
  91. package/dist-es/empty-state.js +13 -13
  92. package/dist-es/grid-layout.css-mistica.js +3 -3
  93. package/dist-es/grid-layout.js +80 -66
  94. package/dist-es/header.js +37 -37
  95. package/dist-es/highlighted-card.js +35 -31
  96. package/dist-es/image.js +88 -67
  97. package/dist-es/index.js +1817 -1814
  98. package/dist-es/navigation-bar.js +1 -1
  99. package/dist-es/package-version.js +1 -1
  100. package/dist-es/select.js +23 -18
  101. package/dist-es/skins/movistar.js +112 -99
  102. package/dist-es/spinner.js +38 -37
  103. package/dist-es/style.css +1 -1
  104. package/dist-es/table.css-mistica.js +14 -0
  105. package/dist-es/table.css.ts.vanilla.css-mistica.js +2 -0
  106. package/dist-es/table.js +214 -0
  107. package/dist-es/theme.js +77 -17
  108. package/dist-es/timer.css-mistica.js +4 -0
  109. package/dist-es/timer.css.ts.vanilla.css-mistica.js +2 -0
  110. package/dist-es/timer.js +307 -0
  111. package/dist-es/tooltip.js +16 -16
  112. package/dist-es/touchable.js +47 -43
  113. package/dist-es/utils/helpers.js +31 -31
  114. package/package.json +1 -1
@@ -0,0 +1,13 @@
1
+ export declare const vars: {
2
+ maxHeight: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
3
+ };
4
+ export declare const table: string;
5
+ export declare const fullWidth: string;
6
+ export declare const collapsedRowsInMobile: string;
7
+ export declare const boxed: string;
8
+ export declare const cellTextAlign: Record<"left" | "right" | "center", string>;
9
+ export declare const scrollContainer: string;
10
+ export declare const scrollOverResponsiveLayout: string;
11
+ export declare const verticalAlign: Record<"top" | "middle", string>;
12
+ export declare const mobileCellHeading: string;
13
+ export declare const collapsedRowTittle: string;
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ Object.defineProperty(exports, "default", {
6
+ enumerable: true,
7
+ get: function() {
8
+ return a;
9
+ }
10
+ });
11
+ const a = "";
@@ -0,0 +1,39 @@
1
+ import * as React from 'react';
2
+ import type { DataAttributes } from './utils/types';
3
+ type TextAlign = 'left' | 'right' | 'center';
4
+ type VerticalAlign = 'top' | 'middle';
5
+ type TableProps = {
6
+ heading: Array<React.ReactNode>;
7
+ content?: Array<Array<React.ReactNode>>;
8
+ boxed?: boolean;
9
+ emptyCase?: React.ReactNode;
10
+ /**
11
+ * In mobile, the table will be scrollable horizontally by default. Alternatively, you can set it to 'collapse-rows', which will
12
+ * render every row as a card
13
+ */
14
+ responsive?: 'scroll' | 'collapse-rows';
15
+ columnTextAlign?: Array<TextAlign> | TextAlign;
16
+ rowVerticalAlign?: VerticalAlign;
17
+ columnWidth?: Array<number | string>;
18
+ /**
19
+ * by default, the table expands to all the available width, if you want the table to have the minimum width to fit the rows content, set fullWidth to false.
20
+ * It's ignored in mobile
21
+ */
22
+ fullWidth?: boolean;
23
+ /**
24
+ * Limits the height of the table and the content will have vertical scroll.
25
+ * It's ignored in mobile when responsive move is 'collapse-rows'
26
+ */
27
+ maxHeight?: number | string;
28
+ /**
29
+ * when rendering the table inside a responsive layout, you can enable this prop to make the table scrollable over the layout paddings
30
+ */
31
+ scrollOverResponsiveLayout?: boolean;
32
+ /** "data-" prefix is automatically added. For example, use "testid" instead of "data-testid" */
33
+ dataAttributes?: DataAttributes;
34
+ 'aria-label'?: string;
35
+ 'aria-labelledby'?: string;
36
+ 'aria-describedby'?: string;
37
+ };
38
+ export declare const Table: React.ForwardRefExoticComponent<TableProps & React.RefAttributes<HTMLDivElement>>;
39
+ export {};
package/dist/table.js ADDED
@@ -0,0 +1,269 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ Object.defineProperty(exports, "Table", {
6
+ enumerable: true,
7
+ get: function() {
8
+ return ee;
9
+ }
10
+ });
11
+ const _jsxruntime = require("react/jsx-runtime");
12
+ const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
13
+ const _dom = require("./utils/dom.js");
14
+ const _tablecssmistica = require("./table.css-mistica.js");
15
+ const _skincontractcssmistica = require("./skins/skin-contract.css-mistica.js");
16
+ const _text = require("./text.js");
17
+ const _boxed = require("./boxed.js");
18
+ const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
19
+ const _box = /*#__PURE__*/ _interop_require_default(require("./box.js"));
20
+ const _css = require("./utils/css.js");
21
+ function _interop_require_default(obj) {
22
+ return obj && obj.__esModule ? obj : {
23
+ default: obj
24
+ };
25
+ }
26
+ function _getRequireWildcardCache(nodeInterop) {
27
+ if (typeof WeakMap !== "function") return null;
28
+ var cacheBabelInterop = new WeakMap();
29
+ var cacheNodeInterop = new WeakMap();
30
+ return (_getRequireWildcardCache = function(nodeInterop) {
31
+ return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
32
+ })(nodeInterop);
33
+ }
34
+ function _interop_require_wildcard(obj, nodeInterop) {
35
+ if (!nodeInterop && obj && obj.__esModule) {
36
+ return obj;
37
+ }
38
+ if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
39
+ return {
40
+ default: obj
41
+ };
42
+ }
43
+ var cache = _getRequireWildcardCache(nodeInterop);
44
+ if (cache && cache.has(obj)) {
45
+ return cache.get(obj);
46
+ }
47
+ var newObj = {
48
+ __proto__: null
49
+ };
50
+ var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
51
+ for(var key in obj){
52
+ if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
53
+ var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
54
+ if (desc && (desc.get || desc.set)) {
55
+ Object.defineProperty(newObj, key, desc);
56
+ } else {
57
+ newObj[key] = obj[key];
58
+ }
59
+ }
60
+ }
61
+ newObj.default = obj;
62
+ if (cache) {
63
+ cache.set(obj, newObj);
64
+ }
65
+ return newObj;
66
+ }
67
+ function _define_property(obj, key, value) {
68
+ if (key in obj) {
69
+ Object.defineProperty(obj, key, {
70
+ value: value,
71
+ enumerable: true,
72
+ configurable: true,
73
+ writable: true
74
+ });
75
+ } else {
76
+ obj[key] = value;
77
+ }
78
+ return obj;
79
+ }
80
+ function _object_spread(target) {
81
+ for(var i = 1; i < arguments.length; i++){
82
+ var source = arguments[i] != null ? arguments[i] : {};
83
+ var ownKeys = Object.keys(source);
84
+ if (typeof Object.getOwnPropertySymbols === "function") {
85
+ ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
86
+ return Object.getOwnPropertyDescriptor(source, sym).enumerable;
87
+ }));
88
+ }
89
+ ownKeys.forEach(function(key) {
90
+ _define_property(target, key, source[key]);
91
+ });
92
+ }
93
+ return target;
94
+ }
95
+ function ownKeys(object, enumerableOnly) {
96
+ var keys = Object.keys(object);
97
+ if (Object.getOwnPropertySymbols) {
98
+ var symbols = Object.getOwnPropertySymbols(object);
99
+ if (enumerableOnly) {
100
+ symbols = symbols.filter(function(sym) {
101
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
102
+ });
103
+ }
104
+ keys.push.apply(keys, symbols);
105
+ }
106
+ return keys;
107
+ }
108
+ function _object_spread_props(target, source) {
109
+ source = source != null ? source : {};
110
+ if (Object.getOwnPropertyDescriptors) {
111
+ Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
112
+ } else {
113
+ ownKeys(Object(source)).forEach(function(key) {
114
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
115
+ });
116
+ }
117
+ return target;
118
+ }
119
+ function _object_without_properties(source, excluded) {
120
+ if (source == null) return {};
121
+ var target = _object_without_properties_loose(source, excluded);
122
+ var key, i;
123
+ if (Object.getOwnPropertySymbols) {
124
+ var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
125
+ for(i = 0; i < sourceSymbolKeys.length; i++){
126
+ key = sourceSymbolKeys[i];
127
+ if (excluded.indexOf(key) >= 0) continue;
128
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
129
+ target[key] = source[key];
130
+ }
131
+ }
132
+ return target;
133
+ }
134
+ function _object_without_properties_loose(source, excluded) {
135
+ if (source == null) return {};
136
+ var target = {};
137
+ var sourceKeys = Object.keys(source);
138
+ var key, i;
139
+ for(i = 0; i < sourceKeys.length; i++){
140
+ key = sourceKeys[i];
141
+ if (excluded.indexOf(key) >= 0) continue;
142
+ target[key] = source[key];
143
+ }
144
+ return target;
145
+ }
146
+ const C = "left", ee = /*#__PURE__*/ _react.forwardRef((_param, v)=>{
147
+ var { dataAttributes: f, heading: n, content: d, boxed: y, responsive: O, fullWidth: s = !0, maxHeight: c, emptyCase: m, columnTextAlign: p = C, rowVerticalAlign: h = "middle", columnWidth: l, scrollOverResponsiveLayout: j } = _param, b = _object_without_properties(_param, [
148
+ "dataAttributes",
149
+ "heading",
150
+ "content",
151
+ "boxed",
152
+ "responsive",
153
+ "fullWidth",
154
+ "maxHeight",
155
+ "emptyCase",
156
+ "columnTextAlign",
157
+ "rowVerticalAlign",
158
+ "columnWidth",
159
+ "scrollOverResponsiveLayout"
160
+ ]);
161
+ const u = (a)=>{
162
+ var _p_a;
163
+ return Array.isArray(p) ? (_p_a = p[a]) !== null && _p_a !== void 0 ? _p_a : C : p;
164
+ }, r = O === "collapse-rows", g = /* @__PURE__ */ (0, _jsxruntime.jsxs)("table", {
165
+ className: (0, _classnames.default)(_tablecssmistica.table, {
166
+ [_tablecssmistica.boxed]: y,
167
+ [_tablecssmistica.collapsedRowsInMobile]: r,
168
+ [_tablecssmistica.fullWidth]: s
169
+ }),
170
+ "aria-label": b["aria-label"],
171
+ "aria-labelledby": b["aria-labelledby"],
172
+ "aria-describedby": b["aria-describedby"],
173
+ children: [
174
+ /* @__PURE__ */ (0, _jsxruntime.jsx)("thead", {
175
+ children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_text.Text1, {
176
+ as: "tr",
177
+ medium: !0,
178
+ transform: "uppercase",
179
+ color: _skincontractcssmistica.vars.colors.textSecondary,
180
+ wordBreak: !1,
181
+ children: n.map((a, t)=>/* @__PURE__ */ (0, _jsxruntime.jsx)("th", {
182
+ scope: "col",
183
+ className: (0, _classnames.default)(_tablecssmistica.cellTextAlign[u(t)], _tablecssmistica.verticalAlign[h]),
184
+ style: {
185
+ minWidth: l == null ? void 0 : l[t],
186
+ width: l == null ? void 0 : l[t]
187
+ },
188
+ children: a
189
+ }, t))
190
+ })
191
+ }),
192
+ /* @__PURE__ */ (0, _jsxruntime.jsx)("tbody", {
193
+ children: d && d.length ? d.map((a, t)=>/* @__PURE__ */ (0, _jsxruntime.jsx)("tr", {
194
+ children: a.map((I, o)=>/* @__PURE__ */ (0, _jsxruntime.jsxs)("td", {
195
+ className: _tablecssmistica.verticalAlign[h],
196
+ children: [
197
+ o !== 0 && r && // this is aria-hidden because screen readers already read the column heading from the th
198
+ /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
199
+ className: _tablecssmistica.mobileCellHeading,
200
+ "aria-hidden": !0,
201
+ children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_text.Text1, {
202
+ medium: !0,
203
+ color: _skincontractcssmistica.vars.colors.textSecondary,
204
+ children: n[o]
205
+ })
206
+ }),
207
+ /* @__PURE__ */ (0, _jsxruntime.jsx)(_text.Text2, {
208
+ as: "div",
209
+ weight: o === 0 && r ? "medium" : "regular",
210
+ wordBreak: !1,
211
+ children: /* @__PURE__ */ (0, _jsxruntime.jsx)("div", {
212
+ className: (0, _classnames.default)(_tablecssmistica.cellTextAlign[u(o)], {
213
+ [_tablecssmistica.collapsedRowTittle]: o === 0 && r
214
+ }),
215
+ children: I
216
+ })
217
+ })
218
+ ]
219
+ }, o))
220
+ }, t)) : /* @__PURE__ */ (0, _jsxruntime.jsx)("tr", {
221
+ children: /* @__PURE__ */ (0, _jsxruntime.jsx)("td", {
222
+ colSpan: n.length,
223
+ children: typeof m == "string" ? /* @__PURE__ */ (0, _jsxruntime.jsx)(_box.default, {
224
+ paddingY: 56,
225
+ children: /* @__PURE__ */ (0, _jsxruntime.jsx)(_text.Text2, {
226
+ regular: !0,
227
+ textAlign: "center",
228
+ as: "div",
229
+ children: m
230
+ })
231
+ }) : m
232
+ })
233
+ })
234
+ })
235
+ ]
236
+ }), w = function() {
237
+ let a = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
238
+ return {
239
+ className: (0, _classnames.default)(_tablecssmistica.scrollContainer, {
240
+ [_tablecssmistica.scrollOverResponsiveLayout]: a,
241
+ [_tablecssmistica.collapsedRowsInMobile]: r,
242
+ [_tablecssmistica.fullWidth]: s
243
+ }),
244
+ style: (0, _css.applyCssVars)({
245
+ [_tablecssmistica.vars.maxHeight]: typeof c == "number" ? `${c}px` : c !== null && c !== void 0 ? c : "auto"
246
+ })
247
+ };
248
+ };
249
+ return y ? /* @__PURE__ */ (0, _jsxruntime.jsx)(_boxed.InternalBoxed, {
250
+ desktopOnly: r,
251
+ width: "fit-content",
252
+ maxWidth: "100%",
253
+ minWidth: {
254
+ desktop: s ? "100%" : "auto",
255
+ mobile: r || s ? "100%" : "auto"
256
+ },
257
+ ref: v,
258
+ dataAttributes: _object_spread({
259
+ "component-name": "Table"
260
+ }, f),
261
+ children: /* @__PURE__ */ (0, _jsxruntime.jsx)("div", _object_spread_props(_object_spread({}, w()), {
262
+ children: g
263
+ }))
264
+ }) : /* @__PURE__ */ (0, _jsxruntime.jsx)("div", _object_spread_props(_object_spread({
265
+ ref: v
266
+ }, (0, _dom.getPrefixedDataAttributes)(f, "Table"), w(j)), {
267
+ children: g
268
+ }));
269
+ });
package/dist/text.d.ts CHANGED
@@ -10,7 +10,7 @@ export interface TextPresetProps {
10
10
  truncate?: boolean | number;
11
11
  wordBreak?: boolean;
12
12
  hyphens?: 'auto' | 'manual' | 'none';
13
- textAlign?: 'center' | 'right';
13
+ textAlign?: 'center' | 'right' | 'left';
14
14
  id?: string;
15
15
  as?: React.ComponentType<any> | string;
16
16
  role?: string;
package/dist/theme.d.ts CHANGED
@@ -50,6 +50,21 @@ declare const TEXTS_ES: {
50
50
  counterQuantity: string;
51
51
  counterMinValue: string;
52
52
  counterMaxValue: string;
53
+ timerDaysShortLabel: string;
54
+ timerHoursShortLabel: string;
55
+ timerMinutesShortLabel: string;
56
+ timerSecondsShortLabel: string;
57
+ timerAnd: string;
58
+ timerDayLongLabel: string;
59
+ timerDaysLongLabel: string;
60
+ timerHourLongLabel: string;
61
+ timerHoursLongLabel: string;
62
+ timerMinuteLongLabel: string;
63
+ timerMinutesLongLabel: string;
64
+ timerSecondLongLabel: string;
65
+ timerSecondsLongLabel: string;
66
+ timerDisplayMinutesLabel: string;
67
+ timerDisplaySecondsLabel: string;
53
68
  };
54
69
  export declare const getTexts: (locale: Locale) => typeof TEXTS_ES;
55
70
  export declare const NAVBAR_HEIGHT_MOBILE = 56;
@@ -59,6 +74,10 @@ export declare const dimensions: {
59
74
  headerMobileHeight: number;
60
75
  headerDesktopHeight: number;
61
76
  };
77
+ /**
78
+ * https://reactrouter.com/en/main/components/link
79
+ * https://nextjs.org/docs/app/api-reference/components/link
80
+ */
62
81
  type LinkComponent = React.ComponentType<{
63
82
  style?: React.CSSProperties;
64
83
  className?: string;
@@ -84,6 +103,7 @@ type LinkComponent = React.ComponentType<{
84
103
  onClick?: React.MouseEventHandler<HTMLAnchorElement>;
85
104
  onKeyDown?: React.KeyboardEventHandler<HTMLAnchorElement>;
86
105
  children: React.ReactNode;
106
+ target?: string;
87
107
  }>;
88
108
  export declare const getMisticaLinkComponent: (Link?: ThemeConfig['Link']) => LinkComponent;
89
109
  export type ColorScheme = 'dark' | 'light' | 'auto';
package/dist/theme.js CHANGED
@@ -10,19 +10,19 @@ function _export(target, all) {
10
10
  }
11
11
  _export(exports, {
12
12
  NAVBAR_HEIGHT_DESKTOP: function() {
13
- return c;
13
+ return m;
14
14
  },
15
15
  NAVBAR_HEIGHT_MOBILE: function() {
16
16
  return u;
17
17
  },
18
18
  dimensions: function() {
19
- return V;
19
+ return v;
20
20
  },
21
21
  getMisticaLinkComponent: function() {
22
- return E;
22
+ return h;
23
23
  },
24
24
  getTexts: function() {
25
- return g;
25
+ return f;
26
26
  }
27
27
  });
28
28
  const _jsxruntime = require("react/jsx-runtime");
@@ -150,7 +150,22 @@ const l = {
150
150
  counterDecreaseLabel: "Disminuir valor",
151
151
  counterQuantity: "cantidad",
152
152
  counterMinValue: "m\xednimo",
153
- counterMaxValue: "m\xe1ximo"
153
+ counterMaxValue: "m\xe1ximo",
154
+ timerDaysShortLabel: "d",
155
+ timerHoursShortLabel: "h",
156
+ timerMinutesShortLabel: "min",
157
+ timerSecondsShortLabel: "s",
158
+ timerAnd: "y",
159
+ timerDayLongLabel: "d\xeda",
160
+ timerDaysLongLabel: "d\xedas",
161
+ timerHourLongLabel: "hora",
162
+ timerHoursLongLabel: "horas",
163
+ timerMinuteLongLabel: "minuto",
164
+ timerMinutesLongLabel: "minutos",
165
+ timerSecondLongLabel: "segundo",
166
+ timerSecondsLongLabel: "segundos",
167
+ timerDisplayMinutesLabel: "min",
168
+ timerDisplaySecondsLabel: "seg"
154
169
  }, i = {
155
170
  expirationDatePlaceholder: "MM/YY",
156
171
  enablePasswordVisibility: "Show password",
@@ -196,7 +211,22 @@ const l = {
196
211
  counterDecreaseLabel: "Decrease value",
197
212
  counterQuantity: "quantity",
198
213
  counterMinValue: "minimum of",
199
- counterMaxValue: "maximum of"
214
+ counterMaxValue: "maximum of",
215
+ timerDaysShortLabel: "d",
216
+ timerHoursShortLabel: "h",
217
+ timerMinutesShortLabel: "min",
218
+ timerSecondsShortLabel: "s",
219
+ timerAnd: "and",
220
+ timerDayLongLabel: "day",
221
+ timerDaysLongLabel: "days",
222
+ timerHourLongLabel: "hour",
223
+ timerHoursLongLabel: "hours",
224
+ timerMinuteLongLabel: "minute",
225
+ timerMinutesLongLabel: "minutes",
226
+ timerSecondLongLabel: "second",
227
+ timerSecondsLongLabel: "seconds",
228
+ timerDisplayMinutesLabel: "min",
229
+ timerDisplaySecondsLabel: "sec"
200
230
  }, s = {
201
231
  expirationDatePlaceholder: "MM/JJ",
202
232
  enablePasswordVisibility: "Passwort anzeigen",
@@ -242,7 +272,22 @@ const l = {
242
272
  counterDecreaseLabel: "Wert verringern",
243
273
  counterQuantity: "menge",
244
274
  counterMinValue: "minimal",
245
- counterMaxValue: "maximal"
275
+ counterMaxValue: "maximal",
276
+ timerDaysShortLabel: "Tg.",
277
+ timerHoursShortLabel: "Std.",
278
+ timerMinutesShortLabel: "Min.",
279
+ timerSecondsShortLabel: "Sek.",
280
+ timerAnd: "und",
281
+ timerDayLongLabel: "Tag",
282
+ timerDaysLongLabel: "Tage",
283
+ timerHourLongLabel: "Stunde",
284
+ timerHoursLongLabel: "Stunden",
285
+ timerMinuteLongLabel: "Minute",
286
+ timerMinutesLongLabel: "Minuten",
287
+ timerSecondLongLabel: "Sekunde",
288
+ timerSecondsLongLabel: "Sekunden",
289
+ timerDisplayMinutesLabel: "Min.",
290
+ timerDisplaySecondsLabel: "Sek."
246
291
  }, d = {
247
292
  expirationDatePlaceholder: "MM/AA",
248
293
  enablePasswordVisibility: "mostrar senha",
@@ -288,8 +333,23 @@ const l = {
288
333
  counterDecreaseLabel: "diminuir valor",
289
334
  counterQuantity: "quantidade",
290
335
  counterMinValue: "m\xednimo",
291
- counterMaxValue: "m\xe1ximo"
292
- }, g = (e)=>{
336
+ counterMaxValue: "m\xe1ximo",
337
+ timerDaysShortLabel: "d",
338
+ timerHoursShortLabel: "h",
339
+ timerMinutesShortLabel: "min",
340
+ timerSecondsShortLabel: "s",
341
+ timerAnd: "e",
342
+ timerDayLongLabel: "dia",
343
+ timerDaysLongLabel: "dias",
344
+ timerHourLongLabel: "hora",
345
+ timerHoursLongLabel: "horas",
346
+ timerMinuteLongLabel: "minuto",
347
+ timerMinutesLongLabel: "minutos",
348
+ timerSecondLongLabel: "segundo",
349
+ timerSecondsLongLabel: "segundos",
350
+ timerDisplayMinutesLabel: "min",
351
+ timerDisplaySecondsLabel: "seg"
352
+ }, f = (e)=>{
293
353
  switch(e.toLocaleLowerCase().split(/[-_]/)[0]){
294
354
  case "es":
295
355
  return l;
@@ -302,10 +362,10 @@ const l = {
302
362
  default:
303
363
  return process.env.NODE_ENV !== "production" && console.error(`Invalid locale: ${e}`), i;
304
364
  }
305
- }, u = 56, c = 80, V = {
365
+ }, u = 56, m = 80, v = {
306
366
  headerMobileHeight: u,
307
- headerDesktopHeight: c
308
- }, m = (_param)=>{
367
+ headerDesktopHeight: m
368
+ }, c = (_param)=>{
309
369
  var { to: e, innerRef: r } = _param, a = _object_without_properties(_param, [
310
370
  "to",
311
371
  "innerRef"
@@ -316,14 +376,14 @@ const l = {
316
376
  }, a), {
317
377
  children: a.children
318
378
  }));
319
- }, C = (e)=>e, p = (e)=>(_param)=>{
379
+ }, C = (e)=>e, b = (e)=>(_param)=>{
320
380
  var { innerRef: r } = _param, a = _object_without_properties(_param, [
321
381
  "innerRef"
322
382
  ]);
323
383
  return /* @__PURE__ */ (0, _jsxruntime.jsx)(e, _object_spread({
324
384
  ref: r
325
385
  }, a));
326
- }, f = (e)=>(_param)=>{
386
+ }, L = (e)=>(_param)=>{
327
387
  var { to: r, innerRef: a, children: t } = _param, n = _object_without_properties(_param, [
328
388
  "to",
329
389
  "innerRef",
@@ -337,7 +397,7 @@ const l = {
337
397
  children: t
338
398
  }))
339
399
  });
340
- }, b = (e)=>(_param)=>{
400
+ }, p = (e)=>(_param)=>{
341
401
  var { to: r, innerRef: a, children: t } = _param, n = _object_without_properties(_param, [
342
402
  "to",
343
403
  "innerRef",
@@ -349,19 +409,19 @@ const l = {
349
409
  }, n), {
350
410
  children: t
351
411
  }));
352
- }, E = (e)=>{
353
- if (!e) return m;
412
+ }, h = (e)=>{
413
+ if (!e) return c;
354
414
  if (typeof e == "function" || e.$$typeof) return e;
355
415
  switch(e.type){
356
416
  case "ReactRouter5":
357
417
  return C(e.Component);
358
418
  case "ReactRouter6":
359
- return p(e.Component);
419
+ return b(e.Component);
360
420
  case "Next12":
361
- return f(e.Component);
421
+ return L(e.Component);
362
422
  case "Next13":
363
423
  case "Next14":
364
- return b(e.Component);
424
+ return p(e.Component);
365
425
  default:
366
426
  const r = e.type;
367
427
  throw new Error(`Invalid Link type: ${r}`);
@@ -0,0 +1,39 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ function _export(target, all) {
6
+ for(var name in all)Object.defineProperty(target, name, {
7
+ enumerable: true,
8
+ get: all[name]
9
+ });
10
+ }
11
+ _export(exports, {
12
+ boxedTimerDisplayValue: function() {
13
+ return n;
14
+ },
15
+ boxedTimerValueContainer: function() {
16
+ return y;
17
+ },
18
+ boxedTimerValueContainerInverse: function() {
19
+ return a;
20
+ },
21
+ inlineText: function() {
22
+ return f;
23
+ },
24
+ shortLabelText: function() {
25
+ return _;
26
+ },
27
+ timerDisplayValue: function() {
28
+ return r;
29
+ },
30
+ timerWrapper: function() {
31
+ return i;
32
+ },
33
+ unitContainer: function() {
34
+ return t;
35
+ }
36
+ });
37
+ require("./sprinkles.css.ts.vanilla.css-mistica.js");
38
+ require("./timer.css.ts.vanilla.css-mistica.js");
39
+ var n = "_18fye848", y = "_18fye84a _1y2v1nfa1 _1y2v1nfba _1y2v1nf7m _1y2v1nf8v _1y2v1nfkb _1y2v1nf6l", a = "_18fye84a _1y2v1nfa1 _1y2v1nfba _1y2v1nf7m _1y2v1nf8v _1y2v1nfkb _1y2v1nf3q", f = "_18fye841", _ = "_18fye841 _1y2v1nfho", r = "_1y2v1nfhk _1y2v1nfhq _1y2v1nfhz", i = "_1y2v1nfho", t = "_18fye841 _1y2v1nfhl _1y2v1nfht";
@@ -0,0 +1,8 @@
1
+ export declare const timerWrapper: string;
2
+ export declare const inlineText: string;
3
+ export declare const unitContainer: string;
4
+ export declare const shortLabelText: string;
5
+ export declare const timerDisplayValue: string;
6
+ export declare const boxedTimerDisplayValue: string;
7
+ export declare const boxedTimerValueContainer: string;
8
+ export declare const boxedTimerValueContainerInverse: string;
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ Object.defineProperty(exports, "default", {
6
+ enumerable: true,
7
+ get: function() {
8
+ return s;
9
+ }
10
+ });
11
+ const s = "";
@@ -0,0 +1,27 @@
1
+ import * as React from 'react';
2
+ import type { DataAttributes } from './utils/types';
3
+ export type TimeUnit = 'days' | 'hours' | 'minutes' | 'seconds';
4
+ type Label = 'none' | 'short' | 'long';
5
+ export interface RemainingTime {
6
+ days?: number;
7
+ hours?: number;
8
+ minutes?: number;
9
+ seconds?: number;
10
+ }
11
+ interface BaseProps {
12
+ endTimestamp: Date | number;
13
+ minTimeUnit: TimeUnit;
14
+ maxTimeUnit: TimeUnit;
15
+ dataAttributes?: DataAttributes;
16
+ onProgress?: (value: RemainingTime) => void;
17
+ 'aria-label'?: string;
18
+ }
19
+ interface TextTimerProps extends BaseProps {
20
+ labelType?: Label;
21
+ }
22
+ interface TimerProps extends BaseProps {
23
+ boxed?: boolean;
24
+ }
25
+ export declare const TextTimer: React.FC<TextTimerProps>;
26
+ export declare const Timer: React.FC<TimerProps>;
27
+ export {};