@netless/fastboard-ui 1.0.0-canary.1 → 1.0.0-canary.4
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.ts +71 -56
- package/dist/index.js +358 -296
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +340 -260
- package/dist/index.mjs.map +1 -1
- package/dist/index.svelte.mjs +340 -260
- package/dist/index.svelte.mjs.map +1 -1
- package/package.json +3 -3
- package/src/actions/tippy.ts +9 -5
- package/src/components/Button/Button.svelte.d.ts +1 -2
- package/src/components/Fastboard/Fastboard.svelte +3 -3
- package/src/components/Fastboard/Fastboard.svelte.ts +1 -1
- package/src/components/Fastboard/ReplayFastboard.svelte +5 -2
- package/src/components/Fastboard/ReplayFastboard.svelte.ts +2 -1
- package/src/components/PageControl/PageControl.svelte +2 -2
- package/src/components/Toolbar/README.md +1 -1
- package/src/components/Toolbar/Toolbar.scss +1 -1
- package/src/components/Toolbar/Toolbar.svelte +2 -1
- package/src/components/Toolbar/Toolbar.svelte.d.ts +7 -1
- package/src/components/Toolbar/components/constants.ts +0 -2
- package/src/components/Toolbar/components/helper.ts +1 -1
- package/src/components/ZoomControl/ZoomControl.svelte +1 -1
- package/src/helpers/index.ts +72 -48
- package/src/index.ts +8 -4
- package/src/style.scss +4 -0
- package/src/typings.ts +16 -6
package/dist/index.js
CHANGED
|
@@ -1,58 +1,28 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
var
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
var
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
if (__getOwnPropSymbols)
|
|
19
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
20
|
-
if (__propIsEnum.call(b, prop))
|
|
21
|
-
__defNormalProp(a, prop, b[prop]);
|
|
22
|
-
}
|
|
23
|
-
return a;
|
|
24
|
-
};
|
|
25
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
26
|
-
var __export = (target, all) => {
|
|
27
|
-
for (var name10 in all)
|
|
28
|
-
__defProp(target, name10, { get: all[name10], enumerable: true });
|
|
29
|
-
};
|
|
30
|
-
var __copyProps = (to, from, except, desc) => {
|
|
31
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
32
|
-
for (let key of __getOwnPropNames(from))
|
|
33
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
34
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var Tippy = require('tippy.js');
|
|
6
|
+
|
|
7
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
8
|
+
|
|
9
|
+
var Tippy__default = /*#__PURE__*/_interopDefaultLegacy(Tippy);
|
|
10
|
+
|
|
11
|
+
// inline-sass-helper:inline-sass-style-helper.js
|
|
12
|
+
function injectStyle(text2) {
|
|
13
|
+
if (typeof document !== "undefined") {
|
|
14
|
+
var style = document.createElement("style");
|
|
15
|
+
var node = document.createTextNode(text2);
|
|
16
|
+
style.appendChild(node);
|
|
17
|
+
document.head.appendChild(style);
|
|
35
18
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// inline-sass-content:./src/style.scss
|
|
22
|
+
var style_default = '.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}.tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px #9aa1b126,0 4px 80px -8px #24282f40,0 4px 4px -2px #5b5e6926;background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}.fastboard-icon.light .fastboard-icon-stroke-color{stroke:var(--fastboard-color, #5d6066)}.fastboard-icon.light .fastboard-icon-fill-color{fill:var(--fastboard-color, #5d6066)}.fastboard-icon.light.is-active .fastboard-icon-stroke-color{stroke:var(--fastboard-active-color, #3381ff)}.fastboard-icon.light.is-active .fastboard-icon-fill-color{fill:var(--fastboard-active-color, #3381ff)}.fastboard-icon.dark .fastboard-icon-stroke-color{stroke:var(--fastboard-color, #7b7e84)}.fastboard-icon.dark .fastboard-icon-fill-color{fill:var(--fastboard-color, #7b7e84)}.fastboard-icon.dark.is-active .fastboard-icon-stroke-color{stroke:var(--fastboard-active-color, #2867cc)}.fastboard-icon.dark.is-active .fastboard-icon-fill-color{fill:var(--fastboard-active-color, #2867cc)}.fastboard-redo-undo{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}.fastboard-redo-undo *{box-sizing:inherit}.fastboard-redo-undo.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-redo-undo.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-redo-undo-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-redo-undo-btn svg,.fastboard-redo-undo-btn img{width:100%;height:100%;pointer-events:none}.fastboard-redo-undo-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-redo-undo-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-redo-undo-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-zoom-control{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}.fastboard-zoom-control *{box-sizing:inherit}.fastboard-zoom-control.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-zoom-control.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-zoom-control-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-zoom-control-btn svg,.fastboard-zoom-control-btn img{width:100%;height:100%;pointer-events:none}.fastboard-zoom-control-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-zoom-control-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-zoom-control-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-zoom-control-text{font-variant-numeric:tabular-nums}.fastboard-page-control{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}.fastboard-page-control *{box-sizing:inherit}.fastboard-page-control.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-page-control.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-page-control-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-page-control-btn svg,.fastboard-page-control-btn img{width:100%;height:100%;pointer-events:none}.fastboard-page-control-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-page-control-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-page-control-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-page-control-text{font-variant-numeric:tabular-nums}.fastboard-player-control{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px);width:100%}.fastboard-player-control *{box-sizing:inherit}.fastboard-player-control.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-player-control.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-player-control-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0;display:inline}.fastboard-player-control-btn svg,.fastboard-player-control-btn img{width:100%;height:100%;pointer-events:none}.fastboard-player-control-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-player-control-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-player-control-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-player-control-btn.loading svg,.fastboard-player-control-btn.loading img{animation:fastboard-player-control-rotate .5s linear infinite}@keyframes fastboard-player-control-rotate{to{transform:rotate(360deg)}}.fastboard-player-control-btn.speed{width:auto;padding:4px;text-align:right;font-size:14px;font-variant-numeric:tabular-nums}.fastboard-player-control-btn.is-active.light{color:var(--fastboard-active-color, #3381ff)}.fastboard-player-control-btn.is-active.dark{color:var(--fastboard-active-color, #2867cc)}.fastboard-player-control-speed-text,.fastboard-player-control-progress{font-size:14px;font-variant-numeric:tabular-nums;line-height:16px}.fastboard-player-control-progress{display:inline-flex;align-items:center}.fastboard-player-control-panel.speed{display:flex;flex-direction:column}.fastboard-toolbar{height:100%;display:flex;align-items:center;position:relative;transform:translate(0);transition:transform .5s cubic-bezier(.34,1.56,.64,1);pointer-events:none}.fastboard-toolbar.collapsed{transform:translate(-100%)}.fastboard-toolbar-handler{position:absolute;left:100%;width:17px;font-size:0;border-radius:3px;cursor:pointer;pointer-events:auto}.fastboard-toolbar-handler:focus-visible{outline:2px solid -webkit-focus-ring-color}.fastboard-toolbar-handler input[type=checkbox]{position:absolute;top:0;left:0;appearance:none;margin:0;width:100%;height:100%;cursor:pointer;opacity:0;z-index:-1}.fastboard-toolbar-handler svg{opacity:0;transition:opacity .5s 1s;pointer-events:none}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-bg-color{fill:var(--fastboard-bg-color, rgba(255, 255, 255, .9))}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-border-color{stroke:var(--fastboard-border-color, #e5e8f0)}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-image-stroke-color{stroke:var(--fastboard-color, #5d6066)}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-image-fill-color{fill:var(--fastboard-color, #5d6066)}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-bg-color{fill:var(--fastboard-bg-color, rgba(20, 24, 30, .9))}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-border-color{stroke:var(--fastboard-border-color, #383b42)}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-image-stroke-color{stroke:var(--fastboard-color, #7b7e84)}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-image-fill-color{fill:var(--fastboard-color, #7b7e84)}.fastboard-toolbar:hover .fastboard-toolbar-handler svg,.fastboard-toolbar.collapsed .fastboard-toolbar-handler svg{opacity:1;transition:opacity .2s}.fastboard-toolbar-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:4px;width:32px;height:32px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-toolbar-btn svg,.fastboard-toolbar-btn img{width:100%;height:100%;pointer-events:none}.fastboard-toolbar-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-toolbar-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-toolbar-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-slider{box-sizing:border-box;position:relative;width:100%;height:100%;display:flex;align-items:center}.fastboard-slider *{box-sizing:inherit}.fastboard-slider-track{appearance:none;background:rgba(0,0,0,0);border:0;border-radius:26px;flex:1;display:block;height:19px;margin:0;width:0;min-width:0;padding:0;transition:box-shadow .3s ease;cursor:pointer;touch-action:manipulation}.fastboard-slider-track::-webkit-slider-runnable-track{border:0;border-radius:2.5px;height:5px;transition:box-shadow .3s ease;user-select:none;background-color:#80808040;-webkit-user-select:none;background-image:linear-gradient(to right,currentColor var(--value, 0%),transparent var(--value, 0%))}.fastboard-slider-track::-webkit-slider-thumb{background:#fff;border:0;border-radius:100%;box-shadow:0 1px 1px #23292f26,0 0 0 1px #23292f33;width:13px;height:13px;position:relative;transition:all .2s ease;cursor:grab;appearance:none;margin-top:-4px}.fastboard-slider-track::-moz-range-track{border:0;border-radius:2.5px;height:5px;transition:box-shadow .3s ease;user-select:none;background-color:#80808040;-webkit-user-select:none}.fastboard-slider-track::-moz-range-thumb{appearance:none;background:#fff;border:0;border-radius:100%;box-shadow:0 1px 1px #23292f26,0 0 0 1px #23292f33;width:13px;height:13px;position:relative;transition:all .2s ease;cursor:grab}.fastboard-slider-track::-moz-range-progress{background:currentColor;border-radius:2.5px;height:5px}.fastboard-slider-track::-ms-track{border:0;border-radius:2.5px;height:5px;transition:box-shadow .3s ease;user-select:none;background-color:#80808040;-webkit-user-select:none;color:#0000}.fastboard-slider-track::-ms-thumb{appearance:none;background:#fff;border:0;border-radius:100%;box-shadow:0 1px 1px #23292f26,0 0 0 1px #23292f33;width:13px;height:13px;position:relative;transition:all .2s ease;cursor:grab;margin-top:0}.fastboard-slider-track::-ms-tooltip{display:none}.fastboard-slider-track::-moz-focus-outer{border:0}.fastboard-slider-track.grabbing::-webkit-slider-thumb{cursor:grabbing}.fastboard-slider-track.light{color:var(--fastboard-active-color, #3381ff)}.fastboard-slider-track.dark{color:var(--fastboard-active-color, #2867cc)}.fastboard-toolbar-contents{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px);padding:2px 0;gap:0;flex-direction:column}.fastboard-toolbar-contents *{box-sizing:inherit}.fastboard-toolbar-contents.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-toolbar-contents.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-toolbar-contents>.fastboard-toolbar-btn{margin:2px 4px}.fastboard-toolbar-btn-interactive{position:relative}.fastboard-toolbar-triangle{width:0px;height:0px;border-bottom:4px solid;border-left:4px solid rgba(0,0,0,0);position:absolute;bottom:0;right:0}.fastboard-toolbar-btn:focus+.fastboard-toolbar-triangle{opacity:0}.fastboard-toolbar-scrollable{padding:2px 4px;overflow:hidden;display:flex;flex-direction:column;gap:4px}.fastboard-toolbar-tooltip{display:inline-flex;align-items:center;gap:4px}.fastboard-toolbar-hotkey{display:inline-flex;margin-right:-4px;width:24px;height:24px;align-items:center;justify-content:center;background-color:#ffffff1a;border-radius:4px}.fastboard-toolbar-panel-wrapper{display:none}.fastboard-toolbar-panel{display:flex;flex-direction:column}.fastboard-toolbar-panel-divider{height:.5px;width:100%;margin:4px 0;background-color:#ffffff26}.fastboard-toolbar-colors,.fastboard-toolbar-shapes{display:grid;align-self:center;grid-template:repeat(2,1fr)/repeat(4,1fr);align-items:center;justify-items:center;gap:4px}.fastboard-toolbar-shape-btn,.fastboard-toolbar-color-btn{width:24px;height:24px;padding:0;display:inline-flex;align-items:center;justify-content:center}.fastboard-toolbar-color-btn{border:1px solid rgba(0,0,0,0)}.fastboard-toolbar-color-btn.light.is-active{border-color:var(--fastboard-active-color, #3381ff)}.fastboard-toolbar-color-btn.dark.is-active{border-color:var(--fastboard-active-color, #2867cc)}.fastboard-toolbar-color-item{display:inline-block;width:16px;height:16px;border-radius:4px;pointer-events:none}.fastboard-toolbar-panel.apps{display:grid;grid-template-columns:repeat(min(var(--n, 3),3),minmax(max-content,1fr));gap:4px}.fastboard-toolbar-app-btn{margin:0;border:0;border-radius:2px;padding:4px 6px;background-color:#0000;display:inline-flex;flex-direction:column;align-items:center;gap:4px;font-size:0}.fastboard-toolbar-app-btn:disabled{opacity:.8}.fastboard-toolbar-app-btn-icon{width:32px;height:32px;pointer-events:none}.fastboard-toolbar-app-btn-text{font-size:14px;line-height:1;max-width:100%;overflow:hidden;text-overflow:ellipsis}.fastboard-toolbar-app-btn.is-loading{cursor:progress}.fastboard-toolbar-app-btn.is-failed{cursor:not-allowed;opacity:.5}.fastboard-toolbar-app-btn:not(:disabled,.is-loading,.is-failed):hover.light{cursor:pointer;background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-toolbar-app-btn-text.light{color:var(--fastboard-color, #5d6066)}.fastboard-toolbar-app-btn:not(:disabled,.is-loading,.is-failed):hover.dark{cursor:pointer;background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-toolbar-app-btn-text.dark{color:var(--fastboard-color, #7b7e84)}.fastboard-root{position:relative;width:100%;height:100%;overflow:hidden}.fastboard-view{position:absolute;top:0;left:0;width:100%;height:100%}.fastboard-left{display:flex;align-items:center;position:absolute;bottom:62px;top:8px;left:0;z-index:200;pointer-events:none}.fastboard-left .fastboard-toolbar{padding-left:16px}.fastboard-bottom-left,.fastboard-bottom,.fastboard-bottom-right{display:flex;gap:10px;position:absolute;bottom:8px;left:8px;padding:8px;z-index:200;pointer-events:none}.fastboard-bottom-right{left:auto;right:8px}.fastboard-bottom{right:8px}.fastboard-left.hidden *,.fastboard-bottom.hidden *,.fastboard-bottom-left.hidden *,.fastboard-bottom-right.hidden *{opacity:0;pointer-events:none}.fastboard-tip{font-family:inherit;color:#d5d9e0;background-color:#03060d}.fastboard-tip[data-placement^=right]>.tippy-arrow:before{top:4px;border-width:4px;border-right-color:#03060d}.fastboard-tip[data-placement^=top]>.tippy-arrow:before{left:4px;border-width:4px;border-top-color:#03060d}.fastboard-panel .tippy-content{padding:8px}.netless-whiteboard:focus-visible{outline:none}';
|
|
40
23
|
|
|
41
|
-
// src/
|
|
42
|
-
|
|
43
|
-
__export(src_exports, {
|
|
44
|
-
Fastboard: () => Fastboard_default,
|
|
45
|
-
PageControl: () => PageControl_default,
|
|
46
|
-
PlayerControl: () => PlayerControl_default,
|
|
47
|
-
RedoUndo: () => RedoUndo_default,
|
|
48
|
-
ReplayFastboard: () => ReplayFastboard_default,
|
|
49
|
-
Toolbar: () => Toolbar_default,
|
|
50
|
-
ZoomControl: () => ZoomControl_default,
|
|
51
|
-
apps: () => apps,
|
|
52
|
-
createReplayUI: () => createReplayUI,
|
|
53
|
-
createUI: () => createUI
|
|
54
|
-
});
|
|
55
|
-
module.exports = __toCommonJS(src_exports);
|
|
24
|
+
// inline-sass-stub:./src/style.scss
|
|
25
|
+
injectStyle(style_default);
|
|
56
26
|
|
|
57
27
|
// ../../node_modules/.pnpm/svelte@3.49.0/node_modules/svelte/internal/index.mjs
|
|
58
28
|
function noop() {
|
|
@@ -591,7 +561,14 @@ function create_else_block(ctx) {
|
|
|
591
561
|
p(ctx2, dirty) {
|
|
592
562
|
if (default_slot) {
|
|
593
563
|
if (default_slot.p && (!current || dirty & 8)) {
|
|
594
|
-
update_slot_base(
|
|
564
|
+
update_slot_base(
|
|
565
|
+
default_slot,
|
|
566
|
+
default_slot_template,
|
|
567
|
+
ctx2,
|
|
568
|
+
ctx2[3],
|
|
569
|
+
!current ? get_all_dirty_from_scope(ctx2[3]) : get_slot_changes(default_slot_template, ctx2[3], dirty, null),
|
|
570
|
+
null
|
|
571
|
+
);
|
|
595
572
|
}
|
|
596
573
|
}
|
|
597
574
|
},
|
|
@@ -3416,11 +3393,8 @@ var Icons = {
|
|
|
3416
3393
|
Loading: Loading_default
|
|
3417
3394
|
};
|
|
3418
3395
|
var Icons_default = Icons;
|
|
3419
|
-
|
|
3420
|
-
// src/actions/tippy.ts
|
|
3421
|
-
var import_tippy = __toESM(require("tippy.js"));
|
|
3422
3396
|
if (is_client) {
|
|
3423
|
-
|
|
3397
|
+
Tippy__default["default"].setDefaultProps({
|
|
3424
3398
|
delay: [1e3, 400],
|
|
3425
3399
|
duration: 300,
|
|
3426
3400
|
offset: [0, 11],
|
|
@@ -3441,8 +3415,7 @@ if (is_client) {
|
|
|
3441
3415
|
}
|
|
3442
3416
|
}
|
|
3443
3417
|
function remove() {
|
|
3444
|
-
|
|
3445
|
-
(_a = instance59.popper.firstElementChild) == null ? void 0 : _a.classList.remove("fastboard-tip");
|
|
3418
|
+
instance59.popper.firstElementChild?.classList.remove("fastboard-tip");
|
|
3446
3419
|
}
|
|
3447
3420
|
return {
|
|
3448
3421
|
onCreate: add,
|
|
@@ -3455,7 +3428,7 @@ if (is_client) {
|
|
|
3455
3428
|
});
|
|
3456
3429
|
}
|
|
3457
3430
|
var tippy = function(node, props) {
|
|
3458
|
-
const instance59 =
|
|
3431
|
+
const instance59 = Tippy__default["default"](node, props);
|
|
3459
3432
|
return {
|
|
3460
3433
|
update(props2) {
|
|
3461
3434
|
instance59.setProps(props2);
|
|
@@ -3466,11 +3439,13 @@ var tippy = function(node, props) {
|
|
|
3466
3439
|
};
|
|
3467
3440
|
};
|
|
3468
3441
|
function tippy_hide_all() {
|
|
3469
|
-
document.querySelectorAll("[data-tippy-root]").forEach(
|
|
3470
|
-
|
|
3471
|
-
|
|
3472
|
-
|
|
3473
|
-
|
|
3442
|
+
document.querySelectorAll("[data-tippy-root]").forEach(tippy_hide);
|
|
3443
|
+
}
|
|
3444
|
+
function tippy_hide(el) {
|
|
3445
|
+
const instance59 = el._tippy;
|
|
3446
|
+
if (instance59) {
|
|
3447
|
+
instance59.hide();
|
|
3448
|
+
}
|
|
3474
3449
|
}
|
|
3475
3450
|
var tippy_menu = {
|
|
3476
3451
|
delay: 0,
|
|
@@ -3511,7 +3486,14 @@ function create_else_block_1(ctx) {
|
|
|
3511
3486
|
p(ctx2, dirty) {
|
|
3512
3487
|
if (default_slot) {
|
|
3513
3488
|
if (default_slot.p && (!current || dirty & 256)) {
|
|
3514
|
-
update_slot_base(
|
|
3489
|
+
update_slot_base(
|
|
3490
|
+
default_slot,
|
|
3491
|
+
default_slot_template,
|
|
3492
|
+
ctx2,
|
|
3493
|
+
ctx2[8],
|
|
3494
|
+
!current ? get_all_dirty_from_scope(ctx2[8]) : get_slot_changes(default_slot_template, ctx2[8], dirty, null),
|
|
3495
|
+
null
|
|
3496
|
+
);
|
|
3515
3497
|
}
|
|
3516
3498
|
}
|
|
3517
3499
|
if (!current || dirty & 7 && button_class_value !== (button_class_value = ctx2[1] + "-btn " + ctx2[0] + " " + ctx2[2])) {
|
|
@@ -3642,7 +3624,14 @@ function create_else_block2(ctx) {
|
|
|
3642
3624
|
p(ctx2, dirty) {
|
|
3643
3625
|
if (default_slot) {
|
|
3644
3626
|
if (default_slot.p && (!current || dirty & 256)) {
|
|
3645
|
-
update_slot_base(
|
|
3627
|
+
update_slot_base(
|
|
3628
|
+
default_slot,
|
|
3629
|
+
default_slot_template,
|
|
3630
|
+
ctx2,
|
|
3631
|
+
ctx2[8],
|
|
3632
|
+
!current ? get_all_dirty_from_scope(ctx2[8]) : get_slot_changes(default_slot_template, ctx2[8], dirty, null),
|
|
3633
|
+
null
|
|
3634
|
+
);
|
|
3646
3635
|
}
|
|
3647
3636
|
}
|
|
3648
3637
|
if (!current || dirty & 7 && button_class_value !== (button_class_value = ctx2[1] + "-btn " + ctx2[0] + " " + ctx2[2])) {
|
|
@@ -3718,14 +3707,14 @@ function create_if_block_1(ctx) {
|
|
|
3718
3707
|
if (!mounted) {
|
|
3719
3708
|
dispose = [
|
|
3720
3709
|
listen(button, "click", ctx[10]),
|
|
3721
|
-
action_destroyer(tippy_action = tippy.call(null, button,
|
|
3722
|
-
content: ctx[6]
|
|
3723
|
-
|
|
3710
|
+
action_destroyer(tippy_action = tippy.call(null, button, {
|
|
3711
|
+
content: ctx[6],
|
|
3712
|
+
...tippy_menu,
|
|
3724
3713
|
placement: ctx[7],
|
|
3725
3714
|
appendTo: document.body,
|
|
3726
3715
|
theme: ctx[2],
|
|
3727
3716
|
className: "fastboard-panel"
|
|
3728
|
-
}))
|
|
3717
|
+
})),
|
|
3729
3718
|
action_destroyer(tippy_action_1 = tippy.call(null, span1, {
|
|
3730
3719
|
content: ctx[4],
|
|
3731
3720
|
placement: ctx[5],
|
|
@@ -3738,7 +3727,14 @@ function create_if_block_1(ctx) {
|
|
|
3738
3727
|
p(ctx2, dirty) {
|
|
3739
3728
|
if (default_slot) {
|
|
3740
3729
|
if (default_slot.p && (!current || dirty & 256)) {
|
|
3741
|
-
update_slot_base(
|
|
3730
|
+
update_slot_base(
|
|
3731
|
+
default_slot,
|
|
3732
|
+
default_slot_template,
|
|
3733
|
+
ctx2,
|
|
3734
|
+
ctx2[8],
|
|
3735
|
+
!current ? get_all_dirty_from_scope(ctx2[8]) : get_slot_changes(default_slot_template, ctx2[8], dirty, null),
|
|
3736
|
+
null
|
|
3737
|
+
);
|
|
3742
3738
|
}
|
|
3743
3739
|
}
|
|
3744
3740
|
if (!current || dirty & 7 && button_class_value !== (button_class_value = ctx2[1] + "-btn " + ctx2[0] + " " + ctx2[2])) {
|
|
@@ -3748,14 +3744,14 @@ function create_if_block_1(ctx) {
|
|
|
3748
3744
|
button.disabled = ctx2[3];
|
|
3749
3745
|
}
|
|
3750
3746
|
if (tippy_action && is_function(tippy_action.update) && dirty & 196)
|
|
3751
|
-
tippy_action.update.call(null,
|
|
3752
|
-
content: ctx2[6]
|
|
3753
|
-
|
|
3747
|
+
tippy_action.update.call(null, {
|
|
3748
|
+
content: ctx2[6],
|
|
3749
|
+
...tippy_menu,
|
|
3754
3750
|
placement: ctx2[7],
|
|
3755
3751
|
appendTo: document.body,
|
|
3756
3752
|
theme: ctx2[2],
|
|
3757
3753
|
className: "fastboard-panel"
|
|
3758
|
-
})
|
|
3754
|
+
});
|
|
3759
3755
|
if (!current || dirty & 2 && span0_class_value !== (span0_class_value = ctx2[1] + "-triangle")) {
|
|
3760
3756
|
attr(span0, "class", span0_class_value);
|
|
3761
3757
|
}
|
|
@@ -3959,12 +3955,11 @@ function create_default_slot_3(ctx) {
|
|
|
3959
3955
|
};
|
|
3960
3956
|
}
|
|
3961
3957
|
function create_default_slot_2(ctx) {
|
|
3962
|
-
var _a;
|
|
3963
3958
|
let icon;
|
|
3964
3959
|
let current;
|
|
3965
3960
|
icon = new Icon_default({
|
|
3966
3961
|
props: {
|
|
3967
|
-
src:
|
|
3962
|
+
src: ctx[1]?.undo[ctx[2]],
|
|
3968
3963
|
alt: "[undo]",
|
|
3969
3964
|
$$slots: { default: [create_default_slot_3] },
|
|
3970
3965
|
$$scope: { ctx }
|
|
@@ -3979,10 +3974,9 @@ function create_default_slot_2(ctx) {
|
|
|
3979
3974
|
current = true;
|
|
3980
3975
|
},
|
|
3981
3976
|
p(ctx2, dirty) {
|
|
3982
|
-
var _a2;
|
|
3983
3977
|
const icon_changes = {};
|
|
3984
3978
|
if (dirty & 6)
|
|
3985
|
-
icon_changes.src =
|
|
3979
|
+
icon_changes.src = ctx2[1]?.undo[ctx2[2]];
|
|
3986
3980
|
if (dirty & 131073) {
|
|
3987
3981
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
3988
3982
|
}
|
|
@@ -4037,12 +4031,11 @@ function create_default_slot_1(ctx) {
|
|
|
4037
4031
|
};
|
|
4038
4032
|
}
|
|
4039
4033
|
function create_default_slot(ctx) {
|
|
4040
|
-
var _a;
|
|
4041
4034
|
let icon;
|
|
4042
4035
|
let current;
|
|
4043
4036
|
icon = new Icon_default({
|
|
4044
4037
|
props: {
|
|
4045
|
-
src:
|
|
4038
|
+
src: ctx[1]?.redo[ctx[2]],
|
|
4046
4039
|
alt: "[redo]",
|
|
4047
4040
|
$$slots: { default: [create_default_slot_1] },
|
|
4048
4041
|
$$scope: { ctx }
|
|
@@ -4057,10 +4050,9 @@ function create_default_slot(ctx) {
|
|
|
4057
4050
|
current = true;
|
|
4058
4051
|
},
|
|
4059
4052
|
p(ctx2, dirty) {
|
|
4060
|
-
var _a2;
|
|
4061
4053
|
const icon_changes = {};
|
|
4062
4054
|
if (dirty & 6)
|
|
4063
|
-
icon_changes.src =
|
|
4055
|
+
icon_changes.src = ctx2[1]?.redo[ctx2[2]];
|
|
4064
4056
|
if (dirty & 131073) {
|
|
4065
4057
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
4066
4058
|
}
|
|
@@ -4202,10 +4194,10 @@ function instance46($$self, $$props, $$invalidate) {
|
|
|
4202
4194
|
let { icons = void 0 } = $$props;
|
|
4203
4195
|
let type;
|
|
4204
4196
|
function undo() {
|
|
4205
|
-
app
|
|
4197
|
+
app?.undo();
|
|
4206
4198
|
}
|
|
4207
4199
|
function redo() {
|
|
4208
|
-
app
|
|
4200
|
+
app?.redo();
|
|
4209
4201
|
}
|
|
4210
4202
|
$$self.$$set = ($$props2) => {
|
|
4211
4203
|
if ("app" in $$props2)
|
|
@@ -4219,7 +4211,7 @@ function instance46($$self, $$props, $$invalidate) {
|
|
|
4219
4211
|
};
|
|
4220
4212
|
$$self.$$.update = () => {
|
|
4221
4213
|
if ($$self.$$.dirty & 2048) {
|
|
4222
|
-
$$subscribe_writable($$invalidate(8, writable2 = app
|
|
4214
|
+
$$subscribe_writable($$invalidate(8, writable2 = app?.writable));
|
|
4223
4215
|
}
|
|
4224
4216
|
if ($$self.$$.dirty & 65536) {
|
|
4225
4217
|
$$invalidate(13, disabled = !$writable);
|
|
@@ -4231,10 +4223,10 @@ function instance46($$self, $$props, $$invalidate) {
|
|
|
4231
4223
|
$$invalidate(2, type = disabled ? "disable" : "normal");
|
|
4232
4224
|
}
|
|
4233
4225
|
if ($$self.$$.dirty & 2048) {
|
|
4234
|
-
$$subscribe_undoSteps($$invalidate(6, undoSteps = app
|
|
4226
|
+
$$subscribe_undoSteps($$invalidate(6, undoSteps = app?.canUndoSteps));
|
|
4235
4227
|
}
|
|
4236
4228
|
if ($$self.$$.dirty & 2048) {
|
|
4237
|
-
$$subscribe_redoSteps($$invalidate(5, redoSteps = app
|
|
4229
|
+
$$subscribe_redoSteps($$invalidate(5, redoSteps = app?.canRedoSteps));
|
|
4238
4230
|
}
|
|
4239
4231
|
if ($$self.$$.dirty & 40960) {
|
|
4240
4232
|
$$invalidate(4, undo_disabled = disabled || !$undoSteps);
|
|
@@ -4311,12 +4303,11 @@ function create_default_slot_5(ctx) {
|
|
|
4311
4303
|
};
|
|
4312
4304
|
}
|
|
4313
4305
|
function create_default_slot_4(ctx) {
|
|
4314
|
-
var _a;
|
|
4315
4306
|
let icon;
|
|
4316
4307
|
let current;
|
|
4317
4308
|
icon = new Icon_default({
|
|
4318
4309
|
props: {
|
|
4319
|
-
src:
|
|
4310
|
+
src: ctx[1]?.prev[ctx[5]],
|
|
4320
4311
|
alt: "[prev]",
|
|
4321
4312
|
$$slots: { default: [create_default_slot_5] },
|
|
4322
4313
|
$$scope: { ctx }
|
|
@@ -4331,10 +4322,9 @@ function create_default_slot_4(ctx) {
|
|
|
4331
4322
|
current = true;
|
|
4332
4323
|
},
|
|
4333
4324
|
p(ctx2, dirty) {
|
|
4334
|
-
var _a2;
|
|
4335
4325
|
const icon_changes = {};
|
|
4336
4326
|
if (dirty & 34)
|
|
4337
|
-
icon_changes.src =
|
|
4327
|
+
icon_changes.src = ctx2[1]?.prev[ctx2[5]];
|
|
4338
4328
|
if (dirty & 262145) {
|
|
4339
4329
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
4340
4330
|
}
|
|
@@ -4437,12 +4427,11 @@ function create_default_slot_32(ctx) {
|
|
|
4437
4427
|
};
|
|
4438
4428
|
}
|
|
4439
4429
|
function create_default_slot_22(ctx) {
|
|
4440
|
-
var _a;
|
|
4441
4430
|
let icon;
|
|
4442
4431
|
let current;
|
|
4443
4432
|
icon = new Icon_default({
|
|
4444
4433
|
props: {
|
|
4445
|
-
src:
|
|
4434
|
+
src: ctx[1]?.next[ctx[5]],
|
|
4446
4435
|
alt: "[next]",
|
|
4447
4436
|
$$slots: { default: [create_default_slot_32] },
|
|
4448
4437
|
$$scope: { ctx }
|
|
@@ -4457,10 +4446,9 @@ function create_default_slot_22(ctx) {
|
|
|
4457
4446
|
current = true;
|
|
4458
4447
|
},
|
|
4459
4448
|
p(ctx2, dirty) {
|
|
4460
|
-
var _a2;
|
|
4461
4449
|
const icon_changes = {};
|
|
4462
4450
|
if (dirty & 34)
|
|
4463
|
-
icon_changes.src =
|
|
4451
|
+
icon_changes.src = ctx2[1]?.next[ctx2[5]];
|
|
4464
4452
|
if (dirty & 262145) {
|
|
4465
4453
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
4466
4454
|
}
|
|
@@ -4515,12 +4503,11 @@ function create_default_slot_12(ctx) {
|
|
|
4515
4503
|
};
|
|
4516
4504
|
}
|
|
4517
4505
|
function create_default_slot2(ctx) {
|
|
4518
|
-
var _a;
|
|
4519
4506
|
let icon;
|
|
4520
4507
|
let current;
|
|
4521
4508
|
icon = new Icon_default({
|
|
4522
4509
|
props: {
|
|
4523
|
-
src:
|
|
4510
|
+
src: ctx[1]?.add[ctx[5]],
|
|
4524
4511
|
alt: "[add]",
|
|
4525
4512
|
$$slots: { default: [create_default_slot_12] },
|
|
4526
4513
|
$$scope: { ctx }
|
|
@@ -4535,10 +4522,9 @@ function create_default_slot2(ctx) {
|
|
|
4535
4522
|
current = true;
|
|
4536
4523
|
},
|
|
4537
4524
|
p(ctx2, dirty) {
|
|
4538
|
-
var _a2;
|
|
4539
4525
|
const icon_changes = {};
|
|
4540
4526
|
if (dirty & 34)
|
|
4541
|
-
icon_changes.src =
|
|
4527
|
+
icon_changes.src = ctx2[1]?.add[ctx2[5]];
|
|
4542
4528
|
if (dirty & 262145) {
|
|
4543
4529
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
4544
4530
|
}
|
|
@@ -4748,14 +4734,14 @@ function instance47($$self, $$props, $$invalidate) {
|
|
|
4748
4734
|
let { icons = void 0 } = $$props;
|
|
4749
4735
|
let type;
|
|
4750
4736
|
function prevPage() {
|
|
4751
|
-
app
|
|
4737
|
+
app?.prevPage();
|
|
4752
4738
|
}
|
|
4753
4739
|
function nextPage() {
|
|
4754
|
-
app
|
|
4740
|
+
app?.nextPage();
|
|
4755
4741
|
}
|
|
4756
4742
|
function addPage() {
|
|
4757
|
-
app
|
|
4758
|
-
app
|
|
4743
|
+
app?.addPage({ after: true });
|
|
4744
|
+
app?.nextPage();
|
|
4759
4745
|
}
|
|
4760
4746
|
$$self.$$set = ($$props2) => {
|
|
4761
4747
|
if ("app" in $$props2)
|
|
@@ -4769,7 +4755,7 @@ function instance47($$self, $$props, $$invalidate) {
|
|
|
4769
4755
|
};
|
|
4770
4756
|
$$self.$$.update = () => {
|
|
4771
4757
|
if ($$self.$$.dirty & 32768) {
|
|
4772
|
-
$$subscribe_writable($$invalidate(11, writable2 = app
|
|
4758
|
+
$$subscribe_writable($$invalidate(11, writable2 = app?.writable));
|
|
4773
4759
|
}
|
|
4774
4760
|
if ($$self.$$.dirty & 131072) {
|
|
4775
4761
|
$$invalidate(2, disabled = !$writable);
|
|
@@ -4781,10 +4767,10 @@ function instance47($$self, $$props, $$invalidate) {
|
|
|
4781
4767
|
$$invalidate(5, type = disabled ? "disable" : "normal");
|
|
4782
4768
|
}
|
|
4783
4769
|
if ($$self.$$.dirty & 32768) {
|
|
4784
|
-
$$subscribe_index($$invalidate(9, index = app
|
|
4770
|
+
$$subscribe_index($$invalidate(9, index = app?.pageIndex));
|
|
4785
4771
|
}
|
|
4786
4772
|
if ($$self.$$.dirty & 32768) {
|
|
4787
|
-
$$subscribe_length($$invalidate(8, length = app
|
|
4773
|
+
$$subscribe_length($$invalidate(8, length = app?.pageLength));
|
|
4788
4774
|
}
|
|
4789
4775
|
if ($$self.$$.dirty & 20) {
|
|
4790
4776
|
$$invalidate(7, prev_disabled = disabled || !$index);
|
|
@@ -4867,12 +4853,11 @@ function create_default_slot_52(ctx) {
|
|
|
4867
4853
|
};
|
|
4868
4854
|
}
|
|
4869
4855
|
function create_default_slot_42(ctx) {
|
|
4870
|
-
var _a;
|
|
4871
4856
|
let icon;
|
|
4872
4857
|
let current;
|
|
4873
4858
|
icon = new Icon_default({
|
|
4874
4859
|
props: {
|
|
4875
|
-
src:
|
|
4860
|
+
src: ctx[1]?.plus[ctx[4]],
|
|
4876
4861
|
alt: "[plus]",
|
|
4877
4862
|
$$slots: { default: [create_default_slot_52] },
|
|
4878
4863
|
$$scope: { ctx }
|
|
@@ -4887,10 +4872,9 @@ function create_default_slot_42(ctx) {
|
|
|
4887
4872
|
current = true;
|
|
4888
4873
|
},
|
|
4889
4874
|
p(ctx2, dirty) {
|
|
4890
|
-
var _a2;
|
|
4891
4875
|
const icon_changes = {};
|
|
4892
4876
|
if (dirty & 18)
|
|
4893
|
-
icon_changes.src =
|
|
4877
|
+
icon_changes.src = ctx2[1]?.plus[ctx2[4]];
|
|
4894
4878
|
if (dirty & 262145) {
|
|
4895
4879
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
4896
4880
|
}
|
|
@@ -4985,12 +4969,11 @@ function create_default_slot_33(ctx) {
|
|
|
4985
4969
|
};
|
|
4986
4970
|
}
|
|
4987
4971
|
function create_default_slot_23(ctx) {
|
|
4988
|
-
var _a;
|
|
4989
4972
|
let icon;
|
|
4990
4973
|
let current;
|
|
4991
4974
|
icon = new Icon_default({
|
|
4992
4975
|
props: {
|
|
4993
|
-
src:
|
|
4976
|
+
src: ctx[1]?.minus[ctx[4]],
|
|
4994
4977
|
alt: "[minus]",
|
|
4995
4978
|
$$slots: { default: [create_default_slot_33] },
|
|
4996
4979
|
$$scope: { ctx }
|
|
@@ -5005,10 +4988,9 @@ function create_default_slot_23(ctx) {
|
|
|
5005
4988
|
current = true;
|
|
5006
4989
|
},
|
|
5007
4990
|
p(ctx2, dirty) {
|
|
5008
|
-
var _a2;
|
|
5009
4991
|
const icon_changes = {};
|
|
5010
4992
|
if (dirty & 18)
|
|
5011
|
-
icon_changes.src =
|
|
4993
|
+
icon_changes.src = ctx2[1]?.minus[ctx2[4]];
|
|
5012
4994
|
if (dirty & 262145) {
|
|
5013
4995
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
5014
4996
|
}
|
|
@@ -5063,12 +5045,11 @@ function create_default_slot_13(ctx) {
|
|
|
5063
5045
|
};
|
|
5064
5046
|
}
|
|
5065
5047
|
function create_default_slot3(ctx) {
|
|
5066
|
-
var _a;
|
|
5067
5048
|
let icon;
|
|
5068
5049
|
let current;
|
|
5069
5050
|
icon = new Icon_default({
|
|
5070
5051
|
props: {
|
|
5071
|
-
src:
|
|
5052
|
+
src: ctx[1]?.reset[ctx[4]],
|
|
5072
5053
|
alt: "[reset]",
|
|
5073
5054
|
$$slots: { default: [create_default_slot_13] },
|
|
5074
5055
|
$$scope: { ctx }
|
|
@@ -5083,10 +5064,9 @@ function create_default_slot3(ctx) {
|
|
|
5083
5064
|
current = true;
|
|
5084
5065
|
},
|
|
5085
5066
|
p(ctx2, dirty) {
|
|
5086
|
-
var _a2;
|
|
5087
5067
|
const icon_changes = {};
|
|
5088
5068
|
if (dirty & 18)
|
|
5089
|
-
icon_changes.src =
|
|
5069
|
+
icon_changes.src = ctx2[1]?.reset[ctx2[4]];
|
|
5090
5070
|
if (dirty & 262145) {
|
|
5091
5071
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
5092
5072
|
}
|
|
@@ -5324,21 +5304,21 @@ function instance48($$self, $$props, $$invalidate) {
|
|
|
5324
5304
|
let { icons = void 0 } = $$props;
|
|
5325
5305
|
let type;
|
|
5326
5306
|
function plus() {
|
|
5327
|
-
app
|
|
5307
|
+
app?.moveCamera({
|
|
5328
5308
|
scale: next_scale(scale, 1),
|
|
5329
5309
|
centerX: 0,
|
|
5330
5310
|
centerY: 0
|
|
5331
5311
|
});
|
|
5332
5312
|
}
|
|
5333
5313
|
function minus() {
|
|
5334
|
-
app
|
|
5314
|
+
app?.moveCamera({
|
|
5335
5315
|
scale: next_scale(scale, -1),
|
|
5336
5316
|
centerX: 0,
|
|
5337
5317
|
centerY: 0
|
|
5338
5318
|
});
|
|
5339
5319
|
}
|
|
5340
5320
|
function reset() {
|
|
5341
|
-
app
|
|
5321
|
+
app?.moveCamera({ scale: 1, centerX: 0, centerY: 0 });
|
|
5342
5322
|
}
|
|
5343
5323
|
$$self.$$set = ($$props2) => {
|
|
5344
5324
|
if ("app" in $$props2)
|
|
@@ -5351,9 +5331,8 @@ function instance48($$self, $$props, $$invalidate) {
|
|
|
5351
5331
|
$$invalidate(1, icons = $$props2.icons);
|
|
5352
5332
|
};
|
|
5353
5333
|
$$self.$$.update = () => {
|
|
5354
|
-
var _a;
|
|
5355
5334
|
if ($$self.$$.dirty & 16384) {
|
|
5356
|
-
$$subscribe_writable($$invalidate(10, writable2 = app
|
|
5335
|
+
$$subscribe_writable($$invalidate(10, writable2 = app?.writable));
|
|
5357
5336
|
}
|
|
5358
5337
|
if ($$self.$$.dirty & 131072) {
|
|
5359
5338
|
$$invalidate(2, disabled = !$writable);
|
|
@@ -5365,10 +5344,10 @@ function instance48($$self, $$props, $$invalidate) {
|
|
|
5365
5344
|
$$invalidate(4, type = disabled ? "disable" : "normal");
|
|
5366
5345
|
}
|
|
5367
5346
|
if ($$self.$$.dirty & 16384) {
|
|
5368
|
-
$$subscribe_camera($$invalidate(8, camera = app
|
|
5347
|
+
$$subscribe_camera($$invalidate(8, camera = app?.baseCamera));
|
|
5369
5348
|
}
|
|
5370
5349
|
if ($$self.$$.dirty & 8) {
|
|
5371
|
-
$$invalidate(16, scale =
|
|
5350
|
+
$$invalidate(16, scale = $camera?.scale ?? 1);
|
|
5372
5351
|
}
|
|
5373
5352
|
if ($$self.$$.dirty & 65540) {
|
|
5374
5353
|
$$invalidate(7, plus_disabled = disabled || next_scale(scale, 1) <= scale);
|
|
@@ -5585,8 +5564,8 @@ var scrollTop = function(node, value) {
|
|
|
5585
5564
|
var AppsInToolbar = class {
|
|
5586
5565
|
constructor(_data) {
|
|
5587
5566
|
this._data = _data;
|
|
5588
|
-
this._listeners = [];
|
|
5589
5567
|
}
|
|
5568
|
+
_listeners = [];
|
|
5590
5569
|
get data() {
|
|
5591
5570
|
return this._data;
|
|
5592
5571
|
}
|
|
@@ -5864,7 +5843,7 @@ function instance50($$self, $$props, $$invalidate) {
|
|
|
5864
5843
|
let { theme = "light" } = $$props;
|
|
5865
5844
|
let { disabled = false } = $$props;
|
|
5866
5845
|
function set_stroke_width({ detail: value2 }) {
|
|
5867
|
-
app
|
|
5846
|
+
app?.setStrokeWidth(value2);
|
|
5868
5847
|
}
|
|
5869
5848
|
$$self.$$set = ($$props2) => {
|
|
5870
5849
|
if ("app" in $$props2)
|
|
@@ -5875,12 +5854,11 @@ function instance50($$self, $$props, $$invalidate) {
|
|
|
5875
5854
|
$$invalidate(5, disabled = $$props2.disabled);
|
|
5876
5855
|
};
|
|
5877
5856
|
$$self.$$.update = () => {
|
|
5878
|
-
var _a;
|
|
5879
5857
|
if ($$self.$$.dirty & 8) {
|
|
5880
|
-
$$subscribe_memberState($$invalidate(1, memberState = app
|
|
5858
|
+
$$subscribe_memberState($$invalidate(1, memberState = app?.memberState));
|
|
5881
5859
|
}
|
|
5882
5860
|
if ($$self.$$.dirty & 128) {
|
|
5883
|
-
$$invalidate(6, value =
|
|
5861
|
+
$$invalidate(6, value = $memberState?.strokeWidth ?? 1);
|
|
5884
5862
|
}
|
|
5885
5863
|
if ($$self.$$.dirty & 112) {
|
|
5886
5864
|
$$invalidate(0, props = { value, theme, disabled });
|
|
@@ -6038,10 +6016,10 @@ function instance51($$self, $$props, $$invalidate) {
|
|
|
6038
6016
|
};
|
|
6039
6017
|
$$self.$$.update = () => {
|
|
6040
6018
|
if ($$self.$$.dirty & 32) {
|
|
6041
|
-
$$subscribe_memberState($$invalidate(3, memberState = app
|
|
6019
|
+
$$subscribe_memberState($$invalidate(3, memberState = app?.memberState));
|
|
6042
6020
|
}
|
|
6043
6021
|
if ($$self.$$.dirty & 64) {
|
|
6044
|
-
$$invalidate(2, strokeColor = $memberState
|
|
6022
|
+
$$invalidate(2, strokeColor = $memberState?.strokeColor);
|
|
6045
6023
|
}
|
|
6046
6024
|
};
|
|
6047
6025
|
return [theme, disabled, strokeColor, memberState, set_stroke_color, app, $memberState];
|
|
@@ -6187,10 +6165,10 @@ function instance52($$self, $$props, $$invalidate) {
|
|
|
6187
6165
|
};
|
|
6188
6166
|
$$self.$$.update = () => {
|
|
6189
6167
|
if ($$self.$$.dirty & 32) {
|
|
6190
|
-
$$subscribe_memberState($$invalidate(3, memberState = app
|
|
6168
|
+
$$subscribe_memberState($$invalidate(3, memberState = app?.memberState));
|
|
6191
6169
|
}
|
|
6192
6170
|
if ($$self.$$.dirty & 64) {
|
|
6193
|
-
$$invalidate(2, textColor = $memberState
|
|
6171
|
+
$$invalidate(2, textColor = $memberState?.textColor);
|
|
6194
6172
|
}
|
|
6195
6173
|
};
|
|
6196
6174
|
return [theme, disabled, textColor, memberState, set_stroke_color, app, $memberState];
|
|
@@ -6585,23 +6563,23 @@ function instance53($$self, $$props, $$invalidate) {
|
|
|
6585
6563
|
$$invalidate(6, t = i18n5[language]);
|
|
6586
6564
|
}
|
|
6587
6565
|
if ($$self.$$.dirty & 256) {
|
|
6588
|
-
$$subscribe_memberState($$invalidate(5, memberState = app
|
|
6566
|
+
$$subscribe_memberState($$invalidate(5, memberState = app?.memberState));
|
|
6589
6567
|
}
|
|
6590
6568
|
if ($$self.$$.dirty & 2048) {
|
|
6591
|
-
$$invalidate(4, appliance = $memberState
|
|
6569
|
+
$$invalidate(4, appliance = $memberState?.currentApplianceName);
|
|
6592
6570
|
}
|
|
6593
6571
|
if ($$self.$$.dirty & 2048) {
|
|
6594
|
-
$$invalidate(3, shape = $memberState
|
|
6572
|
+
$$invalidate(3, shape = $memberState?.shapeType);
|
|
6595
6573
|
}
|
|
6596
6574
|
if ($$self.$$.dirty & 256) {
|
|
6597
|
-
$$invalidate(10, hotkeys = app
|
|
6575
|
+
$$invalidate(10, hotkeys = app?.hotKeys);
|
|
6598
6576
|
}
|
|
6599
6577
|
if ($$self.$$.dirty & 1024) {
|
|
6600
6578
|
$$invalidate(2, c = {
|
|
6601
|
-
rectangle: hotkeys
|
|
6602
|
-
ellipse: hotkeys
|
|
6603
|
-
straight: hotkeys
|
|
6604
|
-
arrow: hotkeys
|
|
6579
|
+
rectangle: hotkeys?.changeToRectangle,
|
|
6580
|
+
ellipse: hotkeys?.changeToEllipse,
|
|
6581
|
+
straight: hotkeys?.changeToStraight,
|
|
6582
|
+
arrow: hotkeys?.changeToArrow
|
|
6605
6583
|
});
|
|
6606
6584
|
}
|
|
6607
6585
|
};
|
|
@@ -8530,29 +8508,29 @@ function instance54($$self, $$props, $$invalidate) {
|
|
|
8530
8508
|
set_store_value(top, $top = clamp($top + 32 + 4, 0, max_scroll), $top);
|
|
8531
8509
|
}
|
|
8532
8510
|
function clicker() {
|
|
8533
|
-
app
|
|
8511
|
+
app?.setAppliance("clicker");
|
|
8534
8512
|
}
|
|
8535
8513
|
function selector() {
|
|
8536
|
-
app
|
|
8514
|
+
app?.setAppliance("selector");
|
|
8537
8515
|
}
|
|
8538
8516
|
function pencil() {
|
|
8539
|
-
app
|
|
8517
|
+
app?.setAppliance("pencil");
|
|
8540
8518
|
}
|
|
8541
8519
|
function text2() {
|
|
8542
|
-
app
|
|
8520
|
+
app?.setAppliance("text");
|
|
8543
8521
|
}
|
|
8544
8522
|
function select_last_shape() {
|
|
8545
8523
|
if (applianceShapes.includes(last_shape)) {
|
|
8546
|
-
app
|
|
8524
|
+
app?.setAppliance(last_shape);
|
|
8547
8525
|
} else {
|
|
8548
|
-
app
|
|
8526
|
+
app?.setAppliance("shape", last_shape);
|
|
8549
8527
|
}
|
|
8550
8528
|
}
|
|
8551
8529
|
function eraser() {
|
|
8552
|
-
app
|
|
8530
|
+
app?.setAppliance("eraser");
|
|
8553
8531
|
}
|
|
8554
8532
|
function clear() {
|
|
8555
|
-
app
|
|
8533
|
+
app?.cleanCurrentScene();
|
|
8556
8534
|
}
|
|
8557
8535
|
function div2_binding($$value) {
|
|
8558
8536
|
binding_callbacks[$$value ? "unshift" : "push"](() => {
|
|
@@ -8609,28 +8587,28 @@ function instance54($$self, $$props, $$invalidate) {
|
|
|
8609
8587
|
$$invalidate(9, t = i18n4[language]);
|
|
8610
8588
|
}
|
|
8611
8589
|
if ($$self.$$.dirty[0] & 1) {
|
|
8612
|
-
$$invalidate(32, hotkeys = app
|
|
8590
|
+
$$invalidate(32, hotkeys = app?.hotKeys);
|
|
8613
8591
|
}
|
|
8614
8592
|
if ($$self.$$.dirty[0] & 512 | $$self.$$.dirty[1] & 2) {
|
|
8615
8593
|
$$invalidate(18, c = {
|
|
8616
|
-
clicker: tooltip(t.clicker, hotkeys
|
|
8617
|
-
selector: tooltip(t.selector, hotkeys
|
|
8618
|
-
pencil: tooltip(t.pencil, hotkeys
|
|
8619
|
-
eraser: tooltip(t.eraser, hotkeys
|
|
8620
|
-
text: tooltip(t.text, hotkeys
|
|
8594
|
+
clicker: tooltip(t.clicker, hotkeys?.changeToClick),
|
|
8595
|
+
selector: tooltip(t.selector, hotkeys?.changeToSelector),
|
|
8596
|
+
pencil: tooltip(t.pencil, hotkeys?.changeToPencil),
|
|
8597
|
+
eraser: tooltip(t.eraser, hotkeys?.changeToEraser),
|
|
8598
|
+
text: tooltip(t.text, hotkeys?.changeToText)
|
|
8621
8599
|
});
|
|
8622
8600
|
}
|
|
8623
8601
|
if ($$self.$$.dirty[0] & 1) {
|
|
8624
|
-
$$subscribe_memberState($$invalidate(17, memberState = app
|
|
8602
|
+
$$subscribe_memberState($$invalidate(17, memberState = app?.memberState));
|
|
8625
8603
|
}
|
|
8626
8604
|
if ($$self.$$.dirty[1] & 8) {
|
|
8627
|
-
$$invalidate(8, appliance = $memberState
|
|
8605
|
+
$$invalidate(8, appliance = $memberState?.currentApplianceName);
|
|
8628
8606
|
}
|
|
8629
8607
|
if ($$self.$$.dirty[1] & 8) {
|
|
8630
|
-
$$invalidate(7, shape = $memberState
|
|
8608
|
+
$$invalidate(7, shape = $memberState?.shapeType);
|
|
8631
8609
|
}
|
|
8632
8610
|
if ($$self.$$.dirty[0] & 1) {
|
|
8633
|
-
$$subscribe_status($$invalidate(16, status = app
|
|
8611
|
+
$$subscribe_status($$invalidate(16, status = app?.appsStatus));
|
|
8634
8612
|
}
|
|
8635
8613
|
if ($$self.$$.dirty[0] & 384) {
|
|
8636
8614
|
if (applianceShapes.includes(appliance)) {
|
|
@@ -8688,16 +8666,25 @@ function instance54($$self, $$props, $$invalidate) {
|
|
|
8688
8666
|
var Contents = class extends SvelteComponent {
|
|
8689
8667
|
constructor(options) {
|
|
8690
8668
|
super();
|
|
8691
|
-
init(
|
|
8692
|
-
|
|
8693
|
-
|
|
8694
|
-
|
|
8695
|
-
|
|
8696
|
-
|
|
8697
|
-
|
|
8698
|
-
|
|
8699
|
-
|
|
8700
|
-
|
|
8669
|
+
init(
|
|
8670
|
+
this,
|
|
8671
|
+
options,
|
|
8672
|
+
instance54,
|
|
8673
|
+
create_fragment54,
|
|
8674
|
+
safe_not_equal,
|
|
8675
|
+
{
|
|
8676
|
+
app: 0,
|
|
8677
|
+
theme: 1,
|
|
8678
|
+
language: 2,
|
|
8679
|
+
disabled: 3,
|
|
8680
|
+
scroll_height: 4,
|
|
8681
|
+
computed_height: 31,
|
|
8682
|
+
scrollable: 5,
|
|
8683
|
+
hide_apps: 6
|
|
8684
|
+
},
|
|
8685
|
+
null,
|
|
8686
|
+
[-1, -1]
|
|
8687
|
+
);
|
|
8701
8688
|
}
|
|
8702
8689
|
};
|
|
8703
8690
|
var Contents_default = Contents;
|
|
@@ -8809,7 +8796,12 @@ function create_fragment55(ctx) {
|
|
|
8809
8796
|
path1 = svg_element("path");
|
|
8810
8797
|
if_block.c();
|
|
8811
8798
|
attr(div0, "class", div0_class_value = name6 + "-contents " + ctx[1]);
|
|
8812
|
-
set_style(
|
|
8799
|
+
set_style(
|
|
8800
|
+
div0,
|
|
8801
|
+
"height",
|
|
8802
|
+
ctx[5] ? ctx[6] + "px" : "auto",
|
|
8803
|
+
false
|
|
8804
|
+
);
|
|
8813
8805
|
attr(input, "type", "checkbox");
|
|
8814
8806
|
attr(path0, "fill", "#fff");
|
|
8815
8807
|
attr(path0, "stroke", "none");
|
|
@@ -8868,7 +8860,12 @@ function create_fragment55(ctx) {
|
|
|
8868
8860
|
attr(div0, "class", div0_class_value);
|
|
8869
8861
|
}
|
|
8870
8862
|
if (dirty & 96) {
|
|
8871
|
-
set_style(
|
|
8863
|
+
set_style(
|
|
8864
|
+
div0,
|
|
8865
|
+
"height",
|
|
8866
|
+
ctx2[5] ? ctx2[6] + "px" : "auto",
|
|
8867
|
+
false
|
|
8868
|
+
);
|
|
8872
8869
|
}
|
|
8873
8870
|
if (dirty & 8) {
|
|
8874
8871
|
input.checked = ctx2[3];
|
|
@@ -8949,9 +8946,8 @@ function instance55($$self, $$props, $$invalidate) {
|
|
|
8949
8946
|
$$invalidate(11, config = $$props2.config);
|
|
8950
8947
|
};
|
|
8951
8948
|
$$self.$$.update = () => {
|
|
8952
|
-
var _a;
|
|
8953
8949
|
if ($$self.$$.dirty & 1) {
|
|
8954
|
-
$$subscribe_writable($$invalidate(8, writable2 = app
|
|
8950
|
+
$$subscribe_writable($$invalidate(8, writable2 = app?.writable));
|
|
8955
8951
|
}
|
|
8956
8952
|
if ($$self.$$.dirty & 16384) {
|
|
8957
8953
|
$$invalidate(7, disabled = !$writable);
|
|
@@ -8963,7 +8959,7 @@ function instance55($$self, $$props, $$invalidate) {
|
|
|
8963
8959
|
$$invalidate(5, scrollable = $scroll_height + extra_height > $container_height);
|
|
8964
8960
|
}
|
|
8965
8961
|
if ($$self.$$.dirty & 2048) {
|
|
8966
|
-
$$invalidate(4, hide_apps =
|
|
8962
|
+
$$invalidate(4, hide_apps = config.apps?.enable === false);
|
|
8967
8963
|
}
|
|
8968
8964
|
};
|
|
8969
8965
|
return [
|
|
@@ -9005,12 +9001,11 @@ function get_each_context5(ctx, list, i) {
|
|
|
9005
9001
|
return child_ctx;
|
|
9006
9002
|
}
|
|
9007
9003
|
function create_else_block_13(ctx) {
|
|
9008
|
-
var _a;
|
|
9009
9004
|
let icon;
|
|
9010
9005
|
let current;
|
|
9011
9006
|
icon = new Icon_default({
|
|
9012
9007
|
props: {
|
|
9013
|
-
src:
|
|
9008
|
+
src: ctx[1]?.play[ctx[5]],
|
|
9014
9009
|
alt: "[play]",
|
|
9015
9010
|
$$slots: { default: [create_default_slot_54] },
|
|
9016
9011
|
$$scope: { ctx }
|
|
@@ -9025,10 +9020,9 @@ function create_else_block_13(ctx) {
|
|
|
9025
9020
|
current = true;
|
|
9026
9021
|
},
|
|
9027
9022
|
p(ctx2, dirty) {
|
|
9028
|
-
var _a2;
|
|
9029
9023
|
const icon_changes = {};
|
|
9030
9024
|
if (dirty & 34)
|
|
9031
|
-
icon_changes.src =
|
|
9025
|
+
icon_changes.src = ctx2[1]?.play[ctx2[5]];
|
|
9032
9026
|
if (dirty & 268435457) {
|
|
9033
9027
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
9034
9028
|
}
|
|
@@ -9050,12 +9044,11 @@ function create_else_block_13(ctx) {
|
|
|
9050
9044
|
};
|
|
9051
9045
|
}
|
|
9052
9046
|
function create_if_block_22(ctx) {
|
|
9053
|
-
var _a;
|
|
9054
9047
|
let icon;
|
|
9055
9048
|
let current;
|
|
9056
9049
|
icon = new Icon_default({
|
|
9057
9050
|
props: {
|
|
9058
|
-
src:
|
|
9051
|
+
src: ctx[1]?.pause[ctx[5]],
|
|
9059
9052
|
alt: "[pause]",
|
|
9060
9053
|
$$slots: { default: [create_default_slot_44] },
|
|
9061
9054
|
$$scope: { ctx }
|
|
@@ -9070,10 +9063,9 @@ function create_if_block_22(ctx) {
|
|
|
9070
9063
|
current = true;
|
|
9071
9064
|
},
|
|
9072
9065
|
p(ctx2, dirty) {
|
|
9073
|
-
var _a2;
|
|
9074
9066
|
const icon_changes = {};
|
|
9075
9067
|
if (dirty & 34)
|
|
9076
|
-
icon_changes.src =
|
|
9068
|
+
icon_changes.src = ctx2[1]?.pause[ctx2[5]];
|
|
9077
9069
|
if (dirty & 268435457) {
|
|
9078
9070
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
9079
9071
|
}
|
|
@@ -9095,12 +9087,11 @@ function create_if_block_22(ctx) {
|
|
|
9095
9087
|
};
|
|
9096
9088
|
}
|
|
9097
9089
|
function create_if_block_13(ctx) {
|
|
9098
|
-
var _a;
|
|
9099
9090
|
let icon;
|
|
9100
9091
|
let current;
|
|
9101
9092
|
icon = new Icon_default({
|
|
9102
9093
|
props: {
|
|
9103
|
-
src:
|
|
9094
|
+
src: ctx[1]?.loading[ctx[5]],
|
|
9104
9095
|
alt: "[loading]",
|
|
9105
9096
|
$$slots: { default: [create_default_slot_35] },
|
|
9106
9097
|
$$scope: { ctx }
|
|
@@ -9115,10 +9106,9 @@ function create_if_block_13(ctx) {
|
|
|
9115
9106
|
current = true;
|
|
9116
9107
|
},
|
|
9117
9108
|
p(ctx2, dirty) {
|
|
9118
|
-
var _a2;
|
|
9119
9109
|
const icon_changes = {};
|
|
9120
9110
|
if (dirty & 34)
|
|
9121
|
-
icon_changes.src =
|
|
9111
|
+
icon_changes.src = ctx2[1]?.loading[ctx2[5]];
|
|
9122
9112
|
if (dirty & 268435457) {
|
|
9123
9113
|
icon_changes.$$scope = { dirty, ctx: ctx2 };
|
|
9124
9114
|
}
|
|
@@ -9827,7 +9817,7 @@ function instance56($$self, $$props, $$invalidate) {
|
|
|
9827
9817
|
$$invalidate(12, t = i18n6[language]);
|
|
9828
9818
|
}
|
|
9829
9819
|
if ($$self.$$.dirty & 524288) {
|
|
9830
|
-
$$invalidate(21, canPlay = player
|
|
9820
|
+
$$invalidate(21, canPlay = player?.canplay);
|
|
9831
9821
|
}
|
|
9832
9822
|
if ($$self.$$.dirty & 2097152) {
|
|
9833
9823
|
$$invalidate(4, disabled = !canPlay);
|
|
@@ -9836,16 +9826,16 @@ function instance56($$self, $$props, $$invalidate) {
|
|
|
9836
9826
|
$$invalidate(5, type = disabled ? "disable" : "normal");
|
|
9837
9827
|
}
|
|
9838
9828
|
if ($$self.$$.dirty & 524288) {
|
|
9839
|
-
$$subscribe_duration($$invalidate(11, duration = player
|
|
9829
|
+
$$subscribe_duration($$invalidate(11, duration = player?.duration));
|
|
9840
9830
|
}
|
|
9841
9831
|
if ($$self.$$.dirty & 524288) {
|
|
9842
|
-
$$subscribe_current($$invalidate(10, current = player
|
|
9832
|
+
$$subscribe_current($$invalidate(10, current = player?.currentTime));
|
|
9843
9833
|
}
|
|
9844
9834
|
if ($$self.$$.dirty & 524288) {
|
|
9845
|
-
$$subscribe_playbackRate($$invalidate(9, playbackRate = player
|
|
9835
|
+
$$subscribe_playbackRate($$invalidate(9, playbackRate = player?.playbackRate));
|
|
9846
9836
|
}
|
|
9847
9837
|
if ($$self.$$.dirty & 524288) {
|
|
9848
|
-
$$subscribe_phase($$invalidate(8, phase = player
|
|
9838
|
+
$$subscribe_phase($$invalidate(8, phase = player?.phase));
|
|
9849
9839
|
}
|
|
9850
9840
|
if ($$self.$$.dirty & 4194304) {
|
|
9851
9841
|
$$invalidate(3, loading = $phase === "waitingFirstFrame" || $phase === "buffering");
|
|
@@ -9899,29 +9889,69 @@ var PlayerControl = class extends SvelteComponent {
|
|
|
9899
9889
|
var PlayerControl_default = PlayerControl;
|
|
9900
9890
|
|
|
9901
9891
|
// src/components/Fastboard/ReplayFastboard.svelte
|
|
9902
|
-
function
|
|
9903
|
-
let div2;
|
|
9904
|
-
let div0;
|
|
9905
|
-
let t;
|
|
9906
|
-
let div1;
|
|
9892
|
+
function create_if_block9(ctx) {
|
|
9907
9893
|
let playercontrol;
|
|
9908
9894
|
let current;
|
|
9909
|
-
let mounted;
|
|
9910
|
-
let dispose;
|
|
9911
9895
|
playercontrol = new PlayerControl_default({
|
|
9912
9896
|
props: {
|
|
9913
9897
|
player: ctx[0],
|
|
9914
9898
|
theme: ctx[1],
|
|
9915
|
-
language: ctx[2]
|
|
9899
|
+
language: ctx[2],
|
|
9900
|
+
icons: ctx[3].player_control?.icons
|
|
9916
9901
|
}
|
|
9917
9902
|
});
|
|
9903
|
+
return {
|
|
9904
|
+
c() {
|
|
9905
|
+
create_component(playercontrol.$$.fragment);
|
|
9906
|
+
},
|
|
9907
|
+
m(target, anchor) {
|
|
9908
|
+
mount_component(playercontrol, target, anchor);
|
|
9909
|
+
current = true;
|
|
9910
|
+
},
|
|
9911
|
+
p(ctx2, dirty) {
|
|
9912
|
+
const playercontrol_changes = {};
|
|
9913
|
+
if (dirty & 1)
|
|
9914
|
+
playercontrol_changes.player = ctx2[0];
|
|
9915
|
+
if (dirty & 2)
|
|
9916
|
+
playercontrol_changes.theme = ctx2[1];
|
|
9917
|
+
if (dirty & 4)
|
|
9918
|
+
playercontrol_changes.language = ctx2[2];
|
|
9919
|
+
if (dirty & 8)
|
|
9920
|
+
playercontrol_changes.icons = ctx2[3].player_control?.icons;
|
|
9921
|
+
playercontrol.$set(playercontrol_changes);
|
|
9922
|
+
},
|
|
9923
|
+
i(local) {
|
|
9924
|
+
if (current)
|
|
9925
|
+
return;
|
|
9926
|
+
transition_in(playercontrol.$$.fragment, local);
|
|
9927
|
+
current = true;
|
|
9928
|
+
},
|
|
9929
|
+
o(local) {
|
|
9930
|
+
transition_out(playercontrol.$$.fragment, local);
|
|
9931
|
+
current = false;
|
|
9932
|
+
},
|
|
9933
|
+
d(detaching) {
|
|
9934
|
+
destroy_component(playercontrol, detaching);
|
|
9935
|
+
}
|
|
9936
|
+
};
|
|
9937
|
+
}
|
|
9938
|
+
function create_fragment57(ctx) {
|
|
9939
|
+
let div2;
|
|
9940
|
+
let div0;
|
|
9941
|
+
let t;
|
|
9942
|
+
let div1;
|
|
9943
|
+
let current;
|
|
9944
|
+
let mounted;
|
|
9945
|
+
let dispose;
|
|
9946
|
+
let if_block = ctx[3].player_control?.enable !== false && create_if_block9(ctx);
|
|
9918
9947
|
return {
|
|
9919
9948
|
c() {
|
|
9920
9949
|
div2 = element("div");
|
|
9921
9950
|
div0 = element("div");
|
|
9922
9951
|
t = space();
|
|
9923
9952
|
div1 = element("div");
|
|
9924
|
-
|
|
9953
|
+
if (if_block)
|
|
9954
|
+
if_block.c();
|
|
9925
9955
|
attr(div0, "class", name8 + "-view");
|
|
9926
9956
|
attr(div1, "class", name8 + "-bottom");
|
|
9927
9957
|
attr(div2, "class", name8 + "-root");
|
|
@@ -9930,25 +9960,37 @@ function create_fragment57(ctx) {
|
|
|
9930
9960
|
m(target, anchor) {
|
|
9931
9961
|
insert(target, div2, anchor);
|
|
9932
9962
|
append(div2, div0);
|
|
9933
|
-
ctx[
|
|
9963
|
+
ctx[8](div0);
|
|
9934
9964
|
append(div2, t);
|
|
9935
9965
|
append(div2, div1);
|
|
9936
|
-
|
|
9966
|
+
if (if_block)
|
|
9967
|
+
if_block.m(div1, null);
|
|
9937
9968
|
current = true;
|
|
9938
9969
|
if (!mounted) {
|
|
9939
|
-
dispose = listen(div0, "touchstart", ctx[
|
|
9970
|
+
dispose = listen(div0, "touchstart", ctx[5], { passive: true, capture: true });
|
|
9940
9971
|
mounted = true;
|
|
9941
9972
|
}
|
|
9942
9973
|
},
|
|
9943
9974
|
p(ctx2, [dirty]) {
|
|
9944
|
-
|
|
9945
|
-
|
|
9946
|
-
|
|
9947
|
-
|
|
9948
|
-
|
|
9949
|
-
|
|
9950
|
-
|
|
9951
|
-
|
|
9975
|
+
if (ctx2[3].player_control?.enable !== false) {
|
|
9976
|
+
if (if_block) {
|
|
9977
|
+
if_block.p(ctx2, dirty);
|
|
9978
|
+
if (dirty & 8) {
|
|
9979
|
+
transition_in(if_block, 1);
|
|
9980
|
+
}
|
|
9981
|
+
} else {
|
|
9982
|
+
if_block = create_if_block9(ctx2);
|
|
9983
|
+
if_block.c();
|
|
9984
|
+
transition_in(if_block, 1);
|
|
9985
|
+
if_block.m(div1, null);
|
|
9986
|
+
}
|
|
9987
|
+
} else if (if_block) {
|
|
9988
|
+
group_outros();
|
|
9989
|
+
transition_out(if_block, 1, 1, () => {
|
|
9990
|
+
if_block = null;
|
|
9991
|
+
});
|
|
9992
|
+
check_outros();
|
|
9993
|
+
}
|
|
9952
9994
|
if (dirty & 1) {
|
|
9953
9995
|
toggle_class(div2, "loading", !ctx2[0]);
|
|
9954
9996
|
}
|
|
@@ -9956,18 +9998,19 @@ function create_fragment57(ctx) {
|
|
|
9956
9998
|
i(local) {
|
|
9957
9999
|
if (current)
|
|
9958
10000
|
return;
|
|
9959
|
-
transition_in(
|
|
10001
|
+
transition_in(if_block);
|
|
9960
10002
|
current = true;
|
|
9961
10003
|
},
|
|
9962
10004
|
o(local) {
|
|
9963
|
-
transition_out(
|
|
10005
|
+
transition_out(if_block);
|
|
9964
10006
|
current = false;
|
|
9965
10007
|
},
|
|
9966
10008
|
d(detaching) {
|
|
9967
10009
|
if (detaching)
|
|
9968
10010
|
detach(div2);
|
|
9969
|
-
ctx[
|
|
9970
|
-
|
|
10011
|
+
ctx[8](null);
|
|
10012
|
+
if (if_block)
|
|
10013
|
+
if_block.d();
|
|
9971
10014
|
mounted = false;
|
|
9972
10015
|
dispose();
|
|
9973
10016
|
}
|
|
@@ -9978,6 +10021,7 @@ function instance57($$self, $$props, $$invalidate) {
|
|
|
9978
10021
|
let { player = null } = $$props;
|
|
9979
10022
|
let { theme = "light" } = $$props;
|
|
9980
10023
|
let { language = "en" } = $$props;
|
|
10024
|
+
let { config = {} } = $$props;
|
|
9981
10025
|
let { containerRef = void 0 } = $$props;
|
|
9982
10026
|
let container;
|
|
9983
10027
|
let mounted = false;
|
|
@@ -9998,7 +10042,7 @@ function instance57($$self, $$props, $$invalidate) {
|
|
|
9998
10042
|
function div0_binding($$value) {
|
|
9999
10043
|
binding_callbacks[$$value ? "unshift" : "push"](() => {
|
|
10000
10044
|
container = $$value;
|
|
10001
|
-
$$invalidate(
|
|
10045
|
+
$$invalidate(4, container);
|
|
10002
10046
|
});
|
|
10003
10047
|
}
|
|
10004
10048
|
$$self.$$set = ($$props2) => {
|
|
@@ -10008,22 +10052,24 @@ function instance57($$self, $$props, $$invalidate) {
|
|
|
10008
10052
|
$$invalidate(1, theme = $$props2.theme);
|
|
10009
10053
|
if ("language" in $$props2)
|
|
10010
10054
|
$$invalidate(2, language = $$props2.language);
|
|
10055
|
+
if ("config" in $$props2)
|
|
10056
|
+
$$invalidate(3, config = $$props2.config);
|
|
10011
10057
|
if ("containerRef" in $$props2)
|
|
10012
|
-
$$invalidate(
|
|
10058
|
+
$$invalidate(6, containerRef = $$props2.containerRef);
|
|
10013
10059
|
};
|
|
10014
10060
|
$$self.$$.update = () => {
|
|
10015
|
-
if ($$self.$$.dirty &
|
|
10061
|
+
if ($$self.$$.dirty & 17) {
|
|
10016
10062
|
try {
|
|
10017
10063
|
if (player && container) {
|
|
10018
10064
|
player.bindContainer(container);
|
|
10019
|
-
$$invalidate(
|
|
10065
|
+
$$invalidate(7, mounted = true);
|
|
10020
10066
|
}
|
|
10021
10067
|
} catch (err) {
|
|
10022
10068
|
console.error("[fastboard] An error occurred while binding container");
|
|
10023
10069
|
console.error(err);
|
|
10024
10070
|
}
|
|
10025
10071
|
}
|
|
10026
|
-
if ($$self.$$.dirty &
|
|
10072
|
+
if ($$self.$$.dirty & 131) {
|
|
10027
10073
|
if (player && theme && mounted) {
|
|
10028
10074
|
player.manager.setPrefersColorScheme(theme);
|
|
10029
10075
|
}
|
|
@@ -10033,6 +10079,7 @@ function instance57($$self, $$props, $$invalidate) {
|
|
|
10033
10079
|
player,
|
|
10034
10080
|
theme,
|
|
10035
10081
|
language,
|
|
10082
|
+
config,
|
|
10036
10083
|
container,
|
|
10037
10084
|
focus_me,
|
|
10038
10085
|
containerRef,
|
|
@@ -10047,7 +10094,8 @@ var ReplayFastboard = class extends SvelteComponent {
|
|
|
10047
10094
|
player: 0,
|
|
10048
10095
|
theme: 1,
|
|
10049
10096
|
language: 2,
|
|
10050
|
-
|
|
10097
|
+
config: 3,
|
|
10098
|
+
containerRef: 6
|
|
10051
10099
|
});
|
|
10052
10100
|
}
|
|
10053
10101
|
};
|
|
@@ -10107,7 +10155,8 @@ function create_if_block_23(ctx) {
|
|
|
10107
10155
|
props: {
|
|
10108
10156
|
app: ctx[0],
|
|
10109
10157
|
theme: ctx[1],
|
|
10110
|
-
language: ctx[2]
|
|
10158
|
+
language: ctx[2],
|
|
10159
|
+
icons: ctx[3].redo_undo?.icons
|
|
10111
10160
|
}
|
|
10112
10161
|
});
|
|
10113
10162
|
return {
|
|
@@ -10126,6 +10175,8 @@ function create_if_block_23(ctx) {
|
|
|
10126
10175
|
redoundo_changes.theme = ctx2[1];
|
|
10127
10176
|
if (dirty & 4)
|
|
10128
10177
|
redoundo_changes.language = ctx2[2];
|
|
10178
|
+
if (dirty & 8)
|
|
10179
|
+
redoundo_changes.icons = ctx2[3].redo_undo?.icons;
|
|
10129
10180
|
redoundo.$set(redoundo_changes);
|
|
10130
10181
|
},
|
|
10131
10182
|
i(local) {
|
|
@@ -10150,7 +10201,8 @@ function create_if_block_14(ctx) {
|
|
|
10150
10201
|
props: {
|
|
10151
10202
|
app: ctx[0],
|
|
10152
10203
|
theme: ctx[1],
|
|
10153
|
-
language: ctx[2]
|
|
10204
|
+
language: ctx[2],
|
|
10205
|
+
icons: ctx[3].zoom_control?.icons
|
|
10154
10206
|
}
|
|
10155
10207
|
});
|
|
10156
10208
|
return {
|
|
@@ -10169,6 +10221,8 @@ function create_if_block_14(ctx) {
|
|
|
10169
10221
|
zoomcontrol_changes.theme = ctx2[1];
|
|
10170
10222
|
if (dirty & 4)
|
|
10171
10223
|
zoomcontrol_changes.language = ctx2[2];
|
|
10224
|
+
if (dirty & 8)
|
|
10225
|
+
zoomcontrol_changes.icons = ctx2[3].zoom_control?.icons;
|
|
10172
10226
|
zoomcontrol.$set(zoomcontrol_changes);
|
|
10173
10227
|
},
|
|
10174
10228
|
i(local) {
|
|
@@ -10186,14 +10240,15 @@ function create_if_block_14(ctx) {
|
|
|
10186
10240
|
}
|
|
10187
10241
|
};
|
|
10188
10242
|
}
|
|
10189
|
-
function
|
|
10243
|
+
function create_if_block10(ctx) {
|
|
10190
10244
|
let pagecontrol;
|
|
10191
10245
|
let current;
|
|
10192
10246
|
pagecontrol = new PageControl_default({
|
|
10193
10247
|
props: {
|
|
10194
10248
|
app: ctx[0],
|
|
10195
10249
|
theme: ctx[1],
|
|
10196
|
-
language: ctx[2]
|
|
10250
|
+
language: ctx[2],
|
|
10251
|
+
icons: ctx[3].page_control?.icons
|
|
10197
10252
|
}
|
|
10198
10253
|
});
|
|
10199
10254
|
return {
|
|
@@ -10212,6 +10267,8 @@ function create_if_block9(ctx) {
|
|
|
10212
10267
|
pagecontrol_changes.theme = ctx2[1];
|
|
10213
10268
|
if (dirty & 4)
|
|
10214
10269
|
pagecontrol_changes.language = ctx2[2];
|
|
10270
|
+
if (dirty & 8)
|
|
10271
|
+
pagecontrol_changes.icons = ctx2[3].page_control?.icons;
|
|
10215
10272
|
pagecontrol.$set(pagecontrol_changes);
|
|
10216
10273
|
},
|
|
10217
10274
|
i(local) {
|
|
@@ -10230,7 +10287,6 @@ function create_if_block9(ctx) {
|
|
|
10230
10287
|
};
|
|
10231
10288
|
}
|
|
10232
10289
|
function create_fragment58(ctx) {
|
|
10233
|
-
var _a, _b, _c, _d;
|
|
10234
10290
|
let div4;
|
|
10235
10291
|
let div0;
|
|
10236
10292
|
let t0;
|
|
@@ -10243,10 +10299,10 @@ function create_fragment58(ctx) {
|
|
|
10243
10299
|
let current;
|
|
10244
10300
|
let mounted;
|
|
10245
10301
|
let dispose;
|
|
10246
|
-
let if_block0 =
|
|
10247
|
-
let if_block1 =
|
|
10248
|
-
let if_block2 =
|
|
10249
|
-
let if_block3 =
|
|
10302
|
+
let if_block0 = ctx[3].toolbar?.enable !== false && create_if_block_32(ctx);
|
|
10303
|
+
let if_block1 = ctx[3].redo_undo?.enable !== false && create_if_block_23(ctx);
|
|
10304
|
+
let if_block2 = ctx[3].zoom_control?.enable !== false && create_if_block_14(ctx);
|
|
10305
|
+
let if_block3 = ctx[3].page_control?.enable !== false && create_if_block10(ctx);
|
|
10250
10306
|
return {
|
|
10251
10307
|
c() {
|
|
10252
10308
|
div4 = element("div");
|
|
@@ -10302,8 +10358,7 @@ function create_fragment58(ctx) {
|
|
|
10302
10358
|
}
|
|
10303
10359
|
},
|
|
10304
10360
|
p(ctx2, [dirty]) {
|
|
10305
|
-
|
|
10306
|
-
if (((_a2 = ctx2[3].toolbar) == null ? void 0 : _a2.enable) !== false) {
|
|
10361
|
+
if (ctx2[3].toolbar?.enable !== false) {
|
|
10307
10362
|
if (if_block0) {
|
|
10308
10363
|
if_block0.p(ctx2, dirty);
|
|
10309
10364
|
if (dirty & 8) {
|
|
@@ -10325,7 +10380,7 @@ function create_fragment58(ctx) {
|
|
|
10325
10380
|
if (dirty & 32) {
|
|
10326
10381
|
toggle_class(div1, "hidden", !(ctx2[5] === "visible" || ctx2[5] === "toolbar-only"));
|
|
10327
10382
|
}
|
|
10328
|
-
if (
|
|
10383
|
+
if (ctx2[3].redo_undo?.enable !== false) {
|
|
10329
10384
|
if (if_block1) {
|
|
10330
10385
|
if_block1.p(ctx2, dirty);
|
|
10331
10386
|
if (dirty & 8) {
|
|
@@ -10344,7 +10399,7 @@ function create_fragment58(ctx) {
|
|
|
10344
10399
|
});
|
|
10345
10400
|
check_outros();
|
|
10346
10401
|
}
|
|
10347
|
-
if (
|
|
10402
|
+
if (ctx2[3].zoom_control?.enable !== false) {
|
|
10348
10403
|
if (if_block2) {
|
|
10349
10404
|
if_block2.p(ctx2, dirty);
|
|
10350
10405
|
if (dirty & 8) {
|
|
@@ -10366,14 +10421,14 @@ function create_fragment58(ctx) {
|
|
|
10366
10421
|
if (dirty & 32) {
|
|
10367
10422
|
toggle_class(div2, "hidden", ctx2[5] !== "visible");
|
|
10368
10423
|
}
|
|
10369
|
-
if (
|
|
10424
|
+
if (ctx2[3].page_control?.enable !== false) {
|
|
10370
10425
|
if (if_block3) {
|
|
10371
10426
|
if_block3.p(ctx2, dirty);
|
|
10372
10427
|
if (dirty & 8) {
|
|
10373
10428
|
transition_in(if_block3, 1);
|
|
10374
10429
|
}
|
|
10375
10430
|
} else {
|
|
10376
|
-
if_block3 =
|
|
10431
|
+
if_block3 = create_if_block10(ctx2);
|
|
10377
10432
|
if_block3.c();
|
|
10378
10433
|
transition_in(if_block3, 1);
|
|
10379
10434
|
if_block3.m(div3, null);
|
|
@@ -10479,13 +10534,13 @@ function instance58($$self, $$props, $$invalidate) {
|
|
|
10479
10534
|
};
|
|
10480
10535
|
$$self.$$.update = () => {
|
|
10481
10536
|
if ($$self.$$.dirty & 1) {
|
|
10482
|
-
$$subscribe_writable($$invalidate(8, writable2 = app
|
|
10537
|
+
$$subscribe_writable($$invalidate(8, writable2 = app?.writable));
|
|
10483
10538
|
}
|
|
10484
10539
|
if ($$self.$$.dirty & 1) {
|
|
10485
|
-
$$subscribe_boxState($$invalidate(7, boxState = app
|
|
10540
|
+
$$subscribe_boxState($$invalidate(7, boxState = app?.boxState));
|
|
10486
10541
|
}
|
|
10487
10542
|
if ($$self.$$.dirty & 1) {
|
|
10488
|
-
$$subscribe_focusedApp($$invalidate(6, focusedApp = app
|
|
10543
|
+
$$subscribe_focusedApp($$invalidate(6, focusedApp = app?.focusedApp));
|
|
10489
10544
|
}
|
|
10490
10545
|
if ($$self.$$.dirty & 28672) {
|
|
10491
10546
|
if (!$writable) {
|
|
@@ -10553,72 +10608,79 @@ var Fastboard_default = Fastboard;
|
|
|
10553
10608
|
// src/helpers/index.ts
|
|
10554
10609
|
function createUI(app, div) {
|
|
10555
10610
|
let fastboard;
|
|
10556
|
-
|
|
10557
|
-
|
|
10558
|
-
|
|
10559
|
-
fastboard.$destroy();
|
|
10560
|
-
}
|
|
10561
|
-
fastboard = new Fastboard_default({ target: div2, props: __spreadValues({ app }, props) });
|
|
10562
|
-
return ui;
|
|
10563
|
-
},
|
|
10564
|
-
update(props) {
|
|
10565
|
-
if (fastboard) {
|
|
10566
|
-
fastboard.$set(props);
|
|
10567
|
-
}
|
|
10568
|
-
},
|
|
10569
|
-
destroy() {
|
|
10570
|
-
if (fastboard) {
|
|
10571
|
-
fastboard.$destroy();
|
|
10572
|
-
}
|
|
10573
|
-
fastboard = void 0;
|
|
10611
|
+
function mount(div2, props) {
|
|
10612
|
+
if (fastboard) {
|
|
10613
|
+
fastboard.$destroy();
|
|
10574
10614
|
}
|
|
10575
|
-
|
|
10615
|
+
fastboard = new Fastboard_default({ target: div2, props: { app, ...props } });
|
|
10616
|
+
return ui;
|
|
10617
|
+
}
|
|
10618
|
+
function update2(props) {
|
|
10619
|
+
if (fastboard) {
|
|
10620
|
+
fastboard.$set(props);
|
|
10621
|
+
}
|
|
10622
|
+
}
|
|
10623
|
+
function destroy() {
|
|
10624
|
+
if (fastboard) {
|
|
10625
|
+
fastboard.$destroy();
|
|
10626
|
+
}
|
|
10627
|
+
fastboard = void 0;
|
|
10628
|
+
}
|
|
10629
|
+
function setElement(div2) {
|
|
10630
|
+
if (div2) {
|
|
10631
|
+
mount(div2);
|
|
10632
|
+
} else {
|
|
10633
|
+
destroy();
|
|
10634
|
+
}
|
|
10635
|
+
}
|
|
10636
|
+
const ui = { mount, update: update2, destroy, setElement };
|
|
10576
10637
|
if (div) {
|
|
10577
|
-
|
|
10638
|
+
mount(div, { app });
|
|
10578
10639
|
}
|
|
10579
10640
|
return ui;
|
|
10580
10641
|
}
|
|
10581
10642
|
function createReplayUI(player, div) {
|
|
10582
10643
|
let fastboard;
|
|
10583
|
-
|
|
10584
|
-
|
|
10585
|
-
|
|
10586
|
-
fastboard.$destroy();
|
|
10587
|
-
}
|
|
10588
|
-
fastboard = new ReplayFastboard_default({ target: div2, props: __spreadValues({ player }, props) });
|
|
10589
|
-
return ui;
|
|
10590
|
-
},
|
|
10591
|
-
update(props) {
|
|
10592
|
-
if (fastboard) {
|
|
10593
|
-
fastboard.$set(props);
|
|
10594
|
-
}
|
|
10595
|
-
},
|
|
10596
|
-
destroy() {
|
|
10597
|
-
if (fastboard) {
|
|
10598
|
-
fastboard.$destroy();
|
|
10599
|
-
}
|
|
10600
|
-
fastboard = void 0;
|
|
10644
|
+
function mount(div2, props) {
|
|
10645
|
+
if (fastboard) {
|
|
10646
|
+
fastboard.$destroy();
|
|
10601
10647
|
}
|
|
10602
|
-
|
|
10648
|
+
fastboard = new ReplayFastboard_default({ target: div2, props: { player, ...props } });
|
|
10649
|
+
return ui;
|
|
10650
|
+
}
|
|
10651
|
+
function update2(props) {
|
|
10652
|
+
if (fastboard) {
|
|
10653
|
+
fastboard.$set(props);
|
|
10654
|
+
}
|
|
10655
|
+
}
|
|
10656
|
+
function destroy() {
|
|
10657
|
+
if (fastboard) {
|
|
10658
|
+
fastboard.$destroy();
|
|
10659
|
+
}
|
|
10660
|
+
fastboard = void 0;
|
|
10661
|
+
}
|
|
10662
|
+
function setElement(div2) {
|
|
10663
|
+
if (div2) {
|
|
10664
|
+
mount(div2);
|
|
10665
|
+
} else {
|
|
10666
|
+
destroy();
|
|
10667
|
+
}
|
|
10668
|
+
}
|
|
10669
|
+
const ui = { mount, update: update2, destroy, setElement };
|
|
10603
10670
|
if (div) {
|
|
10604
|
-
|
|
10671
|
+
mount(div, { player });
|
|
10605
10672
|
}
|
|
10606
10673
|
return ui;
|
|
10607
10674
|
}
|
|
10608
10675
|
|
|
10609
|
-
|
|
10610
|
-
|
|
10611
|
-
|
|
10612
|
-
|
|
10613
|
-
|
|
10614
|
-
|
|
10615
|
-
|
|
10616
|
-
|
|
10617
|
-
|
|
10618
|
-
|
|
10619
|
-
// inline-sass-content:./src/style.scss
|
|
10620
|
-
var style_default = '.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}.tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px #9aa1b126,0 4px 80px -8px #24282f40,0 4px 4px -2px #5b5e6926;background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}.fastboard-icon.light .fastboard-icon-stroke-color{stroke:var(--fastboard-color, #5d6066)}.fastboard-icon.light .fastboard-icon-fill-color{fill:var(--fastboard-color, #5d6066)}.fastboard-icon.light.is-active .fastboard-icon-stroke-color{stroke:var(--fastboard-active-color, #3381ff)}.fastboard-icon.light.is-active .fastboard-icon-fill-color{fill:var(--fastboard-active-color, #3381ff)}.fastboard-icon.dark .fastboard-icon-stroke-color{stroke:var(--fastboard-color, #7b7e84)}.fastboard-icon.dark .fastboard-icon-fill-color{fill:var(--fastboard-color, #7b7e84)}.fastboard-icon.dark.is-active .fastboard-icon-stroke-color{stroke:var(--fastboard-active-color, #2867cc)}.fastboard-icon.dark.is-active .fastboard-icon-fill-color{fill:var(--fastboard-active-color, #2867cc)}.fastboard-redo-undo{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}.fastboard-redo-undo *{box-sizing:inherit}.fastboard-redo-undo.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-redo-undo.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-redo-undo-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-redo-undo-btn svg,.fastboard-redo-undo-btn img{width:100%;height:100%;pointer-events:none}.fastboard-redo-undo-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-redo-undo-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-redo-undo-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-zoom-control{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}.fastboard-zoom-control *{box-sizing:inherit}.fastboard-zoom-control.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-zoom-control.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-zoom-control-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-zoom-control-btn svg,.fastboard-zoom-control-btn img{width:100%;height:100%;pointer-events:none}.fastboard-zoom-control-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-zoom-control-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-zoom-control-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-zoom-control-text{font-variant-numeric:tabular-nums}.fastboard-page-control{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}.fastboard-page-control *{box-sizing:inherit}.fastboard-page-control.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-page-control.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-page-control-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-page-control-btn svg,.fastboard-page-control-btn img{width:100%;height:100%;pointer-events:none}.fastboard-page-control-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-page-control-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-page-control-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-page-control-text{font-variant-numeric:tabular-nums}.fastboard-player-control{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px);width:100%}.fastboard-player-control *{box-sizing:inherit}.fastboard-player-control.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-player-control.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-player-control-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:0;width:24px;height:24px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0;display:inline}.fastboard-player-control-btn svg,.fastboard-player-control-btn img{width:100%;height:100%;pointer-events:none}.fastboard-player-control-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-player-control-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-player-control-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-player-control-btn.loading svg,.fastboard-player-control-btn.loading img{animation:fastboard-player-control-rotate .5s linear infinite}@keyframes fastboard-player-control-rotate{to{transform:rotate(360deg)}}.fastboard-player-control-btn.speed{width:auto;padding:4px;text-align:right;font-size:14px;font-variant-numeric:tabular-nums}.fastboard-player-control-btn.is-active.light{color:var(--fastboard-active-color, #3381ff)}.fastboard-player-control-btn.is-active.dark{color:var(--fastboard-active-color, #2867cc)}.fastboard-player-control-speed-text,.fastboard-player-control-progress{font-size:14px;font-variant-numeric:tabular-nums;line-height:16px}.fastboard-player-control-progress{display:inline-flex;align-items:center}.fastboard-player-control-panel.speed{display:flex;flex-direction:column}.fastboard-toolbar{height:100%;display:flex;align-items:center;position:relative;transform:translate(0);transition:transform .5s cubic-bezier(.34,1.56,.64,1);pointer-events:none}.fastboard-toolbar.collapsed{transform:translate(-100%)}.fastboard-toolbar-handler{position:absolute;left:100%;width:17px;font-size:0;border-radius:3px;cursor:pointer;pointer-events:auto}.fastboard-toolbar-handler:focus-within{outline:2px solid -webkit-focus-ring-color}.fastboard-toolbar-handler input[type=checkbox]{position:absolute;top:0;left:0;appearance:none;margin:0;width:100%;height:100%;cursor:pointer;opacity:0;z-index:-1}.fastboard-toolbar-handler svg{opacity:0;transition:opacity .5s 1s;pointer-events:none}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-bg-color{fill:var(--fastboard-bg-color, rgba(255, 255, 255, .9))}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-border-color{stroke:var(--fastboard-border-color, #e5e8f0)}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-image-stroke-color{stroke:var(--fastboard-color, #5d6066)}.fastboard-toolbar-handler.light .fastboard-toolbar-handler-image-fill-color{fill:var(--fastboard-color, #5d6066)}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-bg-color{fill:var(--fastboard-bg-color, rgba(20, 24, 30, .9))}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-border-color{stroke:var(--fastboard-border-color, #383b42)}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-image-stroke-color{stroke:var(--fastboard-color, #7b7e84)}.fastboard-toolbar-handler.dark .fastboard-toolbar-handler-image-fill-color{fill:var(--fastboard-color, #7b7e84)}.fastboard-toolbar:hover .fastboard-toolbar-handler svg,.fastboard-toolbar.collapsed .fastboard-toolbar-handler svg{opacity:1;transition:opacity .2s}.fastboard-toolbar-btn{appearance:none;cursor:pointer;margin:0;border:0;padding:4px;width:32px;height:32px;background-color:#0000;border-radius:4px;font-size:0;line-height:1;flex-shrink:0}.fastboard-toolbar-btn svg,.fastboard-toolbar-btn img{width:100%;height:100%;pointer-events:none}.fastboard-toolbar-btn:disabled{opacity:.5;cursor:not-allowed}.fastboard-toolbar-btn.light:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-toolbar-btn.dark:not(:disabled):hover{background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-slider{box-sizing:border-box;position:relative;width:100%;height:100%;display:flex;align-items:center}.fastboard-slider *{box-sizing:inherit}.fastboard-slider-track{appearance:none;background:rgba(0,0,0,0);border:0;border-radius:26px;flex:1;display:block;height:19px;margin:0;width:0;min-width:0;padding:0;transition:box-shadow .3s ease;cursor:pointer;touch-action:manipulation}.fastboard-slider-track::-webkit-slider-runnable-track{border:0;border-radius:2.5px;height:5px;transition:box-shadow .3s ease;user-select:none;background-color:#80808040;-webkit-user-select:none;background-image:linear-gradient(to right,currentColor var(--value, 0%),transparent var(--value, 0%))}.fastboard-slider-track::-webkit-slider-thumb{background:#fff;border:0;border-radius:100%;box-shadow:0 1px 1px #23292f26,0 0 0 1px #23292f33;width:13px;height:13px;position:relative;transition:all .2s ease;cursor:grab;appearance:none;margin-top:-4px}.fastboard-slider-track::-moz-range-track{border:0;border-radius:2.5px;height:5px;transition:box-shadow .3s ease;user-select:none;background-color:#80808040;-webkit-user-select:none}.fastboard-slider-track::-moz-range-thumb{appearance:none;background:#fff;border:0;border-radius:100%;box-shadow:0 1px 1px #23292f26,0 0 0 1px #23292f33;width:13px;height:13px;position:relative;transition:all .2s ease;cursor:grab}.fastboard-slider-track::-moz-range-progress{background:currentColor;border-radius:2.5px;height:5px}.fastboard-slider-track::-ms-track{border:0;border-radius:2.5px;height:5px;transition:box-shadow .3s ease;user-select:none;background-color:#80808040;-webkit-user-select:none;color:#0000}.fastboard-slider-track::-ms-thumb{appearance:none;background:#fff;border:0;border-radius:100%;box-shadow:0 1px 1px #23292f26,0 0 0 1px #23292f33;width:13px;height:13px;position:relative;transition:all .2s ease;cursor:grab;margin-top:0}.fastboard-slider-track::-ms-tooltip{display:none}.fastboard-slider-track::-moz-focus-outer{border:0}.fastboard-slider-track.grabbing::-webkit-slider-thumb{cursor:grabbing}.fastboard-slider-track.light{color:var(--fastboard-active-color, #3381ff)}.fastboard-slider-track.dark{color:var(--fastboard-active-color, #2867cc)}.fastboard-toolbar-contents{box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;border:1px solid;border-radius:4px;font-size:14px;font-family:system-ui;pointer-events:auto;backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px);padding:2px 0;gap:0;flex-direction:column}.fastboard-toolbar-contents *{box-sizing:inherit}.fastboard-toolbar-contents.light{color:var(--fastboard-color, #5d6066);background-color:var(--fastboard-bg-color, rgba(255, 255, 255, .9));border-color:var(--fastboard-border-color, #e5e8f0)}.fastboard-toolbar-contents.dark{color:var(--fastboard-color, #7b7e84);background-color:var(--fastboard-bg-color, rgba(20, 24, 30, .9));border-color:var(--fastboard-border-color, #383b42)}.fastboard-toolbar-contents>.fastboard-toolbar-btn{margin:2px 4px}.fastboard-toolbar-btn-interactive{position:relative}.fastboard-toolbar-triangle{width:0px;height:0px;border-bottom:4px solid;border-left:4px solid rgba(0,0,0,0);position:absolute;bottom:0;right:0}.fastboard-toolbar-btn:focus+.fastboard-toolbar-triangle{opacity:0}.fastboard-toolbar-scrollable{padding:2px 4px;overflow:hidden;display:flex;flex-direction:column;gap:4px}.fastboard-toolbar-tooltip{display:inline-flex;align-items:center;gap:4px}.fastboard-toolbar-hotkey{display:inline-flex;margin-right:-4px;width:24px;height:24px;align-items:center;justify-content:center;background-color:#ffffff1a;border-radius:4px}.fastboard-toolbar-panel-wrapper{display:none}.fastboard-toolbar-panel{display:flex;flex-direction:column}.fastboard-toolbar-panel-divider{height:.5px;width:100%;margin:4px 0;background-color:#ffffff26}.fastboard-toolbar-colors,.fastboard-toolbar-shapes{display:grid;align-self:center;grid-template:repeat(2,1fr)/repeat(4,1fr);align-items:center;justify-items:center;gap:4px}.fastboard-toolbar-shape-btn,.fastboard-toolbar-color-btn{width:24px;height:24px;padding:0;display:inline-flex;align-items:center;justify-content:center}.fastboard-toolbar-color-btn{border:1px solid rgba(0,0,0,0)}.fastboard-toolbar-color-btn.light.is-active{border-color:var(--fastboard-active-color, #3381ff)}.fastboard-toolbar-color-btn.dark.is-active{border-color:var(--fastboard-active-color, #2867cc)}.fastboard-toolbar-color-item{display:inline-block;width:16px;height:16px;border-radius:4px;pointer-events:none}.fastboard-toolbar-panel.apps{display:grid;grid-template-columns:repeat(min(var(--n, 3),3),minmax(max-content,1fr));gap:4px}.fastboard-toolbar-app-btn{margin:0;border:0;border-radius:2px;padding:4px 6px;background-color:#0000;display:inline-flex;flex-direction:column;align-items:center;gap:4px;font-size:0}.fastboard-toolbar-app-btn:disabled{opacity:.8}.fastboard-toolbar-app-btn-icon{width:32px;height:32px;pointer-events:none}.fastboard-toolbar-app-btn-text{font-size:14px;line-height:1;max-width:100%;overflow:hidden;text-overflow:ellipsis}.fastboard-toolbar-app-btn.is-loading{cursor:progress}.fastboard-toolbar-app-btn.is-failed{cursor:not-allowed;opacity:.5}.fastboard-toolbar-app-btn:not(:disabled,.is-loading,.is-failed):hover.light{cursor:pointer;background-color:var(--fastboard-hover-bg-color, #ebf2ff)}.fastboard-toolbar-app-btn-text.light{color:var(--fastboard-color, #5d6066)}.fastboard-toolbar-app-btn:not(:disabled,.is-loading,.is-failed):hover.dark{cursor:pointer;background-color:var(--fastboard-hover-bg-color, #383b42)}.fastboard-toolbar-app-btn-text.dark{color:var(--fastboard-color, #7b7e84)}.fastboard-root{position:relative;width:100%;height:100%;overflow:hidden}.fastboard-view{position:absolute;top:0;left:0;width:100%;height:100%}.fastboard-left{display:flex;align-items:center;position:absolute;bottom:62px;top:8px;left:0;z-index:200;pointer-events:none}.fastboard-left .fastboard-toolbar{padding-left:16px}.fastboard-bottom-left,.fastboard-bottom,.fastboard-bottom-right{display:flex;gap:10px;position:absolute;bottom:8px;left:8px;padding:8px;z-index:200;pointer-events:none}.fastboard-bottom-right{left:auto;right:8px}.fastboard-bottom{right:8px}.fastboard-left.hidden *,.fastboard-bottom.hidden *,.fastboard-bottom-left.hidden *,.fastboard-bottom-right.hidden *{opacity:0;pointer-events:none}.fastboard-tip{font-family:inherit;color:#d5d9e0;background-color:#03060d}.fastboard-tip[data-placement^=right]>.tippy-arrow:before{top:4px;border-width:4px;border-right-color:#03060d}.fastboard-tip[data-placement^=top]>.tippy-arrow:before{left:4px;border-width:4px;border-top-color:#03060d}.fastboard-panel .tippy-content{padding:8px}';
|
|
10621
|
-
|
|
10622
|
-
// inline-sass-stub:./src/style.scss
|
|
10623
|
-
injectStyle(style_default);
|
|
10676
|
+
exports.Fastboard = Fastboard_default;
|
|
10677
|
+
exports.PageControl = PageControl_default;
|
|
10678
|
+
exports.PlayerControl = PlayerControl_default;
|
|
10679
|
+
exports.RedoUndo = RedoUndo_default;
|
|
10680
|
+
exports.ReplayFastboard = ReplayFastboard_default;
|
|
10681
|
+
exports.Toolbar = Toolbar_default;
|
|
10682
|
+
exports.ZoomControl = ZoomControl_default;
|
|
10683
|
+
exports.apps = apps;
|
|
10684
|
+
exports.createReplayUI = createReplayUI;
|
|
10685
|
+
exports.createUI = createUI;
|
|
10624
10686
|
//# sourceMappingURL=index.js.map
|