@xsolla/xui-core 0.141.1 → 0.147.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/index.d.mts +410 -2
- package/index.d.ts +410 -2
- package/index.js +209 -1
- package/index.js.map +1 -1
- package/index.mjs +209 -1
- package/index.mjs.map +1 -1
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -2354,6 +2354,91 @@ var themeConfig = (mode = "dark", productContext = defaultProductContext) => {
|
|
|
2354
2354
|
};
|
|
2355
2355
|
return configs[size];
|
|
2356
2356
|
},
|
|
2357
|
+
imageUploader: (size) => {
|
|
2358
|
+
const configs = {
|
|
2359
|
+
xl: {
|
|
2360
|
+
box: 200,
|
|
2361
|
+
wideWidth: 440,
|
|
2362
|
+
padding: 14,
|
|
2363
|
+
gap: 10,
|
|
2364
|
+
iconSize: 32,
|
|
2365
|
+
labelFontSize: 20,
|
|
2366
|
+
labelLineHeight: 22,
|
|
2367
|
+
descriptionFontSize: 20,
|
|
2368
|
+
descriptionLineHeight: 22,
|
|
2369
|
+
errorFontSize: 16,
|
|
2370
|
+
errorLineHeight: 18,
|
|
2371
|
+
errorGap: 8,
|
|
2372
|
+
radius: 8,
|
|
2373
|
+
borderWidth: 1
|
|
2374
|
+
},
|
|
2375
|
+
lg: {
|
|
2376
|
+
box: 168,
|
|
2377
|
+
wideWidth: 440,
|
|
2378
|
+
padding: 14,
|
|
2379
|
+
gap: 10,
|
|
2380
|
+
iconSize: 24,
|
|
2381
|
+
labelFontSize: 18,
|
|
2382
|
+
labelLineHeight: 24,
|
|
2383
|
+
descriptionFontSize: 18,
|
|
2384
|
+
descriptionLineHeight: 20,
|
|
2385
|
+
errorFontSize: 16,
|
|
2386
|
+
errorLineHeight: 18,
|
|
2387
|
+
errorGap: 8,
|
|
2388
|
+
radius: 8,
|
|
2389
|
+
borderWidth: 1
|
|
2390
|
+
},
|
|
2391
|
+
md: {
|
|
2392
|
+
box: 136,
|
|
2393
|
+
wideWidth: 400,
|
|
2394
|
+
padding: 12,
|
|
2395
|
+
gap: 8,
|
|
2396
|
+
iconSize: 24,
|
|
2397
|
+
labelFontSize: 16,
|
|
2398
|
+
labelLineHeight: 20,
|
|
2399
|
+
descriptionFontSize: 14,
|
|
2400
|
+
descriptionLineHeight: 16,
|
|
2401
|
+
errorFontSize: 14,
|
|
2402
|
+
errorLineHeight: 16,
|
|
2403
|
+
errorGap: 6,
|
|
2404
|
+
radius: 8,
|
|
2405
|
+
borderWidth: 1
|
|
2406
|
+
},
|
|
2407
|
+
sm: {
|
|
2408
|
+
box: 104,
|
|
2409
|
+
wideWidth: 320,
|
|
2410
|
+
padding: 10,
|
|
2411
|
+
gap: 6,
|
|
2412
|
+
iconSize: 18,
|
|
2413
|
+
labelFontSize: 14,
|
|
2414
|
+
labelLineHeight: 18,
|
|
2415
|
+
descriptionFontSize: 14,
|
|
2416
|
+
descriptionLineHeight: 18,
|
|
2417
|
+
errorFontSize: 12,
|
|
2418
|
+
errorLineHeight: 14,
|
|
2419
|
+
errorGap: 6,
|
|
2420
|
+
radius: 8,
|
|
2421
|
+
borderWidth: 1
|
|
2422
|
+
},
|
|
2423
|
+
xs: {
|
|
2424
|
+
box: 72,
|
|
2425
|
+
wideWidth: 240,
|
|
2426
|
+
padding: 8,
|
|
2427
|
+
gap: 4,
|
|
2428
|
+
iconSize: 18,
|
|
2429
|
+
labelFontSize: 12,
|
|
2430
|
+
labelLineHeight: 16,
|
|
2431
|
+
descriptionFontSize: 12,
|
|
2432
|
+
descriptionLineHeight: 16,
|
|
2433
|
+
errorFontSize: 11,
|
|
2434
|
+
errorLineHeight: 13,
|
|
2435
|
+
errorGap: 4,
|
|
2436
|
+
radius: 8,
|
|
2437
|
+
borderWidth: 1
|
|
2438
|
+
}
|
|
2439
|
+
};
|
|
2440
|
+
return configs[size];
|
|
2441
|
+
},
|
|
2357
2442
|
inputPin: (size) => {
|
|
2358
2443
|
const configs = {
|
|
2359
2444
|
xl: {
|
|
@@ -2896,7 +2981,10 @@ var themeConfig = (mode = "dark", productContext = defaultProductContext) => {
|
|
|
2896
2981
|
md: { height: 6, labelSize: 12, helperSize: 12, gap: 6 },
|
|
2897
2982
|
sm: { height: 4, labelSize: 12, helperSize: 12, gap: 4 },
|
|
2898
2983
|
xs: { height: 2, labelSize: 10, helperSize: 10, gap: 2 },
|
|
2899
|
-
xxs: { height: 2, labelSize: 10, helperSize: 10, gap: 2 }
|
|
2984
|
+
xxs: { height: 2, labelSize: 10, helperSize: 10, gap: 2 },
|
|
2985
|
+
l: { height: 8, labelSize: 16, helperSize: 14, gap: 10 },
|
|
2986
|
+
m: { height: 6, labelSize: 14, helperSize: 12, gap: 8 },
|
|
2987
|
+
s: { height: 4, labelSize: 12, helperSize: 12, gap: 6 }
|
|
2900
2988
|
};
|
|
2901
2989
|
return configs[size];
|
|
2902
2990
|
},
|
|
@@ -3037,6 +3125,126 @@ var themeConfig = (mode = "dark", productContext = defaultProductContext) => {
|
|
|
3037
3125
|
zIndex: 1e3
|
|
3038
3126
|
};
|
|
3039
3127
|
},
|
|
3128
|
+
drawer: () => ({
|
|
3129
|
+
// Sizing values from Figma design: B2B Components Library node-id=8291-103845
|
|
3130
|
+
widthSm: 480,
|
|
3131
|
+
widthMd: 620,
|
|
3132
|
+
widthLg: 1056,
|
|
3133
|
+
headerHeight: 80,
|
|
3134
|
+
headerPaddingX: 32,
|
|
3135
|
+
headerPaddingY: 24,
|
|
3136
|
+
headerGap: 24,
|
|
3137
|
+
titleFontSize: 18,
|
|
3138
|
+
titleLineHeight: 24,
|
|
3139
|
+
contentPaddingX: 32,
|
|
3140
|
+
footerPadding: 16,
|
|
3141
|
+
outerPadding: 8,
|
|
3142
|
+
containerRadius: 4,
|
|
3143
|
+
contentRadius: 8,
|
|
3144
|
+
stepperPadding: 16,
|
|
3145
|
+
stepperRadius: 8,
|
|
3146
|
+
stepperContentGap: 8,
|
|
3147
|
+
scrimColor: "rgba(0, 0, 0, 0.75)",
|
|
3148
|
+
animationDuration: 300,
|
|
3149
|
+
zIndex: 1e3
|
|
3150
|
+
}),
|
|
3151
|
+
sidebar: () => ({
|
|
3152
|
+
// Sizing values from Figma design: B2B Components Library
|
|
3153
|
+
widthExpanded: 280,
|
|
3154
|
+
widthCollapsed: 48,
|
|
3155
|
+
radius: 4,
|
|
3156
|
+
itemHeight: 32,
|
|
3157
|
+
iconSize: 18,
|
|
3158
|
+
padding: 8,
|
|
3159
|
+
sectionLabelHeight: 20,
|
|
3160
|
+
// Aligns nested item text with parent label (padding 8 + icon 18 + gap 8 = 34)
|
|
3161
|
+
// and centers the rail under the parent icon (padding 8 + iconSize/2 = 17).
|
|
3162
|
+
nestedItemPaddingLeft: 34,
|
|
3163
|
+
nestedItemRailLeft: 17,
|
|
3164
|
+
chevronSize: 14,
|
|
3165
|
+
externalIconSize: 18,
|
|
3166
|
+
chatBadgeSize: 6,
|
|
3167
|
+
itemBadgeSize: 4,
|
|
3168
|
+
focusOutlineWidth: 2,
|
|
3169
|
+
scrollbarWidth: 4,
|
|
3170
|
+
popoverGap: 12,
|
|
3171
|
+
popoverViewportPadding: 8,
|
|
3172
|
+
popoverMinWidth: 180,
|
|
3173
|
+
popoverMaxWidth: 240,
|
|
3174
|
+
popoverShadow: "0 2px 25px rgba(7, 7, 8, 0.15)",
|
|
3175
|
+
popoverZIndex: 1e3,
|
|
3176
|
+
transitionWidth: "0.25s ease-in-out",
|
|
3177
|
+
transitionFadeIn: "opacity 0.15s ease-in-out 0.1s",
|
|
3178
|
+
transitionFadeOut: "opacity 0.1s ease-in-out",
|
|
3179
|
+
transitionItem: "background-color 0.15s ease-in-out, color 0.15s ease-in-out",
|
|
3180
|
+
transitionRows: "grid-template-rows 0.25s ease-in-out"
|
|
3181
|
+
}),
|
|
3182
|
+
stepperB2b: () => ({
|
|
3183
|
+
// Sizing values from Figma design: B2B Components Library
|
|
3184
|
+
// variant grid node-id=10999-17988, state grid node-id=10259-5501
|
|
3185
|
+
chipSize: 32,
|
|
3186
|
+
chipRadius: 2,
|
|
3187
|
+
chipPaddingTop: 5,
|
|
3188
|
+
chipPaddingBottom: 4,
|
|
3189
|
+
chipPaddingX: 4,
|
|
3190
|
+
chipIconSize: 16,
|
|
3191
|
+
numberFontSize: 18,
|
|
3192
|
+
numberLineHeight: 24,
|
|
3193
|
+
titleFontSize: 16,
|
|
3194
|
+
titleLineHeight: 20,
|
|
3195
|
+
descriptionFontSize: 14,
|
|
3196
|
+
descriptionLineHeight: 20,
|
|
3197
|
+
captionFontSize: 12,
|
|
3198
|
+
captionLineHeight: 16,
|
|
3199
|
+
itemGap: 12,
|
|
3200
|
+
contentGap: 4,
|
|
3201
|
+
contentMinHeight: 32,
|
|
3202
|
+
contentWidth: 128,
|
|
3203
|
+
activeCardRadiusVertical: 4,
|
|
3204
|
+
activeCardRadiusHorizontal: 6,
|
|
3205
|
+
activeCardPaddingTop: 24,
|
|
3206
|
+
activeCardPaddingX: 24,
|
|
3207
|
+
activeCardPaddingYHorizontal: 12,
|
|
3208
|
+
activeCardPaddingLeftHorizontal: 12,
|
|
3209
|
+
activeCardGapHorizontal: 8,
|
|
3210
|
+
innerConnectorLength: 48,
|
|
3211
|
+
connectorSegment: 24,
|
|
3212
|
+
connectorCellHeight: 24,
|
|
3213
|
+
connectorCellWidth: 80,
|
|
3214
|
+
surfaceRadius: 8,
|
|
3215
|
+
surfacePaddingVertical: 16,
|
|
3216
|
+
surfacePaddingHorizontal: 8,
|
|
3217
|
+
horizontalItemGap: 16,
|
|
3218
|
+
horizontalFirstItemWidth: 220,
|
|
3219
|
+
horizontalItemWidth: 236,
|
|
3220
|
+
horizontalConnectorSegment: 32,
|
|
3221
|
+
horizontalConnectorGap: 12,
|
|
3222
|
+
simpleCardPadding: 12,
|
|
3223
|
+
simpleCardRadius: 4,
|
|
3224
|
+
simpleCardGap: 4,
|
|
3225
|
+
simpleItemGap: 4,
|
|
3226
|
+
simpleHorizontalCellWidth: 56,
|
|
3227
|
+
simpleHorizontalStubLength: 8
|
|
3228
|
+
}),
|
|
3229
|
+
collapsibleB2b: () => ({
|
|
3230
|
+
// Sizing values from Figma design: B2B Components Library node-id=10469-6509
|
|
3231
|
+
triggerPadding: 16,
|
|
3232
|
+
triggerGap: 12,
|
|
3233
|
+
triggerMinHeight: 56,
|
|
3234
|
+
surfaceRadius: 8,
|
|
3235
|
+
cellRadius: 4,
|
|
3236
|
+
iconSlotSize: 32,
|
|
3237
|
+
iconSlotRadius: 4,
|
|
3238
|
+
chevronSize: 24,
|
|
3239
|
+
trailingGap: 8,
|
|
3240
|
+
textGap: 2,
|
|
3241
|
+
titleFontSize: 16,
|
|
3242
|
+
titleLineHeight: 20,
|
|
3243
|
+
captionFontSize: 12,
|
|
3244
|
+
captionLineHeight: 18,
|
|
3245
|
+
panelPadding: 16,
|
|
3246
|
+
accordionItemGap: 8
|
|
3247
|
+
}),
|
|
3040
3248
|
toast: () => {
|
|
3041
3249
|
return {
|
|
3042
3250
|
minHeight: 64,
|