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

Unified Diff: third_party/polymer/components-chromium/core-menu-button/core-menu-button-extracted.js

Issue 592593002: Inline scripts were extracted from Polymer elements. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: s/echo ""/echo/ Created 6 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: third_party/polymer/components-chromium/core-menu-button/core-menu-button-extracted.js
diff --git a/third_party/polymer/components-chromium/core-menu-button/core-menu-button-extracted.js b/third_party/polymer/components-chromium/core-menu-button/core-menu-button-extracted.js
new file mode 100644
index 0000000000000000000000000000000000000000..4bc658cc70ea4f68fb040e4c170fae15acd7903c
--- /dev/null
+++ b/third_party/polymer/components-chromium/core-menu-button/core-menu-button-extracted.js
@@ -0,0 +1,63 @@
+
+ Polymer('core-menu-button', {
+ /**
+ * The icon to display.
+ * @attribute icon
+ * @type string
+ */
+ icon: 'dots',
+ src: '',
+ /**
+ * The index of the selected menu item.
+ * @attribute selected
+ * @type number
+ */
+ selected: '',
+ /**
+ * Set to true to open the menu.
+ * @attribute opened
+ * @type boolean
+ */
+ opened: false,
+ /**
+ * Set to true to cause the menu popup to be displayed inline rather
+ * than in its own layer.
+ * @attribute inlineMenu
+ * @type boolean
+ */
+ inlineMenu: false,
+ /**
+ * Horizontally align the overlay with the button. Accepted values are
+ * ["left", "center", "right"].
+ * @attribute halign
+ * @type string
+ */
+ halign: 'center',
+ /**
+ * Display the overlay on top or below the button. Accepted values are
+ * ["top", "bottom"].
+ * @attribute valign
+ * @type string
+ */
+ valign: 'bottom',
+ multi: false,
+ closeAction: function() {
+ this.opened = false;
+ },
+ /**
+ * Toggle the opened state of the dropdown.
+ * @method toggle
+ */
+ toggle: function() {
+ this.opened = !this.opened;
+ },
+ /**
+ * The selected menu item.
+ * @property selection
+ * @type Node
+ */
+ get selection() {
+ return this.$.menu.selection;
+ }
+ });
+

Powered by Google App Engine
This is Rietveld 408576698