changeset 6282:b52a66c5755f

style: replace action_button with Bootstrap compatible btn class names Based on work by Dominik Ruf.
author Mads Kiilerich <madski@unity3d.com>
date Thu, 20 Oct 2016 19:55:58 +0200
parents d4b39ef6cadf
children d27572fa323c
files kallithea/public/css/style.css kallithea/templates/admin/my_account/my_account_emails.html kallithea/templates/admin/permissions/permissions_ips.html kallithea/templates/admin/repo_groups/repo_group_edit_perms.html kallithea/templates/admin/repos/repo_edit_fields.html kallithea/templates/admin/repos/repo_edit_permissions.html kallithea/templates/admin/settings/settings_hooks.html kallithea/templates/admin/user_groups/user_group_edit_perms.html kallithea/templates/admin/users/user_edit_emails.html kallithea/templates/admin/users/user_edit_ips.html kallithea/templates/data_table/_dt_elements.html kallithea/templates/pullrequests/pullrequest_data.html
diffstat 12 files changed, 21 insertions(+), 32 deletions(-) [+]
line wrap: on
line diff
--- a/kallithea/public/css/style.css	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/public/css/style.css	Thu Oct 20 19:55:58 2016 +0200
@@ -2929,17 +2929,6 @@
     padding-bottom: 5px;
 }
 
-.action_button {
-    border: 0;
-    display: inline;
-}
-
-.action_button:hover {
-    border: 0;
-    text-decoration: underline;
-    cursor: pointer;
-}
-
 #switch_repos {
     position: absolute;
     height: 25px;
--- a/kallithea/templates/admin/my_account/my_account_emails.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/my_account/my_account_emails.html	Thu Oct 20 19:55:58 2016 +0200
@@ -21,7 +21,7 @@
                     ${h.hidden('del_email_id',em.email_id)}
                     <i class="icon-minus-circled" style="color:#FF4444"></i>
                     ${h.submit('remove_',_('Delete'),id="remove_email_%s" % em.email_id,
-                    class_="action_button", onclick="return  confirm('"+_('Confirm to delete this email: %s') % em.email+"');")}
+                    class_="btn btn-default btn-xs", onclick="return  confirm('"+_('Confirm to delete this email: %s') % em.email+"');")}
                 ${h.end_form()}
             </td>
           </tr>
--- a/kallithea/templates/admin/permissions/permissions_ips.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/permissions/permissions_ips.html	Thu Oct 20 19:55:58 2016 +0200
@@ -10,7 +10,7 @@
                     ${h.hidden('del_ip_id',ip.ip_id)}
                     ${h.hidden('default_user', 'True')}
                     <i class="icon-minus-circled" style="color:#FF4444"></i> ${h.submit('remove_',_('Delete'),id="remove_ip_%s" % ip.ip_id,
-                    class_="action_button", onclick="return confirm('"+_('Confirm to delete this IP address: %s') % ip.ip_addr+"');")}
+                    class_="btn btn-default btn-xs", onclick="return confirm('"+_('Confirm to delete this IP address: %s') % ip.ip_addr+"');")}
                 ${h.end_form()}
               </td>
           </tr>
--- a/kallithea/templates/admin/repo_groups/repo_group_edit_perms.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/repo_groups/repo_group_edit_perms.html	Thu Oct 20 19:55:58 2016 +0200
@@ -30,7 +30,7 @@
                         </td>
                         <td>
                           %if r2p.user.username !='default':
-                            <span style="color:#da4f49" class="action_button" onclick="ajaxActionRevoke(${r2p.user.user_id}, 'user', '${'id%s'%id(r2p.user.username)}', '${r2p.user.username}')">
+                            <span style="color:#da4f49" class="btn btn-default btn-xs" onclick="ajaxActionRevoke(${r2p.user.user_id}, 'user', '${'id%s'%id(r2p.user.username)}', '${r2p.user.username}')">
                              <i class="icon-minus-circled"></i> ${_('Revoke')}
                             </span>
                           %endif
@@ -67,7 +67,7 @@
                             %endif
                         </td>
                         <td>
-                            <span style="color:#da4f49" class="action_button" onclick="ajaxActionRevoke(${g2p.users_group.users_group_id}, 'user_group', '${'id%s'%id(g2p.users_group.users_group_name)}', '${g2p.users_group.users_group_name}')">
+                            <span style="color:#da4f49" class="btn btn-default btn-xs" onclick="ajaxActionRevoke(${g2p.users_group.users_group_id}, 'user_group', '${'id%s'%id(g2p.users_group.users_group_name)}', '${g2p.users_group.users_group_name}')">
                             <i class="icon-minus-circled"></i> ${_('Revoke')}
                             </span>
                         </td>
--- a/kallithea/templates/admin/repos/repo_edit_fields.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/repos/repo_edit_fields.html	Thu Oct 20 19:55:58 2016 +0200
@@ -16,7 +16,7 @@
               ${h.form(url('delete_repo_fields', repo_name=c.repo_info.repo_name, field_id=field.repo_field_id))}
                   <i class="icon-minus-circled" style="color:#FF4444"></i>
                   ${h.submit('remove_%s' % field.repo_field_id, _('Delete'), id="remove_field_%s" % field.repo_field_id,
-                  class_="action_button", onclick="return confirm('"+_('Confirm to delete this field: %s') % field.field_key+"');")}
+                  class_="btn btn-default btn-xs", onclick="return confirm('"+_('Confirm to delete this field: %s') % field.field_key+"');")}
               ${h.end_form()}
             </td>
         </tr>
--- a/kallithea/templates/admin/repos/repo_edit_permissions.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/repos/repo_edit_permissions.html	Thu Oct 20 19:55:58 2016 +0200
@@ -39,7 +39,7 @@
                         </td>
                         <td>
                           %if r2p.user.username !='default':
-                            <span style="color:#da4f49" class="action_button" onclick="ajaxActionRevoke(${r2p.user.user_id}, 'user', '${'id%s'%id(r2p.user.username)}', '${r2p.user.username}')">
+                            <span style="color:#da4f49" class="btn btn-default btn-xs" onclick="ajaxActionRevoke(${r2p.user.user_id}, 'user', '${'id%s'%id(r2p.user.username)}', '${r2p.user.username}')">
                             <i class="icon-minus-circled"></i> ${_('Revoke')}
                             </span>
                           %endif
@@ -64,7 +64,7 @@
                             %endif
                         </td>
                         <td>
-                            <span style="color:#da4f49" class="action_button" onclick="ajaxActionRevoke(${g2p.users_group.users_group_id}, 'user_group', '${'id%s'%id(g2p.users_group.users_group_name)}', '${g2p.users_group.users_group_name}')">
+                            <span style="color:#da4f49" class="btn btn-default btn-xs" onclick="ajaxActionRevoke(${g2p.users_group.users_group_id}, 'user_group', '${'id%s'%id(g2p.users_group.users_group_name)}', '${g2p.users_group.users_group_name}')">
                             <i class="icon-minus-circled"></i> ${_('Revoke')}
                             </span>
                         </td>
--- a/kallithea/templates/admin/settings/settings_hooks.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/settings/settings_hooks.html	Thu Oct 20 19:55:58 2016 +0200
@@ -30,7 +30,7 @@
             ${h.hidden('hook_ui_key',hook.ui_key)}
             ${h.hidden('hook_ui_value',hook.ui_value)}
             ${h.text('hook_ui_value_new',hook.ui_value,size=60)}
-            <span class="action_button"
+            <span class="btn btn-default btn-xs"
                 onclick="delete_hook(${hook.ui_id},'${'id%s' % hook.ui_id }')">
             <i class="icon-minus-circled" style="color:#FF4444"></i>
             ${_('Delete')}
--- a/kallithea/templates/admin/user_groups/user_group_edit_perms.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/user_groups/user_group_edit_perms.html	Thu Oct 20 19:55:58 2016 +0200
@@ -30,7 +30,7 @@
                         </td>
                         <td>
                           %if r2p.user.username !='default':
