Skip to content

App 内置示例

这一页只收录 APK / 已导出源码里已经出现的原文示例,不做改写。

1. RichUI 内置模板

这些模板字符串来自:

  • ../../apk_jadx/sources/com/tencent/mobileqq/aio/msglist/holder/component/template/template/j.java
  • ../../apk_jadx/sources/com/tencent/mobileqq/aio/msglist/holder/component/template/template/k.java

1.1 com.tencent.public.function.warn

json
{
  "version": 1,
  "templateId": "com.tencent.public.function.warn",
  "layout": {
    "viewId": "app",
    "width": -1,
    "height": -2,
    "direction": "vertical",
    "layout": [
      {
        "viewId": "header",
        "direction": "horizontal",
        "marginLeft": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "appIcon",
            "viewType": "image",
            "marginTop": 12,
            "marginBottom": 12,
            "height": 24,
            "width": 24,
            "gravity": "centerVertical"
          },
          {
            "viewId": "appName",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 12,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          }
        ]
      },
      {
        "viewId": "divider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1
      },
      {
        "viewId": "titleArea",
        "direction": "horizontal",
        "marginLeft": 16,
        "marginTop": 24,
        "marginRight": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "title",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "gravity": "centerVertical"
          }
        ]
      },
      {
        "viewId": "contentArea",
        "direction": "vertical",
        "marginLeft": 16,
        "marginTop": 20,
        "marginRight": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "contentText",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "maxLine": 3
          }
        ]
      },
      {
        "viewId": "operationItemDivider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1,
        "marginTop": 24,
        "marginLeft": 12,
        "marginRight": 12
      },
      {
        "viewId": "operationItem1",
        "direction": "horizontal",
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "operationText1",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 16,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          },
          {
            "viewId": "arrowIcon1",
            "viewType": "image",
            "height": 16,
            "width": 16,
            "marginTop": 12,
            "marginBottom": 12,
            "marginRight": 16,
            "gravity": "centerVertical|right"
          }
        ]
      }
    ]
  },
  "attributes": {
    "viewId": "app",
    "radius": 12,
    "backgroundColor": "bubble_guest",
    "clickable": true,
    "schema": "$$jumpUrl",
    "attributes": [
      {
        "viewId": "header",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "schema": "$$appJumpUrl",
        "attributes": [
          {
            "viewId": "appIcon",
            "src": "$$appIcon",
            "radius": 12
          },
          {
            "viewId": "appName",
            "text": "$$appName",
            "textSize": 16,
            "textColor": "bubble_guest_text_primary",
            "maxLine": 1
          }
        ]
      },
      {
        "viewId": "divider1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "backgroundColor": "border_standard"
      },
      {
        "viewId": "titleArea",
        "attributes": [
          {
            "viewId": "title",
            "text": "$$title",
            "textSize": 17,
            "textColor": "bubble_guest_text_primary",
            "fontBold": true,
            "maxLine": 1
          }
        ]
      },
      {
        "viewId": "contentArea",
        "attributes": [
          {
            "viewId": "contentText",
            "text": "$$contentText",
            "textSize": 16,
            "textColor": "bubble_guest_text_primary",
            "maxLine": 4
          }
        ]
      },
      {
        "viewId": "operationItemDivider1",
        "backgroundColor": "border_standard",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationJump1",
              "visibleBehave": "GONE",
              "src": "$$operationJump1"
            }
          }
        }
      },
      {
        "viewId": "operationItem1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationJump1",
              "visibleBehave": "GONE",
              "src": "$$operationJump1"
            }
          }
        },
        "clickable": true,
        "schema": "$$operationJump1",
        "attributes": [
          {
            "viewId": "operationText1",
            "text": "$$operationText1",
            "maxLine": 1,
            "textSize": 14,
            "textColor": "bubble_guest_text_primary"
          },
          {
            "viewId": "arrowIcon1",
            "src": "$$operationIcon1"
          }
        ]
      }
    ]
  }
}

1.2 com.tencent.public.function.pay

