diff --git a/docs/classes/_script__lib_cyberterminal_.cyberterminal.md b/docs/classes/_script__lib_cyberterminal_.cyberterminal.md
index 54926ba..a460630 100644
--- a/docs/classes/_script__lib_cyberterminal_.cyberterminal.md
+++ b/docs/classes/_script__lib_cyberterminal_.cyberterminal.md
@@ -77,7 +77,7 @@ ___
▸ **addMachine**(): [MachineWorker](../interfaces/_script__lib_machineworker_.machineworker.md)
-*Defined in [script/_lib/CyberTerminal.ts:90](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L90)*
+*Defined in [script/_lib/CyberTerminal.ts:79](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L79)*
**Returns:** [MachineWorker](../interfaces/_script__lib_machineworker_.machineworker.md)
@@ -88,7 +88,7 @@ ___
▸ **connectTo**(url: *`string`*): `Promise`<`void`>
-*Defined in [script/_lib/CyberTerminal.ts:43](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L43)*
+*Defined in [script/_lib/CyberTerminal.ts:36](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L36)*
**Parameters:**
@@ -105,7 +105,7 @@ ___
▸ **removeMachine**(): `void`
-*Defined in [script/_lib/CyberTerminal.ts:101](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L101)*
+*Defined in [script/_lib/CyberTerminal.ts:91](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L91)*
**Returns:** `void`
@@ -114,16 +114,15 @@ ___
### setAddress
-▸ **setAddress**(url: *`string`*, push: *`boolean`*): `void`
+▸ **setAddress**(url: *`string`*): `void`
-*Defined in [script/_lib/CyberTerminal.ts:125](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L125)*
+*Defined in [script/_lib/CyberTerminal.ts:116](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/CyberTerminal.ts#L116)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| url | `string` |
-| push | `boolean` |
**Returns:** `void`
diff --git a/docs/classes/_script__lib_electronsys_.electronsys.md b/docs/classes/_script__lib_electronsys_.electronsys.md
index 66a32b7..c62f61c 100644
--- a/docs/classes/_script__lib_electronsys_.electronsys.md
+++ b/docs/classes/_script__lib_electronsys_.electronsys.md
@@ -48,6 +48,7 @@ Sys implementation for electron app. See [Sys](../interfaces/__lib_sys_.sys.md)
* [setDisplayMode](_script__lib_electronsys_.electronsys.md#setdisplaymode)
* [setNativeMouse](_script__lib_electronsys_.electronsys.md#setnativemouse)
* [setTextInput](_script__lib_electronsys_.electronsys.md#settextinput)
+* [showLink](_script__lib_electronsys_.electronsys.md#showlink)
* [startTone](_script__lib_electronsys_.electronsys.md#starttone)
* [stopTone](_script__lib_electronsys_.electronsys.md#stoptone)
* [waitForVsync](_script__lib_electronsys_.electronsys.md#waitforvsync)
@@ -177,7 +178,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[addEventListener](_script__lib_websys_.websys.md#addeventlistener)*
-*Defined in [script/_lib/WebSys.ts:449](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L449)*
+*Defined in [script/_lib/WebSys.ts:456](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L456)*
**Parameters:**
@@ -199,7 +200,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[createMachine](_script__lib_websys_.websys.md#createmachine)*
-*Defined in [script/_lib/WebSys.ts:252](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L252)*
+*Defined in [script/_lib/WebSys.ts:246](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L246)*
**Returns:** [WebMachineWorker](_script__lib_websys_.webmachineworker.md)
@@ -235,7 +236,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[drawBitmap](_script__lib_websys_.websys.md#drawbitmap)*
-*Defined in [script/_lib/WebSys.ts:90](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L90)*
+*Defined in [script/_lib/WebSys.ts:84](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L84)*
**Parameters:**
@@ -256,7 +257,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[focusInput](_script__lib_websys_.websys.md#focusinput)*
-*Defined in [script/_lib/WebSys.ts:395](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L395)*
+*Defined in [script/_lib/WebSys.ts:389](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L389)*
**Parameters:**
@@ -275,7 +276,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[head](_script__lib_websys_.websys.md#head)*
-*Defined in [script/_lib/WebSys.ts:354](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L354)*
+*Defined in [script/_lib/WebSys.ts:348](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L348)*
**Parameters:**
@@ -311,7 +312,7 @@ ___
### openWeb
-▸ **openWeb**(path: *`string`*): `any`
+▸ **openWeb**(path: *`string`*): `boolean`
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[openWeb](../interfaces/_script__lib_sys_.sys.md#openweb)*
@@ -325,7 +326,7 @@ ___
| ------ | ------ |
| path | `string` |
-**Returns:** `any`
+**Returns:** `boolean`
___
@@ -336,7 +337,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[post](_script__lib_websys_.websys.md#post)*
-*Defined in [script/_lib/WebSys.ts:317](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L317)*
+*Defined in [script/_lib/WebSys.ts:311](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L311)*
**Parameters:**
@@ -358,7 +359,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[print](_script__lib_websys_.websys.md#print)*
-*Defined in [script/_lib/WebSys.ts:98](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L98)*
+*Defined in [script/_lib/WebSys.ts:92](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L92)*
**Parameters:**
@@ -401,7 +402,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[replaceTextInput](_script__lib_websys_.websys.md#replacetextinput)*
-*Defined in [script/_lib/WebSys.ts:422](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L422)*
+*Defined in [script/_lib/WebSys.ts:416](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L416)*
**Parameters:**
@@ -418,7 +419,7 @@ ___
### setAddress
-▸ **setAddress**(url: *`string`*, push: *`boolean`*): `void`
+▸ **setAddress**(url: *`string`*): `void`
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[setAddress](../interfaces/_script__lib_sys_.sys.md#setaddress)*
@@ -431,7 +432,6 @@ ___
| Param | Type |
| ------ | ------ |
| url | `string` |
-| push | `boolean` |
**Returns:** `void`
@@ -444,7 +444,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[setDisplayMode](_script__lib_websys_.websys.md#setdisplaymode)*
-*Defined in [script/_lib/WebSys.ts:51](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L51)*
+*Defined in [script/_lib/WebSys.ts:45](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L45)*
**Parameters:**
@@ -469,7 +469,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[setNativeMouse](_script__lib_websys_.websys.md#setnativemouse)*
-*Defined in [script/_lib/WebSys.ts:440](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L440)*
+*Defined in [script/_lib/WebSys.ts:434](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L434)*
**Parameters:**
@@ -488,7 +488,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[setTextInput](_script__lib_websys_.websys.md#settextinput)*
-*Defined in [script/_lib/WebSys.ts:413](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L413)*
+*Defined in [script/_lib/WebSys.ts:407](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L407)*
**Parameters:**
@@ -501,6 +501,25 @@ ___
**Returns:** `void`
+___
+
+
+### showLink
+
+▸ **showLink**(url: *`string`*): `HTMLElement`
+
+*Inherited from [WebSys](_script__lib_websys_.websys.md).[showLink](_script__lib_websys_.websys.md#showlink)*
+
+*Defined in [script/_lib/WebSys.ts:443](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L443)*
+
+**Parameters:**
+
+| Param | Type |
+| ------ | ------ |
+| url | `string` |
+
+**Returns:** `HTMLElement`
+
___
@@ -510,7 +529,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[startTone](_script__lib_websys_.websys.md#starttone)*
-*Defined in [script/_lib/WebSys.ts:388](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L388)*
+*Defined in [script/_lib/WebSys.ts:382](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L382)*
**Returns:** `void`
@@ -523,7 +542,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[stopTone](_script__lib_websys_.websys.md#stoptone)*
-*Defined in [script/_lib/WebSys.ts:391](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L391)*
+*Defined in [script/_lib/WebSys.ts:385](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L385)*
**Returns:** `void`
@@ -536,7 +555,7 @@ ___
*Inherited from [WebSys](_script__lib_websys_.websys.md).[waitForVsync](_script__lib_websys_.websys.md#waitforvsync)*
-*Defined in [script/_lib/WebSys.ts:246](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L246)*
+*Defined in [script/_lib/WebSys.ts:240](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L240)*
**Returns:** `Promise`<`Object`>
diff --git a/docs/classes/_script__lib_websys_.webmachineworker.md b/docs/classes/_script__lib_websys_.webmachineworker.md
index 38e04ba..10edde6 100644
--- a/docs/classes/_script__lib_websys_.webmachineworker.md
+++ b/docs/classes/_script__lib_websys_.webmachineworker.md
@@ -37,7 +37,7 @@
⊕ **new WebMachineWorker**(): [WebMachineWorker](_script__lib_websys_.webmachineworker.md)
-*Defined in [script/_lib/WebSys.ts:675](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L675)*
+*Defined in [script/_lib/WebSys.ts:683](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L683)*
**Returns:** [WebMachineWorker](_script__lib_websys_.webmachineworker.md)
@@ -53,7 +53,7 @@ ___
*Implementation of [MachineWorker](../interfaces/_script__lib_machineworker_.machineworker.md).[baseUrl](../interfaces/_script__lib_machineworker_.machineworker.md#baseurl)*
-*Defined in [script/_lib/WebSys.ts:675](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L675)*
+*Defined in [script/_lib/WebSys.ts:683](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L683)*
___
@@ -62,7 +62,7 @@ ___
**● worker**: *`Worker`*
-*Defined in [script/_lib/WebSys.ts:674](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L674)*
+*Defined in [script/_lib/WebSys.ts:682](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L682)*
___
@@ -76,7 +76,7 @@ ___
*Implementation of [MachineWorker](../interfaces/_script__lib_machineworker_.machineworker.md).[onMessage](../interfaces/_script__lib_machineworker_.machineworker.md#onmessage)*
-*Defined in [script/_lib/WebSys.ts:685](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L685)*
+*Defined in [script/_lib/WebSys.ts:693](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L693)*
**Parameters:**
@@ -93,7 +93,7 @@ ___
▸ **send**(msg: *`any`*, transferables?: * `any`[] | `undefined`*): `void`
-*Defined in [script/_lib/WebSys.ts:681](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L681)*
+*Defined in [script/_lib/WebSys.ts:689](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L689)*
**Parameters:**
@@ -113,7 +113,7 @@ ___
*Implementation of [MachineWorker](../interfaces/_script__lib_machineworker_.machineworker.md).[terminate](../interfaces/_script__lib_machineworker_.machineworker.md#terminate)*
-*Defined in [script/_lib/WebSys.ts:691](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L691)*
+*Defined in [script/_lib/WebSys.ts:699](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L699)*
**Returns:** `void`
diff --git a/docs/classes/_script__lib_websys_.websys.md b/docs/classes/_script__lib_websys_.websys.md
index 31423cf..5b888ea 100644
--- a/docs/classes/_script__lib_websys_.websys.md
+++ b/docs/classes/_script__lib_websys_.websys.md
@@ -48,6 +48,7 @@ Sys implementation for web browsers. See [Sys](../interfaces/__lib_sys_.sys.md)
* [setDisplayMode](_script__lib_websys_.websys.md#setdisplaymode)
* [setNativeMouse](_script__lib_websys_.websys.md#setnativemouse)
* [setTextInput](_script__lib_websys_.websys.md#settextinput)
+* [showLink](_script__lib_websys_.websys.md#showlink)
* [startTone](_script__lib_websys_.websys.md#starttone)
* [stopTone](_script__lib_websys_.websys.md#stoptone)
* [waitForVsync](_script__lib_websys_.websys.md#waitforvsync)
@@ -159,7 +160,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[addEventListener](../interfaces/_script__lib_sys_.sys.md#addeventlistener)*
-*Defined in [script/_lib/WebSys.ts:449](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L449)*
+*Defined in [script/_lib/WebSys.ts:456](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L456)*
**Parameters:**
@@ -179,7 +180,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[createMachine](../interfaces/_script__lib_sys_.sys.md#createmachine)*
-*Defined in [script/_lib/WebSys.ts:252](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L252)*
+*Defined in [script/_lib/WebSys.ts:246](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L246)*
**Returns:** [WebMachineWorker](_script__lib_websys_.webmachineworker.md)
@@ -192,7 +193,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[delete](../interfaces/_script__lib_sys_.sys.md#delete)*
-*Defined in [script/_lib/WebSys.ts:345](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L345)*
+*Defined in [script/_lib/WebSys.ts:339](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L339)*
**Parameters:**
@@ -211,7 +212,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[drawBitmap](../interfaces/_script__lib_sys_.sys.md#drawbitmap)*
-*Defined in [script/_lib/WebSys.ts:90](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L90)*
+*Defined in [script/_lib/WebSys.ts:84](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L84)*
**Parameters:**
@@ -230,7 +231,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[focusInput](../interfaces/_script__lib_sys_.sys.md#focusinput)*
-*Defined in [script/_lib/WebSys.ts:395](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L395)*
+*Defined in [script/_lib/WebSys.ts:389](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L389)*
**Parameters:**
@@ -247,7 +248,7 @@ ___
▸ **head**(filename: *`string`*): `Promise`<`string`>
-*Defined in [script/_lib/WebSys.ts:354](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L354)*
+*Defined in [script/_lib/WebSys.ts:348](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L348)*
**Parameters:**
@@ -266,7 +267,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[list](../interfaces/_script__lib_sys_.sys.md#list)*
-*Defined in [script/_lib/WebSys.ts:365](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L365)*
+*Defined in [script/_lib/WebSys.ts:359](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L359)*
**Parameters:**
@@ -285,7 +286,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[openWeb](../interfaces/_script__lib_sys_.sys.md#openweb)*
-*Defined in [script/_lib/WebSys.ts:445](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L445)*
+*Defined in [script/_lib/WebSys.ts:439](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L439)*
**Parameters:**
@@ -302,7 +303,7 @@ ___
▸ **post**(filename: *`string`*, data: * `string` | `ArrayBuffer`*): `Promise`<`ArrayBuffer`>
-*Defined in [script/_lib/WebSys.ts:317](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L317)*
+*Defined in [script/_lib/WebSys.ts:311](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L311)*
**Parameters:**
@@ -322,7 +323,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[print](../interfaces/_script__lib_sys_.sys.md#print)*
-*Defined in [script/_lib/WebSys.ts:98](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L98)*
+*Defined in [script/_lib/WebSys.ts:92](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L92)*
**Parameters:**
@@ -341,7 +342,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[read](../interfaces/_script__lib_sys_.sys.md#read)*
-*Defined in [script/_lib/WebSys.ts:256](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L256)*
+*Defined in [script/_lib/WebSys.ts:250](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L250)*
**Parameters:**
@@ -361,7 +362,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[replaceTextInput](../interfaces/_script__lib_sys_.sys.md#replacetextinput)*
-*Defined in [script/_lib/WebSys.ts:422](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L422)*
+*Defined in [script/_lib/WebSys.ts:416](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L416)*
**Parameters:**
@@ -378,7 +379,7 @@ ___
### setAddress
-▸ **setAddress**(url: *`string`*, push: *`boolean`*): `void`
+▸ **setAddress**(url: *`string`*): `void`
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[setAddress](../interfaces/_script__lib_sys_.sys.md#setaddress)*
@@ -389,7 +390,6 @@ ___
| Param | Type |
| ------ | ------ |
| url | `string` |
-| push | `boolean` |
**Returns:** `void`
@@ -400,7 +400,7 @@ ___
▸ **setDisplayMode**(mode: * "none" | "text" | "pixel"*, width: *`number`*, height: *`number`*, visibleWidth?: *`number`*, visibleHeight?: *`number`*): `void`
-*Defined in [script/_lib/WebSys.ts:51](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L51)*
+*Defined in [script/_lib/WebSys.ts:45](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L45)*
**Parameters:**
@@ -423,7 +423,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[setNativeMouse](../interfaces/_script__lib_sys_.sys.md#setnativemouse)*
-*Defined in [script/_lib/WebSys.ts:440](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L440)*
+*Defined in [script/_lib/WebSys.ts:434](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L434)*
**Parameters:**
@@ -440,7 +440,7 @@ ___
▸ **setTextInput**(text: *`string`*, pos: *`number`*, len: *`number`*, type?: * `undefined` | `string`*): `void`
-*Defined in [script/_lib/WebSys.ts:413](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L413)*
+*Defined in [script/_lib/WebSys.ts:407](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L407)*
**Parameters:**
@@ -453,6 +453,23 @@ ___
**Returns:** `void`
+___
+
+
+### showLink
+
+▸ **showLink**(url: *`string`*): `HTMLElement`
+
+*Defined in [script/_lib/WebSys.ts:443](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L443)*
+
+**Parameters:**
+
+| Param | Type |
+| ------ | ------ |
+| url | `string` |
+
+**Returns:** `HTMLElement`
+
___
@@ -460,7 +477,7 @@ ___
▸ **startTone**(): `void`
-*Defined in [script/_lib/WebSys.ts:388](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L388)*
+*Defined in [script/_lib/WebSys.ts:382](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L382)*
**Returns:** `void`
@@ -471,7 +488,7 @@ ___
▸ **stopTone**(): `void`
-*Defined in [script/_lib/WebSys.ts:391](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L391)*
+*Defined in [script/_lib/WebSys.ts:385](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L385)*
**Returns:** `void`
@@ -482,7 +499,7 @@ ___
▸ **waitForVsync**(): `Promise`<`Object`>
-*Defined in [script/_lib/WebSys.ts:246](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L246)*
+*Defined in [script/_lib/WebSys.ts:240](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L240)*
**Returns:** `Promise`<`Object`>
@@ -495,7 +512,7 @@ ___
*Implementation of [Sys](../interfaces/_script__lib_sys_.sys.md).[write](../interfaces/_script__lib_sys_.sys.md#write)*
-*Defined in [script/_lib/WebSys.ts:307](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L307)*
+*Defined in [script/_lib/WebSys.ts:301](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/WebSys.ts#L301)*
**Parameters:**
diff --git a/docs/interfaces/_script__lib_sys_.sys.md b/docs/interfaces/_script__lib_sys_.sys.md
index 99ceb96..0d5a011 100644
--- a/docs/interfaces/_script__lib_sys_.sys.md
+++ b/docs/interfaces/_script__lib_sys_.sys.md
@@ -135,7 +135,7 @@ ___
▸ **addEventListener**(event: *`string`*, listener: *`Function`*): `void`
-*Defined in [script/_lib/Sys.ts:133](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L133)*
+*Defined in [script/_lib/Sys.ts:132](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L132)*
**Parameters:**
@@ -153,7 +153,7 @@ ___
▸ **createMachine**(): [MachineWorker](_script__lib_machineworker_.machineworker.md)
-*Defined in [script/_lib/Sys.ts:70](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L70)*
+*Defined in [script/_lib/Sys.ts:69](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L69)*
Create a machine.
@@ -167,7 +167,7 @@ ___
▸ **delete**(filename: *`string`*): `Promise`<`boolean`>
-*Defined in [script/_lib/Sys.ts:90](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L90)*
+*Defined in [script/_lib/Sys.ts:89](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L89)*
Delete a file.
@@ -186,7 +186,7 @@ ___
▸ **drawBitmap**(buffer: *`ArrayBuffer`*): `void`
-*Defined in [script/_lib/Sys.ts:44](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L44)*
+*Defined in [script/_lib/Sys.ts:43](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L43)*
Draw given bitmap to pixel display.
@@ -205,7 +205,7 @@ ___
▸ **focusInput**(input: * "text" | "mouse" | "game"*): `string`[]
-*Defined in [script/_lib/Sys.ts:102](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L102)*
+*Defined in [script/_lib/Sys.ts:101](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L101)*
Focus on given type of input.
@@ -224,7 +224,7 @@ ___
▸ **list**(path: *`string`*): `Promise`<`any`>
-*Defined in [script/_lib/Sys.ts:96](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L96)*
+*Defined in [script/_lib/Sys.ts:95](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L95)*
List contents of a directory.
@@ -243,7 +243,7 @@ ___
▸ **openWeb**(url: *`string`*): `void`
-*Defined in [script/_lib/Sys.ts:131](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L131)*
+*Defined in [script/_lib/Sys.ts:130](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L130)*
Open a link in default web browser.
@@ -262,7 +262,7 @@ ___
▸ **print**(str: *`string`*): `void`
-*Defined in [script/_lib/Sys.ts:49](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L49)*
+*Defined in [script/_lib/Sys.ts:48](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L48)*
Print string to text display.
@@ -281,7 +281,7 @@ ___
▸ **read**(filename: *`string`*, options: *`any`*): `Promise`<`any`>
-*Defined in [script/_lib/Sys.ts:77](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L77)*
+*Defined in [script/_lib/Sys.ts:76](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L76)*
Read a file.
@@ -301,7 +301,7 @@ ___
▸ **replaceTextInput**(search: *`string`*, replace: *`string`*, fromIndex: *`number`*): `void`
-*Defined in [script/_lib/Sys.ts:119](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L119)*
+*Defined in [script/_lib/Sys.ts:118](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L118)*
Replace first occurrence of a substring with another.
@@ -320,9 +320,9 @@ ___
### setAddress
-▸ **setAddress**(url: *`string`*, push: *`boolean`*): `void`
+▸ **setAddress**(url: *`string`*): `void`
-*Defined in [script/_lib/Sys.ts:31](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L31)*
+*Defined in [script/_lib/Sys.ts:30](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L30)*
Set the current URL.
@@ -331,7 +331,6 @@ Set the current URL.
| Param | Type | Description |
| ------ | ------ | ------ |
| url | `string` | URL |
-| push | `boolean` | if it should be pushed to the navigation stack. |
**Returns:** `void`
@@ -342,7 +341,7 @@ ___
▸ **setDisplayMode**(mode: * "none" | "text" | "pixel"*, width: *`number`*, height: *`number`*): `void`
-*Defined in [script/_lib/Sys.ts:39](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L39)*
+*Defined in [script/_lib/Sys.ts:38](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L38)*
Switch display mode.
@@ -363,7 +362,7 @@ ___
▸ **setNativeMouse**(type: *`string`*): `void`
-*Defined in [script/_lib/Sys.ts:125](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L125)*
+*Defined in [script/_lib/Sys.ts:124](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L124)*
Set the appearance of the native mouse cursor.
@@ -382,7 +381,7 @@ ___
▸ **setTextInput**(text: *`string`*, pos: *`number`*, len: *`number`*, type?: * "multiline" | "text" | "password" | "number" | "url" | "email" | "tel"*): `void`
-*Defined in [script/_lib/Sys.ts:111](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L111)*
+*Defined in [script/_lib/Sys.ts:110](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L110)*
Set the state of the text input.
@@ -404,7 +403,7 @@ ___
▸ **startTone**(channel: *`number`*, frequency: *`number`*, volume?: * `undefined` | `number`*, type?: * "sine" | "square" | "sawtooth" | "triangle"*): `void`
-*Defined in [script/_lib/Sys.ts:58](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L58)*
+*Defined in [script/_lib/Sys.ts:57](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L57)*
Start tone oscillator
@@ -426,7 +425,7 @@ ___
▸ **stopTone**(channel: *`number`*): `void`
-*Defined in [script/_lib/Sys.ts:64](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L64)*
+*Defined in [script/_lib/Sys.ts:63](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L63)*
Stop tone oscillator
@@ -445,7 +444,7 @@ ___
▸ **write**(filename: *`string`*, data: * `string` | `ArrayBuffer`*): `Promise`<`boolean`>
-*Defined in [script/_lib/Sys.ts:84](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L84)*
+*Defined in [script/_lib/Sys.ts:83](https://github.com/FantasyInternet/cyberterminal/blob/HEAD/src/script/_lib/Sys.ts#L83)*
Write to a file.
diff --git a/package-lock.json b/package-lock.json
index 86452c0..506f460 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "cyberterminal",
- "version": "0.4.6",
+ "version": "0.4.7",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
diff --git a/package.json b/package.json
index 1255500..07715e5 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "cyberterminal",
- "version": "0.4.6",
+ "version": "0.4.7",
"description": "A fantasy internet client.",
"author": {
"name": "poeticandroid",
diff --git a/src/script/_lib/CyberTerminal.ts b/src/script/_lib/CyberTerminal.ts
index 6053db9..a408f95 100644
--- a/src/script/_lib/CyberTerminal.ts
+++ b/src/script/_lib/CyberTerminal.ts
@@ -31,13 +31,6 @@ export default class CyberTerminal {
}
}
})
- addEventListener("popstate", (e: PopStateEvent) => {
- if (this.machineWorkers.length) {
- if (e.state !== this.machineWorkers[this.machineWorkers.length - 1].baseUrl) {
- this.removeMachine()
- }
- }
- })
}
async connectTo(url: string) {
@@ -59,7 +52,7 @@ export default class CyberTerminal {
let msg = await this._findBoot(url)
if (msg.wasm) {
this.sys.print(".")
- this.sys.setAddress("" + msg.url, true)
+ this.setAddress("" + msg.url)
this.sys.setDisplayMode("none", 0, 0)
machine.send({
cmd: "resize",
@@ -69,21 +62,17 @@ export default class CyberTerminal {
this._connecting = setTimeout(() => {
this._connecting = null
}, 2048)
- } else if (typeof process !== "undefined") {
- this.sys.print(".")
+ } else {
+ this.sys.print("!\n")
+ this.sys.print("could not load boot.wasm!")
+ this.setAddress("" + msg.url)
+ this.sys.openWeb(url)
this._connecting = setTimeout(() => {
if (this.machineWorkers.length > 1) {
this.removeMachine()
- this._connecting = null
}
+ this._connecting = null
}, 2048)
- this.sys.openWeb(url)
- } else if (location.toString() !== url) {
- this.sys.print(".")
- this.sys.openWeb(url)
- } else {
- this.sys.print("!\n")
- this.sys.print("could not load boot.wasm!")
}
}
@@ -95,6 +84,7 @@ export default class CyberTerminal {
machine.onMessage(this._onMessage.bind(this))
this.sys.textInput.setState({ type: "multiline", text: "", pos: 0, len: 0, key: 0 })
this.sys.chipSound.stopAll()
+ console.log("Machines in stack", this.machineWorkers.length)
return machine
}
@@ -104,27 +94,28 @@ export default class CyberTerminal {
console.log("Disconnecting from", machine ? machine.baseUrl : machine)
this.sys.setDisplayMode("text", 80, 20)
this.sys.print("\n\nDisconnecting...")
- history.back()
- if (this.machineWorkers.length)
- this.sys.setAddress(this.machineWorkers[this.machineWorkers.length - 1].baseUrl, false)
+ this.sys.textInput.setState({ type: "multiline", text: "", pos: 0, len: 0 })
+ this.sys.chipSound.stopAll()
setTimeout(() => {
if (this.machineWorkers.length) {
+ this.setAddress(this.machineWorkers[this.machineWorkers.length - 1].baseUrl)
this.sys.setDisplayMode("none", 0, 0)
this.machineWorkers[this.machineWorkers.length - 1].send({ cmd: "resume" })
} else {
+ console.log("Going back, coz no machines left..")
history.back()
setTimeout(() => {
+ console.log("Reloading, coz no machines left")
location.reload()
}, 1024)
}
}, 128)
- this.sys.textInput.setState({ type: "multiline", text: "", pos: 0, len: 0 })
- this.sys.chipSound.stopAll()
+ console.log("Machines in stack", this.machineWorkers.length)
}
- setAddress(url: string, push: boolean) {
+ setAddress(url: string) {
this.machineWorkers[this.machineWorkers.length - 1].baseUrl = url
- this.sys.setAddress(url, push)
+ this.sys.setAddress(url)
}
diff --git a/src/script/_lib/ElectronSys.ts b/src/script/_lib/ElectronSys.ts
index f4f891a..9984709 100644
--- a/src/script/_lib/ElectronSys.ts
+++ b/src/script/_lib/ElectronSys.ts
@@ -43,7 +43,7 @@ export default class ElectronSys extends WebSys {
this._createUserFolder()
}
- setAddress(url: string, push: boolean) {
+ setAddress(url: string) {
document.title = url + " - " + this._title
}
@@ -160,13 +160,23 @@ export default class ElectronSys extends WebSys {
}
openWeb(path: string) {
+ let a = this.showLink(path).querySelector("a")
let url = new URL(path)
- if (url.protocol !== "file:") {
- return shell.openExternal(path)
+ if (url.protocol === "file:") {
+ path = decodeURI(url.pathname)
+ if (process.platform === "win32") path = path.substr(1)
+ a.textContent = path
+ a.addEventListener("click", (e) => {
+ shell.showItemInFolder(path)
+ e.preventDefault()
+ })
+ } else {
+ a.addEventListener("click", (e) => {
+ shell.openExternal(path)
+ e.preventDefault()
+ })
}
- path = decodeURI(url.pathname)
- if (process.platform === "win32") path = path.substr(1)
- shell.showItemInFolder(path)
+ return true
}
/** _privates */
diff --git a/src/script/_lib/Sys.ts b/src/script/_lib/Sys.ts
index 512d922..f17abbb 100644
--- a/src/script/_lib/Sys.ts
+++ b/src/script/_lib/Sys.ts
@@ -26,9 +26,8 @@ export default interface Sys {
/**
* Set the current URL.
* @param url URL
- * @param push if it should be pushed to the navigation stack.
*/
- setAddress(url: string, push: boolean): void
+ setAddress(url: string): void
/**
* Switch display mode.
diff --git a/src/script/_lib/WebSys.ts b/src/script/_lib/WebSys.ts
index c516e52..14a739c 100644
--- a/src/script/_lib/WebSys.ts
+++ b/src/script/_lib/WebSys.ts
@@ -38,14 +38,8 @@ export default class WebSys implements Sys {
this.startupUrl = location.toString()
}
- setAddress(url: string, push: boolean) {
- if (url !== location.toString()) {
- if (push) {
- history.pushState(url, url, url)
- } else {
- history.replaceState(url, url, url)
- }
- }
+ setAddress(url: string) {
+ history.replaceState(url, url, url)
}
setDisplayMode(mode: "none" | "text" | "pixel", width: number, height: number, visibleWidth = width, visibleHeight = height) {
@@ -443,7 +437,20 @@ export default class WebSys implements Sys {
}
openWeb(url: string) {
- location.assign(url)
+ this.showLink(url)
+ }
+
+ showLink(url: string) {
+ let dialog = this._container.querySelector(".dialog")
+ dialog.innerHTML = '
👆
'
+ let a = dialog.querySelector("a")
+ a.href = url
+ a.textContent = url
+ dialog.classList.add("active")
+ setTimeout(() => {
+ dialog.classList.remove("active")
+ }, 4096)
+ return dialog
}
addEventListener(event: string, fn: Function) {
@@ -482,9 +489,10 @@ export default class WebSys implements Sys {
private _initContainer() {
let style = document.createElement("style")
- style.textContent = css.replace(/;/g, " !important;")
+ style.textContent = css.replace(/}/g, ";}").replace(/;/g, " !important;")
; (document.querySelector("head")).insertBefore(style, document.querySelector("head *"))
- this._container.innerHTML = ''
+ this._container.innerHTML =
+ ''
this._displayContainer = this._container.querySelector(".display")
addEventListener("resize", () => { this._resize() })
}
diff --git a/src/script/_lib/css.ts b/src/script/_lib/css.ts
index aa9603c..f26dfef 100644
--- a/src/script/_lib/css.ts
+++ b/src/script/_lib/css.ts
@@ -1 +1 @@
-export default "fantasy-terminal{align-items:center;background-color:black;color:#ccc;display:flex;justify-content:center;overflow:hidden;position:relative;touch-action:none;min-width:1em;min-height:1em;max-height:100vh}fantasy-terminal pre{font-family:monospace;white-space:pre}fantasy-terminal pre span.current{text-decoration:underline}fantasy-terminal canvas{min-width:none;max-width:none;min-height:none;max-height:none}fantasy-terminal .input{position:absolute;top:0;left:0}fantasy-terminal .input .text{position:absolute;right:100vw;bottom:100vh}fantasy-terminal .input .text textarea,fantasy-terminal .input .text input{position:static}fantasy-terminal .input .game{font-size:24px;opacity:.75;position:fixed;left:0;bottom:-100%;width:100%;height:100%;transition:bottom 1s,opacity 1s}fantasy-terminal .input .game.active{bottom:0}fantasy-terminal .input .game.idle{opacity:.1;transition:bottom 1s,opacity 10s}fantasy-terminal .input .game .left{left:0}fantasy-terminal .input .game .left .slider{left:calc(40% - 1.5em)}fantasy-terminal .input .game .left .slider .knob{background-image:url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAsUlEQVRo3u2ZXQqAMAyDiyfv0XqDHUlfHIiIVvfXzHzgiwhNUJd2EyGEkFlJIrLuV0ITbwfh2YihibeHezDiYUx4BIY24RWWTYRDX74tQgj5ts5rwxraKid6BlD1WiPSs1rNkdFfXDtCG2wl80SUQSTd9U7LH0ZC2E8I/ieeYhmdIsh6mlAB28EghARCGz3bDfiNLU9OjGxNik2EF38nFEb8VRsMd8Bxnicgj5gIIcTHBmt2bad/9QQUAAAAAElFTkSuQmCC\")}fantasy-terminal .input .game .right{right:0}fantasy-terminal .input .game .right .slider{left:calc(60% - 1.5em)}fantasy-terminal .input .game .right .slider .knob{background-image:url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAACQUlEQVRo3u2YQUiUQRTHfy2aosQGuSB6CoqKvYTQoYN60kNoRIe6REHdPESX1KtQEl2ULoEgboJ0ExGUiLqXGEVUUGJYlKZ4UDMFa9sO/hcWmW/xk53BifnD8DHv8d68983Mf94MBPx/yO1oG8A7oAeo8DGBwpbxKQGAcqAW6JZs3bcE8qiR7LtPCRwAksBZYFyyTl/3wDegw8ZgCUdJ1QANQLVPM5BQ4G3AtGSDvm7iOsmWSz1YmeVkEsBh4Lz6f3xKIGeQPfaNhf4Cm8BnoBc4GCqtgAC7GNHmextRu1+RfsBBLGMa60wcoyQwJ8O+HbpTKodfOGCTFLAlFhuKa9wIZGXcKlmVblU/gHoHf/8WsACMioaPxHVwR7MwL+MM8BtocrSU36hualcct/dyQr+U8Ud9bzoK/rTGu6g4FoHZvVTOx4CfcvbUIZH0a/0fUr9PMZyL66gamJHxL+CEg+DLgSXguWFGJuI6e6QnkWdyMK0BbOJCkReNLHB0t46uy+iGqPWL+r2OuD+q3d+Nk7SWzLCBWrMWmSjP/Z8MulrdJZaBymJOqoD3wAfD/fWu/sKcZsUG95sO0Dwmpb9WzElGfz8dQa1TcjJiiftzQEuE/rL0U6HiCwiwgyfaZFcj9MeBNUsEUBKkxdVfDVxdCbzWgZjcz7PwULPQbZBngeb9voxSwCqwwva7aCF/3/NlL3Qp4AcqydeAVw4KwZKhgu2XuC2VJBvASd8Y6VJBBdmBpzA9s5ccCTxHSCAkEOA5/gEUCbDsMuovvwAAAABJRU5ErkJggg==\")}fantasy-terminal .input .game .left,fantasy-terminal .input .game .right{touch-action:none;position:absolute;bottom:0;width:40%;height:80%}fantasy-terminal .input .game .left .slider,fantasy-terminal .input .game .right .slider{background-color:gray;border-radius:1.5em;position:absolute;width:3em;height:3em;top:60%}fantasy-terminal .input .game .left .slider .knob,fantasy-terminal .input .game .right .slider .knob{background-color:white;border-radius:1em;position:absolute;left:0;top:0;margin:.5em .5em;width:2em;height:2em}"
+export default "fantasy-terminal{align-items:center;background-color:black;color:#ccc;display:flex;justify-content:center;overflow:hidden;position:relative;touch-action:none;min-width:1em;min-height:1em;max-height:100vh}fantasy-terminal pre{font-family:monospace;white-space:pre}fantasy-terminal pre span.current{text-decoration:underline}fantasy-terminal canvas{min-width:none;max-width:none;min-height:none;max-height:none}fantasy-terminal .input{position:absolute;top:0;left:0}fantasy-terminal .input .text{position:absolute;right:100vw;bottom:100vh}fantasy-terminal .input .text textarea,fantasy-terminal .input .text input{position:static}fantasy-terminal .input .game{font-size:24px;opacity:.75;position:fixed;left:0;bottom:-100%;width:100%;height:100%;transition:bottom 1s,opacity 1s}fantasy-terminal .input .game.active{bottom:0}fantasy-terminal .input .game.idle{opacity:.1;transition:bottom 1s,opacity 10s}fantasy-terminal .input .game .left{left:0}fantasy-terminal .input .game .left .slider{left:calc(40% - 1.5em)}fantasy-terminal .input .game .left .slider .knob{background-image:url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAsUlEQVRo3u2ZXQqAMAyDiyfv0XqDHUlfHIiIVvfXzHzgiwhNUJd2EyGEkFlJIrLuV0ITbwfh2YihibeHezDiYUx4BIY24RWWTYRDX74tQgj5ts5rwxraKid6BlD1WiPSs1rNkdFfXDtCG2wl80SUQSTd9U7LH0ZC2E8I/ieeYhmdIsh6mlAB28EghARCGz3bDfiNLU9OjGxNik2EF38nFEb8VRsMd8Bxnicgj5gIIcTHBmt2bad/9QQUAAAAAElFTkSuQmCC\")}fantasy-terminal .input .game .right{right:0}fantasy-terminal .input .game .right .slider{left:calc(60% - 1.5em)}fantasy-terminal .input .game .right .slider .knob{background-image:url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAACQUlEQVRo3u2YQUiUQRTHfy2aosQGuSB6CoqKvYTQoYN60kNoRIe6REHdPESX1KtQEl2ULoEgboJ0ExGUiLqXGEVUUGJYlKZ4UDMFa9sO/hcWmW/xk53BifnD8DHv8d68983Mf94MBPx/yO1oG8A7oAeo8DGBwpbxKQGAcqAW6JZs3bcE8qiR7LtPCRwAksBZYFyyTl/3wDegw8ZgCUdJ1QANQLVPM5BQ4G3AtGSDvm7iOsmWSz1YmeVkEsBh4Lz6f3xKIGeQPfaNhf4Cm8BnoBc4GCqtgAC7GNHmextRu1+RfsBBLGMa60wcoyQwJ8O+HbpTKodfOGCTFLAlFhuKa9wIZGXcKlmVblU/gHoHf/8WsACMioaPxHVwR7MwL+MM8BtocrSU36hualcct/dyQr+U8Ud9bzoK/rTGu6g4FoHZvVTOx4CfcvbUIZH0a/0fUr9PMZyL66gamJHxL+CEg+DLgSXguWFGJuI6e6QnkWdyMK0BbOJCkReNLHB0t46uy+iGqPWL+r2OuD+q3d+Nk7SWzLCBWrMWmSjP/Z8MulrdJZaBymJOqoD3wAfD/fWu/sKcZsUG95sO0Dwmpb9WzElGfz8dQa1TcjJiiftzQEuE/rL0U6HiCwiwgyfaZFcj9MeBNUsEUBKkxdVfDVxdCbzWgZjcz7PwULPQbZBngeb9voxSwCqwwva7aCF/3/NlL3Qp4AcqydeAVw4KwZKhgu2XuC2VJBvASd8Y6VJBBdmBpzA9s5ccCTxHSCAkEOA5/gEUCbDsMuovvwAAAABJRU5ErkJggg==\")}fantasy-terminal .input .game .left,fantasy-terminal .input .game .right{touch-action:none;position:absolute;bottom:0;width:40%;height:80%}fantasy-terminal .input .game .left .slider,fantasy-terminal .input .game .right .slider{background-color:gray;border-radius:1.5em;position:absolute;width:3em;height:3em;top:60%}fantasy-terminal .input .game .left .slider .knob,fantasy-terminal .input .game .right .slider .knob{background-color:white;border-radius:1em;position:absolute;left:0;top:0;margin:.5em .5em;width:2em;height:2em}fantasy-terminal .input .dialog{background-color:#def;box-shadow:0 0 1em black;color:#369;font-size:20px;transition:top 1s,max-height 2s;position:fixed;left:0;top:-4em;width:100%;max-height:0;overflow:hidden}fantasy-terminal .input .dialog.active,fantasy-terminal .input .dialog:hover{top:0;max-height:10em}fantasy-terminal .input .dialog p{text-align:center}fantasy-terminal .input .dialog a{color:inherit}fantasy-terminal .input .dialog button{background-color:rgba(127,127,127,0.25);border:2px solid inherit;margin:0 1em;padding:.1em 1em}"
diff --git a/src/style/defaults.less b/src/style/defaults.less
index db2d229..c34e06d 100644
--- a/src/style/defaults.less
+++ b/src/style/defaults.less
@@ -97,5 +97,35 @@ fantasy-terminal {
}
}
}
+ .dialog {
+ background-color: #def;
+ box-shadow: 0 0 1em black;
+ color: #369;
+ font-size: 20px;
+ transition: top 1s, max-height 2s;
+ position: fixed;
+ left: 0;
+ top: -4em;
+ width: 100%;
+ max-height: 0em;
+ overflow: hidden;
+ &.active,
+ &:hover {
+ top: 0em;
+ max-height: 10em;
+ }
+ p {
+ text-align: center;
+ }
+ a {
+ color: inherit;
+ }
+ button {
+ background-color: rgba(127, 127, 127, .25);
+ border: 2px solid inherit;
+ margin: 0 1em;
+ padding: .1em 1em;
+ }
+ }
}
}
\ No newline at end of file