-                            <span style="color:#da4f49" class="action_button" onclick="ajaxActionRevoke(${r2p.user.user_id}, 'user', '${'id%s'%id(r2p.user.username)}', '${r2p.user.username}')">
+                            <span style="color:#da4f49" class="btn btn-default btn-xs" onclick="ajaxActionRevoke(${r2p.user.user_id}, 'user', '${'id%s'%id(r2p.user.username)}', '${r2p.user.username}')">
                              <i class="icon-minus-circled"></i> ${_('Revoke')}
                             </span>
                           %endif
@@ -67,7 +67,7 @@
                             %endif
                         </td>
                         <td>
-                            <span style="color:#da4f49" class="action_button" onclick="ajaxActionRevoke(${g2p.user_group.users_group_id}, 'user_group', '${'id%s'%id(g2p.user_group.users_group_name)}', '${g2p.user_group.users_group_name}')">
+                            <span style="color:#da4f49" class="btn btn-default btn-xs" onclick="ajaxActionRevoke(${g2p.user_group.users_group_id}, 'user_group', '${'id%s'%id(g2p.user_group.users_group_name)}', '${g2p.user_group.users_group_name}')">
                             <i class="icon-minus-circled"></i> ${_('Revoke')}
                             </span>
                         </td>
--- a/kallithea/templates/admin/users/user_edit_emails.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/users/user_edit_emails.html	Thu Oct 20 19:55:58 2016 +0200
@@ -21,7 +21,7 @@
                     ${h.hidden('del_email_id',em.email_id)}
                     <i class="icon-minus-circled" style="color:#FF4444"></i>
                     ${h.submit('remove_',_('Delete'),id="remove_email_%s" % em.email_id,
-                    class_="action_button", onclick="return  confirm('"+_('Confirm to delete this email: %s') % em.email+"');")}
+                    class_="btn btn-default btn-xs", onclick="return  confirm('"+_('Confirm to delete this email: %s') % em.email+"');")}
                 ${h.end_form()}
             </td>
           </tr>
--- a/kallithea/templates/admin/users/user_edit_ips.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/admin/users/user_edit_ips.html	Thu Oct 20 19:55:58 2016 +0200
@@ -20,7 +20,7 @@
                     ${h.hidden('del_ip_id',ip.ip_id)}
                     <i class="icon-minus-circled" style="color:#FF4444"></i>
                     ${h.submit('remove_',_('Delete'),id="remove_ip_%s" % ip.ip_id,
-                    class_="action_button", onclick="return  confirm('"+_('Confirm to delete this IP address: %s') % ip.ip_addr+"');")}
+                    class_="btn btn-default btn-xs", onclick="return  confirm('"+_('Confirm to delete this IP address: %s') % ip.ip_addr+"');")}
                 ${h.end_form()}
             </td>
           </tr>
--- a/kallithea/templates/data_table/_dt_elements.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/data_table/_dt_elements.html	Thu Oct 20 19:55:58 2016 +0200
@@ -120,13 +120,13 @@
   <div>
     <div style="float:left; margin-right:5px;" class="grid_edit">
       <a href="${h.url('edit_repo',repo_name=repo_name)}" title="${_('Edit')}">
-        <i class="icon-pencil"></i> ${h.submit('edit_%s' % repo_name,_('Edit'),class_="action_button")}
+        <i class="icon-pencil"></i> ${h.submit('edit_%s' % repo_name,_('Edit'),class_="btn btn-default btn-xs")}
       </a>
     </div>
     <div style="float:left" class="grid_delete">
       ${h.form(h.url('delete_repo', repo_name=repo_name))}
         <i class="icon-minus-circled" style="color:#FF4444"></i>
