@hia-doc/profiles 0.1.0 → 1.0.0-rc.2

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/README.md CHANGED
@@ -1,8 +1,19 @@
1
1
  # @hia-doc/profiles
2
2
 
3
- Official documentation profile distribution for HIA documentation tools.
3
+ ## 1.0.0 source candidate
4
4
 
5
- The package contains the stable and bridge profile JSON files proven by the main repository release gate. It is separate from `@hia-doc/profile`, which owns profile loading, validation and registry queries.
5
+ This source tree targets a coordinated 1.0.0 package candidate. It does not
6
+ announce npm availability. See the [package migration guide](../../docs/package-v1-migration.md)
7
+ for matching dependencies, artifact versions and source compatibility.
8
+
9
+ 中文:当前为1.0.0源码候选,实际发布及工件版本请分别核对迁移说明。
10
+
11
+
12
+ Official documentation profile JSON, catalog metadata and defensive-copy accessors. Profile accessors and separately created runtime sets return independent profile copies. Catalog constants, the literal ID array and direct JSON module exports remain shared, unfrozen metadata and should be treated as read-only.
13
+
14
+ The bundled profile schema, catalog and individual profile versions remain `0.1.0-draft`; the `stable` layer name does not itself establish a stable release. Runtime inheritance/alias errors are reported through profile-set diagnostics. See [distribution and version boundaries](../../docs/profile-distribution.md) and [composition limits](../../docs/profile-composition.md).
15
+
16
+ The package is separate from `@hia-doc/profile`, which owns profile loading, validation and registry queries.
6
17
 
7
18
  ## API
8
19
 
@@ -29,8 +40,36 @@ import catalog from "@hia-doc/profiles/catalog.json" with { type: "json" };
29
40
  import cssdoc from "@hia-doc/profiles/cssdoc.profile.json" with { type: "json" };
