@rabex-kit/rabex-ui 0.1.33 → 0.1.34
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/Theme/Tabs/index.d.ts +1 -2673
- package/dist/rabex-ui.cjs.development.js +94 -47
- package/dist/rabex-ui.cjs.development.js.map +1 -1
- package/dist/rabex-ui.cjs.production.min.js +1 -1
- package/dist/rabex-ui.cjs.production.min.js.map +1 -1
- package/dist/rabex-ui.esm.js +94 -47
- package/dist/rabex-ui.esm.js.map +1 -1
- package/package.json +1 -1
@@ -3131,20 +3131,28 @@ var RabexTabs = {
|
|
3131
3131
|
root: function root(_ref) {
|
3132
3132
|
var ownerState = _ref.ownerState,
|
3133
3133
|
theme = _ref.theme;
|
3134
|
-
|
3134
|
+
// The ownerState now contains all the props you need
|
3135
|
+
var _ref2 = ownerState || {},
|
3136
|
+
hasBorder = _ref2.hasBorder,
|
3137
|
+
isSeparate = _ref2.isSeparate,
|
3138
|
+
size = _ref2.size,
|
3139
|
+
mode = _ref2.mode,
|
3140
|
+
variant = _ref2.variant,
|
3141
|
+
orientation = _ref2.orientation;
|
3142
|
+
// Default styles applied to all tabs
|
3143
|
+
var baseStyles = {
|
3135
3144
|
borderRadius: 8,
|
3136
3145
|
minHeight: 'unset',
|
3137
3146
|
color: theme.palette.base.A10
|
3138
|
-
}
|
3147
|
+
};
|
3148
|
+
// Mode-specific styles
|
3149
|
+
var modeStyles = mode === 'underline' ? {
|
3139
3150
|
'& .MuiTab-root.Mui-selected': {
|
3140
3151
|
borderRadius: 4,
|
3141
3152
|
color: theme.palette.mode === 'light' ? theme.palette.textColor.A60 : theme.palette.textColor.A0
|
3142
3153
|
},
|
3143
|
-
'& .MuiTabs-flexContainer': {
|
3144
|
-
// padding: theme.spacing(1)
|
3145
|
-
},
|
3146
3154
|
backgroundColor: 'unset'
|
3147
|
-
}
|
3155
|
+
} : {
|
3148
3156
|
'& .MuiTab-root.Mui-selected': {
|
3149
3157
|
borderRadius: 4,
|
3150
3158
|
color: theme.palette.mode === 'light' ? theme.palette.textColor.A60 : theme.palette.textColor.A0
|
@@ -3153,58 +3161,97 @@ var RabexTabs = {
|
|
3153
3161
|
padding: theme.spacing(1)
|
3154
3162
|
},
|
3155
3163
|
backgroundColor: theme.palette.mode === 'light' ? theme.palette.secondary.A100 : theme.palette.secondary.A100
|
3156
|
-
}
|
3157
|
-
|
3158
|
-
|
3159
|
-
|
3160
|
-
|
3161
|
-
|
3162
|
-
|
3163
|
-
|
3164
|
-
|
3165
|
-
|
3166
|
-
|
3167
|
-
|
3168
|
-
|
3169
|
-
borderRadius: theme.spacing(2)
|
3170
|
-
}, ownerState.size === 'lg' && {
|
3171
|
-
'& .MuiTabs-fixed': {
|
3172
|
-
padding: theme.spacing(3, 4),
|
3173
|
-
marginBottom: theme.spacing(3)
|
3174
|
-
},
|
3175
|
-
height: theme.spacing(12),
|
3176
|
-
borderRadius: theme.spacing(3)
|
3177
|
-
}, ownerState.mode === 'underline' && {
|
3178
|
-
'& .MuiTab-root.Mui-selected': {
|
3179
|
-
borderRadius: 4,
|
3180
|
-
color: theme.palette.mode === 'light' ? theme.palette.textColor.A60 : theme.palette.textColor.A0
|
3164
|
+
};
|
3165
|
+
// Size-specific styles
|
3166
|
+
var sizeMap = mode === 'underline' ? {
|
3167
|
+
sm: {
|
3168
|
+
'& .MuiTabs-fixed': {
|
3169
|
+
'& .MuiTab-root': {
|
3170
|
+
padding: theme.spacing(1, 2)
|
3171
|
+
},
|
3172
|
+
// padding: theme.spacing(1, 2),
|
3173
|
+
marginBottom: theme.spacing(2)
|
3174
|
+
},
|
3175
|
+
height: theme.spacing(8),
|
3176
|
+
borderRadius: theme.spacing(2)
|
3181
3177
|
},
|
3182
|
-
|
3183
|
-
|
3178
|
+
md: {
|
3179
|
+
'& .MuiTabs-fixed': {
|
3180
|
+
'& .MuiTab-root': {
|
3181
|
+
padding: theme.spacing(2, 4)
|
3182
|
+
},
|
3183
|
+
// padding: theme.spacing(2, 4),
|
3184
|
+
marginBottom: theme.spacing(2)
|
3185
|
+
},
|
3186
|
+
height: theme.spacing(10),
|
3187
|
+
borderRadius: theme.spacing(2)
|
3184
3188
|
},
|
3185
|
-
|
3186
|
-
|
3187
|
-
|
3188
|
-
|
3189
|
-
|
3189
|
+
lg: {
|
3190
|
+
'& .MuiTabs-fixed': {
|
3191
|
+
'& .MuiTab-root': {
|
3192
|
+
padding: theme.spacing(3, 4)
|
3193
|
+
},
|
3194
|
+
// padding: theme.spacing(3, 4),
|
3195
|
+
marginBottom: theme.spacing(3)
|
3196
|
+
},
|
3197
|
+
height: theme.spacing(12),
|
3198
|
+
borderRadius: theme.spacing(3)
|
3199
|
+
}
|
3200
|
+
} : {
|
3201
|
+
sm: {
|
3202
|
+
'& .MuiTabs-fixed': {
|
3203
|
+
padding: theme.spacing(1, 2),
|
3204
|
+
marginBottom: theme.spacing(2)
|
3205
|
+
},
|
3206
|
+
height: theme.spacing(8),
|
3207
|
+
borderRadius: theme.spacing(2)
|
3190
3208
|
},
|
3191
|
-
|
3192
|
-
|
3209
|
+
md: {
|
3210
|
+
'& .MuiTabs-fixed': {
|
3211
|
+
padding: theme.spacing(2, 4),
|
3212
|
+
marginBottom: theme.spacing(2)
|
3213
|
+
},
|
3214
|
+
height: theme.spacing(10),
|
3215
|
+
borderRadius: theme.spacing(2)
|
3193
3216
|
},
|
3194
|
-
|
3195
|
-
|
3217
|
+
lg: {
|
3218
|
+
'& .MuiTabs-fixed': {
|
3219
|
+
padding: theme.spacing(3, 4),
|
3220
|
+
marginBottom: theme.spacing(3)
|
3221
|
+
},
|
3222
|
+
height: theme.spacing(12),
|
3223
|
+
borderRadius: theme.spacing(3)
|
3224
|
+
}
|
3225
|
+
};
|
3226
|
+
var sizeStyles = sizeMap[size || 'sm'] || sizeMap.sm;
|
3227
|
+
// Variant-specific styles
|
3228
|
+
var variantStyles = variant === 'fullWidth' ? {
|
3196
3229
|
width: '100%'
|
3197
|
-
}
|
3230
|
+
} : {};
|
3231
|
+
// Orientation-specific styles
|
3232
|
+
var orientationStyles = orientation === 'vertical' ? {
|
3198
3233
|
'& .MuiTab-root::after': {
|
3199
3234
|
content: 'unset',
|
3200
3235
|
display: 'none'
|
3201
3236
|
}
|
3202
|
-
}
|
3237
|
+
} : {};
|
3238
|
+
// Border styles
|
3239
|
+
var borderStyles = hasBorder ? isSeparate ? {
|
3240
|
+
'& .MuiTab-root': {
|
3241
|
+
borderRadius: 5,
|
3242
|
+
padding: theme.spacing(2, 3),
|
3243
|
+
border: "2px dotted " + theme.palette.base.A40
|
3244
|
+
}
|
3245
|
+
} : {
|
3246
|
+
border: "2px dotted " + theme.palette.base.A40
|
3247
|
+
} : {};
|
3248
|
+
// Return combined styles
|
3249
|
+
return _extends({}, baseStyles, modeStyles, sizeStyles, variantStyles, orientationStyles, borderStyles);
|
3203
3250
|
},
|
3204
|
-
indicator: function indicator(
|
3205
|
-
var ownerState =
|
3251
|
+
indicator: function indicator(_ref3) {
|
3252
|
+
var ownerState = _ref3.ownerState;
|
3206
3253
|
return {
|
3207
|
-
display: ownerState.mode === 'underline' ? 'show' : 'none'
|
3254
|
+
display: (ownerState === null || ownerState === void 0 ? void 0 : ownerState.mode) === 'underline' ? 'show' : 'none'
|
3208
3255
|
};
|
3209
3256
|
}
|
3210
3257
|
},
|