@ultraviolet/form 6.2.0 → 6.2.2
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/_virtual/{_@oxc-project_runtime@0.114.0 → _@oxc-project_runtime@0.115.0}/helpers/asyncToGenerator.js +5 -3
- package/dist/_virtual/_@oxc-project_runtime@0.115.0/helpers/defineProperty.js +19 -0
- package/dist/_virtual/{_@oxc-project_runtime@0.114.0 → _@oxc-project_runtime@0.115.0}/helpers/objectSpread2.js +8 -4
- package/dist/_virtual/_@oxc-project_runtime@0.115.0/helpers/objectWithoutProperties.js +22 -0
- package/dist/_virtual/_@oxc-project_runtime@0.115.0/helpers/objectWithoutPropertiesLoose.js +17 -0
- package/dist/_virtual/{_@oxc-project_runtime@0.114.0 → _@oxc-project_runtime@0.115.0}/helpers/toPrimitive.js +8 -4
- package/dist/_virtual/_@oxc-project_runtime@0.115.0/helpers/toPropertyKey.js +17 -0
- package/dist/_virtual/{_@oxc-project_runtime@0.114.0 → _@oxc-project_runtime@0.115.0}/helpers/typeof.js +5 -3
- package/dist/_virtual/_rolldown/runtime.js +2 -1
- package/dist/components/CheckboxField/index.js +59 -51
- package/dist/components/CheckboxGroupField/index.js +67 -59
- package/dist/components/DateInputField/index.js +94 -84
- package/dist/components/FileInputField/index.js +64 -60
- package/dist/components/Form/defaultErrors.js +25 -21
- package/dist/components/Form/index.d.ts +2 -1
- package/dist/components/Form/index.d.ts.map +1 -1
- package/dist/components/Form/index.js +41 -31
- package/dist/components/KeyValueField/index.js +88 -86
- package/dist/components/NumberInputField/index.js +66 -57
- package/dist/components/RadioField/index.js +65 -57
- package/dist/components/RadioGroupField/index.js +50 -42
- package/dist/components/SelectInputField/index.js +56 -48
- package/dist/components/SelectableCardField/index.js +64 -58
- package/dist/components/SelectableCardGroupField/SelectableCardGroupField.js +56 -48
- package/dist/components/SelectableCardGroupField/index.js +9 -0
- package/dist/components/SelectableCardOptionGroupField/index.js +61 -53
- package/dist/components/SliderField/index.js +83 -75
- package/dist/components/Submit/index.js +22 -18
- package/dist/components/SubmitErrorAlert/index.js +15 -11
- package/dist/components/SwitchButtonField/index.js +47 -41
- package/dist/components/TagInputField/index.js +54 -45
- package/dist/components/TextAreaField/index.js +78 -72
- package/dist/components/TextInputField/index.js +67 -61
- package/dist/components/TimeInputField/index.js +50 -46
- package/dist/components/ToggleField/index.js +63 -55
- package/dist/components/ToggleGroupField/index.js +53 -45
- package/dist/components/UnitInputField/index.js +61 -53
- package/dist/components/VerificationCodeField/index.js +47 -39
- package/dist/components/compositions/CodeEditorField/index.js +48 -42
- package/dist/components/compositions/CustomerSatisfactionField/index.js +17 -13
- package/dist/components/compositions/OfferListField/index.js +54 -48
- package/dist/components/compositions/OptionSelectorField/index.js +53 -45
- package/dist/components/compositions/PlansField/index.js +25 -21
- package/dist/components/compositions/index.js +17 -5
- package/dist/components/index.js +59 -0
- package/dist/hooks/index.js +9 -0
- package/dist/hooks/useOnFieldChange.js +25 -24
- package/dist/index.js +14 -1
- package/dist/providers/ErrorContext/index.js +28 -24
- package/dist/providers/index.js +11 -0
- package/dist/utils/validateRegex.js +7 -3
- package/dist/validators/isInteger.js +11 -7
- package/dist/validators/maxDate.js +7 -3
- package/dist/validators/minDate.js +7 -3
- package/package.json +6 -6
- package/dist/_virtual/_@oxc-project_runtime@0.114.0/helpers/defineProperty.js +0 -15
- package/dist/_virtual/_@oxc-project_runtime@0.114.0/helpers/objectWithoutProperties.js +0 -18
- package/dist/_virtual/_@oxc-project_runtime@0.114.0/helpers/objectWithoutPropertiesLoose.js +0 -15
- package/dist/_virtual/_@oxc-project_runtime@0.114.0/helpers/toPropertyKey.js +0 -12
|
@@ -1,7 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { __esmMin } from "../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { CodeEditorField, init_CodeEditorField } from "./CodeEditorField/index.js";
|
|
3
|
+
import { CustomerSatisfactionField, init_CustomerSatisfactionField } from "./CustomerSatisfactionField/index.js";
|
|
4
|
+
import { OfferListField, init_OfferListField } from "./OfferListField/index.js";
|
|
5
|
+
import { OptionSelectorField, init_OptionSelectorField } from "./OptionSelectorField/index.js";
|
|
6
|
+
import { PlansField, init_PlansField } from "./PlansField/index.js";
|
|
6
7
|
|
|
8
|
+
//#region src/components/compositions/index.ts
|
|
9
|
+
var init_compositions = __esmMin(() => {
|
|
10
|
+
init_CodeEditorField();
|
|
11
|
+
init_CustomerSatisfactionField();
|
|
12
|
+
init_OfferListField();
|
|
13
|
+
init_OptionSelectorField();
|
|
14
|
+
init_PlansField();
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
//#endregion
|
|
18
|
+
init_compositions();
|
|
7
19
|
export { CodeEditorField, CustomerSatisfactionField, OfferListField, OptionSelectorField, PlansField };
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { __esmMin } from "../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { CheckboxField, init_CheckboxField } from "./CheckboxField/index.js";
|
|
3
|
+
import { CheckboxGroupField, init_CheckboxGroupField } from "./CheckboxGroupField/index.js";
|
|
4
|
+
import { DateInputField, init_DateInputField } from "./DateInputField/index.js";
|
|
5
|
+
import { FileInputField, init_FileInputField } from "./FileInputField/index.js";
|
|
6
|
+
import { Form } from "./Form/index.js";
|
|
7
|
+
import { TextInputField, init_TextInputField } from "./TextInputField/index.js";
|
|
8
|
+
import { KeyValueField, init_KeyValueField } from "./KeyValueField/index.js";
|
|
9
|
+
import { NumberInputField, init_NumberInputField } from "./NumberInputField/index.js";
|
|
10
|
+
import { RadioField, init_RadioField } from "./RadioField/index.js";
|
|
11
|
+
import { RadioGroupField, init_RadioGroupField } from "./RadioGroupField/index.js";
|
|
12
|
+
import { SelectableCardField, init_SelectableCardField } from "./SelectableCardField/index.js";
|
|
13
|
+
import { SelectableCardGroupField } from "./SelectableCardGroupField/SelectableCardGroupField.js";
|
|
14
|
+
import { init_SelectableCardGroupField } from "./SelectableCardGroupField/index.js";
|
|
15
|
+
import { SelectableCardOptionGroupField, init_SelectableCardOptionGroupField } from "./SelectableCardOptionGroupField/index.js";
|
|
16
|
+
import { SelectInputField, init_SelectInputField } from "./SelectInputField/index.js";
|
|
17
|
+
import { SliderField, init_SliderField } from "./SliderField/index.js";
|
|
18
|
+
import { Submit, init_Submit } from "./Submit/index.js";
|
|
19
|
+
import { SubmitErrorAlert, init_SubmitErrorAlert } from "./SubmitErrorAlert/index.js";
|
|
20
|
+
import { SwitchButtonField, init_SwitchButtonField } from "./SwitchButtonField/index.js";
|
|
21
|
+
import { TagInputField, init_TagInputField } from "./TagInputField/index.js";
|
|
22
|
+
import { TextAreaField, init_TextAreaField } from "./TextAreaField/index.js";
|
|
23
|
+
import { TimeInputField, init_TimeInputField } from "./TimeInputField/index.js";
|
|
24
|
+
import { ToggleField, init_ToggleField } from "./ToggleField/index.js";
|
|
25
|
+
import { ToggleGroupField, init_ToggleGroupField } from "./ToggleGroupField/index.js";
|
|
26
|
+
import { UnitInputField, init_UnitInputField } from "./UnitInputField/index.js";
|
|
27
|
+
import { VerificationCodeField, init_VerificationCodeField } from "./VerificationCodeField/index.js";
|
|
28
|
+
|
|
29
|
+
//#region src/components/index.ts
|
|
30
|
+
var init_components = __esmMin(() => {
|
|
31
|
+
init_CheckboxField();
|
|
32
|
+
init_CheckboxGroupField();
|
|
33
|
+
init_DateInputField();
|
|
34
|
+
init_FileInputField();
|
|
35
|
+
init_KeyValueField();
|
|
36
|
+
init_NumberInputField();
|
|
37
|
+
init_RadioField();
|
|
38
|
+
init_RadioGroupField();
|
|
39
|
+
init_SelectableCardField();
|
|
40
|
+
init_SelectableCardGroupField();
|
|
41
|
+
init_SelectableCardOptionGroupField();
|
|
42
|
+
init_SelectInputField();
|
|
43
|
+
init_SliderField();
|
|
44
|
+
init_Submit();
|
|
45
|
+
init_SubmitErrorAlert();
|
|
46
|
+
init_SwitchButtonField();
|
|
47
|
+
init_TagInputField();
|
|
48
|
+
init_TextAreaField();
|
|
49
|
+
init_TextInputField();
|
|
50
|
+
init_TimeInputField();
|
|
51
|
+
init_ToggleField();
|
|
52
|
+
init_ToggleGroupField();
|
|
53
|
+
init_UnitInputField();
|
|
54
|
+
init_VerificationCodeField();
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
//#endregion
|
|
58
|
+
init_components();
|
|
59
|
+
export { init_components };
|
|
@@ -1,31 +1,32 @@
|
|
|
1
|
-
import { __name } from "../_virtual/_rolldown/runtime.js";
|
|
1
|
+
import { __esmMin, __name } from "../_virtual/_rolldown/runtime.js";
|
|
2
2
|
import { useFormContext } from "react-hook-form";
|
|
3
3
|
import { useEffect, useRef } from "react";
|
|
4
4
|
|
|
5
5
|
//#region src/hooks/useOnFieldChange.ts
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
};
|
|
6
|
+
var useOnFieldChange;
|
|
7
|
+
var init_useOnFieldChange = __esmMin(() => {
|
|
8
|
+
useOnFieldChange = (fieldName, callback, enabled = true) => {
|
|
9
|
+
const { watch, getValues } = useFormContext();
|
|
10
|
+
const previousValues = useRef(getValues(fieldName));
|
|
11
|
+
useEffect(() => {
|
|
12
|
+
const subscription = watch((value) => {
|
|
13
|
+
if (previousValues.current !== value[fieldName] && enabled) {
|
|
14
|
+
var _callback;
|
|
15
|
+
previousValues.current = value[fieldName];
|
|
16
|
+
(_callback = callback(value[fieldName], value)) === null || _callback === void 0 || _callback.catch(() => null);
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
return () => subscription.unsubscribe();
|
|
20
|
+
}, [
|
|
21
|
+
callback,
|
|
22
|
+
enabled,
|
|
23
|
+
watch,
|
|
24
|
+
getValues,
|
|
25
|
+
fieldName
|
|
26
|
+
]);
|
|
27
|
+
};
|
|
28
|
+
});
|
|
29
29
|
|
|
30
30
|
//#endregion
|
|
31
|
+
init_useOnFieldChange();
|
|
31
32
|
export { useOnFieldChange };
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __esmMin } from "./_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { ErrorProvider, init_ErrorContext, useErrors } from "./providers/ErrorContext/index.js";
|
|
2
3
|
import { CheckboxField } from "./components/CheckboxField/index.js";
|
|
3
4
|
import { CheckboxGroupField } from "./components/CheckboxGroupField/index.js";
|
|
4
5
|
import { DateInputField } from "./components/DateInputField/index.js";
|
|
@@ -24,7 +25,19 @@ import { ToggleField } from "./components/ToggleField/index.js";
|
|
|
24
25
|
import { ToggleGroupField } from "./components/ToggleGroupField/index.js";
|
|
25
26
|
import { UnitInputField } from "./components/UnitInputField/index.js";
|
|
26
27
|
import { VerificationCodeField } from "./components/VerificationCodeField/index.js";
|
|
28
|
+
import { init_components } from "./components/index.js";
|
|
27
29
|
import { useOnFieldChange } from "./hooks/useOnFieldChange.js";
|
|
30
|
+
import { init_hooks } from "./hooks/index.js";
|
|
28
31
|
import { useController, useFieldArray, useForm, useFormContext, useFormState, useWatch } from "react-hook-form";
|
|
29
32
|
|
|
33
|
+
//#region src/index.ts
|
|
34
|
+
var init_src = __esmMin(() => {
|
|
35
|
+
init_components();
|
|
36
|
+
init_components();
|
|
37
|
+
init_hooks();
|
|
38
|
+
init_ErrorContext();
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
//#endregion
|
|
42
|
+
init_src();
|
|
30
43
|
export { CheckboxField, CheckboxGroupField, DateInputField, ErrorProvider, FileInputField, Form, KeyValueField, NumberInputField, RadioField, RadioGroupField, SelectInputField, SelectableCardField, SelectableCardGroupField, SelectableCardOptionGroupField, SliderField, Submit, SubmitErrorAlert, SwitchButtonField, TagInputField, TextAreaField, TextInputField, TimeInputField, ToggleField, ToggleGroupField, UnitInputField, VerificationCodeField, useController, useErrors, useFieldArray, useForm, useFormContext, useFormState, useOnFieldChange, useWatch };
|
|
@@ -1,31 +1,35 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { __name } from "../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { __esmMin, __name } from "../../_virtual/_rolldown/runtime.js";
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import { createContext, useCallback, useContext, useMemo } from "react";
|
|
5
5
|
|
|
6
6
|
//#region src/providers/ErrorContext/index.tsx
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
errors
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
7
|
+
var ErrorContext, ErrorProvider, useErrors;
|
|
8
|
+
var init_ErrorContext = __esmMin(() => {
|
|
9
|
+
ErrorContext = createContext(void 0);
|
|
10
|
+
ErrorProvider = ({ children, errors }) => {
|
|
11
|
+
const getError = useCallback((meta, error) => {
|
|
12
|
+
var _errors$error$type;
|
|
13
|
+
if (!error) return;
|
|
14
|
+
if (error.message) return error.message;
|
|
15
|
+
return errors === null || errors === void 0 || (_errors$error$type = errors[error.type]) === null || _errors$error$type === void 0 ? void 0 : _errors$error$type.call(errors, meta);
|
|
16
|
+
}, [errors]);
|
|
17
|
+
const value = useMemo(() => ({
|
|
18
|
+
errors,
|
|
19
|
+
getError
|
|
20
|
+
}), [errors, getError]);
|
|
21
|
+
return /* @__PURE__ */ jsx(ErrorContext.Provider, {
|
|
22
|
+
value,
|
|
23
|
+
children
|
|
24
|
+
});
|
|
25
|
+
};
|
|
26
|
+
useErrors = () => {
|
|
27
|
+
const context = useContext(ErrorContext);
|
|
28
|
+
if (context === void 0) throw new Error("useErrors must be used within an ErrorProvider ");
|
|
29
|
+
return context;
|
|
30
|
+
};
|
|
31
|
+
});
|
|
29
32
|
|
|
30
33
|
//#endregion
|
|
31
|
-
|
|
34
|
+
init_ErrorContext();
|
|
35
|
+
export { ErrorProvider, init_ErrorContext, useErrors };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { __esmMin } from "../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { ErrorProvider, init_ErrorContext, useErrors } from "./ErrorContext/index.js";
|
|
3
|
+
|
|
4
|
+
//#region src/providers/index.ts
|
|
5
|
+
var init_providers = __esmMin(() => {
|
|
6
|
+
init_ErrorContext();
|
|
7
|
+
});
|
|
8
|
+
|
|
9
|
+
//#endregion
|
|
10
|
+
init_providers();
|
|
11
|
+
export { init_providers };
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { __name } from "../_virtual/_rolldown/runtime.js";
|
|
1
|
+
import { __esmMin, __name } from "../_virtual/_rolldown/runtime.js";
|
|
2
2
|
|
|
3
3
|
//#region src/utils/validateRegex.ts
|
|
4
|
-
|
|
4
|
+
var validateRegex;
|
|
5
|
+
var init_validateRegex = __esmMin(() => {
|
|
6
|
+
validateRegex = (value, regexes) => regexes.every((regex) => value === void 0 || value === "" || (Array.isArray(regex) ? regex.some((regexOr) => regexOr.test(value)) : regex.test(value)));
|
|
7
|
+
});
|
|
5
8
|
|
|
6
9
|
//#endregion
|
|
7
|
-
|
|
10
|
+
init_validateRegex();
|
|
11
|
+
export { init_validateRegex, validateRegex };
|
|
@@ -1,11 +1,15 @@
|
|
|
1
|
-
import { __name } from "../_virtual/_rolldown/runtime.js";
|
|
1
|
+
import { __esmMin, __name } from "../_virtual/_rolldown/runtime.js";
|
|
2
2
|
|
|
3
3
|
//#region src/validators/isInteger.ts
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
var isInteger;
|
|
5
|
+
var init_isInteger = __esmMin(() => {
|
|
6
|
+
isInteger = (step) => (value) => {
|
|
7
|
+
if (value === void 0 || step === void 0) return true;
|
|
8
|
+
if (Number.isInteger(step)) return Number.isInteger(value) && Number.isInteger(value);
|
|
9
|
+
return !(Number.isInteger(value) || Number.isInteger(value));
|
|
10
|
+
};
|
|
11
|
+
});
|
|
9
12
|
|
|
10
13
|
//#endregion
|
|
11
|
-
|
|
14
|
+
init_isInteger();
|
|
15
|
+
export { init_isInteger, isInteger };
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { __name } from "../_virtual/_rolldown/runtime.js";
|
|
1
|
+
import { __esmMin, __name } from "../_virtual/_rolldown/runtime.js";
|
|
2
2
|
|
|
3
3
|
//#region src/validators/maxDate.ts
|
|
4
|
-
|
|
4
|
+
var maxDateValidator;
|
|
5
|
+
var init_maxDate = __esmMin(() => {
|
|
6
|
+
maxDateValidator = (maxDate) => (value) => value === void 0 || maxDate === void 0 || (Array.isArray(value) ? value[1] <= maxDate : value <= maxDate);
|
|
7
|
+
});
|
|
5
8
|
|
|
6
9
|
//#endregion
|
|
7
|
-
|
|
10
|
+
init_maxDate();
|
|
11
|
+
export { init_maxDate, maxDateValidator };
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { __name } from "../_virtual/_rolldown/runtime.js";
|
|
1
|
+
import { __esmMin, __name } from "../_virtual/_rolldown/runtime.js";
|
|
2
2
|
|
|
3
3
|
//#region src/validators/minDate.ts
|
|
4
|
-
|
|
4
|
+
var minDateValidator;
|
|
5
|
+
var init_minDate = __esmMin(() => {
|
|
6
|
+
minDateValidator = (maxDate) => (value) => value === void 0 || maxDate === void 0 || (Array.isArray(value) ? value[0] >= maxDate : value >= maxDate);
|
|
7
|
+
});
|
|
5
8
|
|
|
6
9
|
//#endregion
|
|
7
|
-
|
|
10
|
+
init_minDate();
|
|
11
|
+
export { init_minDate, minDateValidator };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ultraviolet/form",
|
|
3
|
-
"version": "6.2.
|
|
3
|
+
"version": "6.2.2",
|
|
4
4
|
"description": "Ultraviolet Form",
|
|
5
5
|
"homepage": "https://github.com/scaleway/ultraviolet#readme",
|
|
6
6
|
"repository": {
|
|
@@ -66,16 +66,16 @@
|
|
|
66
66
|
"@types/react-dom": "19.2.3",
|
|
67
67
|
"react": "19.2.4",
|
|
68
68
|
"react-dom": "19.2.4",
|
|
69
|
-
"vite": "8.0.0-beta.
|
|
70
|
-
"@repo/config": "0.0.
|
|
69
|
+
"vite": "8.0.0-beta.18",
|
|
70
|
+
"@repo/config": "0.0.3",
|
|
71
71
|
"@utils/test": "0.0.1"
|
|
72
72
|
},
|
|
73
73
|
"dependencies": {
|
|
74
74
|
"@babel/runtime": "7.28.6",
|
|
75
75
|
"react-hook-form": "7.71.2",
|
|
76
|
-
"@ultraviolet/icons": "5.1.
|
|
77
|
-
"@ultraviolet/themes": "3.1.
|
|
78
|
-
"@ultraviolet/ui": "3.
|
|
76
|
+
"@ultraviolet/icons": "5.1.6",
|
|
77
|
+
"@ultraviolet/themes": "3.1.2",
|
|
78
|
+
"@ultraviolet/ui": "3.12.0"
|
|
79
79
|
},
|
|
80
80
|
"scripts": {
|
|
81
81
|
"build:profile": "npx vite-bundle-visualizer -c vite.config.ts",
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { __name } from "../../_rolldown/runtime.js";
|
|
2
|
-
import { toPropertyKey } from "./toPropertyKey.js";
|
|
3
|
-
|
|
4
|
-
//#region \0@oxc-project+runtime@0.114.0/helpers/defineProperty.js
|
|
5
|
-
function _defineProperty(e, r, t) {
|
|
6
|
-
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
7
|
-
value: t,
|
|
8
|
-
enumerable: !0,
|
|
9
|
-
configurable: !0,
|
|
10
|
-
writable: !0
|
|
11
|
-
}) : e[r] = t, e;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
//#endregion
|
|
15
|
-
export { _defineProperty };
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { __name } from "../../_rolldown/runtime.js";
|
|
2
|
-
import { _objectWithoutPropertiesLoose } from "./objectWithoutPropertiesLoose.js";
|
|
3
|
-
|
|
4
|
-
//#region \0@oxc-project+runtime@0.114.0/helpers/objectWithoutProperties.js
|
|
5
|
-
function _objectWithoutProperties(e, t) {
|
|
6
|
-
if (null == e) return {};
|
|
7
|
-
var o;
|
|
8
|
-
var r;
|
|
9
|
-
var i = _objectWithoutPropertiesLoose(e, t);
|
|
10
|
-
if (Object.getOwnPropertySymbols) {
|
|
11
|
-
var s = Object.getOwnPropertySymbols(e);
|
|
12
|
-
for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
|
|
13
|
-
}
|
|
14
|
-
return i;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
//#endregion
|
|
18
|
-
export { _objectWithoutProperties };
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { __name } from "../../_rolldown/runtime.js";
|
|
2
|
-
|
|
3
|
-
//#region \0@oxc-project+runtime@0.114.0/helpers/objectWithoutPropertiesLoose.js
|
|
4
|
-
function _objectWithoutPropertiesLoose(r, e) {
|
|
5
|
-
if (null == r) return {};
|
|
6
|
-
var t = {};
|
|
7
|
-
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
8
|
-
if (e.includes(n)) continue;
|
|
9
|
-
t[n] = r[n];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
//#endregion
|
|
15
|
-
export { _objectWithoutPropertiesLoose };
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { __name } from "../../_rolldown/runtime.js";
|
|
2
|
-
import { _typeof } from "./typeof.js";
|
|
3
|
-
import { toPrimitive } from "./toPrimitive.js";
|
|
4
|
-
|
|
5
|
-
//#region \0@oxc-project+runtime@0.114.0/helpers/toPropertyKey.js
|
|
6
|
-
function toPropertyKey(t) {
|
|
7
|
-
var i = toPrimitive(t, "string");
|
|
8
|
-
return "symbol" == _typeof(i) ? i : i + "";
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
//#endregion
|
|
12
|
-
export { toPropertyKey };
|