@histoire/vendors 0.17.8 → 0.17.14
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/client/node_modules/@babel/parser/package.json +2 -2
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/api.d.ts +17 -17
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/app.d.ts +1 -1
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/component.d.ts +5 -5
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/hooks.d.ts +27 -27
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/api/util.d.ts +1 -1
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/env.d.ts +1 -1
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/index.d.ts +6 -6
- package/dist/client/node_modules/@vue/devtools-api/lib/esm/plugin.d.ts +3 -3
- package/dist/client/node_modules/@vue/devtools-api/package.json +12 -12
- package/dist/client/node_modules/@vueuse/core/node_modules/vue-demi/package.json +2 -2
- package/dist/client/node_modules/@vueuse/shared/node_modules/vue-demi/package.json +2 -2
- package/dist/client/node_modules/magic-string/dist/magic-string.cjs.d.ts +4 -0
- package/dist/client/node_modules/magic-string/package.json +7 -7
- package/dist/client/node_modules/pinia/node_modules/vue-demi/package.json +2 -2
- package/dist/client/node_modules/postcss/lib/at-rule.d.ts +25 -3
- package/dist/client/node_modules/postcss/lib/container.d.ts +44 -6
- package/dist/client/node_modules/postcss/lib/declaration.d.ts +2 -2
- package/dist/client/node_modules/postcss/lib/document.d.ts +1 -0
- package/dist/client/node_modules/postcss/lib/node.d.ts +3 -3
- package/dist/client/node_modules/postcss/lib/root.d.ts +1 -0
- package/dist/client/node_modules/postcss/lib/rule.d.ts +6 -2
- package/dist/client/node_modules/postcss/package.json +1 -1
- package/package.json +1 -1
- package/rollup.config.mjs +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@babel/parser",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.24.0",
|
|
4
4
|
"description": "A JavaScript parser",
|
|
5
5
|
"author": "The Babel Team (https://babel.dev/team)",
|
|
6
6
|
"homepage": "https://babel.dev/docs/en/next/babel-parser",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"@babel/code-frame": "^7.23.5",
|
|
38
38
|
"@babel/helper-check-duplicate-nodes": "^7.22.5",
|
|
39
|
-
"@babel/helper-fixtures": "^7.
|
|
39
|
+
"@babel/helper-fixtures": "^7.24.0",
|
|
40
40
|
"@babel/helper-string-parser": "^7.23.4",
|
|
41
41
|
"@babel/helper-validator-identifier": "^7.22.20",
|
|
42
42
|
"charcodes": "^0.2.0"
|
|
@@ -5,24 +5,24 @@ import type { App } from './app.js';
|
|
|
5
5
|
import type { ID } from './util.js';
|
|
6
6
|
export interface DevtoolsPluginApi<TSettings> {
|
|
7
7
|
on: Hookable<Context>;
|
|
8
|
-
notifyComponentUpdate(instance?: ComponentInstance)
|
|
9
|
-
addTimelineLayer(options: TimelineLayerOptions)
|
|
10
|
-
addTimelineEvent(options: TimelineEventOptions)
|
|
11
|
-
addInspector(options: CustomInspectorOptions)
|
|
12
|
-
sendInspectorTree(inspectorId: string)
|
|
13
|
-
sendInspectorState(inspectorId: string)
|
|
14
|
-
selectInspectorNode(inspectorId: string, nodeId: string)
|
|
15
|
-
getComponentBounds(instance: ComponentInstance)
|
|
16
|
-
getComponentName(instance: ComponentInstance)
|
|
17
|
-
getComponentInstances(app: App)
|
|
18
|
-
highlightElement(instance: ComponentInstance)
|
|
19
|
-
unhighlightElement()
|
|
20
|
-
getSettings(pluginId?: string)
|
|
21
|
-
now()
|
|
8
|
+
notifyComponentUpdate: (instance?: ComponentInstance) => void;
|
|
9
|
+
addTimelineLayer: (options: TimelineLayerOptions) => void;
|
|
10
|
+
addTimelineEvent: (options: TimelineEventOptions) => void;
|
|
11
|
+
addInspector: (options: CustomInspectorOptions) => void;
|
|
12
|
+
sendInspectorTree: (inspectorId: string) => void;
|
|
13
|
+
sendInspectorState: (inspectorId: string) => void;
|
|
14
|
+
selectInspectorNode: (inspectorId: string, nodeId: string) => void;
|
|
15
|
+
getComponentBounds: (instance: ComponentInstance) => Promise<ComponentBounds>;
|
|
16
|
+
getComponentName: (instance: ComponentInstance) => Promise<string>;
|
|
17
|
+
getComponentInstances: (app: App) => Promise<ComponentInstance[]>;
|
|
18
|
+
highlightElement: (instance: ComponentInstance) => void;
|
|
19
|
+
unhighlightElement: () => void;
|
|
20
|
+
getSettings: (pluginId?: string) => TSettings;
|
|
21
|
+
now: () => number;
|
|
22
22
|
/**
|
|
23
|
-
* @private
|
|
23
|
+
* @private
|
|
24
24
|
*/
|
|
25
|
-
setSettings(values: TSettings)
|
|
25
|
+
setSettings: (values: TSettings) => void;
|
|
26
26
|
}
|
|
27
27
|
export interface AppRecord {
|
|
28
28
|
id: string;
|
|
@@ -48,7 +48,7 @@ export interface ScreenshotOverlayRenderContext<TData = any, TMeta = any> {
|
|
|
48
48
|
events: (TimelineEvent<TData, TMeta> & ScreenshotOverlayEvent)[];
|
|
49
49
|
index: number;
|
|
50
50
|
}
|
|
51
|
-
export
|
|
51
|
+
export type ScreenshotOverlayRenderResult = HTMLElement | string | false;
|
|
52
52
|
export interface ScreenshotData {
|
|
53
53
|
time: number;
|
|
54
54
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type App = any;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { InspectorNodeTag } from './api.js';
|
|
2
2
|
import type { ID } from './util.js';
|
|
3
|
-
export
|
|
3
|
+
export type ComponentInstance = any;
|
|
4
4
|
export interface ComponentTreeNode {
|
|
5
5
|
uid: ID;
|
|
6
6
|
id: string;
|
|
@@ -43,11 +43,11 @@ export interface ComponentPropState extends ComponentStateBase {
|
|
|
43
43
|
mode?: 'default' | 'sync' | 'once';
|
|
44
44
|
};
|
|
45
45
|
}
|
|
46
|
-
export
|
|
46
|
+
export type ComponentBuiltinCustomStateTypes = 'function' | 'map' | 'set' | 'reference' | 'component' | 'component-definition' | 'router' | 'store';
|
|
47
47
|
export interface ComponentCustomState extends ComponentStateBase {
|
|
48
48
|
value: CustomState;
|
|
49
49
|
}
|
|
50
|
-
export
|
|
50
|
+
export interface CustomState {
|
|
51
51
|
_custom: {
|
|
52
52
|
type: ComponentBuiltinCustomStateTypes | string;
|
|
53
53
|
objectType?: string;
|
|
@@ -71,8 +71,8 @@ export declare type CustomState = {
|
|
|
71
71
|
/** internal */
|
|
72
72
|
_reviveId?: number;
|
|
73
73
|
};
|
|
74
|
-
}
|
|
75
|
-
export
|
|
74
|
+
}
|
|
75
|
+
export type ComponentState = ComponentStateBase | ComponentPropState | ComponentCustomState;
|
|
76
76
|
export interface ComponentDevtoolsOptions {
|
|
77
77
|
hide?: boolean;
|
|
78
78
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ComponentDevtoolsOptions, ComponentInstance, ComponentTreeNode, InspectedComponentData } from './component.js';
|
|
2
2
|
import type { App } from './app.js';
|
|
3
3
|
import type { CustomInspectorNode, CustomInspectorState, TimelineEvent } from './api.js';
|
|
4
4
|
export declare const enum Hooks {
|
|
@@ -31,7 +31,7 @@ export interface ComponentBounds {
|
|
|
31
31
|
width: number;
|
|
32
32
|
height: number;
|
|
33
33
|
}
|
|
34
|
-
export
|
|
34
|
+
export interface HookPayloads {
|
|
35
35
|
[Hooks.TRANSFORM_CALL]: {
|
|
36
36
|
callName: string;
|
|
37
37
|
inArgs: any[];
|
|
@@ -143,8 +143,8 @@ export declare type HookPayloads = {
|
|
|
143
143
|
oldValue: any;
|
|
144
144
|
settings: any;
|
|
145
145
|
};
|
|
146
|
-
}
|
|
147
|
-
export
|
|
146
|
+
}
|
|
147
|
+
export type EditStatePayload = {
|
|
148
148
|
value: any;
|
|
149
149
|
newKey?: string | null;
|
|
150
150
|
remove?: undefined | false;
|
|
@@ -153,28 +153,28 @@ export declare type EditStatePayload = {
|
|
|
153
153
|
newKey?: undefined;
|
|
154
154
|
remove: true;
|
|
155
155
|
};
|
|
156
|
-
export
|
|
156
|
+
export type HookHandler<TPayload, TContext> = (payload: TPayload, ctx: TContext) => void | Promise<void>;
|
|
157
157
|
export interface Hookable<TContext> {
|
|
158
|
-
transformCall(handler: HookHandler<HookPayloads[Hooks.TRANSFORM_CALL], TContext>)
|
|
159
|
-
getAppRecordName(handler: HookHandler<HookPayloads[Hooks.GET_APP_RECORD_NAME], TContext>)
|
|
160
|
-
getAppRootInstance(handler: HookHandler<HookPayloads[Hooks.GET_APP_ROOT_INSTANCE], TContext>)
|
|
161
|
-
registerApplication(handler: HookHandler<HookPayloads[Hooks.REGISTER_APPLICATION], TContext>)
|
|
162
|
-
walkComponentTree(handler: HookHandler<HookPayloads[Hooks.WALK_COMPONENT_TREE], TContext>)
|
|
163
|
-
visitComponentTree(handler: HookHandler<HookPayloads[Hooks.VISIT_COMPONENT_TREE], TContext>)
|
|
164
|
-
walkComponentParents(handler: HookHandler<HookPayloads[Hooks.WALK_COMPONENT_PARENTS], TContext>)
|
|
165
|
-
inspectComponent(handler: HookHandler<HookPayloads[Hooks.INSPECT_COMPONENT], TContext>)
|
|
166
|
-
getComponentBounds(handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_BOUNDS], TContext>)
|
|
167
|
-
getComponentName(handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_NAME], TContext>)
|
|
168
|
-
getComponentInstances(handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_INSTANCES], TContext>)
|
|
169
|
-
getElementComponent(handler: HookHandler<HookPayloads[Hooks.GET_ELEMENT_COMPONENT], TContext>)
|
|
170
|
-
getComponentRootElements(handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_ROOT_ELEMENTS], TContext>)
|
|
171
|
-
editComponentState(handler: HookHandler<HookPayloads[Hooks.EDIT_COMPONENT_STATE], TContext>)
|
|
172
|
-
getComponentDevtoolsOptions(handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_DEVTOOLS_OPTIONS], TContext>)
|
|
173
|
-
getComponentRenderCode(handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_RENDER_CODE], TContext>)
|
|
174
|
-
inspectTimelineEvent(handler: HookHandler<HookPayloads[Hooks.INSPECT_TIMELINE_EVENT], TContext>)
|
|
175
|
-
timelineCleared(handler: HookHandler<HookPayloads[Hooks.TIMELINE_CLEARED], TContext>)
|
|
176
|
-
getInspectorTree(handler: HookHandler<HookPayloads[Hooks.GET_INSPECTOR_TREE], TContext>)
|
|
177
|
-
getInspectorState(handler: HookHandler<HookPayloads[Hooks.GET_INSPECTOR_STATE], TContext>)
|
|
178
|
-
editInspectorState(handler: HookHandler<HookPayloads[Hooks.EDIT_INSPECTOR_STATE], TContext>)
|
|
179
|
-
setPluginSettings(handler: HookHandler<HookPayloads[Hooks.SET_PLUGIN_SETTINGS], TContext>)
|
|
158
|
+
transformCall: (handler: HookHandler<HookPayloads[Hooks.TRANSFORM_CALL], TContext>) => any;
|
|
159
|
+
getAppRecordName: (handler: HookHandler<HookPayloads[Hooks.GET_APP_RECORD_NAME], TContext>) => any;
|
|
160
|
+
getAppRootInstance: (handler: HookHandler<HookPayloads[Hooks.GET_APP_ROOT_INSTANCE], TContext>) => any;
|
|
161
|
+
registerApplication: (handler: HookHandler<HookPayloads[Hooks.REGISTER_APPLICATION], TContext>) => any;
|
|
162
|
+
walkComponentTree: (handler: HookHandler<HookPayloads[Hooks.WALK_COMPONENT_TREE], TContext>) => any;
|
|
163
|
+
visitComponentTree: (handler: HookHandler<HookPayloads[Hooks.VISIT_COMPONENT_TREE], TContext>) => any;
|
|
164
|
+
walkComponentParents: (handler: HookHandler<HookPayloads[Hooks.WALK_COMPONENT_PARENTS], TContext>) => any;
|
|
165
|
+
inspectComponent: (handler: HookHandler<HookPayloads[Hooks.INSPECT_COMPONENT], TContext>) => any;
|
|
166
|
+
getComponentBounds: (handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_BOUNDS], TContext>) => any;
|
|
167
|
+
getComponentName: (handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_NAME], TContext>) => any;
|
|
168
|
+
getComponentInstances: (handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_INSTANCES], TContext>) => any;
|
|
169
|
+
getElementComponent: (handler: HookHandler<HookPayloads[Hooks.GET_ELEMENT_COMPONENT], TContext>) => any;
|
|
170
|
+
getComponentRootElements: (handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_ROOT_ELEMENTS], TContext>) => any;
|
|
171
|
+
editComponentState: (handler: HookHandler<HookPayloads[Hooks.EDIT_COMPONENT_STATE], TContext>) => any;
|
|
172
|
+
getComponentDevtoolsOptions: (handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_DEVTOOLS_OPTIONS], TContext>) => any;
|
|
173
|
+
getComponentRenderCode: (handler: HookHandler<HookPayloads[Hooks.GET_COMPONENT_RENDER_CODE], TContext>) => any;
|
|
174
|
+
inspectTimelineEvent: (handler: HookHandler<HookPayloads[Hooks.INSPECT_TIMELINE_EVENT], TContext>) => any;
|
|
175
|
+
timelineCleared: (handler: HookHandler<HookPayloads[Hooks.TIMELINE_CLEARED], TContext>) => any;
|
|
176
|
+
getInspectorTree: (handler: HookHandler<HookPayloads[Hooks.GET_INSPECTOR_TREE], TContext>) => any;
|
|
177
|
+
getInspectorState: (handler: HookHandler<HookPayloads[Hooks.GET_INSPECTOR_STATE], TContext>) => any;
|
|
178
|
+
editInspectorState: (handler: HookHandler<HookPayloads[Hooks.EDIT_INSPECTOR_STATE], TContext>) => any;
|
|
179
|
+
setPluginSettings: (handler: HookHandler<HookPayloads[Hooks.SET_PLUGIN_SETTINGS], TContext>) => any;
|
|
180
180
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { PluginDescriptor, SetupFunction } from './index.js';
|
|
2
1
|
import type { ApiProxy } from './proxy.js';
|
|
2
|
+
import type { PluginDescriptor, SetupFunction } from './index.js';
|
|
3
3
|
export interface PluginQueueItem {
|
|
4
4
|
pluginDescriptor: PluginDescriptor;
|
|
5
5
|
setupFn: SetupFunction;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import type { DevtoolsPluginApi } from './api/index.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { ExtractSettingsTypes, PluginDescriptor, PluginSettingsItem } from './plugin.js';
|
|
3
3
|
export * from './api/index.js';
|
|
4
4
|
export * from './plugin.js';
|
|
5
5
|
export * from './time.js';
|
|
6
6
|
export { PluginQueueItem } from './env.js';
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
type Cast<A, B> = A extends B ? A : B;
|
|
8
|
+
type Narrowable = string | number | bigint | boolean;
|
|
9
|
+
type Narrow<A> = Cast<A, [] | (A extends Narrowable ? A : never) | ({
|
|
10
10
|
[K in keyof A]: Narrow<A[K]>;
|
|
11
11
|
})>;
|
|
12
|
-
|
|
12
|
+
type Exact<C, T> = {
|
|
13
13
|
[K in keyof C]: K extends keyof T ? T[K] : never;
|
|
14
14
|
};
|
|
15
|
-
export
|
|
15
|
+
export type SetupFunction<TSettings = any> = (api: DevtoolsPluginApi<TSettings>) => void;
|
|
16
16
|
export declare function setupDevtoolsPlugin<TDescriptor extends Exact<TDescriptor, PluginDescriptor>, TSettings = ExtractSettingsTypes<TDescriptor extends {
|
|
17
17
|
settings: infer S;
|
|
18
18
|
} ? S extends Record<string, PluginSettingsItem> ? S : Record<string, PluginSettingsItem> : Record<string, PluginSettingsItem>>>(pluginDescriptor: Narrow<TDescriptor>, setupFn: SetupFunction<TSettings>): void;
|
|
@@ -16,7 +16,7 @@ export interface PluginDescriptor {
|
|
|
16
16
|
enableEarlyProxy?: boolean;
|
|
17
17
|
settings?: Record<string, PluginSettingsItem>;
|
|
18
18
|
}
|
|
19
|
-
export
|
|
19
|
+
export type PluginSettingsItem = {
|
|
20
20
|
label: string;
|
|
21
21
|
description?: string;
|
|
22
22
|
} & ({
|
|
@@ -34,14 +34,14 @@ export declare type PluginSettingsItem = {
|
|
|
34
34
|
type: 'text';
|
|
35
35
|
defaultValue: string;
|
|
36
36
|
});
|
|
37
|
-
|
|
37
|
+
type InferSettingsType<T extends PluginSettingsItem> = [T] extends [{
|
|
38
38
|
type: 'boolean';
|
|
39
39
|
}] ? boolean : [T] extends [{
|
|
40
40
|
type: 'choice';
|
|
41
41
|
}] ? T['options'][number]['value'] : [T] extends [{
|
|
42
42
|
type: 'text';
|
|
43
43
|
}] ? string : unknown;
|
|
44
|
-
export
|
|
44
|
+
export type ExtractSettingsTypes<O extends Record<string, PluginSettingsItem>> = {
|
|
45
45
|
[K in keyof O]: InferSettingsType<O[K]>;
|
|
46
46
|
};
|
|
47
47
|
export {};
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vue/devtools-api",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.6.1",
|
|
4
4
|
"description": "Interact with the Vue devtools from the page",
|
|
5
|
-
"main": "lib/cjs/index.js",
|
|
6
|
-
"browser": "lib/esm/index.js",
|
|
7
|
-
"module": "lib/esm/index.js",
|
|
8
|
-
"types": "lib/esm/index.d.ts",
|
|
9
|
-
"sideEffects": false,
|
|
10
5
|
"author": {
|
|
11
6
|
"name": "Guillaume Chau"
|
|
12
7
|
},
|
|
13
|
-
"files": [
|
|
14
|
-
"lib/esm",
|
|
15
|
-
"lib/cjs"
|
|
16
|
-
],
|
|
17
8
|
"license": "MIT",
|
|
18
9
|
"repository": {
|
|
19
10
|
"url": "https://github.com/vuejs/vue-devtools.git",
|
|
20
11
|
"type": "git",
|
|
21
12
|
"directory": "packages/api"
|
|
22
13
|
},
|
|
14
|
+
"sideEffects": false,
|
|
15
|
+
"main": "lib/cjs/index.js",
|
|
16
|
+
"browser": "lib/esm/index.js",
|
|
17
|
+
"module": "lib/esm/index.js",
|
|
18
|
+
"types": "lib/esm/index.d.ts",
|
|
19
|
+
"files": [
|
|
20
|
+
"lib/cjs",
|
|
21
|
+
"lib/esm"
|
|
22
|
+
],
|
|
23
23
|
"publishConfig": {
|
|
24
24
|
"access": "public"
|
|
25
25
|
},
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
"build:watch": "yarn tsc --module es2015 --outDir lib/esm -d -w --sourceMap"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@types/node": "^
|
|
33
|
+
"@types/node": "^20.11.16",
|
|
34
34
|
"@types/webpack-env": "^1.15.1",
|
|
35
|
-
"typescript": "^
|
|
35
|
+
"typescript": "^5.3.3"
|
|
36
36
|
}
|
|
37
37
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vue-demi",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.7",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">=12"
|
|
6
6
|
},
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"scripts"
|
|
33
33
|
],
|
|
34
34
|
"scripts": {
|
|
35
|
-
"postinstall": "node ./scripts/postinstall.js",
|
|
35
|
+
"postinstall": "node -e \"try{require('./scripts/postinstall.js')}catch(e){}\"",
|
|
36
36
|
"release": "npx bumpp --tag --commit --push && npm publish"
|
|
37
37
|
},
|
|
38
38
|
"peerDependencies": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vue-demi",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.7",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">=12"
|
|
6
6
|
},
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"scripts"
|
|
33
33
|
],
|
|
34
34
|
"scripts": {
|
|
35
|
-
"postinstall": "node ./scripts/postinstall.js",
|
|
35
|
+
"postinstall": "node -e \"try{require('./scripts/postinstall.js')}catch(e){}\"",
|
|
36
36
|
"release": "npx bumpp --tag --commit --push && npm publish"
|
|
37
37
|
},
|
|
38
38
|
"peerDependencies": {
|
|
@@ -209,6 +209,10 @@ export default class MagicString {
|
|
|
209
209
|
* Removing the same content twice, or making removals that partially overlap, will cause an error.
|
|
210
210
|
*/
|
|
211
211
|
remove(start: number, end: number): MagicString;
|
|
212
|
+
/**
|
|
213
|
+
* Reset the modified characters from `start` to `end` (of the original string, **not** the generated string).
|
|
214
|
+
*/
|
|
215
|
+
reset(start: number, end: number): MagicString;
|
|
212
216
|
/**
|
|
213
217
|
* Returns the content of the generated string that corresponds to the slice between `start` and `end` of the original string.
|
|
214
218
|
* Throws error if the indices are for characters that were already removed.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "magic-string",
|
|
3
|
-
"version": "0.30.
|
|
3
|
+
"version": "0.30.8",
|
|
4
4
|
"description": "Modify strings, generate sourcemaps",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"string",
|
|
@@ -42,15 +42,15 @@
|
|
|
42
42
|
"watch": "rollup -cw"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@rollup/plugin-node-resolve": "^15.2.
|
|
46
|
-
"@rollup/plugin-replace": "^5.0.
|
|
45
|
+
"@rollup/plugin-node-resolve": "^15.2.3",
|
|
46
|
+
"@rollup/plugin-replace": "^5.0.5",
|
|
47
47
|
"benchmark": "^2.1.4",
|
|
48
|
-
"bumpp": "^9.
|
|
48
|
+
"bumpp": "^9.3.0",
|
|
49
49
|
"conventional-changelog-cli": "^3.0.0",
|
|
50
|
-
"eslint": "^8.
|
|
50
|
+
"eslint": "^8.56.0",
|
|
51
51
|
"mocha": "^10.2.0",
|
|
52
|
-
"prettier": "^3.
|
|
53
|
-
"publint": "^0.2.
|
|
52
|
+
"prettier": "^3.2.4",
|
|
53
|
+
"publint": "^0.2.7",
|
|
54
54
|
"rollup": "^3.28.0",
|
|
55
55
|
"source-map-js": "^1.0.2",
|
|
56
56
|
"source-map-support": "^0.5.21"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vue-demi",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.7",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">=12"
|
|
6
6
|
},
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"scripts"
|
|
33
33
|
],
|
|
34
34
|
"scripts": {
|
|
35
|
-
"postinstall": "node ./scripts/postinstall.js",
|
|
35
|
+
"postinstall": "node -e \"try{require('./scripts/postinstall.js')}catch(e){}\"",
|
|
36
36
|
"release": "npx bumpp --tag --commit --push && npm publish"
|
|
37
37
|
},
|
|
38
38
|
"peerDependencies": {
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
import Container, {
|
|
1
|
+
import Container, {
|
|
2
|
+
ContainerProps,
|
|
3
|
+
ContainerWithChildren
|
|
4
|
+
} from './container.js'
|
|
2
5
|
|
|
3
6
|
declare namespace AtRule {
|
|
4
7
|
export interface AtRuleRaws extends Record<string, unknown> {
|
|
@@ -81,11 +84,30 @@ declare class AtRule_ extends Container {
|
|
|
81
84
|
*
|
|
82
85
|
* ```js
|
|
83
86
|
* const root = postcss.parse('@media print {}')
|
|
84
|
-
* media.name //=> 'media'
|
|
85
87
|
* const media = root.first
|
|
88
|
+
* media.name //=> 'media'
|
|
86
89
|
* ```
|
|
87
90
|
*/
|
|
88
91
|
name: string
|
|
92
|
+
/**
|
|
93
|
+
* An array containing the layer’s children.
|
|
94
|
+
*
|
|
95
|
+
* ```js
|
|
96
|
+
* const root = postcss.parse('@layer example { a { color: black } }')
|
|
97
|
+
* const layer = root.first
|
|
98
|
+
* layer.nodes.length //=> 1
|
|
99
|
+
* layer.nodes[0].selector //=> 'a'
|
|
100
|
+
* ```
|
|
101
|
+
*
|
|
102
|
+
* Can be `undefinded` if the at-rule has no body.
|
|
103
|
+
*
|
|
104
|
+
* ```js
|
|
105
|
+
* const root = postcss.parse('@layer a, b, c;')
|
|
106
|
+
* const layer = root.first
|
|
107
|
+
* layer.nodes //=> undefined
|
|
108
|
+
* ```
|
|
109
|
+
*/
|
|
110
|
+
nodes: Container['nodes']
|
|
89
111
|
/**
|
|
90
112
|
* The at-rule’s parameters, the values that follow the at-rule’s name
|
|
91
113
|
* but precede any `{}` block.
|
|
@@ -97,7 +119,7 @@ declare class AtRule_ extends Container {
|
|
|
97
119
|
* ```
|
|
98
120
|
*/
|
|
99
121
|
params: string
|
|
100
|
-
parent:
|
|
122
|
+
parent: ContainerWithChildren | undefined
|
|
101
123
|
|
|
102
124
|
raws: AtRule.AtRuleRaws
|
|
103
125
|
|
|
@@ -5,6 +5,12 @@ import Node, { ChildNode, ChildProps, NodeProps } from './node.js'
|
|
|
5
5
|
import Rule from './rule.js'
|
|
6
6
|
|
|
7
7
|
declare namespace Container {
|
|
8
|
+
export class ContainerWithChildren<
|
|
9
|
+
Child extends Node = ChildNode
|
|
10
|
+
> extends Container_<Child> {
|
|
11
|
+
nodes: Child[]
|
|
12
|
+
}
|
|
13
|
+
|
|
8
14
|
export interface ValueOptions {
|
|
9
15
|
/**
|
|
10
16
|
* String that’s used to narrow down values and speed up the regexp search.
|
|
@@ -43,7 +49,7 @@ declare abstract class Container_<Child extends Node = ChildNode> extends Node {
|
|
|
43
49
|
* root.nodes[0].nodes[0].prop //=> 'color'
|
|
44
50
|
* ```
|
|
45
51
|
*/
|
|
46
|
-
nodes: Child[]
|
|
52
|
+
nodes: Child[] | undefined
|
|
47
53
|
|
|
48
54
|
/**
|
|
49
55
|
* Inserts new nodes to the end of the container.
|
|
@@ -66,7 +72,15 @@ declare abstract class Container_<Child extends Node = ChildNode> extends Node {
|
|
|
66
72
|
* @return This node for methods chain.
|
|
67
73
|
*/
|
|
68
74
|
append(
|
|
69
|
-
...nodes: (
|
|
75
|
+
...nodes: (
|
|
76
|
+
| ChildProps
|
|
77
|
+
| ChildProps[]
|
|
78
|
+
| Node
|
|
79
|
+
| Node[]
|
|
80
|
+
| string
|
|
81
|
+
| string[]
|
|
82
|
+
| undefined
|
|
83
|
+
)[]
|
|
70
84
|
): this
|
|
71
85
|
|
|
72
86
|
assign(overrides: Container.ContainerProps | object): this
|
|
@@ -146,7 +160,14 @@ declare abstract class Container_<Child extends Node = ChildNode> extends Node {
|
|
|
146
160
|
*/
|
|
147
161
|
insertAfter(
|
|
148
162
|
oldNode: Child | number,
|
|
149
|
-
newNode:
|
|
163
|
+
newNode:
|
|
164
|
+
| Child
|
|
165
|
+
| Child[]
|
|
166
|
+
| ChildProps
|
|
167
|
+
| ChildProps[]
|
|
168
|
+
| string
|
|
169
|
+
| string[]
|
|
170
|
+
| undefined
|
|
150
171
|
): this
|
|
151
172
|
/**
|
|
152
173
|
* Insert new node before old node within the container.
|
|
@@ -161,7 +182,14 @@ declare abstract class Container_<Child extends Node = ChildNode> extends Node {
|
|
|
161
182
|
*/
|
|
162
183
|
insertBefore(
|
|
163
184
|
oldNode: Child | number,
|
|
164
|
-
newNode:
|
|
185
|
+
newNode:
|
|
186
|
+
| Child
|
|
187
|
+
| Child[]
|
|
188
|
+
| ChildProps
|
|
189
|
+
| ChildProps[]
|
|
190
|
+
| string
|
|
191
|
+
| string[]
|
|
192
|
+
| undefined
|
|
165
193
|
): this
|
|
166
194
|
|
|
167
195
|
/**
|
|
@@ -202,7 +230,15 @@ declare abstract class Container_<Child extends Node = ChildNode> extends Node {
|
|
|
202
230
|
* @return This node for methods chain.
|
|
203
231
|
*/
|
|
204
232
|
prepend(
|
|
205
|
-
...nodes: (
|
|
233
|
+
...nodes: (
|
|
234
|
+
| ChildProps
|
|
235
|
+
| ChildProps[]
|
|
236
|
+
| Node
|
|
237
|
+
| Node[]
|
|
238
|
+
| string
|
|
239
|
+
| string[]
|
|
240
|
+
| undefined
|
|
241
|
+
)[]
|
|
206
242
|
): this
|
|
207
243
|
/**
|
|
208
244
|
* Add child to the end of the node.
|
|
@@ -447,6 +483,8 @@ declare abstract class Container_<Child extends Node = ChildNode> extends Node {
|
|
|
447
483
|
get last(): Child | undefined
|
|
448
484
|
}
|
|
449
485
|
|
|
450
|
-
declare class Container<
|
|
486
|
+
declare class Container<
|
|
487
|
+
Child extends Node = ChildNode
|
|
488
|
+
> extends Container_<Child> {}
|
|
451
489
|
|
|
452
490
|
export = Container
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ContainerWithChildren } from './container.js'
|
|
2
2
|
import Node from './node.js'
|
|
3
3
|
|
|
4
4
|
declare namespace Declaration {
|
|
@@ -79,7 +79,7 @@ declare class Declaration_ extends Node {
|
|
|
79
79
|
*/
|
|
80
80
|
important: boolean
|
|
81
81
|
|
|
82
|
-
parent:
|
|
82
|
+
parent: ContainerWithChildren | undefined
|
|
83
83
|
|
|
84
84
|
/**
|
|
85
85
|
* The property name for a CSS declaration.
|
|
@@ -246,7 +246,7 @@ declare abstract class Node_ {
|
|
|
246
246
|
* @param newNode New node.
|
|
247
247
|
* @return This node for methods chain.
|
|
248
248
|
*/
|
|
249
|
-
after(newNode: Node | Node.ChildProps | Node[] | string): this
|
|
249
|
+
after(newNode: Node | Node.ChildProps | Node[] | string | undefined): this
|
|
250
250
|
|
|
251
251
|
/**
|
|
252
252
|
* It assigns properties to an existing node instance.
|
|
@@ -273,7 +273,7 @@ declare abstract class Node_ {
|
|
|
273
273
|
* @param newNode New node.
|
|
274
274
|
* @return This node for methods chain.
|
|
275
275
|
*/
|
|
276
|
-
before(newNode: Node | Node.ChildProps | Node[] | string): this
|
|
276
|
+
before(newNode: Node | Node.ChildProps | Node[] | string | undefined): this
|
|
277
277
|
|
|
278
278
|
/**
|
|
279
279
|
* Clear the code style properties for the node and its children.
|
|
@@ -531,6 +531,6 @@ declare abstract class Node_ {
|
|
|
531
531
|
warn(result: Result, message: string, options?: WarningOptions): Warning
|
|
532
532
|
}
|
|
533
533
|
|
|
534
|
-
declare class Node extends Node_ {
|
|
534
|
+
declare class Node extends Node_ {}
|
|
535
535
|
|
|
536
536
|
export = Node
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
import Container, {
|
|
1
|
+
import Container, {
|
|
2
|
+
ContainerProps,
|
|
3
|
+
ContainerWithChildren
|
|
4
|
+
} from './container.js'
|
|
2
5
|
|
|
3
6
|
declare namespace Rule {
|
|
4
7
|
export interface RuleRaws extends Record<string, unknown> {
|
|
@@ -69,7 +72,8 @@ declare namespace Rule {
|
|
|
69
72
|
* ```
|
|
70
73
|
*/
|
|
71
74
|
declare class Rule_ extends Container {
|
|
72
|
-
|
|
75
|
+
nodes: NonNullable<Container['nodes']>
|
|
76
|
+
parent: ContainerWithChildren | undefined
|
|
73
77
|
raws: Rule.RuleRaws
|
|
74
78
|
/**
|
|
75
79
|
* The rule’s full selector represented as a string.
|
package/package.json
CHANGED
package/rollup.config.mjs
CHANGED
|
@@ -29,13 +29,13 @@ export default defineConfig({
|
|
|
29
29
|
}),
|
|
30
30
|
{
|
|
31
31
|
name: 'define',
|
|
32
|
-
transform
|
|
32
|
+
transform(code) {
|
|
33
33
|
return code.replace(/__VUE_OPTIONS_API__/g, 'true')
|
|
34
34
|
},
|
|
35
35
|
},
|
|
36
36
|
{
|
|
37
37
|
name: 'process-build',
|
|
38
|
-
closeBundle
|
|
38
|
+
closeBundle() {
|
|
39
39
|
try {
|
|
40
40
|
const pkg = fs.readJsonSync('./package.json')
|
|
41
41
|
const tempDir = path.resolve('./node_modules/.temp/histoire-vendors')
|
|
@@ -68,7 +68,7 @@ export default defineConfig({
|
|
|
68
68
|
const filepath = file.replace(/\.d\.ts$/, '')
|
|
69
69
|
const content = `import Default from '${filepath}'
|
|
70
70
|
export default Default
|
|
71
|
-
export * from '${filepath}'\n
|
|
71
|
+
export * from '${filepath}'\n`.replace(/\n/g, process.platform === 'win32' ? '\r\n' : '\n')
|
|
72
72
|
fs.writeFileSync(path.basename(file).replace(/^b-/, ''), content, 'utf-8')
|
|
73
73
|
}
|
|
74
74
|
// Exports (package.json)
|