Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
quantum-blocks
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ui
quantum-blocks
Commits
ac5a9f7c
Commit
ac5a9f7c
authored
Oct 12, 2021
by
郭志伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(slider): 调整边距展示方式
parent
78ecb4ca
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
79 additions
and
68 deletions
+79
-68
index.ts
app/web/page/editor/component/DynamicForm/index.ts
+3
-3
index.vue
app/web/page/editor/component/DynamicForm/index.vue
+75
-64
index.vue
app/web/page/editor/component/OperationPanel/index.vue
+1
-1
No files found.
app/web/page/editor/component/DynamicForm/index.ts
View file @
ac5a9f7c
...
...
@@ -338,9 +338,9 @@ export default class DynamicForm extends Mixins(ContextMenuMixin, DynamicFormMix
const
ele
=
this
.
getCurElement
();
const
prevCommonStyle
=
cloneDeep
(
ele
.
commonStyle
||
{});
// this.point.w = this.point.w - (this.commonStyle.paddingLeft || 0) - (this.commonStyle.paddingRight || 0);
//
this.point.h = this.point.h - (prevCommonStyle.paddingTop || 0) - (prevCommonStyle.paddingBottom || 0) + (this.commonStyle.paddingTop || 0) + (this.commonStyle.paddingBottom || 0);
this
.
point
.
h
=
this
.
point
.
h
-
(
prevCommonStyle
.
paddingTop
||
0
)
-
(
prevCommonStyle
.
paddingBottom
||
0
)
+
(
this
.
commonStyle
.
paddingTop
||
0
)
+
(
this
.
commonStyle
.
paddingBottom
||
0
);
this
.
updateCommonStyle
({
containerIndex
:
this
.
curEleIndex
,
childIndex
:
this
.
curChildIndex
,
data
:
this
.
commonStyle
});
this
.
updatePoint
();
//
this.adjustHeight();
this
.
adjustHeight
();
}
}
app/web/page/editor/component/DynamicForm/index.vue
View file @
ac5a9f7c
...
...
@@ -49,7 +49,7 @@
<
InputNumber
:
max
=
"
667
"
:
min
=
"
0
"
v
-
model
=
"
point.h
"
@
on
-
change
=
"
updatePoint($event, 'h')
"
><
/InputNumber
>
<
/template
>
<
template
v
-
else
-
if
=
"
item.label.indexOf('边距') > -1
"
>
<
Slider
v
-
model
=
"
commonStyle[item.key]
"
@
on
-
change
=
"
changeMargin
"
/>
<
Slider
v
-
model
=
"
commonStyle[item.key]
"
@
on
-
input
=
"
changeMargin
"
/>
<
/template
>
<
upload
v
-
else
-
if
=
"
item.label === '背景图片'
"
v
-
model
=
"
commonStyle.backgroundImage
"
@
change
=
"
updateStyle($event, 'backgroundImage')
"
><
/upload
>
<
ColorSelector
v
-
else
-
if
=
"
item.label === '背景颜色'
"
v
-
model
=
"
commonStyle.backgroundColor
"
@
input
=
"
updateStyle($event, 'backgroundColor')
"
><
/ColorSelector
>
...
...
@@ -69,12 +69,14 @@
.
dynamic
-
form
{
padding
:
0
0
16
px
;
background
:
#
fff
;
&-
header
{
padding
:
10
px
0
5
px
;
border
-
bottom
:
8
px
solid
#
F5F6FA
;
border
-
bottom
:
8
px
solid
#
f5f6fa
;
text
-
align
:
center
;
div
{
color
:
#
A1A6B
3
;
color
:
#
a1a6b
3
;
padding
:
5
px
;
font
-
size
:
12
px
;
}
...
...
@@ -90,12 +92,15 @@
margin
-
bottom
:
10
px
;
border
-
bottom
:
1
px
solid
#
ebeef5
;
}
&-
component
{
padding
:
0
20
px
;
border
-
bottom
:
8
px
solid
#
F5F6FA
;
border
-
bottom
:
8
px
solid
#
f5f6fa
;
}
&-
basic
{
padding
:
0
20
px
;
.
Df
-
basic
-
inputnumber
{
margin
-
right
:
10
px
;
}
...
...
@@ -104,7 +109,9 @@
/deep/
.
ivu
-
form
-
item
{
display
:
flex
;
align
-
items
:
center
;
&
:
before
,
&
:
after
{
&
::
before
,
&
::
after
{
display
:
none
;
}
...
...
@@ -122,17 +129,21 @@
.
ivu
-
form
-
item
-
content
{
margin
-
left
:
0
!
important
;
flex
:
1
;
.
ivu
-
tooltip
{
margin
-
right
:
6
px
;
.
ivu
-
btn
-
ghost
{
padding
:
2
px
6
px
;
display
:
flex
;
align
-
items
:
center
;
justify
-
content
:
center
;
.
ivu
-
icon
{
font
-
size
:
20
px
;
}
}
&
:
last
-
child
{
.
ivu
-
icon
{
transform
:
rotate
(
90
deg
);
...
...
app/web/page/editor/component/OperationPanel/index.vue
View file @
ac5a9f7c
...
...
@@ -60,7 +60,7 @@
height: 100%;
top: 0;
left: 0;
z-index: 1;
z-index: 1
02
;
}
}
...
...
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