@almadar/patterns 2.7.0 → 2.7.1
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/component-mapping.json +1 -1
- package/dist/event-contracts.json +1 -1
- package/dist/index.d.ts +86 -4
- package/dist/index.js +75 -4
- package/dist/index.js.map +1 -1
- package/dist/patterns-registry.json +31 -1
- package/dist/registry.json +31 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var version$3 = "1.0.0";
|
|
2
|
-
var exportedAt$3 = "2026-03-
|
|
2
|
+
var exportedAt$3 = "2026-03-15T00:20:59.995Z";
|
|
3
3
|
var patterns = {
|
|
4
4
|
"entity-table": {
|
|
5
5
|
type: "entity-table",
|
|
@@ -3420,6 +3420,24 @@ var patterns = {
|
|
|
3420
3420
|
"string"
|
|
3421
3421
|
],
|
|
3422
3422
|
description: "Additional CSS classes"
|
|
3423
|
+
},
|
|
3424
|
+
mode: {
|
|
3425
|
+
types: [
|
|
3426
|
+
"string"
|
|
3427
|
+
],
|
|
3428
|
+
description: "Display mode: floating (fixed overlay) or inline (block element)"
|
|
3429
|
+
},
|
|
3430
|
+
defaultTab: {
|
|
3431
|
+
types: [
|
|
3432
|
+
"string"
|
|
3433
|
+
],
|
|
3434
|
+
description: "Default active tab id"
|
|
3435
|
+
},
|
|
3436
|
+
schema: {
|
|
3437
|
+
types: [
|
|
3438
|
+
"object"
|
|
3439
|
+
],
|
|
3440
|
+
description: "Raw schema for EventDispatcherTab payload extraction"
|
|
3423
3441
|
}
|
|
3424
3442
|
}
|
|
3425
3443
|
},
|
|
@@ -6202,6 +6220,12 @@ var patterns = {
|
|
|
6202
6220
|
],
|
|
6203
6221
|
description: "onClick prop"
|
|
6204
6222
|
},
|
|
6223
|
+
event: {
|
|
6224
|
+
types: [
|
|
6225
|
+
"string"
|
|
6226
|
+
],
|
|
6227
|
+
description: "event prop"
|
|
6228
|
+
},
|
|
6205
6229
|
icon: {
|
|
6206
6230
|
types: [
|
|
6207
6231
|
"string"
|
|
@@ -7350,6 +7374,12 @@ var patterns = {
|
|
|
7350
7374
|
],
|
|
7351
7375
|
description: "Include HUD slots"
|
|
7352
7376
|
},
|
|
7377
|
+
hudMode: {
|
|
7378
|
+
types: [
|
|
7379
|
+
"string"
|
|
7380
|
+
],
|
|
7381
|
+
description: "HUD positioning mode: 'fixed' (default, viewport-relative) or 'inline' (container-relative, uses sticky)"
|
|
7382
|
+
},
|
|
7353
7383
|
includeFloating: {
|
|
7354
7384
|
types: [
|
|
7355
7385
|
"boolean"
|
|
@@ -17605,7 +17635,7 @@ var integratorsRegistry = {
|
|
|
17605
17635
|
};
|
|
17606
17636
|
|
|
17607
17637
|
var version$1 = "1.0.0";
|
|
17608
|
-
var exportedAt$1 = "2026-03-
|
|
17638
|
+
var exportedAt$1 = "2026-03-15T00:20:59.995Z";
|
|
17609
17639
|
var mappings = {
|
|
17610
17640
|
"page-header": {
|
|
17611
17641
|
component: "PageHeader",
|
|
@@ -18833,7 +18863,7 @@ var componentMapping = {
|
|
|
18833
18863
|
};
|
|
18834
18864
|
|
|
18835
18865
|
var version = "1.0.0";
|
|
18836
|
-
var exportedAt = "2026-03-
|
|
18866
|
+
var exportedAt = "2026-03-15T00:20:59.995Z";
|
|
18837
18867
|
var contracts = {
|
|
18838
18868
|
form: {
|
|
18839
18869
|
emits: [
|
|
@@ -22994,6 +23024,18 @@ declare function getOrbAllowedPatterns(): Record<string, Array<{
|
|
|
22994
23024
|
* Derives everything from the registry. No hardcoded pattern lists.
|
|
22995
23025
|
*/
|
|
22996
23026
|
declare function getOrbAllowedPatternsCompact(): string;
|
|
23027
|
+
/**
|
|
23028
|
+
* Get a slim one-line-per-pattern catalog for Gate 3.5 pattern selection.
|
|
23029
|
+
* Format: "- pattern-name: one-line description"
|
|
23030
|
+
* Much smaller than the full compact reference (~800 tokens vs ~3,500).
|
|
23031
|
+
*/
|
|
23032
|
+
declare function getOrbAllowedPatternsSlim(): string;
|
|
23033
|
+
/**
|
|
23034
|
+
* Get compact markdown reference for a filtered subset of patterns.
|
|
23035
|
+
* Used by Gate 4 after Gate 3.5 selects the relevant patterns.
|
|
23036
|
+
* Includes all props (not just top 5) since we're showing fewer patterns.
|
|
23037
|
+
*/
|
|
23038
|
+
declare function getOrbAllowedPatternsFiltered(patternNames: string[]): string;
|
|
22997
23039
|
|
|
22998
23040
|
/**
|
|
22999
23041
|
* Pattern Recommender
|
|
@@ -25376,6 +25418,18 @@ declare const registry: {
|
|
|
25376
25418
|
types: string[];
|
|
25377
25419
|
description: string;
|
|
25378
25420
|
};
|
|
25421
|
+
mode: {
|
|
25422
|
+
types: string[];
|
|
25423
|
+
description: string;
|
|
25424
|
+
};
|
|
25425
|
+
defaultTab: {
|
|
25426
|
+
types: string[];
|
|
25427
|
+
description: string;
|
|
25428
|
+
};
|
|
25429
|
+
schema: {
|
|
25430
|
+
types: string[];
|
|
25431
|
+
description: string;
|
|
25432
|
+
};
|
|
25379
25433
|
};
|
|
25380
25434
|
};
|
|
25381
25435
|
button: {
|
|
@@ -27260,6 +27314,10 @@ declare const registry: {
|
|
|
27260
27314
|
types: string[];
|
|
27261
27315
|
description: string;
|
|
27262
27316
|
};
|
|
27317
|
+
event: {
|
|
27318
|
+
types: string[];
|
|
27319
|
+
description: string;
|
|
27320
|
+
};
|
|
27263
27321
|
icon: {
|
|
27264
27322
|
types: string[];
|
|
27265
27323
|
description: string;
|
|
@@ -28039,6 +28097,10 @@ declare const registry: {
|
|
|
28039
28097
|
types: string[];
|
|
28040
28098
|
description: string;
|
|
28041
28099
|
};
|
|
28100
|
+
hudMode: {
|
|
28101
|
+
types: string[];
|
|
28102
|
+
description: string;
|
|
28103
|
+
};
|
|
28042
28104
|
includeFloating: {
|
|
28043
28105
|
types: string[];
|
|
28044
28106
|
description: string;
|
|
@@ -36746,6 +36808,18 @@ declare const PATTERN_REGISTRY: {
|
|
|
36746
36808
|
types: string[];
|
|
36747
36809
|
description: string;
|
|
36748
36810
|
};
|
|
36811
|
+
mode: {
|
|
36812
|
+
types: string[];
|
|
36813
|
+
description: string;
|
|
36814
|
+
};
|
|
36815
|
+
defaultTab: {
|
|
36816
|
+
types: string[];
|
|
36817
|
+
description: string;
|
|
36818
|
+
};
|
|
36819
|
+
schema: {
|
|
36820
|
+
types: string[];
|
|
36821
|
+
description: string;
|
|
36822
|
+
};
|
|
36749
36823
|
};
|
|
36750
36824
|
};
|
|
36751
36825
|
button: {
|
|
@@ -38630,6 +38704,10 @@ declare const PATTERN_REGISTRY: {
|
|
|
38630
38704
|
types: string[];
|
|
38631
38705
|
description: string;
|
|
38632
38706
|
};
|
|
38707
|
+
event: {
|
|
38708
|
+
types: string[];
|
|
38709
|
+
description: string;
|
|
38710
|
+
};
|
|
38633
38711
|
icon: {
|
|
38634
38712
|
types: string[];
|
|
38635
38713
|
description: string;
|
|
@@ -39409,6 +39487,10 @@ declare const PATTERN_REGISTRY: {
|
|
|
39409
39487
|
types: string[];
|
|
39410
39488
|
description: string;
|
|
39411
39489
|
};
|
|
39490
|
+
hudMode: {
|
|
39491
|
+
types: string[];
|
|
39492
|
+
description: string;
|
|
39493
|
+
};
|
|
39412
39494
|
includeFloating: {
|
|
39413
39495
|
types: string[];
|
|
39414
39496
|
description: string;
|
|
@@ -48332,4 +48414,4 @@ declare function getComponentForPattern(patternType: string): string | null;
|
|
|
48332
48414
|
*/
|
|
48333
48415
|
declare function isEntityAwarePattern(patternType: string): boolean;
|
|
48334
48416
|
|
|
48335
|
-
export { type AnyPatternConfig, COMPONENT_MAPPING, EVENT_CONTRACTS, INTEGRATORS_REGISTRY, PATTERN_REGISTRY, PATTERN_TYPES, type PatternConfig, type PatternProps, type PatternPropsMap, type PatternRecommendation, type PatternType, type RecommendationContext, buildRecommendationContext, componentMapping, eventContracts, formatRecommendationsForPrompt, generatePatternDescription, getAllPatternTypes, getComponentForPattern, getOrbAllowedPatterns, getOrbAllowedPatternsCompact, getPatternActionsRef, getPatternDefinition, getPatternMetadata, getPatternPropsCompact, getPatternsGroupedByCategory, integratorsRegistry, isEntityAwarePattern, isValidPatternType, patternsRegistry, recommendPatterns, registry };
|
|
48417
|
+
export { type AnyPatternConfig, COMPONENT_MAPPING, EVENT_CONTRACTS, INTEGRATORS_REGISTRY, PATTERN_REGISTRY, PATTERN_TYPES, type PatternConfig, type PatternProps, type PatternPropsMap, type PatternRecommendation, type PatternType, type RecommendationContext, buildRecommendationContext, componentMapping, eventContracts, formatRecommendationsForPrompt, generatePatternDescription, getAllPatternTypes, getComponentForPattern, getOrbAllowedPatterns, getOrbAllowedPatternsCompact, getOrbAllowedPatternsFiltered, getOrbAllowedPatternsSlim, getPatternActionsRef, getPatternDefinition, getPatternMetadata, getPatternPropsCompact, getPatternsGroupedByCategory, integratorsRegistry, isEntityAwarePattern, isValidPatternType, patternsRegistry, recommendPatterns, registry };
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// src/patterns-registry.json
|
|
2
2
|
var patterns_registry_default = {
|
|
3
3
|
version: "1.0.0",
|
|
4
|
-
exportedAt: "2026-03-
|
|
4
|
+
exportedAt: "2026-03-15T00:20:59.995Z",
|
|
5
5
|
patterns: {
|
|
6
6
|
"entity-table": {
|
|
7
7
|
type: "entity-table",
|
|
@@ -3422,6 +3422,24 @@ var patterns_registry_default = {
|
|
|
3422
3422
|
"string"
|
|
3423
3423
|
],
|
|
3424
3424
|
description: "Additional CSS classes"
|
|
3425
|
+
},
|
|
3426
|
+
mode: {
|
|
3427
|
+
types: [
|
|
3428
|
+
"string"
|
|
3429
|
+
],
|
|
3430
|
+
description: "Display mode: floating (fixed overlay) or inline (block element)"
|
|
3431
|
+
},
|
|
3432
|
+
defaultTab: {
|
|
3433
|
+
types: [
|
|
3434
|
+
"string"
|
|
3435
|
+
],
|
|
3436
|
+
description: "Default active tab id"
|
|
3437
|
+
},
|
|
3438
|
+
schema: {
|
|
3439
|
+
types: [
|
|
3440
|
+
"object"
|
|
3441
|
+
],
|
|
3442
|
+
description: "Raw schema for EventDispatcherTab payload extraction"
|
|
3425
3443
|
}
|
|
3426
3444
|
}
|
|
3427
3445
|
},
|
|
@@ -6204,6 +6222,12 @@ var patterns_registry_default = {
|
|
|
6204
6222
|
],
|
|
6205
6223
|
description: "onClick prop"
|
|
6206
6224
|
},
|
|
6225
|
+
event: {
|
|
6226
|
+
types: [
|
|
6227
|
+
"string"
|
|
6228
|
+
],
|
|
6229
|
+
description: "event prop"
|
|
6230
|
+
},
|
|
6207
6231
|
icon: {
|
|
6208
6232
|
types: [
|
|
6209
6233
|
"string"
|
|
@@ -7352,6 +7376,12 @@ var patterns_registry_default = {
|
|
|
7352
7376
|
],
|
|
7353
7377
|
description: "Include HUD slots"
|
|
7354
7378
|
},
|
|
7379
|
+
hudMode: {
|
|
7380
|
+
types: [
|
|
7381
|
+
"string"
|
|
7382
|
+
],
|
|
7383
|
+
description: "HUD positioning mode: 'fixed' (default, viewport-relative) or 'inline' (container-relative, uses sticky)"
|
|
7384
|
+
},
|
|
7355
7385
|
includeFloating: {
|
|
7356
7386
|
types: [
|
|
7357
7387
|
"boolean"
|
|
@@ -17484,7 +17514,7 @@ var integrators_registry_default = {
|
|
|
17484
17514
|
// src/component-mapping.json
|
|
17485
17515
|
var component_mapping_default = {
|
|
17486
17516
|
version: "1.0.0",
|
|
17487
|
-
exportedAt: "2026-03-
|
|
17517
|
+
exportedAt: "2026-03-15T00:20:59.995Z",
|
|
17488
17518
|
mappings: {
|
|
17489
17519
|
"page-header": {
|
|
17490
17520
|
component: "PageHeader",
|
|
@@ -18710,7 +18740,7 @@ var component_mapping_default = {
|
|
|
18710
18740
|
// src/event-contracts.json
|
|
18711
18741
|
var event_contracts_default = {
|
|
18712
18742
|
version: "1.0.0",
|
|
18713
|
-
exportedAt: "2026-03-
|
|
18743
|
+
exportedAt: "2026-03-15T00:20:59.995Z",
|
|
18714
18744
|
contracts: {
|
|
18715
18745
|
form: {
|
|
18716
18746
|
emits: [
|
|
@@ -20162,6 +20192,47 @@ function getOrbAllowedPatternsCompact() {
|
|
|
20162
20192
|
}
|
|
20163
20193
|
return lines.join("\n");
|
|
20164
20194
|
}
|
|
20195
|
+
function getOrbAllowedPatternsSlim() {
|
|
20196
|
+
const grouped = getOrbAllowedPatterns();
|
|
20197
|
+
const lines = [];
|
|
20198
|
+
for (const [cat, items] of Object.entries(grouped).sort()) {
|
|
20199
|
+
lines.push(`## ${cat}`);
|
|
20200
|
+
for (const item of items) {
|
|
20201
|
+
const desc = item.description.split("\n")[0].slice(0, 80);
|
|
20202
|
+
lines.push(`- ${item.name}: ${desc}`);
|
|
20203
|
+
}
|
|
20204
|
+
}
|
|
20205
|
+
return lines.join("\n");
|
|
20206
|
+
}
|
|
20207
|
+
function getOrbAllowedPatternsFiltered(patternNames) {
|
|
20208
|
+
const nameSet = new Set(patternNames);
|
|
20209
|
+
const patterns = patterns_registry_default.patterns || {};
|
|
20210
|
+
const grouped = {};
|
|
20211
|
+
for (const [name, def] of Object.entries(patterns)) {
|
|
20212
|
+
if (!nameSet.has(name)) continue;
|
|
20213
|
+
const cat = def.category || "uncategorized";
|
|
20214
|
+
const propsSchema = def.propsSchema || {};
|
|
20215
|
+
const allProps = Object.keys(propsSchema);
|
|
20216
|
+
if (!grouped[cat]) grouped[cat] = [];
|
|
20217
|
+
grouped[cat].push({
|
|
20218
|
+
name,
|
|
20219
|
+
description: def.description || "",
|
|
20220
|
+
allProps
|
|
20221
|
+
});
|
|
20222
|
+
}
|
|
20223
|
+
const lines = [];
|
|
20224
|
+
for (const [cat, items] of Object.entries(grouped).sort()) {
|
|
20225
|
+
lines.push(`#### ${cat} (${items.length})`);
|
|
20226
|
+
lines.push("| Pattern | Description | Props |");
|
|
20227
|
+
lines.push("|---------|-------------|-------|");
|
|
20228
|
+
for (const item of items) {
|
|
20229
|
+
const desc = item.description.split("\n")[0].slice(0, 60);
|
|
20230
|
+
lines.push(`| \`${item.name}\` | ${desc} | ${item.allProps.join(", ")} |`);
|
|
20231
|
+
}
|
|
20232
|
+
lines.push("");
|
|
20233
|
+
}
|
|
20234
|
+
return lines.join("\n");
|
|
20235
|
+
}
|
|
20165
20236
|
|
|
20166
20237
|
// src/helpers/pattern-recommender.ts
|
|
20167
20238
|
var DOMAIN_KEYWORDS = {
|
|
@@ -20339,6 +20410,6 @@ function isEntityAwarePattern(patternType) {
|
|
|
20339
20410
|
return "entity" in propsSchema;
|
|
20340
20411
|
}
|
|
20341
20412
|
|
|
20342
|
-
export { COMPONENT_MAPPING, EVENT_CONTRACTS, INTEGRATORS_REGISTRY, PATTERN_REGISTRY, PATTERN_TYPES, buildRecommendationContext, component_mapping_default as componentMapping, event_contracts_default as eventContracts, formatRecommendationsForPrompt, generatePatternDescription, getAllPatternTypes, getComponentForPattern, getOrbAllowedPatterns, getOrbAllowedPatternsCompact, getPatternActionsRef, getPatternDefinition, getPatternMetadata, getPatternPropsCompact, getPatternsGroupedByCategory, integrators_registry_default as integratorsRegistry, isEntityAwarePattern, isValidPatternType, patterns_registry_default as patternsRegistry, recommendPatterns, registry };
|
|
20413
|
+
export { COMPONENT_MAPPING, EVENT_CONTRACTS, INTEGRATORS_REGISTRY, PATTERN_REGISTRY, PATTERN_TYPES, buildRecommendationContext, component_mapping_default as componentMapping, event_contracts_default as eventContracts, formatRecommendationsForPrompt, generatePatternDescription, getAllPatternTypes, getComponentForPattern, getOrbAllowedPatterns, getOrbAllowedPatternsCompact, getOrbAllowedPatternsFiltered, getOrbAllowedPatternsSlim, getPatternActionsRef, getPatternDefinition, getPatternMetadata, getPatternPropsCompact, getPatternsGroupedByCategory, integrators_registry_default as integratorsRegistry, isEntityAwarePattern, isValidPatternType, patterns_registry_default as patternsRegistry, recommendPatterns, registry };
|
|
20343
20414
|
//# sourceMappingURL=index.js.map
|
|
20344
20415
|
//# sourceMappingURL=index.js.map
|