bradyvercher / gistpress

WordPress plugin to add Gist oEmbed and shortcode support with caching.
GNU General Public License v2.0
143 stars 28 forks source link

Add GistPress block for Gutenberg #75

Closed GaryJones closed 1 year ago

GaryJones commented 7 years ago

The new Gutenberg editor seems ripe for us to consider adding a GistPress Embed block, with all of the current shortcode attributes mapped to block attributes.

Expected Behavior

Quick couple of mockups, as example:

screenshot 2017-06-19 13 04 19 screenshot 2017-06-19 13 10 50

Current Behavior

None

Possible Solution

Gists inserted with GistPress naturally fit into the block system that Gutenberg uses.

Steps to Produce

  1. Decide on whether the neutral view (after first inserting a block) should ask for the Gist ID / URL (like the Embed block asks for a URL).
  2. Register block, attributes.
  3. Display attributes in settings panel, with any descriptions as needed.
  4. Try and get a basic preview working.
  5. Adapt preview to represent what the block attributes are set as.
  6. Support width / alignment attributes like image blocks do?
  7. Don't break when used on a site that doesn't use Gutenberg Editor.
GaryJones commented 5 years ago

Linking to https://github.com/pantheon-systems/github-gist-gutenberg-block/issues/5#issuecomment-433203303 as a possible starting point for a GistPress block.

redrockapps commented 5 years ago

Here's a plugin of mine that adds Gist ability to the Gutenberg Editor for reference: Gistr WP Plugin

westerdaled commented 5 years ago

Tried both the Gistr ( embed block) & GistPress ( html block) . Both impressive, with the former having the edge through ease of use. Maybe you should combine code bases 😉