From 5d9d72df003c61c7d49c000ade31161e5bc7411a Mon Sep 17 00:00:00 2001 From: Thaum Date: Fri, 30 Jan 2015 10:55:35 +0000 Subject: [PATCH] Updated Feature edit style --- .../features/featureDialog/featureDialog.html | 29 ++++++++++--------- .../features/featureDialog/featureDialog.js | 10 +++++++ .../features/featureDialog/featuresDialog.css | 1 + 3 files changed, 27 insertions(+), 13 deletions(-) diff --git a/rpg-docs/client/views/character/features/featureDialog/featureDialog.html b/rpg-docs/client/views/character/features/featureDialog/featureDialog.html index bf396619..8dbcdc1c 100644 --- a/rpg-docs/client/views/character/features/featureDialog/featureDialog.html +++ b/rpg-docs/client/views/character/features/featureDialog/featureDialog.html @@ -4,27 +4,30 @@
{{name}}
- - - - Delete Feature - Cancel - - +
+
-

Effects

- {{#each effects}} - {{>effectEdit}} - {{/each}} -
- Add Effect +
+
+

Effects

+ {{#each effects}} + {{>effectEdit}} + {{/each}} +
+ Add Effect +
diff --git a/rpg-docs/client/views/character/features/featureDialog/featureDialog.js b/rpg-docs/client/views/character/features/featureDialog/featureDialog.js index e6be56e6..f6fa1d92 100644 --- a/rpg-docs/client/views/character/features/featureDialog/featureDialog.js +++ b/rpg-docs/client/views/character/features/featureDialog/featureDialog.js @@ -4,6 +4,16 @@ Template.featureDialog.rendered = function(){ var feature = Features.findOne(Template.currentData().featureId, {fields: {name: 1}}); if(feature && feature.name) Session.set("global.ui.dialogHeader", feature.name); }) + //update all autogrows after they've been filled + var pata = this.$("paper-autogrow-textarea"); + pata.each(function(index, el){ + el.update($(el).children().get(0)); + }) + //update all input fields as well + var input = this.$("paper-input"); + input.each(function(index, el){ + el.valueChanged(); + }) //after the dialog is built, open it if (!this.alreadyRendered){ Session.set("global.ui.detailShow", true); diff --git a/rpg-docs/client/views/character/features/featureDialog/featuresDialog.css b/rpg-docs/client/views/character/features/featureDialog/featuresDialog.css index ea3c7112..2d1c82d4 100644 --- a/rpg-docs/client/views/character/features/featureDialog/featuresDialog.css +++ b/rpg-docs/client/views/character/features/featureDialog/featuresDialog.css @@ -9,4 +9,5 @@ body /deep/ .featureDialogWidth { #addEffectButton { background: #d23f31; color: #fff; + margin-top: 16px; }