Commit 83e693cd0da26d46b54540b3590feda70082386b
1 parent
9cd21642
add mobile style
Showing
5 changed files
with
104 additions
and
8 deletions
src/css/mobile.css
| 1 | +.m-title-wrap, .m-label { | |
| 2 | + display: none; } | |
| 3 | + | |
| 1 | 4 | @media screen and (max-width: 768px) { |
| 2 | - .player_volume_wrapper { | |
| 5 | + .player_volume_wrapper, .ladda-label { | |
| 3 | 6 | display: none !important; } |
| 7 | + .m-label { | |
| 8 | + display: block; } | |
| 4 | 9 | #componentWrapper .player_mediaTime_total { |
| 5 | 10 | border-right: none; } |
| 6 | 11 | #componentWrapper .progress_bg { |
| ... | ... | @@ -13,10 +18,12 @@ |
| 13 | 18 | .m-title-wrap { |
| 14 | 19 | width: 100%; |
| 15 | 20 | height: 36px; |
| 16 | - background-color: red; | |
| 21 | + line-height: 36px; | |
| 22 | + background-color: #FFF; | |
| 17 | 23 | display: flex; |
| 18 | 24 | justify-content: space-between; |
| 19 | - padding: 0 24px; } | |
| 25 | + padding: 0 24px; | |
| 26 | + border-bottom: 1px solid #eee; } | |
| 20 | 27 | .CodeMirror-gutter { |
| 21 | 28 | width: 24px !important; |
| 22 | 29 | min-width: 24px !important; } |
| ... | ... | @@ -46,4 +53,26 @@ |
| 46 | 53 | #playFooter { |
| 47 | 54 | height: 40px; |
| 48 | 55 | background-color: rgba(0, 0, 0, 0.5); |
| 49 | - padding: 0px 24px; } } | |
| 56 | + padding: 0px 24px; } | |
| 57 | + .console-wrap #toolbar .func { | |
| 58 | + height: 56px; | |
| 59 | + padding-top: 0; | |
| 60 | + position: absolute; | |
| 61 | + right: 16px; | |
| 62 | + bottom: 54px; | |
| 63 | + z-index: 9999; } | |
| 64 | + #full-screen { | |
| 65 | + display: none; } | |
| 66 | + .compile-btn { | |
| 67 | + padding: 0; | |
| 68 | + height: 56px; | |
| 69 | + width: 56px; | |
| 70 | + border-radius: 50%; | |
| 71 | + color: #FFF; | |
| 72 | + background-image: -webkit-linear-gradient(left, #1FB6FF 0%, #62DCF5 100%); | |
| 73 | + background-image: linear-gradient(to right, #1FB6FF 0%, #62DCF5 100%); } | |
| 74 | + .m-menu { | |
| 75 | + color: #1FB6FF; } | |
| 76 | + .m-menu img { | |
| 77 | + width: 16px; | |
| 78 | + vertical-align: middle; } } | ... | ... |
src/img/down.png
0 → 100644
2.85 KB
src/js/player.js
| ... | ... | @@ -4,6 +4,7 @@ $(function(){ |
| 4 | 4 | var _role = getQuery('role'); |
| 5 | 5 | var _codeReplayId = getQuery('codeReplayId'); |
| 6 | 6 | var player = $.AudioPlayer; |
| 7 | + var status = true; | |
| 7 | 8 | |
| 8 | 9 | var languageName = Dir.getLangName(_languageid); |
| 9 | 10 | $("title").html(languageName); |
| ... | ... | @@ -32,4 +33,16 @@ $(function(){ |
| 32 | 33 | CodingEditer.editable(0) |
| 33 | 34 | }) |
| 34 | 35 | |
| 36 | + $('.m-menu').on('click', function(){ | |
| 37 | + | |
| 38 | + if (status) { | |
| 39 | + $('.m-dir-wrap').show(); | |
| 40 | + status = false; | |
| 41 | + }else{ | |
| 42 | + $('.m-dir-wrap').hide(); | |
| 43 | + status = true; | |
| 44 | + } | |
| 45 | + | |
| 46 | + }) | |
| 47 | + | |
| 35 | 48 | }) |
| 36 | 49 | \ No newline at end of file | ... | ... |
src/scss/mobile.scss
| 1 | +.m-title-wrap, .m-label{ | |
| 2 | + display: none; | |
| 3 | +} | |
| 1 | 4 | @media screen and (max-width: 768px) { |
| 2 | - .player_volume_wrapper{ | |
| 5 | + | |
| 6 | + .player_volume_wrapper, .ladda-label{ | |
| 3 | 7 | display: none !important; |
| 4 | 8 | } |
| 9 | + .m-label{ | |
| 10 | + display: block; | |
| 11 | + } | |
| 5 | 12 | #componentWrapper .player_mediaTime_total{ |
| 6 | 13 | border-right: none; |
| 7 | 14 | } |
| ... | ... | @@ -18,10 +25,12 @@ |
| 18 | 25 | .m-title-wrap{ |
| 19 | 26 | width: 100%; |
| 20 | 27 | height: 36px; |
| 21 | - background-color: red; | |
| 28 | + line-height: 36px; | |
| 29 | + background-color: #FFF; | |
| 22 | 30 | display: flex; |
| 23 | 31 | justify-content: space-between; |
| 24 | 32 | padding: 0 24px; |
| 33 | + border-bottom: 1px solid #eee; | |
| 25 | 34 | } |
| 26 | 35 | .CodeMirror-gutter { |
| 27 | 36 | width: 24px !important; |
| ... | ... | @@ -63,4 +72,45 @@ |
| 63 | 72 | background-color: rgba(0,0,0,0.5); |
| 64 | 73 | padding: 0px 24px; |
| 65 | 74 | } |
| 66 | -} | |
| 67 | 75 | \ No newline at end of file |
| 76 | + | |
| 77 | + .console-wrap #toolbar .func { | |
| 78 | + height: 56px; | |
| 79 | + padding-top: 0; | |
| 80 | + position: absolute; | |
| 81 | + right: 16px; | |
| 82 | + bottom: 54px; | |
| 83 | + z-index: 9999; | |
| 84 | + } | |
| 85 | + #full-screen{ | |
| 86 | + display: none; | |
| 87 | + } | |
| 88 | + .compile-btn{ | |
| 89 | + padding: 0; | |
| 90 | + height: 56px; | |
| 91 | + width: 56px; | |
| 92 | + border-radius: 50%; | |
| 93 | + color: #FFF; | |
| 94 | + background-image: -webkit-linear-gradient(left, #1FB6FF 0%, #62DCF5 100%); | |
| 95 | + background-image: linear-gradient(to right, #1FB6FF 0%, #62DCF5 100%); | |
| 96 | + } | |
| 97 | + | |
| 98 | + .m-menu{ | |
| 99 | + color: #1FB6FF; | |
| 100 | + img{ | |
| 101 | + width: 16px; | |
| 102 | + vertical-align: middle; | |
| 103 | + } | |
| 104 | + } | |
| 105 | + | |
| 106 | + // .ladda-button[data-style=expand-right] .ladda-spinner{ | |
| 107 | + // right: 14px !important; | |
| 108 | + // top: 14px !important; | |
| 109 | + // } | |
| 110 | + | |
| 111 | + | |
| 112 | +} | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | ... | ... |
src/v1.1/player.html
| ... | ... | @@ -59,7 +59,7 @@ |
| 59 | 59 | </div> |
| 60 | 60 | <div class="m-title-wrap"> |
| 61 | 61 | <div class="m-title">创业公司融资的基本流程?创业...</div> |
| 62 | - <div class="m-menu">mainV</div> | |
| 62 | + <div class="m-menu">main <img src="../img/down.png" alt=""></div> | |
| 63 | 63 | </div> |
| 64 | 64 | <!-- 录制区 --> |
| 65 | 65 | <div class="record-wrap"> |
| ... | ... | @@ -91,6 +91,10 @@ |
| 91 | 91 | <div class="pull-right func"> |
| 92 | 92 | <button class="btn compile-btn" id="CompileBtn"> |
| 93 | 93 | <span class="ladda-label">编译运行</span> |
| 94 | + <span class="m-label"> | |
| 95 | + <p>编译</p> | |
| 96 | + <p>运行</p> | |
| 97 | + </span> | |
| 94 | 98 | </button> |
| 95 | 99 | <!-- <img src="../img/full-screen-icon.svg" alt=""> --> |
| 96 | 100 | <a id="full-screen" class="fb"> | ... | ... |