Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
php
/
citic-mdrt
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
81dbcbb7
authored
Apr 20, 2020
by
doszhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dos
parent
abeb0139
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
40 additions
and
34 deletions
+40
-34
Public/static/js/common.js
+40
-34
No files found.
Public/static/js/common.js
View file @
81dbcbb7
...
...
@@ -123,43 +123,49 @@ function toUploadPage() {
}
function
initPage
()
{
const
headerHeight
=
313
;
const
logoHeight
=
parseFloat
(
$
(
'.logo'
).
css
(
'height'
));
const
inputHeight
=
parseFloat
(
$
(
'.input-wrapper'
).
css
(
'height'
));
const
transformTop
=
parseFloat
(
getTranslateDistance
());
let
inputBottomSpacing
;
let
spacing
=
(
headerHeight
-
transformTop
-
logoHeight
-
inputHeight
)
/
3
;
if
(
spacing
>
35
)
{
inputBottomSpacing
=
35
;
}
else
{
inputBottomSpacing
=
26.5
;
}
spacing
=
(
headerHeight
-
transformTop
-
logoHeight
-
inputHeight
-
inputBottomSpacing
)
/
2
;
$
(
'.logo'
).
css
(
'top'
,
transformTop
+
spacing
+
'px'
);
$
(
'.input-wrapper'
).
css
(
'top'
,
transformTop
+
(
spacing
*
2
+
logoHeight
)
+
'px'
);
const
bottomHeight
=
418
;
const
numHeight
=
parseFloat
(
$
(
'.num'
).
css
(
'height'
));
const
btnHeight
=
parseFloat
(
$
(
'.btn-go'
).
css
(
'height'
));
const
textHeight
=
parseFloat
(
$
(
'.bottom'
).
css
(
'height'
));
spacing
=
(
bottomHeight
-
numHeight
-
btnHeight
-
textHeight
-
transformTop
)
/
4
;
const
transformTop
=
getTranslateDistance
();
$
(
'.top'
).
css
(
'top'
,
transformTop
);
$
(
'.bottom'
).
css
({
top
:
'auto'
,
bottom
:
spacing
+
transformTop
+
'px'
});
bottom
:
transformTop
})
// const headerHeight = 313;
// const logoHeight = parseFloat($('.logo').css('height'));
// const inputHeight = parseFloat($('.input-wrapper').css('height'));
// const transformTop = parseFloat(getTranslateDistance());
// let inputBottomSpacing;
// let spacing = (headerHeight - transformTop - logoHeight - inputHeight) / 3;
// if (spacing > 35) {
// inputBottomSpacing = 35;
// } else {
// inputBottomSpacing = 26.5;
// }
// spacing = (headerHeight - transformTop - logoHeight - inputHeight - inputBottomSpacing) / 2;
// $('.logo').css('top', transformTop + spacing + 'px');
// $('.input-wrapper').css('top', transformTop + (spacing * 2 + logoHeight) + 'px');
// const bottomHeight = 418;
// const numHeight = parseFloat($('.num').css('height'));
// const btnHeight = parseFloat($('.btn-go').css('height'));
// const textHeight = parseFloat($('.bottom').css('height'));
// spacing = (bottomHeight - numHeight - btnHeight - textHeight - transformTop) / 4;
// $('.bottom').css({
// top: 'auto',
// bottom: spacing + transformTop + 'px'
// });
$
(
'.btn-go'
).
css
({
top
:
'auto'
,
bottom
:
spacing
*
2
+
textHeight
+
transformTop
+
'px'
});
$
(
'.num'
).
css
({
top
:
'auto'
,
bottom
:
spacing
*
3
+
textHeight
+
btnHeight
+
transformTop
+
'px'
});
//
$('.btn-go').css({
//
top: 'auto',
//
bottom: spacing * 2 + textHeight + transformTop + 'px'
//
});
//
$('.num').css({
//
top: 'auto',
//
bottom: spacing * 3 + textHeight + btnHeight + transformTop + 'px'
//
});
}
function
changePoster
()
{
...
...
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