fix_new_and_upload_button_html_css

This commit is contained in:
Jörn Friedrich Dreyer 2012-11-06 12:20:57 +01:00
parent 75367f91e0
commit 76395057d4
2 changed files with 27 additions and 12 deletions

View file

@ -13,7 +13,7 @@
.file_upload_wrapper { font-weight:bold; display:-moz-inline-box; /* fallback for older firefox versions*/ display:block; float:left; padding-left:0; overflow:hidden; position:relative; margin:0; margin-left:2px; } .file_upload_wrapper { font-weight:bold; display:-moz-inline-box; /* fallback for older firefox versions*/ display:block; float:left; padding-left:0; overflow:hidden; position:relative; margin:0; margin-left:2px; }
.file_upload_wrapper .file_upload_button_wrapper { position:absolute; top:0; left:0; width:100%; height:100%; cursor:pointer; z-index:1000; } .file_upload_wrapper .file_upload_button_wrapper { position:absolute; top:0; left:0; width:100%; height:100%; cursor:pointer; z-index:1000; }
#new { background-color:#5bb75b; float:left; margin:0 0 0 1em; border-right:none; z-index:1010; height:1.3em; } #new { background-color:#5bb75b; float:left; margin:0 0 0 1em; border-right:none; z-index:1010; height:1.3em; }
#new:hover, a.file_upload_button_wrapper:hover + button.file_upload_filename { background-color:#4b964b; } #new:hover, #upload:hover, a.file_upload_button_wrapper:hover + button.file_upload_filename { background-color:#4b964b; }
#new.active { border-bottom-left-radius:0; border-bottom-right-radius:0; border-bottom:none; } #new.active { border-bottom-left-radius:0; border-bottom-right-radius:0; border-bottom:none; }
#new>a { padding:.5em 1.2em .3em; color:#fff; text-shadow:0 1px 0 #51a351; } #new>a { padding:.5em 1.2em .3em; color:#fff; text-shadow:0 1px 0 #51a351; }
#new>ul { display:none; position:fixed; text-align:left; padding:.5em; background:#f8f8f8; margin-top:0.075em; border:1px solid #ddd; min-width:7em; margin-left:-.5em; z-index:-1; } #new>ul { display:none; position:fixed; text-align:left; padding:.5em; background:#f8f8f8; margin-top:0.075em; border:1px solid #ddd; min-width:7em; margin-left:-.5em; z-index:-1; }
@ -22,6 +22,19 @@
#new>ul>li>input { padding:0.3em; margin:-0.3em; } #new>ul>li>input { padding:0.3em; margin:-0.3em; }
#new, .file_upload_filename { border:1px solid; border-color:#51a351 #419341 #387038; -moz-box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset; -webkit-box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset; box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset; } #new, .file_upload_filename { border:1px solid; border-color:#51a351 #419341 #387038; -moz-box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset; -webkit-box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset; box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset; }
#new .popup { border-top-left-radius:0; z-index:10; } #new .popup { border-top-left-radius:0; z-index:10; }
#upload { background-image: url('%webroot%/core/img/actions/upload-white.svg');
background-repeat: no-repeat;
background-position: 1em 6px;
padding:.4em 1.2em .4em 2.5em;
color:#fff;
text-shadow:0 1px 0 #51a351;
border-color:#51a351 #419341 #387038;
-moz-box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset;
-webkit-box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset;
box-shadow:0 1px 1px #f8f8f8, 1px 1px 1px #ada inset;
background-color:#5bb75b;
margin-left:0.2em;
height:1.3em; }
#file_newfolder_name { background-image:url('%webroot%/core/img/places/folder.svg'); font-weight:normal; width:7em; } #file_newfolder_name { background-image:url('%webroot%/core/img/places/folder.svg'); font-weight:normal; width:7em; }
.file_upload_start, .file_upload_filename { font-size:1em; } .file_upload_start, .file_upload_filename { font-size:1em; }
@ -31,10 +44,10 @@
.file_upload_start { -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)"; filter:alpha(opacity=0); opacity:0; z-index:1; position:absolute; left:0; top:0; width:100%; cursor:pointer;} .file_upload_start { -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)"; filter:alpha(opacity=0); opacity:0; z-index:1; position:absolute; left:0; top:0; width:100%; cursor:pointer;}
.file_upload_filename { background-color:#5bb75b; z-index:100; cursor:pointer; background-image: url('%webroot%/core/img/actions/upload-white.svg'); background-repeat: no-repeat; background-position: center; height: 2.29em; width: 2.5em; } .file_upload_filename { background-color:#5bb75b; z-index:100; cursor:pointer; background-image: url('%webroot%/core/img/actions/upload-white.svg'); background-repeat: no-repeat; background-position: center; height: 2.29em; width: 2.5em; }
#upload { position:absolute; right:13.5em; top:0em; } #uploadprogresswrappwer { position:absolute; right:13.5em; top:0em; }
#upload #uploadprogressbar { position:relative; display:inline-block; width:10em; height:1.5em; top:.4em; } #uploadprogresswrappwer #uploadprogressbar { position:relative; display:inline-block; width:10em; height:1.5em; top:.4em; }
.file_upload_form, .file_upload_wrapper, .file_upload_start, .file_upload_filename, #file_upload_submit { cursor:pointer; } .file_upload_form, .file_upload_wrapper, .file_upload_start, .file_upload_filename, #file_upload_submit { cursor:pointer; overflow: visible; }
/* FILE TABLE */ /* FILE TABLE */
#emptyfolder { position:absolute; margin:10em 0 0 10em; font-size:1.5em; font-weight:bold; color:#888; text-shadow:#fff 0 1px 0; } #emptyfolder { position:absolute; margin:10em 0 0 10em; font-size:1.5em; font-weight:bold; color:#888; text-shadow:#fff 0 1px 0; }

View file

@ -3,7 +3,7 @@
<?php echo($_['breadcrumb']); ?> <?php echo($_['breadcrumb']); ?>
<?php if ($_['isCreatable']):?> <?php if ($_['isCreatable']):?>
<div class="actions <?php if (isset($_['files']) and count($_['files'])==0):?>emptyfolder<?php endif; ?>"> <div class="actions <?php if (isset($_['files']) and count($_['files'])==0):?>emptyfolder<?php endif; ?>">
<div id='new' class='button'> <div id="new" class="button">
<a><?php echo $l->t('New');?></a> <a><?php echo $l->t('New');?></a>
<ul class="popup popupTop"> <ul class="popup popupTop">
<li style="background-image:url('<?php echo OCP\mimetype_icon('text/plain') ?>')" <li style="background-image:url('<?php echo OCP\mimetype_icon('text/plain') ?>')"
@ -30,19 +30,21 @@
<input type="hidden" class="max_human_file_size" <input type="hidden" class="max_human_file_size"
value="(max <?php echo $_['uploadMaxHumanFilesize']; ?>)"> value="(max <?php echo $_['uploadMaxHumanFilesize']; ?>)">
<input type="hidden" name="dir" value="<?php echo $_['dir'] ?>" id="dir"> <input type="hidden" name="dir" value="<?php echo $_['dir'] ?>" id="dir">
<a id="upload" class="button"></a>
<input class="file_upload_start" type="file" name='files[]'/> <input class="file_upload_start" type="file" name='files[]'/>
<a href="#" class="file_upload_button_wrapper" onclick="return false;" <a href="#" class="file_upload_button_wrapper" onclick="return false;"
title="<?php echo $l->t('Upload'); echo ' max. '.$_['uploadMaxHumanFilesize'] ?>"></a> title="<?php echo $l->t('Upload'); echo ' max. '.$_['uploadMaxHumanFilesize'] ?>"></a>
<button class="file_upload_filename"></button>
<iframe name="file_upload_target_1" class='file_upload_target' src=""></iframe> <iframe name="file_upload_target_1" class='file_upload_target' src=""></iframe>
</form> </form>
</div> </div>
<div id="upload"> <div id="upload">
<div id="uploadprogressbar"></div> <div id="uploadprogressbar"></div>
<input type="button" class="stop" style="display:none" <input type="button" class="stop" style="display:none"
value="<?php echo $l->t('Cancel upload');?>" value="<?php echo $l->t('Cancel upload');?>"
onclick="javascript:Files.cancelUploads();" /> onclick="javascript:Files.cancelUploads();"
</div> />
</div>
</div> </div>
<div id="file_action_panel"></div> <div id="file_action_panel"></div>