Closed kennyjwilli closed 9 years ago
As the title says, when you create a paper-button programmatically the button does not realize its content. It will not center the text and the iron-icon rendered inside the paper-button does not appear.
paper-button
iron-icon
<!doctype html> <html lang=""> <head> <title>sandbox</title> <link rel="import" href="bower_components/polymer/polymer.html"> <link rel="import" href="bower_components/paper-button/paper-button.html"> <link rel="import" href="bower_components/iron-icon/iron-icon.html"> <link rel="import" href="bower_components/iron-icons/iron-icons.html"> </head> <body unresolved class="fullbleed"> <paper-button> <iron-icon icon="send"></iron-icon> Test </paper-button> <script type="text/javascript"> var btn = document.createElement("paper-button"); var icon = document.createElement("iron-icon"); icon.icon = "send"; btn.appendChild(icon); btn.innerHTML = btn.innerHTML + "new"; document.body.appendChild(btn); </script> </body> </html>
As the title says, when you create a
paper-button
programmatically the button does not realize its content. It will not center the text and theiron-icon
rendered inside thepaper-button
does not appear.