@cabloy/vue-runtime-core 3.4.33 → 3.4.35

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.
@@ -47,9 +47,8 @@ interface SchedulerJob extends Function {
47
47
  /**
48
48
  * Attached by renderer.ts when setting up a component's render effect
49
49
  * Used to obtain component information when reporting max recursive updates.
50
- * dev only.
51
50
  */
52
- ownerInstance?: ComponentInternalInstance;
51
+ i?: ComponentInternalInstance;
53
52
  }
54
53
  type SchedulerJobs = SchedulerJob | SchedulerJob[];
55
54
  export declare function nextTick<T = void, R = void>(this: T, fn?: (this: T) => R): Promise<Awaited<R>>;
@@ -280,7 +279,7 @@ export interface HydrationRenderer extends Renderer<Element | ShadowRoot> {
280
279
  export type ElementNamespace = 'svg' | 'mathml' | undefined;
281
280
  export type RootRenderFunction<HostElement = RendererElement> = (vnode: VNode | null, container: HostElement, namespace?: ElementNamespace) => void;
282
281
  export interface RendererOptions<HostNode = RendererNode, HostElement = RendererElement> {
283
- patchProp(el: HostElement, key: string, prevValue: any, nextValue: any, namespace?: ElementNamespace, prevChildren?: VNode<HostNode, HostElement>[], parentComponent?: ComponentInternalInstance | null, parentSuspense?: SuspenseBoundary | null, unmountChildren?: UnmountChildrenFn): void;
282
+ patchProp(el: HostElement, key: string, prevValue: any, nextValue: any, namespace?: ElementNamespace, parentComponent?: ComponentInternalInstance | null): void;
284
283
  insert(el: HostNode, parent: HostElement, anchor?: HostNode | null): void;
285
284
  remove(el: HostNode): void;
286
285
  createElement(type: string, namespace?: ElementNamespace, isCustomizedBuiltIn?: string, vnodeProps?: (VNodeProps & {
@@ -298,7 +297,7 @@ export interface RendererOptions<HostNode = RendererNode, HostElement = Renderer
298
297
  insertStaticContent?(content: string, parent: HostElement, anchor: HostNode | null, namespace: ElementNamespace, start?: HostNode | null, end?: HostNode | null): [HostNode, HostNode];
299
298
  }
300
299
  export interface RendererNode {
301
- [key: string]: any;
300
+ [key: string | symbol]: any;
302
301
  }
303
302
  export interface RendererElement extends RendererNode {
304
303
  }
@@ -323,7 +322,6 @@ type MoveFn = (vnode: VNode, container: RendererElement, anchor: RendererNode |
323
322
  type NextFn = (vnode: VNode) => RendererNode | null;
324
323
  type UnmountFn = (vnode: VNode, parentComponent: ComponentInternalInstance | null, parentSuspense: SuspenseBoundary | null, doRemove?: boolean, optimized?: boolean) => void;
325
324
  type RemoveFn = (vnode: VNode) => void;
326
- type UnmountChildrenFn = (children: VNode[], parentComponent: ComponentInternalInstance | null, parentSuspense: SuspenseBoundary | null, doRemove?: boolean, optimized?: boolean, start?: number) => void;
327
325
  type MountComponentFn = (initialVNode: VNode, container: RendererElement, anchor: RendererNode | null, parentComponent: ComponentInternalInstance | null, parentSuspense: SuspenseBoundary | null, namespace: ElementNamespace, optimized: boolean) => void;
328
326
  type SetupRenderEffectFn = (instance: ComponentInternalInstance, initialVNode: VNode, container: RendererElement, anchor: RendererNode | null, parentSuspense: SuspenseBoundary | null, namespace: ElementNamespace, optimized: boolean) => void;
329
327
  declare enum MoveType {
@@ -885,9 +883,21 @@ export declare const Static: unique symbol;
885
883
  export type VNodeTypes = string | VNode | Component | typeof Text | typeof Static | typeof Comment | typeof Fragment | typeof Teleport | typeof TeleportImpl | typeof Suspense | typeof SuspenseImpl;
886
884
  export type VNodeRef = string | Ref | ((ref: Element | ComponentPublicInstance | null, refs: Record<string, any>) => void);
887
885
  type VNodeNormalizedRefAtom = {
886
+ /**
887
+ * component instance
888
+ */
888
889
  i: ComponentInternalInstance;
890
+ /**
891
+ * Actual ref
892
+ */
889
893
  r: VNodeRef;
894
+ /**
895
+ * setup ref key
896
+ */
890
897
  k?: string;
898
+ /**
899
+ * refInFor marker
900
+ */
891
901
  f?: boolean;
892
902
  };
893
903
  type VNodeNormalizedRef = VNodeNormalizedRefAtom | VNodeNormalizedRefAtom[];
@@ -928,6 +938,7 @@ export interface VNode<HostNode = RendererNode, HostElement = RendererElement, E
928
938
  el: HostNode | null;
929
939
  anchor: HostNode | null;
930
940
  target: HostElement | null;
941
+ targetStart: HostNode | null;
931
942
  targetAnchor: HostNode | null;
932
943
  suspense: SuspenseBoundary | null;
933
944
  shapeFlag: number;
@@ -1122,8 +1133,6 @@ export interface ComponentInternalInstance {
1122
1133
  slots: InternalSlots;
1123
1134
  refs: Data;
1124
1135
  emit: EmitFn;
1125
- attrsProxy: Data | null;
1126
- slotsProxy: Slots | null;
1127
1136
  isMounted: boolean;
1128
1137
  isUnmounted: boolean;
1129
1138
  isDeactivated: boolean;
@@ -1138,7 +1147,7 @@ export declare function registerRuntimeCompiler(_compile: any): void;
1138
1147
  export declare const isRuntimeOnly: () => boolean;
1139
1148
 
1140
1149
  export type WatchEffect = (onCleanup: OnCleanup) => void;
1141
- export type WatchSource<T = any> = Ref<T> | ComputedRef<T> | (() => T);
1150
+ export type WatchSource<T = any> = Ref<T, any> | ComputedRef<T> | (() => T);
1142
1151
  export type WatchCallback<V = any, OV = any> = (value: V, oldValue: OV, onCleanup: OnCleanup) => any;
1143
1152
  type MaybeUndefined<T, I> = I extends true ? T | undefined : T;
1144
1153
  type MapSources<T, Immediate> = {
@@ -1438,12 +1447,13 @@ export declare enum ErrorCodes {
1438
1447
  APP_WARN_HANDLER = 11,
1439
1448
  FUNCTION_REF = 12,
1440
1449
  ASYNC_COMPONENT_LOADER = 13,
1441
- SCHEDULER = 14
1450
+ SCHEDULER = 14,
1451
+ COMPONENT_UPDATE = 15
1442
1452
  }
1443
1453
  type ErrorTypes = LifecycleHooks | ErrorCodes;
1444
- export declare function callWithErrorHandling(fn: Function, instance: ComponentInternalInstance | null, type: ErrorTypes, args?: unknown[]): any;
1454
+ export declare function callWithErrorHandling(fn: Function, instance: ComponentInternalInstance | null | undefined, type: ErrorTypes, args?: unknown[]): any;
1445
1455
  export declare function callWithAsyncErrorHandling(fn: Function | Function[], instance: ComponentInternalInstance | null, type: ErrorTypes, args?: unknown[]): any;
1446
- export declare function handleError(err: unknown, instance: ComponentInternalInstance | null, type: ErrorTypes, throwInDev?: boolean): void;
1456
+ export declare function handleError(err: unknown, instance: ComponentInternalInstance | null | undefined, type: ErrorTypes, throwInDev?: boolean): void;
1447
1457
 
1448
1458
  export declare function initCustomFormatter(): void;
1449
1459