File tree Expand file tree Collapse file tree 4 files changed +12
-10
lines changed
Expand file tree Collapse file tree 4 files changed +12
-10
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,12 @@ Consider giving a star ⭐ on [Github](https://github.com/pnd280/complexity).
1212
1313---
1414
15+ ## v0.0.5.18
16+
17+ _ Release date: 27th Nov, 2024_
18+
19+ - ** FIX** : Fixed Thread ToC title retrieval.
20+
1521## v0.0.5.16
1622
1723_ Release date: 23rd Nov, 2024_
Original file line number Diff line number Diff line change 11{
22 "name" : " complexity" ,
33 "displayName" : " Complexity - Perplexity AI Supercharged" ,
4- "version" : " 0.0.5.17 " ,
4+ "version" : " 0.0.5.18 " ,
55 "author" : " pnd280" ,
66 "description" : " ⚡ Supercharge your Perplexity AI" ,
77 "type" : " module" ,
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ import throttle from "lodash/throttle";
88import { AnchorProps } from "@/content-script/components/ThreadToc" ;
99import useRouter from "@/content-script/hooks/useRouter" ;
1010import { useCanvasStore } from "@/content-script/session-store/canvas" ;
11- import { DomHelperSelectors } from "@/utils/DomSelectors" ;
11+ import { DomSelectors } from "@/utils/DomSelectors" ;
1212import UiUtils from "@/utils/UiUtils" ;
1313import { scrollToElement } from "@/utils/utils" ;
1414
@@ -60,14 +60,9 @@ export default function useThreadTocObserver() {
6060
6161 $messageBlocks . forEach ( ( { $query, $answer, $messageBlock } ) => {
6262 queueMicrotask ( ( ) => {
63- const title =
64- $query . find ( "textarea" ) . val ( ) ||
65- $query
66- . find (
67- `>*:not(${ DomHelperSelectors . THREAD . MESSAGE . TEXT_COL_CHILD . MARKDOWN_QUERY } ):not(.tw-sticky)` ,
68- )
69- . first ( )
70- . text ( ) ;
63+ const title = $query
64+ . find ( DomSelectors . THREAD . MESSAGE . TEXT_COL_CHILD . QUERY_TITLE )
65+ . text ( ) ;
7166
7267 if ( ! title . length ) return ;
7368
Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ const DomSelectors = {
1919 TEXT_COL_CHILD : {
2020 /** The query box */
2121 QUERY : ".my-md.md\\:my-lg" ,
22+ QUERY_TITLE : ".group\\/title>:last-child" ,
2223 /** The answer box */
2324 ANSWER : ".mb-md" ,
2425 /** The answer heading */
You can’t perform that action at this time.
0 commit comments