@netless/fastboard-ui 0.3.2 → 0.3.3
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.js +27 -20
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +27 -20
- package/dist/index.mjs.map +1 -1
- package/dist/index.svelte.mjs +19 -14
- package/dist/index.svelte.mjs.map +1 -1
- package/package.json +4 -5
- package/src/components/Fastboard/Fastboard.svelte +1 -1
- package/src/components/Fastboard/ReplayFastboard.svelte +1 -1
- package/src/components/Toolbar/components/Contents.svelte +6 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@netless/fastboard-ui",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.3",
|
|
4
4
|
"description": "The front-end of @netless/fastboard-core.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"svelte": "dist/index.svelte.mjs",
|
|
@@ -10,14 +10,14 @@
|
|
|
10
10
|
],
|
|
11
11
|
"repository": "netless-io/fastboard",
|
|
12
12
|
"peerDependencies": {
|
|
13
|
-
"@netless/fastboard-core": "0.3.
|
|
13
|
+
"@netless/fastboard-core": "0.3.3"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
16
|
"tippy.js": "^6.3.7"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
19
|
"@netless/esbuild-plugin-inline-sass": "0.1.0",
|
|
20
|
-
"@netless/fastboard-core": "0.3.
|
|
20
|
+
"@netless/fastboard-core": "0.3.3"
|
|
21
21
|
},
|
|
22
22
|
"scripts": {
|
|
23
23
|
"cleanup": "rimraf dist",
|
|
@@ -27,6 +27,5 @@
|
|
|
27
27
|
"test:ssr": "esbuild-dev test/ssr.ts"
|
|
28
28
|
},
|
|
29
29
|
"module": "dist/index.mjs",
|
|
30
|
-
"types": "dist/index.d.ts"
|
|
31
|
-
"readme": "## @netless/fastboard-ui\n\nThe front-end of [@netless/fastboard-core](https://github.com/netless-io/fastboard/tree/main/packages/fastboard-core).\n\n### License\n\nMIT @ [netless](https://github.com/netless-io)\n"
|
|
30
|
+
"types": "dist/index.d.ts"
|
|
32
31
|
}
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
</script>
|
|
59
59
|
|
|
60
60
|
<div class="{name}-root" class:loading={!app}>
|
|
61
|
-
<div class="{name}-view" bind:this={container} on:touchstart|capture={tippy_hide_all} />
|
|
61
|
+
<div class="{name}-view" bind:this={container} on:touchstart|capture|passive={tippy_hide_all} />
|
|
62
62
|
<div class="{name}-left" class:hidden={!(layout === "visible" || layout === "toolbar-only")}>
|
|
63
63
|
{#if config.toolbar?.enable !== false}
|
|
64
64
|
<Toolbar {app} {theme} {language} config={config.toolbar} />
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
</script>
|
|
37
37
|
|
|
38
38
|
<div class="{name}-root" class:loading={!player}>
|
|
39
|
-
<div class="{name}-view" bind:this={container} on:touchstart|capture={tippy_hide_all} />
|
|
39
|
+
<div class="{name}-view" bind:this={container} on:touchstart|capture|passive={tippy_hide_all} />
|
|
40
40
|
<div class="{name}-bottom">
|
|
41
41
|
<PlayerControl {player} {theme} {language} />
|
|
42
42
|
</div>
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
import StrokeColor from "./StrokeColor.svelte";
|
|
19
19
|
import TextColor from "./TextColor.svelte";
|
|
20
20
|
import Shapes from "./Shapes.svelte";
|
|
21
|
+
import { tippy_hide_all } from "../../../actions/tippy";
|
|
21
22
|
|
|
22
23
|
export let app: FastboardApp | null | undefined = null;
|
|
23
24
|
export let theme: Theme = "light";
|
|
@@ -180,6 +181,10 @@
|
|
|
180
181
|
{#each $apps as netless_app}
|
|
181
182
|
{@const { icon, label, kind, onClick } = netless_app}
|
|
182
183
|
{@const state = $status && $status[kind]}
|
|
184
|
+
{@const on_click = () => {
|
|
185
|
+
app && onClick(app);
|
|
186
|
+
tippy_hide_all();
|
|
187
|
+
}}
|
|
183
188
|
<button
|
|
184
189
|
class="{name}-app-btn {kind} {theme}"
|
|
185
190
|
class:is-loading={state && state.status === "loading"}
|
|
@@ -187,7 +192,7 @@
|
|
|
187
192
|
title={label + (state && state.reason ? ": " + state.reason : "")}
|
|
188
193
|
data-app-kind={netless_app.kind}
|
|
189
194
|
disabled={state && state.status !== "idle"}
|
|
190
|
-
on:click={
|
|
195
|
+
on:click={on_click}
|
|
191
196
|
>
|
|
192
197
|
<img class="{name}-app-btn-icon {theme}" src={icon} alt={kind} title={label} />
|
|
193
198
|
<span class="{name}-app-btn-text {theme}">{label}</span>
|