json
{
  "version": 1,
  "templateId": "com.tencent.public.function.pay",
  "layout": {
    "viewId": "app",
    "width": -1,
    "height": -2,
    "direction": "vertical",
    "layout": [
      {
        "viewId": "header",
        "direction": "horizontal",
        "marginLeft": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "appIcon",
            "viewType": "image",
            "marginTop": 12,
            "marginBottom": 12,
            "height": 24,
            "width": 24,
            "gravity": "centerVertical"
          },
          {
            "viewId": "appName",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 12,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          }
        ]
      },
      {
        "viewId": "divider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1
      },
      {
        "viewId": "titleArea",
        "direction": "horizontal",
        "marginLeft": 16,
        "marginTop": 24,
        "marginRight": 16,
        "marginBottom": 12,
        "height": -2,
        "width": -2,
        "layout": [
          {
            "viewId": "title",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "gravity": "centerVertical"
          }
        ]
      },
      {
        "viewId": "contentArea",
        "direction": "vertical",
        "marginLeft": 16,
        "marginTop": 20,
        "marginRight": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "contentText",
            "viewType": "text",
            "height": -2,
            "width": -2,
            "gravity": "centerHorizontal"
          },
          {
            "viewId": "money",
            "viewType": "text",
            "marginTop": 12,
            "height": -2,
            "width": -2,
            "gravity": "centerHorizontal"
          }
        ]
      },
      {
        "viewId": "infoItems",
        "direction": "horizontal",
        "marginLeft": 16,
        "marginRight": 16,
        "marginTop": 20,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "infoItemTitles",
            "direction": "vertical",
            "height": -2,
            "width": -2,
            "marginRight": 12,
            "layout": [
              {
                "viewId": "infoItemTitle1",
                "viewType": "text",
                "height": -2,
                "width": -2
              },
              {
                "viewId": "infoItemTitle2",
                "viewType": "text",
                "height": -2,
                "width": -2,
                "marginTop": 12
              },
              {
                "viewId": "infoItemTitle3",
                "viewType": "text",
                "height": -2,
                "width": -2,
                "marginTop": 12
              },
              {
                "viewId": "infoItemTitle4",
                "viewType": "text",
                "height": -2,
                "width": -2,
                "marginTop": 12
              }
            ]
          },
          {
            "viewId": "infoItemDeses",
            "direction": "vertical",
            "height": -2,
            "width": -1,
            "layout": [
              {
                "viewId": "infoItemDes1",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "infoItemDes2",
                "viewType": "text",
                "height": -2,
                "width": -1,
                "marginTop": 12
              },
              {
                "viewId": "infoItemDes3",
                "viewType": "text",
                "height": -2,
                "width": -1,
                "marginTop": 12
              },
              {
                "viewId": "infoItemDes4",
                "viewType": "text",
                "height": -2,
                "width": -1,
                "marginTop": 12
              }
            ]
          }
        ]
      },
      {
        "viewId": "operationItemDivider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1,
        "marginLeft": 12,
        "marginRight": 12,
        "marginTop": 24
      },
      {
        "viewId": "operationItem1",
        "direction": "horizontal",
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "operationText1",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 16,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          },
          {
            "viewId": "arrowIcon1",
            "viewType": "image",
            "height": 16,
            "width": 16,
            "marginTop": 12,
            "marginBottom": 12,
            "marginRight": 16,
            "gravity": "centerVertical|right"
          }
        ]
      }
    ]
  },
  "attributes": {
    "viewId": "app",
    "radius": 12,
    "backgroundColor": "bubble_guest",
    "clickable": true,
    "schema": "$$jumpUrl",
    "attributes": [
      {
        "viewId": "header",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "schema": "$$appJumpUrl",
        "attributes": [
          {
            "viewId": "appIcon",
            "src": "$$appIcon",
            "radius": 12
          },
          {
            "viewId": "appName",
            "text": "$$appName",
            "textSize": 16,
            "textColor": "bubble_guest_text_primary",
            "maxLine": 1
          }
        ]
      },
      {
        "viewId": "divider1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "backgroundColor": "border_standard"
      },
      {
        "viewId": "titleArea",
        "attributes": [
          {
            "viewId": "title",
            "text": "$$title",
            "textSize": 17,
            "textColor": "bubble_guest_text_primary",
            "fontBold": true,
            "maxLine": 1
          }
        ]
      },
      {
        "viewId": "contentArea",
        "attributes": [
          {
            "viewId": "contentText",
            "text": "$$contentText",
            "textSize": 16,
            "textColor": "bubble_guest_text_secondary",
            "maxLine": 1
          },
          {
            "viewId": "money",
            "text": "$$money",
            "textSize": 46,
            "textColor": "bubble_guest_text_primary",
            "fontBold": true,
            "maxLine": 1
          }
        ]
      },
      {
        "viewId": "infoItems",
        "attributes": [
          {
            "viewId": "infoItemTitles",
            "attributes": [
              {
                "viewId": "infoItemTitle1",
                "text": "$$infoItemTitle1",
                "textSize": 16,
                "textColor": "bubble_guest_text_secondary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemTitle1",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemTitle1"
                    }
                  }
                }
              },
              {
                "viewId": "infoItemTitle2",
                "text": "$$infoItemTitle2",
                "textSize": 16,
                "textColor": "bubble_guest_text_secondary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemTitle2",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemTitle2"
                    }
                  }
                }
              },
              {
                "viewId": "infoItemTitle3",
                "text": "$$infoItemTitle3",
                "textSize": 16,
                "textColor": "bubble_guest_text_secondary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemTitle3",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemTitle3"
                    }
                  }
                }
              },
              {
                "viewId": "infoItemTitle4",
                "text": "$$infoItemTitle4",
                "textSize": 16,
                "textColor": "bubble_guest_text_secondary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemTitle4",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemTitle4"
                    }
                  }
                }
              }
            ]
          },
          {
            "viewId": "infoItemDeses",
            "attributes": [
              {
                "viewId": "infoItemDes1",
                "text": "$$infoItemDes1",
                "textSize": 16,
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemDes1",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemDes1"
                    }
                  }
                }
              },
              {
                "viewId": "infoItemDes2",
                "text": "$$infoItemDes2",
                "textSize": 16,
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemDes2",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemDes2"
                    }
                  }
                }
              },
              {
                "viewId": "infoItemDes3",
                "text": "$$infoItemDes3",
                "textSize": 16,
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemDes3",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemDes3"
                    }
                  }
                }
              },
              {
                "viewId": "infoItemDes4",
                "text": "$$infoItemDes4",
                "textSize": 16,
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$infoItemDes4",
                      "visibleBehave": "GONE",
                      "src": "$$infoItemDes4"
                    }
                  }
                }
              }
            ]
          }
        ]
      },
      {
        "viewId": "operationItemDivider1",
        "backgroundColor": "border_standard",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationJump1",
              "visibleBehave": "GONE",
              "src": "$$operationJump1"
            }
          }
        }
      },
      {
        "viewId": "operationItem1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationJump1",
              "visibleBehave": "GONE",
              "src": "$$operationJump1"
            }
          }
        },
        "clickable": true,
        "schema": "$$operationJump1",
        "attributes": [
          {
            "viewId": "operationText1",
            "text": "$$operationText1",
            "maxLine": 1,
            "textSize": 14,
            "textColor": "bubble_guest_text_primary"
          },
          {
            "viewId": "arrowIcon1",
            "src": "$$operationIcon1"
          }
        ]
      }
    ]
  }
}

1.3 com.tencent.public.game.list

json
{
  "version": 1,
  "templateId": "com.tencent.public.game.list",
  "layout": {
    "viewId": "app",
    "width": -1,
    "height": -2,
    "direction": "vertical",
    "layout": [
      {
        "viewId": "header",
        "direction": "horizontal",
        "marginLeft": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "appIcon",
            "viewType": "image",
            "marginTop": 12,
            "marginBottom": 12,
            "height": 24,
            "width": 24,
            "gravity": "centerVertical"
          },
          {
            "viewId": "appName",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 12,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          },
          {
            "viewId": "more",
            "height": -2,
            "width": -2,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "right|centerVertical",
            "layout": [
              {
                "viewId": "moreIcon",
                "viewType": "image",
                "height": 24,
                "width": 24,
                "marginLeft": 16,
                "marginRight": 16
              }
            ]
          }
        ]
      },
      {
        "viewId": "divider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1
      },
      {
        "viewId": "operationItem1",
        "height": -2,
        "width": -1,
        "marginRight": 16,
        "marginLeft": 16,
        "marginBottom": 12,
        "marginTop": 12,
        "direction": "horizontal",
        "layout": [
          {
            "viewId": "operationContent1",
            "height": -2,
            "width": -1,
            "direction": "vertical",
            "gravity": "centerVertical",
            "marginRight": 6,
            "layout": [
              {
                "viewId": "operationTitle1",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "operationTime1",
                "viewType": "text",
                "width": -1,
                "height": -2,
                "marginTop": 4
              }
            ]
          },
          {
            "viewId": "operationImage1",
            "viewType": "image",
            "gravity": "right",
            "height": 60,
            "width": 60
          }
        ]
      },
      {
        "viewId": "operationItemDivider2",
        "viewType": "image",
        "height": 0.5,
        "width": -1,
        "marginLeft": 16,
        "marginRight": 88
      },
      {
        "viewId": "operationItem2",
        "height": -2,
        "width": -1,
        "marginRight": 16,
        "marginLeft": 16,
        "marginBottom": 12,
        "marginTop": 12,
        "direction": "horizontal",
        "layout": [
          {
            "viewId": "operationContent2",
            "height": -2,
            "width": -1,
            "marginRight": 6,
            "direction": "vertical",
            "gravity": "centerVertical",
            "layout": [
              {
                "viewId": "operationTitle2",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "operationTime2",
                "viewType": "text",
                "width": -1,
                "height": -2,
                "marginTop": 4
              }
            ]
          },
          {
            "viewId": "operationImage2",
            "viewType": "image",
            "gravity": "right",
            "height": 60,
            "width": 60
          }
        ]
      },
      {
        "viewId": "operationItemDivider3",
        "viewType": "image",
        "height": 0.5,
        "width": -1,
        "marginLeft": 16,
        "marginRight": 88
      },
      {
        "viewId": "operationItem3",
        "height": -2,
        "width": -1,
        "marginRight": 16,
        "marginLeft": 16,
        "marginBottom": 12,
        "marginTop": 12,
        "direction": "horizontal",
        "layout": [
          {
            "viewId": "operationContent3",
            "height": -2,
            "width": -1,
            "marginRight": 6,
            "direction": "vertical",
            "gravity": "centerVertical",
            "layout": [
              {
                "viewId": "operationTitle3",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "operationTime3",
                "viewType": "text",
                "width": -1,
                "height": -2,
                "marginTop": 4
              }
            ]
          },
          {
            "viewId": "operationImage3",
            "viewType": "image",
            "gravity": "right",
            "height": 60,
            "width": 60
          }
        ]
      },
      {
        "viewId": "operationItemDivider4",
        "viewType": "image",
        "height": 0.5,
        "width": -1,
        "marginLeft": 16,
        "marginRight": 88
      },
      {
        "viewId": "operationItem4",
        "height": -2,
        "width": -1,
        "marginRight": 16,
        "marginLeft": 16,
        "marginBottom": 12,
        "marginTop": 12,
        "direction": "horizontal",
        "layout": [
          {
            "viewId": "operationContent4",
            "height": -2,
            "width": -1,
            "marginRight": 6,
            "direction": "vertical",
            "gravity": "centerVertical",
            "layout": [
              {
                "viewId": "operationTitle4",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "operationTime4",
                "viewType": "text",
                "width": -1,
                "height": -2,
                "marginTop": 4
              }
            ]
          },
          {
            "viewId": "operationImage4",
            "viewType": "image",
            "height": 60,
            "gravity": "right",
            "width": 60
          }
        ]
      },
      {
        "viewId": "operationItemDivider5",
        "viewType": "image",
        "height": 0.5,
        "width": -1,
        "marginLeft": 16,
        "marginRight": 88
      },
      {
        "viewId": "operationItem5",
        "height": -2,
        "width": -1,
        "marginRight": 16,
        "marginLeft": 16,
        "marginBottom": 12,
        "marginTop": 12,
        "direction": "horizontal",
        "layout": [
          {
            "viewId": "operationContent5",
            "height": -2,
            "width": -1,
            "marginRight": 6,
            "direction": "vertical",
            "gravity": "centerVertical",
            "layout": [
              {
                "viewId": "operationTitle5",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "operationTime5",
                "viewType": "text",
                "width": -1,
                "height": -2,
                "marginTop": 4
              }
            ]
          },
          {
            "viewId": "operationImage5",
            "viewType": "image",
            "height": 60,
            "gravity": "right",
            "width": 60
          }
        ]
      }
    ]
  },
  "attributes": {
    "viewId": "app",
    "radius": 10,
    "backgroundColor": "bubble_guest",
    "clickable": true,
    "schema": "$$jumpUrl",
    "attributes": [
      {
        "viewId": "header",
        "schema": "$$appJumpUrl",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "attributes": [
          {
            "viewId": "appIcon",
            "src": "$$appIcon",
            "radius": 12
          },
          {
            "viewId": "appName",
            "text": "$$appName",
            "textSize": 16,
            "textColor": "bubble_guest_text_primary",
            "maxLine": 1
          },
          {
            "viewId": "more",
            "attributes": [
              {
                "viewId": "moreIcon",
                "src": "$$moreIcon"
              }
            ],
            "clickable": true,
            "schema": "$$moreJump",
            "event": {
              "init": {
                "visibleCtr": {
                  "visible": "$$moreJump",
                  "visibleBehave": "GONE",
                  "src": "$$moreJump"
                }
              }
            }
          }
        ]
      },
      {
        "viewId": "divider1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "backgroundColor": "border_standard"
      },
      {
        "viewId": "operationItem1",
        "schema": "$$operationJumpUrl1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle1",
              "visibleBehave": "GONE",
              "src": "$$operationTitle1"
            }
          }
        },
        "attributes": [
          {
            "viewId": "operationContent1",
            "attributes": [
              {
                "viewId": "operationTitle1",
                "text": "$$operationTitle1",
                "textColor": "bubble_guest_text_primary",
                "textSize": 17,
                "maxLine": 1
              },
              {
                "viewId": "operationTime1",
                "text": "$$operationTime1",
                "textSize": 16,
                "textColor": "text_secondary",
                "maxLine": 1
              }
            ]
          },
          {
            "viewId": "operationImage1",
            "src": "$$operationImage1",
            "contentMode": 2,
            "radius": 6
          }
        ]
      },
      {
        "viewId": "operationItemDivider2",
        "backgroundColor": "border_standard",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle2",
              "visibleBehave": "GONE",
              "src": "$$operationTitle2"
            }
          }
        }
      },
      {
        "viewId": "operationItem2",
        "schema": "$$operationJumpUrl2",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle2",
              "visibleBehave": "GONE",
              "src": "$$operationTitle2"
            }
          }
        },
        "attributes": [
          {
            "viewId": "operationContent2",
            "attributes": [
              {
                "viewId": "operationTitle2",
                "text": "$$operationTitle2",
                "textColor": "bubble_guest_text_primary",
                "textSize": 17,
                "maxLine": 1
              },
              {
                "viewId": "operationTime2",
                "text": "$$operationTime2",
                "textSize": 16,
                "textColor": "text_secondary",
                "maxLine": 1
              }
            ]
          },
          {
            "viewId": "operationImage2",
            "src": "$$operationImage2",
            "contentMode": 2,
            "radius": 6
          }
        ]
      },
      {
        "viewId": "operationItemDivider3",
        "backgroundColor": "border_standard",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle3",
              "visibleBehave": "GONE",
              "src": "$$operationTitle3"
            }
          }
        }
      },
      {
        "viewId": "operationItem3",
        "schema": "$$operationJumpUrl3",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle3",
              "visibleBehave": "GONE",
              "src": "$$operationTitle3"
            }
          }
        },
        "attributes": [
          {
            "viewId": "operationContent3",
            "attributes": [
              {
                "viewId": "operationTitle3",
                "text": "$$operationTitle3",
                "textColor": "bubble_guest_text_primary",
                "textSize": 17,
                "maxLine": 1
              },
              {
                "viewId": "operationTime3",
                "text": "$$operationTime3",
                "textSize": 16,
                "textColor": "text_secondary",
                "maxLine": 1
              }
            ]
          },
          {
            "viewId": "operationImage3",
            "src": "$$operationImage3",
            "contentMode": 2,
            "radius": 6
          }
        ]
      },
      {
        "viewId": "operationItemDivider4",
        "backgroundColor": "border_standard",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle4",
              "visibleBehave": "GONE",
              "src": "$$operationTitle4"
            }
          }
        }
      },
      {
        "viewId": "operationItem4",
        "schema": "$$operationJumpUrl4",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle4",
              "visibleBehave": "GONE",
              "src": "$$operationTitle4"
            }
          }
        },
        "attributes": [
          {
            "viewId": "operationContent4",
            "attributes": [
              {
                "viewId": "operationTitle4",
                "text": "$$operationTitle4",
                "textColor": "bubble_guest_text_primary",
                "textSize": 17,
                "maxLine": 1
              },
              {
                "viewId": "operationTime4",
                "text": "$$operationTime4",
                "textSize": 16,
                "textColor": "text_secondary",
                "maxLine": 1
              }
            ]
          },
          {
            "viewId": "operationImage4",
            "src": "$$operationImage4",
            "contentMode": 2,
            "radius": 6
          }
        ]
      },
      {
        "viewId": "operationItemDivider5",
        "backgroundColor": "border_standard",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle5",
              "visibleBehave": "GONE",
              "src": "$$operationTitle5"
            }
          }
        }
      },
      {
        "viewId": "operationItem5",
        "schema": "$$operationJumpUrl5",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle5",
              "visibleBehave": "GONE",
              "src": "$$operationTitle5"
            }
          }
        },
        "attributes": [
          {
            "viewId": "operationContent5",
            "attributes": [
              {
                "viewId": "operationTitle5",
                "text": "$$operationTitle5",
                "textColor": "bubble_guest_text_primary",
                "textSize": 17,
                "maxLine": 1
              },
              {
                "viewId": "operationTime5",
                "text": "$$operationTime5",
                "textSize": 16,
                "textColor": "text_secondary",
                "maxLine": 1
              }
            ]
          },
          {
            "viewId": "operationImage5",
            "src": "$$operationImage5",
            "contentMode": 2,
            "radius": 6
          }
        ]
      }
    ]
  }
}

