Skip to content

Commit

Permalink
Merge pull request #13 from contentstack/next
Browse files Browse the repository at this point in the history
Next : href linking issue fixed
  • Loading branch information
ishaileshmishra authored Nov 20, 2023
2 parents 38b62ce + a5be7d3 commit 4171564
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 26 deletions.
11 changes: 0 additions & 11 deletions .github/workflows/sast-scan.yml

This file was deleted.

11 changes: 0 additions & 11 deletions .github/workflows/secrets-scan.yml

This file was deleted.

2 changes: 1 addition & 1 deletion ContentstackUtils.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'ContentstackUtils'
s.version = '1.3.0'
s.version = '1.3.1'
s.summary = 'Contentstack is a headless CMS with an API-first approach that puts content at the centre.'

s.description = <<-DESC
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ To use this SDK on iOS platform, you will have to install the SDK according to t
Add the following to your Podfile:

use_frameworks!
pod 'ContentstackUtils', '~> 1.2.1'
pod 'ContentstackUtils', '~> 1.3.1'

#### Swift Package Manager
1. Installing libxml2 to your computer:
Expand All @@ -41,7 +41,7 @@ Add the following to your Podfile:
let package = Package(
name: "YourProject",
dependencies: [
.package(url: "https://github.com/tid-kijyun/ContentstackUtils.git", from: "1.2.1"),
.package(url: "https://github.com/tid-kijyun/ContentstackUtils.git", from: "1.3.1"),
],
targets: [
.target(
Expand Down
2 changes: 1 addition & 1 deletion Sources/ContentstackUtils/Option.swift
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ open class Option: Renderable {
case NodeType.paragraph.rawValue:
return "<p>\(next(node.children))</p>"
case NodeType.link.rawValue:
return "<a href=\"\(node.attrs["href"] ?? "")\">\(next(node.children))</a>"
return "<a href=\"\(node.attrs["href"] ?? node.attrs["url"] ?? "")\">\(next(node.children))</a>"
case NodeType.image.rawValue:
return "<img src=\"\(node.attrs["src"] ?? node.attrs["asset-link"] ?? "")\" />\(next(node.children))"
case NodeType.embed.rawValue:
Expand Down

0 comments on commit 4171564

Please sign in to comment.