diff options
author | fligtar@gmail.com <fligtar@gmail.com@4eb1ac78-321c-0410-a911-ec516a8615a5> | 2008-12-09 02:00:52 (GMT) |
---|---|---|
committer | fligtar@gmail.com <fligtar@gmail.com@4eb1ac78-321c-0410-a911-ec516a8615a5> | 2008-12-09 02:00:52 (GMT) |
commit | 8de929665c7d90b943583b2de27ad6aa212843da (patch) | |
tree | ee6116343d61cbea0f524843c3019f10c31859db | |
parent | 08792837c8a12ff7912284999ea5df169b32af19 (diff) |
compat dashboard updates for testing
git-svn-id: http://svn.mozilla.org/addons/trunk@20590 4eb1ac78-321c-0410-a911-ec516a8615a5
-rw-r--r-- | site/app/controllers/compatibility_controller.php | 73 | ||||
-rw-r--r-- | site/app/controllers/components/versioncompare.php | 68 | ||||
-rw-r--r-- | site/app/views/compatibility/dashboard.thtml | 62 | ||||
-rw-r--r-- | site/app/views/compatibility/developers.thtml | 73 | ||||
-rw-r--r-- | site/app/views/compatibility/users.thtml | 42 | ||||
-rw-r--r-- | site/app/views/elements/compatibility/developer_tips.thtml | 44 | ||||
-rw-r--r-- | site/app/views/elements/compatibility/user_tips.thtml | 44 | ||||
-rw-r--r-- | site/app/webroot/css/compatibility.css | 82 | ||||
-rw-r--r-- | site/app/webroot/img/mdc-logo.png | bin | 0 -> 6116 bytes | |||
-rw-r--r-- | site/app/webroot/js/compatibility.js | 26 |
10 files changed, 476 insertions, 38 deletions
diff --git a/site/app/controllers/compatibility_controller.php b/site/app/controllers/compatibility_controller.php index 81c6648..b36d940 100644 --- a/site/app/controllers/compatibility_controller.php +++ b/site/app/controllers/compatibility_controller.php @@ -35,10 +35,6 @@ * the terms of any one of the MPL, the GPL or the LGPL. * * ***** END LICENSE BLOCK ***** */ -define('COMPAT_LATEST', 'latest'); -define('COMPAT_BETA', 'beta'); -define('COMPAT_ALPHA', 'alpha'); -define('COMPAT_OTHER', 'other'); /** This controller requires the bin/compatibility_report.php script to be @@ -54,7 +50,7 @@ define('COMPAT_OTHER', 'other'); class CompatibilityController extends AppController { var $name = 'Compatibility'; - var $uses = array('Appversion'); + var $uses = array('Addon', 'Appversion'); var $components = array('Amo','Versioncompare'); /** @@ -68,7 +64,7 @@ class CompatibilityController extends AppController $this->cssAdd = array('compatibility'); $this->publish('cssAdd', $this->cssAdd); - $this->jsAdd = array('jquery-ui/jquery.dimensions.min.js', 'jquery-ui/effects.core.min.js', 'jquery-ui/effects.slide.min.js', 'compatibility.js'); + $this->jsAdd = array('compatibility.js'); $this->publish('jsAdd', $this->jsAdd); $this->layout = 'mozilla'; @@ -95,6 +91,9 @@ class CompatibilityController extends AppController $this->publish('totals', $data['totals']); $this->publish('version', $version); + + $session = $this->Session->read('User'); + $this->publish('loggedin', !empty($session)); $this->render('dashboard'); } @@ -119,6 +118,68 @@ class CompatibilityController extends AppController else $this->render('report', 'mozilla'); } + + function developers($version = COMPAT_DEFAULT_VERSION, $format = 'html') { + global $compatibility_versions; + if (!in_array($version, $compatibility_versions)) $version = COMPAT_DEFAULT_VERSION; + $session = $this->Session->read('User'); + + if (!empty($session)) { + $addon_ids = $this->Addon->getAddonsByUser($session['id']); + $addons = array(); + + if (!empty($addon_ids)) { + $relatedVersions = $this->Appversion->getRelatedVersions($version); + $appversions = $this->Versioncompare->getCompatibilityGrades($version, $relatedVersions[APP_FIREFOX]); + + foreach ($addon_ids as $addon_id => $addon_name) { + $stats = $this->Addon->query("SELECT date, count, application FROM update_counts WHERE addon_id = {$addon_id} ORDER BY date DESC LIMIT 1"); + $updatepings = unserialize($stats[0]['update_counts']['application']); + + $addons[$addon_id] = array( + 'name' => $addon_name, + 'totalCount' => $stats[0]['update_counts']['count'], + 'date' => $stats[0]['update_counts']['date'], + 'versionCount' => 0 + ); + + // Tally active users of clients using the specified version + if (!empty($updatepings['{ec8030f7-c20a-464f-9b0e-13a3a9e97384}'])) { + foreach ($updatepings['{ec8030f7-c20a-464f-9b0e-13a3a9e97384}'] as $appversion => $count) { + if (strpos($appversion, $version) !== false) { + $addons[$addon_id]['versionCount'] += $count; + } + } + } + + $addons[$addon_id]['percentage'] = round(($addons[$addon_id]['versionCount'] / $addons[$addon_id]['totalCount'] * 100), 2); + + // Get latest version's compatibility + $compat = $this->Addon->query("SELECT appversions.version, versions.id FROM versions INNER JOIN applications_versions ON applications_versions.version_id = versions.id INNER JOIN appversions ON appversions.id = applications_versions.max WHERE versions.addon_id={$addon_id} AND applications_versions.application_id = ".APP_FIREFOX." ORDER BY versions.created DESC LIMIT 1"); + + $addons[$addon_id]['appversion'] = $compat[0]['appversions']['version']; + $addons[$addon_id]['latestVersion'] = $compat[0]['versions']['id']; + $addons[$addon_id]['grade'] = $this->Versioncompare->gradeCompatibility($addons[$addon_id]['appversion'], $version, $appversions); + } + } + + $this->publish('addons', $addons); + } + + $this->publish('loggedin', !empty($session)); + $this->publish('format', $format); + $this->publish('version', $version); + + if ($format == 'ajax') + $this->render('developers', 'ajax'); + else + $this->render('developers', 'mozilla'); + } + + function users($version = COMPAT_DEFAULT_VERSION) { + $this->publish('version', $version); + $this->render('users'); + } } diff --git a/site/app/controllers/components/versioncompare.php b/site/app/controllers/components/versioncompare.php index 7fcd2b8..8483ca8 100644 --- a/site/app/controllers/components/versioncompare.php +++ b/site/app/controllers/components/versioncompare.php @@ -46,6 +46,11 @@ * @subpackage core */ +define('COMPAT_LATEST', 'latest'); +define('COMPAT_BETA', 'beta'); +define('COMPAT_ALPHA', 'alpha'); +define('COMPAT_OTHER', 'other'); + class VersioncompareComponent extends Object { /** * Parse a version part. @@ -194,5 +199,68 @@ class VersioncompareComponent extends Object { function _compareCakeResultVersions($a,$b) { return $this->CompareVersions($a['Appversion']['version'], $b['Appversion']['version']); } + + /** + * Grades an array of appversions relative to their compatibility with a + * major version. + * @param string $compatibility_version major version, like 3.0 or 3.1 + * @param array $versions array of version strings to grade + * @return array appversion => grade + */ + function getCompatibilityGrades($compatibility_version, $versions) { + $this->sortAppversionArray($versions); + $versions = array_reverse($versions, true); + + $appversions = array(); + $highestFound = false; + + foreach ($versions as $version) { + // If highest version hasn't been found but this is pre, count it anyway + if (!$highestFound && strpos($version, 'pre') !== false) { + $appversions[$version] = COMPAT_LATEST; + continue; + } + // This version is the highest without pre, so mark highest as found + if (!$highestFound) { + $appversions[$version] = COMPAT_LATEST; + $highestFound = true; + continue; + } + if (strpos($version, 'b') !== false) { + $appversions[$version] = COMPAT_BETA; + continue; + } + if (strpos($version, 'a') !== false) { + $appversions[$version] = COMPAT_ALPHA; + continue; + } + // Release candidates and final (3.1, 3.1pre, 3.1rc1) are colored as beta + if (strpos($version, 'rc') !== false || $version == $compatibility_version || $version == "{$compatibility_version}pre") { + $appversions[$version] = COMPAT_BETA; + continue; + } + + $appversions[$version] = COMPAT_OTHER; + } + + return $appversions; + } + + /** + * Grades an appversion relative to a major version. + * @param string $version the version to grade + * @param string $compatibility_version the major version + * @param array $gradedArray array of existing grades, output from getCompatibilityGrades() + * @return string compatibility grade constant + */ + function gradeCompatibility($version, $compatibility_version, $gradedArray) { + // See if maxversion is identified as related to this major version + if (array_key_exists($version, $gradedArray)) + return $gradedArray[$version]; + elseif ($this->compareVersions($version, $compatibility_version) > 0) + return COMPAT_LATEST; + else + return COMPAT_OTHER; + } } ?> diff --git a/site/app/views/compatibility/dashboard.thtml b/site/app/views/compatibility/dashboard.thtml index 02c4720..9198c21 100644 --- a/site/app/views/compatibility/dashboard.thtml +++ b/site/app/views/compatibility/dashboard.thtml @@ -46,8 +46,8 @@ <p>Be prepared for the release of Firefox <?=$version?> with the tools and information available for the Firefox Add-ons community found below.</p> <ul> <li id="nav-report"><a href="<?=$html->url('/compatibility/report/'.$version)?>" onclick="compatibility.viewReport(); return false;">View Compatibility Report</a></li> - <li id="nav-developers"><a href="<?=$html->url('/compatibility/developers/'.$version)?>" onclick="compatibility.viewDeveloperInfo(); return false;">Information for Add-on Developers<span>Coming Soon!</span></a></li> - <li id="nav-users"><a href="<?=$html->url('/compatibility/users/'.$version)?>" onclick="compatibility.viewEndUserInfo(); return false;">Information for Add-on Users<span>Coming Soon!</span></a></li> + <li id="nav-developers"><a href="<?=$html->url('/compatibility/developers/'.$version)?>" onclick="compatibility.viewDeveloperInfo(); return false;">Information for Add-on Developers</a></li> + <li id="nav-users"><a href="<?=$html->url('/compatibility/users/'.$version)?>" onclick="compatibility.viewEndUserInfo(); return false;">Information for Add-on Users</a></li> </ul> </div> @@ -55,10 +55,10 @@ <div id="report-intro"> <?php $percentages = array( - COMPAT_OTHER => round(($totals[$version][COMPAT_OTHER]['adu'] / $totals['adu95']) * 100), - COMPAT_ALPHA => round(($totals[$version][COMPAT_ALPHA]['adu'] / $totals['adu95']) * 100), - COMPAT_BETA => round(($totals[$version][COMPAT_BETA]['adu'] / $totals['adu95']) * 100), - COMPAT_LATEST => round(($totals[$version][COMPAT_LATEST]['adu'] / $totals['adu95']) * 100), + COMPAT_OTHER => (($totals[$version][COMPAT_OTHER]['adu'] / $totals['adu95']) * 100), + COMPAT_ALPHA => (($totals[$version][COMPAT_ALPHA]['adu'] / $totals['adu95']) * 100), + COMPAT_BETA => (($totals[$version][COMPAT_BETA]['adu'] / $totals['adu95']) * 100), + COMPAT_LATEST => (($totals[$version][COMPAT_LATEST]['adu'] / $totals['adu95']) * 100), ); ?> <div class="header"> @@ -66,13 +66,13 @@ <?=$html->image('wordmarks/firefox-'.$version.'_small.png')?>Add-on Compatibility Report </div> </div> - <p class="intro">Of the <?=number_format($totals['addons95'])?> add-ons that make up 95% of add-on usage known to Mozilla, <b><?=$percentages[COMPAT_LATEST]?>%</b> are currently considered compatible with the latest builds of Firefox <?=$version?>.</p> + <p class="intro">Of the <?=number_format($totals['addons95'])?> add-ons that make up 95% of add-on usage known to Mozilla, <b><?=round($percentages[COMPAT_LATEST])?>%</b> are currently considered compatible with the latest builds of Firefox <?=$version?>.</p> <div id="overall-compat"> <div id="overall-compat-bar"> - <div class="compat-other" style="width: <?=$percentages[COMPAT_OTHER]?>%;"><?=($percentages[COMPAT_OTHER] >= 5 ? "{$percentages[COMPAT_OTHER]}%": '')?></div> - <div class="compat-alpha" style="width: <?=$percentages[COMPAT_ALPHA]?>%;"><?=($percentages[COMPAT_ALPHA] >= 5 ? "{$percentages[COMPAT_ALPHA]}%": '')?></div> - <div class="compat-beta" style="width: <?=$percentages[COMPAT_BETA]?>%;"><?=($percentages[COMPAT_BETA] >= 5 ? "{$percentages[COMPAT_BETA]}%": '')?></div> - <div class="compat-latest" style="width: <?=$percentages[COMPAT_LATEST]?>%;"><?=($percentages[COMPAT_LATEST] >= 5 ? "{$percentages[COMPAT_LATEST]}%": '')?></div> + <div class="compat-other" style="width: <?=$percentages[COMPAT_OTHER]?>%;"><?=($percentages[COMPAT_OTHER] >= 5 ? round($percentages[COMPAT_OTHER]).'%': '')?></div> + <div class="compat-alpha" style="width: <?=$percentages[COMPAT_ALPHA]?>%;"><?=($percentages[COMPAT_ALPHA] >= 5 ? round($percentages[COMPAT_ALPHA]).'%': '')?></div> + <div class="compat-beta" style="width: <?=$percentages[COMPAT_BETA]?>%;"><?=($percentages[COMPAT_BETA] >= 5 ? round($percentages[COMPAT_BETA]).'%': '')?></div> + <div class="compat-latest" style="width: <?=$percentages[COMPAT_LATEST]?>%;"><?=($percentages[COMPAT_LATEST] >= 5 ? round($percentages[COMPAT_LATEST]).'%': '')?></div> </div> <div id="overall-compat-legend"> @@ -107,11 +107,49 @@ <div class="loading">Loading data...</div> <div id="report-details-data"></div> </div> + + <div id="developers-intro"> + <div class="header"> + <div class="title"> + <?=$html->image('wordmarks/firefox-'.$version.'_small.png')?>Information for Add-on Developers + </div> + </div> + <br /> + <a href="https://developer.mozilla.org/En/Updating_extensions_for_Firefox_<?=$version?>"><?=$html->image('mdc-logo.png', array('class' => 'rightalign'))?></a> + <?=$this->renderElement('compatibility/developer_tips');?> + + <?php if ($loggedin): ?> + <div class="details-link"><a href="#" onclick="compatibility.viewDeveloperDetails();">Check Status of My Add-ons</a></div> + <?php else: ?> + <p class="login">If you have add-ons hosted on Mozilla Add-ons, <a href="<?=$html->url($html->login_url())?>">please login</a> to analyze the status of your add-ons for Firefox <?=$version?>.</p> + <?php endif; ?> + </div> + + <div id="developers-details"> + <div class="header"> + <div class="title"> + <?=$html->image('wordmarks/firefox-'.$version.'_small.png')?>Add-on Status Check Results + </div> + </div> + + <div class="loading">Retrieving status of hosted add-ons...</div> + <div id="developers-details-data"></div> + </div> + + <div id="users-intro"> + <div class="header"> + <div class="title"> + <?=$html->image('wordmarks/firefox-'.$version.'_small.png')?>Information for Add-on Users + </div> + </div> + <br /> + <?=$this->renderElement('compatibility/user_tips');?> + </div> </div> - </div> <script type="text/javascript"> var detailsURL = '<?=$html->url('/compatibility/report/'.$version.'/ajax')?>'; +var developerStatusURL = '<?=$html->url('/compatibility/developers/'.$version.'/ajax')?>'; var version = '<?=$version?>'; </script> diff --git a/site/app/views/compatibility/developers.thtml b/site/app/views/compatibility/developers.thtml new file mode 100644 index 0000000..4f42cf3 --- /dev/null +++ b/site/app/views/compatibility/developers.thtml @@ -0,0 +1,73 @@ +<?php +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is addons.mozilla.org site. + * + * The Initial Developer of the Original Code is + * The Mozilla Foundation. + * Portions created by the Initial Developer are Copyright (C) 2008 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * Justin Scott <fligtar@mozilla.com> (Original Author) + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ +if ($format != 'ajax') { +?> +<div id="content" style="min-height: 400px;"> + <h2>Information for Add-on Developers</h2> + <?=$this->renderElement('compatibility/developer_tips');?> +<?php +} +if ($loggedin) { + if ($format != 'ajax') { + echo '<h2>Add-on Status Check Results</h2>'; + } + + if (!empty($addons)) { + echo '<ul class="developer-addons">'; + foreach ($addons as $addon_id => $addon) { + echo '<li>'; + echo '<div class="appversion compat-'.$addon['grade'].'">'.$addon['appversion'].'</div>'; + echo '<div class="addon-details">'; + echo '<span class="name">'.$addon['name'].'</span>'; + echo '<span class="details">'.$html->number_format($addon['versionCount'], 0)." Firefox {$version} users ({$addon['percentage']}% of total)".' · <a href="'.$html->url('/developers/versions/edit/'.$addon['latestVersion']).'">Adjust maxVersion without uploading</a></span>'; + echo '</div>'; + echo '</li>'; + } + echo '</ul>'; + } + else { + echo '<p class="login">You do not have any add-ons hosted on Mozilla Add-ons.</p>'; + } +} +else { + echo '<p class="login">If you have add-ons hosted on Mozilla Add-ons, <a href="'.$html->url($html->login_url()).'">please login</a> to analyze the status of your add-ons for Firefox '.$version.'.</p>'; +} +?> +<?php if ($format != 'ajax'): ?> +</div> +<?php endif; ?>
\ No newline at end of file diff --git a/site/app/views/compatibility/users.thtml b/site/app/views/compatibility/users.thtml new file mode 100644 index 0000000..94dfb50 --- /dev/null +++ b/site/app/views/compatibility/users.thtml @@ -0,0 +1,42 @@ +<?php +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is addons.mozilla.org site. + * + * The Initial Developer of the Original Code is + * The Mozilla Foundation. + * Portions created by the Initial Developer are Copyright (C) 2008 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * Justin Scott <fligtar@mozilla.com> (Original Author) + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ +?> +<div id="content" style="min-height: 400px;"> + <h2>Information for Add-on Users</h2> + <?=$this->renderElement('compatibility/user_tips');?> +</div>
\ No newline at end of file diff --git a/site/app/views/elements/compatibility/developer_tips.thtml b/site/app/views/elements/compatibility/developer_tips.thtml new file mode 100644 index 0000000..878e4d9 --- /dev/null +++ b/site/app/views/elements/compatibility/developer_tips.thtml @@ -0,0 +1,44 @@ +<?php +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is addons.mozilla.org site. + * + * The Initial Developer of the Original Code is + * The Mozilla Foundation. + * Portions created by the Initial Developer are Copyright (C) 2008 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * Justin Scott <fligtar@mozilla.com> (Original Author) + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ +?> +<ul class="tips"> + <li>Information on updating your add-ons to Firefox <?=$version?> can be found in this <a href="https://developer.mozilla.org/En/Updating_extensions_for_Firefox_<?=$version?>">Mozilla Developer Center article</a>.</li> + <li>Information on overall changes in Firefox <?=$version?> can be found in <a href="https://developer.mozilla.org/en/Firefox_<?=$version?>_for_developers">this article</a>.</li> + <li>You can subscribe to the <a href="https://addons.mozilla.org/newsletter">about:addons newsletter</a> and the <a href="http://blog.mozilla.com/addons/">Mozilla Add-ons blog</a> for additional updates.</li> + <li>If your add-on requires no code changes to claim compatibility and is hosted on Mozilla Add-ons, you can bump its compatible maxVersion online without uploading a new file by heading to the <a href="<?=$html->url('/developers')?>">Developer Tools area</a> or by viewing its status below.</li> +</ul>
\ No newline at end of file diff --git a/site/app/views/elements/compatibility/user_tips.thtml b/site/app/views/elements/compatibility/user_tips.thtml new file mode 100644 index 0000000..56b4dbd --- /dev/null +++ b/site/app/views/elements/compatibility/user_tips.thtml @@ -0,0 +1,44 @@ +<?php +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is addons.mozilla.org site. + * + * The Initial Developer of the Original Code is + * The Mozilla Foundation. + * Portions created by the Initial Developer are Copyright (C) 2008 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * Justin Scott <fligtar@mozilla.com> (Original Author) + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ +?> +<ul class="tips"> + <li>While many add-ons can support the changes in Firefox <?=$version?> without any code modifications, others may require additional work by the authors to ensure a smooth upgrade. Please be patient during this time, as many add-on developers maintain their add-ons voluntarily as a hobby.</li> + <li>Mozilla discourages disabling compatibility checking in your browser, as this can lead to serious problems starting up Firefox and even data loss if an extension not compatible with a new version of Firefox is forced to be used.</li> + <li>If the extension you're trying to use is not compatible after Firefox <?=$version?> is launched, you may want to check its website or author's homepage for any news concerning the update.</li> + <li>You may also want to look for an add-on with similar functionality that does support Firefox <?=$version?> on the <a href="<?=$html->url('/')?>">Firefox Add-ons</a> website.</li> +</ul>
\ No newline at end of file diff --git a/site/app/webroot/css/compatibility.css b/site/app/webroot/css/compatibility.css index 21a8f04..8ee240d 100644 --- a/site/app/webroot/css/compatibility.css +++ b/site/app/webroot/css/compatibility.css @@ -69,18 +69,6 @@ border-color: #2D3B58; } -#nav-developers a span, -#nav-users a span{ - display: none; - color: red; - font-size: 10px; -} - -#nav-developers a:hover span, -#nav-users a:hover span{ - display: block; -} - #compat-home-nav { display: none; border: 1px solid #666666; @@ -98,12 +86,17 @@ #report-intro, #report-details, -#report-details-data { +#report-details-data, +#developers-intro, +#developers-details, +#developers-details-data, +#users-intro { display: none; } -#report-details-data { - overflow-y: scroll; +#report-details-data, +#developers-details-data { + overflow-y: auto; overflow-x: hidden; height: 350px; } @@ -112,10 +105,12 @@ margin: 15px 10px; } -#report-intro .details-link { +.details-link { text-align: center; clear: both; font-size: 1.2em; + font-weight: bold; + padding: 10px; } #report-intro .details-link a:link, @@ -222,3 +217,58 @@ .compat-other { background-color: #999999; } + +/* Developer Info */ +.developer-addons { + padding: 0; + margin: 0; +} +.developer-addons li { + margin: 10px 0; + padding: 0; + list-style: none; + font-size: 15px; +} +.developer-addons li div.addon-details { + border: 2px solid #666666; + -moz-border-radius: 6px; + -moz-border-radius-topleft: 0; + -webkit-border-radius: 6px; + -webkit-border-top-left-radius: 0; + margin-left: 93px; + padding: 0 5px; + background-color: #FFFFFF; +} +.developer-addons li div.appversion { + color: white; + text-align: center; + float: left; + width: 85px; + padding: 3px; + border: 2px solid #666666; + -moz-border-radius-topleft: 6px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-top-left-radius: 6px; + -webkit-border-bottom-left-radius: 6px; +} +.developer-addons li .name { + display: block; +} +.developer-addons li .details { + font-size: 13px; +} + +.rightalign { + float: right; + margin: 0 0 10px 10px; +} + +.login { + font-size: 1.1em; + font-style: italic; + margin-top: 10px; +} + +ul.tips { + font-size: 1.2em; +}
\ No newline at end of file diff --git a/site/app/webroot/img/mdc-logo.png b/site/app/webroot/img/mdc-logo.png Binary files differnew file mode 100644 index 0000000..72b7831 --- /dev/null +++ b/site/app/webroot/img/mdc-logo.png diff --git a/site/app/webroot/js/compatibility.js b/site/app/webroot/js/compatibility.js index 9d496a0..d338dd5 100644 --- a/site/app/webroot/js/compatibility.js +++ b/site/app/webroot/js/compatibility.js @@ -1,7 +1,7 @@ var compatibility = { viewReport: function() { $('#compat-intro').fadeOut('medium', function() { - $('#compat-home-nav').show('slide', {direction: 'down'}, 100); + $('#compat-home-nav').fadeIn(); $('#report-intro').fadeIn('medium'); }); }, @@ -22,16 +22,34 @@ var compatibility = { }, viewHome: function() { - $('#report-intro,#report-details,#report-details-data,.loading,#compat-home-nav').hide(); + $('#report-intro,#report-details,#report-details-data,.loading,#compat-home-nav,#developers-intro,#developers-details,#users-intro').hide(); $('.compat-box').animate({ width: '650px'}, 'fast'); $('#compat-intro').fadeIn('medium'); }, viewDeveloperInfo: function() { - + $('#compat-intro').fadeOut('medium', function() { + $('#compat-home-nav').fadeIn(); + $('#developers-intro').fadeIn('medium'); + }); + }, + + viewDeveloperDetails: function() { + $('#developers-intro').fadeOut('medium', function() { + $('#developers-details').fadeIn('medium', function() { + $('#developers-details .loading').show(); + $('#developers-details-data').load(developerStatusURL, null, function() { + $('#developers-details .loading').hide(); + $('#developers-details-data').show(); + }); + }); + }); }, viewEndUserInfo: function() { - + $('#compat-intro').fadeOut('medium', function() { + $('#compat-home-nav').fadeIn(); + $('#users-intro').fadeIn('medium'); + }); } };
\ No newline at end of file |