30
41
  ```
31
42
 
32
- The distributed files use `documentation-profile@0.1.0-draft`. Profile contract versions are independent from the npm package version.
43
+ The distributed files use `documentation-profile@0.1.0-draft`. The runtime now exposes a separate `1.0.0` source schema candidate and retains an exact legacy reader; it does not rewrite these files. Domain-profile, schema, catalog and npm versions remain independent.
44
+
45
+ ## Explicit TypeScript project profile
46
+
47
+ The generic TypeScript project chain has an independent `ts-jsdoc-bridge@0.2.0-draft` profile using the already supported `documentation-profile@1.0.0` structure. It declares extraction/bridge `0.2.0-draft`, HIA core document `0.2.0` and direct documentation source map `1.1.0`. Actual types and members remain visible. It does not claim JavaScript emission, native JSDoc execution or ordinary-map coordinate evidence.
48
+
49
+ ```ts
50
+ import {
51
+ getOfficialTsDocProjectProfile,
52
+ createOfficialTsDocProjectProfileSet,
53
+ HIA_TSDOC_PROJECT_PROFILE_CATALOG
54
+ } from "@hia-doc/profiles";
55
+ ```
56
+
57
+ The first two functions return independent data. The explicit set selects the new TS profile and keeps the six original parent/peer versions. Existing getters, default sets and `catalog.json` retain their seven original profiles. A runtime set still admits only one version per identity; select the version before creating a set. Catalog constants and JSON imports remain shared metadata.
58
+
59
+ Explicit JSON subpaths are `@hia-doc/profiles/ts-jsdoc-bridge/0.2.0-draft.profile.json` and `@hia-doc/profiles/tsdoc-project/catalog.json`. The new catalog retains the existing catalog shape/version and describes only the new profile's schema. Neither a new profile nor the stable wire structure establishes a published npm package or stable domain-profile semantics.
33
60
 
34
61
  ## Status
35
62
 
36
- This workspace package is not yet a public npm release. The canonical `@hia-doc` scope and MIT license are approved; publication still requires operational npm scope ownership, stable owner/distribution package versions, Trusted Publishing ownership and a registry install smoke.
63
+ The manifest is publishable. Source changes and local tarballs do not prove registry availability or stable-release qualification. Publication requires approved release versions, npm scope ownership, Trusted Publishing ownership and a registry install smoke. The package uses the MIT license.
64
+
65
+ ## Structured TypeScript projects
66
+
67
+ Select getOfficialTsDocProjectProfile('0.3.0-draft') or createOfficialTsDocProjectProfileSet('0.3.0-draft') for structured type expressions. Omitted versions still select 0.2. The separate HIA_TSDOC_STRUCTURED_PROJECT_PROFILE_CATALOG and JSON subpaths ./ts-jsdoc-bridge/0.3.0-draft.profile.json and ./tsdoc-project/0.3.0-draft/catalog.json expose the new profile. Each set has one exact version per identity.
68
+
69
+ 中文说明。0.3规范与目录须显式读取,原七规范默认和0.2项目目录保留。类型结构不意味着执行权限或发射证明。
70
+
71
+ ## Generic and array type wrappers
72
+
73
+ Explicitly select `getOfficialTsDocProjectProfile('0.4.0-draft')` or `createOfficialTsDocProjectProfileSet('0.4.0-draft')` for generic applications, array elements and `readonly` operands. `HIA_TSDOC_WRAPPED_PROJECT_PROFILE_CATALOG`, `./ts-jsdoc-bridge/0.4.0-draft.profile.json` and `./tsdoc-project/0.4.0-draft/catalog.json` describe this exact profile. Target names record source syntax. Generic evaluation, inherited-member expansion and runtime identity remain outside this model.
74
+
75
+ 中文说明。0.4 须显式选择,保留泛型目标与实参顺序、数组元素及 `readonly` 操作数。默认仍为 0.2,0.3 的读取与拒绝边界保持。详见主仓 `docs/sdk-type-wrappers.md`。
package/dist/index.d.ts CHANGED
@@ -1,21 +1,122 @@
1
1
  import type { HiaDocumentationProfile, HiaProfileLayer, HiaProfileSet } from "@hia-doc/profile";
2
+ /**
3
+ * @lang zh-CN 目录形状的版本,与npm版本和每份规范语义版本独立。
4
+ * @lang en Catalog-shape version, independent of npm and individual profile semantic versions.
5
+ */
2
6
  export declare const HIA_OFFICIAL_PROFILE_CATALOG_VERSION = "0.1.0-draft";
7
+ /**
8
+ * @lang zh-CN 随包七份JSON实际使用的schema身份,不追随runtime未来默认版本。
9
+ * @lang en Schema identity actually used by the seven bundled JSON files, independent of future runtime defaults.
10
+ */
3
11
  export declare const HIA_OFFICIAL_PROFILE_SCHEMA_VERSION = "0.1.0-draft";
12
+ /**
13
+ * @lang zh-CN 官方身份的字面类型与固定列出顺序;调用者应只读使用,运行时未冻结数组。
14
+ * @lang en Literal official identities and fixed listing order; callers must treat this array as read-only, as it is not frozen at runtime.
15
+ */
4
16
  export declare const HIA_OFFICIAL_PROFILE_IDS: readonly ["cssdoc", "doc-source-map", "htmdoc", "jsdoc", "pug-htmdoc-bridge", "sass-cssdoc-bridge", "ts-jsdoc-bridge"];
17
+ /**
18
+ * @lang zh-CN 七个官方身份的闭集;访问器另允许string查询未知身份并返回undefined。
19
+ * @lang en Closed set of seven official identities; accessors separately allow string queries and return undefined for unknown identities.
20
+ */
5
21
  export type HiaOfficialProfileId = typeof HIA_OFFICIAL_PROFILE_IDS[number];
22
+ /**
23
+ * @lang zh-CN 目录中的一条元数据引用,不自动加载文件、解析版本范围或授予公开权限。
24
+ * @lang en One catalog metadata reference, without automatic file loading, version-range resolution or disclosure permission.
25
+ */
6
26
  export interface HiaOfficialProfileCatalogEntry {
27
+ /**
28
+ * @lang zh-CN 声明的语义分层,不自动决定继承优先级。
29
+ * @lang en Declared semantic layer, without automatic inheritance precedence.
30
+ */
7
31
  layer: HiaProfileLayer;
32
+ /**
33
+ * @lang zh-CN 相对于包目录的显式JSON导出位置;不是URL抓取指令。
34
+ * @lang en Explicit JSON export location relative to the package catalog, not a URL-fetch instruction.
35
+ */
8
36
  path: string;
37
+ /**
38
+ * @lang zh-CN 精确官方身份。
39
+ * @lang en Exact official identity.
40
+ */
9
41
  profileId: HiaOfficialProfileId;
42
+ /**
43
+ * @lang zh-CN 单份规范的语义版本,不等于schema/catalog/npm版本。
44
+ * @lang en Individual profile semantic version, distinct from schema/catalog/npm versions.
45
+ */
10
46
  profileVersion: string;
11
47
  }
48
+ /**
49
+ * @lang zh-CN 官方目录的静态类型视图,不是已执行校验或注册表发布证明。
50
+ * @lang en Static type view of the official catalog, not proof of executed validation or registry publication.
51
+ */
12
52
  export interface HiaOfficialProfileCatalog {
53
+ /**
54
+ * @lang zh-CN 目录形状版本。
55
+ * @lang en Catalog-shape version.
56
+ */
13
57
  catalogVersion: string;
58
+ /**
59
+ * @lang zh-CN 此目录内配置使用的文档化配置规范schema版本。
60
+ * @lang en Documentation-profile schema version used by this catalog's profiles.
61
+ */
14
62
  profileSchemaVersion: string;
63
+ /**
64
+ * @lang zh-CN 按官方顺序列出的引用;目录元数据共享,调用者不应直接修改。
65
+ * @lang en References in official order; catalog metadata is shared and callers must not mutate it directly.
66
+ */
15
67
  profiles: HiaOfficialProfileCatalogEntry[];
16
68
  }
69
+ /**
70
+ * @lang zh-CN 共享且未冻结的目录对象,与catalog.json导出共享模块数据;调用者须只读使用或自行复制。
71
+ * @lang en Shared, unfrozen catalog object using the catalog.json module data; callers must treat it as read-only or clone it themselves.
72
+ */
17
73
  export declare const HIA_OFFICIAL_PROFILE_CATALOG: HiaOfficialProfileCatalog;
74
+ /**
75
+ * @lang zh-CN 显式项目规范目录;形状版本不变,schema版本仅描述该目录的一份新规范。共享元数据须只读使用。
76
+ * @lang en Explicit project profile catalog; its shape version is unchanged and schema version describes its one new profile. Treat shared metadata as read-only.
77
+ */
78
+ export declare const HIA_TSDOC_PROJECT_PROFILE_CATALOG: HiaOfficialProfileCatalog;
79
+ /**
80
+ * @lang zh-CN 显式0.3类型表达式目录,独立于原项目目录和七份默认规范。
81
+ * @lang en Explicit 0.3 type-expression catalog, separate from the original project catalog and seven default profiles.
82
+ */
83
+ export declare const HIA_TSDOC_STRUCTURED_PROJECT_PROFILE_CATALOG: HiaOfficialProfileCatalog;
84
+ /**
85
+ * @lang zh-CN 显式0.4泛型/数组包装目录,独立于旧版默认及目录。
86
+ * @lang en Explicit 0.4 generic/array wrapper catalog, independent of legacy defaults and catalogs.
87
+ */
88
+ export declare const HIA_TSDOC_WRAPPED_PROJECT_PROFILE_CATALOG: HiaOfficialProfileCatalog;
89
+ /**
90
+ * @lang zh-CN 按精确版本取得TypeScript项目桥接独立副本,省略仍为0.2,不推断任意版本。
91
+ * @lang en Gets an independent TypeScript project bridge by exact version, defaulting to 0.2 without inferring arbitrary versions.
92
+ * @param version <lang><zh-CN>精确0.2、0.3或0.4身份,省略使用0.2。</zh-CN><en>Exact 0.2, 0.3 or 0.4 identity, defaulting to 0.2.</en></lang>
93
+ * @returns <lang><zh-CN>使用已确认1.0结构的选定草案规范副本;不授予执行/源码公开许可。</zh-CN><en>The selected draft profile copy using the confirmed 1.0 structure, without execution/source-publication permission.</en></lang>
94
+ */
95
+ export declare function getOfficialTsDocProjectProfile(version?: "0.2.0-draft" | "0.3.0-draft" | "0.4.0-draft"): HiaDocumentationProfile;
96
+ /**
97
+ * @lang zh-CN 显式为项目链组装规范集合,仅替换旧TS项;六份原父/同级规范保持精确版本。
98
+ * @lang en Explicitly assemble a project-chain profile set, replacing only the legacy TS entry while retaining the six original parent/peer versions.
99
+ * @param version <lang><zh-CN>精确项目版本,省略保留0.2选择。</zh-CN><en>Exact project version, preserving 0.2 selection when omitted.</en></lang>
100
+ * @returns <lang><zh-CN>独立集合和诊断;同一集合每身份仍只有一版,不自动切换现有项目。</zh-CN><en>An independent set and diagnostics; each identity still has one version per set and existing projects are not switched automatically.</en></lang>
101
+ */
102
+ export declare function createOfficialTsDocProjectProfileSet(version?: "0.2.0-draft" | "0.3.0-draft" | "0.4.0-draft"): HiaProfileSet;
103
+ /**
104
+ * @lang zh-CN 按官方固定顺序列出七份配置,不解析继承或选择默认配置。
105
+ * @lang en Lists seven profiles in fixed official order without resolving inheritance or choosing a default profile.
106
+ * @returns <lang><zh-CN>新数组及每份配置的独立深拷贝;不访问文件系统/网络。</zh-CN><en>A new array of independent deep copies, without filesystem or network access.</en></lang>
107
+ */
18
108
  export declare function listOfficialHiaProfiles(): HiaDocumentationProfile[];
109
+ /**
110
+ * @lang zh-CN 按精确官方身份读取独立配置副本,不按大小写、路径或版本范围猜测。
111
+ * @lang en Reads an independent profile copy by exact official identity without case, path or version-range inference.
112
+ * @param profileId <lang><zh-CN>官方身份或任意string;未知值不回退到默认配置。</zh-CN><en>Official identity or arbitrary string; unknown values do not fall back to a default profile.</en></lang>
113
+ * @returns <lang><zh-CN>深拷贝或undefined;不解析继承、不执行规则、不写回包数据。</zh-CN><en>A deep copy or undefined, without resolving inheritance, executing rules or writing package data.</en></lang>
114
+ */
19
115
  export declare function getOfficialHiaProfile(profileId: HiaOfficialProfileId | string): HiaDocumentationProfile | undefined;
116
+ /**
117
+ * @lang zh-CN 从七份全新副本创建运行时集合,保留runtime诊断供调用者检查。
118
+ * @lang en Creates a runtime set from seven fresh copies, retaining runtime diagnostics for caller inspection.
119
+ * @returns <lang><zh-CN>新Map/配置副本/诊断数组;不自动采用到项目或保证所有草案语义已稳定。</zh-CN><en>New Map/profile copies/diagnostics, without automatic project adoption or guarantees that all draft semantics are stable.</en></lang>
120
+ */
20
121
  export declare function createOfficialHiaProfileSet(): HiaProfileSet;
21
122
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,uBAAuB,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEhG,eAAO,MAAM,oCAAoC,gBAAgB,CAAC;AAClE,eAAO,MAAM,mCAAmC,gBAAgB,CAAC;AACjE,eAAO,MAAM,wBAAwB,wHAQ3B,CAAC;AAEX,MAAM,MAAM,oBAAoB,GAAG,OAAO,wBAAwB,CAAC,MAAM,CAAC,CAAC;AAE3E,MAAM,WAAW,8BAA8B;IAC7C,KAAK,EAAE,eAAe,CAAC;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,oBAAoB,CAAC;IAChC,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,yBAAyB;IACxC,cAAc,EAAE,MAAM,CAAC;IACvB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,QAAQ,EAAE,8BAA8B,EAAE,CAAC;CAC5C;AAgBD,eAAO,MAAM,4BAA4B,EAAkB,yBAAyB,CAAC;AAErF,wBAAgB,uBAAuB,IAAI,uBAAuB,EAAE,CAEnE;AAED,wBAAgB,qBAAqB,CAAC,SAAS,EAAE,oBAAoB,GAAG,MAAM,GAAG,uBAAuB,GAAG,SAAS,CAGnH;AAED,wBAAgB,2BAA2B,IAAI,aAAa,CAE3D"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAoBA,OAAO,KAAK,EAAE,uBAAuB,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEhG;;;GAGG;AACH,e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GAAG,MAAM,GAAG,uBAAuB,GAAG,SAAS,CAInH;AAED;;;;GAIG;AACH,wBAAgB,2BAA2B,IAAI,aAAa,CAE3D"}
package/dist/index.js CHANGED
@@ -1,3 +1,8 @@
1
+ /**
2
+ * @file
3
+ * @lang zh-CN 七份默认规范及显式TypeScript项目版本的分发入口;访问器复制配置,目录常量/直接JSON导出是共享元数据。
4
+ * @lang en Distribution entry for seven default profiles and an explicit TypeScript project version; accessors copy profiles while catalogs/direct JSON exports are shared metadata.
5
+ */
1
6
  import catalogData from "./catalog.json" with { type: "json" };
2
7
  import cssdocProfileData from "./profiles/cssdoc.profile.json" with { type: "json" };
3
8
  import docSourceMapProfileData from "./profiles/doc-source-map.profile.json" with { type: "json" };
@@ -6,9 +11,27 @@ import jsdocProfileData from "./profiles/jsdoc.profile.json" with { type: "json"
6
11
  import pugHtmdocBridgeProfileData from "./profiles/pug-htmdoc-bridge.profile.json" with { type: "json" };
7
12
  import sassCssdocBridgeProfileData from "./profiles/sass-cssdoc-bridge.profile.json" with { type: "json" };
8
13
  import tsJsdocBridgeProfileData from "./profiles/ts-jsdoc-bridge.profile.json" with { type: "json" };
14
+ import tsDocProjectProfileData from "./profiles/versioned/ts-jsdoc-bridge-0.2.0-draft.profile.json" with { type: "json" };
15
+ import tsDocProjectCatalogData from "./tsdoc-project-catalog.json" with { type: "json" };
16
+ import tsDocStructuredProfileData from "./profiles/versioned/ts-jsdoc-bridge-0.3.0-draft.profile.json" with { type: "json" };
17
+ import tsDocStructuredCatalogData from "./tsdoc-structured-project-catalog.json" with { type: "json" };
18
+ import tsDocWrappedProfileData from "./profiles/versioned/ts-jsdoc-bridge-0.4.0-draft.profile.json" with { type: "json" };
19
+ import tsDocWrappedCatalogData from "./tsdoc-wrapped-project-catalog.json" with { type: "json" };
9
20
  import { createHiaProfileSet } from "@hia-doc/profile";
21
+ /**
22
+ * @lang zh-CN 目录形状的版本,与npm版本和每份规范语义版本独立。
23
+ * @lang en Catalog-shape version, independent of npm and individual profile semantic versions.
24
+ */
10
25
  export const HIA_OFFICIAL_PROFILE_CATALOG_VERSION = "0.1.0-draft";
26
+ /**
27
+ * @lang zh-CN 随包七份JSON实际使用的schema身份,不追随runtime未来默认版本。
28
+ * @lang en Schema identity actually used by the seven bundled JSON files, independent of future runtime defaults.
29
+ */
11
30
  export const HIA_OFFICIAL_PROFILE_SCHEMA_VERSION = "0.1.0-draft";
31
+ /**
32
+ * @lang zh-CN 官方身份的字面类型与固定列出顺序;调用者应只读使用,运行时未冻结数组。
33
+ * @lang en Literal official identities and fixed listing order; callers must treat this array as read-only, as it is not frozen at runtime.
34
+ */
12
35
  export const HIA_OFFICIAL_PROFILE_IDS = [
13
36
  "cssdoc",
14
37
  "doc-source-map",
@@ -18,6 +41,7 @@ export const HIA_OFFICIAL_PROFILE_IDS = [
18
41
  "sass-cssdoc-bridge",
19
42
  "ts-jsdoc-bridge"
20
43
  ];
44
+ // <lang><zh-CN>固定JSON模块构成分发数据源,不扫描workspace、抓取网络或自动选择项目规范。</zh-CN><en>Fixed JSON modules form distribution data, without workspace scanning, network fetching or automatic project-profile selection.</en></lang>
21
45
  const officialProfiles = [
22
46
  cssdocProfileData,
23
47
  docSourceMapProfileData,
@@ -27,18 +51,82 @@ const officialProfiles = [
27
51
  sassCssdocBridgeProfileData,
28
52
  tsJsdocBridgeProfileData
29
53
  ];
54
+ // <lang><zh-CN>字面身份Map避免constructor/__proto__原型命中,注册时不改写JSON字段。</zh-CN><en>A literal-identity Map avoids constructor/__proto__ prototype hits without rewriting JSON fields during registration.</en></lang>
30
55
  const officialProfileById = new Map(officialProfiles.map((profile) => [profile.profileId, profile]));
56
+ /**
57
+ * @lang zh-CN 共享且未冻结的目录对象,与catalog.json导出共享模块数据;调用者须只读使用或自行复制。
58
+ * @lang en Shared, unfrozen catalog object using the catalog.json module data; callers must treat it as read-only or clone it themselves.
59
+ */
31
60
  export const HIA_OFFICIAL_PROFILE_CATALOG = catalogData;
61
+ /**
62
+ * @lang zh-CN 显式项目规范目录;形状版本不变,schema版本仅描述该目录的一份新规范。共享元数据须只读使用。
63
+ * @lang en Explicit project profile catalog; its shape version is unchanged and schema version describes its one new profile. Treat shared metadata as read-only.
64
+ */
65
+ export const HIA_TSDOC_PROJECT_PROFILE_CATALOG = tsDocProjectCatalogData;
66
+ /**
67
+ * @lang zh-CN 显式0.3类型表达式目录,独立于原项目目录和七份默认规范。
68
+ * @lang en Explicit 0.3 type-expression catalog, separate from the original project catalog and seven default profiles.
69
+ */
70
+ export const HIA_TSDOC_STRUCTURED_PROJECT_PROFILE_CATALOG = tsDocStructuredCatalogData;
71
+ /**
72
+ * @lang zh-CN 显式0.4泛型/数组包装目录,独立于旧版默认及目录。
73
+ * @lang en Explicit 0.4 generic/array wrapper catalog, independent of legacy defaults and catalogs.
74
+ */
75
+ export const HIA_TSDOC_WRAPPED_PROJECT_PROFILE_CATALOG = tsDocWrappedCatalogData;
76
+ /**
77
+ * @lang zh-CN 按精确版本取得TypeScript项目桥接独立副本,省略仍为0.2,不推断任意版本。
78
+ * @lang en Gets an independent TypeScript project bridge by exact version, defaulting to 0.2 without inferring arbitrary versions.
79
+ * @param version <lang><zh-CN>精确0.2、0.3或0.4身份,省略使用0.2。</zh-CN><en>Exact 0.2, 0.3 or 0.4 identity, defaulting to 0.2.</en></lang>
80
+ * @returns <lang><zh-CN>使用已确认1.0结构的选定草案规范副本;不授予执行/源码公开许可。</zh-CN><en>The selected draft profile copy using the confirmed 1.0 structure, without execution/source-publication permission.</en></lang>
81
+ */
82
+ export function getOfficialTsDocProjectProfile(version = "0.2.0-draft") {
83
+ if (version !== "0.2.0-draft" && version !== "0.3.0-draft" && version !== "0.4.0-draft")
84
+ throw new Error("Unsupported TypeScript project profile version.");
85
+ const profile = version === "0.4.0-draft" ? tsDocWrappedProfileData : version === "0.3.0-draft" ? tsDocStructuredProfileData : tsDocProjectProfileData;
86
+ return structuredClone(profile);
87
+ }
88
+ /**
89
+ * @lang zh-CN 显式为项目链组装规范集合,仅替换旧TS项;六份原父/同级规范保持精确版本。
90
+ * @lang en Explicitly assemble a project-chain profile set, replacing only the legacy TS entry while retaining the six original parent/peer versions.
91
+ * @param version <lang><zh-CN>精确项目版本,省略保留0.2选择。</zh-CN><en>Exact project version, preserving 0.2 selection when omitted.</en></lang>
92
+ * @returns <lang><zh-CN>独立集合和诊断;同一集合每身份仍只有一版,不自动切换现有项目。</zh-CN><en>An independent set and diagnostics; each identity still has one version per set and existing projects are not switched automatically.</en></lang>
93
+ */
94
+ export function createOfficialTsDocProjectProfileSet(version = "0.2.0-draft") {
95
+ // <lang><zh-CN>先取旧分发的独立副本,在送入原runtime前明确选择新TS版本,不修改包内数据或运行时选择规则。</zh-CN><en>Start from defensive legacy copies and select the new TS version before invoking the existing runtime, without mutating package data or selection rules.</en></lang>
96
+ const profiles = listOfficialHiaProfiles().map((profile) => profile.profileId === "ts-jsdoc-bridge" ? getOfficialTsDocProjectProfile(version) : profile);
97
+ return createHiaProfileSet({ profiles });
98
+ }
99
+ /**
100
+ * @lang zh-CN 按官方固定顺序列出七份配置,不解析继承或选择默认配置。
101
+ * @lang en Lists seven profiles in fixed official order without resolving inheritance or choosing a default profile.
102
+ * @returns <lang><zh-CN>新数组及每份配置的独立深拷贝;不访问文件系统/网络。</zh-CN><en>A new array of independent deep copies, without filesystem or network access.</en></lang>
103
+ */
32
104
  export function listOfficialHiaProfiles() {
33
105
  return officialProfiles.map(cloneProfile);
34
106
  }
107
+ /**
108
+ * @lang zh-CN 按精确官方身份读取独立配置副本,不按大小写、路径或版本范围猜测。
109
+ * @lang en Reads an independent profile copy by exact official identity without case, path or version-range inference.
110
+ * @param profileId <lang><zh-CN>官方身份或任意string;未知值不回退到默认配置。</zh-CN><en>Official identity or arbitrary string; unknown values do not fall back to a default profile.</en></lang>
111
+ * @returns <lang><zh-CN>深拷贝或undefined;不解析继承、不执行规则、不写回包数据。</zh-CN><en>A deep copy or undefined, without resolving inheritance, executing rules or writing package data.</en></lang>
112
+ */
35
113
  export function getOfficialHiaProfile(profileId) {
114
+ // <lang><zh-CN>静态身份断言只用于Map键类型,不让任意string成为已知官方身份。</zh-CN><en>The static identity cast serves only the Map key type and does not make arbitrary strings known official identities.</en></lang>
36
115
  const profile = officialProfileById.get(profileId);
37
116
  return profile ? cloneProfile(profile) : undefined;
38
117
  }
118
+ /**
119
+ * @lang zh-CN 从七份全新副本创建运行时集合,保留runtime诊断供调用者检查。
120
+ * @lang en Creates a runtime set from seven fresh copies, retaining runtime diagnostics for caller inspection.
121
+ * @returns <lang><zh-CN>新Map/配置副本/诊断数组;不自动采用到项目或保证所有草案语义已稳定。</zh-CN><en>New Map/profile copies/diagnostics, without automatic project adoption or guarantees that all draft semantics are stable.</en></lang>
122
+ */
39
123
  export function createOfficialHiaProfileSet() {
40
124
  return createHiaProfileSet({ profiles: listOfficialHiaProfiles() });
41
125
  }
126
+ /**
127
+ * @lang zh-CN 复制包内普通JSON配置,访问器修改不影响下一次访问;直接JSON导入仍须只读使用。
128
+ * @lang en Clones package JSON profiles so accessor mutations do not affect subsequent calls; direct JSON imports still require read-only use.
129
+ */
42
130
  function cloneProfile(profile) {
43
131
  return structuredClone(profile);
44
132
  }
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,gBAAgB,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAC/D,OAAO,iBAAiB,MAAM,gCAAgC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACrF,OAAO,uBAAuB,MAAM,wCAAwC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACnG,OAAO,iBAAiB,MAAM,gCAAgC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACrF,OAAO,gBAAgB,MAAM,+BAA+B,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACnF,OAAO,0BAA0B,M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displayName": "TypeScript Project Documentation Bridge",
6
+ "layer": "bridge",
7
+ "extends": ["jsdoc", "doc-source-map"],
8
+ "contracts": [
9
+ { "name": "hia-tsdoc-extraction", "version": "0.2.0-draft", "role": "consumes" },
10
+ { "name": "hia-ts-jsdoc-bridge", "version": "0.2.0-draft", "role": "produces" },
11
+ { "name": "hia-core-document", "version": "0.2.0", "role": "produces" },
12
+ { "name": "doc-source-map", "version": "1.1.0", "role": "produces" }
13
+ ],
14
+ "targets": ["typescript-source", "typescript-symbol", "tsdoc-extraction", "ts-jsdoc-bridge", "hia-document", "doc-source-map-manifest"],
15
+ "tags": [
16
+ {
17
+ "name": "typeParam", "status": "experimental", "scope": ["block"],
18
+ "targets": ["typescript-symbol"], "repeatable": true,
19
+ "valueGrammar": "type-parameter-name [description]",
20
+ "mapsTo": { "field": "i18n.fields", "fieldPathPattern": "typeParams.<name>.description" },
21
+ "metadata": { "documentation": { "zh-CN": "保留真实类型参数文档及字段级语言,不执行类型代码。", "en": "Retain actual type-parameter documentation and field locales without executing type code." } }
22
+ }
23
+ ],
24
+ "rules": [
25
+ {
26
+ "ruleId": "ts-jsdoc/type-only-symbol-policy", "category": "bridge", "defaultSeverity": "info",
27
+ "optionsSchema": { "type": "object", "properties": { "typeOnlySymbolPolicy": { "const": "core-symbol" } }, "additionalProperties": false },
28
+ "appliesTo": ["typescript-symbol"],
29
+ "messages": { "default": "Actual project types and members remain visible as HIA symbols with original documentation and parentage.", "zh-CN": "项目真实类型与成员作为可见HIA符号保留原文档和父项。" },
30
+ "fixable": false, "hasSuggestions": false
31
+ },
32
+ {
33
+ "ruleId": "ts-jsdoc/project-emission-evidence", "category": "source-map", "defaultSeverity": "error",
34
+ "optionsSchema": { "type": "object", "additionalProperties": false },
35
+ "appliesTo": ["ts-jsdoc-bridge", "doc-source-map-manifest"],
36
+ "messages": { "default": "Project extraction has no JavaScript emission or ordinary-map evidence; preserve actual direct source linkage only.", "zh-CN": "项目提取没有JavaScript发射或普通地图证明,只保留实际直接源码关联。" },
37
+ "fixable": false, "hasSuggestions": false
38
+ }
39
+ ],
40
+ "mappings": [
41
+ {
42
+ "from": "typescript-symbol", "to": "hia-symbol", "conditions": ["supported-authorized-declaration"],
43
+ "confidence": "high", "sourcePolicy": "actual-typescript-ast-exclusive-utf16", "metadataPolicy": "preserve-full-fields-parent-and-public-entry", "diagnostics": []
44
+ },
45
+ {
46
+ "from": "typescript-symbol", "to": "ts-jsdoc-bridge-symbol", "conditions": ["supported-authorized-declaration"],
47
+ "confidence": "high", "sourcePolicy": "actual-typescript-ast-exclusive-utf16", "metadataPolicy": "preserve-full-fields-and-explicit-non-emission", "diagnostics": []
48
+ }
49
+ ],
50
+ "diagnostics": [],
51
+ "capabilities": {
52
+ "sourceMap": { "index": true, "locations": true },
53
+ "ordinarySourceMap": { "produces": false },
54
+ "nativeJsdocExecution": false,
55
+ "sourcesContentPolicy": "none",
56
+ "rangeConvention": { "endBoundary": "exclusive", "columnUnit": "utf16-code-unit" },
57
+ "documentation": { "zh-CN": "本规范描述已实现项目链的语义,不执行规则、不授予源码访问或声称产品/发行验收。", "en": "This profile describes implemented project-chain semantics without executing rules, granting source access, or claiming product/release acceptance." }
58
+ }
59
+ }
@@ -0,0 +1,163 @@
1
+ {
2
+ "schemaVersion": "1.0.0",
3
+ "profileId": "ts-jsdoc-bridge",
4
+ "profileVersion": "0.3.0-draft",
5
+ "displayName": "TypeScript Structured Project Documentation Bridge",
6
+ "layer": "bridge",
7
+ "extends": [
8
+ "jsdoc",
9
+ "doc-source-map"
10
+ ],
11
+ "contracts": [
12
+ {
13
+ "name": "hia-tsdoc-extraction",
14
+ "version": "0.3.0-draft",
15
+ "role": "consumes"
16
+ },
17
+ {
18
+ "name": "hia-ts-jsdoc-bridge",
19
+ "version": "0.3.0-draft",
20
+ "role": "produces"
21
+ },
22
+ {
23
+ "name": "hia-core-document",
24
+ "version": "0.2.0",
25
+ "role": "produces"
26
+ },
27
+ {
28
+ "name": "doc-source-map",
29
+ "version": "1.1.0",
30
+ "role": "produces"
31
+ }
32
+ ],
33
+ "targets": [
34
+ "typescript-source",
35
+ "typescript-symbol",
36
+ "tsdoc-extraction",
37
+ "ts-jsdoc-bridge",
38
+ "hia-document",
39
+ "doc-source-map-manifest"
40
+ ],
41
+ "tags": [
42
+ {
43
+ "name": "typeParam",
44
+ "status": "experimental",
45
+ "scope": [
46
+ "block"
47
+ ],
48
+ "targets": [
49
+ "typescript-symbol"
50
+ ],
51
+ "repeatable": true,
52
+ "valueGrammar": "type-parameter-name [description]",
53
+ "mapsTo": {
54
+ "field": "i18n.fields",
55
+ "fieldPathPattern": "typeParams.<name>.description"
56
+ },
57
+ "metadata": {
58
+ "documentation": {
59
+ "zh-CN": "保留真实类型参数文档及字段级语言,不执行类型代码。",
60
+ "en": "Retain actual type-parameter documentation and field locales without executing type code."
61
+ }
62
+ }
63
+ }
64
+ ],
65
+ "rules": [
66
+ {
67
+ "ruleId": "ts-jsdoc/type-only-symbol-policy",
68
+ "category": "bridge",
69
+ "defaultSeverity": "info",
70
+ "optionsSchema": {
71
+ "type": "object",
72
+ "properties": {
73
+ "typeOnlySymbolPolicy": {
74
+ "const": "core-symbol"
75
+ }
76
+ },
77
+ "additionalProperties": false
78
+ },
79
+ "appliesTo": [
80
+ "typescript-symbol"
81
+ ],
82
+ "messages": {
83
+ "default": "Actual project types and members remain visible as HIA symbols with original documentation and parentage.",
84
+ "zh-CN": "项目真实类型与成员作为可见HIA符号保留原文档和父项。"
85
+ },
86
+ "fixable": false,
87
+ "hasSuggestions": false
88
+ },
89
+ {
90
+ "ruleId": "ts-jsdoc/project-emission-evidence",
91
+ "category": "source-map",
92
+ "defaultSeverity": "error",
93
+ "optionsSchema": {
94
+ "type": "object",
95
+ "additionalProperties": false
96
+ },
97
+ "appliesTo": [
98
+ "ts-jsdoc-bridge",
99
+ "doc-source-map-manifest"
100
+ ],
101
+ "messages": {
102
+ "default": "Project extraction has no JavaScript emission or ordinary-map evidence; preserve actual direct source linkage only.",
103
+ "zh-CN": "项目提取没有JavaScript发射或普通地图证明,只保留实际直接源码关联。"
104
+ },
105
+ "fixable": false,
106
+ "hasSuggestions": false
107
+ }
108
+ ],
109
+ "mappings": [
110
+ {
111
+ "from": "typescript-symbol",
112
+ "to": "hia-symbol",
113
+ "conditions": [
114
+ "supported-authorized-declaration"
115
+ ],
116
+ "confidence": "high",
117
+ "sourcePolicy": "actual-typescript-ast-exclusive-utf16",
118
+ "metadataPolicy": "preserve-full-fields-parent-and-public-entry",
119
+ "diagnostics": []
120
+ },
121
+ {
122
+ "from": "typescript-symbol",
123
+ "to": "ts-jsdoc-bridge-symbol",
124
+ "conditions": [
125
+ "supported-authorized-declaration"
126
+ ],
127
+ "confidence": "high",
128
+ "sourcePolicy": "actual-typescript-ast-exclusive-utf16",
129
+ "metadataPolicy": "preserve-full-fields-and-explicit-non-emission",
130
+ "diagnostics": []
131
+ }
132
+ ],
133
+ "diagnostics": [],
134
+ "capabilities": {
135
+ "sourceMap": {
136
+ "index": true,
137
+ "locations": true
138
+ },
139
+ "ordinarySourceMap": {
140
+ "produces": false
141
+ },
142
+ "nativeJsdocExecution": false,
143
+ "sourcesContentPolicy": "none",
144
+ "rangeConvention": {
145
+ "endBoundary": "exclusive",
146
+ "columnUnit": "utf16-code-unit"
147
+ },
148
+ "documentation": {
149
+ "zh-CN": "本规范描述已实现项目链的语义,不执行规则、不授予源码访问或声称产品/发行验收。",
150
+ "en": "This profile describes implemented project-chain semantics without executing rules, granting source access, or claiming product/release acceptance."
151
+ },
152
+ "typeExpressions": {
153
+ "physicalMemberCoverage": "explicit-source-members",
154
+ "operators": [
155
+ "object",
156
+ "union",
157
+ "intersection",
158
+ "opaque"
159
+ ],
160
+ "branchIndex": "zero-based-source-order"
161
+ }
162
+ }
163
+ }
@@ -0,0 +1,168 @@
1
+ {
2
+ "schemaVersion": "1.0.0",
3
+ "profileId": "ts-jsdoc-bridge",
4
+ "profileVersion": "0.4.0-draft",
5
+ "displayName": "TypeScript Wrapped Type Documentation Bridge",
6
+ "layer": "bridge",
7
+ "extends": [
8
+ "jsdoc",
9
+ "doc-source-map"
10
+ ],
11
+ "contracts": [
12
+ {
13
+ "name": "hia-tsdoc-extraction",
14
+ "version": "0.4.0-draft",
15
+ "role": "consumes"
16
+ },
17
+ {
18
+ "name": "hia-ts-jsdoc-bridge",
19
+ "version": "0.4.0-draft",
20
+ "role": "produces"
21
+ },
22
+ {
23
+ "name": "hia-core-document",
24
+ "version": "0.2.0",
25
+ "role": "produces"
26
+ },
27
+ {
28
+ "name": "doc-source-map",
29
+ "version": "1.1.0",
30
+ "role": "produces"
31
+ }
32
+ ],
33
+ "targets": [
34
+ "typescript-source",
35
+ "typescript-symbol",
36
+ "tsdoc-extraction",
37
+ "ts-jsdoc-bridge",
38
+ "hia-document",
39
+ "doc-source-map-manifest"
40
+ ],
41
+ "tags": [
42
+ {
43
+ "name": "typeParam",
44
+ "status": "experimental",
45
+ "scope": [
46
+ "block"
47
+ ],
48
+ "targets": [
49
+ "typescript-symbol"
50
+ ],
51
+ "repeatable": true,
52
+ "valueGrammar": "type-parameter-name [description]",
53
+ "mapsTo": {
54
+ "field": "i18n.fields",
55
+ "fieldPathPattern": "typeParams.<name>.description"
56
+ },
57
+ "metadata": {
58
+ "documentation": {
59
+ "zh-CN": "保留真实类型参数文档及字段级语言,不执行类型代码。",
60
+ "en": "Retain actual type-parameter documentation and field locales without executing type code."
61
+ }
62
+ }
63
+ }
64
+ ],
65
+ "rules": [
66
+ {
67
+ "ruleId": "ts-jsdoc/type-only-symbol-policy",
68
+ "category": "bridge",
69
+ "defaultSeverity": "info",
70
+ "optionsSchema": {
71
+ "type": "object",
72
+ "properties": {
73
+ "typeOnlySymbolPolicy": {
74
+ "const": "core-symbol"
75
+ }
76
+ },
77
+ "additionalProperties": false
78
+ },
79
+ "appliesTo": [
80
+ "typescript-symbol"
81
+ ],
82
+ "messages": {
83
+ "default": "Actual project types and members remain visible as HIA symbols with original documentation and parentage.",
84
+ "zh-CN": "项目真实类型与成员作为可见HIA符号保留原文档和父项。"
85
+ },
86
+ "fixable": false,
87
+ "hasSuggestions": false
88
+ },
89
+ {
90
+ "ruleId": "ts-jsdoc/project-emission-evidence",
91
+ "category": "source-map",
92
+ "defaultSeverity": "error",
93
+ "optionsSchema": {
94
+ "type": "object",
95
+ "additionalProperties": false
96
+ },
97
+ "appliesTo": [
98
+ "ts-jsdoc-bridge",
99
+ "doc-source-map-manifest"
100
+ ],
101
+ "messages": {
102
+ "default": "Project extraction has no JavaScript emission or ordinary-map evidence; preserve actual direct source linkage only.",
103
+ "zh-CN": "项目提取没有JavaScript发射或普通地图证明,只保留实际直接源码关联。"
104
+ },
105
+ "fixable": false,
106
+ "hasSuggestions": false
107
+ }
108
+ ],
109
+ "mappings": [
110
+ {
111
+ "from": "typescript-symbol",
112
+ "to": "hia-symbol",
113
+ "conditions": [
114
+ "supported-authorized-declaration"
115
+ ],
116
+ "confidence": "high",
117
+ "sourcePolicy": "actual-typescript-ast-exclusive-utf16",
118
+ "metadataPolicy": "preserve-full-fields-parent-and-public-entry",
119
+ "diagnostics": []
120
+ },
121
+ {
122
+ "from": "typescript-symbol",
123
+ "to": "ts-jsdoc-bridge-symbol",
124
+ "conditions": [
125
+ "supported-authorized-declaration"
126
+ ],
127
+ "confidence": "high",
128
+ "sourcePolicy": "actual-typescript-ast-exclusive-utf16",
129
+ "metadataPolicy": "preserve-full-fields-and-explicit-non-emission",
130
+ "diagnostics": []
131
+ }
132
+ ],
133
+ "diagnostics": [],
134
+ "capabilities": {
135
+ "sourceMap": {
136
+ "index": true,
137
+ "locations": true
138
+ },
139
+ "ordinarySourceMap": {
140
+ "produces": false
141
+ },
142
+ "nativeJsdocExecution": false,
143
+ "sourcesContentPolicy": "none",
144
+ "rangeConvention": {
145
+ "endBoundary": "exclusive",
146
+ "columnUnit": "utf16-code-unit"
147
+ },
148
+ "documentation": {
149
+ "zh-CN": "本规范描述已实现项目链的语义,不执行规则、不授予源码访问或声称产品/发行验收。",
150
+ "en": "This profile describes implemented project-chain semantics without executing rules, granting source access, or claiming product/release acceptance."
151
+ },
152
+ "typeExpressions": {
153
+ "physicalMemberCoverage": "explicit-source-members",
154
+ "operators": [
155
+ "object",
156
+ "union",
157
+ "intersection",
158
+ "opaque",
159
+ "application",
160
+ "array",
161
+ "type-operator"
162
+ ],
163
+ "branchIndex": "zero-based-source-order",
164
+ "argumentIndex": "zero-based-source-order",
165
+ "genericTarget": "lexical-reference"
166
+ }
167
+ }
168
+ }
@@ -0,0 +1,12 @@
1
+ {
2
+ "catalogVersion": "0.1.0-draft",
3
+ "profileSchemaVersion": "1.0.0",
4
+ "profiles": [
5
+ {
6
+ "profileId": "ts-jsdoc-bridge",
7
+ "profileVersion": "0.2.0-draft",
8
+ "layer": "bridge",
9
+ "path": "./ts-jsdoc-bridge/0.2.0-draft.profile.json"
10
+ }
11
+ ]
12
+ }
@@ -0,0 +1,12 @@
1
+ {
2
+ "catalogVersion": "0.1.0-draft",
3
+ "profileSchemaVersion": "1.0.0",
4
+ "profiles": [
5
+ {
6
+ "profileId": "ts-jsdoc-bridge",
7
+ "profileVersion": "0.3.0-draft",
8
+ "layer": "bridge",
9
+ "path": "./ts-jsdoc-bridge/0.3.0-draft.profile.json"
10
+ }
11
+ ]
12
+ }
@@ -0,0 +1,12 @@
1
+ {
2
+ "catalogVersion": "0.1.0-draft",
3
+ "profileSchemaVersion": "1.0.0",
4
+ "profiles": [
5
+ {
6
+ "profileId": "ts-jsdoc-bridge",
7
+ "profileVersion": "0.4.0-draft",
8
+ "layer": "bridge",
9
+ "path": "./ts-jsdoc-bridge/0.4.0-draft.profile.json"
10
+ }
11
+ ]
12
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hia-doc/profiles",
3
- "version": "0.1.0",
3
+ "version": "1.0.0-rc.2",
4
4
  "description": "Official documentation profile distribution for HIA documentation tools.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -9,7 +9,7 @@
9
9
  "directory": "packages/profiles"
10
10
  },
11
11
  "engines": {
12
- "node": ">=20.19.0"
12
+ "node": "^22.23.4 || ^24.22.1"
13
13
  },
14
14
  "type": "module",
15
15
  "main": "./dist/index.js",
@@ -27,6 +27,12 @@
27
27
  "./pug-htmdoc-bridge.profile.json": "./dist/profiles/pug-htmdoc-bridge.profile.json",
28
28
  "./sass-cssdoc-bridge.profile.json": "./dist/profiles/sass-cssdoc-bridge.profile.json",
29
29
  "./ts-jsdoc-bridge.profile.json": "./dist/profiles/ts-jsdoc-bridge.profile.json",
30
+ "./ts-jsdoc-bridge/0.2.0-draft.profile.json": "./dist/profiles/versioned/ts-jsdoc-bridge-0.2.0-draft.profile.json",
31
+ "./ts-jsdoc-bridge/0.3.0-draft.profile.json": "./dist/profiles/versioned/ts-jsdoc-bridge-0.3.0-draft.profile.json",
32
+ "./ts-jsdoc-bridge/0.4.0-draft.profile.json": "./dist/profiles/versioned/ts-jsdoc-bridge-0.4.0-draft.profile.json",
33
+ "./tsdoc-project/catalog.json": "./dist/tsdoc-project-catalog.json",
34
+ "./tsdoc-project/0.3.0-draft/catalog.json": "./dist/tsdoc-structured-project-catalog.json",
35
+ "./tsdoc-project/0.4.0-draft/catalog.json": "./dist/tsdoc-wrapped-project-catalog.json",
30
36
  "./package.json": "./package.json"
31
37
  },
32
38
  "files": [
@@ -38,11 +44,11 @@
38
44
  "access": "public"
39
45
  },
40
46
  "dependencies": {
41
- "@hia-doc/profile": "0.1.0"
47
+ "@hia-doc/profile": "1.0.0-rc.2"
42
48
  },
43
49
  "sideEffects": false,
44
50
  "scripts": {
45
51
  "build": "tsc -p tsconfig.json",
46
- "test": "vitest run --root ../.. packages/profiles/src/index.test.ts"
52
+ "test": "vitest run --root ../.. packages/profiles/src"
47
53
  }
48
54
  }