@magicx-eng/ai-autocomplete-vanilla 0.73.3 → 0.74.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/index.d.mts +22 -0
- package/dist/index.d.ts +22 -0
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -203,6 +203,8 @@ interface AutocompleteRequest {
|
|
|
203
203
|
client_option_parameters: string[];
|
|
204
204
|
/** Tells the server this client can show option-value completions of the word being typed. */
|
|
205
205
|
accepts_traditional_autocomplete?: boolean;
|
|
206
|
+
/** Set on a preview sent while an IME composes. The server answers completions only, or nothing. */
|
|
207
|
+
traditional_autocomplete_only?: boolean;
|
|
206
208
|
};
|
|
207
209
|
meta: {
|
|
208
210
|
request_id: string;
|
|
@@ -927,6 +929,17 @@ declare function timeWheelIndexFromScroll(column: TimeWheelColumn, scrollTop: nu
|
|
|
927
929
|
*/
|
|
928
930
|
interface CoreInputState {
|
|
929
931
|
text: string;
|
|
932
|
+
/**
|
|
933
|
+
* The editor text while an IME composes a syllable (`text`), and the
|
|
934
|
+
* committed `text` it was composed over (`over`). Null when no composition
|
|
935
|
+
* shows text that differs from `text`. Option rows match their bold part
|
|
936
|
+
* against it, so the bold part follows what the user sees. It is ignored
|
|
937
|
+
* once `text` no longer equals `over`.
|
|
938
|
+
*/
|
|
939
|
+
composing: {
|
|
940
|
+
text: string;
|
|
941
|
+
over: string;
|
|
942
|
+
} | null;
|
|
930
943
|
completedParams: CompletedParamState[];
|
|
931
944
|
/**
|
|
932
945
|
* LLM-identified params from the latest response. Revisable: replaced
|
|
@@ -1863,6 +1876,15 @@ declare class AIAutocomplete {
|
|
|
1863
1876
|
/** Whether cards draw a cart button: an `onProductAddToCart` handler is set. */
|
|
1864
1877
|
hasProductAddToCart(): boolean;
|
|
1865
1878
|
handleTextChange(value: string): void;
|
|
1879
|
+
/**
|
|
1880
|
+
* Preview the editor text while an IME composes a syllable. The editor
|
|
1881
|
+
* calls `handleTextChange` again at compositionend.
|
|
1882
|
+
*
|
|
1883
|
+
* The preview request is debounced like typing. Its answer is shown only
|
|
1884
|
+
* when it carries completions for the word. It does not change the text,
|
|
1885
|
+
* the params, the product strip or any event.
|
|
1886
|
+
*/
|
|
1887
|
+
handleCompositionText(value: string): void;
|
|
1866
1888
|
private applyTextChange;
|
|
1867
1889
|
/** Page the datepicker back one month. No-op unless a date pill is active. */
|
|
1868
1890
|
showPreviousMonth(): void;
|
package/dist/index.d.ts
CHANGED
|
@@ -203,6 +203,8 @@ interface AutocompleteRequest {
|
|
|
203
203
|
client_option_parameters: string[];
|
|
204
204
|
/** Tells the server this client can show option-value completions of the word being typed. */
|
|
205
205
|
accepts_traditional_autocomplete?: boolean;
|
|
206
|
+
/** Set on a preview sent while an IME composes. The server answers completions only, or nothing. */
|
|
207
|
+
traditional_autocomplete_only?: boolean;
|
|
206
208
|
};
|
|
207
209
|
meta: {
|
|
208
210
|
request_id: string;
|
|
@@ -927,6 +929,17 @@ declare function timeWheelIndexFromScroll(column: TimeWheelColumn, scrollTop: nu
|
|
|
927
929
|
*/
|
|
928
930
|
interface CoreInputState {
|
|
929
931
|
text: string;
|
|
932
|
+
/**
|
|
933
|
+
* The editor text while an IME composes a syllable (`text`), and the
|
|
934
|
+
* committed `text` it was composed over (`over`). Null when no composition
|
|
935
|
+
* shows text that differs from `text`. Option rows match their bold part
|
|
936
|
+
* against it, so the bold part follows what the user sees. It is ignored
|
|
937
|
+
* once `text` no longer equals `over`.
|
|
938
|
+
*/
|
|
939
|
+
composing: {
|
|
940
|
+
text: string;
|
|
941
|
+
over: string;
|
|
942
|
+
} | null;
|
|
930
943
|
completedParams: CompletedParamState[];
|
|
931
944
|
/**
|
|
932
945
|
* LLM-identified params from the latest response. Revisable: replaced
|
|
@@ -1863,6 +1876,15 @@ declare class AIAutocomplete {
|
|
|
1863
1876
|
/** Whether cards draw a cart button: an `onProductAddToCart` handler is set. */
|
|
1864
1877
|
hasProductAddToCart(): boolean;
|
|
1865
1878
|
handleTextChange(value: string): void;
|
|
1879
|
+
/**
|
|
1880
|
+
* Preview the editor text while an IME composes a syllable. The editor
|
|
1881
|
+
* calls `handleTextChange` again at compositionend.
|
|
1882
|
+
*
|
|
1883
|
+
* The preview request is debounced like typing. Its answer is shown only
|
|
1884
|
+
* when it carries completions for the word. It does not change the text,
|
|
1885
|
+
* the params, the product strip or any event.
|
|
1886
|
+
*/
|
|
1887
|
+
handleCompositionText(value: string): void;
|
|
1866
1888
|
private applyTextChange;
|
|
1867
1889
|
/** Page the datepicker back one month. No-op unless a date pill is active. */
|
|
1868
1890
|
showPreviousMonth(): void;
|