Skip to content

Transform TextInput to es6 class #5805

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions ace-internal.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export namespace Ace {
type HoverTooltip = import("ace-code/src/tooltip").HoverTooltip;
type Tooltip = import("ace-code/src/tooltip").Tooltip;
type PopupManager = import("ace-code/src/tooltip").PopupManager;
type TextInput = import("ace-code/src/keyboard/textinput").TextInput;

type AfterLoadCallback = (err: Error | null, module: unknown) => void;
type LoaderFunction = (moduleName: string, afterLoad: AfterLoadCallback) => void;
Expand Down Expand Up @@ -967,12 +968,6 @@ export namespace Ace {
new(session: EditSession): Selection;
}

interface TextInput {
resetSelection(): void;

setAriaOption(options?: { activeDescendant: string, role: string, setLabel: any }): void;
}

type CompleterCallback = (error: any, completions: Completion[]) => void;

interface Completer {
Expand Down Expand Up @@ -1292,6 +1287,13 @@ export namespace Ace {
export interface ScrollbarEvents {
"scroll": (e: { data: number }) => void;
}

export interface AriaOptions {
activeDescendant?: string;
role?: string;
setLabel?: boolean;
inline?: boolean;
}
}


Expand Down
15 changes: 7 additions & 8 deletions ace.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ declare module "ace-code" {
type HoverTooltip = import("ace-code/src/tooltip").HoverTooltip;
type Tooltip = import("ace-code/src/tooltip").Tooltip;
type PopupManager = import("ace-code/src/tooltip").PopupManager;
type TextInput = import("ace-code/src/keyboard/textinput").TextInput;
type AfterLoadCallback = (err: Error | null, module: unknown) => void;
type LoaderFunction = (moduleName: string, afterLoad: AfterLoadCallback) => void;
export interface ConfigOptions {
Expand Down Expand Up @@ -775,14 +776,6 @@ declare module "ace-code" {
var Selection: {
new(session: EditSession): Selection;
};
interface TextInput {
resetSelection(): void;
setAriaOption(options?: {
activeDescendant: string;
role: string;
setLabel: any;
}): void;
}
type CompleterCallback = (error: any, completions: Completion[]) => void;
interface Completer {
identifierRegexps?: Array<RegExp>;
Expand Down Expand Up @@ -1032,6 +1025,12 @@ declare module "ace-code" {
data: number;
}) => void;
}
export interface AriaOptions {
activeDescendant?: string;
role?: string;
setLabel?: boolean;
inline?: boolean;
}
}
export const config: typeof import("ace-code/src/config");
export function edit(el?: string | (HTMLElement & {
Expand Down
2 changes: 1 addition & 1 deletion src/editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ class Editor {

/**
*
* @param {string | string[]} command
* @param {string | string[] | import("../ace-internal").Ace.Command} command
* @param [args]
* @return {boolean}
*/
Expand Down
Loading
Loading