You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by mo...@apache.org on 2019/04/01 02:47:12 UTC

[incubator-weex] branch master updated: [iOS] Fire event when span within an a-label is clicked.

This is an automated email from the ASF dual-hosted git repository.

moshen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-weex.git


The following commit(s) were added to refs/heads/master by this push:
     new cce5b0c  [iOS] Fire event when span within an a-label is clicked.
     new 469ab31  Merge pull request #2260 from sunshl/bugfix_pseudo
cce5b0c is described below

commit cce5b0ca756c9920eeca9f79d2b9e4397ef101fa
Author: huanglei.hl <hu...@alibaba-inc.com>
AuthorDate: Thu Mar 28 17:59:16 2019 +0800

    [iOS] Fire event when span within an a-label is clicked.
    
    * feature: If a span is clicked which is in an a-label of a richtext component, an itemclick event will be fired.
    * demo: http://editor.weex.io/p/sunshl/Contribute/commit/b21e1133830b48767c6d00d712e415b2
    * doc pr: apache/incubator-weex-site#362
---
 ios/sdk/WeexSDK/Sources/Component/WXRichText.mm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/ios/sdk/WeexSDK/Sources/Component/WXRichText.mm b/ios/sdk/WeexSDK/Sources/Component/WXRichText.mm
index 2b1ba96..93bb876 100644
--- a/ios/sdk/WeexSDK/Sources/Component/WXRichText.mm
+++ b/ios/sdk/WeexSDK/Sources/Component/WXRichText.mm
@@ -198,6 +198,9 @@ do {\
     }
     else if (superNode.href) {
         node.href = superNode.href;
+        if (!(node.pseudoRef.length) && superNode.pseudoRef.length) {
+            node.pseudoRef = superNode.pseudoRef;
+        }
     }
     
     if (attributes[@"src"]) {