@vue/shared 3.6.0-beta.4 → 3.6.0-beta.5
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/shared.cjs.js +511 -480
- package/dist/shared.cjs.prod.js +509 -470
- package/dist/shared.d.ts +264 -252
- package/dist/shared.esm-bundler.js +510 -475
- package/package.json +1 -1
package/dist/shared.d.ts
CHANGED
|
@@ -1,24 +1,26 @@
|
|
|
1
|
+
//#region temp/packages/shared/src/makeMap.d.ts
|
|
1
2
|
/**
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
* Make a map and return a function for checking if a key
|
|
4
|
+
* is in that map.
|
|
5
|
+
* IMPORTANT: all calls of this function must be prefixed with
|
|
6
|
+
* \/\*#\_\_PURE\_\_\*\/
|
|
7
|
+
* So that they can be tree-shaken if necessary.
|
|
8
|
+
*/
|
|
8
9
|
export declare function makeMap(str: string): (key: string) => boolean;
|
|
9
|
-
|
|
10
|
+
//#endregion
|
|
11
|
+
//#region temp/packages/shared/src/general.d.ts
|
|
10
12
|
export declare const EMPTY_OBJ: {
|
|
11
|
-
|
|
13
|
+
readonly [key: string]: any;
|
|
12
14
|
};
|
|
13
15
|
export declare const EMPTY_ARR: readonly never[];
|
|
14
16
|
export declare const NOOP: () => void;
|
|
15
17
|
/**
|
|
16
|
-
|
|
17
|
-
|
|
18
|
+
* Always return true.
|
|
19
|
+
*/
|
|
18
20
|
export declare const YES: () => boolean;
|
|
19
21
|
/**
|
|
20
|
-
|
|
21
|
-
|
|
22
|
+
* Always return false.
|
|
23
|
+
*/
|
|
22
24
|
export declare const NO: () => boolean;
|
|
23
25
|
export declare const isOn: (key: string) => boolean;
|
|
24
26
|
export declare const isNativeOn: (key: string) => boolean;
|
|
@@ -45,334 +47,344 @@ export declare const isReservedProp: (key: string) => boolean;
|
|
|
45
47
|
export declare const isBuiltInTag: (key: string) => boolean;
|
|
46
48
|
export declare const isBuiltInDirective: (key: string) => boolean;
|
|
47
49
|
/**
|
|
48
|
-
|
|
49
|
-
|
|
50
|
+
* @private
|
|
51
|
+
*/
|
|
50
52
|
export declare const camelize: (str: string) => string;
|
|
51
53
|
/**
|
|
52
|
-
|
|
53
|
-
|
|
54
|
+
* @private
|
|
55
|
+
*/
|
|
54
56
|
export declare const hyphenate: (str: string) => string;
|
|
55
57
|
/**
|
|
56
|
-
|
|
57
|
-
|
|
58
|
+
* @private
|
|
59
|
+
*/
|
|
58
60
|
export declare const capitalize: <T extends string>(str: T) => Capitalize<T>;
|
|
59
61
|
/**
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
export declare const toHandlerKey: <T extends string>(str: T) => T extends
|
|
62
|
+
* @private
|
|
63
|
+
*/
|
|
64
|
+
export declare const toHandlerKey: <T extends string>(str: T) => T extends "" ? "" : `on${Capitalize<T>}`;
|
|
63
65
|
/**
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
* #13070 When v-model and v-model:model directives are used together,
|
|
67
|
+
* they will generate the same modelModifiers prop,
|
|
68
|
+
* so a `$` suffix is added to avoid conflicts.
|
|
69
|
+
* @private
|
|
70
|
+
*/
|
|
69
71
|
export declare const getModifierPropName: (name: string) => string;
|
|
70
72
|
export declare const hasChanged: (value: any, oldValue: any) => boolean;
|
|
71
73
|
export declare const invokeArrayFns: (fns: Function[], ...arg: any[]) => void;
|
|
72
74
|
export declare const def: (obj: object, key: string | symbol, value: any, writable?: boolean) => void;
|
|
73
75
|
/**
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
76
|
+
* "123-foo" will be parsed to 123
|
|
77
|
+
* This is used for the .number modifier in v-model
|
|
78
|
+
*/
|
|
77
79
|
export declare const looseToNumber: (val: any) => any;
|
|
78
80
|
/**
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
81
|
+
* Only concerns number-like strings
|
|
82
|
+
* "123-foo" will be returned as-is
|
|
83
|
+
*/
|
|
82
84
|
export declare const toNumber: (val: any) => any;
|
|
83
85
|
export declare const getGlobalThis: () => any;
|
|
84
86
|
export declare function genPropsAccessExp(name: string): string;
|
|
85
87
|
export declare function genCacheKey(source: string, options: any): string;
|
|
86
88
|
export declare function canSetValueDirectly(tagName: string): boolean;
|
|
87
|
-
|
|
89
|
+
//#endregion
|
|
90
|
+
//#region temp/packages/shared/src/patchFlags.d.ts
|
|
88
91
|
/**
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
92
|
+
* Patch flags are optimization hints generated by the compiler.
|
|
93
|
+
* when a block with dynamicChildren is encountered during diff, the algorithm
|
|
94
|
+
* enters "optimized mode". In this mode, we know that the vdom is produced by
|
|
95
|
+
* a render function generated by the compiler, so the algorithm only needs to
|
|
96
|
+
* handle updates explicitly marked by these patch flags.
|
|
97
|
+
*
|
|
98
|
+
* Patch flags can be combined using the | bitwise operator and can be checked
|
|
99
|
+
* using the & operator, e.g.
|
|
100
|
+
*
|
|
101
|
+
* ```js
|
|
102
|
+
* const flag = TEXT | CLASS
|
|
103
|
+
* if (flag & TEXT) { ... }
|
|
104
|
+
* ```
|
|
105
|
+
*
|
|
106
|
+
* Check the `patchElement` function in '../../runtime-core/src/renderer.ts' to see how the
|
|
107
|
+
* flags are handled during diff.
|
|
108
|
+
*/
|
|
106
109
|
export declare enum PatchFlags {
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
110
|
+
/**
|
|
111
|
+
* Indicates an element with dynamic textContent (children fast path)
|
|
112
|
+
*/
|
|
113
|
+
TEXT = 1,
|
|
114
|
+
/**
|
|
115
|
+
* Indicates an element with dynamic class binding.
|
|
116
|
+
*/
|
|
117
|
+
CLASS = 2,
|
|
118
|
+
/**
|
|
119
|
+
* Indicates an element with dynamic style
|
|
120
|
+
* The compiler pre-compiles static string styles into static objects
|
|
121
|
+
* + detects and hoists inline static objects
|
|
122
|
+
* e.g. `style="color: red"` and `:style="{ color: 'red' }"` both get hoisted
|
|
123
|
+
* as:
|
|
124
|
+
* ```js
|
|
125
|
+
* const style = { color: 'red' }
|
|
126
|
+
* render() { return e('div', { style }) }
|
|
127
|
+
* ```
|
|
128
|
+
*/
|
|
129
|
+
STYLE = 4,
|
|
130
|
+
/**
|
|
131
|
+
* Indicates an element that has non-class/style dynamic props.
|
|
132
|
+
* Can also be on a component that has any dynamic props (includes
|
|
133
|
+
* class/style). when this flag is present, the vnode also has a dynamicProps
|
|
134
|
+
* array that contains the keys of the props that may change so the runtime
|
|
135
|
+
* can diff them faster (without having to worry about removed props)
|
|
136
|
+
*/
|
|
137
|
+
PROPS = 8,
|
|
138
|
+
/**
|
|
139
|
+
* Indicates an element with props with dynamic keys. When keys change, a full
|
|
140
|
+
* diff is always needed to remove the old key. This flag is mutually
|
|
141
|
+
* exclusive with CLASS, STYLE and PROPS.
|
|
142
|
+
*/
|
|
143
|
+
FULL_PROPS = 16,
|
|
144
|
+
/**
|
|
145
|
+
* Indicates an element that requires props hydration
|
|
146
|
+
* (but not necessarily patching)
|
|
147
|
+
* e.g. event listeners & v-bind with prop modifier
|
|
148
|
+
*/
|
|
149
|
+
NEED_HYDRATION = 32,
|
|
150
|
+
/**
|
|
151
|
+
* Indicates a fragment whose children order doesn't change.
|
|
152
|
+
*/
|
|
153
|
+
STABLE_FRAGMENT = 64,
|
|
154
|
+
/**
|
|
155
|
+
* Indicates a fragment with keyed or partially keyed children
|
|
156
|
+
*/
|
|
157
|
+
KEYED_FRAGMENT = 128,
|
|
158
|
+
/**
|
|
159
|
+
* Indicates a fragment with unkeyed children.
|
|
160
|
+
*/
|
|
161
|
+
UNKEYED_FRAGMENT = 256,
|
|
162
|
+
/**
|
|
163
|
+
* Indicates an element that only needs non-props patching, e.g. ref or
|
|
164
|
+
* directives (onVnodeXXX hooks). since every patched vnode checks for refs
|
|
165
|
+
* and onVnodeXXX hooks, it simply marks the vnode so that a parent block
|
|
166
|
+
* will track it.
|
|
167
|
+
*/
|
|
168
|
+
NEED_PATCH = 512,
|
|
169
|
+
/**
|
|
170
|
+
* Indicates a component with dynamic slots (e.g. slot that references a v-for
|
|
171
|
+
* iterated value, or dynamic slot names).
|
|
172
|
+
* Components with this flag are always force updated.
|
|
173
|
+
*/
|
|
174
|
+
DYNAMIC_SLOTS = 1024,
|
|
175
|
+
/**
|
|
176
|
+
* Indicates a fragment that was created only because the user has placed
|
|
177
|
+
* comments at the root level of a template. This is a dev-only flag since
|
|
178
|
+
* comments are stripped in production.
|
|
179
|
+
*/
|
|
180
|
+
DEV_ROOT_FRAGMENT = 2048,
|
|
181
|
+
/**
|
|
182
|
+
* SPECIAL FLAGS -------------------------------------------------------------
|
|
183
|
+
* Special flags are negative integers. They are never matched against using
|
|
184
|
+
* bitwise operators (bitwise matching should only happen in branches where
|
|
185
|
+
* patchFlag > 0), and are mutually exclusive. When checking for a special
|
|
186
|
+
* flag, simply check patchFlag === FLAG.
|
|
187
|
+
*/
|
|
188
|
+
/**
|
|
189
|
+
* Indicates a cached static vnode. This is also a hint for hydration to skip
|
|
190
|
+
* the entire sub tree since static content never needs to be updated.
|
|
191
|
+
*/
|
|
192
|
+
CACHED = -1,
|
|
193
|
+
/**
|
|
194
|
+
* A special flag that indicates that the diffing algorithm should bail out
|
|
195
|
+
* of optimized mode. For example, on block fragments created by renderSlot()
|
|
196
|
+
* when encountering non-compiler generated slots (i.e. manually written
|
|
197
|
+
* render functions, which should always be fully diffed)
|
|
198
|
+
* OR manually cloneVNodes
|
|
199
|
+
*/
|
|
200
|
+
BAIL = -2
|
|
198
201
|
}
|
|
199
202
|
/**
|
|
200
|
-
|
|
201
|
-
|
|
203
|
+
* dev only flag -> name mapping
|
|
204
|
+
*/
|
|
202
205
|
export declare const PatchFlagNames: Record<PatchFlags, string>;
|
|
203
|
-
|
|
206
|
+
//#endregion
|
|
207
|
+
//#region temp/packages/shared/src/shapeFlags.d.ts
|
|
204
208
|
export declare enum ShapeFlags {
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
209
|
+
ELEMENT = 1,
|
|
210
|
+
FUNCTIONAL_COMPONENT = 2,
|
|
211
|
+
STATEFUL_COMPONENT = 4,
|
|
212
|
+
TEXT_CHILDREN = 8,
|
|
213
|
+
ARRAY_CHILDREN = 16,
|
|
214
|
+
SLOTS_CHILDREN = 32,
|
|
215
|
+
TELEPORT = 64,
|
|
216
|
+
SUSPENSE = 128,
|
|
217
|
+
COMPONENT_SHOULD_KEEP_ALIVE = 256,
|
|
218
|
+
COMPONENT_KEPT_ALIVE = 512,
|
|
219
|
+
COMPONENT = 6
|
|
216
220
|
}
|
|
217
|
-
|
|
221
|
+
//#endregion
|
|
222
|
+
//#region temp/packages/shared/src/slotFlags.d.ts
|
|
218
223
|
export declare enum SlotFlags {
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
224
|
+
/**
|
|
225
|
+
* Stable slots that only reference slot props or context state. The slot
|
|
226
|
+
* can fully capture its own dependencies so when passed down the parent won't
|
|
227
|
+
* need to force the child to update.
|
|
228
|
+
*/
|
|
229
|
+
STABLE = 1,
|
|
230
|
+
/**
|
|
231
|
+
* Slots that reference scope variables (v-for or an outer slot prop), or
|
|
232
|
+
* has conditional structure (v-if, v-for). The parent will need to force
|
|
233
|
+
* the child to update because the slot does not fully capture its dependencies.
|
|
234
|
+
*/
|
|
235
|
+
DYNAMIC = 2,
|
|
236
|
+
/**
|
|
237
|
+
* `<slot/>` being forwarded into a child component. Whether the parent needs
|
|
238
|
+
* to update the child is dependent on what kind of slots the parent itself
|
|
239
|
+
* received. This has to be refined at runtime, when the child's vnode
|
|
240
|
+
* is being created (in `normalizeChildren`)
|
|
241
|
+
*/
|
|
242
|
+
FORWARDED = 3
|
|
238
243
|
}
|
|
239
244
|
/**
|
|
240
|
-
|
|
241
|
-
|
|
245
|
+
* Dev only
|
|
246
|
+
*/
|
|
242
247
|
export declare const slotFlagsText: Record<SlotFlags, string>;
|
|
243
|
-
|
|
248
|
+
//#endregion
|
|
249
|
+
//#region temp/packages/shared/src/globalsAllowList.d.ts
|
|
244
250
|
export declare const isGloballyAllowed: (key: string) => boolean;
|
|
245
251
|
/** @deprecated use `isGloballyAllowed` instead */
|
|
246
252
|
export declare const isGloballyWhitelisted: (key: string) => boolean;
|
|
247
|
-
|
|
253
|
+
//#endregion
|
|
254
|
+
//#region temp/packages/shared/src/codeframe.d.ts
|
|
248
255
|
export declare function generateCodeFrame(source: string, start?: number, end?: number): string;
|
|
249
|
-
|
|
256
|
+
//#endregion
|
|
257
|
+
//#region temp/packages/shared/src/normalizeProp.d.ts
|
|
250
258
|
export type NormalizedStyle = Record<string, unknown>;
|
|
251
259
|
export declare function normalizeStyle(value: unknown): NormalizedStyle | string | undefined;
|
|
252
260
|
export declare function parseStringStyle(cssText: string): NormalizedStyle;
|
|
253
261
|
export declare function stringifyStyle(styles: NormalizedStyle | string | undefined): string;
|
|
254
262
|
export declare function normalizeClass(value: unknown): string;
|
|
255
263
|
export declare function normalizeProps(props: Record<string, any> | null): Record<string, any> | null;
|
|
256
|
-
|
|
264
|
+
//#endregion
|
|
265
|
+
//#region temp/packages/shared/src/domTagConfig.d.ts
|
|
257
266
|
/**
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
267
|
+
* Compiler only.
|
|
268
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
269
|
+
*/
|
|
261
270
|
export declare const isHTMLTag: (key: string) => boolean;
|
|
262
271
|
/**
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
272
|
+
* Compiler only.
|
|
273
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
274
|
+
*/
|
|
266
275
|
export declare const isSVGTag: (key: string) => boolean;
|
|
267
276
|
/**
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
277
|
+
* Compiler only.
|
|
278
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
279
|
+
*/
|
|
271
280
|
export declare const isMathMLTag: (key: string) => boolean;
|
|
272
281
|
/**
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
282
|
+
* Compiler only.
|
|
283
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
284
|
+
*/
|
|
276
285
|
export declare const isVoidTag: (key: string) => boolean;
|
|
277
286
|
/**
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
287
|
+
* Compiler only.
|
|
288
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
289
|
+
*/
|
|
281
290
|
export declare const isFormattingTag: (key: string) => boolean;
|
|
282
291
|
/**
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
292
|
+
* Compiler only.
|
|
293
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
294
|
+
*/
|
|
286
295
|
export declare const isAlwaysCloseTag: (key: string) => boolean;
|
|
287
296
|
/**
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
297
|
+
* Compiler only.
|
|
298
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
299
|
+
*/
|
|
291
300
|
export declare const isInlineTag: (key: string) => boolean;
|
|
292
301
|
/**
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
302
|
+
* Compiler only.
|
|
303
|
+
* Do NOT use in runtime code paths unless behind `__DEV__` flag.
|
|
304
|
+
*/
|
|
296
305
|
export declare const isBlockTag: (key: string) => boolean;
|
|
297
|
-
|
|
306
|
+
//#endregion
|
|
307
|
+
//#region temp/packages/shared/src/domAttrConfig.d.ts
|
|
298
308
|
export declare const isSpecialBooleanAttr: (key: string) => boolean;
|
|
299
309
|
/**
|
|
300
|
-
|
|
301
|
-
|
|
310
|
+
* The full list is needed during SSR to produce the correct initial markup.
|
|
311
|
+
*/
|
|
302
312
|
export declare const isBooleanAttr: (key: string) => boolean;
|
|
303
313
|
/**
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
314
|
+
* Boolean attributes should be included if the value is truthy or ''.
|
|
315
|
+
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
|
316
|
+
*/
|
|
307
317
|
export declare function includeBooleanAttr(value: unknown): boolean;
|
|
308
318
|
export declare function isSSRSafeAttrName(name: string): boolean;
|
|
309
319
|
export declare const propsToAttrMap: Record<string, string | undefined>;
|
|
310
320
|
/**
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
321
|
+
* Known attributes, this is used for stringification of runtime static nodes
|
|
322
|
+
* so that we don't stringify bindings that cannot be set from HTML.
|
|
323
|
+
* Don't also forget to allow `data-*` and `aria-*`!
|
|
324
|
+
* Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes
|
|
325
|
+
*/
|
|
316
326
|
export declare const isKnownHtmlAttr: (key: string) => boolean;
|
|
317
327
|
/**
|
|
318
|
-
|
|
319
|
-
|
|
328
|
+
* Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute
|
|
329
|
+
*/
|
|
320
330
|
export declare const isKnownSvgAttr: (key: string) => boolean;
|
|
321
331
|
/**
|
|
322
|
-
|
|
323
|
-
|
|
332
|
+
* Generated from https://developer.mozilla.org/en-US/docs/Web/MathML/Attribute
|
|
333
|
+
*/
|
|
324
334
|
export declare const isKnownMathMLAttr: (key: string) => boolean;
|
|
325
335
|
/**
|
|
326
|
-
|
|
327
|
-
|
|
336
|
+
* Shared between server-renderer and runtime-core hydration logic
|
|
337
|
+
*/
|
|
328
338
|
export declare function isRenderableAttrValue(value: unknown): boolean;
|
|
329
339
|
export declare function shouldSetAsAttr(tagName: string, key: string): boolean;
|
|
330
|
-
|
|
340
|
+
//#endregion
|
|
341
|
+
//#region temp/packages/shared/src/domNamespace.d.ts
|
|
331
342
|
export type Namespace = number;
|
|
332
343
|
export declare enum Namespaces {
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
344
|
+
HTML = 0,
|
|
345
|
+
SVG = 1,
|
|
346
|
+
MATH_ML = 2
|
|
336
347
|
}
|
|
337
|
-
|
|
348
|
+
//#endregion
|
|
349
|
+
//#region temp/packages/shared/src/escapeHtml.d.ts
|
|
338
350
|
export declare function escapeHtml(string: unknown): string;
|
|
339
351
|
export declare function escapeHtmlComment(src: string): string;
|
|
340
352
|
export declare const cssVarNameEscapeSymbolsRE: RegExp;
|
|
341
353
|
export declare function getEscapedCssVarName(key: string, doubleEscape: boolean): string;
|
|
342
|
-
|
|
354
|
+
//#endregion
|
|
355
|
+
//#region temp/packages/shared/src/looseEqual.d.ts
|
|
343
356
|
export declare function looseEqual(a: any, b: any): boolean;
|
|
344
357
|
export declare function looseIndexOf(arr: any[], val: any): number;
|
|
345
|
-
|
|
358
|
+
//#endregion
|
|
359
|
+
//#region temp/packages/shared/src/toDisplayString.d.ts
|
|
346
360
|
/**
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
361
|
+
* For converting {{ interpolation }} values to displayed strings.
|
|
362
|
+
* @private
|
|
363
|
+
*/
|
|
350
364
|
export declare const toDisplayString: (val: unknown) => string;
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
export type
|
|
356
|
-
export type LooseRequired<T> = {
|
|
357
|
-
[P in keyof (T & Required<T>)]: T[P];
|
|
358
|
-
};
|
|
365
|
+
//#endregion
|
|
366
|
+
//#region temp/packages/shared/src/typeUtils.d.ts
|
|
367
|
+
export type Prettify<T> = { [K in keyof T]: T[K] } & {};
|
|
368
|
+
export type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never;
|
|
369
|
+
export type LooseRequired<T> = { [P in keyof (T & Required<T>)]: T[P] };
|
|
359
370
|
export type IfAny<T, Y, N> = 0 extends 1 & T ? Y : N;
|
|
360
371
|
export type IsKeyValues<T, K = string> = IfAny<T, false, T extends object ? (keyof T extends K ? true : false) : false>;
|
|
361
372
|
/**
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
373
|
+
* Utility for extracting the parameters from a function overload (for typed emits)
|
|
374
|
+
* https://github.com/microsoft/TypeScript/issues/32164#issuecomment-1146737709
|
|
375
|
+
*/
|
|
365
376
|
export type OverloadParameters<T extends (...args: any[]) => any> = Parameters<OverloadUnion<T>>;
|
|
366
377
|
type OverloadProps<TOverload> = Pick<TOverload, keyof TOverload>;
|
|
367
|
-
type OverloadUnionRecursive<TOverload, TPartialOverload = unknown> = TOverload extends (...args: infer TArgs) => infer TReturn ? TPartialOverload extends TOverload ? never : OverloadUnionRecursive<TPartialOverload & TOverload, TPartialOverload & ((...args: TArgs) => TReturn) & OverloadProps<TOverload>> | ((...args: TArgs) => TReturn) : never;
|
|
368
|
-
type OverloadUnion<TOverload extends (...args: any[]) => any> = Exclude<OverloadUnionRecursive<(() => never) & TOverload>, TOverload extends () => never ? never : () => never>;
|
|
369
|
-
|
|
378
|
+
type OverloadUnionRecursive<TOverload, TPartialOverload = unknown> = TOverload extends ((...args: infer TArgs) => infer TReturn) ? TPartialOverload extends TOverload ? never : OverloadUnionRecursive<TPartialOverload & TOverload, TPartialOverload & ((...args: TArgs) => TReturn) & OverloadProps<TOverload>> | ((...args: TArgs) => TReturn) : never;
|
|
379
|
+
type OverloadUnion<TOverload extends (...args: any[]) => any> = Exclude<OverloadUnionRecursive<(() => never) & TOverload>, TOverload extends (() => never) ? never : () => never>;
|
|
380
|
+
//#endregion
|
|
381
|
+
//#region temp/packages/shared/src/subSequence.d.ts
|
|
370
382
|
export declare function getSequence(arr: number[]): number[];
|
|
371
|
-
|
|
383
|
+
//#endregion
|
|
384
|
+
//#region temp/packages/shared/src/cssVars.d.ts
|
|
372
385
|
/**
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
386
|
+
* Normalize CSS var value created by `v-bind` in `<style>` block
|
|
387
|
+
* See https://github.com/vuejs/core/pull/12461#issuecomment-2495804664
|
|
388
|
+
*/
|
|
376
389
|
export declare function normalizeCssVarValue(value: unknown): string;
|
|
377
|
-
|
|
378
|
-
|
|
390
|
+
//#endregion
|