Plugin Directory

Changeset 949376


Ignore:
Timestamp:
07/16/2014 06:08:32 AM (12 years ago)
Author:
kushsharma
Message:

Improved UI

Location:
kush-micro-news/trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • kush-micro-news/trunk/assets/css/style.css

    r949304 r949376  
    106106
    107107/* ------------------------------------------Admin starts ----*/
    108 
    109 
    110 #micro-news .editB{
     108#micro-news-board .wrapNews{
     109    width:99%;
     110    padding:2px 2px 10px 2px;       
     111    min-height:50px;
     112    position:relative;
     113}
     114
     115#micro-news-board .wrapNews .title{
     116    color:#0066cc;
     117    font-size:15px;
     118    font-family:Myriad Pro, Trebuchet MS, Arial, Sans-Serif;
     119    margin-top: 0px;
     120    margin-bottom: 2px;
     121    display: inline-block;
     122}
     123
     124#micro-news-board .wrapNews .text{
     125    padding-bottom:10px;
     126    position: relative;
     127}
     128
     129
     130#micro-news-board .wrapNews .clean:hover{
     131    background-color:transparent;
     132}
     133
     134#micro-news-board .editB{
    111135    float:right;
    112136    width:50px;
     
    114138    top:0px;
    115139    right:25px;
    116 
    117 }
    118 
    119 #micro-news  .closeB{
    120     margin-top:1px;
     140}
     141
     142#micro-news-board .closeB{ 
    121143    color: #fff;   
    122144    cursor:pointer;
    123145    position:absolute;
    124146    top:0px;
    125     right:0px; 
    126     width:5px;
     147    right:0px;     
    127148    background: #21759b;   
     149    visibility: hidden;
    128150   
    129151    -moz-border-radius: 7px;
    130152    -webkit-border-radius: 7px;
    131153    border-radius: 7px;
     154
    132155    -moz-box-sizing: content-box;
    133156    -webkit-box-sizing: content-box;
     
    135158}
    136159
    137 #micro-news  .closeB:hover{
     160#micro-news-board .closeB:hover{
     161    -moz-border-radius: 4px;
    138162    -webkit-border-radius: 4px;
    139163    border-radius: 4px;
    140164}
    141165
    142 #mirco-news .container-admin-meta-link{
     166#mirco-news-board .container-admin-meta-link{
    143167    position: relative;
    144168}
     
    150174#update-micro-news .row{
    151175    width:100%;
    152     padding:5px;
    153    
     176    padding:5px;   
    154177}
    155178
    156179#update-micro-news .row label{
    157180    display:block;
     181
    158182}
    159183
    160184#update-micro-news input[type=text]{
    161185    width:400px;
     186    border: 2px solid black;
    162187}
    163188
    164189#update-micro-news textarea{
    165     width:400px;
    166     height:80px;
    167 }
    168 
    169 #add-micro-news label{
    170     display:block;
    171 }
    172 
    173 #add-micro-news input[type=text]{
    174     width:400px;
    175 }
    176 
    177 #add-micro-news textarea{
    178     width:400px;
    179     height:80px;
    180 }
    181 
    182 #add-micro-news .row {
    183     width:100%;
    184     padding:15px;
    185 }
    186 
    187 #add-micro-news input[type=submit]{
    188     width:100px;   
    189 }
    190 
     190    min-width:400px;
     191    min-height:80px;
     192    border: 2px solid black;
     193}
     194
     195/*pagination*/
    191196.micro-news-post-nav{
    192197    padding:2px;
     
    211216}
    212217
     218 /* - add new - */
     219
     220#add-micro-news .row {
     221    width:100%;
     222    padding:15px;
     223    margin-bottom: 5px;
     224    border-left: 3px solid #F25555;
     225}
     226
     227#add-micro-news label{
     228    display:block;
     229    font-size: 18px;   
     230}
     231
     232#add-micro-news input[type=text]{
     233    min-width:400px;
     234    border: 2px solid black;
     235}
     236
     237#add-micro-news textarea{
     238    min-width:400px;
     239    min-height:80px;
     240    border: 2px solid black;
     241}
     242
     243#add-micro-news input[type=submit]{
     244    width:100px;   
     245    padding: 5px;
     246}
     247
    213248/* - config - */
    214249#mirco-news-config .options {
    215250    padding: 5px;
     251
     252    margin-bottom: 5px;
     253    border-left: 3px solid #F25555;
    216254}
    217255#mirco-news-config .options label{
     
    219257    display: inline-block;
    220258}
    221 
    222 
    223 
    224259/* ----Admin ends ----*/
    225260
  • kush-micro-news/trunk/assets/js/script.js

    r949294 r949376  
    11jQuery(function ($) {
    22
    3     $(document).on('click','#micro-news .editB',function(){     
     3    $(document).on('click','#micro-news-board .editB',function(){       
    44               
    55        parent=$(this).parent();
     
    1515        fields +='<div class="row"><label for="nContent">Content:</label><textarea class="text-updated" name="nContent">'+content+'</textarea></div>';
    1616        fields +='<div class="row"><label for="nLink">Link:</label><input type="text" name="nLink" class="link-updated regular-text" value="'+link+'"/>';
    17         fields +='</div><input type="hidden" name="nId" value="'+id+'"/><div class="row"><input type="submit" class="submit-update"></div></form>';
     17        fields +='</div><input type="hidden" name="nId" value="'+id+'"/><div class="row"><input type="submit" class="button-primary submit-update"></div></form>';
    1818       
    1919       
     
    2626            parent.addClass('open');
    2727           
     28            $(this).attr('value','Update');
     29
    2830            //show cross sign
    29             //$("#micro-news .closeB").attr('visibility','visible');
    30 
    31             $(this).attr('value','Update');}
     31            $(parent).children(".closeB").css('visibility','visible'); 
     32            }       
    3233        else
    3334            {
    3435            //hide cross sign
    35             //$("#micro-news .closeB").attr('visibility','hidden');
     36            $(parent).children(".closeB").css('visibility','hidden');
    3637
     38            parent.removeClass('open');
     39            $(this).attr('value','edit');
    3740           
    3841            title=$('#update-micro-news .title-updated').val();
     
    5053                });
    5154               
    52                 $('#update-micro-news').remove();
    53                 parent.removeClass('open');
    54                 $(this).attr('value','edit');
    55             }
    56            
     55            $('#update-micro-news').remove();
     56               
     57            }           
    5758       
    5859    });
    5960   
    60     $(document).on('click','#micro-news .delB',function(){ 
     61    $(document).on('click','#micro-news-board .delB',function(){   
    6162        parent=$(this).parent();
    6263       
    6364        id=$(parent).attr('data-id');
    6465       
    65             $.ajax({
    66                     url:location.href,
    67                     cache:false,
    68                     type:"post",
    69                     data:{dId:id},
    70                     success:function(){
    71                         parent.hide('slow');
    72                     }
    73                 });
     66        $.ajax({
     67            url:location.href,
     68            cache:false,
     69            type:"post",
     70            data:{dId:id},
     71            success:function(){
     72                parent.hide('slow');
     73            }
     74        });
    7475   
    7576    });
    7677   
    77     $(document).on('click','#micro-news .closeB',function(){
     78    $(document).on('click','#micro-news-board .closeB',function(){
    7879
    7980        parent=$(this).parent();
     
    8182        id=$(parent).attr('data-id');
    8283   
    83         $('#micro-news .update-micro-news-'+id).remove();
     84        $('#micro-news-board .update-micro-news-'+id).remove();
    8485        parent.removeClass('open');
    8586       
    86         $("[data-id='mn-edit-"+id+"']").attr('value','edit');
     87        $("[data-id='mn-edit-"+id+"']").attr('value','Edit');
     88
     89        //hiding itself
     90        $(this).css('visibility','hidden');
    8791       
    8892    });
  • kush-micro-news/trunk/includes/admin.php

    r949294 r949376  
    109109        <div class="options">           
    110110            <label for="titleColor">Title Color:</label>
     111            <input type="text" name="titleColor" value="<?php echo get_option('kush_mn_color_title');?>" />
    111112            <select name="titleColorList" onclick="check_custom_color(this,'title')">
    112113                <option value="#0066CC">Light Blue [Default]</option>
     
    120121                <option value="#191970">Midnight Blue</option>             
    121122            </select>
    122             <input type="text" name="titleColor" value="<?php echo get_option('kush_mn_color_title');?>" />
    123123            <h5 style="display:inline-block;margin:0;">(Hexadecimal color values, like: #0066CC)</h5>
    124124        </div>
    125125        <div class="options">
    126126            <label for="textColor">Text Color:</label>
     127            <input type="text" name="textColor" value="<?php echo get_option('kush_mn_color_text');?>" />
    127128            <select name="textColorList" onclick="check_custom_color(this,'text')">
    128129                <option value="#666666">Grey [Default]</option>
     
    136137                <option value="#191970">Midnight Blue</option>             
    137138            </select>
    138             <input type="text" name="textColor" value="<?php echo get_option('kush_mn_color_text');?>" />
    139139        </div>
    140140        <div class="options">
  • kush-micro-news/trunk/includes/core.php

    r949304 r949376  
    118118    <?php if($what!=''){echo '<h3>'.$what.'</h3>';}?>
    119119   
    120         <div id="micro-news" class="clearfix widefat"> 
     120        <div id="micro-news-board" class="clearfix widefat">   
    121121        <?php $i=1;
    122122        foreach ( $rows as $row )
     
    125125            <div class="wrapNews" data-id="<?php echo $row->id;?>">
    126126                <span class="number"><?php echo $i;$i++;?>) </span>
    127                 <div class="title" id="mn-title-<?php echo $row->id;?>">
     127                <h2 class="title" id="mn-title-<?php echo $row->id;?>">
    128128                    <?php echo $row->name;?>
    129                 </div>
     129                </h2>
    130130               
    131131                <div class="text" id="mn-text-<?php echo $row->id;?>">
     
    134134                <div class="container-admin-meta-link">
    135135                    <span> <strong>on</strong> <?php $date=strtotime($row->time); echo date('d M Y',$date);?></span>
    136                     |               
     136                    |
    137137                    <strong>Reference Link : </strong><span id="mn-link-<?php echo $row->id;?>"><?php echo $row->url;?></a></span>
    138138                </div>
    139139                <input type="button" value="Edit" class="button-primary editB" data-id="mn-edit-<?php echo $row->id;?>"/>
     140                <input type="button" value="X" class="button-primary closeB" />
    140141                <input type="button" value="Delete" class="button-primary delB"/>
    141                 <span class="button-primary closeB">x</span>
    142142            </div> 
    143143            <hr>
  • kush-micro-news/trunk/index.php

    r949304 r949376  
    33Plugin Name: Kush Micro News
    44Description: Spread the news in shortest possible way. Use links to refer data and title to concise it.
    5 Version: 1.3.5
     5Version: 1.4.0
    66Author: Kush Sharma
    77Author Email: thekushsharma@gmail.com
  • kush-micro-news/trunk/readme.txt

    r949304 r949376  
    55Requires at least: 3.0.1
    66Tested up to: 3.9.1
    7 Stable tag: 1.3.5
     7Stable tag: 1.4.0
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    7676== Changelog ==
    7777
    78 = 1.3.5
     78= 1.4.0 =
     79* Improved UI of configuration page
     80
     81= 1.3.5 =
    7982* Misc bug fix.
    8083
Note: See TracChangeset for help on using the changeset viewer.