File tree Expand file tree Collapse file tree 3 files changed +12
-7
lines changed
Expand file tree Collapse file tree 3 files changed +12
-7
lines changed Original file line number Diff line number Diff line change 3737 npx brrr builds/respec-w3c.js -o builds
3838 file_size=$(stat -c%s "builds/respec-w3c.js")
3939 xfer_file_size=$(stat -c%s "builds/respec-w3c.js.br")
40- curl --fail - L -X PUT "https://respec.org/respec/size" \
40+ curl -L -X PUT "https://respec.org/respec/size" \
4141 -H "Authorization: $RESPEC_SECRET" \
42+ -s -w "HTTP Response Code: %{http_code}\n" \
4243 -d "size=$file_size" -d "xferSize=$xfer_file_size "\
4344 -d "sha=$GITHUB_SHA" -d "timestamp=$timestamp"
4445 env :
Original file line number Diff line number Diff line change 1111import { html , pluralize } from "./import-maps.js" ;
1212import css from "../styles/ui.css.js" ;
1313import { markdownToHtml } from "./markdown.js" ;
14+ import { reindent } from "./reindent.js" ;
1415import { sub } from "./pubsubhub.js" ;
1516export const name = "core/ui" ;
1617
@@ -266,10 +267,15 @@ function rsErrorToHTML(err) {
266267 const plugin = err . plugin
267268 ? `<p class="respec-plugin">(plugin: "${ err . plugin } ")</p>`
268269 : "" ;
270+
269271 const hint = err . hint
270- ? `\n<p class="respec-hint"><strong>How to fix:</strong> ${ markdownToHtml (
271- err . hint ,
272- { inline : true }
272+ ? `\n${ markdownToHtml (
273+ `<p class="respec-hint"><strong>How to fix:</strong> ${ reindent (
274+ err . hint
275+ ) } `,
276+ {
277+ inline : ! err . hint . includes ( "\n" ) ,
278+ }
273279 ) } \n`
274280 : "" ;
275281 const elements = Array . isArray ( err . elements )
Original file line number Diff line number Diff line change @@ -456,9 +456,7 @@ function showErrors({ ambiguous, notFound }) {
456456 } ;
457457
458458 const howToFix = ( howToCiteURL , originalTerm ) => {
459- return docLink `
460- [See search matches for "${ originalTerm } "](${ howToCiteURL } ) or
461- ${ "[Learn about this error|#error-term-not-found]" } .` ;
459+ return docLink `[See search matches for "${ originalTerm } "](${ howToCiteURL } ) or ${ "[Learn about this error|#error-term-not-found]" } .` ;
462460 } ;
463461
464462 for ( const { query, elems } of notFound . values ( ) ) {
You can’t perform that action at this time.
0 commit comments