Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: skin/mobile-options.css

Issue 29488575: Issue 5384 - Introduced dedicated mobile options page (Closed)
Patch Set: Addressed mobile-options.js comments Created July 18, 2017, 5:39 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: skin/mobile-options.css
===================================================================
new file mode 100644
--- /dev/null
+++ b/skin/mobile-options.css
@@ -0,0 +1,347 @@
+/*
+ * This file is part of Adblock Plus <https://adblockplus.org/>,
+ * Copyright (C) 2006-2017 eyeo GmbH
+ *
+ * Adblock Plus is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 3 as
+ * published by the Free Software Foundation.
+ *
+ * Adblock Plus is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+body
+{
+ text-align: center;
saroyanm 2017/07/31 15:50:43 Detail: You are overwriting this value in child el
Thomas Greiner 2017/08/01 12:50:05 This is necessary for centering the main content a
+ font-family: sans-serif;
saroyanm 2017/07/31 15:50:42 I think this is "Source Sans Pro". I think we can
Thomas Greiner 2017/08/01 12:50:07 Done. I was just copying it from new-options.css.
+ font-size: 14px;
saroyanm 2017/07/31 15:50:42 We use EMs and PXs all together, this solution is
Thomas Greiner 2017/08/01 12:50:08 Acknowledged.
+ color: #3E4347;
saroyanm 2017/07/31 15:50:43 According to the style guide, I guess this should
Thomas Greiner 2017/08/01 12:50:06 Done.
+}
+
+main,
+[role="dialog"]
+{
+ text-align: start;
+}
+
+main
+{
+ padding: 20px 45px;
+}
+
+h1
+{
+ position: relative;
+ font-size: 1em;
+ line-height: 20px;
+ color: #000;
+}
+
+h1::before
+{
+ position: absolute;
+ left: -25px;
+ width: 20px;
+ height: 20px;
+ background: url(mobile/abp-logo.svg) 0/20px;
+ content: "";
+}
+
+html[dir="rtl"] h1::before
+{
+ left: auto;
+ right: -25px;
+}
+
+h2
+{
+ font-size: 1em;
+}
+
+a:link,
+a:visited
+{
+ text-decoration: none;
+ color: #0A9BD0;
saroyanm 2017/07/31 15:50:42 I think this should be #5CBCE1 according to the st
Thomas Greiner 2017/08/01 12:50:05 The style guide states that text links should have
+}
+
+[hidden]
+{
+ display: none !important;
+}
+
+#acceptableAds-more
+{
+ white-space: nowrap;
+}
+
+/* Lists */
+
+ul
+{
+ margin: 0;
+ padding: 0;
+}
+
+ul > li
+{
+ display: flex;
+ align-items: center;
+ box-sizing: border-box;
+ min-height: 36px;
+ padding: 5px 10px;
+ border: 1px solid #BCBCBC;
saroyanm 2017/07/31 15:50:42 Newly added language in style guide, has also diff
saroyanm 2017/07/31 15:50:42 I think the border color should be "#BBBBBB" accor
Thomas Greiner 2017/08/01 12:50:03 This feature doesn't exist in the mobile options p
Thomas Greiner 2017/08/01 12:50:08 Done.
+ border-bottom: none;
+ list-style: none;
+}
+
+ul > li > span
+{
+ flex: 1;
saroyanm 2017/07/31 15:50:41 I have assumption that you want to fill whole free
Thomas Greiner 2017/08/01 12:50:04 All those seem to be equivalent: - `flex: auto` -
+ padding: 10px;
+ word-wrap: break-word;
+ overflow: hidden;
+}
+
+/* Form elements */
+
+input[type="text"]
+{
+ min-width: 220px;
+ padding: 5px 0;
+ border: 0;
+ border-bottom: 1px solid #BCBCBC;
saroyanm 2017/07/31 15:50:43 The appearance of this element is different in des
Thomas Greiner 2017/08/01 12:50:07 Done. Yeah, I agree that we should prioritize the
+}
+
+input[type="text"]::placeholder
+{
+ color: #9E9E9E;
saroyanm 2017/07/31 15:50:41 According to Style guide, this is #4A4A4A.
Thomas Greiner 2017/08/01 12:50:03 It looks like the placeholder text should be `#BBB
+}
+
+input[type="text"]:focus::placeholder
+{
+ color: transparent;
+}
+
+input[type="text"]:not(:focus):placeholder-shown ~ label,
+input[type="text"]:not(:placeholder-shown) ~ .error
+{
+ visibility: hidden
+}
+
+.toggle-container
+{
+ display: flex;
+}
+
+.toggle-container > span
+{
+ flex-grow: 1;
saroyanm 2017/07/31 15:50:42 I'll suggest to use "flex" instead as it's done fo
Thomas Greiner 2017/08/01 12:50:08 Done.
+}
+
+.toggle-container input
+{
+ display: none;
+}
+
+.toggle-image
+{
+ display: inline-block;
+ flex-shrink: 0;
saroyanm 2017/07/31 15:50:43 Not sure if this is required.
Thomas Greiner 2017/08/01 12:50:04 We don't want the image to shrink below its regula
+ width: 36px;
+ height: 21px;
+ background-image: url(mobile/toggle.png);
saroyanm 2017/07/31 15:50:41 Detail: while we are using SVGs for other icons, I
Thomas Greiner 2017/08/01 12:50:03 This is what I got from Jeen so I just used it. I
+}
+
+input:checked + .toggle-image
+{
+ background-position: 0 -22px;
+}
+
+button
+{
+ width: 100%;
+ height: 45px;
saroyanm 2017/07/31 15:50:40 Suggestion: let's use padding not to be dependent
Thomas Greiner 2017/08/01 12:50:05 I get what you mean but this is a bit tricky in th
+ border: none;
+ font-weight: 600;
+ text-transform: uppercase;
+ color: #0A9BD0;
saroyanm 2017/07/31 15:50:41 I think this should be "#099CD0" according to the
Thomas Greiner 2017/08/01 12:50:04 Done.
+ background: none;
+}
+
+button.primary,
+button.secondary
+{
+ height: 36px;
+ margin: 5px 0;
+ border: 1px solid;
+ border-radius: 2px;
+}
+
+button.primary
+{
+ color: #FFF;
+ border-color: #0A9BD0;
saroyanm 2017/07/31 15:50:43 "#5CBCE1" -styleguide.
Thomas Greiner 2017/08/01 12:50:08 On page 8 of the style guide it says that we shoul
+ background-color: #0A9BD0;
+}
+
+button.secondary
+{
+ border-color: #BCBCBC;
saroyanm 2017/07/31 15:50:41 "#0A9DD1" - styleguide.
Thomas Greiner 2017/08/01 12:50:07 That's not what's shown in https://bytebucket.org/
+}
+
+button.remove
+{
+ width: 36px;
+ height: 36px;
+ padding: 0;
+ background-color: #0A9BD0;
saroyanm 2017/07/31 15:50:40 Suggestion "#5CBCE1" for consistency, if the color
Thomas Greiner 2017/08/01 12:50:04 Done. Used `#099DD1` instead again because it's mo
+ mask: url(mobile/trash.svg) center/19px no-repeat;
+}
+
+ul + button
Thomas Greiner 2017/08/01 12:50:06 Note that I noticed that the content of this butto
+{
+ width: 100%;
+ border: 1px solid #BCBCBC;
saroyanm 2017/07/31 15:50:41 #BBB
Thomas Greiner 2017/08/01 12:50:04 Done.
+}
+
+/* Dialogs */
+
+#dialog
+{
+ display: flex;
+ align-items: flex-start;
+ justify-content: center;
+ position: fixed;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ padding-top: 20px;
+ background: rgba(0, 0, 0, 0.7);
+ z-index: 101;
+}
+
+[role="dialog"]
+{
+ max-width: 25em;
saroyanm 2017/07/31 15:50:41 Why are we using EMs here ? Other widths are speci
Thomas Greiner 2017/08/01 12:50:05 Because it's specifically mentioned in the spec:
+ padding: 0;
+ border: 1px solid #BCBCBC;
saroyanm 2017/07/31 15:50:42 #BBB
Thomas Greiner 2017/08/01 12:50:04 Done.
+ background-color: #FFF;
+}
+
+[role="dialog"] h2
+{
+ margin: 0;
+}
+
+[role="dialog"] form
+{
+ padding: 20px;
+}
+
+[role="dialog"] p
+{
+ display: flex;
+ flex-direction: column;
+ margin: 5px 0;
+}
+
+[role="dialog"] label
+{
+ order: 1;
+ display: block;
+ margin: 5px 0;
+ font-size: 10px;
+}
+
+[role="dialog"] menu
+{
+ display: flex;
+ margin: 0;
+ padding: 0;
+ border-top: 1px solid #BCBCBC;
saroyanm 2017/07/31 15:50:40 #BBB
Thomas Greiner 2017/08/01 12:50:07 Done.
+}
+
+[role="dialog"] input[type="text"]
+{
+ order: 2;
+}
+
+[role="dialog"] .error
+{
+ order: 3;
+ margin-top: 5px;
+ font-size: 12px;
+ color: #D1142A;
saroyanm 2017/07/31 15:50:43 #C11D26 (Note: The visuals are different, but this
Thomas Greiner 2017/08/01 12:50:08 Done.
+}
+
+[role="dialog"]:not([data-error]) .error,
+#dialog-subscribe:not([data-error="title"]) .error[data-error="title"],
+#dialog-subscribe:not([data-error="url"]) .error[data-error="url"]
+{
+ visibility: hidden;
+}
+
+#dialog-subscribe[data-error="title"] [name="title"]:placeholder-shown,
+#dialog-subscribe[data-error="url"] [name="url"]:placeholder-shown
+{
+ border-color: #D1142A;
saroyanm 2017/07/31 15:50:43 #C11D26
Thomas Greiner 2017/08/01 12:50:07 Done.
+}
+
+body:not([data-dialog]) #dialog,
+body:not([data-dialog="recommended"]) #dialog-recommended,
+body:not([data-dialog="subscribe"]) #dialog-subscribe
+{
+ display: none;
+}
+
+#dialog-recommended
+{
+ display: flex;
+ flex-direction: column;
+ top: 20px;
+ max-height: calc(100vh - 40px);
saroyanm 2017/07/31 15:50:41 Why Calc is marked as experimental still ? https:/
Thomas Greiner 2017/08/01 12:50:06 Seems likethe CSS Values and Module Level 3 standa
+}
+
+#dialog-recommended ul
+{
+ width: auto;
+ margin: 0;
+ overflow-y: auto;
+}
+
+#dialog-recommended ul li
+{
+ border: none;
+}
+
+#dialog-recommended ul li.installed
+{
+ color: #A1A1A1;
saroyanm 2017/07/31 15:50:42 This is not specified, maybe: #BBB
Thomas Greiner 2017/08/01 12:50:07 Done.
+}
+
+#dialog-recommended ul li::before
+{
+ flex-shrink: 0;
+ width: 13px;
+ height: 11px;
+ margin: 10px;
+ content: "";
+}
+
+#dialog-recommended ul li.installed::before
+{
+ background-color: #A1A1A1;
+ mask: url(mobile/checkmark.svg) center/cover no-repeat;
+}
+
+#dialog-recommended menu
+{
+ flex-shrink: 0;
+}
« mobile-options.js ('K') | « mobile-options.js ('k') | skin/mobile/abp-logo.svg » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld