Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(125)

Unified Diff: chrome/browser/resources/settings/languages_page/languages_page.html

Issue 2359353002: MD Settings: Polish for Languages main page (Closed)
Patch Set: dbeam feedback Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/settings/languages_page/languages_page.html
diff --git a/chrome/browser/resources/settings/languages_page/languages_page.html b/chrome/browser/resources/settings/languages_page/languages_page.html
index e07cdcb6e64ea2fe5acf4a9038a7ea0a910fdf0d..27b4bc4cb112884371ab4c3e7473d5c7841920f2 100644
--- a/chrome/browser/resources/settings/languages_page/languages_page.html
+++ b/chrome/browser/resources/settings/languages_page/languages_page.html
@@ -6,7 +6,6 @@
<link rel="import" href="chrome://resources/polymer/v1_0/neon-animation/neon-animatable.html">
<link rel="import" href="chrome://resources/polymer/v1_0/paper-checkbox/paper-checkbox.html">
<link rel="import" href="chrome://resources/polymer/v1_0/paper-icon-button/paper-icon-button.html">
-<link rel="import" href="chrome://resources/polymer/v1_0/paper-toggle-button/paper-toggle-button.html">
<link rel="import" href="chrome://resources/cr_elements/cr_expand_button/cr_expand_button.html">
<link rel="import" href="chrome://resources/cr_elements/cr_lazy_render/cr_lazy_render.html">
<link rel="import" href="chrome://resources/cr_elements/cr_shared_menu/cr_shared_menu.html">
@@ -42,10 +41,29 @@
margin-top: 4px;
}
+ cr-shared-menu {
+ --cr-shared-menu-width: 320px;
+ }
+
+ cr-shared-menu.complex .dropdown-item {
+ min-height: 36px;
+ }
+
+ cr-shared-menu:not(.complex) hr {
+ display: none;
+ }
+
+ cr-shared-menu.complex hr {
+ /* Override user-agent border and margin. */
+ border: none;
+ /* TODO(michaelpg): Update to whatever variable is used for the darker,
+ * full-width separators: crbug.com/649547. */
+ border-top: var(--settings-separator-line);
+ margin: 6px 0 0 0;
+ }
+
paper-checkbox.dropdown-item {
--checkbox-margin-start: 0;
- /* Allow for the ripple height. */
- min-height: var(--paper-checkbox-ink-size);
}
</style>
<settings-languages languages="{{languages}}" prefs="{{prefs}}"
@@ -129,12 +147,13 @@
<div class$="list-item [[getInputMethodItemClass_(
item.id, languages.inputMethods.currentId)]]"
on-tap="onInputMethodTap_" actionable>
- <div>[[item.displayName]]</div>
- <div class="middle">
- <iron-icon icon="settings:done"
+ <div class="start">
+ <div>[[item.displayName]]</div>
+ <div class="explain-selected"
hidden="[[!isCurrentInputMethod_(
item.id, languages.inputMethods.currentId)]]">
- </iron-icon>
+ $i18n{inputMethodEnabled}
+ </div>
</div>
<paper-icon-button icon="cr:settings"
on-tap="onInputMethodOptionsTap_"
@@ -165,19 +184,12 @@
<div class="list-frame vertical-list">
<template is="dom-repeat" items="[[languages.enabled]]">
<div class="list-item">
- <label class="start"
- id="supportsSpellCheckLabel-[[item.language.code]]">
- <span disabled$="[[!item.language.supportsSpellcheck]]">
- [[item.language.displayName]]
- </span>
- </label>
- <paper-toggle-button
+ <paper-checkbox
checked="[[item.spellCheckEnabled]]"
on-change="onSpellCheckChange_"
- disabled$="[[!item.language.supportsSpellcheck]]"
- aria-labelledby=
- "supportsSpellCheckLabel-[[item.language.code]]">
- </paper-toggle-button>
+ disabled$="[[!item.language.supportsSpellcheck]]">
+ [[item.language.displayName]]
+ </paper-checkbox>
</label>
</template>
<div class="list-item list-button" on-tap="onEditDictionaryTap_">
@@ -187,7 +199,8 @@
</iron-collapse>
</if>
<template is="cr-lazy-render" id="menu">
- <cr-shared-menu>
+ <cr-shared-menu
+ class$="[[getMenuClass_(prefs.translate.enabled.value)]]">
<if expr="chromeos or is_win">
<paper-checkbox id="uiLanguageItem" class="dropdown-item"
checked="[[isProspectiveUILanguage_(
@@ -207,10 +220,17 @@
detailLanguage_.language, languages.translateTarget)]]">
$i18n{offerToTranslateInThisLanguage}
</paper-checkbox>
+ <hr>
<button class="dropdown-item" role="menuitem"
- on-tap="onMoveUpTap_"
+ on-tap="onMoveToTopTap_"
hidden="[[isFirstLanguage_(
detailLanguage_, languages.enabled.*)]]">
+ $i18n{moveToTop}
+ </button>
+ <button class="dropdown-item" role="menuitem"
+ on-tap="onMoveUpTap_"
+ hidden="[[isFirstOrSecondLanguage_(
+ detailLanguage_, languages.enabled.*)]]">
$i18n{moveUp}
</button>
<button class="dropdown-item" role="menuitem"

Powered by Google App Engine
This is Rietveld 408576698