@arcgis/lumina-compiler 5.1.0-next.1 → 5.1.0-next.100
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/context/index.d.ts +3 -0
- package/dist/dependencies/discover.d.ts +0 -6
- package/dist/dependencies/index.d.ts +0 -1
- package/dist/dependencies/testSetupFiles.d.ts +0 -1
- package/dist/dependencies/updateLumina.d.ts +5 -3
- package/dist/dependencies/utils.d.ts +0 -9
- package/dist/docs/index.d.ts +5 -5
- package/dist/docs/stencilDocsJson.d.ts +3 -2
- package/dist/docs/vsCodeCustomData/types.d.ts +3 -2
- package/dist/docs/webTypes/description.d.ts +1 -6
- package/dist/docs/webTypes/index.d.ts +1 -2
- package/dist/docs/webTypes/types.d.ts +4 -3
- package/dist/entrypoints/config.d.ts +0 -1
- package/dist/entrypoints/dtsUtils.d.ts +0 -1
- package/dist/index.js +1103 -1053
- package/dist/jsxToLitHtml/jsxVisitor.d.ts +1 -2
- package/dist/loader/lazy.d.ts +2 -2
- package/dist/logger-C9XakOcA.js +36 -0
- package/dist/plugins/buildCdn.d.ts +0 -4
- package/dist/plugins/buildWrappers.d.ts +1 -0
- package/dist/plugins/handleDynamicAssets.d.ts +5 -0
- package/dist/plugins/provideAssets.d.ts +0 -1
- package/dist/plugins/updatePackageJson.d.ts +5 -0
- package/dist/publicTypes.d.ts +11 -11
- package/dist/puppeteerTesting/index.js +5 -3
- package/dist/puppeteerTesting/vitest/matchers/index.d.ts +12 -12
- package/dist/puppeteerTesting/vitest/runner.d.ts +3 -3
- package/dist/puppeteerTesting/vitest/runner.js +1 -1
- package/dist/puppeteerTesting/vitest/types.d.ts +2 -1
- package/dist/testing/index.d.ts +1 -1
- package/dist/testing/index.js +75 -75
- package/dist/testing/mount.d.ts +7 -0
- package/dist/transformers/injectRuntimeOptions.d.ts +5 -0
- package/dist/transformers/members.d.ts +1 -3
- package/package.json +13 -13
- package/dist/logger-63CXuX6h.js +0 -33
- package/dist/utils/error.d.ts +0 -4
package/dist/context/index.d.ts
CHANGED
|
@@ -10,6 +10,9 @@ import { getLocalDefinedComponentsFromApiJson } from '../entrypoints/resolveTagN
|
|
|
10
10
|
import { unsafeGetUndocumentedPrinter } from '@arcgis/api-extractor/utils/internalTypeScriptApis';
|
|
11
11
|
import { ApiExtractor } from '@arcgis/api-extractor/extractor/ApiExtractor';
|
|
12
12
|
import { ApiExtractorPluginConfig } from '@arcgis/api-extractor/vite/plugin';
|
|
13
|
+
/**
|
|
14
|
+
* A compiler state and context object that is shared across plugins.
|
|
15
|
+
*/
|
|
13
16
|
export declare class CompilerContext {
|
|
14
17
|
/**
|
|
15
18
|
* TypeScript source file instances created in serve mode
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { PackageJson } from '@arcgis/components-build-utils';
|
|
2
|
-
import { WebTypes } from '../docs/webTypes/types.ts';
|
|
3
2
|
import { ApiJson } from '@arcgis/api-extractor/apiJson';
|
|
4
3
|
import { LuminaOptions } from '../publicTypes.ts';
|
|
5
4
|
export type ResolvedDependencyComponents = {
|
|
@@ -63,8 +62,3 @@ export declare function manifestToDependencyComponents(manifest: Partial<ApiJson
|
|
|
63
62
|
readonly packageName: string | undefined;
|
|
64
63
|
readonly getImportPath: (tagName: string) => string;
|
|
65
64
|
}, computeRequiredProperties?: boolean): ResolvedDependencyComponents["components"];
|
|
66
|
-
export declare const webTypesToDependencyComponents: (webTypes: Partial<WebTypes>, dependency: {
|
|
67
|
-
readonly packageName: string;
|
|
68
|
-
readonly getImportPath: (tagName: string) => string;
|
|
69
|
-
}) => ResolvedDependencyComponents["components"];
|
|
70
|
-
export declare const inferDependencyComponentModuleName: (usesExports: boolean, tagName: string) => string;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { ResolvedDependencyComponents } from './discover.ts';
|
|
2
|
-
export declare function updateLuminaTs(dependencies: readonly ResolvedDependencyComponents[], srcDir: string,
|
|
2
|
+
export declare function updateLuminaTs(dependencies: readonly ResolvedDependencyComponents[], srcDir: string,
|
|
3
3
|
/** Preserved positional argument for compatibility because codemod was passing it */
|
|
4
|
-
_unused?: never,
|
|
5
|
-
|
|
4
|
+
_unused?: never,
|
|
5
|
+
/** Preserved positional argument for compatibility because codemod was passing it */
|
|
6
|
+
_unused2?: never, packageJson?: import('@arcgis/components-build-utils').PackageJson): Promise<boolean>;
|
|
7
|
+
declare function produceLuminaTs(dependencies: readonly ResolvedDependencyComponents[], packageJson?: import('@arcgis/components-build-utils').PackageJson): string;
|
|
6
8
|
export declare const exportsForTests: {
|
|
7
9
|
produceLuminaTs: typeof produceLuminaTs;
|
|
8
10
|
};
|
|
@@ -7,15 +7,6 @@ export type DependencyInjectionResult = HtmlTagDescriptor | {
|
|
|
7
7
|
optimizableImports: string[];
|
|
8
8
|
javascriptCode: string[];
|
|
9
9
|
};
|
|
10
|
-
/**
|
|
11
|
-
* Convert a path like C:/Users/test into /C:/Users/test
|
|
12
|
-
*
|
|
13
|
-
* Leaves posix paths unchanged
|
|
14
|
-
*
|
|
15
|
-
* Mirrors what Vite does:
|
|
16
|
-
* https://github.com/vitejs/vite/blob/564c8f45f5429bd149b441d7dca4f44347dedfb1/packages/vite/src/node/server/warmup.ts#L66
|
|
17
|
-
*/
|
|
18
|
-
export declare const absolutePathToUrl: (absolutePath: string) => string;
|
|
19
10
|
/**
|
|
20
11
|
* The `baseUrl` should be set to `context.viteConfig.base`
|
|
21
12
|
* Vite always normalized `base` to end with `/`, and, if in serve mode, to not
|
package/dist/docs/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { CompilerContext } from '../context/index.ts';
|
|
2
2
|
import { Plugin } from 'vite';
|
|
3
3
|
/**
|
|
4
|
-
* Generate JSON component metadata in 4 formats
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
4
|
+
* Generate JSON component metadata in 4 formats
|
|
5
|
+
* - community standard
|
|
6
|
+
* - Stencil-like format
|
|
7
|
+
* - VS Code standard
|
|
8
|
+
* - JetBrains standard
|
|
9
9
|
*/
|
|
10
10
|
export declare function generateDocs(context: CompilerContext): Plugin;
|
|
@@ -4,7 +4,8 @@ import { ApiDocsTag } from '@arcgis/api-extractor/apiJson';
|
|
|
4
4
|
* To avoid having a dependency on Stencil, we inline Stencil types rather than
|
|
5
5
|
* importing them.
|
|
6
6
|
*/
|
|
7
|
-
|
|
7
|
+
interface JsonDocs {
|
|
8
|
+
deprecation?: string;
|
|
8
9
|
components: JsonDocsComponent[];
|
|
9
10
|
timestamp: string;
|
|
10
11
|
compiler: {
|
|
@@ -90,7 +91,7 @@ interface ComplexType {
|
|
|
90
91
|
resolved: string;
|
|
91
92
|
references: ComponentCompilerTypeReferences;
|
|
92
93
|
}
|
|
93
|
-
|
|
94
|
+
interface JsonDocsProp {
|
|
94
95
|
name: string;
|
|
95
96
|
complexType?: ComplexType;
|
|
96
97
|
type: string;
|
|
@@ -21,7 +21,7 @@ export type VsCodeTag = {
|
|
|
21
21
|
attributes?: VsCodeTagAttribute[];
|
|
22
22
|
references?: VsCodeReference[];
|
|
23
23
|
};
|
|
24
|
-
|
|
24
|
+
type VsCodeCssProperty = {
|
|
25
25
|
name: string;
|
|
26
26
|
description?: string;
|
|
27
27
|
values?: VsCodeValue[];
|
|
@@ -36,7 +36,8 @@ export type VsCodeTagAttribute = {
|
|
|
36
36
|
export type VsCodeValue = {
|
|
37
37
|
name: string;
|
|
38
38
|
};
|
|
39
|
-
|
|
39
|
+
type VsCodeReference = {
|
|
40
40
|
name: string;
|
|
41
41
|
url: string;
|
|
42
42
|
};
|
|
43
|
+
export {};
|
|
@@ -1,7 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ApiCustomElementDeclaration } from '@arcgis/api-extractor/apiJson';
|
|
2
2
|
export declare function getComponentDetailsTemplate(component: ApiCustomElementDeclaration): string;
|
|
3
|
-
export declare const getSlotsTemplate: (slots?: ApiSlot[]) => string;
|
|
4
|
-
export declare const getEventsTemplate: (events?: ApiEvent[]) => string;
|
|
5
|
-
export declare const getCssPropsTemplate: (cssProperties?: ApiCssCustomProperty[]) => string;
|
|
6
|
-
export declare const getPartsTemplate: (cssParts?: ApiCssPart[]) => string;
|
|
7
|
-
export declare const getMethodsTemplate: (methods: ApiClassMember[]) => string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { WebTypesOptions,
|
|
1
|
+
import { WebTypesOptions, WebTypes } from './types.ts';
|
|
2
2
|
import { ApiCustomElementDeclaration } from '@arcgis/api-extractor/apiJson';
|
|
3
3
|
/**
|
|
4
4
|
* Originally based on
|
|
@@ -17,4 +17,3 @@ import { ApiCustomElementDeclaration } from '@arcgis/api-extractor/apiJson';
|
|
|
17
17
|
* - https://github.com/break-stuff/cem-tools/issues/112
|
|
18
18
|
*/
|
|
19
19
|
export declare function generateWebTypes(components: ApiCustomElementDeclaration[], options: WebTypesOptions): WebTypes;
|
|
20
|
-
export declare const getTagList: (components: ApiCustomElementDeclaration[]) => WebTypesElement[];
|
|
@@ -41,14 +41,14 @@ export type WebTypesAttribute = {
|
|
|
41
41
|
value: WebTypesValue;
|
|
42
42
|
required?: boolean;
|
|
43
43
|
};
|
|
44
|
-
|
|
44
|
+
type WebTypesSlot = {
|
|
45
45
|
name?: string;
|
|
46
46
|
description?: string;
|
|
47
47
|
};
|
|
48
|
-
|
|
48
|
+
type WebTypesValue = {
|
|
49
49
|
type?: string[] | string;
|
|
50
50
|
};
|
|
51
|
-
|
|
51
|
+
type WebTypesJsProperties = {
|
|
52
52
|
properties: WebTypesJsProperty[];
|
|
53
53
|
events: WebTypesEvent[];
|
|
54
54
|
};
|
|
@@ -74,3 +74,4 @@ export type WebTypesCssProperty = {
|
|
|
74
74
|
name: string;
|
|
75
75
|
description?: string;
|
|
76
76
|
};
|
|
77
|
+
export {};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export declare const customElementEntrypointName = "customElement.js";
|
|
2
|
-
export declare const customElementDtsFileName = "customElement.d.ts";
|
|
3
2
|
export type CustomElementInterdependencies = Record<string, {
|
|
4
3
|
/**
|
|
5
4
|
* All local or foreign custom elements referenced in current file.
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { path } from '@arcgis/components-build-utils';
|
|
2
2
|
import { CompilerContext } from '../context/index.ts';
|
|
3
|
-
export declare const rePath: RegExp;
|
|
4
3
|
/**
|
|
5
4
|
* Rewrite references to `./components/component-folder-name/component-file-name.js` with
|
|
6
5
|
* `./components/component-tag-name/customElement.js` in `.js` and `.d.ts` files.
|