1.4 com.tencent.public.game.simple

json
{
  "version": 1,
  "templateId": "com.tencent.public.game.simple",
  "layout": {
    "viewId": "app",
    "width": -1,
    "height": -2,
    "direction": "vertical",
    "layout": [
      {
        "viewId": "header",
        "direction": "horizontal",
        "marginLeft": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "appIcon",
            "viewType": "image",
            "marginTop": 12,
            "marginBottom": 12,
            "height": 24,
            "width": 24,
            "gravity": "centerVertical"
          },
          {
            "viewId": "appName",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 12,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          },
          {
            "viewId": "more",
            "height": -2,
            "width": -2,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "right|centerVertical",
            "layout": [
              {
                "viewId": "moreIcon",
                "viewType": "image",
                "height": 24,
                "width": 24,
                "marginLeft": 16,
                "marginRight": 16
              }
            ]
          }
        ]
      },
      {
        "viewId": "divider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1
      },
      {
        "viewId": "content",
        "direction": "horizontal",
        "height": -2,
        "width": -1,
        "marginTop": 12,
        "marginBottom": 12,
        "marginRight": 16,
        "marginLeft": 16,
        "layout": [
          {
            "viewId": "contentLeft",
            "height": -2,
            "width": -1,
            "gravity": "centerVertical",
            "direction": "vertical",
            "layout": [
              {
                "viewId": "titleArea",
                "direction": "horizontal",
                "height": -2,
                "width": -1,
                "layout": [
                  {
                    "viewId": "title",
                    "viewType": "text",
                    "height": -2,
                    "width": -1,
                    "gravity": "centerVertical"
                  }
                ]
              },
              {
                "viewId": "time",
                "viewType": "text",
                "width": -1,
                "height": -2,
                "marginTop": 4
              }
            ]
          },
          {
            "viewId": "contentRight",
            "marginLeft": 7,
            "viewType": "image",
            "width": 60,
            "height": 60,
            "gravity": "centerVertical|right"
          }
        ]
      }
    ]
  },
  "attributes": {
    "viewId": "app",
    "radius": 10,
    "backgroundColor": "bubble_guest",
    "clickable": true,
    "schema": "$$jumpUrl",
    "attributes": [
      {
        "viewId": "header",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "schema": "$$appJumpUrl",
        "attributes": [
          {
            "viewId": "appIcon",
            "src": "$$appIcon",
            "radius": 12
          },
          {
            "viewId": "appName",
            "text": "$$appName",
            "textSize": 16,
            "textColor": "bubble_guest_text_primary",
            "maxLine": 1
          },
          {
            "viewId": "more",
            "attributes": [
              {
                "viewId": "moreIcon",
                "src": "$$moreIcon"
              }
            ],
            "clickable": true,
            "schema": "$$moreJump",
            "event": {
              "init": {
                "visibleCtr": {
                  "visible": "$$moreJump",
                  "visibleBehave": "GONE",
                  "src": "$$moreJump"
                }
              }
            }
          }
        ]
      },
      {
        "viewId": "divider1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "backgroundColor": "border_standard"
      },
      {
        "viewId": "content",
        "attributes": [
          {
            "viewId": "contentLeft",
            "attributes": [
              {
                "viewId": "titleArea",
                "attributes": [
                  {
                    "viewId": "title",
                    "text": "$$title",
                    "textSize": 17,
                    "textColor": "bubble_guest_text_primary",
                    "fontBold": true,
                    "maxLine": 1
                  }
                ]
              },
              {
                "viewId": "time",
                "text": "$$time",
                "textSize": 16,
                "textColor": "text_secondary",
                "maxLine": 1
              }
            ]
          },
          {
            "viewId": "contentRight",
            "src": "$$image",
            "radius": 6,
            "event": {
              "init": {
                "visibleCtr": {
                  "visible": "$$image",
                  "visibleBehave": "GONE",
                  "src": "$$image"
                }
              }
            }
          }
        ]
      }
    ]
  }
}

