forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Import Polymer templates at runtime in ash/webui/common/.
Also using css_to_wrapper() for wrapping CSS vars files with a JS file that can be imported at runtime. Effectively this CL replaces html_to_js(), with html_to_wrapper() and css_to_wrapper() in ash/webui/common/. Besides this being a good improvement on its own, it will also make it easier to move various CrOS-only stuff that is already using html_to_wrapper() and css_to_wrapper() from ui/webui/resources/ to ash/webui/common moving forward. Bug: 1292025,1322682 Change-Id: I760b02be0e1ff2336717546d1c7c2d5ea3665600 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3787238 Reviewed-by: Jimmy Gong <jimmyxgong@chromium.org> Commit-Queue: Demetrios Papadopoulos <dpapad@chromium.org> Cr-Commit-Position: refs/heads/main@{#1028623}
- Loading branch information
Showing
14 changed files
with
149 additions
and
139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
/* Copyright 2022 The Chromium Authors. All rights reserved. | ||
* Use of this source code is governed by a BSD-style license that can be | ||
* found in the LICENSE file. */ | ||
|
||
/* #css_wrapper_metadata_start | ||
* #type=vars | ||
* #import=chrome://resources/cr_elements/shared_vars_css.m.js | ||
* #import=chrome://resources/polymer/v3_0/paper-styles/color.js | ||
* #css_wrapper_metadata_end */ | ||
|
||
html { | ||
--areas-no-header-nav: "sideNav main"; | ||
--areas-no-header-nav-banner: "banner banner" | ||
"sideNav main"; | ||
--iron-icon-fill-color: var(--cros-icon-color-primary); | ||
--iron-icon-height: 20px; | ||
--iron-icon-width: 20px; | ||
--left-aligned-top-offset: 64px; | ||
} | ||
|
||
/* calc formula: (viewport width - (padding + side nav size)) */ | ||
@media (min-width: 600px) { | ||
html { | ||
--areas-nav: "head head" | ||
"main main"; | ||
--areas-nav-banner: "head head" | ||
"banner banner" | ||
"main main"; | ||
--columns-nav: 1fr 1fr; | ||
--container-padding-nav: 24px; | ||
--container-max-width-nav: calc(100vw - 48px); | ||
} | ||
} | ||
|
||
@media (min-width: 769px) { | ||
html { | ||
--areas-nav: "head head" | ||
"sideNav main"; | ||
--areas-nav-banner: "head head" | ||
"banner banner" | ||
"sideNav main"; | ||
--columns-nav: 192px 1fr; | ||
--container-padding-nav: 40px; | ||
--container-max-width-nav: calc(100vw - 272px); | ||
} | ||
} | ||
|
||
@media (min-width: 961px) { | ||
html { | ||
--columns-nav: 248px 1fr; | ||
--container-padding-nav: 48px; | ||
--container-max-width-nav: calc(100vw - 344px); | ||
|
||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.