Commit 3835a951 authored by James Vecore's avatar James Vecore Committed by Chromium LUCI CQ

Revert "WebUI: Cleanup unnecessary code duplication in cr_dialog."

This reverts commit f306830b.

Reason for revert: The if expression doesn't work mid tag on attributes on chromeos: http://screen/8GEEvG6Tpzzu8Ct.png

Original change's description:
> WebUI: Cleanup unnecessary code duplication in cr_dialog.
>
> At r819219 a large part of cr_dialog.html code was duplicated between
> CrOS/non-CrOS builds unnecessarily.
>
> Bug: 1007433
> Change-Id: Ia7de207202cdbd39f0b8d8671cd809249da36081
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2565184
> Commit-Queue: dpapad <dpapad@chromium.org>
> Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#831882}

TBR=khorimoto@chromium.org,dpapad@chromium.org

Change-Id: Ib7a20c91b4cfbf5e73b5d9b7b841788adb794ef5
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 1007433
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2567354Reviewed-by: default avatarJames Vecore <vecore@google.com>
Commit-Queue: James Vecore <vecore@google.com>
Cr-Commit-Position: refs/heads/master@{#832237}
parent c86f47d0
......@@ -148,14 +148,12 @@
margin-top: 4px;
}
</style>
<!-- TODO(crbug/1139958): Remove "not chromeos" block when chromeVox issue
is fixed-->
<!-- TODO(crbug/1139958): Remove "not chromeos" block when chromeVox issue is fixed-->
<!--Update both "not chromeos" and "chromeos" blocks if either changes-->
<if expr="not chromeos">
<dialog id="dialog" on-close="onNativeDialogClose_"
on-cancel="onNativeDialogCancel_" part="dialog"
<if expr="not chromeos">
aria-labelledby="title"
</if>
>
aria-labelledby="title">
<!-- This wrapper is necessary, such that the "pulse" animation is not
erroneously played when the user clicks on the outer-most scrollbar. -->
<div id="content-wrapper" part="wrapper">
......@@ -177,6 +175,32 @@
<slot name="footer"></slot>
</div>
</dialog>
</if>
<if expr="chromeos">
<dialog id="dialog" on-close="onNativeDialogClose_"
on-cancel="onNativeDialogCancel_" part="dialog">
<!-- This wrapper is necessary, such that the "pulse" animation is not
erroneously played when the user clicks on the outer-most scrollbar. -->
<div id="content-wrapper" part="wrapper">
<div class="top-container">
<div id="title" class="title-container" tabindex="-1">
<slot name="title"></slot>
</div>
<cr-icon-button id="close" class="icon-clear"
hidden$="[[!showCloseButton]]" aria-label$="[[closeText]]"
on-click="cancel" on-keypress="onCloseKeypress_">
</cr-icon-button>
</div>
<slot name="header"></slot>
<div class="body-container" id="container" show-bottom-shadow
part="body-container">
<slot name="body"></slot>
</div>
<slot name="button-container"></slot>
<slot name="footer"></slot>
</div>
</dialog>
</if>
</template>
<script src="cr_dialog.js"></script>
</dom-module>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment