Problem/Motivation

Sometimes (specially when content comes from other sources) it would be useful to convert plain URLs to tags that can be later picked up by the default filter and converted to embeds.

Proposed resolution

Add a filter that does that.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

slashrsm created an issue. See original summary.

slashrsm’s picture

Status: Active » Needs review
FileSize
7.22 KB
slashrsm’s picture

FileSize
13.12 KB
8.64 KB

Added optional prefix that triggers conversions.

PR for tests: https://github.com/drupal-media/url_embed/pull/32

thenchev’s picture

Status: Needs review » Needs work
+++ b/src/Tests/ConvertUrlToEmbedFilterTest.php
@@ -0,0 +1,134 @@
+use Drupal\video_embed_field\Tests\WebTestBase;

Wrong use statement.

+++ b/src/Plugin/Filter/ConvertUrlToEmbedFilter.php
@@ -0,0 +1,191 @@
+      '#title' => $this->t('URL prefox'),

typo

slashrsm’s picture

Status: Needs work » Needs review
FileSize
13.1 KB
1.29 KB
thenchev’s picture

Status: Needs review » Reviewed & tested by the community

Its passing on the pull request. Looks good to go.

slashrsm’s picture

Status: Reviewed & tested by the community » Fixed

Committed.

  • slashrsm committed 6554740 on 8.x-1.x
    Issue #2733385 by slashrsm, Denchev: Add a text filter that converts...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.