@stackmemoryai/stackmemory 0.1.0 → 0.2.0
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/scripts/initialize.js +15 -15
- package/dist/scripts/initialize.js.map +1 -1
- package/dist/scripts/status.js +21 -11
- package/dist/scripts/status.js.map +1 -1
- package/dist/src/beads/beads-task-store.d.ts +117 -0
- package/dist/src/beads/beads-task-store.d.ts.map +1 -0
- package/dist/src/beads/beads-task-store.js +318 -0
- package/dist/src/beads/beads-task-store.js.map +1 -0
- package/dist/src/beads/task-aware-context.d.ts +103 -0
- package/dist/src/beads/task-aware-context.d.ts.map +1 -0
- package/dist/src/beads/task-aware-context.js +395 -0
- package/dist/src/beads/task-aware-context.js.map +1 -0
- package/dist/src/beads-task-store.d.ts +117 -0
- package/dist/src/beads-task-store.d.ts.map +1 -0
- package/dist/src/beads-task-store.js +318 -0
- package/dist/src/beads-task-store.js.map +1 -0
- package/dist/src/cli/cli.d.ts +7 -0
- package/dist/src/cli/cli.d.ts.map +1 -0
- package/dist/src/cli/cli.js +471 -0
- package/dist/src/cli/cli.js.map +1 -0
- package/dist/src/core/error-handler.d.ts +46 -0
- package/dist/src/core/error-handler.d.ts.map +1 -0
- package/dist/src/core/error-handler.js +212 -0
- package/dist/src/core/error-handler.js.map +1 -0
- package/dist/src/core/frame-manager.d.ts +106 -0
- package/dist/src/core/frame-manager.d.ts.map +1 -0
- package/dist/src/core/frame-manager.js +387 -0
- package/dist/src/core/frame-manager.js.map +1 -0
- package/dist/src/core/logger.d.ts +24 -0
- package/dist/src/core/logger.d.ts.map +1 -0
- package/dist/src/core/logger.js +121 -0
- package/dist/src/core/logger.js.map +1 -0
- package/dist/src/core/logger.test.d.ts +2 -0
- package/dist/src/core/logger.test.d.ts.map +1 -0
- package/dist/src/core/logger.test.js +31 -0
- package/dist/src/core/logger.test.js.map +1 -0
- package/dist/src/index.d.ts +4 -4
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +4 -4
- package/dist/src/index.js.map +1 -1
- package/dist/src/integrations/linear-auth.d.ts +99 -0
- package/dist/src/integrations/linear-auth.d.ts.map +1 -0
- package/dist/src/integrations/linear-auth.js +319 -0
- package/dist/src/integrations/linear-auth.js.map +1 -0
- package/dist/src/integrations/linear-auto-sync.d.ts +77 -0
- package/dist/src/integrations/linear-auto-sync.d.ts.map +1 -0
- package/dist/src/integrations/linear-auto-sync.js +268 -0
- package/dist/src/integrations/linear-auto-sync.js.map +1 -0
- package/dist/src/integrations/linear-client.d.ts +86 -0
- package/dist/src/integrations/linear-client.d.ts.map +1 -0
- package/dist/src/integrations/linear-client.js +275 -0
- package/dist/src/integrations/linear-client.js.map +1 -0
- package/dist/src/integrations/linear-config.d.ts +51 -0
- package/dist/src/integrations/linear-config.d.ts.map +1 -0
- package/dist/src/integrations/linear-config.js +103 -0
- package/dist/src/integrations/linear-config.js.map +1 -0
- package/dist/src/integrations/linear-sync.d.ts +95 -0
- package/dist/src/integrations/linear-sync.d.ts.map +1 -0
- package/dist/src/integrations/linear-sync.js +340 -0
- package/dist/src/integrations/linear-sync.js.map +1 -0
- package/dist/src/mcp/mcp-server.d.ts +38 -0
- package/dist/src/mcp/mcp-server.d.ts.map +1 -0
- package/dist/src/mcp/mcp-server.js +812 -0
- package/dist/src/mcp/mcp-server.js.map +1 -0
- package/dist/src/pebbles/pebbles-task-store.d.ts +117 -0
- package/dist/src/pebbles/pebbles-task-store.d.ts.map +1 -0
- package/dist/src/pebbles/pebbles-task-store.js +335 -0
- package/dist/src/pebbles/pebbles-task-store.js.map +1 -0
- package/dist/src/pebbles/task-aware-context.d.ts +103 -0
- package/dist/src/pebbles/task-aware-context.d.ts.map +1 -0
- package/dist/src/pebbles/task-aware-context.js +412 -0
- package/dist/src/pebbles/task-aware-context.js.map +1 -0
- package/dist/src/task-aware-context.d.ts +103 -0
- package/dist/src/task-aware-context.d.ts.map +1 -0
- package/dist/src/task-aware-context.js +395 -0
- package/dist/src/task-aware-context.js.map +1 -0
- package/package.json +40 -9
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Linear Auto-Sync Configuration Management
|
|
3
|
+
* Handles persistent configuration for auto-sync service
|
|
4
|
+
*/
|
|
5
|
+
import { AutoSyncConfig } from './linear-auto-sync.js';
|
|
6
|
+
export interface PersistedSyncConfig {
|
|
7
|
+
enabled: boolean;
|
|
8
|
+
interval: number;
|
|
9
|
+
direction: 'bidirectional' | 'to_linear' | 'from_linear';
|
|
10
|
+
conflictResolution: 'linear_wins' | 'stackmemory_wins' | 'manual' | 'newest_wins';
|
|
11
|
+
retryAttempts: number;
|
|
12
|
+
retryDelay: number;
|
|
13
|
+
quietHours?: {
|
|
14
|
+
start: number;
|
|
15
|
+
end: number;
|
|
16
|
+
};
|
|
17
|
+
lastUpdated: number;
|
|
18
|
+
}
|
|
19
|
+
export declare class LinearConfigManager {
|
|
20
|
+
private configPath;
|
|
21
|
+
constructor(projectRoot: string);
|
|
22
|
+
/**
|
|
23
|
+
* Load configuration from file
|
|
24
|
+
*/
|
|
25
|
+
loadConfig(): PersistedSyncConfig | null;
|
|
26
|
+
/**
|
|
27
|
+
* Save configuration to file
|
|
28
|
+
*/
|
|
29
|
+
saveConfig(config: Partial<PersistedSyncConfig>): void;
|
|
30
|
+
/**
|
|
31
|
+
* Get default configuration
|
|
32
|
+
*/
|
|
33
|
+
getDefaultConfig(): PersistedSyncConfig;
|
|
34
|
+
/**
|
|
35
|
+
* Convert to AutoSyncConfig format
|
|
36
|
+
*/
|
|
37
|
+
toAutoSyncConfig(config?: PersistedSyncConfig): AutoSyncConfig;
|
|
38
|
+
/**
|
|
39
|
+
* Update specific configuration values
|
|
40
|
+
*/
|
|
41
|
+
updateConfig(updates: Partial<PersistedSyncConfig>): void;
|
|
42
|
+
/**
|
|
43
|
+
* Check if configuration exists
|
|
44
|
+
*/
|
|
45
|
+
hasConfig(): boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Reset to default configuration
|
|
48
|
+
*/
|
|
49
|
+
resetConfig(): void;
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=linear-config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"linear-config.d.ts","sourceRoot":"","sources":["../../../src/integrations/linear-config.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAEvD,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,eAAe,GAAG,WAAW,GAAG,aAAa,CAAC;IACzD,kBAAkB,EACd,aAAa,GACb,kBAAkB,GAClB,QAAQ,GACR,aAAa,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE;QACX,KAAK,EAAE,MAAM,CAAC;QACd,GAAG,EAAE,MAAM,CAAC;KACb,CAAC;IACF,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,qBAAa,mBAAmB;IAC9B,OAAO,CAAC,UAAU,CAAS;gBAEf,WAAW,EAAE,MAAM;IAQ/B;;OAEG;IACH,UAAU,IAAI,mBAAmB,GAAG,IAAI;IAiBxC;;OAEG;IACH,UAAU,CAAC,MAAM,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAAG,IAAI;IAqBtD;;OAEG;IACH,gBAAgB,IAAI,mBAAmB;IAgBvC;;OAEG;IACH,gBAAgB,CAAC,MAAM,CAAC,EAAE,mBAAmB,GAAG,cAAc;IAkB9D;;OAEG;IACH,YAAY,CAAC,OAAO,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAAG,IAAI;IAIzD;;OAEG;IACH,SAAS,IAAI,OAAO;IAIpB;;OAEG;IACH,WAAW,IAAI,IAAI;CAGpB"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Linear Auto-Sync Configuration Management
|
|
3
|
+
* Handles persistent configuration for auto-sync service
|
|
4
|
+
*/
|
|
5
|
+
import { readFileSync, writeFileSync, existsSync } from 'fs';
|
|
6
|
+
import { join } from 'path';
|
|
7
|
+
import { logger } from '../core/logger.js';
|
|
8
|
+
export class LinearConfigManager {
|
|
9
|
+
configPath;
|
|
10
|
+
constructor(projectRoot) {
|
|
11
|
+
this.configPath = join(projectRoot, '.stackmemory', 'linear-auto-sync.json');
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Load configuration from file
|
|
15
|
+
*/
|
|
16
|
+
loadConfig() {
|
|
17
|
+
if (!existsSync(this.configPath)) {
|
|
18
|
+
return null;
|
|
19
|
+
}
|
|
20
|
+
try {
|
|
21
|
+
const configData = readFileSync(this.configPath, 'utf8');
|
|
22
|
+
return JSON.parse(configData);
|
|
23
|
+
}
|
|
24
|
+
catch (error) {
|
|
25
|
+
logger.error('Failed to load Linear auto-sync configuration:', error);
|
|
26
|
+
return null;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Save configuration to file
|
|
31
|
+
*/
|
|
32
|
+
saveConfig(config) {
|
|
33
|
+
const existingConfig = this.loadConfig() || this.getDefaultConfig();
|
|
34
|
+
const updatedConfig = {
|
|
35
|
+
...existingConfig,
|
|
36
|
+
...config,
|
|
37
|
+
lastUpdated: Date.now(),
|
|
38
|
+
};
|
|
39
|
+
try {
|
|
40
|
+
writeFileSync(this.configPath, JSON.stringify(updatedConfig, null, 2));
|
|
41
|
+
logger.info('Linear auto-sync configuration saved');
|
|
42
|
+
}
|
|
43
|
+
catch (error) {
|
|
44
|
+
logger.error('Failed to save Linear auto-sync configuration:', error);
|
|
45
|
+
throw error;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Get default configuration
|
|
50
|
+
*/
|
|
51
|
+
getDefaultConfig() {
|
|
52
|
+
return {
|
|
53
|
+
enabled: true,
|
|
54
|
+
interval: 5, // 5 minutes
|
|
55
|
+
direction: 'bidirectional',
|
|
56
|
+
conflictResolution: 'newest_wins',
|
|
57
|
+
retryAttempts: 3,
|
|
58
|
+
retryDelay: 30000, // 30 seconds
|
|
59
|
+
quietHours: {
|
|
60
|
+
start: 22, // 10 PM
|
|
61
|
+
end: 7, // 7 AM
|
|
62
|
+
},
|
|
63
|
+
lastUpdated: Date.now(),
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* Convert to AutoSyncConfig format
|
|
68
|
+
*/
|
|
69
|
+
toAutoSyncConfig(config) {
|
|
70
|
+
const persistedConfig = config || this.loadConfig() || this.getDefaultConfig();
|
|
71
|
+
return {
|
|
72
|
+
enabled: persistedConfig.enabled,
|
|
73
|
+
direction: persistedConfig.direction,
|
|
74
|
+
defaultTeamId: undefined, // Will be set by sync engine
|
|
75
|
+
autoSync: true,
|
|
76
|
+
conflictResolution: persistedConfig.conflictResolution,
|
|
77
|
+
syncInterval: persistedConfig.interval,
|
|
78
|
+
interval: persistedConfig.interval,
|
|
79
|
+
retryAttempts: persistedConfig.retryAttempts,
|
|
80
|
+
retryDelay: persistedConfig.retryDelay,
|
|
81
|
+
quietHours: persistedConfig.quietHours,
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Update specific configuration values
|
|
86
|
+
*/
|
|
87
|
+
updateConfig(updates) {
|
|
88
|
+
this.saveConfig(updates);
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* Check if configuration exists
|
|
92
|
+
*/
|
|
93
|
+
hasConfig() {
|
|
94
|
+
return existsSync(this.configPath);
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Reset to default configuration
|
|
98
|
+
*/
|
|
99
|
+
resetConfig() {
|
|
100
|
+
this.saveConfig(this.getDefaultConfig());
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
//# sourceMappingURL=linear-config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"linear-config.js","sourceRoot":"","sources":["../../../src/integrations/linear-config.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,IAAI,CAAC;AAC7D,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAqB3C,MAAM,OAAO,mBAAmB;IACtB,UAAU,CAAS;IAE3B,YAAY,WAAmB;QAC7B,IAAI,CAAC,UAAU,GAAG,IAAI,CACpB,WAAW,EACX,cAAc,EACd,uBAAuB,CACxB,CAAC;IACJ,CAAC;IAED;;OAEG;IACH,UAAU;QACR,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC;YACjC,OAAO,IAAI,CAAC;QACd,CAAC;QAED,IAAI,CAAC;YACH,MAAM,UAAU,GAAG,YAAY,CAAC,IAAI,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;YACzD,OAAO,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;QAChC,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,CAAC,KAAK,CACV,gDAAgD,EAChD,KAAc,CACf,CAAC;YACF,OAAO,IAAI,CAAC;QACd,CAAC;IACH,CAAC;IAED;;OAEG;IACH,UAAU,CAAC,MAAoC;QAC7C,MAAM,cAAc,GAAG,IAAI,CAAC,UAAU,EAAE,IAAI,IAAI,CAAC,gBAAgB,EAAE,CAAC;QAEpE,MAAM,aAAa,GAAwB;YACzC,GAAG,cAAc;YACjB,GAAG,MAAM;YACT,WAAW,EAAE,IAAI,CAAC,GAAG,EAAE;SACxB,CAAC;QAEF,IAAI,CAAC;YACH,aAAa,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,SAAS,CAAC,aAAa,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAA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AO,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACrC,CAAC;IAED;;OAEG;IACH,WAAW;QACT,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC,CAAC;IAC3C,CAAC;CACF"}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Linear Bi-directional Sync Engine
|
|
3
|
+
* Handles syncing tasks between StackMemory and Linear
|
|
4
|
+
*/
|
|
5
|
+
import { PebblesTaskStore } from '../pebbles/pebbles-task-store.js';
|
|
6
|
+
import { LinearAuthManager } from './linear-auth.js';
|
|
7
|
+
export interface SyncConfig {
|
|
8
|
+
enabled: boolean;
|
|
9
|
+
direction: 'bidirectional' | 'to_linear' | 'from_linear';
|
|
10
|
+
defaultTeamId?: string;
|
|
11
|
+
autoSync: boolean;
|
|
12
|
+
conflictResolution: 'linear_wins' | 'stackmemory_wins' | 'manual' | 'newest_wins';
|
|
13
|
+
syncInterval?: number;
|
|
14
|
+
}
|
|
15
|
+
export interface SyncResult {
|
|
16
|
+
success: boolean;
|
|
17
|
+
synced: {
|
|
18
|
+
toLinear: number;
|
|
19
|
+
fromLinear: number;
|
|
20
|
+
updated: number;
|
|
21
|
+
};
|
|
22
|
+
conflicts: Array<{
|
|
23
|
+
taskId: string;
|
|
24
|
+
linearId: string;
|
|
25
|
+
reason: string;
|
|
26
|
+
}>;
|
|
27
|
+
errors: string[];
|
|
28
|
+
}
|
|
29
|
+
export interface TaskMapping {
|
|
30
|
+
stackmemoryId: string;
|
|
31
|
+
linearId: string;
|
|
32
|
+
linearIdentifier: string;
|
|
33
|
+
lastSyncTimestamp: number;
|
|
34
|
+
lastLinearUpdate: string;
|
|
35
|
+
lastStackMemoryUpdate: number;
|
|
36
|
+
}
|
|
37
|
+
export declare class LinearSyncEngine {
|
|
38
|
+
private taskStore;
|
|
39
|
+
private linearClient;
|
|
40
|
+
private authManager;
|
|
41
|
+
private config;
|
|
42
|
+
private mappings;
|
|
43
|
+
constructor(taskStore: PebblesTaskStore, authManager: LinearAuthManager, config: SyncConfig);
|
|
44
|
+
/**
|
|
45
|
+
* Perform bi-directional sync
|
|
46
|
+
*/
|
|
47
|
+
sync(): Promise<SyncResult>;
|
|
48
|
+
/**
|
|
49
|
+
* Sync tasks from StackMemory to Linear
|
|
50
|
+
*/
|
|
51
|
+
private syncToLinear;
|
|
52
|
+
/**
|
|
53
|
+
* Sync tasks from Linear to StackMemory
|
|
54
|
+
*/
|
|
55
|
+
private syncFromLinear;
|
|
56
|
+
/**
|
|
57
|
+
* Create Linear issue from StackMemory task
|
|
58
|
+
*/
|
|
59
|
+
private createLinearIssueFromTask;
|
|
60
|
+
/**
|
|
61
|
+
* Update Linear issue from StackMemory task
|
|
62
|
+
*/
|
|
63
|
+
private updateLinearIssueFromTask;
|
|
64
|
+
/**
|
|
65
|
+
* Update StackMemory task from Linear issue
|
|
66
|
+
*/
|
|
67
|
+
private updateTaskFromLinearIssue;
|
|
68
|
+
/**
|
|
69
|
+
* Check if task should be updated from Linear based on conflict resolution strategy
|
|
70
|
+
*/
|
|
71
|
+
private shouldUpdateFromLinear;
|
|
72
|
+
/**
|
|
73
|
+
* Get tasks that haven't been synced to Linear yet
|
|
74
|
+
*/
|
|
75
|
+
private getUnsyncedTasks;
|
|
76
|
+
/**
|
|
77
|
+
* Get tasks that have been modified since last sync
|
|
78
|
+
*/
|
|
79
|
+
private getModifiedTasks;
|
|
80
|
+
/**
|
|
81
|
+
* Update task with Linear reference
|
|
82
|
+
*/
|
|
83
|
+
private updateTaskWithLinearRef;
|
|
84
|
+
private formatDescriptionForLinear;
|
|
85
|
+
private mapPriorityToLinear;
|
|
86
|
+
private mapTagsToLinear;
|
|
87
|
+
private mapLinearStateToStatus;
|
|
88
|
+
private loadMappings;
|
|
89
|
+
private saveMappings;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Default sync configuration
|
|
93
|
+
*/
|
|
94
|
+
export declare const DEFAULT_SYNC_CONFIG: SyncConfig;
|
|
95
|
+
//# sourceMappingURL=linear-sync.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"linear-sync.d.ts","sourceRoot":"","sources":["../../../src/integrations/linear-sync.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EAEL,gBAAgB,EAGjB,MAAM,kCAAkC,CAAC;AAM1C,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAErD,MAAM,WAAW,UAAU;IACzB,OAAO,EAAE,OAAO,CAAC;IACjB,SAAS,EAAE,eAAe,GAAG,WAAW,GAAG,aAAa,CAAC;IACzD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,EAAE,OAAO,CAAC;IAClB,kBAAkB,EACd,aAAa,GACb,kBAAkB,GAClB,QAAQ,GACR,aAAa,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,UAAU;IACzB,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE;QACN,QAAQ,EAAE,MAAM,CAAC;QACjB,UAAU,EAAE,MAAM,CAAC;QACnB,OAAO,EAAE,MAAM,CAAC;KACjB,CAAC;IACF,SAAS,EAAE,KAAK,CAAC;QACf,MAAM,EAAE,MAAM,CAAC;QACf,QAAQ,EAAE,MAAM,CAAC;QACjB,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC,CAAC;IACH,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB;AAED,MAAM,WAAW,WAAW;IAC1B,aAAa,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB,gBAAgB,EAAE,MAAM,CAAC;IACzB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,gBAAgB,EAAE,MAAM,CAAC;IACzB,qBAAqB,EAAE,MAAM,CAAC;CAC/B;AAED,qBAAa,gBAAgB;IAC3B,OAAO,CAAC,SAAS,CAAmB;IACpC,OAAO,CAAC,YAAY,CAAe;IACnC,OAAO,CAAC,WAAW,CAAoB;IACvC,OAAO,CAAC,MAAM,CAAa;IAC3B,OAAO,CAAC,QAAQ,CAAuC;gBAGrD,SAAS,EAAE,gBAAgB,EAC3B,WAAW,EAAE,iBAAiB,EAC9B,MAAM,EAAE,UAAU;IAYpB;;OAEG;IACG,IAAI,IAAI,OAAO,CAAC,UAAU,CAAC;IA6DjC;;OAEG;YACW,YAAY;IAuE1B;;OAEG;YACW,cAAc;IA4F5B;;OAEG;YACW,yBAAyB;IAiBvC;;OAEG;YACW,yBAAyB;IAgBvC;;OAEG;IACH,OAAO,CAAC,yBAAyB;IAmBjC;;OAEG;IACH,OAAO,CAAC,sBAAsB;IAqB9B;;OAEG;IACH,OAAO,CAAC,gBAAgB;IAOxB;;OAEG;IACH,OAAO,CAAC,gBAAgB;IAaxB;;OAEG;IACH,OAAO,CAAC,uBAAuB;IAc/B,OAAO,CAAC,0BAA0B;IAmBlC,OAAO,CAAC,mBAAmB;IAU3B,OAAO,CAAC,eAAe;IAMvB,OAAO,CAAC,sBAAsB;IAkB9B,OAAO,CAAC,YAAY;IAMpB,OAAO,CAAC,YAAY;CAIrB;AAED;;GAEG;AACH,eAAO,MAAM,mBAAmB,EAAE,UAMjC,CAAC"}
|
|
@@ -0,0 +1,340 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Linear Bi-directional Sync Engine
|
|
3
|
+
* Handles syncing tasks between StackMemory and Linear
|
|
4
|
+
*/
|
|
5
|
+
import { logger } from '../core/logger.js';
|
|
6
|
+
import { LinearClient, } from './linear-client.js';
|
|
7
|
+
export class LinearSyncEngine {
|
|
8
|
+
taskStore;
|
|
9
|
+
linearClient;
|
|
10
|
+
authManager;
|
|
11
|
+
config;
|
|
12
|
+
mappings = new Map();
|
|
13
|
+
constructor(taskStore, authManager, config) {
|
|
14
|
+
this.taskStore = taskStore;
|
|
15
|
+
this.authManager = authManager;
|
|
16
|
+
this.config = config;
|
|
17
|
+
this.linearClient = new LinearClient({
|
|
18
|
+
apiKey: '', // Will be set from auth manager
|
|
19
|
+
});
|
|
20
|
+
this.loadMappings();
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Perform bi-directional sync
|
|
24
|
+
*/
|
|
25
|
+
async sync() {
|
|
26
|
+
if (!this.config.enabled) {
|
|
27
|
+
return {
|
|
28
|
+
success: false,
|
|
29
|
+
synced: { toLinear: 0, fromLinear: 0, updated: 0 },
|
|
30
|
+
conflicts: [],
|
|
31
|
+
errors: ['Sync is disabled'],
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
const result = {
|
|
35
|
+
success: true,
|
|
36
|
+
synced: { toLinear: 0, fromLinear: 0, updated: 0 },
|
|
37
|
+
conflicts: [],
|
|
38
|
+
errors: [],
|
|
39
|
+
};
|
|
40
|
+
try {
|
|
41
|
+
// Get valid token and update client
|
|
42
|
+
const token = await this.authManager.getValidToken();
|
|
43
|
+
this.linearClient = new LinearClient({ apiKey: token });
|
|
44
|
+
// Get team info if not configured
|
|
45
|
+
if (!this.config.defaultTeamId) {
|
|
46
|
+
const team = await this.linearClient.getTeam();
|
|
47
|
+
this.config.defaultTeamId = team.id;
|
|
48
|
+
logger.info(`Using Linear team: ${team.name} (${team.key})`);
|
|
49
|
+
}
|
|
50
|
+
// Sync in both directions based on configuration
|
|
51
|
+
if (this.config.direction === 'bidirectional' ||
|
|
52
|
+
this.config.direction === 'to_linear') {
|
|
53
|
+
const toLinearResult = await this.syncToLinear();
|
|
54
|
+
result.synced.toLinear = toLinearResult.created;
|
|
55
|
+
result.synced.updated += toLinearResult.updated;
|
|
56
|
+
result.errors.push(...toLinearResult.errors);
|
|
57
|
+
}
|
|
58
|
+
if (this.config.direction === 'bidirectional' ||
|
|
59
|
+
this.config.direction === 'from_linear') {
|
|
60
|
+
const fromLinearResult = await this.syncFromLinear();
|
|
61
|
+
result.synced.fromLinear = fromLinearResult.created;
|
|
62
|
+
result.synced.updated += fromLinearResult.updated;
|
|
63
|
+
result.conflicts.push(...fromLinearResult.conflicts);
|
|
64
|
+
result.errors.push(...fromLinearResult.errors);
|
|
65
|
+
}
|
|
66
|
+
this.saveMappings();
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
result.success = false;
|
|
70
|
+
result.errors.push(`Sync failed: ${String(error)}`);
|
|
71
|
+
logger.error('Linear sync failed:', error);
|
|
72
|
+
}
|
|
73
|
+
return result;
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* Sync tasks from StackMemory to Linear
|
|
77
|
+
*/
|
|
78
|
+
async syncToLinear() {
|
|
79
|
+
const result = { created: 0, updated: 0, errors: [] };
|
|
80
|
+
// Get unsynced tasks from StackMemory
|
|
81
|
+
const unsyncedTasks = this.getUnsyncedTasks();
|
|
82
|
+
for (const task of unsyncedTasks) {
|
|
83
|
+
try {
|
|
84
|
+
const linearIssue = await this.createLinearIssueFromTask(task);
|
|
85
|
+
// Create mapping
|
|
86
|
+
const mapping = {
|
|
87
|
+
stackmemoryId: task.id,
|
|
88
|
+
linearId: linearIssue.id,
|
|
89
|
+
linearIdentifier: linearIssue.identifier,
|
|
90
|
+
lastSyncTimestamp: Date.now(),
|
|
91
|
+
lastLinearUpdate: linearIssue.updatedAt,
|
|
92
|
+
lastStackMemoryUpdate: task.timestamp * 1000,
|
|
93
|
+
};
|
|
94
|
+
this.mappings.set(task.id, mapping);
|
|
95
|
+
// Update task with Linear reference
|
|
96
|
+
this.updateTaskWithLinearRef(task.id, linearIssue);
|
|
97
|
+
result.created++;
|
|
98
|
+
logger.info(`Synced task to Linear: ${task.title} → ${linearIssue.identifier}`);
|
|
99
|
+
}
|
|
100
|
+
catch (error) {
|
|
101
|
+
result.errors.push(`Failed to sync task ${task.id}: ${String(error)}`);
|
|
102
|
+
logger.error(`Failed to sync task ${task.id} to Linear:`, error);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
// Update existing Linear issues for modified StackMemory tasks
|
|
106
|
+
const modifiedTasks = this.getModifiedTasks();
|
|
107
|
+
for (const task of modifiedTasks) {
|
|
108
|
+
try {
|
|
109
|
+
const mapping = this.mappings.get(task.id);
|
|
110
|
+
if (!mapping)
|
|
111
|
+
continue;
|
|
112
|
+
await this.updateLinearIssueFromTask(task, mapping);
|
|
113
|
+
mapping.lastSyncTimestamp = Date.now();
|
|
114
|
+
mapping.lastStackMemoryUpdate = task.timestamp * 1000;
|
|
115
|
+
result.updated++;
|
|
116
|
+
logger.info(`Updated Linear issue: ${mapping.linearIdentifier}`);
|
|
117
|
+
}
|
|
118
|
+
catch (error) {
|
|
119
|
+
result.errors.push(`Failed to update Linear issue for task ${task.id}: ${String(error)}`);
|
|
120
|
+
logger.error(`Failed to update Linear issue for task ${task.id}:`, error);
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
return result;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Sync tasks from Linear to StackMemory
|
|
127
|
+
*/
|
|
128
|
+
async syncFromLinear() {
|
|
129
|
+
const result = {
|
|
130
|
+
created: 0,
|
|
131
|
+
updated: 0,
|
|
132
|
+
conflicts: [],
|
|
133
|
+
errors: [],
|
|
134
|
+
};
|
|
135
|
+
// For now, we'll focus on updating existing mapped tasks
|
|
136
|
+
// Creating new StackMemory tasks from Linear issues would require frame context
|
|
137
|
+
for (const [taskId, mapping] of this.mappings) {
|
|
138
|
+
try {
|
|
139
|
+
const linearIssue = await this.linearClient.getIssue(mapping.linearId);
|
|
140
|
+
if (!linearIssue) {
|
|
141
|
+
result.errors.push(`Linear issue ${mapping.linearId} not found`);
|
|
142
|
+
continue;
|
|
143
|
+
}
|
|
144
|
+
// Check if Linear issue was updated since last sync
|
|
145
|
+
const linearUpdateTime = new Date(linearIssue.updatedAt).getTime();
|
|
146
|
+
if (linearUpdateTime <= mapping.lastSyncTimestamp) {
|
|
147
|
+
continue; // No changes in Linear
|
|
148
|
+
}
|
|
149
|
+
// Check for conflicts
|
|
150
|
+
const task = this.taskStore.getTask(taskId);
|
|
151
|
+
if (!task) {
|
|
152
|
+
result.errors.push(`StackMemory task ${taskId} not found`);
|
|
153
|
+
continue;
|
|
154
|
+
}
|
|
155
|
+
const stackMemoryUpdateTime = task.timestamp * 1000;
|
|
156
|
+
if (stackMemoryUpdateTime > mapping.lastSyncTimestamp &&
|
|
157
|
+
linearUpdateTime > mapping.lastSyncTimestamp) {
|
|
158
|
+
// Conflict: both sides updated since last sync
|
|
159
|
+
result.conflicts.push({
|
|
160
|
+
taskId,
|
|
161
|
+
linearId: mapping.linearId,
|
|
162
|
+
reason: 'Both StackMemory and Linear were updated since last sync',
|
|
163
|
+
});
|
|
164
|
+
if (this.config.conflictResolution === 'manual') {
|
|
165
|
+
continue; // Skip, let user resolve manually
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
// Apply conflict resolution
|
|
169
|
+
const shouldUpdateFromLinear = this.shouldUpdateFromLinear(task, linearIssue, mapping, stackMemoryUpdateTime, linearUpdateTime);
|
|
170
|
+
if (shouldUpdateFromLinear) {
|
|
171
|
+
this.updateTaskFromLinearIssue(task, linearIssue);
|
|
172
|
+
mapping.lastSyncTimestamp = Date.now();
|
|
173
|
+
mapping.lastLinearUpdate = linearIssue.updatedAt;
|
|
174
|
+
result.updated++;
|
|
175
|
+
logger.info(`Updated StackMemory task from Linear: ${task.title}`);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
catch (error) {
|
|
179
|
+
result.errors.push(`Failed to sync from Linear for task ${taskId}: ${String(error)}`);
|
|
180
|
+
logger.error(`Failed to sync from Linear for task ${taskId}:`, error);
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
return result;
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* Create Linear issue from StackMemory task
|
|
187
|
+
*/
|
|
188
|
+
async createLinearIssueFromTask(task) {
|
|
189
|
+
const input = {
|
|
190
|
+
title: task.title,
|
|
191
|
+
description: this.formatDescriptionForLinear(task),
|
|
192
|
+
teamId: this.config.defaultTeamId,
|
|
193
|
+
priority: this.mapPriorityToLinear(task.priority),
|
|
194
|
+
estimate: task.estimated_effort
|
|
195
|
+
? Math.ceil(task.estimated_effort / 60)
|
|
196
|
+
: undefined, // Convert minutes to hours
|
|
197
|
+
labelIds: this.mapTagsToLinear(task.tags),
|
|
198
|
+
};
|
|
199
|
+
return await this.linearClient.createIssue(input);
|
|
200
|
+
}
|
|
201
|
+
/**
|
|
202
|
+
* Update Linear issue from StackMemory task
|
|
203
|
+
*/
|
|
204
|
+
async updateLinearIssueFromTask(task, mapping) {
|
|
205
|
+
const updates = {
|
|
206
|
+
title: task.title,
|
|
207
|
+
description: this.formatDescriptionForLinear(task),
|
|
208
|
+
priority: this.mapPriorityToLinear(task.priority),
|
|
209
|
+
estimate: task.estimated_effort
|
|
210
|
+
? Math.ceil(task.estimated_effort / 60)
|
|
211
|
+
: undefined,
|
|
212
|
+
};
|
|
213
|
+
await this.linearClient.updateIssue(mapping.linearId, updates);
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* Update StackMemory task from Linear issue
|
|
217
|
+
*/
|
|
218
|
+
updateTaskFromLinearIssue(task, linearIssue) {
|
|
219
|
+
// Map Linear state to StackMemory status
|
|
220
|
+
const newStatus = this.mapLinearStateToStatus(linearIssue.state.type);
|
|
221
|
+
if (newStatus !== task.status) {
|
|
222
|
+
this.taskStore.updateTaskStatus(task.id, newStatus, 'Updated from Linear');
|
|
223
|
+
}
|
|
224
|
+
// Note: Other fields like title, description could be updated here
|
|
225
|
+
// but require careful consideration of conflict resolution
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* Check if task should be updated from Linear based on conflict resolution strategy
|
|
229
|
+
*/
|
|
230
|
+
shouldUpdateFromLinear(task, linearIssue, mapping, stackMemoryUpdateTime, linearUpdateTime) {
|
|
231
|
+
switch (this.config.conflictResolution) {
|
|
232
|
+
case 'linear_wins':
|
|
233
|
+
return true;
|
|
234
|
+
case 'stackmemory_wins':
|
|
235
|
+
return false;
|
|
236
|
+
case 'newest_wins':
|
|
237
|
+
return linearUpdateTime > stackMemoryUpdateTime;
|
|
238
|
+
case 'manual':
|
|
239
|
+
return false;
|
|
240
|
+
default:
|
|
241
|
+
return false;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
/**
|
|
245
|
+
* Get tasks that haven't been synced to Linear yet
|
|
246
|
+
*/
|
|
247
|
+
getUnsyncedTasks() {
|
|
248
|
+
const activeTasks = this.taskStore.getActiveTasks();
|
|
249
|
+
return activeTasks.filter((task) => !this.mappings.has(task.id) && !task.external_refs?.linear);
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* Get tasks that have been modified since last sync
|
|
253
|
+
*/
|
|
254
|
+
getModifiedTasks() {
|
|
255
|
+
const tasks = [];
|
|
256
|
+
for (const [taskId, mapping] of this.mappings) {
|
|
257
|
+
const task = this.taskStore.getTask(taskId);
|
|
258
|
+
if (task && task.timestamp * 1000 > mapping.lastSyncTimestamp) {
|
|
259
|
+
tasks.push(task);
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
return tasks;
|
|
263
|
+
}
|
|
264
|
+
/**
|
|
265
|
+
* Update task with Linear reference
|
|
266
|
+
*/
|
|
267
|
+
updateTaskWithLinearRef(taskId, linearIssue) {
|
|
268
|
+
const task = this.taskStore.getTask(taskId);
|
|
269
|
+
if (!task)
|
|
270
|
+
return;
|
|
271
|
+
// This would need a method in PebblesTaskStore to update external_refs
|
|
272
|
+
// For now, we'll track this in our mappings
|
|
273
|
+
logger.info(`Task ${taskId} mapped to Linear ${linearIssue.identifier}`);
|
|
274
|
+
}
|
|
275
|
+
// Mapping utilities
|
|
276
|
+
formatDescriptionForLinear(task) {
|
|
277
|
+
let description = task.description || '';
|
|
278
|
+
description += `\n\n---\n**StackMemory Context:**\n`;
|
|
279
|
+
description += `- Task ID: ${task.id}\n`;
|
|
280
|
+
description += `- Frame: ${task.frame_id}\n`;
|
|
281
|
+
description += `- Created: ${new Date(task.created_at * 1000).toISOString()}\n`;
|
|
282
|
+
if (task.tags.length > 0) {
|
|
283
|
+
description += `- Tags: ${task.tags.join(', ')}\n`;
|
|
284
|
+
}
|
|
285
|
+
if (task.depends_on.length > 0) {
|
|
286
|
+
description += `- Dependencies: ${task.depends_on.join(', ')}\n`;
|
|
287
|
+
}
|
|
288
|
+
return description;
|
|
289
|
+
}
|
|
290
|
+
mapPriorityToLinear(priority) {
|
|
291
|
+
const map = {
|
|
292
|
+
low: 1, // Low priority in Linear
|
|
293
|
+
medium: 2, // Medium priority in Linear
|
|
294
|
+
high: 3, // High priority in Linear
|
|
295
|
+
urgent: 4, // Urgent priority in Linear
|
|
296
|
+
};
|
|
297
|
+
return map[priority] || 2;
|
|
298
|
+
}
|
|
299
|
+
mapTagsToLinear(_tags) {
|
|
300
|
+
// In a full implementation, this would map StackMemory tags to Linear label IDs
|
|
301
|
+
// For now, return undefined to skip label assignment
|
|
302
|
+
return undefined;
|
|
303
|
+
}
|
|
304
|
+
mapLinearStateToStatus(linearStateType) {
|
|
305
|
+
switch (linearStateType) {
|
|
306
|
+
case 'backlog':
|
|
307
|
+
case 'unstarted':
|
|
308
|
+
return 'pending';
|
|
309
|
+
case 'started':
|
|
310
|
+
return 'in_progress';
|
|
311
|
+
case 'completed':
|
|
312
|
+
return 'completed';
|
|
313
|
+
case 'cancelled':
|
|
314
|
+
return 'cancelled';
|
|
315
|
+
default:
|
|
316
|
+
return 'pending';
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
// Persistence for mappings
|
|
320
|
+
loadMappings() {
|
|
321
|
+
// In a full implementation, this would load from a file or database
|
|
322
|
+
// For now, start with empty mappings
|
|
323
|
+
this.mappings.clear();
|
|
324
|
+
}
|
|
325
|
+
saveMappings() {
|
|
326
|
+
// In a full implementation, this would save to a file or database
|
|
327
|
+
logger.info(`Saved ${this.mappings.size} task mappings`);
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
/**
|
|
331
|
+
* Default sync configuration
|
|
332
|
+
*/
|
|
333
|
+
export const DEFAULT_SYNC_CONFIG = {
|
|
334
|
+
enabled: false,
|
|
335
|
+
direction: 'bidirectional',
|
|
336
|
+
autoSync: false,
|
|
337
|
+
conflictResolution: 'newest_wins',
|
|
338
|
+
syncInterval: 15, // minutes
|
|
339
|
+
};
|
|
340
|
+
//# sourceMappingURL=linear-sync.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"linear-sync.js","sourceRoot":"","sources":["../../../src/integrations/linear-sync.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAO3C,OAAO,EACL,YAAY,GAGb,MAAM,oBAAoB,CAAC;AAwC5B,MAAM,OAAO,gBAAgB;IACnB,SAAS,CAAmB;IAC5B,YAAY,CAAe;IAC3B,WAAW,CAAoB;IAC/B,MAAM,CAAa;IACnB,QAAQ,GAA6B,IAAI,GAAG,EAAE,CAAC;IAEvD,YACE,SAA2B,EAC3B,WAA8B,EAC9B,MAAkB;QAElB,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;QAC3B,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QAC/B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,YAAY,GAAG,IAAI,YAAY,CAAC;YACnC,MAAM,EAAE,EAAE,EAAE,gCAAgC;SAC7C,CAAC,CAAC;QAEH,IAAI,CAAC,YAAY,EAAE,CAAC;IACtB,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,IAAI;QACR,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;YACzB,OAAO;gBACL,OAAO,EAAE,KAAK;gBACd,MAAM,EAAE,EAAE,QAAQ,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE;gBAClD,SAAS,EAAE,EAAE;gBACb,MAAM,EAAE,CAAC,kBAAkB,CAAC;aAC7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}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* StackMemory MCP Server - Local Instance
|
|
4
|
+
* This runs locally and provides context to Claude Code
|
|
5
|
+
*/
|
|
6
|
+
declare class LocalStackMemoryMCP {
|
|
7
|
+
private server;
|
|
8
|
+
private db;
|
|
9
|
+
private projectRoot;
|
|
10
|
+
private frameManager;
|
|
11
|
+
private taskStore;
|
|
12
|
+
private projectId;
|
|
13
|
+
private contexts;
|
|
14
|
+
constructor();
|
|
15
|
+
private findProjectRoot;
|
|
16
|
+
private initDB;
|
|
17
|
+
private loadInitialContext;
|
|
18
|
+
private getProjectId;
|
|
19
|
+
private getProjectInfo;
|
|
20
|
+
private addContext;
|
|
21
|
+
private loadStoredContexts;
|
|
22
|
+
private setupHandlers;
|
|
23
|
+
private handleGetContext;
|
|
24
|
+
private handleAddDecision;
|
|
25
|
+
private handleStartFrame;
|
|
26
|
+
private handleCloseFrame;
|
|
27
|
+
private handleAddAnchor;
|
|
28
|
+
private handleGetHotStack;
|
|
29
|
+
private logAttention;
|
|
30
|
+
private handleCreateTask;
|
|
31
|
+
private handleUpdateTaskStatus;
|
|
32
|
+
private handleGetActiveTasks;
|
|
33
|
+
private handleGetTaskMetrics;
|
|
34
|
+
private handleAddTaskDependency;
|
|
35
|
+
start(): Promise<void>;
|
|
36
|
+
}
|
|
37
|
+
export default LocalStackMemoryMCP;
|
|
38
|
+
//# sourceMappingURL=mcp-server.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-server.d.ts","sourceRoot":"","sources":["../../../src/mcp/mcp-server.ts"],"names":[],"mappings":";AACA;;;GAGG;AAwBH,cAAM,mBAAmB;IACvB,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,EAAE,CAAoB;IAC9B,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,YAAY,CAAe;IACnC,OAAO,CAAC,SAAS,CAAmB;IAIpC,OAAO,CAAC,SAAS,CAAS;IAC1B,OAAO,CAAC,QAAQ,CAA+B;;IAsD/C,OAAO,CAAC,eAAe;IAWvB,OAAO,CAAC,MAAM;IA8Bd,OAAO,CAAC,kBAAkB;IA+B1B,OAAO,CAAC,YAAY;IAepB,OAAO,CAAC,cAAc;IAetB,OAAO,CAAC,UAAU;IAgBlB,OAAO,CAAC,kBAAkB;IAgB1B,OAAO,CAAC,aAAa;YAmSP,gBAAgB;YA6ChB,iBAAiB;YAejB,gBAAgB;YAqChB,gBAAgB;YAoChB,eAAe;YAuBf,iBAAiB;IA8D/B,OAAO,CAAC,YAAY;YAYN,gBAAgB;YA4ChB,sBAAsB;YAkCtB,oBAAoB;YA2CpB,oBAAoB;YAmCpB,uBAAuB;IAiC/B,KAAK;CAKZ;AAGD,eAAe,mBAAmB,CAAC"}
|