# StorySnapshot

Source: /tuil/docs/reference/packages/story/api/story-snapshot
Locale: en

interface exported by @mwillbanks/tuil-story.



{/* Generated by tooling/docs/generate-reference.ts. */}

## interface [#interface]

Public interface exported by `@mwillbanks/tuil-story`.

```ts
export interface StorySnapshot {
  readonly storyId: string;
  readonly variant: string;
  readonly frame: string;
  readonly ansiFrame: string;
  readonly semantics: readonly QueryableSemanticNode[];
  readonly focus: StoryFrame["focus"];
  readonly controls: TerminalStoryControls;
}
```

## Members [#members]

| Member      | Type                                                                                                                                                         | Required | Description                                                                                                                                                                                        | Related types                                                                           |
| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- |
| `storyId`   | `string`                                                                                                                                                     | Yes      | The `storyId` member uses the `string` contract.                                                                                                                                                   | —                                                                                       |
| `variant`   | `string`                                                                                                                                                     | Yes      | The `variant` member uses the `string` contract.                                                                                                                                                   | —                                                                                       |
| `frame`     | `string`                                                                                                                                                     | Yes      | The `frame` member uses the `string` contract.                                                                                                                                                     | —                                                                                       |
| `ansiFrame` | `string`                                                                                                                                                     | Yes      | The `ansiFrame` member uses the `string` contract.                                                                                                                                                 | —                                                                                       |
| `semantics` | `readonly QueryableSemanticNode[]`                                                                                                                           | Yes      | The `semantics` member uses the `readonly QueryableSemanticNode[]` contract.                                                                                                                       | [`QueryableSemanticNode`](/tuil/docs/reference/packages/testing/api/queryable-semantic-node) |
| `focus`     | `&#123; readonly focusedId?: string; readonly nodes: readonly &#123; readonly id: string; readonly label?: string; readonly role?: string; &#125;[]; &#125;` | Yes      | The `focus` member uses the `&#123; readonly focusedId?: string; readonly nodes: readonly &#123; readonly id: string; readonly label?: string; readonly role?: string; &#125;[]; &#125;` contract. | —                                                                                       |
| `controls`  | `TerminalStoryControls`                                                                                                                                      | Yes      | The `controls` member uses the `TerminalStoryControls` contract.                                                                                                                                   | [`TerminalStoryControls`](/tuil/docs/reference/packages/story/api/terminal-story-controls)   |

## Parameters [#parameters]

This declaration has no public members.

## Returns [#returns]

This declaration does not return a value.

## Throws [#throws]

No thrown errors are documented for this declaration.

## Related types [#related-types]

* [`StoryFrame`](/tuil/docs/reference/packages/story/api/story-frame)
* [`TerminalStoryControls`](/tuil/docs/reference/packages/story/api/terminal-story-controls)

## Source [#source]

[View the secondary source reference](https://github.com/mwillbanks/tuil/blob/main/packages/story/src/index.tsx)

## Package [#package]

[@mwillbanks/tuil-story](/tuil/docs/reference/packages/story)
