File tree Expand file tree Collapse file tree 2 files changed +12
-4
lines changed
Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ const inFlightRequests = new Map<string, Promise<unknown>>();
66
77export const client = async < T > (
88 pathname : `/api/${string } `,
9- ttl = 3 * 60 * 1000 ,
9+ ttl = 3 * 60 * 1000 * 0 ,
1010) : Promise < T > => {
1111 const { apiKey } = await settings . getValue ( ) ;
1212 if ( ! apiKey ) {
Original file line number Diff line number Diff line change @@ -13,15 +13,23 @@ export const unfurler = async (el: HTMLAnchorElement) => {
1313 const diagram = await client < CacooDiagram > (
1414 `/api/v1/diagrams/${ encodeURIComponent ( parsed . diagramId ) } .json` ,
1515 ) ;
16- const sheet =
17- parsed . sheetId && diagram . sheets . find ( ( s ) => s . uid === parsed . sheetId ) ;
16+ const sheet = diagram . sheets . find ( ( s ) => s . uid === parsed . sheetId ) ;
1817
19- let title = diagram . title ;
18+ let title = "" ;
19+
20+ title += diagram . title ;
2021
2122 if ( diagram . folderName ) {
2223 title = `${ diagram . folderName } / ${ title } ` ;
2324 }
2425
26+ if ( parsed . shapeId ) {
27+ title = `Shape in ${ title } ` ;
28+ }
29+ if ( parsed . commentId ) {
30+ title = `Comment on ${ title } ` ;
31+ }
32+
2533 title = `[${ diagram . organizationName } ] ${ title } ` ;
2634
2735 if ( sheet ) {
You can’t perform that action at this time.
0 commit comments