@acorex-platform/extension-source-control-core-client 0.0.21

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.
@@ -0,0 +1,69 @@
1
+ //#region ----- Source control extension root config -----
2
+ const config = {
3
+ i18n: 'extensions-source-control',
4
+ };
5
+ const MODULE_NAME = 'SourceControlExtension';
6
+ const RootConfig = {
7
+ config,
8
+ module: {
9
+ name: MODULE_NAME,
10
+ title: `@${config.i18n}:module.title`,
11
+ icon: 'fa-light fa-code-branch',
12
+ },
13
+ entities: {
14
+ projectSourceControlLink: {
15
+ name: 'ProjectSourceControlLink',
16
+ fullName: `${MODULE_NAME}.ProjectSourceControlLink`,
17
+ title: `@${config.i18n}:entities.project-source-control-link.title`,
18
+ titlePlural: `@${config.i18n}:entities.project-source-control-link.plural`,
19
+ icon: 'fa-light fa-link',
20
+ source: `${MODULE_NAME}.ProjectSourceControlLink`,
21
+ },
22
+ },
23
+ };
24
+ //#endregion
25
+
26
+ //#region ----- Source control extension settings keys -----
27
+ const AXESourceControlExtensionSettings = {
28
+ EnabledProjectTypeIds: 'SourceControlExtension:Setting:EnabledProjectTypeIds',
29
+ };
30
+ /** Demo default — matches ProjectManagement seed Software project type id. */
31
+ const AXE_SC_DEFAULT_ENABLED_PROJECT_TYPE_ID = 'pm-mock-project-type-software';
32
+ //#endregion
33
+
34
+ //#region ----- Source control extension command keys -----
35
+ const AXESourceControlCommandKeys = {
36
+ ProjectLinkRepository: 'SourceControlExtension.Project:LinkRepository',
37
+ ProjectUnlinkRepository: 'SourceControlExtension.Project:UnlinkRepository',
38
+ };
39
+ //#endregion
40
+
41
+ //#region ----- Source control hook keys -----
42
+ const AXESourceControlHookKeys = {
43
+ CommitActions: 'source-control.repository.commit-actions',
44
+ BranchActions: 'source-control.repository.branch-actions',
45
+ };
46
+ //#endregion
47
+
48
+ //#region ----- Source control provider constants -----
49
+ const AXE_SC_DOMAIN_ID = 'source-control';
50
+ const AXE_SC_PROVIDER_GITHUB = 'github';
51
+ const AXE_SC_PROVIDER_GITLAB = 'gitlab';
52
+ const AXE_SC_PROVIDER_IDS = [AXE_SC_PROVIDER_GITHUB, AXE_SC_PROVIDER_GITLAB];
53
+ //#endregion
54
+
55
+ //#region ----- Remote repository DTOs -----
56
+ //#endregion
57
+
58
+ //#region ----- Repository browse DTOs -----
59
+ //#endregion
60
+
61
+ //#region ----- Project source control link types -----
62
+ //#endregion
63
+
64
+ /**
65
+ * Generated bundle index. Do not edit.
66
+ */
67
+
68
+ export { AXESourceControlCommandKeys, AXESourceControlExtensionSettings, AXESourceControlHookKeys, AXE_SC_DEFAULT_ENABLED_PROJECT_TYPE_ID, AXE_SC_DOMAIN_ID, AXE_SC_PROVIDER_GITHUB, AXE_SC_PROVIDER_GITLAB, AXE_SC_PROVIDER_IDS, RootConfig };
69
+ //# sourceMappingURL=acorex-platform-extension-source-control-core-client-contracts.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"acorex-platform-extension-source-control-core-client-contracts.mjs","sources":["../../../../libs/extensions/source-control/core/contracts/src/root-config.ts","../../../../libs/extensions/source-control/core/contracts/src/settings.keys.ts","../../../../libs/extensions/source-control/core/contracts/src/commands.keys.ts","../../../../libs/extensions/source-control/core/contracts/src/hook.keys.ts","../../../../libs/extensions/source-control/core/contracts/src/provider.constants.ts","../../../../libs/extensions/source-control/core/contracts/src/repo.types.ts","../../../../libs/extensions/source-control/core/contracts/src/repository.types.ts","../../../../libs/extensions/source-control/core/contracts/src/link.types.ts","../../../../libs/extensions/source-control/core/contracts/src/acorex-platform-extension-source-control-core-client-contracts.ts"],"sourcesContent":["//#region ----- Source control extension root config -----\n\nconst config = {\n i18n: 'extensions-source-control',\n};\n\nconst MODULE_NAME = 'SourceControlExtension';\n\nexport const RootConfig = {\n config,\n module: {\n name: MODULE_NAME,\n title: `@${config.i18n}:module.title`,\n icon: 'fa-light fa-code-branch',\n },\n entities: {\n projectSourceControlLink: {\n name: 'ProjectSourceControlLink',\n fullName: `${MODULE_NAME}.ProjectSourceControlLink`,\n title: `@${config.i18n}:entities.project-source-control-link.title`,\n titlePlural: `@${config.i18n}:entities.project-source-control-link.plural`,\n icon: 'fa-light fa-link',\n source: `${MODULE_NAME}.ProjectSourceControlLink`,\n },\n },\n};\n\n//#endregion\n","//#region ----- Source control extension settings keys -----\n\nexport const AXESourceControlExtensionSettings = {\n EnabledProjectTypeIds: 'SourceControlExtension:Setting:EnabledProjectTypeIds',\n} as const;\n\n/** Demo default — matches ProjectManagement seed Software project type id. */\nexport const AXE_SC_DEFAULT_ENABLED_PROJECT_TYPE_ID = 'pm-mock-project-type-software';\n\n//#endregion\n","//#region ----- Source control extension command keys -----\n\nexport const AXESourceControlCommandKeys = {\n ProjectLinkRepository: 'SourceControlExtension.Project:LinkRepository',\n ProjectUnlinkRepository: 'SourceControlExtension.Project:UnlinkRepository',\n} as const;\n\n//#endregion\n","//#region ----- Source control hook keys -----\r\r\n\r\r\nexport const AXESourceControlHookKeys = {\r\r\n CommitActions: 'source-control.repository.commit-actions',\r\r\n BranchActions: 'source-control.repository.branch-actions',\r\r\n} as const;\r\r\n\r\r\n//#endregion\r\r\n","//#region ----- Source control provider constants -----\n\nexport const AXE_SC_DOMAIN_ID = 'source-control';\n\nexport const AXE_SC_PROVIDER_GITHUB = 'github';\nexport const AXE_SC_PROVIDER_GITLAB = 'gitlab';\n\nexport const AXE_SC_PROVIDER_IDS = [AXE_SC_PROVIDER_GITHUB, AXE_SC_PROVIDER_GITLAB] as const;\n\nexport type AXESourceControlProviderId = (typeof AXE_SC_PROVIDER_IDS)[number];\n\n//#endregion\n","//#region ----- Remote repository DTOs -----\n\nexport interface AXESourceControlRemoteRepoDto {\n remoteId: string;\n fullName: string;\n webUrl: string;\n defaultBranch?: string;\n description?: string;\n}\n\nexport interface AXESourceControlSearchReposRequest {\n providerId: string;\n connectionId: string;\n query?: string;\n}\n\nexport interface AXESourceControlSearchReposResponse {\n items: AXESourceControlRemoteRepoDto[];\n}\n\n//#endregion\n","//#region ----- Repository browse DTOs -----\r\r\n\r\r\nimport type { AXPActionMenuItem } from '@acorex-platform/framework-shared/core';\r\r\n\r\r\nimport type { AXESourceControlProjectSourceControlLinkEntityModel } from './link.types';\r\r\n\r\r\nexport interface AXESourceControlBranchDto {\r\r\n name: string;\r\r\n isDefault?: boolean;\r\r\n}\r\r\n\r\r\nexport interface AXESourceControlCommitDto {\r\r\n sha: string;\r\r\n shortSha?: string;\r\r\n message: string;\r\r\n authorName: string;\r\r\n committedAt: string;\r\r\n webUrl: string;\r\r\n}\r\r\n\r\r\nexport interface AXESourceControlListBranchesRequest {\r\r\n providerId: string;\r\r\n connectionId: string;\r\r\n fullName: string;\r\r\n}\r\r\n\r\r\nexport interface AXESourceControlListBranchesResponse {\r\r\n items: AXESourceControlBranchDto[];\r\r\n}\r\r\n\r\r\nexport interface AXESourceControlListCommitsRequest {\r\r\n providerId: string;\r\r\n connectionId: string;\r\r\n fullName: string;\r\r\n branch: string;\r\r\n take?: number;\r\r\n}\r\r\n\r\r\nexport interface AXESourceControlListCommitsResponse {\r\r\n items: AXESourceControlCommitDto[];\r\r\n}\r\r\n\r\r\n//#endregion\r\r\n\r\r\n//#region ----- Hook payloads -----\r\r\n\r\r\nexport interface AXESourceControlCommitActionsHookPayload {\r\r\n projectId: string;\r\r\n link: AXESourceControlProjectSourceControlLinkEntityModel;\r\r\n branch: string;\r\r\n commit: AXESourceControlCommitDto;\r\r\n actions: AXPActionMenuItem[];\r\r\n}\r\r\n\r\r\nexport interface AXESourceControlBranchActionsHookPayload {\r\r\n projectId: string;\r\r\n link: AXESourceControlProjectSourceControlLinkEntityModel;\r\r\n branch: string;\r\r\n baseBranch: string;\r\r\n actions: AXPActionMenuItem[];\r\r\n}\r\r\n\r\r\n//#endregion\r\r\n","//#region ----- Project source control link types -----\n\nimport type { AXPEntityModel } from '@acorex-platform/framework-shared/entity';\n\nexport interface AXESourceControlProjectSourceControlLinkEntityModel extends AXPEntityModel<string> {\n projectId: string;\n providerId: string;\n connectionId: string;\n remoteId: string;\n fullName: string;\n webUrl: string;\n defaultBranch?: string;\n linkedAt: string;\n}\n\nexport interface AXESourceControlLinkRepositoryCommandInput {\n projectId: string;\n}\n\nexport interface AXESourceControlUnlinkRepositoryCommandInput {\n projectId: string;\n}\n\nexport interface AXESourceControlLinkRepositoryPayload {\n projectId: string;\n providerId: string;\n connectionId: string;\n remoteId: string;\n fullName: string;\n webUrl: string;\n defaultBranch?: string;\n linkedAt: string;\n}\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"AAAA;AAEA,MAAM,MAAM,GAAG;AACb,IAAA,IAAI,EAAE,2BAA2B;CAClC;AAED,MAAM,WAAW,GAAG,wBAAwB;AAErC,MAAM,UAAU,GAAG;IACxB,MAAM;AACN,IAAA,MAAM,EAAE;AACN,QAAA,IAAI,EAAE,WAAW;AACjB,QAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,aAAA,CAAe;AACrC,QAAA,IAAI,EAAE,yBAAyB;AAChC,KAAA;AACD,IAAA,QAAQ,EAAE;AACR,QAAA,wBAAwB,EAAE;AACxB,YAAA,IAAI,EAAE,0BAA0B;YAChC,QAAQ,EAAE,CAAA,EAAG,WAAW,CAAA,yBAAA,CAA2B;AACnD,YAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,2CAAA,CAA6C;AACnE,YAAA,WAAW,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,4CAAA,CAA8C;AAC1E,YAAA,IAAI,EAAE,kBAAkB;YACxB,MAAM,EAAE,CAAA,EAAG,WAAW,CAAA,yBAAA,CAA2B;AAClD,SAAA;AACF,KAAA;;AAGH;;AC3BA;AAEO,MAAM,iCAAiC,GAAG;AAC/C,IAAA,qBAAqB,EAAE,sDAAsD;;AAG/E;AACO,MAAM,sCAAsC,GAAG;AAEtD;;ACTA;AAEO,MAAM,2BAA2B,GAAG;AACzC,IAAA,qBAAqB,EAAE,+CAA+C;AACtE,IAAA,uBAAuB,EAAE,iDAAiD;;AAG5E;;ACPA;AAIO,MAAM,wBAAwB,GAAG;AAEtC,IAAA,aAAa,EAAE,0CAA0C;AAEzD,IAAA,aAAa,EAAE,0CAA0C;;AAM3D;;ACdA;AAEO,MAAM,gBAAgB,GAAG;AAEzB,MAAM,sBAAsB,GAAG;AAC/B,MAAM,sBAAsB,GAAG;MAEzB,mBAAmB,GAAG,CAAC,sBAAsB,EAAE,sBAAsB;AAIlF;;ACXA;AAoBA;;ACpBA;AA4HA;;AC5HA;AAkCA;;AClCA;;AAEG;;;;"}