From ed712e9a442d903eea1a7cffc68bde219608d8d0 Mon Sep 17 00:00:00 2001 From: Scott Main Date: Thu, 23 Feb 2017 12:21:05 -0800 Subject: Update 'added in' text to provide a different message for previews and add CSS to style the APIs that are marked with this new since tag. If the API level is not a number, then I assume the 'since' tag given for the API level is a letter, which is what we use for the developer previews, so it shows the new label. Change-Id: I0e569e28144a5df37bd41a23e9d3918a0443e0a3 (cherry picked from commit a77fb01ec0242b918dd0aa478cdc2334e7260203) --- res/assets/templates-sdk/assets/css/default.css | 39 +++++++++++++++++++++++++ res/assets/templates/macros.cs | 8 +++-- 2 files changed, 45 insertions(+), 2 deletions(-) diff --git a/res/assets/templates-sdk/assets/css/default.css b/res/assets/templates-sdk/assets/css/default.css index 9e5df48..65d7fde 100644 --- a/res/assets/templates-sdk/assets/css/default.css +++ b/res/assets/templates-sdk/assets/css/default.css @@ -3277,6 +3277,45 @@ table.jd-tagtable th { color:inherit; } + +/* Must be updated with each letter-appropriate preview */ +body.apilevel-O #jd-content { + background: url('../images/preview.png') repeat; +} + +/* Must be updated with each letter-appropriate preview */ +#jd-content .apilevel-O:not(.absent) h3 { + color: #f5ba15; +} + +/* Must be updated with each letter-appropriate preview */ +#jd-content .apilevel-O:not(.absent) .api-level a, +body.apilevel-O #api-info-block .api-level a { + color: #f5ba15; + font-size: 14px; +} + +/* Must be updated with each letter-appropriate preview */ +#jd-content .apilevel-O:not(.absent) td, +#jd-content .apilevel-O:not(.absent) th, +body.apilevel-O #jd-content table:not(.jd-inheritance-table) td, +body.apilevel-O #jd-content th { + background: rgba(245, 185, 16, 0.2); + border: solid 1px #f5ba15; +} + +/* Must be updated with each letter-appropriate preview */ +#jd-content tr.apilevel-O:not(.absent) td { + background: rgba(245, 185, 16, 0.2); + border: solid 1px #ddd; +} + +/* Must be updated with each letter-appropriate preview */ +#jd-content .apilevel-O:not(.absent) th, +body.apilevel-O #jd-content th { + background: #f5ba15; +} + /************ STICKY NAV BAR ******************/ #context { diff --git a/res/assets/templates/macros.cs b/res/assets/templates/macros.cs index bcb9a1d..eae1d8d 100644 --- a/res/assets/templates/macros.cs +++ b/res/assets/templates/macros.cs @@ -248,8 +248,12 @@ def:see_also_tags(also) ?> - Added in API level 0 ?> + added in API level + Android Developer Preview