touch (tablet): fix deselect when tapping space; add edit text button

This commit is contained in:
Lukas F. Hartmann
2020-12-18 17:07:32 +01:00
parent 16e926b76a
commit 82515e3a8e
5 changed files with 46 additions and 38 deletions

View File

@@ -322,6 +322,7 @@
"follow_present": "Follow",
"mute_present": "Unfollow",
"follow_present_help": "If someone else is presenting this Space, the other members automatically follow the presentation. Switch following on or off with this button.",
"export": "export",
"media": "Media"
"export": "Export",
"media": "Media",
"tool_edit_text": "Edit Text"
}

View File

@@ -1923,10 +1923,7 @@ var SpacedeckSections = {
}.bind(this));
},
delayed_edit_artifact: function(evt) {
evt.stopPropagation();
evt.preventDefault();
delayed_edit_artifact: function() {
var a = this.selected_artifacts()[0];
var el = $("#ios-focuser-"+a._id);
@@ -2087,8 +2084,6 @@ var SpacedeckSections = {
if (a.description!=dom.innerHTML) {
a.description = dom.innerHTML;
console.log("new DOM:",dom.innerHTML);
this.update_board_artifact_viewmodel(a);
this.queue_artifact_for_save(a);

View File

@@ -285,6 +285,7 @@ function setup_whiteboard_directives() {
$scope.start_adding_placeholder(evt);
return;
} else if ($scope.active_tool=="pan") {
this.deselect();
this.start_pan(evt);
return;
}

View File

@@ -85,13 +85,13 @@
v-bind:class="{text-editing:(editing_artifact_id==a._id && (a.view.major_type=='text' || a.view.major_type=='shape'))}"
id="artifact-{{a._id}}">
<div v-if="a.view && a.view.major_type" style="height:100%; width:100%" v-bind:title="(a.editor_name || (a.user && a.user.nickname) || '')">
<span v-if="a.locked && is_selected(a)" class="link-wrapper">
<span class="btn btn-sm btn-icon btn-round btn-primary">
<span class="icon icon-lock-closed"></span>
</span>
</span>
<!-- text -->
<div v-if="a.view.major_type == 'text'" class="text" v-bind:style="a.view.inner_style">
<div class="text-table">

View File

@@ -97,6 +97,17 @@
<button class="btn btn-divider"></button>
<div class="dropdown bottom light center">
<div class="btn-collapse" v-bind:class="{in:selection_metrics.contains_text}">
<button
class="btn btn-icon-labeled btn-transparent"
v-on:click="delayed_edit_artifact()">
<span class="icon icon-pencil"></span>
<span class="icon-label"><%=__("tool_edit_text")%></span>
</button>
</div>
</div>
<div class="dropdown top light right" v-bind:class="{open:opened_dialog=='object-options'}">
<button class="btn btn-transparent btn-icon-labeled" v-on:click="open_dialog('object-options')" v-bind:class="{open : opened_dialog=='object-options'}">
<span class="icon icon-cogwheel"></span>