@mamrp/components 1.7.37 → 1.7.41

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/index.d.mts CHANGED
@@ -100,6 +100,7 @@ interface JalaliDatePickerProps$2 {
100
100
  minDate?: any;
101
101
  clear?: boolean;
102
102
  views?: ("year" | "month" | "day")[];
103
+ variant?: "outlined" | "standard";
103
104
  }
104
105
  declare const JalaliDatePicker$2: React__default.FC<JalaliDatePickerProps$2>;
105
106
 
package/dist/index.d.ts CHANGED
@@ -100,6 +100,7 @@ interface JalaliDatePickerProps$2 {
100
100
  minDate?: any;
101
101
  clear?: boolean;
102
102
  views?: ("year" | "month" | "day")[];
103
+ variant?: "outlined" | "standard";
103
104
  }
104
105
  declare const JalaliDatePicker$2: React__default.FC<JalaliDatePickerProps$2>;
105
106
 
package/dist/index.js CHANGED
@@ -1171,7 +1171,8 @@ var JalaliDatePicker = ({
1171
1171
  maxDate,
1172
1172
  minDate,
1173
1173
  clear = true,
1174
- views
1174
+ views,
1175
+ variant = "outlined"
1175
1176
  }) => {
1176
1177
  const today = (0, import_moment_jalaali.default)();
1177
1178
  const customLocaleText = {
@@ -1273,6 +1274,7 @@ var JalaliDatePicker = ({
1273
1274
  size,
1274
1275
  placeholder: field.value || isLoading ? "" : "\u0627\u0646\u062A\u062E\u0627\u0628 \u062A\u0627\u0631\u06CC\u062E ",
1275
1276
  onClick: () => !disabled && !isLoading && setOpen(true),
1277
+ variant,
1276
1278
  InputLabelProps: {
1277
1279
  shrink: true,
1278
1280
  style: { color: error ? "#D32F2F" : "inherit" }
@@ -1321,7 +1323,8 @@ var JalaliDatePicker = ({
1321
1323
  display: "flex",
1322
1324
  alignItems: "center",
1323
1325
  gap: "2px",
1324
- ...clear && field.value && { mr: 4.5 }
1326
+ ...variant === "outlined" && clear && field.value && { mr: 4.5 },
1327
+ ...variant === "standard" && clear && field.value && { mr: 4.5 }
1325
1328
  }
1326
1329
  },
1327
1330
  /* @__PURE__ */ import_react7.default.createElement(import_material9.Tooltip, { title: "\u0631\u0648\u0632 \u0642\u0628\u0644" }, /* @__PURE__ */ import_react7.default.createElement(
@@ -1387,9 +1390,36 @@ var JalaliDatePicker = ({
1387
1390
  },
1388
1391
  sx: {
1389
1392
  width: "100%",
1390
- borderColor: error ? "#D32F2F" : "#C4C4C4",
1391
- "& .MuiOutlinedInput-notchedOutline": {
1392
- borderColor: error ? "#D32F2F" : "#C4C4C4"
1393
+ ...variant === "outlined" && {
1394
+ "& .MuiOutlinedInput-notchedOutline": {
1395
+ borderColor: error ? "#D32F2F" : "#C4C4C4"
1396
+ },
1397
+ "& .MuiOutlinedInput-root": {
1398
+ borderRadius: "12px",
1399
+ "&:hover fieldset": {
1400
+ borderColor: error ? "#D32F2F" : "#085938"
1401
+ },
1402
+ "&.Mui-focused fieldset": {
1403
+ borderColor: error ? "#D32F2F" : "#085938"
1404
+ }
1405
+ },
1406
+ "& .MuiInputLabel-root.Mui-focused": {
1407
+ color: "#085938"
1408
+ }
1409
+ },
1410
+ ...variant === "standard" && {
1411
+ "& .MuiInput-underline:before": {
1412
+ borderBottomColor: error ? "#D32F2F" : "rgba(0, 0, 0, 0.42)"
1413
+ },
1414
+ "& .MuiInput-underline:hover:not(.Mui-disabled):before": {
1415
+ borderBottomColor: error ? "#D32F2F" : "rgba(0, 0, 0, 0.87)"
1416
+ },
1417
+ "& .MuiInput-underline:after": {
1418
+ borderBottomColor: error ? "#D32F2F" : "#085938"
1419
+ },
1420
+ "& .MuiInputLabel-root.Mui-focused": {
1421
+ color: "#085938"
1422
+ }
1393
1423
  },
1394
1424
  "& .MuiInputBase-root": {
1395
1425
  height: size === "small" ? 40 : 56