Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Motion Bank
MB.js
Quasar Components MoSys
Commits
48d67ffa
Commit
48d67ffa
authored
Oct 16, 2019
by
christianrhansen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mobile: created touch resize handler for new cells (unfinished)
parent
3267ea1c
Pipeline
#16931
passed with stage
in 1 minute and 42 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
3 deletions
+37
-3
partials/GridEditor.vue
partials/GridEditor.vue
+37
-3
No files found.
partials/GridEditor.vue
View file @
48d67ffa
...
...
@@ -165,7 +165,8 @@
position="bottom-right")
//------------------------- buttons
.row.text-dark(style="background-color: rgba(0, 0, 0, .2);")
// .row.text-dark(style="background-color: rgba(0, 0, 0, .2);")
.row.text-dark(style="background-color: rgba(255, 150, 150, .3);")
//----- delete cell
.col
...
...
@@ -218,7 +219,10 @@
.text-center
q-btn.edit-cell-button(@click="mobileCellResize(mobileSelectedCell, 0, 1)", round, flat, size="md")
q-icon(name="add")
// --------------------------------------------------------------------------------------------------- test-button
div.test-button.fixed.q-pa-md.bg-dark.text-white(v-touch-pan="testButton", round, flat,
:style="{left: cursor.x - 20 + 'px', top: cursor.y - 20 + 'px'}")
q-icon.rotate-45(name="arrow_forward_ios")
</
template
>
<
script
>
...
...
@@ -273,7 +277,8 @@
mobileTempCell
:
{
x
:
0
,
y
:
0
,
width
:
1
,
height
:
1
,
show
:
false
,
onGrid
:
false
,
button
:
false
},
slide
:
undefined
,
modal
:
false
,
carousel
:
{
visibility
:
false
,
icon
:
'
open_with
'
,
slide
:
0
}
carousel
:
{
visibility
:
false
,
icon
:
'
open_with
'
,
slide
:
0
},
cursor
:
{
x
:
undefined
,
y
:
undefined
}
}
},
computed
:
{
...
...
@@ -371,6 +376,29 @@
}
},
methods
:
{
testButton
(
obj
)
{
this
.
cursor
=
{
x
:
obj
.
position
.
left
,
y
:
obj
.
position
.
top
}
// ---> panGrid
let
res
=
this
.
getGridPositionForEvent
(
obj
)
if
(
obj
.
isFirst
)
{
this
.
mobileTempCell
.
show
=
true
this
.
mobileTempCell
.
button
=
false
// this.mobileTempCell.x = res.x
// this.mobileTempCell.y = res.y
}
this
.
mobileTempCell
.
width
=
res
.
x
-
this
.
mobileTempCell
.
x
+
1
this
.
mobileTempCell
.
height
=
res
.
y
-
this
.
mobileTempCell
.
y
+
1
if
(
obj
.
isFinal
)
{
this
.
mobileTempCell
.
onGrid
=
true
this
.
mobileTempCell
.
button
=
true
// this.addMobileCell(obj)
// this.mobileTempCell.show = false
}
},
clearCachedCell
()
{
this
.
$store
.
commit
(
'
mosys/cacheNewCell
'
,
undefined
)
this
.
clearTempCell
()
...
...
@@ -1095,6 +1123,12 @@
.transition-opacity
transition opacity ease 350ms
.test-button
left 0
top 100px
width 40px
height 40px
border-radius 1000px
</
style
>
<
style
lang=
"stylus"
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment