Browse Source

支持按最新回复排序

pull/6/head
hole-thu 5 years ago
parent
commit
1932e8910b
  1. 8
      src/Config.js
  2. 3
      src/flows_api.js

8
src/Config.js

@ -29,6 +29,7 @@ const DEFAULT_CONFIG = {
easter_egg: true,
color_scheme: 'default',
no_c_post: false,
by_c: false,
block_words: [],
whitelist_cw: []
};
@ -441,6 +442,13 @@ export class ConfigUI extends PureComponent {
description="不获取所有带折叠警告的树洞,折叠警告豁免将不起作用"
/>
<hr />
<ConfigSwitch
callback={this.save_changes_bound}
id="by_c"
name="根据最新回复排序"
description="有最新回复的洞在最上面"
/>
<hr />
<p>
新功能建议或问题反馈请在&nbsp;
<a

3
src/flows_api.js

@ -139,7 +139,8 @@ export const API = {
get_list: async (page, token) => {
let response = await fetch(
API_BASE + '/getlist?p=' + page
+ (window.config.no_c_post ? '&no_cw' : ''),
+ (window.config.no_c_post ? '&no_cw' : '')
+ (window.config.by_c ? '&by_c' : ''),
{
headers: {'User-Token': token},
},

Loading…
Cancel
Save