@yellowcode/mod 0.4.0 → 0.5.0-beta.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.
Files changed (2) hide show
  1. package/index.d.ts +6 -3
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  // The types of "yellowcode/mod". Generated by tools/mod-types.ts from src/mods; do not edit.
2
- import type { KeyEvent, RGBA } from "@opentui/core"
2
+ import type { KeyEvent, RGBA, SyntaxStyle } from "@opentui/core"
3
3
  import type { Component, JSX } from "solid-js"
4
4
 
5
- export declare const apiVersion = "0.2.1"
5
+ export declare const apiVersion = "0.2.2"
6
6
 
7
7
  export type ModTheme = {
8
8
  readonly background: RGBA | null
@@ -17,8 +17,11 @@ export type ModTheme = {
17
17
  readonly selection: RGBA | null
18
18
  readonly diffAddText: RGBA
19
19
  readonly diffDelText: RGBA
20
+ readonly diffAdd: RGBA | null
21
+ readonly diffDel: RGBA | null
20
22
  }
21
23
  export declare const theme: ModTheme
24
+ export declare const syntaxStyle: () => SyntaxStyle
22
25
  export declare function Diff(props: { diff: string; lang?: string; context?: number }): JSX.Element
23
26
  export declare function Code(props: { code: string; lang: string }): JSX.Element
24
27
  export declare function Rule(props: { width: number }): JSX.Element
@@ -194,7 +197,7 @@ export type ModInputOptions = {
194
197
  export type ModDialogViewProps = {
195
198
  width: number
196
199
  height: number
197
- onKey: (handler: (key: KeyEvent) => void) => Dispose
200
+ onKey: (handler: (key: KeyEvent) => boolean | void) => Dispose
198
201
  close(): void
199
202
  }
200
203
  export type ModDialogOptions = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yellowcode/mod",
3
- "version": "0.4.0",
3
+ "version": "0.5.0-beta.1",
4
4
  "description": "Types of the YellowCode mod API",
5
5
  "license": "GPL-3.0-only",
6
6
  "author": "Arda Sarı",