File tree Expand file tree Collapse file tree
renderers/web_core/src/v0_9/rendering Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -360,12 +360,10 @@ export class DataContext {
360360 }
361361
362362 private resolvePath ( path : string ) : string {
363- // In A2UI v0.9, all paths generated by the prompt-first LLM must begin with a leading `/`
364- // to satisfy RFC 6901 JSON Pointer validation.
365- // Thus, paths like `/imageUrl` are effectively relative to this DataContext.
366- const relPath = path . startsWith ( '/' ) ? path . substring ( 1 ) : path ;
367-
368- if ( relPath === '' || relPath === '.' ) {
363+ if ( path . startsWith ( '/' ) ) {
364+ return path ;
365+ }
366+ if ( path === '' || path === '.' ) {
369367 return this . path ;
370368 }
371369
@@ -375,6 +373,6 @@ export class DataContext {
375373 }
376374 if ( base === '/' ) base = '' ;
377375
378- return `${ base } /${ relPath } ` ;
376+ return `${ base } /${ path } ` ;
379377 }
380378}
You can’t perform that action at this time.
0 commit comments