-        ${h.submit('remove_%s' % repo_name,_('Delete'),class_="action_button",
+        ${h.submit('remove_%s' % repo_name,_('Delete'),class_="btn btn-default btn-xs",
         onclick="return confirm('"+_('Confirm to delete this repository: %s') % repo_name+"');")}
       ${h.end_form()}
     </div>
@@ -148,13 +148,13 @@
 <%def name="user_actions(user_id, username)">
  <div style="float:left" class="grid_edit">
    <a href="${h.url('edit_user',id=user_id)}" title="${_('Edit')}">
-     <i class="icon-pencil"></i> ${h.submit('edit_%s' % username,_('Edit'),class_="action_button")}
+     <i class="icon-pencil"></i> ${h.submit('edit_%s' % username,_('Edit'),class_="btn btn-default btn-xs")}
    </a>
  </div>
  <div style="float:left" class="grid_delete">
   ${h.form(h.url('delete_user', id=user_id))}
     <i class="icon-minus-circled" style="color:#FF4444"></i>
-    ${h.submit('remove_',_('Delete'),id="remove_user_%s" % user_id, class_="action_button",
+    ${h.submit('remove_',_('Delete'),id="remove_user_%s" % user_id, class_="btn btn-default btn-xs",
     onclick="return confirm('"+_('Confirm to delete this user: %s') % username+"');")}
   ${h.end_form()}
  </div>
@@ -164,13 +164,13 @@
  <div style="float:left" class="grid_edit">
     <a href="${h.url('edit_users_group', id=user_group_id)}" title="${_('Edit')}">
     <i class="icon-pencil"></i>
-     ${h.submit('edit_%s' % user_group_name,_('Edit'),class_="action_button", id_="submit_user_group_edit")}
+     ${h.submit('edit_%s' % user_group_name,_('Edit'),class_="btn btn-default btn-xs", id_="submit_user_group_edit")}
     </a>
  </div>
  <div style="float:left" class="grid_delete">
     ${h.form(h.url('delete_users_group', id=user_group_id))}
       <i class="icon-minus-circled" style="color:#FF4444"></i>
-      ${h.submit('remove_',_('Delete'),id="remove_group_%s" % user_group_id, class_="action_button",
+      ${h.submit('remove_',_('Delete'),id="remove_group_%s" % user_group_id, class_="btn btn-default btn-xs",
       onclick="return confirm('"+_('Confirm to delete this user group: %s') % user_group_name+"');")}
     ${h.end_form()}
  </div>
@@ -180,13 +180,13 @@
  <div style="float:left" class="grid_edit">
     <a href="${h.url('edit_repo_group',group_name=repo_group_name)}" title="${_('Edit')}">
     <i class="icon-pencil"></i>
-     ${h.submit('edit_%s' % repo_group_name, _('Edit'),class_="action_button")}
+     ${h.submit('edit_%s' % repo_group_name, _('Edit'),class_="btn btn-default btn-xs")}
     </a>
  </div>
  <div style="float:left" class="grid_delete">
     ${h.form(h.url('delete_repos_group', group_name=repo_group_name))}
         <i class="icon-minus-circled" style="color:#FF4444"></i>
-        ${h.submit('remove_%s' % repo_group_name,_('Delete'),class_="action_button",
+        ${h.submit('remove_%s' % repo_group_name,_('Delete'),class_="btn btn-default btn-xs",
         onclick="return confirm('"+ungettext('Confirm to delete this group: %s with %s repository','Confirm to delete this group: %s with %s repositories',gr_count) % (repo_group_name, gr_count)+"');")}
     ${h.end_form()}
  </div>
--- a/kallithea/templates/pullrequests/pullrequest_data.html	Mon Oct 24 21:45:35 2016 +0200
+++ b/kallithea/templates/pullrequests/pullrequest_data.html	Thu Oct 20 19:55:58 2016 +0200
@@ -61,7 +61,7 @@
       <td style="text-align:right">
         %if pr.owner_id == c.authuser.user_id:
           ${h.form(url('pullrequest_delete', repo_name=pr.other_repo.repo_name, pull_request_id=pr.pull_request_id), style="display:inline-block")}
-          <button class="action_button"
+          <button class="btn btn-default btn-xs"
                   id="remove_${pr.pull_request_id}"
                   name="remove_${pr.pull_request_id}"
                   title="${_('Delete Pull Request')}"