1.5 com.tencent.public.game.mix

json
{
  "version": 1,
  "templateId": "com.tencent.public.game.mix",
  "layout": {
    "viewId": "app",
    "width": -1,
    "height": -2,
    "direction": "vertical",
    "layout": [
      {
        "viewId": "header",
        "direction": "horizontal",
        "marginLeft": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "appIcon",
            "viewType": "image",
            "marginTop": 12,
            "marginBottom": 12,
            "height": 24,
            "width": 24,
            "gravity": "centerVertical"
          },
          {
            "viewId": "appName",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "marginLeft": 12,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "centerVertical"
          },
          {
            "viewId": "more",
            "height": -2,
            "width": -2,
            "marginTop": 12,
            "marginBottom": 12,
            "gravity": "right|centerVertical",
            "layout": [
              {
                "viewId": "moreIcon",
                "viewType": "image",
                "height": 24,
                "width": 24,
                "marginLeft": 16,
                "marginRight": 16
              }
            ]
          }
        ]
      },
      {
        "viewId": "divider1",
        "viewType": "image",
        "height": 0.5,
        "width": -1
      },
      {
        "viewId": "titleArea",
        "direction": "horizontal",
        "marginLeft": 16,
        "marginTop": 12,
        "marginRight": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "title",
            "viewType": "text",
            "height": -2,
            "width": -1,
            "gravity": "centerVertical"
          }
        ]
      },
      {
        "viewId": "contentArea",
        "direction": "horizontal",
        "marginLeft": 16,
        "marginTop": 12,
        "marginRight": 16,
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "contentArea1",
            "width": -2,
            "height": -2,
            "direction": "vertical",
            "gravity": "centerVertical",
            "layout": [
              {
                "viewId": "contentTitle1",
                "viewType": "text",
                "width": -2,
                "height": -2
              },
              {
                "viewId": "contentDes1",
                "viewType": "text",
                "marginTop": 4,
                "width": -2,
                "height": -2
              }
            ]
          },
          {
            "viewId": "contentArea2",
            "marginLeft": 24,
            "width": -2,
            "height": -2,
            "direction": "vertical",
            "gravity": "centerVertical",
            "layout": [
              {
                "viewId": "contentTitle2",
                "viewType": "text",
                "width": -2,
                "height": -2
              },
              {
                "viewId": "contentDes2",
                "viewType": "text",
                "marginTop": 4,
                "width": -2,
                "height": -2
              }
            ]
          },
          {
            "viewId": "contentArea3",
            "marginLeft": 24,
            "width": -1,
            "height": -2,
            "gravity": "centerVertical",
            "direction": "vertical",
            "layout": [
              {
                "viewId": "contentTitle3",
                "viewType": "text",
                "width": -2,
                "height": -2
              },
              {
                "viewId": "contentDes3",
                "viewType": "text",
                "marginTop": 4,
                "width": -2,
                "height": -2
              }
            ]
          },
          {
            "viewId": "contentImage",
            "marginLeft": 7,
            "width": 60,
            "height": 60,
            "gravity": "right",
            "layout": [
              {
                "viewId": "image",
                "viewType": "image",
                "width": 60,
                "height": 60
              }
            ]
          }
        ]
      },
      {
        "viewId": "time",
        "viewType": "text",
        "width": -2,
        "height": -2,
        "marginTop": 12,
        "marginLeft": 16,
        "marginRight": 16,
        "marginBottom": 12
      }
    ]
  },
  "attributes": {
    "viewId": "app",
    "radius": 10,
    "backgroundColor": "bubble_guest",
    "clickable": true,
    "schema": "$$jumpUrl",
    "attributes": [
      {
        "viewId": "header",
        "schema": "$$appJumpUrl",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "attributes": [
          {
            "viewId": "appIcon",
            "src": "$$appIcon",
            "radius": 12
          },
          {
            "viewId": "appName",
            "text": "$$appName",
            "textSize": 16,
            "textColor": "bubble_guest_text_primary",
            "maxLine": 1
          },
          {
            "viewId": "more",
            "attributes": [
              {
                "viewId": "moreIcon",
                "src": "$$moreIcon"
              }
            ],
            "clickable": true,
            "schema": "$$moreJump",
            "event": {
              "init": {
                "visibleCtr": {
                  "visible": "$$moreJump",
                  "visibleBehave": "GONE",
                  "src": "$$moreJump"
                }
              }
            }
          }
        ]
      },
      {
        "viewId": "divider1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$appIcon",
              "visibleBehave": "GONE",
              "src": "$$appIcon"
            }
          }
        },
        "backgroundColor": "border_standard"
      },
      {
        "viewId": "titleArea",
        "attributes": [
          {
            "viewId": "title",
            "text": "$$title",
            "textSize": 17,
            "textColor": "bubble_guest_text_primary",
            "fontBold": true,
            "maxLine": 1
          }
        ]
      },
      {
        "viewId": "contentArea",
        "attributes": [
          {
            "viewId": "contentArea1",
            "attributes": [
              {
                "viewId": "contentTitle1",
                "text": "$$contentTitle1",
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "textSize": 12
              },
              {
                "viewId": "contentDes1",
                "text": "$$contentDes1",
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "textSize": 20,
                "fontBold": 1
              }
            ]
          },
          {
            "viewId": "contentArea2",
            "attributes": [
              {
                "viewId": "contentTitle2",
                "text": "$$contentTitle2",
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "textSize": 12
              },
              {
                "viewId": "contentDes2",
                "text": "$$contentDes2",
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "textSize": 20,
                "fontBold": 1
              }
            ]
          },
          {
            "viewId": "contentArea3",
            "attributes": [
              {
                "viewId": "contentTitle3",
                "text": "$$contentTitle3",
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "textSize": 12
              },
              {
                "viewId": "contentDes3",
                "text": "$$contentDes3",
                "textColor": "bubble_guest_text_primary",
                "maxLine": 1,
                "textSize": 20,
                "fontBold": 1
              }
            ]
          },
          {
            "viewId": "contentImage",
            "event": {
              "init": {
                "visibleCtr": {
                  "visible": "$$image",
                  "visibleBehave": "GONE",
                  "src": "$$image"
                }
              }
            },
            "attributes": [
              {
                "viewId": "image",
                "src": "$$image",
                "radius": 6
              }
            ]
          }
        ]
      },
      {
        "viewId": "time",
        "text": "$$time",
        "textSize": 16,
        "textColor": "text_secondary",
        "maxLine": 1
      }
    ]
  }
}

