@opencraw/studio 0.0.31 → 0.0.33

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 (49) hide show
  1. package/dist/document-view/index.d.ts +1 -1
  2. package/dist/document-view/workbook-view.mapper.d.ts +17 -1
  3. package/dist/index.d.ts +2 -2
  4. package/dist/index.esm.js +658 -49
  5. package/dist/page-snapshot/blocked-page.algorithm.d.ts +10 -0
  6. package/dist/page-snapshot/consent-banner.algorithm.d.ts +23 -0
  7. package/dist/page-snapshot/detect-url.use-case.d.ts +13 -0
  8. package/dist/page-snapshot/index.d.ts +4 -0
  9. package/dist/page-snapshot/inline-assets.mapper.d.ts +29 -0
  10. package/dist/page-snapshot/inline-local-images.use-case.d.ts +19 -0
  11. package/dist/page-snapshot/take-snapshot.use-case.d.ts +2 -0
  12. package/dist/recipe-workspace/import-document.use-case.d.ts +5 -3
  13. package/dist/selector-inference/selector-ranking.policy.d.ts +1 -1
  14. package/dist/src/document-view/index.d.ts +1 -1
  15. package/dist/src/document-view/workbook-view.mapper.d.ts +17 -1
  16. package/dist/src/index.d.ts +2 -2
  17. package/dist/src/page-snapshot/blocked-page.algorithm.d.ts +10 -0
  18. package/dist/src/page-snapshot/consent-banner.algorithm.d.ts +23 -0
  19. package/dist/src/page-snapshot/detect-url.use-case.d.ts +13 -0
  20. package/dist/src/page-snapshot/index.d.ts +4 -0
  21. package/dist/src/page-snapshot/inline-assets.mapper.d.ts +29 -0
  22. package/dist/src/page-snapshot/inline-local-images.use-case.d.ts +19 -0
  23. package/dist/src/page-snapshot/take-snapshot.use-case.d.ts +2 -0
  24. package/dist/src/recipe-workspace/import-document.use-case.d.ts +5 -3
  25. package/dist/src/selector-inference/selector-ranking.policy.d.ts +1 -1
  26. package/dist/src/studio-api/command.contract.d.ts +31 -0
  27. package/dist/src/studio-api/deck-view.contract.d.ts +2 -0
  28. package/dist/src/studio-api/detect-url-view.contract.d.ts +24 -0
  29. package/dist/src/studio-api/grid-view.contract.d.ts +15 -0
  30. package/dist/src/studio-api/index.d.ts +8 -6
  31. package/dist/src/studio-api/infer-selector-view.contract.d.ts +86 -0
  32. package/dist/src/studio-api/snapshot-view.contract.d.ts +1 -0
  33. package/dist/src/studio-server/detect-url.handler.d.ts +10 -0
  34. package/dist/src/studio-server/grid-view.handler.d.ts +12 -1
  35. package/dist/studio-api/command.contract.d.ts +31 -0
  36. package/dist/studio-api/deck-view.contract.d.ts +2 -0
  37. package/dist/studio-api/detect-url-view.contract.d.ts +24 -0
  38. package/dist/studio-api/grid-view.contract.d.ts +15 -0
  39. package/dist/studio-api/index.d.ts +8 -6
  40. package/dist/studio-api/infer-selector-view.contract.d.ts +86 -0
  41. package/dist/studio-api/snapshot-view.contract.d.ts +1 -0
  42. package/dist/studio-server/detect-url.handler.d.ts +10 -0
  43. package/dist/studio-server/grid-view.handler.d.ts +12 -1
  44. package/dist/ui/assets/index-Db6-8OgZ.js +42 -0
  45. package/dist/ui/assets/{pdf-CtmGNMM2.js → pdf-rdp2xUbL.js} +1 -1
  46. package/dist/ui/index.html +11 -2
  47. package/dist/ui/opencraw-logo.svg +28 -0
  48. package/package.json +3 -3
  49. package/dist/ui/assets/index-CMzc4-FL.js +0 -40
@@ -8,6 +8,6 @@ export { previewDeckTable, previewGridTable, previewPdfTable } from './table-pre
8
8
  export type { DeckTablePreviewMatch, DeckTablePreviewOptions, DeckTablePreviewResult, GridTablePreviewMatch, GridTablePreviewOptions, GridTablePreviewResult, TablePreviewMatch, TablePreviewOptions, TablePreviewResult } from './table-preview.use-case';
