No commit activity in last 3 years
No release in over 3 years
An HTML::Pipeline filter converting Trix-compliant YouTube or Vimeo preview figures into URLs
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.10
>= 0
~> 10.0

Runtime

 Project Readme

HTML::Pipeline Trix Video

This project is intended to provide a filter that will take Trix-produced content as input, find <figure> tags that hold onto image previews taken from YouTube or Vimeo videos, and convert those into raw YouTube or Vimeo video URLs.

The intention is that this returned URL can then be filtered through html-pipeline-vimeo and html-pipeline-youtube in order to display embedded videos in Trix-produced content.

This is based off of the work-flow suggested in Trix's Issue 206.

Installation

Add this line to your application's Gemfile:

gem 'html-pipeline'
gem 'html-pipeline-trix-video'

And then execute:

$ bundle

Or install it yourself as:

$ gem install html-pipeline-trix-video

Usage

You can add HTML::Pipeline::TrixVideoFilter into your pipeline like this:

pipeline = HTML::Pipeline.new [
  HTML::Pipeline::TrixVideoFilter,
  HTML::Pipeline::VimeoFilter
]

result = pipeline.call(text)

See html-pipeline.