signal-desktop/.storybook/preview-head.html

60 lines
1.6 KiB
HTML
Raw Normal View History

2023-01-03 19:55:46 +00:00
<!-- Copyright 2019 Signal Messenger, LLC -->
2020-10-30 20:34:04 +00:00
<!-- SPDX-License-Identifier: AGPL-3.0-only -->
2019-12-17 20:25:57 +00:00
<!-- prettier-ignore -->
<link rel="stylesheet" href="../stylesheets/manifest.css" />
<link
href="../node_modules/@indutny/frameless-titlebar/dist/styles.css"
rel="stylesheet"
type="text/css"
/>
2020-09-24 15:11:38 +00:00
<script>
2022-07-05 16:44:53 +00:00
// eslint-disable-next-line
const noop = () => {};
2023-03-28 20:31:24 +00:00
window.Whisper = window.Whisper || {};
window.Whisper.events = {
on: noop,
};
2021-09-17 21:54:41 +00:00
window.SignalWindow = window.SignalWindow || {};
window.SignalWindow.log = {
2020-09-24 15:11:38 +00:00
fatal: console.error.bind(console),
error: console.error.bind(console),
warn: console.warn.bind(console),
info: console.info.bind(console),
debug: console.debug.bind(console),
trace: console.trace.bind(console),
};
window.SignalContext = {
2022-07-05 16:44:53 +00:00
activeWindowService: {
isActive: () => true,
2022-07-05 16:44:53 +00:00
registerForActive: noop,
unregisterForActive: noop,
registerForChange: noop,
unregisterForChange: noop,
},
nativeThemeListener: {
getSystemValue: async () => 'light',
2022-07-05 16:44:53 +00:00
subscribe: noop,
unsubscribe: noop,
},
Settings: {
themeSetting: {
getValue: async () => 'light',
},
2022-07-19 19:03:25 +00:00
waitForChange: () => new Promise(noop),
},
OS: {
2022-07-05 16:44:53 +00:00
hasCustomTitleBar: () => false,
},
2023-04-06 21:49:24 +00:00
config: {},
};
2023-04-03 20:16:27 +00:00
window.ConversationController = window.ConversationController || {};
window.ConversationController.isSignalConversation = () => false;
window.ConversationController.onConvoMessageMount = noop;
2023-03-01 19:00:50 +00:00
window.getPreferredSystemLocales = () => ['en'];
2021-06-23 18:18:47 +00:00
</script>