open-grid 1.2.0 → 1.3.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.
Files changed (294) hide show
  1. package/CHANGELOG.md +376 -353
  2. package/README.md +1 -1
  3. package/dist/OpenGrid-B7m7ei7f.cjs +7385 -0
  4. package/dist/OpenGrid-CeUdO_fM.js +7398 -0
  5. package/dist/index-CeJ-0-80.cjs +260 -0
  6. package/dist/index-DnarQ4eR.js +266 -0
  7. package/dist/index-DrCPRuYi.js +548 -0
  8. package/dist/index-JjfWY3Bt.cjs +520 -0
  9. package/dist/open-grid-base.css +12 -1
  10. package/dist/open-grid-react.cjs +27 -1
  11. package/dist/open-grid-react.js +22 -82
  12. package/dist/open-grid-vue.cjs +31 -1
  13. package/dist/open-grid-vue.js +29 -79
  14. package/dist/open-grid.cjs +272 -6
  15. package/dist/open-grid.js +177 -266
  16. package/dist/types/bench/perf.d.ts +14 -8
  17. package/dist/types/core/AppearanceResolver.d.ts +98 -11
  18. package/dist/types/core/CFRenderBridge.d.ts +13 -0
  19. package/dist/types/core/CellEditManager.d.ts +73 -0
  20. package/dist/types/core/CellEventHandler.d.ts +99 -2
  21. package/dist/types/core/CellTypeRegistry.d.ts +24 -0
  22. package/dist/types/core/ChartManager.d.ts +51 -3
  23. package/dist/types/core/ColumnLayout.d.ts +100 -2
  24. package/dist/types/core/ContextMenu.d.ts +43 -2
  25. package/dist/types/core/CrossGridController.d.ts +86 -15
  26. package/dist/types/core/CrossGridMapper.d.ts +43 -5
  27. package/dist/types/core/CrossGridRegistry.d.ts +36 -2
  28. package/dist/types/core/DataLayer.d.ts +210 -15
  29. package/dist/types/core/DetailManager.d.ts +106 -15
  30. package/dist/types/core/DragVisuals.d.ts +33 -4
  31. package/dist/types/core/EventEmitter.d.ts +54 -0
  32. package/dist/types/core/ExportManager.d.ts +66 -1
  33. package/dist/types/core/ExtensionPointRegistry.d.ts +160 -14
  34. package/dist/types/core/FilterPanel.d.ts +17 -2
  35. package/dist/types/core/FilterSelect.d.ts +37 -13
  36. package/dist/types/core/FindBarManager.d.ts +26 -0
  37. package/dist/types/core/FlatRowModel.d.ts +54 -11
  38. package/dist/types/core/FooterManager.d.ts +53 -1
  39. package/dist/types/core/FormulaController.d.ts +139 -10
  40. package/dist/types/core/FormulaEngine.d.ts +15 -4
  41. package/dist/types/core/GridComposer.d.ts +54 -6
  42. package/dist/types/core/GridRenderer.d.ts +143 -10
  43. package/dist/types/core/GridShuttle.d.ts +44 -4
  44. package/dist/types/core/GroupEngine.d.ts +68 -10
  45. package/dist/types/core/GroupTreeManager.d.ts +86 -2
  46. package/dist/types/core/IconRegistry.d.ts +56 -9
  47. package/dist/types/core/KeyboardManager.d.ts +88 -4
  48. package/dist/types/core/MaskingEngine.d.ts +10 -9
  49. package/dist/types/core/MathUtils.d.ts +58 -5
  50. package/dist/types/core/MergeEngine.d.ts +45 -10
  51. package/dist/types/core/MutationService.d.ts +113 -10
  52. package/dist/types/core/OGDecimal.d.ts +144 -13
  53. package/dist/types/core/OpenGrid.d.ts +99 -0
  54. package/dist/types/core/OrgChart.d.ts +56 -1
  55. package/dist/types/core/OverrideKernel.d.ts +59 -15
  56. package/dist/types/core/Pagination.d.ts +38 -4
  57. package/dist/types/core/PivotEngine.d.ts +37 -0
  58. package/dist/types/core/RangeSelectionManager.d.ts +121 -7
  59. package/dist/types/core/RenderController.d.ts +56 -0
  60. package/dist/types/core/RowDragDrop.d.ts +52 -6
  61. package/dist/types/core/RowManager.d.ts +55 -0
  62. package/dist/types/core/SkinRegistry.d.ts +55 -15
  63. package/dist/types/core/SortFilterManager.d.ts +80 -1
  64. package/dist/types/core/TreeEngine.d.ts +60 -6
  65. package/dist/types/core/TriggerManager.d.ts +46 -0
  66. package/dist/types/core/VirtualScroll.d.ts +64 -0
  67. package/dist/types/core/WorksheetManager.d.ts +61 -2
  68. package/dist/types/core/XmlConverter.d.ts +56 -23
  69. package/dist/types/core/a11y/AccessibilityAdapter.d.ts +103 -0
  70. package/dist/types/core/a11y/AriaIntent.d.ts +34 -0
  71. package/dist/types/core/a11y/KeyboardInteractionModel.d.ts +64 -0
  72. package/dist/types/core/a11y/LiveRegionController.d.ts +89 -0
  73. package/dist/types/core/a11y/OverlayStack.d.ts +36 -0
  74. package/dist/types/core/a11y/VisualEquivRegistry.d.ts +37 -0
  75. package/dist/types/core/a11y/index.d.ts +13 -0
  76. package/dist/types/core/a11y/ports.d.ts +24 -0
  77. package/dist/types/core/appearance/Appearance.d.ts +68 -0
  78. package/dist/types/core/appearance/AppearanceAxis.d.ts +94 -0
  79. package/dist/types/core/appearance/AppearanceComposer.d.ts +45 -0
  80. package/dist/types/core/appearance/AppearanceProvider.d.ts +50 -0
  81. package/dist/types/core/appearance/AppearanceView.d.ts +51 -0
  82. package/dist/types/core/appearance/DensityRegistry.d.ts +36 -0
  83. package/dist/types/core/appearance/ResolvedAppearanceSnapshot.d.ts +84 -0
  84. package/dist/types/core/appearance/TextureRegistry.d.ts +32 -0
  85. package/dist/types/core/appearance/ThemeMetaRegistry.d.ts +67 -0
  86. package/dist/types/core/appearance/axisAdapters.d.ts +37 -0
  87. package/dist/types/core/appearance/defaults.d.ts +10 -0
  88. package/dist/types/core/appearance/index.d.ts +20 -0
  89. package/dist/types/core/appearance/tokenCatalog.d.ts +30 -0
  90. package/dist/types/core/cf/CFEngine.d.ts +56 -0
  91. package/dist/types/core/cf/CFEvaluator.d.ts +24 -0
  92. package/dist/types/core/cf/CFRule.d.ts +127 -0
  93. package/dist/types/core/cf/ColorScale.d.ts +49 -0
  94. package/dist/types/core/cf/InkResolver.d.ts +33 -0
  95. package/dist/types/core/cf/appearance.d.ts +20 -0
  96. package/dist/types/core/cf/encoders.d.ts +61 -0
  97. package/dist/types/core/cf/eval-types.d.ts +93 -0
  98. package/dist/types/core/cf/index.d.ts +21 -0
  99. package/dist/types/core/cf/lineage.d.ts +32 -0
  100. package/dist/types/core/cf/predicates.d.ts +27 -0
  101. package/dist/types/core/cf/serialize.d.ts +46 -0
  102. package/dist/types/core/chart/CanvasAdapter.d.ts +50 -1
  103. package/dist/types/core/chart/DataExtractor.d.ts +53 -12
  104. package/dist/types/core/chart/a11y.d.ts +22 -0
  105. package/dist/types/core/chart/chart-type-registry.d.ts +53 -0
  106. package/dist/types/core/chart/downsample-report.d.ts +36 -0
  107. package/dist/types/core/chart/downsample.d.ts +26 -1
  108. package/dist/types/core/chart/engine/ChartEngineRegistry.d.ts +52 -0
  109. package/dist/types/core/chart/geometry.d.ts +96 -0
  110. package/dist/types/core/chart/hittest.d.ts +21 -3
  111. package/dist/types/core/chart/palette.d.ts +96 -12
  112. package/dist/types/core/chart/parity.d.ts +12 -0
  113. package/dist/types/core/chart/provenance.d.ts +47 -0
  114. package/dist/types/core/chart/scales.d.ts +28 -1
  115. package/dist/types/core/chart/scene.d.ts +102 -0
  116. package/dist/types/core/chart/server.d.ts +36 -0
  117. package/dist/types/core/chart/surfaces/CanvasSurface.d.ts +48 -0
  118. package/dist/types/core/chart/surfaces/ServerRasterSurface.d.ts +26 -0
  119. package/dist/types/core/chart/surfaces/SvgSurface.d.ts +24 -0
  120. package/dist/types/core/chart/surfaces/pattern-overlay.d.ts +24 -0
  121. package/dist/types/core/chart/types.d.ts +107 -10
  122. package/dist/types/core/command/CommandBus.d.ts +51 -0
  123. package/dist/types/core/command/CommandRegistry.d.ts +43 -0
  124. package/dist/types/core/command/CommandStack.d.ts +38 -0
  125. package/dist/types/core/command/ICommand.d.ts +110 -0
  126. package/dist/types/core/command/commands/CellWriteCommand.d.ts +32 -0
  127. package/dist/types/core/command/commands/CompositeCommand.d.ts +17 -0
  128. package/dist/types/core/command/commands/RowCommands.d.ts +39 -0
  129. package/dist/types/core/command/index.d.ts +9 -0
  130. package/dist/types/core/command/support.d.ts +51 -0
  131. package/dist/types/core/coordinate/ColumnMetrics.d.ts +30 -0
  132. package/dist/types/core/coordinate/CoordinateKernel.d.ts +88 -0
  133. package/dist/types/core/coordinate/FrozenPanes.d.ts +29 -0
  134. package/dist/types/core/coordinate/MergeSourceAdapter.d.ts +18 -0
  135. package/dist/types/core/coordinate/NodeBudget.d.ts +33 -0
  136. package/dist/types/core/coordinate/ResizeGovernor.d.ts +50 -0
  137. package/dist/types/core/coordinate/RowMetrics.d.ts +37 -0
  138. package/dist/types/core/coordinate/ViewPermutation.d.ts +23 -0
  139. package/dist/types/core/coordinate/index.d.ts +10 -0
  140. package/dist/types/core/coordinate/ports.d.ts +45 -0
  141. package/dist/types/core/coordinate/types.d.ts +76 -0
  142. package/dist/types/core/detail/DetailGlyph.d.ts +42 -7
  143. package/dist/types/core/detail/DetailSplice.d.ts +42 -11
  144. package/dist/types/core/detail/DetailState.d.ts +80 -11
  145. package/dist/types/core/detail/SubgridCache.d.ts +72 -10
  146. package/dist/types/core/detail/index.d.ts +8 -0
  147. package/dist/types/core/domain/AggregateResult.d.ts +54 -0
  148. package/dist/types/core/domain/CellAddress.d.ts +61 -0
  149. package/dist/types/core/domain/CellValueAccess.d.ts +29 -0
  150. package/dist/types/core/domain/Delta.d.ts +37 -0
  151. package/dist/types/core/domain/DomainValue.d.ts +80 -0
  152. package/dist/types/core/domain/Missing.d.ts +65 -0
  153. package/dist/types/core/domain/Money.d.ts +42 -0
  154. package/dist/types/core/domain/NormalizationBasis.d.ts +47 -0
  155. package/dist/types/core/domain/Plain.d.ts +45 -0
  156. package/dist/types/core/domain/Quantity.d.ts +32 -0
  157. package/dist/types/core/domain/Ratios.d.ts +100 -0
  158. package/dist/types/core/domain/ThresholdSet.d.ts +46 -0
  159. package/dist/types/core/domain/ValueType.d.ts +71 -0
  160. package/dist/types/core/domain/rounding.d.ts +25 -0
  161. package/dist/types/core/domain/strategies.d.ts +38 -0
  162. package/dist/types/core/editors/CellEditor.d.ts +29 -2
  163. package/dist/types/core/editors/DateEditor.d.ts +18 -0
  164. package/dist/types/core/editors/SelectEditor.d.ts +29 -0
  165. package/dist/types/core/export/ChannelRegistry.d.ts +18 -0
  166. package/dist/types/core/export/ExportManifest.d.ts +13 -0
  167. package/dist/types/core/export/GridArtifactSource.d.ts +62 -0
  168. package/dist/types/core/export/Provenance.d.ts +34 -0
  169. package/dist/types/core/export/StreamPump.d.ts +28 -0
  170. package/dist/types/core/export/channels/CsvChannel.d.ts +20 -0
  171. package/dist/types/core/export/channels/JsonChannel.d.ts +18 -0
  172. package/dist/types/core/export/channels/XlsxChannel.d.ts +53 -0
  173. package/dist/types/core/export/channels/XmlChannel.d.ts +21 -0
  174. package/dist/types/core/export/channels/capabilities.d.ts +13 -0
  175. package/dist/types/core/export/index.d.ts +24 -0
  176. package/dist/types/core/export/print/OutputChannelAdapter.d.ts +61 -0
  177. package/dist/types/core/export/print/Paginator.d.ts +48 -0
  178. package/dist/types/core/export/print/PrintRenderTarget.d.ts +36 -0
  179. package/dist/types/core/export/sinks.d.ts +40 -0
  180. package/dist/types/core/export/types.d.ts +211 -0
  181. package/dist/types/core/extension/DeprecationManager.d.ts +42 -0
  182. package/dist/types/core/extension/IExtension.d.ts +90 -0
  183. package/dist/types/core/extension/Registry.d.ts +142 -0
  184. package/dist/types/core/extension/SlotRegistry.d.ts +46 -0
  185. package/dist/types/core/extension/adapters.d.ts +44 -0
  186. package/dist/types/core/extension/conformance.d.ts +47 -0
  187. package/dist/types/core/extension/index.d.ts +16 -0
  188. package/dist/types/core/extension/registries.d.ts +31 -0
  189. package/dist/types/core/extension/reserved.d.ts +10 -0
  190. package/dist/types/core/format/DisplayFormatter.d.ts +47 -0
  191. package/dist/types/core/format/FormatCache.d.ts +20 -0
  192. package/dist/types/core/format/FormatterRegistry.d.ts +22 -0
  193. package/dist/types/core/format/grammar/AstRenderer.d.ts +10 -0
  194. package/dist/types/core/format/grammar/FormatCompiler.d.ts +16 -0
  195. package/dist/types/core/format/index.d.ts +55 -0
  196. package/dist/types/core/format/pipeline/DomainTypeResolver.d.ts +8 -0
  197. package/dist/types/core/format/pipeline/LocaleFormat.d.ts +11 -0
  198. package/dist/types/core/format/pipeline/ValueInterpreter.d.ts +8 -0
  199. package/dist/types/core/format/policy/MaskPolicy.d.ts +8 -0
  200. package/dist/types/core/format/policy/NegativePolicy.d.ts +12 -0
  201. package/dist/types/core/format/policy/NullPolicy.d.ts +10 -0
  202. package/dist/types/core/format/policy/TruncatePolicy.d.ts +11 -0
  203. package/dist/types/core/format/types.d.ts +292 -0
  204. package/dist/types/core/formula/CalcCacheStore.d.ts +89 -0
  205. package/dist/types/core/formula/CalcProvenance.d.ts +44 -0
  206. package/dist/types/core/formula/CalcService.d.ts +137 -0
  207. package/dist/types/core/formula/CyclePathReporter.d.ts +28 -0
  208. package/dist/types/core/formula/FormulaEvaluator.d.ts +35 -1
  209. package/dist/types/core/formula/FormulaGraph.d.ts +84 -7
  210. package/dist/types/core/formula/FormulaParser.d.ts +9 -0
  211. package/dist/types/core/formula/FormulaStore.d.ts +63 -1
  212. package/dist/types/core/formula/FunctionRegistry.d.ts +138 -0
  213. package/dist/types/core/formula/Generation.d.ts +86 -0
  214. package/dist/types/core/formula/RecalcCoordinator.d.ts +151 -9
  215. package/dist/types/core/formula/ReferenceRewriter.d.ts +81 -0
  216. package/dist/types/core/formula/functions/essential.d.ts +3 -0
  217. package/dist/types/core/formula/functions/extended/index.d.ts +10 -0
  218. package/dist/types/core/formula/normalizeRefs.d.ts +34 -3
  219. package/dist/types/core/formula/numericLiteral.d.ts +11 -1
  220. package/dist/types/core/formula/serializeFormula.d.ts +10 -1
  221. package/dist/types/core/formula/types.d.ts +71 -8
  222. package/dist/types/core/host/CapabilityRegistry.d.ts +61 -0
  223. package/dist/types/core/host/GridHostDriver.d.ts +27 -0
  224. package/dist/types/core/host/GridHostPort.d.ts +37 -0
  225. package/dist/types/core/host/SliceOwnershipGuard.d.ts +27 -0
  226. package/dist/types/core/host/archCheck.d.ts +26 -0
  227. package/dist/types/core/host/index.d.ts +6 -0
  228. package/dist/types/core/host/reconcile.d.ts +22 -0
  229. package/dist/types/core/i18n/LocaleContext.d.ts +40 -0
  230. package/dist/types/core/i18n/types.d.ts +26 -1
  231. package/dist/types/core/icons/bootstrap-icons.d.ts +4 -2
  232. package/dist/types/core/quality/ContrastAuditor.d.ts +64 -0
  233. package/dist/types/core/quality/DeterminismKernel.d.ts +68 -0
  234. package/dist/types/core/quality/PerfBaseline.d.ts +23 -0
  235. package/dist/types/core/quality/PerfSpec.d.ts +95 -0
  236. package/dist/types/core/quality/RealBrowserGate.d.ts +69 -0
  237. package/dist/types/core/quality/RegressionJudge.d.ts +35 -0
  238. package/dist/types/core/quality/ReleaseGate.d.ts +94 -0
  239. package/dist/types/core/quality/VisualRegression.d.ts +74 -0
  240. package/dist/types/core/quality/hooks.d.ts +53 -0
  241. package/dist/types/core/quality/index.d.ts +20 -0
  242. package/dist/types/core/quality/pixelMetrics.d.ts +24 -0
  243. package/dist/types/core/range/ClipboardCodec.d.ts +46 -4
  244. package/dist/types/core/range/FillEngine.d.ts +69 -9
  245. package/dist/types/core/range/RangeModel.d.ts +100 -13
  246. package/dist/types/core/range/RangeQuery.d.ts +24 -2
  247. package/dist/types/core/range/types.d.ts +27 -11
  248. package/dist/types/core/realtime/BackpressureScheduler.d.ts +0 -0
  249. package/dist/types/core/realtime/FreshnessClock.d.ts +34 -0
  250. package/dist/types/core/realtime/IRealtimeSource.d.ts +82 -0
  251. package/dist/types/core/realtime/LiveStateGuard.d.ts +23 -0
  252. package/dist/types/core/realtime/PollingSource.d.ts +42 -0
  253. package/dist/types/core/realtime/RealtimeController.d.ts +54 -0
  254. package/dist/types/core/realtime/RtAnnouncePolicy.d.ts +53 -0
  255. package/dist/types/core/realtime/RtApplyCommand.d.ts +29 -0
  256. package/dist/types/core/realtime/RtChartTargetTrigger.d.ts +26 -0
  257. package/dist/types/core/realtime/StreamingSource.d.ts +47 -0
  258. package/dist/types/core/realtime/backoff.d.ts +12 -0
  259. package/dist/types/core/realtime/index.d.ts +13 -0
  260. package/dist/types/core/realtime/ports.d.ts +80 -0
  261. package/dist/types/core/render/CellApplier.d.ts +18 -0
  262. package/dist/types/core/render/CellErrorBoundary.d.ts +65 -0
  263. package/dist/types/core/render/CellPipeline.d.ts +39 -0
  264. package/dist/types/core/render/CellRenderRequest.d.ts +209 -0
  265. package/dist/types/core/render/CellStageRegistry.d.ts +53 -0
  266. package/dist/types/core/render/OverlayCompositor.d.ts +38 -0
  267. package/dist/types/core/render/RenderBudget.d.ts +67 -0
  268. package/dist/types/core/render/contrast.d.ts +33 -0
  269. package/dist/types/core/render/index.d.ts +35 -0
  270. package/dist/types/core/render/stages/BackgroundStage.d.ts +14 -0
  271. package/dist/types/core/render/stages/DecoratorStage.d.ts +12 -0
  272. package/dist/types/core/render/stages/OverlayStage.d.ts +12 -0
  273. package/dist/types/core/render/stages/ValueRendererStage.d.ts +15 -0
  274. package/dist/types/core/render/stages/index.d.ts +14 -0
  275. package/dist/types/core/renderers/CellRenderer.d.ts +100 -8
  276. package/dist/types/core/state/AutosaveController.d.ts +63 -0
  277. package/dist/types/core/state/IStatePersistence.d.ts +59 -0
  278. package/dist/types/core/state/MultiTabGuard.d.ts +33 -0
  279. package/dist/types/core/state/SchemaMigrator.d.ts +33 -0
  280. package/dist/types/core/state/SemVerPolicy.d.ts +39 -0
  281. package/dist/types/core/state/StateCodec.d.ts +75 -0
  282. package/dist/types/core/state/index.d.ts +6 -0
  283. package/dist/types/core/types.d.ts +17 -0
  284. package/dist/types/react/OpenGrid.d.ts +54 -0
  285. package/dist/types/react/index.d.ts +5 -0
  286. package/dist/types/realtime/index.d.ts +1 -0
  287. package/dist/types/vue/index.d.ts +5 -0
  288. package/dist/types/vue/types.d.ts +35 -0
  289. package/dist/xlsx.min-BQ1o3sB6.cjs +11793 -0
  290. package/dist/{xlsx.min-Wavxcamn.js → xlsx.min-Bbz2ZypC.js} +453 -566
  291. package/package.json +112 -110
  292. package/dist/OpenGrid-B0Spm0rU.js +0 -10404
  293. package/dist/OpenGrid-CuXj0isp.cjs +0 -97
  294. package/dist/xlsx.min-Bx-LxWOf.cjs +0 -138
@@ -0,0 +1,37 @@
1
+ import { GridOptions, ColumnDef } from '../types.js';
2
+ import { CapabilitySnapshot } from './CapabilityRegistry.js';
3
+ /**
4
+ * 프레임워크가 그리드에 반영을 요청하는 최소 옵션 델타(구조/데이터/외관).
5
+ * / Minimal option delta a framework can request the grid to apply.
6
+ */
7
+ export interface GridPropsPatch<T = any> {
8
+ readonly data?: readonly T[];
9
+ readonly columns?: readonly ColumnDef<T>[];
10
+ readonly theme?: string;
11
+ readonly skin?: string;
12
+ /** props 로 못 덮는 나머지 코어 옵션(부분). 구조 옵션 변경은 재생성 유발(reconcile). */
13
+ readonly options?: Partial<GridOptions<T>>;
14
+ }
15
+ /** subscribe 해지자. 프레임워크 unmount 시 반드시 호출(누수 방지). / Unsubscribe handle. */
16
+ export type Unsubscribe = () => void;
17
+ /** 포트 이벤트 핸들러(프레임워크 무관). / Framework-agnostic event handler. */
18
+ export type HostEventHandler = (payload: any) => void;
19
+ /**
20
+ * 코어↔호스트의 유일한 안정 경계(semver 공개 계약).
21
+ * 어떤 멤버도 React/Vue/jQuery 타입을 참조하지 않는다(DIP 근인 제거, REQ-TX-848).
22
+ * / The single stable seam between core and host. No member references any framework type.
23
+ */
24
+ export interface GridHostPort<T extends Record<string, any> = any> {
25
+ /** 컨테이너에 그리드를 마운트. 이미 마운트면 no-op+dev 경고. 멱등 계약. */
26
+ mount(container: HTMLElement, options: GridOptions<T>): void;
27
+ /** 마운트 해제 + 모든 리스너 정리(파사드 destroy 위임). 멱등. */
28
+ unmount(): void;
29
+ /** 얕은 diff 로 최소 변이 적용(reconcile 정책). 미마운트 시 dev 경고. */
30
+ updateProps(patch: GridPropsPatch<T>): void;
31
+ /** 코어 이벤트 구독. 반환 해지자를 어댑터가 생명주기에 묶어 반드시 해제. */
32
+ subscribe(event: string, handler: HostEventHandler): Unsubscribe;
33
+ /** (읽기 전용) 능력 프로브 — 패리티 매트릭스가 질의. 도메인 상태 노출 아님. */
34
+ readonly capabilities: CapabilitySnapshot;
35
+ /** 마운트 여부(테스트·어댑터 방어용, 읽기 전용). */
36
+ readonly mounted: boolean;
37
+ }
@@ -0,0 +1,27 @@
1
+ import { SliceKey } from '../coordinate/ports.js';
2
+ /** REQ-TX-841 위반 — 비소유 모듈이 좌표 슬라이스를 직접 변이하려 함. / Slice-ownership violation. */
3
+ export declare class SliceOwnershipViolation extends Error {
4
+ readonly slice: SliceKey;
5
+ readonly owner: string;
6
+ readonly detail: string;
7
+ constructor(slice: SliceKey, owner: string, detail: string);
8
+ }
9
+ /** 소유자 조회. / Look up the declared owner of a slice. */
10
+ export declare function ownerOf(slice: SliceKey): string;
11
+ /**
12
+ * 소유권 assert — 비소유 액터가 슬라이스를 변이하려 하면 throw.
13
+ * 소유 모듈이 변이 진입점에서 스스로를 신고하는 저비용 가드.
14
+ * / Assert ownership; throws if a non-owner actor attempts to mutate the slice.
15
+ */
16
+ export declare function assertSliceOwner(slice: SliceKey, actor: string): void;
17
+ /**
18
+ * 좌표 슬라이스를 읽기전용으로 봉인 — 커널은 슬라이스를 read-only 입력으로만 받으므로,
19
+ * 소비 경로에서 어떤 직접 쓰기(프로퍼티 대입·delete·배열 변이 메서드)든 즉시 SliceOwnershipViolation.
20
+ * 비소유 모듈의 우발적 변이를 런타임에서 결정론적으로 탐지한다(dev throw, REQ-TX-841).
21
+ *
22
+ * `owner` 인자가 주어지면 소유자 자신은 변이를 허용(신뢰 경계) — 그 외 전부 차단.
23
+ * / Seal a coordinate slice as read-only. Any direct write throws a SliceOwnershipViolation.
24
+ */
25
+ export declare function sealSlice<V extends object>(slice: SliceKey, value: V, owner?: string): V;
26
+ /** 전체 슬라이스 키 목록(테스트·게이트 열거용). / All slice keys. */
27
+ export declare const SLICE_KEYS: SliceKey[];
@@ -0,0 +1,26 @@
1
+ export type ArchRuleId = 'core-imports-framework' | 'headless-dom-global' | 'a11y-aria-write' | 'getcomputedstyle-scope';
2
+ export interface ArchViolation {
3
+ readonly rule: ArchRuleId;
4
+ readonly path: string;
5
+ readonly line: number;
6
+ readonly detail: string;
7
+ }
8
+ export interface SourceFile {
9
+ readonly path: string;
10
+ readonly content: string;
11
+ }
12
+ export interface ArchCheckOptions {
13
+ /** 헤드리스 순수 dir 접두사(이 안에서 DOM 전역 금지). / Headless-pure dir prefixes. */
14
+ readonly headlessDirs?: readonly string[];
15
+ /** 코어 접두사(이 안에서 프레임워크 import 금지). / Core prefix (no framework imports). */
16
+ readonly coreDir?: string;
17
+ /** 경계 화이트리스트(헤드리스 규칙 예외 — humble shell·boundary). / Boundary whitelist. */
18
+ readonly boundaryDirs?: readonly string[];
19
+ }
20
+ /**
21
+ * 정적 적합성 검사. 위반 목록 반환(빈 배열=통과).
22
+ * / Static fitness check. Returns the list of violations (empty = pass).
23
+ */
24
+ export declare function archCheck(files: readonly SourceFile[], opts?: ArchCheckOptions): ArchViolation[];
25
+ /** 위반을 사람이 읽는 리포트로 직렬화(CLI 소비). / Serialize violations for the CLI. */
26
+ export declare function formatViolations(violations: readonly ArchViolation[]): string;
@@ -0,0 +1,6 @@
1
+ export type { GridHostPort, GridPropsPatch, Unsubscribe, HostEventHandler, } from './GridHostPort.js';
2
+ export { createGridHost, GridHostDriver } from './GridHostDriver.js';
3
+ export { reconcile, STRUCTURAL_KEYS, type ReconcilePlan, type StructuralKey, } from './reconcile.js';
4
+ export { CapabilityRegistry, CAPABILITY_REGISTRY, computeParity, type Capability, type CapabilitySnapshot, type AdapterConformance, type AdapterId, type Priority, type ParityMatrix, type ParityCell, type AdapterParity, } from './CapabilityRegistry.js';
5
+ export { sealSlice, assertSliceOwner, ownerOf, SliceOwnershipViolation, SLICE_KEYS, } from './SliceOwnershipGuard.js';
6
+ export { archCheck, formatViolations, type ArchViolation, type ArchRuleId, type SourceFile, type ArchCheckOptions, } from './archCheck.js';
@@ -0,0 +1,22 @@
1
+ import { GridOptions } from '../types.js';
2
+ import { GridPropsPatch } from './GridHostPort.js';
3
+ /**
4
+ * 구조 옵션 키(변경 시 그리드 재생성 필요). / Structural option keys (require recreation).
5
+ * 컬럼 형태·고정열·트리/그룹·페이징 등 조립 위상에 영향을 주는 옵션들.
6
+ */
7
+ export declare const STRUCTURAL_KEYS: readonly ["columns", "frozenColumns", "frozenRows", "treeMode", "groupBy", "masterDetail", "pagination", "virtualScroll", "multiHeader"];
8
+ export type StructuralKey = (typeof STRUCTURAL_KEYS)[number];
9
+ /** updateProps 재조정 계획. / Reconcile plan for updateProps. */
10
+ export interface ReconcilePlan {
11
+ /** 구조 옵션 변경 → 재생성. / Structural change → recreate. */
12
+ readonly recreate: boolean;
13
+ readonly data: boolean;
14
+ readonly theme: boolean;
15
+ readonly skin: boolean;
16
+ readonly options: boolean;
17
+ }
18
+ /**
19
+ * 순수 함수(헤드리스·결정론). 구조 vs in-place 를 옵션 키 분류표로 판정.
20
+ * / Pure, deterministic. Classifies structural vs in-place using the key table.
21
+ */
22
+ export declare function reconcile<T>(prev: GridOptions<T>, patch: GridPropsPatch<T>): ReconcilePlan;
@@ -0,0 +1,40 @@
1
+ import { LocaleRegistry } from './LocaleRegistry.js';
2
+ import { LocaleMeta, LocaleMessageKey, MessageParams } from './types.js';
3
+ /**
4
+ * `LocaleMeta` 조회 파사드 — 값객체/포맷터/정렬/검색이 주입받는 단일 컨텍스트 포트.
5
+ * `LocaleRegistry.meta()` 를 감싸 문화별 Intl 객체를 메모이즈 제공한다.
6
+ * / The single culture-context port injected into VOs/formatters/sort/search. Wraps
7
+ * `LocaleRegistry.meta()` and memoizes per-locale Intl objects.
8
+ */
9
+ export declare class LocaleContextProvider {
10
+ private readonly _registry;
11
+ private readonly _subscribers;
12
+ private _collator;
13
+ private _numberFmt;
14
+ private _dateTimeFmt;
15
+ /** 메모 무효화 기준 — 활성 로케일. 변경 감지 시 캐시 clear. / Memo-invalidation basis: active locale. */
16
+ private _memoLocale;
17
+ constructor(registry: LocaleRegistry);
18
+ /** 활성 로케일 문화 컨텍스트(폴백 병합 후). / Active-locale culture context (after fallback merge). */
19
+ meta(): LocaleMeta;
20
+ /** 정렬/검색 tie-break 콜레이터(메모이즈). collation 규칙은 `LocaleMeta.collation` 에서 조회. / Collator (memoized). */
21
+ collator(): Intl.Collator;
22
+ /** 숫자 포맷(메모이즈). numbering/currency 기본값은 `LocaleMeta` 에서 보강. / NumberFormat (memoized). */
23
+ numberFormat(opts?: Intl.NumberFormatOptions): Intl.NumberFormat;
24
+ /** 날짜/시간 포맷(메모이즈). calendar/timeZone 기본값은 `LocaleMeta` 에서 보강. / DateTimeFormat (memoized). */
25
+ dateTimeFormat(opts?: Intl.DateTimeFormatOptions): Intl.DateTimeFormat;
26
+ /** i18n 메시지 해석(어댑터·공지가 하드코딩 대신 이걸로). / Message resolution. */
27
+ t(key: LocaleMessageKey | string, params?: MessageParams): string;
28
+ /**
29
+ * 활성 로케일 전환의 정본 경로 — 레지스트리 전환 + 메모 무효화 + 구독자 통지(어댑터 onLocaleChange 배선).
30
+ * / The canonical active-locale switch: registry.setActive + memo invalidation + notify subscribers.
31
+ */
32
+ setLocale(id: string): void;
33
+ /** 활성 로케일 변경 구독. 해제 함수 반환. / Subscribe to active-locale change; returns an unsubscribe fn. */
34
+ onChange(cb: () => void): () => void;
35
+ /** 외부에서 레지스트리를 직접 전환한 경우의 수동 메모 갱신·통지. / Manual refresh when the registry changed externally. */
36
+ refresh(): void;
37
+ private _syncMemo;
38
+ private _invalidate;
39
+ private _notify;
40
+ }
@@ -234,7 +234,14 @@ export type PartialLocaleMessages = {
234
234
  export type LocaleMessageKey = {
235
235
  [S in keyof LocaleMessages]: `${S & string}.${keyof LocaleMessages[S] & string}`;
236
236
  }[keyof LocaleMessages];
237
- /** 로케일 포맷 파라미터(문자열 아님): Intl 태그·방향·수출 폰트. / Locale format params (non-string): Intl tag, direction, export font. */
237
+ /**
238
+ * 문화 규칙 단일 컨텍스트(REQ-T9-816, DD-12 §2.4). 값객체·포맷터·정렬·검색이 문화를 **오직 여기서만**
239
+ * 조회한다(불변식 3). 아래 확장 필드는 전부 additive·옵셔널 — 기존 3필드·소비처 불변(semver 하위호환).
240
+ * ★대표 소유 = DD-12: DD-04 `FormatContext.locale`·DD-15 `ExportRunCtx.locale` 는 이 타입을 import(재선언 금지).
241
+ * / Single culture context (REQ-T9-816, DD-12 §2.4). The only lawful culture-lookup path (invariant 3).
242
+ * The extension fields below are all additive & optional — original 3 fields/consumers unchanged.
243
+ * ★Canonical owner = DD-12; DD-04/DD-15 import this type (no re-declaration).
244
+ */
238
245
  export interface LocaleMeta {
239
246
  /** BCP-47 태그(toLocaleString/lang/인쇄 템플릿용). 예 'ko-KR'. / BCP-47 tag (for toLocaleString/lang/print template). e.g. 'ko-KR'. */
240
247
  readonly intlLocale: string;
@@ -242,6 +249,24 @@ export interface LocaleMeta {
242
249
  readonly dir?: 'ltr' | 'rtl';
243
250
  /** Excel 내보내기 기본 폰트. / Default font for Excel export. */
244
251
  readonly exportFont?: string;
252
+ /** 기본 통화코드(ISO 4217) — Money 미지정 시 폴백. / Default currency (ISO 4217). */
253
+ readonly currency?: string;
254
+ /** 달력 체계(gregory/japanese/…) — Intl.DateTimeFormat 위임. / Calendar system. */
255
+ readonly calendar?: string;
256
+ /** 콜레이션 규칙(정렬 tie-break·대소문자·발음구별) — Intl.Collator 옵션. / Collation for sort/search. */
257
+ readonly collation?: {
258
+ readonly sensitivity?: 'base' | 'accent' | 'case' | 'variant';
259
+ readonly numeric?: boolean;
260
+ readonly caseFirst?: 'upper' | 'lower' | 'false';
261
+ };
262
+ /** 숫자 체계(latn/arab/…). / Numbering system. */
263
+ readonly numbering?: string;
264
+ /** 시간대. / Time zone. */
265
+ readonly timeZone?: string;
266
+ /** 주 시작요일(0=일·1=월·6=토). / First day of week. */
267
+ readonly firstDayOfWeek?: 0 | 1 | 6;
268
+ /** 텍스트팽창 계수(레이아웃 예산 힌트·의사로케일). 예 de≈1.35, 의사로케일=1.4(REQ-T9-817). / Text-expansion factor. */
269
+ readonly textExpansion?: number;
245
270
  }
246
271
  /** register() 결과 — 누락 키 정직 신호(막지 않음). / register() result — honest missing-key signal (never blocks). */
247
272
  export interface LocaleRegisterResult {
@@ -1,9 +1,11 @@
1
- /** 모든 큐레이션 글리프 공통 viewBox(Bootstrap Icons 16px 그리드). */
1
+ /** 모든 큐레이션 글리프 공통 viewBox(Bootstrap Icons 16px 그리드). / Common viewBox for all curated glyphs (Bootstrap Icons 16px grid). */
2
2
  export declare const ICON_VIEWBOX = "0 0 16 16";
3
3
  /**
4
4
  * symbolId → SVG 내부 마크업(<path>/<g>). Bootstrap Icons v1.13.1(MIT)에서 큐레이션.
5
5
  * `eye-reveal` 는 예외(기존 마스킹 셀 커스텀 글리프, 행동 보존용).
6
+ * / symbolId → inner SVG markup (<path>/<g>). Curated from Bootstrap Icons v1.13.1 (MIT).
7
+ * `eye-reveal` is the exception (existing masking-cell custom glyph, kept for behavior parity).
6
8
  */
7
9
  export declare const BOOTSTRAP_ICONS: Readonly<Record<string, string>>;
8
- /** 큐레이션에 포함된 symbol 개수(테스트/디버깅용). `eye-reveal`(커스텀 1) 포함. */
10
+ /** 큐레이션에 포함된 symbol 개수(테스트/디버깅용). `eye-reveal`(커스텀 1) 포함. / Count of curated symbols (for tests/debugging), including `eye-reveal` (1 custom). */
9
11
  export declare const BOOTSTRAP_ICON_COUNT: number;
@@ -0,0 +1,64 @@
1
+ /** 대비 검사 쌍 — 전경/배경 + 요구 임계. / A contrast pair — fg/bg + required threshold. */
2
+ export interface ContrastPair {
3
+ readonly fg: string;
4
+ readonly bg: string;
5
+ readonly kind: 'bodyText' | 'largeText' | 'uiComponent' | 'graphic';
6
+ readonly context: {
7
+ theme: string;
8
+ skin: string;
9
+ state: string;
10
+ tokenId: string;
11
+ };
12
+ }
13
+ /** WCAG 임계: bodyText ≥4.5, large/ui/graphic ≥3.0. 의도적 고정(표준 SSOT). / WCAG minimums. */
14
+ export declare const CONTRAST_MIN: Readonly<Record<ContrastPair['kind'], number>>;
15
+ /** 단일 쌍 판정. / A single pair verdict. */
16
+ export interface ContrastVerdict {
17
+ readonly pair: ContrastPair;
18
+ readonly ratio: number;
19
+ readonly required: number;
20
+ readonly status: 'pass' | 'fail';
21
+ }
22
+ /**
23
+ * 외관 토큰 스냅샷 입력(헤드리스 계약). DD-11 `ResolvedAppearanceSnapshot` 구현 시 대체 import.
24
+ * 감사기는 토큰 값을 만들지 않고, 스냅샷이 선언한 대비 관련 쌍을 순회·판정만 한다.
25
+ * / Appearance token snapshot input (headless contract). To be replaced by DD-11's
26
+ * `ResolvedAppearanceSnapshot` import once implemented.
27
+ */
28
+ export interface AppearanceSnapshotLike {
29
+ readonly theme: string;
30
+ readonly skin: string;
31
+ readonly state: string;
32
+ /** 토큰 id → 결정된 색(hex/rgb). / token id → resolved color. */
33
+ readonly colors: Readonly<Record<string, string>>;
34
+ /** 감사 대상 대비 쌍(전경 토큰·배경 토큰·종류). / contrast pairs to audit. */
35
+ readonly pairs: ReadonlyArray<{
36
+ readonly fgToken: string;
37
+ readonly bgToken: string;
38
+ readonly kind: ContrastPair['kind'];
39
+ }>;
40
+ }
41
+ /**
42
+ * 대비 감사기 — 순수 계산(DOM 무관, 헤드리스).
43
+ * CRC: 색쌍→대비비→판정 | 협력: DD-11(토큰 스냅샷 입력)·ReleaseGate(a11y 게이트)·palette.ts(산식).
44
+ * 불변식: 미달 1건이라도 있으면 실패. 산식 재구현 0 — palette.contrastRatio 위임.
45
+ * / Contrast auditor — pure computation (DOM-agnostic, headless).
46
+ */
47
+ export declare class ContrastAuditor {
48
+ /**
49
+ * 테마×스킨×상태 스냅샷에서 색쌍 인벤토리 생성(누락 토큰=미커버). 결정론 순서.
50
+ * / Build a pair inventory from snapshots (missing token = uncovered). Deterministic order.
51
+ */
52
+ enumeratePairs(snapshots: readonly AppearanceSnapshotLike[]): ContrastPair[];
53
+ /**
54
+ * 스냅샷의 대비 쌍 중 토큰 값이 누락된 항목 지목(미커버=완결성 위반, TX-830).
55
+ * / Report pairs whose token colors are missing (uncovered = completeness violation).
56
+ */
57
+ coverageGaps(snapshots: readonly AppearanceSnapshotLike[]): string[];
58
+ /** WCAG 2.2 상대휘도 대비비 = palette.contrastRatio 위임(자체 산식 없음). / Delegated ratio. */
59
+ ratio(fg: string, bg: string): number;
60
+ /** 전수 판정. / Audit every pair. */
61
+ audit(pairs: readonly ContrastPair[]): ContrastVerdict[];
62
+ /** 미달 목록만 필터(리포트용). / Filter to failures only (for reporting). */
63
+ failures(verdicts: readonly ContrastVerdict[]): ContrastVerdict[];
64
+ }
@@ -0,0 +1,68 @@
1
+ /** 주입 clock — 프로덕션=시스템시계, 테스트=고정/전진 가능한 가짜시계. / Injected clock. */
2
+ export interface IClock {
3
+ now(): number;
4
+ raf(cb: (t: number) => void): number;
5
+ cancelRaf(id: number): void;
6
+ }
7
+ /** 주입 RNG — 시드 기반 결정론 난수(테스트), 프로덕션=암묵 시드. / Injected RNG. */
8
+ export interface IRandom {
9
+ next(): number;
10
+ seed(s: number): void;
11
+ }
12
+ /**
13
+ * 결정론 커널 — 비결정성 소스의 단일 주입 지점.
14
+ * CRC: 시간/난수/idle-flush 통제 | 협력: 렌더 파이프라인·차트가 DI 로 소비.
15
+ * 불변식: 동일 seed·동일 clock 스텝 → 동일 출력. whenIdle 는 보류 flush 후 resolve.
16
+ * / Deterministic kernel — the single injection point for non-determinism.
17
+ */
18
+ export declare class DeterminismKernel {
19
+ readonly clock: IClock;
20
+ readonly random: IRandom;
21
+ constructor(clock: IClock, random: IRandom);
22
+ /**
23
+ * 모든 보류 작업(raf 렌더·이미지 로드·캔버스 draw·레이아웃 반영) 완료 후 resolve.
24
+ * 시각회귀 스위트가 캡처 직전 호출 → 플래키(찍는 타이밍 경쟁) 제거의 핵심.
25
+ * / Resolve after all pending work completes; called right before a golden capture.
26
+ */
27
+ whenIdle(): Promise<void>;
28
+ /** 보류 렌더를 강제 flush(동기 레이아웃 확정) — 골든 캡처용. / Force-flush pending renders. */
29
+ flushLayout(): void;
30
+ /**
31
+ * 결정론 직렬화: 키 순서·수치 포맷 고정(toJSON diff·회귀 비교 가능화).
32
+ * / Deterministic serialization: fixed key order + number format.
33
+ */
34
+ stableStringify(value: unknown): string;
35
+ /**
36
+ * 포맷터 순수성 검증 헬퍼: 동일 입력 2회 실행 산출물 바이트 동일 assert.
37
+ * 위반 시 throw(계약 테스트에서 순수성 위반 탐지).
38
+ * / Purity check helper: run fn twice and assert byte-identical output; throws on violation.
39
+ */
40
+ assertPure<T>(fn: () => T): void;
41
+ }
42
+ /** 프로덕션 clock — 시스템 시계/requestAnimationFrame 위임(헤드리스는 setTimeout 폴백). */
43
+ export declare class SystemClock implements IClock {
44
+ now(): number;
45
+ raf(cb: (t: number) => void): number;
46
+ cancelRaf(id: number): void;
47
+ }
48
+ /** 시드 기반 결정론 PRNG(mulberry32). / Seeded deterministic PRNG (mulberry32). */
49
+ export declare class SeededRandom implements IRandom {
50
+ private _state;
51
+ constructor(seed?: number);
52
+ next(): number;
53
+ seed(s: number): void;
54
+ }
55
+ /** 수동 전진 가짜 시계 — 예약된 raf 콜백을 결정론 실행. / Manually-advanced fake clock. */
56
+ export declare class FakeClock implements IClock {
57
+ private _now;
58
+ private _nextId;
59
+ private _pending;
60
+ constructor(start?: number);
61
+ now(): number;
62
+ raf(cb: (t: number) => void): number;
63
+ cancelRaf(id: number): void;
64
+ /** 시간 전진 + 예약된 raf 콜백 결정론 실행. / Advance time and run scheduled raf callbacks. */
65
+ advance(ms: number): void;
66
+ /** 보류 raf 콜백을 등록 순서대로 flush(현재 시각 전달). / Flush pending raf callbacks in registration order. */
67
+ flushRaf(): void;
68
+ }
@@ -0,0 +1,23 @@
1
+ /** 지표 단위. / Metric unit. */
2
+ export type MetricUnit = 'ms' | 'fps' | 'kb' | 'mb' | 'ratio' | 'nodes' | 'percent';
3
+ /** 단일 지표의 기준값 — 골든 파일(버전 관리)의 한 항목. / A single baseline entry (golden file). */
4
+ export interface BaselineEntry {
5
+ readonly metricId: string;
6
+ readonly value: number;
7
+ readonly unit: MetricUnit;
8
+ readonly capturedAt: string;
9
+ readonly commit: string;
10
+ }
11
+ /** 기준선 SSOT — 회귀 판정의 유일한 진실원. / Baseline SSOT — the single source of regression truth. */
12
+ export interface PerfBaseline {
13
+ readonly version: string;
14
+ readonly entries: Readonly<Record<string, BaselineEntry>>;
15
+ /** 지표별 허용 회귀율 오버라이드(기본 5%). fps는 하한이라 부호 반전. / per-metric tolerance overrides. */
16
+ readonly toleranceOverrides?: Readonly<Record<string, number>>;
17
+ }
18
+ /** 기본 허용 회귀율(%). / Default allowed regression (%). */
19
+ export declare const DEFAULT_REGRESSION_TOLERANCE_PCT = 5;
20
+ /** 빈 기준선(신규 지표 전부 status='new'). / An empty baseline (all metrics become 'new'). */
21
+ export declare const EMPTY_BASELINE: PerfBaseline;
22
+ /** 항목 배열로 기준선을 조립(편의). / Build a baseline from an entry array (convenience). */
23
+ export declare function makeBaseline(version: string, entries: readonly BaselineEntry[], toleranceOverrides?: Readonly<Record<string, number>>): PerfBaseline;
@@ -0,0 +1,95 @@
1
+ /** 규모 축 — 대표 워크로드. / Scale axis — representative workloads. */
2
+ export type Scale = '10k' | '100k' | '1m';
3
+ /** 조작 축 — 7대 핵심 조작(SPS 매트릭스 행). / Operation axis — the 7 core operations (SPS matrix rows). */
4
+ export type Operation = 'initialRender' | 'verticalScroll' | 'sort' | 'filter' | 'cellEditCommit' | 'cfRecalc' | 'themeSwitch';
5
+ /**
6
+ * 상호작용 지연 등급(TX-802) — 정성어를 수치로 못박는 SSOT. 모든 상호작용 예산은 이 등급 하나를 인용.
7
+ * / Interaction latency class (TX-802) — the SSOT that pins qualitative words to numbers.
8
+ */
9
+ export declare enum LatencyClass {
10
+ Instant = "instant",// keypress→paint ≤16.7ms (1프레임)
11
+ Immediate = "immediate",// 지각적 즉시 ≤100ms
12
+ Responsive = "responsive",// INP p75 ≤200ms
13
+ Heavy = "heavy"
14
+ }
15
+ /** 지연 등급별 상한(ms) — 의도적 고정(표준·SSOT). / Per-class latency ceilings (ms) — intentionally fixed. */
16
+ export declare const LATENCY_MS: Readonly<Record<LatencyClass, number>>;
17
+ /**
18
+ * 단일 예산 셀 — SPS 매트릭스의 한 칸(조작×규모).
19
+ * 불변식: 모든 임계는 상한(≤)이거나 하한(≥, fps만). null=해당 규모에서 미측정 명시(누락과 구분).
20
+ * / A single budget cell — one square (operation×scale) of the SPS matrix.
21
+ */
22
+ export interface PerfBudget {
23
+ readonly op: Operation;
24
+ readonly scale: Scale;
25
+ readonly p50Ms?: number;
26
+ readonly p95Ms: number;
27
+ readonly minFps?: number;
28
+ readonly maxDomNodes?: number;
29
+ readonly latencyClass: LatencyClass;
30
+ readonly reqIds: readonly string[];
31
+ }
32
+ /**
33
+ * per-feature 렌더 예산 — 가시행 기준 노드/프레임(TX-801 원장·TX-808 각론).
34
+ * "빈 그리드는 빨라도 CF 켜지면 무너진다" — 총론이 아닌 기능별 각론.
35
+ * / per-feature render budget — nodes/frame per visible row.
36
+ */
37
+ export interface FeatureBudget {
38
+ readonly feature: 'cf' | 'sparkline' | 'databar' | 'heatmap' | 'widgetCell' | 'chart';
39
+ readonly scale: Scale;
40
+ readonly nodesPerVisibleRow: number;
41
+ readonly frameMs: number;
42
+ readonly reqIds: readonly string[];
43
+ }
44
+ /** TTFR·페인트·CLS 예산(TX-801). mount→첫 페인트. / TTFR·paint·CLS budget (TX-801). */
45
+ export interface PaintBudget {
46
+ readonly scale: Scale;
47
+ readonly ttfrMs: number;
48
+ readonly ttiMs: number;
49
+ readonly cls: number;
50
+ }
51
+ /** 상주 메모리 상한 곡선(TX-804). / Resident-memory ceiling curve (TX-804). */
52
+ export interface MemoryBudget {
53
+ readonly scale: Scale;
54
+ readonly maxResidentMb: number;
55
+ readonly maxDetachedNodes: number;
56
+ }
57
+ /**
58
+ * 통합 성능 명세 — 단일 SSOT 애그리게이트.
59
+ * 이 객체 하나가 "성능이 무엇을 의미하는가"의 유일한 정본. CI·문서·대시보드가 모두 이걸 인용.
60
+ * / Aggregate performance spec — the single SSOT.
61
+ */
62
+ export interface PerfSpec {
63
+ readonly version: string;
64
+ readonly operations: readonly PerfBudget[];
65
+ readonly features: readonly FeatureBudget[];
66
+ readonly paint: readonly PaintBudget[];
67
+ readonly memory: readonly MemoryBudget[];
68
+ /** 커버리지 계약: 신규 기능 키가 등장했는데 예산이 없으면 게이트 실패(머지 금지 강제). */
69
+ readonly coveredFeatures: readonly string[];
70
+ }
71
+ /** 기본 성능 명세 SSOT(v1). / Default performance spec SSOT (v1). */
72
+ export declare const DEFAULT_PERF_SPEC: PerfSpec;
73
+ /** 지표 id 규약: `${op}.${scale}.p95` 등 — 기준선/판정 키의 SSOT. / Metric id convention. */
74
+ export declare function metricId(op: Operation, scale: Scale, kind?: 'p50' | 'p95' | 'fps'): string;
75
+ /** op×scale 예산 셀 조회. 없으면 undefined. / Look up the op×scale budget cell. */
76
+ export declare function findBudget(spec: PerfSpec, op: Operation, scale: Scale): PerfBudget | undefined;
77
+ /** 단일 예산 assert 결과. / Single budget assertion result. */
78
+ export interface BudgetCheck {
79
+ readonly metricId: string;
80
+ readonly measured: number;
81
+ readonly budget: number;
82
+ /** fps/처리량 하한 지표면 true(작을수록 실패). / true for a floor metric (smaller = failing). */
83
+ readonly isFloor: boolean;
84
+ readonly withinBudget: boolean;
85
+ }
86
+ /**
87
+ * 측정 p95(ms)를 op×scale 상한과 대조. 상한 초과 시 withinBudget=false.
88
+ * / Assert a measured p95 (ms) against the op×scale ceiling.
89
+ */
90
+ export declare function assertP95(spec: PerfSpec, op: Operation, scale: Scale, measuredMs: number): BudgetCheck;
91
+ /**
92
+ * 측정 fps 를 op×scale 하한과 대조(스크롤류). 하한 미만이면 withinBudget=false.
93
+ * / Assert a measured fps against the op×scale floor (scroll-like).
94
+ */
95
+ export declare function assertFps(spec: PerfSpec, op: Operation, scale: Scale, measuredFps: number): BudgetCheck;
@@ -0,0 +1,69 @@
1
+ /** 픽셀 어서션 — 특정 좌표의 RGBA 기대(허용오차). / Pixel assertion — expected RGBA at a coordinate. */
2
+ export interface PixelAssertion {
3
+ readonly kind: 'pixel';
4
+ readonly at: {
5
+ x: number;
6
+ y: number;
7
+ };
8
+ readonly expect: {
9
+ rgba: [number, number, number, number];
10
+ tolerance: number;
11
+ };
12
+ }
13
+ /** 노드수 어서션 — 셀렉터 라이브 노드 상한(TX-803). / Node-count assertion — live node cap. */
14
+ export interface NodeCountAssertion {
15
+ readonly kind: 'nodeCount';
16
+ readonly selector: string;
17
+ readonly max: number;
18
+ }
19
+ /** 렌더 의존 기능 1건. / One render-dependent feature case. */
20
+ export interface RenderGateCase {
21
+ readonly id: string;
22
+ readonly feature: 'chart' | 'microVisual' | 'virtualization' | 'pixelAlign' | 'merge' | 'frozen';
23
+ readonly fixtureId: string;
24
+ /** 최소 1개 이상의 픽셀/노드 어서션 필수(없으면 게이트가 이 케이스를 무효 처리). */
25
+ readonly assertions: ReadonlyArray<PixelAssertion | NodeCountAssertion>;
26
+ }
27
+ /** 단일 어서션 결과. / A single assertion result. */
28
+ export interface AssertionResult {
29
+ readonly assertion: PixelAssertion | NodeCountAssertion;
30
+ readonly measured: number | [number, number, number, number];
31
+ readonly status: 'pass' | 'fail';
32
+ }
33
+ /** 케이스 1건의 실행 결과. / One case's run result. */
34
+ export interface CaseResult {
35
+ readonly caseId: string;
36
+ readonly engine: string;
37
+ readonly status: 'pass' | 'fail' | 'invalid';
38
+ readonly assertions: readonly AssertionResult[];
39
+ }
40
+ /** 엔진별 개별 리포트(TX-828 크로스브라우저). / Per-engine report. */
41
+ export interface RenderGateReport {
42
+ readonly engine: string;
43
+ readonly cases: readonly CaseResult[];
44
+ readonly status: 'pass' | 'fail';
45
+ }
46
+ /** 실브라우저 케이스 구동 계약(Playwright 잡/스텁 주입). / Real-browser case runner contract. */
47
+ export interface ICaseRunner {
48
+ readonly engine: string;
49
+ run(c: RenderGateCase): Promise<readonly AssertionResult[]>;
50
+ }
51
+ /**
52
+ * 실브라우저 게이트 — 렌더 의존 기능 전수가 실픽셀/노드 어서션을 통과해야 완료.
53
+ * CRC: 케이스 등록·구동·판정·커버리지 | 협력: ICaseRunner(엔진별)·ReleaseGate.
54
+ * 불변식: 케이스마다 assertion ≥1(허위완료 방지). assertion=0 → invalid.
55
+ * / Real-browser gate — every render-dependent feature must pass real pixel/node assertions.
56
+ */
57
+ export declare class RealBrowserGate {
58
+ private readonly runner;
59
+ private readonly _cases;
60
+ constructor(runner: ICaseRunner);
61
+ /** 케이스 등록. / Register a case. */
62
+ registerCase(c: RenderGateCase): void;
63
+ /** 등록 케이스 수. / Registered case count. */
64
+ get caseCount(): number;
65
+ /** 실브라우저 구동 → 엔진 리포트. assertion=0 케이스는 invalid(허위완료 차단). / Run cases. */
66
+ run(): Promise<RenderGateReport>;
67
+ /** 커버리지: 렌더 의존 기능 목록 중 케이스 없는 항목 → 미커버 실패. / Coverage gaps. */
68
+ coverageGaps(featureInventory: readonly string[]): string[];
69
+ }
@@ -0,0 +1,35 @@
1
+ import { PerfSpec } from './PerfSpec.js';
2
+ import { PerfBaseline } from './PerfBaseline.js';
3
+ /** 한 지표의 판정 결과 — 게이트 산출의 최소 단위. / A single metric verdict — the atomic gate output. */
4
+ export interface MetricVerdict {
5
+ readonly metricId: string;
6
+ readonly measured: number;
7
+ readonly baseline: number | null;
8
+ readonly budget: number;
9
+ /** (measured-baseline)/baseline*100. baseline=null|0 이면 null(NaN 금지). / null when baseline is null/0. */
10
+ readonly regressionPct: number | null;
11
+ readonly status: 'pass' | 'fail-budget' | 'fail-regression' | 'new';
12
+ readonly reqIds: readonly string[];
13
+ }
14
+ /**
15
+ * 회귀 판정기 — SPS 예산 + 기준선을 함께 적용하는 2중 게이트.
16
+ * CRC: 예산 위반·기준선 회귀 판정 | 협력: PerfSpec(예산)·PerfBaseline(기준선 DI).
17
+ * / Regression judge — the SPS-budget + baseline double gate.
18
+ */
19
+ export declare class RegressionJudge {
20
+ private readonly spec;
21
+ private readonly baseline;
22
+ constructor(spec: PerfSpec, baseline: PerfBaseline);
23
+ /** 지표별 허용 회귀율(%) — override 없으면 기본 5. / Per-metric tolerance (%). */
24
+ private tolerance;
25
+ /**
26
+ * 실측 지표맵을 받아 지표별 판정 배열 반환. 순수 함수(부작용 0).
27
+ * / Judge a measured metric map into per-metric verdicts. Pure.
28
+ */
29
+ judge(measured: Readonly<Record<string, number>>): MetricVerdict[];
30
+ /**
31
+ * 커버리지 검사: SPS coveredFeatures 중 실측에 없는 기능 지표 → 미커버 지목(머지 금지 강제).
32
+ * / Coverage check: covered features with no measured metric → merge-blocking gaps.
33
+ */
34
+ coverageGaps(measured: Readonly<Record<string, number>>): string[];
35
+ }