Skip to content

Conversation

@bfintal
Copy link
Contributor

@bfintal bfintal commented Feb 16, 2015

Added type color, uses WordPress' native color picker and created a new template for the new field.

I don't know where to put the initializing js though, so I added it to the template file. I also used jQuery('[id="{{ data.attr }}"]') instead of just specifying the ID via #{{ data.attr }} since that did not work when the shortcode is edited multiple times since the first initialization no longer exists on the succeeding call.

We need the color option for our: Page Builder Sandwich

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should only load these if a colorpicker field type has been used.

@bfintal
Copy link
Contributor Author

bfintal commented Feb 18, 2015

Revamped how the color field was included, now included the same way as #146

Much cleaner now

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can just do this.$el.find() here

@mattheu
Copy link
Contributor

mattheu commented Feb 18, 2015

Looking great

One small comment on the styling. This rule .media-frame a { border-bottom: none } in media-views.css is removing the border - which is a little annoying.

I think the only solution is to add a style to the shortcake CSS to fix this

@bfintal
Copy link
Contributor Author

bfintal commented Feb 18, 2015

@mattheu all done :) Also added in the attribute checker. Might be beneficial if that function was ported over to the Shortcode_UI class so other fields can use it.

@bfintal
Copy link
Contributor Author

bfintal commented Feb 18, 2015

@mattheu Good catch on the bottom border, I must be going blind 👍

@danielbachhuber danielbachhuber added this to the v0.2.0 milestone Feb 18, 2015
@danielbachhuber
Copy link
Contributor

👍 Thanks for your work on this, @bfintal

danielbachhuber added a commit that referenced this pull request Feb 18, 2015
@danielbachhuber danielbachhuber merged commit ace5c35 into wp-shortcake:master Feb 18, 2015
@mattheu
Copy link
Contributor

mattheu commented Feb 18, 2015

Might be beneficial if that function was ported over to the Shortcode_UI class so other fields can use it.

+1 see #173

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants