@fusion.dev/helix 0.208.1 → 0.210.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/types/svelte.d.ts CHANGED
@@ -179,6 +179,7 @@ declare module 'svelte/elements' {
179
179
  'helix-tab': Helix<'helix-tab'>
180
180
  'helix-tag-group': Helix<'helix-tag-group'>
181
181
  'helix-tag': Helix<'helix-tag'>
182
+ 'helix-terminal': Helix<'helix-terminal'>
182
183
  'helix-text': Helix<'helix-text'>
183
184
  'helix-textarea': Helix<'helix-textarea'>
184
185
  'helix-time-input': Helix<'helix-time-input'>
package/types/vue.d.ts CHANGED
@@ -240,6 +240,13 @@ import type {
240
240
  HelixTabs,
241
241
  HelixTag,
242
242
  HelixTagGroup,
243
+ HelixTerminal,
244
+ HelixTerminalBellEvent,
245
+ HelixTerminalInputEvent,
246
+ HelixTerminalLinkEvent,
247
+ HelixTerminalResizeEvent,
248
+ HelixTerminalRestartEvent,
249
+ HelixTerminalTitleEvent,
243
250
  HelixText,
244
251
  HelixTextarea,
245
252
  HelixTimeInput,
@@ -19875,6 +19882,168 @@ export type HelixTagVueEvents = {
19875
19882
  "helix-dismiss": HelixTagHelixDismissElementEvent;
19876
19883
  };
19877
19884
 
19885
+ /** `HelixTerminal` component event */
19886
+ export type HelixTerminalElementEvent<E = Event> = TypedEvent<HelixTerminal, E>;
19887
+ /** `helix-copy` event type */
19888
+ export type HelixTerminalHelixCopyElementEvent =
19889
+ HelixTerminalElementEvent<HelixCopyEvent>;
19890
+ /** `helix-terminal-bell` event type */
19891
+ export type HelixTerminalHelixTerminalBellElementEvent =
19892
+ HelixTerminalElementEvent<HelixTerminalBellEvent>;
19893
+ /** `helix-terminal-input` event type */
19894
+ export type HelixTerminalHelixTerminalInputElementEvent =
19895
+ HelixTerminalElementEvent<HelixTerminalInputEvent>;
19896
+ /** `helix-terminal-link` event type */
19897
+ export type HelixTerminalHelixTerminalLinkElementEvent =
19898
+ HelixTerminalElementEvent<HelixTerminalLinkEvent>;
19899
+ /** `helix-terminal-resize` event type */
19900
+ export type HelixTerminalHelixTerminalResizeElementEvent =
19901
+ HelixTerminalElementEvent<HelixTerminalResizeEvent>;
19902
+ /** `helix-terminal-restart` event type */
19903
+ export type HelixTerminalHelixTerminalRestartElementEvent =
19904
+ HelixTerminalElementEvent<HelixTerminalRestartEvent>;
19905
+ /** `helix-terminal-title` event type */
19906
+ export type HelixTerminalHelixTerminalTitleElementEvent =
19907
+ HelixTerminalElementEvent<HelixTerminalTitleEvent>;
19908
+
19909
+ export type HelixTerminalVueProps = {
19910
+ /** Covers the container instead of taking a height of its own, for a
19911
+ terminal that fills a pane. The container needs a position, such as
19912
+ `position: relative`. */
19913
+ fill?: (HelixTerminal["fill"]) | undefined;
19914
+ /** How the frame stands off the page. Unset, it is outlined. `plain` draws
19915
+ no edge or corners, for a pane that draws its own. */
19916
+ separation?: (HelixTerminal["separation"]) | undefined;
19917
+ /** The clear button's label. */
19918
+ "clear-label"?: (HelixTerminal["clearLabel"]) | undefined;
19919
+ /** The clear button's label. */
19920
+ clearLabel?: (HelixTerminal["clearLabel"]) | undefined;
19921
+ /** The grid's width in character cells. Set it with `rows` to fix the grid's size; unset, the grid fills the frame. */
19922
+ columns?: (HelixTerminal["columns"]) | undefined;
19923
+ /** Which built-in controls the header shows, as a list of `find`, `copy`,
19924
+ `clear`, and `fullscreen`, or `none`. Absent is `find clear`. */
19925
+ controls?: (HelixTerminal["controls"]) | undefined;
19926
+ /** The name of the row of controls, read by screen readers. */
19927
+ "controls-label"?: (HelixTerminal["controlsLabel"]) | undefined;
19928
+ /** The name of the row of controls, read by screen readers. */
19929
+ controlsLabel?: (HelixTerminal["controlsLabel"]) | undefined;
19930
+ /** What screen readers hear after a copy. */
19931
+ "copied-label"?: (HelixTerminal["copiedLabel"]) | undefined;
19932
+ /** What screen readers hear after a copy. */
19933
+ copiedLabel?: (HelixTerminal["copiedLabel"]) | undefined;
19934
+ /** The copy button's label. */
19935
+ "copy-label"?: (HelixTerminal["copyLabel"]) | undefined;
19936
+ /** The copy button's label. */
19937
+ copyLabel?: (HelixTerminal["copyLabel"]) | undefined;
19938
+ /** How the process exited, which the page sets when it does. While it is set,
19939
+ the status line says it, the frame sends no input, and Restart is shown.
19940
+ Clear it when a new process starts. */
19941
+ "exit-code"?: (HelixTerminal["exitCode"] | `${number}`) | undefined;
19942
+ /** How the process exited, which the page sets when it does. While it is set,
19943
+ the status line says it, the frame sends no input, and Restart is shown.
19944
+ Clear it when a new process starts. */
19945
+ exitCode?: (HelixTerminal["exitCode"]) | undefined;
19946
+ /** What the status line says once the process has exited. `{code}` is its
19947
+ exit code, written as the process gave it, and code `0` is a clean exit. */
19948
+ "exited-label"?: (HelixTerminal["exitedLabel"]) | undefined;
19949
+ /** What the status line says once the process has exited. `{code}` is its
19950
+ exit code, written as the process gave it, and code `0` is a clean exit. */
19951
+ exitedLabel?: (HelixTerminal["exitedLabel"]) | undefined;
19952
+ /** The terminal's name where `label` is empty and the host has no `aria-label`. */
19953
+ "fallback-label"?: (HelixTerminal["fallbackLabel"]) | undefined;
19954
+ /** The terminal's name where `label` is empty and the host has no `aria-label`. */
19955
+ fallbackLabel?: (HelixTerminal["fallbackLabel"]) | undefined;
19956
+ /** The label of the button that closes the find bar. */
19957
+ "find-close-label"?: (HelixTerminal["findCloseLabel"]) | undefined;
19958
+ /** The label of the button that closes the find bar. */
19959
+ findCloseLabel?: (HelixTerminal["findCloseLabel"]) | undefined;
19960
+ /** The name of the find bar's row of buttons, read by screen readers. */
19961
+ "find-controls-label"?: (HelixTerminal["findControlsLabel"]) | undefined;
19962
+ /** The name of the find bar's row of buttons, read by screen readers. */
19963
+ findControlsLabel?: (HelixTerminal["findControlsLabel"]) | undefined;
19964
+ /** The find button's label, and the find field's name and placeholder. */
19965
+ "find-label"?: (HelixTerminal["findLabel"]) | undefined;
19966
+ /** The find button's label, and the find field's name and placeholder. */
19967
+ findLabel?: (HelixTerminal["findLabel"]) | undefined;
19968
+ /** The next match button's label. */
19969
+ "find-next-label"?: (HelixTerminal["findNextLabel"]) | undefined;
19970
+ /** The next match button's label. */
19971
+ findNextLabel?: (HelixTerminal["findNextLabel"]) | undefined;
19972
+ /** The previous match button's label. */
19973
+ "find-previous-label"?: (HelixTerminal["findPreviousLabel"]) | undefined;
19974
+ /** The previous match button's label. */
19975
+ findPreviousLabel?: (HelixTerminal["findPreviousLabel"]) | undefined;
19976
+ /** The fullscreen button's label. */
19977
+ "fullscreen-label"?: (HelixTerminal["fullscreenLabel"]) | undefined;
19978
+ /** The fullscreen button's label. */
19979
+ fullscreenLabel?: (HelixTerminal["fullscreenLabel"]) | undefined;
19980
+ /** The name of the element the reader types into, which the renderer draws. */
19981
+ "input-label"?: (HelixTerminal["inputLabel"]) | undefined;
19982
+ /** The name of the element the reader types into, which the renderer draws. */
19983
+ inputLabel?: (HelixTerminal["inputLabel"]) | undefined;
19984
+ /** The terminal's name, in the header and for screen readers, such as the
19985
+ shell or the folder it runs in. Several terminals on a page need names
19986
+ that tell them apart. */
19987
+ label?: (HelixTerminal["label"]) | undefined;
19988
+ /** What the find bar says of its matches. `{index}` is the current match,
19989
+ counting from 1, and `{count}` how many there are. */
19990
+ "matches-label"?: (HelixTerminal["matchesLabel"]) | undefined;
19991
+ /** What the find bar says of its matches. `{index}` is the current match,
19992
+ counting from 1, and `{count}` how many there are. */
19993
+ matchesLabel?: (HelixTerminal["matchesLabel"]) | undefined;
19994
+ /** Draws the output and sends no input, with no cursor, for a transcript or
19995
+ a command an agent ran. The attribute is `readonly`, the platform's
19996
+ spelling. */
19997
+ readonly?: (HelixTerminal["readOnly"]) | undefined;
19998
+ /** Draws the output and sends no input, with no cursor, for a transcript or
19999
+ a command an agent ran. The attribute is `readonly`, the platform's
20000
+ spelling. */
20001
+ readOnly?: (HelixTerminal["readOnly"]) | undefined;
20002
+ /** The Restart button's label. */
20003
+ "restart-label"?: (HelixTerminal["restartLabel"]) | undefined;
20004
+ /** The Restart button's label. */
20005
+ restartLabel?: (HelixTerminal["restartLabel"]) | undefined;
20006
+ /** The grid's height in lines. Set it with `columns` to fix the grid's size; unset, the grid fills the frame. */
20007
+ rows?: (HelixTerminal["rows"]) | undefined;
20008
+ /** Keeps the grid as lines a screen reader moves through, and says new
20009
+ output as it arrives. Off by default, since it costs time on every
20010
+ write. Connect it to a setting your reader can turn on. */
20011
+ "screen-reader-mode"?: (HelixTerminal["screenReaderMode"]) | undefined;
20012
+ /** Keeps the grid as lines a screen reader moves through, and says new
20013
+ output as it arrives. Off by default, since it costs time on every
20014
+ write. Connect it to a setting your reader can turn on. */
20015
+ screenReaderMode?: (HelixTerminal["screenReaderMode"]) | undefined;
20016
+ /** What the terminal's input describes to a screen reader. `{key}` is the key that switches Tab. */
20017
+ "tab-hint-label"?: (HelixTerminal["tabHintLabel"]) | undefined;
20018
+ /** What the terminal's input describes to a screen reader. `{key}` is the key that switches Tab. */
20019
+ tabHintLabel?: (HelixTerminal["tabHintLabel"]) | undefined;
20020
+ /** What the status line says while Tab moves focus. `{key}` is the key that switches it back. */
20021
+ "tab-moves-focus-label"?: (HelixTerminal["tabMovesFocusLabel"]) | undefined;
20022
+ /** What the status line says while Tab moves focus. `{key}` is the key that switches it back. */
20023
+ tabMovesFocusLabel?: (HelixTerminal["tabMovesFocusLabel"]) | undefined;
20024
+ /** What screen readers hear when Tab goes back to typing in the terminal. */
20025
+ "tab-types-label"?: (HelixTerminal["tabTypesLabel"]) | undefined;
20026
+ /** What screen readers hear when Tab goes back to typing in the terminal. */
20027
+ tabTypesLabel?: (HelixTerminal["tabTypesLabel"]) | undefined;
20028
+ };
20029
+
20030
+ export type HelixTerminalVueEvents = {
20031
+ /** The copy control or its key put the selection on the clipboard. */
20032
+ "helix-copy": HelixTerminalHelixCopyElementEvent;
20033
+ /** The program rang the bell. The frame flashes once. */
20034
+ "helix-terminal-bell": HelixTerminalHelixTerminalBellElementEvent;
20035
+ /** The reader typed or pasted, with `data` encoded for the program. Write it to the process. Not sent while `readonly`, or once `exit-code` is set. */
20036
+ "helix-terminal-input": HelixTerminalHelixTerminalInputElementEvent;
20037
+ /** A link in the output was activated, with its `href`. Cancelable: cancel it to open the link yourself. Left alone, a web address opens in a new tab. */
20038
+ "helix-terminal-link": HelixTerminalHelixTerminalLinkElementEvent;
20039
+ /** The grid changed size, with `columns`, `rows`, `width`, and `height`. Resize the process's pseudo-terminal to match. */
20040
+ "helix-terminal-resize": HelixTerminalHelixTerminalResizeElementEvent;
20041
+ /** The Restart button was pressed after the process exited. Start a new process and clear `exit-code`. */
20042
+ "helix-terminal-restart": HelixTerminalHelixTerminalRestartElementEvent;
20043
+ /** The program set its title, with `title`. The frame keeps its own `label`. */
20044
+ "helix-terminal-title": HelixTerminalHelixTerminalTitleElementEvent;
20045
+ };
20046
+
19878
20047
  export type HelixTextVueProps = {
19879
20048
  /** The HTML element to render.
19880
20049
 
@@ -25420,6 +25589,68 @@ export type CustomCssProperties = {
25420
25589
  "--tag-gap"?: (string) | undefined;
25421
25590
  /** The corner radius of the tag. */
25422
25591
  "--tag-radius"?: (string) | undefined;
25592
+ /** The frame's height, as a length. Ignored with `fill`, where the container decides it. */
25593
+ "--terminal-block-size"?: (string) | undefined;
25594
+ /** The edge around the frame and the rules inside it. */
25595
+ "--terminal-border-color"?: (string) | undefined;
25596
+ /** The face of the grid. Defaults to the monospaced face. */
25597
+ "--terminal-font-family"?: (string) | undefined;
25598
+ /** The size of the grid's text. Defaults to the small text step. */
25599
+ "--terminal-font-size"?: (string) | undefined;
25600
+ /** The fill of the header, the find bar, and the status line. */
25601
+ "--terminal-header-background-color"?: (string) | undefined;
25602
+ /** The space between the frame's edge and the grid. */
25603
+ "--terminal-padding"?: (string) | undefined;
25604
+ /** The frame's corners. */
25605
+ "--terminal-radius"?: (string) | undefined;
25606
+ /** The ground of the current match of a search. */
25607
+ "--terminal-active-match-background-color"?: (string) | undefined;
25608
+ /** The edge of the current match of a search. */
25609
+ "--terminal-active-match-border-color"?: (string) | undefined;
25610
+ /** ANSI black, which codes `30` and `40` draw. */
25611
+ "--terminal-ansi-black"?: (string) | undefined;
25612
+ /** ANSI blue, which codes `34` and `44` draw. */
25613
+ "--terminal-ansi-blue"?: (string) | undefined;
25614
+ /** ANSI bright black, which codes `90` and `100` draw. */
25615
+ "--terminal-ansi-bright-black"?: (string) | undefined;
25616
+ /** ANSI bright blue, which codes `94` and `104` draw. */
25617
+ "--terminal-ansi-bright-blue"?: (string) | undefined;
25618
+ /** ANSI bright cyan, which codes `96` and `106` draw. */
25619
+ "--terminal-ansi-bright-cyan"?: (string) | undefined;
25620
+ /** ANSI bright green, which codes `92` and `102` draw. */
25621
+ "--terminal-ansi-bright-green"?: (string) | undefined;
25622
+ /** ANSI bright magenta, which codes `95` and `105` draw. */
25623
+ "--terminal-ansi-bright-magenta"?: (string) | undefined;
25624
+ /** ANSI bright red, which codes `91` and `101` draw. */
25625
+ "--terminal-ansi-bright-red"?: (string) | undefined;
25626
+ /** ANSI bright white, which codes `97` and `107` draw. */
25627
+ "--terminal-ansi-bright-white"?: (string) | undefined;
25628
+ /** ANSI bright yellow, which codes `93` and `103` draw. */
25629
+ "--terminal-ansi-bright-yellow"?: (string) | undefined;
25630
+ /** ANSI cyan, which codes `36` and `46` draw. */
25631
+ "--terminal-ansi-cyan"?: (string) | undefined;
25632
+ /** ANSI green, which codes `32` and `42` draw. */
25633
+ "--terminal-ansi-green"?: (string) | undefined;
25634
+ /** ANSI magenta, which codes `35` and `45` draw. */
25635
+ "--terminal-ansi-magenta"?: (string) | undefined;
25636
+ /** ANSI red, which codes `31` and `41` draw. */
25637
+ "--terminal-ansi-red"?: (string) | undefined;
25638
+ /** ANSI white, which codes `37` and `47` draw. */
25639
+ "--terminal-ansi-white"?: (string) | undefined;
25640
+ /** ANSI yellow, which codes `33` and `43` draw. */
25641
+ "--terminal-ansi-yellow"?: (string) | undefined;
25642
+ /** The ground of the grid. */
25643
+ "--terminal-background-color"?: (string) | undefined;
25644
+ /** The text of the grid where the program sets no color. */
25645
+ "--terminal-color"?: (string) | undefined;
25646
+ /** The cursor. */
25647
+ "--terminal-cursor-color"?: (string) | undefined;
25648
+ /** The ground of every match of a search but the current one. */
25649
+ "--terminal-match-background-color"?: (string) | undefined;
25650
+ /** The grid's scrollbar. */
25651
+ "--terminal-scrollbar-thumb-color"?: (string) | undefined;
25652
+ /** The ground of selected text. See-through, so the text keeps its color. */
25653
+ "--terminal-selection-background-color"?: (string) | undefined;
25423
25654
  /** The typeface. Overrides the ramp's. */
25424
25655
  "--text-font-family"?: (string) | undefined;
25425
25656
  /** The size. Overrides the ramp's. */
@@ -26706,6 +26937,12 @@ export interface WcToolkitVueGlobalComponents {
26706
26937
  HelixTagVueProps,
26707
26938
  HelixTagVueEvents
26708
26939
  >;
26940
+ /** The styled frame: a bordered box on the page's background with a header strip for the name and the controls, and a status line that appears when the process exits. It is 24rem tall unless 'fill' is set or '--terminal-block-size' says otherwise. 'connectTerminal' themes the terminal from your tokens. The sixteen ANSI colors share Log's hues, red the danger color, green success, yellow warning, and blue info, and the four grays keep their order from dark to light in each color mode. Set '--terminal-ansi-red' and its siblings, '--terminal-cursor-color', or '--terminal-selection-background-color' on the terminal to choose them yourself, such as 'helix-terminal { --terminal-ansi-blue: #3b82f6 }'. The [Terminals](https://fusion.dev/helix/docs/terminals) guide lists them all. Set 'fill' for a terminal that fills a pane, such as one side of a 'Splitter': the frame covers its container, which needs a position of its own, such as 'position: relative'. Set 'separation="plain"' where the pane already draws the edge. */
26941
+ "helix-terminal": DefineCustomElement<
26942
+ HelixTerminal,
26943
+ HelixTerminalVueProps,
26944
+ HelixTerminalVueEvents
26945
+ >;
26709
26946
  /** 'as' sets the element, which decides the document outline and what a screen reader announces. 'variant' sets the type ramp, which decides size, weight, leading, and tracking together. The two match by default, so usually you set only 'as', such as 'as="h2"'. Set 'variant' when the look and the element differ, such as a heading that looks smaller or a '<p>' styled as a caption. The pairing is resolved in CSS, so the element writes nothing to its host. 'as="h2"' picks up the heading ramp through a selector, and setting 'variant' overrides the pairing. Do not derive it in 'willUpdate', because that adds a host attribute the server markup does not have, which causes a hydration mismatch in React. Size, weight, and leading are not separate properties. Choose a named ramp with 'variant'. 'tone' and 'emphasis' are separate from 'variant', because color carries state. Combining them would need a variant for every pair, such as 'caption-danger' and 'label-muted'. 'lines' cuts the text off after that many lines and ends it with an ellipsis. 'text-wrap' balances or tidies the line breaks, and 'text-align' sets the alignment. Each '--text-*' property overrides one value of the ramp, for a text or for every text inside an element. **To label a control, write a native '<label data-text="label">'.** The base layer gives it the label ramp. A Helix field takes its own 'label'. */
26710
26947
  "helix-text": DefineCustomElement<
26711
26948
  HelixText,
package/types/words.d.ts CHANGED
@@ -4037,6 +4037,118 @@ declare module '@fusion.dev/helix-core' {
4037
4037
  */
4038
4038
  emptyLabel: Message
4039
4039
  }
4040
+ 'helix-terminal': {
4041
+ /**
4042
+ * The clear button's label.
4043
+ *
4044
+ * English: `Clear`
4045
+ */
4046
+ clearLabel: Message
4047
+ /**
4048
+ * The name of the row of controls, read by screen readers.
4049
+ *
4050
+ * English: `Terminal controls`
4051
+ */
4052
+ controlsLabel: Message
4053
+ /**
4054
+ * What screen readers hear after a copy.
4055
+ *
4056
+ * English: `Copied`
4057
+ */
4058
+ copiedLabel: Message
4059
+ /**
4060
+ * The copy button's label.
4061
+ *
4062
+ * English: `Copy`
4063
+ */
4064
+ copyLabel: Message
4065
+ /**
4066
+ * What the status line says once the process has exited. `{code}` is its
4067
+ * exit code, written as the process gave it, and code `0` is a clean exit.
4068
+ *
4069
+ * English: `{code, select, 0 {The process exited.} other {The process exited with code {code}.}}`
4070
+ */
4071
+ exitedLabel: Message
4072
+ /**
4073
+ * The terminal's name where `label` is empty and the host has no `aria-label`.
4074
+ *
4075
+ * English: `Terminal`
4076
+ */
4077
+ fallbackLabel: Message
4078
+ /**
4079
+ * The label of the button that closes the find bar.
4080
+ *
4081
+ * English: `Close find`
4082
+ */
4083
+ findCloseLabel: Message
4084
+ /**
4085
+ * The name of the find bar's row of buttons, read by screen readers.
4086
+ *
4087
+ * English: `Find controls`
4088
+ */
4089
+ findControlsLabel: Message
4090
+ /**
4091
+ * The find button's label, and the find field's name and placeholder.
4092
+ *
4093
+ * English: `Find`
4094
+ */
4095
+ findLabel: Message
4096
+ /**
4097
+ * The next match button's label.
4098
+ *
4099
+ * English: `Next match`
4100
+ */
4101
+ findNextLabel: Message
4102
+ /**
4103
+ * The previous match button's label.
4104
+ *
4105
+ * English: `Previous match`
4106
+ */
4107
+ findPreviousLabel: Message
4108
+ /**
4109
+ * The fullscreen button's label.
4110
+ *
4111
+ * English: `Fill the screen`
4112
+ */
4113
+ fullscreenLabel: Message
4114
+ /**
4115
+ * The name of the element the reader types into, which the renderer draws.
4116
+ *
4117
+ * English: `Terminal input`
4118
+ */
4119
+ inputLabel: Message
4120
+ /**
4121
+ * What the find bar says of its matches. `{index}` is the current match,
4122
+ * counting from 1, and `{count}` how many there are.
4123
+ *
4124
+ * English: `{count, plural, =0 {No matches} one {{index} of # match} other {{index} of # matches}}`
4125
+ */
4126
+ matchesLabel: Message
4127
+ /**
4128
+ * The Restart button's label.
4129
+ *
4130
+ * English: `Restart`
4131
+ */
4132
+ restartLabel: Message
4133
+ /**
4134
+ * What the terminal's input describes to a screen reader. `{key}` is the key that switches Tab.
4135
+ *
4136
+ * English: `Press {key} to move focus with Tab.`
4137
+ */
4138
+ tabHintLabel: Message
4139
+ /**
4140
+ * What the status line says while Tab moves focus. `{key}` is the key that switches it back.
4141
+ *
4142
+ * English: `Tab moves focus. Press {key} to type Tab in the terminal.`
4143
+ */
4144
+ tabMovesFocusLabel: Message
4145
+ /**
4146
+ * What screen readers hear when Tab goes back to typing in the terminal.
4147
+ *
4148
+ * English: `Tab types in the terminal.`
4149
+ */
4150
+ tabTypesLabel: Message
4151
+ }
4040
4152
  'helix-textarea': {
4041
4153
  /**
4042
4154
  * The accessible name of the clear button, which shows only an icon.