File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 258258 } ) ;
259259 }
260260
261+ function rewriteFeedbackLink ( ) {
262+ var title = encodeURIComponent ( 'Doc feedback: ' + document . title ) ;
263+ var body = encodeURIComponent ( 'Page: ' + location . href + '\n\nWhat could be improved:\n' ) ;
264+ document . querySelectorAll ( '.md-feedback a[href*="discussions/new"]' ) . forEach ( function ( a ) {
265+ a . href = 'https://github.com/utPLSQL/utPLSQL/discussions/new?category=documentation-feedback&title=' + title + '&body=' + body ;
266+ } ) ;
267+ }
268+
261269 /* Hide Material's built-in header controls immediately to prevent a flash
262270 where logo/palette appear before the topbar is painted. */
263271 ensureStyle ( ) ;
273281 applyScheme ( effectiveScheme ( getPreference ( ) ) ) ;
274282
275283 if ( document . readyState === 'loading' ) {
276- document . addEventListener ( 'DOMContentLoaded' , inject ) ;
284+ document . addEventListener ( 'DOMContentLoaded' , function ( ) { inject ( ) ; rewriteFeedbackLink ( ) ; } ) ;
277285 } else {
278286 inject ( ) ;
287+ rewriteFeedbackLink ( ) ;
279288 }
280289
281290 /* Material instant navigation — fires after each page swap. */
282291 if ( typeof document$ !== 'undefined' ) {
283292 document$ . subscribe ( inject ) ;
293+ document$ . subscribe ( rewriteFeedbackLink ) ;
284294 }
285295 /* Fallback: browser history navigation */
286296 window . addEventListener ( 'popstate' , updateActiveLink ) ;
Original file line number Diff line number Diff line change @@ -48,6 +48,20 @@ extra:
4848 analytics :
4949 provider : google
5050 property : G-WMFVR98J0Q
51+ feedback :
52+ title : Was this page helpful?
53+ ratings :
54+ - icon : material/emoticon-happy-outline
55+ name : This page was helpful
56+ data : 1
57+ note : >-
58+ Thanks for your feedback!
59+ - icon : material/emoticon-sad-outline
60+ name : This page could be improved
61+ data : 0
62+ note : >-
63+ Thanks for your feedback! Help us improve this page by
64+ using our <a href="https://github.com/utPLSQL/utPLSQL/discussions/new?category=documentation-feedback" target="_blank" rel="noopener noreferrer">GitHub Discussions</a>.
5165 social :
5266 - icon : fontawesome/brands/twitter
5367 link : https://twitter.com/utPLSQL
You can’t perform that action at this time.
0 commit comments