9
9
  export { previewRegion } from './region-preview.use-case';
10
10
  export type { RegionPreviewResult, RegionPreviewMatch } from './region-preview.use-case';
11
- export { workbookDocumentView } from './workbook-view.mapper';
11
+ export { workbookDocumentView, workbookSheetRows } from './workbook-view.mapper';
12
12
  export type { GridCellType, GridCellView, GridMergeView, GridSheetView, WorkbookDocumentView } from './workbook-view.mapper';
13
13
  //# sourceMappingURL=index.d.ts.map
@@ -22,7 +22,10 @@ export interface GridSheetView {
22
22
  hiddenRows: number[];
23
23
  /** The widest row's own length, ragged rows included — for the grid to size its columns. */
24
24
  columnCount: number;
25
+ /** The sheet's rows; only the first window of them when `rowCount` is set (the rest are fetched with `grid-rows`). */
25
26
  rows: GridCellView[][];
27
+ /** How many rows the sheet has, set only when `rows` holds just the first window of them. */
28
+ rowCount?: number;
26
29
  merges: GridMergeView[];
27
30
  /** Column widths in characters by 0-based column, as the spreadsheet stores them; absent keys are columns the file does not size. */
28
31
  columnWidths?: Record<string, number>;
@@ -55,5 +58,18 @@ export interface WorkbookDocumentView {
55
58
  * @param document - The read workbook (a spreadsheet or a CSV).
56
59
  * @returns The view.
57
60
  */
58
- export declare function workbookDocumentView(document: WorkbookDocument): WorkbookDocumentView;
61
+ export declare function workbookDocumentView(document: WorkbookDocument, options?: {
62
+ windowRows?: number;
63
+ }): WorkbookDocumentView;
64
+ /**
65
+ * A run of one sheet's rows, typed, for a grid that only holds the screens around where it is scrolled to (the rest of a big file is never
66
+ * sent to the browser until it is needed).
67
+ *
68
+ * @param document - The read workbook.
69
+ * @param sheetIndex - Which sheet, 0-based.
70
+ * @param from - The first row, 0-based.
71
+ * @param count - How many rows at most.
72
+ * @returns The rows (fewer at the end of the sheet, none past it).
73
+ */
74
+ export declare function workbookSheetRows(document: WorkbookDocument, sheetIndex: number, from: number, count: number): GridCellView[][];
59
75
  //# sourceMappingURL=workbook-view.mapper.d.ts.map
package/dist/index.d.ts CHANGED
@@ -9,6 +9,6 @@ export { runSample, loadRecipePair } from './sample-run';
9
9
  export type { RecipePair, SampleRunCallbacks, SampleRunHandle, SampleRunRecord, SampleRunRejected, SampleRunResult, SampleStepSummary, SampleStoppedBy } from './sample-run';
10
10
  export { fetchStartPage } from './page-snapshot';
11
11
  export type { WhyFacts, WhyStepFact } from './explain-why';
12
- export { sampleBudgetSchema, openWorkspaceCommandSchema, chooseFolderCommandSchema, openPathCommandSchema, importDocumentCommandSchema, runSampleCommandSchema, stopRunCommandSchema, saveRecipeCommandSchema, fetchStartPageCommandSchema, saveOutlineCommandSchema, takeSnapshotCommandSchema, verifySelectorCommandSchema, inferSelectorCommandSchema, missingWhyTargetSchema, rejectedWhyTargetSchema, whyTargetSchema, explainWhyCommandSchema, studioCommandSchema, chooseFolderViewSchema, openPathViewSchema, importDocumentViewSchema, stoppedBySchema, fieldTraceSchema, traceLineEventSchema, recordEventSchema, recordRejectedEventSchema, runFinishedEventSchema, workspaceChangedEventSchema, studioEventSchema, loadedHooksSchema, recipeIssueSchema, recipeListingSchema, workspaceViewSchema, sampleRunRecordSchema, sampleRunViewSchema, startPageViewSchema, snapshotViewSchema, verifySelectorViewSchema, fieldPickSchema, inferSelectorViewSchema, sentencePartSchema, outlineCardSchema, outlineBracketSchema, outlineNodeSchema, outlineViewSchema, whyViewSchema, inspectPageCommandSchema, responsesSeenCommandSchema, documentTreeCommandSchema, pdfViewCommandSchema, tablePreviewOptionsSchema, tablePreviewCommandSchema, regionPreviewCommandSchema, regionPreviewMatchSchema, regionPreviewViewSchema, gridViewCommandSchema, gridPreviewOptionsSchema, gridPreviewCommandSchema, deckViewCommandSchema, deckPreviewOptionsSchema, deckPreviewCommandSchema, domTreeNodeViewSchema, pageDataFindingSchema, inspectViewSchema, observedResponseSchema, responsesSeenViewSchema, documentTreeNodeViewSchema, documentTreeViewSchema, pdfCellViewSchema, pdfRowViewSchema, pdfPageViewSchema, pdfDocumentViewSchema, tablePreviewTableSchema, tablePreviewBandSchema, tablePreviewMatchSchema, tablePreviewViewSchema, gridCellViewSchema, gridMergeViewSchema, gridSheetViewSchema, workbookDocumentViewSchema, gridTablePreviewMatchSchema, gridTablePreviewViewSchema, deckShapeViewSchema, deckChartSeriesViewSchema, deckChartViewSchema, deckSlideViewSchema, deckDocumentViewSchema, deckTablePreviewMatchSchema, deckTablePreviewViewSchema, startRecordingCommandSchema, stopRecordingCommandSchema, recordingCardEventSchema, recordingNoteEventSchema, recordingStoppedEventSchema, } from './studio-api';
13
- export type { SampleBudget, OpenWorkspaceCommand, ChooseFolderCommand, OpenPathCommand, ImportDocumentCommand, RunSampleCommand, StopRunCommand, SaveRecipeCommand, FetchStartPageCommand, SaveOutlineCommand, TakeSnapshotCommand, VerifySelectorCommand, InferSelectorCommand, MissingWhyTarget, RejectedWhyTarget, WhyTarget, ExplainWhyCommand, InspectPageCommand, ResponsesSeenCommand, DocumentTreeCommand, PdfViewCommand, TablePreviewOptions, TablePreviewCommand, RegionPreviewCommand, GridViewCommand, GridPreviewOptions, GridPreviewCommand, DeckViewCommand, DeckPreviewOptions, DeckPreviewCommand, StudioCommand, ChooseFolderView, OpenPathView, ImportDocumentView, RegionPreviewMatchView, RegionPreviewView, StoppedBy, FieldTraceView, TraceLineEvent, RecordEvent, RecordRejectedEvent, RunFinishedEvent, WorkspaceChangedEvent, StudioEvent, LoadedHooks, RecipeIssue, RecipeListing, WorkspaceView, SampleRunView, StartPageView, SnapshotView, VerifySelectorView, FieldPick, InferSelectorView, SentencePart, OutlineCard, OutlineBracket, OutlineNode, OutlineView, WhyView, DomTreeNodeView, PageDataKind, PageDataFindingView, InspectView, ObservedResponseView, ResponsesSeenView, DocumentTreeNodeView, DocumentTreeView, PdfCellView, PdfRowView, PdfPageView, PdfDocumentView, TablePreviewTableView, TablePreviewBandView, TablePreviewMatchView, TablePreviewView, GridCellView, GridMergeView, GridSheetView, WorkbookDocumentView, GridTablePreviewMatchView, GridTablePreviewView, DeckShapeView, DeckChartSeriesView, DeckChartView, DeckSlideView, DeckDocumentView, DeckTablePreviewMatchView, DeckTablePreviewView, StartRecordingCommand, StopRecordingCommand, RecordingCardEvent, RecordingNoteEvent, RecordingStoppedEvent, } from './studio-api';
12
+ export { sampleBudgetSchema, openWorkspaceCommandSchema, chooseFolderCommandSchema, openPathCommandSchema, importDocumentCommandSchema, runSampleCommandSchema, stopRunCommandSchema, saveRecipeCommandSchema, fetchStartPageCommandSchema, detectUrlCommandSchema, saveOutlineCommandSchema, takeSnapshotCommandSchema, verifySelectorCommandSchema, inferSelectorCommandSchema, missingWhyTargetSchema, rejectedWhyTargetSchema, whyTargetSchema, explainWhyCommandSchema, studioCommandSchema, chooseFolderViewSchema, openPathViewSchema, importDocumentViewSchema, stoppedBySchema, fieldTraceSchema, traceLineEventSchema, recordEventSchema, recordRejectedEventSchema, runFinishedEventSchema, workspaceChangedEventSchema, studioEventSchema, loadedHooksSchema, recipeIssueSchema, recipeListingSchema, workspaceViewSchema, sampleRunRecordSchema, sampleRunViewSchema, startPageViewSchema, detectUrlViewSchema, snapshotViewSchema, verifySelectorViewSchema, fieldPickSchema, inferSelectorViewSchema, selectorAlternativeSchema, sentencePartSchema, outlineCardSchema, outlineBracketSchema, outlineNodeSchema, outlineViewSchema, whyViewSchema, inspectPageCommandSchema, responsesSeenCommandSchema, documentTreeCommandSchema, pdfViewCommandSchema, tablePreviewOptionsSchema, tablePreviewCommandSchema, regionPreviewCommandSchema, regionPreviewMatchSchema, regionPreviewViewSchema, gridViewCommandSchema, gridRowsCommandSchema, gridPreviewOptionsSchema, gridPreviewCommandSchema, deckViewCommandSchema, deckPreviewOptionsSchema, deckPreviewCommandSchema, domTreeNodeViewSchema, pageDataFindingSchema, inspectViewSchema, observedResponseSchema, responsesSeenViewSchema, documentTreeNodeViewSchema, documentTreeViewSchema, pdfCellViewSchema, pdfRowViewSchema, pdfPageViewSchema, pdfDocumentViewSchema, tablePreviewTableSchema, tablePreviewBandSchema, tablePreviewMatchSchema, tablePreviewViewSchema, gridCellViewSchema, gridMergeViewSchema, gridRowsViewSchema, gridSheetViewSchema, workbookDocumentViewSchema, gridTablePreviewMatchSchema, gridTablePreviewViewSchema, deckShapeViewSchema, deckChartSeriesViewSchema, deckChartViewSchema, deckSlideViewSchema, deckDocumentViewSchema, deckTablePreviewMatchSchema, deckTablePreviewViewSchema, startRecordingCommandSchema, stopRecordingCommandSchema, recordingCardEventSchema, recordingNoteEventSchema, recordingStoppedEventSchema, } from './studio-api';
13
+ export type { SampleBudget, OpenWorkspaceCommand, ChooseFolderCommand, OpenPathCommand, ImportDocumentCommand, RunSampleCommand, StopRunCommand, SaveRecipeCommand, FetchStartPageCommand, DetectUrlCommand, SaveOutlineCommand, TakeSnapshotCommand, VerifySelectorCommand, InferSelectorCommand, MissingWhyTarget, RejectedWhyTarget, WhyTarget, ExplainWhyCommand, InspectPageCommand, ResponsesSeenCommand, DocumentTreeCommand, PdfViewCommand, TablePreviewOptions, TablePreviewCommand, RegionPreviewCommand, GridViewCommand, GridRowsCommand, GridPreviewOptions, GridPreviewCommand, DeckViewCommand, DeckPreviewOptions, DeckPreviewCommand, StudioCommand, ChooseFolderView, OpenPathView, ImportDocumentView, RegionPreviewMatchView, RegionPreviewView, StoppedBy, FieldTraceView, TraceLineEvent, RecordEvent, RecordRejectedEvent, RunFinishedEvent, WorkspaceChangedEvent, StudioEvent, LoadedHooks, RecipeIssue, RecipeListing, WorkspaceView, SampleRunView, StartPageView, DetectUrlView, SnapshotView, VerifySelectorView, FieldPick, InferSelectorView, SelectorAlternative, SentencePart, OutlineCard, OutlineBracket, OutlineNode, OutlineView, WhyView, DomTreeNodeView, PageDataKind, PageDataFindingView, InspectView, ObservedResponseView, ResponsesSeenView, DocumentTreeNodeView, DocumentTreeView, PdfCellView, PdfRowView, PdfPageView, PdfDocumentView, TablePreviewTableView, TablePreviewBandView, TablePreviewMatchView, TablePreviewView, GridCellView, GridMergeView, GridRowsView, GridSheetView, WorkbookDocumentView, GridTablePreviewMatchView, GridTablePreviewView, DeckShapeView, DeckChartSeriesView, DeckChartView, DeckSlideView, DeckDocumentView, DeckTablePreviewMatchView, DeckTablePreviewView, StartRecordingCommand, StopRecordingCommand, RecordingCardEvent, RecordingNoteEvent, RecordingStoppedEvent, } from './studio-api';
14
14
  //# sourceMappingURL=index.d.ts.map