microboard-temp 0.14.20 → 0.14.22
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/cjs/browser.js +287 -62
- package/dist/cjs/index.js +287 -62
- package/dist/cjs/node.js +287 -62
- package/dist/cjs/overlayIconManifest.js +115 -0
- package/dist/esm/browser.js +287 -62
- package/dist/esm/index.js +287 -62
- package/dist/esm/node.js +287 -62
- package/dist/esm/overlayIconManifest.js +113 -0
- package/dist/overlay-icons/Items/Card/icons/Flip.icon.svg +1 -0
- package/dist/overlay-icons/Items/Card/icons/RotateCcw.icon.svg +1 -0
- package/dist/overlay-icons/Items/Card/icons/RotateCw.icon.svg +1 -0
- package/dist/overlay-icons/Items/Card/icons/Tool.icon.svg +7 -0
- package/dist/overlay-icons/Items/Connector/icons/LineCurved.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/LineOrthogonal.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/LineStraight.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerArrowHeavy.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerArrowThin.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerCircleFilled.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerCircleOutline.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerDiamondFilled.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerDiamondOutline.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerNone.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerTriangleFilled.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/PointerTriangleOutline.icon.svg +1 -0
- package/dist/overlay-icons/Items/Connector/icons/SmartJump.icon.svg +3 -0
- package/dist/overlay-icons/Items/Connector/icons/Style.icon.svg +5 -0
- package/dist/overlay-icons/Items/Connector/icons/SwitchPointers.icon.svg +4 -0
- package/dist/overlay-icons/Items/Connector/icons/Tool.icon.svg +3 -0
- package/dist/overlay-icons/Items/Deck/icons/CreateFromSelection.icon.svg +1 -0
- package/dist/overlay-icons/Items/Deck/icons/DrawBottom.icon.svg +1 -0
- package/dist/overlay-icons/Items/Deck/icons/DrawMany.icon.svg +1 -0
- package/dist/overlay-icons/Items/Deck/icons/DrawRandom.icon.svg +1 -0
- package/dist/overlay-icons/Items/Deck/icons/DrawTop.icon.svg +1 -0
- package/dist/overlay-icons/Items/Deck/icons/Flip.icon.svg +1 -0
- package/dist/overlay-icons/Items/Deck/icons/Shuffle.icon.svg +1 -0
- package/dist/overlay-icons/Items/Dice/icons/Range.icon.svg +1 -0
- package/dist/overlay-icons/Items/Dice/icons/Throw.icon.svg +1 -0
- package/dist/overlay-icons/Items/Dice/icons/Tool.icon.svg +1 -0
- package/dist/overlay-icons/Items/Drawing/icons/Eraser.icon.svg +3 -0
- package/dist/overlay-icons/Items/Drawing/icons/Highlighter.icon.svg +3 -0
- package/dist/overlay-icons/Items/Drawing/icons/Pen.icon.svg +3 -0
- package/dist/overlay-icons/Items/Frame/Basic/1-1/1-1.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Basic/16-9/16-9.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Basic/3-2/3-2.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Basic/4-3/4-3.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Basic/9-18/9-18.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Basic/A4/A4.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Basic/Custom/Custom.icon.svg +14 -0
- package/dist/overlay-icons/Items/Frame/Basic/Letter/Letter.icon.svg +1 -0
- package/dist/overlay-icons/Items/Frame/Frame.icon.svg +1 -0
- package/dist/overlay-icons/Items/Placeholder/Placeholder.icon.svg +4 -0
- package/dist/overlay-icons/Items/RichText/icons/FontSize.icon.svg +3 -0
- package/dist/overlay-icons/Items/RichText/icons/Text.icon.svg +3 -0
- package/dist/overlay-icons/Items/Screen/icons/Background.icon.svg +1 -0
- package/dist/overlay-icons/Items/Screen/icons/BackgroundImage.icon.svg +1 -0
- package/dist/overlay-icons/Items/Screen/icons/BackgroundImageRemove.icon.svg +1 -0
- package/dist/overlay-icons/Items/Screen/icons/Pouch.icon.svg +1 -0
- package/dist/overlay-icons/Items/Screen/icons/Tool.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_Annotation/BPMN_Annotation.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_DataObject/BPMN_DataObject.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_DataStore/BPMN_DataStore.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_EndEvent/BPMN_EndEvent.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_EventSubprocess/BPMN_EventSubprocess.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_Gateway/BPMN_Gateway.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_GatewayParallel/BPMN_GatewayParallel.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_GatewayXOR/BPMN_GatewayXOR.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_Group/BPMN_Group.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_IntermediateEvent/BPMN_IntermediateEvent.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_IntermediateEventNoneInterrupting/BPMN_IntermediateEventNoneInterrupting.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_Participant/BPMN_Participant.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_StartEvent/BPMN_StartEvent.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_StartEventNoneInterrupting/BPMN_StartEventNoneInterrupting.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_Task/BPMN_Task.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/BPMN/BPMN_Transaction/BPMN_Transaction.icon.svg +1 -0
- package/dist/overlay-icons/Items/Shape/Basic/ArrowLeft/ArrowLeft.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/ArrowLeftRight/ArrowLeftRight.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/ArrowRight/ArrowRight.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/BracesLeft/BracesLeft.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/BracesRight/BracesRight.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Circle/Circle.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Cloud/Cloud.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Cross/Cross.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Cylinder/Cylinder.icon.svg +19 -0
- package/dist/overlay-icons/Items/Shape/Basic/Hexagon/Hexagon.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Octagon/Octagon.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Parallelogram/Parallelogram.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Pentagon/Pentagon.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Rectangle/Rectangle.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Rhombus/Rhombus.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/RoundedRectangle/RoundedRectangle.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/SpeachBubble/SpeachBubble.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Star/Star.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Trapezoid/Trapezoid.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/Basic/Triangle/Triangle.icon.svg +14 -0
- package/dist/overlay-icons/Items/Shape/icons/ArrowBlockLeft.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/ArrowBlockRight.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/Color.icon.svg +4 -0
- package/dist/overlay-icons/Items/Shape/icons/Fill.icon.svg +4 -0
- package/dist/overlay-icons/Items/Shape/icons/PredefinedProcess.icon.svg +4 -0
- package/dist/overlay-icons/Items/Shape/icons/ReversedParallelogram.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/ReversedTriangle.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/Stroke.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/StrokeDash.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/StrokeDot.icon.svg +5 -0
- package/dist/overlay-icons/Items/Shape/icons/StrokeLongDash.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/StrokeSolid.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/Tool.icon.svg +3 -0
- package/dist/overlay-icons/Items/Shape/icons/Type.icon.svg +5 -0
- package/dist/overlay-icons/Items/Sticker/Path/Sticker.icon.svg +14 -0
- package/dist/overlay-icons/Overlay/icons/BringToFront.icon.svg +5 -0
- package/dist/overlay-icons/Overlay/icons/Delete.icon.svg +7 -0
- package/dist/overlay-icons/Overlay/icons/Duplicate.icon.svg +4 -0
- package/dist/overlay-icons/Overlay/icons/Lock.icon.svg +4 -0
- package/dist/overlay-icons/Overlay/icons/SendToBack.icon.svg +5 -0
- package/dist/overlay-icons/Overlay/icons/Unlock.icon.svg +4 -0
- package/dist/overlay-icons/Overlay/overlay-icons.svg +323 -0
- package/dist/types/Items/Card/CardOverlay.d.ts +2 -1
- package/dist/types/Overlay/IconPack.d.ts +4 -2
- package/dist/types/Overlay/OverlayMetadata.d.ts +24 -0
- package/dist/types/Overlay/overlayRegistry.d.ts +1 -0
- package/dist/types/Selection/SelectionOverlay.d.ts +1 -0
- package/dist/types/Selection/index.d.ts +1 -0
- package/dist/types/Tools/WorkflowTool.d.ts +8 -0
- package/dist/types/Tools/index.d.ts +1 -0
- package/dist/types/overlayIconManifest.d.ts +2 -0
- package/package.json +8 -2
package/dist/esm/browser.js
CHANGED
|
@@ -11499,7 +11499,11 @@ function toLocalTransformOp(op, containerMatrix, itemId) {
|
|
|
11499
11499
|
}
|
|
11500
11500
|
}
|
|
11501
11501
|
// src/Overlay/IconPack.ts
|
|
11502
|
-
var
|
|
11502
|
+
var OVERLAY_ICON_ASSET_PREFIX = "overlay-icons/";
|
|
11503
|
+
var OVERLAY_ICON_SPRITE_PATH = normalizeOverlayIconAssetPath("src/Overlay/overlay-icons.svg");
|
|
11504
|
+
function normalizeOverlayIconAssetPath(sourcePath) {
|
|
11505
|
+
return sourcePath.startsWith("src/") ? `${OVERLAY_ICON_ASSET_PREFIX}${sourcePath.slice(4)}` : sourcePath;
|
|
11506
|
+
}
|
|
11503
11507
|
function overlaySymbolIcon(key) {
|
|
11504
11508
|
return {
|
|
11505
11509
|
kind: "symbol",
|
|
@@ -11507,15 +11511,18 @@ function overlaySymbolIcon(key) {
|
|
|
11507
11511
|
sourcePath: OVERLAY_ICON_SPRITE_PATH
|
|
11508
11512
|
};
|
|
11509
11513
|
}
|
|
11510
|
-
function overlayAssetIcon(
|
|
11514
|
+
function overlayAssetIcon(sourcePath, state) {
|
|
11515
|
+
const path2 = normalizeOverlayIconAssetPath(sourcePath);
|
|
11511
11516
|
return state ? {
|
|
11512
11517
|
kind: "asset",
|
|
11513
11518
|
path: path2,
|
|
11519
|
+
sourcePath,
|
|
11514
11520
|
mimeType: "image/svg+xml",
|
|
11515
11521
|
state
|
|
11516
11522
|
} : {
|
|
11517
11523
|
kind: "asset",
|
|
11518
11524
|
path: path2,
|
|
11525
|
+
sourcePath,
|
|
11519
11526
|
mimeType: "image/svg+xml"
|
|
11520
11527
|
};
|
|
11521
11528
|
}
|
|
@@ -11675,10 +11682,23 @@ function compareEntriesByOrder(a, b) {
|
|
|
11675
11682
|
return aOrder - bOrder || aLabel.localeCompare(bLabel);
|
|
11676
11683
|
}
|
|
11677
11684
|
function readOverlayValueSource(context, source) {
|
|
11685
|
+
if (source.kind === "selectionProperty") {
|
|
11686
|
+
return readOverlayContextProperty(context.selection, source.property);
|
|
11687
|
+
}
|
|
11678
11688
|
if (source.kind === "itemProperty") {
|
|
11679
|
-
return context.item
|
|
11689
|
+
return readOverlayContextProperty(context.item, source.property);
|
|
11690
|
+
}
|
|
11691
|
+
return readOverlayContextProperty(context.tool, source.property);
|
|
11692
|
+
}
|
|
11693
|
+
function readOverlayContextProperty(target, property) {
|
|
11694
|
+
if (!target) {
|
|
11695
|
+
return;
|
|
11696
|
+
}
|
|
11697
|
+
const value = target[property];
|
|
11698
|
+
if (typeof value === "function") {
|
|
11699
|
+
return value.call(target);
|
|
11680
11700
|
}
|
|
11681
|
-
return
|
|
11701
|
+
return value;
|
|
11682
11702
|
}
|
|
11683
11703
|
// src/Items/BaseItem/BaseItem.ts
|
|
11684
11704
|
class BaseItem {
|
|
@@ -62820,6 +62840,10 @@ class Drawing extends BaseItem {
|
|
|
62820
62840
|
this.path2d = new conf.path2DFactory;
|
|
62821
62841
|
const context = this.path2d;
|
|
62822
62842
|
const points = this.points;
|
|
62843
|
+
if (points.length === 0) {
|
|
62844
|
+
this.untransformedMbr = new Mbr;
|
|
62845
|
+
return;
|
|
62846
|
+
}
|
|
62823
62847
|
if (points.length < 3) {
|
|
62824
62848
|
context.arc(points[0].x, points[0].y, 0.5, 0, Math.PI * 2, true);
|
|
62825
62849
|
context.closePath();
|
|
@@ -62870,6 +62894,9 @@ class Drawing extends BaseItem {
|
|
|
62870
62894
|
}
|
|
62871
62895
|
}
|
|
62872
62896
|
optimizePoints() {
|
|
62897
|
+
if (this.points.length === 0) {
|
|
62898
|
+
return;
|
|
62899
|
+
}
|
|
62873
62900
|
const dp = douglasPeucker(this.points, 1);
|
|
62874
62901
|
dp.push(this.points[this.points.length - 1]);
|
|
62875
62902
|
this.points = dp;
|
|
@@ -63155,6 +63182,68 @@ var propertyOps = {
|
|
|
63155
63182
|
}
|
|
63156
63183
|
};
|
|
63157
63184
|
|
|
63185
|
+
// src/Tools/Tool.ts
|
|
63186
|
+
class Tool {
|
|
63187
|
+
leftButtonDown() {
|
|
63188
|
+
return false;
|
|
63189
|
+
}
|
|
63190
|
+
leftButtonUp() {
|
|
63191
|
+
return false;
|
|
63192
|
+
}
|
|
63193
|
+
leftButtonDouble() {
|
|
63194
|
+
return false;
|
|
63195
|
+
}
|
|
63196
|
+
rightButtonDown() {
|
|
63197
|
+
return false;
|
|
63198
|
+
}
|
|
63199
|
+
rightButtonUp() {
|
|
63200
|
+
return false;
|
|
63201
|
+
}
|
|
63202
|
+
rightButtonDouble() {
|
|
63203
|
+
return false;
|
|
63204
|
+
}
|
|
63205
|
+
middleButtonDown() {
|
|
63206
|
+
return false;
|
|
63207
|
+
}
|
|
63208
|
+
middleButtonUp() {
|
|
63209
|
+
return false;
|
|
63210
|
+
}
|
|
63211
|
+
middleButtonDouble() {
|
|
63212
|
+
return false;
|
|
63213
|
+
}
|
|
63214
|
+
keyDown(_key) {
|
|
63215
|
+
return false;
|
|
63216
|
+
}
|
|
63217
|
+
keyUp(_key) {
|
|
63218
|
+
return false;
|
|
63219
|
+
}
|
|
63220
|
+
pointerMoveBy(_x, _y) {
|
|
63221
|
+
return false;
|
|
63222
|
+
}
|
|
63223
|
+
pointerDown() {
|
|
63224
|
+
return false;
|
|
63225
|
+
}
|
|
63226
|
+
pointerUp() {
|
|
63227
|
+
return false;
|
|
63228
|
+
}
|
|
63229
|
+
onCancel() {}
|
|
63230
|
+
onConfirm() {}
|
|
63231
|
+
render(_context) {}
|
|
63232
|
+
}
|
|
63233
|
+
|
|
63234
|
+
// src/Tools/BoardTool.ts
|
|
63235
|
+
class BoardTool extends Tool {
|
|
63236
|
+
board;
|
|
63237
|
+
constructor(board) {
|
|
63238
|
+
super();
|
|
63239
|
+
this.board = board;
|
|
63240
|
+
}
|
|
63241
|
+
}
|
|
63242
|
+
|
|
63243
|
+
// src/Tools/WorkflowTool.ts
|
|
63244
|
+
class WorkflowTool extends BoardTool {
|
|
63245
|
+
}
|
|
63246
|
+
|
|
63158
63247
|
// src/Items/Card/CardOverlay.ts
|
|
63159
63248
|
var cardOverlay = {
|
|
63160
63249
|
itemType: "Card",
|
|
@@ -63190,6 +63279,73 @@ var cardOverlay = {
|
|
|
63190
63279
|
}
|
|
63191
63280
|
]
|
|
63192
63281
|
};
|
|
63282
|
+
var addCardToolOverlay = {
|
|
63283
|
+
toolName: "AddCard",
|
|
63284
|
+
label: "Card",
|
|
63285
|
+
kind: "create",
|
|
63286
|
+
createsItemType: "Card",
|
|
63287
|
+
family: "game",
|
|
63288
|
+
icon: overlayAssetIcon("src/Items/Card/icons/Tool.icon.svg"),
|
|
63289
|
+
launch: {
|
|
63290
|
+
kind: "workflow",
|
|
63291
|
+
workflow: {
|
|
63292
|
+
kind: "property-sheet",
|
|
63293
|
+
description: "Upload front and back images for one or more cards.",
|
|
63294
|
+
submitLabel: "Create cards",
|
|
63295
|
+
controls: [
|
|
63296
|
+
{
|
|
63297
|
+
id: "cardArtwork",
|
|
63298
|
+
label: "Card artwork",
|
|
63299
|
+
editor: {
|
|
63300
|
+
kind: "asset-upload",
|
|
63301
|
+
mode: "paired",
|
|
63302
|
+
fields: [
|
|
63303
|
+
{
|
|
63304
|
+
id: "face",
|
|
63305
|
+
label: "Front",
|
|
63306
|
+
accept: ["image/*"],
|
|
63307
|
+
required: true
|
|
63308
|
+
},
|
|
63309
|
+
{
|
|
63310
|
+
id: "back",
|
|
63311
|
+
label: "Back",
|
|
63312
|
+
accept: ["image/*"],
|
|
63313
|
+
required: true
|
|
63314
|
+
}
|
|
63315
|
+
]
|
|
63316
|
+
}
|
|
63317
|
+
}
|
|
63318
|
+
],
|
|
63319
|
+
submit: {
|
|
63320
|
+
kind: "create-items",
|
|
63321
|
+
itemType: "Card",
|
|
63322
|
+
strategy: "per-upload-entry",
|
|
63323
|
+
placement: "stagger-from-pointer",
|
|
63324
|
+
properties: [
|
|
63325
|
+
{
|
|
63326
|
+
property: "faceUrl",
|
|
63327
|
+
source: { kind: "uploadField", controlId: "cardArtwork", fieldId: "face" }
|
|
63328
|
+
},
|
|
63329
|
+
{
|
|
63330
|
+
property: "backsideUrl",
|
|
63331
|
+
source: { kind: "uploadField", controlId: "cardArtwork", fieldId: "back" }
|
|
63332
|
+
}
|
|
63333
|
+
]
|
|
63334
|
+
}
|
|
63335
|
+
}
|
|
63336
|
+
},
|
|
63337
|
+
surface: {
|
|
63338
|
+
order: 4,
|
|
63339
|
+
group: {
|
|
63340
|
+
id: "gameItems",
|
|
63341
|
+
label: "Game items",
|
|
63342
|
+
icon: overlayAssetIcon("src/Items/Dice/icons/Tool.icon.svg"),
|
|
63343
|
+
order: 1,
|
|
63344
|
+
behavior: "open-panel"
|
|
63345
|
+
},
|
|
63346
|
+
relatedToolNames: ["AddDice", "AddScreen", "AddPouch"]
|
|
63347
|
+
}
|
|
63348
|
+
};
|
|
63193
63349
|
|
|
63194
63350
|
// src/Items/Card/Card.ts
|
|
63195
63351
|
var defaultCardData = {
|
|
@@ -63384,6 +63540,11 @@ registerItem({
|
|
|
63384
63540
|
defaultData: defaultCardData,
|
|
63385
63541
|
overlay: cardOverlay
|
|
63386
63542
|
});
|
|
63543
|
+
registerTool({
|
|
63544
|
+
name: "AddCard",
|
|
63545
|
+
tool: WorkflowTool,
|
|
63546
|
+
overlay: addCardToolOverlay
|
|
63547
|
+
});
|
|
63387
63548
|
registerHotkey({
|
|
63388
63549
|
name: "Rotate90deg",
|
|
63389
63550
|
hotkey: { key: { button: "KeyQ", shift: true }, label: { windows: "Shift+Q", mac: "⇧Q" } },
|
|
@@ -63890,64 +64051,6 @@ registerHotkey({
|
|
|
63890
64051
|
}
|
|
63891
64052
|
});
|
|
63892
64053
|
registerSelectionAction(createDeckSelectionAction);
|
|
63893
|
-
// src/Tools/Tool.ts
|
|
63894
|
-
class Tool {
|
|
63895
|
-
leftButtonDown() {
|
|
63896
|
-
return false;
|
|
63897
|
-
}
|
|
63898
|
-
leftButtonUp() {
|
|
63899
|
-
return false;
|
|
63900
|
-
}
|
|
63901
|
-
leftButtonDouble() {
|
|
63902
|
-
return false;
|
|
63903
|
-
}
|
|
63904
|
-
rightButtonDown() {
|
|
63905
|
-
return false;
|
|
63906
|
-
}
|
|
63907
|
-
rightButtonUp() {
|
|
63908
|
-
return false;
|
|
63909
|
-
}
|
|
63910
|
-
rightButtonDouble() {
|
|
63911
|
-
return false;
|
|
63912
|
-
}
|
|
63913
|
-
middleButtonDown() {
|
|
63914
|
-
return false;
|
|
63915
|
-
}
|
|
63916
|
-
middleButtonUp() {
|
|
63917
|
-
return false;
|
|
63918
|
-
}
|
|
63919
|
-
middleButtonDouble() {
|
|
63920
|
-
return false;
|
|
63921
|
-
}
|
|
63922
|
-
keyDown(_key) {
|
|
63923
|
-
return false;
|
|
63924
|
-
}
|
|
63925
|
-
keyUp(_key) {
|
|
63926
|
-
return false;
|
|
63927
|
-
}
|
|
63928
|
-
pointerMoveBy(_x, _y) {
|
|
63929
|
-
return false;
|
|
63930
|
-
}
|
|
63931
|
-
pointerDown() {
|
|
63932
|
-
return false;
|
|
63933
|
-
}
|
|
63934
|
-
pointerUp() {
|
|
63935
|
-
return false;
|
|
63936
|
-
}
|
|
63937
|
-
onCancel() {}
|
|
63938
|
-
onConfirm() {}
|
|
63939
|
-
render(_context) {}
|
|
63940
|
-
}
|
|
63941
|
-
|
|
63942
|
-
// src/Tools/BoardTool.ts
|
|
63943
|
-
class BoardTool extends Tool {
|
|
63944
|
-
board;
|
|
63945
|
-
constructor(board) {
|
|
63946
|
-
super();
|
|
63947
|
-
this.board = board;
|
|
63948
|
-
}
|
|
63949
|
-
}
|
|
63950
|
-
|
|
63951
64054
|
// src/Tools/CustomTool.ts
|
|
63952
64055
|
class CustomTool extends BoardTool {
|
|
63953
64056
|
name;
|
|
@@ -67751,6 +67854,125 @@ class Presence {
|
|
|
67751
67854
|
}
|
|
67752
67855
|
}
|
|
67753
67856
|
|
|
67857
|
+
// src/Selection/SelectionOverlay.ts
|
|
67858
|
+
function everyItemHasRichText(items) {
|
|
67859
|
+
return items.length > 0 && items.every((item) => !!item.getRichText?.());
|
|
67860
|
+
}
|
|
67861
|
+
registerSelectionAction({
|
|
67862
|
+
id: "selection.delete",
|
|
67863
|
+
label: "Delete",
|
|
67864
|
+
icon: overlayAssetIcon("src/Overlay/icons/Delete.icon.svg"),
|
|
67865
|
+
description: "Removes the selected items from the board.",
|
|
67866
|
+
invoke: { kind: "selectionMethod", methodName: "removeFromBoard" },
|
|
67867
|
+
isAvailable: (items) => items.length > 0
|
|
67868
|
+
});
|
|
67869
|
+
registerSelectionAction({
|
|
67870
|
+
id: "selection.duplicate",
|
|
67871
|
+
label: "Duplicate",
|
|
67872
|
+
icon: overlayAssetIcon("src/Overlay/icons/Duplicate.icon.svg"),
|
|
67873
|
+
description: "Duplicates the selected items.",
|
|
67874
|
+
invoke: { kind: "selectionMethod", methodName: "duplicate" },
|
|
67875
|
+
isAvailable: (items) => items.length > 0
|
|
67876
|
+
});
|
|
67877
|
+
registerSelectionAction({
|
|
67878
|
+
id: "selection.lock",
|
|
67879
|
+
label: "Lock",
|
|
67880
|
+
icon: overlayAssetIcon("src/Overlay/icons/Lock.icon.svg"),
|
|
67881
|
+
description: "Locks the selected items.",
|
|
67882
|
+
invoke: { kind: "selectionMethod", methodName: "lock" },
|
|
67883
|
+
isAvailable: (items) => items.length > 0 && !items.some((item) => item.transformation.isLocked)
|
|
67884
|
+
});
|
|
67885
|
+
registerSelectionAction({
|
|
67886
|
+
id: "selection.unlock",
|
|
67887
|
+
label: "Unlock",
|
|
67888
|
+
icon: overlayAssetIcon("src/Overlay/icons/Unlock.icon.svg"),
|
|
67889
|
+
description: "Unlocks the selected items.",
|
|
67890
|
+
invoke: { kind: "selectionMethod", methodName: "unlock" },
|
|
67891
|
+
isAvailable: (items) => items.some((item) => item.transformation.isLocked)
|
|
67892
|
+
});
|
|
67893
|
+
registerSelectionAction({
|
|
67894
|
+
id: "selection.bringToFront",
|
|
67895
|
+
label: "Bring to front",
|
|
67896
|
+
icon: overlayAssetIcon("src/Overlay/icons/BringToFront.icon.svg"),
|
|
67897
|
+
description: "Moves the selection above overlapping items.",
|
|
67898
|
+
invoke: { kind: "selectionMethod", methodName: "bringToFront" },
|
|
67899
|
+
isAvailable: (items) => items.length > 0
|
|
67900
|
+
});
|
|
67901
|
+
registerSelectionAction({
|
|
67902
|
+
id: "selection.sendToBack",
|
|
67903
|
+
label: "Send to back",
|
|
67904
|
+
icon: overlayAssetIcon("src/Overlay/icons/SendToBack.icon.svg"),
|
|
67905
|
+
description: "Moves the selection behind overlapping items.",
|
|
67906
|
+
invoke: { kind: "selectionMethod", methodName: "sendToBack" },
|
|
67907
|
+
isAvailable: (items) => items.length > 0
|
|
67908
|
+
});
|
|
67909
|
+
registerSelectionAction({
|
|
67910
|
+
id: "selection.text.fontSize",
|
|
67911
|
+
label: "Font size",
|
|
67912
|
+
icon: styleFontSizeIcon(),
|
|
67913
|
+
invoke: { kind: "selectionMethod", methodName: "setFontSize" },
|
|
67914
|
+
controls: [
|
|
67915
|
+
{
|
|
67916
|
+
id: "fontSize",
|
|
67917
|
+
label: "Font size",
|
|
67918
|
+
valueSource: { kind: "selectionProperty", property: "getFontSize" },
|
|
67919
|
+
editor: {
|
|
67920
|
+
kind: "number-stepper",
|
|
67921
|
+
min: 8,
|
|
67922
|
+
max: 144,
|
|
67923
|
+
step: 1,
|
|
67924
|
+
presets: [12, 14, 16, 18, 24, 32, 48],
|
|
67925
|
+
unit: "px"
|
|
67926
|
+
},
|
|
67927
|
+
invoke: { kind: "selectionMethod", methodName: "setFontSize" }
|
|
67928
|
+
}
|
|
67929
|
+
],
|
|
67930
|
+
isAvailable: everyItemHasRichText
|
|
67931
|
+
});
|
|
67932
|
+
registerSelectionAction({
|
|
67933
|
+
id: "selection.text.color",
|
|
67934
|
+
label: "Text color",
|
|
67935
|
+
icon: styleColorIcon({
|
|
67936
|
+
swatch: { kind: "selectionProperty", property: "getFontColor" }
|
|
67937
|
+
}),
|
|
67938
|
+
invoke: { kind: "selectionMethod", methodName: "setFontColor" },
|
|
67939
|
+
controls: [
|
|
67940
|
+
{
|
|
67941
|
+
id: "fontColor",
|
|
67942
|
+
label: "Text color",
|
|
67943
|
+
valueSource: { kind: "selectionProperty", property: "getFontColor" },
|
|
67944
|
+
editor: {
|
|
67945
|
+
kind: "color",
|
|
67946
|
+
palette: ["#111111", "#FFFFFF", "#E11D48", "#2563EB", "#16A34A", "#F59E0B"]
|
|
67947
|
+
},
|
|
67948
|
+
invoke: { kind: "selectionMethod", methodName: "setFontColor" }
|
|
67949
|
+
}
|
|
67950
|
+
],
|
|
67951
|
+
isAvailable: everyItemHasRichText
|
|
67952
|
+
});
|
|
67953
|
+
registerSelectionAction({
|
|
67954
|
+
id: "selection.text.highlight",
|
|
67955
|
+
label: "Highlight",
|
|
67956
|
+
icon: {
|
|
67957
|
+
...overlayAssetIcon("src/Items/Screen/icons/Background.icon.svg"),
|
|
67958
|
+
state: { swatch: { kind: "selectionProperty", property: "getFontHighlight" } }
|
|
67959
|
+
},
|
|
67960
|
+
invoke: { kind: "selectionMethod", methodName: "setFontHighlight" },
|
|
67961
|
+
controls: [
|
|
67962
|
+
{
|
|
67963
|
+
id: "fontHighlight",
|
|
67964
|
+
label: "Highlight",
|
|
67965
|
+
valueSource: { kind: "selectionProperty", property: "getFontHighlight" },
|
|
67966
|
+
editor: {
|
|
67967
|
+
kind: "color",
|
|
67968
|
+
palette: ["transparent", "#FEF08A", "#FDBA74", "#BFDBFE", "#FBCFE8", "#D9F99D"]
|
|
67969
|
+
},
|
|
67970
|
+
invoke: { kind: "selectionMethod", methodName: "setFontHighlight" }
|
|
67971
|
+
}
|
|
67972
|
+
],
|
|
67973
|
+
isAvailable: everyItemHasRichText
|
|
67974
|
+
});
|
|
67975
|
+
|
|
67754
67976
|
// src/Selection/SelectionItems.ts
|
|
67755
67977
|
class SelectionItems {
|
|
67756
67978
|
items = new Map;
|
|
@@ -75737,6 +75959,7 @@ export {
|
|
|
75737
75959
|
overlaySymbolIcon,
|
|
75738
75960
|
overlayAssetIcon,
|
|
75739
75961
|
omitDefaultProperties,
|
|
75962
|
+
normalizeOverlayIconAssetPath,
|
|
75740
75963
|
messageRouter,
|
|
75741
75964
|
meetsWCAG_AAA,
|
|
75742
75965
|
meetsWCAG_AA,
|
|
@@ -75805,6 +76028,7 @@ export {
|
|
|
75805
76028
|
calculatePosition,
|
|
75806
76029
|
calculateAudioPosition,
|
|
75807
76030
|
borderWidths,
|
|
76031
|
+
WorkflowTool,
|
|
75808
76032
|
VideoItem,
|
|
75809
76033
|
Transformation,
|
|
75810
76034
|
Tools,
|
|
@@ -75837,6 +76061,7 @@ export {
|
|
|
75837
76061
|
PRESENCE_CLEANUP_IDLE_TIMER,
|
|
75838
76062
|
OVERLAY_SYMBOL_KEYS,
|
|
75839
76063
|
OVERLAY_ICON_SPRITE_PATH,
|
|
76064
|
+
OVERLAY_ICON_ASSET_PREFIX,
|
|
75840
76065
|
MiroItemConverter,
|
|
75841
76066
|
Mbr,
|
|
75842
76067
|
Matrix,
|