@ahmadmubarak98/namozaj 1.8.3 → 1.8.4
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/main.d.ts +10 -1
- package/dist/namozaj.js +49 -31
- package/package.json +1 -1
package/dist/main.d.ts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
|
+
import { ButtonPropsSizeOverrides } from '@mui/material';
|
|
2
|
+
import { ButtonPropsVariantOverrides } from '@mui/material';
|
|
1
3
|
import { CountryIso2 } from 'react-international-phone';
|
|
2
4
|
import { default as default_2 } from 'react';
|
|
3
5
|
import { FieldValues } from 'react-hook-form';
|
|
6
|
+
import { OverridableStringUnion } from '@mui/types';
|
|
4
7
|
import { ParsedCountry } from 'react-international-phone';
|
|
5
8
|
import { PickersTimezone } from '@mui/x-date-pickers';
|
|
6
9
|
import { SxProps } from '@mui/material';
|
|
@@ -24,6 +27,7 @@ export declare type BaseFieldConfig = {
|
|
|
24
27
|
translated?: boolean;
|
|
25
28
|
helperText?: HelperTextConfig;
|
|
26
29
|
validations?: ValidationRule[];
|
|
30
|
+
renderLabelRightSide?: (formMethods: RHFFormMethods) => React.ReactNode;
|
|
27
31
|
grid?: GridColumnConfig;
|
|
28
32
|
fullRow?: boolean;
|
|
29
33
|
className?: string;
|
|
@@ -474,11 +478,15 @@ export declare type SliderFieldConfig = BaseFieldConfig & {
|
|
|
474
478
|
|
|
475
479
|
export declare interface SubmitButtonProps {
|
|
476
480
|
label?: string;
|
|
477
|
-
size?:
|
|
481
|
+
size?: OverridableStringUnion<'small' | 'medium' | 'large', ButtonPropsSizeOverrides>;
|
|
478
482
|
className?: string;
|
|
483
|
+
sx?: SxProps<Theme>;
|
|
484
|
+
color?: BaseColors;
|
|
485
|
+
variant?: OverridableStringUnion<'text' | 'outlined' | 'contained', ButtonPropsVariantOverrides>;
|
|
479
486
|
buttonType?: "button" | "submit" | "reset";
|
|
480
487
|
disabled?: boolean;
|
|
481
488
|
hidden?: boolean;
|
|
489
|
+
fullWidth?: boolean;
|
|
482
490
|
}
|
|
483
491
|
|
|
484
492
|
export declare type SwitchFieldConfig = BaseFieldConfig & {
|
|
@@ -495,6 +503,7 @@ export declare type TextFieldConfig = BaseFieldConfig & {
|
|
|
495
503
|
size?: FieldSize;
|
|
496
504
|
maxLength?: number;
|
|
497
505
|
minLength?: number;
|
|
506
|
+
showCharCount?: boolean;
|
|
498
507
|
secured?: boolean;
|
|
499
508
|
multiline?: boolean;
|
|
500
509
|
rows?: number;
|
package/dist/namozaj.js
CHANGED
|
@@ -10674,7 +10674,7 @@ const VisibilityIcon = createSvgIcon(/* @__PURE__ */ jsx("path", {
|
|
|
10674
10674
|
fullWidth: !0
|
|
10675
10675
|
}
|
|
10676
10676
|
),
|
|
10677
|
-
l.maxLength && l.maxLength > 0 && /* @__PURE__ */ jsxs(
|
|
10677
|
+
l.showCharCount && l.maxLength && l.maxLength > 0 && /* @__PURE__ */ jsxs(
|
|
10678
10678
|
InputLabel$1,
|
|
10679
10679
|
{
|
|
10680
10680
|
variant: "standard",
|
|
@@ -51208,30 +51208,43 @@ const FileField = ({
|
|
|
51208
51208
|
]
|
|
51209
51209
|
}
|
|
51210
51210
|
), FieldLabel = ({ field: e, htmlFor: t }) => {
|
|
51211
|
-
const a = e.meta.tooltip,
|
|
51212
|
-
return /* @__PURE__ */ jsxs(
|
|
51213
|
-
|
|
51214
|
-
|
|
51215
|
-
|
|
51216
|
-
|
|
51217
|
-
|
|
51218
|
-
|
|
51219
|
-
|
|
51220
|
-
|
|
51221
|
-
|
|
51222
|
-
|
|
51223
|
-
|
|
51224
|
-
|
|
51225
|
-
|
|
51226
|
-
|
|
51227
|
-
|
|
51228
|
-
|
|
51229
|
-
|
|
51230
|
-
|
|
51231
|
-
|
|
51232
|
-
|
|
51233
|
-
|
|
51234
|
-
|
|
51211
|
+
const a = useFormContext(), l = e.meta.tooltip, c = useMemo(() => isFieldRequired(e), [e]);
|
|
51212
|
+
return /* @__PURE__ */ jsxs(
|
|
51213
|
+
Stack,
|
|
51214
|
+
{
|
|
51215
|
+
direction: "row",
|
|
51216
|
+
justifyContent: "space-between",
|
|
51217
|
+
alignItems: "center",
|
|
51218
|
+
spacing: 0.5,
|
|
51219
|
+
flexWrap: "wrap",
|
|
51220
|
+
children: [
|
|
51221
|
+
/* @__PURE__ */ jsxs(Stack, { direction: "row", alignItems: "center", spacing: 0.5, children: [
|
|
51222
|
+
/* @__PURE__ */ jsxs(
|
|
51223
|
+
Typography$1,
|
|
51224
|
+
{
|
|
51225
|
+
variant: "body1",
|
|
51226
|
+
sx: {
|
|
51227
|
+
fontWeight: 500,
|
|
51228
|
+
fontSize: "0.875rem",
|
|
51229
|
+
lineHeight: 1.5,
|
|
51230
|
+
color: "#000"
|
|
51231
|
+
},
|
|
51232
|
+
component: "label",
|
|
51233
|
+
htmlFor: t,
|
|
51234
|
+
"aria-required": c,
|
|
51235
|
+
children: [
|
|
51236
|
+
e.meta.label,
|
|
51237
|
+
" ",
|
|
51238
|
+
c && /* @__PURE__ */ jsx("span", { style: { color: "red" }, children: "*" })
|
|
51239
|
+
]
|
|
51240
|
+
}
|
|
51241
|
+
),
|
|
51242
|
+
(l == null ? void 0 : l.text) && /* @__PURE__ */ jsx(Tooltip, { ...l })
|
|
51243
|
+
] }),
|
|
51244
|
+
e.meta.renderLabelRightSide ? e.meta.renderLabelRightSide(a) : null
|
|
51245
|
+
]
|
|
51246
|
+
}
|
|
51247
|
+
);
|
|
51235
51248
|
};
|
|
51236
51249
|
var LocalEventService = class {
|
|
51237
51250
|
constructor() {
|
|
@@ -87576,17 +87589,22 @@ const Form = React__default.forwardRef(
|
|
|
87576
87589
|
},
|
|
87577
87590
|
[h]
|
|
87578
87591
|
), S = () => {
|
|
87579
|
-
var K, ce, we, Re, ve;
|
|
87592
|
+
var K, ce, we, Re, ve, ye, We, je, Xe, Ue, Ge;
|
|
87580
87593
|
return /* @__PURE__ */ jsx(Fragment, { children: !((K = e.submitButtonProps) != null && K.hidden) && /* @__PURE__ */ jsx(
|
|
87581
87594
|
Button$1,
|
|
87582
87595
|
{
|
|
87583
87596
|
loading: e.loading,
|
|
87584
87597
|
loadingPosition: "start",
|
|
87585
|
-
variant: "contained",
|
|
87586
|
-
color: "primary",
|
|
87587
|
-
type: "submit",
|
|
87588
|
-
|
|
87589
|
-
|
|
87598
|
+
variant: ((ce = e.submitButtonProps) == null ? void 0 : ce.variant) || "contained",
|
|
87599
|
+
color: ((we = e.submitButtonProps) == null ? void 0 : we.color) || "primary",
|
|
87600
|
+
type: ((Re = e.submitButtonProps) == null ? void 0 : Re.buttonType) || "submit",
|
|
87601
|
+
size: ((ve = e.submitButtonProps) == null ? void 0 : ve.size) || "medium",
|
|
87602
|
+
disabled: typeof ((ye = e.submitButtonProps) == null ? void 0 : ye.disabled) == "boolean" ? (We = e.submitButtonProps) == null ? void 0 : We.disabled : (je = e.stepper) != null && je.advanceOnValidation ? l : v,
|
|
87603
|
+
sx: {
|
|
87604
|
+
...((Xe = e.submitButtonProps) == null ? void 0 : Xe.sx) || {}
|
|
87605
|
+
},
|
|
87606
|
+
fullWidth: (Ue = e.submitButtonProps) == null ? void 0 : Ue.fullWidth,
|
|
87607
|
+
children: ((Ge = e.submitButtonProps) == null ? void 0 : Ge.label) || "Submit"
|
|
87590
87608
|
}
|
|
87591
87609
|
) });
|
|
87592
87610
|
}, x = () => /* @__PURE__ */ jsx(Fragment, {});
|