microboard-ui-temp 0.0.38 → 0.0.39
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/board.html +3 -3
- package/dist/customWebComponents.js +5 -5
- package/dist/index.js +7 -5
- package/package.json +2 -2
package/dist/board.html
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
<link
|
|
12
12
|
rel="stylesheet"
|
|
13
13
|
crossorigin
|
|
14
|
-
href="https://unpkg.com/microboard-ui-temp@0.0.
|
|
14
|
+
href="https://unpkg.com/microboard-ui-temp@0.0.39/dist/board.css"
|
|
15
15
|
/>
|
|
16
16
|
<body style="overflow-x: hidden; overflow-y: hidden">
|
|
17
17
|
<div id="items">
|
|
@@ -84,11 +84,11 @@
|
|
|
84
84
|
</div>
|
|
85
85
|
<script
|
|
86
86
|
type="module"
|
|
87
|
-
src="https://unpkg.com/microboard-ui-temp@0.0.
|
|
87
|
+
src="https://unpkg.com/microboard-ui-temp@0.0.39/dist/customWebComponents.js"
|
|
88
88
|
></script>
|
|
89
89
|
<script
|
|
90
90
|
defer
|
|
91
|
-
src="https://unpkg.com/microboard-ui-temp@0.0.
|
|
91
|
+
src="https://unpkg.com/microboard-ui-temp@0.0.39/dist/loadLinksImages.js"
|
|
92
92
|
></script>
|
|
93
93
|
</body>
|
|
94
94
|
</head>
|
|
@@ -275,9 +275,9 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
275
275
|
translateY = 0;
|
|
276
276
|
scale = 1;
|
|
277
277
|
updateTransform();
|
|
278
|
-
const { initInter } = await import("https://www.unpkg.com/microboard-ui-temp@0.0.
|
|
278
|
+
const { initInter } = await import("https://www.unpkg.com/microboard-ui-temp@0.0.39/dist/index.js");
|
|
279
279
|
initInter();
|
|
280
|
-
const { createApp } = await import("https://www.unpkg.com/microboard-ui-temp@0.0.
|
|
280
|
+
const { createApp } = await import("https://www.unpkg.com/microboard-ui-temp@0.0.39/dist/index.js");
|
|
281
281
|
const app = createApp();
|
|
282
282
|
window.app = app;
|
|
283
283
|
const stringed = await app.openAndEditFile();
|
|
@@ -286,12 +286,12 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
286
286
|
app.getBoard().deserializeHTML(stringed);
|
|
287
287
|
app.localRender("items");
|
|
288
288
|
}
|
|
289
|
-
const response = await fetch("https://www.unpkg.com/microboard-ui-temp@0.0.
|
|
289
|
+
const response = await fetch("https://www.unpkg.com/microboard-ui-temp@0.0.39/dist/index.css");
|
|
290
290
|
const cssText = await response.text();
|
|
291
291
|
const styleEl = document.createElement("style");
|
|
292
292
|
styleEl.textContent = cssText;
|
|
293
293
|
document.body.appendChild(styleEl);
|
|
294
|
-
const responseSvg = await fetch("https://www.unpkg.com/microboard-ui-temp@0.0.
|
|
294
|
+
const responseSvg = await fetch("https://www.unpkg.com/microboard-ui-temp@0.0.39/dist/sprite.svg");
|
|
295
295
|
const svgText = await responseSvg.text();
|
|
296
296
|
const div = document.createElement("div");
|
|
297
297
|
div.style.display = "none";
|
|
@@ -308,7 +308,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
308
308
|
ev.stopPropagation();
|
|
309
309
|
const htmlContent = document.documentElement.innerHTML;
|
|
310
310
|
const boardName2 = document.title?.trim() || "shared-board";
|
|
311
|
-
const { boardsApi, createApp, frontConf } = await import("https://www.unpkg.com/microboard-ui-temp@0.0.
|
|
311
|
+
const { boardsApi, createApp, frontConf } = await import("https://www.unpkg.com/microboard-ui-temp@0.0.39/dist/index.js");
|
|
312
312
|
frontConf.apiURL = "https://dev-app.microboard.io/api/v1/";
|
|
313
313
|
const boardId = await boardsApi.createBoardUnAuthed(boardName2);
|
|
314
314
|
const app = createApp();
|
package/dist/index.js
CHANGED
|
@@ -255868,7 +255868,7 @@ class Card extends BaseItem {
|
|
|
255868
255868
|
this.board.bringToFront(this);
|
|
255869
255869
|
}, 1000);
|
|
255870
255870
|
this.transformation.subject.subscribe((_, op) => {
|
|
255871
|
-
if (this.parent === "Board" && op.method === "translateBy"
|
|
255871
|
+
if (this.parent === "Board" && op.method === "translateBy") {
|
|
255872
255872
|
this.throttledBringToFront();
|
|
255873
255873
|
}
|
|
255874
255874
|
this.updateMbr();
|
|
@@ -255895,14 +255895,14 @@ class Card extends BaseItem {
|
|
|
255895
255895
|
this.imageToRender = this.face;
|
|
255896
255896
|
}
|
|
255897
255897
|
}
|
|
255898
|
-
render(context) {
|
|
255898
|
+
render(context, left) {
|
|
255899
255899
|
if (this.transformationRenderBlock) {
|
|
255900
255900
|
return;
|
|
255901
255901
|
}
|
|
255902
255902
|
const ctx = context.ctx;
|
|
255903
255903
|
if (this.imageToRender && this.imageToRender.complete) {
|
|
255904
255904
|
ctx.save();
|
|
255905
|
-
ctx.drawImage(this.imageToRender, this.left, this.top, CARD_DIMENSIONS.width, CARD_DIMENSIONS.height);
|
|
255905
|
+
ctx.drawImage(this.imageToRender, left ? left : this.left, this.top, CARD_DIMENSIONS.width, CARD_DIMENSIONS.height);
|
|
255906
255906
|
ctx.restore();
|
|
255907
255907
|
}
|
|
255908
255908
|
}
|
|
@@ -256098,14 +256098,16 @@ class Deck extends BaseItem {
|
|
|
256098
256098
|
if (!width2 || !height3) {
|
|
256099
256099
|
return;
|
|
256100
256100
|
}
|
|
256101
|
-
const tempCanvas =
|
|
256101
|
+
const tempCanvas = conf.documentFactory.createElement("canvas");
|
|
256102
256102
|
tempCanvas.width = width2;
|
|
256103
256103
|
tempCanvas.height = height3;
|
|
256104
256104
|
const tempCtx = tempCanvas.getContext("2d");
|
|
256105
256105
|
if (!tempCtx)
|
|
256106
256106
|
return;
|
|
256107
256107
|
const tempContext = { ...context, ctx: tempCtx };
|
|
256108
|
-
this.index?.
|
|
256108
|
+
this.index?.list().forEach((item, index2) => {
|
|
256109
|
+
item.render(tempContext, index2 * 2);
|
|
256110
|
+
});
|
|
256109
256111
|
this.cachedCanvas = tempCanvas;
|
|
256110
256112
|
}
|
|
256111
256113
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "microboard-ui-temp",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.39",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"module": "dist/index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"i18next-browser-languagedetector": "^8.2.0",
|
|
51
51
|
"js-cookie": "^3.0.5",
|
|
52
52
|
"jwt-decode": "^4.0.0",
|
|
53
|
-
"microboard-temp": "^0.4.
|
|
53
|
+
"microboard-temp": "^0.4.94",
|
|
54
54
|
"nanoid": "^5.1.5",
|
|
55
55
|
"prop-types": "^15.8.1",
|
|
56
56
|
"react-hot-toast": "2.4.1",
|