Bug 1609872 - Make about:policies an HTML page. r=ntim
authoreghitta <emil.ghitta@softvision.ro>
Sun, 08 Mar 2020 20:54:17 +0000
changeset 517482 03852000dace59e2f15ffb548ec376433020a6e8
parent 517481 13400b21b6c37818142d4766f1545864b487598a
child 517483 6f8c5bdc772653e0560200ebea4219e1745a27f9
push id37194
push usershindli@mozilla.com
push dateMon, 09 Mar 2020 03:45:29 +0000
treeherdermozilla-central@2540a369a5a8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersntim
bugs1609872
milestone75.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1609872 - Make about:policies an HTML page. r=ntim Differential Revision: https://phabricator.services.mozilla.com/D65896
browser/components/about/AboutRedirector.cpp
browser/components/enterprisepolicies/content/aboutPolicies.html
browser/components/enterprisepolicies/content/aboutPolicies.xhtml
browser/components/enterprisepolicies/jar.mn
--- a/browser/components/about/AboutRedirector.cpp
+++ b/browser/components/about/AboutRedirector.cpp
@@ -57,17 +57,17 @@ static const RedirEntry kRedirMap[] = {
          nsIAboutModule::HIDE_FROM_ABOUTABOUT},
     {"logins", "chrome://browser/content/aboutlogins/aboutLogins.html",
      nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::URI_MUST_LOAD_IN_CHILD |
          nsIAboutModule::URI_CAN_LOAD_IN_PRIVILEGEDABOUT_PROCESS |
          nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT},
     {"tabcrashed", "chrome://browser/content/aboutTabCrashed.xhtml",
      nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
          nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::HIDE_FROM_ABOUTABOUT},
-    {"policies", "chrome://browser/content/policies/aboutPolicies.xhtml",
+    {"policies", "chrome://browser/content/policies/aboutPolicies.html",
      nsIAboutModule::ALLOW_SCRIPT},
     {"privatebrowsing", "chrome://browser/content/aboutPrivateBrowsing.html",
      nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
          nsIAboutModule::URI_MUST_LOAD_IN_CHILD | nsIAboutModule::ALLOW_SCRIPT},
     {"profiling",
      "chrome://devtools/content/performance-new/aboutprofiling/index.xhtml",
      nsIAboutModule::ALLOW_SCRIPT},
     {"rights", "chrome://global/content/aboutRights.xhtml",
rename from browser/components/enterprisepolicies/content/aboutPolicies.xhtml
rename to browser/components/enterprisepolicies/content/aboutPolicies.html
--- a/browser/components/enterprisepolicies/content/aboutPolicies.xhtml
+++ b/browser/components/enterprisepolicies/content/aboutPolicies.html
@@ -1,77 +1,76 @@
-<?xml version="1.0" encoding="UTF-8"?>
 <!--
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 -->
 <!DOCTYPE html>
 
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
     <head>
-        <meta http-equiv="Content-Security-Policy" content="default-src chrome:; object-src 'none'" />
-        <title data-l10n-id="about-policies-title"/>
-        <link rel="stylesheet" href="chrome://browser/content/policies/aboutPolicies.css" type="text/css" />
-        <link rel="localization" href="branding/brand.ftl"/>
-        <link rel="localization" href="browser/branding/sync-brand.ftl"/>
-        <link rel="localization" href="browser/aboutPolicies.ftl"/>
-        <link rel="localization" href="browser/policies/policies-descriptions.ftl"/>
-        <script src="chrome://browser/content/policies/aboutPolicies.js" />
+        <meta http-equiv="Content-Security-Policy" content="default-src chrome:; object-src 'none'">
+        <title data-l10n-id="about-policies-title"></title>
+        <link rel="stylesheet" href="chrome://browser/content/policies/aboutPolicies.css">
+        <link rel="localization" href="branding/brand.ftl">
+        <link rel="localization" href="browser/branding/sync-brand.ftl">
+        <link rel="localization" href="browser/aboutPolicies.ftl">
+        <link rel="localization" href="browser/policies/policies-descriptions.ftl">
+        <script src="chrome://browser/content/policies/aboutPolicies.js"></script>
     </head>
     <body id="body">
         <div id="categories">
             <div class="category" selected="true" id="category-active">
-                <img class="category-icon" src="chrome://browser/content/policies/policies-active.svg"></img>
+                <img class="category-icon" src="chrome://browser/content/policies/policies-active.svg">
                 <label class="category-name" data-l10n-id="active-policies-tab"></label>
             </div>
             <div class="category" id="category-documentation">
-                <img class="category-icon" src="chrome://browser/content/policies/policies-documentation.svg"></img>
+                <img class="category-icon" src="chrome://browser/content/policies/policies-documentation.svg">
                 <label class="category-name" data-l10n-id="documentation-tab"></label>
             </div>
             <div class="category" id="category-errors">
-                <img class="category-icon" src="chrome://browser/content/policies/policies-error.svg"></img>
+                <img class="category-icon" src="chrome://browser/content/policies/policies-error.svg">
                 <label class="category-name" data-l10n-id="errors-tab"></label>
             </div>
         </div>
         <div class="main-content">
             <div class="header">
-                <div id="sectionTitle" class="header-name" data-l10n-id="active-policies-tab"/>
+                <div id="sectionTitle" class="header-name" data-l10n-id="active-policies-tab"></div>
             </div>
 
             <div id="active" class="tab active">
                 <h3 class="inactive-service-message" data-l10n-id="inactive-message"></h3>
                 <h3 class="no-specified-policies-message" data-l10n-id="no-specified-policies-message"></h3>
                 <table>
                     <thead>
                         <tr>
-                            <th data-l10n-id="policy-name"/>
-                            <th data-l10n-id="policy-value"/>
+                            <th data-l10n-id="policy-name"></th>
+                            <th data-l10n-id="policy-value"></th>
                         </tr>
                     </thead>
-                    <tbody id="activeContent" />
+                    <tbody id="activeContent"></tbody>
                 </table>
             </div>
 
             <div id="documentation" class="tab" hidden="true">
                 <table>
                     <thead>
                         <tr>
-                            <th data-l10n-id="policy-name"/>
+                            <th data-l10n-id="policy-name"></th>
                         </tr>
                     </thead>
-                    <tbody id="documentationContent" />
+                    <tbody id="documentationContent"></tbody>
                 </table>
             </div>
 
              <div id="errors" class="tab" hidden="true">
                 <table>
                     <thead>
                         <tr>
-                            <th data-l10n-id="policy-errors"/>
+                            <th data-l10n-id="policy-errors"></th>
                         </tr>
                     </thead>
-                    <tbody id="errorsContent" />
+                    <tbody id="errorsContent"></tbody>
                 </table>
             </div>
         </div>
     </body>
 </html>
--- a/browser/components/enterprisepolicies/jar.mn
+++ b/browser/components/enterprisepolicies/jar.mn
@@ -1,11 +1,11 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 browser.jar:
     content/browser/policies/aboutPolicies.css              (content/aboutPolicies.css)
-    content/browser/policies/aboutPolicies.xhtml            (content/aboutPolicies.xhtml)
+    content/browser/policies/aboutPolicies.html             (content/aboutPolicies.html)
     content/browser/policies/aboutPolicies.js               (content/aboutPolicies.js)
     content/browser/policies/policies-active.svg            (content/policies-active.svg)
     content/browser/policies/policies-documentation.svg     (content/policies-documentation.svg)
     content/browser/policies/policies-error.svg             (content/policies-error.svg)