[mod] css

This commit is contained in:
Andy Bunce 2025-11-01 16:31:29 +00:00
parent 4bfb36e4e0
commit 13871be80b
7 changed files with 43 additions and 29 deletions

View file

@ -3,18 +3,18 @@ import module namespace ast="lsp/ast" at "../webapp/lsp/ast/ast.xqm";
(: declare variable $file:="sample.docs/pdfbox.xqm"; :)
declare variable $file:="sample.docs/simple.xq";
declare variable $A:=doc("sample.docs/parse-pdfbox.xml");
declare variable $A:="sample.docs/pdfbox.xqm";
unparsed-text($file)
unparsed-text($A)
=>ast:build()
=>ast:build({"flatten":true(),"position":true()})
update{
(: update{
for $e in descendant-or-self::element()
let $len:=string-length($e)
let $before:=$e/preceding-sibling::node()/string-length()=>sum()
return (insert node attribute len { $len } into $e,
insert node attribute before { $before } into $e
)
}
} :)

View file

@ -4,3 +4,4 @@ declare variable $parse:=doc($src)/*;
syms:list($parse,string($parse ))