Query for recently accessed/modified/created pages, limiting the query to top-N

Thanks! the following worked (with reverse sorting and top-N, recent pages in the last 30 days)

#+BEGIN_QUERY
{:title [:h3 "Recent Pages"]
:query [:find (pull ?b [* {:block/_parent ...}])
:in $ ?end
:where
[?b :block/updated-at ?v]
[(- ?end 30 * 24 * 60 * 60 * 1000 ) ?period]
[(>= ?v ?period)]
[(< ?v ?end)]
]
:inputs [:end-of-today-ms]
:result-transform (fn [result] (take 15
  (sort-by (comp - (fn [h]
    (get h :block/updated-at))) result)
) )
}
#+END_QUERY