diff options
author | jim-p <jimp@pfsense.org> | 2016-03-09 16:25:57 -0500 |
---|---|---|
committer | jim-p <jimp@pfsense.org> | 2016-03-09 16:26:20 -0500 |
commit | 2e7fa7ca1b996254898ad8137f9299cb67806446 (patch) | |
tree | 066edbc429ca874e8a6eaa9a9f33f1789798c9fe /src | |
parent | da8a11340d83c76dc14d85b0326e1a81f9222c60 (diff) | |
download | pfsense-2e7fa7ca1b996254898ad8137f9299cb67806446.zip pfsense-2e7fa7ca1b996254898ad8137f9299cb67806446.tar.gz |
Fix some more stragglers for icon/button consistency. Ticket #5965
Diffstat (limited to 'src')
-rw-r--r-- | src/usr/local/www/diag_nanobsd.php | 50 | ||||
-rw-r--r-- | src/usr/local/www/interfaces.php | 36 | ||||
-rw-r--r-- | src/usr/local/www/services_captiveportal_vouchers.php | 2 | ||||
-rw-r--r-- | src/usr/local/www/status_captiveportal.php | 10 | ||||
-rw-r--r-- | src/usr/local/www/system_authservers.php | 6 |
5 files changed, 75 insertions, 29 deletions
diff --git a/src/usr/local/www/diag_nanobsd.php b/src/usr/local/www/diag_nanobsd.php index 0619837..8bf3c75 100644 --- a/src/usr/local/www/diag_nanobsd.php +++ b/src/usr/local/www/diag_nanobsd.php @@ -154,8 +154,13 @@ $section->addInput(new Form_StaticText( $NANOBSD_SIZE )); -$slicebtn = new Form_Button('bootslice', 'Switch Slice'); -$slicebtn->removeClass('btn-primary')->addClass('btn-default btn-sm'); +$slicebtn = new Form_Button( + 'bootslice', + 'Switch Slice', + null, + 'fa-retweet' +); +$slicebtn->addClass('btn-warning btn-sm'); $section->addInput(new Form_StaticText( 'Bootup slice', @@ -163,8 +168,9 @@ $section->addInput(new Form_StaticText( )); $refcount = refcount_read(1000); +$mounted_rw = is_writable("/"); -if (is_writable("/")) { +if ($mounted_rw) { /* refcount_read returns -1 when shared memory section does not exist */ /* refcount can be zero here when the user has set nanobsd_force_rw */ /* refcount 1 is normal, so only display the count for abnormal values */ @@ -182,9 +188,14 @@ if (is_writable("/")) { // Only show the changero button if force read/write is off, or the file system is not in writable state, or there is an unusual refcount. // If force read/write is on, and the file system is in writable state, and refcount is normal then the user has no reason to mess about. -if (!isset($config['system']['nanobsd_force_rw']) || !is_writable("/") || ($refcount > 1)) { - $robtn = new Form_Button('changero', $btnlbl); - $robtn->removeClass('btn-primary')->addClass('btn-default btn-sm'); +if (!isset($config['system']['nanobsd_force_rw']) || !$mounted_rw || ($refcount > 1)) { + $robtn = new Form_Button( + 'changero', + $btnlbl, + null, + ($mounted_rw) ? 'fa-lock' : 'fa-unlock' + ); + $robtn->addClass(($mounted_rw) ? 'btn-success' : 'btn-warning' . ' btn-sm'); $lbl .= ' ' . $robtn; } @@ -200,8 +211,13 @@ $section->addInput(new Form_Checkbox( isset($config['system']['nanobsd_force_rw']) )); -$permbtn = new Form_Button('setrw', 'Save'); -$permbtn->removeClass('btn-primary')->addClass('btn-default btn-sm'); +$permbtn = new Form_Button( + 'setrw', + 'Save', + null, + 'fa-save' +); +$permbtn->addClass('btn-primary btn-sm'); $section->addInput(new Form_StaticText( null, @@ -215,8 +231,13 @@ $section->addInput(new Form_Input( $COMPLETE_PATH )); -$dupbtn = new Form_Button('duplicateslice', 'Duplicate ' . $COMPLETE_BOOT_PATH . ' -> ' . $TOFLASH); -$dupbtn->removeClass('btn-primary')->addClass('btn-default btn-sm'); +$dupbtn = new Form_Button( + 'duplicateslice', + 'Duplicate ' . $COMPLETE_BOOT_PATH . ' -> ' . $TOFLASH, + null, + 'fa-clone' +); +$dupbtn->addClass('btn-success btn-sm'); $section->addInput(new Form_StaticText( 'Duplicate boot slice', @@ -229,8 +250,13 @@ $section->addInput(new Form_StaticText( )); if (file_exists("/conf/upgrade_log.txt")) { - $viewbtn = new Form_Button('viewupgradelog', 'View log'); - $viewbtn->removeClass('btn-primary')->addClass('btn-default btn-sm'); + $viewbtn = new Form_Button( + 'viewupgradelog', + 'View log', + null, + 'fa-file-text-o' + ); + $viewbtn->addClass('btn-primary btn-sm'); $section->addInput(new Form_StaticText( 'View previous upgrade log', diff --git a/src/usr/local/www/interfaces.php b/src/usr/local/www/interfaces.php index c07e398..8c6f563 100644 --- a/src/usr/local/www/interfaces.php +++ b/src/usr/local/www/interfaces.php @@ -1817,8 +1817,10 @@ $group->add(new Form_Select( $group->add(new Form_Button( 'addgw', - 'Add a new gateway' -))->removeClass('btn-primary')->setAttribute('data-target', '#newgateway')->setAttribute('data-toggle', 'modal'); + 'Add a new gateway', + null, + 'fa-plus' +))->addClass('btn-success')->setAttribute('data-target', '#newgateway')->setAttribute('data-toggle', 'modal'); $group->setHelp('If this interface is an Internet connection, select an existing Gateway from the list or add a new one using the "Add" button.' . '<br />' . 'On local LANs the upstream gateway should be "none".' . @@ -1848,8 +1850,10 @@ $group->add(new Form_Select( $group->add(new Form_Button( 'addgw6', - 'Add a new gateway' -))->removeClass('btn-primary')->setAttribute('data-target', '#newgateway6')->setAttribute('data-toggle', 'modal'); + 'Add a new gateway', + null, + 'fa-plus' +))->addClass('btn-success')->setAttribute('data-target', '#newgateway6')->setAttribute('data-toggle', 'modal'); $group->setHelp('If this interface is an Internet connection, select an existing Gateway from the list or add a new one using the "Add" button.' . '<br />' . 'On local LANs the upstream gateway should be "none". '); @@ -1888,17 +1892,21 @@ $modal->addInput(new Form_Input( $btnaddgw6 = new Form_Button( 'add6', - 'Add' + 'Add', + null, + 'fa-plus' ); -$btnaddgw6->removeClass('btn-primary')->addClass('btn-success'); +$btnaddgw6->addClass('btn-success'); $btncnxgw6 = new Form_Button( 'cnx6', - 'Cancel' + 'Cancel', + null, + 'fa-undo' ); -$btncnxgw6->removeClass('btn-primary')->addClass('btn-default'); +$btncnxgw6->addClass('btn-warning'); $modal->addInput(new Form_StaticText( null, @@ -3200,17 +3208,21 @@ $modal->addInput(new Form_Input( $btnaddgw = new Form_Button( 'add', - 'Add' + 'Add', + null, + 'fa-plus' ); -$btnaddgw->removeClass('btn-primary')->addClass('btn-success'); +$btnaddgw->addClass('btn-success'); $btncnxgw = new Form_Button( 'cnx', - 'Cancel' + 'Cancel', + null, + 'fa-undo' ); -$btncnxgw->removeClass('btn-primary')->addClass('btn-default'); +$btncnxgw->addClass('btn-warning'); $modal->addInput(new Form_StaticText( null, diff --git a/src/usr/local/www/services_captiveportal_vouchers.php b/src/usr/local/www/services_captiveportal_vouchers.php index 6f8ff5a..57eb862 100644 --- a/src/usr/local/www/services_captiveportal_vouchers.php +++ b/src/usr/local/www/services_captiveportal_vouchers.php @@ -674,7 +674,7 @@ events.push(function() { // Set initial state setShowHide($('#enable').is(":checked")); - var generateButton = $('<a class="btn btn-xs btn-default"><?=gettext("Generate new keys");?></a>'); + var generateButton = $('<a class="btn btn-xs btn-warning"><i class="fa fa-refresh icon-embed-btn"></i><?=gettext("Generate new keys");?></a>'); generateButton.on('click', function() { $.ajax({ type: 'get', diff --git a/src/usr/local/www/status_captiveportal.php b/src/usr/local/www/status_captiveportal.php index 905847e..79d8ed0 100644 --- a/src/usr/local/www/status_captiveportal.php +++ b/src/usr/local/www/status_captiveportal.php @@ -274,12 +274,18 @@ endif; if (!empty($cpzone)): if ($_GET['showact']): ?> <input type="hidden" name="showact" value="0" /> - <input type="submit" class="btn btn-default" value="<?=gettext("Don't show last activity")?>" /> + <button type="submit" class="btn btn-info" value="<?=gettext("Don't show last activity")?>"> + <i class="fa fa-minus-circle icon-embed-btn"></i> + <?=gettext("Hide Last Activity")?> + </button> <?php else: ?> <input type="hidden" name="showact" value="1" /> - <input type="submit" class="btn btn-default" value="<?=gettext("Show last activity")?>" /> + <button type="submit" class="btn btn-info" value="<?=gettext("Show last activity")?>"> + <i class="fa fa-plus-circle icon-embed-btn"></i> + <?=gettext("Show Last Activity")?> + </button> <?php endif; ?> diff --git a/src/usr/local/www/system_authservers.php b/src/usr/local/www/system_authservers.php index 9f113b0..7665455 100644 --- a/src/usr/local/www/system_authservers.php +++ b/src/usr/local/www/system_authservers.php @@ -571,8 +571,10 @@ $group->add(new Form_Input( $group->add(new Form_Button( 'Select', - 'Select a container' -))->removeClass('btn-primary')->addClass('btn-default'); + 'Select a container', + null, + 'fa-search' +))->addClass('btn-info'); $section->add($group); |