47edeea601
* Initial implementation of CallsWidgetWindow * Refactor + implement widget resizing logic * Add tests * Enable screen sharing * Channel link * Add more tests * Move constants to common file * Extract boundsDiff into util * Set background color on initialization * Fix channel link * Support installations under a subpath * Fix path, caching issues and pass title * [MM-48142] Fix remaining call state issues in main window (#2349) * Update widget URL to new format * Slightly bump widget dimensions to account for border * Fix call state on parent window
66 lines
1.9 KiB
JavaScript
66 lines
1.9 KiB
JavaScript
// Copyright (c) 2016-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
// Copyright (c) 2015-2016 Yuya Ochiai
|
|
|
|
// This files uses CommonJS.
|
|
/* eslint-disable import/no-commonjs */
|
|
'use strict';
|
|
|
|
const {merge} = require('webpack-merge');
|
|
|
|
const CopyPlugin = require('copy-webpack-plugin');
|
|
|
|
const base = require('./webpack.config.base');
|
|
|
|
module.exports = merge(base, {
|
|
entry: {
|
|
index: './src/main/app/index.ts',
|
|
mainWindow: './src/main/preload/mainWindow.js',
|
|
dropdown: './src/main/preload/dropdown.js',
|
|
downloadsDropdown: './src/main/preload/downloadsDropdown.js',
|
|
downloadsDropdownMenu: './src/main/preload/downloadsDropdownMenu.js',
|
|
preload: './src/main/preload/mattermost.js',
|
|
modalPreload: './src/main/preload/modalPreload.js',
|
|
loadingScreenPreload: './src/main/preload/loadingScreenPreload.js',
|
|
urlView: './src/main/preload/urlView.js',
|
|
callsWidget: './src/main/preload/callsWidget.js',
|
|
},
|
|
externals: {
|
|
'macos-notification-state': 'require("macos-notification-state")',
|
|
'windows-focus-assist': 'require("windows-focus-assist")',
|
|
},
|
|
module: {
|
|
rules: [{
|
|
test: /\.(js|ts)?$/,
|
|
use: {
|
|
loader: 'babel-loader',
|
|
options: {
|
|
include: ['@babel/plugin-proposal-class-properties'],
|
|
},
|
|
},
|
|
}, {
|
|
test: /\.mp3$/,
|
|
type: 'asset/inline',
|
|
},
|
|
{
|
|
test: /\.node$/,
|
|
loader: 'node-loader',
|
|
}],
|
|
},
|
|
plugins: [
|
|
new CopyPlugin({
|
|
patterns: [{
|
|
from: 'assets/**/*',
|
|
context: 'src',
|
|
}],
|
|
}),
|
|
],
|
|
node: {
|
|
__filename: true,
|
|
__dirname: true,
|
|
},
|
|
target: 'electron-main',
|
|
});
|
|
|
|
/* eslint-enable import/no-commonjs */
|