@wfrog/vc-ui 1.11.9 → 1.11.11

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.
Files changed (135) hide show
  1. package/dist/es/chunk/Bw0Rhd-r.mjs +110 -0
  2. package/dist/es/chunk/CqTdDZkE.mjs +31 -0
  3. package/dist/es/chunk/{DAnWZLYj.mjs → CzWfBa_8.mjs} +96 -2
  4. package/dist/es/chunk/D229kQ56.mjs +28 -0
  5. package/dist/es/chunk/{Cxx_YWUC.mjs → DcouM6gM.mjs} +6 -548
  6. package/dist/es/chunk/Fo0dZYnz.mjs +128 -0
  7. package/dist/es/chunk/KanuIcmc.mjs +412 -0
  8. package/dist/es/chunk/{B71xEPfK.mjs → uuUHUjSk.mjs} +4 -35
  9. package/dist/es/components/backbottom/backbottom.mjs +3 -2
  10. package/dist/es/components/button/button.mjs +4 -5
  11. package/dist/es/components/choice/choice.mjs +4 -4
  12. package/dist/es/components/choice/index.css +1 -1
  13. package/dist/es/components/color-switch/color-switch.mjs +73 -1046
  14. package/dist/es/components/color-switch/index.css +1 -1
  15. package/dist/es/components/cropper/cropper.mjs +11 -117
  16. package/dist/es/components/cropper/index.css +1 -1
  17. package/dist/es/components/currency/currency.mjs +4 -5
  18. package/dist/es/components/daterange-picker/daterange-picker.mjs +8 -6253
  19. package/dist/es/components/dialog/dialog.mjs +7 -400
  20. package/dist/es/components/dialog/index.css +1 -1
  21. package/dist/es/components/dialog-camera-upload/dialog-camera-upload.mjs +10 -11
  22. package/dist/es/components/dialog-map-point/dialog-map-point.mjs +4 -3
  23. package/dist/es/components/dialog-upload-images/dialog-upload-images.mjs +9 -1374
  24. package/dist/es/components/dialog-upload-images/index.css +1 -1
  25. package/dist/es/components/drag-verify/drag-verify.mjs +3 -2
  26. package/dist/es/components/drawer/drawer.mjs +10 -352
  27. package/dist/es/components/drawer/index.css +1 -1
  28. package/dist/es/components/easy-pagination/easy-pagination.mjs +3 -2
  29. package/dist/es/components/explorer/explorer.mjs +3 -3
  30. package/dist/es/components/explorer-column-table/explorer-column-table.mjs +5 -7
  31. package/dist/es/components/explorer-column-table/index.css +1 -1
  32. package/dist/es/components/explorer-container/explorer-container.d.ts +1 -1
  33. package/dist/es/components/explorer-container/explorer-container.mjs +4 -3
  34. package/dist/es/components/explorer-filter/explorer-filter.mjs +5 -4
  35. package/dist/es/components/explorer-footer/explorer-footer.mjs +4 -8
  36. package/dist/es/components/explorer-form/explorer-form.mjs +4 -3
  37. package/dist/es/components/explorer-list/explorer-list.mjs +5 -4
  38. package/dist/es/components/explorer-modal-form/explorer-modal-form.mjs +4 -3
  39. package/dist/es/components/explorer-panel/explorer-panel.mjs +3 -3
  40. package/dist/es/components/explorer-query/explorer-query.mjs +9 -2201
  41. package/dist/es/components/explorer-query/index.css +1 -1
  42. package/dist/es/components/explorer-table/explorer-table.mjs +20 -24
  43. package/dist/es/components/explorer-table/index.css +16 -9
  44. package/dist/es/components/explorer-tools/explorer-tools.mjs +13 -264
  45. package/dist/es/components/explorer-tools/index.css +1 -1
  46. package/dist/es/components/explorer-tree/explorer-tree.mjs +4 -5
  47. package/dist/es/components/icon-picker/icon-picker.mjs +8 -12
  48. package/dist/es/components/image/image.mjs +4 -4
  49. package/dist/es/components/info-tooltip/info-tooltip.mjs +336 -4
  50. package/dist/es/components/input/input.mjs +3 -2
  51. package/dist/es/components/input-number/input-number.mjs +3 -3
  52. package/dist/es/components/pca-picker/index.css +1 -1
  53. package/dist/es/components/pca-picker/pca-picker.mjs +443 -601
  54. package/dist/es/components/screenfull/screenfull.mjs +4 -3
  55. package/dist/es/components/scrollbar/scrollbar.mjs +3 -2
  56. package/dist/es/components/select/select.mjs +3 -5
  57. package/dist/es/components/single-player/index.css +1 -1
  58. package/dist/es/components/single-player/single-player.mjs +10 -1087
  59. package/dist/es/components/splitter/splitter.mjs +3 -3
  60. package/dist/es/components/splitter-panel/splitter-panel.mjs +3 -3
  61. package/dist/es/components/switch/index.css +1 -1
  62. package/dist/es/components/switch/switch.mjs +9 -395
  63. package/dist/es/components/tags/tags.mjs +7 -9
  64. package/dist/es/components/text-ellipsis/text-ellipsis.mjs +3 -3
  65. package/dist/es/components/thousand-input/thousand-input.mjs +33 -1
  66. package/dist/es/components/tinymce/tinymce.mjs +4 -3
  67. package/dist/es/components/transfer/transfer.mjs +3 -4
  68. package/dist/es/components/transfer-panel/transfer-panel.mjs +5 -4
  69. package/dist/es/components/tree-picker/popover-cascader.css +1 -1
  70. package/dist/es/components/tree-picker/tree-picker.mjs +5 -10
  71. package/dist/es/index.mjs +1 -1
  72. package/dist/index.css +29 -49
  73. package/package.json +1 -1
  74. package/dist/es/chunk/B-rxnVJv.mjs +0 -3
  75. package/dist/es/chunk/B5HpgPRt.mjs +0 -69
  76. package/dist/es/chunk/BBhZKpIc.mjs +0 -2179
  77. package/dist/es/chunk/BDcsaNYa.mjs +0 -59
  78. package/dist/es/chunk/BTSSEFfD.mjs +0 -319
  79. package/dist/es/chunk/BTpNRPQW.mjs +0 -55
  80. package/dist/es/chunk/BVBK1U57.mjs +0 -96
  81. package/dist/es/chunk/Bc6yUGLs.mjs +0 -45
  82. package/dist/es/chunk/BjVI1XMz.mjs +0 -40
  83. package/dist/es/chunk/BlzQCBDu.mjs +0 -5741
  84. package/dist/es/chunk/BpJKnxlF.mjs +0 -476
  85. package/dist/es/chunk/Brp-qSBw.mjs +0 -2003
  86. package/dist/es/chunk/BunQI8Jb.mjs +0 -390
  87. package/dist/es/chunk/C0XgBrDz.mjs +0 -775
  88. package/dist/es/chunk/C0pTANRX.mjs +0 -109
  89. package/dist/es/chunk/CBMjhoFP.mjs +0 -101
  90. package/dist/es/chunk/CBiNtNvQ.mjs +0 -242
  91. package/dist/es/chunk/CBlJeNBO.mjs +0 -890
  92. package/dist/es/chunk/CCVL_Zj-.mjs +0 -427
  93. package/dist/es/chunk/CEl4MyfJ.mjs +0 -252
  94. package/dist/es/chunk/CJK5_jsA.mjs +0 -53
  95. package/dist/es/chunk/CKOcwq5V.mjs +0 -44
  96. package/dist/es/chunk/COs9dJZa.mjs +0 -66
  97. package/dist/es/chunk/CPt6MxJW.mjs +0 -375
  98. package/dist/es/chunk/CVqW0jzp.mjs +0 -107
  99. package/dist/es/chunk/CccIsEqA.mjs +0 -128
  100. package/dist/es/chunk/CjLR27-a.mjs +0 -582
  101. package/dist/es/chunk/CoGexPPD.mjs +0 -2192
  102. package/dist/es/chunk/CsLIbnzG.mjs +0 -64
  103. package/dist/es/chunk/Ct6q2FXg.mjs +0 -5
  104. package/dist/es/chunk/Cuq5meQh.mjs +0 -184
  105. package/dist/es/chunk/CvYIOfT1.mjs +0 -23
  106. package/dist/es/chunk/CxHJBf4l.mjs +0 -31
  107. package/dist/es/chunk/CzdaOBtA.mjs +0 -66
  108. package/dist/es/chunk/D0QTifnI.mjs +0 -54
  109. package/dist/es/chunk/D1QnA2iT.mjs +0 -229
  110. package/dist/es/chunk/D3AvJlVX.mjs +0 -188
  111. package/dist/es/chunk/D9Lr0Bzb.mjs +0 -1136
  112. package/dist/es/chunk/DCkPv0hy.mjs +0 -29
  113. package/dist/es/chunk/DRwwUUhy.mjs +0 -49
  114. package/dist/es/chunk/DX-2VRY2.mjs +0 -836
  115. package/dist/es/chunk/DZ2oTFad.mjs +0 -687
  116. package/dist/es/chunk/D_bou1py.mjs +0 -55
  117. package/dist/es/chunk/Da199A5L.mjs +0 -314
  118. package/dist/es/chunk/DbhQlaOz.mjs +0 -94
  119. package/dist/es/chunk/Dgu95mOy.mjs +0 -237
  120. package/dist/es/chunk/DhGOsWxx.mjs +0 -6
  121. package/dist/es/chunk/Dm_Sj5aH.mjs +0 -487
  122. package/dist/es/chunk/Dmi-1GRO.mjs +0 -163
  123. package/dist/es/chunk/DodoD9a9.mjs +0 -52
  124. package/dist/es/chunk/DrrVDcwm.mjs +0 -955
  125. package/dist/es/chunk/Du_zJ1Fz.mjs +0 -49
  126. package/dist/es/chunk/DxxbB5jY.mjs +0 -34
  127. package/dist/es/chunk/Gk1J52Yw.mjs +0 -207
  128. package/dist/es/chunk/NsldgdCh.mjs +0 -704
  129. package/dist/es/chunk/V6KjsUQN.mjs +0 -35
  130. package/dist/es/chunk/eEsLFV3s.mjs +0 -76
  131. package/dist/es/chunk/fqiLhk0V.mjs +0 -2065
  132. package/dist/es/chunk/nxVM7re4.mjs +0 -35
  133. package/dist/es/chunk/s7HLrANj.mjs +0 -215
  134. package/dist/es/chunk/vPhxogl3.mjs +0 -19
  135. package/dist/es/components/icon/icon2.mjs +0 -27