1.6 com.tencent.public.game.video

json
{
  "version": 1,
  "templateId": "com.tencent.public.game.video",
  "layout": {
    "viewId": "app",
    "width": -1,
    "height": -2,
    "direction": "vertical",
    "layout": [
      {
        "viewId": "header",
        "height": -2,
        "width": -1,
        "layout": [
          {
            "viewId": "image",
            "viewType": "image",
            "height": -2,
            "width": -1,
            "ratio": 1.8
          },
          {
            "viewId": "videoIcon",
            "viewType": "image",
            "height": 65,
            "width": 65,
            "gravity": "center"
          }
        ]
      },
      {
        "viewId": "operationItem1",
        "height": 50,
        "width": -1,
        "marginRight": 16,
        "marginLeft": 16,
        "marginBottom": 12,
        "marginTop": 12,
        "layout": [
          {
            "viewId": "operationArea1",
            "height": -2,
            "width": -1,
            "gravity": "center",
            "direction": "vertical",
            "layout": [
              {
                "viewId": "operationTitle1",
                "viewType": "text",
                "height": -2,
                "width": -1
              },
              {
                "viewId": "operationDes1",
                "viewType": "text",
                "marginTop": 4,
                "height": -2,
                "width": -1
              }
            ]
          }
        ]
      }
    ]
  },
  "attributes": {
    "viewId": "app",
    "radius": 10,
    "backgroundColor": "bubble_guest",
    "clickable": true,
    "schema": "$$jumpUrl",
    "attributes": [
      {
        "viewId": "header",
        "schema": "$$videoUrl",
        "attributes": [
          {
            "viewId": "image",
            "src": "$$image"
          },
          {
            "viewId": "videoIcon",
            "src": "$$videoIcon"
          }
        ]
      },
      {
        "viewId": "operationItem1",
        "event": {
          "init": {
            "visibleCtr": {
              "visible": "$$operationTitle1",
              "visibleBehave": "GONE",
              "src": "$$operationTitle1"
            }
          }
        },
        "attributes": [
          {
            "viewId": "operationArea1",
            "attributes": [
              {
                "viewId": "operationTitle1",
                "text": "$$operationTitle1",
                "textColor": "bubble_guest_text_primary",
                "fontBold": true,
                "textSize": 17,
                "maxLine": 1
              },
              {
                "viewId": "operationDes1",
                "text": "$$operationDes1",
                "textColor": "bubble_guest_text_secondary",
                "textSize": 16,
                "maxLine": 1,
                "event": {
                  "init": {
                    "visibleCtr": {
                      "visible": "$$operationDes1",
                      "visibleBehave": "GONE",
                      "src": "$$operationDes1"
                    }
                  }
                }
              }
            ]
          }
        ]
      }
    ]
  }
}

2. markdown/node 内置片段

这些原文来自:

  • ../../classes14_src/base/markdown/preprocessor/MarkdownPreprocessor.java
  • ../../classes14_src/base/markdown/renderer/compose/elements/code/MarkdownCodeKt.java

2.1 quoteArea 未完成态折叠

md
[ ](mqqapi://markdown/node?nodeType=replace&nodeID=quoteArea
md
[ ](mqqapi://markdown/node?nodeType=quoteArea&nodeID=quoteArea&state=end

这两段来自源码里的 contains(...) 检查,所以当前拿到的是代码内字面量前缀,不是完整最终 URI。

2.2 loading

md
正在获取资料[](mqqapi://markdown/node?nodeType=loading)

另一些文件里也直接出现:

md
[](mqqapi://markdown/node?nodeType=loading)

2.3 inner_typewritePoint

md
[ ](mqqapi://markdown/node?nodeType=inner_typewritePoint)

3. 说明

  • 本页优先保留 app 内原文
  • 当前 6 份内置 RichUI 模板都已完整展开
  • quoteArea 相关两条 replace/end 当前拿到的是源码里的字面量前缀,因为预处理器本身就是用 contains(...) 检查前缀