@telefonica/mistica 13.5.0 → 13.6.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/css/mistica.css +1 -1
- package/dist/boxed.d.ts +6 -0
- package/dist/boxed.js +29 -18
- package/dist/card.css-mistica.js +12 -7
- package/dist/card.css.d.ts +5 -0
- package/dist/card.d.ts +40 -2
- package/dist/card.js +271 -79
- package/dist/highlighted-card.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -0
- package/dist/menu.css-mistica.js +6 -6
- package/dist/menu.css.d.ts +2 -2
- package/dist/menu.js +73 -69
- package/dist/package-version.js +1 -1
- package/dist/text-field.js +33 -22
- package/dist/text.d.ts +3 -0
- package/dist/text.js +162 -119
- package/dist-es/boxed.js +30 -25
- package/dist-es/card.css-mistica.js +2 -2
- package/dist-es/card.js +314 -124
- package/dist-es/highlighted-card.js +1 -1
- package/dist-es/index.js +1701 -1701
- package/dist-es/menu.css-mistica.js +5 -5
- package/dist-es/menu.js +82 -78
- package/dist-es/package-version.js +1 -1
- package/dist-es/style.css +1 -1
- package/dist-es/text-field.js +38 -27
- package/dist-es/text.js +164 -121
- package/package.json +1 -1
package/dist/text.js
CHANGED
|
@@ -9,18 +9,18 @@ function _export(target, all) {
|
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
_export(exports, {
|
|
12
|
-
Text: ()=>
|
|
13
|
-
Text1: ()=>
|
|
14
|
-
Text10: ()=>
|
|
15
|
-
Text2: ()=>
|
|
16
|
-
Text3: ()=>
|
|
17
|
-
Text4: ()=>
|
|
18
|
-
Text5: ()=>
|
|
19
|
-
Text6: ()=>
|
|
20
|
-
Text7: ()=>
|
|
21
|
-
Text8: ()=>
|
|
22
|
-
Text9: ()=>
|
|
23
|
-
default: ()=>
|
|
12
|
+
Text: ()=>r,
|
|
13
|
+
Text1: ()=>he,
|
|
14
|
+
Text10: ()=>ne,
|
|
15
|
+
Text2: ()=>ge,
|
|
16
|
+
Text3: ()=>le,
|
|
17
|
+
Text4: ()=>pe,
|
|
18
|
+
Text5: ()=>ae,
|
|
19
|
+
Text6: ()=>xe,
|
|
20
|
+
Text7: ()=>me,
|
|
21
|
+
Text8: ()=>se,
|
|
22
|
+
Text9: ()=>re,
|
|
23
|
+
default: ()=>r
|
|
24
24
|
});
|
|
25
25
|
const _react = /*#__PURE__*/ _interopRequireWildcard(require("react"));
|
|
26
26
|
const _classnames = /*#__PURE__*/ _interopRequireDefault(require("classnames"));
|
|
@@ -155,195 +155,238 @@ function _objectWithoutPropertiesLoose(source, excluded) {
|
|
|
155
155
|
}
|
|
156
156
|
return target;
|
|
157
157
|
}
|
|
158
|
-
const
|
|
158
|
+
const K = {
|
|
159
159
|
light: 300,
|
|
160
160
|
regular: 400,
|
|
161
161
|
medium: 500,
|
|
162
162
|
bold: 700
|
|
163
|
-
},
|
|
164
|
-
let { weight: e , color:
|
|
163
|
+
}, Q = (e)=>e === !0 ? 1 : e || "initial", r = (param)=>{
|
|
164
|
+
let { weight: e , color: i = _skinContractCssMisticaJs.vars.colors.textPrimary , decoration: t , truncate: o , transform: g , wordBreak: c = !0 , hyphens: z , as: H = "span" , children: h , size: u , mobileSize: d = u , desktopSize: b = u , lineHeight: T , mobileLineHeight: k = T , desktopLineHeight: L = T , letterSpacing: w , textAlign: v , textShadow: A , id: P , role: y , "aria-level": I , dataAttributes: W } = param;
|
|
165
165
|
var S;
|
|
166
|
-
const
|
|
166
|
+
const V = (0, _themeVariantContextJs.useIsInverseVariant)(), C = Q(o), D = {
|
|
167
167
|
[_skinContractCssMisticaJs.vars.colors.textPrimary]: _skinContractCssMisticaJs.vars.colors.textPrimaryInverse,
|
|
168
168
|
[_skinContractCssMisticaJs.vars.colors.textSecondary]: _skinContractCssMisticaJs.vars.colors.textSecondaryInverse,
|
|
169
169
|
[_skinContractCssMisticaJs.vars.colors.textLink]: _skinContractCssMisticaJs.vars.colors.textLinkInverse
|
|
170
170
|
};
|
|
171
|
-
if (!
|
|
172
|
-
const
|
|
173
|
-
[_textCssMisticaJs.truncateToOneLine]:
|
|
174
|
-
[_textCssMisticaJs.truncateToMoreThanOneLine]:
|
|
175
|
-
}),
|
|
176
|
-
[_textCssMisticaJs.vars.mobileSize]:
|
|
177
|
-
[_textCssMisticaJs.vars.mobileLineHeight]:
|
|
178
|
-
[_textCssMisticaJs.vars.desktopSize]:
|
|
179
|
-
[_textCssMisticaJs.vars.desktopLineHeight]:
|
|
180
|
-
}),
|
|
181
|
-
[_textCssMisticaJs.vars.lineClamp]: String(
|
|
171
|
+
if (!h && h !== 0) return null;
|
|
172
|
+
const M = (0, _classnames.default)(_textCssMisticaJs.text, c ? _textCssMisticaJs.withWordBreak : _textCssMisticaJs.withoutWordBreak, {
|
|
173
|
+
[_textCssMisticaJs.truncateToOneLine]: o === 1 || o === !0,
|
|
174
|
+
[_textCssMisticaJs.truncateToMoreThanOneLine]: o && o > 1
|
|
175
|
+
}), O = (0, _dynamic.assignInlineVars)({
|
|
176
|
+
[_textCssMisticaJs.vars.mobileSize]: d ? (0, _cssJs.pxToRem)(d) : "",
|
|
177
|
+
[_textCssMisticaJs.vars.mobileLineHeight]: k ? (0, _cssJs.pxToRem)(k) : "",
|
|
178
|
+
[_textCssMisticaJs.vars.desktopSize]: b ? (0, _cssJs.pxToRem)(b) : "",
|
|
179
|
+
[_textCssMisticaJs.vars.desktopLineHeight]: L ? (0, _cssJs.pxToRem)(L) : ""
|
|
180
|
+
}), R = o ? (0, _dynamic.assignInlineVars)({
|
|
181
|
+
[_textCssMisticaJs.vars.lineClamp]: String(C)
|
|
182
182
|
}) : {};
|
|
183
|
-
return /*#__PURE__*/ _react.createElement(
|
|
184
|
-
className:
|
|
185
|
-
id:
|
|
186
|
-
role:
|
|
187
|
-
"aria-level":
|
|
188
|
-
}, (0, _domJs.getPrefixedDataAttributes)(
|
|
189
|
-
style: _objectSpreadProps(_objectSpread({},
|
|
190
|
-
hyphens:
|
|
183
|
+
return /*#__PURE__*/ _react.createElement(H, _objectSpreadProps(_objectSpread({
|
|
184
|
+
className: M,
|
|
185
|
+
id: P,
|
|
186
|
+
role: y,
|
|
187
|
+
"aria-level": I
|
|
188
|
+
}, (0, _domJs.getPrefixedDataAttributes)(W)), {
|
|
189
|
+
style: _objectSpreadProps(_objectSpread({}, O, R), {
|
|
190
|
+
hyphens: z,
|
|
191
191
|
letterSpacing: w,
|
|
192
|
-
fontWeight: e ?
|
|
193
|
-
textTransform:
|
|
194
|
-
textDecoration:
|
|
195
|
-
overflowWrap:
|
|
196
|
-
color:
|
|
197
|
-
textAlign:
|
|
192
|
+
fontWeight: e ? K[e] : "inherit",
|
|
193
|
+
textTransform: g || "inherit",
|
|
194
|
+
textDecoration: t != null ? t : "inherit",
|
|
195
|
+
overflowWrap: c ? "anywhere" : "inherit",
|
|
196
|
+
color: V && (S = D[i]) != null ? S : i,
|
|
197
|
+
textAlign: v,
|
|
198
|
+
textShadow: A
|
|
198
199
|
})
|
|
199
|
-
}),
|
|
200
|
-
},
|
|
200
|
+
}), h);
|
|
201
|
+
}, l = (e)=>{
|
|
201
202
|
if (e.light) return "light";
|
|
202
203
|
if (e.regular) return "regular";
|
|
203
204
|
if (e.medium) return "medium";
|
|
204
|
-
},
|
|
205
|
-
|
|
206
|
-
|
|
205
|
+
}, s = (param)=>{
|
|
206
|
+
let { forceMobileSizes: e , mobileSize: i , mobileLineHeight: t , desktopSize: o , desktopLineHeight: g } = param;
|
|
207
|
+
return e ? {
|
|
208
|
+
size: i,
|
|
209
|
+
lineHeight: t
|
|
210
|
+
} : {
|
|
211
|
+
mobileSize: i,
|
|
212
|
+
mobileLineHeight: t,
|
|
213
|
+
desktopSize: o,
|
|
214
|
+
desktopLineHeight: g
|
|
215
|
+
};
|
|
216
|
+
}, ne = (_param)=>{
|
|
217
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
218
|
+
"dataAttributes",
|
|
219
|
+
"forceMobileSizes"
|
|
207
220
|
]);
|
|
208
|
-
const { textPresets:
|
|
209
|
-
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(
|
|
221
|
+
const { textPresets: o } = (0, _hooksJs.useTheme)();
|
|
222
|
+
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
223
|
+
forceMobileSizes: i,
|
|
210
224
|
mobileSize: 48,
|
|
211
225
|
mobileLineHeight: "56px",
|
|
212
226
|
desktopSize: 64,
|
|
213
|
-
desktopLineHeight: "72px"
|
|
214
|
-
|
|
227
|
+
desktopLineHeight: "72px"
|
|
228
|
+
})), {
|
|
229
|
+
weight: o.text10.weight,
|
|
215
230
|
dataAttributes: _objectSpread({
|
|
216
231
|
"component-name": "Text10"
|
|
217
232
|
}, e)
|
|
218
|
-
}, t));
|
|
219
|
-
},
|
|
220
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
221
|
-
"dataAttributes"
|
|
233
|
+
}), t));
|
|
234
|
+
}, re = (_param)=>{
|
|
235
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
236
|
+
"dataAttributes",
|
|
237
|
+
"forceMobileSizes"
|
|
222
238
|
]);
|
|
223
|
-
const { textPresets:
|
|
224
|
-
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(
|
|
239
|
+
const { textPresets: o } = (0, _hooksJs.useTheme)();
|
|
240
|
+
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
241
|
+
forceMobileSizes: i,
|
|
225
242
|
mobileSize: 40,
|
|
226
243
|
mobileLineHeight: "48px",
|
|
227
244
|
desktopSize: 56,
|
|
228
|
-
desktopLineHeight: "64px"
|
|
229
|
-
|
|
245
|
+
desktopLineHeight: "64px"
|
|
246
|
+
})), {
|
|
247
|
+
weight: o.text9.weight,
|
|
230
248
|
dataAttributes: _objectSpread({
|
|
231
249
|
"component-name": "Text9"
|
|
232
250
|
}, e)
|
|
233
|
-
}, t));
|
|
234
|
-
},
|
|
235
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
236
|
-
"dataAttributes"
|
|
251
|
+
}), t));
|
|
252
|
+
}, se = (_param)=>{
|
|
253
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
254
|
+
"dataAttributes",
|
|
255
|
+
"forceMobileSizes"
|
|
237
256
|
]);
|
|
238
|
-
const { textPresets:
|
|
239
|
-
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(
|
|
257
|
+
const { textPresets: o } = (0, _hooksJs.useTheme)();
|
|
258
|
+
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
259
|
+
forceMobileSizes: i,
|
|
240
260
|
mobileSize: 32,
|
|
241
261
|
mobileLineHeight: "40px",
|
|
242
262
|
desktopSize: 48,
|
|
243
|
-
desktopLineHeight: "56px"
|
|
244
|
-
|
|
263
|
+
desktopLineHeight: "56px"
|
|
264
|
+
})), {
|
|
265
|
+
weight: o.text8.weight,
|
|
245
266
|
dataAttributes: _objectSpread({
|
|
246
267
|
"component-name": "Text8"
|
|
247
268
|
}, e)
|
|
248
|
-
}, t));
|
|
249
|
-
},
|
|
250
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
251
|
-
"dataAttributes"
|
|
269
|
+
}), t));
|
|
270
|
+
}, me = (_param)=>{
|
|
271
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
272
|
+
"dataAttributes",
|
|
273
|
+
"forceMobileSizes"
|
|
252
274
|
]);
|
|
253
|
-
const { textPresets:
|
|
254
|
-
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(
|
|
275
|
+
const { textPresets: o } = (0, _hooksJs.useTheme)();
|
|
276
|
+
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
277
|
+
forceMobileSizes: i,
|
|
255
278
|
mobileSize: 28,
|
|
256
279
|
mobileLineHeight: "32px",
|
|
257
280
|
desktopSize: 40,
|
|
258
|
-
desktopLineHeight: "48px"
|
|
259
|
-
|
|
281
|
+
desktopLineHeight: "48px"
|
|
282
|
+
})), {
|
|
283
|
+
weight: o.text7.weight,
|
|
260
284
|
dataAttributes: _objectSpread({
|
|
261
285
|
"component-name": "Text7"
|
|
262
286
|
}, e)
|
|
263
|
-
}, t));
|
|
264
|
-
},
|
|
265
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
266
|
-
"dataAttributes"
|
|
287
|
+
}), t));
|
|
288
|
+
}, xe = (_param)=>{
|
|
289
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
290
|
+
"dataAttributes",
|
|
291
|
+
"forceMobileSizes"
|
|
267
292
|
]);
|
|
268
|
-
const { textPresets:
|
|
269
|
-
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(
|
|
293
|
+
const { textPresets: o } = (0, _hooksJs.useTheme)();
|
|
294
|
+
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
295
|
+
forceMobileSizes: i,
|
|
270
296
|
mobileSize: 24,
|
|
271
297
|
mobileLineHeight: "32px",
|
|
272
298
|
desktopSize: 32,
|
|
273
|
-
desktopLineHeight: "40px"
|
|
274
|
-
|
|
299
|
+
desktopLineHeight: "40px"
|
|
300
|
+
})), {
|
|
301
|
+
weight: o.text6.weight,
|
|
275
302
|
dataAttributes: _objectSpread({
|
|
276
303
|
"component-name": "Text6"
|
|
277
304
|
}, e)
|
|
278
|
-
}, t));
|
|
279
|
-
},
|
|
280
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
281
|
-
"dataAttributes"
|
|
305
|
+
}), t));
|
|
306
|
+
}, ae = (_param)=>{
|
|
307
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
308
|
+
"dataAttributes",
|
|
309
|
+
"forceMobileSizes"
|
|
282
310
|
]);
|
|
283
|
-
const { textPresets:
|
|
284
|
-
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(
|
|
311
|
+
const { textPresets: o } = (0, _hooksJs.useTheme)();
|
|
312
|
+
return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
313
|
+
forceMobileSizes: i,
|
|
285
314
|
mobileSize: 20,
|
|
286
315
|
mobileLineHeight: "24px",
|
|
287
316
|
desktopSize: 28,
|
|
288
|
-
desktopLineHeight: "32px"
|
|
289
|
-
|
|
317
|
+
desktopLineHeight: "32px"
|
|
318
|
+
})), {
|
|
319
|
+
weight: o.text5.weight,
|
|
290
320
|
dataAttributes: _objectSpread({
|
|
291
321
|
"component-name": "Text5"
|
|
292
322
|
}, e)
|
|
293
|
-
}, t));
|
|
294
|
-
},
|
|
295
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
296
|
-
"dataAttributes"
|
|
323
|
+
}), t));
|
|
324
|
+
}, pe = (_param)=>/* @__PURE__ */ {
|
|
325
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
326
|
+
"dataAttributes",
|
|
327
|
+
"forceMobileSizes"
|
|
297
328
|
]);
|
|
298
|
-
return (0, _jsxRuntimeJs.jsx)(
|
|
329
|
+
return (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
330
|
+
forceMobileSizes: i,
|
|
299
331
|
mobileSize: 18,
|
|
300
332
|
mobileLineHeight: "24px",
|
|
301
333
|
desktopSize: 20,
|
|
302
|
-
desktopLineHeight: "28px"
|
|
303
|
-
|
|
334
|
+
desktopLineHeight: "28px"
|
|
335
|
+
})), {
|
|
336
|
+
weight: l(t),
|
|
304
337
|
dataAttributes: _objectSpread({
|
|
305
338
|
"component-name": "Text4"
|
|
306
339
|
}, e)
|
|
307
|
-
}, t));
|
|
308
|
-
},
|
|
309
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
310
|
-
"dataAttributes"
|
|
340
|
+
}), t));
|
|
341
|
+
}, le = (_param)=>/* @__PURE__ */ {
|
|
342
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
343
|
+
"dataAttributes",
|
|
344
|
+
"forceMobileSizes"
|
|
311
345
|
]);
|
|
312
|
-
return (0, _jsxRuntimeJs.jsx)(
|
|
346
|
+
return (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
347
|
+
forceMobileSizes: i,
|
|
313
348
|
mobileSize: 16,
|
|
349
|
+
mobileLineHeight: "24px",
|
|
314
350
|
desktopSize: 18,
|
|
315
|
-
|
|
316
|
-
|
|
351
|
+
desktopLineHeight: "24px"
|
|
352
|
+
})), {
|
|
353
|
+
weight: l(t),
|
|
317
354
|
dataAttributes: _objectSpread({
|
|
318
355
|
"component-name": "Text3"
|
|
319
356
|
}, e)
|
|
320
|
-
}, t));
|
|
321
|
-
},
|
|
322
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
323
|
-
"dataAttributes"
|
|
357
|
+
}), t));
|
|
358
|
+
}, ge = (_param)=>/* @__PURE__ */ {
|
|
359
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
360
|
+
"dataAttributes",
|
|
361
|
+
"forceMobileSizes"
|
|
324
362
|
]);
|
|
325
|
-
return (0, _jsxRuntimeJs.jsx)(
|
|
363
|
+
return (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
364
|
+
forceMobileSizes: i,
|
|
326
365
|
mobileSize: 14,
|
|
327
366
|
mobileLineHeight: "20px",
|
|
328
367
|
desktopSize: 16,
|
|
329
|
-
desktopLineHeight: "24px"
|
|
330
|
-
|
|
368
|
+
desktopLineHeight: "24px"
|
|
369
|
+
})), {
|
|
370
|
+
weight: l(t),
|
|
331
371
|
dataAttributes: _objectSpread({
|
|
332
372
|
"component-name": "Text2"
|
|
333
373
|
}, e)
|
|
334
|
-
}, t));
|
|
335
|
-
},
|
|
336
|
-
var { dataAttributes: e } = _param, t = _objectWithoutProperties(_param, [
|
|
337
|
-
"dataAttributes"
|
|
374
|
+
}), t));
|
|
375
|
+
}, he = (_param)=>/* @__PURE__ */ {
|
|
376
|
+
var { dataAttributes: e , forceMobileSizes: i } = _param, t = _objectWithoutProperties(_param, [
|
|
377
|
+
"dataAttributes",
|
|
378
|
+
"forceMobileSizes"
|
|
338
379
|
]);
|
|
339
|
-
return (0, _jsxRuntimeJs.jsx)(
|
|
380
|
+
return (0, _jsxRuntimeJs.jsx)(r, _objectSpread(_objectSpreadProps(_objectSpread({}, s({
|
|
381
|
+
forceMobileSizes: i,
|
|
340
382
|
mobileSize: 12,
|
|
341
383
|
mobileLineHeight: "16px",
|
|
342
384
|
desktopSize: 14,
|
|
343
|
-
desktopLineHeight: "20px"
|
|
344
|
-
|
|
385
|
+
desktopLineHeight: "20px"
|
|
386
|
+
})), {
|
|
387
|
+
weight: l(t),
|
|
345
388
|
dataAttributes: _objectSpread({
|
|
346
389
|
"component-name": "Text1"
|
|
347
390
|
}, e)
|
|
348
|
-
}, t));
|
|
391
|
+
}), t));
|
|
349
392
|
};
|
package/dist-es/boxed.js
CHANGED
|
@@ -50,41 +50,46 @@ function _objectSpreadProps(target, source) {
|
|
|
50
50
|
}
|
|
51
51
|
return target;
|
|
52
52
|
}
|
|
53
|
-
import * as
|
|
54
|
-
import
|
|
55
|
-
import { useIsInverseVariant as
|
|
53
|
+
import * as n from "react";
|
|
54
|
+
import v from "classnames";
|
|
55
|
+
import { useIsInverseVariant as B, ThemeVariant as h } from "./theme-variant-context.js";
|
|
56
56
|
import { getPrefixedDataAttributes as k } from "./utils/dom.js";
|
|
57
|
-
import { vars as
|
|
58
|
-
import { useTheme as
|
|
59
|
-
import { inverseBorder as
|
|
57
|
+
import { vars as i } from "./skins/skin-contract.css-mistica.js";
|
|
58
|
+
import { useTheme as R } from "./hooks.js";
|
|
59
|
+
import { inverseBorder as w } from "./boxed.css-mistica.js";
|
|
60
60
|
import { sprinkles as e } from "./sprinkles.css-mistica.js";
|
|
61
|
-
import { jsx as
|
|
62
|
-
const
|
|
61
|
+
import { jsx as t } from "./_virtual/jsx-runtime.js";
|
|
62
|
+
const y = (o, r)=>o && !r ? w : r ? e({
|
|
63
63
|
border: "none"
|
|
64
64
|
}) : e({
|
|
65
65
|
border: "regular"
|
|
66
|
-
}),
|
|
67
|
-
let { children: o , isInverse: r = !1 , className:
|
|
68
|
-
const { isDarkMode:
|
|
69
|
-
return /* @__PURE__ */
|
|
70
|
-
ref:
|
|
66
|
+
}), D = /*#__PURE__*/ n.forwardRef((param, p)=>{
|
|
67
|
+
let { children: o , isInverse: r = !1 , className: s , role: m , dataAttributes: d , "aria-label": f , width: l , height: c , minHeight: u , borderRadius: b , background: a } = param;
|
|
68
|
+
const { isDarkMode: x } = R(), g = B();
|
|
69
|
+
return /* @__PURE__ */ t("div", _objectSpreadProps(_objectSpread({
|
|
70
|
+
ref: p,
|
|
71
71
|
style: {
|
|
72
|
-
width:
|
|
73
|
-
height:
|
|
74
|
-
|
|
72
|
+
width: l,
|
|
73
|
+
height: c,
|
|
74
|
+
minHeight: u,
|
|
75
|
+
boxSizing: "border-box",
|
|
76
|
+
background: a
|
|
75
77
|
},
|
|
76
|
-
className:
|
|
77
|
-
borderRadius:
|
|
78
|
+
className: v(s, y(g, r), e({
|
|
79
|
+
borderRadius: b,
|
|
78
80
|
overflow: "hidden",
|
|
79
|
-
background: r && !
|
|
81
|
+
background: a ? void 0 : r && !x ? i.colors.backgroundBrand : i.colors.backgroundContainer
|
|
80
82
|
})),
|
|
81
|
-
role:
|
|
82
|
-
"aria-label":
|
|
83
|
-
}, k(
|
|
84
|
-
children: /* @__PURE__ */
|
|
83
|
+
role: m,
|
|
84
|
+
"aria-label": f
|
|
85
|
+
}, k(d)), {
|
|
86
|
+
children: /* @__PURE__ */ t(h, {
|
|
85
87
|
isInverse: r,
|
|
86
88
|
children: o
|
|
87
89
|
})
|
|
88
90
|
}));
|
|
89
|
-
})
|
|
90
|
-
|
|
91
|
+
}), N = /*#__PURE__*/ n.forwardRef((o, r)=>/* @__PURE__ */ t(D, _objectSpreadProps(_objectSpread({}, o), {
|
|
92
|
+
ref: r,
|
|
93
|
+
borderRadius: 8
|
|
94
|
+
})));
|
|
95
|
+
export { N as Boxed, D as InternalBoxed };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import "./sprinkles.css.ts.vanilla.js";
|
|
2
2
|
import "./card.css.ts.vanilla.js";
|
|
3
|
-
var _ = "_15e54s91 _1y2v1nf5i _1y2v1nf64 _1y2v1nf5y", y = "_1y2v1nf5i", f = "_15e54s97 _1y2v1nf72 _1y2v1nf7g _1y2v1nf6b _1y2v1nf6p _1y2v1nf5i _1y2v1nf64 _1y2v1nf5o _1y2v1nf7p",
|
|
4
|
-
export { _ as actions, y as boxed, f as
|
|
3
|
+
var _ = "_15e54s91 _1y2v1nf5i _1y2v1nf64 _1y2v1nf5y", y = "_1y2v1nf5i", f = "_15e54s9i _1y2v1nf7y _1y2v1nf8d _1y2v1nf5i _1y2v1nf5x _1y2v1nf5r _1y2v1nf9h", a = "_1y2v1nf5i _1y2v1nf80 _1y2v1nf8f _1y2v1nf5x _1y2v1nf5r", r = "_15e54s9j _1y2v1nf7y _1y2v1nf8d _1y2v1nf5i _1y2v1nf5x _1y2v1nf5r _1y2v1nf9h", e = "_15e54s97 _1y2v1nf72 _1y2v1nf7g _1y2v1nf6b _1y2v1nf6p _1y2v1nf5i _1y2v1nf64 _1y2v1nf5o _1y2v1nf7p", i = "_15e54s9e _1y2v1nf5i _1y2v1nf64 _1y2v1nf5o _1y2v1nf5u", o = "_15e54s9f", d = "_1y2v1nf5i _1y2v1nf5o _1y2v1nf85 _1y2v1nf7p", s = "_15e54s95 _1y2v1nf72 _1y2v1nf7g _1y2v1nf5i _1y2v1nf64 _1y2v1nf6a _1y2v1nf6p _1y2v1nf5o", p = "_15e54s99 _1y2v1nf6a _1y2v1nf6o _1y2v1nf72 _1y2v1nf7g _1y2v1nf5i _1y2v1nf85 _1y2v1nf5o _1y2v1nf5u _1y2v1nf64", t = "_15e54s9b _1y2v1nf65 _1y2v1nf6j _1y2v1nf6x _1y2v1nf7b _1y2v1nf5i _1y2v1nf85 _1y2v1nf7p _1y2v1nf9g _1y2v1nf5c", c = "_15e54s9c _1y2v1nf65 _1y2v1nf6j _1y2v1nf6x _1y2v1nf7b _1y2v1nf5i _1y2v1nf85 _1y2v1nf7p _1y2v1nf9g _1y2v1nf5c";
|
|
4
|
+
export { _ as actions, y as boxed, f as cardAction, a as cardActionIconButton, r as cardActionInverse, e as dataCard, i as displayCard, o as displayCardGradient, d as mediaCard, s as mediaCardContent, p as snapCard, t as snapCardTouchableHover, c as snapCardTouchableHoverTransparent };
|