@@ -1,109 +0,0 @@
1
- import { getCurrentInstance, inject, ref, computed, unref, provide } from 'vue';
2
- import { u as useNamespace, p as defaultNamespace, a as debugWarn, r as namespaceContextKey } from './Gk1J52Yw.mjs';
3
- import { u as useZIndex, d as defaultInitialZIndex, z as zIndexContextKey } from './BjVI1XMz.mjs';
4
- import { u as useLocale, l as localeContextKey } from './CEl4MyfJ.mjs';
5
- import { S as SIZE_INJECTION_KEY } from './vPhxogl3.mjs';
6
- import { e as emptyValuesContextKey } from './COs9dJZa.mjs';
7
- import { k as keysOf } from './Du_zJ1Fz.mjs';
8
-
9
- const configProviderContextKey = Symbol();
10
-
11
- const globalConfig = ref();
12
- function useGlobalConfig(key, defaultValue = void 0) {
13
- const config = getCurrentInstance() ? inject(configProviderContextKey, globalConfig) : globalConfig;
14
- if (key) {
15
- return computed(() => {
16
- var _a, _b;
17
- return (_b = (_a = config.value) == null ? void 0 : _a[key]) != null ? _b : defaultValue;
18
- });
19
- } else {
20
- return config;
21
- }
22
- }
23
- function useGlobalComponentSettings(block, sizeFallback) {
24
- const config = useGlobalConfig();
25
- const ns = useNamespace(
26
- block,
27
- computed(() => {
28
- var _a;
29
- return ((_a = config.value) == null ? void 0 : _a.namespace) || defaultNamespace;
30
- })
31
- );
32
- const locale = useLocale(computed(() => {
33
- var _a;
34
- return (_a = config.value) == null ? void 0 : _a.locale;
35
- }));
36
- const zIndex = useZIndex(
37
- computed(() => {
38
- var _a;
39
- return ((_a = config.value) == null ? void 0 : _a.zIndex) || defaultInitialZIndex;
40
- })
41
- );
42
- const size = computed(() => {
43
- var _a;
44
- return unref(sizeFallback) || ((_a = config.value) == null ? void 0 : _a.size) || "";
45
- });
46
- provideGlobalConfig(computed(() => unref(config) || {}));
47
- return {
48
- ns,
49
- locale,
50
- zIndex,
51
- size
52
- };
53
- }
54
- const provideGlobalConfig = (config, app, global = false) => {
55
- var _a;
56
- const inSetup = !!getCurrentInstance();
57
- const oldConfig = inSetup ? useGlobalConfig() : void 0;
58
- const provideFn = (_a = void 0 ) != null ? _a : inSetup ? provide : void 0;
59
- if (!provideFn) {
60
- debugWarn(
61
- "provideGlobalConfig",
62
- "provideGlobalConfig() can only be used inside setup()."
63
- );
64
- return;
65
- }
66
- const context = computed(() => {
67
- const cfg = unref(config);
68
- if (!(oldConfig == null ? void 0 : oldConfig.value))
69
- return cfg;
70
- return mergeConfig(oldConfig.value, cfg);
71
- });
72
- provideFn(configProviderContextKey, context);
73
- provideFn(
74
- localeContextKey,
75
- computed(() => context.value.locale)
76
- );
77
- provideFn(
78
- namespaceContextKey,
79
- computed(() => context.value.namespace)
80
- );
81
- provideFn(
82
- zIndexContextKey,
83
- computed(() => context.value.zIndex)
84
- );
85
- provideFn(SIZE_INJECTION_KEY, {
86
- size: computed(() => context.value.size || "")
87
- });
88
- provideFn(
89
- emptyValuesContextKey,
90
- computed(() => ({
91
- emptyValues: context.value.emptyValues,
92
- valueOnClear: context.value.valueOnClear
93
- }))
94
- );
95
- if (global || !globalConfig.value) {
96
- globalConfig.value = context.value;
97
- }
98
- return context;
99
- };
100
- const mergeConfig = (a, b) => {
101
- const keys = [.../* @__PURE__ */ new Set([...keysOf(a), ...keysOf(b)])];
102
- const obj = {};
103
- for (const key of keys) {
104
- obj[key] = b[key] !== void 0 ? b[key] : a[key];
105
- }
106
- return obj;
107
- };
108
-
109
- export { useGlobalComponentSettings as a, useGlobalConfig as u };
@@ -1,101 +0,0 @@
1
- import { inject, ref, getCurrentInstance, computed, onMounted, watch, toRef, onUnmounted, unref } from 'vue';
2
- import { f as formContextKey, a as formItemContextKey, u as useId } from './nxVM7re4.mjs';
3
- import { a as useGlobalSize } from './vPhxogl3.mjs';
4
-
5
- const useFormItem = () => {
6
- const form = inject(formContextKey, void 0);
7
- const formItem = inject(formItemContextKey, void 0);
8
- return {
9
- form,
10
- formItem
11
- };
12
- };
13
- const useFormItemInputId = (props, {
14
- formItemContext,
15
- disableIdGeneration,
16
- disableIdManagement
17
- }) => {
18
- if (!disableIdGeneration) {
19
- disableIdGeneration = ref(false);
20
- }
21
- if (!disableIdManagement) {
22
- disableIdManagement = ref(false);
23
- }
24
- const instance = getCurrentInstance();
25
- const inLabel = () => {
26
- let parent = instance == null ? void 0 : instance.parent;
27
- while (parent) {
28
- if (parent.type.name === "ElFormItem") {
29
- return false;
30
- }
31
- if (parent.type.name === "ElLabelWrap") {
32
- return true;
33
- }
34
- parent = parent.parent;
35
- }
36
- return false;
37
- };
38
- const inputId = ref();
39
- let idUnwatch = void 0;
40
- const isLabeledByFormItem = computed(() => {
41
- var _a;
42
- return !!(!(props.label || props.ariaLabel) && formItemContext && formItemContext.inputIds && ((_a = formItemContext.inputIds) == null ? void 0 : _a.length) <= 1);
43
- });
44
- onMounted(() => {
45
- idUnwatch = watch(
46
- [toRef(props, "id"), disableIdGeneration],
47
- ([id, disableIdGeneration2]) => {
48
- const newId = id != null ? id : !disableIdGeneration2 ? useId().value : void 0;
49
- if (newId !== inputId.value) {
50
- if ((formItemContext == null ? void 0 : formItemContext.removeInputId) && !inLabel()) {
51
- inputId.value && formItemContext.removeInputId(inputId.value);
52
- if (!(disableIdManagement == null ? void 0 : disableIdManagement.value) && !disableIdGeneration2 && newId) {
53
- formItemContext.addInputId(newId);
54
- }
55
- }
56
- inputId.value = newId;
57
- }
58
- },
59
- { immediate: true }
60
- );
61
- });
62
- onUnmounted(() => {
63
- idUnwatch && idUnwatch();
64
- if (formItemContext == null ? void 0 : formItemContext.removeInputId) {
65
- inputId.value && formItemContext.removeInputId(inputId.value);
66
- }
67
- });
68
- return {
69
- isLabeledByFormItem,
70
- inputId
71
- };
72
- };
73
-
74
- const useProp = (name) => {
75
- const vm = getCurrentInstance();
76
- return computed(() => {
77
- var _a, _b;
78
- return (_b = (_a = vm == null ? void 0 : vm.proxy) == null ? void 0 : _a.$props) == null ? void 0 : _b[name];
79
- });
80
- };
81
-
82
- const useFormSize = (fallback, ignore = {}) => {
83
- const emptyRef = ref(void 0);
84
- const size = ignore.prop ? emptyRef : useProp("size");
85
- const globalConfig = ignore.global ? emptyRef : useGlobalSize();
86
- const form = ignore.form ? { size: void 0 } : inject(formContextKey, void 0);
87
- const formItem = ignore.formItem ? { size: void 0 } : inject(formItemContextKey, void 0);
88
- return computed(
89
- () => size.value || unref(fallback) || (formItem == null ? void 0 : formItem.size) || (form == null ? void 0 : form.size) || globalConfig.value || ""
90
- );
91
- };
92
- const useFormDisabled = (fallback) => {
93
- const disabled = useProp("disabled");
94
- const form = inject(formContextKey, void 0);
95
- return computed(() => {
96
- var _a, _b, _c;
97
- return (_c = (_b = (_a = disabled.value) != null ? _a : unref(fallback)) != null ? _b : form == null ? void 0 : form.disabled) != null ? _c : false;
98
- });
99
- };
100
-
101
- export { useFormDisabled as a, useFormItemInputId as b, useFormSize as c, useFormItem as u };
@@ -1,242 +0,0 @@
1
- import { i as isObjectLike, b as baseGetTag, n as baseGet, l as castPath, t as toKey, w as arrayMap } from './Cxx_YWUC.mjs';
2
- import { g as getPrototype, c as copyObject, f as getAllKeysIn, b as baseClone } from './DZ2oTFad.mjs';
3
- import { a as flatRest } from './BunQI8Jb.mjs';
4
-
5
- /** `Object#toString` result references. */
6
- var objectTag = '[object Object]';
7
-
8
- /** Used for built-in method references. */
9
- var funcProto = Function.prototype,
10
- objectProto$1 = Object.prototype;
11
-
12
- /** Used to resolve the decompiled source of functions. */
13
- var funcToString = funcProto.toString;
14
-
15
- /** Used to check objects for own properties. */
16
- var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
17
-
18
- /** Used to infer the `Object` constructor. */
19
- var objectCtorString = funcToString.call(Object);
20
-
21
- /**
22
- * Checks if `value` is a plain object, that is, an object created by the
23
- * `Object` constructor or one with a `[[Prototype]]` of `null`.
24
- *
25
- * @static
26
- * @memberOf _
27
- * @since 0.8.0
28
- * @category Lang
29
- * @param {*} value The value to check.
30
- * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.
31
- * @example
32
- *
33
- * function Foo() {
34
- * this.a = 1;
35
- * }
36
- *
37
- * _.isPlainObject(new Foo);
38
- * // => false
39
- *
40
- * _.isPlainObject([1, 2, 3]);
41
- * // => false
42
- *
43
- * _.isPlainObject({ 'x': 0, 'y': 0 });
44
- * // => true
45
- *
46
- * _.isPlainObject(Object.create(null));
47
- * // => true
48
- */
49
- function isPlainObject(value) {
50
- if (!isObjectLike(value) || baseGetTag(value) != objectTag) {
51
- return false;
52
- }
53
- var proto = getPrototype(value);
54
- if (proto === null) {
55
- return true;
56
- }
57
- var Ctor = hasOwnProperty$1.call(proto, 'constructor') && proto.constructor;
58
- return typeof Ctor == 'function' && Ctor instanceof Ctor &&
59
- funcToString.call(Ctor) == objectCtorString;
60
- }
61
-
62
- /**
63
- * The base implementation of `_.slice` without an iteratee call guard.
64
- *
65
- * @private
66
- * @param {Array} array The array to slice.
67
- * @param {number} [start=0] The start position.
68
- * @param {number} [end=array.length] The end position.
69
- * @returns {Array} Returns the slice of `array`.
70
- */
71
- function baseSlice(array, start, end) {
72
- var index = -1,
73
- length = array.length;
74
-
75
- if (start < 0) {
76
- start = -start > length ? 0 : (length + start);
77
- }
78
- end = end > length ? length : end;
79
- if (end < 0) {
80
- end += length;
81
- }
82
- length = start > end ? 0 : ((end - start) >>> 0);
83
- start >>>= 0;
84
-
85
- var result = Array(length);
86
- while (++index < length) {
87
- result[index] = array[index + start];
88
- }
89
- return result;
90
- }
91
-
92
- /**
93
- * Gets the last element of `array`.
94
- *
95
- * @static
96
- * @memberOf _
97
- * @since 0.1.0
98
- * @category Array
99
- * @param {Array} array The array to query.
100
- * @returns {*} Returns the last element of `array`.
101
- * @example
102
- *
103
- * _.last([1, 2, 3]);
104
- * // => 3
105
- */
106
- function last(array) {
107
- var length = array == null ? 0 : array.length;
108
- return length ? array[length - 1] : undefined;
109
- }
110
-
111
- /**
112
- * Gets the parent value at `path` of `object`.
113
- *
114
- * @private
115
- * @param {Object} object The object to query.
116
- * @param {Array} path The path to get the parent value of.
117
- * @returns {*} Returns the parent value.
118
- */
119
- function parent(object, path) {
120
- return path.length < 2 ? object : baseGet(object, baseSlice(path, 0, -1));
121
- }
122
-
123
- /** Used for built-in method references. */
124
- var objectProto = Object.prototype;
125
-
126
- /** Used to check objects for own properties. */
127
- var hasOwnProperty = objectProto.hasOwnProperty;
128
-
129
- /**
130
- * The base implementation of `_.unset`.
131
- *
132
- * @private
133
- * @param {Object} object The object to modify.
134
- * @param {Array|string} path The property path to unset.
135
- * @returns {boolean} Returns `true` if the property is deleted, else `false`.
136
- */
137
- function baseUnset(object, path) {
138
- path = castPath(path, object);
139
-
140
- // Prevent prototype pollution, see: https://github.com/lodash/lodash/security/advisories/GHSA-xxjr-mmjv-4gpg
141
- var index = -1,
142
- length = path.length;
143
-
144
- if (!length) {
145
- return true;
146
- }
147
-
148
- var isRootPrimitive = object == null || (typeof object !== 'object' && typeof object !== 'function');
149
-
150
- while (++index < length) {
151
- var key = path[index];
152
-
153
- // skip non-string keys (e.g., Symbols, numbers)
154
- if (typeof key !== 'string') {
155
- continue;
156
- }
157
-
158
- // Always block "__proto__" anywhere in the path if it's not expected
159
- if (key === '__proto__' && !hasOwnProperty.call(object, '__proto__')) {
160
- return false;
161
- }
162
-
163
- // Block "constructor.prototype" chains
164
- if (key === 'constructor' &&
165
- (index + 1) < length &&
166
- typeof path[index + 1] === 'string' &&
167
- path[index + 1] === 'prototype') {
168
-
169
- // Allow ONLY when the path starts at a primitive root, e.g., _.unset(0, 'constructor.prototype.a')
170
- if (isRootPrimitive && index === 0) {
171
- continue;
172
- }
173
-
174
- return false;
175
- }
176
- }
177
-
178
- var obj = parent(object, path);
179
- return obj == null || delete obj[toKey(last(path))];
180
- }
181
-
182
- /**
183
- * Used by `_.omit` to customize its `_.cloneDeep` use to only clone plain
184
- * objects.
185
- *
186
- * @private
187
- * @param {*} value The value to inspect.
188
- * @param {string} key The key of the property to inspect.
189
- * @returns {*} Returns the uncloned value or `undefined` to defer cloning to `_.cloneDeep`.
190
- */
191
- function customOmitClone(value) {
192
- return isPlainObject(value) ? undefined : value;
193
- }
194
-
195
- /** Used to compose bitmasks for cloning. */
196
- var CLONE_DEEP_FLAG = 1,
197
- CLONE_FLAT_FLAG = 2,
198
- CLONE_SYMBOLS_FLAG = 4;
199
-
200
- /**
201
- * The opposite of `_.pick`; this method creates an object composed of the
202
- * own and inherited enumerable property paths of `object` that are not omitted.
203
- *
204
- * **Note:** This method is considerably slower than `_.pick`.
205
- *
206
- * @static
207
- * @since 0.1.0
208
- * @memberOf _
209
- * @category Object
210
- * @param {Object} object The source object.
211
- * @param {...(string|string[])} [paths] The property paths to omit.
212
- * @returns {Object} Returns the new object.
213
- * @example
214
- *
215
- * var object = { 'a': 1, 'b': '2', 'c': 3 };
216
- *
217
- * _.omit(object, ['a', 'c']);
218
- * // => { 'b': '2' }
219
- */
220
- var omit = flatRest(function(object, paths) {
221
- var result = {};
222
- if (object == null) {
223
- return result;
224
- }
225
- var isDeep = false;
226
- paths = arrayMap(paths, function(path) {
227
- path = castPath(path, object);
228
- isDeep || (isDeep = path.length > 1);
229
- return path;
230
- });
231
- copyObject(object, getAllKeysIn(object), result);
232
- if (isDeep) {
233
- result = baseClone(result, CLONE_DEEP_FLAG | CLONE_FLAT_FLAG | CLONE_SYMBOLS_FLAG, customOmitClone);
234
- }
235
- var length = paths.length;
236
- while (length--) {
237
- baseUnset(result, paths[length]);
238
- }
239
- return result;
240
- });
241
-
242
- export { isPlainObject as i, omit as o };