@mdfriday/foundry 26.3.15 → 26.3.17
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/cli.js +49 -6
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/internal/application/identity.d.ts +2 -22
- package/dist/internal/domain/identity/entity/user.d.ts +24 -14
- package/dist/internal/domain/identity/index.d.ts +1 -1
- package/dist/internal/domain/workspace/entity/project.d.ts +1 -0
- package/dist/internal/interfaces/obsidian/auth.d.ts +10 -0
- package/dist/internal/interfaces/obsidian/config.d.ts +1 -0
- package/dist/internal/interfaces/obsidian/index.d.ts +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -1151,6 +1151,19 @@ var init_project = __esm({
|
|
|
1151
1151
|
this.setNestedValue(this.config, key2, value);
|
|
1152
1152
|
log2.debug(`Project config updated: ${key2}`, { projectName: this.metadata.name });
|
|
1153
1153
|
}
|
|
1154
|
+
/**
|
|
1155
|
+
* Set entire configuration object (replaces current config)
|
|
1156
|
+
*
|
|
1157
|
+
* This method replaces the entire configuration with the provided object.
|
|
1158
|
+
* Useful for bulk updates to avoid race conditions from multiple writes.
|
|
1159
|
+
*/
|
|
1160
|
+
setConfig(config) {
|
|
1161
|
+
if (this.config === null) {
|
|
1162
|
+
throw new Error("Configuration not loaded. Call loadConfig() first.");
|
|
1163
|
+
}
|
|
1164
|
+
this.config = config;
|
|
1165
|
+
log2.debug(`Project config replaced entirely`, { projectName: this.metadata.name });
|
|
1166
|
+
}
|
|
1154
1167
|
/**
|
|
1155
1168
|
* Unset configuration value (supports nested keys with dot notation)
|
|
1156
1169
|
*/
|
|
@@ -2471,8 +2484,13 @@ var init_user = __esm({
|
|
|
2471
2484
|
/**
|
|
2472
2485
|
* 获取认证状态信息
|
|
2473
2486
|
*/
|
|
2487
|
+
/**
|
|
2488
|
+
* 获取用户状态
|
|
2489
|
+
*
|
|
2490
|
+
* @returns 完整的用户状态信息,包括认证、License 和 Sync 配置
|
|
2491
|
+
*/
|
|
2474
2492
|
getStatus() {
|
|
2475
|
-
|
|
2493
|
+
const status = {
|
|
2476
2494
|
isAuthenticated: this.isAuthenticated(),
|
|
2477
2495
|
email: this.email.getValue(),
|
|
2478
2496
|
serverUrl: this.serverConfig.getApiUrl(),
|
|
@@ -2484,8 +2502,20 @@ var init_user = __esm({
|
|
|
2484
2502
|
isTrial: this.isTrialAccount(),
|
|
2485
2503
|
licensePlan: this.license?.getPlan(),
|
|
2486
2504
|
licenseExpires: this.license?.getFormattedExpiresAt(),
|
|
2487
|
-
licenseDaysRemaining: this.license?.getDaysRemaining()
|
|
2505
|
+
licenseDaysRemaining: this.license?.getDaysRemaining(),
|
|
2506
|
+
hasSyncConfig: this.syncConfig !== null
|
|
2488
2507
|
};
|
|
2508
|
+
if (this.syncConfig) {
|
|
2509
|
+
status.syncConfig = {
|
|
2510
|
+
dbEndpoint: this.syncConfig.getDbEndpoint(),
|
|
2511
|
+
dbName: this.syncConfig.getDbName(),
|
|
2512
|
+
email: this.syncConfig.getEmail(),
|
|
2513
|
+
userDir: this.syncConfig.getUserDir(),
|
|
2514
|
+
status: this.syncConfig.getStatus(),
|
|
2515
|
+
isActive: this.syncConfig.isActive()
|
|
2516
|
+
};
|
|
2517
|
+
}
|
|
2518
|
+
return status;
|
|
2489
2519
|
}
|
|
2490
2520
|
// ============================================================================
|
|
2491
2521
|
// Serialization
|
|
@@ -4642,15 +4672,28 @@ var init_identity2 = __esm({
|
|
|
4642
4672
|
/**
|
|
4643
4673
|
* 获取认证状态
|
|
4644
4674
|
*/
|
|
4675
|
+
/**
|
|
4676
|
+
* 获取用户状态
|
|
4677
|
+
*
|
|
4678
|
+
* @returns 用户状态信息,包括认证、License 和 Sync 配置
|
|
4679
|
+
*/
|
|
4645
4680
|
getStatus() {
|
|
4646
4681
|
if (!this.currentUser) {
|
|
4647
4682
|
return {
|
|
4648
4683
|
isAuthenticated: false,
|
|
4649
|
-
email:
|
|
4650
|
-
license: "",
|
|
4684
|
+
email: "",
|
|
4651
4685
|
serverUrl: ServerConfig.createDefault().getApiUrl(),
|
|
4652
4686
|
tokenExpired: true,
|
|
4653
|
-
hasToken: false
|
|
4687
|
+
hasToken: false,
|
|
4688
|
+
hasLicense: false,
|
|
4689
|
+
license: void 0,
|
|
4690
|
+
licenseValid: false,
|
|
4691
|
+
isTrial: false,
|
|
4692
|
+
licensePlan: void 0,
|
|
4693
|
+
licenseExpires: void 0,
|
|
4694
|
+
licenseDaysRemaining: void 0,
|
|
4695
|
+
hasSyncConfig: false,
|
|
4696
|
+
syncConfig: void 0
|
|
4654
4697
|
};
|
|
4655
4698
|
}
|
|
4656
4699
|
return this.currentUser.getStatus();
|
|
@@ -55116,7 +55159,7 @@ For more information, visit: https://help.mdfriday.com
|
|
|
55116
55159
|
* Show version
|
|
55117
55160
|
*/
|
|
55118
55161
|
showVersion() {
|
|
55119
|
-
const version = "26.3.
|
|
55162
|
+
const version = "26.3.17";
|
|
55120
55163
|
return {
|
|
55121
55164
|
success: true,
|
|
55122
55165
|
message: `MDFriday CLI v${version}`
|
package/dist/index.d.ts
CHANGED
|
@@ -3,4 +3,4 @@ export { processSSGParallel, ParallelSSGStats } from './internal/application/ssg
|
|
|
3
3
|
export { startIncrementalBuild, IncrementalBuildConfig, IncrementalBuildCoordinator } from './internal/application/incremental-ssg';
|
|
4
4
|
export { MarkdownRenderer, AutoIDGenerator, ParsingResult, Header, TocFragments, Link, Paragraph } from './internal/domain/markdown';
|
|
5
5
|
export { PageTask } from './pkg/page-filter';
|
|
6
|
-
export { ObsidianWorkspaceService, createObsidianWorkspaceService, ObsidianWorkspaceInitOptions, ObsidianWorkspaceInfo, ObsidianWorkspaceResult, ObsidianProjectService, createObsidianProjectService, ObsidianProjectCreateOptions, ObsidianProjectInfo, ObsidianProjectResult, ObsidianBuildService, createObsidianBuildService, ObsidianBuildOptions, ObsidianBuildResult, ObsidianGlobalConfigService, ObsidianProjectConfigService, createObsidianGlobalConfigService, createObsidianProjectConfigService, ObsidianConfigResult, ConfigGetResult, ConfigListResult, ObsidianPublishService, createObsidianPublishService, ObsidianPublishMethod, ObsidianPublishOptions, ObsidianPublishProgress, ObsidianPublishResult, ObsidianTestConnectionResult, ObsidianServeService, createObsidianServeService, ObsidianServeOptions, ObsidianServeResult, ObsidianServeProgress, ObsidianLicenseService, createObsidianLicenseService, ObsidianLicenseInfo, ObsidianLicenseUsage, ObsidianLicenseResult, ObsidianAuthService, createObsidianAuthService, ObsidianAuthStatus, ObsidianServerConfig, ObsidianAuthResult, ObsidianDomainService, createObsidianDomainService, ObsidianDomainInfo, ObsidianSubdomainCheckResult, ObsidianSubdomainUpdateResult, ObsidianCustomDomainCheckResult, ObsidianCustomDomainAddResult, ObsidianHttpsCertificate, ObsidianHttpsStatusResult, ObsidianDomainResult, createWorkspaceAppService, createWorkspaceFactory, type PublishHttpClient, type PublishHttpResponse, type IdentityHttpClient, type IdentityHttpResponse, type AnyPublishConfig, type FTPConfig, type NetlifyConfig, type MDFridayConfig, type SyncConfig, type SyncConfigData, } from './internal/interfaces/obsidian';
|
|
6
|
+
export { ObsidianWorkspaceService, createObsidianWorkspaceService, ObsidianWorkspaceInitOptions, ObsidianWorkspaceInfo, ObsidianWorkspaceResult, ObsidianProjectService, createObsidianProjectService, ObsidianProjectCreateOptions, ObsidianProjectInfo, ObsidianProjectResult, ObsidianBuildService, createObsidianBuildService, ObsidianBuildOptions, ObsidianBuildResult, ObsidianGlobalConfigService, ObsidianProjectConfigService, createObsidianGlobalConfigService, createObsidianProjectConfigService, ObsidianConfigResult, ConfigGetResult, ConfigListResult, ObsidianPublishService, createObsidianPublishService, ObsidianPublishMethod, ObsidianPublishOptions, ObsidianPublishProgress, ObsidianPublishResult, ObsidianTestConnectionResult, ObsidianServeService, createObsidianServeService, ObsidianServeOptions, ObsidianServeResult, ObsidianServeProgress, ObsidianLicenseService, createObsidianLicenseService, ObsidianLicenseInfo, ObsidianLicenseUsage, ObsidianLicenseResult, ObsidianAuthService, createObsidianAuthService, ObsidianAuthStatus, ObsidianSyncConfig, ObsidianServerConfig, ObsidianAuthResult, ObsidianDomainService, createObsidianDomainService, ObsidianDomainInfo, ObsidianSubdomainCheckResult, ObsidianSubdomainUpdateResult, ObsidianCustomDomainCheckResult, ObsidianCustomDomainAddResult, ObsidianHttpsCertificate, ObsidianHttpsStatusResult, ObsidianDomainResult, createWorkspaceAppService, createWorkspaceFactory, type PublishHttpClient, type PublishHttpResponse, type IdentityHttpClient, type IdentityHttpResponse, type AnyPublishConfig, type FTPConfig, type NetlifyConfig, type MDFridayConfig, type SyncConfig, type SyncConfigData, } from './internal/interfaces/obsidian';
|