mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) support ?embed=true and &style=light for a clean embed experience
Summary: This adds query parameters useful for tailoring the Grist experience, with an eye to embedding. Setting `style=light` removes side and top bars, as a first pass at a focused view of a single document page (this would benefit from refining). Setting `embed=true` has no significant effect just yet other than it restricts document access to viewer at most (this can be overridden by specifying `/m/default`). Test Plan: added tests Reviewers: dsagal Reviewed By: dsagal Differential Revision: https://phab.getgrist.com/D2585
This commit is contained in:
15
app/client/lib/log.ts
Normal file
15
app/client/lib/log.ts
Normal file
@@ -0,0 +1,15 @@
|
||||
/**
|
||||
* Client-side debug logging.
|
||||
* At the moment this simply logs to the browser console, but it's still useful to have dedicated
|
||||
* methods to allow collecting them in the future, or silencing them in production or in mocha
|
||||
* tests.
|
||||
*/
|
||||
|
||||
export type LogMethod = (message: string, ...args: any[]) => void;
|
||||
|
||||
// tslint:disable:no-console
|
||||
export const debug: LogMethod = console.debug.bind(console);
|
||||
export const info: LogMethod = console.info.bind(console);
|
||||
export const log: LogMethod = console.log.bind(console);
|
||||
export const warn: LogMethod = console.warn.bind(console);
|
||||
export const error: LogMethod = console.error.bind(console);
|
||||
Reference in New Issue
Block a user