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

Unified Diff: ui/webui/resources/cr_elements/cr_input/cr_input.js

Issue 976713007: Add a readonly attribute to cr-input. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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: ui/webui/resources/cr_elements/cr_input/cr_input.js
diff --git a/ui/webui/resources/cr_elements/cr_input/cr_input.js b/ui/webui/resources/cr_elements/cr_input/cr_input.js
index 3f8f253c8911a6213888389484f703aff9b39ef8..4258ecd6985cdbec6b7bd4706ecc40e94c50f081 100644
--- a/ui/webui/resources/cr_elements/cr_input/cr_input.js
+++ b/ui/webui/resources/cr_elements/cr_input/cr_input.js
@@ -46,6 +46,15 @@ Polymer('cr-input', {
disabled: {value: false, reflect: true},
/**
+ * Set to true to make the input read-only.
+ *
+ * @attribute readonly
+ * @type boolean
+ * @default false
+ */
+ readonly: {value: false, reflect: true},
+
+ /**
* Set to true to mark the input as required.
*
* @attribute required

Powered by Google App Engine
This is Rietveld 408576698