kritzel-stencil 0.0.112 → 0.0.113
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/kritzel-brush-style_18.cjs.entry.js +12 -10
- package/dist/cjs/kritzel-brush-style_18.cjs.entry.js.map +1 -1
- package/dist/collection/classes/handlers/key.handler.js +4 -1
- package/dist/collection/classes/handlers/key.handler.js.map +1 -1
- package/dist/collection/components/core/kritzel-editor/kritzel-editor.js +4 -4
- package/dist/collection/components/core/kritzel-editor/kritzel-editor.js.map +1 -1
- package/dist/collection/components/ui/kritzel-controls/kritzel-controls.js +4 -5
- package/dist/collection/components/ui/kritzel-controls/kritzel-controls.js.map +1 -1
- package/dist/components/kritzel-controls.js +1 -1
- package/dist/components/kritzel-editor.js +6 -6
- package/dist/components/kritzel-editor.js.map +1 -1
- package/dist/components/kritzel-engine.js +1 -1
- package/dist/components/{p-BnsTGnvc.js → p-CFwf2KYj.js} +6 -7
- package/dist/components/p-CFwf2KYj.js.map +1 -0
- package/dist/components/{p--2WHhuBI.js → p-DieKGjdj.js} +6 -3
- package/dist/components/{p--2WHhuBI.js.map → p-DieKGjdj.js.map} +1 -1
- package/dist/esm/kritzel-brush-style_18.entry.js +12 -10
- package/dist/esm/kritzel-brush-style_18.entry.js.map +1 -1
- package/dist/stencil/{p-65e86254.entry.js → p-dc26eb80.entry.js} +2 -2
- package/dist/stencil/p-dc26eb80.entry.js.map +1 -0
- package/dist/stencil/stencil.esm.js +1 -1
- package/dist/types/components/core/kritzel-editor/kritzel-editor.d.ts +1 -1
- package/package.json +1 -1
- package/dist/components/p-BnsTGnvc.js.map +0 -1
- package/dist/stencil/p-65e86254.entry.js.map +0 -1
|
@@ -1144,10 +1144,9 @@ const KritzelControls = class {
|
|
|
1144
1144
|
this.kritzelEngine.enable();
|
|
1145
1145
|
}
|
|
1146
1146
|
async closeTooltip() {
|
|
1147
|
-
var _a
|
|
1147
|
+
var _a;
|
|
1148
1148
|
this.tooltipVisible = false;
|
|
1149
1149
|
(_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.enable();
|
|
1150
|
-
(_b = this.kritzelEngine) === null || _b === void 0 ? void 0 : _b.setFocus();
|
|
1151
1150
|
}
|
|
1152
1151
|
get activeToolAsTextTool() {
|
|
1153
1152
|
var _a;
|
|
@@ -1208,13 +1207,13 @@ const KritzelControls = class {
|
|
|
1208
1207
|
render() {
|
|
1209
1208
|
var _a, _b;
|
|
1210
1209
|
const hasNoConfig = ((_a = this.activeControl) === null || _a === void 0 ? void 0 : _a.config) === undefined || ((_b = this.activeControl) === null || _b === void 0 ? void 0 : _b.config) === null;
|
|
1211
|
-
return (h(Host, { key: '
|
|
1210
|
+
return (h(Host, { key: 'c20b7cbc7228f1b13a7e17f7ea94c96151e11608', class: {
|
|
1212
1211
|
mobile: this.isTouchDevice,
|
|
1213
|
-
} }, h("kritzel-utility-panel", { key: '
|
|
1212
|
+
} }, h("kritzel-utility-panel", { key: '0e56c27c57d5cd7302ec80f6809fe4673afddae5', style: {
|
|
1214
1213
|
position: 'absolute',
|
|
1215
1214
|
bottom: '56px',
|
|
1216
1215
|
left: '12px',
|
|
1217
|
-
}, onUndo: () => { var _a; return (_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.undo(); }, onRedo: () => { var _a; return (_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.redo(); }, onDelete: () => { var _a; return (_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.delete(); } }), h("div", { key: '
|
|
1216
|
+
}, onUndo: () => { var _a; return (_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.undo(); }, onRedo: () => { var _a; return (_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.redo(); }, onDelete: () => { var _a; return (_a = this.kritzelEngine) === null || _a === void 0 ? void 0 : _a.delete(); } }), h("div", { key: '6454509e3c524a42345e383270e3c1220f87dab6', class: "kritzel-controls" }, this.controls.map(control => {
|
|
1218
1217
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1219
1218
|
if (control.type === 'tool') {
|
|
1220
1219
|
return (h("button", { class: {
|
|
@@ -2930,10 +2929,10 @@ const KritzelEditor = class {
|
|
|
2930
2929
|
event.preventDefault();
|
|
2931
2930
|
}
|
|
2932
2931
|
}
|
|
2933
|
-
handleKeyDown(
|
|
2932
|
+
handleKeyDown(event) {
|
|
2934
2933
|
var _a;
|
|
2935
|
-
|
|
2936
|
-
|
|
2934
|
+
if (event.key === 'Escape') {
|
|
2935
|
+
event.preventDefault();
|
|
2937
2936
|
(_a = this.controlsRef) === null || _a === void 0 ? void 0 : _a.closeTooltip();
|
|
2938
2937
|
}
|
|
2939
2938
|
}
|
|
@@ -2946,7 +2945,7 @@ const KritzelEditor = class {
|
|
|
2946
2945
|
}
|
|
2947
2946
|
}
|
|
2948
2947
|
render() {
|
|
2949
|
-
return (h(Host, { key: '
|
|
2948
|
+
return (h(Host, { key: '009fe43f85f368b2f60b31947596e1423f60e28d' }, h("kritzel-engine", { key: '76fa90e8c283723d546d02ab4eacc111047d6b9d', ref: el => (this.engineRef = el) }), h("kritzel-controls", { key: 'a7381534ab01236d12135f7a9f1a486c9b4be05a', ref: el => (this.controlsRef = el), controls: this.controls, style: this.hideControls ? { display: 'none' } : { display: 'flex' } })));
|
|
2950
2949
|
}
|
|
2951
2950
|
get host() { return getElement(this); }
|
|
2952
2951
|
};
|
|
@@ -3664,10 +3663,13 @@ class KritzelKeyHandler extends KritzelBaseHandler {
|
|
|
3664
3663
|
}
|
|
3665
3664
|
handleKeyDown(event) {
|
|
3666
3665
|
if (this._store.state.isFocused === false) {
|
|
3666
|
+
event.preventDefault();
|
|
3667
3667
|
return;
|
|
3668
3668
|
}
|
|
3669
|
-
event.preventDefault();
|
|
3670
3669
|
this._store.state.isCtrlKeyPressed = event.ctrlKey;
|
|
3670
|
+
if (this._store.state.isCtrlKeyPressed) {
|
|
3671
|
+
event.preventDefault();
|
|
3672
|
+
}
|
|
3671
3673
|
if (event.key === 'Escape' && this._store.state.selectionGroup) {
|
|
3672
3674
|
this._store.clearSelection();
|
|
3673
3675
|
}
|