diff --git a/src/apps/cn.wps.moffice_eng.ts b/src/apps/cn.wps.moffice_eng.ts index 919973977..e661d3d1a 100644 --- a/src/apps/cn.wps.moffice_eng.ts +++ b/src/apps/cn.wps.moffice_eng.ts @@ -149,6 +149,14 @@ export default defineGkdApp({ snapshotUrls: 'https://i.gkd.li/i/26026279', exampleUrls: 'https://e.gkd.li/a17eca15-c7bd-4ea6-ba84-0d3242641697', }, + { + key: 3, + fastQuery: true, + activityIds: 'cn.wps.moffice.main.local.HomeRootActivity', + matches: + '[vid="home_page_list_view"] [vid="card_v"] >2 LinearLayout + * > [vid="close_iv"][visibleToUser=true]', + snapshotUrls: 'https://i.gkd.li/i/28419645', + }, ], }, ], diff --git a/src/apps/com.baidu.tieba.ts b/src/apps/com.baidu.tieba.ts index e46d1d164..c98e01a89 100644 --- a/src/apps/com.baidu.tieba.ts +++ b/src/apps/com.baidu.tieba.ts @@ -18,7 +18,22 @@ export default defineGkdApp({ activityIds: '.pb.pb.main.PbActivity', matches: '@ImageView[clickable=true] -2 LinearLayout > [text^="打开通知"]', - snapshotUrls: 'https://i.gkd.li/import/13536170', + snapshotUrls: 'https://i.gkd.li/i/13536170', + }, + { + key: 1, + activityIds: '.immessagecenter.mention.reply.ReplyMeActivity', + matches: 'TextView[text="开启消息推送"] +2 TextView[text="不开启"]', + snapshotUrls: 'https://i.gkd.li/i/13675694', + }, + { + key: 2, + activityIds: 'com.baidu.tbadk.browser.TBWebContainerActivity', + matches: '[text="开启通知"] [text="暂不开启"]', + snapshotUrls: [ + 'https://i.gkd.li/i/13804455', + 'https://i.gkd.li/i/20918198', + ], }, ], }, @@ -48,7 +63,6 @@ export default defineGkdApp({ key: 1, matches: '@FrameLayout[clickable=true][visibleToUser=true] < LinearLayout < RelativeLayout <3 LinearLayout < RelativeLayout + LinearLayout >2 [text$="广告"]', - exampleUrls: 'https://e.gkd.li/3b2f0906-f620-4fda-a59f-334a9548836e', snapshotUrls: [ 'https://i.gkd.li/i/16595127', 'https://i.gkd.li/i/16595515', @@ -91,11 +105,12 @@ export default defineGkdApp({ 'ImageView[childCount=0] < @FrameLayout[clickable=true][childCount=1][visibleToUser=true] <2 RelativeLayout + RelativeLayout >3 [text="广告"]', snapshotUrls: 'https://i.gkd.li/i/24541094', }, + // 第二段 { key: 50, preKeys: [0, 1, 2, 3, 4, 5], - name: '点击[不感兴趣]', // 直接结束, 无需第三段 + name: '②点击[不感兴趣]', // 直接结束, 无需第三段 matches: '@View[clickable=true][visibleToUser=true] - [text^="选择不喜欢"]', snapshotUrls: [ @@ -107,7 +122,7 @@ export default defineGkdApp({ { key: 51, preKeys: [0, 1, 2, 3, 4, 5], - name: '选一个[理由]', + name: '②选一个[理由]', matches: '[text="已经看过" || text="广告重复" || text="不感兴趣"][clickable=true]', snapshotUrls: [ @@ -117,15 +132,16 @@ export default defineGkdApp({ { key: 52, preKeys: [0, 1, 2, 3, 4, 5], - name: '选[不喜欢]该直播', + name: '②选[不喜欢]该直播', matches: '@[clickable=true] >3 [text="不喜欢"]', snapshotUrls: 'https://i.gkd.li/i/27052244', // [不喜欢] 直播 }, + // 第三段 { key: 100, preKeys: [51, 52], - name: '点击[确定]', + name: '③点击[确定]', matches: '@[clickable=true] - [text^="已选"][text$="理由"]', snapshotUrls: 'https://i.gkd.li/i/26934788', }, @@ -138,26 +154,13 @@ export default defineGkdApp({ matchTime: 10000, forcedTime: 10000, actionMaximum: 1, - activityIds: [ - 'com.baidu.tieba.tblauncher.MainTabActivity', - 'com.baidu.tieba.frs.FrsActivity', - ], + activityIds: ['.tblauncher.MainTabActivity', '.frs.FrsActivity'], rules: [ { key: 1, matches: 'RelativeLayout[childCount=2] > @RelativeLayout[childCount=1][clickable=true] > ImageView', - snapshotUrls: 'https://i.gkd.li/import/13060892', - }, - { - key: 2, - fastQuery: true, - matches: - '@ImageView[childCount=0][clickable=true][visibleToUser=true] < LinearLayout[childCount=1] <4 RelativeLayout +3 LinearLayout >4 [text="小游戏"]', - snapshotUrls: [ - 'https://i.gkd.li/i/17943902', - 'https://i.gkd.li/i/18217417', - ], + snapshotUrls: 'https://i.gkd.li/i/13060892', }, ], }, @@ -168,48 +171,35 @@ export default defineGkdApp({ enable: false, matchTime: 10000, actionMaximum: 1, - activityIds: [ - 'com.baidu.tbadk.browser.TBWebContainerActivity', - 'com.baidu.tieba.frs.FrsActivity', - 'com.baidu.tieba.tblauncher.MainTabActivity', - 'com.baidu.tieba.LogoActivity', - ], rules: [ { key: 1, name: '点击正下方x关闭', + activityIds: [ + '.frs.FrsActivity', + '.tblauncher.MainTabActivity', + '.LogoActivity', + ], matches: - '@TextView[id="com.baidu.tieba:id/obfuscated"][clickable=true][childCount=0][visibleToUser=true] - FrameLayout[childCount=2][getChild(1).text="广告"] < RelativeLayout[childCount=2] < [parent=null]', + '@TextView[vid="obfuscated"][clickable=true][childCount=0][visibleToUser=true] - FrameLayout[childCount=2][getChild(1).text="广告"] < RelativeLayout[childCount=2] < [parent=null]', snapshotUrls: [ - 'https://i.gkd.li/import/13168383', - 'https://i.gkd.li/import/13322120', - 'https://i.gkd.li/import/13328246', + 'https://i.gkd.li/i/13168383', + 'https://i.gkd.li/i/13322120', + 'https://i.gkd.li/i/13328246', ], }, { key: 2, - name: '点击正下方x关闭2', - forcedTime: 10000, - matches: - 'WebView[text="会员弹窗" || text="一键签到"] >(3,4) TextView + Image[text!=null][childCount=0][visibleToUser=true]', - snapshotUrls: [ - 'https://i.gkd.li/i/14630806', - 'https://i.gkd.li/i/14630806', - 'https://i.gkd.li/i/15119439', - 'https://i.gkd.li/i/15119451', - 'https://i.gkd.li/i/16426630', + activityIds: [ + '.tblauncher.MainTabActivity', + 'com.baidu.tbadk.browser.TBWebContainerActivity', ], - }, - { - key: 3, - name: '点击正下方x关闭3', matches: 'WebView[text!=null] > View[childCount=1] > View[childCount=3] > @[visibleToUser=true][index=2]', snapshotUrls: [ 'https://i.gkd.li/i/13060891', 'https://i.gkd.li/i/16703244', ], - excludeSnapshotUrls: ['https://i.gkd.li/i/13222361'], }, ], }, @@ -220,54 +210,41 @@ export default defineGkdApp({ matchDelay: 500, matchTime: 10000, actionMaximum: 1, + activityIds: ['.pb.pb.main.PbActivity', '.tblauncher.MainTabActivity'], rules: [ { key: 0, - name: '首页右侧悬浮广告-1', - activityIds: [ - '.tblauncher.MainTabActivity', - '.pb.pb.main.PbActivity', - ], + fastQuery: true, + name: '悬浮广告1', matches: - '@ImageView[clickable=true][visibleToUser=true][vid="obfuscated"] - [text="广告"]', + '@ImageView[clickable=true][visibleToUser=true][width<77] - [text="广告"]', snapshotUrls: [ - 'https://i.gkd.li/import/13115167', 'https://i.gkd.li/i/16622395', 'https://i.gkd.li/i/16632851', ], - excludeSnapshotUrls: 'https://i.gkd.li/import/13327933', + excludeSnapshotUrls: 'https://i.gkd.li/i/13327933', // 加 [width<77] 排除 }, { key: 1, - name: '首页右侧悬浮广告-2', - activityIds: 'com.baidu.tieba.tblauncher.MainTabActivity', + name: '悬浮广告2', matches: - 'RelativeLayout >2 RelativeLayout[childCount=1] > ImageView[childCount=0][clickable=true]', - snapshotUrls: 'https://i.gkd.li/import/14291964', + 'RelativeLayout[childCount=2] >2 ImageView[clickable=true][visibleToUser=true][width<77]', + snapshotUrls: [ + 'https://i.gkd.li/i/14291964', + 'https://i.gkd.li/i/13625336', + 'https://i.gkd.li/i/13627881', + ], + excludeSnapshotUrls: 'https://i.gkd.li/i/28344945', // 加 RelativeLayout[childCount=2] 排除 }, { key: 2, name: '评论区左侧悬浮广告', - fastQuery: true, - activityIds: 'com.baidu.tieba.pb.pb.main.PbActivity', + activityIds: '.pb.pb.main.PbActivity', matches: 'FrameLayout[getChild(1).getChild(1).text!=null] + @FrameLayout[clickable=true] > LinearLayout[childCount=2] > ImageView + [text="广告"][visibleToUser=true]', - snapshotUrls: 'https://i.gkd.li/import/13296280', + snapshotUrls: 'https://i.gkd.li/i/13296280', excludeSnapshotUrls: 'https://i.gkd.li/i/20361318', }, - { - key: 3, - activityIds: [ - 'com.baidu.tieba.pb.pb.main.PbActivity', - 'com.baidu.tieba.tblauncher.MainTabActivity', - ], - matches: - 'RelativeLayout[childCount=2] > RelativeLayout[childCount=1] > ImageView[childCount=0][clickable=true]', - snapshotUrls: [ - 'https://i.gkd.li/import/13625336', - 'https://i.gkd.li/import/13627881', - ], - }, ], }, { @@ -308,26 +285,23 @@ export default defineGkdApp({ { key: 0, name: '贴吧页签到', - activityIds: 'com.baidu.tieba.forum.ForumActivity', + activityIds: '.forum.ForumActivity', matches: '@TextView[text="签到"][visibleToUser=true] (3,4) TextView + Image[text!=null][childCount=0][visibleToUser=true]', + snapshotUrls: [ + 'https://i.gkd.li/i/14630806', + 'https://i.gkd.li/i/15119439', + 'https://i.gkd.li/i/15119451', + 'https://i.gkd.li/i/16426630', + ], + }, + ], + }, + { + key: 15, + name: '局部广告-信息流广告', + desc: '点击关闭', + fastQuery: true, + forcedTime: 10000, rules: [ { key: 0, + activityIds: '.pb.pb.main.PbActivity', + matches: + '@[clickable=true][visibleToUser=true] <(1,2) RelativeLayout <(1,4) RelativeLayout[childCount>1] >(3,4) [text="广告"]', + snapshotUrls: [ + 'https://i.gkd.li/i/16595124', + 'https://i.gkd.li/i/16596297', + ], + excludeSnapshotUrls: 'https://i.gkd.li/i/16632851', // [childCount>1] 防止误触 + }, + { + key: 1, + activityIds: [ + '.tblauncher.MainTabActivity', + '.pb.pb.main.PbActivity', + '.forum.ForumActivity', + ], + matches: + '@FrameLayout[clickable=true][visibleToUser=true] <4 RelativeLayout + FrameLayout >7 [text="广告"]', + snapshotUrls: [ + 'https://i.gkd.li/i/16595301', + 'https://i.gkd.li/i/16596195', + 'https://i.gkd.li/i/16596775', + ], + }, + { + key: 2, + activityIds: '.tblauncher.MainTabActivity', + matches: + '@ImageView[childCount=0][clickable=true][visibleToUser=true] < LinearLayout[childCount=1] <4 RelativeLayout +3 LinearLayout >4 [text="小游戏"]', + snapshotUrls: [ + 'https://i.gkd.li/i/17943902', + 'https://i.gkd.li/i/18217417', + ], + }, + { + key: 3, + activityIds: '.tblauncher.MainTabActivity', + matches: + 'ImageView < @[clickable=true] <2 FrameLayout[childCount=2] -3 ViewGroup > [text="广告"]', + snapshotUrls: 'https://i.gkd.li/i/28345921', + }, + ], + }, + { + key: 16, + name: '局部广告-感兴趣的吧推广', + desc: '关闭首页、吧内其他贴吧的推广', + rules: [ + { + key: 1, fastQuery: true, activityIds: ['.tblauncher.MainTabActivity', '.forum.ForumActivity'], matches: diff --git a/src/apps/com.cainiao.wireless.ts b/src/apps/com.cainiao.wireless.ts index e6e2f52fa..734e53b31 100644 --- a/src/apps/com.cainiao.wireless.ts +++ b/src/apps/com.cainiao.wireless.ts @@ -82,6 +82,15 @@ export default defineGkdApp({ 'Image[childCount=0][width<100 && height<100] < @View[clickable=true][childCount=1] - Image[childCount=0][text="超时享"] < [childCount=0][text="开心收下"] <2] + [text="近期不再提醒我"]', + 'com.alipay.mobile.nebulax.xriver.activity.XRiverActivity', + ], + anyMatches: [ + '[text^="去"][text.length>2] + [text="近期不再提醒我"]', + '@Image[width<80 && height<80][visibleToUser=true] < View < View < View < View < WebView[text*="半浮层容器"] < WebView <2 * < * < [id="android:id/content"]', + ], snapshotUrls: [ // 弹窗中的文字和图片每隔几秒切换 'https://i.gkd.li/i/16427922', 'https://i.gkd.li/i/22984695', 'https://i.gkd.li/i/22984696', 'https://i.gkd.li/i/24981728', + 'https://i.gkd.li/i/27384135', ], }, { @@ -350,7 +356,7 @@ export default defineGkdApp({ '.AlipayLogin', ], matches: [ - '[text="访问被拒绝" || text="人气太旺啦,请稍后再试" || text="訪問被拒絕" || text="人氣太旺啦,請稍後再試" || text="伺服器繁忙,請稍後再試"][visibleToUser=true]', + '[text="访问被拒绝" || text^="人气太旺啦" || text^="訪問被拒絕" || text^="人氣太旺啦" || text^="伺服器繁忙"][visibleToUser=true]', '[id="com.alipay.mobile.antui:id/back_button"][clickable=true]', ], snapshotUrls: [ diff --git a/src/apps/com.google.android.youtube.ts b/src/apps/com.google.android.youtube.ts index 5319b4449..0f920ddc8 100644 --- a/src/apps/com.google.android.youtube.ts +++ b/src/apps/com.google.android.youtube.ts @@ -38,6 +38,7 @@ export default defineGkdApp({ ], rules: [ { + key: 0, matches: '@[desc="关闭广告面板" || desc="Close ad panel"][clickable=true] - ImageView <<3 FrameLayout < [vid="panel_header"][visibleToUser=true]', snapshotUrls: [ @@ -46,6 +47,19 @@ export default defineGkdApp({ 'https://i.gkd.li/i/14784199', ], }, + { + key: 1, + matches: + '@[clickable=true][index=parent.childCount.minus(1)] -n [text$="广告" || text*="ad " || desc$="广告" || desc*="ad "] <<3 [vid="panel_header"]', + snapshotUrls: [ + 'https://i.gkd.li/i/27373744', + 'https://i.gkd.li/i/27373748', + ], + exampleUrls: [ + 'https://e.gkd.li/e1655855-8497-4b92-8919-4fdb4f6f00b1', + 'https://e.gkd.li/d024797b-88c5-4ab4-aa53-433b1889eaf1', + ], + }, ], }, { diff --git a/src/apps/com.icbc.ts b/src/apps/com.icbc.ts index e670ee643..de904dadd 100644 --- a/src/apps/com.icbc.ts +++ b/src/apps/com.icbc.ts @@ -25,9 +25,16 @@ export default defineGkdApp({ rules: [ { fastQuery: true, - activityIds: 'com.icbc.activity.web.ICBCWebView', + activityIds: [ + '.activity.web.ICBCWebView', + '.activity.main.MainActivity', + '.mydetail.MyDetailMainActivity', + ], matches: '[vid="iv_close_task_center"]', - snapshotUrls: 'https://i.gkd.li/i/22616307', + snapshotUrls: [ + 'https://i.gkd.li/i/22616307', + 'https://i.gkd.li/i/23227312', + ], }, ], }, diff --git a/src/apps/com.jingdong.app.mall.ts b/src/apps/com.jingdong.app.mall.ts index d9108d99c..29b9fcfbe 100644 --- a/src/apps/com.jingdong.app.mall.ts +++ b/src/apps/com.jingdong.app.mall.ts @@ -187,8 +187,8 @@ export default defineGkdApp({ { key: 0, anyMatches: [ - 'ImageView < FrameLayout[index=0] < ViewGroup[childCount>=3] > FrameLayout[index=parent.childCount.minus(1)||index=parent.childCount.minus(2)][childCount=1] > ImageView[desc="关闭"]', - 'View + FrameLayout[index=1] <2 ViewGroup[childCount>=3] > FrameLayout[index=parent.childCount.minus(1)||index=parent.childCount.minus(2)][childCount=1] > ImageView[desc="关闭"]', + 'ImageView < FrameLayout[index=0] < ViewGroup[childCount>=3] > FrameLayout[index=parent.childCount.minus(1)||index=parent.childCount.minus(2)][childCount=1] > ImageView[desc="关闭"][visibleToUser=true]', + 'View + FrameLayout[index=1] <2 ViewGroup[childCount>=3] > FrameLayout[index=parent.childCount.minus(1)||index=parent.childCount.minus(2)][childCount=1] > ImageView[desc="关闭"][visibleToUser=true]', ], snapshotUrls: [ 'https://i.gkd.li/import/13258973', @@ -201,14 +201,14 @@ export default defineGkdApp({ { key: 1, matches: - '@View[desc.length=null][clickable=true][longClickable=false][visibleToUser=true][id=null] -n ImageView[id=null] parent.right.minus(140)][top<=parent.top.plus(30)] -n ImageView[id=null] 2 [text.length>0] < ViewGroup + @ViewGroup > ImageView', - '@ViewGroup[index=parent.childCount.minus(1)] -2 ViewGroup[childCount<=1][index=0] + ViewGroup[childCount=2] >2 [text.length>0&&text.length<=3]', + 'ImageView +n ViewGroup >2 [text.length>0] < ViewGroup + @ViewGroup[clickable=true][visibleToUser=true][right>parent.right.minus(180)] > ImageView <parent.right.minus(180)] -2 ViewGroup[childCount<=1][index=0] + ViewGroup[childCount=2] >2 [text.length>0&&text.length<=3] <(1,3) [text$="用" || text$="收下" || text*="立减"][childCount!=null] <(1,2,3) [id=null][text$="用" || text$="收下" || text*="立减"] < ImageButton[index=0]', + '@[desc^="未选中" || desc^="未選定" || desc^="Unselected"][visibleToUser=true] + [text="原图" || text="原圖" || text="Full Image"]', + '@[desc^="未选中" || desc^="未選定" || desc^="Unselected"][visibleToUser=true]', ], snapshotUrls: [ 'https://i.gkd.li/i/16987145', // 未选中 @@ -420,10 +421,12 @@ export default defineGkdApp({ 'https://i.gkd.li/i/18413281', 'https://i.gkd.li/i/14661734', 'https://i.gkd.li/i/19625049', + 'https://i.gkd.li/i/27852612', ], excludeSnapshotUrls: [ 'https://i.gkd.li/i/16987141', // 已选中 'https://i.gkd.li/i/16987147', // 已选中 + 'https://i.gkd.li/i/27852606', ], }, ], diff --git a/src/apps/com.tencent.mobileqq.ts b/src/apps/com.tencent.mobileqq.ts index b7ae2c2f6..05186408e 100644 --- a/src/apps/com.tencent.mobileqq.ts +++ b/src/apps/com.tencent.mobileqq.ts @@ -82,6 +82,9 @@ export default defineGkdApp({ 'https://i.gkd.li/i/24230528', 'https://i.gkd.li/i/25235782', 'https://i.gkd.li/i/26159150', + 'https://i.gkd.li/i/28426083', + 'https://i.gkd.li/i/28425887', + 'https://i.gkd.li/i/28425944', ], excludeSnapshotUrls: [ 'https://i.gkd.li/i/14414585', // 误触 diff --git a/src/apps/com.twitter.android.ts b/src/apps/com.twitter.android.ts index bf3b96629..e63d87aed 100644 --- a/src/apps/com.twitter.android.ts +++ b/src/apps/com.twitter.android.ts @@ -6,17 +6,15 @@ export default defineGkdApp({ groups: [ { key: 1, - name: '分段广告-信息流广告', - desc: '关闭信息流中的广告', + name: '分段广告-主页信息流广告', + desc: '点击右上角关闭,点击我不喜欢', + actionCd: 3000, // https://github.com/gkd-kit/subscription/issues/832 enable: false, + fastQuery: true, activityIds: [ 'com.twitter.app.main.MainActivity', 'com.twitter.app.profiles.ProfileActivity', - 'com.twitter.tweetdetail.TweetDetailActivity', - 'com.twitter.android.search.implementation.results.SearchActivity', ], - actionCd: 3000, // https://github.com/gkd-kit/subscription/issues/832 - fastQuery: true, rules: [ { key: 0, @@ -24,70 +22,38 @@ export default defineGkdApp({ matches: '@[vid="tweet_curation_action"] <2 * + * >3 [text="视频将在广告后播放"]', snapshotUrls: [ - 'https://i.gkd.li/import/12798795', + 'https://i.gkd.li/i/12798795', 'https://i.gkd.li/i/14782884', ], }, { key: 1, name: '推荐广告-点击右上角关闭', - matches: - '@[id="com.twitter.android:id/tweet_curation_action"] <<(2,5) * * >n [id="com.twitter.android:id/tweet_promoted_badge_bottom"]', + matches: '@[vid="tweet_curation_action"] <2 * + * > [text$="推荐"]', snapshotUrls: [ - 'https://i.gkd.li/import/12813235', + 'https://i.gkd.li/i/12813235', 'https://i.gkd.li/i/14782897', 'https://i.gkd.li/i/17182889', - 'https://i.gkd.li/import/12825969', // com.twitter.tweetdetail.TweetDetailActivity - 'https://i.gkd.li/import/12847584', // com.twitter.android.search.implementation.results.SearchActivity - 'https://i.gkd.li/import/12882676', // com.twitter.tweetdetail.TweetDetailActivity - 'https://i.gkd.li/import/12904603', // com.twitter.app.profiles.ProfileActivity ], }, { key: 2, - name: '点击右上角关闭-英文', matches: '@[vid="tweet_curation_action"] - [vid="tweet_ad_badge_top_right"][visibleToUser=true]', - snapshotUrls: [ - 'https://i.gkd.li/import/13680756', - 'https://i.gkd.li/i/24359526', - ], + snapshotUrls: 'https://i.gkd.li/i/24359526', }, { preKeys: [0, 1, 2], key: 10, - name: '点击屏蔽/隐藏,如果机会全用完需要取消遍再屏蔽', + name: '点击[我不喜欢这个广告]', matches: - '@ViewGroup > [id="com.twitter.android:id/action_sheet_item_title"][text^="屏蔽"||text^="封鎖"||text^="Block"||text^="隐藏 @"||text^="Mute @"||text^="Unblock @"||text^="Unmute @"]', + '@ViewGroup[clickable=true] > [text="我不喜欢这个广告" || text="我不喜歡這個廣告" || text^="屏蔽" || text="封鎖" || text^="Block" ][visibleToUser=true]', snapshotUrls: [ - 'https://i.gkd.li/import/12798810', + 'https://i.gkd.li/i/12798810', 'https://i.gkd.li/i/14782902', - 'https://i.gkd.li/import/12828815', // com.twitter.tweetdetail.TweetDetailActivity - 'https://i.gkd.li/import/12847600', // com.twitter.android.search.implementation.results.SearchActivity - 'https://i.gkd.li/import/12904602', // com.twitter.app.profiles.ProfileActivity - 'https://i.gkd.li/import/13680783', // 兼容英文 - 'https://i.gkd.li/i/20034038', // 封鎖 - 'https://i.gkd.li/i/20239421', 'https://i.gkd.li/i/24359537', - 'https://i.gkd.li/i/25089665', // 屏蔽已用 - 'https://i.gkd.li/i/25461007', // 隐藏已用 - 'https://i.gkd.li/i/25461077', // En-Mute - 'https://i.gkd.li/i/25461050', // En-Unmute - 'https://i.gkd.li/i/26865753', - ], - }, - { - preKeys: 10, - key: 11, - name: '二次确认-点击屏蔽', - matches: - '[text="取消"||text^="Cancel"] + [text="屏蔽"||text^="Block"||text="是的,我确定"||text^="Yes"||text^="屏蔽"||text^="Mute"||text^="Unmute"]', - snapshotUrls: [ - 'https://i.gkd.li/import/12828832', // com.twitter.tweetdetail.TweetDetailActivity - 'https://i.gkd.li/import/12904601', // com.twitter.app.profiles.ProfileActivity - 'https://i.gkd.li/import/13680798', // 兼容英文 - 'https://i.gkd.li/i/25089666', - 'https://i.gkd.li/i/25461062', // En-Unmute + 'https://i.gkd.li/i/28415651', // 我不喜欢*-zh_TW + 'https://i.gkd.li/i/20239421', // ^屏蔽 ], }, ], @@ -118,10 +84,6 @@ export default defineGkdApp({ activityIds: 'com.twitter.tweetdetail.TweetDetailActivity', matches: '[vid="translation_link" || vid="grok_translation_link"][index=parent.childCount.minus(1)][index!=2]', - exampleUrls: [ - 'https://e.gkd.li/ced46989-9c6a-4626-b027-7953e0fdc2c6', - 'https://m.gkd.li/57941037/40ece44f-883f-429a-aa0c-17dac15a50e4', - ], snapshotUrls: [ 'https://i.gkd.li/i/14189817', 'https://i.gkd.li/i/14615911', diff --git a/src/apps/com.xyhui.ts b/src/apps/com.xyhui.ts index 079095dda..b7dda3616 100644 --- a/src/apps/com.xyhui.ts +++ b/src/apps/com.xyhui.ts @@ -77,6 +77,23 @@ export default defineGkdApp({ '@ImageView[width<100 && height<100] <<4 * + * >4 [text="反馈"]', snapshotUrls: 'https://i.gkd.li/i/23567050', }, + { + key: 14, + fastQuery: true, + activityIds: '.lut.act.LutMainActivity', + matches: + '@ImageView[childCount=0][text=null][desc=null][id=null][visibleToUser=true][width<90 && height<90] < FrameLayout[childCount=1][text=null][desc=null][id=null] - FrameLayout[childCount>2] >3 [text^="立即" || text$="应用" || text="了解更多" || text="查看详情"]', + snapshotUrls: 'https://i.gkd.li/i/23937136', + }, + { + key: 15, + name: '京东广告2', + fastQuery: true, + activityIds: '.lut.act.LutMainActivity', + matches: + '@ImageView[childCount=0][text=null][visibleToUser=true] < FrameLayout[childCount=1] <3 FrameLayout[childCount=3] < FrameLayout[childCount=2] +5 FrameLayout[childCount=4] > [text^="扭动或点击"]', + snapshotUrls: 'https://i.gkd.li/i/27525121', + }, ], }, ], diff --git a/src/apps/tv.danmaku.bili.ts b/src/apps/tv.danmaku.bili.ts index dcacc5c0f..eacfee576 100644 --- a/src/apps/tv.danmaku.bili.ts +++ b/src/apps/tv.danmaku.bili.ts @@ -40,8 +40,10 @@ export default defineGkdApp({ { key: 0, name: '点击广告卡片右侧菜单图标', - matches: + anyMatches: [ '[height > prev.bottom.plus(200)] >n [(((desc*="广告"||desc*="来自淘宝")&&desc*="查看")||desc$=",,轻点两下查看详情"||(desc^="【有奖调研】"&&desc.length=22))||(id*="/ad_")][visibleToUser=true] >(2,3,4) @ImageView[visibleToUser=true] < [vid^="more" || id^="tv.danmaku.bili.adbiz:id/more"][visibleToUser=true]', + '[id$="ad_tint_frame" || id$="root_container" || id$="constraintLayout"][visibleToUser=true] >(1,2,3) [vid="more" || id="tv.danmaku.bili.adbiz:id/more"]', + ], snapshotUrls: [ 'https://i.gkd.li/import/12642260', // n = 2 'https://i.gkd.li/import/12705266', // n = 3 @@ -70,6 +72,7 @@ export default defineGkdApp({ 'https://i.gkd.li/i/23123800', 'https://i.gkd.li/i/23687196', 'https://i.gkd.li/i/27153803', + 'https://i.gkd.li/i/27686976', ], excludeSnapshotUrls: ['https://i.gkd.li/i/23833031'], // 会出现按钮在底部导航栏后且visibleToUser=true的情况,需要使用 [height > prev.bottom.plus(200)] 排除,原理是根元素的高度必须大于右侧元素(视频卡片元素)bottom+200 }, diff --git a/src/globalGroups.ts b/src/globalGroups.ts index f3f17d8dc..f2c92d1fa 100644 --- a/src/globalGroups.ts +++ b/src/globalGroups.ts @@ -50,11 +50,9 @@ const OPEN_AD_FAST_COUNT_DOWN_VIDS = '[vid="count_down"||vid="count_down_view"||vid="countDown"||vid="countDownView"||vid="gdt_count_down_view"||vid="GdtCountDownView"||vid="ui_count_down"]'; // 兜底规则保持旧主规则的匹配表达式,避免只优化快速路径导致 desc/宽泛 vid 场景回归。 const OPEN_AD_FALLBACK_MATCHES = `${COMMON_PREFIX}[((text.length<10&&(text*="跳过"||text*="跳 过"||text*="跳過"||text*="跳 過"||text~="(?is).*skip.*")&&text!*="视频"&&text!*="片头"&&text!*="片尾")||id~="(?is).*tt_splash_skip_btn"||(vid~="(?is).*skip.*"&&vid!~="(?is).*video.*"&&vid!~="(?is).*head.*"&&vid!~="(?is).*tail.*"&&!(text="帮助")&&!(text="取消")&&!(text*="退出"))||(vid~="(?is).*count.*"&&vid~="(?is).*down.*"&&!(vid~="(?is).*load.*")&&!(vid~="(?is).*hour.*")&&!(vid~="(?is).*minute.*")&&!(vid~="(?is).*timing.*")&&!(vid~="(?is).*add.*")&&!(vid~="(?is).*ead.*"))||(desc.length<10&&(desc*="跳过"||desc*="跳過"||desc~="(?is).*skip.*")))]${OPEN_AD_TIME_EXCLUDES}`; -const OPEN_AD_TEXT_EXCLUDE_MATCH = - '([text*="搜索" || text="历史记录" || text$="在搜"][text.length>3 && text.length<7][visibleToUser=true]) || ([text="设置" || text$="设置" || text="退款详情" || text="Submit" || text*="阅读并同意" || text$="登录" || text="书签" || text="NEXT"][visibleToUser=true]) || ([text$="选好了" || text^="下一步" || text^="完成" || text*="跳过片"][text.length<10][visibleToUser=true]) || ([text^="选择"][text*="偏好" || text*="兴趣" || text*="喜好"][text.length<10][visibleToUser=true])'; // 快速规则和兜底规则共用旧排除条件,保证优化前后的误触保护一致。 const OPEN_AD_EXCLUDE_MATCHES = [ - OPEN_AD_TEXT_EXCLUDE_MATCH, + '[text="Submit" || text="书签" || text="NEXT" || text="覆盖" || text*="阅读并同意" || ((text*="搜索" || text="历史记录" || text$="在搜") && text.length>3 && text.length<7) || ((text$="设置" || text*="跳过片" || (text^="选择" && (text*="偏好" || text*="兴趣" || text*="喜好" || text*="行业"))) && text.length<10)][visibleToUser=true]', '[id~="(?is).*search.*"] < * > [(id~="(?is).*clear.*")||(id~="(?is).*close.*")||(id~="(?is).*back.*")||(text~="(?is).*取消.*")][height>0&&width>0][top>0&&left>0]', '[name!$=".EditText"] < * > [(id~="(?is).*clear.*")||(id~="(?is).*close.*")||(id~="(?is).*back.*")||(text~="(?is).*取消.*")][height>0&&width>0][top>0&&left>0]', ]; @@ -609,14 +607,14 @@ export default defineGkdGlobalGroups([ key: 4, matches: [ `${COMMON_PREFIX}[(text*="未成年"||text*="儿童"||text*="青少年"||text*="守护")&&text*="模式"&&text.length<15]`, - `${COMMON_PREFIX}[(text*="知道了"||text*="我已知晓"||text*="已满"||text*="不再提醒")&&text.length<8]`, + `${COMMON_PREFIX}[(text*="知道了"||text*="我已知晓"||text*="已满"||text*="不再提")&&text.length<8]`, ], }, { key: 5, matches: [ `${COMMON_PREFIX}[(desc*="未成年"||desc*="儿童"||desc*="青少年"||desc*="守护")&&desc*="模式"&&desc.length<15]`, - `${COMMON_PREFIX}[(desc*="知道了"||desc*="我已知晓"||desc*="已满"||desc*="不再提醒")&&desc.length<8]`, + `${COMMON_PREFIX}[(desc*="知道了"||desc*="我已知晓"||desc*="已满"||desc*="不再提")&&desc.length<8]`, ], }, ],